pixi-effects 0.28.2 → 0.30.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.
Files changed (93) hide show
  1. package/CHANGELOG.md +59 -0
  2. package/README.md +11 -10
  3. package/ai/chat-template.html +5 -5
  4. package/ai/tools/check.mjs +18 -3
  5. package/ai/tools/lookup.mjs +208 -0
  6. package/ai/tools/pixi-effects.mjs +16 -5
  7. package/ai/tools/render.mjs +14 -9
  8. package/ai/tools/view.mjs +6 -2
  9. package/dist/Base-CB1_FPZD.d.cts +60 -0
  10. package/dist/Base-Ne74ztNl.d.ts +60 -0
  11. package/dist/Composition-MUKR3FYD.cjs +16 -0
  12. package/dist/{Composition-K6B3APM5.cjs.map → Composition-MUKR3FYD.cjs.map} +1 -1
  13. package/dist/Composition-RJGA7KDU.js +7 -0
  14. package/dist/{Composition-H7UNR5F5.js.map → Composition-RJGA7KDU.js.map} +1 -1
  15. package/dist/Controller.cjs +73 -45
  16. package/dist/Controller.cjs.map +1 -1
  17. package/dist/Controller.d.cts +16 -22
  18. package/dist/Controller.d.ts +16 -22
  19. package/dist/Controller.js +74 -40
  20. package/dist/Controller.js.map +1 -1
  21. package/dist/{Movie-CHcM8HNB.d.ts → Movie-C2rZFkrO.d.ts} +227 -119
  22. package/dist/{Movie-Cx5ozUGb.d.cts → Movie-DdnpLpw1.d.cts} +227 -119
  23. package/dist/{blendModes-HDOP6R7T.cjs → blendModes-ETMYWATF.cjs} +5 -5
  24. package/dist/{blendModes-HDOP6R7T.cjs.map → blendModes-ETMYWATF.cjs.map} +1 -1
  25. package/dist/{blendModes-PAVTW3BO.js → blendModes-RIVZXL5A.js} +4 -4
  26. package/dist/{blendModes-PAVTW3BO.js.map → blendModes-RIVZXL5A.js.map} +1 -1
  27. package/dist/{chunk-P4GY3Z4G.cjs → chunk-2DXPTKQZ.cjs} +6 -6
  28. package/dist/chunk-2DXPTKQZ.cjs.map +1 -0
  29. package/dist/{chunk-TYWFKCPY.js → chunk-4KB3GUEK.js} +5 -5
  30. package/dist/chunk-4KB3GUEK.js.map +1 -0
  31. package/dist/{chunk-5MZWXVTT.js → chunk-A3Q3SDSH.js} +35 -28
  32. package/dist/chunk-A3Q3SDSH.js.map +1 -0
  33. package/dist/chunk-CRQFDY7E.js +4182 -0
  34. package/dist/chunk-CRQFDY7E.js.map +1 -0
  35. package/dist/chunk-HREBQAY4.cjs +4206 -0
  36. package/dist/chunk-HREBQAY4.cjs.map +1 -0
  37. package/dist/{chunk-ZMAD3KJU.cjs → chunk-LYOKH7KE.cjs} +22 -3
  38. package/dist/chunk-LYOKH7KE.cjs.map +1 -0
  39. package/dist/{chunk-45QKLD6M.js → chunk-RCVZX2JP.js} +22 -3
  40. package/dist/chunk-RCVZX2JP.js.map +1 -0
  41. package/dist/{chunk-KBH33IQX.cjs → chunk-WHNADXXG.cjs} +121 -114
  42. package/dist/chunk-WHNADXXG.cjs.map +1 -0
  43. package/dist/{chunk-7VN2KI3U.js → chunk-ZAXYPXKW.js} +14 -6
  44. package/dist/chunk-ZAXYPXKW.js.map +1 -0
  45. package/dist/{chunk-MJW7KILM.cjs → chunk-ZVUO325O.cjs} +32 -24
  46. package/dist/chunk-ZVUO325O.cjs.map +1 -0
  47. package/dist/index.cjs +106 -4482
  48. package/dist/index.cjs.map +1 -1
  49. package/dist/index.d.cts +15 -60
  50. package/dist/index.d.ts +15 -60
  51. package/dist/index.js +6 -4457
  52. package/dist/index.js.map +1 -1
  53. package/dist/loader.css +1 -1
  54. package/dist/{Presenter.cjs → present.cjs} +370 -31
  55. package/dist/present.cjs.map +1 -0
  56. package/dist/present.d.cts +278 -0
  57. package/dist/present.d.ts +278 -0
  58. package/dist/{Presenter.js → present.js} +358 -32
  59. package/dist/present.js.map +1 -0
  60. package/dist/three.cjs +6 -6
  61. package/dist/three.d.cts +2 -2
  62. package/dist/three.d.ts +2 -2
  63. package/dist/three.js +2 -2
  64. package/dist/{types-DpK1vwcl.d.ts → types-BzIB65Vk.d.cts} +11 -265
  65. package/dist/{types-DpK1vwcl.d.cts → types-BzIB65Vk.d.ts} +11 -265
  66. package/docs/api.md +44 -77
  67. package/docs/dsl.md +16 -14
  68. package/llms-full.txt +121 -117
  69. package/llms.txt +3 -2
  70. package/package.json +5 -5
  71. package/skills/pixi-effects/SKILL.md +7 -7
  72. package/skills/pixi-effects/reference/cheatsheet.md +9 -9
  73. package/skills/pixi-effects/reference/direction.md +2 -0
  74. package/skills/pixi-effects/reference/pitfalls.md +6 -6
  75. package/skills/pixi-effects/reference/quickstart.md +29 -0
  76. package/skills/pixi-effects/reference/recipes.md +4 -4
  77. package/skills/pixi-effects/template.html +7 -7
  78. package/dist/Base-C6f0fE8j.d.ts +0 -109
  79. package/dist/Base-DI1FCGcH.d.cts +0 -109
  80. package/dist/Composition-H7UNR5F5.js +0 -7
  81. package/dist/Composition-K6B3APM5.cjs +0 -16
  82. package/dist/Presenter.cjs.map +0 -1
  83. package/dist/Presenter.d.cts +0 -122
  84. package/dist/Presenter.d.ts +0 -122
  85. package/dist/Presenter.js.map +0 -1
  86. package/dist/chunk-45QKLD6M.js.map +0 -1
  87. package/dist/chunk-5MZWXVTT.js.map +0 -1
  88. package/dist/chunk-7VN2KI3U.js.map +0 -1
  89. package/dist/chunk-KBH33IQX.cjs.map +0 -1
  90. package/dist/chunk-MJW7KILM.cjs.map +0 -1
  91. package/dist/chunk-P4GY3Z4G.cjs.map +0 -1
  92. package/dist/chunk-TYWFKCPY.js.map +0 -1
  93. package/dist/chunk-ZMAD3KJU.cjs.map +0 -1
