@make-pictures/kits 0.0.0-stage → 2.0.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.
Files changed (59) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +49 -2
  3. package/dist/chunk-3SUIELJV.mjs +601 -0
  4. package/dist/chunk-4Z3G6FPZ.mjs +485 -0
  5. package/dist/chunk-AHA23PHC.mjs +678 -0
  6. package/dist/chunk-CW623YVB.mjs +1124 -0
  7. package/dist/chunk-NNA7XXQB.mjs +1059 -0
  8. package/dist/chunk-S4CHTWOS.mjs +1237 -0
  9. package/dist/chunk-WAA7P5FT.mjs +912 -0
  10. package/dist/data-storytelling/AnimatedBarRace.d.ts +37 -0
  11. package/dist/data-storytelling/MetricComparisonCard.d.ts +29 -0
  12. package/dist/data-storytelling/TimelineTrack.d.ts +29 -0
  13. package/dist/data-storytelling/index.cjs +1224 -0
  14. package/dist/data-storytelling/index.d.ts +3 -0
  15. package/dist/data-storytelling/index.mjs +10 -0
  16. package/dist/index.cjs +6010 -0
  17. package/dist/index.d.ts +7 -0
  18. package/dist/index.mjs +108 -0
  19. package/dist/isometric-3d/IsometricStudioEnvironment.d.ts +8 -0
  20. package/dist/isometric-3d/Stylized3DCharacter.d.ts +29 -0
  21. package/dist/isometric-3d/index.cjs +611 -0
  22. package/dist/isometric-3d/index.d.ts +2 -0
  23. package/dist/isometric-3d/index.mjs +8 -0
  24. package/dist/kinetic-typography/AnimatedMetricCounter.d.ts +36 -0
  25. package/dist/kinetic-typography/ImpactKeywordCard.d.ts +31 -0
  26. package/dist/kinetic-typography/WordByWordStage.d.ts +47 -0
  27. package/dist/kinetic-typography/index.cjs +665 -0
  28. package/dist/kinetic-typography/index.d.ts +3 -0
  29. package/dist/kinetic-typography/index.mjs +14 -0
  30. package/dist/motion-diagrams-2d/CameraRig.d.ts +34 -0
  31. package/dist/motion-diagrams-2d/CodePayloadToast.d.ts +14 -0
  32. package/dist/motion-diagrams-2d/DataFlowEdge.d.ts +24 -0
  33. package/dist/motion-diagrams-2d/NodeBox.d.ts +65 -0
  34. package/dist/motion-diagrams-2d/SystemNode.d.ts +21 -0
  35. package/dist/motion-diagrams-2d/index.cjs +1137 -0
  36. package/dist/motion-diagrams-2d/index.d.ts +5 -0
  37. package/dist/motion-diagrams-2d/index.mjs +28 -0
  38. package/dist/paper-diorama-3d/ImageCutout3D.d.ts +47 -0
  39. package/dist/paper-diorama-3d/PaperCutout3D.d.ts +62 -0
  40. package/dist/paper-diorama-3d/PaperPopUpBook3D.d.ts +51 -0
  41. package/dist/paper-diorama-3d/PaperStageLighting3D.d.ts +12 -0
  42. package/dist/paper-diorama-3d/index.cjs +1087 -0
  43. package/dist/paper-diorama-3d/index.d.ts +4 -0
  44. package/dist/paper-diorama-3d/index.mjs +34 -0
  45. package/dist/product-frames/BrowserFrame.d.ts +28 -0
  46. package/dist/product-frames/PhoneFrame.d.ts +23 -0
  47. package/dist/product-frames/ScreenSpotlightOverlay.d.ts +34 -0
  48. package/dist/product-frames/frameMedia.d.ts +24 -0
  49. package/dist/product-frames/index.cjs +507 -0
  50. package/dist/product-frames/index.d.ts +8 -0
  51. package/dist/product-frames/index.mjs +12 -0
  52. package/dist/vfx/CinematicLensOverlay.d.ts +29 -0
  53. package/dist/vfx/ParticleField.d.ts +18 -0
  54. package/dist/vfx/SceneTransition.d.ts +24 -0
  55. package/dist/vfx/StagePostProcessing3D.d.ts +44 -0
  56. package/dist/vfx/index.cjs +933 -0
  57. package/dist/vfx/index.d.ts +4 -0
  58. package/dist/vfx/index.mjs +14 -0
  59. package/package.json +95 -4
