jssm 5.149.2 → 5.150.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.
- package/README.md +7 -7
- package/custom-elements.json +261 -11
- package/dist/cdn/instance.js +929 -443
- package/dist/cdn/viz.js +761 -332
- 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/cm6/fsl_language.js +3 -1
- package/dist/deno/README.md +7 -7
- package/dist/deno/jssm.d.ts +14 -2
- package/dist/deno/jssm.js +1 -1
- package/dist/deno/jssm_types.d.ts +11 -1
- 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/instance.js +88 -31
- package/dist/wc/widgets.js +137 -18
- package/jssm.es5.d.cts +23 -1
- package/jssm.es6.d.ts +23 -1
- package/jssm_viz.es5.d.cts +23 -1
- package/jssm_viz.es6.d.ts +23 -1
- package/package.json +1 -1
package/jssm_viz.es5.d.cts
CHANGED
|
@@ -510,6 +510,15 @@ declare type JssmBaseTheme = {
|
|
|
510
510
|
* @typeParam StateType - The state-name type (usually `string`).
|
|
511
511
|
* @typeParam DataType - The user-supplied data payload type (`mDT`).
|
|
512
512
|
*/
|
|
513
|
+
/**
|
|
514
|
+
* Editor/panel defaults an FSL machine declares in an `editor: {}` block
|
|
515
|
+
* (fsl#1334), read by the all-widgets web control: a stochastic run-count
|
|
516
|
+
* and the panels the machine requests under `request` panel mode.
|
|
517
|
+
*/
|
|
518
|
+
declare type JssmEditorConfig = {
|
|
519
|
+
stochastic_run_count?: number;
|
|
520
|
+
panels?: Array<string>;
|
|
521
|
+
};
|
|
513
522
|
declare type JssmGenericConfig<StateType, DataType> = {
|
|
514
523
|
graph_layout?: JssmLayout;
|
|
515
524
|
complete?: Array<StateType>;
|
|
@@ -539,6 +548,7 @@ declare type JssmGenericConfig<StateType, DataType> = {
|
|
|
539
548
|
min_exits?: number;
|
|
540
549
|
max_exits?: number;
|
|
541
550
|
allow_islands?: JssmAllowIslands;
|
|
551
|
+
editor_config?: JssmEditorConfig;
|
|
542
552
|
allow_force?: false;
|
|
543
553
|
actions?: JssmPermittedOpt;
|
|
544
554
|
simplify_bidi?: boolean;
|
|
@@ -1291,6 +1301,7 @@ declare class Machine<mDT> {
|
|
|
1291
1301
|
_code_allows_override: JssmAllowsOverride;
|
|
1292
1302
|
_config_allows_override: JssmAllowsOverride;
|
|
1293
1303
|
_allow_islands: JssmAllowIslands;
|
|
1304
|
+
_editor_config?: JssmEditorConfig;
|
|
1294
1305
|
_post_hooks: Map<number, HookHandler<mDT>>;
|
|
1295
1306
|
_post_named_hooks: Map<number, Map<number, HookHandler<mDT>>>;
|
|
1296
1307
|
_post_entry_hooks: Map<number, HookHandler<mDT>>;
|
|
@@ -1340,7 +1351,7 @@ declare class Machine<mDT> {
|
|
|
1340
1351
|
_firing_error: boolean;
|
|
1341
1352
|
_boundary_depth: number;
|
|
1342
1353
|
_boundary_depth_limit: number;
|
|
1343
|
-
constructor({ start_states, end_states, failed_outputs, initial_state, start_states_no_enforce, complete, transitions, machine_author, machine_comment, machine_contributor, machine_definition, machine_language, machine_license, machine_name, machine_version, npm_name, default_size, state_declaration, property_definition, state_property, fsl_version, dot_preamble, arrange_declaration, arrange_start_declaration, arrange_end_declaration, theme, flow, graph_layout, instance_name, history, boundary_depth_limit, data, default_state_config, default_active_state_config, default_hooked_state_config, default_terminal_state_config, default_start_state_config, default_end_state_config, default_transition_config, default_graph_config, group_registry, group_metadata, group_hooks, state_hooks, allows_override, config_allows_override, allow_islands, rng_seed, time_source, timeout_source, clear_timeout_source }: JssmGenericConfig<StateType, mDT>);
|
|
1354
|
+
constructor({ start_states, end_states, failed_outputs, initial_state, start_states_no_enforce, complete, transitions, machine_author, machine_comment, machine_contributor, machine_definition, machine_language, machine_license, machine_name, machine_version, npm_name, default_size, state_declaration, property_definition, state_property, fsl_version, dot_preamble, arrange_declaration, arrange_start_declaration, arrange_end_declaration, theme, flow, graph_layout, instance_name, history, boundary_depth_limit, data, default_state_config, default_active_state_config, default_hooked_state_config, default_terminal_state_config, default_start_state_config, default_end_state_config, default_transition_config, default_graph_config, group_registry, group_metadata, group_hooks, state_hooks, allows_override, config_allows_override, allow_islands, editor_config, rng_seed, time_source, timeout_source, clear_timeout_source }: JssmGenericConfig<StateType, mDT>);
|
|
1344
1355
|
/********
|
|
1345
1356
|
*
|
|
1346
1357
|
* Internal method for fabricating states. Not meant for external use.
|
|
@@ -1768,6 +1779,17 @@ declare class Machine<mDT> {
|
|
|
1768
1779
|
* @returns The machine name string.
|
|
1769
1780
|
*/
|
|
1770
1781
|
machine_name(): string;
|
|
1782
|
+
/** The editor/panel defaults declared in the FSL `editor: {}` block, or
|
|
1783
|
+
* `undefined` when none was given. Read by the all-widgets web control
|
|
1784
|
+
* (fsl#1334) — `panels` drives `request` panel mode.
|
|
1785
|
+
*
|
|
1786
|
+
* @returns `{ stochastic_run_count?, panels? }`, or `undefined`.
|
|
1787
|
+
*
|
|
1788
|
+
* @example
|
|
1789
|
+
* const m = sm`editor: { panels: [history]; }; a -> b;`;
|
|
1790
|
+
* m.editor_config(); // => { panels: ['history'] }
|
|
1791
|
+
*/
|
|
1792
|
+
editor_config(): JssmEditorConfig | undefined;
|
|
1771
1793
|
/** Get the npm package name associated with the machine. Set via the FSL `npm_name` directive.
|
|
1772
1794
|
* Returns `undefined` when not present.
|
|
1773
1795
|
* @returns The npm package name string, or `undefined`.
|
package/jssm_viz.es6.d.ts
CHANGED
|
@@ -510,6 +510,15 @@ declare type JssmBaseTheme = {
|
|
|
510
510
|
* @typeParam StateType - The state-name type (usually `string`).
|
|
511
511
|
* @typeParam DataType - The user-supplied data payload type (`mDT`).
|
|
512
512
|
*/
|
|
513
|
+
/**
|
|
514
|
+
* Editor/panel defaults an FSL machine declares in an `editor: {}` block
|
|
515
|
+
* (fsl#1334), read by the all-widgets web control: a stochastic run-count
|
|
516
|
+
* and the panels the machine requests under `request` panel mode.
|
|
517
|
+
*/
|
|
518
|
+
declare type JssmEditorConfig = {
|
|
519
|
+
stochastic_run_count?: number;
|
|
520
|
+
panels?: Array<string>;
|
|
521
|
+
};
|
|
513
522
|
declare type JssmGenericConfig<StateType, DataType> = {
|
|
514
523
|
graph_layout?: JssmLayout;
|
|
515
524
|
complete?: Array<StateType>;
|
|
@@ -539,6 +548,7 @@ declare type JssmGenericConfig<StateType, DataType> = {
|
|
|
539
548
|
min_exits?: number;
|
|
540
549
|
max_exits?: number;
|
|
541
550
|
allow_islands?: JssmAllowIslands;
|
|
551
|
+
editor_config?: JssmEditorConfig;
|
|
542
552
|
allow_force?: false;
|
|
543
553
|
actions?: JssmPermittedOpt;
|
|
544
554
|
simplify_bidi?: boolean;
|
|
@@ -1291,6 +1301,7 @@ declare class Machine<mDT> {
|
|
|
1291
1301
|
_code_allows_override: JssmAllowsOverride;
|
|
1292
1302
|
_config_allows_override: JssmAllowsOverride;
|
|
1293
1303
|
_allow_islands: JssmAllowIslands;
|
|
1304
|
+
_editor_config?: JssmEditorConfig;
|
|
1294
1305
|
_post_hooks: Map<number, HookHandler<mDT>>;
|
|
1295
1306
|
_post_named_hooks: Map<number, Map<number, HookHandler<mDT>>>;
|
|
1296
1307
|
_post_entry_hooks: Map<number, HookHandler<mDT>>;
|
|
@@ -1340,7 +1351,7 @@ declare class Machine<mDT> {
|
|
|
1340
1351
|
_firing_error: boolean;
|
|
1341
1352
|
_boundary_depth: number;
|
|
1342
1353
|
_boundary_depth_limit: number;
|
|
1343
|
-
constructor({ start_states, end_states, failed_outputs, initial_state, start_states_no_enforce, complete, transitions, machine_author, machine_comment, machine_contributor, machine_definition, machine_language, machine_license, machine_name, machine_version, npm_name, default_size, state_declaration, property_definition, state_property, fsl_version, dot_preamble, arrange_declaration, arrange_start_declaration, arrange_end_declaration, theme, flow, graph_layout, instance_name, history, boundary_depth_limit, data, default_state_config, default_active_state_config, default_hooked_state_config, default_terminal_state_config, default_start_state_config, default_end_state_config, default_transition_config, default_graph_config, group_registry, group_metadata, group_hooks, state_hooks, allows_override, config_allows_override, allow_islands, rng_seed, time_source, timeout_source, clear_timeout_source }: JssmGenericConfig<StateType, mDT>);
|
|
1354
|
+
constructor({ start_states, end_states, failed_outputs, initial_state, start_states_no_enforce, complete, transitions, machine_author, machine_comment, machine_contributor, machine_definition, machine_language, machine_license, machine_name, machine_version, npm_name, default_size, state_declaration, property_definition, state_property, fsl_version, dot_preamble, arrange_declaration, arrange_start_declaration, arrange_end_declaration, theme, flow, graph_layout, instance_name, history, boundary_depth_limit, data, default_state_config, default_active_state_config, default_hooked_state_config, default_terminal_state_config, default_start_state_config, default_end_state_config, default_transition_config, default_graph_config, group_registry, group_metadata, group_hooks, state_hooks, allows_override, config_allows_override, allow_islands, editor_config, rng_seed, time_source, timeout_source, clear_timeout_source }: JssmGenericConfig<StateType, mDT>);
|
|
1344
1355
|
/********
|
|
1345
1356
|
*
|
|
1346
1357
|
* Internal method for fabricating states. Not meant for external use.
|
|
@@ -1768,6 +1779,17 @@ declare class Machine<mDT> {
|
|
|
1768
1779
|
* @returns The machine name string.
|
|
1769
1780
|
*/
|
|
1770
1781
|
machine_name(): string;
|
|
1782
|
+
/** The editor/panel defaults declared in the FSL `editor: {}` block, or
|
|
1783
|
+
* `undefined` when none was given. Read by the all-widgets web control
|
|
1784
|
+
* (fsl#1334) — `panels` drives `request` panel mode.
|
|
1785
|
+
*
|
|
1786
|
+
* @returns `{ stochastic_run_count?, panels? }`, or `undefined`.
|
|
1787
|
+
*
|
|
1788
|
+
* @example
|
|
1789
|
+
* const m = sm`editor: { panels: [history]; }; a -> b;`;
|
|
1790
|
+
* m.editor_config(); // => { panels: ['history'] }
|
|
1791
|
+
*/
|
|
1792
|
+
editor_config(): JssmEditorConfig | undefined;
|
|
1771
1793
|
/** Get the npm package name associated with the machine. Set via the FSL `npm_name` directive.
|
|
1772
1794
|
* Returns `undefined` when not present.
|
|
1773
1795
|
* @returns The npm package name string, or `undefined`.
|