@almadar/std 16.232.0 → 16.234.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/behaviors/behaviors-registry.json +1422 -133
- package/behaviors/lolo/ui/avl/atoms/ui-avl-glyph.lolo +54 -0
- package/behaviors/lolo/ui/avl/atoms/ui-avl-state-machine.lolo +132 -0
- package/behaviors/lolo/ui/avl/atoms/ui-behavior-view.lolo +5 -6
- package/behaviors/lolo/ui/avl/atoms/ui-module-card.lolo +7 -8
- package/behaviors/lolo/ui/core/atoms/std-board.lolo +6 -1
- package/behaviors/lolo/ui/core/atoms/std-event-log.lolo +12 -2
- package/behaviors/lolo/ui/core/atoms/ui-box.lolo +2 -2
- package/behaviors/lolo/ui/core/atoms/ui-button.lolo +1 -1
- package/behaviors/lolo/ui/core/molecules/ui-breadcrumb.lolo +1 -1
- package/behaviors/lolo/ui/core/molecules/ui-code-block.lolo +74 -0
- package/behaviors/lolo/ui/core/molecules/ui-file-tree.lolo +17 -0
- package/behaviors/lolo/ui/core/organisms/ui-state-machine-view.lolo +104 -2
- package/behaviors/lolo/ui/game/atoms/ui-draw-skinned-mesh.lolo +1 -1
- package/behaviors/lolo-behavior-contracts.json +1 -1
- package/behaviors/registry/factory-signatures.json +1 -1
- package/behaviors/registry/ui/avl/atoms/ui-avl-glyph.orb +211 -0
- package/behaviors/registry/ui/avl/atoms/ui-avl-state-machine.orb +761 -0
- package/behaviors/registry/ui/avl/atoms/ui-behavior-view.orb +157 -66
- package/behaviors/registry/ui/avl/atoms/ui-module-card.orb +158 -67
- package/behaviors/registry/ui/core/atoms/std-board.orb +9 -1
- package/behaviors/registry/ui/core/atoms/std-event-log.orb +19 -3
- package/behaviors/registry/ui/core/atoms/ui-box.orb +2 -2
- package/behaviors/registry/ui/core/atoms/ui-button.orb +1 -0
- package/behaviors/registry/ui/core/molecules/ui-breadcrumb.orb +9 -1
- package/behaviors/registry/ui/core/molecules/ui-code-block.orb +185 -0
- package/behaviors/registry/ui/core/molecules/ui-file-tree.orb +81 -0
- package/behaviors/registry/ui/core/organisms/ui-state-machine-view.orb +487 -2
- package/behaviors/registry/ui/game/atoms/ui-draw-skinned-mesh.orb +1 -2
- package/dist/behaviors/exports-reader.js +1891 -1476
- package/dist/behaviors/functions/index.d.ts +251 -10
- package/dist/behaviors/functions/index.js +1886 -1477
- package/dist/behaviors/index.d.ts +1 -1
- package/dist/behaviors/index.js +1892 -1477
- package/dist/behaviors/query.js +1891 -1476
- package/dist/behaviors-embeddings.hash.json +3 -3
- package/dist/behaviors-embeddings.json +19 -11
- package/dist/behaviors-registry.json +1422 -133
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1892 -1477
- package/dist/knob-embeddings.hash.json +3 -3
- package/dist/knob-embeddings.json +171 -7
- package/dist/registry/factory-signatures.json +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
app ui-avl-glyph "1.0.0"
|
|
2
|
+
"AvlGlyph — UI factory (1:1 with the @almadar/ui avl-glyph pattern)."
|
|
3
|
+
;; @pattern "avl-glyph"
|
|
4
|
+
orbital AvlGlyphOrbital {
|
|
5
|
+
entity AvlGlyphItem [runtime] {
|
|
6
|
+
id : string!
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
trait AvlGlyphRender -> @rebindable AvlGlyphItem [interaction, instance] {
|
|
10
|
+
initial: idle
|
|
11
|
+
|
|
12
|
+
state idle {
|
|
13
|
+
INIT -> idle
|
|
14
|
+
(render-ui main {
|
|
15
|
+
kind: @config.kind
|
|
16
|
+
label: @config.label
|
|
17
|
+
effectType: @config.effectType
|
|
18
|
+
size: @config.size
|
|
19
|
+
showCaption: @config.showCaption
|
|
20
|
+
className: @config.className
|
|
21
|
+
type: avl-glyph
|
|
22
|
+
})
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
config {
|
|
26
|
+
kind : "application" | "orbital" | "entity" | "trait" | "page" | "state" | "transition" | "event" | "guard" | "effect" | "field" | "fieldType" | "binding" | "bindingRef" | "persistence" | "operator" | "sexpr" | "literal" = state
|
|
27
|
+
@label "Kind"
|
|
28
|
+
@description "Which notation symbol to draw."
|
|
29
|
+
@tier "presentation"
|
|
30
|
+
label : string
|
|
31
|
+
@label "Label"
|
|
32
|
+
@description "Caption, and the drawn text for operator / literal / bindingRef symbols."
|
|
33
|
+
@tier "presentation"
|
|
34
|
+
effectType : string
|
|
35
|
+
@label "Effect Type"
|
|
36
|
+
@description "Effect symbol variant. @default 'set'"
|
|
37
|
+
@tier "presentation"
|
|
38
|
+
size : "sm" | "md" | "lg" = md
|
|
39
|
+
@label "Size"
|
|
40
|
+
@description "Symbol height. @default 'md'"
|
|
41
|
+
@tier "presentation"
|
|
42
|
+
showCaption : boolean = true
|
|
43
|
+
@label "Show Caption"
|
|
44
|
+
@description "Show the caption under the symbol. @default true"
|
|
45
|
+
@tier "presentation"
|
|
46
|
+
className : string
|
|
47
|
+
@label "Class Name"
|
|
48
|
+
@description "className prop"
|
|
49
|
+
@tier "presentation"
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
page "/avl-glyph" as AvlGlyphPage -> AvlGlyphRender
|
|
54
|
+
}
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
app ui-avl-state-machine "1.0.0"
|
|
2
|
+
"AvlStateMachine — UI factory (1:1 with the @almadar/ui avl-state-machine pattern)."
|
|
3
|
+
;; @pattern "avl-state-machine"
|
|
4
|
+
orbital AvlStateMachineOrbital {
|
|
5
|
+
type AvlStateMachineTrait = {
|
|
6
|
+
name : string!
|
|
7
|
+
linkedEntity : string!
|
|
8
|
+
states : [AvlStateMachineTraitStatesItem]!
|
|
9
|
+
transitions : [AvlStateMachineTraitTransitionsItem]!
|
|
10
|
+
emittedEvents : [string]!
|
|
11
|
+
listenedEvents : [string]!
|
|
12
|
+
}
|
|
13
|
+
type AvlStateMachineTraitStatesItem = {
|
|
14
|
+
name : string!
|
|
15
|
+
isInitial : boolean
|
|
16
|
+
isTerminal : boolean
|
|
17
|
+
}
|
|
18
|
+
type AvlStateMachineTraitTransitionsItem = {
|
|
19
|
+
from : string!
|
|
20
|
+
to : string!
|
|
21
|
+
event : string!
|
|
22
|
+
guard : SExpr
|
|
23
|
+
effects : [AvlStateMachineTraitTransitionsItemEffectsItem]!
|
|
24
|
+
index : number!
|
|
25
|
+
}
|
|
26
|
+
type AvlStateMachineTraitTransitionsItemEffectsItem = {
|
|
27
|
+
type : string!
|
|
28
|
+
args : [SExpr]!
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
entity AvlStateMachineItem [runtime] {
|
|
32
|
+
id : string!
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
trait AvlStateMachineRender -> @rebindable AvlStateMachineItem [interaction, instance] {
|
|
36
|
+
initial: idle
|
|
37
|
+
|
|
38
|
+
state idle {
|
|
39
|
+
INIT -> idle
|
|
40
|
+
(render-ui main {
|
|
41
|
+
trait: @config.traitProp
|
|
42
|
+
activeState: @config.activeState
|
|
43
|
+
activeTransition: @config.activeTransition
|
|
44
|
+
visitedStates: @config.visitedStates
|
|
45
|
+
stateClickEvent: @config.stateClickEvent
|
|
46
|
+
transitionClickEvent: @config.transitionClickEvent
|
|
47
|
+
selectedState: @config.selectedState
|
|
48
|
+
pendingSourceState: @config.pendingSourceState
|
|
49
|
+
nodeShape: @config.nodeShape
|
|
50
|
+
entityFields: @config.entityFields
|
|
51
|
+
direction: @config.direction
|
|
52
|
+
showHeader: @config.showHeader
|
|
53
|
+
className: @config.className
|
|
54
|
+
type: avl-state-machine
|
|
55
|
+
})
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
emits {
|
|
59
|
+
@config.stateClickEvent -> external {
|
|
60
|
+
stateId : string!
|
|
61
|
+
}
|
|
62
|
+
@description "Emits UI:{stateClickEvent} with { stateId } when a state is clicked."
|
|
63
|
+
@tier "essential"
|
|
64
|
+
@config.transitionClickEvent -> external {
|
|
65
|
+
index : number!
|
|
66
|
+
event : string!
|
|
67
|
+
from : string!
|
|
68
|
+
to : string!
|
|
69
|
+
}
|
|
70
|
+
@description "Emits UI:{transitionClickEvent} with { index, event, from, to } when a transition label is clicked."
|
|
71
|
+
@tier "essential"
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
config {
|
|
75
|
+
traitProp : AvlStateMachineTrait = { name: "OrderFlow", linkedEntity: "Order", states: [{ name: "browsing", isInitial: true, isTerminal: false }, { name: "editing", isInitial: false, isTerminal: false }, { name: "saving", isInitial: false, isTerminal: false }, { name: "confirmed", isInitial: false, isTerminal: true }, { name: "failed", isInitial: false, isTerminal: false }], transitions: [{ from: "browsing", to: "editing", event: "EDIT", effects: [{ type: "render-ui", args: [] }], index: 0 }, { from: "editing", to: "saving", event: "SAVE", effects: [{ type: "persist", args: [] }, { type: "notify", args: [] }], index: 1 }, { from: "saving", to: "confirmed", event: "SAVED", effects: [{ type: "emit", args: [] }, { type: "render-ui", args: [] }], index: 2 }, { from: "saving", to: "failed", event: "SAVE_FAILED", effects: [{ type: "notify", args: [] }], index: 3 }, { from: "failed", to: "editing", event: "RETRY", effects: [], index: 4 }, { from: "editing", to: "browsing", event: "CANCEL", effects: [{ type: "render-ui", args: [] }], index: 5 }, { from: "confirmed", to: "browsing", event: "DONE", effects: [{ type: "navigate", args: [] }], index: 6 }], emittedEvents: ["ORDER_SAVED"], listenedEvents: ["PAYMENT_OK"] }
|
|
76
|
+
@label "Trait"
|
|
77
|
+
@description "The trait to draw (see `parseTraitLevel`)."
|
|
78
|
+
@synonyms "trait"
|
|
79
|
+
@tier "presentation"
|
|
80
|
+
activeState : string
|
|
81
|
+
@label "Active State"
|
|
82
|
+
@description "State execution is currently in."
|
|
83
|
+
@tier "presentation"
|
|
84
|
+
activeTransition : number
|
|
85
|
+
@label "Active Transition"
|
|
86
|
+
@description "`index` of the transition that just fired."
|
|
87
|
+
@tier "presentation"
|
|
88
|
+
visitedStates : [string] = []
|
|
89
|
+
@label "Visited States"
|
|
90
|
+
@description "States already passed through, in order."
|
|
91
|
+
@tier "presentation"
|
|
92
|
+
stateClickEvent : event = "STATE_CLICK"
|
|
93
|
+
@label "State Click Event"
|
|
94
|
+
@description "Emits UI:{stateClickEvent} with { stateId } when a state is clicked."
|
|
95
|
+
@tier "presentation"
|
|
96
|
+
transitionClickEvent : event = "TRANSITION_CLICK"
|
|
97
|
+
@label "Transition Click Event"
|
|
98
|
+
@description "Emits UI:{transitionClickEvent} with { index, event, from, to } when a transition label is clicked."
|
|
99
|
+
@tier "presentation"
|
|
100
|
+
selectedState : string
|
|
101
|
+
@label "Selected State"
|
|
102
|
+
@description "State picked in an editor (first click)."
|
|
103
|
+
@tier "presentation"
|
|
104
|
+
pendingSourceState : string
|
|
105
|
+
@label "Pending Source State"
|
|
106
|
+
@description "Source of a transition being drawn — the next state click picks its target."
|
|
107
|
+
@tier "presentation"
|
|
108
|
+
nodeShape : "pill" | "gear" = pill
|
|
109
|
+
@label "Node Shape"
|
|
110
|
+
@description "Node silhouette. @default 'pill'"
|
|
111
|
+
@tier "presentation"
|
|
112
|
+
entityFields : [string] = []
|
|
113
|
+
@label "Entity Fields"
|
|
114
|
+
@description "Entity field names listed in the header."
|
|
115
|
+
@tier "presentation"
|
|
116
|
+
direction : "ltr" | "rtl" = ltr
|
|
117
|
+
@label "Direction"
|
|
118
|
+
@description "Flow direction. @default 'ltr'"
|
|
119
|
+
@tier "presentation"
|
|
120
|
+
showHeader : boolean = true
|
|
121
|
+
@label "Show Header"
|
|
122
|
+
@description "Show the trait header (name, entity, listens/emits). @default true"
|
|
123
|
+
@tier "presentation"
|
|
124
|
+
className : string
|
|
125
|
+
@label "Class Name"
|
|
126
|
+
@description "className prop"
|
|
127
|
+
@tier "presentation"
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
page "/avl-state-machine" as AvlStateMachinePage -> AvlStateMachineRender
|
|
132
|
+
}
|
|
@@ -5,7 +5,6 @@ orbital BehaviorViewOrbital {
|
|
|
5
5
|
type BehaviorViewData = {
|
|
6
6
|
orbitalName : string!
|
|
7
7
|
entityName : string!
|
|
8
|
-
persistence : string!
|
|
9
8
|
fields : [BehaviorViewDataFieldsItem]!
|
|
10
9
|
traits : [BehaviorViewDataTraitsItem]!
|
|
11
10
|
pages : [BehaviorViewDataPagesItem]!
|
|
@@ -40,14 +39,14 @@ orbital BehaviorViewOrbital {
|
|
|
40
39
|
}
|
|
41
40
|
type BehaviorViewDataTraitDetailsValueStatesItem = {
|
|
42
41
|
name : string!
|
|
43
|
-
isInitial : boolean
|
|
44
|
-
isTerminal : boolean
|
|
42
|
+
isInitial : boolean
|
|
43
|
+
isTerminal : boolean
|
|
45
44
|
}
|
|
46
45
|
type BehaviorViewDataTraitDetailsValueTransitionsItem = {
|
|
47
46
|
from : string!
|
|
48
47
|
to : string!
|
|
49
48
|
event : string!
|
|
50
|
-
guard : SExpr
|
|
49
|
+
guard : SExpr
|
|
51
50
|
effects : [BehaviorViewDataTraitDetailsValueTransitionsItemEffectsItem]!
|
|
52
51
|
index : number!
|
|
53
52
|
}
|
|
@@ -78,9 +77,9 @@ orbital BehaviorViewOrbital {
|
|
|
78
77
|
}
|
|
79
78
|
|
|
80
79
|
config {
|
|
81
|
-
data : BehaviorViewData = { orbitalName: "
|
|
80
|
+
data : BehaviorViewData = { orbitalName: "OrderOrbital", entityName: "Order", persistence: "persistent", fields: [{ name: "customer", type: "string", required: true, hasDefault: false }, { name: "qty", type: "number", required: true, hasDefault: true }, { name: "status", type: "string", required: false, hasDefault: true }], traits: [{ name: "OrderFlow", stateCount: 5, eventCount: 7, transitionCount: 7, emits: ["ORDER_SAVED"], listens: ["PAYMENT_OK"] }], pages: [{ name: "Orders", route: "/orders" }], traitDetails: { OrderFlow: { name: "OrderFlow", linkedEntity: "Order", states: [{ name: "browsing", isInitial: true, isTerminal: false }, { name: "editing", isInitial: false, isTerminal: false }, { name: "saving", isInitial: false, isTerminal: false }, { name: "confirmed", isInitial: false, isTerminal: true }, { name: "failed", isInitial: false, isTerminal: false }], transitions: [{ from: "browsing", to: "editing", event: "EDIT", effects: [{ type: "render-ui", args: [] }], index: 0 }, { from: "editing", to: "saving", event: "SAVE", effects: [{ type: "persist", args: [] }, { type: "notify", args: [] }], index: 1 }, { from: "saving", to: "confirmed", event: "SAVED", effects: [{ type: "emit", args: [] }, { type: "render-ui", args: [] }], index: 2 }, { from: "saving", to: "failed", event: "SAVE_FAILED", effects: [{ type: "notify", args: [] }], index: 3 }, { from: "failed", to: "editing", event: "RETRY", effects: [], index: 4 }, { from: "editing", to: "browsing", event: "CANCEL", effects: [{ type: "render-ui", args: [] }], index: 5 }, { from: "confirmed", to: "browsing", event: "DONE", effects: [{ type: "navigate", args: [] }], index: 6 }], emittedEvents: ["ORDER_SAVED"], listenedEvents: ["PAYMENT_OK"] } }, externalLinks: [{ targetOrbital: "PaymentOrbital", eventName: "PAYMENT_OK", direction: "in", traitName: "OrderFlow" }] }
|
|
82
81
|
@label "Data"
|
|
83
|
-
@description "
|
|
82
|
+
@description "The orbital to summarize."
|
|
84
83
|
@tier "presentation"
|
|
85
84
|
}
|
|
86
85
|
}
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
app ui-module-card "1.0.0"
|
|
2
|
-
"ModuleCard — a card
|
|
3
|
-
;; @capabilities "
|
|
2
|
+
"ModuleCard — a compact summary card for one orbital module: its entity and fields, a mini state machine per trait, and its pages. — UI factory (1:1 with the @almadar/ui module-card pattern)."
|
|
3
|
+
;; @capabilities "orbital module summary card, entity and trait overview card, app architecture node card"
|
|
4
4
|
;; @pattern "module-card"
|
|
5
5
|
orbital ModuleCardOrbital {
|
|
6
6
|
type ModuleCardData = {
|
|
7
7
|
orbitalName : string!
|
|
8
8
|
entityName : string!
|
|
9
|
-
persistence : string!
|
|
10
9
|
fields : [ModuleCardDataFieldsItem]!
|
|
11
10
|
traits : [ModuleCardDataTraitsItem]!
|
|
12
11
|
pages : [ModuleCardDataPagesItem]!
|
|
@@ -41,14 +40,14 @@ orbital ModuleCardOrbital {
|
|
|
41
40
|
}
|
|
42
41
|
type ModuleCardDataTraitDetailsValueStatesItem = {
|
|
43
42
|
name : string!
|
|
44
|
-
isInitial : boolean
|
|
45
|
-
isTerminal : boolean
|
|
43
|
+
isInitial : boolean
|
|
44
|
+
isTerminal : boolean
|
|
46
45
|
}
|
|
47
46
|
type ModuleCardDataTraitDetailsValueTransitionsItem = {
|
|
48
47
|
from : string!
|
|
49
48
|
to : string!
|
|
50
49
|
event : string!
|
|
51
|
-
guard : SExpr
|
|
50
|
+
guard : SExpr
|
|
52
51
|
effects : [ModuleCardDataTraitDetailsValueTransitionsItemEffectsItem]!
|
|
53
52
|
index : number!
|
|
54
53
|
}
|
|
@@ -79,9 +78,9 @@ orbital ModuleCardOrbital {
|
|
|
79
78
|
}
|
|
80
79
|
|
|
81
80
|
config {
|
|
82
|
-
data : ModuleCardData = { orbitalName: "
|
|
81
|
+
data : ModuleCardData = { orbitalName: "OrderOrbital", entityName: "Order", persistence: "persistent", fields: [{ name: "customer", type: "string", required: true, hasDefault: false }, { name: "qty", type: "number", required: true, hasDefault: true }, { name: "status", type: "string", required: false, hasDefault: true }], traits: [{ name: "OrderFlow", stateCount: 5, eventCount: 7, transitionCount: 7, emits: ["ORDER_SAVED"], listens: ["PAYMENT_OK"] }], pages: [{ name: "Orders", route: "/orders" }], traitDetails: { OrderFlow: { name: "OrderFlow", linkedEntity: "Order", states: [{ name: "browsing", isInitial: true, isTerminal: false }, { name: "editing", isInitial: false, isTerminal: false }, { name: "saving", isInitial: false, isTerminal: false }, { name: "confirmed", isInitial: false, isTerminal: true }, { name: "failed", isInitial: false, isTerminal: false }], transitions: [{ from: "browsing", to: "editing", event: "EDIT", effects: [{ type: "render-ui", args: [] }], index: 0 }, { from: "editing", to: "saving", event: "SAVE", effects: [{ type: "persist", args: [] }, { type: "notify", args: [] }], index: 1 }, { from: "saving", to: "confirmed", event: "SAVED", effects: [{ type: "emit", args: [] }, { type: "render-ui", args: [] }], index: 2 }, { from: "saving", to: "failed", event: "SAVE_FAILED", effects: [{ type: "notify", args: [] }], index: 3 }, { from: "failed", to: "editing", event: "RETRY", effects: [], index: 4 }, { from: "editing", to: "browsing", event: "CANCEL", effects: [{ type: "render-ui", args: [] }], index: 5 }, { from: "confirmed", to: "browsing", event: "DONE", effects: [{ type: "navigate", args: [] }], index: 6 }], emittedEvents: ["ORDER_SAVED"], listenedEvents: ["PAYMENT_OK"] } }, externalLinks: [{ targetOrbital: "PaymentOrbital", eventName: "PAYMENT_OK", direction: "in", traitName: "OrderFlow" }] }
|
|
83
82
|
@label "Data"
|
|
84
|
-
@description "
|
|
83
|
+
@description "The orbital to summarize."
|
|
85
84
|
@tier "presentation"
|
|
86
85
|
}
|
|
87
86
|
}
|
|
@@ -241,7 +241,7 @@ orbital BoardOrbital {
|
|
|
241
241
|
REFETCH_QUERY -> viewing_board
|
|
242
242
|
(fetch BoardView {
|
|
243
243
|
emit: { failure: BoardItemsLoadFailed, success: BoardItemsLoaded }
|
|
244
|
-
filter: (or ["=", ?searchTerm, ""] (str/includes (object/get @entity
|
|
244
|
+
filter: (or ["=", ?searchTerm, ""] (str/includes (object/get @entity @config.searchField) ?searchTerm))
|
|
245
245
|
})
|
|
246
246
|
REFETCH_FILTER -> viewing_board
|
|
247
247
|
(fetch BoardView {
|
|
@@ -535,6 +535,11 @@ orbital BoardOrbital {
|
|
|
535
535
|
@label "Board title"
|
|
536
536
|
@description "Heading shown above the column board"
|
|
537
537
|
@tier "presentation"
|
|
538
|
+
searchField : string = "title"
|
|
539
|
+
@label "Which column does the search box match against?"
|
|
540
|
+
@description "Name the field on this entity the search box's str/includes filter matches against. Declared, never inferred: an entity with no `title` column must set this to a real field (e.g. name, summary) or the search box can never match a card."
|
|
541
|
+
@synonyms "search column, search on field, match field, search key"
|
|
542
|
+
@tier "policy"
|
|
538
543
|
columns : [ColumnSpec] = [{
|
|
539
544
|
icon: circle
|
|
540
545
|
key: todo
|
|
@@ -241,12 +241,12 @@ orbital EventLogOrbital {
|
|
|
241
241
|
REFETCH_QUERY -> viewing
|
|
242
242
|
(fetch EventLogView {
|
|
243
243
|
emit: { failure: EventLogLoadFailed, success: EventLogLoaded }
|
|
244
|
-
filter: (and (or ["=", @entity.filterKind, ""] ["=", (object/get @entity
|
|
244
|
+
filter: (and (or ["=", @entity.filterKind, ""] ["=", (object/get @entity @config.kindField), @entity.filterKind]) (or ["=", ?searchTerm, ""] (str/includes (object/get @entity @config.searchField) ?searchTerm)))
|
|
245
245
|
})
|
|
246
246
|
REFETCH_FILTER -> viewing
|
|
247
247
|
(fetch EventLogView {
|
|
248
248
|
emit: { failure: EventLogLoadFailed, success: EventLogLoaded }
|
|
249
|
-
filter: (and (or ["=", @entity.filterKind, ""] ["=", (object/get @entity
|
|
249
|
+
filter: (and (or ["=", @entity.filterKind, ""] ["=", (object/get @entity @config.kindField), @entity.filterKind]) (or ["=", ?value, ""] ["=", (object/get @entity ?field), ?value]))
|
|
250
250
|
})
|
|
251
251
|
;; No filter carried over on REFETCH_PAGE, mirroring std-browse exactly —
|
|
252
252
|
;; the reference page arm does not preserve query/filter either.
|
|
@@ -588,6 +588,16 @@ orbital EventLogOrbital {
|
|
|
588
588
|
@label "Section title"
|
|
589
589
|
@description "Heading shown above the activity timeline"
|
|
590
590
|
@tier "presentation"
|
|
591
|
+
searchField : string = "title"
|
|
592
|
+
@label "Which column does the search box match against?"
|
|
593
|
+
@description "Name the field on this entity the search box's str/includes filter matches against. Declared, never inferred: an entity with no `title` column must set this to a real field or the search box can never match an entry."
|
|
594
|
+
@synonyms "search column, search on field, match field, search key"
|
|
595
|
+
@tier "policy"
|
|
596
|
+
kindField : string = "kind"
|
|
597
|
+
@label "Which column holds each entry's kind?"
|
|
598
|
+
@description "Name the field on this entity the kind filter compares against (the values of kindOptions). An entity whose kind lives under another column (e.g. status) sets it here, or the kind filter can never match an entry."
|
|
599
|
+
@synonyms "kind column, type field, category column, filter by kind"
|
|
600
|
+
@tier "policy"
|
|
591
601
|
kindOptions : [KindOption] = [{
|
|
592
602
|
icon: plus-circle
|
|
593
603
|
key: created
|
|
@@ -59,7 +59,7 @@ orbital BoxOrbital {
|
|
|
59
59
|
@label "Dir"
|
|
60
60
|
@description "Text direction for this subtree: 'ltr', 'rtl' (Arabic/Hebrew content) or 'auto'"
|
|
61
61
|
@tier "presentation"
|
|
62
|
-
padding : "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" =
|
|
62
|
+
padding : "none" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" = md
|
|
63
63
|
@label "Padding"
|
|
64
64
|
@description "Padding on all sides"
|
|
65
65
|
@tier "presentation"
|
|
@@ -87,7 +87,7 @@ orbital BoxOrbital {
|
|
|
87
87
|
@label "Bg"
|
|
88
88
|
@description "Background color"
|
|
89
89
|
@tier "presentation"
|
|
90
|
-
border : boolean =
|
|
90
|
+
border : boolean = true
|
|
91
91
|
@label "Border"
|
|
92
92
|
@description "Show border"
|
|
93
93
|
@tier "presentation"
|
|
@@ -96,7 +96,7 @@ orbital ButtonOrbital {
|
|
|
96
96
|
@label "Action Payload"
|
|
97
97
|
@description "Payload to include with the action event"
|
|
98
98
|
@tier "presentation"
|
|
99
|
-
label : string
|
|
99
|
+
label : string = Button
|
|
100
100
|
@label "Label"
|
|
101
101
|
@description "Button label text (alternative to children for schema-driven rendering)"
|
|
102
102
|
@tier "presentation"
|
|
@@ -42,7 +42,7 @@ orbital BreadcrumbOrbital {
|
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
config {
|
|
45
|
-
items : [BreadcrumbItemsItem] = []
|
|
45
|
+
items : [BreadcrumbItemsItem] = [{ label: "Home", href: "/" } { label: "Page" }]
|
|
46
46
|
@label "Items"
|
|
47
47
|
@description "Breadcrumb items. Omit together with `fromNavStack` to render the orbital-scoped navigation stack instead of an authored trail."
|
|
48
48
|
@tier "presentation"
|
|
@@ -25,6 +25,15 @@ orbital CodeBlockOrbital {
|
|
|
25
25
|
code : string
|
|
26
26
|
stack : string
|
|
27
27
|
}
|
|
28
|
+
type CodeBlockDiagnosticsItem = {
|
|
29
|
+
line : number!
|
|
30
|
+
column : number
|
|
31
|
+
endLine : number
|
|
32
|
+
endColumn : number
|
|
33
|
+
severity : "error" | "warning"!
|
|
34
|
+
message : string!
|
|
35
|
+
approximate : boolean
|
|
36
|
+
}
|
|
28
37
|
|
|
29
38
|
entity CodeBlockItem [runtime] {
|
|
30
39
|
id : string!
|
|
@@ -70,6 +79,11 @@ orbital CodeBlockOrbital {
|
|
|
70
79
|
onSetMode: @config.onSetMode
|
|
71
80
|
motions: @config.motions
|
|
72
81
|
operators: @config.operators
|
|
82
|
+
problems: @config.problems
|
|
83
|
+
diagnostics: @config.diagnostics
|
|
84
|
+
onGoToDefinition: @config.onGoToDefinition
|
|
85
|
+
diagnosticsCode: @config.diagnosticsCode
|
|
86
|
+
lineNumbers: @config.lineNumbers
|
|
73
87
|
type: code-block
|
|
74
88
|
})
|
|
75
89
|
CHANGE -> idle
|
|
@@ -105,6 +119,11 @@ orbital CodeBlockOrbital {
|
|
|
105
119
|
onSetMode: @config.onSetMode
|
|
106
120
|
motions: @config.motions
|
|
107
121
|
operators: @config.operators
|
|
122
|
+
problems: @config.problems
|
|
123
|
+
diagnostics: @config.diagnostics
|
|
124
|
+
onGoToDefinition: @config.onGoToDefinition
|
|
125
|
+
diagnosticsCode: @config.diagnosticsCode
|
|
126
|
+
lineNumbers: @config.lineNumbers
|
|
108
127
|
type: code-block
|
|
109
128
|
})
|
|
110
129
|
EDITOR_FOCUS -> idle
|
|
@@ -140,6 +159,11 @@ orbital CodeBlockOrbital {
|
|
|
140
159
|
onSetMode: @config.onSetMode
|
|
141
160
|
motions: @config.motions
|
|
142
161
|
operators: @config.operators
|
|
162
|
+
problems: @config.problems
|
|
163
|
+
diagnostics: @config.diagnostics
|
|
164
|
+
onGoToDefinition: @config.onGoToDefinition
|
|
165
|
+
diagnosticsCode: @config.diagnosticsCode
|
|
166
|
+
lineNumbers: @config.lineNumbers
|
|
143
167
|
type: code-block
|
|
144
168
|
})
|
|
145
169
|
EDITOR_BLUR -> idle
|
|
@@ -175,6 +199,11 @@ orbital CodeBlockOrbital {
|
|
|
175
199
|
onSetMode: @config.onSetMode
|
|
176
200
|
motions: @config.motions
|
|
177
201
|
operators: @config.operators
|
|
202
|
+
problems: @config.problems
|
|
203
|
+
diagnostics: @config.diagnostics
|
|
204
|
+
onGoToDefinition: @config.onGoToDefinition
|
|
205
|
+
diagnosticsCode: @config.diagnosticsCode
|
|
206
|
+
lineNumbers: @config.lineNumbers
|
|
178
207
|
type: code-block
|
|
179
208
|
})
|
|
180
209
|
MOTION -> idle
|
|
@@ -210,6 +239,11 @@ orbital CodeBlockOrbital {
|
|
|
210
239
|
onSetMode: @config.onSetMode
|
|
211
240
|
motions: @config.motions
|
|
212
241
|
operators: @config.operators
|
|
242
|
+
problems: @config.problems
|
|
243
|
+
diagnostics: @config.diagnostics
|
|
244
|
+
onGoToDefinition: @config.onGoToDefinition
|
|
245
|
+
diagnosticsCode: @config.diagnosticsCode
|
|
246
|
+
lineNumbers: @config.lineNumbers
|
|
213
247
|
type: code-block
|
|
214
248
|
})
|
|
215
249
|
OPERATE -> idle
|
|
@@ -245,6 +279,11 @@ orbital CodeBlockOrbital {
|
|
|
245
279
|
onSetMode: @config.onSetMode
|
|
246
280
|
motions: @config.motions
|
|
247
281
|
operators: @config.operators
|
|
282
|
+
problems: @config.problems
|
|
283
|
+
diagnostics: @config.diagnostics
|
|
284
|
+
onGoToDefinition: @config.onGoToDefinition
|
|
285
|
+
diagnosticsCode: @config.diagnosticsCode
|
|
286
|
+
lineNumbers: @config.lineNumbers
|
|
248
287
|
type: code-block
|
|
249
288
|
})
|
|
250
289
|
INSERT_TEXT -> idle
|
|
@@ -280,6 +319,11 @@ orbital CodeBlockOrbital {
|
|
|
280
319
|
onSetMode: @config.onSetMode
|
|
281
320
|
motions: @config.motions
|
|
282
321
|
operators: @config.operators
|
|
322
|
+
problems: @config.problems
|
|
323
|
+
diagnostics: @config.diagnostics
|
|
324
|
+
onGoToDefinition: @config.onGoToDefinition
|
|
325
|
+
diagnosticsCode: @config.diagnosticsCode
|
|
326
|
+
lineNumbers: @config.lineNumbers
|
|
283
327
|
type: code-block
|
|
284
328
|
})
|
|
285
329
|
SET_MODE -> idle
|
|
@@ -315,6 +359,11 @@ orbital CodeBlockOrbital {
|
|
|
315
359
|
onSetMode: @config.onSetMode
|
|
316
360
|
motions: @config.motions
|
|
317
361
|
operators: @config.operators
|
|
362
|
+
problems: @config.problems
|
|
363
|
+
diagnostics: @config.diagnostics
|
|
364
|
+
onGoToDefinition: @config.onGoToDefinition
|
|
365
|
+
diagnosticsCode: @config.diagnosticsCode
|
|
366
|
+
lineNumbers: @config.lineNumbers
|
|
318
367
|
type: code-block
|
|
319
368
|
})
|
|
320
369
|
}
|
|
@@ -335,6 +384,11 @@ orbital CodeBlockOrbital {
|
|
|
335
384
|
}
|
|
336
385
|
@description "Declarative bus emit fired when this editor loses focus."
|
|
337
386
|
@tier "essential"
|
|
387
|
+
@config.onGoToDefinition -> external {
|
|
388
|
+
identifier : string
|
|
389
|
+
}
|
|
390
|
+
@description "Editable only: Cmd/Ctrl+click, or Cmd/Ctrl+Enter at the caret, on an identifier `definitionAt` accepts."
|
|
391
|
+
@tier "essential"
|
|
338
392
|
}
|
|
339
393
|
|
|
340
394
|
listens {
|
|
@@ -490,6 +544,26 @@ orbital CodeBlockOrbital {
|
|
|
490
544
|
@label "Operators"
|
|
491
545
|
@description "Operator vocabulary this editor accepts. Default: the full `EditorOperator` set."
|
|
492
546
|
@tier "presentation"
|
|
547
|
+
problems : number
|
|
548
|
+
@label "Problems"
|
|
549
|
+
@description "Editable only: how many problems the host knows the code has (some, like a parse error, have no line to mark). With `assist`, the editor offers to fix them."
|
|
550
|
+
@tier "presentation"
|
|
551
|
+
diagnostics : [CodeBlockDiagnosticsItem] = []
|
|
552
|
+
@label "Diagnostics"
|
|
553
|
+
@description "Editable only: problems located in the code (1-based line/column in characters, `endColumn` just past the last one), each underlined exactly — red wavy for an error, amber for a warning, dotted where the position is approximate. The message of the one under the caret shows below the editor."
|
|
554
|
+
@tier "presentation"
|
|
555
|
+
onGoToDefinition : event = "GO_TO_DEFINITION"
|
|
556
|
+
@label "On Go To Definition"
|
|
557
|
+
@description "Editable only: Cmd/Ctrl+click, or Cmd/Ctrl+Enter at the caret, on an identifier `definitionAt` accepts."
|
|
558
|
+
@tier "presentation"
|
|
559
|
+
diagnosticsCode : string
|
|
560
|
+
@label "Diagnostics Code"
|
|
561
|
+
@description "The code `diagnostics` were computed on. When the editor's text has moved on, each range is carried over the edit; a range the edit touches is dropped until the code is checked again. Absent: they describe the current text."
|
|
562
|
+
@tier "presentation"
|
|
563
|
+
lineNumbers : boolean
|
|
564
|
+
@label "Line Numbers"
|
|
565
|
+
@description "Editable only: number the lines in a gutter (lines with errors in red). Default on."
|
|
566
|
+
@tier "presentation"
|
|
493
567
|
}
|
|
494
568
|
}
|
|
495
569
|
|
|
@@ -7,6 +7,8 @@ orbital FileTreeOrbital {
|
|
|
7
7
|
path : string!
|
|
8
8
|
type : "file" | "dir"!
|
|
9
9
|
children : [FileTreeTreeItem]
|
|
10
|
+
note : string
|
|
11
|
+
expandable : boolean
|
|
10
12
|
size : number
|
|
11
13
|
language : string
|
|
12
14
|
}
|
|
@@ -33,6 +35,8 @@ orbital FileTreeOrbital {
|
|
|
33
35
|
selectedId: @config.selectedId
|
|
34
36
|
look: @config.look
|
|
35
37
|
onFileSelect: @config.onFileSelect
|
|
38
|
+
onNodeExpand: @config.onNodeExpand
|
|
39
|
+
expandedPaths: @config.expandedPaths
|
|
36
40
|
onNodeSelect: @config.onNodeSelect
|
|
37
41
|
onNodeAction: @config.onNodeAction
|
|
38
42
|
nodeActionIcon: @config.nodeActionIcon
|
|
@@ -50,6 +54,11 @@ orbital FileTreeOrbital {
|
|
|
50
54
|
}
|
|
51
55
|
@description "Called when a file is clicked"
|
|
52
56
|
@tier "essential"
|
|
57
|
+
@config.onNodeExpand -> external {
|
|
58
|
+
path : string
|
|
59
|
+
}
|
|
60
|
+
@description "Called the first time a node marked `expandable` is expanded, with its path, so its children can be loaded."
|
|
61
|
+
@tier "essential"
|
|
53
62
|
}
|
|
54
63
|
|
|
55
64
|
config {
|
|
@@ -77,6 +86,14 @@ orbital FileTreeOrbital {
|
|
|
77
86
|
@label "On File Select"
|
|
78
87
|
@description "Called when a file is clicked"
|
|
79
88
|
@tier "presentation"
|
|
89
|
+
onNodeExpand : event = "NODE_EXPAND"
|
|
90
|
+
@label "On Node Expand"
|
|
91
|
+
@description "Called the first time a node marked `expandable` is expanded, with its path, so its children can be loaded."
|
|
92
|
+
@tier "presentation"
|
|
93
|
+
expandedPaths : [string] = []
|
|
94
|
+
@label "Expanded Paths"
|
|
95
|
+
@description "Paths to show expanded (e.g. to reveal a node): each is expanded when it appears here, loading its children if needed."
|
|
96
|
+
@tier "presentation"
|
|
80
97
|
onNodeSelect : event = ""
|
|
81
98
|
@label "On Node Select"
|
|
82
99
|
@description "Called when a node is clicked, in flat `items` mode; carries the selected node's id. Presence-gated: binding this prop is what turns on the click-to-select affordance, mirroring Badge's `onRemove`."
|