@@ -0,0 +1,1137 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // packages/kits/src/motion-diagrams-2d/index.ts
21
+ var motion_diagrams_2d_exports = {};
22
+ __export(motion_diagrams_2d_exports, {
23
+ CameraRig: () => CameraRig,
24
+ CodePayloadToast: () => CodePayloadToast,
25
+ DataFlowEdge: () => DataFlowEdge,
26
+ FlowCurve: () => FlowCurve,
27
+ SystemNode: () => SystemNode,
28
+ WorldBox: () => WorldBox,
29
+ evaluateCameraState: () => evaluateCameraState,
30
+ evaluateCubicBezier: () => evaluateCubicBezier,
31
+ portBottom: () => portBottom,
32
+ portLeft: () => portLeft,
33
+ portRight: () => portRight,
34
+ portTop: () => portTop
35
+ });
36
+ module.exports = __toCommonJS(motion_diagrams_2d_exports);
37
+
38
+ // packages/kits/src/motion-diagrams-2d/CameraRig.tsx
39
+ var import_remotion = require("remotion");
40
+ var import_core = require("@make-pictures/core");
41
+ var import_jsx_runtime = require("react/jsx-runtime");
42
+ function evaluateCameraState(frame, fps, keyframes) {
43
+ if (keyframes.length === 0) {
44
+ return {
45
+ x: 960,
46
+ y: 540,
47
+ zoom: 1,
48
+ rotateZ: 0,
49
+ velocity: 0
50
+ };
51
+ }
52
+ let x = keyframes[0].x;
53
+ let y = keyframes[0].y;
54
+ let zoom = keyframes[0].zoom;
55
+ let rotateZ = keyframes[0].rotateZ ?? 0;
56
+ let velocity = 0;
57
+ for (let i = 1; i < keyframes.length; i++) {
58
+ const prev = keyframes[i - 1];
59
+ const curr = keyframes[i];
60
+ if (frame < curr.startFrame) {
61
+ break;
62
+ }
63
+ const p = (0, import_remotion.spring)({
64
+ frame: frame - curr.startFrame,
65
+ fps,
66
+ config: {
67
+ damping: 200,
68
+ stiffness: curr.stiffness ?? 42,
69
+ mass: 1.25
70
+ }
71
+ });
72
+ const midFlightArc = 0.5 * (1 - Math.cos(2 * Math.PI * p));
73
+ const zoomDip = (curr.flightZoomDip ?? 0) * midFlightArc;
74
+ const bankAdd = (curr.flightBankDeg ?? 0) * midFlightArc;
75
+ x += (curr.x - prev.x) * p;
76
+ y += (curr.y - prev.y) * p;
77
+ zoom += (curr.zoom - prev.zoom) * p + zoomDip;
78
+ rotateZ += ((curr.rotateZ ?? 0) - (prev.rotateZ ?? 0)) * p + bankAdd;
79
+ velocity = Math.max(velocity, midFlightArc);
80
+ }
81
+ const floatX = Math.sin(frame / 45) * 4;
82
+ const floatY = Math.cos(frame / 55) * 3.5;
83
+ return {
84
+ x: x + floatX,
85
+ y: y + floatY,
86
+ zoom,
87
+ rotateZ,
88
+ velocity
89
+ };
90
+ }
91
+ var CameraRig = ({
92
+ keyframes,
93
+ stageWidth = 1920,
94
+ stageHeight = 1080,
95
+ variant = "light",
96
+ children
97
+ }) => {
98
+ const frame = (0, import_remotion.useCurrentFrame)();
99
+ const { fps } = (0, import_remotion.useVideoConfig)();
100
+ (0, import_core.useStudioFontsReady)();
101
+ const cam = evaluateCameraState(frame, fps, keyframes);
102
+ const centerX = stageWidth / 2;
103
+ const centerY = stageHeight / 2;
104
+ const gridSpacing = Math.max(24, 80 * cam.zoom);
105
+ const dotSpacing = Math.max(16, 40 * cam.zoom);
106
+ const gridOffsetX = centerX - cam.x * cam.zoom;
107
+ const gridOffsetY = centerY - cam.y * cam.zoom;
108
+ const isDark = variant === "dark";
109
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
110
+ import_remotion.AbsoluteFill,
111
+ {
112
+ style: {
113
+ backgroundColor: isDark ? import_core.THEME.colors.bgPrimary : import_core.STUDIO_THEME.colors.bgCanvas,
114
+ overflow: "hidden"
115
+ },
116
+ children: [
117
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
118
+ import_remotion.AbsoluteFill,
119
+ {
120
+ style: {
121
+ backgroundImage: isDark ? `
122
+ radial-gradient(circle at 20% 25%, rgba(0, 240, 255, 0.14) 0%, transparent 48%),
123
+ radial-gradient(circle at 80% 30%, rgba(139, 92, 246, 0.16) 0%, transparent 50%),
124
+ radial-gradient(circle at 50% 82%, rgba(16, 185, 129, 0.12) 0%, transparent 55%)
125
+ ` : `
126
+ radial-gradient(circle at 20% 25%, rgba(165, 180, 252, 0.35) 0%, transparent 48%),
127
+ radial-gradient(circle at 80% 30%, rgba(199, 210, 254, 0.32) 0%, transparent 50%),
128
+ radial-gradient(circle at 50% 82%, rgba(224, 231, 255, 0.42) 0%, transparent 55%)
129
+ `,
130
+ pointerEvents: "none"
131
+ }
132
+ }
133
+ ),
134
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
135
+ import_remotion.AbsoluteFill,
136
+ {
137
+ style: {
138
+ backgroundImage: isDark ? `
139
+ linear-gradient(to right, rgba(255, 255, 255, 0.045) 1px, transparent 1px),
140
+ linear-gradient(to bottom, rgba(255, 255, 255, 0.045) 1px, transparent 1px)
141
+ ` : `
142
+ linear-gradient(to right, rgba(15, 23, 42, 0.045) 1px, transparent 1px),
143
+ linear-gradient(to bottom, rgba(15, 23, 42, 0.045) 1px, transparent 1px)
144
+ `,
145
+ backgroundSize: `${gridSpacing}px ${gridSpacing}px`,
146
+ backgroundPosition: `${gridOffsetX}px ${gridOffsetY}px`,
147
+ pointerEvents: "none"
148
+ }
149
+ }
150
+ ),
151
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
152
+ import_remotion.AbsoluteFill,
153
+ {
154
+ style: {
155
+ backgroundImage: isDark ? "radial-gradient(rgba(56, 189, 248, 0.18) 1.5px, transparent 1.5px)" : "radial-gradient(rgba(37, 99, 235, 0.14) 1.5px, transparent 1.5px)",
156
+ backgroundSize: `${dotSpacing}px ${dotSpacing}px`,
157
+ backgroundPosition: `${gridOffsetX + dotSpacing / 2}px ${gridOffsetY + dotSpacing / 2}px`,
158
+ pointerEvents: "none"
159
+ }
160
+ }
161
+ ),
162
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
163
+ "div",
164
+ {
165
+ style: {
166
+ position: "absolute",
167
+ left: 0,
168
+ top: 0,
169
+ width: 0,
170
+ height: 0,
171
+ transformOrigin: "0 0",
172
+ willChange: "transform",
173
+ transform: `translate3d(${centerX}px, ${centerY}px, 0) scale(${cam.zoom}) rotate(${cam.rotateZ}deg) translate3d(${-cam.x}px, ${-cam.y}px, 0)`
174
+ },
175
+ children
176
+ }
177
+ )
178
+ ]
179
+ }
180
+ );
181
+ };
182
+
183
+ // packages/kits/src/motion-diagrams-2d/NodeBox.tsx
184
+ var import_remotion2 = require("remotion");
185
+ var import_core2 = require("@make-pictures/core");
186
+ var import_jsx_runtime2 = require("react/jsx-runtime");
187
+ var portRight = (n, dy = 0) => ({
188
+ x: n.cx + n.w / 2,
189
+ y: n.cy + dy
190
+ });
191
+ var portLeft = (n, dy = 0) => ({
192
+ x: n.cx - n.w / 2,
193
+ y: n.cy + dy
194
+ });
195
+ var portTop = (n, dx = 0) => ({
196
+ x: n.cx + dx,
197
+ y: n.cy - n.h / 2
198
+ });
199
+ var portBottom = (n, dx = 0) => ({
200
+ x: n.cx + dx,
201
+ y: n.cy + n.h / 2
202
+ });
203
+ var WorldBox = ({
204
+ node,
205
+ scale = 1,
206
+ opacity = 1,
207
+ zIndex = 2,
208
+ style,
209
+ children
210
+ }) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
211
+ "div",
212
+ {
213
+ style: {
214
+ position: "absolute",
215
+ left: node.cx - node.w / 2,
216
+ top: node.cy - node.h / 2,
217
+ width: node.w,
218
+ height: node.h,
219
+ boxSizing: "border-box",
220
+ transformOrigin: "center center",
221
+ transform: `scale(${scale})`,
222
+ opacity,
223
+ zIndex,
224
+ fontFamily: import_core2.STUDIO_FONTS.sans,
225
+ ...style
226
+ },
227
+ children
228
+ }
229
+ );
230
+ var FlowCurve = ({
231
+ from,
232
+ to,
233
+ curveY = 0,
234
+ curveX = 0,
235
+ orientation = "horizontal",
236
+ color = import_core2.STUDIO_THEME.colors.brand[600],
237
+ activeFromFrame,
238
+ packetSpeedFrames = 100,
239
+ packetCount = 2,
240
+ strokeWidth = 4,
241
+ dashed = false,
242
+ blocked = false
243
+ }) => {
244
+ const frame = (0, import_remotion2.useCurrentFrame)();
245
+ const { fps } = (0, import_remotion2.useVideoConfig)();
246
+ const dx = to.x - from.x;
247
+ const dy = to.y - from.y;
248
+ const p0 = from;
249
+ const p1 = orientation === "vertical" ? { x: from.x + curveX, y: from.y + dy * 0.45 } : { x: from.x + dx * 0.4, y: from.y + curveY };
250
+ const p2 = orientation === "vertical" ? { x: to.x + curveX, y: to.y - dy * 0.45 } : { x: from.x + dx * 0.6, y: to.y + curveY };
251
+ const p3 = to;
252
+ const d = `M ${p0.x} ${p0.y} C ${p1.x} ${p1.y}, ${p2.x} ${p2.y}, ${p3.x} ${p3.y}`;
253
+ const drawProgress = (0, import_remotion2.spring)({
254
+ frame: frame - activeFromFrame,
255
+ fps,
256
+ config: import_core2.SPRING_PRESETS.smooth
257
+ });
258
+ if (drawProgress <= 0.01) return null;
259
+ const evalBezier = (t) => {
260
+ const u = 1 - t;
261
+ return {
262
+ x: u * u * u * p0.x + 3 * u * u * t * p1.x + 3 * u * t * t * p2.x + t * t * t * p3.x,
263
+ y: u * u * u * p0.y + 3 * u * u * t * p1.y + 3 * u * t * t * p2.y + t * t * t * p3.y
264
+ };
265
+ };
266
+ const packets = [];
267
+ if (!blocked && frame >= activeFromFrame + 10) {
268
+ for (let i = 0; i < packetCount; i++) {
269
+ const offset = i / packetCount * packetSpeedFrames;
270
+ const elapsed = frame - (activeFromFrame + 10) - offset;
271
+ if (elapsed < 0) continue;
272
+ const t = elapsed % packetSpeedFrames / packetSpeedFrames;
273
+ const alpha = t < 0.1 ? t / 0.1 : t > 0.9 ? (1 - t) / 0.1 : 1;
274
+ const pt = evalBezier(t);
275
+ packets.push({ x: pt.x, y: pt.y, alpha });
276
+ }
277
+ }
278
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
279
+ "svg",
280
+ {
281
+ style: {
282
+ position: "absolute",
283
+ left: 0,
284
+ top: 0,
285
+ width: 1,
286
+ height: 1,
287
+ overflow: "visible",
288
+ pointerEvents: "none",
289
+ zIndex: 1
290
+ },
291
+ children: [
292
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
293
+ "path",
294
+ {
295
+ d,
296
+ fill: "none",
297
+ stroke: color,
298
+ strokeWidth: strokeWidth + 6,
299
+ strokeOpacity: 0.14 * drawProgress,
300
+ strokeLinecap: "round"
301
+ }
302
+ ),
303
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
304
+ "path",
305
+ {
306
+ d,
307
+ fill: "none",
308
+ stroke: color,
309
+ strokeWidth,
310
+ strokeOpacity: 0.85 * drawProgress,
311
+ strokeDasharray: dashed ? "10 10" : void 0,
312
+ strokeLinecap: "round"
313
+ }
314
+ ),
315
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
316
+ "circle",
317
+ {
318
+ cx: from.x,
319
+ cy: from.y,
320
+ r: 6,
321
+ fill: "#FFFFFF",
322
+ stroke: color,
323
+ strokeWidth: 3,
324
+ opacity: drawProgress
325
+ }
326
+ ),
327
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
328
+ "circle",
329
+ {
330
+ cx: to.x,
331
+ cy: to.y,
332
+ r: 6,
333
+ fill: "#FFFFFF",
334
+ stroke: color,
335
+ strokeWidth: 3,
336
+ opacity: drawProgress
337
+ }
338
+ ),
339
+ packets.map((pkt, idx) => /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("g", { opacity: pkt.alpha * drawProgress, children: [
340
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("circle", { cx: pkt.x, cy: pkt.y, r: 12, fill: color, opacity: 0.22 }),
341
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
342
+ "circle",
343
+ {
344
+ cx: pkt.x,
345
+ cy: pkt.y,
346
+ r: 6.5,
347
+ fill: "#FFFFFF",
348
+ stroke: color,
349
+ strokeWidth: 3
350
+ }
351
+ )
352
+ ] }, idx))
353
+ ]
354
+ }
355
+ );
356
+ };
357
+
358
+ // packages/kits/src/motion-diagrams-2d/SystemNode.tsx
359
+ var import_remotion3 = require("remotion");
360
+ var import_core3 = require("@make-pictures/core");
361
+ var import_jsx_runtime3 = require("react/jsx-runtime");
362
+ var SystemNode = ({
363
+ title,
364
+ subtitle,
365
+ badge,
366
+ statusText,
367
+ activeStatusText,
368
+ icon: Icon,
369
+ x,
370
+ y,
371
+ width = 340,
372
+ height = 188,
373
+ accentColor = import_core3.THEME.colors.accents.cyan,
374
+ enterFrame = 0,
375
+ activeRanges = [],
376
+ metricsLabel,
377
+ metricsValue
378
+ }) => {
379
+ const frame = (0, import_remotion3.useCurrentFrame)();
380
+ const { fps } = (0, import_remotion3.useVideoConfig)();
381
+ const enterProgress = (0, import_remotion3.spring)({
382
+ frame: frame - enterFrame,
383
+ fps,
384
+ config: import_core3.SPRING_PRESETS.snappy
385
+ });
386
+ if (enterProgress <= 2e-3) {
387
+ return null;
388
+ }
389
+ let activeStrength = 0;
390
+ for (const [start, end] of activeRanges) {
391
+ if (frame >= start - 8 && frame <= end + 24) {
392
+ const rampIn = (0, import_remotion3.spring)({
393
+ frame: frame - start,
394
+ fps,
395
+ config: import_core3.SPRING_PRESETS.smooth
396
+ });
397
+ const rampOut = (0, import_remotion3.interpolate)(frame, [end, end + 22], [1, 0], {
398
+ extrapolateLeft: "clamp",
399
+ extrapolateRight: "clamp"
400
+ });
401
+ activeStrength = Math.max(activeStrength, rampIn * rampOut);
402
+ }
403
+ }
404
+ const isCurrentlyActive = activeStrength > 0.35;
405
+ const pulseWave = (0, import_remotion3.interpolate)(
406
+ Math.sin((frame - enterFrame) * 0.045),
407
+ [-1, 1],
408
+ [0.82, 1.1]
409
+ );
410
+ const glowIntensity = activeStrength * pulseWave;
411
+ const scale = (0, import_remotion3.interpolate)(enterProgress, [0, 1], [0.88, 1]) + (0, import_remotion3.interpolate)(activeStrength, [0, 1], [0, 0.024]);
412
+ const translateY = (0, import_remotion3.interpolate)(enterProgress, [0, 1], [28, 0]);
413
+ const opacity = (0, import_remotion3.interpolate)(enterProgress, [0, 0.65, 1], [0, 0.9, 1]);
414
+ const displayedStatus = isCurrentlyActive && activeStatusText ? activeStatusText : statusText;
415
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
416
+ "div",
417
+ {
418
+ style: {
419
+ position: "absolute",
420
+ left: x - width / 2,
421
+ top: y - height / 2,
422
+ width,
423
+ height,
424
+ opacity,
425
+ willChange: "transform, opacity",
426
+ transform: `translate3d(0, ${translateY}px, 0) scale(${scale})`,
427
+ borderRadius: import_core3.THEME.radii.lg,
428
+ backgroundColor: "rgba(15, 18, 29, 0.95)",
429
+ backgroundImage: `radial-gradient(130% 110% at 50% 0%, ${accentColor}${isCurrentlyActive ? "26" : "0E"} 0%, rgba(15, 18, 29, 0.6) 68%)`,
430
+ border: `1px solid ${isCurrentlyActive ? `${accentColor}88` : "rgba(255, 255, 255, 0.09)"}`,
431
+ boxShadow: activeStrength > 0.02 ? import_core3.THEME.shadows.glow(accentColor, glowIntensity) : import_core3.THEME.shadows.card,
432
+ padding: "20px 22px",
433
+ display: "flex",
434
+ flexDirection: "column",
435
+ justifyContent: "space-between",
436
+ boxSizing: "border-box",
437
+ overflow: "hidden"
438
+ },
439
+ children: [
440
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
441
+ "div",
442
+ {
443
+ style: {
444
+ position: "absolute",
445
+ top: 0,
446
+ left: "12%",
447
+ right: "12%",
448
+ height: 1.5,
449
+ background: `linear-gradient(90deg, transparent, ${isCurrentlyActive ? accentColor : "rgba(255,255,255,0.22)"}, transparent)`,
450
+ opacity: (0, import_remotion3.interpolate)(activeStrength, [0, 1], [0.55, 1])
451
+ }
452
+ }
453
+ ),
454
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
455
+ "div",
456
+ {
457
+ style: {
458
+ display: "flex",
459
+ alignItems: "center",
460
+ justifyContent: "space-between"
461
+ },
462
+ children: [
463
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
464
+ "div",
465
+ {
466
+ style: {
467
+ width: 44,
468
+ height: 44,
469
+ borderRadius: 12,
470
+ backgroundColor: `${accentColor}${isCurrentlyActive ? "28" : "14"}`,
471
+ border: `1px solid ${accentColor}${isCurrentlyActive ? "77" : "33"}`,
472
+ boxShadow: isCurrentlyActive ? `0 0 22px ${accentColor}55` : "none",
473
+ display: "flex",
474
+ alignItems: "center",
475
+ justifyContent: "center"
476
+ },
477
+ children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
478
+ Icon,
479
+ {
480
+ size: 22,
481
+ color: isCurrentlyActive ? "#FFFFFF" : accentColor,
482
+ strokeWidth: 2
483
+ }
484
+ )
485
+ }
486
+ ),
487
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
488
+ "div",
489
+ {
490
+ style: {
491
+ padding: "4px 10px",
492
+ borderRadius: import_core3.THEME.radii.pill,
493
+ backgroundColor: "rgba(255, 255, 255, 0.045)",
494
+ border: "1px solid rgba(255, 255, 255, 0.08)",
495
+ fontFamily: import_core3.FONTS.mono,
496
+ fontSize: 11,
497
+ fontWeight: 500,
498
+ letterSpacing: "0.06em",
499
+ textTransform: "uppercase",
500
+ color: isCurrentlyActive ? accentColor : import_core3.THEME.colors.textSecondary
501
+ },
502
+ children: badge
503
+ }
504
+ )
505
+ ]
506
+ }
507
+ ),
508
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { style: { marginTop: 6 }, children: [
509
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
510
+ "div",
511
+ {
512
+ style: {
513
+ fontFamily: import_core3.FONTS.sans,
514
+ fontSize: 21,
515
+ fontWeight: 600,
516
+ letterSpacing: "-0.025em",
517
+ color: import_core3.THEME.colors.textPrimary,
518
+ lineHeight: 1.2
519
+ },
520
+ children: title
521
+ }
522
+ ),
523
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
524
+ "div",
525
+ {
526
+ style: {
527
+ fontFamily: import_core3.FONTS.sans,
528
+ fontSize: 13,
529
+ fontWeight: 400,
530
+ color: import_core3.THEME.colors.textSecondary,
531
+ marginTop: 4,
532
+ lineHeight: 1.35
533
+ },
534
+ children: subtitle
535
+ }
536
+ )
537
+ ] }),
538
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
539
+ "div",
540
+ {
541
+ style: {
542
+ display: "flex",
543
+ alignItems: "center",
544
+ justifyContent: "space-between",
545
+ paddingTop: 10,
546
+ borderTop: "1px solid rgba(255, 255, 255, 0.06)"
547
+ },
548
+ children: [
549
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
550
+ "div",
551
+ {
552
+ style: {
553
+ display: "flex",
554
+ alignItems: "center",
555
+ gap: 8
556
+ },
557
+ children: [
558
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
559
+ "span",
560
+ {
561
+ style: {
562
+ width: 8,
563
+ height: 8,
564
+ borderRadius: "50%",
565
+ backgroundColor: isCurrentlyActive ? accentColor : "rgba(148, 163, 184, 0.45)",
566
+ boxShadow: isCurrentlyActive ? `0 0 12px ${accentColor}, 0 0 24px ${accentColor}` : "none"
567
+ }
568
+ }
569
+ ),
570
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
571
+ "span",
572
+ {
573
+ style: {
574
+ fontFamily: import_core3.FONTS.mono,
575
+ fontSize: 11.5,
576
+ fontWeight: 500,
577
+ color: isCurrentlyActive ? import_core3.THEME.colors.textPrimary : import_core3.THEME.colors.textMuted,
578
+ letterSpacing: "0.02em"
579
+ },
580
+ children: displayedStatus
581
+ }
582
+ )
583
+ ]
584
+ }
585
+ ),
586
+ metricsLabel && metricsValue && /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
587
+ "div",
588
+ {
589
+ style: {
590
+ fontFamily: import_core3.FONTS.mono,
591
+ fontSize: 11,
592
+ color: import_core3.THEME.colors.textSecondary
593
+ },
594
+ children: [
595
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("span", { style: { color: import_core3.THEME.colors.textMuted }, children: [
596
+ metricsLabel,
597
+ ": "
598
+ ] }),
599
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("span", { style: { color: isCurrentlyActive ? accentColor : "#E2E8F0" }, children: metricsValue })
600
+ ]
601
+ }
602
+ )
603
+ ]
604
+ }
605
+ )
606
+ ]
607
+ }
608
+ );
609
+ };
610
+
611
+ // packages/kits/src/motion-diagrams-2d/DataFlowEdge.tsx
612
+ var import_remotion4 = require("remotion");
613
+ var import_core4 = require("@make-pictures/core");
614
+ var import_jsx_runtime4 = require("react/jsx-runtime");
615
+ function evaluateCubicBezier(p0, p1, p2, p3, t) {
616
+ const u = 1 - t;
617
+ const tt = t * t;
618
+ const uu = u * u;
619
+ const uuu = uu * u;
620
+ const ttt = tt * t;
621
+ return {
622
+ x: uuu * p0.x + 3 * uu * t * p1.x + 3 * u * tt * p2.x + ttt * p3.x,
623
+ y: uuu * p0.y + 3 * uu * t * p1.y + 3 * u * tt * p2.y + ttt * p3.y
624
+ };
625
+ }
626
+ var DataFlowEdge = ({
627
+ id,
628
+ from,
629
+ to,
630
+ curveOffsetY = -70,
631
+ color = import_core4.THEME.colors.accents.cyan,
632
+ secondaryColor,
633
+ drawStartFrame = 0,
634
+ flowStartFrame = 30,
635
+ flowEndFrame = 600,
636
+ packetCount = 2,
637
+ traverseFrames = 96,
638
+ direction = "forward",
639
+ label,
640
+ subLabel,
641
+ labelOffsetY = -28
642
+ }) => {
643
+ const frame = (0, import_remotion4.useCurrentFrame)();
644
+ const { fps } = (0, import_remotion4.useVideoConfig)();
645
+ const endColor = secondaryColor ?? color;
646
+ const dx = to.x - from.x;
647
+ const p0 = from;
648
+ const p1 = {
649
+ x: from.x + dx * 0.36,
650
+ y: from.y + curveOffsetY
651
+ };
652
+ const p2 = {
653
+ x: from.x + dx * 0.64,
654
+ y: to.y + curveOffsetY
655
+ };
656
+ const p3 = to;
657
+ const pathData = `M ${p0.x} ${p0.y} C ${p1.x} ${p1.y}, ${p2.x} ${p2.y}, ${p3.x} ${p3.y}`;
658
+ const drawProgress = (0, import_remotion4.spring)({
659
+ frame: frame - drawStartFrame,
660
+ fps,
661
+ config: import_core4.SPRING_PRESETS.smooth
662
+ });
663
+ if (drawProgress <= 5e-3) {
664
+ return null;
665
+ }
666
+ const isFlowActive = frame >= flowStartFrame && frame <= flowEndFrame;
667
+ const flowFadeIn = (0, import_remotion4.interpolate)(
668
+ frame,
669
+ [flowStartFrame, flowStartFrame + 16],
670
+ [0, 1],
671
+ { extrapolateLeft: "clamp", extrapolateRight: "clamp" }
672
+ );
673
+ const flowFadeOut = (0, import_remotion4.interpolate)(
674
+ frame,
675
+ [flowEndFrame - 18, flowEndFrame],
676
+ [1, 0],
677
+ { extrapolateLeft: "clamp", extrapolateRight: "clamp" }
678
+ );
679
+ const flowAlpha = isFlowActive ? flowFadeIn * flowFadeOut : 0;
680
+ const midPoint = evaluateCubicBezier(p0, p1, p2, p3, 0.5);
681
+ const pathLengthEstimate = 1600;
682
+ const dashOffset = (0, import_remotion4.interpolate)(
683
+ drawProgress,
684
+ [0, 1],
685
+ [pathLengthEstimate, 0]
686
+ );
687
+ const gradId = `edge-grad-${id}`;
688
+ const packets = [];
689
+ if (flowAlpha > 0.01) {
690
+ for (let i = 0; i < packetCount; i++) {
691
+ const staggerFrames = Math.round(i / packetCount * traverseFrames);
692
+ const localElapsed = frame - flowStartFrame - staggerFrames;
693
+ if (localElapsed < 0) continue;
694
+ const rawProgress = localElapsed % traverseFrames / traverseFrames;
695
+ const t = direction === "forward" ? rawProgress : 1 - rawProgress;
696
+ const edgeFade = (0, import_remotion4.interpolate)(t, [0, 0.08, 0.92, 1], [0, 1, 1, 0], {
697
+ extrapolateLeft: "clamp",
698
+ extrapolateRight: "clamp"
699
+ }) * flowAlpha;
700
+ const head = evaluateCubicBezier(p0, p1, p2, p3, t);
701
+ const trail = [];
702
+ const trailSteps = 5;
703
+ for (let s = 1; s <= trailSteps; s++) {
704
+ const dt = s * 0.016 * (direction === "forward" ? -1 : 1);
705
+ const clampedT = Math.max(0, Math.min(1, t + dt));
706
+ trail.push(evaluateCubicBezier(p0, p1, p2, p3, clampedT));
707
+ }
708
+ packets.push({ head, trail, opacity: edgeFade });
709
+ }
710
+ }
711
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
712
+ "div",
713
+ {
714
+ style: {
715
+ position: "absolute",
716
+ inset: 0,
717
+ pointerEvents: "none"
718
+ },
719
+ children: [
720
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
721
+ "svg",
722
+ {
723
+ width: 1920,
724
+ height: 1080,
725
+ viewBox: "0 0 1920 1080",
726
+ style: { position: "absolute", inset: 0, overflow: "visible" },
727
+ children: [
728
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("defs", { children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
729
+ "linearGradient",
730
+ {
731
+ id: gradId,
732
+ x1: from.x,
733
+ y1: from.y,
734
+ x2: to.x,
735
+ y2: to.y,
736
+ gradientUnits: "userSpaceOnUse",
737
+ children: [
738
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("stop", { offset: "0%", stopColor: color }),
739
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("stop", { offset: "100%", stopColor: endColor })
740
+ ]
741
+ }
742
+ ) }),
743
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
744
+ "path",
745
+ {
746
+ d: pathData,
747
+ fill: "none",
748
+ stroke: "rgba(255, 255, 255, 0.09)",
749
+ strokeWidth: 2,
750
+ strokeDasharray: pathLengthEstimate,
751
+ strokeDashoffset: dashOffset,
752
+ strokeLinecap: "round"
753
+ }
754
+ ),
755
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
756
+ "path",
757
+ {
758
+ d: pathData,
759
+ fill: "none",
760
+ stroke: `url(#${gradId})`,
761
+ strokeWidth: 2,
762
+ strokeDasharray: "6 10",
763
+ strokeOpacity: 0.32 * drawProgress + 0.35 * flowAlpha,
764
+ strokeLinecap: "round"
765
+ }
766
+ ),
767
+ flowAlpha > 0.01 && /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
768
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
769
+ "path",
770
+ {
771
+ d: pathData,
772
+ fill: "none",
773
+ stroke: `url(#${gradId})`,
774
+ strokeWidth: 11,
775
+ strokeOpacity: 0.14 * flowAlpha,
776
+ strokeLinecap: "round"
777
+ }
778
+ ),
779
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
780
+ "path",
781
+ {
782
+ d: pathData,
783
+ fill: "none",
784
+ stroke: `url(#${gradId})`,
785
+ strokeWidth: 3,
786
+ strokeOpacity: 0.62 * flowAlpha,
787
+ strokeLinecap: "round"
788
+ }
789
+ )
790
+ ] }),
791
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
792
+ "circle",
793
+ {
794
+ cx: from.x,
795
+ cy: from.y,
796
+ r: 4.5,
797
+ fill: color,
798
+ opacity: drawProgress
799
+ }
800
+ ),
801
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
802
+ "circle",
803
+ {
804
+ cx: to.x,
805
+ cy: to.y,
806
+ r: 4.5,
807
+ fill: endColor,
808
+ opacity: drawProgress
809
+ }
810
+ ),
811
+ packets.map((pkt, idx) => /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)("g", { opacity: pkt.opacity, children: [
812
+ pkt.trail.map((pt, tIdx) => {
813
+ const ratio = 1 - (tIdx + 1) / (pkt.trail.length + 1);
814
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
815
+ "circle",
816
+ {
817
+ cx: pt.x,
818
+ cy: pt.y,
819
+ r: 5.2 * ratio,
820
+ fill: color,
821
+ opacity: 0.4 * ratio
822
+ },
823
+ `trail-${tIdx}`
824
+ );
825
+ }),
826
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
827
+ "circle",
828
+ {
829
+ cx: pkt.head.x,
830
+ cy: pkt.head.y,
831
+ r: 16,
832
+ fill: color,
833
+ opacity: 0.14
834
+ }
835
+ ),
836
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
837
+ "circle",
838
+ {
839
+ cx: pkt.head.x,
840
+ cy: pkt.head.y,
841
+ r: 10,
842
+ fill: color,
843
+ opacity: 0.28
844
+ }
845
+ ),
846
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
847
+ "circle",
848
+ {
849
+ cx: pkt.head.x,
850
+ cy: pkt.head.y,
851
+ r: 5.2,
852
+ fill: "#FFFFFF",
853
+ stroke: color,
854
+ strokeWidth: 2.5
855
+ }
856
+ )
857
+ ] }, `pkt-${idx}`))
858
+ ]
859
+ }
860
+ ),
861
+ label && drawProgress > 0.4 && /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
862
+ "div",
863
+ {
864
+ style: {
865
+ position: "absolute",
866
+ left: midPoint.x,
867
+ top: midPoint.y + labelOffsetY,
868
+ transform: `translate3d(-50%, -50%, 0) scale(${(0, import_remotion4.interpolate)(
869
+ drawProgress,
870
+ [0.4, 1],
871
+ [0.85, 1],
872
+ { extrapolateLeft: "clamp", extrapolateRight: "clamp" }
873
+ )})`,
874
+ opacity: (0, import_remotion4.interpolate)(drawProgress, [0.4, 0.9], [0, 1], {
875
+ extrapolateLeft: "clamp",
876
+ extrapolateRight: "clamp"
877
+ }),
878
+ padding: "5px 12px",
879
+ borderRadius: import_core4.THEME.radii.pill,
880
+ backgroundColor: "rgba(11, 14, 23, 0.94)",
881
+ border: `1px solid ${flowAlpha > 0.2 ? `${color}77` : "rgba(255,255,255,0.1)"}`,
882
+ boxShadow: flowAlpha > 0.2 ? `0 0 20px ${color}33, 0 8px 20px rgba(0,0,0,0.6)` : "0 8px 20px rgba(0,0,0,0.6)",
883
+ display: "flex",
884
+ alignItems: "center",
885
+ gap: 7,
886
+ whiteSpace: "nowrap"
887
+ },
888
+ children: [
889
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
890
+ "span",
891
+ {
892
+ style: {
893
+ width: 6,
894
+ height: 6,
895
+ borderRadius: "50%",
896
+ backgroundColor: color,
897
+ boxShadow: flowAlpha > 0.2 ? `0 0 8px ${color}` : "none"
898
+ }
899
+ }
900
+ ),
901
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
902
+ "span",
903
+ {
904
+ style: {
905
+ fontFamily: import_core4.FONTS.mono,
906
+ fontSize: 11,
907
+ fontWeight: 600,
908
+ color: import_core4.THEME.colors.textPrimary,
909
+ letterSpacing: "0.04em"
910
+ },
911
+ children: label
912
+ }
913
+ ),
914
+ subLabel && /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
915
+ "span",
916
+ {
917
+ style: {
918
+ fontFamily: import_core4.FONTS.mono,
919
+ fontSize: 10.5,
920
+ color: import_core4.THEME.colors.textSecondary
921
+ },
922
+ children: [
923
+ "\u2022 ",
924
+ subLabel
925
+ ]
926
+ }
927
+ )
928
+ ]
929
+ }
930
+ )
931
+ ]
932
+ }
933
+ );
934
+ };
935
+
936
+ // packages/kits/src/motion-diagrams-2d/CodePayloadToast.tsx
937
+ var import_remotion5 = require("remotion");
938
+ var import_core5 = require("@make-pictures/core");
939
+ var import_jsx_runtime5 = require("react/jsx-runtime");
940
+ function renderHighlightedLine(line, accentColor) {
941
+ const jsonKeyMatch = line.match(/^(\s*)("[^"]+")(\s*:\s*)(.*)$/);
942
+ if (jsonKeyMatch) {
943
+ const [, indent, keyPart, colonPart, valuePart] = jsonKeyMatch;
944
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
945
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { children: indent }),
946
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#93C5FD" }, children: keyPart }),
947
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#64748B" }, children: colonPart }),
948
+ renderJsonValue(valuePart, accentColor)
949
+ ] });
950
+ }
951
+ const sqlKeywords = /\b(INSERT|INTO|VALUES|SELECT|FROM|WHERE|RETURNING|await|const|return)\b/g;
952
+ if (sqlKeywords.test(line)) {
953
+ const tokens = line.split(/(\b(?:INSERT|INTO|VALUES|SELECT|FROM|WHERE|RETURNING|await|const|return)\b)/g);
954
+ return tokens.map(
955
+ (tok, idx) => /^(INSERT|INTO|VALUES|SELECT|FROM|WHERE|RETURNING|await|const|return)$/.test(tok) ? /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: accentColor, fontWeight: 600 }, children: tok }, idx) : /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#E2E8F0" }, children: tok }, idx)
956
+ );
957
+ }
958
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#94A3B8" }, children: line });
959
+ }
960
+ function renderJsonValue(raw, accentColor) {
961
+ const trailingComma = raw.endsWith(",") ? "," : "";
962
+ const clean = raw.endsWith(",") ? raw.slice(0, -1) : raw;
963
+ if (/^".*"$/.test(clean)) {
964
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
965
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#6EE7B7" }, children: clean }),
966
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#64748B" }, children: trailingComma })
967
+ ] });
968
+ }
969
+ if (/^(true|false|null)$/.test(clean)) {
970
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
971
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: accentColor, fontWeight: 600 }, children: clean }),
972
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#64748B" }, children: trailingComma })
973
+ ] });
974
+ }
975
+ if (/^-?\d+(\.\d+)?$/.test(clean)) {
976
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(import_jsx_runtime5.Fragment, { children: [
977
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#FCD34D" }, children: clean }),
978
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#64748B" }, children: trailingComma })
979
+ ] });
980
+ }
981
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { style: { color: "#E2E8F0" }, children: raw });
982
+ }
983
+ var CodePayloadToast = ({
984
+ x,
985
+ y,
986
+ width = 410,
987
+ methodBadge,
988
+ endpoint,
989
+ latencyText = "18ms",
990
+ code,
991
+ accentColor = import_core5.THEME.colors.accents.cyan,
992
+ startFrame,
993
+ endFrame
994
+ }) => {
995
+ const frame = (0, import_remotion5.useCurrentFrame)();
996
+ const { fps } = (0, import_remotion5.useVideoConfig)();
997
+ if (frame < startFrame - 2 || frame > endFrame + 24) {
998
+ return null;
999
+ }
1000
+ const enterProgress = (0, import_remotion5.spring)({
1001
+ frame: frame - startFrame,
1002
+ fps,
1003
+ config: import_core5.SPRING_PRESETS.snappy
1004
+ });
1005
+ const exitProgress = (0, import_remotion5.interpolate)(frame, [endFrame, endFrame + 18], [1, 0], {
1006
+ extrapolateLeft: "clamp",
1007
+ extrapolateRight: "clamp"
1008
+ });
1009
+ const combined = enterProgress * exitProgress;
1010
+ const translateY = (0, import_remotion5.interpolate)(enterProgress, [0, 1], [18, 0]);
1011
+ const scale = (0, import_remotion5.interpolate)(combined, [0, 1], [0.92, 1]);
1012
+ const lines = code.trim().split("\n");
1013
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
1014
+ "div",
1015
+ {
1016
+ style: {
1017
+ position: "absolute",
1018
+ left: x - width / 2,
1019
+ top: y,
1020
+ width,
1021
+ opacity: combined,
1022
+ willChange: "transform, opacity",
1023
+ transform: `translate3d(0, ${translateY}px, 0) scale(${scale})`,
1024
+ borderRadius: import_core5.THEME.radii.md,
1025
+ backgroundColor: "rgba(11, 14, 23, 0.95)",
1026
+ border: `1px solid ${accentColor}44`,
1027
+ boxShadow: `0 24px 60px rgba(0, 0, 0, 0.8), 0 0 28px ${accentColor}22, 0 1px 0 rgba(255, 255, 255, 0.1) inset`,
1028
+ overflow: "hidden",
1029
+ pointerEvents: "none"
1030
+ },
1031
+ children: [
1032
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
1033
+ "div",
1034
+ {
1035
+ style: {
1036
+ display: "flex",
1037
+ alignItems: "center",
1038
+ justifyContent: "space-between",
1039
+ padding: "9px 14px",
1040
+ backgroundColor: "rgba(255, 255, 255, 0.03)",
1041
+ borderBottom: "1px solid rgba(255, 255, 255, 0.07)"
1042
+ },
1043
+ children: [
1044
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)("div", { style: { display: "flex", alignItems: "center", gap: 8 }, children: [
1045
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1046
+ "span",
1047
+ {
1048
+ style: {
1049
+ padding: "2px 7px",
1050
+ borderRadius: 5,
1051
+ backgroundColor: `${accentColor}24`,
1052
+ border: `1px solid ${accentColor}66`,
1053
+ fontFamily: import_core5.FONTS.mono,
1054
+ fontSize: 10,
1055
+ fontWeight: 600,
1056
+ color: accentColor,
1057
+ letterSpacing: "0.04em"
1058
+ },
1059
+ children: methodBadge
1060
+ }
1061
+ ),
1062
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1063
+ "span",
1064
+ {
1065
+ style: {
1066
+ fontFamily: import_core5.FONTS.mono,
1067
+ fontSize: 11.5,
1068
+ fontWeight: 500,
1069
+ color: import_core5.THEME.colors.textPrimary
1070
+ },
1071
+ children: endpoint
1072
+ }
1073
+ )
1074
+ ] }),
1075
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1076
+ "span",
1077
+ {
1078
+ style: {
1079
+ fontFamily: import_core5.FONTS.mono,
1080
+ fontSize: 10.5,
1081
+ color: import_core5.THEME.colors.textSecondary
1082
+ },
1083
+ children: latencyText
1084
+ }
1085
+ )
1086
+ ]
1087
+ }
1088
+ ),
1089
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1090
+ "div",
1091
+ {
1092
+ style: {
1093
+ padding: "12px 16px",
1094
+ fontFamily: import_core5.FONTS.mono,
1095
+ fontSize: 12,
1096
+ lineHeight: 1.55,
1097
+ whiteSpace: "pre"
1098
+ },
1099
+ children: lines.map((line, idx) => {
1100
+ const lineOpacity = (0, import_remotion5.interpolate)(
1101
+ frame - startFrame,
1102
+ [idx * 2, idx * 2 + 10],
1103
+ [0, 1],
1104
+ { extrapolateLeft: "clamp", extrapolateRight: "clamp" }
1105
+ );
1106
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
1107
+ "div",
1108
+ {
1109
+ style: {
1110
+ opacity: lineOpacity,
1111
+ display: "flex"
1112
+ },
1113
+ children: [
1114
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1115
+ "span",
1116
+ {
1117
+ style: {
1118
+ width: 22,
1119
+ color: "rgba(100, 116, 139, 0.45)",
1120
+ userSelect: "none",
1121
+ fontSize: 10.5
1122
+ },
1123
+ children: idx + 1
1124
+ }
1125
+ ),
1126
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { children: renderHighlightedLine(line, accentColor) })
1127
+ ]
1128
+ },
1129
+ idx
1130
+ );
1131
+ })
1132
+ }
1133
+ )
1134
+ ]
1135
+ }
1136
+ );
1137
+ };