package/dist/index.d.cts CHANGED
@@ -1,7 +1,8 @@
1
- export { A as AudioInspectOptions, a as AudioReport, b as AudioSourceReport, C as ContactSheetOptions, F as FontReport, c as FrameEvent, I as InspectOptions, d as InspectReport, e as IssueGroup, L as LayerInfo, f as LoadProgressState, g as LoadStage, h as LoaderOption, M as MotionBlurOptions, i as MotionBlurSpec, j as Movie, k as MovieErrorEvent, l as MovieOptions, O as OnionSkinOptions, P as ProgressEvent, R as RenderOptions, m as ReviewOptions, n as ReviewReport, S as SnapshotOptions, o as SoundMeasure, p as StopEvent, q as StopImage, r as StopImagesOptions, T as TimelineData, s as TimelineHtmlOptions, t as TimelineRow, u as TimelineSvgOptions, v as TimelineTransition, V as VolumeEvent, w as dismissLoader, x as failLoader, y as resolveLoader } from './Movie-Cx5ozUGb.cjs';
2
- import { S as SequenceSpec, C as CompositionShape, I as ImageSequenceSpec, a as CameraSequenceSpec, K as Keyframe, T as TextSequenceSpec, M as MusicOptions, b as MusicEvents, P as Props, c as TransitionSpec, d as CompositionSpec, e as SequenceCommon } from './types-DpK1vwcl.cjs';
3
- export { A as ArcShapeSpec, f as AssetSpec, g as AudioAssetSpec, h as AudioMusicSpec, i as AudioSequenceSpec, j as AudioSfxSpec, B as BlendModeName, k as ChromaKeyFilterSpec, l as CircleShapeSpec, m as CompositionSequenceSpec, n as CrossfadeTransition, o as CustomFilterSpec, D as DipTransition, p as DissolveTransition, E as EllipseShapeSpec, q as Expr, F as FilterSpec, G as GradientSpec, r as IrisTransition, L as LightSequenceSpec, s as LineShapeSpec, t as LumaTransition, u as MaskRefSpec, v as MatteRefSpec, w as MusicDrum, x as MusicDrumEvents, y as MusicDrumHit, z as MusicDrums, H as MusicInstrument, J as MusicLevel, N as MusicNote, O as MusicSummary, Q as MusicTrack, R as MusicTrackEvents, U as NullSequenceSpec, V as PathShapeSpec, W as PolygonShapeSpec, X as PropValue, Y as RectShapeSpec, Z as SfxKnobs, _ as SfxOptions, $ as SfxPreset, a0 as SfxVoice, a1 as ShaderSequenceSpec, a2 as ShapeSequenceSpec, a3 as SlideTransition, a4 as Stop, a5 as StopSpec, a6 as TransitionCommon, a7 as VideoSequenceSpec, a8 as WipeTransition, a9 as ZoomTransition, aa as normalizeStops, ab as pictureStops } from './types-DpK1vwcl.cjs';
4
- import { S as Sequence } from './Base-DI1FCGcH.cjs';
1
+ import { M as MusicEvents } from './Movie-DdnpLpw1.cjs';
2
+ export { A as AudioInspectOptions, a as AudioReport, b as AudioSourceReport, C as ContactSheetOptions, F as FontReport, c as FrameEvent, I as InspectOptions, d as InspectReport, e as IssueGroup, L as LayerInfo, f as LoadProgressState, g as LoadStage, h as LoaderOption, i as MotionBlurOptions, j as MotionBlurSpec, k as Movie, l as MovieErrorEvent, m as MovieOptions, n as MusicDrumEvents, o as MusicDrumHit, p as MusicNote, q as MusicSummary, r as MusicTrackEvents, O as OnionSkinOptions, P as ProgressEvent, R as RenderOptions, s as ReviewOptions, t as ReviewReport, S as SnapshotOptions, u as SoundMeasure, T as TimelineData, v as TimelineHtmlOptions, w as TimelineRow, x as TimelineSvgOptions, y as TimelineTransition, V as VolumeEvent, z as dismissLoader, B as failLoader, D as resolveLoader } from './Movie-DdnpLpw1.cjs';
3
+ import { S as SequenceSpec, C as CompositionShape, I as ImageSequenceSpec, a as CameraSequenceSpec, K as Keyframe, T as TextSequenceSpec, M as MusicOptions, b as SequenceCommon } from './types-BzIB65Vk.cjs';
4
+ export { A as ArcShapeSpec, c as AssetSpec, d as AudioAssetSpec, e as AudioMusicSpec, f as AudioSequenceSpec, g as AudioSfxSpec, B as BlendModeName, h as ChromaKeyFilterSpec, i as CircleShapeSpec, j as CompositionSequenceSpec, k as CompositionSpec, l as CrossfadeTransition, m as CustomFilterSpec, D as DipTransition, n as DissolveTransition, E as EllipseShapeSpec, o as Expr, F as FilterSpec, G as GradientSpec, p as IrisTransition, L as LightSequenceSpec, q as LineShapeSpec, r as LumaTransition, s as MaskRefSpec, t as MatteRefSpec, u as MusicDrum, v as MusicDrums, w as MusicInstrument, x as MusicLevel, y as MusicTrack, N as NullSequenceSpec, P as PathShapeSpec, z as PolygonShapeSpec, H as PropValue, J as Props, R as RectShapeSpec, O as SfxKnobs, Q as SfxOptions, U as SfxPreset, V as SfxVoice, W as ShaderSequenceSpec, X as ShapeSequenceSpec, Y as SlideTransition, Z as Stop, _ as StopSpec, $ as TransitionCommon, a0 as TransitionSpec, a1 as VideoSequenceSpec, a2 as WipeTransition, a3 as ZoomTransition } from './types-BzIB65Vk.cjs';
5
+ import { S as Sequence } from './Base-CB1_FPZD.cjs';
5
6
  import 'pixi.js';
