-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
206 lines (191 loc) · 5.29 KB
/
index.js
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
import { HTMLClip, loadPlugin } from "@donkeyclip/motorcortex";
import Player from "@donkeyclip/motorcortex-player";
import SlideDefinition from "../dist/motorcortex-slides.esm";
const Clip = loadPlugin(SlideDefinition);
const css = `
body {
background-color : white;
}
.container,.container2,.container3,.container4 {
width: 1920px;
height: 1080px;
overflow: hidden;
display: flex;
position: absolute;
}
`;
const html = `
<div>
<div class="container container1"></div>
<div class="container container3"></div>
<div class="container container2"></div>
<div class="container container4"></div>
<div class="container container6"></div>
<div class="container container5"></div>
<div class="container container7"></div>
<div class="container container8"></div>
<div class="container container9"></div>
<div class="container container10"></div>
<div class="container container11"></div>
<div class="container container12"></div>
<div class="container container13"></div>
<div class="container container14"></div>
<div class="container container15"></div>
<div class="container container16"></div>
</div>
`;
const host = document.getElementById("clip");
const containerParams = {
width: "1920px",
height: "1080px",
};
const overlay = ["#101820D7", "#101820FF"];
const main = "#FEE715FF";
const clip = new HTMLClip({
css,
html,
host,
fonts: [
{
type: `google-font`,
src: `https://fonts.googleapis.com/css?family=Roboto+Mono:100,300,400,500,700&display=swap`,
},
],
containerParams,
id: "root",
});
const introClip = new Clip.Intro(
{
title: "Demo",
subtitle: "Promo Plugin",
description: `Lorem ipsum dolor, sit amet consectetur adipisicing elit. Totam
eveniet eosdsdawdw numquam facilis libero iure natus, voluptatibus
deserunt laboriosam, perspiciatis consequatur nostrum.`,
month: "December",
bgUrl:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/kissmybutonbg.jpg",
overlayColor: overlay,
mainColor: main,
},
{
selector: ".container1",
}
);
const dayOne = new Clip.SlideDateOneVid(
{
title: ["the", "MOTORCORTEX TEAM", "Presents"],
description: `Lorem ipsum dolor, sit amet consectetur adipisicing elit. Totam
eveniet eosdsdawdw numquam facilis libero iure natus, voluptatibus
deserunt laboriosam, perspiciatis consequatur nostrum.`,
bgUrl:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/kissmybutonbg.jpg",
overlayColor: overlay,
mainColor: main,
bgUrl2:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/bg2.jpg",
month: "December",
day: `monday`,
dayNumber: 20,
year: 2019,
vidDuration: 6000,
vidLink: [
"https://donkey-spaces.ams3.digitaloceanspaces.com/assets/motorcortex-slides/vid.mp4",
],
},
{
selector: ".container3",
}
);
const scrolPresenter = new Clip.Scrollslide(
{
title: "Presenter",
name: "name surname",
position: "Web developer at kissmybuton",
bgUrl:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/bg3.jpg",
overlayColor: overlay,
mainColor: main,
},
{
selector: ".container4",
}
);
const ltrPresenter = new Clip.LtRslide(
{
title: "Presenter",
name: "name surname",
position: "Web developer at kissmybuton",
bgUrl:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/bg4.jpg",
overlayColor: overlay,
mainColor: main,
},
{
selector: ".container6",
}
);
const dayTwo = new Clip.SlideDateTwo(
{
title: "Presenter",
name: "name surname",
position: "Web developer at kissmybuton",
bigTitle: "Event",
bgUrl:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/bg5.jpg",
overlayColor: overlay,
dateOverlay: "#ff00b3",
mainColor: "#00ff40",
bgUrl2:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/bg2.jpg",
month: "December",
day: `monday`,
dayNumber: 22,
year: 2019,
},
{
selector: ".container7",
}
);
const bttPresenter = new Clip.BtTslide(
{
title: "Presenter",
name: "name surname",
position: "Web developer at kissmybuton",
bgUrl:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/bg4.jpg",
overlayColor: overlay,
mainColor: main,
},
{
selector: ".container10",
}
);
const bttDay = new Clip.BtTslideDate(
{
title: "PresenterTEST",
name: "name surname",
position: "Web developer at kissmybuton",
bgUrl:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/bg3.jpg",
overlayColor: overlay,
dateOverlay: "#ff00b3",
mainColor: "#00ff40",
bgUrl2:
"https://donkeyclip.github.io/motorcortex-slides/demo/assets/bg2.jpg",
month: "December",
day: `monday`,
dayNumber: 21,
year: 2019,
},
{
selector: ".container16",
}
);
clip.addIncident(introClip, 0);
clip.addIncident(dayOne, clip.calculatedDuration - 2000);
clip.addIncident(scrolPresenter, clip.calculatedDuration - 2000);
clip.addIncident(ltrPresenter, clip.calculatedDuration - 2000);
clip.addIncident(dayTwo, clip.calculatedDuration - 2000);
clip.addIncident(bttDay, clip.calculatedDuration - 2000);
clip.addIncident(bttPresenter, clip.calculatedDuration - 2000);
new Player({ clip });