@zync/zync-screnplay-player 0.1.204 → 0.1.205

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.
Files changed (25) hide show
  1. package/dist/bundle.js +1 -1
  2. package/dist/screenplay/RemotionRenderer/components/LottieAnimationGlobal.js +21 -21
  3. package/dist/screenplay/RemotionRenderer/components/layouts/CreatorCollabColdOpen.js +741 -0
  4. package/dist/screenplay/RemotionRenderer/components/layouts/CreatorCollabConversationSpine.js +607 -0
  5. package/dist/screenplay/RemotionRenderer/components/layouts/CreatorCollabDocumentaryInset.js +606 -0
  6. package/dist/screenplay/RemotionRenderer/components/layouts/CreatorCollabRackFocus.js +603 -0
  7. package/dist/screenplay/RemotionRenderer/components/layouts/CreatorCollabStudioSet.js +589 -0
  8. package/dist/screenplay/RemotionRenderer/components/utils/FaceCenteredVideo.js +50 -50
  9. package/dist/screenplay/RemotionRenderer/components/utils/PausableImg.js +4 -4
  10. package/dist/screenplay/RemotionRenderer/components/utils/README.md +80 -80
  11. package/dist/screenplay/RemotionRenderer/components/utils/StretchTextDemo.js +3 -3
  12. package/dist/screenplay/RemotionRenderer/development.js +164 -1239
  13. package/dist/screenplay/RemotionRenderer/helpers/convertToSeconds.js +8 -8
  14. package/dist/screenplay/RemotionRenderer/helpers/faceBasedVideoStyles.js +4 -4
  15. package/dist/screenplay/RemotionRenderer/helpers/faceCenteredVideoTransforms.js +46 -46
  16. package/dist/screenplay/RemotionRenderer/main/lib/layouts/CreatorCollabColdOpenLayout.js +22 -0
  17. package/dist/screenplay/RemotionRenderer/main/lib/layouts/CreatorCollabConversationSpineLayout.js +22 -0
  18. package/dist/screenplay/RemotionRenderer/main/lib/layouts/CreatorCollabDocumentaryInsetLayout.js +22 -0
  19. package/dist/screenplay/RemotionRenderer/main/lib/layouts/CreatorCollabRackFocusLayout.js +22 -0
  20. package/dist/screenplay/RemotionRenderer/main/lib/layouts/CreatorCollabStudioSetLayout.js +22 -0
  21. package/dist/screenplay/RemotionRenderer/main/lib/layouts/LayoutFactory.js +25 -0
  22. package/dist/screenplay/RemotionRenderer/main/screenplaySchema.js +51 -51
  23. package/dist/screenplay/RemotionRenderer/registeredComponents.js +12 -2
  24. package/dist/screenplay/RemotionRenderer/tracks/LayoutVideoTrack.js +20 -20
  25. package/package.json +47 -47
