@vanillaskyai/video 0.8.8 → 0.10.0
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/CHANGELOG.md +42 -0
- package/PUBLIC-API.md +5 -8
- package/dist/{builtin-server-CUYPIDE7.js → builtin-server-W4PLJUZ5.js} +2 -2
- package/dist/{catalog-types-BIhSpOWK.d.ts → catalog-types-WTbLP6Jh.d.ts} +5 -1
- package/dist/chapter-title-YRLIQY3V.js +7 -0
- package/dist/check-runtime.js +5 -14
- package/dist/{chunk-AITKH6QT.js → chunk-2HFO22K2.js} +15 -40
- package/dist/chunk-4YM2M62S.js +13 -0
- package/dist/chunk-4ZJLPHBV.js +684 -0
- package/dist/chunk-77VY4O7A.js +390 -0
- package/dist/{chunk-MMUXVA47.js → chunk-7M56IUUX.js} +9 -8
- package/dist/chunk-7NZOMTAL.js +63 -0
- package/dist/{chunk-2DOLF4QN.js → chunk-AUPC6MDK.js} +12 -14
- package/dist/{chunk-352ZZCET.js → chunk-EGVQODKU.js} +2 -2
- package/dist/{chunk-2USVB3CY.js → chunk-ELVOT2FQ.js} +284 -177
- package/dist/chunk-EWWCQFTI.js +18 -0
- package/dist/{chunk-KT3M7KDL.js → chunk-HKUI5BTB.js} +3 -3
- package/dist/chunk-IIN5M5HW.js +697 -0
- package/dist/{chunk-LMG3GHLL.js → chunk-IQMYK5DX.js} +29 -3
- package/dist/{chunk-OWBT45EN.js → chunk-IR44XKBI.js} +1 -1
- package/dist/{chunk-MXZSDGZQ.js → chunk-NMFDC2W2.js} +4 -6
- package/dist/{chunk-5SLENAJW.js → chunk-PAJ44TFW.js} +1 -2
- package/dist/{chunk-L7QGGKJ2.js → chunk-PDQFQIQW.js} +1 -1
- package/dist/{chunk-WJ6FLKNC.js → chunk-R3XAOMKP.js} +14 -0
- package/dist/{chunk-2OKB27TG.js → chunk-RXTN2CW6.js} +2 -2
- package/dist/{chunk-XWWLKRNU.js → chunk-TVIU23OM.js} +38 -49
- package/dist/chunk-XX4GXKTX.js +35 -0
- package/dist/chunk-Z67Q5KUW.js +16 -0
- package/dist/{chunk-3VRMKFM7.js → chunk-ZDJNFA52.js} +11 -24
- package/dist/cinema-media-C7OUPNSH.js +12 -0
- package/dist/cli.js +18 -9
- package/dist/comparison-GNZOR7MF.js +37 -0
- package/dist/compose-video-TBFTONUC.js +12 -0
- package/dist/editorial-timeline-EMV5335S.js +43 -0
- package/dist/{events-BQ6z264n.d.ts → events-B4YCc4vc.d.ts} +1 -1
- package/dist/index.d.ts +4 -6
- package/dist/index.js +3 -7
- package/dist/key-figure-P37VK425.js +30 -0
- package/dist/{kit-tQnCPMOM.d.ts → kit-DrRpdn0p.d.ts} +2 -2
- package/dist/mobile-message-OF7T62B7.js +50 -0
- package/dist/quote-T6WYLN7A.js +33 -0
- package/dist/react.d.ts +21 -11
- package/dist/react.js +585 -826
- package/dist/scene-video-backdrop-PCTARAAJ.js +7 -0
- package/dist/server.d.ts +7 -8
- package/dist/server.js +179 -84
- package/dist/{system-prompt-RRXIWDDD.js → system-prompt-SYRT5DWM.js} +1 -1
- package/dist/template-catalog.d.ts +392 -16
- package/dist/template-catalog.js +1 -1
- package/dist/templates.d.ts +5 -5
- package/dist/test.d.ts +3 -3
- package/dist/test.js +18 -18
- package/dist/text-stream-LD364KBI.js +9 -0
- package/dist/{types-DWFO6qca.d.ts → types-CdBmNTGD.d.ts} +1 -1
- package/dist/{types-CEh9eUFu.d.ts → types-DdZw4GRQ.d.ts} +17 -48
- package/dist/validate-4OUD2CLX.js +10 -0
- package/docs/architecture.md +1 -1
- package/docs/concepts.md +1 -1
- package/docs/custom-templates.md +13 -28
- package/docs/customization.md +11 -59
- package/docs/getting-started.md +2 -2
- package/docs/immersive-interface.md +3 -4
- package/docs/maintainers/cinematic-migration.md +38 -0
- package/docs/media-and-audio.md +14 -14
- package/docs/motion-and-effects.md +6 -14
- package/docs/persistence.md +3 -3
- package/docs/production.md +11 -9
- package/docs/provider-integration.md +9 -16
- package/docs/reference/design-system.html +1 -1
- package/docs/reference/protocol.md +14 -4
- package/docs/testing.md +1 -1
- package/package.json +6 -3
- package/registry/items/backgrounds.json +1 -1
- package/registry/items/chapterTitle.json +80 -0
- package/registry/items/cinemaMedia.json +136 -0
- package/registry/items/comparison.json +168 -0
- package/registry/items/editorialTimeline.json +172 -0
- package/registry/items/keyFigure.json +162 -0
- package/registry/items/mobileMessage.json +153 -0
- package/registry/items/quote.json +161 -0
- package/registry/items/template-context.json +1 -1
- package/registry/items/theme.json +1 -1
- package/starters/video-chat/README.md +24 -26
- package/starters/video-chat/package.json +1 -1
- package/starters/video-chat/providers/video.ts +6 -5
- package/starters/video-chat/stock.ts +35 -151
- package/styles/fonts/OFL.txt +93 -0
- package/styles/fonts/manifest.json +66 -0
- package/styles/fonts/roboto-v51-cyrillic-ext.woff2 +0 -0
- package/styles/fonts/roboto-v51-cyrillic.woff2 +0 -0
- package/styles/fonts/roboto-v51-greek-ext.woff2 +0 -0
- package/styles/fonts/roboto-v51-greek.woff2 +0 -0
- package/styles/fonts/roboto-v51-latin-ext.woff2 +0 -0
- package/styles/fonts/roboto-v51-latin.woff2 +0 -0
- package/styles/fonts/roboto-v51-math.woff2 +0 -0
- package/styles/fonts/roboto-v51-symbols.woff2 +0 -0
- package/styles/fonts/roboto-v51-vietnamese.woff2 +0 -0
- package/styles/fonts/roboto.css +91 -0
- package/styles/video-chat.css +30 -22
- package/dist/bg-confetti-HITCGLGD.js +0 -89
- package/dist/bg-emoji-VU4UZYZN.js +0 -150
- package/dist/bg-media-L34PDQXJ.js +0 -106
- package/dist/brand-message-FUJ4STFO.js +0 -256
- package/dist/chart-bar-EGPHJATL.js +0 -310
- package/dist/chart-counter-5FFWQNZO.js +0 -306
- package/dist/chart-progress-ring-JMXQLMLC.js +0 -302
- package/dist/chunk-4UNKZEAT.js +0 -3575
- package/dist/chunk-5CDAM24P.js +0 -31
- package/dist/chunk-AOWSXU2K.js +0 -18
- package/dist/chunk-CJ7F2CE6.js +0 -104
- package/dist/chunk-FRN6WKHA.js +0 -185
- package/dist/chunk-G5JPHBX7.js +0 -336
- package/dist/chunk-L5BTTCZV.js +0 -97
- package/dist/chunk-P22HHFDK.js +0 -43
- package/dist/chunk-PP3MCPN4.js +0 -1998
- package/dist/chunk-QAAO7OAY.js +0 -19
- package/dist/chunk-S7HFLYNN.js +0 -35
- package/dist/chunk-W3VDIBGR.js +0 -217
- package/dist/chunk-XGRA2MUV.js +0 -242
- package/dist/chunk-XTOXFMLM.js +0 -105
- package/dist/chunk-YJJC4N4D.js +0 -761
- package/dist/compose-video-2NFH4DZY.js +0 -13
- package/dist/cta-logo-YR7LYUR5.js +0 -212
- package/dist/cta-media-DQJBKUO2.js +0 -221
- package/dist/incoming-call-54KQ7O5A.js +0 -323
- package/dist/infographic-before-after-ROS52GOW.js +0 -460
- package/dist/infographic-feature-list-E7MGUDAN.js +0 -272
- package/dist/infographic-problem-solution-3S6NGO5N.js +0 -343
- package/dist/infographic-stat-row-SYB7AB7H.js +0 -247
- package/dist/infographic-steps-KCE6JWE2.js +0 -406
- package/dist/prompt-input-MHX4O42G.js +0 -239
- package/dist/reaction-SLEGR3BE.js +0 -122
- package/dist/scene-video-backdrop-XFPX4O3I.js +0 -10
- package/dist/showcase-code-2HLAVKBM.js +0 -357
- package/dist/showcase-phone-Q4HEO4LH.js +0 -278
- package/dist/showcase-terminal-DL45LUFG.js +0 -312
- package/dist/showcase-web-2QZO73FZ.js +0 -396
- package/dist/social-conversation-75SD2637.js +0 -695
- package/dist/social-milestone-GEFUQSBF.js +0 -296
- package/dist/social-notification-FJ5VHVLK.js +0 -247
- package/dist/social-review-stack-KXQCKFRP.js +0 -242
- package/dist/social-testimonial-JZ7CHC7S.js +0 -287
- package/dist/social-tweet-UCDXM25F.js +0 -298
- package/dist/text-stream-54LXABJW.js +0 -10
- package/dist/validate-T7GBU2YF.js +0 -8
- package/registry/items/barChart.json +0 -245
- package/registry/items/beforeAfter.json +0 -180
- package/registry/items/bigNumber.json +0 -232
- package/registry/items/brandMessage.json +0 -164
- package/registry/items/cardList.json +0 -214
- package/registry/items/chatMessenger.json +0 -151
- package/registry/items/chatWhatsapp.json +0 -151
- package/registry/items/codeEditor.json +0 -191
- package/registry/items/confetti.json +0 -107
- package/registry/items/ctaLogo.json +0 -167
- package/registry/items/ctaMedia.json +0 -200
- package/registry/items/emojiBurst.json +0 -101
- package/registry/items/incomingCall.json +0 -177
- package/registry/items/media.json +0 -187
- package/registry/items/milestone.json +0 -212
- package/registry/items/notification.json +0 -189
- package/registry/items/phoneMockup.json +0 -261
- package/registry/items/problemSolution.json +0 -193
- package/registry/items/progressRing.json +0 -206
- package/registry/items/promptInput.json +0 -155
- package/registry/items/reaction.json +0 -176
- package/registry/items/reviewStack.json +0 -231
- package/registry/items/steps.json +0 -215
- package/registry/items/terminal.json +0 -219
- package/registry/items/testimonial.json +0 -171
- package/registry/items/tripleStats.json +0 -235
- package/registry/items/tweet.json +0 -210
- package/registry/items/webMockup.json +0 -280
|
@@ -1,323 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
fitTextSize,
|
|
3
|
-
stripPipe
|
|
4
|
-
} from "./chunk-S7HFLYNN.js";
|
|
5
|
-
import {
|
|
6
|
-
SceneBackground,
|
|
7
|
-
getMediaBackgroundProps
|
|
8
|
-
} from "./chunk-MXZSDGZQ.js";
|
|
9
|
-
import "./chunk-FRN6WKHA.js";
|
|
10
|
-
import "./chunk-W3VDIBGR.js";
|
|
11
|
-
import {
|
|
12
|
-
SPRING_BOUNCY,
|
|
13
|
-
SPRING_SMOOTH,
|
|
14
|
-
interpolate,
|
|
15
|
-
spring
|
|
16
|
-
} from "./chunk-XTOXFMLM.js";
|
|
17
|
-
import "./chunk-224QNWRA.js";
|
|
18
|
-
import "./chunk-5CDAM24P.js";
|
|
19
|
-
import {
|
|
20
|
-
resolveTokens
|
|
21
|
-
} from "./chunk-XWWLKRNU.js";
|
|
22
|
-
|
|
23
|
-
// src/visual-system/primitives/social/IncomingCallCard.tsx
|
|
24
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
25
|
-
var CLAMP = { extrapolateLeft: "clamp", extrapolateRight: "clamp" };
|
|
26
|
-
var DECLINE_RED = "#FF3B30";
|
|
27
|
-
var ACCEPT_GREEN = "#34C759";
|
|
28
|
-
var PhoneIcon = ({ size, rotated }) => /* @__PURE__ */ jsx(
|
|
29
|
-
"svg",
|
|
30
|
-
{
|
|
31
|
-
width: size,
|
|
32
|
-
height: size,
|
|
33
|
-
viewBox: "0 0 24 24",
|
|
34
|
-
style: {
|
|
35
|
-
transform: rotated ? "rotate(135deg)" : "none",
|
|
36
|
-
display: "block"
|
|
37
|
-
},
|
|
38
|
-
children: /* @__PURE__ */ jsx(
|
|
39
|
-
"path",
|
|
40
|
-
{
|
|
41
|
-
d: "M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1-9.39 0-17-7.61-17-17 0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z",
|
|
42
|
-
fill: "#FFFFFF"
|
|
43
|
-
}
|
|
44
|
-
)
|
|
45
|
-
}
|
|
46
|
-
);
|
|
47
|
-
var IncomingCallCard = ({
|
|
48
|
-
progress,
|
|
49
|
-
width,
|
|
50
|
-
height,
|
|
51
|
-
sceneDuration,
|
|
52
|
-
safeZone,
|
|
53
|
-
callerName: rawCallerName,
|
|
54
|
-
subtitle: rawSubtitle = "is calling....",
|
|
55
|
-
declineLabel: rawDeclineLabel = "Decline",
|
|
56
|
-
acceptLabel: rawAcceptLabel = "Accept",
|
|
57
|
-
textColor = "#FFFFFF",
|
|
58
|
-
beatIntensity = 0
|
|
59
|
-
}) => {
|
|
60
|
-
const dim = Math.min(width, height);
|
|
61
|
-
const callerName = stripPipe(String(rawCallerName || "Your brand"));
|
|
62
|
-
const subtitle = stripPipe(String(rawSubtitle || "is calling...."));
|
|
63
|
-
const declineLabel = stripPipe(String(rawDeclineLabel || "Decline"));
|
|
64
|
-
const acceptLabel = stripPipe(String(rawAcceptLabel || "Accept"));
|
|
65
|
-
const nameSpring = spring(
|
|
66
|
-
interpolate(progress, [0, 0.1], [0, 1], CLAMP),
|
|
67
|
-
SPRING_SMOOTH
|
|
68
|
-
);
|
|
69
|
-
const nameOpacity = interpolate(progress, [0, 0.08], [0, 1], CLAMP);
|
|
70
|
-
const nameY = (1 - nameSpring) * dim * 0.025;
|
|
71
|
-
const subtitleStart = 0.1;
|
|
72
|
-
const subtitleEnd = 0.3;
|
|
73
|
-
const charsRevealed = Math.max(
|
|
74
|
-
0,
|
|
75
|
-
Math.floor(
|
|
76
|
-
interpolate(
|
|
77
|
-
progress,
|
|
78
|
-
[subtitleStart, subtitleEnd],
|
|
79
|
-
[0, subtitle.length],
|
|
80
|
-
CLAMP
|
|
81
|
-
)
|
|
82
|
-
)
|
|
83
|
-
);
|
|
84
|
-
const visibleSubtitle = subtitle.slice(0, charsRevealed);
|
|
85
|
-
const declineSpring = spring(
|
|
86
|
-
interpolate(progress, [0.1, 0.25], [0, 1], CLAMP),
|
|
87
|
-
SPRING_BOUNCY
|
|
88
|
-
);
|
|
89
|
-
const acceptSpring = spring(
|
|
90
|
-
interpolate(progress, [0.13, 0.28], [0, 1], CLAMP),
|
|
91
|
-
SPRING_BOUNCY
|
|
92
|
-
);
|
|
93
|
-
const declineLabelOpacity = interpolate(progress, [0.1, 0.25], [0, 1], CLAMP);
|
|
94
|
-
const acceptLabelOpacity = interpolate(progress, [0.13, 0.28], [0, 1], CLAMP);
|
|
95
|
-
const realT = progress * sceneDuration;
|
|
96
|
-
const vibrateActive = interpolate(progress, [0.28, 0.38], [0, 1], CLAMP);
|
|
97
|
-
const vibrateAngle = vibrateActive * Math.sin(realT * 7 * Math.PI * 2) * 2.5;
|
|
98
|
-
const acceptPulse = progress > 0.35 ? 1 + 0.04 * Math.max(0, Math.sin(realT * Math.PI * 2.4)) : 1;
|
|
99
|
-
const beatGlow = 1 + beatIntensity * 0.35;
|
|
100
|
-
const topPad = Math.max(safeZone.top, height * 0.07);
|
|
101
|
-
const bottomPad = Math.max(safeZone.bottom, height * 0.1);
|
|
102
|
-
const callerBaseFontSize = Math.min(width * 0.16, dim * 0.13);
|
|
103
|
-
const callerFontSize = fitTextSize(callerName, callerBaseFontSize, width * 0.88, {
|
|
104
|
-
minScale: 0.45
|
|
105
|
-
});
|
|
106
|
-
const subtitleFontSize = Math.min(width * 0.075, dim * 0.062);
|
|
107
|
-
const buttonSize = Math.min(width * 0.18, dim * 0.16);
|
|
108
|
-
const phoneIconSize = buttonSize * 0.46;
|
|
109
|
-
const labelFontSize = Math.min(width * 0.04, dim * 0.034);
|
|
110
|
-
const buttonGap = width * 0.3;
|
|
111
|
-
const buttonsBottomFromBottom = bottomPad + labelFontSize * 1.6;
|
|
112
|
-
return /* @__PURE__ */ jsxs(
|
|
113
|
-
"div",
|
|
114
|
-
{
|
|
115
|
-
style: {
|
|
116
|
-
position: "absolute",
|
|
117
|
-
inset: 0,
|
|
118
|
-
pointerEvents: "none"
|
|
119
|
-
},
|
|
120
|
-
children: [
|
|
121
|
-
/* @__PURE__ */ jsxs(
|
|
122
|
-
"div",
|
|
123
|
-
{
|
|
124
|
-
style: {
|
|
125
|
-
position: "absolute",
|
|
126
|
-
top: topPad,
|
|
127
|
-
left: 0,
|
|
128
|
-
right: 0,
|
|
129
|
-
padding: `0 ${width * 0.06}px`,
|
|
130
|
-
display: "flex",
|
|
131
|
-
flexDirection: "column",
|
|
132
|
-
alignItems: "center",
|
|
133
|
-
gap: callerFontSize * 0.45,
|
|
134
|
-
textAlign: "center"
|
|
135
|
-
},
|
|
136
|
-
children: [
|
|
137
|
-
/* @__PURE__ */ jsx(
|
|
138
|
-
"div",
|
|
139
|
-
{
|
|
140
|
-
style: {
|
|
141
|
-
color: textColor,
|
|
142
|
-
fontSize: callerFontSize,
|
|
143
|
-
fontWeight: 600,
|
|
144
|
-
lineHeight: 1.05,
|
|
145
|
-
letterSpacing: -0.5,
|
|
146
|
-
opacity: nameOpacity,
|
|
147
|
-
transform: `translateY(${nameY}px)`,
|
|
148
|
-
textShadow: "0 2px 18px rgba(0,0,0,0.32)"
|
|
149
|
-
},
|
|
150
|
-
children: callerName
|
|
151
|
-
}
|
|
152
|
-
),
|
|
153
|
-
/* @__PURE__ */ jsx(
|
|
154
|
-
"div",
|
|
155
|
-
{
|
|
156
|
-
style: {
|
|
157
|
-
color: textColor,
|
|
158
|
-
fontSize: subtitleFontSize,
|
|
159
|
-
fontWeight: 400,
|
|
160
|
-
textShadow: "0 1px 12px rgba(0,0,0,0.32)",
|
|
161
|
-
minHeight: subtitleFontSize * 1.4
|
|
162
|
-
},
|
|
163
|
-
children: visibleSubtitle
|
|
164
|
-
}
|
|
165
|
-
)
|
|
166
|
-
]
|
|
167
|
-
}
|
|
168
|
-
),
|
|
169
|
-
/* @__PURE__ */ jsxs(
|
|
170
|
-
"div",
|
|
171
|
-
{
|
|
172
|
-
style: {
|
|
173
|
-
position: "absolute",
|
|
174
|
-
bottom: buttonsBottomFromBottom,
|
|
175
|
-
left: 0,
|
|
176
|
-
right: 0,
|
|
177
|
-
display: "flex",
|
|
178
|
-
flexDirection: "row",
|
|
179
|
-
justifyContent: "center",
|
|
180
|
-
alignItems: "flex-end",
|
|
181
|
-
gap: buttonGap
|
|
182
|
-
},
|
|
183
|
-
children: [
|
|
184
|
-
/* @__PURE__ */ jsxs("div", { style: { display: "flex", flexDirection: "column", alignItems: "center", gap: labelFontSize * 0.55 }, children: [
|
|
185
|
-
/* @__PURE__ */ jsx(
|
|
186
|
-
"div",
|
|
187
|
-
{
|
|
188
|
-
style: {
|
|
189
|
-
width: buttonSize,
|
|
190
|
-
height: buttonSize,
|
|
191
|
-
borderRadius: "50%",
|
|
192
|
-
backgroundColor: DECLINE_RED,
|
|
193
|
-
display: "flex",
|
|
194
|
-
alignItems: "center",
|
|
195
|
-
justifyContent: "center",
|
|
196
|
-
transform: `rotate(${vibrateAngle}deg) scale(${declineSpring})`,
|
|
197
|
-
boxShadow: `0 ${dim * 0.012}px ${dim * 0.04}px rgba(0,0,0,0.30)`
|
|
198
|
-
},
|
|
199
|
-
children: /* @__PURE__ */ jsx(PhoneIcon, { size: phoneIconSize, rotated: true })
|
|
200
|
-
}
|
|
201
|
-
),
|
|
202
|
-
/* @__PURE__ */ jsx(
|
|
203
|
-
"div",
|
|
204
|
-
{
|
|
205
|
-
style: {
|
|
206
|
-
color: textColor,
|
|
207
|
-
fontSize: labelFontSize,
|
|
208
|
-
fontWeight: 500,
|
|
209
|
-
opacity: declineLabelOpacity,
|
|
210
|
-
textShadow: "0 1px 8px rgba(0,0,0,0.28)"
|
|
211
|
-
},
|
|
212
|
-
children: declineLabel
|
|
213
|
-
}
|
|
214
|
-
)
|
|
215
|
-
] }),
|
|
216
|
-
/* @__PURE__ */ jsxs("div", { style: { display: "flex", flexDirection: "column", alignItems: "center", gap: labelFontSize * 0.55 }, children: [
|
|
217
|
-
/* @__PURE__ */ jsx(
|
|
218
|
-
"div",
|
|
219
|
-
{
|
|
220
|
-
style: {
|
|
221
|
-
width: buttonSize,
|
|
222
|
-
height: buttonSize,
|
|
223
|
-
borderRadius: "50%",
|
|
224
|
-
backgroundColor: ACCEPT_GREEN,
|
|
225
|
-
display: "flex",
|
|
226
|
-
alignItems: "center",
|
|
227
|
-
justifyContent: "center",
|
|
228
|
-
transform: `rotate(${vibrateAngle}deg) scale(${acceptSpring * acceptPulse})`,
|
|
229
|
-
boxShadow: `0 ${dim * 0.012}px ${dim * 0.05 * beatGlow}px rgba(52,199,89,0.45)`
|
|
230
|
-
},
|
|
231
|
-
children: /* @__PURE__ */ jsx(PhoneIcon, { size: phoneIconSize, rotated: false })
|
|
232
|
-
}
|
|
233
|
-
),
|
|
234
|
-
/* @__PURE__ */ jsx(
|
|
235
|
-
"div",
|
|
236
|
-
{
|
|
237
|
-
style: {
|
|
238
|
-
color: textColor,
|
|
239
|
-
fontSize: labelFontSize,
|
|
240
|
-
fontWeight: 500,
|
|
241
|
-
opacity: acceptLabelOpacity,
|
|
242
|
-
textShadow: "0 1px 8px rgba(0,0,0,0.28)"
|
|
243
|
-
},
|
|
244
|
-
children: acceptLabel
|
|
245
|
-
}
|
|
246
|
-
)
|
|
247
|
-
] })
|
|
248
|
-
]
|
|
249
|
-
}
|
|
250
|
-
)
|
|
251
|
-
]
|
|
252
|
-
}
|
|
253
|
-
);
|
|
254
|
-
};
|
|
255
|
-
|
|
256
|
-
// src/visual-system/scene-templates/incoming-call.tsx
|
|
257
|
-
import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
258
|
-
var IncomingCallTemplate = ({
|
|
259
|
-
variables,
|
|
260
|
-
style,
|
|
261
|
-
progress,
|
|
262
|
-
beatIntensity,
|
|
263
|
-
width,
|
|
264
|
-
height,
|
|
265
|
-
sceneDuration,
|
|
266
|
-
isPlaying = true,
|
|
267
|
-
safeZone,
|
|
268
|
-
backgroundEffect
|
|
269
|
-
}) => {
|
|
270
|
-
const { primary, foreground } = resolveTokens(style);
|
|
271
|
-
const callerName = String(variables.callerName || "Your brand");
|
|
272
|
-
const subtitle = String(variables.subtitle || "is calling....");
|
|
273
|
-
return /* @__PURE__ */ jsxs2(
|
|
274
|
-
"div",
|
|
275
|
-
{
|
|
276
|
-
style: {
|
|
277
|
-
width,
|
|
278
|
-
height,
|
|
279
|
-
backgroundColor: "var(--vanillasky-template-surface, #000)",
|
|
280
|
-
position: "relative",
|
|
281
|
-
overflow: "hidden",
|
|
282
|
-
fontFamily: "system-ui, -apple-system, 'SF Pro Display', 'Segoe UI', Roboto, sans-serif"
|
|
283
|
-
},
|
|
284
|
-
children: [
|
|
285
|
-
/* @__PURE__ */ jsx2(
|
|
286
|
-
SceneBackground,
|
|
287
|
-
{
|
|
288
|
-
style,
|
|
289
|
-
progress,
|
|
290
|
-
sceneDuration,
|
|
291
|
-
width,
|
|
292
|
-
height,
|
|
293
|
-
...getMediaBackgroundProps(variables),
|
|
294
|
-
backgroundEffect,
|
|
295
|
-
seed: `${callerName}${subtitle}`,
|
|
296
|
-
isPlaying,
|
|
297
|
-
beatIntensity
|
|
298
|
-
}
|
|
299
|
-
),
|
|
300
|
-
/* @__PURE__ */ jsx2(
|
|
301
|
-
IncomingCallCard,
|
|
302
|
-
{
|
|
303
|
-
progress,
|
|
304
|
-
width,
|
|
305
|
-
height,
|
|
306
|
-
sceneDuration: sceneDuration ?? 4,
|
|
307
|
-
safeZone: { top: safeZone.top, bottom: safeZone.bottom },
|
|
308
|
-
callerName,
|
|
309
|
-
subtitle,
|
|
310
|
-
declineLabel: String(variables.declineLabel || "Decline"),
|
|
311
|
-
acceptLabel: String(variables.acceptLabel || "Accept"),
|
|
312
|
-
textColor: foreground,
|
|
313
|
-
accent: primary,
|
|
314
|
-
beatIntensity
|
|
315
|
-
}
|
|
316
|
-
)
|
|
317
|
-
]
|
|
318
|
-
}
|
|
319
|
-
);
|
|
320
|
-
};
|
|
321
|
-
export {
|
|
322
|
-
IncomingCallTemplate
|
|
323
|
-
};
|