6
7
 
7
8
  /** A text style as written in a `text` layer's `style` (numbers, not expressions, for the fields that size the text). */
@@ -53,6 +54,12 @@ declare function measureText(text: string, style?: MeasureStyle): TextSize;
53
54
  */
54
55
  declare function splitText(text: string, style?: MeasureStyle, opts?: SplitOptions): TextPiece[];
55
56
 
57
+ /**
58
+ * Unknown option keys are silently ignored by JavaScript, which is how a guessed name like `cols`
59
+ * or `fps` quietly does nothing. Say so, and say what was probably meant.
60
+ */
61
+ declare function warnUnknownOptions(where: string, opts: object | undefined | null, valid: readonly string[]): void;
62
+
56
63
  type SequenceCtor = {
57
64
  new (spec: SequenceSpec, parent: CompositionShape | null, root: CompositionShape): Sequence;
58
65
  };
@@ -404,6 +411,8 @@ interface AnimateTextTween {
404
411
  duration?: number;
405
412
  /** Ease name. */
406
413
  ease?: string;
414
+ /** `out` only: the composition second the exit starts at (every piece leaves in the same wave from then on, and holds its exit state until the layer ends). Without it the exit is the end of the layer run backwards. Not for `in` (an entrance starts with its piece: the options' `at`). */
415
+ at?: number;
407
416
  }