@@ -0,0 +1,603 @@
1
+ import React from 'react';
2
+ import { AbsoluteFill, Easing, interpolate, OffthreadVideo, useCurrentFrame, useVideoConfig } from 'remotion';
3
+ import { loadFont as loadHeadlineFont } from '@remotion/google-fonts/Oswald';
4
+ import { loadFont as loadBodyFont } from '@remotion/google-fonts/Poppins';
5
+ import { useOrientationBased } from '../../hooks/useOrientationBased.js';
6
+ import { useTheme } from '../../theme/hooks/useTheme.js';
7
+ import { distributeTextToFit } from '../../theme/themes/default/Sentence/SentenceSimple.helpers.js';
8
+ import FaceCenteredVideo from '../utils/FaceCenteredVideo';
9
+ import { BlurOverlay } from '../utils/BlurOverlay';
10
+ import { CHROME_PADDING } from '../../config.js';
11
+ import { useVirtualBackground } from '../../hooks/useVirtualBackground';
12
+ import { VirtualBackgroundUnderlay } from '../backgrounds/VirtualBackgroundUnderlay';
13
+ var _loadHeadlineFont = loadHeadlineFont(),
14
+ headlineFontFamily = _loadHeadlineFont.fontFamily;
15
+ var _loadBodyFont = loadBodyFont(),
16
+ bodyFontFamily = _loadBodyFont.fontFamily;
17
+ var withAlpha = function withAlpha(color, alpha) {
18
+ if (!color || typeof color !== 'string' || !color.startsWith('#')) {
19
+ return color;
20
+ }
21
+ var hex = color.replace('#', '');
22
+ if (![3, 6].includes(hex.length)) {
23
+ return color;
24
+ }
25
+ var normalizedHex = hex.length === 3 ? hex.split('').map(function (_char) {
26
+ return _char + _char;
27
+ }).join('') : hex;
28
+ var intValue = Number.parseInt(normalizedHex, 16);
29
+ if (Number.isNaN(intValue)) {
30
+ return color;
31
+ }
32
+ var r = intValue >> 16 & 255;
33
+ var g = intValue >> 8 & 255;
34
+ var b = intValue & 255;
35
+ return "rgba(".concat(r, ", ").concat(g, ", ").concat(b, ", ").concat(alpha, ")");
36
+ };
37
+ var sanitizeText = function sanitizeText(value) {
38
+ return typeof value === 'string' ? value.trim() : '';
39
+ };
40
+ var clampLines = function clampLines() {
41
+ var lines = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
42
+ var maxLines = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 2;
43
+ if (lines.length <= maxLines) return lines;
44
+ var trimmed = lines.slice(0, maxLines);
45
+ var last = trimmed[maxLines - 1].trimEnd();
46
+ var shortened = last.length > 3 ? last.slice(0, -3).trimEnd() : last;
47
+ trimmed[maxLines - 1] = "".concat(shortened, "...");
48
+ return trimmed;
49
+ };
50
+ var mergeFilters = function mergeFilters() {
51
+ for (var _len = arguments.length, filters = new Array(_len), _key = 0; _key < _len; _key++) {
52
+ filters[_key] = arguments[_key];
53
+ }
54
+ var merged = filters.filter(Boolean);
55
+ return merged.length ? merged.join(' ') : undefined;
56
+ };
57
+ var interpolateWithClamp = function interpolateWithClamp(frame, inputRange, outputRange) {
58
+ var easing = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : Easing.out(Easing.ease);
59
+ return interpolate(frame, inputRange, outputRange, {
60
+ easing: easing,
61
+ extrapolateLeft: 'clamp',
62
+ extrapolateRight: 'clamp'
63
+ });
64
+ };
65
+ export var CreatorCollabRackFocus = function CreatorCollabRackFocus(_ref) {
66
+ var children = _ref.children,
67
+ text = _ref.text,
68
+ fullName = _ref.fullName,
69
+ title = _ref.title,
70
+ collaboratorName = _ref.collaboratorName,
71
+ collaboratorTitle = _ref.collaboratorTitle,
72
+ topicLabel = _ref.topicLabel,
73
+ activeSpeaker = _ref.activeSpeaker,
74
+ _ref$startVideoFrom = _ref.startVideoFrom,
75
+ startVideoFrom = _ref$startVideoFrom === void 0 ? 0 : _ref$startVideoFrom,
76
+ firstVideoFile = _ref.firstVideoFile,
77
+ _ref$startSecondVideo = _ref.startSecondVideoFrom,
78
+ startSecondVideoFrom = _ref$startSecondVideo === void 0 ? 0 : _ref$startSecondVideo,
79
+ secondVideoFile = _ref.secondVideoFile,
80
+ firstNoBackgroundVideoUrl = _ref.firstNoBackgroundVideoUrl,
81
+ firstNoBackgroundFaceMetadata = _ref.firstNoBackgroundFaceMetadata,
82
+ noBackgroundVideoEffects = _ref.noBackgroundVideoEffects;
83
+ var _useVideoConfig = useVideoConfig(),
84
+ width = _useVideoConfig.width,
85
+ height = _useVideoConfig.height,
86
+ fps = _useVideoConfig.fps,
87
+ durationInFrames = _useVideoConfig.durationInFrames;
88
+ var frame = useCurrentFrame();
89
+ var _useTheme = useTheme(),
90
+ primaryColor = _useTheme.primaryColor,
91
+ primaryContrast = _useTheme.primaryContrast,
92
+ accentColor = _useTheme.accentColor;
93
+ var _useVirtualBackground = useVirtualBackground(),
94
+ isVirtual = _useVirtualBackground.isVirtual,
95
+ virtualBgUrl = _useVirtualBackground.url;
96
+ var showVirtual = isVirtual && !!firstNoBackgroundVideoUrl;
97
+ var safeText = sanitizeText(text);
98
+ var safeTopicLabel = sanitizeText(topicLabel);
99
+ var safeFullName = sanitizeText(fullName);
100
+ var safeTitle = sanitizeText(title);
101
+ var safeCollaboratorName = sanitizeText(collaboratorName);
102
+ var safeCollaboratorTitle = sanitizeText(collaboratorTitle);
103
+ var speaker = sanitizeText(activeSpeaker).toLowerCase();
104
+ var collaboratorActive = speaker === 'collaborator';
105
+ var hasTitle = Boolean(safeText);
106
+ var hasHostInfo = Boolean(safeFullName || safeTitle);
107
+ var hasCollaboratorInfo = Boolean(safeCollaboratorName || safeCollaboratorTitle);
108
+ var hasCollaboratorVideo = Boolean(secondVideoFile);
109
+ var showCollaboratorLayer = hasCollaboratorVideo || hasCollaboratorInfo;
110
+ var _useOrientationBased = useOrientationBased({
111
+ landscape: {
112
+ framePadding: CHROME_PADDING + 12,
113
+ introTop: height * 0.22,
114
+ introLeft: CHROME_PADDING + 16,
115
+ introCentered: false,
116
+ introWidth: Math.min(width * 0.5, 840),
117
+ introHeight: height * 0.3,
118
+ introFontSize: 90,
119
+ introMaxLines: 3,
120
+ compactTop: CHROME_PADDING + 14,
121
+ compactLeft: CHROME_PADDING + 16,
122
+ compactWidth: Math.min(width * 0.34, 560),
123
+ compactHeight: 112,
124
+ compactFontSize: 38,
125
+ compactMaxLines: 2,
126
+ topicFontSize: 12,
127
+ hostLeft: CHROME_PADDING + 16,
128
+ hostBottom: 114,
129
+ hostWidth: Math.min(width * 0.34, 540),
130
+ hostNameMaxFontSize: 34,
131
+ hostRoleMaxFontSize: 20,
132
+ layerTop: height * 0.14,
133
+ layerLeft: width * 0.48,
134
+ layerWidth: Math.min(width * 0.56, 860),
135
+ layerHeight: Math.min(height * 0.74, 780),
136
+ layerRadius: 44,
137
+ layerNameMaxSize: 32,
138
+ layerRoleMaxSize: 17,
139
+ layerLabelSize: 11
140
+ },
141
+ portrait: {
142
+ framePadding: CHROME_PADDING + 4,
143
+ introTop: height * 0.18,
144
+ introLeft: width / 2,
145
+ introCentered: true,
146
+ introWidth: Math.min(width * 0.8, 620),
147
+ introHeight: height * 0.24,
148
+ introFontSize: 62,
149
+ introMaxLines: 3,
150
+ compactTop: CHROME_PADDING + 18,
151
+ compactLeft: CHROME_PADDING + 8,
152
+ compactWidth: Math.min(width * 0.62, 500),
153
+ compactHeight: 120,
154
+ compactFontSize: 33,
155
+ compactMaxLines: 2,
156
+ topicFontSize: 15,
157
+ hostLeft: CHROME_PADDING + 8,
158
+ hostBottom: 178,
159
+ hostWidth: Math.min(width * 0.58, 480),
160
+ hostNameMaxFontSize: 40,
161
+ hostRoleMaxFontSize: 24,
162
+ layerTop: CHROME_PADDING + 38,
163
+ layerLeft: width * 0.08,
164
+ layerWidth: width * 0.84,
165
+ layerHeight: Math.min(height * 0.32, 330),
166
+ layerRadius: 30,
167
+ layerNameMaxSize: 25,
168
+ layerRoleMaxSize: 15,
169
+ layerLabelSize: 12
170
+ },
171
+ square: {
172
+ framePadding: CHROME_PADDING + 4,
173
+ introTop: height * 0.2,
174
+ introLeft: width / 2,
175
+ introCentered: true,
176
+ introWidth: Math.min(width * 0.76, 540),
177
+ introHeight: height * 0.23,
178
+ introFontSize: 56,
179
+ introMaxLines: 2,
180
+ compactTop: CHROME_PADDING + 10,
181
+ compactLeft: CHROME_PADDING + 6,
182
+ compactWidth: Math.min(width * 0.6, 420),
183
+ compactHeight: 84,
184
+ compactFontSize: 28,
185
+ compactMaxLines: 1,
186
+ topicFontSize: 11,
187
+ hostLeft: CHROME_PADDING + 6,
188
+ hostBottom: 146,
189
+ hostWidth: Math.min(width * 0.54, 400),
190
+ hostNameMaxFontSize: 31,
191
+ hostRoleMaxFontSize: 18,
192
+ layerTop: CHROME_PADDING + 32,
193
+ layerLeft: width * 0.08,
194
+ layerWidth: width * 0.84,
195
+ layerHeight: Math.min(height * 0.28, 230),
196
+ layerRadius: 26,
197
+ layerNameMaxSize: 20,
198
+ layerRoleMaxSize: 12,
199
+ layerLabelSize: 10
200
+ }
201
+ }),
202
+ orientation = _useOrientationBased.orientation,
203
+ framePadding = _useOrientationBased.framePadding,
204
+ introTop = _useOrientationBased.introTop,
205
+ introLeft = _useOrientationBased.introLeft,
206
+ introCentered = _useOrientationBased.introCentered,
207
+ introWidth = _useOrientationBased.introWidth,
208
+ introHeight = _useOrientationBased.introHeight,
209
+ introFontSize = _useOrientationBased.introFontSize,
210
+ introMaxLines = _useOrientationBased.introMaxLines,
211
+ compactTop = _useOrientationBased.compactTop,
212
+ compactLeft = _useOrientationBased.compactLeft,
213
+ compactWidth = _useOrientationBased.compactWidth,
214
+ compactHeight = _useOrientationBased.compactHeight,
215
+ compactFontSize = _useOrientationBased.compactFontSize,
216
+ compactMaxLines = _useOrientationBased.compactMaxLines,
217
+ topicFontSize = _useOrientationBased.topicFontSize,
218
+ hostLeft = _useOrientationBased.hostLeft,
219
+ hostBottom = _useOrientationBased.hostBottom,
220
+ hostWidth = _useOrientationBased.hostWidth,
221
+ hostNameMaxFontSize = _useOrientationBased.hostNameMaxFontSize,
222
+ hostRoleMaxFontSize = _useOrientationBased.hostRoleMaxFontSize,
223
+ layerTop = _useOrientationBased.layerTop,
224
+ layerLeft = _useOrientationBased.layerLeft,
225
+ layerWidth = _useOrientationBased.layerWidth,
226
+ layerHeight = _useOrientationBased.layerHeight,
227
+ layerRadius = _useOrientationBased.layerRadius,
228
+ layerNameMaxSize = _useOrientationBased.layerNameMaxSize,
229
+ layerRoleMaxSize = _useOrientationBased.layerRoleMaxSize,
230
+ layerLabelSize = _useOrientationBased.layerLabelSize;
231
+ var isLandscape = orientation === 'landscape';
232
+ var isPortrait = orientation === 'portrait';
233
+ var introIn = interpolateWithClamp(frame, [0, fps * 0.95], [0, 1]);
234
+ var introOut = interpolateWithClamp(frame, [fps * 1.7, fps * 2.5], [1, 0]);
235
+ var introOpacity = introIn * introOut;
236
+ var introTranslateY = interpolateWithClamp(frame, [0, fps * 0.95, fps * 2.5], [24, 0, -22], Easing.out(Easing.cubic));
237
+ var compactOpacity = interpolateWithClamp(frame, [fps * 2.1, fps * 3.0], [0, 1]);
238
+ var compactTranslateY = interpolateWithClamp(frame, [fps * 2.1, fps * 3.0], [14, 0]);
239
+ var hostOpacityBase = interpolateWithClamp(frame, [fps * 1.15, fps * 2.0], [0, 1]);
240
+ var hostSustain = durationInFrames > fps * 10 ? interpolateWithClamp(frame, [fps * 6.8, fps * 9.8], [1, 0.55]) : 1;
241
+ var hostOpacity = hostOpacityBase * hostSustain;
242
+ var hostTranslateY = interpolateWithClamp(frame, [fps * 1.15, fps * 2.0], [20, 0]);
243
+ var layerIn = interpolateWithClamp(frame, [fps * 1.9, fps * 3.1], [0, 1]);
244
+ var layerTranslateY = interpolateWithClamp(frame, [fps * 1.9, fps * 3.1], [18, 0], Easing.out(Easing.cubic));
245
+ var layerTranslateX = interpolateWithClamp(frame, [fps * 1.9, fps * 3.1], [34, 0], Easing.out(Easing.cubic));
246
+ var accent = accentColor || '#6ec8ff';
247
+ var textColor = primaryContrast || '#ffffff';
248
+ var mutedTextColor = withAlpha(textColor, 0.68) || textColor;
249
+ var softTextColor = withAlpha(textColor, 0.8) || textColor;
250
+ var _distributeTextToFit = distributeTextToFit(safeText, introWidth, introHeight, introFontSize),
251
+ introLinesRaw = _distributeTextToFit.lines,
252
+ introFinalSize = _distributeTextToFit.fontSize;
253
+ var introLines = clampLines(introLinesRaw, introMaxLines);
254
+ var _distributeTextToFit2 = distributeTextToFit(safeText, compactWidth, compactHeight, compactFontSize),
255
+ compactLinesRaw = _distributeTextToFit2.lines,
256
+ compactFinalSize = _distributeTextToFit2.fontSize;
257
+ var compactLines = clampLines(compactLinesRaw, compactMaxLines);
258
+ var _distributeTextToFit3 = distributeTextToFit(safeFullName, hostWidth, isLandscape ? 78 : 92, hostNameMaxFontSize),
259
+ hostNameLines = _distributeTextToFit3.lines,
260
+ hostNameSize = _distributeTextToFit3.fontSize;
261
+ var _distributeTextToFit4 = distributeTextToFit(safeTitle, hostWidth, isLandscape ? 48 : 58, hostRoleMaxFontSize),
262
+ hostRoleLines = _distributeTextToFit4.lines,
263
+ hostRoleSize = _distributeTextToFit4.fontSize;
264
+ var layerTextWidth = Math.max(layerWidth - 52, 0);
265
+ var _distributeTextToFit5 = distributeTextToFit(safeCollaboratorName, layerTextWidth, isLandscape ? 70 : 52, layerNameMaxSize),
266
+ guestNameRaw = _distributeTextToFit5.lines,
267
+ guestNameSize = _distributeTextToFit5.fontSize;
268
+ var guestNameLines = clampLines(guestNameRaw, isLandscape ? 2 : 1);
269
+ var _distributeTextToFit6 = distributeTextToFit(safeCollaboratorTitle, layerTextWidth, isLandscape ? 56 : 40, layerRoleMaxSize),
270
+ guestRoleRaw = _distributeTextToFit6.lines,
271
+ guestRoleSize = _distributeTextToFit6.fontSize;
272
+ var guestRoleLines = clampLines(guestRoleRaw, 1);
273
+ var hostFocus = collaboratorActive ? 1 : 0;
274
+ var hostBlurPx = 0.25 + hostFocus * 1.7;
275
+ var hostBrightness = 1 - hostFocus * 0.16;
276
+ var hostSaturation = 1.03 - hostFocus * 0.2;
277
+ var guestBlurPx = 3.8 - hostFocus * 3.3;
278
+ var guestBrightness = 0.66 + hostFocus * 0.42;
279
+ var guestSaturation = 0.76 + hostFocus * 0.34;
280
+ var guestLabel = collaboratorActive ? 'NOW RESPONDING' : 'NEXT RESPONSE';
281
+ var hostScale = 1.014 + interpolateWithClamp(frame, [0, durationInFrames], [0, 0.02]);
282
+ var layerDrift = Math.sin(frame / 32) * (isLandscape ? 5 : 3);
283
+ var renderCreatorVideo = function renderCreatorVideo(containerWidth, containerHeight, radius) {
284
+ return /*#__PURE__*/React.createElement(React.Fragment, null, showVirtual && virtualBgUrl ? /*#__PURE__*/React.createElement(VirtualBackgroundUnderlay, {
285
+ url: virtualBgUrl,
286
+ width: "100%",
287
+ height: "100%",
288
+ borderRadius: radius,
289
+ zIndex: 1
290
+ }) : null, firstNoBackgroundFaceMetadata ? /*#__PURE__*/React.createElement(FaceCenteredVideo, {
291
+ startFrom: startVideoFrom,
292
+ src: firstVideoFile,
293
+ faceMetadata: firstNoBackgroundFaceMetadata,
294
+ containerWidth: containerWidth,
295
+ containerHeight: containerHeight,
296
+ useAveragePosition: true,
297
+ muted: false,
298
+ style: {
299
+ filter: mergeFilters(!showVirtual && noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim && firstNoBackgroundVideoUrl ? 'brightness(0.7)' : undefined)
300
+ }
301
+ }) : /*#__PURE__*/React.createElement(OffthreadVideo, {
302
+ startFrom: startVideoFrom,
303
+ src: firstVideoFile,
304
+ muted: false,
305
+ style: {
306
+ width: '100%',
307
+ height: '100%',
308
+ objectFit: 'cover',
309
+ filter: mergeFilters(!showVirtual && noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim && firstNoBackgroundVideoUrl ? 'brightness(0.7)' : undefined)
310
+ }
311
+ }), /*#__PURE__*/React.createElement(BlurOverlay, {
312
+ show: !showVirtual && (noBackgroundVideoEffects === null || noBackgroundVideoEffects === void 0 ? void 0 : noBackgroundVideoEffects.backgroundBlur) && firstNoBackgroundVideoUrl,
313
+ width: containerWidth,
314
+ height: containerHeight,
315
+ zIndex: 2
316
+ }), firstNoBackgroundVideoUrl && (showVirtual || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundDim || noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.backgroundBlur) ? /*#__PURE__*/React.createElement(AbsoluteFill, {
317
+ style: {
318
+ position: 'absolute',
319
+ inset: 0,
320
+ zIndex: 4
321
+ }
322
+ }, firstNoBackgroundFaceMetadata ? /*#__PURE__*/React.createElement(FaceCenteredVideo, {
323
+ startFrom: startVideoFrom,
324
+ src: firstNoBackgroundVideoUrl,
325
+ faceMetadata: firstNoBackgroundFaceMetadata,
326
+ containerWidth: containerWidth,
327
+ containerHeight: containerHeight,
328
+ useAveragePosition: true,
329
+ muted: true,
330
+ transparent: true,
331
+ noBackgroundVideoEffects: noBackgroundVideoEffects
332
+ }) : /*#__PURE__*/React.createElement(OffthreadVideo, {
333
+ startFrom: startVideoFrom,
334
+ src: firstNoBackgroundVideoUrl,
335
+ muted: true,
336
+ transparent: true,
337
+ style: {
338
+ width: '100%',
339
+ height: '100%',
340
+ objectFit: 'cover',
341
+ filter: noBackgroundVideoEffects !== null && noBackgroundVideoEffects !== void 0 && noBackgroundVideoEffects.facePop ? 'brightness(1.1) contrast(1.15) saturate(1.05)' : undefined
342
+ }
343
+ })) : null);
344
+ };
345
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(AbsoluteFill, {
346
+ style: {
347
+ width: width,
348
+ height: height,
349
+ overflow: 'hidden',
350
+ backgroundColor: primaryColor || '#0f172a',
351
+ color: textColor,
352
+ fontFamily: bodyFontFamily
353
+ }
354
+ }, /*#__PURE__*/React.createElement("div", {
355
+ style: {
356
+ position: 'absolute',
357
+ inset: 0,
358
+ transform: "scale(".concat(hostScale, ")"),
359
+ transformOrigin: 'center',
360
+ filter: "blur(".concat(hostBlurPx, "px) brightness(").concat(hostBrightness, ") saturate(").concat(hostSaturation, ")"),
361
+ zIndex: 1
362
+ }
363
+ }, renderCreatorVideo(width, height, 0)), showCollaboratorLayer && /*#__PURE__*/React.createElement("div", {
364
+ style: {
365
+ position: 'absolute',
366
+ top: layerTop,
367
+ left: layerLeft,
368
+ width: layerWidth,
369
+ height: layerHeight,
370
+ opacity: layerIn * (collaboratorActive ? 0.98 : 0.86),
371
+ transform: "translateX(".concat(layerTranslateX, "px) translateY(").concat(layerTranslateY + layerDrift, "px)"),
372
+ zIndex: 2
373
+ }
374
+ }, /*#__PURE__*/React.createElement("div", {
375
+ style: {
376
+ position: 'absolute',
377
+ inset: 0,
378
+ borderRadius: layerRadius,
379
+ overflow: 'hidden',
380
+ border: "1px solid ".concat(withAlpha(textColor, collaboratorActive ? 0.26 : 0.14)),
381
+ boxShadow: '0 24px 58px rgba(0, 0, 0, 0.46)',
382
+ backgroundColor: withAlpha(primaryColor || '#0f172a', 0.65)
383
+ }
384
+ }, hasCollaboratorVideo ? /*#__PURE__*/React.createElement(OffthreadVideo, {
385
+ startFrom: startSecondVideoFrom,
386
+ src: secondVideoFile,
387
+ muted: true,
388
+ style: {
389
+ width: '100%',
390
+ height: '100%',
391
+ objectFit: 'cover',
392
+ objectPosition: '50% 20%',
393
+ filter: "blur(".concat(guestBlurPx, "px) brightness(").concat(guestBrightness, ") saturate(").concat(guestSaturation, ")"),
394
+ transform: "scale(".concat(collaboratorActive ? 1.08 : 1.03, ")")
395
+ }
396
+ }) : /*#__PURE__*/React.createElement("div", {
397
+ style: {
398
+ position: 'absolute',
399
+ inset: 0,
400
+ background: "linear-gradient(130deg, ".concat(withAlpha(accent, 0.28), " 0%, ").concat(withAlpha(primaryColor || '#0f172a', 0.92), " 100%)")
401
+ }
402
+ }), /*#__PURE__*/React.createElement("div", {
403
+ style: {
404
+ position: 'absolute',
405
+ inset: 0,
406
+ background: isLandscape ? "linear-gradient(105deg, ".concat(withAlpha('#000000', 0.14), " 0%, ").concat(withAlpha('#000000', 0.55), " 100%)") : "linear-gradient(180deg, ".concat(withAlpha('#000000', 0.18), " 0%, ").concat(withAlpha('#000000', 0.62), " 100%)")
407
+ }
408
+ }), /*#__PURE__*/React.createElement("div", {
409
+ style: {
410
+ position: 'absolute',
411
+ left: 18,
412
+ right: 18,
413
+ top: 14
414
+ }
415
+ }, /*#__PURE__*/React.createElement("div", {
416
+ style: {
417
+ width: 42,
418
+ height: 2,
419
+ backgroundColor: accent,
420
+ marginBottom: 8
421
+ }
422
+ }), /*#__PURE__*/React.createElement("div", {
423
+ style: {
424
+ fontSize: layerLabelSize,
425
+ letterSpacing: '0.24em',
426
+ textTransform: 'uppercase',
427
+ fontWeight: 700,
428
+ color: collaboratorActive ? accent : mutedTextColor
429
+ }
430
+ }, guestLabel)), /*#__PURE__*/React.createElement("div", {
431
+ style: {
432
+ position: 'absolute',
433
+ left: 18,
434
+ right: 18,
435
+ bottom: 16
436
+ }
437
+ }, guestNameLines.map(function (line, index) {
438
+ return /*#__PURE__*/React.createElement("div", {
439
+ key: "rack-focus-guest-name-".concat(index),
440
+ style: {
441
+ fontFamily: headlineFontFamily,
442
+ fontSize: guestNameSize,
443
+ lineHeight: 0.98,
444
+ letterSpacing: '-0.02em',
445
+ fontWeight: 500,
446
+ textShadow: '0 10px 28px rgba(0, 0, 0, 0.5)',
447
+ marginBottom: index === guestNameLines.length - 1 ? 0 : 2
448
+ }
449
+ }, line);
450
+ }), safeCollaboratorTitle && /*#__PURE__*/React.createElement("div", {
451
+ style: {
452
+ marginTop: safeCollaboratorName ? 6 : 0
453
+ }
454
+ }, guestRoleLines.map(function (line, index) {
455
+ return /*#__PURE__*/React.createElement("div", {
456
+ key: "rack-focus-guest-role-".concat(index),
457
+ style: {
458
+ fontSize: guestRoleSize,
459
+ lineHeight: 1.2,
460
+ color: softTextColor,
461
+ marginBottom: index === guestRoleLines.length - 1 ? 0 : 1
462
+ }
463
+ }, line);
464
+ }))))), /*#__PURE__*/React.createElement("div", {
465
+ style: {
466
+ position: 'absolute',
467
+ inset: 0,
468
+ zIndex: 3,
469
+ background: isLandscape ? "linear-gradient(90deg, ".concat(withAlpha('#000000', 0.72), " 0%, ").concat(withAlpha('#000000', 0.44), " 34%, ").concat(withAlpha('#000000', 0.08), " 70%, ").concat(withAlpha('#000000', 0.36), " 100%)") : "linear-gradient(180deg, ".concat(withAlpha('#000000', 0.52), " 0%, ").concat(withAlpha('#000000', 0.2), " 34%, ").concat(withAlpha('#000000', 0.2), " 62%, ").concat(withAlpha('#000000', 0.72), " 100%)")
470
+ }
471
+ }), /*#__PURE__*/React.createElement("div", {
472
+ style: {
473
+ position: 'absolute',
474
+ inset: 0,
475
+ zIndex: 4,
476
+ background: isLandscape ? "radial-gradient(circle at 78% 36%, ".concat(withAlpha(accent, collaboratorActive ? 0.26 : 0.16), " 0%, ").concat(withAlpha(accent, 0), " 42%)") : "radial-gradient(circle at 76% 24%, ".concat(withAlpha(accent, collaboratorActive ? 0.24 : 0.14), " 0%, ").concat(withAlpha(accent, 0), " 38%)")
477
+ }
478
+ }), hasTitle && /*#__PURE__*/React.createElement("div", {
479
+ style: {
480
+ position: 'absolute',
481
+ top: introTop,
482
+ left: introCentered ? '50%' : introLeft,
483
+ width: introWidth,
484
+ textAlign: introCentered ? 'center' : 'left',
485
+ opacity: introOpacity,
486
+ transform: "".concat(introCentered ? 'translateX(-50%) ' : '', "translateY(").concat(introTranslateY, "px)"),
487
+ zIndex: 6
488
+ }
489
+ }, safeTopicLabel && /*#__PURE__*/React.createElement("div", {
490
+ style: {
491
+ fontSize: topicFontSize,
492
+ letterSpacing: '0.28em',
493
+ textTransform: 'uppercase',
494
+ color: mutedTextColor,
495
+ marginBottom: 10,
496
+ fontWeight: 600
497
+ }
498
+ }, safeTopicLabel), introLines.map(function (line, index) {
499
+ return /*#__PURE__*/React.createElement("div", {
500
+ key: "rack-focus-intro-".concat(index),
501
+ style: {
502
+ fontFamily: headlineFontFamily,
503
+ fontSize: introFinalSize,
504
+ lineHeight: 0.96,
505
+ letterSpacing: '-0.03em',
506
+ fontWeight: 500,
507
+ marginBottom: index === introLines.length - 1 ? 0 : 5,
508
+ textShadow: '0 14px 36px rgba(0, 0, 0, 0.45)'
509
+ }
510
+ }, line);
511
+ })), (hasTitle || safeTopicLabel) && /*#__PURE__*/React.createElement("div", {
512
+ style: {
513
+ position: 'absolute',
514
+ top: compactTop,
515
+ left: compactLeft,
516
+ width: compactWidth,
517
+ opacity: compactOpacity,
518
+ transform: "translateY(".concat(compactTranslateY, "px)"),
519
+ zIndex: 7
520
+ }
521
+ }, safeTopicLabel && /*#__PURE__*/React.createElement("div", {
522
+ style: {
523
+ fontSize: topicFontSize,
524
+ letterSpacing: '0.3em',
525
+ textTransform: 'uppercase',
526
+ color: mutedTextColor,
527
+ marginBottom: hasTitle ? 8 : 0,
528
+ fontWeight: 600
529
+ }
530
+ }, safeTopicLabel), compactLines.map(function (line, index) {
531
+ return /*#__PURE__*/React.createElement("div", {
532
+ key: "rack-focus-compact-".concat(index),
533
+ style: {
534
+ fontFamily: headlineFontFamily,
535
+ fontSize: compactFinalSize,
536
+ lineHeight: 0.99,
537
+ letterSpacing: '-0.025em',
538
+ fontWeight: 500,
539
+ marginBottom: index === compactLines.length - 1 ? 0 : 2,
540
+ textShadow: '0 10px 24px rgba(0, 0, 0, 0.32)'
541
+ }
542
+ }, line);
543
+ })), hasHostInfo && /*#__PURE__*/React.createElement("div", {
544
+ style: {
545
+ position: 'absolute',
546
+ left: hostLeft,
547
+ bottom: hostBottom,
548
+ width: hostWidth,
549
+ opacity: hostOpacity,
550
+ transform: "translateY(".concat(hostTranslateY, "px)"),
551
+ zIndex: 7
552
+ }
553
+ }, /*#__PURE__*/React.createElement("div", {
554
+ style: {
555
+ width: isPortrait ? 52 : 44,
556
+ height: 2,
557
+ backgroundColor: accent,
558
+ marginBottom: 12,
559
+ boxShadow: "0 0 18px ".concat(withAlpha(accent, 0.36))
560
+ }
561
+ }), hostNameLines.map(function (line, index) {
562
+ return /*#__PURE__*/React.createElement("div", {
563
+ key: "rack-focus-host-name-".concat(index),
564
+ style: {
565
+ fontFamily: headlineFontFamily,
566
+ fontSize: hostNameSize,
567
+ lineHeight: 0.98,
568
+ letterSpacing: '-0.02em',
569
+ fontWeight: 500,
570
+ marginBottom: index === hostNameLines.length - 1 ? 0 : 2,
571
+ textShadow: '0 12px 30px rgba(0, 0, 0, 0.42)'
572
+ }
573
+ }, line);
574
+ }), safeTitle && /*#__PURE__*/React.createElement("div", {
575
+ style: {
576
+ marginTop: safeFullName ? 6 : 0
577
+ }
578
+ }, hostRoleLines.map(function (line, index) {
579
+ return /*#__PURE__*/React.createElement("div", {
580
+ key: "rack-focus-host-role-".concat(index),
581
+ style: {
582
+ fontSize: hostRoleSize,
583
+ lineHeight: 1.2,
584
+ color: softTextColor,
585
+ marginBottom: index === hostRoleLines.length - 1 ? 0 : 1,
586
+ textShadow: '0 12px 30px rgba(0, 0, 0, 0.36)'
587
+ }
588
+ }, line);
589
+ }))), /*#__PURE__*/React.createElement("div", {
590
+ style: {
591
+ position: 'absolute',
592
+ inset: framePadding,
593
+ border: "1px solid ".concat(withAlpha(accent, collaboratorActive ? 0.26 : 0.12)),
594
+ opacity: isPortrait ? 0.42 : 0.34,
595
+ pointerEvents: 'none',
596
+ zIndex: 5
597
+ }
598
+ })), /*#__PURE__*/React.createElement(AbsoluteFill, {
599
+ style: {
600
+ zIndex: 100
601
+ }
602
+ }, children));
603
+ };