asciify-engine 4.29.0 → 4.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 (105) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/THIRD_PARTY.md +3 -0
  3. package/dist/field.cjs +1 -1
  4. package/dist/field.d.cts +1 -1
  5. package/dist/field.d.ts +1 -1
  6. package/dist/field.js +1 -1
  7. package/dist/{glyph-field-DRC-7uVf.d.ts → glyph-field-BCwGhohg.d.ts} +11 -0
  8. package/dist/{glyph-field-C2fQIlnq.d.cts → glyph-field-DKWHAMml.d.cts} +11 -0
  9. package/dist/kit/{chunk-4NV5APSJ.js → chunk-2NACMWVV.js} +1 -1
  10. package/dist/kit/{chunk-F6F2C3RH.js → chunk-2UOPVMN3.js} +1 -1
  11. package/dist/kit/{chunk-DMRPBFLW.js → chunk-3H3DJI3M.js} +1 -1
  12. package/dist/kit/{chunk-7M2FFUZ3.js → chunk-4G5LJNMB.js} +1 -1
  13. package/dist/kit/{chunk-G4ZSMTFN.js → chunk-4NR7QENR.js} +1 -1
  14. package/dist/kit/{chunk-GKR3ROYR.js → chunk-5Q634WWI.js} +1 -1
  15. package/dist/kit/{chunk-KY5KCIZE.js → chunk-64NSPD2R.js} +1 -1
  16. package/dist/kit/{chunk-2FH6GGV6.js → chunk-6G2ZVIBS.js} +1 -1
  17. package/dist/kit/{chunk-3MHEDZLZ.js → chunk-6NDTKY3V.js} +1 -1
  18. package/dist/kit/{chunk-GBNV3GXG.js → chunk-7QH33RJJ.js} +1 -1
  19. package/dist/kit/{chunk-BFBG3VHI.js → chunk-7TXDNPL3.js} +1 -1
  20. package/dist/kit/{chunk-3OD5BMF5.js → chunk-AAV5QNHU.js} +1 -1
  21. package/dist/kit/chunk-AU33Y2SZ.js +1 -0
  22. package/dist/kit/{chunk-KCEYRIU4.js → chunk-BGPEFFKK.js} +1 -1
  23. package/dist/kit/{chunk-KDROJANO.js → chunk-BJJUDT26.js} +1 -1
  24. package/dist/kit/{chunk-2LBQ7QJT.js → chunk-BO4CPM26.js} +1 -1
  25. package/dist/kit/chunk-BQ53B2HP.js +1 -0
  26. package/dist/kit/chunk-BV6AOHFU.js +1 -0
  27. package/dist/kit/{chunk-QVICL57J.js → chunk-CH64MY3U.js} +1 -1
  28. package/dist/kit/{chunk-LVCGC3SO.js → chunk-CMGMCRAD.js} +1 -1
  29. package/dist/kit/{chunk-4U72YE65.js → chunk-CZL5WMU6.js} +1 -1
  30. package/dist/kit/{chunk-PB5E3D4E.js → chunk-DKRZSP5K.js} +1 -1
  31. package/dist/kit/{chunk-KFXMLIVF.js → chunk-E427W6P5.js} +1 -1
  32. package/dist/kit/{chunk-RXOPJJC4.js → chunk-EH4S6T7U.js} +1 -1
  33. package/dist/kit/chunk-F4IO3HWD.js +1 -0
  34. package/dist/kit/{chunk-K6JX64AS.js → chunk-FU4WW3PU.js} +1 -1
  35. package/dist/kit/{chunk-TRDA73HN.js → chunk-G3FVDS2A.js} +1 -1
  36. package/dist/kit/{chunk-FHN3PPSI.js → chunk-G7GQSPMC.js} +1 -1
  37. package/dist/kit/chunk-GI5BNKBL.js +1 -0
  38. package/dist/kit/{chunk-KEE55QSD.js → chunk-GJANKSX6.js} +1 -1
  39. package/dist/kit/{chunk-Z2FRNFMB.js → chunk-HENGH3DE.js} +1 -1
  40. package/dist/kit/chunk-I377LEZA.js +1 -0
  41. package/dist/kit/chunk-IFZDWKIX.js +1 -0
  42. package/dist/kit/{chunk-WDS7VM2E.js → chunk-J7Y2KBXK.js} +1 -1
  43. package/dist/kit/{chunk-KXI3T72F.js → chunk-JF3WEYIE.js} +1 -1
  44. package/dist/kit/{chunk-3VEMKDBW.js → chunk-LTRVMY3D.js} +1 -1
  45. package/dist/kit/{chunk-EKYEA7Z4.js → chunk-M5JJSIWI.js} +1 -1
  46. package/dist/kit/{chunk-ILXVBO7M.js → chunk-MT23DCGU.js} +1 -1
  47. package/dist/kit/{chunk-NF4WVWAC.js → chunk-MWUPCAET.js} +1 -1
  48. package/dist/kit/{chunk-FPCCX4FM.js → chunk-MYAZOXMF.js} +1 -1
  49. package/dist/kit/{chunk-3YSK7V26.js → chunk-N7J4UAWY.js} +1 -1
  50. package/dist/kit/{chunk-YSN7EHSH.js → chunk-NP7UG7DS.js} +1 -1
  51. package/dist/kit/{chunk-ZCXNGJGB.js → chunk-NQ4PFWOG.js} +1 -1
  52. package/dist/kit/chunk-NS6HYTQZ.js +1 -0
  53. package/dist/kit/chunk-NSKX2OFA.js +1 -0
  54. package/dist/kit/{chunk-WI2AF2KE.js → chunk-OOVUQEXT.js} +1 -1
  55. package/dist/kit/{chunk-W4U5CK6L.js → chunk-P5MVACML.js} +1 -1
  56. package/dist/kit/chunk-PZKQUZQK.js +1 -0
  57. package/dist/kit/{chunk-CGSWUO67.js → chunk-R3ALZFUQ.js} +1 -1
  58. package/dist/kit/{chunk-7DXSG526.js → chunk-RGV7VRYC.js} +1 -1
  59. package/dist/kit/chunk-SBAUVRBY.js +1 -0
  60. package/dist/kit/chunk-SQNULNT3.js +1 -0
  61. package/dist/kit/{chunk-HYVTFKWX.js → chunk-TJHSBZBF.js} +1 -1
  62. package/dist/kit/{chunk-FWODCYYJ.js → chunk-UHLNVM63.js} +1 -1
  63. package/dist/kit/{chunk-UOYBFLGJ.js → chunk-UT6MJP5B.js} +1 -1
  64. package/dist/kit/{chunk-QSTDYL35.js → chunk-UWX7VIXT.js} +1 -1
  65. package/dist/kit/{chunk-6WU247CB.js → chunk-UXDJSGED.js} +1 -1
  66. package/dist/kit/{chunk-Z3KD6CLE.js → chunk-UXJRBOSR.js} +1 -1
  67. package/dist/kit/{chunk-KLRF3S7O.js → chunk-V42Q4L2G.js} +1 -1
  68. package/dist/kit/chunk-V6KL3IA7.js +1 -0
  69. package/dist/kit/{chunk-776H2BJ7.js → chunk-VENDLTH4.js} +1 -1
  70. package/dist/kit/{chunk-ZWZZMU5P.js → chunk-VQ4KIRBW.js} +1 -1
  71. package/dist/kit/{chunk-OZFSNW5N.js → chunk-WPWCFCEZ.js} +1 -1
  72. package/dist/kit/{chunk-H5KHXZWR.js → chunk-WRBLIULG.js} +1 -1
  73. package/dist/kit/{chunk-SDSW7422.js → chunk-WSWIOD2C.js} +1 -1
  74. package/dist/kit/{chunk-NW4U2YRE.js → chunk-X6GAMLEH.js} +1 -1
  75. package/dist/kit/chunk-X7AUCVMH.js +1 -0
  76. package/dist/kit/{chunk-B3TY6UXJ.js → chunk-XDX6WLED.js} +1 -1
  77. package/dist/kit/{chunk-42KMN727.js → chunk-XVA7UGUQ.js} +1 -1
  78. package/dist/kit/chunk-XXHIFJ5Z.js +1 -0
  79. package/dist/kit/{chunk-3LJ5C3U3.js → chunk-XZO4VH2Z.js} +1 -1
  80. package/dist/kit/{chunk-6G5MPND3.js → chunk-Y2SDQ6EC.js} +1 -1
  81. package/dist/kit/{chunk-CG6SGQMY.js → chunk-ZGCKUXYP.js} +1 -1
  82. package/dist/kit/{chunk-E3FPFANJ.js → chunk-ZNZAO7JA.js} +1 -1
  83. package/dist/kit/{chunk-XUCYFWC3.js → chunk-ZTCSVEHT.js} +1 -1
  84. package/dist/kit.cjs +1 -1
  85. package/dist/kit.d.cts +171 -6
  86. package/dist/kit.d.ts +171 -6
  87. package/dist/kit.js +1 -1
  88. package/package.json +1 -1
  89. package/skills/asciify-engine/SKILL.md +4 -4
  90. package/skills/asciify-engine/references/applying-asciify.md +18 -2
  91. package/skills/asciify-engine/references/components.md +81 -0
  92. package/skills/asciify-engine/references/glyph-field.md +2 -0
  93. package/skills/asciify-engine/references/kit.md +132 -3
  94. package/skills/asciify-engine/references/scenario-prompts.md +10 -1
  95. package/dist/kit/chunk-2GAV4OAK.js +0 -1
  96. package/dist/kit/chunk-AIGAJMNN.js +0 -1
  97. package/dist/kit/chunk-EEV6Y7NH.js +0 -1
  98. package/dist/kit/chunk-GF72XM4C.js +0 -1
  99. package/dist/kit/chunk-I5R2347P.js +0 -1
  100. package/dist/kit/chunk-M5VVLYI2.js +0 -1
  101. package/dist/kit/chunk-ORSI57T2.js +0 -1
  102. package/dist/kit/chunk-PGFBIU7R.js +0 -1
  103. package/dist/kit/chunk-UVLKCAKH.js +0 -1
  104. package/dist/kit/chunk-VBWG7HQA.js +0 -1
  105. package/dist/kit/chunk-VV2KP7ZW.js +0 -1
