@zeyos/zx 4.4.0 → 5.2.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.
Files changed (252) hide show
  1. package/CHANGELOG.md +447 -0
  2. package/README.md +44 -11
  3. package/dist/types/components/account-menu/account-menu.d.ts +8 -0
  4. package/dist/types/components/activity-list/activity-list.d.ts +31 -1
  5. package/dist/types/components/app-icon/app-icon.d.ts +14 -2
  6. package/dist/types/components/app-sidebar/app-sidebar.d.ts +293 -17
  7. package/dist/types/components/avatar/avatar.d.ts +46 -7
  8. package/dist/types/components/badge/badge.d.ts +21 -1
  9. package/dist/types/components/button/button.d.ts +15 -0
  10. package/dist/types/components/calendar/calendar.d.ts +67 -5
  11. package/dist/types/components/card-view/card-view.d.ts +7 -4
  12. package/dist/types/components/card-view/record-card.d.ts +11 -0
  13. package/dist/types/components/chart/chart.d.ts +10 -0
  14. package/dist/types/components/checklist/checklist.d.ts +9 -0
  15. package/dist/types/components/code-editor/code-editor.d.ts +6 -17
  16. package/dist/types/components/context-menu/context-menu.d.ts +6 -2
  17. package/dist/types/components/data-filter/data-filter.d.ts +4 -4
  18. package/dist/types/components/datebox/date-range-box.d.ts +5 -1
  19. package/dist/types/components/datebox/datebox.d.ts +7 -2
  20. package/dist/types/components/dialog/dialog.d.ts +46 -6
  21. package/dist/types/components/dropdown/dropdown.d.ts +24 -9
  22. package/dist/types/components/entity-ref/entity-ref.d.ts +2 -2
  23. package/dist/types/components/field/field.d.ts +54 -2
  24. package/dist/types/components/fieldset/external-adapter.d.ts +83 -0
  25. package/dist/types/components/fieldset/fieldset.d.ts +26 -1
  26. package/dist/types/components/file-item/file-item.d.ts +34 -6
  27. package/dist/types/components/file-list/file-list.d.ts +35 -3
  28. package/dist/types/components/filter/filter.d.ts +127 -3
  29. package/dist/types/components/filter-panel/filter-panel.d.ts +36 -7
  30. package/dist/types/components/form/form.d.ts +12 -1
  31. package/dist/types/components/kanban-view/kanban-card.d.ts +8 -0
  32. package/dist/types/components/launcher/launcher.d.ts +268 -15
  33. package/dist/types/components/list-toolbar/list-toolbar.d.ts +16 -7
  34. package/dist/types/components/menu-button/menu-button.d.ts +39 -5
  35. package/dist/types/components/message/message.d.ts +132 -17
  36. package/dist/types/components/modal/modal.d.ts +43 -2
  37. package/dist/types/components/module-bar/module-bar.d.ts +395 -0
  38. package/dist/types/components/pagination/pagination.d.ts +17 -3
  39. package/dist/types/components/select/color.d.ts +12 -0
  40. package/dist/types/components/select/glyphs.d.ts +124 -0
  41. package/dist/types/components/select/select.d.ts +17 -3
  42. package/dist/types/components/sheet/sheet.d.ts +15 -0
  43. package/dist/types/components/stat-tile/stat-tile.d.ts +16 -5
  44. package/dist/types/components/tabbox/tabbox.d.ts +9 -0
  45. package/dist/types/components/table/table.d.ts +311 -18
  46. package/dist/types/components/tag-picker/tag-picker.d.ts +21 -4
  47. package/dist/types/components/tree/tree.d.ts +13 -0
  48. package/dist/types/components/view/record-view.d.ts +59 -2
  49. package/dist/types/components/view-settings/view-settings.d.ts +879 -0
  50. package/dist/types/components/workspace-switcher/workspace-switcher.d.ts +327 -0
  51. package/dist/types/core/breakpoint.d.ts +1 -1
  52. package/dist/types/core/component.d.ts +12 -2
  53. package/dist/types/core/i18n.d.ts +27 -3
  54. package/dist/types/core/icons.d.ts +23 -25
  55. package/dist/types/core/keyboard.d.ts +98 -1
  56. package/dist/types/core/messages.d.ts +382 -0
  57. package/dist/types/core/motion.d.ts +59 -0
  58. package/dist/types/core/overlay-host.d.ts +42 -1
  59. package/dist/types/core/overlay-stack.d.ts +260 -0
  60. package/dist/types/index.d.ts +10 -5
  61. package/dist/types/internal/app-rail.d.ts +38 -0
  62. package/dist/types/internal/menu-items.d.ts +71 -3
  63. package/dist/types/zeyos/connect.d.ts +6 -0
  64. package/dist/types/zeyos/form.d.ts +50 -9
  65. package/dist/types/zeyos/index.d.ts +2 -1
  66. package/dist/types/zeyos/launcher.d.ts +9 -0
  67. package/dist/types/zeyos/module-bar.d.ts +176 -0
  68. package/dist/types/zeyos/query.d.ts +110 -5
  69. package/dist/types/zeyos/schema.d.ts +24 -1
  70. package/dist/types/zeyos/table.d.ts +345 -22
  71. package/dist/types/zeyos/view.d.ts +26 -2
  72. package/dist/zx-zeyos.esm.js +6178 -1008
  73. package/dist/zx-zeyos.esm.min.js +53 -5
  74. package/dist/zx.css +2861 -827
  75. package/dist/zx.esm.js +8909 -1480
  76. package/dist/zx.esm.min.js +55 -7
  77. package/dist/zx.global.js +8911 -1482
  78. package/dist/zx.global.min.js +55 -7
  79. package/dist/zx.min.css +1 -1
  80. package/docs/api.json +1079 -117
  81. package/docs/llms.md +956 -154
  82. package/docs/llms.txt +9 -5
  83. package/package.json +1 -1
  84. package/src/components/account-menu/account-menu.css +35 -10
  85. package/src/components/account-menu/account-menu.js +12 -0
  86. package/src/components/activity-item/activity-item.css +1 -1
  87. package/src/components/activity-item/activity-item.js +3 -0
  88. package/src/components/activity-list/activity-list.css +38 -3
  89. package/src/components/activity-list/activity-list.js +61 -1
  90. package/src/components/app-icon/app-icon.css +14 -3
  91. package/src/components/app-icon/app-icon.js +11 -1
  92. package/src/components/app-rail/app-rail.css +59 -79
  93. package/src/components/app-sidebar/app-sidebar.css +304 -168
  94. package/src/components/app-sidebar/app-sidebar.js +667 -46
  95. package/src/components/aurora/aurora.css +5 -3
  96. package/src/components/avatar/avatar.css +32 -7
  97. package/src/components/avatar/avatar.js +72 -8
  98. package/src/components/badge/badge.css +54 -2
  99. package/src/components/badge/badge.js +29 -2
  100. package/src/components/breadcrumb/breadcrumb.css +1 -1
  101. package/src/components/button/button.css +67 -9
  102. package/src/components/button/button.js +38 -0
  103. package/src/components/calendar/calendar.css +47 -47
  104. package/src/components/calendar/calendar.js +26 -52
  105. package/src/components/card/card.css +4 -4
  106. package/src/components/card-view/card-view.css +14 -12
  107. package/src/components/card-view/card-view.js +13 -9
  108. package/src/components/card-view/record-card.js +14 -3
  109. package/src/components/chart/chart.css +4 -1
  110. package/src/components/chart/chart.js +12 -0
  111. package/src/components/check-button/check-button.css +10 -2
  112. package/src/components/checklist/checklist.css +9 -2
  113. package/src/components/checklist/checklist.js +11 -5
  114. package/src/components/checklist/field-adapter.js +3 -1
  115. package/src/components/code-editor/code-editor.css +7 -6
  116. package/src/components/code-editor/code-editor.js +19 -1
  117. package/src/components/code-editor/field-adapter.js +9 -2
  118. package/src/components/context-menu/context-menu.css +9 -4
  119. package/src/components/context-menu/context-menu.js +8 -2
  120. package/src/components/copy/copy-button.css +6 -0
  121. package/src/components/copy/copy-input.css +9 -4
  122. package/src/components/data-filter/data-filter.css +5 -4
  123. package/src/components/data-filter/data-filter.js +2 -2
  124. package/src/components/date-picker/date-picker.css +6 -6
  125. package/src/components/date-picker/date-range-picker.css +3 -3
  126. package/src/components/date-picker/time-picker.css +3 -3
  127. package/src/components/datebox/date-range-box.css +79 -2
  128. package/src/components/datebox/date-range-box.js +13 -2
  129. package/src/components/datebox/datebox.css +79 -2
  130. package/src/components/datebox/datebox.js +13 -2
  131. package/src/components/dialog/dialog.css +26 -0
  132. package/src/components/dialog/dialog.js +99 -17
  133. package/src/components/dock/dock.css +5 -4
  134. package/src/components/dropdown/dropdown.css +1 -1
  135. package/src/components/dropdown/dropdown.js +159 -72
  136. package/src/components/empty-state/empty-state.css +2 -2
  137. package/src/components/entity-ref/entity-ref.css +1 -1
  138. package/src/components/entity-ref/entity-ref.js +1 -1
  139. package/src/components/field/field.css +28 -9
  140. package/src/components/field/field.js +101 -29
  141. package/src/components/field-upload/field-upload.css +1 -1
  142. package/src/components/fieldset/external-adapter.js +363 -0
  143. package/src/components/fieldset/fieldset.css +5 -3
  144. package/src/components/fieldset/fieldset.js +38 -64
  145. package/src/components/file-item/file-item.js +144 -10
  146. package/src/components/file-list/file-list.js +144 -21
  147. package/src/components/filter/filter.css +86 -2
  148. package/src/components/filter/filter.js +307 -11
  149. package/src/components/filter-panel/filter-panel.css +1 -1
  150. package/src/components/filter-panel/filter-panel.js +149 -32
  151. package/src/components/finder/finder.css +16 -14
  152. package/src/components/form/form.css +5 -4
  153. package/src/components/form/form.js +11 -2
  154. package/src/components/grid/grid.css +1 -1
  155. package/src/components/groupbox/groupbox.css +1 -1
  156. package/src/components/kanban-view/kanban-card.js +11 -3
  157. package/src/components/kanban-view/kanban-view.css +42 -18
  158. package/src/components/kanban-view/kanban-view.js +9 -6
  159. package/src/components/launcher/launcher.css +108 -26
  160. package/src/components/launcher/launcher.js +530 -42
  161. package/src/components/list-toolbar/list-toolbar.css +13 -8
  162. package/src/components/list-toolbar/list-toolbar.js +40 -14
  163. package/src/components/master-panel/master-panel.css +2 -0
  164. package/src/components/master-panel/master-panel.js +0 -1
  165. package/src/components/menu-button/menu-button.css +72 -4
  166. package/src/components/menu-button/menu-button.js +160 -18
  167. package/src/components/message/message.css +33 -3
  168. package/src/components/message/message.js +264 -22
  169. package/src/components/modal/modal.css +1 -1
  170. package/src/components/modal/modal.js +83 -15
  171. package/src/components/module-bar/module-bar.css +486 -0
  172. package/src/components/module-bar/module-bar.js +1074 -0
  173. package/src/components/multi-value-editor/multi-value-editor.css +1 -1
  174. package/src/components/navigation-bar/navigation-bar.css +18 -9
  175. package/src/components/number-field/field-adapter.js +3 -1
  176. package/src/components/number-field/number-field.css +70 -0
  177. package/src/components/number-field/number-field.js +2 -0
  178. package/src/components/pagination/pagination.css +13 -11
  179. package/src/components/pagination/pagination.js +20 -4
  180. package/src/components/panel/panel.css +4 -3
  181. package/src/components/questionnaire/questionnaire.css +4 -4
  182. package/src/components/rating/field-adapter.js +2 -1
  183. package/src/components/rating/rating.css +8 -1
  184. package/src/components/search/search.css +4 -1
  185. package/src/components/select/color.js +22 -0
  186. package/src/components/select/field-adapter.js +2 -0
  187. package/src/components/select/glyphs.js +165 -0
  188. package/src/components/select/select.css +138 -45
  189. package/src/components/select/select.js +92 -47
  190. package/src/components/sheet/sheet.css +12 -9
  191. package/src/components/sheet/sheet.js +74 -32
  192. package/src/components/slider/field-adapter.js +6 -1
  193. package/src/components/slider/slider.css +18 -4
  194. package/src/components/slider/slider.js +1 -1
  195. package/src/components/sort-control/sort-control.css +4 -1
  196. package/src/components/split-view/split-view.css +1 -1
  197. package/src/components/stat-tile/stat-tile.css +42 -47
  198. package/src/components/stat-tile/stat-tile.js +17 -6
  199. package/src/components/stepper/stepper.css +1 -1
  200. package/src/components/tabbox/tabbox.css +41 -32
  201. package/src/components/tabbox/tabbox.js +5 -1
  202. package/src/components/table/table.css +187 -37
  203. package/src/components/table/table.js +718 -73
  204. package/src/components/tag-picker/field-adapter.js +2 -1
  205. package/src/components/tag-picker/tag-picker.css +83 -5
  206. package/src/components/tag-picker/tag-picker.js +25 -8
  207. package/src/components/timebox/timebox.css +22 -2
  208. package/src/components/toggle/toggle.css +12 -1
  209. package/src/components/toolbar/toolbar.js +2 -2
  210. package/src/components/tooltip/tooltip.css +4 -0
  211. package/src/components/tooltip/tooltip.js +44 -19
  212. package/src/components/tree/tree.css +26 -17
  213. package/src/components/tree/tree.js +31 -0
  214. package/src/components/value-list/value-list.css +3 -3
  215. package/src/components/view/record-view.css +1 -1
  216. package/src/components/view/record-view.js +178 -18
  217. package/src/components/view-settings/view-settings.css +285 -0
  218. package/src/components/view-settings/view-settings.js +1830 -0
  219. package/src/components/workspace-switcher/workspace-switcher.css +188 -0
  220. package/src/components/workspace-switcher/workspace-switcher.js +463 -0
  221. package/src/core/breakpoint.js +1 -1
  222. package/src/core/component.js +88 -17
  223. package/src/core/fontawesome.js +5 -1
  224. package/src/core/i18n.js +47 -4
  225. package/src/core/icons.js +204 -61
  226. package/src/core/keyboard.js +206 -11
  227. package/src/core/messages.js +427 -0
  228. package/src/core/motion.js +147 -0
  229. package/src/core/overlay-host.js +77 -3
  230. package/src/core/overlay-stack.js +487 -0
  231. package/src/core/position.js +22 -3
  232. package/src/index.js +10 -5
  233. package/src/internal/app-rail.js +135 -55
  234. package/src/internal/menu-items.js +61 -3
  235. package/src/zeyos/connect.js +6 -2
  236. package/src/zeyos/form.js +69 -27
  237. package/src/zeyos/index.js +4 -1
  238. package/src/zeyos/launcher.js +8 -3
  239. package/src/zeyos/module-bar.js +181 -0
  240. package/src/zeyos/query.js +197 -13
  241. package/src/zeyos/schema.js +144 -27
  242. package/src/zeyos/table.js +287 -84
  243. package/src/zeyos/view.js +49 -93
  244. package/styles/base.css +72 -1
  245. package/styles/icons.css +11 -1
  246. package/styles/print.css +1 -1
  247. package/styles/tokens/dark.css +117 -37
  248. package/styles/tokens/global.css +121 -27
  249. package/styles/tokens/semantic.css +140 -43
  250. package/styles/tokens/themes.css +7 -6
  251. package/styles/zx.css +3 -1
  252. package/styles/tokens/density.css +0 -9
