hyperframes 0.1.15 → 0.2.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/dist/cli.js +3968 -3297
- package/dist/skills/hyperframes-captions/SKILL.md +1 -1
- package/dist/skills/hyperframes-compose/SKILL.md +1 -0
- package/dist/studio/assets/index-Bkp9HQbo.css +1 -0
- package/dist/studio/assets/index-DfhSlTti.js +93 -0
- package/dist/studio/index.html +2 -2
- package/dist/templates/_shared/CLAUDE.md +1 -1
- package/package.json +3 -2
- package/dist/studio/assets/index-CLmYRLY-.css +0 -1
- package/dist/studio/assets/index-CRvFpc0E.js +0 -84
- package/dist/templates/decision-tree/compositions/decision_tree.html +0 -420
- package/dist/templates/decision-tree/index.html +0 -56
- package/dist/templates/generators.ts +0 -32
- package/dist/templates/kinetic-type/compositions/main-graphics.html +0 -588
- package/dist/templates/kinetic-type/index.html +0 -61
- package/dist/templates/nyt-graph/compositions/nyt-chart.html +0 -450
- package/dist/templates/nyt-graph/index.html +0 -51
- package/dist/templates/play-mode/compositions/captions.html +0 -163
- package/dist/templates/play-mode/compositions/intro.html +0 -107
- package/dist/templates/play-mode/compositions/stats.html +0 -388
- package/dist/templates/play-mode/index.html +0 -239
- package/dist/templates/product-promo/assets/figma-cursors.svg +0 -30
- package/dist/templates/product-promo/assets/figma-logo-pieces.svg +0 -15
- package/dist/templates/product-promo/assets/figma-logo-pills.svg +0 -6
- package/dist/templates/product-promo/compositions/scene1-logo-intro.html +0 -189
- package/dist/templates/product-promo/compositions/scene2-4-canvas.html +0 -570
- package/dist/templates/product-promo/compositions/scene5-logo-outro.html +0 -226
- package/dist/templates/product-promo/index.html +0 -158
- package/dist/templates/swiss-grid/assets/swiss-grid.svg +0 -116
- package/dist/templates/swiss-grid/compositions/captions.html +0 -148
- package/dist/templates/swiss-grid/compositions/graphics.html +0 -207
- package/dist/templates/swiss-grid/compositions/intro.html +0 -131
- package/dist/templates/swiss-grid/index.html +0 -234
- package/dist/templates/vignelli/compositions/captions.html +0 -181
- package/dist/templates/vignelli/compositions/overlays.html +0 -323
- package/dist/templates/vignelli/index.html +0 -190
- package/dist/templates/warm-grain/compositions/captions.html +0 -147
- package/dist/templates/warm-grain/compositions/graphics.html +0 -164
- package/dist/templates/warm-grain/compositions/intro.html +0 -86
- package/dist/templates/warm-grain/index.html +0 -294
|
@@ -1,239 +0,0 @@
|
|
|
1
|
-
<!doctype html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
<head>
|
|
4
|
-
<meta charset="UTF-8" />
|
|
5
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
-
<title>Hyperframes - Play Mode</title>
|
|
7
|
-
<script src="https://cdn.jsdelivr.net/npm/gsap@3.14.2/dist/gsap.min.js"></script>
|
|
8
|
-
<style>
|
|
9
|
-
body,
|
|
10
|
-
html {
|
|
11
|
-
margin: 0;
|
|
12
|
-
padding: 0;
|
|
13
|
-
width: 1920px;
|
|
14
|
-
height: 1080px;
|
|
15
|
-
overflow: hidden;
|
|
16
|
-
background-color: #ffffff;
|
|
17
|
-
font-family: "Nunito", sans-serif;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
#main-composition {
|
|
21
|
-
width: 1920px;
|
|
22
|
-
height: 1080px;
|
|
23
|
-
position: relative;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
#bg-comp,
|
|
27
|
-
#aroll-comp,
|
|
28
|
-
#intro-comp,
|
|
29
|
-
#stats-comp,
|
|
30
|
-
#captions-comp {
|
|
31
|
-
position: absolute;
|
|
32
|
-
top: 0;
|
|
33
|
-
left: 0;
|
|
34
|
-
width: 100%;
|
|
35
|
-
height: 100%;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
#bg-comp {
|
|
39
|
-
z-index: 1;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
#aroll-comp {
|
|
43
|
-
z-index: 10;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
#intro-comp {
|
|
47
|
-
z-index: 100;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
#stats-comp {
|
|
51
|
-
z-index: 150;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
#captions-comp {
|
|
55
|
-
z-index: 200;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
#aroll-container {
|
|
59
|
-
position: absolute;
|
|
60
|
-
width: 100%;
|
|
61
|
-
height: 100%;
|
|
62
|
-
display: flex;
|
|
63
|
-
justify-content: center;
|
|
64
|
-
align-items: center;
|
|
65
|
-
z-index: 0;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
#short_mag_cut {
|
|
69
|
-
border-radius: 16px;
|
|
70
|
-
box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
|
|
71
|
-
border: 8px solid #ffffff;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
#background-layer {
|
|
75
|
-
position: absolute;
|
|
76
|
-
top: 0;
|
|
77
|
-
left: 0;
|
|
78
|
-
width: 100%;
|
|
79
|
-
height: 100%;
|
|
80
|
-
background-color: #ffffff;
|
|
81
|
-
z-index: 0;
|
|
82
|
-
}
|
|
83
|
-
</style>
|
|
84
|
-
<link
|
|
85
|
-
href="https://fonts.googleapis.com/css2?family=Nunito:wght@900&display=swap"
|
|
86
|
-
rel="stylesheet"
|
|
87
|
-
/>
|
|
88
|
-
</head>
|
|
89
|
-
<body>
|
|
90
|
-
<div
|
|
91
|
-
id="main-composition"
|
|
92
|
-
data-composition-id="main-video"
|
|
93
|
-
data-start="0"
|
|
94
|
-
data-duration="__VIDEO_DURATION__"
|
|
95
|
-
data-width="1920"
|
|
96
|
-
data-height="1080"
|
|
97
|
-
>
|
|
98
|
-
<!-- Background Layer Composition -->
|
|
99
|
-
<div
|
|
100
|
-
id="bg-comp"
|
|
101
|
-
data-composition-id="background"
|
|
102
|
-
data-start="0"
|
|
103
|
-
data-duration="__VIDEO_DURATION__"
|
|
104
|
-
data-width="1920"
|
|
105
|
-
data-height="1080"
|
|
106
|
-
data-track-index="1"
|
|
107
|
-
>
|
|
108
|
-
<div id="background-layer"></div>
|
|
109
|
-
<style>
|
|
110
|
-
#background-layer {
|
|
111
|
-
position: absolute;
|
|
112
|
-
top: 0;
|
|
113
|
-
left: 0;
|
|
114
|
-
width: 100%;
|
|
115
|
-
height: 100%;
|
|
116
|
-
background-color: #ffffff;
|
|
117
|
-
}
|
|
118
|
-
</style>
|
|
119
|
-
<script>
|
|
120
|
-
(function () {
|
|
121
|
-
const tl = gsap.timeline({ paused: true });
|
|
122
|
-
const bg = document.getElementById("background-layer");
|
|
123
|
-
// Sync with A-roll framing 3 (4.659s)
|
|
124
|
-
tl.to(bg, { backgroundColor: "#0057FF", duration: 0.5 }, 4.659);
|
|
125
|
-
// Sync with A-roll framing 4 (8.88s)
|
|
126
|
-
tl.to(bg, { backgroundColor: "#FFFFFF", duration: 0.5 }, 8.88);
|
|
127
|
-
window.__timelines["background"] = tl;
|
|
128
|
-
})();
|
|
129
|
-
</script>
|
|
130
|
-
</div>
|
|
131
|
-
|
|
132
|
-
<!-- A-roll Layer Composition -->
|
|
133
|
-
<div
|
|
134
|
-
id="aroll-comp"
|
|
135
|
-
data-composition-id="aroll-layer"
|
|
136
|
-
data-start="0"
|
|
137
|
-
data-duration="__VIDEO_DURATION__"
|
|
138
|
-
data-width="1920"
|
|
139
|
-
data-height="1080"
|
|
140
|
-
data-track-index="10"
|
|
141
|
-
>
|
|
142
|
-
<div id="aroll-container">
|
|
143
|
-
<video
|
|
144
|
-
id="short_mag_cut"
|
|
145
|
-
src="__VIDEO_SRC__"
|
|
146
|
-
muted
|
|
147
|
-
playsinline
|
|
148
|
-
data-start="0"
|
|
149
|
-
data-duration="__VIDEO_DURATION__"
|
|
150
|
-
data-track-index="1"
|
|
151
|
-
style="width: 100%; height: auto"
|
|
152
|
-
></video>
|
|
153
|
-
</div>
|
|
154
|
-
<audio
|
|
155
|
-
id="a-roll-audio"
|
|
156
|
-
src="__VIDEO_SRC__"
|
|
157
|
-
data-start="0"
|
|
158
|
-
data-duration="__VIDEO_DURATION__"
|
|
159
|
-
data-track-index="5"
|
|
160
|
-
data-volume="1"
|
|
161
|
-
></audio>
|
|
162
|
-
<style>
|
|
163
|
-
#aroll-container {
|
|
164
|
-
position: absolute;
|
|
165
|
-
width: 100%;
|
|
166
|
-
height: 100%;
|
|
167
|
-
display: flex;
|
|
168
|
-
justify-content: center;
|
|
169
|
-
align-items: center;
|
|
170
|
-
}
|
|
171
|
-
#short_mag_cut {
|
|
172
|
-
border-radius: 16px;
|
|
173
|
-
box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
|
|
174
|
-
border: 8px solid #ffffff;
|
|
175
|
-
}
|
|
176
|
-
</style>
|
|
177
|
-
<script>
|
|
178
|
-
(function () {
|
|
179
|
-
const tl = gsap.timeline({ paused: true });
|
|
180
|
-
const container = document.getElementById("aroll-container");
|
|
181
|
-
gsap.set(container, { y: -1100, scale: 0.8 });
|
|
182
|
-
tl.to(container, { y: 0, duration: 1.2, ease: "elastic.out(1, 0.6)" }, 0);
|
|
183
|
-
tl.to(container, { scale: 1.4, x: -300, duration: 1, ease: "back.out(1.7)" }, 1.839);
|
|
184
|
-
tl.to(container, { scale: 0.7, x: 400, duration: 1, ease: "back.out(1.7)" }, 4.659);
|
|
185
|
-
tl.to(container, { scale: 0.9, x: 0, duration: 1, ease: "back.out(1.7)" }, 8.88);
|
|
186
|
-
window.__timelines["aroll-layer"] = tl;
|
|
187
|
-
})();
|
|
188
|
-
</script>
|
|
189
|
-
</div>
|
|
190
|
-
|
|
191
|
-
<!-- Compositions -->
|
|
192
|
-
<div
|
|
193
|
-
id="intro-comp"
|
|
194
|
-
data-composition-id="intro"
|
|
195
|
-
data-composition-src="compositions/intro.html"
|
|
196
|
-
data-start="0"
|
|
197
|
-
data-duration="__VIDEO_DURATION__"
|
|
198
|
-
data-width="1920"
|
|
199
|
-
data-height="1080"
|
|
200
|
-
data-track-index="100"
|
|
201
|
-
></div>
|
|
202
|
-
<div
|
|
203
|
-
id="captions-comp"
|
|
204
|
-
data-composition-id="captions"
|
|
205
|
-
data-composition-src="compositions/captions.html"
|
|
206
|
-
data-start="0"
|
|
207
|
-
data-duration="__VIDEO_DURATION__"
|
|
208
|
-
data-width="1920"
|
|
209
|
-
data-height="1080"
|
|
210
|
-
data-track-index="200"
|
|
211
|
-
></div>
|
|
212
|
-
<div
|
|
213
|
-
id="stats-comp"
|
|
214
|
-
data-composition-id="stats"
|
|
215
|
-
data-composition-src="compositions/stats.html"
|
|
216
|
-
data-start="0"
|
|
217
|
-
data-duration="__VIDEO_DURATION__"
|
|
218
|
-
data-width="1920"
|
|
219
|
-
data-height="1080"
|
|
220
|
-
data-track-index="150"
|
|
221
|
-
></div>
|
|
222
|
-
|
|
223
|
-
<!-- Audio Clips -->
|
|
224
|
-
<audio id="sfx-bounce-0" src="" data-start="0" data-track-index="5"></audio>
|
|
225
|
-
<audio id="sfx-whoosh-1" src="" data-start="1.839" data-track-index="6"></audio>
|
|
226
|
-
<audio id="sfx-pop-1" src="" data-start="2.039" data-track-index="7"></audio>
|
|
227
|
-
<audio id="sfx-whoosh-2" src="" data-start="4.659" data-track-index="6"></audio>
|
|
228
|
-
<audio id="sfx-pop-2" src="" data-start="4.859" data-track-index="7"></audio>
|
|
229
|
-
<audio id="sfx-whoosh-3" src="" data-start="8.88" data-track-index="6"></audio>
|
|
230
|
-
<audio id="sfx-pop-3" src="" data-start="9.08" data-track-index="7"></audio>
|
|
231
|
-
|
|
232
|
-
<script>
|
|
233
|
-
window.__timelines = window.__timelines || {};
|
|
234
|
-
const tl = gsap.timeline({ paused: true });
|
|
235
|
-
window.__timelines["main-video"] = tl;
|
|
236
|
-
</script>
|
|
237
|
-
</div>
|
|
238
|
-
</body>
|
|
239
|
-
</html>
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1920 1080" width="1920" height="1080">
|
|
2
|
-
<defs>
|
|
3
|
-
<filter id="shadow" x="-20%" y="-20%" width="140%" height="140%">
|
|
4
|
-
<feDropShadow dx="0" dy="2" stdDeviation="2" flood-opacity="0.2"/>
|
|
5
|
-
</filter>
|
|
6
|
-
<g id="cursor-arrow">
|
|
7
|
-
<path d="M0 0 L 16 16 L 9.5 16 L 6.5 23 L 6.5 16 L 0 16 Z" fill="white" stroke="#000" stroke-width="1.5" stroke-linejoin="round" filter="url(#shadow)"/>
|
|
8
|
-
</g>
|
|
9
|
-
</defs>
|
|
10
|
-
|
|
11
|
-
<rect width="1920" height="1080" fill="#f0f0f0" />
|
|
12
|
-
|
|
13
|
-
<g id="cursor-designer" transform="translate(600, 500)">
|
|
14
|
-
<use href="#cursor-arrow" x="0" y="0"/>
|
|
15
|
-
<rect x="16" y="20" width="90" height="24" rx="4" fill="#A259FF"/>
|
|
16
|
-
<text x="61" y="36" font-family="Inter, sans-serif" font-size="12" fill="white" text-anchor="middle" font-weight="bold">Designer</text>
|
|
17
|
-
</g>
|
|
18
|
-
|
|
19
|
-
<g id="cursor-engineer" transform="translate(900, 400)">
|
|
20
|
-
<use href="#cursor-arrow" x="0" y="0"/>
|
|
21
|
-
<rect x="16" y="20" width="90" height="24" rx="4" fill="#1ABCFE"/>
|
|
22
|
-
<text x="61" y="36" font-family="Inter, sans-serif" font-size="12" fill="white" text-anchor="middle" font-weight="bold">Engineer</text>
|
|
23
|
-
</g>
|
|
24
|
-
|
|
25
|
-
<g id="cursor-pm" transform="translate(1200, 600)">
|
|
26
|
-
<use href="#cursor-arrow" x="0" y="0"/>
|
|
27
|
-
<rect x="16" y="20" width="50" height="24" rx="4" fill="#F24E1E"/>
|
|
28
|
-
<text x="41" y="36" font-family="Inter, sans-serif" font-size="12" fill="white" text-anchor="middle" font-weight="bold">PM</text>
|
|
29
|
-
</g>
|
|
30
|
-
</svg>
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1920 1080" width="1920" height="1080">
|
|
2
|
-
<g transform="translate(880, 420)">
|
|
3
|
-
<!-- Top-left: rounded square -->
|
|
4
|
-
<path id="logo-tl" d="M 40 0 A 40 40 0 0 0 0 40 L 0 80 A 40 40 0 0 0 40 120 A 40 40 0 0 0 80 80 L 80 40 A 40 40 0 0 0 40 0 Z" fill="#F24E1E" />
|
|
5
|
-
|
|
6
|
-
<!-- Top-right: rounded square -->
|
|
7
|
-
<path id="logo-tr" d="M 120 0 A 40 40 0 0 0 80 40 L 80 80 A 40 40 0 0 0 120 120 A 40 40 0 0 0 160 80 L 160 40 A 40 40 0 0 0 120 0 Z" fill="#A259FF" />
|
|
8
|
-
|
|
9
|
-
<!-- Bottom-left: half-circle -->
|
|
10
|
-
<path id="logo-bl" d="M 0 120 A 40 120 0 0 0 80 120 Z" fill="#1ABCFE" />
|
|
11
|
-
|
|
12
|
-
<!-- Bottom-right: half-circle -->
|
|
13
|
-
<path id="logo-br" d="M 80 120 A 40 120 0 0 0 160 120 Z" fill="#0ACF83" />
|
|
14
|
-
</g>
|
|
15
|
-
</svg>
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1920 1080" width="1920" height="1080">
|
|
2
|
-
<rect id="pill-tl" x="870" y="410" width="80" height="120" rx="40" fill="#F24E1E" />
|
|
3
|
-
<rect id="pill-tr" x="970" y="410" width="80" height="120" rx="40" fill="#A259FF" />
|
|
4
|
-
<rect id="pill-bl" x="870" y="550" width="80" height="120" rx="40" fill="#1ABCFE" />
|
|
5
|
-
<rect id="pill-br" x="970" y="550" width="80" height="120" rx="40" fill="#0ACF83" />
|
|
6
|
-
</svg>
|
|
@@ -1,189 +0,0 @@
|
|
|
1
|
-
<template id="scene1-logo-intro-template">
|
|
2
|
-
<div
|
|
3
|
-
data-composition-id="scene1-logo-intro"
|
|
4
|
-
data-width="1920"
|
|
5
|
-
data-height="1080"
|
|
6
|
-
data-duration="1.5"
|
|
7
|
-
>
|
|
8
|
-
<div class="canvas">
|
|
9
|
-
<!-- Logo Container -->
|
|
10
|
-
<div class="logo-container">
|
|
11
|
-
<svg viewBox="0 0 160 240" width="160" height="240">
|
|
12
|
-
<!-- Figma Logo Pieces -->
|
|
13
|
-
<!-- Top-left: Red (F24E1E) -->
|
|
14
|
-
<path
|
|
15
|
-
class="logo-piece logo-tl"
|
|
16
|
-
d="M 0 40 C 0 17.9 17.9 0 40 0 L 80 0 L 80 80 L 40 80 C 17.9 80 0 62.1 0 40 Z"
|
|
17
|
-
fill="#F24E1E"
|
|
18
|
-
/>
|
|
19
|
-
<!-- Top-right: Purple (A259FF) -->
|
|
20
|
-
<path
|
|
21
|
-
class="logo-piece logo-tr"
|
|
22
|
-
d="M 80 0 L 120 0 C 142.1 0 160 17.9 160 40 C 160 62.1 142.1 80 120 80 L 80 80 L 80 0 Z"
|
|
23
|
-
fill="#A259FF"
|
|
24
|
-
/>
|
|
25
|
-
<!-- Middle-left: Pink (FF7262) -->
|
|
26
|
-
<path
|
|
27
|
-
class="logo-piece logo-ml"
|
|
28
|
-
d="M 0 120 C 0 97.9 17.9 80 40 80 L 80 80 L 80 160 L 40 160 C 17.9 160 0 142.1 0 120 Z"
|
|
29
|
-
fill="#FF7262"
|
|
30
|
-
/>
|
|
31
|
-
<!-- Middle-right: Blue (1ABCFE) -->
|
|
32
|
-
<circle class="logo-piece logo-mr" cx="120" cy="120" r="40" fill="#1ABCFE" />
|
|
33
|
-
<!-- Bottom-left: Green (0ACF83) -->
|
|
34
|
-
<path
|
|
35
|
-
class="logo-piece logo-bl"
|
|
36
|
-
d="M 0 200 C 0 177.9 17.9 160 40 160 L 80 160 L 80 200 C 80 222.1 62.1 240 40 240 C 17.9 240 0 222.1 0 200 Z"
|
|
37
|
-
fill="#0ACF83"
|
|
38
|
-
/>
|
|
39
|
-
</svg>
|
|
40
|
-
</div>
|
|
41
|
-
|
|
42
|
-
<!-- Expanding Ring -->
|
|
43
|
-
<div class="ring-container">
|
|
44
|
-
<svg viewBox="0 0 400 400" width="400" height="400">
|
|
45
|
-
<circle
|
|
46
|
-
class="ring"
|
|
47
|
-
cx="200"
|
|
48
|
-
cy="200"
|
|
49
|
-
r="80"
|
|
50
|
-
fill="none"
|
|
51
|
-
stroke="#FFFFFF"
|
|
52
|
-
stroke-width="4"
|
|
53
|
-
/>
|
|
54
|
-
</svg>
|
|
55
|
-
</div>
|
|
56
|
-
</div>
|
|
57
|
-
|
|
58
|
-
<style>
|
|
59
|
-
[data-composition-id="scene1-logo-intro"] .canvas {
|
|
60
|
-
width: 1920px;
|
|
61
|
-
height: 1080px;
|
|
62
|
-
background-color: #0a0a0f;
|
|
63
|
-
position: relative;
|
|
64
|
-
overflow: hidden;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
[data-composition-id="scene1-logo-intro"] .logo-container {
|
|
68
|
-
position: absolute;
|
|
69
|
-
left: 880px; /* Center X: 960 - 80 */
|
|
70
|
-
top: 420px; /* Center Y: 540 - 120 */
|
|
71
|
-
width: 160px;
|
|
72
|
-
height: 240px;
|
|
73
|
-
transform-origin: center center;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
[data-composition-id="scene1-logo-intro"] .ring-container {
|
|
77
|
-
position: absolute;
|
|
78
|
-
left: 760px; /* 960 - 200 */
|
|
79
|
-
top: 340px; /* 540 - 200 */
|
|
80
|
-
width: 400px;
|
|
81
|
-
height: 400px;
|
|
82
|
-
pointer-events: none;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
[data-composition-id="scene1-logo-intro"] .ring {
|
|
86
|
-
transform-origin: center center;
|
|
87
|
-
opacity: 0;
|
|
88
|
-
}
|
|
89
|
-
</style>
|
|
90
|
-
|
|
91
|
-
<script>
|
|
92
|
-
(function () {
|
|
93
|
-
const tl = gsap.timeline({ paused: true });
|
|
94
|
-
|
|
95
|
-
const pieces = {
|
|
96
|
-
tl: '[data-composition-id="scene1-logo-intro"] .logo-tl',
|
|
97
|
-
tr: '[data-composition-id="scene1-logo-intro"] .logo-tr',
|
|
98
|
-
ml: '[data-composition-id="scene1-logo-intro"] .logo-ml',
|
|
99
|
-
mr: '[data-composition-id="scene1-logo-intro"] .logo-mr',
|
|
100
|
-
bl: '[data-composition-id="scene1-logo-intro"] .logo-bl',
|
|
101
|
-
};
|
|
102
|
-
|
|
103
|
-
const ring = '[data-composition-id="scene1-logo-intro"] .ring';
|
|
104
|
-
const logoContainer = '[data-composition-id="scene1-logo-intro"] .logo-container';
|
|
105
|
-
|
|
106
|
-
// Initial positions: Corners of the screen
|
|
107
|
-
// Viewport is 1920x1080. Center is 960, 540.
|
|
108
|
-
// logo-container is at 880, 420.
|
|
109
|
-
|
|
110
|
-
tl.set(pieces.tl, { x: -960, y: -540 });
|
|
111
|
-
tl.set(pieces.tr, { x: 960, y: -540 });
|
|
112
|
-
tl.set(pieces.ml, { x: -960, y: 0 });
|
|
113
|
-
tl.set(pieces.mr, { x: 960, y: 0 });
|
|
114
|
-
tl.set(pieces.bl, { x: -960, y: 540 });
|
|
115
|
-
|
|
116
|
-
// 1. Converge to center with 3-frame stagger (approx 0.05s at 60fps)
|
|
117
|
-
// 2. Collide with slight bounce (overshoot 1.1x)
|
|
118
|
-
const convergeDuration = 0.6;
|
|
119
|
-
const stagger = 0.05;
|
|
120
|
-
|
|
121
|
-
const pieceArray = [pieces.tl, pieces.tr, pieces.ml, pieces.mr, pieces.bl];
|
|
122
|
-
|
|
123
|
-
pieceArray.forEach((piece, i) => {
|
|
124
|
-
tl.to(
|
|
125
|
-
piece,
|
|
126
|
-
{
|
|
127
|
-
x: 0,
|
|
128
|
-
y: 0,
|
|
129
|
-
duration: convergeDuration,
|
|
130
|
-
ease: "back.out(1.1)",
|
|
131
|
-
},
|
|
132
|
-
i * stagger,
|
|
133
|
-
);
|
|
134
|
-
});
|
|
135
|
-
|
|
136
|
-
// 3. On collision (approx at 0.6 + 4*0.05 = 0.8s), white ring expands
|
|
137
|
-
const collisionTime = convergeDuration + (pieceArray.length - 1) * stagger;
|
|
138
|
-
|
|
139
|
-
tl.fromTo(
|
|
140
|
-
ring,
|
|
141
|
-
{ scale: 0.2, opacity: 1 },
|
|
142
|
-
{
|
|
143
|
-
scale: 2.5,
|
|
144
|
-
opacity: 0,
|
|
145
|
-
duration: 0.4,
|
|
146
|
-
ease: "power2.out",
|
|
147
|
-
},
|
|
148
|
-
collisionTime,
|
|
149
|
-
);
|
|
150
|
-
|
|
151
|
-
// 4. Logo pulses slightly
|
|
152
|
-
tl.to(
|
|
153
|
-
logoContainer,
|
|
154
|
-
{
|
|
155
|
-
scale: 1.05,
|
|
156
|
-
duration: 0.15,
|
|
157
|
-
ease: "power2.out",
|
|
158
|
-
},
|
|
159
|
-
collisionTime,
|
|
160
|
-
);
|
|
161
|
-
|
|
162
|
-
tl.to(
|
|
163
|
-
logoContainer,
|
|
164
|
-
{
|
|
165
|
-
scale: 1,
|
|
166
|
-
duration: 0.15,
|
|
167
|
-
ease: "power2.in",
|
|
168
|
-
},
|
|
169
|
-
collisionTime + 0.15,
|
|
170
|
-
);
|
|
171
|
-
|
|
172
|
-
// 5. Scale down to 0
|
|
173
|
-
tl.to(
|
|
174
|
-
logoContainer,
|
|
175
|
-
{
|
|
176
|
-
scale: 0,
|
|
177
|
-
duration: 0.3,
|
|
178
|
-
ease: "expo.in",
|
|
179
|
-
delay: 0.1,
|
|
180
|
-
},
|
|
181
|
-
collisionTime + 0.3,
|
|
182
|
-
);
|
|
183
|
-
|
|
184
|
-
window.__timelines = window.__timelines || {};
|
|
185
|
-
window.__timelines["scene1-logo-intro"] = tl;
|
|
186
|
-
})();
|
|
187
|
-
</script>
|
|
188
|
-
</div>
|
|
189
|
-
</template>
|