@cscfi/csc-ui 4.0.0-alpha.9 → 4.0.0-rc.2

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 (203) hide show
  1. package/README.md +36 -2
  2. package/dist/csc-ui.js +22771 -14908
  3. package/dist/custom-elements.json +8943 -5632
  4. package/dist/docs/c-accordion/usage.md +60 -0
  5. package/dist/docs/c-accordion-item/usage.md +1 -0
  6. package/dist/docs/c-alert/usage.md +5 -5
  7. package/dist/docs/c-autocomplete/usage.md +156 -0
  8. package/dist/docs/c-badge/usage.md +50 -0
  9. package/dist/docs/c-breadcrumb/usage.md +104 -0
  10. package/dist/docs/c-breadcrumb-item/usage.md +1 -0
  11. package/dist/docs/c-button/usage.md +13 -0
  12. package/dist/docs/c-button-group/usage.md +16 -2
  13. package/dist/docs/c-card/usage.md +55 -0
  14. package/dist/docs/c-card-actions/usage.md +1 -0
  15. package/dist/docs/c-card-content/usage.md +1 -0
  16. package/dist/docs/c-card-title/usage.md +3 -0
  17. package/dist/docs/c-checkbox/usage.md +37 -5
  18. package/dist/docs/c-color-picker/usage.md +160 -0
  19. package/dist/docs/c-csc-logo/usage.md +25 -0
  20. package/dist/docs/c-data-table/usage.md +180 -0
  21. package/dist/docs/c-date-picker/usage.md +224 -0
  22. package/dist/docs/c-divider/usage.md +36 -0
  23. package/dist/docs/c-file-upload/usage.md +189 -0
  24. package/dist/docs/c-icon/usage.md +51 -0
  25. package/dist/docs/c-icon-button/usage.md +80 -0
  26. package/dist/docs/c-link/usage.md +45 -1
  27. package/dist/docs/c-list/usage.md +50 -0
  28. package/dist/docs/c-list-item/usage.md +1 -0
  29. package/dist/docs/c-list-item-title/usage.md +1 -0
  30. package/dist/docs/c-loader/usage.md +52 -1
  31. package/dist/docs/c-login-button/usage.md +1 -0
  32. package/dist/docs/c-login-buttons/usage.md +48 -0
  33. package/dist/docs/c-login-card/usage.md +45 -0
  34. package/dist/docs/c-login-card-actions/usage.md +1 -0
  35. package/dist/docs/c-login-card-content/usage.md +1 -0
  36. package/dist/docs/c-login-card-title/usage.md +3 -0
  37. package/dist/docs/c-main/usage.md +21 -1
  38. package/dist/docs/c-menu/usage.md +15 -0
  39. package/dist/docs/c-menu-item/usage.md +11 -0
  40. package/dist/docs/c-message/usage.md +56 -0
  41. package/dist/docs/c-modal/usage.md +18 -12
  42. package/dist/docs/c-navigation-button/usage.md +32 -0
  43. package/dist/docs/c-number-field/usage.md +114 -0
  44. package/dist/docs/c-option/usage.md +1 -0
  45. package/dist/docs/c-option-value/usage.md +1 -0
  46. package/dist/docs/c-otp-input/usage.md +95 -0
  47. package/dist/docs/c-page/usage.md +44 -0
  48. package/dist/docs/c-pagination/usage.md +69 -0
  49. package/dist/docs/c-popover/usage.md +1 -1
  50. package/dist/docs/c-progress-bar/usage.md +1 -1
  51. package/dist/docs/c-progress-circle/usage.md +1 -1
  52. package/dist/docs/c-radio/usage.md +9 -6
  53. package/dist/docs/c-radio-group/usage.md +5 -6
  54. package/dist/docs/c-select/usage.md +131 -0
  55. package/dist/docs/c-side-navigation/usage.md +70 -0
  56. package/dist/docs/c-side-navigation-item/usage.md +1 -0
  57. package/dist/docs/c-side-navigation-title/usage.md +1 -0
  58. package/dist/docs/c-slider/usage.md +78 -0
  59. package/dist/docs/c-spinner/usage.md +1 -1
  60. package/dist/docs/c-status/usage.md +46 -0
  61. package/dist/docs/c-step/usage.md +1 -0
  62. package/dist/docs/c-steps/usage.md +35 -0
  63. package/dist/docs/c-sub-navigation-item/usage.md +1 -0
  64. package/dist/docs/c-switch/usage.md +10 -3
  65. package/dist/docs/c-tab/usage.md +1 -0
  66. package/dist/docs/c-tab-buttons/usage.md +15 -0
  67. package/dist/docs/c-tab-item/usage.md +1 -0
  68. package/dist/docs/c-tab-items/usage.md +1 -0
  69. package/dist/docs/c-table/usage.md +1 -1
  70. package/dist/docs/c-tabs/usage.md +77 -0
  71. package/dist/docs/c-tag/usage.md +1 -0
  72. package/dist/docs/c-tags/usage.md +85 -0
  73. package/dist/docs/c-text-field/usage.md +109 -0
  74. package/dist/docs/c-time-picker/usage.md +170 -0
  75. package/dist/docs/c-toasts/usage.md +27 -3
  76. package/dist/docs/c-toolbar/usage.md +17 -0
  77. package/dist/docs/c-tree-select/usage.md +156 -0
  78. package/dist/floating-ui.dom-DvzxEaDJ.js +1292 -0
  79. package/dist/styles/css/tailwind-theme.css +2 -1
  80. package/dist/styles/css/tokens.css +609 -178
  81. package/dist/vscode.css-custom-data.json +556 -99
  82. package/dist/vscode.html-custom-data.json +1050 -480
  83. package/dist/web-types.json +3303 -1707
  84. package/dist-types/components/c-accordion/CAccordion.vue.d.ts +21 -25
  85. package/dist-types/components/c-accordion-item/CAccordionItem.vue.d.ts +13 -12
  86. package/dist-types/components/c-alert/CAlert.vue.d.ts +12 -17
  87. package/dist-types/components/c-autocomplete/CAutocomplete.vue.d.ts +124 -31
  88. package/dist-types/components/c-breadcrumb/CBreadcrumb.vue.d.ts +35 -0
  89. package/dist-types/components/c-breadcrumb/fit.d.ts +29 -0
  90. package/dist-types/components/c-breadcrumb-item/CBreadcrumbItem.vue.d.ts +31 -0
  91. package/dist-types/components/c-button/CButton.vue.d.ts +52 -63
  92. package/dist-types/components/c-button-group/CButtonGroup.vue.d.ts +16 -14
  93. package/dist-types/components/c-card/CCard.vue.d.ts +2 -3
  94. package/dist-types/components/c-card-actions/CCardActions.vue.d.ts +5 -7
  95. package/dist-types/components/c-card-title/CCardTitle.vue.d.ts +11 -1
  96. package/dist-types/components/c-checkbox/CCheckbox.vue.d.ts +33 -52
  97. package/dist-types/components/c-color-picker/CColorPicker.vue.d.ts +189 -0
  98. package/dist-types/components/c-color-picker/colors.d.ts +66 -0
  99. package/dist-types/components/c-csc-logo/CCscLogo.vue.d.ts +1 -3
  100. package/dist-types/components/c-data-table/CDataTable.vue.d.ts +75 -51
  101. package/dist-types/components/c-date-picker/CDatePicker.vue.d.ts +277 -0
  102. package/dist-types/components/c-date-picker/dates.d.ts +119 -0
  103. package/dist-types/components/c-dropdown/CDropdown.vue.d.ts +51 -8
  104. package/dist-types/components/c-file-upload/CFileUpload.vue.d.ts +204 -0
  105. package/dist-types/components/c-file-upload/files.d.ts +99 -0
  106. package/dist-types/components/c-icon-button/CIconButton.vue.d.ts +23 -36
  107. package/dist-types/components/c-input/CInput.vue.d.ts +21 -43
  108. package/dist-types/components/c-link/CLink.vue.d.ts +6 -14
  109. package/dist-types/components/c-list/CList.vue.d.ts +4 -6
  110. package/dist-types/components/c-list-item/CListItem.vue.d.ts +14 -19
  111. package/dist-types/components/c-list-item-title/CListItemTitle.vue.d.ts +3 -2
  112. package/dist-types/components/c-loader/CLoader.vue.d.ts +13 -29
  113. package/dist-types/components/c-login-button/CLoginButton.vue.d.ts +9 -9
  114. package/dist-types/components/c-login-card/CLoginCard.vue.d.ts +11 -16
  115. package/dist-types/components/c-login-card-actions/CLoginCardActions.vue.d.ts +5 -7
  116. package/dist-types/components/c-login-card-title/CLoginCardTitle.vue.d.ts +11 -1
  117. package/dist-types/components/c-main/CMain.vue.d.ts +12 -5
  118. package/dist-types/components/c-menu/CMenu.vue.d.ts +17 -16
  119. package/dist-types/components/c-menu-item/CMenuItem.vue.d.ts +27 -35
  120. package/dist-types/components/c-message/CMessage.vue.d.ts +5 -15
  121. package/dist-types/components/c-modal/CModal.vue.d.ts +3 -3
  122. package/dist-types/components/c-navigation-button/CNavigationButton.vue.d.ts +20 -1
  123. package/dist-types/components/c-number-field/CNumberField.vue.d.ts +169 -0
  124. package/dist-types/components/c-number-field/numbers.d.ts +58 -0
  125. package/dist-types/components/c-option/COption.vue.d.ts +1 -1
  126. package/dist-types/components/c-otp-input/COtpInput.vue.d.ts +16 -30
  127. package/dist-types/components/c-page/CPage.vue.d.ts +2 -3
  128. package/dist-types/components/c-pagination/CPagination.vue.d.ts +56 -26
  129. package/dist-types/components/c-popover/CPopover.vue.d.ts +11 -7
  130. package/dist-types/components/c-progress-bar/CProgressBar.vue.d.ts +10 -14
  131. package/dist-types/components/c-progress-circle/CProgressCircle.vue.d.ts +7 -7
  132. package/dist-types/components/c-radio-group/CRadioGroup.vue.d.ts +11 -8
  133. package/dist-types/components/c-select/CSelect.vue.d.ts +119 -35
  134. package/dist-types/components/c-side-navigation/CSideNavigation.vue.d.ts +10 -18
  135. package/dist-types/components/c-side-navigation-item/CSideNavigationItem.vue.d.ts +22 -14
  136. package/dist-types/components/c-slider/CSlider.vue.d.ts +29 -73
  137. package/dist-types/components/c-spinner/CSpinner.vue.d.ts +4 -8
  138. package/dist-types/components/c-status/CStatus.vue.d.ts +8 -9
  139. package/dist-types/components/c-step/CStep.vue.d.ts +6 -4
  140. package/dist-types/components/c-steps/CSteps.vue.d.ts +3 -7
  141. package/dist-types/components/c-sub-navigation-item/CSubNavigationItem.vue.d.ts +23 -17
  142. package/dist-types/components/c-switch/CSwitch.vue.d.ts +17 -30
  143. package/dist-types/components/c-tab/CTab.vue.d.ts +11 -28
  144. package/dist-types/components/c-tab-buttons/CTabButtons.vue.d.ts +11 -13
  145. package/dist-types/components/c-tab-item/CTabItem.vue.d.ts +4 -5
  146. package/dist-types/components/c-tab-items/CTabItems.vue.d.ts +5 -4
  147. package/dist-types/components/c-table/CTable.vue.d.ts +7 -7
  148. package/dist-types/components/c-tabs/CTabs.vue.d.ts +13 -20
  149. package/dist-types/components/c-tag/CTag.vue.d.ts +22 -21
  150. package/dist-types/components/c-tags/CTags.vue.d.ts +9 -10
  151. package/dist-types/components/c-text-field/CTextField.vue.d.ts +74 -77
  152. package/dist-types/components/c-time-picker/CTimePicker.vue.d.ts +205 -0
  153. package/dist-types/components/c-time-picker/times.d.ts +82 -0
  154. package/dist-types/components/c-toast/CToast.vue.d.ts +3 -4
  155. package/dist-types/components/c-toast/swipe.d.ts +40 -0
  156. package/dist-types/components/c-toasts/CToasts.vue.d.ts +14 -16
  157. package/dist-types/components/c-toolbar/CToolbar.vue.d.ts +10 -1
  158. package/dist-types/components/c-tooltip/CTooltip.vue.d.ts +12 -8
  159. package/dist-types/components/c-tree-select/CTreeSelect.vue.d.ts +257 -0
  160. package/dist-types/index.d.ts +41 -32
  161. package/dist-types/registry.d.ts +9 -0
  162. package/dist-types/shared/FieldMessage.vue.d.ts +8 -5
  163. package/dist-types/shared/PanelHeadingRow.vue.d.ts +13 -0
  164. package/dist-types/shared/SelectionIndicator.vue.d.ts +21 -0
  165. package/dist-types/shared/TypedField.vue.d.ts +48 -0
  166. package/dist-types/shared/appDefaults.d.ts +75 -0
  167. package/dist-types/shared/defineElement.d.ts +1 -0
  168. package/dist-types/shared/inputMask.d.ts +106 -0
  169. package/dist-types/shared/lightDismiss.d.ts +35 -0
  170. package/dist-types/shared/modalStack.d.ts +4 -3
  171. package/dist-types/shared/navigationDrawer.d.ts +4 -0
  172. package/dist-types/shared/optionLabel.d.ts +18 -0
  173. package/dist-types/shared/pageLock.d.ts +26 -0
  174. package/dist-types/shared/peekCap.d.ts +35 -0
  175. package/dist-types/shared/popoverChain.d.ts +13 -10
  176. package/dist-types/shared/positionArea.d.ts +9 -4
  177. package/dist-types/shared/reducedMotion.d.ts +10 -0
  178. package/dist-types/shared/selectAll.d.ts +29 -0
  179. package/dist-types/shared/splitMatches.d.ts +18 -0
  180. package/dist-types/shared/useAnchoredPanel.d.ts +107 -0
  181. package/dist-types/shared/useControlAttrs.d.ts +8 -0
  182. package/dist-types/shared/useDesignatedTrigger.d.ts +5 -4
  183. package/dist-types/shared/useFallbackPosition.d.ts +71 -0
  184. package/dist-types/shared/useHostEmit.d.ts +38 -0
  185. package/dist-types/shared/useIdReferences.d.ts +39 -0
  186. package/dist-types/shared/useKeyboardModality.d.ts +7 -0
  187. package/dist-types/shared/useNarrowViewport.d.ts +19 -0
  188. package/dist-types/shared/useScrollStrip.d.ts +39 -0
  189. package/dist-types/shared/useStatusAnnouncer.d.ts +33 -0
  190. package/dist-types/shared/useTypedField.d.ts +108 -0
  191. package/dist-types/shared/valueEvents.d.ts +41 -0
  192. package/dist-types/shared/visualViewport.d.ts +51 -0
  193. package/dist-types/tag-name-map.d.ts +1572 -672
  194. package/dist-types/theme/applyTheme.d.ts +6 -6
  195. package/dist-types/theme/chart-data.d.ts +51 -0
  196. package/dist-types/theme/ramp.d.ts +38 -0
  197. package/dist-types/theme/themeMode.d.ts +51 -0
  198. package/dist-types/types.d.ts +7 -11
  199. package/package.json +32 -21
  200. package/dist/css-anchor-positioning-fn-RTxo68pt.js +0 -6447
  201. package/dist/docs/c-toast/usage.md +0 -1
  202. package/dist-types/shared/anchorPolyfill.d.ts +0 -24
  203. package/dist-types/shared/emitModelValue.d.ts +0 -37
@@ -2,113 +2,105 @@
2
2
  * GENERATED by scripts/analyzer/tag-map.mjs — do not edit.
3
3
  * Regenerate with `pnpm run docs:manifest`.
4
4
  *
5
- * Typed element interfaces for every registered custom element, plus the
5
+ * Typed element interfaces for every public custom element, plus the
6
6
  * global `HTMLElementTagNameMap` augmentation that makes
7
7
  * `document.createElement('c-button')` and `querySelector('c-button')`
8
- * return the typed element.
8
+ * return the typed element. Also the `CAppDefaults` map (tag → props a
9
+ * consumer may set app-wide with `applyDefaults()`) and its runtime twin
10
+ * `DEFAULTABLE_PROPS`, both derived from the `@defaultable` prop tags.
9
11
  */
10
- import type { CAutocompleteFilter, CAutocompleteItem } from './components/c-autocomplete/CAutocomplete.vue';
12
+ import type { CAccordionValue } from './components/c-accordion/CAccordion.vue';
13
+ import type { CAutocompleteFilter, CAutocompleteItem, CAutocompleteTexts, CAutocompleteValue } from './components/c-autocomplete/CAutocomplete.vue';
14
+ import type { CBreadcrumbTexts } from './components/c-breadcrumb/CBreadcrumb.vue';
11
15
  import type { CButtonGroupValue } from './components/c-button-group/CButtonGroup.vue';
16
+ import type { CColorPickerSwatch, CColorPickerTexts, CColorPickerValue } from './components/c-color-picker/CColorPicker.vue';
12
17
  import type { CDataTableCellContent, CDataTableColumn, CDataTableExpandedContext, CDataTableRow, CDataTableSort, CDataTableTexts } from './components/c-data-table/CDataTable.vue';
13
- import type { CPaginationOptions } from './components/c-pagination/CPagination.vue';
18
+ import type { CDatePickerDisabledDate, CDatePickerText, CDatePickerTexts, CDatePickerValue } from './components/c-date-picker/CDatePicker.vue';
19
+ import type { CFileUploadEntry, CFileUploadFunction, CFileUploadRejection, CFileUploadTexts } from './components/c-file-upload/CFileUpload.vue';
20
+ import type { CNavigationButtonTexts } from './components/c-navigation-button/CNavigationButton.vue';
21
+ import type { CNumberFieldTexts } from './components/c-number-field/CNumberField.vue';
22
+ import type { CPaginationOptions, CPaginationTexts } from './components/c-pagination/CPagination.vue';
23
+ import type { CSelectTexts, CSelectValue } from './components/c-select/CSelect.vue';
24
+ import type { CTimePickerText, CTimePickerTexts, CTimePickerValue } from './components/c-time-picker/CTimePicker.vue';
25
+ import type { CTreeSelectFilter, CTreeSelectItem, CTreeSelectTexts, CTreeSelectValue } from './components/c-tree-select/CTreeSelect.vue';
14
26
  import type { CSelectItem, CToastMessage } from './types';
15
- type AccordionPrimitive = number | string;
16
- type AccordionValue = AccordionPrimitive | AccordionPrimitive[] | null;
17
- type DropdownItem = {
18
- disabled?: boolean;
19
- name: string;
20
- outerHTML?: string;
21
- selected?: boolean;
22
- value: number | string;
23
- };
24
27
  /** Events dispatched by `<c-accordion>`. */
25
28
  export interface CAccordionElementEventMap {
26
29
  /**
27
- * Fired when the expansion state changes, carrying the new value as a bare
28
- * `detail`: the expanded item's value, an array of values in `multiple`
29
- * mode, or `null` when everything is collapsed.
30
- */
31
- change: CustomEvent<AccordionValue>;
32
- /**
33
- * Legacy value-change event carrying the new expansion value (kept for
34
- * existing `@changeValue` listeners and the `v-control` directive).
30
+ * Fired when the user toggles an item, carrying the new value: the expanded
31
+ * item's value, an array of values in `multiple` mode, or `null` when
32
+ * everything is collapsed.
35
33
  */
36
- changeValue: CustomEvent<AccordionValue>;
34
+ change: CustomEvent<CAccordionValue>;
37
35
  /**
38
- * Native bubbling input event dispatched alongside `changeValue` so a plain
39
- * `v-model` works without `v-control`; carries no detail.
36
+ * Native bubbling input event dispatched alongside every value change so a
37
+ * plain `v-model` stays in sync. Carries no detail.
40
38
  */
41
39
  input: CustomEvent<void>;
42
- /**
43
- * Fired with the new expansion value whenever an item is toggled — the
44
- * `v-model` contract.
45
- */
46
- 'update:value': CustomEvent<AccordionValue>;
40
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
41
+ 'update:value': CustomEvent<CAccordionValue>;
47
42
  }
