-
Notifications
You must be signed in to change notification settings - Fork 14
/
main.ts
56 lines (52 loc) · 1.34 KB
/
main.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
import { loadOml2d } from 'oh-my-live2d';
import typescriptLogo from './typescript.svg';
import './style.css';
void loadOml2d({
// parentElement: el,
mobileDisplay: true,
primaryColor: '#38B0DE',
models: [
{
path: 'https://registry.npmmirror.com/oml2d-models/latest/files/models/Senko_Normals/senko.model3.json',
stageStyle: {},
mobileScale: 0.08
},
{
path: 'https://registry.npmmirror.com/oml2d-models/latest/files/models/Pio/model.json',
scale: 0.4,
position: [0, 50],
stageStyle: {
height: 300
}
}
],
tips: {
messageLine: 2,
mobileStyle: {
padding: '0px 5px'
},
// style: {
// width: 300,
// height: '100px'
// },
idleTips: {
wordTheDay(wordTheDayData) {
return `${wordTheDayData.hitokoto} by.${wordTheDayData.from}`;
}
}
}
});
document.querySelector<HTMLDivElement>('#app')!.innerHTML = `
<div>
<a href="https://vitejs.dev" target="_blank">
<img src="/vite.svg" class="logo" alt="Vite logo" />
</a>
<a href="https://www.typescriptlang.org/" target="_blank">
<img src="${typescriptLogo}" class="logo vanilla" alt="TypeScript logo" />
</a>
<h1>Vite + TypeScript</h1>
<p class="read-the-docs">
Click on the Vite and TypeScript logos to learn more
</p>
</div>
`;