408
417
  interface AnimateTextOptions {
409
418
  /** What a piece is: a character (default), a word or a line. */
@@ -421,7 +430,7 @@ interface AnimateTextOptions {
421
430
  duration: number;
422
431
  /** How a piece arrives: a preset (`'rise'` default, `'drop'`, `'fade'`, `'pop'`, `'zoom'`, `'slide'`, `'spin'`), your own tween, or `false` for none. */
423
432
  in?: TextPreset | AnimateTextTween | false;
424
- /** How a piece leaves, in the same wave (the entrance backwards, eased the other way). It leaves from the END of the layer (`at + duration`) and has no `at` of its own: to be gone at time T, set `duration` to T − `at`. Default none. */
433
+ /** How a piece leaves, in the same wave (the entrance backwards, eased the other way). With `{ preset, at: T }` the exit starts at composition second T; without `at` it leaves from the END of the layer (`at + duration`), the last piece finishing exactly then. Default none. */
425
434
  out?: TextPreset | AnimateTextTween | false;
426
435
  /** The wave: see {@link stagger}. Default `{ each: 0.04 }`. */
427
436
  stagger?: StaggerOptions;
@@ -601,60 +610,6 @@ declare function musicBuffer(music: MusicOptions, options?: {
601
610
  */
602
611
  declare function musicEvents(music: MusicOptions): Promise<MusicEvents>;
603
612
 
604
- interface DeckPage {
605
- /** The page's name: shown by the Presenter, and in the stops list. */
606
- name?: string;
607
- /** How long the page lasts, seconds (including any transition into the next page, see `DeckOptions.transition`). Required. */
608
- duration: number;
609
- /** The page's layers, written in the page's own time (`at: 0` is the start of the page). */
610
- sequences: SequenceSpec[];
611
- /** Where the page stops, in the page's own time: the first is the page settled, the rest are steps (a bullet appears, a chart grows). Default: where the transition into the next page begins (the end for the last page). */
612
- stops?: Array<number | {
613
- at: number;
614
- pdf?: boolean;
615
- }>;
616
- /** Speaker notes (kept on the page's first stop). */
617
- notes?: string;
618
- /** Move on by itself this many seconds after the page's last stop (kiosk mode). */
619
- advance?: number;
620
- /** The page is itself a layer: it may carry `initial`, `keyframes`, `filters`, … (fade or slide the whole page, for instance). */
621
- initial?: Props;
622
- keyframes?: Keyframe[];
623
- }
624
- /** A transition spec without the parts `deck()` fills in (which two pages, and when). */
625
- type DeckTransition = TransitionSpec extends infer T ? (T extends TransitionSpec ? Omit<T, 'from' | 'to' | 'at'> : never) : never;
626
- interface DeckOptions {
627
- pages: DeckPage[];
628
- /**
629
- * A transition between every two pages: `{ kind: 'crossfade' | 'slide' | 'wipe' | 'iris' | 'dip' | 'zoom' | 'dissolve' | 'luma', duration, …its own options }` (see Transitions). The next page starts
630
- * `duration` seconds before the current one ends, and the transition plays across the overlap.
631
- */
632
- transition?: DeckTransition;
633
- }
634
- /** What `deck()` returns: spread it into `movie.init` (`{ duration, composition: { sequences, transitions?, stops } }` plus any movie option you passed). */
635
- interface DeckResult {
636
- duration: number;
637
- composition: CompositionSpec;
638
- [movieOption: string]: unknown;
639
- }
640
- /**
641
- * A deck of pages as one movie. Each page is a nested composition laid out after the one before (so its layers use the page's own
642
- * time), the stops (where a `Presenter` pauses) come from the pages, and an optional `transition` joins the pages with the existing
643
- * crossfade / slide / wipe / … transitions.
644
- *
645
- * ```js
646
- * await movie.init({ canvas, width: 1280, height: 720, frameRate: 30, ...deck({
647
- * transition: { kind: 'slide', duration: 0.6, direction: 'left' },
648
- * pages: [
649
- * { name: 'Hello', duration: 5, stops: [1.2], sequences: [ …title, subtitle… ] },
650
- * { name: 'Why', duration: 8, stops: [1.2, 3, 5], sequences: [ …three bullets, at 1.2, 3, 5… ] },
651
- * ],
652
- * }) });
653
- * movie.on('ready', …); new Presenter(movie, { canvas });
654
- * ```
655
- */
656
- declare function deck(options: DeckOptions): DeckResult;
657
-
658
613
  interface WiggleProp {
659
614
  /** The value the property rests at: a number or an expression (`'W/2'`). The wiggle starts and ends here. */
660
615
  around: number | string;
@@ -732,4 +687,4 @@ interface WithFadeOptions {
732
687
  */
733
688
  declare function withFade<T extends SequenceCommon>(spec: T, opts: WithFadeOptions): T;
734
689
 
735
- export { type AnimateTextOptions, type AnimateTextTween, type AudioEnvelope, type AudioEnvelopeSource, type CameraPathOptions, CameraSequenceSpec, CompositionShape, CompositionSpec, type DeckOptions, type DeckPage, type DeckResult, type DeckTransition, type EnvelopeOptions, type FollowPathOptions, ImageSequenceSpec, type KenBurnsOptions, Keyframe, type MeasureStyle, MusicEvents, MusicOptions, type OrbitOptions, type ParticlesOptions, Props, type ReactOptions, type ReactProp, Sequence, SequenceCommon, type SequenceCtor, SequenceSpec, type SplitOptions, type StaggerOptions, type TextPiece, type TextPreset, TextSequenceSpec, type TextSize, TransitionSpec, type WiggleOptions, type WiggleProp, type WithFadeOptions, animateText, audioEnvelope, bpmEnvelope, cameraPath, computeEnvelope, deck, parseEase as ease, followPath, kenBurns, measureText, musicBuffer, musicEnvelope, musicEvents, noise, orbit, particles, rand, random, react, registerSequenceType, splitText, stagger, wiggle, withFade };
690
+ export { type AnimateTextOptions, type AnimateTextTween, type AudioEnvelope, type AudioEnvelopeSource, type CameraPathOptions, CameraSequenceSpec, CompositionShape, type EnvelopeOptions, type FollowPathOptions, ImageSequenceSpec, type KenBurnsOptions, Keyframe, type MeasureStyle, MusicEvents, MusicOptions, type OrbitOptions, type ParticlesOptions, type ReactOptions, type ReactProp, Sequence, SequenceCommon, type SequenceCtor, SequenceSpec, type SplitOptions, type StaggerOptions, type TextPiece, type TextPreset, TextSequenceSpec, type TextSize, type WiggleOptions, type WiggleProp, type WithFadeOptions, animateText, audioEnvelope, bpmEnvelope, cameraPath, computeEnvelope, parseEase as ease, followPath, kenBurns, measureText, musicBuffer, musicEnvelope, musicEvents, noise, orbit, particles, rand, random, react, registerSequenceType, splitText, stagger, warnUnknownOptions, wiggle, withFade };
package/dist/index.d.ts CHANGED
@@ -1,7 +1,8 @@
1
- export { A as AudioInspectOptions, a as AudioReport, b as AudioSourceReport, C as ContactSheetOptions, F as FontReport, c as FrameEvent, I as InspectOptions, d as InspectReport, e as IssueGroup, L as LayerInfo, f as LoadProgressState, g as LoadStage, h as LoaderOption, M as MotionBlurOptions, i as MotionBlurSpec, j as Movie, k as MovieErrorEvent, l as MovieOptions, O as OnionSkinOptions, P as ProgressEvent, R as RenderOptions, m as ReviewOptions, n as ReviewReport, S as SnapshotOptions, o as SoundMeasure, p as StopEvent, q as StopImage, r as StopImagesOptions, T as TimelineData, s as TimelineHtmlOptions, t as TimelineRow, u as TimelineSvgOptions, v as TimelineTransition, V as VolumeEvent, w as dismissLoader, x as failLoader, y as resolveLoader } from './Movie-CHcM8HNB.js';
2
- import { S as SequenceSpec, C as CompositionShape, I as ImageSequenceSpec, a as CameraSequenceSpec, K as Keyframe, T as TextSequenceSpec, M as MusicOptions, b as MusicEvents, P as Props, c as TransitionSpec, d as CompositionSpec, e as SequenceCommon } from './types-DpK1vwcl.js';
3
- export { A as ArcShapeSpec, f as AssetSpec, g as AudioAssetSpec, h as AudioMusicSpec, i as AudioSequenceSpec, j as AudioSfxSpec, B as BlendModeName, k as ChromaKeyFilterSpec, l as CircleShapeSpec, m as CompositionSequenceSpec, n as CrossfadeTransition, o as CustomFilterSpec, D as DipTransition, p as DissolveTransition, E as EllipseShapeSpec, q as Expr, F as FilterSpec, G as GradientSpec, r as IrisTransition, L as LightSequenceSpec, s as LineShapeSpec, t as LumaTransition, u as MaskRefSpec, v as MatteRefSpec, w as MusicDrum, x as MusicDrumEvents, y as MusicDrumHit, z as MusicDrums, H as MusicInstrument, J as MusicLevel, N as MusicNote, O as MusicSummary, Q as MusicTrack, R as MusicTrackEvents, U as NullSequenceSpec, V as PathShapeSpec, W as PolygonShapeSpec, X as PropValue, Y as RectShapeSpec, Z as SfxKnobs, _ as SfxOptions, $ as SfxPreset, a0 as SfxVoice, a1 as ShaderSequenceSpec, a2 as ShapeSequenceSpec, a3 as SlideTransition, a4 as Stop, a5 as StopSpec, a6 as TransitionCommon, a7 as VideoSequenceSpec, a8 as WipeTransition, a9 as ZoomTransition, aa as normalizeStops, ab as pictureStops } from './types-DpK1vwcl.js';
4
- import { S as Sequence } from './Base-C6f0fE8j.js';
1
+ import { M as MusicEvents } from './Movie-C2rZFkrO.js';
2
+ export { A as AudioInspectOptions, a as AudioReport, b as AudioSourceReport, C as ContactSheetOptions, F as FontReport, c as FrameEvent, I as InspectOptions, d as InspectReport, e as IssueGroup, L as LayerInfo, f as LoadProgressState, g as LoadStage, h as LoaderOption, i as MotionBlurOptions, j as MotionBlurSpec, k as Movie, l as MovieErrorEvent, m as MovieOptions, n as MusicDrumEvents, o as MusicDrumHit, p as MusicNote, q as MusicSummary, r as MusicTrackEvents, O as OnionSkinOptions, P as ProgressEvent, R as RenderOptions, s as ReviewOptions, t as ReviewReport, S as SnapshotOptions, u as SoundMeasure, T as TimelineData, v as TimelineHtmlOptions, w as TimelineRow, x as TimelineSvgOptions, y as TimelineTransition, V as VolumeEvent, z as dismissLoader, B as failLoader, D as resolveLoader } from './Movie-C2rZFkrO.js';
3
+ import { S as SequenceSpec, C as CompositionShape, I as ImageSequenceSpec, a as CameraSequenceSpec, K as Keyframe, T as TextSequenceSpec, M as MusicOptions, b as SequenceCommon } from './types-BzIB65Vk.js';
4
+ export { A as ArcShapeSpec, c as AssetSpec, d as AudioAssetSpec, e as AudioMusicSpec, f as AudioSequenceSpec, g as AudioSfxSpec, B as BlendModeName, h as ChromaKeyFilterSpec, i as CircleShapeSpec, j as CompositionSequenceSpec, k as CompositionSpec, l as CrossfadeTransition, m as CustomFilterSpec, D as DipTransition, n as DissolveTransition, E as EllipseShapeSpec, o as Expr, F as FilterSpec, G as GradientSpec, p as IrisTransition, L as LightSequenceSpec, q as LineShapeSpec, r as LumaTransition, s as MaskRefSpec, t as MatteRefSpec, u as MusicDrum, v as MusicDrums, w as MusicInstrument, x as MusicLevel, y as MusicTrack, N as NullSequenceSpec, P as PathShapeSpec, z as PolygonShapeSpec, H as PropValue, J as Props, R as RectShapeSpec, O as SfxKnobs, Q as SfxOptions, U as SfxPreset, V as SfxVoice, W as ShaderSequenceSpec, X as ShapeSequenceSpec, Y as SlideTransition, Z as Stop, _ as StopSpec, $ as TransitionCommon, a0 as TransitionSpec, a1 as VideoSequenceSpec, a2 as WipeTransition, a3 as ZoomTransition } from './types-BzIB65Vk.js';
5
+ import { S as Sequence } from './Base-Ne74ztNl.js';
5
6
  import 'pixi.js';
6
7
 
7
8
  /** A text style as written in a `text` layer's `style` (numbers, not expressions, for the fields that size the text). */
@@ -53,6 +54,12 @@ declare function measureText(text: string, style?: MeasureStyle): TextSize;
53
54
  */
54
55
  declare function splitText(text: string, style?: MeasureStyle, opts?: SplitOptions): TextPiece[];
55
56
 
57
+ /**
58
+ * Unknown option keys are silently ignored by JavaScript, which is how a guessed name like `cols`
59
+ * or `fps` quietly does nothing. Say so, and say what was probably meant.
60
+ */
61
+ declare function warnUnknownOptions(where: string, opts: object | undefined | null, valid: readonly string[]): void;
62
+
56
63
  type SequenceCtor = {
57
64
  new (spec: SequenceSpec, parent: CompositionShape | null, root: CompositionShape): Sequence;
58
65
  };
@@ -404,6 +411,8 @@ interface AnimateTextTween {
404
411
  duration?: number;
405
412
  /** Ease name. */
406
413
  ease?: string;
414
+ /** `out` only: the composition second the exit starts at (every piece leaves in the same wave from then on, and holds its exit state until the layer ends). Without it the exit is the end of the layer run backwards. Not for `in` (an entrance starts with its piece: the options' `at`). */
415
+ at?: number;
407
416
  }
408
417
  interface AnimateTextOptions {
409
418
  /** What a piece is: a character (default), a word or a line. */
@@ -421,7 +430,7 @@ interface AnimateTextOptions {
421
430
  duration: number;
422
431
  /** How a piece arrives: a preset (`'rise'` default, `'drop'`, `'fade'`, `'pop'`, `'zoom'`, `'slide'`, `'spin'`), your own tween, or `false` for none. */
423
432
  in?: TextPreset | AnimateTextTween | false;
424
- /** How a piece leaves, in the same wave (the entrance backwards, eased the other way). It leaves from the END of the layer (`at + duration`) and has no `at` of its own: to be gone at time T, set `duration` to T − `at`. Default none. */
433
+ /** How a piece leaves, in the same wave (the entrance backwards, eased the other way). With `{ preset, at: T }` the exit starts at composition second T; without `at` it leaves from the END of the layer (`at + duration`), the last piece finishing exactly then. Default none. */
425
434
  out?: TextPreset | AnimateTextTween | false;
426
435
  /** The wave: see {@link stagger}. Default `{ each: 0.04 }`. */
427
436
  stagger?: StaggerOptions;
@@ -601,60 +610,6 @@ declare function musicBuffer(music: MusicOptions, options?: {
601
610
  */
602
611
  declare function musicEvents(music: MusicOptions): Promise<MusicEvents>;
603
612
 
604
- interface DeckPage {
605
- /** The page's name: shown by the Presenter, and in the stops list. */
606
- name?: string;
607
- /** How long the page lasts, seconds (including any transition into the next page, see `DeckOptions.transition`). Required. */
608
- duration: number;
609
- /** The page's layers, written in the page's own time (`at: 0` is the start of the page). */
610
- sequences: SequenceSpec[];
611
- /** Where the page stops, in the page's own time: the first is the page settled, the rest are steps (a bullet appears, a chart grows). Default: where the transition into the next page begins (the end for the last page). */
612
- stops?: Array<number | {
613
- at: number;
614
- pdf?: boolean;
615
- }>;
616
- /** Speaker notes (kept on the page's first stop). */
617
- notes?: string;
618
- /** Move on by itself this many seconds after the page's last stop (kiosk mode). */
619
- advance?: number;
620
- /** The page is itself a layer: it may carry `initial`, `keyframes`, `filters`, … (fade or slide the whole page, for instance). */
621
- initial?: Props;
622
- keyframes?: Keyframe[];
623
- }
624
- /** A transition spec without the parts `deck()` fills in (which two pages, and when). */
625
- type DeckTransition = TransitionSpec extends infer T ? (T extends TransitionSpec ? Omit<T, 'from' | 'to' | 'at'> : never) : never;
626
- interface DeckOptions {
627
- pages: DeckPage[];
628
- /**
629
- * A transition between every two pages: `{ kind: 'crossfade' | 'slide' | 'wipe' | 'iris' | 'dip' | 'zoom' | 'dissolve' | 'luma', duration, …its own options }` (see Transitions). The next page starts
630
- * `duration` seconds before the current one ends, and the transition plays across the overlap.
631
- */
632
- transition?: DeckTransition;
633
- }
634
- /** What `deck()` returns: spread it into `movie.init` (`{ duration, composition: { sequences, transitions?, stops } }` plus any movie option you passed). */
635
- interface DeckResult {
636
- duration: number;
637
- composition: CompositionSpec;
638
- [movieOption: string]: unknown;
639
- }
640
- /**
641
- * A deck of pages as one movie. Each page is a nested composition laid out after the one before (so its layers use the page's own
642
- * time), the stops (where a `Presenter` pauses) come from the pages, and an optional `transition` joins the pages with the existing
643
- * crossfade / slide / wipe / … transitions.
644
- *
645
- * ```js
646
- * await movie.init({ canvas, width: 1280, height: 720, frameRate: 30, ...deck({
647
- * transition: { kind: 'slide', duration: 0.6, direction: 'left' },
648
- * pages: [
649
- * { name: 'Hello', duration: 5, stops: [1.2], sequences: [ …title, subtitle… ] },
650
- * { name: 'Why', duration: 8, stops: [1.2, 3, 5], sequences: [ …three bullets, at 1.2, 3, 5… ] },
651
- * ],
652
- * }) });
653
- * movie.on('ready', …); new Presenter(movie, { canvas });
654
- * ```
655
- */
656
- declare function deck(options: DeckOptions): DeckResult;
657
-
658
613
  interface WiggleProp {
659
614
  /** The value the property rests at: a number or an expression (`'W/2'`). The wiggle starts and ends here. */
660
615
  around: number | string;
@@ -732,4 +687,4 @@ interface WithFadeOptions {
732
687
  */
733
688
  declare function withFade<T extends SequenceCommon>(spec: T, opts: WithFadeOptions): T;
734
689
 
735
- export { type AnimateTextOptions, type AnimateTextTween, type AudioEnvelope, type AudioEnvelopeSource, type CameraPathOptions, CameraSequenceSpec, CompositionShape, CompositionSpec, type DeckOptions, type DeckPage, type DeckResult, type DeckTransition, type EnvelopeOptions, type FollowPathOptions, ImageSequenceSpec, type KenBurnsOptions, Keyframe, type MeasureStyle, MusicEvents, MusicOptions, type OrbitOptions, type ParticlesOptions, Props, type ReactOptions, type ReactProp, Sequence, SequenceCommon, type SequenceCtor, SequenceSpec, type SplitOptions, type StaggerOptions, type TextPiece, type TextPreset, TextSequenceSpec, type TextSize, TransitionSpec, type WiggleOptions, type WiggleProp, type WithFadeOptions, animateText, audioEnvelope, bpmEnvelope, cameraPath, computeEnvelope, deck, parseEase as ease, followPath, kenBurns, measureText, musicBuffer, musicEnvelope, musicEvents, noise, orbit, particles, rand, random, react, registerSequenceType, splitText, stagger, wiggle, withFade };
690
+ export { type AnimateTextOptions, type AnimateTextTween, type AudioEnvelope, type AudioEnvelopeSource, type CameraPathOptions, CameraSequenceSpec, CompositionShape, type EnvelopeOptions, type FollowPathOptions, ImageSequenceSpec, type KenBurnsOptions, Keyframe, type MeasureStyle, MusicEvents, MusicOptions, type OrbitOptions, type ParticlesOptions, type ReactOptions, type ReactProp, Sequence, SequenceCommon, type SequenceCtor, SequenceSpec, type SplitOptions, type StaggerOptions, type TextPiece, type TextPreset, TextSequenceSpec, type TextSize, type WiggleOptions, type WiggleProp, type WithFadeOptions, animateText, audioEnvelope, bpmEnvelope, cameraPath, computeEnvelope, parseEase as ease, followPath, kenBurns, measureText, musicBuffer, musicEnvelope, musicEvents, noise, orbit, particles, rand, random, react, registerSequenceType, splitText, stagger, warnUnknownOptions, wiggle, withFade };