package/dist/kit.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { G as GlyphField, r as GlyphFieldOptions } from './glyph-field-C2fQIlnq.cjs';
1
+ import { G as GlyphField, r as GlyphFieldOptions, m as FieldMark } from './glyph-field-DKWHAMml.cjs';
2
2
  import { C as CHARACTER_SETS } from './characters-BgECi5Lf.cjs';
3
3
  import './hover-guide-DdFnAnfU.cjs';
4
4
 
@@ -154,8 +154,18 @@ interface DecodeOptions extends KitOptions {
154
154
  text?: string;
155
155
  /** Total length in ms: the first 30% is drift alone, then the words resolve left to right. Default 800. */
156
156
  duration?: number;
157
- /** `visible` decodes when the element scrolls into view; `manual` waits for `replay()`. Default `visible`. */
158
- trigger?: 'visible' | 'manual';
157
+ /**
158
+ * `visible` decodes when the element scrolls into view; `manual` waits for `replay()`; `scroll` ties the decode to scroll
159
+ * position, resolving as the element rises into view and undoing as it leaves (and idling while the page is still). Default `visible`.
160
+ */
161
+ trigger?: 'visible' | 'manual' | 'scroll';
162
+ /**
163
+ * Flip through other alphabets before landing: `true` for the built-in set (kana, Hangul, accented Latin, Cyrillic, Greek, then
164
+ * digits and signs) or your own list, one string of letters per alphabet. Each flip fills every unresolved letter from one
165
+ * alphabet, drawn in the element's font at the letter's own place; letters lock left to right over the last 60% of the run.
166
+ * The default `duration` becomes 1400.
167
+ */
168
+ scramble?: boolean | string[];
159
169
  /** Decode again when the pointer enters. Default true. */
160
170
  replayOnHover?: boolean;
161
171
  /** `glyphs` keeps the headline in characters; `text` hands back to the crisp HTML text at the end. Default `glyphs`. */
@@ -165,6 +175,8 @@ interface DecodeHandle extends KitHandle<DecodeOptions> {
165
175
  /** Plays the decode again from the drift. */
166
176
  replay(): void;
167
177
  }
178
+ /** The built-in alphabets `scramble: true` flips through. */
179
+ declare const SCRAMBLE_SCRIPTS: string[];
168
180
  /** A headline that condenses out of a drifting field of characters, left to right through a flickering band. */
169
181
  declare function decode(element: HTMLElement, options?: DecodeOptions): DecodeHandle;
170
182
 
@@ -402,6 +414,13 @@ interface WordmarkOptions extends KitOptions {
402
414
  artHeight?: number;
403
415
  /** The canvas's accessible name when the word is not the element's own text. Default the word. */
404
416
  label?: string;
417
+ /**
418
+ * The word gathers out of scattered pieces: `visible` once as it scrolls into view (over `duration`), `scroll` with scroll
419
+ * position, scattering again as it leaves. Off under reduced motion. Default off.
420
+ */
421
+ assemble?: 'visible' | 'scroll' | false;
422
+ /** Ms the `visible` assembly takes. Default 1400. */
423
+ duration?: number;
405
424
  }
406
425
  interface WordmarkHandle extends KitHandle<WordmarkOptions> {
407
426
  /** Sets the word again, as large as fits. */
@@ -665,9 +684,13 @@ interface PageDissolveHandle extends KitHandle<PageDissolveOptions> {
665
684
  /** A page or panel transition: one wave of characters from where the user clicked carries the old view out and the next one in. */
666
685
  declare function pageDissolve(container: HTMLElement, options?: PageDissolveOptions): PageDissolveHandle;
667
686
 
668
- type CursorTrailStyle = 'trail' | 'wake' | 'water' | 'sparkle';
687
+ type CursorTrailStyle = 'trail' | 'wake' | 'water' | 'sparkle' | 'spray';
669
688
  interface CursorTrailOptions extends KitOptions {
670
- /** `trail` the ink trail of a kit field's `hover: 'trail'` (the wordmark's), `wake` a softer, wider band along the path, `water` rings that spread from it, `sparkle` glints scattered along it. Default `trail`. */
689
+ /**
690
+ * `trail` the ink trail of a kit field's `hover: 'trail'` (the wordmark's), `wake` a softer, wider band along the path, `water`
691
+ * rings that spread from it, `sparkle` glints scattered along it, `spray` patches of diagonal hatching sprayed round the path
692
+ * (a drag draws a hatched selection box). Default `trail`.
693
+ */
671
694
  style?: CursorTrailStyle;
672
695
  /** Characters from empty to dense; the head of the trail takes the last one. Default ` .:-=+*#%@`. */
673
696
  charset?: string;
@@ -689,6 +712,11 @@ interface CursorTrailOptions extends KitOptions {
689
712
  zIndex?: number;
690
713
  /** More elements to stay quiet over, as a selector, on top of inputs, dialogs and `[data-ascii-cursor-skip]`. */
691
714
  skip?: string;
715
+ /**
716
+ * Small monospaced coordinate tags (`412, 168`) beside the newest marks and at a drag box's corners, in the ink with
717
+ * `--ascii-readout-text` (default white) on it. Decoration, hidden from assistive technology. Default false.
718
+ */
719
+ readout?: boolean;
692
720
  }
693
721
  interface CursorTrailHandle extends KitHandle<CursorTrailOptions> {
694
722
  /** True while something is fading on screen. */
@@ -703,6 +731,143 @@ interface CursorTrailHandle extends KitHandle<CursorTrailOptions> {
703
731
  */
704
732
  declare function cursorTrail(options?: CursorTrailOptions): CursorTrailHandle;
705
733
 
734
+ interface GlobePoint {
735
+ lat: number;
736
+ lon: number;
737
+ }
738
+ interface GlobeOptions extends KitOptions {
739
+ /** Degrees a second the globe turns; negative turns it the other way, 0 holds it. Default 6. */
740
+ speed?: number;
741
+ /** Longitude facing the viewer at the start, in degrees. Default -30 (the Americas and the Atlantic). */
742
+ lon?: number;
743
+ /** Tilt toward the viewer in degrees; positive shows more of the north. Default 18. */
744
+ tilt?: number;
745
+ /** Where land is, as a tone from 0 to 1 (or a boolean) for a latitude and longitude in degrees. Default the built-in world map. */
746
+ land?: (lat: number, lon: number) => number | boolean;
747
+ /** Latitude and longitude lines every this many degrees; 0 for none. Default 15. */
748
+ graticule?: number;
749
+ /** Places marked with a bright dot and a ring that keeps spreading from it. */
750
+ points?: GlobePoint[];
751
+ /** How strongly the far side's land shows through the near side's ocean, 0 to 1. Default 0.22. */
752
+ backside?: number;
753
+ /** The globe's diameter as a share of the element's shorter side. Default 0.92. */
754
+ size?: number;
755
+ /** Drag to turn it, with a little momentum. Default true. */
756
+ drag?: boolean;
757
+ /** Read to assistive technology. Without one the globe is decoration. */
758
+ label?: string;
759
+ }
760
+ interface GlobeHandle extends KitHandle<GlobeOptions> {
761
+ /** Turns the globe until `lon` (and `lat`, when given, through the tilt) faces the viewer. */
762
+ rotateTo(lon: number, lat?: number): void;
763
+ /** The longitude facing the viewer now. */
764
+ readonly lon: number;
765
+ }
766
+ /**
767
+ * A globe of dots: land, a faint ocean, latitude and longitude lines and the far side's land showing through, turning slowly.
768
+ * Drag turns it; `points` mark places with a spreading ring. It holds still under reduced motion, and a globe with `speed: 0`
769
+ * and no points draws once and idles.
770
+ */
771
+ declare function globe(element: HTMLElement, options?: GlobeOptions): GlobeHandle;
772
+
773
+ /** A frame to morph through: an image URL or element, a canvas, a video, or a function that draws white-on-black each frame. */
774
+ type MorphSource = string | HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ((pen: CanvasRenderingContext2D, w: number, h: number, now: number) => void);
775
+ interface MorphFieldOptions extends KitOptions {
776
+ /** The frames, in order. A function source animates every frame (a turning scene); the others are stills or video. */
777
+ sources: MorphSource[];
778
+ /** Ms each frame holds before the next morphs in. Default 3200. */
779
+ hold?: number;
780
+ /** Ms a morph takes. Default 1000. */
781
+ transition?: number;
782
+ /** Cycle through the frames on its own. Default true; off under reduced motion. */
783
+ autoplay?: boolean;
784
+ /** `cover` fills the element, cropping; `contain` fits inside it. Default `cover`. */
785
+ fit?: 'cover' | 'contain';
786
+ /** `under` sits below the element's content (a hero), `over` above it. Default `under`. */
787
+ layer?: 'under' | 'over';
788
+ /** Called as each morph starts, with the frame it is heading to: keep a caption or a counter ("2/5") in step. */
789
+ onChange?: (index: number) => void;
790
+ /** Read to assistive technology. Without one the field is decoration. */
791
+ label?: string;
792
+ }
793
+ interface MorphFieldHandle extends KitHandle<MorphFieldOptions> {
794
+ /** Morphs to the next frame. */
795
+ next(): void;
796
+ /** Morphs to frame `index`. */
797
+ go(index: number): void;
798
+ /** The frame showing, or being morphed to. */
799
+ readonly index: number;
800
+ }
801
+ /**
802
+ * Frames that morph into one another as the field's marks: by default diagonal engraved lines whose weight follows the tone, so
803
+ * one picture's stripes thin away as the next one's thicken. Holds each frame, then cross-fades; idles between morphs unless a
804
+ * frame is a video or a drawing function.
805
+ */
806
+ declare function morphField(element: HTMLElement, options: MorphFieldOptions): MorphFieldHandle;
807
+
808
+ interface DitherLight {
809
+ /** Centre as a share of the element's width and height; may lie outside 0..1 to light from past an edge. */
810
+ x: number;
811
+ y: number;
812
+ /** Radius as a share of the element's longer side. Default 0.6. */
813
+ radius?: number;
814
+ /** Peak tone, 0 to 1. Default 1. */
815
+ strength?: number;
816
+ }
817
+ interface DitherGradientOptions extends KitOptions {
818
+ /** The lights the gradient is made of. Default one broad light rising from just below the bottom edge. */
819
+ lights?: DitherLight[];
820
+ /** Tone of the ground between the lights, 0 to 1. Default 0.05. */
821
+ base?: number;
822
+ /** How much the lights drift and breathe, 0 (still: draws once, then idles) to 1. Default 0.35. */
823
+ motion?: number;
824
+ /** How far the first light leans toward the pointer, as a share of the element; 0 for none. Default 0.06. */
825
+ follow?: number;
826
+ /** `under` sits below the element's content (a hero's ground); `over` above it. Default `under`. */
827
+ layer?: 'under' | 'over';
828
+ }
829
+ interface DitherGradientHandle extends KitHandle<DitherGradientOptions> {
830
+ /** Replaces the lights; the next frame draws them. */
831
+ setLights(lights: DitherLight[]): void;
832
+ }
833
+ /**
834
+ * A gradient of soft lights drawn as a two-tone dither: the field's ink on the element's own background. The lights drift and
835
+ * breathe gently and the first leans toward the pointer. With `motion: 0` and the pointer away it draws once and idles; reduced
836
+ * motion draws one still frame.
837
+ */
838
+ declare function ditherGradient(element: HTMLElement, options?: DitherGradientOptions): DitherGradientHandle;
839
+
840
+ interface DitherImageOptions extends KitOptions {
841
+ /** The image: a URL or an `<img>`. Default the first `<img>` inside, hidden while the field draws it. */
842
+ src?: string | HTMLImageElement;
843
+ /**
844
+ * The brand's two tones: `[ground, ink]`, each a CSS colour or token. The ground fills the element under the marks; leave it
845
+ * `'transparent'` to keep the element's own background. Default `['transparent', '--ascii-ink-strong']`.
846
+ */
847
+ tones?: [string, string];
848
+ /** The mark the image is drawn in: `dither` (Bayer dots), `pixel`, `mosaic`, `dot`, `engraving`, `stipple`, … Default `dither`. */
849
+ mark?: FieldMark;
850
+ /** Cell size in CSS px. Default 5. */
851
+ cellSize?: number;
852
+ /** `visible` develops the image in from blank when it scrolls into view, `scroll` ties that to scroll position, `none` shows it at once. Default `visible`. */
853
+ reveal?: 'none' | 'visible' | 'scroll';
854
+ /** Length of the `visible` reveal in ms. Default 1100. */
855
+ duration?: number;
856
+ /** Cover crop focus, 0 to 1 on each axis. Default the centre. */
857
+ focus?: {
858
+ x: number;
859
+ y: number;
860
+ };
861
+ /** The canvas's accessible name. Default the image's `alt`. */
862
+ label?: string;
863
+ }
864
+ interface DitherImageHandle extends KitHandle<DitherImageOptions> {
865
+ /** Plays the reveal again from blank. */
866
+ replay(): void;
867
+ }
868
+ /** An image drawn in a brand's two tones as dither, pixels, dots or engraving, developing in as it scrolls into view. */
869
+ declare function ditherImage(element: HTMLElement, options?: DitherImageOptions): DitherImageHandle;
870
+
706
871
  interface SwipeDeckOptions extends KitOptions {
707
872
  /** The cards, in order. Each card's first `img` is drawn in characters. Default `[data-card]`. */
708
873
  cards?: string;
@@ -1425,4 +1590,4 @@ declare function subscribeGlobalLook(listener: (look: GlobalLook | null) => void
1425
1590
  declare function setFieldBudget(n: number): void;
1426
1591
  declare const getFieldBudget: () => number;
1427
1592
 
1428
- export { type AccordionHandle, type AccordionImage, type AccordionOptions, type ArtPanelHandle, type ArtPanelOptions, type AsciiVideoHandle, type AsciiVideoOptions, BEAM_PALETTES, type BackgroundCharset, type BackgroundContext, type BackgroundCursor, type BackgroundHandle, type BackgroundMark, type BackgroundOptions, type BackgroundPreset, type BackgroundRun, type BackgroundSettings, type BeamHandle, type BeamMode, type BeamOptions, type BeamPalette, type BlockChartHandle, type BlockChartOptions, type Box, type ButtonLoadingHandle, type ButtonLoadingOptions, type ButtonState, type CodeInputHandle, type CodeInputOptions, type CodeState, type CommandPaletteHandle, type CommandPaletteOptions, type CompareHandle, type CompareOptions, type CursorTrailHandle, type CursorTrailOptions, type CursorTrailStyle, type DecodeHandle, type DecodeOptions, type DisintegrateOptions, type DropState, type DroppedImage, type DropzoneHandle, type DropzoneOptions, type FieldBackgroundHandle, type FieldBackgroundOptions, type FieldPreset, type GenerateState, type GlobalLook, type ImageGenerateHandle, type ImageGenerateOptions, type ImageStream, type ImageUpdate, KIT_STYLES, type KitHandle, type KitOptions, type KitStyle, type LikeBurstHandle, type LikeBurstOptions, type LikeMark, type OdometerHandle, type OdometerOptions, type OrbState, PILL_TONES, type PageDissolveHandle, type PageDissolveOptions, type PaintFrame, type PillHandle, type PillOptions, type PillTone, type PricingGlowHandle, type PricingGlowOptions, type PullRefreshHandle, type PullRefreshOptions, type PullState, type SkeletonBlock, type SkeletonHandle, type SkeletonOptions, type SlideToConfirmHandle, type SlideToConfirmOptions, type StatusOrbHandle, type StatusOrbOptions, type StreamState, type StreamTextHandle, type StreamTextOptions, type Surface, type SurfaceConfig, type SwipeDeckHandle, type SwipeDeckOptions, type TabsHandle, type TabsOptions, type TemplateDraw, type TemplateFrame, type ThinkingHandle, type ThinkingOptions, type ThinkingState, type Toast, type ToastStackHandle, type ToastStackOptions, VOICE_PALETTES, type VoiceOrbHandle, type VoiceOrbOptions, type VoicePalette, type VoiceState, type WordmarkHandle, type WordmarkOptions, accordion, artPanel, asciiVideo, aurora, background, backgroundCharset, beam, beamPalette, blockChart, buttonLoading, cascade, caustics, circuit, codeInput, commandPalette, compare, constellation, contour, cursorTrail, decode, disintegrate, dna, drift, dropzone, dune, etch, facet, fieldBackground, fire, fluid, getFieldBudget, getGlobalLook, grid, halftone, halo, imageGenerate, interference, likeBurst, mesh, moire, morph, mountCanvas, mountSurface, noise, odometer, pageDissolve, pill, pricingGlow, pullRefresh, pulse, rain, resolveColor, ripple, setFieldBudget, setGlobalLook, silk, skeleton, slideToConfirm, stars, statusOrb, streamText, subscribeGlobalLook, swell, swipeDeck, tabs, terrain, thinking, toastStack, veil, voiceOrb, voidWell, wave, weave, wordField, wordmark };
1593
+ export { type AccordionHandle, type AccordionImage, type AccordionOptions, type ArtPanelHandle, type ArtPanelOptions, type AsciiVideoHandle, type AsciiVideoOptions, BEAM_PALETTES, type BackgroundCharset, type BackgroundContext, type BackgroundCursor, type BackgroundHandle, type BackgroundMark, type BackgroundOptions, type BackgroundPreset, type BackgroundRun, type BackgroundSettings, type BeamHandle, type BeamMode, type BeamOptions, type BeamPalette, type BlockChartHandle, type BlockChartOptions, type Box, type ButtonLoadingHandle, type ButtonLoadingOptions, type ButtonState, type CodeInputHandle, type CodeInputOptions, type CodeState, type CommandPaletteHandle, type CommandPaletteOptions, type CompareHandle, type CompareOptions, type CursorTrailHandle, type CursorTrailOptions, type CursorTrailStyle, type DecodeHandle, type DecodeOptions, type DisintegrateOptions, type DitherGradientHandle, type DitherGradientOptions, type DitherImageHandle, type DitherImageOptions, type DitherLight, type DropState, type DroppedImage, type DropzoneHandle, type DropzoneOptions, type FieldBackgroundHandle, type FieldBackgroundOptions, type FieldPreset, type GenerateState, type GlobalLook, type GlobeHandle, type GlobeOptions, type GlobePoint, type ImageGenerateHandle, type ImageGenerateOptions, type ImageStream, type ImageUpdate, KIT_STYLES, type KitHandle, type KitOptions, type KitStyle, type LikeBurstHandle, type LikeBurstOptions, type LikeMark, type MorphFieldHandle, type MorphFieldOptions, type MorphSource, type OdometerHandle, type OdometerOptions, type OrbState, PILL_TONES, type PageDissolveHandle, type PageDissolveOptions, type PaintFrame, type PillHandle, type PillOptions, type PillTone, type PricingGlowHandle, type PricingGlowOptions, type PullRefreshHandle, type PullRefreshOptions, type PullState, SCRAMBLE_SCRIPTS, type SkeletonBlock, type SkeletonHandle, type SkeletonOptions, type SlideToConfirmHandle, type SlideToConfirmOptions, type StatusOrbHandle, type StatusOrbOptions, type StreamState, type StreamTextHandle, type StreamTextOptions, type Surface, type SurfaceConfig, type SwipeDeckHandle, type SwipeDeckOptions, type TabsHandle, type TabsOptions, type TemplateDraw, type TemplateFrame, type ThinkingHandle, type ThinkingOptions, type ThinkingState, type Toast, type ToastStackHandle, type ToastStackOptions, VOICE_PALETTES, type VoiceOrbHandle, type VoiceOrbOptions, type VoicePalette, type VoiceState, type WordmarkHandle, type WordmarkOptions, accordion, artPanel, asciiVideo, aurora, background, backgroundCharset, beam, beamPalette, blockChart, buttonLoading, cascade, caustics, circuit, codeInput, commandPalette, compare, constellation, contour, cursorTrail, decode, disintegrate, ditherGradient, ditherImage, dna, drift, dropzone, dune, etch, facet, fieldBackground, fire, fluid, getFieldBudget, getGlobalLook, globe, grid, halftone, halo, imageGenerate, interference, likeBurst, mesh, moire, morph, morphField, mountCanvas, mountSurface, noise, odometer, pageDissolve, pill, pricingGlow, pullRefresh, pulse, rain, resolveColor, ripple, setFieldBudget, setGlobalLook, silk, skeleton, slideToConfirm, stars, statusOrb, streamText, subscribeGlobalLook, swell, swipeDeck, tabs, terrain, thinking, toastStack, veil, voiceOrb, voidWell, wave, weave, wordField, wordmark };
package/dist/kit.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { G as GlyphField, r as GlyphFieldOptions } from './glyph-field-DRC-7uVf.js';
1
+ import { G as GlyphField, r as GlyphFieldOptions, m as FieldMark } from './glyph-field-BCwGhohg.js';
2
2
  import { C as CHARACTER_SETS } from './characters-BgECi5Lf.js';
3
3
  import './hover-guide-DdFnAnfU.js';
4
4
 
@@ -154,8 +154,18 @@ interface DecodeOptions extends KitOptions {
154
154
  text?: string;
155
155
  /** Total length in ms: the first 30% is drift alone, then the words resolve left to right. Default 800. */
156
156
  duration?: number;
157
- /** `visible` decodes when the element scrolls into view; `manual` waits for `replay()`. Default `visible`. */
158
- trigger?: 'visible' | 'manual';
157
+ /**
158
+ * `visible` decodes when the element scrolls into view; `manual` waits for `replay()`; `scroll` ties the decode to scroll
159
+ * position, resolving as the element rises into view and undoing as it leaves (and idling while the page is still). Default `visible`.
160
+ */
161
+ trigger?: 'visible' | 'manual' | 'scroll';
162
+ /**
163
+ * Flip through other alphabets before landing: `true` for the built-in set (kana, Hangul, accented Latin, Cyrillic, Greek, then
164
+ * digits and signs) or your own list, one string of letters per alphabet. Each flip fills every unresolved letter from one
165
+ * alphabet, drawn in the element's font at the letter's own place; letters lock left to right over the last 60% of the run.
166
+ * The default `duration` becomes 1400.
167
+ */
168
+ scramble?: boolean | string[];
159
169
  /** Decode again when the pointer enters. Default true. */
160
170
  replayOnHover?: boolean;
161
171
  /** `glyphs` keeps the headline in characters; `text` hands back to the crisp HTML text at the end. Default `glyphs`. */
@@ -165,6 +175,8 @@ interface DecodeHandle extends KitHandle<DecodeOptions> {
165
175
  /** Plays the decode again from the drift. */
166
176
  replay(): void;
167
177
  }
178
+ /** The built-in alphabets `scramble: true` flips through. */
179
+ declare const SCRAMBLE_SCRIPTS: string[];
168
180
  /** A headline that condenses out of a drifting field of characters, left to right through a flickering band. */
169
181
  declare function decode(element: HTMLElement, options?: DecodeOptions): DecodeHandle;
170
182
 
@@ -402,6 +414,13 @@ interface WordmarkOptions extends KitOptions {
402
414
  artHeight?: number;
403
415
  /** The canvas's accessible name when the word is not the element's own text. Default the word. */
404
416
  label?: string;
417
+ /**
418
+ * The word gathers out of scattered pieces: `visible` once as it scrolls into view (over `duration`), `scroll` with scroll
419
+ * position, scattering again as it leaves. Off under reduced motion. Default off.
420
+ */
421
+ assemble?: 'visible' | 'scroll' | false;
422
+ /** Ms the `visible` assembly takes. Default 1400. */
423
+ duration?: number;
405
424
  }
406
425
  interface WordmarkHandle extends KitHandle<WordmarkOptions> {
407
426
  /** Sets the word again, as large as fits. */
@@ -665,9 +684,13 @@ interface PageDissolveHandle extends KitHandle<PageDissolveOptions> {
665
684
  /** A page or panel transition: one wave of characters from where the user clicked carries the old view out and the next one in. */
666
685
  declare function pageDissolve(container: HTMLElement, options?: PageDissolveOptions): PageDissolveHandle;
667
686
 
668
- type CursorTrailStyle = 'trail' | 'wake' | 'water' | 'sparkle';
687
+ type CursorTrailStyle = 'trail' | 'wake' | 'water' | 'sparkle' | 'spray';
669
688
  interface CursorTrailOptions extends KitOptions {
670
- /** `trail` the ink trail of a kit field's `hover: 'trail'` (the wordmark's), `wake` a softer, wider band along the path, `water` rings that spread from it, `sparkle` glints scattered along it. Default `trail`. */
689
+ /**
690
+ * `trail` the ink trail of a kit field's `hover: 'trail'` (the wordmark's), `wake` a softer, wider band along the path, `water`
691
+ * rings that spread from it, `sparkle` glints scattered along it, `spray` patches of diagonal hatching sprayed round the path
692
+ * (a drag draws a hatched selection box). Default `trail`.
693
+ */
671
694
  style?: CursorTrailStyle;
672
695
  /** Characters from empty to dense; the head of the trail takes the last one. Default ` .:-=+*#%@`. */
673
696
  charset?: string;
@@ -689,6 +712,11 @@ interface CursorTrailOptions extends KitOptions {
689
712
  zIndex?: number;
690
713
  /** More elements to stay quiet over, as a selector, on top of inputs, dialogs and `[data-ascii-cursor-skip]`. */
691
714
  skip?: string;
715
+ /**
716
+ * Small monospaced coordinate tags (`412, 168`) beside the newest marks and at a drag box's corners, in the ink with
717
+ * `--ascii-readout-text` (default white) on it. Decoration, hidden from assistive technology. Default false.
718
+ */
719
+ readout?: boolean;
692
720
  }
693
721
  interface CursorTrailHandle extends KitHandle<CursorTrailOptions> {
694
722
  /** True while something is fading on screen. */
@@ -703,6 +731,143 @@ interface CursorTrailHandle extends KitHandle<CursorTrailOptions> {
703
731
  */
704
732
  declare function cursorTrail(options?: CursorTrailOptions): CursorTrailHandle;
705
733
 
734
+ interface GlobePoint {
735
+ lat: number;
736
+ lon: number;
737
+ }
738
+ interface GlobeOptions extends KitOptions {
739
+ /** Degrees a second the globe turns; negative turns it the other way, 0 holds it. Default 6. */
740
+ speed?: number;
741
+ /** Longitude facing the viewer at the start, in degrees. Default -30 (the Americas and the Atlantic). */
742
+ lon?: number;
743
+ /** Tilt toward the viewer in degrees; positive shows more of the north. Default 18. */
744
+ tilt?: number;
745
+ /** Where land is, as a tone from 0 to 1 (or a boolean) for a latitude and longitude in degrees. Default the built-in world map. */
746
+ land?: (lat: number, lon: number) => number | boolean;
747
+ /** Latitude and longitude lines every this many degrees; 0 for none. Default 15. */
748
+ graticule?: number;
749
+ /** Places marked with a bright dot and a ring that keeps spreading from it. */
750
+ points?: GlobePoint[];
751
+ /** How strongly the far side's land shows through the near side's ocean, 0 to 1. Default 0.22. */
752
+ backside?: number;
753
+ /** The globe's diameter as a share of the element's shorter side. Default 0.92. */
754
+ size?: number;
755
+ /** Drag to turn it, with a little momentum. Default true. */
756
+ drag?: boolean;
757
+ /** Read to assistive technology. Without one the globe is decoration. */
758
+ label?: string;
759
+ }
760
+ interface GlobeHandle extends KitHandle<GlobeOptions> {
761
+ /** Turns the globe until `lon` (and `lat`, when given, through the tilt) faces the viewer. */
762
+ rotateTo(lon: number, lat?: number): void;
763
+ /** The longitude facing the viewer now. */
764
+ readonly lon: number;
765
+ }
766
+ /**
767
+ * A globe of dots: land, a faint ocean, latitude and longitude lines and the far side's land showing through, turning slowly.
768
+ * Drag turns it; `points` mark places with a spreading ring. It holds still under reduced motion, and a globe with `speed: 0`
769
+ * and no points draws once and idles.
770
+ */
771
+ declare function globe(element: HTMLElement, options?: GlobeOptions): GlobeHandle;
772
+
773
+ /** A frame to morph through: an image URL or element, a canvas, a video, or a function that draws white-on-black each frame. */
774
+ type MorphSource = string | HTMLImageElement | HTMLCanvasElement | HTMLVideoElement | ((pen: CanvasRenderingContext2D, w: number, h: number, now: number) => void);
775
+ interface MorphFieldOptions extends KitOptions {
776
+ /** The frames, in order. A function source animates every frame (a turning scene); the others are stills or video. */
777
+ sources: MorphSource[];
778
+ /** Ms each frame holds before the next morphs in. Default 3200. */
779
+ hold?: number;
780
+ /** Ms a morph takes. Default 1000. */
781
+ transition?: number;
782
+ /** Cycle through the frames on its own. Default true; off under reduced motion. */
783
+ autoplay?: boolean;
784
+ /** `cover` fills the element, cropping; `contain` fits inside it. Default `cover`. */
785
+ fit?: 'cover' | 'contain';
786
+ /** `under` sits below the element's content (a hero), `over` above it. Default `under`. */
787
+ layer?: 'under' | 'over';
788
+ /** Called as each morph starts, with the frame it is heading to: keep a caption or a counter ("2/5") in step. */
789
+ onChange?: (index: number) => void;
790
+ /** Read to assistive technology. Without one the field is decoration. */
791
+ label?: string;
792
+ }
793
+ interface MorphFieldHandle extends KitHandle<MorphFieldOptions> {
794
+ /** Morphs to the next frame. */
795
+ next(): void;
796
+ /** Morphs to frame `index`. */
797
+ go(index: number): void;
798
+ /** The frame showing, or being morphed to. */
799
+ readonly index: number;
800
+ }
801
+ /**
802
+ * Frames that morph into one another as the field's marks: by default diagonal engraved lines whose weight follows the tone, so
803
+ * one picture's stripes thin away as the next one's thicken. Holds each frame, then cross-fades; idles between morphs unless a
804
+ * frame is a video or a drawing function.
805
+ */
806
+ declare function morphField(element: HTMLElement, options: MorphFieldOptions): MorphFieldHandle;
807
+
808
+ interface DitherLight {
809
+ /** Centre as a share of the element's width and height; may lie outside 0..1 to light from past an edge. */
810
+ x: number;
811
+ y: number;
812
+ /** Radius as a share of the element's longer side. Default 0.6. */
813
+ radius?: number;
814
+ /** Peak tone, 0 to 1. Default 1. */
815
+ strength?: number;
816
+ }
817
+ interface DitherGradientOptions extends KitOptions {
818
+ /** The lights the gradient is made of. Default one broad light rising from just below the bottom edge. */
819
+ lights?: DitherLight[];
820
+ /** Tone of the ground between the lights, 0 to 1. Default 0.05. */
821
+ base?: number;
822
+ /** How much the lights drift and breathe, 0 (still: draws once, then idles) to 1. Default 0.35. */
823
+ motion?: number;
824
+ /** How far the first light leans toward the pointer, as a share of the element; 0 for none. Default 0.06. */
825
+ follow?: number;
826
+ /** `under` sits below the element's content (a hero's ground); `over` above it. Default `under`. */
827
+ layer?: 'under' | 'over';
828
+ }
829
+ interface DitherGradientHandle extends KitHandle<DitherGradientOptions> {
830
+ /** Replaces the lights; the next frame draws them. */
831
+ setLights(lights: DitherLight[]): void;
832
+ }
833
+ /**
834
+ * A gradient of soft lights drawn as a two-tone dither: the field's ink on the element's own background. The lights drift and
835
+ * breathe gently and the first leans toward the pointer. With `motion: 0` and the pointer away it draws once and idles; reduced
836
+ * motion draws one still frame.
837
+ */
838
+ declare function ditherGradient(element: HTMLElement, options?: DitherGradientOptions): DitherGradientHandle;
839
+
840
+ interface DitherImageOptions extends KitOptions {
841
+ /** The image: a URL or an `<img>`. Default the first `<img>` inside, hidden while the field draws it. */
842
+ src?: string | HTMLImageElement;
843
+ /**
844
+ * The brand's two tones: `[ground, ink]`, each a CSS colour or token. The ground fills the element under the marks; leave it
845
+ * `'transparent'` to keep the element's own background. Default `['transparent', '--ascii-ink-strong']`.
846
+ */
847
+ tones?: [string, string];
848
+ /** The mark the image is drawn in: `dither` (Bayer dots), `pixel`, `mosaic`, `dot`, `engraving`, `stipple`, … Default `dither`. */
849
+ mark?: FieldMark;
850
+ /** Cell size in CSS px. Default 5. */
851
+ cellSize?: number;
852
+ /** `visible` develops the image in from blank when it scrolls into view, `scroll` ties that to scroll position, `none` shows it at once. Default `visible`. */
853
+ reveal?: 'none' | 'visible' | 'scroll';
854
+ /** Length of the `visible` reveal in ms. Default 1100. */
855
+ duration?: number;
856
+ /** Cover crop focus, 0 to 1 on each axis. Default the centre. */
857
+ focus?: {
858
+ x: number;
859
+ y: number;
860
+ };
861
+ /** The canvas's accessible name. Default the image's `alt`. */
862
+ label?: string;
863
+ }
864
+ interface DitherImageHandle extends KitHandle<DitherImageOptions> {
865
+ /** Plays the reveal again from blank. */
866
+ replay(): void;
867
+ }
868
+ /** An image drawn in a brand's two tones as dither, pixels, dots or engraving, developing in as it scrolls into view. */
869
+ declare function ditherImage(element: HTMLElement, options?: DitherImageOptions): DitherImageHandle;
870
+
706
871
  interface SwipeDeckOptions extends KitOptions {
707
872
  /** The cards, in order. Each card's first `img` is drawn in characters. Default `[data-card]`. */
708
873
  cards?: string;
@@ -1425,4 +1590,4 @@ declare function subscribeGlobalLook(listener: (look: GlobalLook | null) => void
1425
1590
  declare function setFieldBudget(n: number): void;
1426
1591
  declare const getFieldBudget: () => number;
1427
1592
 
1428
- export { type AccordionHandle, type AccordionImage, type AccordionOptions, type ArtPanelHandle, type ArtPanelOptions, type AsciiVideoHandle, type AsciiVideoOptions, BEAM_PALETTES, type BackgroundCharset, type BackgroundContext, type BackgroundCursor, type BackgroundHandle, type BackgroundMark, type BackgroundOptions, type BackgroundPreset, type BackgroundRun, type BackgroundSettings, type BeamHandle, type BeamMode, type BeamOptions, type BeamPalette, type BlockChartHandle, type BlockChartOptions, type Box, type ButtonLoadingHandle, type ButtonLoadingOptions, type ButtonState, type CodeInputHandle, type CodeInputOptions, type CodeState, type CommandPaletteHandle, type CommandPaletteOptions, type CompareHandle, type CompareOptions, type CursorTrailHandle, type CursorTrailOptions, type CursorTrailStyle, type DecodeHandle, type DecodeOptions, type DisintegrateOptions, type DropState, type DroppedImage, type DropzoneHandle, type DropzoneOptions, type FieldBackgroundHandle, type FieldBackgroundOptions, type FieldPreset, type GenerateState, type GlobalLook, type ImageGenerateHandle, type ImageGenerateOptions, type ImageStream, type ImageUpdate, KIT_STYLES, type KitHandle, type KitOptions, type KitStyle, type LikeBurstHandle, type LikeBurstOptions, type LikeMark, type OdometerHandle, type OdometerOptions, type OrbState, PILL_TONES, type PageDissolveHandle, type PageDissolveOptions, type PaintFrame, type PillHandle, type PillOptions, type PillTone, type PricingGlowHandle, type PricingGlowOptions, type PullRefreshHandle, type PullRefreshOptions, type PullState, type SkeletonBlock, type SkeletonHandle, type SkeletonOptions, type SlideToConfirmHandle, type SlideToConfirmOptions, type StatusOrbHandle, type StatusOrbOptions, type StreamState, type StreamTextHandle, type StreamTextOptions, type Surface, type SurfaceConfig, type SwipeDeckHandle, type SwipeDeckOptions, type TabsHandle, type TabsOptions, type TemplateDraw, type TemplateFrame, type ThinkingHandle, type ThinkingOptions, type ThinkingState, type Toast, type ToastStackHandle, type ToastStackOptions, VOICE_PALETTES, type VoiceOrbHandle, type VoiceOrbOptions, type VoicePalette, type VoiceState, type WordmarkHandle, type WordmarkOptions, accordion, artPanel, asciiVideo, aurora, background, backgroundCharset, beam, beamPalette, blockChart, buttonLoading, cascade, caustics, circuit, codeInput, commandPalette, compare, constellation, contour, cursorTrail, decode, disintegrate, dna, drift, dropzone, dune, etch, facet, fieldBackground, fire, fluid, getFieldBudget, getGlobalLook, grid, halftone, halo, imageGenerate, interference, likeBurst, mesh, moire, morph, mountCanvas, mountSurface, noise, odometer, pageDissolve, pill, pricingGlow, pullRefresh, pulse, rain, resolveColor, ripple, setFieldBudget, setGlobalLook, silk, skeleton, slideToConfirm, stars, statusOrb, streamText, subscribeGlobalLook, swell, swipeDeck, tabs, terrain, thinking, toastStack, veil, voiceOrb, voidWell, wave, weave, wordField, wordmark };
1593
+ export { type AccordionHandle, type AccordionImage, type AccordionOptions, type ArtPanelHandle, type ArtPanelOptions, type AsciiVideoHandle, type AsciiVideoOptions, BEAM_PALETTES, type BackgroundCharset, type BackgroundContext, type BackgroundCursor, type BackgroundHandle, type BackgroundMark, type BackgroundOptions, type BackgroundPreset, type BackgroundRun, type BackgroundSettings, type BeamHandle, type BeamMode, type BeamOptions, type BeamPalette, type BlockChartHandle, type BlockChartOptions, type Box, type ButtonLoadingHandle, type ButtonLoadingOptions, type ButtonState, type CodeInputHandle, type CodeInputOptions, type CodeState, type CommandPaletteHandle, type CommandPaletteOptions, type CompareHandle, type CompareOptions, type CursorTrailHandle, type CursorTrailOptions, type CursorTrailStyle, type DecodeHandle, type DecodeOptions, type DisintegrateOptions, type DitherGradientHandle, type DitherGradientOptions, type DitherImageHandle, type DitherImageOptions, type DitherLight, type DropState, type DroppedImage, type DropzoneHandle, type DropzoneOptions, type FieldBackgroundHandle, type FieldBackgroundOptions, type FieldPreset, type GenerateState, type GlobalLook, type GlobeHandle, type GlobeOptions, type GlobePoint, type ImageGenerateHandle, type ImageGenerateOptions, type ImageStream, type ImageUpdate, KIT_STYLES, type KitHandle, type KitOptions, type KitStyle, type LikeBurstHandle, type LikeBurstOptions, type LikeMark, type MorphFieldHandle, type MorphFieldOptions, type MorphSource, type OdometerHandle, type OdometerOptions, type OrbState, PILL_TONES, type PageDissolveHandle, type PageDissolveOptions, type PaintFrame, type PillHandle, type PillOptions, type PillTone, type PricingGlowHandle, type PricingGlowOptions, type PullRefreshHandle, type PullRefreshOptions, type PullState, SCRAMBLE_SCRIPTS, type SkeletonBlock, type SkeletonHandle, type SkeletonOptions, type SlideToConfirmHandle, type SlideToConfirmOptions, type StatusOrbHandle, type StatusOrbOptions, type StreamState, type StreamTextHandle, type StreamTextOptions, type Surface, type SurfaceConfig, type SwipeDeckHandle, type SwipeDeckOptions, type TabsHandle, type TabsOptions, type TemplateDraw, type TemplateFrame, type ThinkingHandle, type ThinkingOptions, type ThinkingState, type Toast, type ToastStackHandle, type ToastStackOptions, VOICE_PALETTES, type VoiceOrbHandle, type VoiceOrbOptions, type VoicePalette, type VoiceState, type WordmarkHandle, type WordmarkOptions, accordion, artPanel, asciiVideo, aurora, background, backgroundCharset, beam, beamPalette, blockChart, buttonLoading, cascade, caustics, circuit, codeInput, commandPalette, compare, constellation, contour, cursorTrail, decode, disintegrate, ditherGradient, ditherImage, dna, drift, dropzone, dune, etch, facet, fieldBackground, fire, fluid, getFieldBudget, getGlobalLook, globe, grid, halftone, halo, imageGenerate, interference, likeBurst, mesh, moire, morph, morphField, mountCanvas, mountSurface, noise, odometer, pageDissolve, pill, pricingGlow, pullRefresh, pulse, rain, resolveColor, ripple, setFieldBudget, setGlobalLook, silk, skeleton, slideToConfirm, stars, statusOrb, streamText, subscribeGlobalLook, swell, swipeDeck, tabs, terrain, thinking, toastStack, veil, voiceOrb, voidWell, wave, weave, wordField, wordmark };
package/dist/kit.js CHANGED
@@ -1 +1 @@
1
- export{voidWell}from"./kit/chunk-7M2FFUZ3.js";export{wave}from"./kit/chunk-2GAV4OAK.js";export{weave}from"./kit/chunk-W4U5CK6L.js";export{morph}from"./kit/chunk-GKR3ROYR.js";export{noise}from"./kit/chunk-M5VVLYI2.js";export{pulse}from"./kit/chunk-KEE55QSD.js";export{rain}from"./kit/chunk-BFBG3VHI.js";export{silk}from"./kit/chunk-3LJ5C3U3.js";export{stars}from"./kit/chunk-ORSI57T2.js";export{terrain}from"./kit/chunk-QSTDYL35.js";export{veil}from"./kit/chunk-CGSWUO67.js";export{circuit}from"./kit/chunk-E3FPFANJ.js";export{dna}from"./kit/chunk-AIGAJMNN.js";export{dune}from"./kit/chunk-ZCXNGJGB.js";export{etch}from"./kit/chunk-CG6SGQMY.js";export{facet}from"./kit/chunk-6WU247CB.js";export{fire}from"./kit/chunk-UVLKCAKH.js";export{grid}from"./kit/chunk-WI2AF2KE.js";export{moire}from"./kit/chunk-B3TY6UXJ.js";import"./kit/chunk-XPXMCXYI.js";import"./kit/chunk-ZCHGV2CV.js";export{mountCanvas}from"./kit/chunk-3OD5BMF5.js";export{ripple}from"./kit/chunk-Z3KD6CLE.js";export{halo}from"./kit/chunk-6G5MPND3.js";export{interference}from"./kit/chunk-EKYEA7Z4.js";export{mesh}from"./kit/chunk-776H2BJ7.js";export{cascade}from"./kit/chunk-TRDA73HN.js";export{constellation}from"./kit/chunk-3MHEDZLZ.js";export{aurora}from"./kit/chunk-FHN3PPSI.js";export{halftone}from"./kit/chunk-DMRPBFLW.js";export{pullRefresh}from"./kit/chunk-4U72YE65.js";export{background,backgroundCharset}from"./kit/chunk-NW4U2YRE.js";export{swell}from"./kit/chunk-KY5KCIZE.js";export{drift}from"./kit/chunk-GBNV3GXG.js";export{wordField}from"./kit/chunk-RXOPJJC4.js";export{fluid}from"./kit/chunk-UOYBFLGJ.js";export{caustics}from"./kit/chunk-F6F2C3RH.js";export{contour}from"./kit/chunk-FPCCX4FM.js";import"./kit/chunk-3VEMKDBW.js";export{codeInput}from"./kit/chunk-KFXMLIVF.js";export{toastStack}from"./kit/chunk-OZFSNW5N.js";export{thinking}from"./kit/chunk-ZWZZMU5P.js";export{streamText}from"./kit/chunk-4NV5APSJ.js";export{compare}from"./kit/chunk-YSN7EHSH.js";export{accordion}from"./kit/chunk-G4ZSMTFN.js";export{dropzone}from"./kit/chunk-HYVTFKWX.js";export{disintegrate}from"./kit/chunk-3YSK7V26.js";export{VOICE_PALETTES,voiceOrb}from"./kit/chunk-KXI3T72F.js";export{commandPalette}from"./kit/chunk-PGFBIU7R.js";import"./kit/chunk-PB5E3D4E.js";export{likeBurst}from"./kit/chunk-NF4WVWAC.js";export{blockChart}from"./kit/chunk-VBWG7HQA.js";export{pageDissolve}from"./kit/chunk-LVCGC3SO.js";import"./kit/chunk-Z2FRNFMB.js";export{cursorTrail}from"./kit/chunk-EEV6Y7NH.js";export{swipeDeck}from"./kit/chunk-FWODCYYJ.js";export{slideToConfirm}from"./kit/chunk-K6JX64AS.js";export{tabs}from"./kit/chunk-KLRF3S7O.js";export{imageGenerate}from"./kit/chunk-KDROJANO.js";export{fieldBackground}from"./kit/chunk-ILXVBO7M.js";export{wordmark}from"./kit/chunk-I5R2347P.js";export{asciiVideo}from"./kit/chunk-2LBQ7QJT.js";export{artPanel}from"./kit/chunk-XUCYFWC3.js";export{pricingGlow}from"./kit/chunk-42KMN727.js";import"./kit/chunk-7DXSG526.js";export{BEAM_PALETTES,beam,beamPalette}from"./kit/chunk-SDSW7422.js";export{decode}from"./kit/chunk-VV2KP7ZW.js";export{odometer}from"./kit/chunk-2FH6GGV6.js";export{buttonLoading}from"./kit/chunk-QVICL57J.js";export{statusOrb}from"./kit/chunk-KCEYRIU4.js";export{skeleton}from"./kit/chunk-H5KHXZWR.js";export{PILL_TONES,pill}from"./kit/chunk-WDS7VM2E.js";export{mountSurface,resolveColor}from"./kit/chunk-GF72XM4C.js";export{KIT_STYLES,getFieldBudget,getGlobalLook,setFieldBudget,setGlobalLook,subscribeGlobalLook}from"./kit/chunk-FEAFQY7O.js";//# sourceMappingURL=kit.js.map
1
+ export{silk}from"./kit/chunk-XZO4VH2Z.js";export{stars}from"./kit/chunk-XXHIFJ5Z.js";export{terrain}from"./kit/chunk-UWX7VIXT.js";export{veil}from"./kit/chunk-R3ALZFUQ.js";export{voidWell}from"./kit/chunk-4G5LJNMB.js";export{wave}from"./kit/chunk-F4IO3HWD.js";export{weave}from"./kit/chunk-P5MVACML.js";export{facet}from"./kit/chunk-UXDJSGED.js";export{fire}from"./kit/chunk-NS6HYTQZ.js";export{grid}from"./kit/chunk-OOVUQEXT.js";export{moire}from"./kit/chunk-XDX6WLED.js";export{morph}from"./kit/chunk-5Q634WWI.js";export{noise}from"./kit/chunk-V6KL3IA7.js";export{pulse}from"./kit/chunk-GJANKSX6.js";export{rain}from"./kit/chunk-7TXDNPL3.js";export{cascade}from"./kit/chunk-G3FVDS2A.js";export{constellation}from"./kit/chunk-6NDTKY3V.js";export{aurora}from"./kit/chunk-G7GQSPMC.js";export{halftone}from"./kit/chunk-3H3DJI3M.js";export{circuit}from"./kit/chunk-ZNZAO7JA.js";export{dna}from"./kit/chunk-X7AUCVMH.js";export{dune}from"./kit/chunk-NQ4PFWOG.js";export{etch}from"./kit/chunk-ZGCKUXYP.js";import"./kit/chunk-XPXMCXYI.js";import"./kit/chunk-ZCHGV2CV.js";export{mountCanvas}from"./kit/chunk-AAV5QNHU.js";export{wordField}from"./kit/chunk-EH4S6T7U.js";export{fluid}from"./kit/chunk-UT6MJP5B.js";export{caustics}from"./kit/chunk-2UOPVMN3.js";export{contour}from"./kit/chunk-MYAZOXMF.js";export{ripple}from"./kit/chunk-UXJRBOSR.js";export{halo}from"./kit/chunk-Y2SDQ6EC.js";export{interference}from"./kit/chunk-M5JJSIWI.js";export{mesh}from"./kit/chunk-VENDLTH4.js";export{compare}from"./kit/chunk-NP7UG7DS.js";export{accordion}from"./kit/chunk-4NR7QENR.js";export{dropzone}from"./kit/chunk-TJHSBZBF.js";export{disintegrate}from"./kit/chunk-N7J4UAWY.js";export{pullRefresh}from"./kit/chunk-CZL5WMU6.js";export{background,backgroundCharset}from"./kit/chunk-X6GAMLEH.js";export{swell}from"./kit/chunk-64NSPD2R.js";export{drift}from"./kit/chunk-7QH33RJJ.js";import"./kit/chunk-LTRVMY3D.js";export{morphField}from"./kit/chunk-AU33Y2SZ.js";export{ditherGradient}from"./kit/chunk-BV6AOHFU.js";export{ditherImage}from"./kit/chunk-GI5BNKBL.js";export{swipeDeck}from"./kit/chunk-UHLNVM63.js";export{codeInput}from"./kit/chunk-E427W6P5.js";export{toastStack}from"./kit/chunk-WPWCFCEZ.js";export{thinking}from"./kit/chunk-VQ4KIRBW.js";export{streamText}from"./kit/chunk-2NACMWVV.js";export{VOICE_PALETTES,voiceOrb}from"./kit/chunk-JF3WEYIE.js";export{commandPalette}from"./kit/chunk-PZKQUZQK.js";import"./kit/chunk-DKRZSP5K.js";export{slideToConfirm}from"./kit/chunk-FU4WW3PU.js";export{likeBurst}from"./kit/chunk-MWUPCAET.js";export{blockChart}from"./kit/chunk-NSKX2OFA.js";export{pageDissolve}from"./kit/chunk-CMGMCRAD.js";import"./kit/chunk-HENGH3DE.js";export{cursorTrail}from"./kit/chunk-BQ53B2HP.js";export{globe}from"./kit/chunk-SBAUVRBY.js";export{tabs}from"./kit/chunk-V42Q4L2G.js";export{imageGenerate}from"./kit/chunk-BJJUDT26.js";export{fieldBackground}from"./kit/chunk-MT23DCGU.js";export{wordmark}from"./kit/chunk-SQNULNT3.js";export{asciiVideo}from"./kit/chunk-BO4CPM26.js";export{artPanel}from"./kit/chunk-ZTCSVEHT.js";export{pricingGlow}from"./kit/chunk-XVA7UGUQ.js";import"./kit/chunk-RGV7VRYC.js";export{BEAM_PALETTES,beam,beamPalette}from"./kit/chunk-WSWIOD2C.js";export{SCRAMBLE_SCRIPTS,decode}from"./kit/chunk-IFZDWKIX.js";export{odometer}from"./kit/chunk-6G2ZVIBS.js";export{buttonLoading}from"./kit/chunk-CH64MY3U.js";export{statusOrb}from"./kit/chunk-BGPEFFKK.js";export{skeleton}from"./kit/chunk-WRBLIULG.js";export{PILL_TONES,pill}from"./kit/chunk-J7Y2KBXK.js";export{mountSurface,resolveColor}from"./kit/chunk-I377LEZA.js";export{KIT_STYLES,getFieldBudget,getGlobalLook,setFieldBudget,setGlobalLook,subscribeGlobalLook}from"./kit/chunk-FEAFQY7O.js";//# sourceMappingURL=kit.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "asciify-engine",
3
- "version": "4.29.0",
3
+ "version": "4.30.0",
4
4
  "description": "Framework-agnostic ASCII art engine. Convert images, videos, and GIFs into ASCII art rendered on canvas, or run full-bleed GPU character fields with a fluid cursor wake.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -2,13 +2,13 @@
2
2
  name: asciify-engine
3
3
  description: Apply Asciify the way asciify.org does - ASCII components and backgrounds that belong in a real interface, inked from the theme, clear around text, inside the page's radii and motion. Use for UI components in characters (loading, status, toasts, tabs, AI states, charts, transitions, pages), animated ASCII backgrounds, and also photo, video and GIF conversion, GPU character fields, artwork looks for wallpapers, posters and prints, art styles and export, hover and motion, layered typography and rendering performance.
4
4
  metadata:
5
- tested-engine: "4.29.0"
5
+ tested-engine: "4.30.0"
6
6
  updated: "2026-10-17"
7
7
  ---
8
8
 
9
9
  # Asciify Engine
10
10
 
11
- Use the published `asciify-engine` npm package. Tested against **4.29.0**. Check the application's installed version and its public types before using newer options; a local checkout can contain unpublished changes.
11
+ Use the published `asciify-engine` npm package. Tested against **4.30.0**. Check the application's installed version and its public types before using newer options; a local checkout can contain unpublished changes.
12
12
 
13
13
  - Agent entry: https://asciify.org/skill (redirects to this Markdown document).
14
14
  - Components: https://asciify.org/components · Looks: https://asciify.org/looks · Backgrounds: https://asciify.org/backgrounds
@@ -35,7 +35,7 @@ Most requests are a feeling ("make the loading state feel alive", "a calm backgr
35
35
 
36
36
  | The user wants | Use |
37
37
  | --- | --- |
38
- | A UI component in characters: button loading, status, toasts, tabs, pills, odometer, chart, AI thinking and streaming, transitions, sign-in, pricing, 404 | `asciify-engine/kit` ([applying-asciify.md](references/applying-asciify.md), [components.md](references/components.md), [kit.md](references/kit.md)) |
38
+ | A UI component in characters: button loading, status, toasts, tabs, pills, odometer, chart, AI thinking and streaming, transitions, sign-in, pricing, 404; event-site pieces (scrambling headers and headlines, morphing hatched heroes, dithered glows, a dotted globe, two-tone photos, assembling wordmarks, a spray cursor) | `asciify-engine/kit` ([applying-asciify.md](references/applying-asciify.md), [components.md](references/components.md), [kit.md](references/kit.md)) |
39
39
  | A background behind a hero, pricing, docs or a section, light or dark | Kit `fieldBackground(el, { preset: 'hero', clear })` (asciify.org's hero) or `background(el, { preset, clear })` with one of the 12 curated presets below |
40
40
  | Their word or brand in characters | Kit `wordmark`, or `background()` with `wordField` |
41
41
  | Their video in characters on the page | Kit `asciiVideo` |
@@ -49,7 +49,7 @@ Most requests are a feeling ("make the loading state feel alive", "a calm backgr
49
49
 
50
50
  ## The kit in one paragraph
51
51
 
52
- Each kit function mounts an `aria-hidden` field over or inside your element, follows its size and border radius, inks it from your theme in light and dark, pauses off screen, honours reduced motion, falls back without WebGL2 to an inert handle that leaves your HTML working, and cleans up on `destroy()`. components.md has 31 components as short snippets with the prompt a person gives, in categories Components, AI, Text, Transitions, Media, Pages and Backgrounds. In React, create the handle in an effect and return its `destroy`.
52
+ Each kit function mounts an `aria-hidden` field over or inside your element, follows its size and border radius, inks it from your theme in light and dark, pauses off screen, honours reduced motion, falls back without WebGL2 to an inert handle that leaves your HTML working, and cleans up on `destroy()`. components.md has 37 components as short snippets with the prompt a person gives, in categories Components, AI, Text, Transitions, Media, Pages and Backgrounds. In React, create the handle in an effect and return its `destroy`.
53
53
 
54
54
  ```ts
55
55
  import { beam } from 'asciify-engine/kit';
@@ -16,8 +16,9 @@ Pick by what the field does for the person, not by how it looks.
16
16
  | Move between states or views | `tabs`, `pageDissolve`, `commandPalette`, `toastStack`, `disintegrate` |
17
17
  | Answer a gesture | `likeBurst`, `swipeDeck`, `compare`, `accordion`, `dropzone` |
18
18
  | Follow the pointer across the page | `cursorTrail` (one per page, off on touch and under reduced motion) |
19
- | Carry a brand moment or media | `decode`, `wordmark`, `asciiVideo`, `artPanel`, `pricingGlow`, `fieldBackground` `notFound` |
20
- | Set the page's one ground | `fieldBackground` `hero`, or `background()` with a preset (section 9) |
19
+ | Carry a brand moment or media | `decode` (and its `scramble`), `wordmark` (and its `assemble`), `morphField`, `ditherImage`, `asciiVideo`, `artPanel`, `pricingGlow`, `fieldBackground` `notFound` |
20
+ | Show where: places, reach, a network | `globe` with `points` |
21
+ | Set the page's one ground | `fieldBackground` `hero`, `ditherGradient`, or `background()` with a preset (section 9) |
21
22
 
22
23
  Do not use characters:
23
24
 
@@ -219,6 +220,21 @@ const bg = background(hero, { preset: drift, clear: heroCopy, poster: '/stills/d
219
220
  signUpButton.addEventListener('click', () => bg.field?.pulse({ element: signUpButton, strength: 1.2 })); // GPU presets expose the field
220
221
  ```
221
222
 
223
+ ## 9b. Event and launch pages
224
+
225
+ A conference, launch or campaign page can carry more character than a product page, but the same rules hold: one key visual a section, real HTML for every headline and link, and motion that answers the visitor.
226
+
227
+ | Section | Piece | Keep it |
228
+ | --- | --- | --- |
229
+ | Header | `decode(link, { scramble: true, trigger: 'manual', settle: 'text' })` on each nav link | Links rest as plain HTML and only scramble on hover; `cellSize` about 3 so letters stay crisp. |
230
+ | Hero | `morphField` of your own frames (`mark: 'engraving'` lines, white ink on the brand ground) and `decode(h1, { scramble: true, settle: 'text' })` | One morph per hero; a counter or caption through `onChange`; a poster per theme. |
231
+ | Ambient pointer | `cursorTrail({ style: 'spray', readout: true, zIndex: -1 })` | A background hover: behind cards, off on touch and under reduced motion. |
232
+ | Proof sections | `globe` for venues or reach, `ditherImage` for photos in the brand's two tones, `background(el, { preset: wordField, look: { glyphOrder: 'text', … } })` for repeated words | `globe` and `wordField` are section grounds; keep copy off their middle or `clear` it. |
233
+ | Call to action | `ditherGradient` on the brand-coloured panel | Light from an edge, the button over the quiet part. |
234
+ | Footer | `wordmark(mark, { assemble: 'scroll', look: { hover: 'none' } })` | The page trail draws over it; nothing else moves in the footer. |
235
+
236
+ Brand colour as the ground: give the section the brand background and draw in white or a light tint of it (`ink: '#fff'` or a token); on a white section draw in the brand token. Check contrast of the HTML over the busiest frame of the morph.
237
+
222
238
  ## 10. Checklist before you finish
223
239
 
224
240
  - [ ] Every field has a job from section 1; hiding it loses feedback, or it is the page's one ground.