@zeyos/zx 2.3.0 → 4.0.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 +138 -0
- package/DESIGN-SYSTEM.md +96 -0
- package/README.md +29 -39
- package/dist/types/components/account-menu/account-menu.d.ts +144 -0
- package/dist/types/components/app-sidebar/app-sidebar.d.ts +243 -0
- package/dist/types/components/avatar/avatar.d.ts +100 -0
- package/dist/types/components/card/card.d.ts +128 -0
- package/dist/types/components/chart/chart.d.ts +322 -0
- package/dist/types/components/date-picker/month-picker.d.ts +6 -0
- package/dist/types/components/dialog/dialog.d.ts +9 -0
- package/dist/types/components/dock/dock.d.ts +495 -0
- package/dist/types/components/dropdown/dropdown.d.ts +2 -2
- package/dist/types/components/field/field.d.ts +14 -0
- package/dist/types/components/field-upload/field-upload.d.ts +37 -4
- package/dist/types/components/form/form.d.ts +25 -3
- package/dist/types/components/grid/grid.d.ts +172 -0
- package/dist/types/components/launcher/launcher.d.ts +359 -0
- package/dist/types/components/layout/layout.d.ts +4 -4
- package/dist/types/components/menu-button/menu-button.d.ts +10 -2
- package/dist/types/components/modal/modal.d.ts +25 -0
- package/dist/types/components/multi-value-editor/multi-value-editor.d.ts +7 -1
- package/dist/types/components/questionnaire/items.d.ts +327 -0
- package/dist/types/components/questionnaire/questionnaire.d.ts +449 -0
- package/dist/types/components/select/select.d.ts +51 -0
- package/dist/types/components/sheet/sheet-stack.d.ts +167 -0
- package/dist/types/components/sheet/sheet.d.ts +294 -0
- package/dist/types/components/split-view/split-view.d.ts +2 -21
- package/dist/types/components/table/table.d.ts +223 -15
- package/dist/types/components/tooltip/tooltip.d.ts +2 -2
- package/dist/types/components/value-list/value-list.d.ts +24 -3
- package/dist/types/core/dom.d.ts +122 -0
- package/dist/types/core/drag-axis.d.ts +111 -0
- package/dist/types/core/position.d.ts +4 -2
- package/dist/types/index.d.ts +13 -2
- package/dist/types/internal/app-rail.d.ts +265 -0
- package/dist/types/zeyos/icons.d.ts +5 -0
- package/dist/types/zeyos/index.d.ts +2 -1
- package/dist/types/zeyos/launcher.d.ts +147 -0
- package/dist/types/zeyos/select.d.ts +39 -0
- package/dist/zx-zeyos.esm.js +1870 -133
- package/dist/zx-zeyos.esm.min.js +1 -1
- package/dist/zx.css +2006 -267
- package/dist/zx.esm.js +8987 -2757
- package/dist/zx.esm.min.js +3 -3
- package/dist/zx.global.js +8987 -2757
- package/dist/zx.global.min.js +3 -3
- package/dist/zx.min.css +1 -1
- package/docs/api.json +4396 -2344
- package/docs/llms.md +463 -86
- package/docs/llms.txt +32 -19
- package/package.json +10 -17
- package/src/components/account-menu/account-menu.css +70 -0
- package/src/components/account-menu/account-menu.js +208 -0
- package/src/components/app-rail/app-rail.css +107 -0
- package/src/components/app-sidebar/app-sidebar.css +80 -0
- package/src/components/app-sidebar/app-sidebar.js +588 -0
- package/src/components/avatar/avatar.css +61 -0
- package/src/components/avatar/avatar.js +222 -0
- package/src/components/button/button.css +0 -1
- package/src/components/card/card.css +149 -0
- package/src/components/card/card.js +285 -0
- package/src/components/chart/chart.css +61 -0
- package/src/components/chart/chart.js +523 -0
- package/src/components/date-picker/month-picker.js +9 -0
- package/src/components/dialog/dialog.js +11 -4
- package/src/components/dock/dock.css +228 -0
- package/src/components/dock/dock.js +977 -0
- package/src/components/dropdown/dropdown.js +1 -1
- package/src/components/field/field.js +2 -0
- package/src/components/field-upload/field-upload.js +9 -4
- package/src/components/form/form.js +6 -3
- package/src/components/grid/grid.css +6 -0
- package/src/components/grid/grid.js +220 -0
- package/src/components/launcher/launcher.css +210 -0
- package/src/components/launcher/launcher.js +765 -0
- package/src/components/layout/layout.js +2 -2
- package/src/components/menu-button/menu-button.js +27 -2
- package/src/components/modal/modal.css +5 -1
- package/src/components/modal/modal.js +37 -2
- package/src/components/multi-value-editor/multi-value-editor.js +2 -1
- package/src/components/questionnaire/items.js +370 -0
- package/src/components/questionnaire/questionnaire.css +387 -0
- package/src/components/questionnaire/questionnaire.js +1033 -0
- package/src/components/select/field-adapter.js +9 -4
- package/src/components/select/select.css +144 -11
- package/src/components/select/select.js +259 -27
- package/src/components/sheet/sheet-stack.js +304 -0
- package/src/components/sheet/sheet.css +351 -0
- package/src/components/sheet/sheet.js +551 -0
- package/src/components/split-view/split-view.js +76 -161
- package/src/components/table/table.css +43 -0
- package/src/components/table/table.js +531 -52
- package/src/components/tooltip/tooltip.js +5 -2
- package/src/components/value-list/value-list.js +6 -3
- package/src/core/dom.js +322 -0
- package/src/core/drag-axis.js +203 -0
- package/src/core/position.js +68 -22
- package/src/index.js +20 -2
- package/src/internal/app-rail.js +718 -0
- package/src/zeyos/icons.js +8 -3
- package/src/zeyos/index.js +7 -1
- package/src/zeyos/launcher.js +338 -0
- package/src/zeyos/modules.js +1 -0
- package/src/zeyos/select.js +115 -1
- package/styles/tokens/dark.css +2 -3
- package/styles/tokens/global.css +6 -6
- package/styles/tokens/modules.css +1 -0
- package/styles/tokens/semantic.css +5 -3
- package/styles/tokens/themes.css +1 -1
- package/styles/zx.css +11 -1
- package/MIGRATION.md +0 -598
- package/dist/types/compat/base.d.ts +0 -156
- package/dist/types/compat/globals.d.ts +0 -20
- package/dist/types/compat/index.d.ts +0 -128
- package/dist/types/compat/map/basic.d.ts +0 -175
- package/dist/types/compat/map/data.d.ts +0 -102
- package/dist/types/compat/map/date-time.d.ts +0 -80
- package/dist/types/compat/map/factory.d.ts +0 -9
- package/dist/types/compat/map/form.d.ts +0 -98
- package/dist/types/compat/map/helpers.d.ts +0 -12
- package/dist/types/compat/map/http.d.ts +0 -36
- package/dist/types/compat/map/layout.d.ts +0 -106
- package/dist/types/compat/map/options.d.ts +0 -80
- package/dist/types/compat/map/select.d.ts +0 -95
- package/dist/types/compat/map/stubs.d.ts +0 -32
- package/dist/types/compat/map/utilities.d.ts +0 -37
- package/dist/types/compat-entry.d.ts +0 -5
- package/dist/types/components/permission/permission.d.ts +0 -96
- package/dist/zx-compat.esm.js +0 -17484
- package/dist/zx-compat.esm.min.js +0 -1
- package/dist/zx-compat.global.js +0 -23635
- package/dist/zx-compat.global.min.js +0 -3
- package/src/compat/base.js +0 -291
- package/src/compat/globals.js +0 -165
- package/src/compat/index.js +0 -84
- package/src/compat/map/basic.js +0 -464
- package/src/compat/map/data.js +0 -232
- package/src/compat/map/date-time.js +0 -177
- package/src/compat/map/factory.js +0 -45
- package/src/compat/map/form.js +0 -330
- package/src/compat/map/helpers.js +0 -46
- package/src/compat/map/http.js +0 -117
- package/src/compat/map/layout.js +0 -256
- package/src/compat/map/options.js +0 -267
- package/src/compat/map/select.js +0 -198
- package/src/compat/map/stubs.js +0 -26
- package/src/compat/map/utilities.js +0 -113
- package/src/compat-entry.js +0 -11
- package/src/components/permission/permission.css +0 -47
- package/src/components/permission/permission.js +0 -201
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
/** Pixels an arrow key moves a handle. */
|
|
2
|
+
export declare const STEP = 16;
|
|
3
|
+
/** Pixels a shifted arrow key moves a handle. */
|
|
4
|
+
export declare const STEP_LARGE = 64;
|
|
5
|
+
export type DragAxisOptions = {
|
|
6
|
+
/**
|
|
7
|
+
* Axis the handle moves along. `horizontal` reads
|
|
8
|
+
* `clientX`, `vertical` reads `clientY`.
|
|
9
|
+
*/
|
|
10
|
+
orientation: 'horizontal' | 'vertical';
|
|
11
|
+
/**
|
|
12
|
+
* Called on pointer-down before the
|
|
13
|
+
* drag begins. Return `false` to refuse it — the usual reason being that there is nothing to
|
|
14
|
+
* resize on either side of the handle.
|
|
15
|
+
*/
|
|
16
|
+
onStart?: (event: PointerEvent) => boolean | void;
|
|
17
|
+
/**
|
|
18
|
+
* Called at most once per frame with the signed pixel
|
|
19
|
+
* distance travelled along the axis since pointer-down.
|
|
20
|
+
*/
|
|
21
|
+
onMove: (delta: number) => void;
|
|
22
|
+
/**
|
|
23
|
+
* Called once the pointer is released.
|
|
24
|
+
* `moved` is false for a press that never travelled, which is a click rather than a drag.
|
|
25
|
+
*/
|
|
26
|
+
onEnd?: (delta: number, moved: boolean) => void;
|
|
27
|
+
/**
|
|
28
|
+
* Called for an arrow key along the
|
|
29
|
+
* axis. `large` is true while Shift is held.
|
|
30
|
+
*/
|
|
31
|
+
onStep?: (direction: -1 | 1, large: boolean) => void;
|
|
32
|
+
/**
|
|
33
|
+
* Called for Home and End.
|
|
34
|
+
*/
|
|
35
|
+
onJump?: (edge: 'min' | 'max') => void;
|
|
36
|
+
/**
|
|
37
|
+
* Called for Enter and Space, which components use for the
|
|
38
|
+
* collapse affordance a splitter is expected to offer.
|
|
39
|
+
*/
|
|
40
|
+
onActivate?: () => void;
|
|
41
|
+
/**
|
|
42
|
+
* Consulted before every interaction.
|
|
43
|
+
*/
|
|
44
|
+
disabled?: () => boolean;
|
|
45
|
+
};
|
|
46
|
+
export type DragAxisController = {
|
|
47
|
+
/**
|
|
48
|
+
* Whether a drag is in flight.
|
|
49
|
+
*/
|
|
50
|
+
isDragging: () => boolean;
|
|
51
|
+
/**
|
|
52
|
+
* Ends any drag in flight without reporting it.
|
|
53
|
+
*/
|
|
54
|
+
cancel: () => void;
|
|
55
|
+
/**
|
|
56
|
+
* Removes listeners and cancels any drag in flight.
|
|
57
|
+
*/
|
|
58
|
+
destroy: () => void;
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* @typedef {Object} DragAxisOptions
|
|
62
|
+
* @property {'horizontal'|'vertical'} orientation Axis the handle moves along. `horizontal` reads
|
|
63
|
+
* `clientX`, `vertical` reads `clientY`.
|
|
64
|
+
* @property {(event: PointerEvent) => boolean|void} [onStart] Called on pointer-down before the
|
|
65
|
+
* drag begins. Return `false` to refuse it — the usual reason being that there is nothing to
|
|
66
|
+
* resize on either side of the handle.
|
|
67
|
+
* @property {(delta: number) => void} onMove Called at most once per frame with the signed pixel
|
|
68
|
+
* distance travelled along the axis since pointer-down.
|
|
69
|
+
* @property {(delta: number, moved: boolean) => void} [onEnd] Called once the pointer is released.
|
|
70
|
+
* `moved` is false for a press that never travelled, which is a click rather than a drag.
|
|
71
|
+
* @property {(direction: -1|1, large: boolean) => void} [onStep] Called for an arrow key along the
|
|
72
|
+
* axis. `large` is true while Shift is held.
|
|
73
|
+
* @property {(edge: 'min'|'max') => void} [onJump] Called for Home and End.
|
|
74
|
+
* @property {() => void} [onActivate] Called for Enter and Space, which components use for the
|
|
75
|
+
* collapse affordance a splitter is expected to offer.
|
|
76
|
+
* @property {() => boolean} [disabled] Consulted before every interaction.
|
|
77
|
+
*/
|
|
78
|
+
/**
|
|
79
|
+
* @typedef {Object} DragAxisController
|
|
80
|
+
* @property {() => boolean} isDragging Whether a drag is in flight.
|
|
81
|
+
* @property {() => void} cancel Ends any drag in flight without reporting it.
|
|
82
|
+
* @property {() => void} destroy Removes listeners and cancels any drag in flight.
|
|
83
|
+
*/
|
|
84
|
+
/**
|
|
85
|
+
* Pointer and keyboard mechanics for anything dragged along one axis — a split divider, a dock
|
|
86
|
+
* divider, the resizable edge of a sheet.
|
|
87
|
+
*
|
|
88
|
+
* Deliberately knows nothing about sizes. It reports the signed distance travelled and leaves
|
|
89
|
+
* every consumer to do its own arithmetic, because the three that need it disagree about what a
|
|
90
|
+
* drag means: a split view moves one boundary, a dock moves size between two neighbours, and a
|
|
91
|
+
* sheet grows in the opposite direction depending on which edge it is attached to. What they do
|
|
92
|
+
* share is the fiddly part — pointer capture that survives the pointer leaving the handle, one
|
|
93
|
+
* write per frame however fast the pointer reports, telling a click apart from a zero-distance
|
|
94
|
+
* drag, and the WAI-ARIA keyboard map.
|
|
95
|
+
*
|
|
96
|
+
* @param {Element} handle Element the pointer grabs; also the keyboard target.
|
|
97
|
+
* @param {DragAxisOptions} options Axis and callbacks.
|
|
98
|
+
* @returns {DragAxisController}
|
|
99
|
+
*/
|
|
100
|
+
export declare function dragAxis(handle: Element, options: DragAxisOptions): DragAxisController;
|
|
101
|
+
/**
|
|
102
|
+
* Resolves a size option to pixels without touching the DOM.
|
|
103
|
+
*
|
|
104
|
+
* Numbers, bare numeric strings, and `px` lengths are pixels; a percentage resolves against
|
|
105
|
+
* `total`. Every other CSS length — `rem`, `vh`, `calc()` — needs the browser, so it returns `NaN`
|
|
106
|
+
* and the caller hands the value to CSS instead of guessing at it.
|
|
107
|
+
* @param {number|string} value Size option.
|
|
108
|
+
* @param {number} total Container size along the split axis, in pixels.
|
|
109
|
+
* @returns {number} Pixels, or `NaN` when only the browser can resolve the value.
|
|
110
|
+
*/
|
|
111
|
+
export declare function resolveSize(value: number | string, total: number): number;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
export type Placement = 'bottom-start' | 'bottom-end' | 'top-start' | 'top-end' | 'bottom' | 'top' | 'right-start' | 'right-end' | 'left-start' | 'left-end' | 'right' | 'left';
|
|
1
2
|
export type PositionOptions = {
|
|
2
|
-
placement?: 'bottom-start' | 'bottom-end' | 'top-start' | 'top-end' | 'bottom' | 'top';
|
|
3
|
+
placement?: 'bottom-start' | 'bottom-end' | 'top-start' | 'top-end' | 'bottom' | 'top' | 'right-start' | 'right-end' | 'left-start' | 'left-end' | 'right' | 'left';
|
|
3
4
|
/**
|
|
4
5
|
* Gap between anchor and floating element.
|
|
5
6
|
*/
|
|
@@ -23,9 +24,10 @@ export type PositionController = {
|
|
|
23
24
|
*/
|
|
24
25
|
destroy: () => void;
|
|
25
26
|
};
|
|
27
|
+
/** @typedef {'bottom-start'|'bottom-end'|'top-start'|'top-end'|'bottom'|'top'|'right-start'|'right-end'|'left-start'|'left-end'|'right'|'left'} Placement */
|
|
26
28
|
/**
|
|
27
29
|
* @typedef {Object} PositionOptions
|
|
28
|
-
* @property {'bottom-start'|'bottom-end'|'top-start'|'top-end'|'bottom'|'top'} [placement='bottom-start']
|
|
30
|
+
* @property {'bottom-start'|'bottom-end'|'top-start'|'top-end'|'bottom'|'top'|'right-start'|'right-end'|'left-start'|'left-end'|'right'|'left'} [placement='bottom-start']
|
|
29
31
|
* @property {number} [offset=4] Gap between anchor and floating element.
|
|
30
32
|
* @property {boolean} [flip=true] Flip vertically when the preferred side overflows.
|
|
31
33
|
* @property {boolean} [matchWidth=false] Set the floating element's minimum width to the anchor width.
|
package/dist/types/index.d.ts
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*/
|
|
9
9
|
export declare function registerFieldAdapters(): void;
|
|
10
10
|
export { Component } from './core/component.js';
|
|
11
|
-
export { h, htmlEscape, resolveElement, highlightMatch } from './core/dom.js';
|
|
11
|
+
export { h, htmlEscape, resolveElement, highlightMatch, __, compactElement, fragment, parseCompactTag, applyCompactProperties, appendContent, appendCompact, appendCompactChild, onCompactEvent, offCompactEvent, fireCompactEvent } from './core/dom.js';
|
|
12
12
|
export { position } from './core/position.js';
|
|
13
13
|
export { breakpoints, breakpointOf, matchBreakpoint, onBreakpoint } from './core/breakpoint.js';
|
|
14
14
|
export { Http, zeyosService, parseResult } from './core/http.js';
|
|
@@ -37,18 +37,27 @@ export { CopyInput } from './components/copy/copy-input.js';
|
|
|
37
37
|
export { Toolbar } from './components/toolbar/toolbar.js';
|
|
38
38
|
export { Toggle } from './components/toggle/toggle.js';
|
|
39
39
|
export { Groupbox } from './components/groupbox/groupbox.js';
|
|
40
|
+
export { Card } from './components/card/card.js';
|
|
40
41
|
export { Panel } from './components/panel/panel.js';
|
|
41
42
|
export { MasterPanel } from './components/master-panel/master-panel.js';
|
|
42
43
|
export { SplitView, clampSize, resolveSize, snapSize } from './components/split-view/split-view.js';
|
|
44
|
+
export { Dock } from './components/dock/dock.js';
|
|
43
45
|
export { Tabbox } from './components/tabbox/tabbox.js';
|
|
44
46
|
export { NavigationBar } from './components/navigation-bar/navigation-bar.js';
|
|
45
47
|
export { Stepper } from './components/stepper/stepper.js';
|
|
46
48
|
export { Breadcrumb } from './components/breadcrumb/breadcrumb.js';
|
|
47
49
|
export { Pagination, paginationRange } from './components/pagination/pagination.js';
|
|
48
50
|
export { Search } from './components/search/search.js';
|
|
51
|
+
export { Launcher, rankLauncherItems } from './components/launcher/launcher.js';
|
|
52
|
+
export { Avatar, avatarInitials } from './components/avatar/avatar.js';
|
|
53
|
+
export { AccountMenu } from './components/account-menu/account-menu.js';
|
|
54
|
+
export { normalizeAppItems } from './internal/app-rail.js';
|
|
55
|
+
export { AppSidebar } from './components/app-sidebar/app-sidebar.js';
|
|
49
56
|
export { Message } from './components/message/message.js';
|
|
50
57
|
export { Modal } from './components/modal/modal.js';
|
|
51
58
|
export { Dialog } from './components/dialog/dialog.js';
|
|
59
|
+
export { Sheet } from './components/sheet/sheet.js';
|
|
60
|
+
export { SheetStack } from './components/sheet/sheet-stack.js';
|
|
52
61
|
export { Dropdown } from './components/dropdown/dropdown.js';
|
|
53
62
|
export { Tooltip, tooltip, describe } from './components/tooltip/tooltip.js';
|
|
54
63
|
export { MenuButton } from './components/menu-button/menu-button.js';
|
|
@@ -59,7 +68,6 @@ export { TagPicker } from './components/tag-picker/tag-picker.js';
|
|
|
59
68
|
export { NumberField, parseNumber, snapNumber } from './components/number-field/number-field.js';
|
|
60
69
|
export { Rating } from './components/rating/rating.js';
|
|
61
70
|
export { Slider, stepPrecision } from './components/slider/slider.js';
|
|
62
|
-
export { Permission } from './components/permission/permission.js';
|
|
63
71
|
export { DatePicker } from './components/date-picker/date-picker.js';
|
|
64
72
|
export { MonthPicker } from './components/date-picker/month-picker.js';
|
|
65
73
|
export { TimePicker } from './components/date-picker/time-picker.js';
|
|
@@ -68,12 +76,15 @@ export { DateRangePicker, clampRange, defaultDateRangePresets, normalizeRange, r
|
|
|
68
76
|
export { DateRangeBox, formatRangeText, parseRangeText } from './components/datebox/date-range-box.js';
|
|
69
77
|
export { Timebox, splitTime, joinTime } from './components/timebox/timebox.js';
|
|
70
78
|
export { Table } from './components/table/table.js';
|
|
79
|
+
export { Grid, billingColumns, isBillingLine } from './components/grid/grid.js';
|
|
80
|
+
export { Chart, ChartJsAdapter, chartSummaryTable, cloneChartValue, isEmptyChartData } from './components/chart/chart.js';
|
|
71
81
|
export { TreeView } from './components/tree/tree.js';
|
|
72
82
|
export { Finder } from './components/finder/finder.js';
|
|
73
83
|
export { DataFilter } from './components/data-filter/data-filter.js';
|
|
74
84
|
export { Field } from './components/field/field.js';
|
|
75
85
|
export { Fieldset } from './components/fieldset/fieldset.js';
|
|
76
86
|
export { Form } from './components/form/form.js';
|
|
87
|
+
export { Questionnaire } from './components/questionnaire/questionnaire.js';
|
|
77
88
|
export { ValueList } from './components/value-list/value-list.js';
|
|
78
89
|
export { MultiValueEditor } from './components/multi-value-editor/multi-value-editor.js';
|
|
79
90
|
export { FieldUpload } from './components/field-upload/field-upload.js';
|
|
@@ -0,0 +1,265 @@
|
|
|
1
|
+
import { Component } from '../core/component.js';
|
|
2
|
+
import { Dropdown } from '../components/dropdown/dropdown.js';
|
|
3
|
+
export type AppNavItem = {
|
|
4
|
+
/**
|
|
5
|
+
* Stable item identifier.
|
|
6
|
+
*/
|
|
7
|
+
id: string | number;
|
|
8
|
+
/**
|
|
9
|
+
* Visible/accessibility label.
|
|
10
|
+
*/
|
|
11
|
+
label: string;
|
|
12
|
+
/**
|
|
13
|
+
* Icon name, node, component, or factory.
|
|
14
|
+
*/
|
|
15
|
+
icon?: string | Node | {
|
|
16
|
+
toElement: () => Node | null;
|
|
17
|
+
} | ((context: Record<string, any>, item: AppNavItem) => Node | null);
|
|
18
|
+
/**
|
|
19
|
+
* Count or status badge.
|
|
20
|
+
*/
|
|
21
|
+
badge?: string | number;
|
|
22
|
+
/**
|
|
23
|
+
* Emitted value; defaults to `id`.
|
|
24
|
+
*/
|
|
25
|
+
value?: unknown;
|
|
26
|
+
/**
|
|
27
|
+
* Native navigation target; executable/data schemes are disabled.
|
|
28
|
+
*/
|
|
29
|
+
href?: string;
|
|
30
|
+
/**
|
|
31
|
+
* Native link browsing context.
|
|
32
|
+
*/
|
|
33
|
+
target?: string;
|
|
34
|
+
/**
|
|
35
|
+
* Application-owned non-link action.
|
|
36
|
+
*/
|
|
37
|
+
invoke?: () => void;
|
|
38
|
+
/**
|
|
39
|
+
* Whether activation is unavailable.
|
|
40
|
+
*/
|
|
41
|
+
disabled?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* Child destinations/actions.
|
|
44
|
+
*/
|
|
45
|
+
children?: AppNavItem[];
|
|
46
|
+
};
|
|
47
|
+
export type AppRailPresenterOptions = {
|
|
48
|
+
/**
|
|
49
|
+
* Application navigation tree.
|
|
50
|
+
*/
|
|
51
|
+
items?: AppNavItem[];
|
|
52
|
+
/**
|
|
53
|
+
* Active item id.
|
|
54
|
+
*/
|
|
55
|
+
active?: string | number | null;
|
|
56
|
+
/**
|
|
57
|
+
* Rail flow.
|
|
58
|
+
*/
|
|
59
|
+
orientation?: 'vertical' | 'horizontal';
|
|
60
|
+
/**
|
|
61
|
+
* Workspace edge occupied by the rail.
|
|
62
|
+
*/
|
|
63
|
+
side?: 'left' | 'right' | 'top' | 'bottom';
|
|
64
|
+
/**
|
|
65
|
+
* Navigation accessible label.
|
|
66
|
+
*/
|
|
67
|
+
label?: string;
|
|
68
|
+
/**
|
|
69
|
+
* Leading rail content.
|
|
70
|
+
*/
|
|
71
|
+
header?: Node | string | number | {
|
|
72
|
+
toElement: () => Node | null;
|
|
73
|
+
} | null;
|
|
74
|
+
/**
|
|
75
|
+
* Trailing rail content.
|
|
76
|
+
*/
|
|
77
|
+
footer?: Node | string | number | {
|
|
78
|
+
toElement: () => Node | null;
|
|
79
|
+
} | null;
|
|
80
|
+
/**
|
|
81
|
+
* Hover-open delay in milliseconds.
|
|
82
|
+
*/
|
|
83
|
+
openDelay?: number;
|
|
84
|
+
/**
|
|
85
|
+
* Pointer/focus crossing grace in milliseconds.
|
|
86
|
+
*/
|
|
87
|
+
closeDelay?: number;
|
|
88
|
+
/**
|
|
89
|
+
* Optional host icon renderer.
|
|
90
|
+
*/
|
|
91
|
+
renderIcon?: (item: AppNavItem, context: Record<string, any>) => Node | null;
|
|
92
|
+
/**
|
|
93
|
+
* Preventable action listener.
|
|
94
|
+
*/
|
|
95
|
+
onselect?: (event: CustomEvent<AppNavSelectDetail>) => void;
|
|
96
|
+
/**
|
|
97
|
+
* Flyout-state listener.
|
|
98
|
+
*/
|
|
99
|
+
onflyoutchange?: (event: CustomEvent<{
|
|
100
|
+
item: AppNavItem;
|
|
101
|
+
id: string | number;
|
|
102
|
+
open: boolean;
|
|
103
|
+
}>) => void;
|
|
104
|
+
};
|
|
105
|
+
export type AppNavSelectDetail = {
|
|
106
|
+
item: AppNavItem;
|
|
107
|
+
id: string | number;
|
|
108
|
+
value: unknown;
|
|
109
|
+
href: string | null;
|
|
110
|
+
event: Event;
|
|
111
|
+
};
|
|
112
|
+
export type RailFlyout = {
|
|
113
|
+
key: string;
|
|
114
|
+
parentKey: string | null;
|
|
115
|
+
item: AppNavItem;
|
|
116
|
+
trigger: HTMLElement;
|
|
117
|
+
panel: HTMLElement;
|
|
118
|
+
dropdown: Dropdown;
|
|
119
|
+
};
|
|
120
|
+
/**
|
|
121
|
+
* @typedef {Object} AppNavItem
|
|
122
|
+
* @property {string|number} id Stable item identifier.
|
|
123
|
+
* @property {string} label Visible/accessibility label.
|
|
124
|
+
* @property {string|Node|{toElement: () => Node|null}|((context: Record<string, any>, item: AppNavItem) => Node|null)} [icon] Icon name, node, component, or factory.
|
|
125
|
+
* @property {string|number} [badge] Count or status badge.
|
|
126
|
+
* @property {unknown} [value] Emitted value; defaults to `id`.
|
|
127
|
+
* @property {string} [href] Native navigation target; executable/data schemes are disabled.
|
|
128
|
+
* @property {string} [target] Native link browsing context.
|
|
129
|
+
* @property {() => void} [invoke] Application-owned non-link action.
|
|
130
|
+
* @property {boolean} [disabled] Whether activation is unavailable.
|
|
131
|
+
* @property {AppNavItem[]} [children] Child destinations/actions.
|
|
132
|
+
*/
|
|
133
|
+
/**
|
|
134
|
+
* @typedef {Object} AppRailPresenterOptions
|
|
135
|
+
* @property {AppNavItem[]} [items=[]] Application navigation tree.
|
|
136
|
+
* @property {string|number|null} [active=null] Active item id.
|
|
137
|
+
* @property {'vertical'|'horizontal'} [orientation='vertical'] Rail flow.
|
|
138
|
+
* @property {'left'|'right'|'top'|'bottom'} [side='left'] Workspace edge occupied by the rail.
|
|
139
|
+
* @property {string} [label='Applications'] Navigation accessible label.
|
|
140
|
+
* @property {Node|string|number|{toElement: () => Node|null}|null} [header=null] Leading rail content.
|
|
141
|
+
* @property {Node|string|number|{toElement: () => Node|null}|null} [footer=null] Trailing rail content.
|
|
142
|
+
* @property {number} [openDelay=80] Hover-open delay in milliseconds.
|
|
143
|
+
* @property {number} [closeDelay=160] Pointer/focus crossing grace in milliseconds.
|
|
144
|
+
* @property {(item: AppNavItem, context: Record<string, any>) => Node|null} [renderIcon] Optional host icon renderer.
|
|
145
|
+
* @property {(event: CustomEvent<AppNavSelectDetail>) => void} [onselect] Preventable action listener.
|
|
146
|
+
* @property {(event: CustomEvent<{item: AppNavItem, id: string|number, open: boolean}>) => void} [onflyoutchange] Flyout-state listener.
|
|
147
|
+
*/
|
|
148
|
+
/** @typedef {{item: AppNavItem, id: string|number, value: unknown, href: string|null, event: Event}} AppNavSelectDetail */
|
|
149
|
+
/** @typedef {{key: string, parentKey: string|null, item: AppNavItem, trigger: HTMLElement, panel: HTMLElement, dropdown: Dropdown}} RailFlyout */
|
|
150
|
+
/**
|
|
151
|
+
* Minimized application navigation; descendants always open in hover/focus flyouts, never inline.
|
|
152
|
+
* @fires AppRailPresenter#select
|
|
153
|
+
* @fires AppRailPresenter#flyoutchange
|
|
154
|
+
* @extends {Component<AppRailPresenterOptions>}
|
|
155
|
+
*/
|
|
156
|
+
export declare class AppRailPresenter extends Component<AppRailPresenterOptions> {
|
|
157
|
+
_createdRoot: boolean;
|
|
158
|
+
_original: {
|
|
159
|
+
attributes: string[][];
|
|
160
|
+
children: ChildNode[];
|
|
161
|
+
};
|
|
162
|
+
_items: AppNavItem[];
|
|
163
|
+
_active: string | number;
|
|
164
|
+
_flyouts: Map<any, any>;
|
|
165
|
+
_tooltips: any[];
|
|
166
|
+
_tooltipById: Map<any, any>;
|
|
167
|
+
_interaction: RailListenerScope;
|
|
168
|
+
_openTimers: Map<any, any>;
|
|
169
|
+
_closeTimers: Map<any, any>;
|
|
170
|
+
_pointerFocus: WeakSet<object>;
|
|
171
|
+
_silenceFlyoutEvents: boolean;
|
|
172
|
+
static cssName: string;
|
|
173
|
+
/** @type {Readonly<AppRailPresenterOptions>} */
|
|
174
|
+
static defaults: Readonly<AppRailPresenterOptions>;
|
|
175
|
+
/**
|
|
176
|
+
* Creates or enhances a rail host.
|
|
177
|
+
* @param {Element|string|null} target Rail target.
|
|
178
|
+
* @param {AppRailPresenterOptions} [options={}] Rail options.
|
|
179
|
+
*/
|
|
180
|
+
constructor(target?: Element | string | null, options?: AppRailPresenterOptions);
|
|
181
|
+
/** @returns {HTMLElement} */
|
|
182
|
+
render(): HTMLElement;
|
|
183
|
+
/** Replaces navigation items and closes removed flyouts. @param {AppNavItem[]} items @returns {this} */
|
|
184
|
+
setItems(items: AppNavItem[]): this;
|
|
185
|
+
/** Sets the active item without routing. @param {string|number|null} id @returns {this} */
|
|
186
|
+
setActive(id: string | number | null): this;
|
|
187
|
+
/** Returns a shallow copy of normalized items. @returns {AppNavItem[]} */
|
|
188
|
+
getItems(): AppNavItem[];
|
|
189
|
+
/** Opens one item's flyout, optionally focusing its first action. @param {string|number} id @param {{focus?: boolean}} [options={}] @returns {this} */
|
|
190
|
+
openFlyout(id: string | number, { focus }?: {
|
|
191
|
+
focus?: boolean;
|
|
192
|
+
}): this;
|
|
193
|
+
/** Closes one flyout. @param {string|number} id @returns {this} */
|
|
194
|
+
closeFlyout(id: string | number): this;
|
|
195
|
+
/** Closes every flyout and cancels pending hover/focus transitions. @returns {this} */
|
|
196
|
+
closeAllFlyouts(): this;
|
|
197
|
+
/** Reports whether an item's flyout is open. @param {string|number} id @returns {boolean} */
|
|
198
|
+
isFlyoutOpen(id: string | number): boolean;
|
|
199
|
+
/** Focuses the first top-level rail item. @returns {this} */
|
|
200
|
+
focus(): this;
|
|
201
|
+
/** Reports whether a node belongs to this rail, including detached flyout panels. @param {Node|null} node @returns {boolean} @private */
|
|
202
|
+
private _containsNode;
|
|
203
|
+
/** Destroys body popovers/tooltips and restores or removes the root. @returns {void} */
|
|
204
|
+
destroy(): void;
|
|
205
|
+
/** @returns {void} */
|
|
206
|
+
_rebuild(): void;
|
|
207
|
+
/** @param {AppNavItem} item @param {HTMLElement} trigger @param {string} key @param {string|null} parentKey @returns {void} */
|
|
208
|
+
_buildFlyout(item: AppNavItem, trigger: HTMLElement, key: string, parentKey: string | null): void;
|
|
209
|
+
/** @param {AppNavItem} item @param {Event} event @returns {Event} */
|
|
210
|
+
_select(item: AppNavItem, event: Event): Event;
|
|
211
|
+
/** @param {KeyboardEvent} event @returns {void} */
|
|
212
|
+
_onRailKeydown(event: KeyboardEvent): void;
|
|
213
|
+
/** @param {KeyboardEvent} event @param {RailFlyout} flyout @returns {void} */
|
|
214
|
+
_onFlyoutKeydown(event: KeyboardEvent, flyout: RailFlyout): void;
|
|
215
|
+
/** @param {string|number} id @returns {void} */
|
|
216
|
+
_scheduleOpen(id: string | number): void;
|
|
217
|
+
/** @param {string|number} id @returns {void} */
|
|
218
|
+
_scheduleClose(id: string | number): void;
|
|
219
|
+
/** Schedules a flyout and, when leaving a detached panel, each owning flyout for re-evaluation. @param {RailFlyout} flyout @param {boolean} ancestors @returns {void} */
|
|
220
|
+
_scheduleFlyoutClose(flyout: RailFlyout, ancestors: boolean): void;
|
|
221
|
+
/** Resolves a public id or internal descendant path. @param {string|number} id @returns {RailFlyout|null} */
|
|
222
|
+
_resolveFlyout(id: string | number): RailFlyout | null;
|
|
223
|
+
/** Closes the root flyout that owns a selected descendant. @param {string} key @returns {void} */
|
|
224
|
+
_closeFlyoutChain(key: string): void;
|
|
225
|
+
/** Reports whether one flyout owns another through its parent chain. @param {RailFlyout} ancestor @param {RailFlyout} descendant @returns {boolean} */
|
|
226
|
+
_isAncestor(ancestor: RailFlyout, descendant: RailFlyout): boolean;
|
|
227
|
+
/** Cancels crossing timers for a flyout and optionally every owning flyout. @param {RailFlyout} flyout @param {boolean} ancestors @returns {void} */
|
|
228
|
+
_cancelFlyoutTimers(flyout: RailFlyout, ancestors: boolean): void;
|
|
229
|
+
/** Reports pointer/focus presence in a flyout branch, including detached descendant panels. @param {RailFlyout} flyout @returns {boolean} */
|
|
230
|
+
_branchInteracting(flyout: RailFlyout): boolean;
|
|
231
|
+
/** Restores trigger focus without immediately reopening the flyout through its focus handler. @param {HTMLElement} trigger @returns {void} */
|
|
232
|
+
_restoreFocus(trigger: HTMLElement): void;
|
|
233
|
+
/** @param {string} key @returns {void} */
|
|
234
|
+
_cancelTimers(key: string): void;
|
|
235
|
+
/** @param {Map<string, ReturnType<typeof setTimeout>>} timers @param {string} key @returns {void} */
|
|
236
|
+
_cancelTimer(timers: Map<string, ReturnType<typeof setTimeout>>, key: string): void;
|
|
237
|
+
/** @returns {void} */
|
|
238
|
+
_syncActive(): void;
|
|
239
|
+
/** @returns {void} */
|
|
240
|
+
_clearArtifacts(): void;
|
|
241
|
+
}
|
|
242
|
+
/** Owns listeners attached to one dynamic rail render so `setItems()` can release them immediately. */
|
|
243
|
+
declare class RailListenerScope extends Component {
|
|
244
|
+
/** @param {HTMLElement} host Rail host. */
|
|
245
|
+
constructor(host: HTMLElement);
|
|
246
|
+
/** @returns {HTMLElement} */
|
|
247
|
+
render(): HTMLElement;
|
|
248
|
+
}
|
|
249
|
+
/**
|
|
250
|
+
* Normalizes an application navigation tree without mutating caller data.
|
|
251
|
+
* @param {unknown} items Candidate tree.
|
|
252
|
+
* @returns {AppNavItem[]}
|
|
253
|
+
*/
|
|
254
|
+
export declare function normalizeAppItems(items: unknown): AppNavItem[];
|
|
255
|
+
/**
|
|
256
|
+
* Resolves a host-rendered or item-owned navigation icon without moving a mounted source node.
|
|
257
|
+
* @param {AppNavItem} item Navigation item.
|
|
258
|
+
* @param {unknown} renderer Optional component-level renderer.
|
|
259
|
+
* @param {Record<string, any>} context Presentation context.
|
|
260
|
+
* @returns {Node|null}
|
|
261
|
+
*/
|
|
262
|
+
export declare function appNavIcon(item: AppNavItem, renderer: unknown, context: Record<string, any>): Node | null;
|
|
263
|
+
export {};
|
|
264
|
+
/** Fired when a destination/action is activated. @event AppRailPresenter#select @type {CustomEvent<AppNavSelectDetail>} */
|
|
265
|
+
/** Fired when a flyout opens or closes. @event AppRailPresenter#flyoutchange @type {CustomEvent<{item: AppNavItem, id: string|number, open: boolean}>} */
|
|
@@ -79,6 +79,10 @@ export type ModuleChipOptions = {
|
|
|
79
79
|
* Use the stock Font Awesome fallback glyph.
|
|
80
80
|
*/
|
|
81
81
|
standard?: boolean;
|
|
82
|
+
/**
|
|
83
|
+
* Override the module colour for a server-defined fork or weblet.
|
|
84
|
+
*/
|
|
85
|
+
color?: string;
|
|
82
86
|
/**
|
|
83
87
|
* Extra class names.
|
|
84
88
|
*/
|
|
@@ -91,6 +95,7 @@ export type ModuleChipOptions = {
|
|
|
91
95
|
* @property {string|null} [label=null] Accessible label; null marks the chip decorative.
|
|
92
96
|
* @property {boolean} [title=false] Adds the module's display name as a `title` tooltip.
|
|
93
97
|
* @property {boolean} [standard=false] Use the stock Font Awesome fallback glyph.
|
|
98
|
+
* @property {string} [color] Override the module colour for a server-defined fork or weblet.
|
|
94
99
|
* @property {string|string[]} [class] Extra class names.
|
|
95
100
|
*/
|
|
96
101
|
/**
|
|
@@ -7,6 +7,7 @@ export { buildListQuery, tableSortToQuery, dataFilterStateToFilters, dateToUnixS
|
|
|
7
7
|
export { connect } from './connect.js';
|
|
8
8
|
export { zeyosModules, moduleAliases, moduleInfo, moduleColor, moduleIconName, moduleKeys, moduleGlyphColor, normalizeModuleName, registerModules } from './modules.js';
|
|
9
9
|
export { ZEYOS_ICON_KIT, useZeyosIcons, moduleIcon, moduleChip } from './icons.js';
|
|
10
|
-
export {
|
|
10
|
+
export { ZEYOS_LAUNCHER_APPLICATIONS, buildZeyosLauncherConfig, zeyosLauncher, normalizeZeyosLauncherApplications, normalizeZeyosLauncherRecords, zeyosActiveIdentifier } from './launcher.js';
|
|
11
|
+
export { zeyosSelect, buildZeyosSelectConfig, zeyosEntitySelect, buildZeyosEntitySelectConfig } from './select.js';
|
|
11
12
|
export { zeyosForm } from './form.js';
|
|
12
13
|
export { zeyosTable } from './table.js';
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
import { Launcher } from '../components/launcher/launcher.js';
|
|
2
|
+
/** Static application identifiers present in the current ZeyOS shell prototype. */
|
|
3
|
+
export declare const ZEYOS_LAUNCHER_APPLICATIONS: readonly string[];
|
|
4
|
+
export type ZeyosLauncherState = {
|
|
5
|
+
/**
|
|
6
|
+
* Permitted module catalogue.
|
|
7
|
+
*/
|
|
8
|
+
modules?: Record<string, string> | Array<string | Record<string, any>>;
|
|
9
|
+
/**
|
|
10
|
+
* Forks/weblets and authoritative menu entries.
|
|
11
|
+
*/
|
|
12
|
+
menuApps?: Array<Array<any> | Record<string, any>>;
|
|
13
|
+
/**
|
|
14
|
+
* Application identifiers in pinned order.
|
|
15
|
+
*/
|
|
16
|
+
pinned?: string[];
|
|
17
|
+
/**
|
|
18
|
+
* Recent records.
|
|
19
|
+
*/
|
|
20
|
+
recent?: Array<Array<any> | Record<string, any>>;
|
|
21
|
+
/**
|
|
22
|
+
* Current module, `fork#…`, or `weblet#…` identifier.
|
|
23
|
+
*/
|
|
24
|
+
activeIdentifier?: string | null;
|
|
25
|
+
/**
|
|
26
|
+
* Permission predicate.
|
|
27
|
+
*/
|
|
28
|
+
canUseModule?: (module: string) => boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Record search loader.
|
|
31
|
+
*/
|
|
32
|
+
search?: (query: string, context: {
|
|
33
|
+
signal: AbortSignal;
|
|
34
|
+
}) => Promise<unknown> | unknown;
|
|
35
|
+
/**
|
|
36
|
+
* Recent-record loader.
|
|
37
|
+
*/
|
|
38
|
+
loadRecent?: (context: {
|
|
39
|
+
signal: AbortSignal;
|
|
40
|
+
}) => Promise<unknown> | unknown;
|
|
41
|
+
/**
|
|
42
|
+
* Maps an app to href/invoke/value metadata.
|
|
43
|
+
*/
|
|
44
|
+
resolveApplication?: (app: unknown) => Record<string, any> | null;
|
|
45
|
+
/**
|
|
46
|
+
* Maps a record to href/invoke/value metadata.
|
|
47
|
+
*/
|
|
48
|
+
resolveRecord?: (record: unknown) => Record<string, any> | null;
|
|
49
|
+
/**
|
|
50
|
+
* Localized applications/recent/results/entity labels and hints.
|
|
51
|
+
*/
|
|
52
|
+
labels?: Record<string, any>;
|
|
53
|
+
/**
|
|
54
|
+
* Host icon renderer for modules, forks, and weblets.
|
|
55
|
+
*/
|
|
56
|
+
renderApplicationIcon?: (app: unknown, normalized: Record<string, any>) => Node | null;
|
|
57
|
+
/**
|
|
58
|
+
* Host record icon renderer.
|
|
59
|
+
*/
|
|
60
|
+
renderRecordIcon?: (record: unknown, normalized: Record<string, any>) => Node | null;
|
|
61
|
+
/**
|
|
62
|
+
* Legacy weblet-only icon renderer.
|
|
63
|
+
*/
|
|
64
|
+
renderWebletIcon?: (app: unknown, normalized: Record<string, any>) => Node | null;
|
|
65
|
+
};
|
|
66
|
+
export type ZeyosLauncherOptions = {
|
|
67
|
+
/**
|
|
68
|
+
* Use stock icon fallbacks instead of the optional ZeyOS kit.
|
|
69
|
+
*/
|
|
70
|
+
standardIcons?: boolean;
|
|
71
|
+
/**
|
|
72
|
+
* Extra generic Launcher items.
|
|
73
|
+
*/
|
|
74
|
+
items?: Array<Record<string, any>>;
|
|
75
|
+
/**
|
|
76
|
+
* Extra generic Launcher sources.
|
|
77
|
+
*/
|
|
78
|
+
sources?: Array<Record<string, any>>;
|
|
79
|
+
};
|
|
80
|
+
/**
|
|
81
|
+
* @typedef {Object} ZeyosLauncherState
|
|
82
|
+
* @property {Record<string, string>|Array<string|Record<string, any>>} [modules={}] Permitted module catalogue.
|
|
83
|
+
* @property {Array<Array<any>|Record<string, any>>} [menuApps=[]] Forks/weblets and authoritative menu entries.
|
|
84
|
+
* @property {string[]} [pinned=[]] Application identifiers in pinned order.
|
|
85
|
+
* @property {Array<Array<any>|Record<string, any>>} [recent=[]] Recent records.
|
|
86
|
+
* @property {string|null} [activeIdentifier=null] Current module, `fork#…`, or `weblet#…` identifier.
|
|
87
|
+
* @property {(module: string) => boolean} [canUseModule] Permission predicate.
|
|
88
|
+
* @property {(query: string, context: {signal: AbortSignal}) => Promise<unknown>|unknown} [search] Record search loader.
|
|
89
|
+
* @property {(context: {signal: AbortSignal}) => Promise<unknown>|unknown} [loadRecent] Recent-record loader.
|
|
90
|
+
* @property {(app: unknown) => Record<string, any>|null} [resolveApplication] Maps an app to href/invoke/value metadata.
|
|
91
|
+
* @property {(record: unknown) => Record<string, any>|null} [resolveRecord] Maps a record to href/invoke/value metadata.
|
|
92
|
+
* @property {Record<string, any>} [labels] Localized applications/recent/results/entity labels and hints.
|
|
93
|
+
* @property {(app: unknown, normalized: Record<string, any>) => Node|null} [renderApplicationIcon] Host icon renderer for modules, forks, and weblets.
|
|
94
|
+
* @property {(record: unknown, normalized: Record<string, any>) => Node|null} [renderRecordIcon] Host record icon renderer.
|
|
95
|
+
* @property {(app: unknown, normalized: Record<string, any>) => Node|null} [renderWebletIcon] Legacy weblet-only icon renderer.
|
|
96
|
+
*/
|
|
97
|
+
/**
|
|
98
|
+
* @typedef {Object} ZeyosLauncherOptions
|
|
99
|
+
* @property {boolean} [standardIcons=false] Use stock icon fallbacks instead of the optional ZeyOS kit.
|
|
100
|
+
* @property {Array<Record<string, any>>} [items] Extra generic Launcher items.
|
|
101
|
+
* @property {Array<Record<string, any>>} [sources] Extra generic Launcher sources.
|
|
102
|
+
*/
|
|
103
|
+
/**
|
|
104
|
+
* Builds a generic Launcher configuration from explicitly injected ZeyOS shell state. It never
|
|
105
|
+
* reads PG/C globals and never resolves a route itself.
|
|
106
|
+
* @param {ZeyosLauncherState} [state={}] Application-owned shell state.
|
|
107
|
+
* @param {ZeyosLauncherOptions & Record<string, any>} [options={}] Adapter and Launcher options.
|
|
108
|
+
* @returns {Record<string, any>} Plain Launcher options.
|
|
109
|
+
*/
|
|
110
|
+
export declare function buildZeyosLauncherConfig(state?: ZeyosLauncherState, options?: ZeyosLauncherOptions & Record<string, any>): Record<string, any>;
|
|
111
|
+
/**
|
|
112
|
+
* Creates the ZeyOS-configured Launcher. State and route resolvers remain caller-owned inputs.
|
|
113
|
+
* @param {ZeyosLauncherState} [state={}] Injected shell state.
|
|
114
|
+
* @param {ZeyosLauncherOptions & Record<string, any>} [options={}] Adapter and Launcher options.
|
|
115
|
+
* @returns {Launcher}
|
|
116
|
+
*/
|
|
117
|
+
export declare function zeyosLauncher(state?: ZeyosLauncherState, options?: ZeyosLauncherOptions & Record<string, any>): Launcher;
|
|
118
|
+
/**
|
|
119
|
+
* Normalizes module, fork, and weblet applications while preserving menu authority and pin order.
|
|
120
|
+
* @param {ZeyosLauncherState} [state={}] Injected shell state.
|
|
121
|
+
* @param {{standardIcons?: boolean, renderApplicationIcon?: Function, renderWebletIcon?: Function}} [options={}] Icon options.
|
|
122
|
+
* @returns {Array<Record<string, any>>}
|
|
123
|
+
*/
|
|
124
|
+
export declare function normalizeZeyosLauncherApplications(state?: ZeyosLauncherState, options?: {
|
|
125
|
+
standardIcons?: boolean;
|
|
126
|
+
renderApplicationIcon?: Function;
|
|
127
|
+
renderWebletIcon?: Function;
|
|
128
|
+
}): Array<Record<string, any>>;
|
|
129
|
+
/**
|
|
130
|
+
* Normalizes recent records or grouped search payloads without losing server/group order.
|
|
131
|
+
* @param {unknown} payload Recent/search payload.
|
|
132
|
+
* @param {{query?: string, labels?: Record<string, any>, resolveRecord?: Function, renderRecordIcon?: Function, standardIcons?: boolean}} [options={}] Mapping options.
|
|
133
|
+
* @returns {Array<Record<string, any>>}
|
|
134
|
+
*/
|
|
135
|
+
export declare function normalizeZeyosLauncherRecords(payload: unknown, options?: {
|
|
136
|
+
query?: string;
|
|
137
|
+
labels?: Record<string, any>;
|
|
138
|
+
resolveRecord?: Function;
|
|
139
|
+
renderRecordIcon?: Function;
|
|
140
|
+
standardIcons?: boolean;
|
|
141
|
+
}): Array<Record<string, any>>;
|
|
142
|
+
/** @param {{module?: string, fork?: unknown, weblet?: unknown}} state @returns {string} */
|
|
143
|
+
export declare function zeyosActiveIdentifier(state?: {
|
|
144
|
+
module?: string;
|
|
145
|
+
fork?: unknown;
|
|
146
|
+
weblet?: unknown;
|
|
147
|
+
}): string;
|