@almadar/patterns 2.12.2 → 2.14.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/dist/component-mapping.json +16 -1
- package/dist/event-contracts.json +8 -1
- package/dist/index.d.ts +261 -0
- package/dist/index.js +214 -8
- package/dist/index.js.map +1 -1
- package/dist/patterns-registry.json +190 -6
- package/dist/registry.json +190 -6
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// src/patterns-registry.json
|
|
2
2
|
var patterns_registry_default = {
|
|
3
3
|
version: "1.0.0",
|
|
4
|
-
exportedAt: "2026-04-
|
|
4
|
+
exportedAt: "2026-04-18T11:44:35.778Z",
|
|
5
5
|
patterns: {
|
|
6
6
|
"entity-table": {
|
|
7
7
|
type: "entity-table",
|
|
@@ -103,7 +103,8 @@ var patterns_registry_default = {
|
|
|
103
103
|
types: [
|
|
104
104
|
"array"
|
|
105
105
|
],
|
|
106
|
-
|
|
106
|
+
itemKind: "field-ref",
|
|
107
|
+
description: "Columns can be Column objects or simple string field names. String elements must resolve to fields on the linked entity."
|
|
107
108
|
},
|
|
108
109
|
itemActions: {
|
|
109
110
|
types: [
|
|
@@ -497,7 +498,8 @@ var patterns_registry_default = {
|
|
|
497
498
|
types: [
|
|
498
499
|
"string"
|
|
499
500
|
],
|
|
500
|
-
|
|
501
|
+
kind: "field-ref",
|
|
502
|
+
description: "Entity field name containing an image URL to display as card thumbnail. Must resolve to a field on the linked entity."
|
|
501
503
|
}
|
|
502
504
|
}
|
|
503
505
|
},
|
|
@@ -1283,7 +1285,8 @@ var patterns_registry_default = {
|
|
|
1283
1285
|
types: [
|
|
1284
1286
|
"array"
|
|
1285
1287
|
],
|
|
1286
|
-
|
|
1288
|
+
itemKind: "field-ref",
|
|
1289
|
+
description: "Filter definitions from schema. String elements must resolve to fields on the linked entity.",
|
|
1287
1290
|
required: true
|
|
1288
1291
|
},
|
|
1289
1292
|
onFilterChange: {
|
|
@@ -10645,6 +10648,24 @@ var patterns_registry_default = {
|
|
|
10645
10648
|
"string"
|
|
10646
10649
|
],
|
|
10647
10650
|
description: "Additional CSS classes"
|
|
10651
|
+
},
|
|
10652
|
+
editable: {
|
|
10653
|
+
types: [
|
|
10654
|
+
"boolean"
|
|
10655
|
+
],
|
|
10656
|
+
description: "When true, render an editable surface that composes a transparent `Textarea` over a Prism-highlighted overlay. The overlay re-tokenizes on each keystroke (driven from a local mirror of the textarea value), so users see syntax-highlighted code while still being able to type. Folding is skipped in editable mode. History: GAP-51 first-cut shipped plain (no-highlighting) editable text; GAP-77 (2026-04-12) added the Prism overlay layer. Default: false (existing read-only behavior unchanged)."
|
|
10657
|
+
},
|
|
10658
|
+
onChange: {
|
|
10659
|
+
types: [
|
|
10660
|
+
"function"
|
|
10661
|
+
],
|
|
10662
|
+
description: "GAP-51: called with the new code on every keystroke when `editable === true`. Consumers should debounce + parse downstream \u2014 `CodeBlock` does not."
|
|
10663
|
+
},
|
|
10664
|
+
errorLines: {
|
|
10665
|
+
types: [
|
|
10666
|
+
"object"
|
|
10667
|
+
],
|
|
10668
|
+
description: "GAP-80: line-level error/warning highlights for editable mode. Map of 1-based line number \u2192 severity. The overlay paints a colored background on each line: error = red, warning = yellow. Pass undefined (default) to disable. The consumer is responsible for computing the path \u2192 line map from the schema + validation results."
|
|
10648
10669
|
}
|
|
10649
10670
|
}
|
|
10650
10671
|
},
|
|
@@ -13185,7 +13206,8 @@ var patterns_registry_default = {
|
|
|
13185
13206
|
types: [
|
|
13186
13207
|
"string"
|
|
13187
13208
|
],
|
|
13188
|
-
|
|
13209
|
+
kind: "field-ref",
|
|
13210
|
+
description: "Entity field name containing an image URL for card thumbnails. Must resolve to a field on the linked entity."
|
|
13189
13211
|
},
|
|
13190
13212
|
selectable: {
|
|
13191
13213
|
types: [
|
|
@@ -13291,7 +13313,8 @@ var patterns_registry_default = {
|
|
|
13291
13313
|
types: [
|
|
13292
13314
|
"string"
|
|
13293
13315
|
],
|
|
13294
|
-
|
|
13316
|
+
kind: "field-ref",
|
|
13317
|
+
description: "Group items by a field value (renders section headers between groups). Must resolve to a field on the linked entity."
|
|
13295
13318
|
},
|
|
13296
13319
|
senderField: {
|
|
13297
13320
|
types: [
|
|
@@ -20578,6 +20601,18 @@ var patterns_registry_default = {
|
|
|
20578
20601
|
],
|
|
20579
20602
|
description: "onLevelChange prop"
|
|
20580
20603
|
},
|
|
20604
|
+
onOrbitalDoubleClick: {
|
|
20605
|
+
types: [
|
|
20606
|
+
"function"
|
|
20607
|
+
],
|
|
20608
|
+
description: "GAP-52: fired when the user double-clicks an orbital. Consumers (e.g. the builder workspace) use this as the trigger to enter cosmic mode (`AvlOrbitalsCosmicZoom`) for the focused orbital. The level at which this fires is controlled by `cosmicEntryLevel` (default `'expanded'`). At `'expanded'` the existing overview\u2192expanded drill is preserved \u2014 the callback fires only on the second double-click. At `'overview'` the callback fires on the FIRST double-click and the existing drill is suppressed for that interaction. `'both'` fires at either level. The callback runs unconditionally \u2014 persona / permission gating is the consumer's responsibility."
|
|
20609
|
+
},
|
|
20610
|
+
cosmicEntryLevel: {
|
|
20611
|
+
types: [
|
|
20612
|
+
"string"
|
|
20613
|
+
],
|
|
20614
|
+
description: "GAP-53: which level the `onOrbitalDoubleClick` callback fires at. - `'expanded'` (default, non-breaking) \u2014 fires only at L2 expanded; the first overview double-click still drills overview\u2192expanded. - `'overview'` \u2014 fires at L1 overview on the FIRST double-click. The overview\u2192expanded drill is suppressed when the callback is provided. - `'both'` \u2014 fires at either level."
|
|
20615
|
+
},
|
|
20581
20616
|
initialOrbital: {
|
|
20582
20617
|
types: [
|
|
20583
20618
|
"string"
|
|
@@ -22790,6 +22825,155 @@ var patterns_registry_default = {
|
|
|
22790
22825
|
}
|
|
22791
22826
|
}
|
|
22792
22827
|
},
|
|
22828
|
+
"trait-frame": {
|
|
22829
|
+
type: "trait-frame",
|
|
22830
|
+
category: "component",
|
|
22831
|
+
description: "TraitFrame \u2014 renders the current frame of a referenced trait. Resolves the `@trait.X[.slot]` binding at render time by looking up the referenced trait's last `render-ui` payload from the orbital's `UISlotManager`. Re-renders automatically when that trait transitions via the per-trait subscription channel (`subscribeTrait`). This is the single rendering primitive both runtime paths converge on: - **Interpreted path** \u2014 the trait-binding resolver in `renderer/trait-binding-resolver.ts` walks pattern trees at render time, substituting `\"@trait.X\"` string children with this component. - **Compiled path** \u2014 the TypeScript shell codegen in `orbital-shell-typescript/src/backend.rs::pattern_to_jsx_with_data` emits this component directly into generated JSX wherever a `@trait.*` string appears in a pattern tree. Embedding is passive: the referenced trait's state machine runs unchanged; TraitFrame is only a read-only lens on its current frame. Event propagation happens over the shared event bus, not through this component.",
|
|
22832
|
+
suggestedFor: [
|
|
22833
|
+
"trait",
|
|
22834
|
+
"frame",
|
|
22835
|
+
"trait frame"
|
|
22836
|
+
],
|
|
22837
|
+
typicalSize: "small",
|
|
22838
|
+
propsSchema: {
|
|
22839
|
+
traitName: {
|
|
22840
|
+
types: [
|
|
22841
|
+
"string"
|
|
22842
|
+
],
|
|
22843
|
+
description: "Name of the trait whose current frame to embed. Must match a trait declared in the current orbital. Compiler validates that the name exists at build time (see `ORB_BINDING_TRAIT_UNKNOWN`).",
|
|
22844
|
+
required: true
|
|
22845
|
+
},
|
|
22846
|
+
fallback: {
|
|
22847
|
+
types: [
|
|
22848
|
+
"node"
|
|
22849
|
+
],
|
|
22850
|
+
description: "Rendered when the referenced trait has not (yet) emitted any render-ui. Use a skeleton, spinner, or message. Defaults to `null` (renders nothing), so an unfulfilled reference drops cleanly out of a parent `children:` array."
|
|
22851
|
+
}
|
|
22852
|
+
}
|
|
22853
|
+
},
|
|
22854
|
+
"file-tree": {
|
|
22855
|
+
type: "file-tree",
|
|
22856
|
+
category: "component",
|
|
22857
|
+
description: "FileTree component",
|
|
22858
|
+
suggestedFor: [
|
|
22859
|
+
"file",
|
|
22860
|
+
"tree",
|
|
22861
|
+
"file tree"
|
|
22862
|
+
],
|
|
22863
|
+
typicalSize: "medium",
|
|
22864
|
+
propsSchema: {
|
|
22865
|
+
tree: {
|
|
22866
|
+
types: [
|
|
22867
|
+
"array"
|
|
22868
|
+
],
|
|
22869
|
+
description: "The tree data",
|
|
22870
|
+
required: true
|
|
22871
|
+
},
|
|
22872
|
+
selectedPath: {
|
|
22873
|
+
types: [
|
|
22874
|
+
"string"
|
|
22875
|
+
],
|
|
22876
|
+
description: "Currently selected file path"
|
|
22877
|
+
},
|
|
22878
|
+
onFileSelect: {
|
|
22879
|
+
types: [
|
|
22880
|
+
"function"
|
|
22881
|
+
],
|
|
22882
|
+
description: "Called when a file is clicked"
|
|
22883
|
+
},
|
|
22884
|
+
className: {
|
|
22885
|
+
types: [
|
|
22886
|
+
"string"
|
|
22887
|
+
],
|
|
22888
|
+
description: "CSS class"
|
|
22889
|
+
},
|
|
22890
|
+
indent: {
|
|
22891
|
+
types: [
|
|
22892
|
+
"number"
|
|
22893
|
+
],
|
|
22894
|
+
description: "Indent size per level in px (default: 16)"
|
|
22895
|
+
}
|
|
22896
|
+
}
|
|
22897
|
+
},
|
|
22898
|
+
"avl-orbitals-cosmic-zoom": {
|
|
22899
|
+
type: "avl-orbitals-cosmic-zoom",
|
|
22900
|
+
category: "display",
|
|
22901
|
+
description: "AvlOrbitalsCosmicZoom component",
|
|
22902
|
+
suggestedFor: [
|
|
22903
|
+
"avl",
|
|
22904
|
+
"orbitals",
|
|
22905
|
+
"cosmic",
|
|
22906
|
+
"zoom",
|
|
22907
|
+
"avl orbitals cosmic zoom"
|
|
22908
|
+
],
|
|
22909
|
+
typicalSize: "large",
|
|
22910
|
+
propsSchema: {
|
|
22911
|
+
schema: {
|
|
22912
|
+
types: [
|
|
22913
|
+
"object",
|
|
22914
|
+
"string"
|
|
22915
|
+
],
|
|
22916
|
+
description: "The orbital schema (parsed object or JSON string)",
|
|
22917
|
+
required: true
|
|
22918
|
+
},
|
|
22919
|
+
className: {
|
|
22920
|
+
types: [
|
|
22921
|
+
"string"
|
|
22922
|
+
],
|
|
22923
|
+
description: "CSS class for the outer container"
|
|
22924
|
+
},
|
|
22925
|
+
color: {
|
|
22926
|
+
types: [
|
|
22927
|
+
"string"
|
|
22928
|
+
],
|
|
22929
|
+
description: "Primary color for the visualization"
|
|
22930
|
+
},
|
|
22931
|
+
animated: {
|
|
22932
|
+
types: [
|
|
22933
|
+
"boolean"
|
|
22934
|
+
],
|
|
22935
|
+
description: "Enable animations (default: true)"
|
|
22936
|
+
},
|
|
22937
|
+
width: {
|
|
22938
|
+
types: [
|
|
22939
|
+
"number",
|
|
22940
|
+
"string"
|
|
22941
|
+
],
|
|
22942
|
+
description: "Container width"
|
|
22943
|
+
},
|
|
22944
|
+
height: {
|
|
22945
|
+
types: [
|
|
22946
|
+
"number",
|
|
22947
|
+
"string"
|
|
22948
|
+
],
|
|
22949
|
+
description: "Container height"
|
|
22950
|
+
},
|
|
22951
|
+
highlightedOrbital: {
|
|
22952
|
+
types: [
|
|
22953
|
+
"string"
|
|
22954
|
+
],
|
|
22955
|
+
description: "GAP-52: name of the orbital to highlight with a persistent ring/glow. Independent from user-driven selection (click). Used by the builder workspace when entering cosmic mode from a focused orbital \u2014 the focused orbital is highlighted while the user can still click any other orbital to select it."
|
|
22956
|
+
},
|
|
22957
|
+
onOrbitalSelect: {
|
|
22958
|
+
types: [
|
|
22959
|
+
"function"
|
|
22960
|
+
],
|
|
22961
|
+
description: "GAP-55: fired when the user clicks an orbital tile. Consumers (e.g. the builder workspace) use this as the trigger to drill INTO the clicked orbital \u2014 typically by switching back to the canvas tab and opening the clicked orbital at L2 expanded. Local `selected` toggle (visual highlight + info panel) still fires regardless of whether the callback is provided."
|
|
22962
|
+
},
|
|
22963
|
+
minZoom: {
|
|
22964
|
+
types: [
|
|
22965
|
+
"number"
|
|
22966
|
+
],
|
|
22967
|
+
description: "GAP-54: minimum zoom factor when scroll-wheel zooming. Default 0.4."
|
|
22968
|
+
},
|
|
22969
|
+
maxZoom: {
|
|
22970
|
+
types: [
|
|
22971
|
+
"number"
|
|
22972
|
+
],
|
|
22973
|
+
description: "GAP-54: maximum zoom factor when scroll-wheel zooming. Default 3."
|
|
22974
|
+
}
|
|
22975
|
+
}
|
|
22976
|
+
},
|
|
22793
22977
|
heading: {
|
|
22794
22978
|
type: "heading",
|
|
22795
22979
|
category: "component",
|
|
@@ -23606,7 +23790,7 @@ var integrators_registry_default = {
|
|
|
23606
23790
|
// src/component-mapping.json
|
|
23607
23791
|
var component_mapping_default = {
|
|
23608
23792
|
version: "1.0.0",
|
|
23609
|
-
exportedAt: "2026-04-
|
|
23793
|
+
exportedAt: "2026-04-18T11:44:35.778Z",
|
|
23610
23794
|
mappings: {
|
|
23611
23795
|
"page-header": {
|
|
23612
23796
|
component: "PageHeader",
|
|
@@ -25386,6 +25570,21 @@ var component_mapping_default = {
|
|
|
25386
25570
|
importPath: "@/components/organisms/OrbInspector",
|
|
25387
25571
|
category: "debug"
|
|
25388
25572
|
},
|
|
25573
|
+
"trait-frame": {
|
|
25574
|
+
component: "TraitFrame",
|
|
25575
|
+
importPath: "@/components/atoms/TraitFrame",
|
|
25576
|
+
category: "component"
|
|
25577
|
+
},
|
|
25578
|
+
"file-tree": {
|
|
25579
|
+
component: "FileTree",
|
|
25580
|
+
importPath: "@/components/molecules/FileTree",
|
|
25581
|
+
category: "component"
|
|
25582
|
+
},
|
|
25583
|
+
"avl-orbitals-cosmic-zoom": {
|
|
25584
|
+
component: "AvlOrbitalsCosmicZoom",
|
|
25585
|
+
importPath: "@/components/organisms/AvlOrbitalsCosmicZoom",
|
|
25586
|
+
category: "display"
|
|
25587
|
+
},
|
|
25389
25588
|
heading: {
|
|
25390
25589
|
component: "Typography",
|
|
25391
25590
|
importPath: "@/components/atoms/Typography",
|
|
@@ -25402,7 +25601,7 @@ var component_mapping_default = {
|
|
|
25402
25601
|
// src/event-contracts.json
|
|
25403
25602
|
var event_contracts_default = {
|
|
25404
25603
|
version: "1.0.0",
|
|
25405
|
-
exportedAt: "2026-04-
|
|
25604
|
+
exportedAt: "2026-04-18T11:44:35.778Z",
|
|
25406
25605
|
contracts: {
|
|
25407
25606
|
form: {
|
|
25408
25607
|
emits: [
|
|
@@ -26694,6 +26893,13 @@ var event_contracts_default = {
|
|
|
26694
26893
|
type: "object"
|
|
26695
26894
|
}
|
|
26696
26895
|
},
|
|
26896
|
+
{
|
|
26897
|
+
event: "CODE_CHANGE",
|
|
26898
|
+
trigger: "action",
|
|
26899
|
+
payload: {
|
|
26900
|
+
type: "object"
|
|
26901
|
+
}
|
|
26902
|
+
},
|
|
26697
26903
|
{
|
|
26698
26904
|
event: "SERVICE_MODE_TOGGLE",
|
|
26699
26905
|
trigger: "action",
|