jssm 5.162.12 → 5.162.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -7
- package/custom-elements.json +14 -1
- package/dist/cdn/instance.js +1 -1
- package/dist/cdn/viz.js +17 -1
- package/dist/cli/fsl-export-system-prompt.cjs +1 -1
- package/dist/cli/fsl-render.cjs +1 -1
- package/dist/cli/fsl.cjs +1 -1
- package/dist/cli/lib.cjs +1 -1
- package/dist/cli/lib.mjs +1 -1
- package/dist/deno/README.md +8 -7
- package/dist/deno/fsl_markdown_fence.d.ts +20 -3
- package/dist/deno/jssm.d.ts +1 -0
- package/dist/deno/jssm.js +1 -1
- package/dist/deno/jssm_compiler.d.ts +21 -4
- package/dist/deno/jssm_types.d.ts +27 -1
- package/dist/deno/jssm_viz.d.ts +66 -9
- package/dist/fence/fence.js +56 -20
- package/dist/jssm.es5.cjs +1 -1
- package/dist/jssm.es5.iife.js +1 -1
- package/dist/jssm.es6.mjs +1 -1
- package/dist/jssm_viz.cjs +1 -1
- package/dist/jssm_viz.iife.cjs +1 -1
- package/dist/jssm_viz.mjs +1 -1
- package/dist/wc/viz.js +54 -9
- package/dist/wc/widgets.define.js +4 -2
- package/dist/wc/widgets.js +196 -43
- package/jssm.es5.d.cts +67 -7
- package/jssm.es6.d.ts +67 -7
- package/jssm_viz.es5.d.cts +66 -9
- package/jssm_viz.es6.d.ts +66 -9
- package/package.json +2 -1
package/dist/deno/README.md
CHANGED
|
@@ -18,10 +18,10 @@ Please edit the file it's derived from, instead: `./src/md/readme_base.md`
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
21
|
-
* Generated for version 5.162.
|
|
21
|
+
* Generated for version 5.162.13 at 7/12/2026, 12:27:54 PM
|
|
22
22
|
|
|
23
23
|
-->
|
|
24
|
-
# jssm 5.162.
|
|
24
|
+
# jssm 5.162.13
|
|
25
25
|
|
|
26
26
|
[**Try the live editor**](https://stonecypher.github.io/jssm-viz-demo/graph_explorer.html) ·
|
|
27
27
|
[Documentation](https://stonecypher.github.io/jssm/docs/) ·
|
|
@@ -333,7 +333,7 @@ That decision shows up everywhere downstream:
|
|
|
333
333
|
or run `npm run benny` against your own machine.
|
|
334
334
|
|
|
335
335
|
- **More thoroughly tested than any other JavaScript state-machine
|
|
336
|
-
library.** 8,
|
|
336
|
+
library.** 8,681 tests at 100.0% line coverage
|
|
337
337
|
([report](https://coveralls.io/github/StoneCypher/jssm)), plus
|
|
338
338
|
fuzz testing via `fast-check`, with parser test data across ten natural
|
|
339
339
|
languages and Emoji.
|
|
@@ -350,6 +350,7 @@ That decision shows up everywhere downstream:
|
|
|
350
350
|
- [Tutorial: a four-state traffic light](https://github.com/StoneCypher/jssm/blob/main/src/doc_md/Tutorial_TrafficLight.md) - short walkthrough that introduces the three arrow types
|
|
351
351
|
- [Tutorial: building an ATM state machine](https://github.com/StoneCypher/jssm/blob/main/src/doc_md/Tutorial_ATM.md) - longer walkthrough that builds a real-world machine in nine incremental steps
|
|
352
352
|
- [Language reference](https://github.com/StoneCypher/jssm/blob/main/src/doc_md/LanguageReference.md) - DSL reference for people already comfortable with state machines
|
|
353
|
+
- [Styling nodes and graphs](https://github.com/StoneCypher/jssm/blob/main/src/doc_md/Styling.md) - the built-in named color themes and how to select them from FSL source, code, Markdown fences, the CLI, and web components
|
|
353
354
|
- [Catalog of example machines](https://github.com/StoneCypher/jssm/blob/main/src/doc_md/ExampleMachines.md) - comparison table of worked examples (light switch, traffic light, intersection, vending machine, more)
|
|
354
355
|
- [Generated API reference](https://stonecypher.github.io/jssm/docs/) - full surface, generated from the TypeScript source
|
|
355
356
|
|
|
@@ -467,11 +468,11 @@ If your contribution is missing here, please open an issue.
|
|
|
467
468
|
|
|
468
469
|
<br/>
|
|
469
470
|
|
|
470
|
-
***8,
|
|
471
|
+
***8,681 tests***, run 98,078 times.
|
|
471
472
|
|
|
472
|
-
- 7,
|
|
473
|
-
- 903 fuzz tests with 56.
|
|
474
|
-
-
|
|
473
|
+
- 7,778 specs with 100.0% coverage
|
|
474
|
+
- 903 fuzz tests with 56.3% coverage
|
|
475
|
+
- 11,033 TypeScript lines - 0.8 tests per line, 8.9 generated tests per line
|
|
475
476
|
|
|
476
477
|
[](https://github.com/StoneCypher/jssm/actions)
|
|
477
478
|
[](https://www.npmjs.com/package/jssm)
|
|
@@ -16,13 +16,25 @@ export interface FenceDimension {
|
|
|
16
16
|
value: number;
|
|
17
17
|
unit: FenceDimensionUnit;
|
|
18
18
|
}
|
|
19
|
-
/**
|
|
19
|
+
/**
|
|
20
|
+
* The fully-parsed, validated description of one FSL Markdown fence block.
|
|
21
|
+
*
|
|
22
|
+
* Sizing semantics: `width`/`height` (from `width=`/`height=` tokens) are
|
|
23
|
+
* *exact* dimensions — the host renders the block at that size.
|
|
24
|
+
* `max_width`/`max_height` (from `max-width=`/`max-height=` tokens) are
|
|
25
|
+
* *upper bounds* on natural sizing — the block renders at its natural size
|
|
26
|
+
* but is capped on that axis. When both an exact and a max token are given
|
|
27
|
+
* for the same axis, the exact dimension wins and the cap is moot. All four
|
|
28
|
+
* are `null` when their token is absent.
|
|
29
|
+
*/
|
|
20
30
|
export interface FenceDescriptor {
|
|
21
31
|
parts: FencePart[];
|
|
22
32
|
ide: boolean;
|
|
23
33
|
format: FenceImageFormat;
|
|
24
34
|
width: FenceDimension | null;
|
|
25
35
|
height: FenceDimension | null;
|
|
36
|
+
max_width: FenceDimension | null;
|
|
37
|
+
max_height: FenceDimension | null;
|
|
26
38
|
interactive: boolean;
|
|
27
39
|
notes: string[];
|
|
28
40
|
}
|
|
@@ -40,12 +52,17 @@ export declare function fsl_fence_lang(info: string): 'fsl' | 'jssm' | null;
|
|
|
40
52
|
/**
|
|
41
53
|
* Parse a fence info string into a {@link FenceDescriptor}. The first token is
|
|
42
54
|
* the (already-validated) language and is ignored; remaining tokens are
|
|
43
|
-
* classified as parts, image formats, the `ide` macro, or
|
|
44
|
-
* options
|
|
55
|
+
* classified as parts, image formats, the `ide` macro, or the dimension
|
|
56
|
+
* options `width`/`height` (exact size) and `max-width`/`max-height`
|
|
57
|
+
* (upper bounds on natural size — see {@link FenceDescriptor} for the
|
|
58
|
+
* precedence rule when both appear on one axis). All four dimension tokens
|
|
59
|
+
* share one value syntax: a bare number (pixels), `<n>px`, or `<n>%`.
|
|
60
|
+
* Unrecognized or conflicting tokens are dropped and recorded in
|
|
45
61
|
* `notes` rather than throwing, so a host can render forward-compatibly.
|
|
46
62
|
* @param info The full fence info string, e.g. `'fsl image code width=300'`.
|
|
47
63
|
* @returns The validated descriptor; `notes` lists anything ignored or overridden.
|
|
48
64
|
* @example parse_fence_info('fsl').parts // => ['image', 'code']
|
|
49
65
|
* @example parse_fence_info('fsl code image').parts // => ['code', 'image']
|
|
66
|
+
* @example parse_fence_info('fsl image max-width=300 max-height=50%').max_width // => { value: 300, unit: 'px' }
|
|
50
67
|
*/
|
|
51
68
|
export declare function parse_fence_info(info: string): FenceDescriptor;
|
package/dist/deno/jssm.d.ts
CHANGED
|
@@ -2767,6 +2767,7 @@ export { transfer_state_properties, Machine, deserialize, compareVersions, sm, f
|
|
|
2767
2767
|
export { fsl_fence_lang, parse_fence_info } from './fsl_markdown_fence';
|
|
2768
2768
|
export type { FencePart, FenceImageFormat, FenceDimensionUnit, FenceDimension, FenceDescriptor } from './fsl_markdown_fence';
|
|
2769
2769
|
export { FslDirections } from './jssm_types.js';
|
|
2770
|
+
export type { JssmParseOptions } from './jssm_types.js';
|
|
2770
2771
|
export { arrow_direction, arrow_left_kind, arrow_right_kind } from './jssm_arrow.js';
|
|
2771
2772
|
export { compile, wrap_parse as parse, make } from './jssm_compiler.js';
|
|
2772
2773
|
export { unique, find_repeated, weighted_sample_select, weighted_histo_key, sleep, seq, weighted_rand_select, histograph, gen_splitmix32 } from './jssm_util.js';
|