@@ -1,3 +1,4 @@
1
+ export type BadgeTone = 'blue' | 'teal' | 'green' | 'amber' | 'orange' | 'red' | 'pink' | 'violet' | 'slate';
1
2
  export type BadgeOptions = {
2
3
  /**
3
4
  * Visible badge text.
@@ -11,6 +12,13 @@ export type BadgeOptions = {
11
12
  * Semantic intent.
12
13
  */
13
14
  kind?: 'neutral' | 'accent' | 'success' | 'warning' | 'danger' | 'info';
15
+ /**
16
+ * Categorical colour — a project, a label, a module — from
17
+ * the tone palette rather than the status set, so a tag never reads as a warning. When set it
18
+ * decides the colour and `kind` is ignored for it; `variant` still applies. Unknown names are
19
+ * ignored.
20
+ */
21
+ tone?: BadgeTone | null;
14
22
  /**
15
23
  * Fill treatment.
16
24
  */
@@ -29,7 +37,13 @@ export type BadgeOptions = {
29
37
  title?: string;
30
38
  };
31
39
  /**
32
- * Creates a status pill: a small, non-interactive label carrying a semantic colour.
40
+ * Categorical tones, in the order they are documented.
41
+ * @type {ReadonlyArray<BadgeTone>}
42
+ */
43
+ export declare const BADGE_TONES: ReadonlyArray<BadgeTone>;
44
+ /**
45
+ * Creates a status pill: a small, non-interactive label carrying a semantic colour — or, with
46
+ * `tone`, a categorical one.
33
47
  *
34
48
  * The badge is plain text content, so it needs no ARIA of its own. A badge without a label but
35
49
  * with a `title` is named for assistive technology through `role="img"`.
@@ -44,3 +58,9 @@ export declare function badge(opts?: BadgeOptions): HTMLSpanElement;
44
58
  * @returns {HTMLSpanElement}
45
59
  */
46
60
  export declare function badgeGroup(badges: HTMLSpanElement[]): HTMLSpanElement;
61
+ /**
62
+ * Resolves a categorical tone name, or null for anything outside the palette.
63
+ * @param {unknown} value Requested tone.
64
+ * @returns {BadgeTone|null}
65
+ */
66
+ export declare function normalizeBadgeTone(value: unknown): BadgeTone | null;
@@ -23,6 +23,11 @@ export type ButtonOptions = {
23
23
  * Whether the button is disabled.
24
24
  */
25
25
  disabled?: boolean;
26
+ /**
27
+ * Whether the button is working on its action — see
28
+ * `setButtonBusy()`.
29
+ */
30
+ busy?: boolean;
26
31
  /**
27
32
  * Native title text.
28
33
  */
@@ -48,3 +53,13 @@ export declare function button(opts?: ButtonOptions): HTMLButtonElement;
48
53
  * @returns {HTMLDivElement}
49
54
  */
50
55
  export declare function buttonGroup(buttons: HTMLButtonElement[]): HTMLDivElement;
56
+ /**
57
+ * Marks a button as working on its action, or done. A busy button shows a spinner before its
58
+ * label, announces `aria-busy`, and ignores activation — but stays focusable, unlike a disabled
59
+ * one, so focus does not fall to the page while the work runs and the reader hears it finish.
60
+ * Works on any `.zx-btn`, including one the application built itself.
61
+ * @param {HTMLButtonElement} element
62
+ * @param {boolean} busy
63
+ * @returns {HTMLButtonElement} The same button.
64
+ */
65
+ export declare function setButtonBusy(element: HTMLButtonElement, busy: boolean): HTMLButtonElement;
@@ -132,7 +132,9 @@ export type CalendarOptions = {
132
132
  */
133
133
  dateUnit?: 'milliseconds' | 'seconds';
134
134
  /**
135
- * Localized component messages.
135
+ * Per-instance messages, keyed `calendar.*` (`calendar.today`,
136
+ * `calendar.next`, …). The bare keys of earlier versions (`today`, `next`) are still read, after the
137
+ * namespaced key, until the next major version.
136
138
  */
137
139
  msg?: Record<string, string>;
138
140
  /**
@@ -248,6 +250,68 @@ export type CalendarEventChangeDetail = {
248
250
  export type CalendarSetOptions = {
249
251
  silent?: boolean;
250
252
  };
253
+ /** @typedef {import('./calendar-model.js').CalendarEvent} CalendarEvent */
254
+ /** @typedef {import('./calendar-model.js').CalendarView} CalendarView */
255
+ /** @typedef {import('./calendar-model.js').CalendarReader} CalendarReader */
256
+ /**
257
+ * @typedef {Object} CalendarOptions
258
+ * @property {Record<string, any>[]} [events=[]] Event records.
259
+ * @property {Date|string|number|null} [date=null] Initial local anchor date; null uses today.
260
+ * @property {CalendarView} [view='month'] Initial view.
261
+ * @property {CalendarView[]} [views=['agenda','day','week','month','year']] Allowed views.
262
+ * @property {string|string[]} [locale] Intl locale override.
263
+ * @property {number} [weekStart=1] First weekday, 0 (Sunday) through 6 (Saturday).
264
+ * @property {boolean} [weekNumbers=true] Show ISO week numbers in month view.
265
+ * @property {boolean} [workweek=false] Show Monday–Friday in the week time grid.
266
+ * @property {number} [agendaDays=14] Number of days in agenda view.
267
+ * @property {number} [slotDuration=30] Time-grid snap interval in minutes.
268
+ * @property {number} [slotMinTime=0] First visible minute of the day.
269
+ * @property {number} [slotMaxTime=1440] Exclusive last visible minute of the day.
270
+ * @property {number} [scrollTime=480] Minute initially scrolled into view.
271
+ * @property {number} [eventLimit=3] Maximum visible month lanes before a More button.
272
+ * @property {boolean} [selectable=false] Enable pointer time-range selection.
273
+ * @property {boolean} [editable=false] Enable event moving and resizing.
274
+ * @property {boolean|null} [eventStartEditable=null] Global move override; null inherits editable.
275
+ * @property {boolean|null} [eventDurationEditable=null] Global resize override; null inherits editable.
276
+ * @property {boolean} [optimistic=true] Apply event proposals locally before persistence confirms.
277
+ * @property {boolean} [nowIndicator=true] Show the current-time line in day/week views.
278
+ * @property {Date|(() => Date)|null} [now=null] Current-time override for deterministic rendering.
279
+ * @property {boolean} [disabled=false] Disable toolbar, date, selection, and editing controls.
280
+ * @property {CalendarReader} [eventId='id'] Event ID reader.
281
+ * @property {CalendarReader} [eventTitle='title'] Event title reader.
282
+ * @property {CalendarReader} [eventStart='start'] Event start reader.
283
+ * @property {CalendarReader} [eventEnd='end'] Event end reader.
284
+ * @property {CalendarReader} [eventAllDay='allDay'] Event all-day reader.
285
+ * @property {CalendarReader} [eventColor='color'] Event colour reader.
286
+ * @property {CalendarReader} [eventLocation='location'] Event location reader.
287
+ * @property {CalendarReader} [eventEditable='editable'] Per-event move reader.
288
+ * @property {CalendarReader} [eventDurationEditable='durationEditable'] Per-event resize reader.
289
+ * @property {'milliseconds'|'seconds'} [dateUnit='milliseconds'] Unit for numeric event dates.
290
+ * @property {Record<string, string>} [msg] Per-instance messages, keyed `calendar.*` (`calendar.today`,
291
+ * `calendar.next`, …). The bare keys of earlier versions (`today`, `next`) are still read, after the
292
+ * namespaced key, until the next major version.
293
+ * @property {(event: CalendarEvent) => Node|string|null} [renderEvent] Optional safe event-content renderer.
294
+ * @property {(event: CustomEvent<{events: CalendarEvent[]}>) => void} [oneventschange] Programmatic event-data listener.
295
+ * @property {(event: CustomEvent<{view: CalendarView, oldView: CalendarView}>) => void} [onviewchange] View listener.
296
+ * @property {(event: CustomEvent<{view: CalendarView, start: Date, end: Date}>) => void} [ondateschange] Visible-range listener.
297
+ * @property {(event: CustomEvent<{event: CalendarEvent, jsEvent: Event}>) => void} [oneventclick] Event activation listener.
298
+ * @property {(event: CustomEvent<{event: CalendarEvent, jsEvent: Event}>) => void} [oneventdblclick] Event double-activation listener.
299
+ * @property {(event: CustomEvent<{date: Date, allDay: boolean, view: CalendarView, jsEvent: Event}>) => void} [ondateclick] Date/time activation listener.
300
+ * @property {(event: CustomEvent<{start: Date, end: Date, allDay: boolean, view: CalendarView, jsEvent: Event}>) => void} [onselect] Range-selection listener.
301
+ * @property {(event: CustomEvent<CalendarEventChangeDetail>) => void} [oneventchange] Move/resize proposal listener.
302
+ * @property {(event: CustomEvent<{date: Date, view: CalendarView, jsEvent: Event}>) => void} [onnew] New-event command listener.
303
+ * @property {(event: CustomEvent<{date: Date, count: number, jsEvent: Event}>) => void} [onmoreclick] Month-overflow listener.
304
+ */
305
+ /**
306
+ * @typedef {Object} CalendarEventChangeDetail
307
+ * @property {CalendarEvent} event Proposed event.
308
+ * @property {CalendarEvent} oldEvent Previous event.
309
+ * @property {'move'|'resize'} action Edit action.
310
+ * @property {{milliseconds: number, days: number, minutes: number, endMilliseconds: number}} delta Edit delta.
311
+ * @property {Event} jsEvent Originating pointer or keyboard event.
312
+ * @property {() => boolean} revert Idempotent optimistic revert callback.
313
+ */
314
+ /** @typedef {{silent?: boolean}} CalendarSetOptions */
251
315
  /**
252
316
  * Accessible, dependency-free agenda/day/week/month/year scheduling surface.
253
317
  * @fires Calendar#viewchange
@@ -513,10 +577,8 @@ export declare class Calendar extends Component<CalendarOptions> {
513
577
  */
514
578
  _dayCountLabel(day: Date, count: number): string;
515
579
  /**
516
- * Resolves a message through the host translator, falling back to the built-in English text.
517
- *
518
- * Distinct from `msg()`: the built-in `msg` option answers the calendar's own vocabulary, so a
519
- * dotted key falls past it to the host translator, which is what these strings never had.
580
+ * Resolves a message through `msg()`, falling back to the built-in English text. Redundant now
581
+ * that `msg()` ends in the default catalogue; kept until the private copies are removed.
520
582
  * @param {string} key Message key.
521
583
  * @param {string} fallback Built-in text, with `%1`-style placeholders.
522
584
  * @param {...unknown} args Interpolation values.
@@ -109,9 +109,10 @@ export type CardViewOptions = {
109
109
  */
110
110
  headingLevel?: 1 | 2 | 3 | 4 | 5 | 6;
111
111
  /**
112
- * Accessible collection label.
112
+ * Accessible collection label; null resolves message
113
+ * `cardView.label`, "Card view".
113
114
  */
114
- label?: string;
115
+ label?: string | null;
115
116
  onrecordaction?: (event: CustomEvent<Record<string, unknown>>) => void;
116
117
  };
117
118
  export type CardViewState = {
@@ -203,7 +204,8 @@ export type CardRecordGroup = {
203
204
  * @property {'outlined'|'raised'|'filled'} [variant='outlined'] Card surface treatment.
204
205
  * @property {number} [loadingCount=6] Skeleton cards shown while loading.
205
206
  * @property {1|2|3|4|5|6} [headingLevel=3] Per-card title heading level.
206
- * @property {string} [label='Card view'] Accessible collection label.
207
+ * @property {string|null} [label=null] Accessible collection label; null resolves message
208
+ * `cardView.label`, "Card view".
207
209
  * @property {(event:CustomEvent<Record<string,unknown>>)=>void} [onrecordaction]
208
210
  */
209
211
  /**
@@ -304,8 +306,9 @@ export declare class CardView extends RecordView {
304
306
  * @param {CardViewOptions['groupBy']} groupBy Group field or resolver.
305
307
  * @param {unknown[]} [groupOrder=[]] Preferred group ids.
306
308
  * @param {ViewField[]} [fields=[]] Complete fields for accessor-aware grouping.
309
+ * @param {string} [ungroupedLabel='Ungrouped'] Label of the group collecting records without a value.
307
310
  * @returns {CardRecordGroup[]} Deterministic groups.
308
311
  */
309
- export declare function groupCardRecords(records: ViewRecord[], groupBy: CardViewOptions['groupBy'], groupOrder?: unknown[], fields?: ViewField[]): CardRecordGroup[];
312
+ export declare function groupCardRecords(records: ViewRecord[], groupBy: CardViewOptions['groupBy'], groupOrder?: unknown[], fields?: ViewField[], ungroupedLabel?: string): CardRecordGroup[];
310
313
  /** @param {unknown} value @returns {string} */
311
314
  export declare function normalizeCardWidth(value: unknown): string;
@@ -139,6 +139,13 @@ export type RecordCardOptions = {
139
139
  * Listener-free, owner-created controls such as a move handle.
140
140
  */
141
141
  controls?: Node[];
142
+ /**
143
+ * Resolves the card's built-in strings
144
+ * (`recordCard.select`, `recordCard.actions`, `recordCard.untitled`, `recordCard.selected`,
145
+ * `recordCard.notSelected`). An owning component passes its own `msg()`; omitted, the host
146
+ * translator and then the default English catalogue answer.
147
+ */
148
+ message?: (key: string, ...args: unknown[]) => string;
142
149
  };
143
150
  export type ResolvedRecordPreview = {
144
151
  /**
@@ -218,6 +225,10 @@ export type ResolvedRecordPreview = {
218
225
  * @property {'outlined'|'raised'|'filled'} [variant='outlined'] Surface treatment.
219
226
  * @property {1|2|3|4|5|6} [headingLevel=3] Card title heading level.
220
227
  * @property {Node[]} [controls=[]] Listener-free, owner-created controls such as a move handle.
228
+ * @property {(key: string, ...args: unknown[]) => string} [message] Resolves the card's built-in strings
229
+ * (`recordCard.select`, `recordCard.actions`, `recordCard.untitled`, `recordCard.selected`,
230
+ * `recordCard.notSelected`). An owning component passes its own `msg()`; omitted, the host
231
+ * translator and then the default English catalogue answer.
221
232
  */
222
233
  /**
223
234
  * @typedef {Object} ResolvedRecordPreview
@@ -22,6 +22,12 @@ export type ChartSpec = {
22
22
  * Engine-specific options.
23
23
  */
24
24
  options: Record<string, unknown>;
25
+ /**
26
+ * Whether the chart must not animate: the operating system asks
27
+ * for reduced motion, or the host sits inside a `data-zx-motion="reduced"` region. An adapter turns
28
+ * its engine's own animation off when this is true; `ChartJsAdapter` sets `animation: false`.
29
+ */
30
+ reducedMotion: boolean;
25
31
  /**
26
32
  * Point-selection callback.
27
33
  */
@@ -155,6 +161,9 @@ export type ChartOptions = {
155
161
  * @property {string} type Chart type.
156
162
  * @property {ChartData} data Chart data.
157
163
  * @property {Record<string, unknown>} options Engine-specific options.
164
+ * @property {boolean} reducedMotion Whether the chart must not animate: the operating system asks
165
+ * for reduced motion, or the host sits inside a `data-zx-motion="reduced"` region. An adapter turns
166
+ * its engine's own animation off when this is true; `ChartJsAdapter` sets `animation: false`.
158
167
  * @property {(detail: ChartSelectDetail) => void} onSelect Point-selection callback.
159
168
  */
160
169
  /**
@@ -223,6 +232,7 @@ export declare class Chart extends Component<ChartOptions> {
223
232
  _handle: ChartHandle;
224
233
  _destroyed: boolean;
225
234
  _observer: ResizeObserver;
235
+ _stopWatchingMotion: () => void;
226
236
  static cssName: string;
227
237
  /** @type {Readonly<ChartOptions>} */
228
238
  static defaults: Readonly<ChartOptions>;
@@ -29,6 +29,12 @@ export type ChecklistOptions = {
29
29
  * Fallback initial checked state.
30
30
  */
31
31
  defaultChecked?: boolean;
32
+ /**
33
+ * Whether the heading is left out. The group keeps the
34
+ * heading text as its accessible name (`aria-label`); a Field labelling the checklist names it
35
+ * instead, which is why the `checklist` field type sets this.
36
+ */
37
+ hideLabel?: boolean;
32
38
  /**
33
39
  * Async item loader.
34
40
  */
@@ -62,6 +68,9 @@ export type ChecklistLoadedDetail = {
62
68
  * @property {boolean} [search=true] Whether the search field is shown.
63
69
  * @property {number} [height=280] Maximum list height in pixels.
64
70
  * @property {boolean} [defaultChecked=false] Fallback initial checked state.
71
+ * @property {boolean} [hideLabel=false] Whether the heading is left out. The group keeps the
72
+ * heading text as its accessible name (`aria-label`); a Field labelling the checklist names it
73
+ * instead, which is why the `checklist` field type sets this.
65
74
  * @property {(() => Promise<ChecklistItem[]>|ChecklistItem[])|null} [load=null] Async item loader.
66
75
  * @property {Record<string, string>|Record<string, Record<string, string>>} [msg] Localized messages.
67
76
  * @property {(event: CustomEvent<ChecklistChangeDetail>) => void} [onchange] Change listener.
@@ -61,27 +61,14 @@ export type CodeEditorOptions = {
61
61
  value: string;
62
62
  }>) => void;
63
63
  };
64
- /**
65
- * @typedef {Object} CodeEditorOptions
66
- * @property {unknown} [value=''] Initial text.
67
- * @property {string} [name=''] Form field name.
68
- * @property {string} [language='text'] Language identifier shown to the user and exposed as data.
69
- * @property {string} [label='Code editor'] Accessible editor label.
70
- * @property {string} [placeholder=''] Placeholder text.
71
- * @property {number} [rows=12] Visible textarea rows.
72
- * @property {string} [indent='\t'] Text inserted by Tab and removed by Shift+Tab.
73
- * @property {'off'|'soft'|'hard'} [wrap='off'] Textarea wrapping behavior.
74
- * @property {boolean} [spellcheck=false] Whether browser spellcheck is enabled.
75
- * @property {boolean} [readOnly=false] Whether content can be selected but not changed.
76
- * @property {boolean} [disabled=false] Whether the editor is disabled.
77
- * @property {boolean} [status=true] Whether the line/column status is visible.
78
- * @property {(event: CustomEvent<{value:string}>) => void} [oninput] Input listener.
79
- * @property {(event: CustomEvent<{value:string}>) => void} [onchange] Change listener.
80
- */
81
64
  /**
82
65
  * Dependency-free source editor for structured text, Markdown, JSON and code. It deliberately uses
83
66
  * a native textarea: values remain text-safe, browser undo and IME behavior stay intact, and Tab /
84
67
  * Shift+Tab provide predictable indentation without a third-party editor runtime.
68
+ *
69
+ * Capturing Tab is what a code surface has to do, and it would be a keyboard trap if nothing undid
70
+ * it: Escape releases the capture until the next keystroke in the editor, so Escape then Tab (or
71
+ * Shift+Tab) moves focus out of the editor as it would leave any other field.
85
72
  * @fires CodeEditor#input
86
73
  * @fires CodeEditor#change
87
74
  * @extends {Component<CodeEditorOptions>}
@@ -95,6 +82,8 @@ export declare class CodeEditor extends Component<CodeEditorOptions> {
95
82
  _position: HTMLElement;
96
83
  _header: HTMLElement;
97
84
  _input: HTMLTextAreaElement;
85
+ /** Set by Escape: the next Tab moves focus instead of indenting. */
86
+ _tabReleased: boolean;
98
87
  static cssName: string;
99
88
  /** @type {CodeEditorOptions} */
100
89
  static defaults: CodeEditorOptions;
@@ -1,6 +1,6 @@
1
1
  import { Component } from '../../core/component.js';
2
2
  export type MenuItem = import('../../internal/menu-items.js').MenuItem;
3
- export type ContextMenuEntry = import('../../internal/menu-items.js').MenuEntry;
3
+ export type ContextMenuEntry = import('../../internal/menu-items.js').MenuItem | import('../../internal/menu-items.js').MenuHeading | import('../../internal/menu-items.js').MenuSeparator | '-';
4
4
  export type ContextMenuOptions = {
5
5
  /**
6
6
  * Menu
@@ -35,7 +35,11 @@ export type ContextMenuOptions = {
35
35
  onclose?: (event: CustomEvent<Record<string, never>>) => void;
36
36
  };
37
37
  /** @typedef {import('../../internal/menu-items.js').MenuItem} MenuItem */
38
- /** @typedef {import('../../internal/menu-items.js').MenuEntry} ContextMenuEntry */
38
+ /**
39
+ * A context menu's entries: the shared menu model without `choice` rows, which a menu that closes
40
+ * on every activation cannot hold.
41
+ * @typedef {import('../../internal/menu-items.js').MenuItem|import('../../internal/menu-items.js').MenuHeading|import('../../internal/menu-items.js').MenuSeparator|'-'} ContextMenuEntry
42
+ */
39
43
  /**
40
44
  * @typedef {Object} ContextMenuOptions
41
45
  * @property {ContextMenuEntry[]|((context: Element|null) => ContextMenuEntry[])} [items=[]] Menu
@@ -37,7 +37,7 @@ export type SelectFilterDefinition = {
37
37
  */
38
38
  options?: Array<unknown | DataFilterOption>;
39
39
  /**
40
- * Empty option label.
40
+ * Empty option label; omitted resolves message `dataFilter.all`, "All".
41
41
  */
42
42
  emptyLabel?: string;
43
43
  };
@@ -94,7 +94,7 @@ export type DataFilterOptions = {
94
94
  */
95
95
  autoApply?: boolean;
96
96
  /**
97
- * Clear button label; null resolves `dataFilter.clear`.
97
+ * Clear button label; null resolves message `dataFilter.clear`, "Clear".
98
98
  */
99
99
  clearLabel?: string | null;
100
100
  onfilter?: (event: CustomEvent<DataFilterEventDetail>) => void;
@@ -118,7 +118,7 @@ export type DataFilterEventDetail = {
118
118
  * @property {Array<string|((row: DataFilterRow) => unknown)>} [fields] Row fields combined with OR.
119
119
  * @property {(row: DataFilterRow) => unknown} [get] Custom value accessor.
120
120
  * @property {Array<unknown|DataFilterOption>} [options] Explicit options; omitted derives distinct values.
121
- * @property {string} [emptyLabel] Empty option label.
121
+ * @property {string} [emptyLabel] Empty option label; omitted resolves message `dataFilter.all`, "All".
122
122
  */
123
123
  /**
124
124
  * @typedef {Object} TextFilterDefinition
@@ -142,7 +142,7 @@ export type DataFilterEventDetail = {
142
142
  * @property {FilterDefinition[]} [filters=[]] Declarative filters.
143
143
  * @property {DataFilterRow[]} [data=[]] Rows to filter.
144
144
  * @property {boolean} [autoApply=true] Apply and emit whenever a control changes.
145
- * @property {string|null} [clearLabel=null] Clear button label; null resolves `dataFilter.clear`.
145
+ * @property {string|null} [clearLabel=null] Clear button label; null resolves message `dataFilter.clear`, "Clear".
146
146
  * @property {(event: CustomEvent<DataFilterEventDetail>) => void} [onfilter]
147
147
  */
148
148
  /** @typedef {{rows: DataFilterRow[], state: Record<string, unknown>}} DataFilterEventDetail */
@@ -29,7 +29,8 @@ export type DateRangeBoxOptions = {
29
29
  */
30
30
  placeholder?: string | null;
31
31
  /**
32
- * Show a clear button while a range is present.
32
+ * Show a clear button while a range is present and the box is
33
+ * enabled; without it the input keeps no room for one.
33
34
  */
34
35
  clearable?: boolean;
35
36
  /**
@@ -119,6 +120,7 @@ export declare function formatRangeText(range: DateRange | null, format: string,
119
120
  export declare class DateRangeBox extends Component<DateRangeBoxOptions> {
120
121
  _originalState: string;
121
122
  _originalAriaDisabled: string;
123
+ _originalClearable: string;
122
124
  _format: string;
123
125
  _separator: string;
124
126
  _disabled: boolean;
@@ -209,6 +211,8 @@ export declare class DateRangeBox extends Component<DateRangeBoxOptions> {
209
211
  _placeholder(): string;
210
212
  /** @returns {void} */
211
213
  _syncDisplay(): void;
214
+ /** A disabled box offers no clear button: there is nothing it could do. @returns {void} */
215
+ _syncClear(): void;
212
216
  /** @returns {void} */
213
217
  _syncDisabled(): void;
214
218
  /** @returns {void} */
@@ -26,7 +26,8 @@ export type DateboxOptions = {
26
26
  */
27
27
  placeholder?: string | null;
28
28
  /**
29
- * Show a clear button when a value is present.
29
+ * Show a clear button while a value is present and the box is
30
+ * enabled; without it the input keeps no room for one.
30
31
  */
31
32
  clearable?: boolean;
32
33
  /**
@@ -66,7 +67,8 @@ export type DateboxUnit = 'date' | 'seconds';
66
67
  * @property {Date|null} [min=null] Earliest selectable date.
67
68
  * @property {Date|null} [max=null] Latest selectable date.
68
69
  * @property {string|null} [placeholder=null] Input placeholder; null derives one from the format.
69
- * @property {boolean} [clearable=true] Show a clear button when a value is present.
70
+ * @property {boolean} [clearable=true] Show a clear button while a value is present and the box is
71
+ * enabled; without it the input keeps no room for one.
70
72
  * @property {boolean} [disabled=false] Disable all controls.
71
73
  * @property {(event: CustomEvent<{date: Date|null}>) => void} [onchange] Change listener.
72
74
  * @property {(event: CustomEvent<{text: string}>) => void} [oninvalid] Invalid-input listener.
@@ -86,6 +88,7 @@ export type DateboxUnit = 'date' | 'seconds';
86
88
  export declare class Datebox extends Component<DateboxOptions> {
87
89
  _originalState: string;
88
90
  _originalAriaDisabled: string;
91
+ _originalClearable: string;
89
92
  _format: string;
90
93
  _disabled: boolean;
91
94
  _open: boolean;
@@ -142,6 +145,8 @@ export declare class Datebox extends Component<DateboxOptions> {
142
145
  _normalizeValue(value: Date | number | string | null | unknown): Date | null;
143
146
  /** @returns {void} */
144
147
  _syncDisplay(): void;
148
+ /** A disabled box offers no clear button: there is nothing it could do. @returns {void} */
149
+ _syncClear(): void;
145
150
  /** @returns {void} */
146
151
  _syncDisabled(): void;
147
152
  /** @returns {void} */
@@ -50,7 +50,7 @@ export type DialogOptions = {
50
50
  toElement: () => Node | null;
51
51
  } | null;
52
52
  /**
53
- * Element whose nearest Zx theme scope owns the overlay; defaults to the opener.
53
+ * 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.
54
54
  */
55
55
  scope?: Element | string | null;
56
56
  /**
@@ -137,6 +137,14 @@ export type ConfirmOptions = {
137
137
  * Whether the confirmation action is dangerous.
138
138
  */
139
139
  danger?: boolean;
140
+ /**
141
+ * Text the reader must type before the confirm button
142
+ * enables — the name of what is about to be deleted, say. The dialog adds an input labelled
143
+ * "Type <confirmText> to confirm" (message `dialog.typeToConfirm`, `%1` standing for the text),
144
+ * focuses it, and enables the confirm button, and Enter, only while its value matches exactly,
145
+ * ignoring surrounding spaces.
146
+ */
147
+ confirmText?: string | null;
140
148
  };
141
149
  export type PromptOptions = {
142
150
  /**
@@ -155,6 +163,14 @@ export type PromptOptions = {
155
163
  * Input placeholder.
156
164
  */
157
165
  placeholder?: string;
166
+ /**
167
+ * Confirmation label.
168
+ */
169
+ okLabel?: string;
170
+ /**
171
+ * Cancellation label.
172
+ */
173
+ cancelLabel?: string;
158
174
  };
159
175
  /** @typedef {'default'|'primary'|'danger'|'ghost'} DialogButtonKind */
160
176
  /**
@@ -173,7 +189,7 @@ export type PromptOptions = {
173
189
  * @property {DialogButton[]} [buttons=[]] Footer buttons.
174
190
  * @property {boolean} [closable=true] Whether Escape and the header button may close the dialog.
175
191
  * @property {Node|string|number|{toElement: () => Node|null}|null} [content=null] Body content.
176
- * @property {Element|string|null} [scope=null] Element whose nearest Zx theme scope owns the overlay; defaults to the opener.
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.
177
193
  * @property {(event: CustomEvent<Record<string, never>>) => void} [onopen] Open event listener.
178
194
  * @property {(event: CustomEvent<{result: unknown}>) => void} [onclose] Close event listener.
179
195
  * @property {(event: CustomEvent<Record<string, never>>) => void} [oncancel] Cancel event listener.
@@ -204,6 +220,11 @@ export type PromptOptions = {
204
220
  * @property {string} [okLabel='OK'] Confirmation label.
205
221
  * @property {string} [cancelLabel='Cancel'] Cancellation label.
206
222
  * @property {boolean} [danger=false] Whether the confirmation action is dangerous.
223
+ * @property {string|null} [confirmText=null] Text the reader must type before the confirm button
224
+ * enables — the name of what is about to be deleted, say. The dialog adds an input labelled
225
+ * "Type <confirmText> to confirm" (message `dialog.typeToConfirm`, `%1` standing for the text),
226
+ * focuses it, and enables the confirm button, and Enter, only while its value matches exactly,
227
+ * ignoring surrounding spaces.
207
228
  */
208
229
  /**
209
230
  * @typedef {Object} PromptOptions
@@ -211,6 +232,8 @@ export type PromptOptions = {
211
232
  * @property {Node|string|number|null} [message=''] Prompt message.
212
233
  * @property {string} [value=''] Initial input value.
213
234
  * @property {string} [placeholder=''] Input placeholder.
235
+ * @property {string} [okLabel='OK'] Confirmation label.
236
+ * @property {string} [cancelLabel='Cancel'] Cancellation label.
214
237
  */
215
238
  /**
216
239
  * Structured modal with a title, body, footer actions, and switchable views.
@@ -285,17 +308,18 @@ export declare class Dialog extends Modal {
285
308
  */
286
309
  static alert({ title, message, okLabel }?: AlertOptions): Promise<void>;
287
310
  /**
288
- * Opens a confirmation dialog.
311
+ * Opens a confirmation dialog. With `confirmText` it becomes a type-to-confirm dialog: the
312
+ * confirm button stays disabled until the reader has typed that text.
289
313
  * @param {ConfirmOptions} [options={}] Confirmation options.
290
- * @returns {Promise<boolean>}
314
+ * @returns {Promise<boolean>} True when confirmed; false on Cancel, Escape, or the close button.
291
315
  */
292
- static confirm({ title, message, okLabel, cancelLabel, danger }?: ConfirmOptions): Promise<boolean>;
316
+ static confirm({ title, message, okLabel, cancelLabel, danger, confirmText }?: ConfirmOptions): Promise<boolean>;
293
317
  /**
294
318
  * Opens a single-line text prompt.
295
319
  * @param {PromptOptions} [options={}] Prompt options.
296
320
  * @returns {Promise<string|null>}
297
321
  */
298
- static prompt({ title, message, value, placeholder }?: PromptOptions): Promise<string | null>;
322
+ static prompt({ title, message, value, placeholder, okLabel, cancelLabel }?: PromptOptions): Promise<string | null>;
299
323
  /**
300
324
  * Applies the dialog width. Subclasses that size themselves on a different axis override this.
301
325
  *
@@ -313,6 +337,22 @@ export declare class Dialog extends Modal {
313
337
  */
314
338
  _message(key: string, fallback: string): string;
315
339
  }
340
+ /**
341
+ * Reports whether what the reader typed confirms a type-to-confirm dialog: the same text, exactly
342
+ * — case and inner spacing included — once surrounding spaces are ignored on both sides.
343
+ * @param {unknown} typed Input value.
344
+ * @param {unknown} expected Text the dialog asks for.
345
+ * @returns {boolean}
346
+ */
347
+ export declare function typedConfirmation(typed: unknown, expected: unknown): boolean;
348
+ /**
349
+ * Splits the type-to-confirm message around `%1`, where the text to type goes. A translation that
350
+ * leaves `%1` out gets the text after it, following a space; a second `%1` is filled in as text.
351
+ * @param {string} template Message such as "Type %1 to confirm".
352
+ * @param {string} expected Text to type.
353
+ * @returns {[string, string]} The text before and after the text to type.
354
+ */
355
+ export declare function typeToConfirmParts(template: string, expected: string): [string, string];
316
356
  /**
317
357
  * Copies footer-button descriptors without mutating the caller's array or objects, and settles
318
358
  * the two booleans the footer renders from.
@@ -1,6 +1,4 @@
1
1
  import { Component } from '../../core/component.js';
2
- declare const HANDLE_POINTER_DISMISS: unique symbol;
3
- declare const HANDLE_ESCAPE_DISMISS: unique symbol;
4
2
  export type DropdownOptions = {
5
3
  /**
6
4
  * Panel content.
@@ -29,7 +27,7 @@ export type DropdownOptions = {
29
27
  */
30
28
  closeOnSelect?: boolean;
31
29
  /**
32
- * Element whose nearest Zx theme scope owns the panel; defaults to the anchor.
30
+ * Element whose nearest Zx theme scope owns the panel; defaults to the anchor. Resolved on every open, so an anchor connected after construction still gets its scope.
33
31
  */
34
32
  scope?: Element | string | null;
35
33
  /**
@@ -49,12 +47,22 @@ export type DropdownOptions = {
49
47
  * @property {boolean} [matchWidth=false] Whether the panel matches the anchor width.
50
48
  * @property {'click'|'manual'} [openOn='click'] Trigger behavior.
51
49
  * @property {boolean} [closeOnSelect=false] Whether a click within the panel closes it.
52
- * @property {Element|string|null} [scope=null] Element whose nearest Zx theme scope owns the panel; defaults to the anchor.
50
+ * @property {Element|string|null} [scope=null] Element whose nearest Zx theme scope owns the panel; defaults to the anchor. Resolved on every open, so an anchor connected after construction still gets its scope.
53
51
  * @property {(event: CustomEvent<Record<string, never>>) => void} [onopen] Open event listener.
54
52
  * @property {(event: CustomEvent<Record<string, never>>) => void} [onclose] Close event listener.
55
53
  */
56
54
  /**
57
55
  * Generic anchored floating panel using the browser popover top layer.
56
+ *
57
+ * Open, the panel is one entry on the overlay stack (`core/overlay-stack.js`): Escape closes it
58
+ * only while it is the topmost layer that takes Escape, a press outside it and every overlay opened
59
+ * from it closes it, and it closes with the overlay its anchor sits in. Inside an open dialog the
60
+ * panel is hosted by that dialog, so `showModal()` does not make it inert.
61
+ *
62
+ * The panel follows its trigger in the Tab order: Tab on the anchor of an open panel moves into
63
+ * the panel's first focusable control (or onto the panel itself when it carries a `tabindex`),
64
+ * Tab past the panel's last control continues after the anchor, and Shift+Tab from the first goes
65
+ * back to the anchor. Closing while focus is inside returns it to the anchor.
58
66
  * @fires Dropdown#open
59
67
  * @fires Dropdown#close
60
68
  * @extends {Component<DropdownOptions>}
@@ -115,9 +123,16 @@ export declare class Dropdown extends Component<DropdownOptions> {
115
123
  * @returns {void}
116
124
  */
117
125
  destroy(): void;
118
- /** @param {PointerEvent} event @returns {void} */
119
- [HANDLE_POINTER_DISMISS](event: PointerEvent): void;
120
- /** @param {KeyboardEvent} event @returns {void} */
121
- [HANDLE_ESCAPE_DISMISS](event: KeyboardEvent): void;
126
+ /**
127
+ * Internal seam for components built on a Dropdown (MenuButton, ContextMenu, the app rail):
128
+ * replaces what Escape does when the overlay stack routes it to this panel, and takes the panel
129
+ * out of the anchor's Tab order — a menu is reached with the arrow keys, not Tab.
130
+ * @param {{onEscape?: ((event: KeyboardEvent) => void)|null, tabReach?: boolean}} settings
131
+ * @returns {this}
132
+ * @internal
133
+ */
134
+ _configure(settings: {
135
+ onEscape?: ((event: KeyboardEvent) => void) | null;
136
+ tabReach?: boolean;
137
+ }): this;
122
138
  }
123
- export {};
@@ -115,7 +115,7 @@ export type EntityRefOptions = {
115
115
  */
116
116
  actions?: EntityRefActionEntry[];
117
117
  /**
118
- * Density-independent identity size.
118
+ * Size of the icon and the identity text.
119
119
  */
120
120
  size?: 'sm' | 'md' | 'lg';
121
121
  /**
@@ -230,7 +230,7 @@ export type EntityRefState = {
230
230
  * @property {EntityRefMetadata[]} [metadata=[]] Labelled dense metadata.
231
231
  * @property {EntityRefLinkValue} [link=null] Optional native primary link.
232
232
  * @property {EntityRefActionEntry[]} [actions=[]] Secondary controls; element actions keep their own behavior.
233
- * @property {'sm'|'md'|'lg'} [size='md'] Density-independent identity size.
233
+ * @property {'sm'|'md'|'lg'} [size='md'] Size of the icon and the identity text.
234
234
  * @property {boolean} [wrap=false] Whether long identity text may wrap instead of truncating.
235
235
  * @property {string} [actionsLabel='Entity actions'] Accessible name for secondary actions.
236
236
  * @property {(event: CustomEvent<{id: unknown, entity: Readonly<EntityRefState>, href: string, event: MouseEvent}>) => void} [onactivate]