@almadar/std 16.187.0 → 16.189.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/lolo/ui/core/.hand-authored.json +4 -4
- package/behaviors/lolo/ui/core/atoms/std-board.lolo +138 -4
- package/behaviors/lolo/ui/core/atoms/std-browse.lolo +148 -8
- package/behaviors/lolo/ui/core/atoms/std-calendar.lolo +161 -11
- package/behaviors/lolo/ui/core/atoms/std-event-log.lolo +255 -2
- package/behaviors/lolo/ui/core/atoms/std-gallery.lolo +148 -1
- package/behaviors/lolo/ui/core/atoms/std-list.lolo +193 -1
- package/behaviors/lolo/ui/core/atoms/std-record-detail.lolo +731 -0
- package/behaviors/lolo/ui/core/atoms/std-related.lolo +5 -1
- package/behaviors/lolo/ui/core/atoms/std-selection.lolo +182 -1
- package/behaviors/lolo/ui/core/atoms/std-tree.lolo +113 -3
- package/behaviors/lolo/ui/core/atoms/std-version-history.lolo +1 -1
- package/behaviors/lolo/ui/core/molecules/ui-document-details.lolo +80 -0
- package/behaviors/lolo/ui/core/molecules/ui-document-panel.lolo +213 -0
- package/behaviors/lolo/ui/core/molecules/{ui-rich-block-editor.lolo → ui-rich-text-editor.lolo} +25 -25
- package/behaviors/lolo/ui/game/atoms/std-area-fill.lolo +93 -0
- package/behaviors/lolo/ui/game/atoms/std-choice-gate.lolo +100 -0
- package/behaviors/lolo/ui/game/atoms/std-coef-pad.lolo +114 -0
- package/behaviors/lolo/ui/game/atoms/std-curve-fog.lolo +50 -0
- package/behaviors/lolo/ui/game/atoms/std-loop-lock.lolo +79 -0
- package/behaviors/lolo/ui/game/atoms/std-pad-lock.lolo +97 -0
- package/behaviors/lolo/ui/game/atoms/std-patrol-hazard.lolo +14 -7
- package/behaviors/lolo/ui/game/atoms/std-platformer-body.lolo +48 -5
- package/behaviors/lolo/ui/game/atoms/std-velocity-gate.lolo +101 -0
- package/behaviors/lolo/ui/game/atoms/std-zone-card.lolo +95 -0
- package/behaviors/lolo/ui/game/organisms/std-platformer-board-2d.lolo +9 -0
- package/behaviors/registry/infra/atoms/std-approval-gate.orb +16 -8
- package/behaviors/registry/infra/atoms/std-cache-aside.orb +62 -31
- package/behaviors/registry/infra/atoms/std-circuit-breaker.orb +32 -16
- package/behaviors/registry/infra/atoms/std-data-erasure.orb +16 -8
- package/behaviors/registry/infra/atoms/std-mod-queue.orb +16 -8
- package/behaviors/registry/infra/atoms/std-rate-limiter.orb +28 -14
- package/behaviors/registry/infra/organisms/std-status-lifecycle-control.orb +2 -1
- package/behaviors/registry/ml/organisms/std-escalating-decision.orb +10 -5
- package/behaviors/registry/ml/organisms/std-knowledge-tracing.orb +4 -2
- package/behaviors/registry/ui/core/atoms/std-billable-hour.orb +2 -1
- package/behaviors/registry/ui/core/atoms/std-board.orb +355 -2
- package/behaviors/registry/ui/core/atoms/std-browse.orb +304 -31
- package/behaviors/registry/ui/core/atoms/std-calendar.orb +393 -25
- package/behaviors/registry/ui/core/atoms/std-dashboard-grid-embedded.orb +2 -1
- package/behaviors/registry/ui/core/atoms/std-esign-flow.orb +4 -2
- package/behaviors/registry/ui/core/atoms/std-esign-request.orb +6 -3
- package/behaviors/registry/ui/core/atoms/std-event-log.orb +773 -0
- package/behaviors/registry/ui/core/atoms/std-export.orb +4 -2
- package/behaviors/registry/ui/core/atoms/std-gallery.orb +390 -0
- package/behaviors/registry/ui/core/atoms/std-import.orb +4 -2
- package/behaviors/registry/ui/core/atoms/std-list.orb +451 -0
- package/behaviors/registry/ui/core/atoms/std-record-detail.orb +3360 -0
- package/behaviors/registry/ui/core/atoms/std-related.orb +23 -1
- package/behaviors/registry/ui/core/atoms/std-selection.orb +436 -0
- package/behaviors/registry/ui/core/atoms/std-tree.orb +292 -1
- package/behaviors/registry/ui/core/atoms/std-version-history.orb +1 -1
- package/behaviors/registry/ui/core/molecules/ui-document-details.orb +342 -0
- package/behaviors/registry/ui/core/molecules/ui-document-panel.orb +655 -0
- package/behaviors/registry/ui/core/molecules/{ui-rich-block-editor.orb → ui-rich-text-editor.orb} +84 -97
- package/behaviors/registry/ui/game/atoms/std-area-fill.orb +955 -0
- package/behaviors/registry/ui/game/atoms/std-choice-gate.orb +855 -0
- package/behaviors/registry/ui/game/atoms/std-coef-pad.orb +928 -0
- package/behaviors/registry/ui/game/atoms/std-curve-fog.orb +337 -0
- package/behaviors/registry/ui/game/atoms/std-fx-trail.orb +1 -1
- package/behaviors/registry/ui/game/atoms/std-gate-lock.orb +1 -1
- package/behaviors/registry/ui/game/atoms/std-lives.orb +1 -1
- package/behaviors/registry/ui/game/atoms/std-loop-lock.orb +785 -0
- package/behaviors/registry/ui/game/atoms/std-pad-lock.orb +933 -0
- package/behaviors/registry/ui/game/atoms/std-patrol-hazard.orb +190 -44
- package/behaviors/registry/ui/game/atoms/std-platformer-body.orb +1330 -653
- package/behaviors/registry/ui/game/atoms/std-velocity-gate.orb +1040 -0
- package/behaviors/registry/ui/game/atoms/std-zone-card.orb +642 -0
- package/behaviors/registry/ui/game/organisms/std-arcade-board-3d.orb +8 -4
- package/behaviors/registry/ui/game/organisms/std-crew-board-2d.orb +6 -3
- package/behaviors/registry/ui/game/organisms/std-dungeon-board-2d.orb +10 -5
- package/behaviors/registry/ui/game/organisms/std-market-board-3d.orb +8 -4
- package/behaviors/registry/ui/game/organisms/std-objective-board-3d.orb +8 -4
- package/behaviors/registry/ui/game/organisms/std-platformer-board-2d.orb +36 -1
- package/behaviors/registry/ui/game/organisms/std-survival-board-3d.orb +8 -4
- package/behaviors/registry/ui/game/organisms/std-tactics-board-2d.orb +12 -6
- package/behaviors/registry/ui/game/organisms/std-tactics-board-3d.orb +8 -4
- package/behaviors/registry/ui/game/organisms/std-worldmap-board-2d.orb +6 -3
- package/behaviors/registry/ui/learning/atoms/std-learn-slope-probe.orb +1 -1
- package/behaviors/registry/ui/marketing/atoms/std-marketing-article.orb +2 -1
- package/behaviors/registry/ui/marketing/atoms/std-marketing-footer.orb +2 -1
- package/behaviors/registry/ui/marketing/atoms/std-marketing-split.orb +2 -1
- package/behaviors/registry/ui/marketing/atoms/std-marketing-stats.orb +2 -1
- package/behaviors/registry/ui/marketing/atoms/std-marketing-steps.orb +2 -1
- package/behaviors/registry/ui/marketing/atoms/std-marketing-team.orb +2 -1
- package/dist/behaviors/exports-reader.js +10971 -6255
- package/dist/behaviors/functions/index.d.ts +1205 -256
- package/dist/behaviors/functions/index.js +10932 -6245
- package/dist/behaviors/index.d.ts +1 -1
- package/dist/behaviors/index.js +10972 -6256
- package/dist/behaviors/query.js +10971 -6255
- package/dist/behaviors-embeddings.hash.json +3 -3
- package/dist/behaviors-embeddings.json +485 -469
- package/dist/behaviors-registry.json +6125 -2940
- package/dist/index.d.ts +1 -1
- package/dist/index.js +10972 -6256
- package/dist/knob-embeddings.hash.json +3 -3
- package/dist/knob-embeddings.json +1 -1
- package/dist/registry/factory-signatures.json +1 -1
- package/package.json +4 -4
- package/behaviors/lolo/ui/core/atoms/std-rich-editor.lolo +0 -790
- package/behaviors/registry/ui/core/atoms/std-rich-editor.orb +0 -2225
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
app std-gallery "1.0.0"
|
|
2
2
|
"std-gallery — image gallery primitive. Browses GalleryItems in a media-gallery grid; opens a lightbox modal for full-size viewing."
|
|
3
|
+
type FilterSpec = { field : string!, label : string, options : [string] }
|
|
3
4
|
orbital GalleryItemOrbital {
|
|
4
5
|
uses Spinner from "std/behaviors/ui-spinner"
|
|
5
6
|
uses Typography from "std/behaviors/ui-typography"
|
|
@@ -103,7 +104,37 @@ orbital GalleryItemOrbital {
|
|
|
103
104
|
direction: horizontal
|
|
104
105
|
gap: sm
|
|
105
106
|
type: stack
|
|
106
|
-
}, @trait.TitleDivider, @
|
|
107
|
+
}, @trait.TitleDivider, (if @config.bodySearch {
|
|
108
|
+
children: [{
|
|
109
|
+
className: "w-full max-w-md"
|
|
110
|
+
clearable: true
|
|
111
|
+
event: REFETCH_QUERY
|
|
112
|
+
placeholder: @config.searchPlaceholder
|
|
113
|
+
type: search-input
|
|
114
|
+
}]
|
|
115
|
+
direction: horizontal
|
|
116
|
+
gap: sm
|
|
117
|
+
type: stack
|
|
118
|
+
} {
|
|
119
|
+
children: []
|
|
120
|
+
gap: none
|
|
121
|
+
type: stack
|
|
122
|
+
}), (if [">", (array/len @config.filters), 0] {
|
|
123
|
+
children: [{
|
|
124
|
+
entity: GalleryItem
|
|
125
|
+
event: REFETCH_FILTER
|
|
126
|
+
filters: @config.filters
|
|
127
|
+
look: @config.filterBarLook
|
|
128
|
+
type: filter-group
|
|
129
|
+
}]
|
|
130
|
+
direction: horizontal
|
|
131
|
+
gap: sm
|
|
132
|
+
type: stack
|
|
133
|
+
} {
|
|
134
|
+
children: []
|
|
135
|
+
gap: none
|
|
136
|
+
type: stack
|
|
137
|
+
}), @trait.MediaGalleryGrid]
|
|
107
138
|
direction: vertical
|
|
108
139
|
gap: md
|
|
109
140
|
type: stack
|
|
@@ -121,6 +152,78 @@ orbital GalleryItemOrbital {
|
|
|
121
152
|
(fetch GalleryItem {
|
|
122
153
|
emit: { failure: GalleryItemLoadFailed, success: GalleryItemLoaded }
|
|
123
154
|
})
|
|
155
|
+
;; REFETCH_* stays in `browsing` and DOES NOT replace the gallery grid
|
|
156
|
+
;; with a spinner — search-as-you-type would otherwise unmount the
|
|
157
|
+
;; media-gallery every keystroke and flicker. The fetch fires in the
|
|
158
|
+
;; background; when GalleryItemLoaded arrives below, React reconciles
|
|
159
|
+
;; the grid in place instead of unmounting it.
|
|
160
|
+
REFETCH_QUERY -> browsing
|
|
161
|
+
(fetch GalleryItem {
|
|
162
|
+
emit: { failure: GalleryItemLoadFailed, success: GalleryItemLoaded }
|
|
163
|
+
filter: (or ["=", ?searchTerm, ""] (str/includes (object/get @entity name) ?searchTerm))
|
|
164
|
+
limit: @config.pageSize
|
|
165
|
+
offset: 0
|
|
166
|
+
})
|
|
167
|
+
REFETCH_FILTER -> browsing
|
|
168
|
+
(fetch GalleryItem {
|
|
169
|
+
emit: { failure: GalleryItemLoadFailed, success: GalleryItemLoaded }
|
|
170
|
+
filter: (or ["=", ?value, ""] ["=", (object/get @entity ?field), ?value])
|
|
171
|
+
limit: @config.pageSize
|
|
172
|
+
offset: 0
|
|
173
|
+
})
|
|
174
|
+
REFETCH_PAGE -> browsing
|
|
175
|
+
(fetch GalleryItem {
|
|
176
|
+
emit: { failure: GalleryItemLoadFailed, success: GalleryItemLoaded }
|
|
177
|
+
limit: @config.pageSize
|
|
178
|
+
offset: ["*", ["-", ?page, 1], @config.pageSize]
|
|
179
|
+
})
|
|
180
|
+
GalleryItemLoaded -> browsing
|
|
181
|
+
(render-ui main {
|
|
182
|
+
children: [{
|
|
183
|
+
align: center
|
|
184
|
+
children: [@trait.GalleryIcon, {
|
|
185
|
+
content: @config.title
|
|
186
|
+
type: typography
|
|
187
|
+
variant: h3
|
|
188
|
+
}]
|
|
189
|
+
direction: horizontal
|
|
190
|
+
gap: sm
|
|
191
|
+
type: stack
|
|
192
|
+
}, @trait.TitleDivider, (if @config.bodySearch {
|
|
193
|
+
children: [{
|
|
194
|
+
className: "w-full max-w-md"
|
|
195
|
+
clearable: true
|
|
196
|
+
event: REFETCH_QUERY
|
|
197
|
+
placeholder: @config.searchPlaceholder
|
|
198
|
+
type: search-input
|
|
199
|
+
}]
|
|
200
|
+
direction: horizontal
|
|
201
|
+
gap: sm
|
|
202
|
+
type: stack
|
|
203
|
+
} {
|
|
204
|
+
children: []
|
|
205
|
+
gap: none
|
|
206
|
+
type: stack
|
|
207
|
+
}), (if [">", (array/len @config.filters), 0] {
|
|
208
|
+
children: [{
|
|
209
|
+
entity: GalleryItem
|
|
210
|
+
event: REFETCH_FILTER
|
|
211
|
+
filters: @config.filters
|
|
212
|
+
look: @config.filterBarLook
|
|
213
|
+
type: filter-group
|
|
214
|
+
}]
|
|
215
|
+
direction: horizontal
|
|
216
|
+
gap: sm
|
|
217
|
+
type: stack
|
|
218
|
+
} {
|
|
219
|
+
children: []
|
|
220
|
+
gap: none
|
|
221
|
+
type: stack
|
|
222
|
+
}), @trait.MediaGalleryGrid]
|
|
223
|
+
direction: vertical
|
|
224
|
+
gap: md
|
|
225
|
+
type: stack
|
|
226
|
+
})
|
|
124
227
|
VIEW -> viewing
|
|
125
228
|
(set @entity.id ?id)
|
|
126
229
|
(render-ui modal {
|
|
@@ -195,6 +298,25 @@ orbital GalleryItemOrbital {
|
|
|
195
298
|
}
|
|
196
299
|
|
|
197
300
|
listens {
|
|
301
|
+
REFETCH_QUERY {
|
|
302
|
+
searchTerm : string!
|
|
303
|
+
}
|
|
304
|
+
@description "Triggers a gallery refresh based on the current search query."
|
|
305
|
+
@synonyms "refresh, reload, update, re-query"
|
|
306
|
+
@tier "domain"
|
|
307
|
+
REFETCH_FILTER {
|
|
308
|
+
field : string!
|
|
309
|
+
value : string!
|
|
310
|
+
}
|
|
311
|
+
@description "Triggers a gallery refresh based on current filter criteria."
|
|
312
|
+
@synonyms "refresh, filter, update, reload"
|
|
313
|
+
@tier "domain"
|
|
314
|
+
REFETCH_PAGE {
|
|
315
|
+
page : number!
|
|
316
|
+
}
|
|
317
|
+
@description "Triggers a gallery page refresh."
|
|
318
|
+
@synonyms "reload, refresh, update, paginate"
|
|
319
|
+
@tier "domain"
|
|
198
320
|
VIEW {
|
|
199
321
|
id : string!
|
|
200
322
|
row : GalleryItem
|
|
@@ -236,6 +358,31 @@ orbital GalleryItemOrbital {
|
|
|
236
358
|
@description "Entity field holding the image URL shown in the lightbox for the selected item"
|
|
237
359
|
@synonyms "image url field, thumbnail field, src field"
|
|
238
360
|
@tier "presentation"
|
|
361
|
+
bodySearch : boolean = false
|
|
362
|
+
@label "Show the gallery's own search box?"
|
|
363
|
+
@description "Embeds a search box above the gallery grid. Set false (the default) when the page already provides a search affordance (a toolbar Search molecule), so the surface shows one search box instead of two."
|
|
364
|
+
@synonyms "inline search, list search, built-in search, show search, duplicate search"
|
|
365
|
+
@tier "presentation"
|
|
366
|
+
searchPlaceholder : string = "Search…"
|
|
367
|
+
@label "Search box placeholder text"
|
|
368
|
+
@description "Hint text inside the gallery search box (e.g. 'Search photos…')."
|
|
369
|
+
@synonyms "search hint, placeholder, search box text, search label"
|
|
370
|
+
@tier "presentation"
|
|
371
|
+
filters : [FilterSpec] = []
|
|
372
|
+
@label "Which filters should appear above the gallery?"
|
|
373
|
+
@description "Dropdown filter facets by field, rendered as an embedded filter bar above the grid; each selection fires REFETCH_FILTER on this trait. Empty (the default) = no filter bar, which is the right setting whenever the page already composes std-filter beside this gallery and routes `XFilter.FILTER -> REFETCH_FILTER` — that is the wired owner and remains the primary path. Use this knob only for a standalone gallery with no page-level filter affordance."
|
|
374
|
+
@synonyms "filter bar, faceted filters, field filters, dropdowns"
|
|
375
|
+
@tier "presentation"
|
|
376
|
+
filterBarLook : "toolbar" | "chips" | "pills" | "popover-trigger" | "inline-column-header" = toolbar
|
|
377
|
+
@label "Filter bar look"
|
|
378
|
+
@description "Visual treatment for the embedded filter bar, mirroring std-filter's own enum. Only applies when `filters` is non-empty."
|
|
379
|
+
@synonyms "filter bar style, facet style, chips, pills"
|
|
380
|
+
@tier "presentation"
|
|
381
|
+
pageSize : number = 20
|
|
382
|
+
@label "How many images to fetch per page?"
|
|
383
|
+
@description "Records fetched from the server when REFETCH_PAGE fires (a composed std-pagination driving this trait). The initial load and revisit fetches stay unpaged (whole collection), unchanged from before this knob existed."
|
|
384
|
+
@synonyms "fetch limit, records per page, batch size, page limit"
|
|
385
|
+
@tier "presentation"
|
|
239
386
|
}
|
|
240
387
|
}
|
|
241
388
|
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
app std-list "1.0.0"
|
|
2
2
|
"std-list as a Function"
|
|
3
|
+
type FilterSpec = { field : string!, label : string, options : [string] }
|
|
3
4
|
;;
|
|
4
5
|
;; Daisy-chain composition showcase: no `on EVENT { ... }` trait-ref overrides.
|
|
5
6
|
;; Modal + Confirmation trait refs are configured via `config: { ... }` at the
|
|
@@ -71,7 +72,37 @@ orbital ListItemOrbital {
|
|
|
71
72
|
gap: md
|
|
72
73
|
justify: between
|
|
73
74
|
type: stack
|
|
74
|
-
}, { type: divider }, {
|
|
75
|
+
}, { type: divider }, (if @config.bodySearch {
|
|
76
|
+
children: [{
|
|
77
|
+
className: "w-full max-w-md"
|
|
78
|
+
clearable: true
|
|
79
|
+
event: REFETCH_QUERY
|
|
80
|
+
placeholder: @config.searchPlaceholder
|
|
81
|
+
type: search-input
|
|
82
|
+
}]
|
|
83
|
+
direction: horizontal
|
|
84
|
+
gap: sm
|
|
85
|
+
type: stack
|
|
86
|
+
} {
|
|
87
|
+
children: []
|
|
88
|
+
gap: none
|
|
89
|
+
type: stack
|
|
90
|
+
}), (if [">", (array/len @config.filters), 0] {
|
|
91
|
+
children: [{
|
|
92
|
+
entity: ListItem
|
|
93
|
+
event: REFETCH_FILTER
|
|
94
|
+
filters: @config.filters
|
|
95
|
+
look: @config.filterBarLook
|
|
96
|
+
type: filter-group
|
|
97
|
+
}]
|
|
98
|
+
direction: horizontal
|
|
99
|
+
gap: sm
|
|
100
|
+
type: stack
|
|
101
|
+
} {
|
|
102
|
+
children: []
|
|
103
|
+
gap: none
|
|
104
|
+
type: stack
|
|
105
|
+
}), {
|
|
75
106
|
entity: ?data
|
|
76
107
|
fields: [{
|
|
77
108
|
icon: list
|
|
@@ -96,6 +127,7 @@ orbital ListItemOrbital {
|
|
|
96
127
|
label: Delete
|
|
97
128
|
variant: danger
|
|
98
129
|
}]
|
|
130
|
+
pageSize: @config.displayPageSize
|
|
99
131
|
type: data-grid
|
|
100
132
|
}]
|
|
101
133
|
className: "max-w-5xl mx-auto w-full"
|
|
@@ -139,6 +171,114 @@ orbital ListItemOrbital {
|
|
|
139
171
|
emit: { failure: ListItemLoadFailed, success: ListItemLoaded }
|
|
140
172
|
})
|
|
141
173
|
(render-ui main { type: spinner })
|
|
174
|
+
;; REFETCH_* stays in `browsing` and DOES NOT replace the grid with a
|
|
175
|
+
;; spinner — same reasoning as std-browse's REFETCH_* arms: a skeleton
|
|
176
|
+
;; on refetch unmounts the grid and flickers every keystroke. The fetch
|
|
177
|
+
;; fires in the background; the ListItemLoaded arm below re-renders in
|
|
178
|
+
;; place once it lands.
|
|
179
|
+
REFETCH_QUERY -> browsing
|
|
180
|
+
(fetch ListItem {
|
|
181
|
+
emit: { failure: ListItemLoadFailed, success: ListItemLoaded }
|
|
182
|
+
filter: (or ["=", ?searchTerm, ""] (str/includes (object/get @entity name) ?searchTerm))
|
|
183
|
+
})
|
|
184
|
+
REFETCH_FILTER -> browsing
|
|
185
|
+
(fetch ListItem {
|
|
186
|
+
emit: { failure: ListItemLoadFailed, success: ListItemLoaded }
|
|
187
|
+
filter: (or ["=", ?value, ""] ["=", (object/get @entity ?field), ?value])
|
|
188
|
+
})
|
|
189
|
+
;; No filter carried over on REFETCH_PAGE, mirroring std-browse exactly.
|
|
190
|
+
REFETCH_PAGE -> browsing
|
|
191
|
+
(fetch ListItem {
|
|
192
|
+
emit: { failure: ListItemLoadFailed, success: ListItemLoaded }
|
|
193
|
+
limit: @config.pageSize
|
|
194
|
+
offset: ["*", ["-", ?page, 1], @config.pageSize]
|
|
195
|
+
})
|
|
196
|
+
ListItemLoaded -> browsing
|
|
197
|
+
(render-ui main {
|
|
198
|
+
children: [{
|
|
199
|
+
children: [{
|
|
200
|
+
children: [{ name: list, type: icon }, {
|
|
201
|
+
content: ListItems
|
|
202
|
+
type: typography
|
|
203
|
+
variant: h2
|
|
204
|
+
}]
|
|
205
|
+
direction: horizontal
|
|
206
|
+
gap: md
|
|
207
|
+
type: stack
|
|
208
|
+
}, {
|
|
209
|
+
action: CREATE
|
|
210
|
+
icon: plus
|
|
211
|
+
label: Create
|
|
212
|
+
type: button
|
|
213
|
+
variant: primary
|
|
214
|
+
}]
|
|
215
|
+
direction: horizontal
|
|
216
|
+
gap: md
|
|
217
|
+
justify: between
|
|
218
|
+
type: stack
|
|
219
|
+
}, { type: divider }, (if @config.bodySearch {
|
|
220
|
+
children: [{
|
|
221
|
+
className: "w-full max-w-md"
|
|
222
|
+
clearable: true
|
|
223
|
+
event: REFETCH_QUERY
|
|
224
|
+
placeholder: @config.searchPlaceholder
|
|
225
|
+
type: search-input
|
|
226
|
+
}]
|
|
227
|
+
direction: horizontal
|
|
228
|
+
gap: sm
|
|
229
|
+
type: stack
|
|
230
|
+
} {
|
|
231
|
+
children: []
|
|
232
|
+
gap: none
|
|
233
|
+
type: stack
|
|
234
|
+
}), (if [">", (array/len @config.filters), 0] {
|
|
235
|
+
children: [{
|
|
236
|
+
entity: ListItem
|
|
237
|
+
event: REFETCH_FILTER
|
|
238
|
+
filters: @config.filters
|
|
239
|
+
look: @config.filterBarLook
|
|
240
|
+
type: filter-group
|
|
241
|
+
}]
|
|
242
|
+
direction: horizontal
|
|
243
|
+
gap: sm
|
|
244
|
+
type: stack
|
|
245
|
+
} {
|
|
246
|
+
children: []
|
|
247
|
+
gap: none
|
|
248
|
+
type: stack
|
|
249
|
+
}), {
|
|
250
|
+
entity: ?data
|
|
251
|
+
fields: [{
|
|
252
|
+
icon: list
|
|
253
|
+
label: Name
|
|
254
|
+
name: name
|
|
255
|
+
variant: h4
|
|
256
|
+
}, {
|
|
257
|
+
label: Description
|
|
258
|
+
name: description
|
|
259
|
+
variant: caption
|
|
260
|
+
}, {
|
|
261
|
+
label: Status
|
|
262
|
+
name: status
|
|
263
|
+
variant: badge
|
|
264
|
+
}]
|
|
265
|
+
itemActions: [{
|
|
266
|
+
event: EDIT
|
|
267
|
+
label: Edit
|
|
268
|
+
variant: ghost
|
|
269
|
+
}, {
|
|
270
|
+
event: DELETE
|
|
271
|
+
label: Delete
|
|
272
|
+
variant: danger
|
|
273
|
+
}]
|
|
274
|
+
pageSize: @config.displayPageSize
|
|
275
|
+
type: data-grid
|
|
276
|
+
}]
|
|
277
|
+
className: "max-w-5xl mx-auto w-full"
|
|
278
|
+
direction: vertical
|
|
279
|
+
gap: lg
|
|
280
|
+
type: stack
|
|
281
|
+
})
|
|
142
282
|
}
|
|
143
283
|
|
|
144
284
|
state error {
|
|
@@ -190,6 +330,58 @@ orbital ListItemOrbital {
|
|
|
190
330
|
ListItemPersistor.ITEM_CREATED -> INIT
|
|
191
331
|
ListItemPersistor.ITEM_UPDATED -> INIT
|
|
192
332
|
ListItemPersistor.ITEM_DELETED -> INIT
|
|
333
|
+
REFETCH_QUERY {
|
|
334
|
+
searchTerm : string!
|
|
335
|
+
}
|
|
336
|
+
@description "Triggers a list refresh based on the current search term."
|
|
337
|
+
@synonyms "refresh, reload, update, re-query, search"
|
|
338
|
+
@tier "domain"
|
|
339
|
+
REFETCH_FILTER {
|
|
340
|
+
field : string!
|
|
341
|
+
value : string!
|
|
342
|
+
}
|
|
343
|
+
@description "Triggers a list refresh based on current filter criteria."
|
|
344
|
+
@synonyms "refresh, filter, update, reload"
|
|
345
|
+
@tier "domain"
|
|
346
|
+
REFETCH_PAGE {
|
|
347
|
+
page : number!
|
|
348
|
+
}
|
|
349
|
+
@description "Triggers a list page refresh."
|
|
350
|
+
@synonyms "reload, refresh, update, paginate"
|
|
351
|
+
@tier "domain"
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
config {
|
|
355
|
+
bodySearch : boolean = false
|
|
356
|
+
@label "Show the list's own search box?"
|
|
357
|
+
@description "Embeds a search box above the grid. Set true only when the page has no other search affordance (e.g. no page-level std-search), so the surface shows one search box instead of two. False is the default — this atom has never had a search box (0 consumers today)."
|
|
358
|
+
@synonyms "inline search, list search, built-in search, show search"
|
|
359
|
+
@tier "presentation"
|
|
360
|
+
searchPlaceholder : string = "Search…"
|
|
361
|
+
@label "Search box placeholder text"
|
|
362
|
+
@description "Hint text inside the list search box."
|
|
363
|
+
@synonyms "search hint, placeholder, search box text"
|
|
364
|
+
@tier "presentation"
|
|
365
|
+
filters : [FilterSpec] = []
|
|
366
|
+
@label "Which filters should appear above the grid?"
|
|
367
|
+
@description "Dropdown filter facets by field, rendered as an embedded filter bar above the rows; each selection fires REFETCH_FILTER on this trait. Empty (the default) = no filter bar, the right setting whenever the page already composes std-filter beside this list and routes XFilter.FILTER -> REFETCH_FILTER — that is the wired owner and remains the primary path. Use this knob only for a standalone list with no page-level filter affordance."
|
|
368
|
+
@synonyms "filter bar, faceted filters, field filters, dropdowns"
|
|
369
|
+
@tier "presentation"
|
|
370
|
+
filterBarLook : "toolbar" | "chips" | "pills" | "popover-trigger" | "inline-column-header" = toolbar
|
|
371
|
+
@label "Filter bar look"
|
|
372
|
+
@description "Visual treatment for the embedded filter bar, mirroring std-filter's own enum. Only applies when `filters` is non-empty."
|
|
373
|
+
@synonyms "filter bar style, facet style, chips, pills"
|
|
374
|
+
@tier "presentation"
|
|
375
|
+
pageSize : number = 20
|
|
376
|
+
@label "How many rows per page when paging?"
|
|
377
|
+
@description "Records fetched from the server per REFETCH_PAGE request. The initial load and search/filter refetches remain unpaginated (load everything that matches) unless a consumer wires REFETCH_PAGE, so the default list surface is unchanged."
|
|
378
|
+
@synonyms "fetch limit, records per page, page limit"
|
|
379
|
+
@tier "presentation"
|
|
380
|
+
displayPageSize : number = 20
|
|
381
|
+
@label "How many rows to show at once?"
|
|
382
|
+
@description "Rows visible per page before the data-grid's own pagination control appears — 20 matches the CRUD-list density sweet spot (Miller's law, 10-25 rows)."
|
|
383
|
+
@synonyms "visible rows, items per page, display limit, show per page"
|
|
384
|
+
@tier "presentation"
|
|
193
385
|
}
|
|
194
386
|
}
|
|
195
387
|
|