43
+ /** A stack of collapsible sections, each a `c-accordion-item` whose header button shows or hides the content beneath it. */
48
44
  export interface CAccordionElement extends Omit<HTMLElement, 'mandatory' | 'multiple' | 'outlined' | 'value'> {
49
- /** Disallow collapsing all the items */
45
+ /**
46
+ * Keeps the last expanded item from collapsing: its header stops
47
+ * responding until another item expands. It never expands an item
48
+ * itself, so pair it with an initial `value`.
49
+ */
50
50
  mandatory?: boolean;
51
- /** Allow expanding multiple items */
51
+ /**
52
+ * Lets items expand and collapse independently; `value` is then an array
53
+ * of the expanded items' values.
54
+ */
52
55
  multiple?: boolean;
53
- /** Show an outline around expanded items */
56
+ /** Adds a primary ring inside the outline of expanded items. */
54
57
  outlined?: boolean;
55
- /** Value of the accordion */
56
- value?: AccordionValue;
58
+ /**
59
+ * The expanded item's `value`, an array of them with `multiple`, or `null`
60
+ * when every item is collapsed.
61
+ */
62
+ value?: CAccordionValue;
57
63
  addEventListener<K extends keyof CAccordionElementEventMap>(type: K, listener: (this: CAccordionElement, ev: CAccordionElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
58
64
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
59
65
  removeEventListener<K extends keyof CAccordionElementEventMap>(type: K, listener: (this: CAccordionElement, ev: CAccordionElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
60
66
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
61
67
  }
62
- /** Events dispatched by `<c-accordion-item>`. */
63
- export interface CAccordionItemElementEventMap {
64
- /**
65
- * Fired when the header is toggled, carrying the requested expansion state
66
- * and the item's `value`; bubbles so the parent `<c-accordion>` can update
67
- * its model.
68
- */
69
- 'item-change': CustomEvent<{
70
- expanded: boolean;
71
- value: number | string | undefined;
72
- }>;
73
- }
68
+ /** One collapsible section of a `c-accordion`: a header button showing its `heading` (or the `heading` slot) and an optional icon, above the content in the default slot. Place it directly inside the accordion and give it a `value`: the accordion expands items by value and leaves an item without one collapsed. */
74
69
  export interface CAccordionItemElement extends Omit<HTMLElement, 'collapsable' | 'expanded' | 'heading' | 'outlined' | 'value'> {
75
- /** Marks the item as collapsable */
76
- collapsable?: boolean;
77
- /** Expansion status of the item */
78
- expanded?: boolean;
79
- /** Heading of the accordion item */
70
+ /** The header's text. The `heading` slot replaces it for rich content. */
80
71
  heading?: string;
81
- /** Show an outline around the expanded item */
82
- outlined?: boolean;
83
- /** Value of the accordion item */
72
+ /**
73
+ * Identifies the item in the parent `<c-accordion>`'s `value`. Required:
74
+ * the accordion leaves an item without one collapsed.
75
+ */
84
76
  value?: number | string;
85
- addEventListener<K extends keyof CAccordionItemElementEventMap>(type: K, listener: (this: CAccordionItemElement, ev: CAccordionItemElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
86
- addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
87
- removeEventListener<K extends keyof CAccordionItemElementEventMap>(type: K, listener: (this: CAccordionItemElement, ev: CAccordionItemElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
88
- removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
89
77
  }
90
78
  /** Events dispatched by `<c-alert>`. */
91
79
  export interface CAlertElementEventMap {
92
80
  /**
93
- * Fired when the dismiss button is pressed. The alert does not hide
81
+ * Fired when the close button is pressed. The alert does not hide
94
82
  * itself — the consumer owns removal.
95
83
  */
96
- dismiss: CustomEvent<void>;
84
+ close: CustomEvent<void>;
97
85
  }
98
86
  /** A persistent, in-flow status message: a tinted box whose type carries a status family's colours through the icon, heading and accent edge, while the body copy stays neutral. */
99
- export interface CAlertElement extends Omit<HTMLElement, 'dismissible' | 'heading' | 'type'> {
87
+ export interface CAlertElement extends Omit<HTMLElement, 'closeable' | 'heading' | 'type'> {
100
88
  /**
101
- * Show a dismiss button. The alert only emits `dismiss` — removing it from
102
- * the page stays the consumer's job.
89
+ * Show a close button. The alert only fires `close` — removing it from the
90
+ * page stays the consumer's job.
103
91
  */
104
- dismissible?: boolean;
92
+ closeable?: boolean;
105
93
  /**
106
94
  * Heading rendered above the message. The `heading` slot overrides it for
107
95
  * rich content.
108
96
  */
109
97
  heading?: string;
110
- /** Type of the alert */
111
- type?: 'default' | 'error' | 'info' | 'success' | 'warning';
98
+ /**
99
+ * The status type, setting the colours, the icon and how urgently the
100
+ * alert is announced (`warning` and `error` interrupt). Without it the
101
+ * alert has the neutral, brand-primary look and no icon.
102
+ */
103
+ type?: 'error' | 'info' | 'success' | 'warning';
112
104
  addEventListener<K extends keyof CAlertElementEventMap>(type: K, listener: (this: CAlertElement, ev: CAlertElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
113
105
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
114
106
  removeEventListener<K extends keyof CAlertElementEventMap>(type: K, listener: (this: CAlertElement, ev: CAlertElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
@@ -117,11 +109,13 @@ export interface CAlertElement extends Omit<HTMLElement, 'dismissible' | 'headin
117
109
  /** Events dispatched by `<c-autocomplete>`. */
118
110
  export interface CAutocompleteElementEventMap {
119
111
  /**
120
- * Native change event (no detail) dispatched whenever a selection is
121
- * committed or cleared; bubbles through the shadow boundary for
122
- * form-style listeners.
112
+ * Fired when the selected value changes (an option is committed or the
113
+ * selection is cleared), carrying the new value — the option's value, or
114
+ * the whole `{ name, value }` item when `return-object` is set; `null`
115
+ * when cleared. In `multiple` mode the whole array of picked values, in
116
+ * pick order (`[]` when cleared).
123
117
  */
124
- change: CustomEvent<void>;
118
+ change: CustomEvent<CAutocompleteValue>;
125
119
  /**
126
120
  * Fired whenever the query changes — on every keystroke in the search
127
121
  * input, and with an empty string when the panel opens. Carries the query
@@ -129,26 +123,16 @@ export interface CAutocompleteElementEventMap {
129
123
  * your side) and feed the results back via `items`.
130
124
  */
131
125
  'change:query': CustomEvent<string>;
132
- /**
133
- * Fired when the selected value changes (an option is committed or the
134
- * selection is cleared), carrying the new value — the option's value, or
135
- * the whole `{ name, value }` item when `return-object` is set; `null`
136
- * when cleared.
137
- */
138
- changeValue: CustomEvent<CAutocompleteItem | null | number | string>;
139
126
  /**
140
127
  * Native bubbling input event dispatched alongside every value change so a
141
128
  * plain `v-model` stays in sync. Carries no detail.
142
129
  */
143
130
  input: CustomEvent<void>;
144
- /**
145
- * Fired alongside `changeValue` with the same detail — the `v-model`
146
- * contract.
147
- */
148
- 'update:value': CustomEvent<CAutocompleteItem | null | number | string>;
131
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
132
+ 'update:value': CustomEvent<CAutocompleteValue>;
149
133
  }
150
134
  /** A filterable value-selection component: a readonly value field that opens a popover panel with a search input above the matching options. */
151
- export interface CAutocompleteElement extends Omit<HTMLElement, 'clearable' | 'disabled' | 'errorMessage' | 'external' | 'filter' | 'hideDetails' | 'hint' | 'hostId' | 'items' | 'itemsPerPage' | 'label' | 'labelOnTop' | 'loading' | 'name' | 'noResultsText' | 'placeholder' | 'required' | 'returnObject' | 'shadow' | 'size' | 'valid' | 'value'> {
135
+ export interface CAutocompleteElement extends Omit<HTMLElement, 'clearable' | 'disabled' | 'errorMessage' | 'external' | 'filter' | 'hideDetails' | 'hint' | 'invalid' | 'items' | 'itemsPerPage' | 'label' | 'labelOnTop' | 'loading' | 'maxTags' | 'multiple' | 'name' | 'placeholder' | 'required' | 'returnObject' | 'selectAll' | 'shadow' | 'size' | 'texts' | 'value'> {
152
136
  /** Make the selected value clearable */
153
137
  clearable?: boolean;
154
138
  /** Disable the input */
@@ -167,8 +151,11 @@ export interface CAutocompleteElement extends Omit<HTMLElement, 'clearable' | 'd
167
151
  hideDetails?: boolean;
168
152
  /** Hint text for the input */
169
153
  hint?: string;
170
- /** Id of the element */
171
- hostId?: string;
154
+ /**
155
+ * Show the control as invalid: its `error-message`, when set, replaces the
156
+ * hint, and the control is marked `aria-invalid`.
157
+ */
158
+ invalid?: boolean;
172
159
  /** Dropdown items (when not using <c-option> elements) */
173
160
  items?: CAutocompleteItem[];
174
161
  /** Items per page before the list scrolls */
@@ -179,35 +166,84 @@ export interface CAutocompleteElement extends Omit<HTMLElement, 'clearable' | 'd
179
166
  labelOnTop?: boolean;
180
167
  /** Show loading state */
181
168
  loading?: boolean;
169
+ /**
170
+ * In `multiple` mode, show at most this many selected-value tags and fold
171
+ * the rest into one "+N more" tag; `0` shows no tags and reads "N selected"
172
+ * instead; unset shows every tag
173
+ */
174
+ maxTags?: number;
175
+ /**
176
+ * Allow selecting several options: rows toggle, the panel stays open and
177
+ * keeps its query, `value` becomes an array of the selected values (items
178
+ * with `return-object`) in the order they were picked, and the picks show
179
+ * as tags inside the field. Arrays have no attribute form — bind `value` as
180
+ * a DOM property
181
+ */
182
+ multiple?: boolean;
182
183
  /** Input field name */
183
184
  name?: string;
184
- /** Message shown when the query matches no options */
185
- noResultsText?: string;
186
185
  /** Placeholder for the in-panel search input */
187
186
  placeholder?: string;
188
187
  /** Set the autocomplete as required */
189
188
  required?: boolean;
190
189
  /** Return object instead of value */
191
190
  returnObject?: boolean;
191
+ /**
192
+ * In `multiple` mode, pin a select-all row at the top of the list. Its
193
+ * checkbox shows whether none, some or all enabled options currently listed
194
+ * — the matches while a query is typed, the given `items` with `external` —
195
+ * are selected; activating it selects them all, or, when all are selected,
196
+ * unselects them. Ignored in single mode
197
+ */
198
+ selectAll?: boolean;
192
199
  /** Shadow variant */
193
200
  shadow?: boolean;
194
- /** Field height: the 44px default or the 36px `small` box */
201
+ /** Field height: the 52px default (the shared control height) or the 36px `small` box */
195
202
  size?: 'default' | 'small';
196
- /** Set the validity of the input */
197
- valid?: boolean;
198
- /** Selected value (scalar, or object when return-object is set) */
199
- value?: CAutocompleteItem | null | number | string;
200
- /** Reset autocomplete state */
201
- reset(): void;
203
+ /**
204
+ * UI text overrides (i18n), merged over the English defaults. Objects have
205
+ * no attribute form — bind as a DOM property (`:texts.prop` in Vue)
206
+ */
207
+ texts?: CAutocompleteTexts;
208
+ /**
209
+ * Selected value: the option's value, or the whole item with
210
+ * `return-object`; an array of them in `multiple` mode
211
+ */
212
+ value?: CAutocompleteValue;
213
+ /**
214
+ * Focus its combobox, as `focus()` does on a native control: the element renders
215
+ * no box of its own to take it.
216
+ */
217
+ focus(options?: FocusOptions): void;
202
218
  addEventListener<K extends keyof CAutocompleteElementEventMap>(type: K, listener: (this: CAutocompleteElement, ev: CAutocompleteElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
203
219
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
204
220
  removeEventListener<K extends keyof CAutocompleteElementEventMap>(type: K, listener: (this: CAutocompleteElement, ev: CAutocompleteElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
205
221
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
206
222
  }
223
+ /** A small pill that pins a short count or label to the top-right corner of the element it sits in, such as the number of unread messages on a button. */
207
224
  export interface CBadgeElement extends HTMLElement {
208
225
  }
226
+ /** A navigation aid naming where the current page sits in a site's hierarchy: one line of crumbs from the top of the hierarchy down to the current page, the middle ones folding behind a "…" button when the line runs out of room. */
227
+ export interface CBreadcrumbElement extends Omit<HTMLElement, 'texts'> {
228
+ /**
229
+ * UI text overrides (i18n), merged over the English defaults. Objects have
230
+ * no attribute form — set it as a property
231
+ */
232
+ texts?: CBreadcrumbTexts;
233
+ }
234
+ /** One crumb in a `c-breadcrumb`: a link to a level of the hierarchy, or, as the last crumb, the current page. */
235
+ export interface CBreadcrumbItemElement extends Omit<HTMLElement, 'href' | 'target'> {
236
+ /**
237
+ * URL of the page the crumb leads to. Ignored on the current crumb (the
238
+ * last one); a crumb without it names a level that has no page and renders
239
+ * as plain text
240
+ */
241
+ href?: string;
242
+ /** Browsing context the link opens in; the same tab when unset */
243
+ target?: string;
244
+ }
209
245
  /** Buttons trigger actions — submitting a form, opening a modal, confirming a choice. Use one primary (default appearance) button per view; secondary actions use the `outlined`, `ghost` or `text` appearances. */
210
- export interface CButtonElement extends Omit<HTMLElement, 'active' | 'danger' | 'disabled' | 'fit' | 'ghost' | 'hostId' | 'href' | 'inverted' | 'loading' | 'noRadius' | 'noRipple' | 'outlined' | 'size' | 'target' | 'text' | 'type' | 'value'> {
246
+ export interface CButtonElement extends Omit<HTMLElement, 'active' | 'asTab' | 'danger' | 'disabled' | 'fit' | 'ghost' | 'href' | 'inverted' | 'loading' | 'noRadius' | 'noRipple' | 'outlined' | 'size' | 'target' | 'text' | 'type' | 'value'> {
211
247
  /**
212
248
  * Pressed (toggle) state — renders the selected look and sets
213
249
  * `aria-pressed`. Leave unset for regular action buttons: only a
@@ -215,39 +251,63 @@ export interface CButtonElement extends Omit<HTMLElement, 'active' | 'danger' |
215
251
  * `c-button-group` on its slotted buttons.
216
252
  */
217
253
  active?: boolean;
218
- /** Danger variant style */
254
+ /**
255
+ * Danger appearance for a destructive action: the filled button in the error
256
+ * colour; no effect on `outlined`, `ghost` or `text`.
257
+ */
219
258
  danger?: boolean;
220
- /** Disable the button */
259
+ /**
260
+ * Grey the button out and block clicks and keys, a link button (`href`)
261
+ * included.
262
+ */
221
263
  disabled?: boolean;
222
- /** Fit width to containing element */
264
+ /** Stretch the button to the full width of its container. */
223
265
  fit?: boolean;
224
- /** Light button background */
266
+ /** Ghost appearance: primary text on a light primary tint, for lower emphasis. */
225
267
  ghost?: boolean;
226
- /** Id of the button */
227
- hostId?: string;
228
- /** Hyperlink url */
268
+ /**
269
+ * URL to link to: the button renders as a real link (`<a>`) styled as a
270
+ * button.
271
+ */
229
272
  href?: string;
230
- /** Inverted button style for dark backgrounds */
273
+ /**
274
+ * Inverted colours for a fixed dark or brand-coloured backdrop: the
275
+ * `inverse-*` family, the same in both theme modes. Combines with the other
276
+ * appearances.
277
+ */
231
278
  inverted?: boolean;
232
- /** Display loader on the button */
279
+ /**
280
+ * Show a spinner in place of the label and ignore clicks and keys, e.g. while
281
+ * the action runs.
282
+ */
233
283
  loading?: boolean;
234
- /** Remove the default border radius */
284
+ /** Square corners instead of the rounded default. */
235
285
  noRadius?: boolean;
236
- /** Suppress the click ripple (e.g. when a wrapper owns the press feedback). */
237
- noRipple?: boolean;
238
- /** Outlined button style */
286
+ /**
287
+ * Outlined appearance: a primary outline and text with no fill, for lower
288
+ * emphasis.
289
+ */
239
290
  outlined?: boolean;
240
- /** Size of the button */
291
+ /**
292
+ * Size of the button: `small`, `default` (the control height, level with a
293
+ * form field) or `large` (the toolbar height).
294
+ */
241
295
  size?: 'default' | 'large' | 'small';
242
- /** Hyperlink target */
296
+ /**
297
+ * Where the `href` opens, as on a native `<a>`: the same tab unless set —
298
+ * `_blank` for a new one.
299
+ */
243
300
  target?: string;
244
- /** Transparent button background */
301
+ /** Text appearance: primary text with no fill or outline, the lightest look. */
245
302
  text?: boolean;
246
- /** Button type */
303
+ /**
304
+ * Native `type` of the button: `button` unless set, `submit` or `reset`.
305
+ * Ignored when `href` is set.
306
+ */
247
307
  type?: 'button' | 'reset' | 'submit';
248
308
  /**
249
- * Value for the button
250
- * - for use in the c-button-group
309
+ * The button's value in a `c-button-group`; in `c-tab-buttons`, the `value`
310
+ * of the `c-tab-item` panel it shows.
251
311
  */
252
312
  value?: number | string;
253
313
  }
@@ -296,56 +356,83 @@ export interface CButtonGroupElement extends Omit<HTMLElement, 'disabled' | 'lab
296
356
  * an array of the active buttons' values.
297
357
  */
298
358
  value?: CButtonGroupValue;
359
+ /**
360
+ * Focus its tab stop: the selected button, else the first enabled one, as `focus()` does on a native control: the element renders
361
+ * no box of its own to take it.
362
+ */
363
+ focus(options?: FocusOptions): void;
299
364
  addEventListener<K extends keyof CButtonGroupElementEventMap>(type: K, listener: (this: CButtonGroupElement, ev: CButtonGroupElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
300
365
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
301
366
  removeEventListener<K extends keyof CButtonGroupElementEventMap>(type: K, listener: (this: CButtonGroupElement, ev: CButtonGroupElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
302
367
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
303
368
  }
369
+ /** A raised, bordered surface that groups one piece of content — its heading, body and actions — into a single box on the page. */
304
370
  export interface CCardElement extends Omit<HTMLElement, 'fullscreen'> {
305
- /** Enable the fullscreen toggle button */
371
+ /**
372
+ * Shows a toggle button in the card's top-right corner that puts the card
373
+ * in the browser's fullscreen mode and back.
374
+ */
306
375
  fullscreen?: boolean;
307
- /** Enter fullscreen from the outside */
376
+ /**
377
+ * Shows the card in the browser's fullscreen mode; does nothing while any
378
+ * element is already fullscreen. Browsers grant it only in response to a
379
+ * user action, so call it from a click handler.
380
+ */
308
381
  enterFullscreen(): void;
309
- /** Exit fullscreen from the outside */
382
+ /**
383
+ * Returns the card from fullscreen to the page. Ends only the card's own
384
+ * fullscreen, never another element's.
385
+ */
310
386
  exitFullscreen(): void;
311
387
  }
388
+ /** The row of actions at the bottom of a `c-card`, typically `c-button`s, which wraps onto further rows instead of overflowing the card. `justify` distributes the actions along the row (`start` by default, `stretch` to grow them all) and `align` places them across it. */
312
389
  export interface CCardActionsElement extends Omit<HTMLElement, 'align' | 'justify'> {
313
- /** Align the actions */
390
+ /**
391
+ * Aligns the actions across the row: to its top (`start`), centre or
392
+ * bottom (`end`).
393
+ */
314
394
  align?: 'center' | 'end' | 'start';
315
- /** Justify the actions */
395
+ /**
396
+ * Distributes the actions along the row; `stretch` grows every action to
397
+ * share it.
398
+ */
316
399
  justify?: 'center' | 'end' | 'space-around' | 'space-between' | 'start' | 'stretch';
317
400
  }
401
+ /** The body section of a `c-card`: it pads its content in from the card's edges and stacks the children in a column with the card's section spacing. Place it after `c-card-title` and before `c-card-actions`. */
318
402
  export interface CCardContentElement extends HTMLElement {
319
403
  }
320
- export interface CCardTitleElement extends HTMLElement {
404
+ /** The heading section of a `c-card`, set in small uppercase type above a primary accent bar; place it first in the card. Controls in its `actions` slot sit at the right of the heading and move onto their own line under it when the two do not fit side by side. */
405
+ export interface CCardTitleElement extends Omit<HTMLElement, 'headingLevel'> {
406
+ /**
407
+ * The title's heading level, 1 to 6: pick the one that fits the card's
408
+ * place in the page's outline (2 under the page's `h1`, 3 inside a section
409
+ * with an `h2`).
410
+ */
411
+ headingLevel?: 1 | 2 | 3 | 4 | 5 | 6;
321
412
  }
322
413
  /** Events dispatched by `<c-checkbox>`. */
323
414
  export interface CCheckboxElementEventMap {
324
415
  /**
325
- * Standard bubbling DOM change event, re-dispatched from the host when the
326
- * checkbox is toggled (the inner input's change does not cross the shadow
327
- * boundary). No detail; read the new value from the host's `value` property.
328
- */
329
- change: CustomEvent<void>;
330
- /**
331
- * Fired when the checkbox is toggled, carrying the new value —
416
+ * Fired when the user toggles the checkbox, carrying the new value —
332
417
  * `trueValue` when checked, `falseValue` when unchecked.
333
418
  */
334
- changeValue: CustomEvent<boolean | number | string>;
419
+ change: CustomEvent<boolean | number | string>;
335
420
  /**
336
421
  * Native bubbling input event fired on toggle so a plain Vue `v-model`
337
- * works without the `v-control` directive. No detail.
422
+ * stays in sync. No detail.
338
423
  */
339
424
  input: CustomEvent<void>;
340
- /**
341
- * v-model contract event fired on toggle, carrying the new value —
342
- * `trueValue` when checked, `falseValue` when unchecked.
343
- */
425
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
344
426
  'update:value': CustomEvent<boolean | number | string>;
345
427
  }
346
428
  /** A form control for a single on/off choice: a native checkbox with a label, an optional hint, and validation messaging. */
347
- export interface CCheckboxElement extends Omit<HTMLElement, 'checked' | 'disabled' | 'errorMessage' | 'falseValue' | 'hideDetails' | 'hint' | 'hostId' | 'hostName' | 'indeterminate' | 'label' | 'required' | 'trueValue' | 'valid' | 'value'> {
348
- /** If `true`, the checkbox is selected. */
429
+ export interface CCheckboxElement extends Omit<HTMLElement, 'checked' | 'disabled' | 'errorMessage' | 'falseValue' | 'hideDetails' | 'hint' | 'indeterminate' | 'invalid' | 'label' | 'name' | 'required' | 'trueValue' | 'value'> {
430
+ /**
431
+ * Whether the checkbox is on: the boolean view of `value`. Setting it sets
432
+ * `value` to `trueValue` or `falseValue`; reading it reports whether
433
+ * `value` equals `trueValue`. As an attribute it sets the initial state when
434
+ * no `value` is bound.
435
+ */
349
436
  checked?: boolean;
350
437
  /** Disable the checkbox */
351
438
  disabled?: boolean;
@@ -355,44 +442,164 @@ export interface CCheckboxElement extends Omit<HTMLElement, 'checked' | 'disable
355
442
  falseValue?: boolean | number | string;
356
443
  /** Hide the hint and error messages */
357
444
  hideDetails?: boolean;
358
- /** Hint text for the input */
445
+ /** Hint text for the checkbox */
359
446
  hint?: string;
360
- /** Id of the element */
361
- hostId?: string;
362
447
  /**
363
- * Name of the input
364
- * - Only used when the checkbox participates in a native `<form>`
448
+ * Show the mixed state, a bar in place of the check, for a parent checkbox
449
+ * whose options are partly checked. It wins over `checked`; a click or Space
450
+ * clears it and toggles the state, as on a native checkbox
365
451
  */
366
- hostName?: string;
367
- /** Indeterminate state */
368
452
  indeterminate?: boolean;
369
- /** Element label */
453
+ /**
454
+ * Show the control as invalid: its `error-message`, when set, replaces the
455
+ * hint, and the control is marked `aria-invalid`.
456
+ */
457
+ invalid?: boolean;
458
+ /**
459
+ * Label of the checkbox, shown beside the box. Falls back to the default
460
+ * slot content when not set.
461
+ */
370
462
  label?: string;
371
- /** Set as required */
463
+ /**
464
+ * `name` of the inner checkbox input. The component is not
465
+ * form-associated, so it does not submit with a `<form>`.
466
+ */
467
+ name?: string;
468
+ /** Set as required — shows the required marker on the label */
372
469
  required?: boolean;
373
470
  /** The value when the checkbox is checked */
374
471
  trueValue?: boolean | number | string;
375
- /** Set the validity of the input */
376
- valid?: boolean;
377
472
  /**
378
- * The input value
379
- * - Only used when the checkbox participates in a native `<form>`
473
+ * The checkbox's state: `trueValue` while it is on, `falseValue` while it is
474
+ * off. A bound value wins over a `checked` attribute; any other value,
475
+ * `''` included, reads as off.
476
+ */
477
+ value?: string | number | boolean;
478
+ /**
479
+ * Focus its checkbox, as `focus()` does on a native control: the element renders
480
+ * no box of its own to take it.
380
481
  */
381
- value?: boolean | number | string;
482
+ focus(options?: FocusOptions): void;
382
483
  addEventListener<K extends keyof CCheckboxElementEventMap>(type: K, listener: (this: CCheckboxElement, ev: CCheckboxElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
383
484
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
384
485
  removeEventListener<K extends keyof CCheckboxElementEventMap>(type: K, listener: (this: CCheckboxElement, ev: CCheckboxElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
385
486
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
386
487
  }
488
+ /** Events dispatched by `<c-color-picker>`. */
489
+ export interface CColorPickerElementEventMap {
490
+ /**
491
+ * Fired when the value changes — a pick in the panel, typed text
492
+ * committed, the field cleared — carrying the colour in the `format`
493
+ * notation, or `null`. A drag on the area or a slider fires it once, on
494
+ * release.
495
+ */
496
+ change: CustomEvent<CColorPickerValue>;
497
+ /**
498
+ * Fired on every commit of typed text (Enter or leaving the input) with the
499
+ * text as typed. Read `badInput` to tell whether it named a colour.
500
+ */
501
+ 'change:text': CustomEvent<string>;
502
+ /**
503
+ * Native bubbling input event dispatched alongside every value change —
504
+ * each move of a drag included — so a plain `v-model` stays in sync.
505
+ * Carries no detail.
506
+ */
507
+ input: CustomEvent<void>;
508
+ /**
509
+ * Fired with every value change, each move of a drag included — the
510
+ * `v-model` contract.
511
+ */
512
+ 'update:value': CustomEvent<CColorPickerValue>;
513
+ }
514
+ /** A colour field that takes any typed CSS colour, or opens a panel for picking one: a colour area, hue and alpha sliders, per-channel inputs and swatches — or swatches alone under `swatches-only`. */
515
+ export interface CColorPickerElement extends Omit<HTMLElement, 'alpha' | 'clearable' | 'disabled' | 'errorMessage' | 'format' | 'hideDetails' | 'hint' | 'invalid' | 'label' | 'labelOnTop' | 'name' | 'placeholder' | 'required' | 'shadow' | 'size' | 'swatches' | 'swatchesOnly' | 'texts' | 'value'> {
516
+ /**
517
+ * Let the colour carry transparency: an alpha slider and an A channel join
518
+ * the panel. Without it typed alpha is dropped
519
+ */
520
+ alpha?: boolean;
521
+ /** Make the value clearable */
522
+ clearable?: boolean;
523
+ /** Disable the field */
524
+ disabled?: boolean;
525
+ /** Error message shown in place of the hint while the field is invalid */
526
+ errorMessage?: string;
527
+ /**
528
+ * The notation the value is written in — and every emission with it:
529
+ * `#rrggbb`, `rgb(r g b)` or `oklch(l c h)`
530
+ */
531
+ format?: 'hex' | 'oklch' | 'rgb';
532
+ /** Hide the hint and error messages */
533
+ hideDetails?: boolean;
534
+ /** Hint text for the field */
535
+ hint?: string;
536
+ /**
537
+ * Show the control as invalid: its `error-message`, when set, replaces the
538
+ * hint, and the control is marked `aria-invalid`.
539
+ */
540
+ invalid?: boolean;
541
+ /** Element label */
542
+ label?: string;
543
+ /** Label on top of the field */
544
+ labelOnTop?: boolean;
545
+ /** Input field name */
546
+ name?: string;
547
+ /** Placeholder of the input; an example of the notation when empty */
548
+ placeholder?: string;
549
+ /** Set the field as required */
550
+ required?: boolean;
551
+ /** Shadow variant */
552
+ shadow?: boolean;
553
+ /** Field height: the 52px default (the shared control height) or the 36px `small` box */
554
+ size?: 'default' | 'small';
555
+ /**
556
+ * Predefined colours offered under the picker — CSS colours, or
557
+ * `{ value, name }` objects whose name is read out and shown. Arrays have
558
+ * no attribute form — bind as a DOM property
559
+ */
560
+ swatches?: CColorPickerSwatch[];
561
+ /**
562
+ * Limit the choice to the swatches: the field becomes readonly and opens
563
+ * a panel of the swatches alone
564
+ */
565
+ swatchesOnly?: boolean;
566
+ /**
567
+ * UI text overrides (i18n), merged over the English defaults. Objects have
568
+ * no attribute form — bind as a DOM property
569
+ */
570
+ texts?: CColorPickerTexts;
571
+ /**
572
+ * The colour in the `format` notation, or `null` when empty. Any CSS
573
+ * colour is accepted and shown in the notation
574
+ */
575
+ value?: CColorPickerValue;
576
+ /** Whether the committed text names no colour — the value is then `null` (CONTEXT.md "Bad input"). */
577
+ readonly badInput: boolean;
578
+ /**
579
+ * Focus its input (the readonly combobox under `swatches-only`), as `focus()` does on a native control: the element renders
580
+ * no box of its own to take it.
581
+ */
582
+ focus(options?: FocusOptions): void;
583
+ addEventListener<K extends keyof CColorPickerElementEventMap>(type: K, listener: (this: CColorPickerElement, ev: CColorPickerElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
584
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
585
+ removeEventListener<K extends keyof CColorPickerElementEventMap>(type: K, listener: (this: CColorPickerElement, ev: CColorPickerElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
586
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
587
+ }
588
+ /** The CSC logo without its tagline, drawn as an inline SVG in the colours of the current theme mode. */
387
589
  export interface CCscLogoElement extends Omit<HTMLElement, 'width'> {
388
- /** Logo width in pixels */
590
+ /** Logo width in pixels; the height follows the logo's proportions. */
389
591
  width?: number;
390
592
  }
391
593
  /** Events dispatched by `<c-data-table>`. */
392
594
  export interface CDataTableElementEventMap {
393
595
  /** Fired when the expanded rows change, carrying the expanded row ids. */
394
596
  'change:expanded': CustomEvent<string[]>;
395
- /** Fired when the user changes the page, carrying the new 1-based page. */
597
+ /**
598
+ * Fired when the page changes, carrying the new 1-based page: the user
599
+ * picks a page or a page size, or the table moves back to page 1 when
600
+ * `query` changes, or to the last page when the rows shrink beneath the
601
+ * current one.
602
+ */
396
603
  'change:page': CustomEvent<number>;
397
604
  /**
398
605
  * Fired when the user picks a new page size. Also resets the page to 1
@@ -400,17 +607,15 @@ export interface CDataTableElementEventMap {
400
607
  */
401
608
  'change:page-size': CustomEvent<number>;
402
609
  /**
403
- * Fired when the selection changes, carrying the selected row ids and the
404
- * row objects resolvable from the current `data`.
610
+ * Fired when the user changes the selection, carrying the selected row ids
611
+ * — the new `selected`. The rows themselves are `selectedRows`.
405
612
  */
406
- 'change:selected': CustomEvent<{
407
- ids: string[];
408
- rows: CDataTableRow[];
409
- }>;
613
+ 'change:selected': CustomEvent<string[]>;
410
614
  /** Fired when the user sorts a column, carrying the new sorting state. */
411
- 'change:sort': CustomEvent<CDataTableSort | null>;
615
+ 'change:sort': CustomEvent<CDataTableSort>;
412
616
  }
413
- export interface CDataTableElement extends Omit<HTMLElement, 'autohide' | 'columns' | 'data' | 'expanded' | 'expandedContent' | 'external' | 'filter' | 'getRowId' | 'itemCount' | 'loading' | 'page' | 'pageSize' | 'pageSizes' | 'selected' | 'selection' | 'singleExpansion' | 'sort' | 'stickyFooter' | 'stickyHeader' | 'texts'> {
617
+ /** A data-driven table that renders the rows of a `data` array through a set of `columns` definitions, with built-in sorting, pagination, row selection and expandable rows. Rows are your own plain objects; each column reads one of their properties and may render its header, cells and footer through render functions. */
618
+ export interface CDataTableElement extends Omit<HTMLElement, 'autohide' | 'columns' | 'data' | 'expanded' | 'expandedContent' | 'external' | 'getRowId' | 'itemCount' | 'loading' | 'page' | 'pageSize' | 'pageSizes' | 'query' | 'selected' | 'selection' | 'singleExpansion' | 'sort' | 'stickyFooter' | 'stickyHeader' | 'texts'> {
414
619
  /**
415
620
  * Move overflowing `expansion: 'auto'` columns into the expansion row
416
621
  * (rightmost first) instead of scrolling horizontally.
@@ -430,14 +635,9 @@ export interface CDataTableElement extends Omit<HTMLElement, 'autohide' | 'colum
430
635
  /**
431
636
  * The server owns sorting, pagination and filtering: the table renders
432
637
  * `data` verbatim and only emits the state-change events. Requires
433
- * `itemCount` for the pager; disables the select-all banner and `filter`.
638
+ * `itemCount` for the pager; disables the select-all banner and `query`.
434
639
  */
435
640
  external?: boolean;
436
- /**
437
- * Filter rows client-side against this string (all columns). Ignored when
438
- * `external` is set.
439
- */
440
- filter?: string;
441
641
  /**
442
642
  * Return a stable id for a row. Falls back to the row's index — supply
443
643
  * this whenever selection/expansion is used with `external` data.
@@ -456,6 +656,11 @@ export interface CDataTableElement extends Omit<HTMLElement, 'autohide' | 'colum
456
656
  pageSize?: number;
457
657
  /** Options for the pager's page-size menu. */
458
658
  pageSizes?: number[];
659
+ /**
660
+ * The query rows are filtered by client-side, matched against every column.
661
+ * Ignored when `external` is set.
662
+ */
663
+ query?: string;
459
664
  /** Ids of the selected rows (optionally controlled). */
460
665
  selected?: string[];
461
666
  /** Row selection mode. Unset means rows are not selectable. */
@@ -470,61 +675,227 @@ export interface CDataTableElement extends Omit<HTMLElement, 'autohide' | 'colum
470
675
  stickyHeader?: boolean;
471
676
  /** UI text overrides (i18n), merged over the English defaults. */
472
677
  texts?: CDataTableTexts;
678
+ /**
679
+ * The selected rows that the current `data` holds, in selection order:
680
+ * the row objects behind `selected`.
681
+ */
682
+ readonly selectedRows: CDataTableRow[];
473
683
  addEventListener<K extends keyof CDataTableElementEventMap>(type: K, listener: (this: CDataTableElement, ev: CDataTableElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
474
684
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
475
685
  removeEventListener<K extends keyof CDataTableElementEventMap>(type: K, listener: (this: CDataTableElement, ev: CDataTableElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
476
686
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
477
687
  }
688
+ /** Events dispatched by `<c-date-picker>`. */
689
+ export interface CDatePickerElementEventMap {
690
+ /**
691
+ * Fired when the value changes — a day or range is picked, typed text is
692
+ * committed, or the field is cleared — carrying the new value: an ISO
693
+ * date, `{ start, end }` under `range`, or `null`.
694
+ */
695
+ change: CustomEvent<CDatePickerValue>;
696
+ /**
697
+ * Fired with the displayed month as `YYYY-MM` whenever it changes, and
698
+ * when the panel opens — the signal to load that month's `disabled-dates`.
699
+ */
700
+ 'change:month': CustomEvent<string>;
701
+ /**
702
+ * Fired on every commit of typed text (Enter or leaving the input) with the
703
+ * text as typed — `{ start, end }` under `range`. Read `badInput` to tell
704
+ * whether it named a date that can be picked.
705
+ */
706
+ 'change:text': CustomEvent<CDatePickerText>;
707
+ /**
708
+ * Native bubbling input event dispatched alongside every value change so a
709
+ * plain `v-model` stays in sync. Carries no detail.
710
+ */
711
+ input: CustomEvent<void>;
712
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
713
+ 'update:value': CustomEvent<CDatePickerValue>;
714
+ }
715
+ /** A date field that takes a typed date, or opens a calendar panel for picking one, or a start and end date under `range`. */
716
+ export interface CDatePickerElement extends Omit<HTMLElement, 'clearable' | 'disabled' | 'disabledDates' | 'errorMessage' | 'firstDayOfWeek' | 'format' | 'hideDetails' | 'hint' | 'invalid' | 'isDateDisabled' | 'label' | 'labelOnTop' | 'max' | 'min' | 'name' | 'placeholder' | 'range' | 'required' | 'shadow' | 'showToday' | 'showWeekNumbers' | 'size' | 'texts' | 'type' | 'value'> {
717
+ /** Make the value clearable */
718
+ clearable?: boolean;
719
+ /** Disable the field */
720
+ disabled?: boolean;
721
+ /**
722
+ * Dates that cannot be picked: ISO dates and inclusive `{ start, end }`
723
+ * spans. Arrays have no attribute form — bind as a DOM property
724
+ */
725
+ disabledDates?: CDatePickerDisabledDate[];
726
+ /** Error message shown in place of the hint while the field is invalid */
727
+ errorMessage?: string;
728
+ /**
729
+ * First day of the week in the calendar, numbered like `Date.getDay()`:
730
+ * 0 = Sunday, 1 = Monday … 6 = Saturday
731
+ */
732
+ firstDayOfWeek?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
733
+ /**
734
+ * How dates are shown and read from typing: a pattern of the tokens `d`,
735
+ * `dd`, `M`, `MM` and `yyyy` with any separators, e.g. `yyyy-MM-dd`
736
+ */
737
+ format?: string;
738
+ /** Hide the hint and error messages */
739
+ hideDetails?: boolean;
740
+ /** Hint text for the field */
741
+ hint?: string;
742
+ /**
743
+ * Show the control as invalid: its `error-message`, when set, replaces the
744
+ * hint, and the control is marked `aria-invalid`.
745
+ */
746
+ invalid?: boolean;
747
+ /**
748
+ * Predicate for dates that cannot be picked (weekends, say); receives an
749
+ * ISO date. Functions have no attribute form — bind as a DOM property
750
+ */
751
+ isDateDisabled?: (iso: string) => boolean;
752
+ /** Element label */
753
+ label?: string;
754
+ /** Label on top of the field */
755
+ labelOnTop?: boolean;
756
+ /**
757
+ * The latest date that can be picked or typed, as an ISO date; also bounds
758
+ * the calendar's navigation
759
+ */
760
+ max?: string;
761
+ /**
762
+ * The earliest date that can be picked or typed, as an ISO date; also
763
+ * bounds the calendar's navigation
764
+ */
765
+ min?: string;
766
+ /** Input field name */
767
+ name?: string;
768
+ /** Placeholder of the input; the `format` pattern when empty */
769
+ placeholder?: string;
770
+ /**
771
+ * Pick a range: the value becomes `{ start, end }` and the field holds two
772
+ * inputs
773
+ */
774
+ range?: boolean;
775
+ /** Set the field as required */
776
+ required?: boolean;
777
+ /** Shadow variant */
778
+ shadow?: boolean;
779
+ /**
780
+ * Show a Today button under the calendar that picks today ("This month"
781
+ * under `type="month"`)
782
+ */
783
+ showToday?: boolean;
784
+ /**
785
+ * Show ISO 8601 week numbers beside the calendar rows (meaningful with a
786
+ * Monday week start)
787
+ */
788
+ showWeekNumbers?: boolean;
789
+ /** Field height: the 52px default (the shared control height) or the 36px `small` box */
790
+ size?: 'default' | 'small';
791
+ /**
792
+ * UI text overrides (i18n), merged over the names `Intl` gives for the
793
+ * page's `lang` and the English defaults. Objects have no attribute form —
794
+ * bind as a DOM property
795
+ */
796
+ texts?: CDatePickerTexts;
797
+ /**
798
+ * What the field picks: a calendar date, or a year and a month
799
+ * (`'YYYY-MM'`)
800
+ */
801
+ type?: 'date' | 'month';
802
+ /**
803
+ * The date as an ISO `YYYY-MM-DD` string (an ISO `YYYY-MM` month under
804
+ * `type="month"`), or `{ start, end }` under `range`; `null` when empty
805
+ */
806
+ value?: CDatePickerValue;
807
+ /** Whether the committed text names no date that can be picked — the value is then `null` (CONTEXT.md "Bad input"). */
808
+ readonly badInput: boolean;
809
+ /**
810
+ * Focus its input (the start input under `range`), as `focus()` does on a native control: the element renders
811
+ * no box of its own to take it.
812
+ */
813
+ focus(options?: FocusOptions): void;
814
+ addEventListener<K extends keyof CDatePickerElementEventMap>(type: K, listener: (this: CDatePickerElement, ev: CDatePickerElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
815
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
816
+ removeEventListener<K extends keyof CDatePickerElementEventMap>(type: K, listener: (this: CDatePickerElement, ev: CDatePickerElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
817
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
818
+ }
819
+ /** A separator: a thin line dividing groups of content, horizontal by default or vertical with `vertical`. */
478
820
  export interface CDividerElement extends Omit<HTMLElement, 'vertical'> {
479
821
  /** Render a vertical separator instead of the default horizontal one. */
480
822
  vertical?: boolean;
481
823
  }
482
- /** Events dispatched by `<c-dropdown>`. */
483
- export interface CDropdownElementEventMap {
824
+ /** Events dispatched by `<c-file-upload>`. */
825
+ export interface CFileUploadElementEventMap {
826
+ /** Fired with the new list of file entries. */
827
+ change: CustomEvent<CFileUploadEntry[]>;
484
828
  /**
485
- * Fired when the dropdown menu opens or closes; the detail is the new open
486
- * state.
829
+ * Native bubbling input event fired with every value change so a plain Vue
830
+ * `v-model` works. No detail.
487
831
  */
488
- dropdownStateChange: CustomEvent<boolean>;
832
+ input: CustomEvent<void>;
489
833
  /**
490
- * Fired when the user selects an option row, carrying the option's name
491
- * and value for the parent (c-select) to commit.
834
+ * Fired after an add that refused files, listing each with its reason —
835
+ * a type outside `accept`, a file over `max-size`, a file already held,
836
+ * one beyond `max-files`, or a folder. The refused files never join the
837
+ * value.
492
838
  */
493
- selectOption: CustomEvent<{
494
- name: string;
495
- value: number | string;
496
- }>;
497
- }
498
- export interface CDropdownElement extends Omit<HTMLElement, 'dropdownItemType' | 'hostId' | 'index' | 'items' | 'itemsPerPage' | 'parent' | 'type'> {
499
- /** Whether items are <c-option> elements or plain objects */
500
- dropdownItemType?: 'item' | 'option';
501
- /** Id used to build option/announce element ids */
502
- hostId?: string;
503
- /** Current highlighted index */
504
- index?: null | number;
505
- /** Dropdown options: a NodeList of <c-option> or an array of items */
506
- items?: ArrayLike<DropdownItem>;
507
- /** Items per page before adding scroll */
508
- itemsPerPage?: number;
509
- /** Dropdown parent (the c-select / c-autocomplete host element) */
510
- parent?: HTMLElement | null;
511
- /** Parent type — drives autocomplete-only behaviour (highlight, messages) */
512
- type?: 'autocomplete' | 'select';
513
- /** Close dropdown */
514
- close(): void;
515
- focusItem(index: number): void;
516
- /** Open dropdown */
517
- open(): void;
518
- /** Select item */
519
- selectItem(index: number): void;
520
- setStatusText(text: string): void;
521
- /** Update list items */
522
- updateList(reset?: boolean): void;
523
- addEventListener<K extends keyof CDropdownElementEventMap>(type: K, listener: (this: CDropdownElement, ev: CDropdownElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
839
+ reject: CustomEvent<CFileUploadRejection[]>;
840
+ /** v-model contract event, fired with `change`. */
841
+ 'update:value': CustomEvent<CFileUploadEntry[]>;
842
+ }
843
+ /** A field the user adds files to by dropping them on it or choosing them from a file dialog — and, given an upload function, the place each file's upload shows its progress. */
844
+ export interface CFileUploadElement extends Omit<HTMLElement, 'accept' | 'compact' | 'disabled' | 'errorMessage' | 'hideDetails' | 'hint' | 'invalid' | 'label' | 'manual' | 'maxFiles' | 'maxSize' | 'multiple' | 'required' | 'size' | 'texts' | 'upload' | 'value'> {
845
+ /** The file types the field takes, in the native `accept` syntax: extensions (`.pdf`) and media types (`image/*`, `application/json`), comma separated. It filters the file dialog and is checked again on a drop */
846
+ accept?: string;
847
+ /** Show the drop zone as a control-height row — a "Choose files" button and a drop prompt — that lines up with the fields beside it */
848
+ compact?: boolean;
849
+ /** Disable the field. Uploads already running continue */
850
+ disabled?: boolean;
851
+ /** Error message shown in place of the hint while the field is invalid */
852
+ errorMessage?: string;
853
+ /** Hide the hint and error messages */
854
+ hideDetails?: boolean;
855
+ /** Hint text under the drop zone — the place to name the accepted types and limits */
856
+ hint?: string;
857
+ /**
858
+ * Show the control as invalid: its `error-message`, when set, replaces the
859
+ * hint, and the control is marked `aria-invalid`.
860
+ */
861
+ invalid?: boolean;
862
+ /** Label of the field */
863
+ label?: string;
864
+ /** Hold added files as `local` even with an upload function, until `startUploads()` queues them — for a form that uploads on its own button. Files added after the call wait for the next one */
865
+ manual?: boolean;
866
+ /** The most file entries a `multiple` field holds; files beyond it are rejected */
867
+ maxFiles?: null | number;
868
+ /** The largest file in bytes; a larger one is rejected. Sizes are shown in decimal units, so write the limit in decimal bytes (`10000000` reads "10 MB") */
869
+ maxSize?: null | number;
870
+ /** Let a pick or a drop add several files. Without it the field holds one file and a new pick replaces it; the value is a list either way */
871
+ multiple?: boolean;
872
+ /** Set the field as required */
873
+ required?: boolean;
874
+ /** Height of the `compact` row: the 52px default (the shared control height) or the 36px `small` row. The large drop zone has one size */
875
+ size?: 'default' | 'small';
876
+ /** UI text overrides (i18n), merged over the English defaults. Objects have no attribute form — bind as a DOM property */
877
+ texts?: CFileUploadTexts;
878
+ /** The upload function: called once per added file with an abort signal and a progress callback taking a fraction from 0 to 1; what it resolves to becomes the entry's `result`, an `Error` it rejects with becomes the entry's `error` text. Without one the field only holds the files. A function — bind as a DOM property */
879
+ upload?: CFileUploadFunction;
880
+ /** The file entries — always a list. A picked file's entry carries the browser `File`; a server file's entry is `{ id, name, size, status: 'done' }`. `''` reads as empty — what a plain `v-model` holding `null` writes. An array — bind as a DOM property */
881
+ value?: CFileUploadEntry[] | null | string;
882
+ /**
883
+ * Focus its drop zone's button, as `focus()` does on a native control: the element renders
884
+ * no box of its own to take it.
885
+ */
886
+ focus(options?: FocusOptions): void;
887
+ /**
888
+ * Queue every `local` file entry for the upload function — how a `manual`
889
+ * field starts; files added after the call wait for the next one. Fires the
890
+ * value events once when it starts any. Does nothing without an upload function
891
+ */
892
+ startUploads(): void;
893
+ addEventListener<K extends keyof CFileUploadElementEventMap>(type: K, listener: (this: CFileUploadElement, ev: CFileUploadElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
524
894
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
525
- removeEventListener<K extends keyof CDropdownElementEventMap>(type: K, listener: (this: CDropdownElement, ev: CDropdownElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
895
+ removeEventListener<K extends keyof CFileUploadElementEventMap>(type: K, listener: (this: CFileUploadElement, ev: CFileUploadElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
526
896
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
527
897
  }
898
+ /** An icon drawn from a single SVG path, sized in pixels and filled with the colour of the surrounding text unless given one of its own. */
528
899
  export interface CIconElement extends Omit<HTMLElement, 'color' | 'path' | 'size'> {
529
900
  /** Fill color. */
530
901
  color?: string;
@@ -533,157 +904,205 @@ export interface CIconElement extends Omit<HTMLElement, 'color' | 'path' | 'size
533
904
  /** Icon size in pixels. */
534
905
  size?: number;
535
906
  }
907
+ /** An icon-only button: a round native button that shows a single icon and takes its accessible name from an `aria-label` on the element. */
536
908
  export interface CIconButtonElement extends Omit<HTMLElement, 'badge' | 'danger' | 'disabled' | 'ghost' | 'inverted' | 'loading' | 'outlined' | 'path' | 'size' | 'text'> {
537
- /** Show a badge on top of the icon */
909
+ /**
910
+ * Count shown in a bubble at the button's top-right corner; hidden while
911
+ * `null` or empty, so `0` still shows.
912
+ */
538
913
  badge?: null | number | string;
539
- /** Danger variant of the button */
914
+ /**
915
+ * Danger appearance for a destructive action: the filled button in the error
916
+ * colour; no effect on `outlined`, `ghost` or `text`.
917
+ */
540
918
  danger?: boolean;
541
- /** Disable the button */
919
+ /** Disable the button: it leaves the Tab order and ignores the pointer. */
542
920
  disabled?: boolean;
543
- /** Ghost variant of the button */
921
+ /** Ghost appearance: a light primary tint, for lower emphasis. */
544
922
  ghost?: boolean;
545
- /** Inverted color for dark backgrounds */
923
+ /**
924
+ * Inverted colours for a fixed dark or brand-coloured backdrop: the
925
+ * `inverse-*` family, the same in both theme modes. Combines with the other
926
+ * appearances.
927
+ */
546
928
  inverted?: boolean;
547
- /** Loading variant of the button */
929
+ /**
930
+ * Show a spinner in place of the icon and ignore clicks; the button stays
931
+ * focusable and is announced as busy and unavailable.
932
+ */
548
933
  loading?: boolean;
549
- /** Outlined variant of the button */
934
+ /** Outlined appearance: a primary outline with no fill, for lower emphasis. */
550
935
  outlined?: boolean;
551
- /** Path for the svg icon */
936
+ /**
937
+ * Icon path of an icon the button draws itself, always 24px; a slotted icon
938
+ * wins over it.
939
+ */
552
940
  path?: string;
553
- /** Size of the button */
941
+ /** Size of the button: `default` (40px), `small` (32px) or `x-small` (28px). */
554
942
  size?: 'default' | 'small' | 'x-small';
555
- /** Text variant of the button */
943
+ /** Text appearance: no fill or outline, the lightest look. */
556
944
  text?: boolean;
557
945
  }
558
- export interface CInputElement extends Omit<HTMLElement, 'active' | 'disabled' | 'errorMessage' | 'filled' | 'hideDetails' | 'hint' | 'inputId' | 'isTextarea' | 'label' | 'labelOnTop' | 'required' | 'shadow' | 'size' | 'valid'> {
559
- /** Set by the wrapping form component when its input has focus or holds a value. */
560
- active?: boolean;
561
- /** Disable the input */
562
- disabled?: boolean;
563
- /** Error message shown in place of the hint while the input is invalid */
564
- errorMessage?: string;
565
- /** Set by the wrapping form component when its input holds a value. */
566
- filled?: boolean;
567
- /** Hide the hint and error messages */
568
- hideDetails?: boolean;
569
- /** Hint text for the input */
570
- hint?: string;
571
- /** id of the inner input element (for the label's htmlFor). */
572
- inputId?: string;
573
- /** Renders textarea-specific spacing tweaks. */
574
- isTextarea?: boolean;
575
- /** Label of the input */
576
- label?: string;
577
- /** Label on top of the input */
578
- labelOnTop?: boolean;
579
- /** Set the input as required */
580
- required?: boolean;
581
- /** Shadow variant of the input */
582
- shadow?: boolean;
583
- /** Field height: the 44px default or the 36px `small` box */
584
- size?: 'default' | 'small';
585
- /** Set the validíty of the input */
586
- valid?: boolean;
587
- }
588
- /** Basic hyperlink component */
589
- export interface CLinkElement extends Omit<HTMLElement, 'href' | 'target' | 'underline' | 'weight'> {
590
- /** Url of link */
946
+ /** A text link to another page or resource: a native `<a>` in the link colour, with an optional underline. */
947
+ export interface CLinkElement extends Omit<HTMLElement, 'href' | 'target' | 'underline'> {
948
+ /**
949
+ * URL the link leads to. Without it the link has no destination: it is
950
+ * neither focusable nor announced as a link.
951
+ */
591
952
  href?: string;
592
- /** regular target attribute of a hyperlink */
953
+ /**
954
+ * Where the `href` opens, as on a native `<a>`: the same tab unless set —
955
+ * `_blank` for a new one.
956
+ */
593
957
  target?: string;
594
- /** Display line under the link */
958
+ /**
959
+ * Underline the text. Underline links inside running text, so colour is not
960
+ * the only thing telling them apart.
961
+ */
595
962
  underline?: boolean;
596
- /** Customisable font weight */
597
- weight?: number | string;
598
963
  }
964
+ /** A vertical list of rows, each a `c-list-item` with its main content and optional leading and trailing content, for settings entries, related pages or a short set of records. */
599
965
  export interface CListElement extends Omit<HTMLElement, 'bordered' | 'disabled'> {
600
- /** Show border arount the list items */
966
+ /**
967
+ * Draw a 1px border with rounded corners around each item; an `active` item's
968
+ * border turns primary.
969
+ */
601
970
  bordered?: boolean;
602
- /** Disable the list */
971
+ /**
972
+ * Disable every item, items added later included; clearing it re-enables only
973
+ * the items the list disabled.
974
+ */
603
975
  disabled?: boolean;
604
976
  }
977
+ /** One row of a `c-list`: its main content goes in the default slot, leading content such as an icon in the `pre` slot and trailing content in the `post` slot. The row is static unless it has an `href`, which makes it a real link; `ripple` adds a press effect and a Tab stop that Enter and Space press, firing `click`; give navigation an `href`. */
605
978
  export interface CListItemElement extends Omit<HTMLElement, 'active' | 'disabled' | 'disabledByParent' | 'hoverable' | 'href' | 'ripple' | 'target'> {
606
- /** Set the item active */
979
+ /**
980
+ * Mark the item as the current one: a primary tint and ring, announced as
981
+ * current (`aria-current`).
982
+ */
607
983
  active?: boolean;
608
- /** Disable the item */
984
+ /**
985
+ * Grey the item out, ignore the pointer and take it out of the Tab order; a
986
+ * link item stops being a link.
987
+ */
609
988
  disabled?: boolean;
610
- /** Disabled by the parent list */
611
- disabledByParent?: boolean;
612
- /** Display background color on hover */
989
+ /** Add the hover tint alone, without a link or a ripple. */
613
990
  hoverable?: boolean;
614
- /** Hyperlink url */
991
+ /**
992
+ * URL that turns the item's content box into a real link, with a hover tint
993
+ * on the row.
994
+ */
615
995
  href?: string;
616
- /** Add ripple effect to the item */
996
+ /**
997
+ * Add a pointer cursor, the hover tint and a ripple on press; an item without
998
+ * `href` also becomes a Tab stop that Enter and Space press, firing `click`.
999
+ */
617
1000
  ripple?: boolean;
618
- /** Hyperlink target */
1001
+ /**
1002
+ * Where the `href` opens, as on a native `<a>`: the same tab unless set —
1003
+ * `_blank` for a new one.
1004
+ */
619
1005
  target?: string;
620
1006
  }
1007
+ /** The main text of a `c-list-item`, in medium-weight type; place it in the item's default slot. It takes the active row's ink by itself when its item is `active`. */
621
1008
  export interface CListItemTitleElement extends Omit<HTMLElement, 'active'> {
622
- /** Set the title active */
623
- active?: boolean;
624
1009
  }
625
- /** A loader component that fills the nearest containing element that has css-property position set to 'relative' */
626
- export interface CLoaderElement extends Omit<HTMLElement, 'contentdelay' | 'size' | 'visible' | 'width'> {
627
- /** Delay in seconds of showing the contents in the slot of the loader */
628
- contentdelay?: number;
629
- /** Size of the loader */
630
- size?: number;
1010
+ /** A loading overlay that covers a container with a translucent scrim and a centred spinner, with an optional message below it, while that container's content loads. */
1011
+ export interface CLoaderElement extends Omit<HTMLElement, 'contentDelay' | 'hide' | 'size' | 'width'> {
631
1012
  /**
632
- * Whether the loader is shown. Toggling this drives the fade-in / smooth
633
- * fade-out — keep the element mounted and bind `visible` rather than using
634
- * `v-if`, which would unmount it and skip the leave transition.
635
- *
636
- * For imperative control (non-Vue consumers holding an element ref) the
637
- * element also exposes `show()` / `hide()` methods. The prop is named
638
- * `visible` (not `show`) so it doesn't collide with the `show()` method —
639
- * mirroring native `<dialog>` (`open` property + `show()`/`close()` methods).
640
- *
641
- * NOTE: this replaces the original Stencil `hide` prop with its inverse, so
642
- * the default (`true` = shown) preserves the original default behaviour.
643
- */
644
- visible?: boolean;
645
- /** Width of the loader */
1013
+ * Delay, in milliseconds, before the slotted message fades in once the
1014
+ * loader shows.
1015
+ */
1016
+ contentDelay?: number;
1017
+ /**
1018
+ * Hide the loader. Toggling it fades the loader in and out, so keep the
1019
+ * element mounted and bind `hide` rather than using `v-if`, which would
1020
+ * unmount it and skip the fade-out.
1021
+ */
1022
+ hide?: boolean;
1023
+ /** The spinner's diameter in pixels. */
1024
+ size?: number;
1025
+ /** The spinner's stroke width in pixels. */
646
1026
  width?: number;
647
- /** Imperatively hide the loader (plays the smooth fade-out). */
648
- hide(): void;
649
- /** Imperatively show the loader (plays the fade-in). */
650
- show(): void;
651
1027
  }
1028
+ /** One identity-provider choice inside `c-login-buttons`: a card with the provider's logo (`src`, or markup in the `image` slot) above the provider's name. With an `href` it is a link to the provider's sign-in; without one it is a button whose `click` you handle. Leave `alt` empty when the name already identifies the provider. */
652
1029
  export interface CLoginButtonElement extends Omit<HTMLElement, 'alt' | 'href' | 'src'> {
653
- /** Alt description for logo */
1030
+ /**
1031
+ * Alternative text for the `src` logo, read before the provider's name.
1032
+ * Leave it empty when the name already identifies the provider.
1033
+ */
654
1034
  alt?: string;
655
- /** Login provider link. Do not set if using a javascript click handler */
1035
+ /**
1036
+ * The provider's sign-in URL, which makes the card a link. Without it the
1037
+ * card is a button: handle its `click`.
1038
+ */
656
1039
  href?: string;
657
- /** Login provider logo url */
1040
+ /**
1041
+ * URL of the provider's logo, shown above the name. The `image` slot
1042
+ * replaces it.
1043
+ */
658
1044
  src?: string;
659
1045
  }
1046
+ /** A grid of sign-in choices, one `c-login-button` per identity provider, each showing the provider's logo above its name. */
660
1047
  export interface CLoginButtonsElement extends HTMLElement {
661
1048
  }
1049
+ /** The card of a sign-in page: a large surface holding the service's heading, the sign-in form or choices and their actions, with an optional background image showing below a curved edge. */
662
1050
  export interface CLoginCardElement extends Omit<HTMLElement, 'backgroundPosition' | 'mobileBreakpoint' | 'overlay' | 'overlayBlendMode' | 'src'> {
663
- /** Background position (css background-position) */
1051
+ /**
1052
+ * Which part of the `src` image shows: any CSS `background-position`
1053
+ * value.
1054
+ */
664
1055
  backgroundPosition?: string;
665
- /** Mobile breakpoint in pixels */
1056
+ /**
1057
+ * The card's own width, in pixels, at or below which it switches to its
1058
+ * compact layout.
1059
+ */
666
1060
  mobileBreakpoint?: number;
667
- /** Add colored overlay to the background image */
1061
+ /**
1062
+ * Tints the background image with the primary colour, blended through
1063
+ * `overlay-blend-mode`.
1064
+ */
668
1065
  overlay?: boolean;
669
- /** Add colored overlay to the background image */
1066
+ /** How the `overlay` tint blends with the image: a CSS blend mode. */
670
1067
  overlayBlendMode?: 'color-burn' | 'color-dodge' | 'color' | 'darken' | 'difference' | 'exclusion' | 'hard-light' | 'hue' | 'lighten' | 'luminosity' | 'multiply' | 'normal' | 'overlay' | 'saturation' | 'screen' | 'soft-light';
671
- /** Background image */
1068
+ /**
1069
+ * URL of the background image, shown below a curved edge: in the card's
1070
+ * bottom-right corner, or along its bottom in the compact layout. Without
1071
+ * it the content takes the card's full width.
1072
+ */
672
1073
  src?: string;
673
1074
  }
1075
+ /** The row of actions at the bottom of a `c-login-card`: the sign-in button and any link beside it, such as a forgotten-password link. `justify` distributes them along the row (`start` by default, `space-between` to push the last one to the far end, `stretch` to grow them all) and `align` places them across it. */
674
1076
  export interface CLoginCardActionsElement extends Omit<HTMLElement, 'align' | 'justify'> {
675
- /** Align the actions */
1077
+ /**
1078
+ * Aligns the actions across the row: to its top (`start`), centre or
1079
+ * bottom (`end`).
1080
+ */
676
1081
  align?: 'center' | 'end' | 'start';
677
- /** Justify the actions */
1082
+ /**
1083
+ * Distributes the actions along the row; `stretch` grows every action to
1084
+ * share it.
1085
+ */
678
1086
  justify?: 'center' | 'end' | 'space-around' | 'space-between' | 'start' | 'stretch';
679
1087
  }
1088
+ /** The body of a `c-login-card`, which stacks the intro text and the sign-in fields in a column with a 24px gap. Place it between `c-login-card-title` and `c-login-card-actions`. */
680
1089
  export interface CLoginCardContentElement extends HTMLElement {
681
1090
  }
682
- export interface CLoginCardTitleElement extends HTMLElement {
1091
+ /** The heading of a `c-login-card`, in large bold type in the primary colour; place it first in the card. The card shrinks it from 40px to 32px in its compact layout. */
1092
+ export interface CLoginCardTitleElement extends Omit<HTMLElement, 'headingLevel'> {
1093
+ /**
1094
+ * The title's heading level, 1 to 6: pick the one that fits the card's
1095
+ * place in the page's outline (2 under the page's `h1`, 3 inside a section
1096
+ * with an `h2`).
1097
+ */
1098
+ headingLevel?: 1 | 2 | 3 | 4 | 5 | 6;
683
1099
  }
684
- /** Wrapper component for the whole page */
1100
+ /** The page shell of an application: it paints the page canvas and lays out the toolbar, the side navigation and the page in the dashboard layout. It is at least a viewport tall and grows with its content, so the document — not a component — is what scrolls. */
685
1101
  export interface CMainElement extends Omit<HTMLElement, 'disableLayout'> {
686
- /** Disable the default dashboard layout */
1102
+ /**
1103
+ * Turns off the dashboard layout: the slotted components stack in a plain
1104
+ * column, still at least a viewport tall.
1105
+ */
687
1106
  disableLayout?: boolean;
688
1107
  }
689
1108
  /** Events dispatched by `<c-menu>`. */
@@ -700,12 +1119,13 @@ export interface CMenuElementEventMap {
700
1119
  * bubbles out of the menu so a single listener can handle the whole tree.
701
1120
  */
702
1121
  select: CustomEvent<{
703
- value: unknown;
1122
+ value: string | undefined;
704
1123
  }>;
705
1124
  }
1125
+ /** A command menu: a transient panel of actions or navigation choices opened from a trigger (the WAI-ARIA menu-button pattern), authored declaratively with slotted `c-menu-item`, `c-menu-label` and `c-divider` elements. Activating an item fires a one-off `select` event and closes the menu; the menu holds no selected value — that is `c-select`'s job. */
706
1126
  export interface CMenuElement extends Omit<HTMLElement, 'distance' | 'open' | 'position' | 'trigger'> {
707
1127
  /** Distance from the trigger to the panel, in pixels. Defaults to `0`. */
708
- distance?: number | string;
1128
+ distance?: number;
709
1129
  /** Whether the menu is open. Two-way: emits `change:open`. */
710
1130
  open?: boolean;
711
1131
  /** Preferred placement of the panel relative to the trigger. */
@@ -725,64 +1145,55 @@ export interface CMenuElement extends Omit<HTMLElement, 'distance' | 'open' | 'p
725
1145
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
726
1146
  }
727
1147
  /** A single command in a `c-menu`. */
728
- export interface CMenuItemElement extends Omit<HTMLElement, 'active' | 'activeIcon' | 'danger' | 'disabled' | 'icon' | 'value'> {
729
- /**
730
- * Marks the item as the currently selected choice: renders the trailing
731
- * indicator icon and stamps `role="menuitemradio"` + `aria-checked`. Leave
732
- * unset for regular command items — only a true/false value marks the item
733
- * as a selectable choice. The state is consumer-owned: the menu emits
734
- * `select` as usual and never toggles this itself. Distinct from the
735
- * keyboard highlight (the `data-active` attribute the controlling menu
736
- * moves between rows).
737
- */
738
- active?: boolean;
1148
+ export interface CMenuItemElement extends Omit<HTMLElement, 'checked' | 'danger' | 'disabled' | 'type' | 'value'> {
739
1149
  /**
740
- * SVG path for the trailing indicator shown while `active`; defaults to a
741
- * check mark.
1150
+ * Whether a `radio` item is the checked choice: it shows a check mark and
1151
+ * `aria-checked`. The state is yours: the menu fires `select` as usual and
1152
+ * never checks an item itself.
742
1153
  */
743
- activeIcon?: string;
1154
+ checked?: boolean;
744
1155
  /** Marks the action as destructive (renders in the error colour). */
745
1156
  danger?: boolean;
746
1157
  /** Disables the item — it is skipped by keyboard nav and emits no select. */
747
1158
  disabled?: boolean;
748
- /** SVG path for a leading icon rendered before the item's content. */
749
- icon?: string;
1159
+ /**
1160
+ * What the item is: a `command` (a plain menu item) or one `radio` choice
1161
+ * of several, checked with `checked`.
1162
+ */
1163
+ type?: 'command' | 'radio';
750
1164
  /** Value reported in the menu's `select` event when this item is chosen. */
751
1165
  value?: string;
752
- closeSubmenu(): void;
753
- openSubmenu(): void;
754
1166
  }
755
1167
  /** Section label for a group of `c-menu-item`s. */
756
1168
  export interface CMenuLabelElement extends HTMLElement {
757
1169
  }
758
- export interface CMessageElement extends Omit<HTMLElement, 'errorMessage' | 'hint' | 'inputId' | 'valid'> {
1170
+ /** A single line of text under a form control: a neutral hint, or an error message that takes its place while the control is invalid. */
1171
+ export interface CMessageElement extends Omit<HTMLElement, 'errorMessage' | 'hint' | 'invalid'> {
759
1172
  /** Error message shown in place of the hint while the parent is invalid */
760
1173
  errorMessage?: string;
761
- /** Hint text for the input */
1174
+ /** Hint text, shown unless the error message replaces it */
762
1175
  hint?: string;
763
- /** Id of the related input element */
764
- inputId?: string;
765
- /** Parent validíty */
766
- valid?: boolean;
1176
+ /**
1177
+ * Show the `error-message`, when set, in place of the hint. Marking the
1178
+ * control itself `aria-invalid` is up to the control.
1179
+ */
1180
+ invalid?: boolean;
767
1181
  }
768
1182
  /** Events dispatched by `<c-modal>`. */
769
1183
  export interface CModalElementEventMap {
770
1184
  /**
771
- * Fired when the modal dismisses itself — a backdrop click or the Escape
772
- * key on a `dismissable` modal, or a platform-initiated close (e.g. a
773
- * slotted `<form method="dialog">`). The detail is the new open state,
1185
+ * Fired when the modal dismisses itself — the Escape key, a backdrop click
1186
+ * on a `dismissable` modal, or a platform-initiated close (e.g. a slotted
1187
+ * `<form method="dialog">`). The detail is the new open state,
774
1188
  * always `false`.
775
1189
  */
776
- changeValue: CustomEvent<boolean>;
1190
+ change: CustomEvent<boolean>;
777
1191
  /**
778
1192
  * Native bubbling input event dispatched alongside every value change so a
779
1193
  * plain `v-model` stays in sync. Carries no detail.
780
1194
  */
781
1195
  input: CustomEvent<void>;
782
- /**
783
- * Fired alongside `changeValue` with the same detail — the `v-model`
784
- * contract.
785
- */
1196
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
786
1197
  'update:value': CustomEvent<boolean>;
787
1198
  }
788
1199
  /** Modals interrupt the page for a task that must be completed (or explicitly cancelled) before continuing — confirmations, short forms, destructive-action warnings. The slotted content is typically a `c-card`. */
@@ -790,9 +1201,9 @@ export interface CModalElement extends Omit<HTMLElement, 'disableBackdropBlur' |
790
1201
  /** Disable backdrop blur effect */
791
1202
  disableBackdropBlur?: boolean;
792
1203
  /**
793
- * Dismissed when touching/clicking outside the content or pressing Escape.
794
- * A non-dismissable modal responds to either gesture with a nudge animation
795
- * instead of closing.
1204
+ * Dismissed when touching/clicking outside the content. A non-dismissable
1205
+ * modal responds to that with a nudge animation instead of closing. Escape
1206
+ * closes every modal.
796
1207
  */
797
1208
  dismissable?: boolean;
798
1209
  /** Is the modal visible */
@@ -804,8 +1215,97 @@ export interface CModalElement extends Omit<HTMLElement, 'disableBackdropBlur' |
804
1215
  removeEventListener<K extends keyof CModalElementEventMap>(type: K, listener: (this: CModalElement, ev: CModalElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
805
1216
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
806
1217
  }
807
- export interface CNavigationButtonElement extends HTMLElement {
1218
+ /** The hamburger menu button that opens and closes the mobile drawer of a `c-side-navigation`. */
1219
+ export interface CNavigationButtonElement extends Omit<HTMLElement, 'texts'> {
1220
+ /**
1221
+ * UI text overrides (i18n), merged over the English defaults. Objects have
1222
+ * no attribute form — bind as a DOM property
1223
+ */
1224
+ texts?: CNavigationButtonTexts;
1225
+ }
1226
+ /** Events dispatched by `<c-number-field>`. */
1227
+ export interface CNumberFieldElementEventMap {
1228
+ /**
1229
+ * Fired when the number is committed, carrying it — `null` once the field
1230
+ * holds no digit: Enter or leaving the field after typing, each arrow-key
1231
+ * or step-button step, and the release that ends a held step button. Not
1232
+ * fired when nothing changed since the last commit.
1233
+ */
1234
+ change: CustomEvent<null | number>;
1235
+ /**
1236
+ * Native bubbling input event fired alongside every value change so a
1237
+ * plain Vue `v-model` works. No detail.
1238
+ */
1239
+ input: CustomEvent<void>;
1240
+ /**
1241
+ * v-model contract event fired whenever typing or a step changes the
1242
+ * number. Not fired when only the text changes (a group separator, a
1243
+ * trailing decimal separator) or when `value` is set.
1244
+ */
1245
+ 'update:value': CustomEvent<null | number>;
808
1246
  }
1247
+ /** A field for a number — an integer, or one with decimals — shown with thousands separators as it is typed. */
1248
+ export interface CNumberFieldElement extends Omit<HTMLElement, 'decimals' | 'decimalSeparator' | 'disabled' | 'errorMessage' | 'fixedDecimals' | 'groupSeparator' | 'hideDetails' | 'hint' | 'invalid' | 'label' | 'labelOnTop' | 'max' | 'min' | 'name' | 'placeholder' | 'readonly' | 'required' | 'shadow' | 'size' | 'step' | 'texts' | 'value'> {
1249
+ /** The most fraction digits the field takes; `0` makes it an integer field */
1250
+ decimals?: number;
1251
+ /** The decimal separator. Empty follows the page's `lang` (`,` for `fi`, `.` for `en`) */
1252
+ decimalSeparator?: string;
1253
+ /** Disable the field */
1254
+ disabled?: boolean;
1255
+ /** Error message shown in place of the hint while the field is invalid */
1256
+ errorMessage?: string;
1257
+ /** Pad the fraction to exactly `decimals` digits when the field is left (`12,5` → `12,50`) */
1258
+ fixedDecimals?: boolean;
1259
+ /** The thousands separator. Empty follows the page's `lang` (a space for `fi`, `,` for `en`) */
1260
+ groupSeparator?: string;
1261
+ /** Hide the hint and error messages */
1262
+ hideDetails?: boolean;
1263
+ /** Hint text for the field */
1264
+ hint?: string;
1265
+ /**
1266
+ * Show the control as invalid: its `error-message`, when set, replaces the
1267
+ * hint, and the control is marked `aria-invalid`.
1268
+ */
1269
+ invalid?: boolean;
1270
+ /** Label of the field */
1271
+ label?: string;
1272
+ /** Label on top of the field */
1273
+ labelOnTop?: boolean;
1274
+ /** The largest number in range; a larger one is kept and reported as out of range */
1275
+ max?: null | number;
1276
+ /** The smallest number in range; a smaller one is kept and reported as out of range. At `0` or above, the minus key is ignored */
1277
+ min?: null | number;
1278
+ /** Name of the input */
1279
+ name?: string;
1280
+ /** Placeholder of the input */
1281
+ placeholder?: string;
1282
+ /** Mark as readonly */
1283
+ readonly?: boolean;
1284
+ /** Set the field as required */
1285
+ required?: boolean;
1286
+ /** Shadow variant of the field */
1287
+ shadow?: boolean;
1288
+ /** Field height: the 52px default (the shared control height) or the 36px `small` box */
1289
+ size?: 'default' | 'small';
1290
+ /** The spacing of the grid the step buttons and arrow keys move along, counted from `min` (or `0`) */
1291
+ step?: number;
1292
+ /** UI text overrides (i18n), merged over the English defaults. Objects have no attribute form — bind as a DOM property */
1293
+ texts?: CNumberFieldTexts;
1294
+ /** The number, or `null` when the field is empty. A string is read as the number it spells, and `''` as empty — what an attribute, or a plain `v-model` holding `null`, writes; the field always emits a number or `null` */
1295
+ value?: null | number | string;
1296
+ /** Whether the number is below `min` or above `max` (CONTEXT.md "Out of range") */
1297
+ readonly outOfRange: boolean;
1298
+ /**
1299
+ * Focus its input, as `focus()` does on a native control: the element renders
1300
+ * no box of its own to take it.
1301
+ */
1302
+ focus(options?: FocusOptions): void;
1303
+ addEventListener<K extends keyof CNumberFieldElementEventMap>(type: K, listener: (this: CNumberFieldElement, ev: CNumberFieldElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1304
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1305
+ removeEventListener<K extends keyof CNumberFieldElementEventMap>(type: K, listener: (this: CNumberFieldElement, ev: CNumberFieldElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1306
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1307
+ }
1308
+ /** One option of a `c-select` or `c-autocomplete`: `value` is what the field reports when the option is picked, and the option's label is its `name`, else the text of a `c-option-value` inside it, else its whole text. `disabled` keeps it from being picked, and `selected` sets the field's initial value once, silently, while that value is empty — with a bound `v-model`, initialise the model instead. */
809
1309
  export interface COptionElement extends Omit<HTMLElement, 'disabled' | 'name' | 'selected' | 'value'> {
810
1310
  /** Set option as disabled */
811
1311
  disabled?: boolean;
@@ -816,91 +1316,111 @@ export interface COptionElement extends Omit<HTMLElement, 'disabled' | 'name' |
816
1316
  /** Option value */
817
1317
  value?: number | string;
818
1318
  }
1319
+ /** The label region of a `c-option`: wraps the text that c-select and c-autocomplete use as the option's label — in the closed field, its tag and the autocomplete filter — so the option can carry a description or an icon beside its label, and the region in which c-autocomplete marks the runs equal to the query (`::part(match)`). */
819
1320
  export interface COptionValueElement extends HTMLElement {
820
1321
  }
821
1322
  /** Events dispatched by `<c-otp-input>`. */
822
1323
  export interface COtpInputElementEventMap {
823
1324
  /**
824
- * Fired on every digit change with the complete code once all digits are
825
- * filled, or `null` while the code is still incomplete (legacy value-change
826
- * event).
1325
+ * Fired when the code is committed — Enter, or focus leaving the digits
1326
+ * after a change — carrying the digits entered so far (`''` when none).
827
1327
  */
828
- changeValue: CustomEvent<null | string>;
1328
+ change: CustomEvent<string>;
829
1329
  /** Fired when the last digit is filled, carrying the complete code. */
830
- completion: CustomEvent<null | string>;
1330
+ completion: CustomEvent<string>;
831
1331
  /**
832
- * Native bubbling input event for plain `v-model`; carries no detail — the
833
- * model value is mirrored onto the host's `value` property.
1332
+ * Native bubbling input event fired alongside every value change so a
1333
+ * plain `v-model` stays in sync. No detail.
834
1334
  */
835
1335
  input: CustomEvent<void>;
836
1336
  /**
837
- * Fired on every digit change with the currently entered digits (v-model
838
- * contract).
1337
+ * v-model contract event fired on every digit change, carrying the digits
1338
+ * entered so far (`''` when none).
839
1339
  */
840
1340
  'update:value': CustomEvent<string>;
841
1341
  }
842
- export interface COtpInputElement extends Omit<HTMLElement, 'elementId' | 'errorMessage' | 'hasAutofocus' | 'hideDetails' | 'hint' | 'label' | 'length' | 'required' | 'valid' | 'value'> {
843
- /** Id of the element */
844
- elementId?: string;
1342
+ /** A one-time-code field: a row of single-digit boxes, filled in order as the user types or pastes a code, under a group label and above a hint or error message. */
1343
+ export interface COtpInputElement extends Omit<HTMLElement, 'autofocus' | 'errorMessage' | 'hideDetails' | 'hint' | 'invalid' | 'label' | 'length' | 'required' | 'value'> {
1344
+ /** Focus the first digit when the field mounts. */
1345
+ autofocus?: boolean;
845
1346
  /** Error message shown in place of the hint while the input is invalid */
846
1347
  errorMessage?: string;
847
- /** Auto focus */
848
- hasAutofocus?: boolean;
849
1348
  /** Hide the hint and error messages */
850
1349
  hideDetails?: boolean;
851
1350
  /** Hint text for the input */
852
1351
  hint?: string;
1352
+ /**
1353
+ * Show the control as invalid: its `error-message`, when set, replaces the
1354
+ * hint, and the control is marked `aria-invalid`.
1355
+ */
1356
+ invalid?: boolean;
853
1357
  /** Label of the input group, shown above the digit inputs */
854
1358
  label?: string;
855
- /** Length of the OTP code */
1359
+ /** Number of digits in the code, one box each */
856
1360
  length?: number;
857
1361
  /** Set as required — shows the required marker on the label */
858
1362
  required?: boolean;
859
- /** Set the validíty of the input */
860
- valid?: boolean;
861
- /** Value of the input */
1363
+ /**
1364
+ * The digits entered so far, joined into one string (`''` when none).
1365
+ * Setting it fills the boxes from the first one
1366
+ */
862
1367
  value?: string;
1368
+ /**
1369
+ * Focus its first digit box, as `focus()` does on a native control: the element renders
1370
+ * no box of its own to take it.
1371
+ */
1372
+ focus(options?: FocusOptions): void;
863
1373
  addEventListener<K extends keyof COtpInputElementEventMap>(type: K, listener: (this: COtpInputElement, ev: COtpInputElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
864
1374
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
865
1375
  removeEventListener<K extends keyof COtpInputElementEventMap>(type: K, listener: (this: COtpInputElement, ev: COtpInputElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
866
1376
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
867
1377
  }
1378
+ /** The routed-content region of the dashboard layout: inside `c-main` it fills the area beside the side navigation and below the toolbar, pads the current view's content and keeps an optional footer at its bottom edge. */
868
1379
  export interface CPageElement extends Omit<HTMLElement, 'scrollIndicator'> {
869
- /** Display scroll indicator */
1380
+ /**
1381
+ * Shows a 4px primary bar along the top edge of the viewport whose length
1382
+ * tracks how far the document has been scrolled.
1383
+ */
870
1384
  scrollIndicator?: boolean;
871
1385
  }
872
1386
  /** Events dispatched by `<c-pagination>`. */
873
1387
  export interface CPaginationElementEventMap {
874
1388
  /**
875
- * Fired when the user changes the page or the page size, carrying the
876
- * pagination options object with the recomputed `currentPage`,
877
- * `itemsPerPage`, `startFrom` and `endTo` fields.
1389
+ * Fired when the user picks a page or a page size, carrying a new value
1390
+ * with the picked `page` and `pageSize` and the page's `startFrom` and
1391
+ * `endTo`.
878
1392
  */
879
- changeValue: CustomEvent<CPaginationOptions>;
1393
+ change: CustomEvent<CPaginationOptions>;
880
1394
  /**
881
1395
  * Native bubbling input event dispatched alongside every value change so a
882
1396
  * plain `v-model` stays in sync. Carries no detail.
883
1397
  */
884
1398
  input: CustomEvent<void>;
885
- /**
886
- * Fired alongside `changeValue` with the same detail — the `v-model`
887
- * contract.
888
- */
1399
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
889
1400
  'update:value': CustomEvent<CPaginationOptions>;
890
1401
  }
891
- export interface CPaginationElement extends Omit<HTMLElement, 'hideDetails' | 'hideRange' | 'simple' | 'size' | 'value'> {
892
- /** Hide details (per page dropdown and the 'x - y of n pages' text) */
1402
+ /** A page navigation bar for a list split into pages: previous and next buttons around a window of page buttons, with a page-size menu and the range of items shown. */
1403
+ export interface CPaginationElement extends Omit<HTMLElement, 'hideDetails' | 'hideRange' | 'simple' | 'size' | 'texts' | 'value'> {
1404
+ /** Hide the details row: the page-size menu and the "x - y of n items" text */
893
1405
  hideDetails?: boolean;
894
- /** Hide range indicator */
1406
+ /** Hide the range text ("11 - 20 of 96 items"), keeping the page-size menu. */
895
1407
  hideRange?: boolean;
896
- /** Hide page number buttons */
1408
+ /**
1409
+ * Drop the page buttons and move previous and next to the bar's end; the
1410
+ * range text is then the only sign of position.
1411
+ */
897
1412
  simple?: boolean;
898
- /** Hide details (per page dropdown and the 'x - y of n pages' text) */
1413
+ /** Size of the controls: `small` renders the compact page buttons. */
899
1414
  size?: 'default' | 'small';
900
1415
  /**
901
- * Object containing values that are needed for pagination.
902
- *
903
- * Note! startFrom and endTo are assigned automatically to the object based on other values
1416
+ * UI text overrides (i18n), merged over the English defaults. Objects have
1417
+ * no attribute form — bind as a DOM property
1418
+ */
1419
+ texts?: CPaginationTexts;
1420
+ /**
1421
+ * The item count and the current page and page size; see
1422
+ * `CPaginationOptions`. Bind it with `v-model`, or set it and listen to
1423
+ * `change`.
904
1424
  */
905
1425
  value?: CPaginationOptions;
906
1426
  addEventListener<K extends keyof CPaginationElementEventMap>(type: K, listener: (this: CPaginationElement, ev: CPaginationElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
@@ -921,7 +1441,7 @@ export interface CPopoverElementEventMap {
921
1441
  /** A click-opened, non-modal surface anchored to its trigger, floating in the top layer; its content may be interactive. */
922
1442
  export interface CPopoverElement extends Omit<HTMLElement, 'distance' | 'heading' | 'open' | 'position' | 'trigger'> {
923
1443
  /** Distance from the trigger to the panel, in pixels. Defaults to `0`. */
924
- distance?: number | string;
1444
+ distance?: number;
925
1445
  /**
926
1446
  * Heading rendered at the top of the panel, doubling as its accessible
927
1447
  * name. Without it, set `aria-label` on the host. Named `heading`, not
@@ -948,38 +1468,41 @@ export interface CPopoverElement extends Omit<HTMLElement, 'distance' | 'heading
948
1468
  }
949
1469
  /** A horizontal progress bar that fills a track to a known completion percentage, with an optional details line showing the value and a label. */
950
1470
  export interface CProgressBarElement extends Omit<HTMLElement, 'hideDetails' | 'indeterminate' | 'label' | 'singleLine' | 'value'> {
951
- /** Hide the percentage display */
1471
+ /**
1472
+ * Hides the details line (the percentage and `label`); `label` still
1473
+ * names the bar.
1474
+ */
952
1475
  hideDetails?: boolean;
953
- /** Indeterminate state of the progress bar */
1476
+ /**
1477
+ * Replaces the fill with a looping sweep for work of unknown duration,
1478
+ * hiding the details line and exposing no value.
1479
+ */
954
1480
  indeterminate?: boolean;
955
- /** Optional details message next to percentage display */
1481
+ /**
1482
+ * What is progressing: shown after the percentage, and the progress bar's
1483
+ * accessible name.
1484
+ */
956
1485
  label?: string;
957
- /** Place details next to progress bar */
1486
+ /** Places the details line beside the bar instead of below it. */
958
1487
  singleLine?: boolean;
959
- /** Progress bar value in percentage (0 to 100) */
1488
+ /**
1489
+ * Completion percentage, 0 to 100. The fill clamps a value outside that
1490
+ * range; the details line shows it as given, a negative one in the error
1491
+ * colour.
1492
+ */
960
1493
  value?: number;
961
1494
  }
962
1495
  /** A circular progress indicator that draws a known completion percentage as an arc around a track — the circular counterpart of `c-progress-bar`. */
963
- export interface CProgressCircleElement extends Omit<HTMLElement, 'size' | 'value' | 'width'> {
1496
+ export interface CProgressCircleElement extends Omit<HTMLElement, 'size' | 'thickness' | 'value'> {
964
1497
  /** Diameter of the circle in pixels */
965
1498
  size?: number;
966
- /** Progress value in percentage (0 to 100) */
967
- value?: number;
968
- /**
969
- * Stroke width of the track in pixels; the value arc draws at half this
970
- * width, inset within the track
971
- */
972
- width?: number;
973
- }
974
- /** Events dispatched by `<c-radio>`. */
975
- export interface CRadioElementEventMap {
976
1499
  /**
977
- * Fired when the radio is selected by the user, carrying its `value`.
978
- * Bubbles composed so the parent `<c-radio-group>` — whose shadow root a
979
- * light-DOM event never enters — catches it on its host; a consumer
980
- * listening on the group hears it too, with the radio as `target`.
1500
+ * Thickness of the track in pixels; the value arc draws at half this
1501
+ * thickness, inset within the track
981
1502
  */
982
- change: CustomEvent<string>;
1503
+ thickness?: number;
1504
+ /** Progress value in percentage (0 to 100) */
1505
+ value?: number;
983
1506
  }
984
1507
  /** A single radio option inside a `c-radio-group`: a native radio input whose default slot is its clickable, announced label. */
985
1508
  export interface CRadioElement extends Omit<HTMLElement, 'disabled' | 'value'> {
@@ -987,28 +1510,21 @@ export interface CRadioElement extends Omit<HTMLElement, 'disabled' | 'value'> {
987
1510
  disabled?: boolean;
988
1511
  /** Radio button value */
989
1512
  value?: string;
990
- addEventListener<K extends keyof CRadioElementEventMap>(type: K, listener: (this: CRadioElement, ev: CRadioElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
991
- addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
992
- removeEventListener<K extends keyof CRadioElementEventMap>(type: K, listener: (this: CRadioElement, ev: CRadioElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
993
- removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
994
1513
  }
995
1514
  /** Events dispatched by `<c-radio-group>`. */
996
1515
  export interface CRadioGroupElementEventMap {
997
- /** Fired when a radio is selected, carrying the selected radio's value. */
998
- changeValue: CustomEvent<string>;
1516
+ /** Fired when the user selects a radio, carrying the selected radio's value. */
1517
+ change: CustomEvent<string>;
999
1518
  /**
1000
1519
  * Native bubbling input event fired on selection so a plain Vue `v-model`
1001
- * works without the `v-control` directive. No detail.
1520
+ * stays in sync. No detail.
1002
1521
  */
1003
1522
  input: CustomEvent<void>;
1004
- /**
1005
- * v-model contract event fired on selection, carrying the selected radio's
1006
- * value.
1007
- */
1523
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
1008
1524
  'update:value': CustomEvent<string>;
1009
1525
  }
1010
1526
  /** A radio group is a set of mutually exclusive choices where exactly one can be selected, authored as slotted `c-radio` children. Give the group a `label` so the choice it represents is named for every user, and a `hint` describing how to answer. */
1011
- export interface CRadioGroupElement extends Omit<HTMLElement, 'disabled' | 'errorMessage' | 'hideDetails' | 'hint' | 'inline' | 'label' | 'required' | 'valid' | 'value'> {
1527
+ export interface CRadioGroupElement extends Omit<HTMLElement, 'disabled' | 'errorMessage' | 'hideDetails' | 'hint' | 'inline' | 'invalid' | 'label' | 'required' | 'value'> {
1012
1528
  /** Disable the radio group */
1013
1529
  disabled?: boolean;
1014
1530
  /** Error message shown in place of the hint while the group is invalid */
@@ -1019,17 +1535,25 @@ export interface CRadioGroupElement extends Omit<HTMLElement, 'disabled' | 'erro
1019
1535
  hint?: string;
1020
1536
  /** Display radio buttons inline */
1021
1537
  inline?: boolean;
1538
+ /**
1539
+ * Show the control as invalid: its `error-message`, when set, replaces the
1540
+ * hint, and the control is marked `aria-invalid`.
1541
+ */
1542
+ invalid?: boolean;
1022
1543
  /** Label of the radio group */
1023
1544
  label?: string;
1024
1545
  /** Set as required */
1025
1546
  required?: boolean;
1026
- /** Set the validity of the input */
1027
- valid?: boolean;
1028
1547
  /**
1029
1548
  * Value of the radio group; matched against each radio's `value` by strict
1030
1549
  * string equality
1031
1550
  */
1032
1551
  value?: null | string;
1552
+ /**
1553
+ * Focus its tab stop: the checked radio, else the first enabled one, as `focus()` does on a native control: the element renders
1554
+ * no box of its own to take it.
1555
+ */
1556
+ focus(options?: FocusOptions): void;
1033
1557
  addEventListener<K extends keyof CRadioGroupElementEventMap>(type: K, listener: (this: CRadioGroupElement, ev: CRadioGroupElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1034
1558
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1035
1559
  removeEventListener<K extends keyof CRadioGroupElementEventMap>(type: K, listener: (this: CRadioGroupElement, ev: CRadioGroupElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
@@ -1041,20 +1565,20 @@ export interface CSelectElementEventMap {
1041
1565
  * Fired when the selection changes (an option is picked or the value is
1042
1566
  * cleared), carrying the new value — the option's value, or the whole
1043
1567
  * `{ name, value }` item when `return-object` is set; `null` when cleared.
1568
+ * In `multiple` mode the whole array of picked values, in pick order
1569
+ * (`[]` when cleared).
1044
1570
  */
1045
- changeValue: CustomEvent<CSelectItem | null | number | string>;
1571
+ change: CustomEvent<CSelectValue>;
1046
1572
  /**
1047
1573
  * Native bubbling input event dispatched alongside every value change so a
1048
1574
  * plain `v-model` stays in sync. Carries no detail.
1049
1575
  */
1050
1576
  input: CustomEvent<void>;
1051
- /**
1052
- * Fired alongside `changeValue` with the same detail — the `v-model`
1053
- * contract.
1054
- */
1055
- 'update:value': CustomEvent<CSelectItem | null | number | string>;
1577
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
1578
+ 'update:value': CustomEvent<CSelectValue>;
1056
1579
  }
1057
- export interface CSelectElement extends Omit<HTMLElement, 'clearable' | 'disabled' | 'errorMessage' | 'hideDetails' | 'hint' | 'hostId' | 'items' | 'itemsPerPage' | 'label' | 'labelOnTop' | 'loading' | 'name' | 'optionAsSelection' | 'placeholder' | 'required' | 'returnObject' | 'shadow' | 'size' | 'valid' | 'value'> {
1580
+ /** A value-selection field: a readonly field that opens a listbox of options — slotted `c-option` elements or an `items` array — and holds the picked value, emitting the value events that back `v-model`. */
1581
+ export interface CSelectElement extends Omit<HTMLElement, 'clearable' | 'disabled' | 'errorMessage' | 'hideDetails' | 'hint' | 'invalid' | 'items' | 'itemsPerPage' | 'label' | 'labelOnTop' | 'loading' | 'maxTags' | 'multiple' | 'name' | 'optionAsSelection' | 'placeholder' | 'required' | 'returnObject' | 'selectAll' | 'shadow' | 'size' | 'texts' | 'value'> {
1058
1582
  /** Make the selected value clearable */
1059
1583
  clearable?: boolean;
1060
1584
  /** Disable the input */
@@ -1065,8 +1589,11 @@ export interface CSelectElement extends Omit<HTMLElement, 'clearable' | 'disable
1065
1589
  hideDetails?: boolean;
1066
1590
  /** Hint text for the input */
1067
1591
  hint?: string;
1068
- /** Id of the element */
1069
- hostId?: string;
1592
+ /**
1593
+ * Show the control as invalid: its `error-message`, when set, replaces the
1594
+ * hint, and the control is marked `aria-invalid`.
1595
+ */
1596
+ invalid?: boolean;
1070
1597
  /** Dropdown items (when not using <c-option> elements) */
1071
1598
  items?: CSelectItem[];
1072
1599
  /** Items per page before adding scroll */
@@ -1077,6 +1604,20 @@ export interface CSelectElement extends Omit<HTMLElement, 'clearable' | 'disable
1077
1604
  labelOnTop?: boolean;
1078
1605
  /** Show loading state */
1079
1606
  loading?: boolean;
1607
+ /**
1608
+ * In `multiple` mode, show at most this many selected-value tags and fold
1609
+ * the rest into one "+N more" tag; `0` shows no tags and reads "N selected"
1610
+ * instead; unset shows every tag
1611
+ */
1612
+ maxTags?: number;
1613
+ /**
1614
+ * Allow selecting several options: rows toggle and the list stays open,
1615
+ * `value` becomes an array of the selected values (items with
1616
+ * `return-object`) in the order they were picked, and the picks show as
1617
+ * tags inside the field. `option-as-selection` is ignored in this mode.
1618
+ * Arrays have no attribute form — bind `value` as a DOM property
1619
+ */
1620
+ multiple?: boolean;
1080
1621
  /** Input field name */
1081
1622
  name?: string;
1082
1623
  /** Display the option as selection (only with <c-option> elements) */
@@ -1087,16 +1628,32 @@ export interface CSelectElement extends Omit<HTMLElement, 'clearable' | 'disable
1087
1628
  required?: boolean;
1088
1629
  /** Return object instead of value */
1089
1630
  returnObject?: boolean;
1631
+ /**
1632
+ * In `multiple` mode, pin a select-all row at the top of the list. Its
1633
+ * checkbox shows whether none, some or all enabled options are selected;
1634
+ * activating it selects every enabled option — or, when all are selected,
1635
+ * unselects them. Ignored in single mode
1636
+ */
1637
+ selectAll?: boolean;
1090
1638
  /** Shadow variant */
1091
1639
  shadow?: boolean;
1092
- /** Field height: the 44px default or the 36px `small` box */
1640
+ /** Field height: the 52px default (the shared control height) or the 36px `small` box */
1093
1641
  size?: 'default' | 'small';
1094
- /** Set the validity of the input */
1095
- valid?: boolean;
1096
- /** Selected value (scalar, or object when return-object is set) */
1097
- value?: CSelectItem | null | number | string;
1098
- /** Reset select state */
1099
- reset(): void;
1642
+ /**
1643
+ * UI text overrides (i18n), merged over the English defaults. Objects have
1644
+ * no attribute form — bind as a DOM property (`:texts.prop` in Vue)
1645
+ */
1646
+ texts?: CSelectTexts;
1647
+ /**
1648
+ * Selected value: the option's value, or the whole item with
1649
+ * `return-object`; an array of them in `multiple` mode
1650
+ */
1651
+ value?: CSelectValue;
1652
+ /**
1653
+ * Focus its combobox, as `focus()` does on a native control: the element renders
1654
+ * no box of its own to take it.
1655
+ */
1656
+ focus(options?: FocusOptions): void;
1100
1657
  addEventListener<K extends keyof CSelectElementEventMap>(type: K, listener: (this: CSelectElement, ev: CSelectElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1101
1658
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1102
1659
  removeEventListener<K extends keyof CSelectElementEventMap>(type: K, listener: (this: CSelectElement, ev: CSelectElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
@@ -1105,22 +1662,26 @@ export interface CSelectElement extends Omit<HTMLElement, 'clearable' | 'disable
1105
1662
  /** Events dispatched by `<c-side-navigation>`. */
1106
1663
  export interface CSideNavigationElementEventMap {
1107
1664
  /**
1108
- * Fired when the drawer is closed from within (the mobile close button or
1109
- * the backdrop overlay), carrying the new visibility (`false`).
1110
- * Named `change:menu-visible`, not `update:menuVisible`: Vue's runtime
1111
- * silently drops `onUpdate:*` listeners on custom elements
1112
- * (`isModelListener`), so a template `@update:menu-visible` would never be
1113
- * attached.
1665
+ * Fired when the user opens or closes the drawer — a `c-navigation-button`,
1666
+ * the close button, the backdrop, or activating an item — carrying the new
1667
+ * `open`. Named `change:open`, not `update:open`: Vue's runtime silently
1668
+ * drops `onUpdate:*` listeners on custom elements (`isModelListener`).
1114
1669
  */
1115
- 'change:menu-visible': CustomEvent<boolean>;
1670
+ 'change:open': CustomEvent<boolean>;
1116
1671
  }
1117
- export interface CSideNavigationElement extends Omit<HTMLElement, 'menuVisible' | 'mobile' | 'styles'> {
1118
- /** Mobile version menu visibility */
1119
- menuVisible?: boolean;
1120
- /** Mobile version */
1672
+ /** The dashboard layout's left-hand menu: section titles, navigation items and their sub-items in a drawer that is pinned beside the page on desktop and slides in over it on mobile. */
1673
+ export interface CSideNavigationElement extends Omit<HTMLElement, 'mobile' | 'open'> {
1674
+ /**
1675
+ * Render the drawer as a panel that slides in from the right over a backdrop,
1676
+ * opened and closed by `open` or a `c-navigation-button`; while open it is a
1677
+ * modal dialog.
1678
+ */
1121
1679
  mobile?: boolean;
1122
- /** Background styles */
1123
- styles?: null | Record<string, string>;
1680
+ /**
1681
+ * Whether the `mobile` drawer is open. A `c-navigation-button` anywhere on
1682
+ * the page toggles it.
1683
+ */
1684
+ open?: boolean;
1124
1685
  addEventListener<K extends keyof CSideNavigationElementEventMap>(type: K, listener: (this: CSideNavigationElement, ev: CSideNavigationElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1125
1686
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1126
1687
  removeEventListener<K extends keyof CSideNavigationElementEventMap>(type: K, listener: (this: CSideNavigationElement, ev: CSideNavigationElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
@@ -1129,78 +1690,98 @@ export interface CSideNavigationElement extends Omit<HTMLElement, 'menuVisible'
1129
1690
  /** Events dispatched by `<c-side-navigation-item>`. */
1130
1691
  export interface CSideNavigationItemElementEventMap {
1131
1692
  /**
1132
- * Fired when the item is activated (click or Enter), carrying the
1133
- * originating DOM event; bubbles so the parent `<c-side-navigation>` can
1134
- * coordinate which item is active.
1693
+ * Fired when the item is activated (click or Enter), carrying its `value`;
1694
+ * bubbles out of the navigation, as `c-menu`'s does, so one listener on
1695
+ * `c-side-navigation` can handle every item.
1135
1696
  */
1136
- itemChange: CustomEvent<Event>;
1697
+ select: CustomEvent<{
1698
+ value: string | undefined;
1699
+ }>;
1137
1700
  }
1138
- export interface CSideNavigationItemElement extends Omit<HTMLElement, 'active' | 'focusable' | 'href' | 'loading' | 'target'> {
1139
- /** Indicate active state */
1701
+ /** One entry of a `c-side-navigation`: its label text, after an optional leading `c-icon`, goes in the default slot, and activating it fires `select` with its `value`; with `href` it is a real link, opened in `target`, and without one a button. Write `c-sub-navigation-item` children inside it to make it an expandable parent, whose `active` then means expanded rather than the current page. */
1702
+ export interface CSideNavigationItemElement extends Omit<HTMLElement, 'active' | 'collapsed' | 'href' | 'loading' | 'target' | 'value'> {
1703
+ /**
1704
+ * On an item without sub-items, mark the current page
1705
+ * (`aria-current="page"`); on a parent, expand its sub-items.
1706
+ */
1140
1707
  active?: boolean;
1141
- /** Whether the item is in the keyboard tab order — a parent item sets this to false on its collapsed sub-items so hidden items aren't Tab-reachable */
1142
- focusable?: boolean;
1143
- /** Hyperlink url */
1708
+ /** URL that makes the item a real link; without it the item is a button. */
1144
1709
  href?: string;
1145
- /** Loading state */
1710
+ /** Cover the item with a loading overlay: a translucent scrim and a spinner. */
1146
1711
  loading?: boolean;
1147
- /** Hyperlink target */
1712
+ /**
1713
+ * Where the `href` opens, as on a native `<a>`: the same tab unless set —
1714
+ * `_blank` for a new one.
1715
+ */
1148
1716
  target?: string;
1717
+ /** Value reported in the `select` event when the item is activated */
1718
+ value?: string;
1149
1719
  addEventListener<K extends keyof CSideNavigationItemElementEventMap>(type: K, listener: (this: CSideNavigationItemElement, ev: CSideNavigationItemElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1150
1720
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1151
1721
  removeEventListener<K extends keyof CSideNavigationItemElementEventMap>(type: K, listener: (this: CSideNavigationItemElement, ev: CSideNavigationItemElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1152
1722
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1153
1723
  }
1724
+ /** A section title in a `c-side-navigation`: uppercase text over a divider line, placed before the items it groups. It is a heading (level 2), so screen-reader users can jump between sections, and cannot be activated. */
1154
1725
  export interface CSideNavigationTitleElement extends HTMLElement {
1155
1726
  }
1156
1727
  /** Events dispatched by `<c-slider>`. */
1157
1728
  export interface CSliderElementEventMap {
1158
1729
  /**
1159
- * Fired on every thumb movement, carrying the new slider value — a number
1160
- * when the current `value` prop is a number, otherwise a string.
1730
+ * Fired when a move is committed — the release that ends a drag, or each
1731
+ * arrow-key step — carrying the value.
1161
1732
  */
1162
- changeValue: CustomEvent<number | string>;
1733
+ change: CustomEvent<number>;
1163
1734
  /**
1164
1735
  * Native bubbling input event fired on every thumb movement so a plain Vue
1165
- * `v-model` works without the `v-control` directive. No detail.
1736
+ * `v-model` stays in sync. No detail.
1166
1737
  */
1167
1738
  input: CustomEvent<void>;
1168
1739
  /**
1169
1740
  * v-model contract event fired on every thumb movement, carrying the new
1170
- * slider value — a number when the current `value` prop is a number,
1171
- * otherwise a string.
1741
+ * value.
1172
1742
  */
1173
- 'update:value': CustomEvent<number | string>;
1743
+ 'update:value': CustomEvent<number>;
1174
1744
  }
1175
- export interface CSliderElement extends Omit<HTMLElement, 'ariaLabelInternal' | 'disabled' | 'disableTooltip' | 'hostId' | 'hostName' | 'label' | 'labels' | 'max' | 'min' | 'segments' | 'step' | 'ticks' | 'unit' | 'value'> {
1176
- /** Aria label */
1177
- ariaLabelInternal?: string;
1745
+ /** A slider for picking a number from a range by dragging a thumb along a track, with a label, a value bubble and optional tick marks. */
1746
+ export interface CSliderElement extends Omit<HTMLElement, 'disabled' | 'disableTooltip' | 'label' | 'labels' | 'max' | 'min' | 'name' | 'segments' | 'step' | 'ticks' | 'unit' | 'value'> {
1178
1747
  /** Disable the slider */
1179
1748
  disabled?: boolean;
1180
- /** Disable tooltip */
1749
+ /**
1750
+ * Turn off the value bubble shown above the thumb while the slider is
1751
+ * hovered, pressed or focused
1752
+ */
1181
1753
  disableTooltip?: boolean;
1182
- /** Id of the element */
1183
- hostId?: string;
1184
- /** Id of the element */
1185
- hostName?: string;
1186
1754
  /** Label of the slider */
1187
1755
  label?: string;
1188
- /** Show tick labels */
1756
+ /**
1757
+ * Write a number under the track at each tick mark position, `segments`
1758
+ * apart, formatted like the value bubble's; shown with or without `ticks`
1759
+ */
1189
1760
  labels?: boolean;
1190
- /** Max value */
1191
- max?: number | string;
1192
- /** Min value */
1193
- min?: number | string;
1194
- /** Segment count */
1195
- segments?: number | string;
1196
- /** Step */
1197
- step?: number | string;
1198
- /** Thow ticks */
1761
+ /** The largest value. */
1762
+ max?: number;
1763
+ /** The smallest value. */
1764
+ min?: number;
1765
+ /**
1766
+ * `name` of the inner range input. The component is not
1767
+ * form-associated, so it does not submit with a `<form>`.
1768
+ */
1769
+ name?: string;
1770
+ /** Number of segments the tick marks divide the track into. */
1771
+ segments?: number;
1772
+ /** Step between values. */
1773
+ step?: number;
1774
+ /** Draw tick marks along the track, `segments` apart. */
1199
1775
  ticks?: boolean;
1200
- /** Unit */
1776
+ /** Unit shown after the value in the tooltip and read with it, e.g. `%`. */
1201
1777
  unit?: string;
1202
- /** Value */
1203
- value?: number | string;
1778
+ /** The value, a number between `min` and `max`. */
1779
+ value?: number;
1780
+ /**
1781
+ * Focus its slider, as `focus()` does on a native control: the element renders
1782
+ * no box of its own to take it.
1783
+ */
1784
+ focus(options?: FocusOptions): void;
1204
1785
  addEventListener<K extends keyof CSliderElementEventMap>(type: K, listener: (this: CSliderElement, ev: CSliderElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1205
1786
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1206
1787
  removeEventListener<K extends keyof CSliderElementEventMap>(type: K, listener: (this: CSliderElement, ev: CSliderElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
@@ -1208,218 +1789,219 @@ export interface CSliderElement extends Omit<HTMLElement, 'ariaLabelInternal' |
1208
1789
  }
1209
1790
  /** A circular indeterminate activity indicator — pure motion with no value, for waits of unknown duration. */
1210
1791
  export interface CSpinnerElement extends Omit<HTMLElement, 'color' | 'size' | 'width'> {
1211
- /** Color of the spinner */
1792
+ /**
1793
+ * Stroke colour, the primary role by default; `currentColor` follows the
1794
+ * surrounding text colour.
1795
+ */
1212
1796
  color?: string;
1213
- /** Size of the spinner */
1797
+ /** Diameter in pixels. */
1214
1798
  size?: number;
1215
- /** Width of the spinner */
1799
+ /** Stroke width in pixels. */
1216
1800
  width?: number;
1217
1801
  }
1802
+ /** A status pill: a short word naming the state of a record, such as Active, Pending or Failed, tinted with the colours of its status type. */
1218
1803
  export interface CStatusElement extends Omit<HTMLElement, 'type'> {
1219
- /** Status type */
1804
+ /**
1805
+ * The status family whose tint and ink paint the pill; without it the
1806
+ * pill is neutral grey.
1807
+ */
1220
1808
  type?: 'error' | 'info' | 'success' | 'warning';
1221
1809
  }
1810
+ /** One step of a `c-steps` indicator: its label goes in the default slot, under a dot that is ringed for the current step and becomes a check mark once the step is complete. A step has no props of its own — its state follows the parent's `value`. */
1222
1811
  export interface CStepElement extends Omit<HTMLElement, 'complete' | 'current'> {
1223
- /** Mark step as complete */
1224
- complete?: boolean;
1225
- /** Mark step as current */
1226
- current?: boolean;
1227
1812
  }
1813
+ /** A step indicator for a multi-step flow: a row of `c-step` dots joined by lines, with the steps before the current one checked off and the current one ringed. */
1228
1814
  export interface CStepsElement extends Omit<HTMLElement, 'value'> {
1229
- /** Value of the accordion (current step number) */
1230
- value?: number | string;
1815
+ /** Number of the current step, counting from 1. */
1816
+ value?: number;
1817
+ }
1818
+ /** Events dispatched by `<c-sub-navigation-item>`. */
1819
+ export interface CSubNavigationItemElementEventMap {
1820
+ /**
1821
+ * Fired when the item is activated (click or Enter), carrying its `value`;
1822
+ * bubbles out of the navigation, as `c-side-navigation-item`'s does.
1823
+ */
1824
+ select: CustomEvent<{
1825
+ value: string | undefined;
1826
+ }>;
1231
1827
  }
1232
- export interface CSubNavigationItemElement extends Omit<HTMLElement, 'active' | 'focusable' | 'href' | 'loading' | 'target'> {
1233
- /** Active state */
1828
+ /** A second-level entry of a `c-side-navigation`, written inside the `c-side-navigation-item` it belongs to (no `slot` attribute needed) and shown while that parent is `active`. Activating it fires `select` with its `value` and closes the mobile drawer. It does not mark itself as the current page: set `active` on the sub-item of the page shown, and on its parent so the parent is expanded. */
1829
+ export interface CSubNavigationItemElement extends Omit<HTMLElement, 'active' | 'collapsed' | 'href' | 'loading' | 'target' | 'value'> {
1830
+ /**
1831
+ * Mark the sub-item as the current page (`aria-current="page"`); set `active`
1832
+ * on its parent item too, so the parent is expanded.
1833
+ */
1234
1834
  active?: boolean;
1235
- /** Element is visible and focusable */
1236
- focusable?: boolean;
1237
- /** Link url */
1835
+ /**
1836
+ * URL that makes the sub-item a real link; without it the sub-item is a
1837
+ * button.
1838
+ */
1238
1839
  href?: string;
1239
- /** Loading state */
1840
+ /**
1841
+ * Cover the sub-item with a loading overlay: a translucent scrim and a
1842
+ * spinner.
1843
+ */
1240
1844
  loading?: boolean;
1241
- /** Link target */
1845
+ /**
1846
+ * Where the `href` opens, as on a native `<a>`: the same tab unless set —
1847
+ * `_blank` for a new one.
1848
+ */
1242
1849
  target?: string;
1850
+ /** Value reported in the `select` event when the item is activated */
1851
+ value?: string;
1852
+ addEventListener<K extends keyof CSubNavigationItemElementEventMap>(type: K, listener: (this: CSubNavigationItemElement, ev: CSubNavigationItemElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1853
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1854
+ removeEventListener<K extends keyof CSubNavigationItemElementEventMap>(type: K, listener: (this: CSubNavigationItemElement, ev: CSubNavigationItemElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1855
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1243
1856
  }
1244
1857
  /** Events dispatched by `<c-switch>`. */
1245
1858
  export interface CSwitchElementEventMap {
1246
1859
  /**
1247
- * Standard bubbling DOM change event, re-dispatched from the host when the
1248
- * switch is toggled (the inner input's change does not cross the shadow
1249
- * boundary). No detail; read the new value from the host's `value` property.
1250
- */
1251
- change: CustomEvent<void>;
1252
- /**
1253
- * Fired when the switch is toggled, carrying the new value —
1860
+ * Fired when the user toggles the switch, carrying the new value —
1254
1861
  * `trueValue` when on, `falseValue` when off.
1255
1862
  */
1256
- changeValue: CustomEvent<boolean | number | string>;
1863
+ change: CustomEvent<boolean | number | string>;
1257
1864
  /**
1258
1865
  * Native bubbling input event fired on toggle so a plain Vue `v-model`
1259
- * works without the `v-control` directive. No detail.
1866
+ * stays in sync. No detail.
1260
1867
  */
1261
1868
  input: CustomEvent<void>;
1262
- /**
1263
- * v-model contract event fired on toggle, carrying the new value —
1264
- * `trueValue` when on, `falseValue` when off.
1265
- */
1869
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
1266
1870
  'update:value': CustomEvent<boolean | number | string>;
1267
1871
  }
1268
- /** A toggle for a binary setting that takes effect immediately: a native switch control with a label, an optional hint, and validation messaging. */
1269
- export interface CSwitchElement extends Omit<HTMLElement, 'checked' | 'disabled' | 'falseValue' | 'hostId' | 'label' | 'loading' | 'required' | 'trueValue' | 'value'> {
1270
- /** If `true`, the checkbox is selected. */
1872
+ /** A toggle for a binary setting that takes effect immediately: a native switch control with a label. */
1873
+ export interface CSwitchElement extends Omit<HTMLElement, 'checked' | 'disabled' | 'falseValue' | 'label' | 'loading' | 'required' | 'trueValue' | 'value'> {
1874
+ /**
1875
+ * Whether the switch is on: the boolean view of `value`. Setting it sets
1876
+ * `value` to `trueValue` or `falseValue`; reading it reports whether
1877
+ * `value` equals `trueValue`. As an attribute it sets the initial state when
1878
+ * no `value` is bound.
1879
+ */
1271
1880
  checked?: boolean;
1272
1881
  /** If `true`, the switch is disabled and cannot be toggled */
1273
1882
  disabled?: boolean;
1274
- /** The value when the checkbox is unchecked */
1883
+ /** The value when the switch is off */
1275
1884
  falseValue?: boolean | number | string;
1276
- /** Id for the element */
1277
- hostId?: string;
1278
1885
  /**
1279
1886
  * Label of the switch, shown beside the toggle. Falls back to the default
1280
1887
  * slot content when not set.
1281
1888
  */
1282
1889
  label?: string;
1283
- /** Loading state */
1890
+ /**
1891
+ * Show a spinner in place of the handle, such as while the change is
1892
+ * saved. The switch ignores toggles meanwhile and is announced as busy
1893
+ */
1284
1894
  loading?: boolean;
1285
- /** Set as required */
1895
+ /** Set as required — shows the required marker on the label */
1286
1896
  required?: boolean;
1287
- /** The value when the checkbox is checked */
1897
+ /** The value when the switch is on */
1288
1898
  trueValue?: boolean | number | string;
1289
1899
  /**
1290
- * The input value
1291
- * - Only used when the checkbox participates in a native `<form>`
1900
+ * The switch's state: `trueValue` while it is on, `falseValue` while it is
1901
+ * off. A bound value wins over a `checked` attribute; any other value,
1902
+ * `''` included, reads as off.
1292
1903
  */
1293
- value?: boolean | number | string;
1904
+ value?: string | number | boolean;
1905
+ /**
1906
+ * Focus its switch, as `focus()` does on a native control: the element renders
1907
+ * no box of its own to take it.
1908
+ */
1909
+ focus(options?: FocusOptions): void;
1294
1910
  addEventListener<K extends keyof CSwitchElementEventMap>(type: K, listener: (this: CSwitchElement, ev: CSwitchElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1295
1911
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1296
1912
  removeEventListener<K extends keyof CSwitchElementEventMap>(type: K, listener: (this: CSwitchElement, ev: CSwitchElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1297
1913
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1298
1914
  }
1299
- /** Events dispatched by `<c-tab>`. */
1300
- export interface CTabElementEventMap {
1915
+ /** One tab in the row of a `c-tabs`: its label goes in the default slot (a `c-badge` there sits on the tab's corner), and its `value` names the `c-tab-item` panel it shows. `c-tabs` decides which tab is active; `disabled` keeps a tab from being selected. */
1916
+ export interface CTabElement extends Omit<HTMLElement, 'active' | 'disabled' | 'tabStop' | 'value'> {
1301
1917
  /**
1302
- * Fired when the tab is activated (click, or Space/Enter), carrying the tab
1303
- * element and its value; the parent `<c-tabs>` listens for it to switch the
1304
- * active tab.
1918
+ * Grey the tab out and keep it from being selected by pointer or keyboard;
1919
+ * the arrow keys skip it.
1305
1920
  */
1306
- tabChange: CustomEvent<{
1307
- element: HTMLElement | null;
1308
- value: number | string | undefined;
1309
- }>;
1310
- /**
1311
- * Fired when the tab receives focus, so the parent `<c-tabs>` can drive
1312
- * arrow-key navigation.
1313
- */
1314
- tabFocus: CustomEvent<number | string | undefined>;
1315
- }
1316
- export interface CTabElement extends Omit<HTMLElement, 'active' | 'disabled' | 'hostId' | 'position' | 'setsize' | 'value'> {
1317
- /** Mark tab as active */
1318
- active?: boolean;
1319
- /** Mark tab as disabled */
1320
1921
  disabled?: boolean;
1321
- /** Id of the tab */
1322
- hostId?: string;
1323
- /** Position in the set */
1324
- position?: number;
1325
- /** Size of the set */
1326
- setsize?: number;
1327
1922
  /**
1328
- * Value for the tab
1329
- * - for use in c-tabs
1923
+ * Value of the tab, matching the `value` of the `c-tab-item` panel it shows;
1924
+ * `c-tabs` holds it as its `value` while this tab is active.
1330
1925
  */
1331
1926
  value?: number | string;
1332
- addEventListener<K extends keyof CTabElementEventMap>(type: K, listener: (this: CTabElement, ev: CTabElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1333
- addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1334
- removeEventListener<K extends keyof CTabElementEventMap>(type: K, listener: (this: CTabElement, ev: CTabElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1335
- removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1336
- }
1337
- /** Events dispatched by `<c-tab-buttons>`. */
1338
- export interface CTabButtonsElementEventMap {
1339
- /**
1340
- * Fired when the user activates a tab button, carrying the newly selected
1341
- * value. The parent `<c-tabs>` listens for it and pushes the accepted value
1342
- * back down; consumers should listen to `c-tabs` instead.
1343
- */
1344
- tabChange: CustomEvent<{
1345
- element: HTMLElement | null;
1346
- value: number | string;
1347
- }>;
1348
1927
  }
1349
1928
  /** Tab buttons present a `c-tabs` tab list as a segmented control instead of the underlined tab row. Author it only inside `<c-tabs>`, with plain `<c-button>` children whose `value`s match the `c-tab-item` panels; `c-tabs` owns the active value and pushes it down. */
1350
1929
  export interface CTabButtonsElement extends Omit<HTMLElement, 'disabled' | 'size' | 'value'> {
1351
1930
  /** Disable the whole tab strip — every slotted c-button is disabled and the selection can no longer be changed. */
1352
1931
  disabled?: boolean;
1353
- /** Size of the buttons */
1932
+ /** Size of the buttons: `default`, or the more compact `small`. */
1354
1933
  size?: 'default' | 'small';
1355
- /** Value of the active tab — pushed down by the parent c-tabs. */
1356
- value?: number | string;
1357
- addEventListener<K extends keyof CTabButtonsElementEventMap>(type: K, listener: (this: CTabButtonsElement, ev: CTabButtonsElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1358
- addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1359
- removeEventListener<K extends keyof CTabButtonsElementEventMap>(type: K, listener: (this: CTabButtonsElement, ev: CTabButtonsElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1360
- removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1361
1934
  }
1362
- /** Events dispatched by `<c-tab-item>`. */
1363
- export interface CTabItemElementEventMap {
1935
+ /** One tab panel inside `c-tab-items`, shown while its `value` equals the `value` of `c-tabs` — give it the same `value` as its `c-tab`. Inactive panels stay in the DOM, hidden, so their content keeps its state across tab switches. */
1936
+ export interface CTabItemElement extends Omit<HTMLElement, 'active' | 'value'> {
1364
1937
  /**
1365
- * Fired whenever the panel's content is resized, so the parent
1366
- * `<c-tab-items>` can re-measure and keep the slide position correct.
1938
+ * Value of the panel, the same as its `c-tab`'s; the panel shows while the
1939
+ * `value` of `c-tabs` equals it.
1367
1940
  */
1368
- contentChange: CustomEvent<void>;
1369
- }
1370
- export interface CTabItemElement extends Omit<HTMLElement, 'active' | 'value'> {
1371
- /** Active */
1372
- active?: boolean;
1373
- /** Tab value */
1374
1941
  value?: number | string;
1375
- addEventListener<K extends keyof CTabItemElementEventMap>(type: K, listener: (this: CTabItemElement, ev: CTabItemElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1376
- addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1377
- removeEventListener<K extends keyof CTabItemElementEventMap>(type: K, listener: (this: CTabItemElement, ev: CTabItemElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1378
- removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1379
1942
  }
1943
+ /** The panel container of a `c-tabs`: slot it in with `slot="items"` and put the `c-tab-item` panels inside it. It shows the panel whose `value` matches the tabs' value and slides between panels; it has no props of its own, as `c-tabs` drives it. */
1380
1944
  export interface CTabItemsElement extends Omit<HTMLElement, 'disableAnimation' | 'value'> {
1381
- /** Disable animation */
1382
- disableAnimation?: boolean;
1383
- /** Currently active tab */
1384
- value?: number | string;
1385
1945
  }
1386
1946
  /** A styled wrapper for a table you author yourself: slot in a plain `<table>` and c-table gives it the CSC look plus an optional responsive card layout on narrow screens. The table stays in your own DOM — your stylesheets, your framework's rendering, and `::part()` selectors on components nested in cells (a `c-tag` status chip, a `c-pagination` footer) all keep working. */
1387
1947
  export interface CTableElement extends Omit<HTMLElement, 'mobileBreakpoint' | 'responsive'> {
1388
- /** Mobile breakpoint in pixels */
1948
+ /**
1949
+ * The table's width, in pixels, at or below which a `responsive` table
1950
+ * stacks its rows into cards.
1951
+ */
1389
1952
  mobileBreakpoint?: number;
1390
- /** Should the table be responsive */
1953
+ /**
1954
+ * Stacks the rows into cards, each cell labelled with its column header,
1955
+ * while the table is no wider than `mobile-breakpoint`.
1956
+ */
1391
1957
  responsive?: boolean;
1958
+ /**
1959
+ * Re-read the header cells into the narrow layout's row labels, after the
1960
+ * table's rows or headers changed from code.
1961
+ */
1962
+ updateMobileLabels(): void;
1392
1963
  }
1393
1964
  /** Events dispatched by `<c-tabs>`. */
1394
1965
  export interface CTabsElementEventMap {
1395
1966
  /**
1396
- * Fired when the user activates a tab (click, or Enter/Space on a focused
1397
- * tab), carrying the newly selected tab value. Legacy value-change event.
1967
+ * Fired when the user activates another tab (click, or Enter/Space on a
1968
+ * focused tab), carrying the newly selected tab value.
1398
1969
  */
1399
- changeValue: CustomEvent<number | string>;
1970
+ change: CustomEvent<number | string>;
1400
1971
  /** Native bubbling input event dispatched for plain `v-model` support; carries no detail. */
1401
1972
  input: CustomEvent<void>;
1402
- /**
1403
- * Fired alongside `changeValue` with the newly selected tab value; fulfills
1404
- * the `v-model`/`v-control` contract.
1405
- */
1973
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
1406
1974
  'update:value': CustomEvent<number | string>;
1407
1975
  }
1976
+ /** A tab set that switches between panels of related content: a row of `c-tab` headers above the `c-tab-item` panels, one panel shown at a time. */
1408
1977
  export interface CTabsElement extends Omit<HTMLElement, 'borderless' | 'disableAnimation' | 'justify' | 'mobileBreakpoint' | 'value' | 'vertical'> {
1409
- /** Disable the bottom border */
1978
+ /** Remove the line along the tab row. */
1410
1979
  borderless?: boolean;
1411
- /** Disable animation */
1980
+ /**
1981
+ * Switch off the underline's glide and the panels' slide; both also stop
1982
+ * under the reduced-motion preference.
1983
+ */
1412
1984
  disableAnimation?: boolean;
1413
- /** Justification of the children */
1985
+ /**
1986
+ * Placement of the tabs along the row: `stretch` grows them to fill it;
1987
+ * `start`, `center` and `end` keep each tab at its own width. No effect on
1988
+ * `vertical` tabs.
1989
+ */
1414
1990
  justify?: 'center' | 'end' | 'start' | 'stretch';
1415
1991
  /**
1416
- * Mobile breakpoint in pixels
1417
- * - affects the content stacking with the vertical tabs
1992
+ * Width in pixels of the `c-tabs` element (not the viewport) below which
1993
+ * `vertical` tabs move above the panels. No effect on horizontal tabs.
1418
1994
  */
1419
1995
  mobileBreakpoint?: number;
1420
- /** Currently active tab */
1996
+ /**
1997
+ * Value of the active tab: the `c-tab` and the `c-tab-item` with the same
1998
+ * `value` are shown. With no match, no tab is active and no panel is shown.
1999
+ */
1421
2000
  value?: number | string;
1422
- /** Vertical tabs */
2001
+ /**
2002
+ * Stack the tabs in a column beside the panels, which slide vertically; below
2003
+ * `mobile-breakpoint` the column moves above the panels.
2004
+ */
1423
2005
  vertical?: boolean;
1424
2006
  addEventListener<K extends keyof CTabsElementEventMap>(type: K, listener: (this: CTabsElement, ev: CTabsElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1425
2007
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
@@ -1431,67 +2013,92 @@ export interface CTagElementEventMap {
1431
2013
  /** Fired when the tag's close button is activated. */
1432
2014
  close: CustomEvent<void>;
1433
2015
  }
1434
- export interface CTagElement extends Omit<HTMLElement, 'active' | 'badge' | 'closeable' | 'flat' | 'size'> {
1435
- /** Mark tag as active */
2016
+ /** A pill-shaped tag naming one item — a keyword, a category, an applied filter — authored inside `c-tags`, or on its own where a single tag is needed, such as a status in a table cell. With `closeable` it shows a close button that fires `close` and leaves removing the tag to you; name that button with `close-label`, for example "Remove Chemistry". */
2017
+ export interface CTagElement extends Omit<HTMLElement, 'active' | 'badge' | 'closeable' | 'closeLabel' | 'flat' | 'size'> {
2018
+ /**
2019
+ * Paint the filled, selected look, announced as the pressed state of a
2020
+ * plain tag. The tag never sets it itself: toggle it on `click`
2021
+ */
1436
2022
  active?: boolean;
1437
- /** Display an optional badge at the start of the tag */
2023
+ /** A number or short text shown in a small pill at the start of the tag */
1438
2024
  badge?: null | number | string;
1439
- /** Mark tag as closeable */
2025
+ /**
2026
+ * Add a close button that fires `close`; removing the tag stays your job.
2027
+ * The button, not the tag, is then the Tab stop
2028
+ */
1440
2029
  closeable?: boolean;
1441
- /** Remove the hover effect */
2030
+ /** Accessible name of the close button rendered when `closeable` */
2031
+ closeLabel?: string;
2032
+ /**
2033
+ * Make the tag a plain label: no hover effect, not a button, and out of
2034
+ * the Tab order
2035
+ */
1442
2036
  flat?: boolean;
1443
- /** Size of the tag */
2037
+ /**
2038
+ * Size of the tag: `small` renders a compact pill. Inside `c-tags`, the
2039
+ * group's `size` overrides it
2040
+ */
1444
2041
  size?: 'default' | 'small';
1445
2042
  addEventListener<K extends keyof CTagElementEventMap>(type: K, listener: (this: CTagElement, ev: CTagElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1446
2043
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1447
2044
  removeEventListener<K extends keyof CTagElementEventMap>(type: K, listener: (this: CTagElement, ev: CTagElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1448
2045
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1449
2046
  }
2047
+ /** A group of `c-tag` elements laid out in a wrapping row, with an optional group label above them. */
1450
2048
  export interface CTagsElement extends Omit<HTMLElement, 'label' | 'required' | 'size'> {
1451
2049
  /** Label of the tag group, shown above the tags */
1452
2050
  label?: string;
1453
2051
  /** Set as required — shows the required marker on the label */
1454
2052
  required?: boolean;
1455
- /** Size of the tags */
2053
+ /**
2054
+ * Size of every tag in the group: `small` renders them compact. Overrides
2055
+ * each tag's own `size`
2056
+ */
1456
2057
  size?: 'default' | 'small';
1457
2058
  }
1458
2059
  /** Events dispatched by `<c-text-field>`. */
1459
2060
  export interface CTextFieldElementEventMap {
1460
2061
  /**
1461
- * Standard bubbling DOM change event, re-dispatched from the host when the
1462
- * inner input/textarea fires its native change (which does not cross the
1463
- * shadow boundary). No detail; read the current text from the host's
1464
- * `value` property.
2062
+ * Fired when typed text is committed — Enter, or leaving the field after
2063
+ * editing it — carrying the text, trimmed when `trim-whitespace` is set.
1465
2064
  */
1466
- change: CustomEvent<void>;
1467
- /**
1468
- * Fired on every keystroke (and on native change), carrying the current
1469
- * text — trimmed when `trim-whitespace` is set.
1470
- */
1471
- changeValue: CustomEvent<string>;
2065
+ change: CustomEvent<string>;
1472
2066
  /**
1473
2067
  * Native bubbling input event fired alongside every value change so a
1474
- * plain Vue `v-model` works without the `v-control` directive. No detail.
2068
+ * plain Vue `v-model` stays in sync. No detail.
1475
2069
  */
1476
2070
  input: CustomEvent<void>;
1477
2071
  /**
1478
- * v-model contract event fired on every keystroke (and on native change),
1479
- * carrying the current text — trimmed when `trim-whitespace` is set.
2072
+ * v-model contract event fired on every keystroke, carrying the current
2073
+ * text — trimmed when `trim-whitespace` is set.
1480
2074
  */
1481
2075
  'update:value': CustomEvent<string>;
1482
2076
  }
1483
- export interface CTextFieldElement extends Omit<HTMLElement, 'autocomplete' | 'autocorrect' | 'automaticCapitalize' | 'disabled' | 'errorMessage' | 'hideDetails' | 'hint' | 'hostId' | 'label' | 'labelOnTop' | 'max' | 'min' | 'name' | 'placeholder' | 'readonly' | 'required' | 'rows' | 'shadow' | 'size' | 'step' | 'trimWhitespace' | 'type' | 'valid' | 'value'> {
1484
- /** HTML input autocomplete */
2077
+ /** A text field for a single line of text, or several lines under `rows`, with a label, a hint and an error message. */
2078
+ export interface CTextFieldElement extends Omit<HTMLElement, 'autocapitalize' | 'autocomplete' | 'autocorrect' | 'autofocus' | 'disabled' | 'errorMessage' | 'hideDetails' | 'hint' | 'invalid' | 'label' | 'labelOnTop' | 'mask' | 'max' | 'min' | 'name' | 'placeholder' | 'readonly' | 'required' | 'rows' | 'shadow' | 'size' | 'step' | 'trimWhitespace' | 'type' | 'value'> {
2079
+ /**
2080
+ * How on-screen keyboards capitalize typed text, as the native
2081
+ * `autocapitalize` attribute; unset leaves the browser's default
2082
+ */
2083
+ autocapitalize?: 'characters' | 'none' | 'off' | 'on' | 'sentences' | 'words';
2084
+ /**
2085
+ * The browser's autofill hint, as the native `autocomplete` attribute
2086
+ * (`email`, `new-password`, `off`…)
2087
+ */
1485
2088
  autocomplete?: string;
1486
2089
  /**
1487
2090
  * Enable native input autocorrection (Safari). Maps to the input's
1488
2091
  * `autocorrect="on"`/`"off"` attribute; left unset (browser default per
1489
- * input type) when not specified. Mirrors the platform
2092
+ * input type) when not specified. The attribute takes the native values
2093
+ * (`autocorrect="off"`), the property also the platform's
1490
2094
  * `HTMLElement.autocorrect` boolean.
1491
2095
  */
1492
- autocorrect?: boolean;
1493
- /** HTML input autocapitalize */
1494
- automaticCapitalize?: 'characters' | 'none' | 'off' | 'on' | 'sentences' | 'words';
2096
+ autocorrect?: 'off' | 'on' | boolean;
2097
+ /**
2098
+ * Focus the input when the field mounts, as the native `autofocus` does —
2099
+ * which is not honoured inside a shadow root.
2100
+ */
2101
+ autofocus?: boolean;
1495
2102
  /** Disable the input */
1496
2103
  disabled?: boolean;
1497
2104
  /** Error message shown in place of the hint while the input is invalid */
@@ -1500,78 +2107,224 @@ export interface CTextFieldElement extends Omit<HTMLElement, 'autocomplete' | 'a
1500
2107
  hideDetails?: boolean;
1501
2108
  /** Hint text for the input */
1502
2109
  hint?: string;
1503
- /** Id of the input */
1504
- hostId?: string;
2110
+ /**
2111
+ * Show the control as invalid: its `error-message`, when set, replaces the
2112
+ * hint, and the control is marked `aria-invalid`.
2113
+ */
2114
+ invalid?: boolean;
1505
2115
  /** Label of the input */
1506
2116
  label?: string;
1507
2117
  /** Label on top of the input */
1508
2118
  labelOnTop?: boolean;
1509
- /** Maximum value on a numeric input */
2119
+ /** Input mask the typed text follows: `#` a digit, `A` a letter, `*` a letter or a digit, `\` escapes the next character, `[…]` wraps a trailing optional section, anything else is a literal. Applies to a single-line `text`, `tel` or `search` field */
2120
+ mask?: string;
2121
+ /** Largest value of a `type="number"` field, as the native `max` attribute */
1510
2122
  max?: null | number;
1511
- /** Minimum value on a numeric input */
2123
+ /** Smallest value of a `type="number"` field, as the native `min` attribute */
1512
2124
  min?: null | number;
1513
- /** Name of the input */
2125
+ /**
2126
+ * `name` of the inner input. The component is not form-associated, so it
2127
+ * does not submit with a `<form>`.
2128
+ */
1514
2129
  name?: string;
1515
- /** Placeholder of the input */
2130
+ /**
2131
+ * Placeholder of the input. Beside a floating `label` it shows only while
2132
+ * the field is focused; under a `mask` it replaces the mask guide
2133
+ */
1516
2134
  placeholder?: string;
1517
- /** Mark as readonly */
2135
+ /**
2136
+ * Make the input read-only: its text can be selected and copied but not
2137
+ * edited
2138
+ */
1518
2139
  readonly?: boolean;
1519
2140
  /** Set the input as required */
1520
2141
  required?: boolean;
1521
- /** Rows on the input */
2142
+ /**
2143
+ * Number of text lines the field shows; above `1` it becomes a multi-line
2144
+ * textarea
2145
+ */
1522
2146
  rows?: number;
1523
- /** Shadow variant of the input */
2147
+ /** Draw the field as a raised, drop-shadowed box instead of an outlined one */
1524
2148
  shadow?: boolean;
1525
- /** Field height: the 44px default or the 36px `small` box (single-line fields) */
2149
+ /** Field height: the 52px default (the shared control height) or the 36px `small` box (single-line fields) */
1526
2150
  size?: 'default' | 'small';
1527
- /** Step size on a numeric input */
2151
+ /** Step of a `type="number"` field, as the native `step` attribute */
1528
2152
  step?: null | number;
1529
- /** Trim whitespace from the return value */
2153
+ /**
2154
+ * Trim leading and trailing whitespace from the emitted text, and from the
2155
+ * shown text when the field is left
2156
+ */
1530
2157
  trimWhitespace?: boolean;
1531
- /** Type of the input */
2158
+ /**
2159
+ * The native input type: `password` adds a toggle that reveals the text,
2160
+ * `date` a button that opens the browser's date picker, and `number` honours
2161
+ * `min`, `max` and `step`
2162
+ */
1532
2163
  type?: 'date' | 'email' | 'number' | 'password' | 'search' | 'tel' | 'text' | 'url';
1533
- /** Set the validity of the input */
1534
- valid?: boolean;
1535
- /** Value of the input */
2164
+ /**
2165
+ * The text in the field; under a `mask`, the text as shown, literals
2166
+ * included
2167
+ */
1536
2168
  value?: string;
2169
+ /** Whether a masked field has every mask token filled (always `true` without a mask) */
2170
+ readonly maskComplete: boolean;
2171
+ /** The text without the mask's literals: only the characters filling its tokens (the text as is without a mask) */
2172
+ readonly unmaskedValue: string;
2173
+ /**
2174
+ * Focus its input, as `focus()` does on a native control: the element renders
2175
+ * no box of its own to take it.
2176
+ */
2177
+ focus(options?: FocusOptions): void;
1537
2178
  addEventListener<K extends keyof CTextFieldElementEventMap>(type: K, listener: (this: CTextFieldElement, ev: CTextFieldElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1538
2179
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1539
2180
  removeEventListener<K extends keyof CTextFieldElementEventMap>(type: K, listener: (this: CTextFieldElement, ev: CTextFieldElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1540
2181
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1541
2182
  }
1542
- /** Events dispatched by `<c-toast>`. */
1543
- export interface CToastElementEventMap {
2183
+ /** Events dispatched by `<c-time-picker>`. */
2184
+ export interface CTimePickerElementEventMap {
1544
2185
  /**
1545
- * Fired once the toast's leave transition has finished (after a manual
1546
- * dismiss or the auto-close timer), carrying the dismissed toast's message
1547
- * object.
2186
+ * Fired when the value changes — a row is picked or moved to in a column,
2187
+ * typed text is committed, or the field is cleared — carrying the new
2188
+ * value: an ISO `HH:mm` time, `{ start, end }` under `range`, or `null`.
1548
2189
  */
1549
- close: CustomEvent<CToastMessage | null>;
2190
+ change: CustomEvent<CTimePickerValue>;
2191
+ /**
2192
+ * Fired on every commit of typed text (Enter or leaving the input) with the
2193
+ * text as typed — `{ start, end }` under `range`. Read `badInput` to tell
2194
+ * whether it named a time that can be picked.
2195
+ */
2196
+ 'change:text': CustomEvent<CTimePickerText>;
2197
+ /**
2198
+ * Native bubbling input event dispatched alongside every value change so a
2199
+ * plain `v-model` stays in sync. Carries no detail.
2200
+ */
2201
+ input: CustomEvent<void>;
2202
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
2203
+ 'update:value': CustomEvent<CTimePickerValue>;
1550
2204
  }
1551
- /** A single toast notification, rendered and managed by c-toasts */
1552
- export interface CToastElement extends Omit<HTMLElement, 'message'> {
1553
- /** Messages */
1554
- message?: CToastMessage | null;
1555
- closeToast(): void;
1556
- addEventListener<K extends keyof CToastElementEventMap>(type: K, listener: (this: CToastElement, ev: CToastElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
2205
+ /** A time field that takes a typed time, or opens hour and minute columns for picking one, or a start and end time under `range`. */
2206
+ export interface CTimePickerElement extends Omit<HTMLElement, 'clearable' | 'disabled' | 'errorMessage' | 'format' | 'hideDetails' | 'hint' | 'invalid' | 'label' | 'labelOnTop' | 'max' | 'min' | 'minuteStep' | 'name' | 'placeholder' | 'range' | 'required' | 'shadow' | 'showNow' | 'size' | 'texts' | 'value'> {
2207
+ /** Make the value clearable */
2208
+ clearable?: boolean;
2209
+ /** Disable the field */
2210
+ disabled?: boolean;
2211
+ /** Error message shown in place of the hint while the field is invalid */
2212
+ errorMessage?: string;
2213
+ /**
2214
+ * How times are shown and read from typing: a pattern of the tokens `H`,
2215
+ * `HH` (24-hour), `h`, `hh` (12-hour, with the period `a`) and `mm` with
2216
+ * any separators, e.g. `HH:mm` or `h:mm a`
2217
+ */
2218
+ format?: string;
2219
+ /** Hide the hint and error messages */
2220
+ hideDetails?: boolean;
2221
+ /** Hint text for the field */
2222
+ hint?: string;
2223
+ /**
2224
+ * Show the control as invalid: its `error-message`, when set, replaces the
2225
+ * hint, and the control is marked `aria-invalid`.
2226
+ */
2227
+ invalid?: boolean;
2228
+ /** Element label */
2229
+ label?: string;
2230
+ /** Label on top of the field */
2231
+ labelOnTop?: boolean;
2232
+ /** The latest time that can be picked or typed, as an ISO `HH:mm` time */
2233
+ max?: string;
2234
+ /**
2235
+ * The earliest time that can be picked or typed, as an ISO `HH:mm` time;
2236
+ * a `min` after `max` is invalid and both are ignored
2237
+ */
2238
+ min?: string;
2239
+ /**
2240
+ * Minutes between the minute column's rows; typed times need not fall on
2241
+ * the step
2242
+ */
2243
+ minuteStep?: number;
2244
+ /** Input field name */
2245
+ name?: string;
2246
+ /** Placeholder of the input; the `format` pattern when empty */
2247
+ placeholder?: string;
2248
+ /**
2249
+ * Pick a range: the value becomes `{ start, end }` and the field holds two
2250
+ * inputs
2251
+ */
2252
+ range?: boolean;
2253
+ /** Set the field as required */
2254
+ required?: boolean;
2255
+ /** Shadow variant */
2256
+ shadow?: boolean;
2257
+ /** Show a Now button under the columns that commits the current time */
2258
+ showNow?: boolean;
2259
+ /** Field height: the 52px default (the shared control height) or the 36px `small` box */
2260
+ size?: 'default' | 'small';
2261
+ /**
2262
+ * UI text overrides (i18n), merged over the AM/PM texts `Intl` gives for
2263
+ * the page's `lang` and the English defaults. Objects have no attribute
2264
+ * form — bind as a DOM property
2265
+ */
2266
+ texts?: CTimePickerTexts;
2267
+ /**
2268
+ * The time as an ISO `HH:mm` string on a 24-hour clock, or `{ start, end }`
2269
+ * under `range`; `null` when empty
2270
+ */
2271
+ value?: CTimePickerValue;
2272
+ /** Whether the committed text names no time that can be picked — the value is then `null` (CONTEXT.md "Bad input"). */
2273
+ readonly badInput: boolean;
2274
+ /**
2275
+ * Focus its input (the start input under `range`), as `focus()` does on a native control: the element renders
2276
+ * no box of its own to take it.
2277
+ */
2278
+ focus(options?: FocusOptions): void;
2279
+ addEventListener<K extends keyof CTimePickerElementEventMap>(type: K, listener: (this: CTimePickerElement, ev: CTimePickerElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
1557
2280
  addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
1558
- removeEventListener<K extends keyof CToastElementEventMap>(type: K, listener: (this: CToastElement, ev: CToastElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
2281
+ removeEventListener<K extends keyof CTimePickerElementEventMap>(type: K, listener: (this: CTimePickerElement, ev: CTimePickerElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1559
2282
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1560
2283
  }
1561
- /** Toasts are passive, transient notifications — operation results, background progress — stacked and managed by a single `c-toasts` container via its `addToast` / `removeToast` methods. */
2284
+ /** Events dispatched by `<c-toasts>`. */
2285
+ export interface CToastsElementEventMap {
2286
+ /**
2287
+ * Fired once a toast has left (closed by its close button, a swipe, the
2288
+ * timer or `removeToast`), carrying its message with the `id` it was
2289
+ * shown under.
2290
+ */
2291
+ close: CustomEvent<CToastMessage>;
2292
+ }
2293
+ /** Toasts are passive, transient notifications — operation results, background progress — stacked and managed by a single `c-toasts` container via its `addToast` / `removeToast` methods. `addToast` returns the message's `id` (its own, or a generated one), which `removeToast` takes; `close` fires on the container with the message once a toast has left. */
1562
2294
  export interface CToastsElement extends Omit<HTMLElement, 'absolute' | 'horizontal' | 'vertical'> {
1563
- /** Use absolute positioning */
2295
+ /**
2296
+ * Places the stack in its nearest positioned ancestor instead of the
2297
+ * viewport, for in-container notifications. Such a stack is not
2298
+ * guaranteed to paint above an open modal.
2299
+ */
1564
2300
  absolute?: boolean;
1565
- /** Horizontal position */
2301
+ /**
2302
+ * Where the stack sits across the viewport, or across its container
2303
+ * under `absolute`.
2304
+ */
1566
2305
  horizontal?: 'center' | 'left' | 'right';
1567
- /** Vertical position */
2306
+ /** The edge the stack is anchored to; toasts slide in from it. */
1568
2307
  vertical?: 'bottom' | 'top';
1569
- /** Add a new message */
1570
- addToast(message: CToastMessage): void;
1571
- /** Remove a message by id (id should be specified in the addToast params) */
2308
+ /**
2309
+ * Show a message as a toast and return its `id` — the message's own, or a
2310
+ * generated one — for `removeToast`. A second `custom` message while one is
2311
+ * shown is refused, and returns `undefined`.
2312
+ */
2313
+ addToast(message: CToastMessage): string | undefined;
2314
+ /** Close the toast with this `id`, the one `addToast` returned. */
1572
2315
  removeToast(id: string): void;
2316
+ addEventListener<K extends keyof CToastsElementEventMap>(type: K, listener: (this: CToastsElement, ev: CToastsElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
2317
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
2318
+ removeEventListener<K extends keyof CToastsElementEventMap>(type: K, listener: (this: CToastsElement, ev: CToastsElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
2319
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1573
2320
  }
1574
- export interface CToolbarElement extends HTMLElement {
2321
+ /** The app-wide bar at the top of the dashboard layout: the logo, the service name and global actions such as the user menu or log out. It is pinned to the top of the viewport by default and stays there while the page scrolls; `static` keeps it in the page flow so it scrolls away with the content. */
2322
+ export interface CToolbarElement extends Omit<HTMLElement, 'static'> {
2323
+ /**
2324
+ * Keep the toolbar in the page flow so it scrolls away with the content
2325
+ * instead of staying pinned to the top of its scroll container
2326
+ */
2327
+ static?: boolean;
1575
2328
  }
1576
2329
  /** Events dispatched by `<c-tooltip>`. */
1577
2330
  export interface CTooltipElementEventMap {
@@ -1590,9 +2343,9 @@ export interface CTooltipElement extends Omit<HTMLElement, 'delay' | 'distance'
1590
2343
  * shows the tooltip immediately, regardless of this value. Defaults to
1591
2344
  * `400`.
1592
2345
  */
1593
- delay?: number | string;
2346
+ delay?: number;
1594
2347
  /** Distance from the trigger to the tooltip, in pixels. Defaults to `4`. */
1595
- distance?: number | string;
2348
+ distance?: number;
1596
2349
  /** Whether the tooltip is open. Two-way: emits `change:open`. */
1597
2350
  open?: boolean;
1598
2351
  /** Preferred placement of the tooltip relative to the trigger. */
@@ -1616,6 +2369,149 @@ export interface CTooltipElement extends Omit<HTMLElement, 'delay' | 'distance'
1616
2369
  removeEventListener<K extends keyof CTooltipElementEventMap>(type: K, listener: (this: CTooltipElement, ev: CTooltipElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
1617
2370
  removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
1618
2371
  }
2372
+ /** Events dispatched by `<c-tree-select>`. */
2373
+ export interface CTreeSelectElementEventMap {
2374
+ /**
2375
+ * Fired when the selection changes — an item is committed or the selection
2376
+ * is cleared — carrying the new value: the item's value, the
2377
+ * `CTreeSelectSelection` with `return-object`, or `null` when cleared.
2378
+ */
2379
+ change: CustomEvent<CTreeSelectValue>;
2380
+ /**
2381
+ * Fired whenever the query changes — on every keystroke in the search
2382
+ * input, and with an empty string when the panel opens. Carries the query
2383
+ * string.
2384
+ */
2385
+ 'change:query': CustomEvent<string>;
2386
+ /**
2387
+ * Native bubbling input event dispatched alongside every value change so a
2388
+ * plain `v-model` stays in sync. Carries no detail.
2389
+ */
2390
+ input: CustomEvent<void>;
2391
+ /** Fired alongside `change` with the same detail — the `v-model` contract. */
2392
+ 'update:value': CustomEvent<CTreeSelectValue>;
2393
+ }
2394
+ /** A hierarchical value-selection component: a readonly value field that opens a panel for browsing a tree one level at a time, or searching it as a whole, to commit one item. */
2395
+ export interface CTreeSelectElement extends Omit<HTMLElement, 'allowBranch' | 'clearable' | 'disabled' | 'errorMessage' | 'filter' | 'hideDetails' | 'hint' | 'invalid' | 'items' | 'itemsPerPage' | 'label' | 'labelOnTop' | 'levelLabels' | 'name' | 'placeholder' | 'required' | 'returnObject' | 'shadow' | 'size' | 'texts' | 'value'> {
2396
+ /**
2397
+ * Let a branch be committed as the value: a pinned select-branch row heads
2398
+ * every level below the root, and matching branches are listed as search
2399
+ * results
2400
+ */
2401
+ allowBranch?: boolean;
2402
+ /** Make the selected value clearable */
2403
+ clearable?: boolean;
2404
+ /** Disable the field */
2405
+ disabled?: boolean;
2406
+ /** Error message shown in place of the hint while the field is invalid */
2407
+ errorMessage?: string;
2408
+ /**
2409
+ * Custom search predicate; receives the item, the query and the item's
2410
+ * ancestors. Functions have no attribute form — bind as a DOM property
2411
+ */
2412
+ filter?: CTreeSelectFilter;
2413
+ /** Hide the hint and error messages */
2414
+ hideDetails?: boolean;
2415
+ /** Hint text for the field */
2416
+ hint?: string;
2417
+ /**
2418
+ * Show the control as invalid: its `error-message`, when set, replaces the
2419
+ * hint, and the control is marked `aria-invalid`.
2420
+ */
2421
+ invalid?: boolean;
2422
+ /**
2423
+ * The tree to pick from. Arrays have no attribute form — bind as a DOM
2424
+ * property (`:items.prop` in Vue)
2425
+ */
2426
+ items?: CTreeSelectItem[];
2427
+ /** Items per page before the list scrolls */
2428
+ itemsPerPage?: number;
2429
+ /** Element label */
2430
+ label?: string;
2431
+ /** Label on top of the field */
2432
+ labelOnTop?: boolean;
2433
+ /**
2434
+ * Names of the levels, top level first, shown in the panel header; a
2435
+ * missing entry falls back to `texts.level(n)`. Arrays have no attribute
2436
+ * form — bind as a DOM property
2437
+ */
2438
+ levelLabels?: string[];
2439
+ /** Input field name */
2440
+ name?: string;
2441
+ /** Placeholder for the search input inside the panel */
2442
+ placeholder?: string;
2443
+ /** Set the field as required */
2444
+ required?: boolean;
2445
+ /**
2446
+ * Emit the committed item with its path as a `CTreeSelectSelection` instead
2447
+ * of its value
2448
+ */
2449
+ returnObject?: boolean;
2450
+ /** Shadow variant */
2451
+ shadow?: boolean;
2452
+ /** Field height: the 52px default (the shared control height) or the 36px `small` box */
2453
+ size?: 'default' | 'small';
2454
+ /**
2455
+ * UI text overrides (i18n), merged over the English defaults. Objects have
2456
+ * no attribute form — bind as a DOM property (`:texts.prop` in Vue)
2457
+ */
2458
+ texts?: CTreeSelectTexts;
2459
+ /**
2460
+ * Selected value: the committed item's value, or the `CTreeSelectSelection`
2461
+ * with `return-object`; `null` when nothing is selected
2462
+ */
2463
+ value?: CTreeSelectValue;
2464
+ /**
2465
+ * Focus its combobox, as `focus()` does on a native control: the element renders
2466
+ * no box of its own to take it.
2467
+ */
2468
+ focus(options?: FocusOptions): void;
2469
+ addEventListener<K extends keyof CTreeSelectElementEventMap>(type: K, listener: (this: CTreeSelectElement, ev: CTreeSelectElementEventMap[K]) => void, options?: boolean | AddEventListenerOptions): void;
2470
+ addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
2471
+ removeEventListener<K extends keyof CTreeSelectElementEventMap>(type: K, listener: (this: CTreeSelectElement, ev: CTreeSelectElementEventMap[K]) => void, options?: boolean | EventListenerOptions): void;
2472
+ removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
2473
+ }
2474
+ /**
2475
+ * Props a consumer may set for every instance of a tag with
2476
+ * `applyDefaults()` (`@defaultable` in the manifest), typed as the
2477
+ * element's own members. An explicit per-instance attribute or property
2478
+ * always wins over an app default.
2479
+ */
2480
+ export interface CAppDefaults {
2481
+ 'c-autocomplete'?: Partial<Pick<CAutocompleteElement, 'hideDetails' | 'itemsPerPage' | 'labelOnTop' | 'shadow' | 'size' | 'texts'>>;
2482
+ 'c-breadcrumb'?: Partial<Pick<CBreadcrumbElement, 'texts'>>;
2483
+ 'c-color-picker'?: Partial<Pick<CColorPickerElement, 'alpha' | 'format' | 'hideDetails' | 'labelOnTop' | 'shadow' | 'size' | 'texts'>>;
2484
+ 'c-data-table'?: Partial<Pick<CDataTableElement, 'texts'>>;
2485
+ 'c-date-picker'?: Partial<Pick<CDatePickerElement, 'firstDayOfWeek' | 'format' | 'hideDetails' | 'labelOnTop' | 'shadow' | 'showToday' | 'showWeekNumbers' | 'size' | 'texts'>>;
2486
+ 'c-file-upload'?: Partial<Pick<CFileUploadElement, 'compact' | 'hideDetails' | 'size' | 'texts'>>;
2487
+ 'c-navigation-button'?: Partial<Pick<CNavigationButtonElement, 'texts'>>;
2488
+ 'c-number-field'?: Partial<Pick<CNumberFieldElement, 'decimalSeparator' | 'decimals' | 'fixedDecimals' | 'groupSeparator' | 'hideDetails' | 'labelOnTop' | 'shadow' | 'size' | 'step' | 'texts'>>;
2489
+ 'c-pagination'?: Partial<Pick<CPaginationElement, 'texts'>>;
2490
+ 'c-select'?: Partial<Pick<CSelectElement, 'hideDetails' | 'itemsPerPage' | 'labelOnTop' | 'shadow' | 'size' | 'texts'>>;
2491
+ 'c-text-field'?: Partial<Pick<CTextFieldElement, 'hideDetails' | 'labelOnTop' | 'shadow' | 'size'>>;
2492
+ 'c-time-picker'?: Partial<Pick<CTimePickerElement, 'format' | 'hideDetails' | 'labelOnTop' | 'shadow' | 'showNow' | 'size' | 'texts'>>;
2493
+ 'c-tree-select'?: Partial<Pick<CTreeSelectElement, 'hideDetails' | 'itemsPerPage' | 'labelOnTop' | 'shadow' | 'size' | 'texts'>>;
2494
+ }
2495
+ /** Runtime allow-list behind `applyDefaults()` validation — the same data as `CAppDefaults`. */
2496
+ export declare const DEFAULTABLE_PROPS: {
2497
+ readonly 'c-autocomplete': readonly ["hideDetails", "itemsPerPage", "labelOnTop", "shadow", "size", "texts"];
2498
+ readonly 'c-breadcrumb': readonly ["texts"];
2499
+ readonly 'c-color-picker': readonly ["alpha", "format", "hideDetails", "labelOnTop", "shadow", "size", "texts"];
2500
+ readonly 'c-data-table': readonly ["texts"];
2501
+ readonly 'c-date-picker': readonly ["firstDayOfWeek", "format", "hideDetails", "labelOnTop", "shadow", "showToday", "showWeekNumbers", "size", "texts"];
2502
+ readonly 'c-file-upload': readonly ["compact", "hideDetails", "size", "texts"];
2503
+ readonly 'c-navigation-button': readonly ["texts"];
2504
+ readonly 'c-number-field': readonly ["decimalSeparator", "decimals", "fixedDecimals", "groupSeparator", "hideDetails", "labelOnTop", "shadow", "size", "step", "texts"];
2505
+ readonly 'c-pagination': readonly ["texts"];
2506
+ readonly 'c-select': readonly ["hideDetails", "itemsPerPage", "labelOnTop", "shadow", "size", "texts"];
2507
+ readonly 'c-text-field': readonly ["hideDetails", "labelOnTop", "shadow", "size"];
2508
+ readonly 'c-time-picker': readonly ["format", "hideDetails", "labelOnTop", "shadow", "showNow", "size", "texts"];
2509
+ readonly 'c-tree-select': readonly ["hideDetails", "itemsPerPage", "labelOnTop", "shadow", "size", "texts"];
2510
+ };
2511
+ /** Tags dispatching the v-model contract event `update:value` — the value controls (CONTEXT.md). */
2512
+ export declare const VALUE_TAGS: readonly ["c-accordion", "c-autocomplete", "c-button-group", "c-checkbox", "c-color-picker", "c-date-picker", "c-file-upload", "c-modal", "c-number-field", "c-otp-input", "c-pagination", "c-radio-group", "c-select", "c-slider", "c-switch", "c-tabs", "c-text-field", "c-time-picker", "c-tree-select"];
2513
+ /** Events dispatched only to wire a parent to its composed children (ADR-0075); never public API. */
2514
+ export declare const INTERNAL_EVENTS: readonly ["contentchange", "dropdownstatechange", "itemchange", "radioselect", "selectall", "selectoption", "tabchange", "tabfocus"];
1619
2515
  declare global {
1620
2516
  interface HTMLElementTagNameMap {
1621
2517
  'c-accordion': CAccordionElement;
@@ -1623,6 +2519,8 @@ declare global {
1623
2519
  'c-alert': CAlertElement;
1624
2520
  'c-autocomplete': CAutocompleteElement;
1625
2521
  'c-badge': CBadgeElement;
2522
+ 'c-breadcrumb': CBreadcrumbElement;
2523
+ 'c-breadcrumb-item': CBreadcrumbItemElement;
1626
2524
  'c-button': CButtonElement;
1627
2525
  'c-button-group': CButtonGroupElement;
1628
2526
  'c-card': CCardElement;
@@ -1630,13 +2528,14 @@ declare global {
1630
2528
  'c-card-content': CCardContentElement;
1631
2529
  'c-card-title': CCardTitleElement;
1632
2530
  'c-checkbox': CCheckboxElement;
2531
+ 'c-color-picker': CColorPickerElement;
1633
2532
  'c-csc-logo': CCscLogoElement;
1634
2533
  'c-data-table': CDataTableElement;
2534
+ 'c-date-picker': CDatePickerElement;
1635
2535
  'c-divider': CDividerElement;
1636
- 'c-dropdown': CDropdownElement;
2536
+ 'c-file-upload': CFileUploadElement;
1637
2537
  'c-icon': CIconElement;
1638
2538
  'c-icon-button': CIconButtonElement;
1639
- 'c-input': CInputElement;
1640
2539
  'c-link': CLinkElement;
1641
2540
  'c-list': CListElement;
1642
2541
  'c-list-item': CListItemElement;
@@ -1655,6 +2554,7 @@ declare global {
1655
2554
  'c-message': CMessageElement;
1656
2555
  'c-modal': CModalElement;
1657
2556
  'c-navigation-button': CNavigationButtonElement;
2557
+ 'c-number-field': CNumberFieldElement;
1658
2558
  'c-option': COptionElement;
1659
2559
  'c-option-value': COptionValueElement;
1660
2560
  'c-otp-input': COtpInputElement;
@@ -1685,10 +2585,10 @@ declare global {
1685
2585
  'c-tag': CTagElement;
1686
2586
  'c-tags': CTagsElement;
1687
2587
  'c-text-field': CTextFieldElement;
1688
- 'c-toast': CToastElement;
2588
+ 'c-time-picker': CTimePickerElement;
1689
2589
  'c-toasts': CToastsElement;
1690
2590
  'c-toolbar': CToolbarElement;
1691
2591
  'c-tooltip': CTooltipElement;
2592
+ 'c-tree-select': CTreeSelectElement;
1692
2593
  }
1693
2594
  }
1694
- export {};