@zeyos/zx 5.7.1 → 5.8.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/CHANGELOG.md +296 -0
- package/README.md +47 -9
- package/dist/types/components/activity-item/activity-item.d.ts +14 -3
- package/dist/types/components/agent-avatar/agent-avatar.d.ts +165 -0
- package/dist/types/components/agent-avatar/agent-face.d.ts +93 -0
- package/dist/types/components/agent-thread/ag-ui.d.ts +21 -9
- package/dist/types/components/agent-thread/agent-thread.d.ts +26 -0
- package/dist/types/components/agent-thread/ui-message-stream.d.ts +3 -1
- package/dist/types/components/approval-card/approval-card.d.ts +31 -2
- package/dist/types/components/aurora/aurora.d.ts +31 -5
- package/dist/types/components/calendar/calendar.d.ts +39 -26
- package/dist/types/components/chart/chart.d.ts +250 -20
- package/dist/types/components/chart/color.d.ts +66 -0
- package/dist/types/components/chart/svg-adapter.d.ts +103 -0
- package/dist/types/components/chart/svg-geometry.d.ts +203 -0
- package/dist/types/components/check-button/check-button.d.ts +1 -4
- package/dist/types/components/checklist/checklist.d.ts +19 -5
- package/dist/types/components/code-editor/code-editor.d.ts +55 -1
- package/dist/types/components/composer/composer.d.ts +41 -6
- package/dist/types/components/context-menu/context-menu.d.ts +36 -8
- package/dist/types/components/copy/copy-button.d.ts +6 -0
- package/dist/types/components/copy/copy-input.d.ts +1 -0
- package/dist/types/components/date-picker/date-picker.d.ts +14 -0
- package/dist/types/components/date-picker/time-picker.d.ts +26 -17
- package/dist/types/components/datebox/datebox.d.ts +8 -4
- package/dist/types/components/dialog/dialog.d.ts +13 -2
- package/dist/types/components/empty-state/empty-state.d.ts +10 -1
- package/dist/types/components/field/field.d.ts +4 -2
- package/dist/types/components/form/form.d.ts +2 -1
- package/dist/types/components/kanban-view/kanban-card.d.ts +7 -0
- package/dist/types/components/kanban-view/kanban-view.d.ts +15 -3
- package/dist/types/components/launcher/launcher.d.ts +26 -0
- package/dist/types/components/master-panel/master-panel.d.ts +9 -4
- package/dist/types/components/menu-button/menu-button.d.ts +29 -5
- package/dist/types/components/message/message.d.ts +308 -5
- package/dist/types/components/modal/modal.d.ts +11 -0
- package/dist/types/components/modal/native-dialog.d.ts +40 -0
- package/dist/types/components/module-bar/module-bar.d.ts +9 -2
- package/dist/types/components/multi-value-editor/multi-value-editor.d.ts +5 -4
- package/dist/types/components/number-field/number-field.d.ts +7 -0
- package/dist/types/components/pagination/pagination.d.ts +341 -19
- package/dist/types/components/run-status/run-status.d.ts +26 -0
- package/dist/types/components/run-trace/run-trace.d.ts +10 -6
- package/dist/types/components/search/search.d.ts +16 -4
- package/dist/types/components/select/select.d.ts +19 -1
- package/dist/types/components/sheet/sheet.d.ts +18 -4
- package/dist/types/components/slider/slider.d.ts +2 -1
- package/dist/types/components/stat-tile/stat-tile.d.ts +20 -3
- package/dist/types/components/stepper/stepper.d.ts +17 -4
- package/dist/types/components/surface/catalog.d.ts +61 -17
- package/dist/types/components/surface/surface.d.ts +6 -4
- package/dist/types/components/table/table.d.ts +207 -5
- package/dist/types/components/table/window.d.ts +25 -1
- package/dist/types/components/toggle/toggle.d.ts +38 -6
- package/dist/types/components/tooltip/tooltip.d.ts +5 -4
- package/dist/types/components/tree/tree.d.ts +43 -6
- package/dist/types/components/truncate/truncate.d.ts +4 -2
- package/dist/types/components/value-list/value-list.d.ts +9 -2
- package/dist/types/core/date.d.ts +2 -1
- package/dist/types/core/drag-axis.d.ts +10 -5
- package/dist/types/core/export.d.ts +2 -2
- package/dist/types/core/format.d.ts +3 -1
- package/dist/types/core/icons.d.ts +36 -3
- package/dist/types/core/keyboard.d.ts +7 -3
- package/dist/types/core/messages.d.ts +3 -0
- package/dist/types/core/storage.d.ts +4 -3
- package/dist/types/core/util.d.ts +3 -1
- package/dist/types/elements/define.d.ts +5 -2
- package/dist/types/index.d.ts +6 -4
- package/dist/types/internal/agent-model.d.ts +99 -0
- package/dist/types/internal/app-rail.d.ts +37 -2
- package/dist/types/internal/collections.d.ts +18 -0
- package/dist/types/internal/menu-items.d.ts +27 -0
- package/dist/types/internal/overlay-content.d.ts +23 -0
- package/dist/types/internal/presence-loop.d.ts +5 -2
- package/dist/types/locales/index.d.ts +3 -0
- package/dist/types/zeyos/calendar.d.ts +43 -7
- package/dist/types/zeyos/connect.d.ts +4 -0
- package/dist/types/zeyos/form.d.ts +13 -5
- package/dist/types/zeyos/select.d.ts +5 -2
- package/dist/types/zeyos/table.d.ts +16 -8
- package/dist/types/zeyos/view.d.ts +2 -1
- package/dist/zx-zeyos.esm.js +2998 -451
- package/dist/zx-zeyos.esm.min.js +4 -4
- package/dist/zx.core.css +4 -0
- package/dist/zx.core.min.css +1 -1
- package/dist/zx.css +948 -48
- package/dist/zx.esm.js +7432 -3408
- package/dist/zx.esm.min.js +26 -26
- package/dist/zx.global.js +7432 -3408
- package/dist/zx.global.min.js +26 -26
- package/dist/zx.layered.css +950 -48
- package/dist/zx.layered.min.css +1 -1
- package/dist/zx.min.css +1 -1
- package/docs/agent-catalog.json +159 -1
- package/docs/agent-surfaces.md +21 -21
- package/docs/api.json +3122 -528
- package/docs/components/account-menu.md +24 -0
- package/docs/components/activity-item.md +23 -0
- package/docs/components/activity-list.md +28 -0
- package/docs/components/agent-avatar.md +59 -0
- package/docs/components/agent-thread.md +275 -0
- package/docs/components/app-icon.md +36 -0
- package/docs/components/app-sidebar.md +92 -0
- package/docs/components/approval-card.md +71 -0
- package/docs/components/aurora.md +34 -0
- package/docs/components/avatar.md +37 -0
- package/docs/components/badge.md +36 -0
- package/docs/components/block-view.md +34 -0
- package/docs/components/breadcrumb.md +20 -0
- package/docs/components/button.md +23 -0
- package/docs/components/calendar.md +68 -0
- package/docs/components/card-view.md +73 -0
- package/docs/components/card.md +25 -0
- package/docs/components/chart.md +109 -0
- package/docs/components/check-button.md +16 -0
- package/docs/components/checklist.md +19 -0
- package/docs/components/code-editor.md +38 -0
- package/docs/components/composer.md +107 -0
- package/docs/components/context-menu.md +32 -0
- package/docs/components/copy.md +37 -0
- package/docs/components/data-filter.md +16 -0
- package/docs/components/date-picker.md +31 -0
- package/docs/components/date-range.md +21 -0
- package/docs/components/datebox.md +31 -0
- package/docs/components/dialog.md +25 -0
- package/docs/components/dock.md +57 -0
- package/docs/components/dropdown.md +39 -0
- package/docs/components/elements.md +63 -0
- package/docs/components/empty-state.md +17 -0
- package/docs/components/entity-ref.md +26 -0
- package/docs/components/field-upload.md +18 -0
- package/docs/components/file-item.md +27 -0
- package/docs/components/file-list.md +23 -0
- package/docs/components/filter-panel.md +45 -0
- package/docs/components/filter.md +47 -0
- package/docs/components/finder.md +25 -0
- package/docs/components/form-widgets.md +42 -0
- package/docs/components/form.md +80 -0
- package/docs/components/grid.md +26 -0
- package/docs/components/groupbox.md +11 -0
- package/docs/components/helpers.md +359 -0
- package/docs/components/icons.md +87 -0
- package/docs/components/index.md +99 -0
- package/docs/components/kanban-view.md +42 -0
- package/docs/components/kbd.md +23 -0
- package/docs/components/kernel.md +41 -0
- package/docs/components/launcher.md +66 -0
- package/docs/components/layout.md +33 -0
- package/docs/components/list-toolbar.md +38 -0
- package/docs/components/loading.md +48 -0
- package/docs/components/menu-button.md +47 -0
- package/docs/components/message.md +76 -0
- package/docs/components/modal.md +27 -0
- package/docs/components/module-bar.md +71 -0
- package/docs/components/multi-value-editor.md +16 -0
- package/docs/components/navigation-bar.md +22 -0
- package/docs/components/number-field.md +34 -0
- package/docs/components/pagination.md +73 -0
- package/docs/components/panel.md +28 -0
- package/docs/components/prompt-starters.md +40 -0
- package/docs/components/prose.md +38 -0
- package/docs/components/questionnaire.md +115 -0
- package/docs/components/rating.md +19 -0
- package/docs/components/run-status.md +50 -0
- package/docs/components/run-trace.md +72 -0
- package/docs/components/search.md +11 -0
- package/docs/components/select.md +129 -0
- package/docs/components/sheet-stack.md +39 -0
- package/docs/components/sheet.md +77 -0
- package/docs/components/skeleton.md +27 -0
- package/docs/components/slider.md +29 -0
- package/docs/components/sort-control.md +21 -0
- package/docs/components/source-list.md +30 -0
- package/docs/components/split-view.md +12 -0
- package/docs/components/stat-tile.md +49 -0
- package/docs/components/stepper.md +27 -0
- package/docs/components/surface.md +152 -0
- package/docs/components/tabbox.md +33 -0
- package/docs/components/table-view.md +43 -0
- package/docs/components/table.md +232 -0
- package/docs/components/tag-picker.md +39 -0
- package/docs/components/timebox.md +16 -0
- package/docs/components/toggle.md +21 -0
- package/docs/components/tokens.md +82 -0
- package/docs/components/toolbar.md +26 -0
- package/docs/components/tooltip.md +16 -0
- package/docs/components/tree.md +48 -0
- package/docs/components/truncate.md +21 -0
- package/docs/components/value-list.md +14 -0
- package/docs/components/view-settings.md +56 -0
- package/docs/components/workspace-switcher.md +42 -0
- package/docs/components/zeyos.md +196 -0
- package/docs/llms-small.txt +299 -0
- package/docs/llms.md +697 -100
- package/docs/llms.txt +46 -19
- package/package.json +9 -4
- package/src/components/activity-item/activity-item.js +21 -2
- package/src/components/agent-avatar/agent-avatar.css +195 -0
- package/src/components/agent-avatar/agent-avatar.js +333 -0
- package/src/components/agent-avatar/agent-face.js +292 -0
- package/src/components/agent-thread/ag-ui.js +44 -11
- package/src/components/agent-thread/agent-thread.js +103 -11
- package/src/components/agent-thread/ui-message-stream.js +3 -1
- package/src/components/app-rail/app-rail.css +5 -0
- package/src/components/app-sidebar/app-sidebar.css +3 -0
- package/src/components/app-sidebar/app-sidebar.js +4 -3
- package/src/components/approval-card/approval-card.css +6 -0
- package/src/components/approval-card/approval-card.js +55 -7
- package/src/components/aurora/aurora.css +149 -14
- package/src/components/aurora/aurora.js +49 -6
- package/src/components/calendar/calendar.css +6 -2
- package/src/components/calendar/calendar.js +127 -47
- package/src/components/card-view/card-view.js +5 -6
- package/src/components/chart/chart.css +159 -1
- package/src/components/chart/chart.js +450 -62
- package/src/components/chart/color.js +297 -0
- package/src/components/chart/svg-adapter.js +576 -0
- package/src/components/chart/svg-geometry.js +323 -0
- package/src/components/check-button/check-button.js +3 -18
- package/src/components/checklist/checklist.js +46 -17
- package/src/components/checklist/field-adapter.js +4 -1
- package/src/components/code-editor/code-editor.css +33 -0
- package/src/components/code-editor/code-editor.js +97 -8
- package/src/components/code-editor/field-adapter.js +3 -0
- package/src/components/composer/composer.css +3 -0
- package/src/components/composer/composer.js +100 -22
- package/src/components/context-menu/context-menu.js +41 -5
- package/src/components/copy/copy-button.js +9 -1
- package/src/components/copy/copy-input.js +5 -0
- package/src/components/data-filter/filter-core.js +0 -1
- package/src/components/date-picker/date-picker.css +8 -0
- package/src/components/date-picker/date-picker.js +47 -8
- package/src/components/date-picker/date-range-picker.js +1 -1
- package/src/components/date-picker/month-picker.js +19 -3
- package/src/components/date-picker/time-picker.js +54 -19
- package/src/components/datebox/date-range-box.js +7 -3
- package/src/components/datebox/datebox.js +32 -6
- package/src/components/dialog/dialog.css +6 -0
- package/src/components/dialog/dialog.js +22 -30
- package/src/components/dropdown/dropdown.js +1 -18
- package/src/components/empty-state/empty-state.js +21 -2
- package/src/components/field/field.js +19 -3
- package/src/components/fieldset/fieldset.js +3 -1
- package/src/components/filter/filter.js +9 -0
- package/src/components/form/form.js +19 -2
- package/src/components/kanban-view/kanban-card.js +15 -2
- package/src/components/kanban-view/kanban-view.css +21 -0
- package/src/components/kanban-view/kanban-view.js +29 -16
- package/src/components/launcher/launcher.css +14 -0
- package/src/components/launcher/launcher.js +54 -9
- package/src/components/master-panel/master-panel.js +24 -22
- package/src/components/menu-button/menu-button.js +26 -4
- package/src/components/message/message.css +228 -29
- package/src/components/message/message.js +664 -30
- package/src/components/modal/modal.js +70 -25
- package/src/components/modal/native-dialog.js +91 -0
- package/src/components/module-bar/module-bar.css +3 -0
- package/src/components/module-bar/module-bar.js +17 -4
- package/src/components/multi-value-editor/multi-value-editor.css +7 -2
- package/src/components/multi-value-editor/multi-value-editor.js +3 -2
- package/src/components/navigation-bar/navigation-bar.js +13 -1
- package/src/components/number-field/field-adapter.js +3 -0
- package/src/components/number-field/number-field.js +2 -1
- package/src/components/pagination/pagination.css +26 -2
- package/src/components/pagination/pagination.js +551 -65
- package/src/components/prose/prose.js +7 -1
- package/src/components/rating/field-adapter.js +3 -0
- package/src/components/run-status/run-status.js +43 -3
- package/src/components/run-trace/run-trace.js +15 -7
- package/src/components/search/search.js +3 -18
- package/src/components/select/field-adapter.js +8 -1
- package/src/components/select/select.js +68 -13
- package/src/components/sheet/sheet.js +27 -8
- package/src/components/slider/field-adapter.js +3 -0
- package/src/components/slider/slider.js +4 -6
- package/src/components/stat-tile/stat-tile.js +24 -9
- package/src/components/stepper/stepper.css +15 -0
- package/src/components/stepper/stepper.js +34 -2
- package/src/components/surface/catalog.js +185 -28
- package/src/components/surface/surface.js +10 -5
- package/src/components/tabbox/tabbox.js +13 -1
- package/src/components/table/table.css +160 -2
- package/src/components/table/table.js +479 -52
- package/src/components/table/window.js +46 -4
- package/src/components/table-view/table-view.js +1 -10
- package/src/components/tag-picker/field-adapter.js +3 -0
- package/src/components/tag-picker/tag-picker.js +2 -0
- package/src/components/timebox/field-adapter.js +3 -0
- package/src/components/toggle/toggle.js +51 -27
- package/src/components/tooltip/tooltip.js +21 -14
- package/src/components/tree/tree.js +87 -14
- package/src/components/truncate/truncate.js +21 -5
- package/src/components/value-list/value-list.js +37 -9
- package/src/components/view-settings/view-settings.js +1 -5
- package/src/core/component.js +34 -2
- package/src/core/date.js +5 -4
- package/src/core/drag-axis.js +24 -7
- package/src/core/export.js +4 -4
- package/src/core/fontawesome.js +34 -3
- package/src/core/format.js +3 -1
- package/src/core/http.js +23 -11
- package/src/core/icons.js +51 -10
- package/src/core/keyboard.js +83 -9
- package/src/core/messages.js +3 -0
- package/src/core/position.js +2 -2
- package/src/core/storage.js +80 -31
- package/src/core/util.js +16 -5
- package/src/elements/define.js +82 -47
- package/src/elements/kit.js +46 -35
- package/src/index.js +8 -4
- package/src/internal/agent-model.js +152 -0
- package/src/internal/app-rail.js +53 -2
- package/src/internal/collections.js +25 -0
- package/src/internal/menu-items.js +59 -0
- package/src/internal/overlay-content.js +35 -0
- package/src/internal/presence-loop.js +61 -14
- package/src/locales/de.js +3 -0
- package/src/zeyos/calendar.js +81 -19
- package/src/zeyos/connect.js +5 -1
- package/src/zeyos/form.js +29 -10
- package/src/zeyos/select.js +36 -12
- package/src/zeyos/table.js +43 -11
- package/src/zeyos/view.js +2 -1
- package/styles/tokens/semantic.css +7 -1
- package/styles/zx.css +1 -0
|
@@ -21,11 +21,13 @@ export type DateboxOptions = {
|
|
|
21
21
|
*/
|
|
22
22
|
time?: boolean;
|
|
23
23
|
/**
|
|
24
|
-
* Earliest selectable date.
|
|
24
|
+
* Earliest selectable date. Bounds are whole local calendar days,
|
|
25
|
+
* as in the calendar: with `time`, any time on the `min` day is allowed.
|
|
25
26
|
*/
|
|
26
27
|
min?: Date | null;
|
|
27
28
|
/**
|
|
28
|
-
* Latest selectable date
|
|
29
|
+
* Latest selectable date, the whole local calendar day: with
|
|
30
|
+
* `time`, any time on the `max` day is allowed.
|
|
29
31
|
*/
|
|
30
32
|
max?: Date | null;
|
|
31
33
|
/**
|
|
@@ -75,8 +77,10 @@ export type DateboxUnit = 'date' | 'seconds';
|
|
|
75
77
|
* so a date reads as the rest of the screen writes dates. It is never parsed, so it may use any
|
|
76
78
|
* `formatDate()` token, month and weekday names included. Null shows `format`.
|
|
77
79
|
* @property {boolean} [time=false] Append `%H:%M` and show time controls.
|
|
78
|
-
* @property {Date|null} [min=null] Earliest selectable date.
|
|
79
|
-
*
|
|
80
|
+
* @property {Date|null} [min=null] Earliest selectable date. Bounds are whole local calendar days,
|
|
81
|
+
* as in the calendar: with `time`, any time on the `min` day is allowed.
|
|
82
|
+
* @property {Date|null} [max=null] Latest selectable date, the whole local calendar day: with
|
|
83
|
+
* `time`, any time on the `max` day is allowed.
|
|
80
84
|
* @property {string|null} [placeholder=null] Input placeholder; null derives one from the format.
|
|
81
85
|
* @property {boolean} [clearable=true] Show a clear button while a value is present and the box is
|
|
82
86
|
* enabled; without it the input keeps no room for one.
|
|
@@ -40,7 +40,7 @@ export type DialogOptions = {
|
|
|
40
40
|
*/
|
|
41
41
|
buttons?: DialogButton[];
|
|
42
42
|
/**
|
|
43
|
-
* Whether Escape and the header button may close the dialog.
|
|
43
|
+
* Whether Escape and the header button may close the dialog. When false the header button is not rendered as a control at all: it is not displayed, not focusable, and closes nothing.
|
|
44
44
|
*/
|
|
45
45
|
closable?: boolean;
|
|
46
46
|
/**
|
|
@@ -187,7 +187,7 @@ export type PromptOptions = {
|
|
|
187
187
|
* @property {string} [title=''] Dialog title.
|
|
188
188
|
* @property {'sm'|'md'|'lg'|number} [size='md'] Preset or pixel width.
|
|
189
189
|
* @property {DialogButton[]} [buttons=[]] Footer buttons.
|
|
190
|
-
* @property {boolean} [closable=true] Whether Escape and the header button may close the dialog.
|
|
190
|
+
* @property {boolean} [closable=true] Whether Escape and the header button may close the dialog. When false the header button is not rendered as a control at all: it is not displayed, not focusable, and closes nothing.
|
|
191
191
|
* @property {Node|string|number|{toElement: () => Node|null}|null} [content=null] Body content.
|
|
192
192
|
* @property {Element|string|null} [scope=null] Element whose nearest Zx theme scope owns the overlay; defaults to the opener. Resolved on every open, so a scope connected after construction still owns it.
|
|
193
193
|
* @property {(event: CustomEvent<Record<string, never>>) => void} [onopen] Open event listener.
|
|
@@ -320,6 +320,17 @@ export declare class Dialog extends Modal {
|
|
|
320
320
|
* @returns {Promise<string|null>}
|
|
321
321
|
*/
|
|
322
322
|
static prompt({ title, message, value, placeholder, okLabel, cancelLabel }?: PromptOptions): Promise<string | null>;
|
|
323
|
+
/**
|
|
324
|
+
* Whether the header close button is offered. Switched off, it is not displayed, not focusable,
|
|
325
|
+
* and does not dismiss the dialog. A dialog shows it while it is `closable`; a subclass with a
|
|
326
|
+
* setting of its own for the button overrides this.
|
|
327
|
+
*
|
|
328
|
+
* Called from the constructor before any subclass field initializers have run, so an override
|
|
329
|
+
* may read `this.options` but no instance state.
|
|
330
|
+
* @returns {boolean}
|
|
331
|
+
* @protected
|
|
332
|
+
*/
|
|
333
|
+
protected _hasCloseButton(): boolean;
|
|
323
334
|
/**
|
|
324
335
|
* Applies the dialog width. Subclasses that size themselves on a different axis override this.
|
|
325
336
|
*
|
|
@@ -1,9 +1,18 @@
|
|
|
1
1
|
export type ButtonOptions = import('../button/button.js').ButtonOptions;
|
|
2
|
+
export type AgentFace = import('../../internal/agent-model.js').AgentFace;
|
|
2
3
|
export type EmptyStateOptions = {
|
|
3
4
|
/**
|
|
4
5
|
* Decorative icon name; null renders no icon.
|
|
5
6
|
*/
|
|
6
7
|
icon?: string | null;
|
|
8
|
+
/**
|
|
9
|
+
* Draws an agent's face in place of the icon — an empty
|
|
10
|
+
* conversation, an agent with nothing to do yet: its AgentAvatar traits and name, or `true` to
|
|
11
|
+
* derive the face from the title. The face is keyed by the agent's `seed`, else its `name`, else
|
|
12
|
+
* the title; give the agent's seed or name so its face matches the one drawn elsewhere.
|
|
13
|
+
* Decorative and at rest, so the text says whose it is.
|
|
14
|
+
*/
|
|
15
|
+
agent?: AgentFace | true | null;
|
|
7
16
|
/**
|
|
8
17
|
* Headline text, rendered as a paragraph so page outlines stay intact.
|
|
9
18
|
*/
|
|
@@ -28,7 +37,7 @@ export type EmptyStateOptions = {
|
|
|
28
37
|
/**
|
|
29
38
|
* Creates the placeholder shown where a list, table, or panel has no content yet.
|
|
30
39
|
*
|
|
31
|
-
* Purely presentational: the icon is decorative, the headline is a paragraph rather than a heading
|
|
40
|
+
* Purely presentational: the icon — or an agent's face — is decorative, the headline is a paragraph rather than a heading
|
|
32
41
|
* so dropping the element into a Table's empty slot or a Panel body never disturbs the page's
|
|
33
42
|
* heading outline.
|
|
34
43
|
*
|
|
@@ -107,7 +107,8 @@ export type FieldAdapter = {
|
|
|
107
107
|
destroy?: () => void;
|
|
108
108
|
/**
|
|
109
109
|
* The element the field's label, description, and validity
|
|
110
|
-
* belong to when it is not `el` — the text input inside a composite control.
|
|
110
|
+
* belong to when it is not `el` — the text input inside a composite control. The field's label
|
|
111
|
+
* names it through `aria-labelledby`, over any name the component gave it. Left out, a
|
|
111
112
|
* wrapper that cannot be labelled hands them to the first unnamed form control inside it.
|
|
112
113
|
*/
|
|
113
114
|
labelTarget?: Element;
|
|
@@ -151,7 +152,8 @@ export type NumericCoercion = {
|
|
|
151
152
|
* control has none.
|
|
152
153
|
* @property {() => void} [destroy] Release adapter-owned resources.
|
|
153
154
|
* @property {Element} [labelTarget] The element the field's label, description, and validity
|
|
154
|
-
* belong to when it is not `el` — the text input inside a composite control.
|
|
155
|
+
* belong to when it is not `el` — the text input inside a composite control. The field's label
|
|
156
|
+
* names it through `aria-labelledby`, over any name the component gave it. Left out, a
|
|
155
157
|
* wrapper that cannot be labelled hands them to the first unnamed form control inside it.
|
|
156
158
|
*/
|
|
157
159
|
/** @typedef {(field: Field, options: Readonly<FieldOptions>) => FieldAdapter} FieldAdapterFactory */
|
|
@@ -199,7 +199,8 @@ export declare class Form extends Component<FormOptions> {
|
|
|
199
199
|
*/
|
|
200
200
|
clearHighlights(): this;
|
|
201
201
|
/**
|
|
202
|
-
* Validates and emits a preventable submit event.
|
|
202
|
+
* Validates and emits a preventable submit event. A disabled field — disabled itself, or inside
|
|
203
|
+
* a disabled `<fieldset>` — is not validated, so it can neither block the submit nor take focus.
|
|
203
204
|
* @returns {boolean} True when valid and not prevented.
|
|
204
205
|
* @fires Form#submit
|
|
205
206
|
* @fires Form#invalid
|
|
@@ -58,6 +58,12 @@ export type KanbanAssignee = {
|
|
|
58
58
|
* person has in every Avatar.
|
|
59
59
|
*/
|
|
60
60
|
tone: import('../avatar/avatar.js').AvatarTone;
|
|
61
|
+
/**
|
|
62
|
+
* An agent's face traits — `seed`, `tone`, `body`,
|
|
63
|
+
* `eyes`, `material` — when the descriptor carries `face`; the card draws its AgentAvatar instead of
|
|
64
|
+
* initials or a picture.
|
|
65
|
+
*/
|
|
66
|
+
face: Record<string, string> | null;
|
|
61
67
|
};
|
|
62
68
|
/**
|
|
63
69
|
* Normalizes one indicator value into the descriptor the badge is built from. A plain value
|
|
@@ -96,6 +102,7 @@ export declare function createKanbanProgress(progress: KanbanProgress, label: st
|
|
|
96
102
|
* resolve to the same shape, and an unsafe image URL degrades to initials rather than failing.
|
|
97
103
|
* A descriptor may name its `tone`; otherwise the tone is derived from the name exactly as Avatar
|
|
98
104
|
* derives it.
|
|
105
|
+
* A descriptor with `face` (AgentAvatar traits, or `true`) is an agent, drawn as its face.
|
|
99
106
|
* @param {unknown} value Raw field value.
|
|
100
107
|
* @returns {KanbanAssignee[]} Normalized people, in the order supplied.
|
|
101
108
|
*/
|
|
@@ -371,7 +371,9 @@ export type KanbanViewOptions = {
|
|
|
371
371
|
*/
|
|
372
372
|
progressMax?: number;
|
|
373
373
|
/**
|
|
374
|
-
* Responsible people; a name, a list, or descriptors
|
|
374
|
+
* Responsible people; a name, a list, or descriptors
|
|
375
|
+
* (`{name, src?, initials?, tone?}`). A descriptor with `face` — AgentAvatar traits, or `true` —
|
|
376
|
+
* is an agent, drawn as its generated face.
|
|
375
377
|
*/
|
|
376
378
|
assignees?: KanbanCardField;
|
|
377
379
|
/**
|
|
@@ -532,6 +534,7 @@ export type KanbanSectionMeta = {
|
|
|
532
534
|
export type KanbanKeyboardMove = {
|
|
533
535
|
ids: unknown[];
|
|
534
536
|
from: KanbanMovePoint;
|
|
537
|
+
origin: KanbanMovePoint;
|
|
535
538
|
to: KanbanMovePoint;
|
|
536
539
|
};
|
|
537
540
|
export type KanbanCardReader = ((record: KanbanRecord, index: number) => unknown) | null;
|
|
@@ -607,6 +610,11 @@ export declare class KanbanView extends RecordView {
|
|
|
607
610
|
lane: string | null;
|
|
608
611
|
index: number;
|
|
609
612
|
};
|
|
613
|
+
origin: {
|
|
614
|
+
column: string;
|
|
615
|
+
lane: string | null;
|
|
616
|
+
index: number;
|
|
617
|
+
};
|
|
610
618
|
to: {
|
|
611
619
|
column: string;
|
|
612
620
|
lane: string | null;
|
|
@@ -1188,8 +1196,12 @@ export declare class KanbanView extends RecordView {
|
|
|
1188
1196
|
_draggableCards(list: HTMLElement): HTMLElement[];
|
|
1189
1197
|
/** @param {string} column @param {string|null} lane @param {Set<unknown>} excluded @returns {number} */
|
|
1190
1198
|
_visibleCount(column: string, lane: string | null, excluded: Set<unknown>): number;
|
|
1191
|
-
/**
|
|
1192
|
-
|
|
1199
|
+
/**
|
|
1200
|
+
* @param {unknown} id Record id.
|
|
1201
|
+
* @param {Set<unknown>} [excluded] Cards that do not count, such as the others moving with it.
|
|
1202
|
+
* @returns {number} Position among the visible cards in its bucket.
|
|
1203
|
+
*/
|
|
1204
|
+
_visibleIndex(id: unknown, excluded?: Set<unknown>): number;
|
|
1193
1205
|
/** @returns {void} */
|
|
1194
1206
|
_syncKeyboardTarget(): void;
|
|
1195
1207
|
/** @returns {void} */
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Component } from '../../core/component.js';
|
|
2
|
+
import { AgentAvatar } from '../agent-avatar/agent-avatar.js';
|
|
2
3
|
export type LauncherItem = {
|
|
3
4
|
/**
|
|
4
5
|
* Stable item identifier.
|
|
@@ -24,6 +25,12 @@ export type LauncherItem = {
|
|
|
24
25
|
* Decorative icon name, node, or factory.
|
|
25
26
|
*/
|
|
26
27
|
icon?: string | Node | ((item: LauncherItem) => Node | null);
|
|
28
|
+
/**
|
|
29
|
+
* Draws the item as an
|
|
30
|
+
* agent: its AgentAvatar, still, in place of `icon` — these options, or `true` to derive it from
|
|
31
|
+
* the label. An activity's word joins the option's accessible name.
|
|
32
|
+
*/
|
|
33
|
+
agent?: import('../../internal/app-rail.js').AppNavAgent | true;
|
|
27
34
|
/**
|
|
28
35
|
* Compact metadata.
|
|
29
36
|
*/
|
|
@@ -295,6 +302,9 @@ export type LauncherPageEntry = {
|
|
|
295
302
|
* @property {string|string[]} [keywords] Additional search text.
|
|
296
303
|
* @property {string} [group] Result group.
|
|
297
304
|
* @property {string|Node|((item: LauncherItem) => Node|null)} [icon] Decorative icon name, node, or factory.
|
|
305
|
+
* @property {import('../../internal/app-rail.js').AppNavAgent|true} [agent] Draws the item as an
|
|
306
|
+
* agent: its AgentAvatar, still, in place of `icon` — these options, or `true` to derive it from
|
|
307
|
+
* the label. An activity's word joins the option's accessible name.
|
|
298
308
|
* @property {string|number} [badge] Compact metadata.
|
|
299
309
|
* @property {string|number} [hint] Muted text at the end of the row, such as a current value or a project.
|
|
300
310
|
* @property {string|string[]|{label: string|string[], keys?: string}} [shortcut] Key labels drawn as
|
|
@@ -399,6 +409,15 @@ export type LauncherPageEntry = {
|
|
|
399
409
|
*/
|
|
400
410
|
export declare class Launcher extends Component<LauncherOptions> {
|
|
401
411
|
_createdRoot: boolean;
|
|
412
|
+
/**
|
|
413
|
+
* The faces of agent items, one per item id, reused while results redraw on every keystroke and
|
|
414
|
+
* destroyed with the launcher.
|
|
415
|
+
* @type {Map<string, {signature: string, avatar: AgentAvatar}>}
|
|
416
|
+
*/
|
|
417
|
+
_agentFaces: Map<string, {
|
|
418
|
+
signature: string;
|
|
419
|
+
avatar: AgentAvatar;
|
|
420
|
+
}>;
|
|
402
421
|
/** @type {import('../../core/overlay-stack.js').OverlayHandle|null} Entry on the overlay stack while open. */
|
|
403
422
|
_overlay: import('../../core/overlay-stack.js').OverlayHandle | null;
|
|
404
423
|
_original: {
|
|
@@ -556,6 +575,13 @@ export declare class Launcher extends Component<LauncherOptions> {
|
|
|
556
575
|
_renderResults(): void;
|
|
557
576
|
/** @param {RankedLauncherItem} item @param {number} index @returns {HTMLElement} */
|
|
558
577
|
_option(item: RankedLauncherItem, index: number): HTMLElement;
|
|
578
|
+
/**
|
|
579
|
+
* The AgentAvatar an agent item draws, kept per item id and rebuilt only when the item changes.
|
|
580
|
+
* @private
|
|
581
|
+
* @param {LauncherItem} item
|
|
582
|
+
* @returns {AgentAvatar|null}
|
|
583
|
+
*/
|
|
584
|
+
private _agentFace;
|
|
559
585
|
/** @returns {void} */
|
|
560
586
|
_renderStatus(): void;
|
|
561
587
|
/** @returns {void} */
|
|
@@ -67,11 +67,10 @@ export type MasterPanelOptions = {
|
|
|
67
67
|
*/
|
|
68
68
|
export declare class MasterPanel extends Component<MasterPanelOptions> {
|
|
69
69
|
_createdRoot: boolean;
|
|
70
|
-
|
|
71
|
-
attributes: Array<[string, string]>;
|
|
72
|
-
children: Node[];
|
|
73
|
-
};
|
|
70
|
+
_snapshot: import("../../core/dom.js").TargetSnapshot;
|
|
74
71
|
_cleaned: boolean;
|
|
72
|
+
/** @type {WeakMap<Element, (event: MouseEvent) => void>} Click callbacks of descriptor buttons. */
|
|
73
|
+
_clicks: WeakMap<Element, (event: MouseEvent) => void>;
|
|
75
74
|
static cssName: string;
|
|
76
75
|
/** @type {Readonly<MasterPanelOptions>} */
|
|
77
76
|
static defaults: Readonly<MasterPanelOptions>;
|
|
@@ -109,4 +108,10 @@ export declare class MasterPanel extends Component<MasterPanelOptions> {
|
|
|
109
108
|
setFooter(content: MasterPanelContent): this;
|
|
110
109
|
/** @returns {void} */
|
|
111
110
|
destroy(): void;
|
|
111
|
+
/**
|
|
112
|
+
* Runs the callback of the descriptor button a click landed in, with the button as `this`.
|
|
113
|
+
* @param {MouseEvent} event Click inside the action area.
|
|
114
|
+
* @returns {void}
|
|
115
|
+
*/
|
|
116
|
+
_onButtonClick(event: MouseEvent): void;
|
|
112
117
|
}
|
|
@@ -25,10 +25,7 @@ export type MenuButtonOptions = {
|
|
|
25
25
|
/**
|
|
26
26
|
* Select event listener.
|
|
27
27
|
*/
|
|
28
|
-
onselect?: (event: CustomEvent<
|
|
29
|
-
value: unknown;
|
|
30
|
-
item: MenuItem;
|
|
31
|
-
}>) => void;
|
|
28
|
+
onselect?: (event: CustomEvent<MenuButtonSelectDetail>) => void;
|
|
32
29
|
/**
|
|
33
30
|
* Open event listener.
|
|
34
31
|
*/
|
|
@@ -38,6 +35,21 @@ export type MenuButtonOptions = {
|
|
|
38
35
|
*/
|
|
39
36
|
onclose?: (event: CustomEvent<Record<string, never>>) => void;
|
|
40
37
|
};
|
|
38
|
+
export type MenuButtonSelectDetail = {
|
|
39
|
+
/**
|
|
40
|
+
* The chosen item's value.
|
|
41
|
+
*/
|
|
42
|
+
value: unknown;
|
|
43
|
+
/**
|
|
44
|
+
* The chosen item, as the application gave it.
|
|
45
|
+
*/
|
|
46
|
+
item: MenuItem;
|
|
47
|
+
/**
|
|
48
|
+
* For a `menuitemcheckbox` or `menuitemradio`, the state choosing it
|
|
49
|
+
* gives the item: a checkbox toggles, a radio is checked. Absent for a plain item.
|
|
50
|
+
*/
|
|
51
|
+
checked?: boolean;
|
|
52
|
+
};
|
|
41
53
|
export type MenuButtonOpenOptions = {
|
|
42
54
|
/**
|
|
43
55
|
* Where focus goes when this opening ends with a
|
|
@@ -55,10 +67,17 @@ export type MenuButtonOpenOptions = {
|
|
|
55
67
|
* @property {'default'|'primary'|'danger'|'ghost'} [kind='default'] Trigger button kind.
|
|
56
68
|
* @property {MenuButtonItem[]} [items=[]] Menu items and separators.
|
|
57
69
|
* @property {'bottom-start'|'bottom-end'|'top-start'|'top-end'|'bottom'|'top'|'right-start'|'right-end'|'left-start'|'left-end'|'right'|'left'} [placement='bottom-start'] Menu placement.
|
|
58
|
-
* @property {(event: CustomEvent<
|
|
70
|
+
* @property {(event: CustomEvent<MenuButtonSelectDetail>) => void} [onselect] Select event listener.
|
|
59
71
|
* @property {(event: CustomEvent<Record<string, never>>) => void} [onopen] Open event listener.
|
|
60
72
|
* @property {(event: CustomEvent<Record<string, never>>) => void} [onclose] Close event listener.
|
|
61
73
|
*/
|
|
74
|
+
/**
|
|
75
|
+
* @typedef {Object} MenuButtonSelectDetail
|
|
76
|
+
* @property {unknown} value The chosen item's value.
|
|
77
|
+
* @property {MenuItem} item The chosen item, as the application gave it.
|
|
78
|
+
* @property {boolean} [checked] For a `menuitemcheckbox` or `menuitemradio`, the state choosing it
|
|
79
|
+
* gives the item: a checkbox toggles, a radio is checked. Absent for a plain item.
|
|
80
|
+
*/
|
|
62
81
|
/**
|
|
63
82
|
* @typedef {Object} MenuButtonOpenOptions
|
|
64
83
|
* @property {boolean|HTMLElement} [returnFocus=true] Where focus goes when this opening ends with a
|
|
@@ -71,6 +90,11 @@ export type MenuButtonOpenOptions = {
|
|
|
71
90
|
* Choosing an item closes the menu and puts focus back on the trigger before the `select` event
|
|
72
91
|
* and the item's `onselect` run, so whatever they open — a dialog, a sheet — records the trigger
|
|
73
92
|
* as the place to return to, and focus they move themselves stays where they put it.
|
|
93
|
+
*
|
|
94
|
+
* Choosing a `menuitemcheckbox` toggles its `aria-checked`, and choosing a `menuitemradio` checks
|
|
95
|
+
* it and unchecks the other radio items of its section (between separators or headings); the new
|
|
96
|
+
* state arrives as `detail.checked`. A `select` listener that prevents the event keeps the state as
|
|
97
|
+
* it was, and one that calls `setItems()` renders the state it wants instead.
|
|
74
98
|
* @fires MenuButton#select
|
|
75
99
|
* @fires MenuButton#open
|
|
76
100
|
* @fires MenuButton#close
|