@cscfi/csc-ui 4.0.0-alpha.10 → 4.0.0-alpha.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/csc-ui.js +7314 -6856
- package/dist/custom-elements.json +260 -57
- package/dist/docs/c-autocomplete/usage.md +97 -0
- package/dist/docs/c-button-group/usage.md +6 -0
- package/dist/docs/c-menu/usage.md +15 -0
- package/dist/docs/c-menu-item/usage.md +6 -0
- package/dist/docs/c-option-value/usage.md +1 -0
- package/dist/docs/c-select/usage.md +71 -0
- package/dist/vscode.css-custom-data.json +54 -1
- package/dist/vscode.html-custom-data.json +35 -20
- package/dist/web-types.json +155 -53
- package/dist-types/components/c-autocomplete/CAutocomplete.vue.d.ts +70 -11
- package/dist-types/components/c-checkbox/CCheckbox.vue.d.ts +2 -2
- package/dist-types/components/c-data-table/CDataTable.vue.d.ts +1 -1
- package/dist-types/components/c-dropdown/CDropdown.vue.d.ts +15 -3
- package/dist-types/components/c-input/CInput.vue.d.ts +1 -1
- package/dist-types/components/c-menu/CMenu.vue.d.ts +1 -1
- package/dist-types/components/c-popover/CPopover.vue.d.ts +1 -1
- package/dist-types/components/c-select/CSelect.vue.d.ts +68 -17
- package/dist-types/components/c-side-navigation/CSideNavigation.vue.d.ts +1 -1
- package/dist-types/components/c-tag/CTag.vue.d.ts +7 -0
- package/dist-types/components/c-text-field/CTextField.vue.d.ts +3 -3
- package/dist-types/components/c-tooltip/CTooltip.vue.d.ts +1 -1
- package/dist-types/index.d.ts +2 -1
- package/dist-types/shared/FormLabel.vue.d.ts +1 -1
- package/dist-types/shared/SelectionIndicator.vue.d.ts +21 -0
- package/dist-types/shared/optionLabel.d.ts +18 -0
- package/dist-types/shared/peekCap.d.ts +35 -0
- package/dist-types/shared/splitMatches.d.ts +18 -0
- package/dist-types/tag-name-map.d.ts +78 -17
- package/package.json +1 -1
|
@@ -68,19 +68,33 @@
|
|
|
68
68
|
"owner": "c-autocomplete"
|
|
69
69
|
},
|
|
70
70
|
{
|
|
71
|
-
"declaration": "export interface CAutocompleteOption {\n /** Whether the option is disabled. */\n disabled: boolean;\n
|
|
71
|
+
"declaration": "export interface CAutocompleteOption {\n /** Whether the option is disabled. */\n disabled: boolean;\n /**\n * The option's label: its `name`, else the text of its `c-option-value`,\n * else its whole text content (for an `items` entry, its `name`).\n */\n label: string;\n /** The option's value. */\n value: number | string;\n}",
|
|
72
72
|
"description": "The normalized option handed to a `c-autocomplete` `filter` predicate. `label`\nis the option's `name` (or its trimmed text content when authored as a\nslotted `<c-option>`).",
|
|
73
73
|
"kind": "interface",
|
|
74
74
|
"name": "CAutocompleteOption",
|
|
75
75
|
"owner": "c-autocomplete"
|
|
76
76
|
},
|
|
77
77
|
{
|
|
78
|
-
"declaration": "export interface CAutocompleteProps {\n /** Make the selected value clearable */\n clearable?: boolean;\n /** Disable the input */\n disabled?: boolean;\n /**\n * Error message shown in place of the hint while the autocomplete is invalid\n *\n * @freeform\n */\n errorMessage?: string;\n /**\n * The consumer owns filtering: the component renders its options verbatim\n * and only emits `change:query` as the user types. Pair with `loading` and\n * an async data source feeding `items`\n */\n external?: boolean;\n /** Custom filter predicate; receives a normalized option + the query. Ignored when `external` is set */\n filter?: CAutocompleteFilter;\n /** Hide the hint and error messages */\n hideDetails?: boolean;\n /**\n * Hint text for the input\n *\n * @freeform\n */\n hint?: string;\n /**\n * Id of the element\n *\n * @freeform\n */\n hostId?: string;\n /** Dropdown items (when not using <c-option> elements) */\n items?: CAutocompleteItem[];\n /** Items per page before the list scrolls */\n itemsPerPage?: number;\n /**\n * Element label\n *\n * @freeform\n */\n label?: string;\n /** Label on top of the input */\n labelOnTop?: boolean;\n /** Show loading state */\n loading?: boolean;\n /**\n *
|
|
78
|
+
"declaration": "export interface CAutocompleteProps {\n /** Make the selected value clearable */\n clearable?: boolean;\n /** Disable the input */\n disabled?: boolean;\n /**\n * Error message shown in place of the hint while the autocomplete is invalid\n *\n * @freeform\n */\n errorMessage?: string;\n /**\n * The consumer owns filtering: the component renders its options verbatim\n * and only emits `change:query` as the user types. Pair with `loading` and\n * an async data source feeding `items`\n */\n external?: boolean;\n /** Custom filter predicate; receives a normalized option + the query. Ignored when `external` is set */\n filter?: CAutocompleteFilter;\n /** Hide the hint and error messages */\n hideDetails?: boolean;\n /**\n * Hint text for the input\n *\n * @freeform\n */\n hint?: string;\n /**\n * Id of the element\n *\n * @freeform\n */\n hostId?: string;\n /** Dropdown items (when not using <c-option> elements) */\n items?: CAutocompleteItem[];\n /** Items per page before the list scrolls */\n itemsPerPage?: number;\n /**\n * Element label\n *\n * @freeform\n */\n label?: string;\n /** Label on top of the input */\n labelOnTop?: boolean;\n /** Show loading state */\n loading?: boolean;\n /**\n * In `multiple` mode, show at most this many selected-value tags and fold\n * the rest into one \"+N more\" tag; `0` shows no tags and reads \"N selected\"\n * instead; unset shows every tag\n */\n maxTags?: number;\n /**\n * Allow selecting several options: rows toggle, the panel stays open and\n * keeps its query, `value` becomes an array of the selected values (items\n * with `return-object`) in the order they were picked, and the picks show\n * as tags inside the field. Arrays have no attribute form — bind `value` as\n * a DOM property\n */\n multiple?: boolean;\n /**\n * Input field name\n *\n * @freeform\n */\n name?: string;\n /**\n * Placeholder for the in-panel search input\n *\n * @freeform\n */\n placeholder?: string;\n /** Set the autocomplete as required */\n required?: boolean;\n /** Return object instead of value */\n returnObject?: boolean;\n /** Shadow variant */\n shadow?: boolean;\n /** Field height: the 44px default or the 36px `small` box */\n size?: CFieldSize;\n /**\n * UI text overrides (i18n), merged over the English defaults. Objects have\n * no attribute form — bind as a DOM property (`:texts.prop` in Vue)\n */\n texts?: CAutocompleteTexts;\n /** Set the validity of the input */\n valid?: boolean;\n /**\n * Selected value: the option's value, or the whole item with\n * `return-object`; an array of them in `multiple` mode\n */\n value?: CAutocompleteValue;\n}",
|
|
79
79
|
"description": "",
|
|
80
80
|
"kind": "interface",
|
|
81
81
|
"name": "CAutocompleteProps",
|
|
82
82
|
"owner": "c-autocomplete"
|
|
83
83
|
},
|
|
84
|
+
{
|
|
85
|
+
"declaration": "export interface CAutocompleteTexts {\n /** Accessible label of the clear button. */\n clearSelection?: string;\n /** Accessible label of the search input inside the panel. */\n filterOptions?: string;\n /** Text of the loading row shown while `loading` with nothing to list. */\n loading?: string;\n /**\n * Text of the overflow tag when `max-tags` folds the selection; receives the\n * number of hidden tags.\n */\n more?: (count: number) => string;\n /** Text of the row shown when the query matches no options. */\n noResults?: string;\n /** Accessible label of a tag's remove button; receives the option label. */\n remove?: (label: string) => string;\n /** Placeholder of the search input when the `placeholder` prop is empty. */\n searchPlaceholder?: string;\n /**\n * Field text when `max-tags=\"0\"` shows no tags; receives the selection\n * count.\n */\n selected?: (count: number) => string;\n /** Accessible label of the chevron button that opens and closes the panel. */\n toggleOptions?: string;\n}",
|
|
86
|
+
"description": "UI texts of `c-autocomplete`, shallow-merged over the English defaults.\nStatic labels are strings; count- or label-interpolated ones are\nfunctions.",
|
|
87
|
+
"kind": "interface",
|
|
88
|
+
"name": "CAutocompleteTexts",
|
|
89
|
+
"owner": "c-autocomplete"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"declaration": "export type CAutocompleteValue =\n | (number | string)[]\n | CAutocompleteItem\n | CAutocompleteItem[]\n | null\n | number\n | string;",
|
|
93
|
+
"description": "Selection value of `c-autocomplete`: the committed option's value — or the\nwhole `{ name, value }` item with `return-object` — and `null` when\ncleared. In `multiple` mode an array of them in the order they were\npicked, `[]` when empty.",
|
|
94
|
+
"kind": "type-alias",
|
|
95
|
+
"name": "CAutocompleteValue",
|
|
96
|
+
"owner": "c-autocomplete"
|
|
97
|
+
},
|
|
84
98
|
{
|
|
85
99
|
"declaration": "export interface CButtonProps {\n /**\n * Pressed (toggle) state — renders the selected look and sets\n * `aria-pressed`. Leave unset for regular action buttons: only a\n * true/false value marks the button as a toggle. Driven by\n * `c-button-group` on its slotted buttons.\n */\n active?: boolean;\n /**\n * Danger variant style\n *\n * @seeded from csc-ui — verify\n */\n danger?: boolean;\n /**\n * Disable the button\n *\n * @seeded from csc-ui — verify\n */\n disabled?: boolean;\n /**\n * Fit width to containing element\n *\n * @seeded from csc-ui — verify\n */\n fit?: boolean;\n /**\n * Light button background\n *\n * @seeded from csc-ui — verify\n */\n ghost?: boolean;\n /**\n * Id of the button\n *\n * @seeded from csc-ui — verify\n * @freeform\n */\n hostId?: string;\n /**\n * Hyperlink url\n *\n * @seeded from csc-ui — verify\n * @freeform any URL\n */\n href?: string;\n /**\n * Inverted button style for dark backgrounds\n *\n * @seeded from csc-ui — verify\n */\n inverted?: boolean;\n /**\n * Display loader on the button\n *\n * @seeded from csc-ui — verify\n */\n loading?: boolean;\n /**\n * Remove the default border radius\n *\n * @seeded from csc-ui — verify\n */\n noRadius?: boolean;\n /** Suppress the click ripple (e.g. when a wrapper owns the press feedback). */\n noRipple?: boolean;\n /**\n * Outlined button style\n *\n * @seeded from csc-ui — verify\n */\n outlined?: boolean;\n /**\n * Size of the button\n *\n * @seeded from csc-ui — verify\n */\n size?: CButtonSize;\n /**\n * Hyperlink target\n *\n * @seeded from csc-ui — verify\n * @freeform any browsing-context name (e.g. _blank, _self)\n */\n target?: string;\n /**\n * Transparent button background\n *\n * @seeded from csc-ui — verify\n */\n text?: boolean;\n /**\n * Button type\n *\n * @seeded from csc-ui — verify\n */\n type?: CButtonType;\n /**\n * Value for the button\n * - for use in the c-button-group\n *\n * @seeded from csc-ui — verify\n */\n value?: number | string;\n}",
|
|
86
100
|
"description": "",
|
|
@@ -319,6 +333,27 @@
|
|
|
319
333
|
"name": "CPopoverProps",
|
|
320
334
|
"owner": "c-popover"
|
|
321
335
|
},
|
|
336
|
+
{
|
|
337
|
+
"declaration": "export interface CSelectProps {\n /** Make the selected value clearable */\n clearable?: boolean;\n /** Disable the input */\n disabled?: boolean;\n /**\n * Error message shown in place of the hint while the select is invalid\n *\n * @freeform\n */\n errorMessage?: string;\n /** Hide the hint and error messages */\n hideDetails?: boolean;\n /**\n * Hint text for the input\n *\n * @freeform\n */\n hint?: string;\n /**\n * Id of the element\n *\n * @freeform\n */\n hostId?: string;\n /** Dropdown items (when not using <c-option> elements) */\n items?: CSelectItem[];\n /** Items per page before adding scroll */\n itemsPerPage?: number;\n /**\n * Element label\n *\n * @freeform\n */\n label?: string;\n /** Label on top of the input */\n labelOnTop?: boolean;\n /** Show loading state */\n loading?: boolean;\n /**\n * In `multiple` mode, show at most this many selected-value tags and fold\n * the rest into one \"+N more\" tag; `0` shows no tags and reads \"N selected\"\n * instead; unset shows every tag\n */\n maxTags?: number;\n /**\n * Allow selecting several options: rows toggle and the list stays open,\n * `value` becomes an array of the selected values (items with\n * `return-object`) in the order they were picked, and the picks show as\n * tags inside the field. `option-as-selection` is ignored in this mode.\n * Arrays have no attribute form — bind `value` as a DOM property\n */\n multiple?: boolean;\n /**\n * Input field name\n *\n * @freeform\n */\n name?: string;\n /** Display the option as selection (only with <c-option> elements) */\n optionAsSelection?: boolean;\n /**\n * Placeholder text\n *\n * @freeform\n */\n placeholder?: string;\n /** Set the select as required */\n required?: boolean;\n /** Return object instead of value */\n returnObject?: boolean;\n /** Shadow variant */\n shadow?: boolean;\n /** Field height: the 44px default or the 36px `small` box */\n size?: CFieldSize;\n /**\n * UI text overrides (i18n), merged over the English defaults. Objects have\n * no attribute form — bind as a DOM property (`:texts.prop` in Vue)\n */\n texts?: CSelectTexts;\n /** Set the validity of the input */\n valid?: boolean;\n /**\n * Selected value: the option's value, or the whole item with\n * `return-object`; an array of them in `multiple` mode\n */\n value?: CSelectValue;\n}",
|
|
338
|
+
"description": "",
|
|
339
|
+
"kind": "interface",
|
|
340
|
+
"name": "CSelectProps",
|
|
341
|
+
"owner": "c-select"
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
"declaration": "export interface CSelectTexts {\n /** Accessible label of the clear button. */\n clearSelection?: string;\n /**\n * Text of the overflow tag when `max-tags` folds the selection; receives the\n * number of hidden tags.\n */\n more?: (count: number) => string;\n /** Accessible label of a tag's remove button; receives the option label. */\n remove?: (label: string) => string;\n /**\n * Field text when `max-tags=\"0\"` shows no tags; receives the selection\n * count.\n */\n selected?: (count: number) => string;\n /** Accessible label of the chevron button that opens and closes the list. */\n toggleOptions?: string;\n}",
|
|
345
|
+
"description": "UI texts of `c-select`, shallow-merged over the English defaults. Static\nlabels are strings; count- or label-interpolated ones are functions.",
|
|
346
|
+
"kind": "interface",
|
|
347
|
+
"name": "CSelectTexts",
|
|
348
|
+
"owner": "c-select"
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
"declaration": "export type CSelectValue =\n | (number | string)[]\n | CSelectItem\n | CSelectItem[]\n | null\n | number\n | string;",
|
|
352
|
+
"description": "Selection value of `c-select`: the picked option's value — or the whole\n`{ name, value }` item with `return-object` — and `null` when nothing is\nselected. In `multiple` mode an array of them in the order they were\npicked, `[]` when empty.",
|
|
353
|
+
"kind": "type-alias",
|
|
354
|
+
"name": "CSelectValue",
|
|
355
|
+
"owner": "c-select"
|
|
356
|
+
},
|
|
322
357
|
{
|
|
323
358
|
"declaration": "export interface CStatusProps {\n /**\n * Status type\n *\n * @seeded from csc-ui — verify\n */\n type?: CStatusType;\n}",
|
|
324
359
|
"description": "",
|
|
@@ -362,7 +397,7 @@
|
|
|
362
397
|
"owner": "c-tabs"
|
|
363
398
|
},
|
|
364
399
|
{
|
|
365
|
-
"declaration": "export interface CTagProps {\n /**\n * Mark tag as active\n *\n * @seeded from csc-ui — verify\n */\n active?: boolean;\n /**\n * Display an optional badge at the start of the tag\n *\n * @seeded from csc-ui — verify\n */\n badge?: null | number | string;\n /**\n * Mark tag as closeable\n *\n * @seeded from csc-ui — verify\n */\n closeable?: boolean;\n /**\n * Remove the hover effect\n *\n * @seeded from csc-ui — verify\n */\n flat?: boolean;\n /**\n * Size of the tag\n *\n * @seeded from csc-ui — verify\n */\n size?: CTagSize;\n}",
|
|
400
|
+
"declaration": "export interface CTagProps {\n /**\n * Mark tag as active\n *\n * @seeded from csc-ui — verify\n */\n active?: boolean;\n /**\n * Display an optional badge at the start of the tag\n *\n * @seeded from csc-ui — verify\n */\n badge?: null | number | string;\n /**\n * Mark tag as closeable\n *\n * @seeded from csc-ui — verify\n */\n closeable?: boolean;\n /**\n * Accessible name of the close button rendered when `closeable`\n *\n * @freeform\n */\n closeLabel?: string;\n /**\n * Remove the hover effect\n *\n * @seeded from csc-ui — verify\n */\n flat?: boolean;\n /**\n * Size of the tag\n *\n * @seeded from csc-ui — verify\n */\n size?: CTagSize;\n}",
|
|
366
401
|
"description": "",
|
|
367
402
|
"kind": "interface",
|
|
368
403
|
"name": "CTagProps",
|
|
@@ -1050,25 +1085,30 @@
|
|
|
1050
1085
|
"default": "false"
|
|
1051
1086
|
},
|
|
1052
1087
|
{
|
|
1053
|
-
"fieldName": "
|
|
1054
|
-
"name": "
|
|
1055
|
-
"description": "
|
|
1088
|
+
"fieldName": "maxTags",
|
|
1089
|
+
"name": "max-tags",
|
|
1090
|
+
"description": "In `multiple` mode, show at most this many selected-value tags and fold\nthe rest into one \"+N more\" tag; `0` shows no tags and reads \"N selected\"\ninstead; unset shows every tag",
|
|
1056
1091
|
"type": {
|
|
1057
|
-
"text": "
|
|
1058
|
-
},
|
|
1059
|
-
"default": "''",
|
|
1060
|
-
"csc": {
|
|
1061
|
-
"freeform": true
|
|
1092
|
+
"text": "number"
|
|
1062
1093
|
}
|
|
1063
1094
|
},
|
|
1064
1095
|
{
|
|
1065
|
-
"fieldName": "
|
|
1066
|
-
"name": "
|
|
1067
|
-
"description": "
|
|
1096
|
+
"fieldName": "multiple",
|
|
1097
|
+
"name": "multiple",
|
|
1098
|
+
"description": "Allow selecting several options: rows toggle, the panel stays open and\nkeeps its query, `value` becomes an array of the selected values (items\nwith `return-object`) in the order they were picked, and the picks show\nas tags inside the field. Arrays have no attribute form — bind `value` as\na DOM property",
|
|
1099
|
+
"type": {
|
|
1100
|
+
"text": "boolean"
|
|
1101
|
+
},
|
|
1102
|
+
"default": "false"
|
|
1103
|
+
},
|
|
1104
|
+
{
|
|
1105
|
+
"fieldName": "name",
|
|
1106
|
+
"name": "name",
|
|
1107
|
+
"description": "Input field name",
|
|
1068
1108
|
"type": {
|
|
1069
1109
|
"text": "string"
|
|
1070
1110
|
},
|
|
1071
|
-
"default": "'
|
|
1111
|
+
"default": "''",
|
|
1072
1112
|
"csc": {
|
|
1073
1113
|
"freeform": true
|
|
1074
1114
|
}
|
|
@@ -1132,15 +1172,6 @@
|
|
|
1132
1172
|
"text": "boolean"
|
|
1133
1173
|
},
|
|
1134
1174
|
"default": "true"
|
|
1135
|
-
},
|
|
1136
|
-
{
|
|
1137
|
-
"fieldName": "value",
|
|
1138
|
-
"name": "value",
|
|
1139
|
-
"description": "Selected value (scalar, or object when return-object is set)",
|
|
1140
|
-
"type": {
|
|
1141
|
-
"text": "CAutocompleteItem | null | number | string"
|
|
1142
|
-
},
|
|
1143
|
-
"default": "null"
|
|
1144
1175
|
}
|
|
1145
1176
|
],
|
|
1146
1177
|
"cssParts": [
|
|
@@ -1160,9 +1191,37 @@
|
|
|
1160
1191
|
"name": "list",
|
|
1161
1192
|
"description": "The scrollable options listbox"
|
|
1162
1193
|
},
|
|
1194
|
+
{
|
|
1195
|
+
"name": "item",
|
|
1196
|
+
"description": "One option row in the list"
|
|
1197
|
+
},
|
|
1198
|
+
{
|
|
1199
|
+
"name": "indicator",
|
|
1200
|
+
"description": "The decorative checkbox box on an option row in `multiple` mode; border, fill and glyph draw with `currentColor`, so `color` recolours them together (the c-checkbox recipe)"
|
|
1201
|
+
},
|
|
1202
|
+
{
|
|
1203
|
+
"name": "mark",
|
|
1204
|
+
"description": "The check glyph inside a row indicator; draws with `currentColor`"
|
|
1205
|
+
},
|
|
1206
|
+
{
|
|
1207
|
+
"name": "match",
|
|
1208
|
+
"description": "A run of an option's label equal to the query, in the row; underlined in the primary colour, text inherits the row"
|
|
1209
|
+
},
|
|
1163
1210
|
{
|
|
1164
1211
|
"name": "info",
|
|
1165
1212
|
"description": "The info row: loading while `loading` with an empty list, otherwise no-results when the query matches no options"
|
|
1213
|
+
},
|
|
1214
|
+
{
|
|
1215
|
+
"name": "tags",
|
|
1216
|
+
"description": "The row of selected-value tags inside the field (`multiple` mode)"
|
|
1217
|
+
},
|
|
1218
|
+
{
|
|
1219
|
+
"name": "tag",
|
|
1220
|
+
"description": "One selected-value tag: the `c-tag` host, including the overflow tag"
|
|
1221
|
+
},
|
|
1222
|
+
{
|
|
1223
|
+
"name": "tag-root",
|
|
1224
|
+
"description": "The pill box inside each tag (the `c-tag` `root` part), for colours and borders"
|
|
1166
1225
|
}
|
|
1167
1226
|
],
|
|
1168
1227
|
"cssProperties": [],
|
|
@@ -1185,9 +1244,9 @@
|
|
|
1185
1244
|
{
|
|
1186
1245
|
"name": "changeValue",
|
|
1187
1246
|
"type": {
|
|
1188
|
-
"text": "CustomEvent<
|
|
1247
|
+
"text": "CustomEvent<CAutocompleteValue>"
|
|
1189
1248
|
},
|
|
1190
|
-
"description": "Fired when the selected value changes (an option is committed or the\nselection is cleared), carrying the new value — the option's value, or\nthe whole `{ name, value }` item when `return-object` is set; `null`\nwhen cleared. Also dispatched as `change-value` — bind that name in Vue templates."
|
|
1249
|
+
"description": "Fired when the selected value changes (an option is committed or the\nselection is cleared), carrying the new value — the option's value, or\nthe whole `{ name, value }` item when `return-object` is set; `null`\nwhen cleared. In `multiple` mode the whole array of picked values, in\npick order (`[]` when cleared). Also dispatched as `change-value` — bind that name in Vue templates."
|
|
1191
1250
|
},
|
|
1192
1251
|
{
|
|
1193
1252
|
"name": "input",
|
|
@@ -1199,7 +1258,7 @@
|
|
|
1199
1258
|
{
|
|
1200
1259
|
"name": "update:value",
|
|
1201
1260
|
"type": {
|
|
1202
|
-
"text": "CustomEvent<
|
|
1261
|
+
"text": "CustomEvent<CAutocompleteValue>"
|
|
1203
1262
|
},
|
|
1204
1263
|
"description": "Fired alongside `changeValue` with the same detail — the `v-model`\ncontract."
|
|
1205
1264
|
}
|
|
@@ -1348,26 +1407,32 @@
|
|
|
1348
1407
|
},
|
|
1349
1408
|
{
|
|
1350
1409
|
"kind": "field",
|
|
1351
|
-
"name": "
|
|
1410
|
+
"name": "maxTags",
|
|
1352
1411
|
"privacy": "public",
|
|
1353
|
-
"description": "
|
|
1412
|
+
"description": "In `multiple` mode, show at most this many selected-value tags and fold\nthe rest into one \"+N more\" tag; `0` shows no tags and reads \"N selected\"\ninstead; unset shows every tag",
|
|
1354
1413
|
"type": {
|
|
1355
|
-
"text": "
|
|
1356
|
-
},
|
|
1357
|
-
"default": "''",
|
|
1358
|
-
"csc": {
|
|
1359
|
-
"freeform": true
|
|
1414
|
+
"text": "number"
|
|
1360
1415
|
}
|
|
1361
1416
|
},
|
|
1362
1417
|
{
|
|
1363
1418
|
"kind": "field",
|
|
1364
|
-
"name": "
|
|
1419
|
+
"name": "multiple",
|
|
1420
|
+
"privacy": "public",
|
|
1421
|
+
"description": "Allow selecting several options: rows toggle, the panel stays open and\nkeeps its query, `value` becomes an array of the selected values (items\nwith `return-object`) in the order they were picked, and the picks show\nas tags inside the field. Arrays have no attribute form — bind `value` as\na DOM property",
|
|
1422
|
+
"type": {
|
|
1423
|
+
"text": "boolean"
|
|
1424
|
+
},
|
|
1425
|
+
"default": "false"
|
|
1426
|
+
},
|
|
1427
|
+
{
|
|
1428
|
+
"kind": "field",
|
|
1429
|
+
"name": "name",
|
|
1365
1430
|
"privacy": "public",
|
|
1366
|
-
"description": "
|
|
1431
|
+
"description": "Input field name",
|
|
1367
1432
|
"type": {
|
|
1368
1433
|
"text": "string"
|
|
1369
1434
|
},
|
|
1370
|
-
"default": "'
|
|
1435
|
+
"default": "''",
|
|
1371
1436
|
"csc": {
|
|
1372
1437
|
"freeform": true
|
|
1373
1438
|
}
|
|
@@ -1428,6 +1493,16 @@
|
|
|
1428
1493
|
"typeAlias": "CFieldSize"
|
|
1429
1494
|
}
|
|
1430
1495
|
},
|
|
1496
|
+
{
|
|
1497
|
+
"kind": "field",
|
|
1498
|
+
"name": "texts",
|
|
1499
|
+
"privacy": "public",
|
|
1500
|
+
"description": "UI text overrides (i18n), merged over the English defaults. Objects have\nno attribute form — bind as a DOM property (`:texts.prop` in Vue)",
|
|
1501
|
+
"type": {
|
|
1502
|
+
"text": "CAutocompleteTexts"
|
|
1503
|
+
},
|
|
1504
|
+
"default": "() => ({})"
|
|
1505
|
+
},
|
|
1431
1506
|
{
|
|
1432
1507
|
"kind": "field",
|
|
1433
1508
|
"name": "valid",
|
|
@@ -1442,9 +1517,9 @@
|
|
|
1442
1517
|
"kind": "field",
|
|
1443
1518
|
"name": "value",
|
|
1444
1519
|
"privacy": "public",
|
|
1445
|
-
"description": "Selected value
|
|
1520
|
+
"description": "Selected value: the option's value, or the whole item with\n`return-object`; an array of them in `multiple` mode",
|
|
1446
1521
|
"type": {
|
|
1447
|
-
"text": "
|
|
1522
|
+
"text": "CAutocompleteValue"
|
|
1448
1523
|
},
|
|
1449
1524
|
"default": "null"
|
|
1450
1525
|
},
|
|
@@ -2041,7 +2116,7 @@
|
|
|
2041
2116
|
"cssParts": [
|
|
2042
2117
|
{
|
|
2043
2118
|
"name": "root",
|
|
2044
|
-
"description": "The segmented-control box
|
|
2119
|
+
"description": "The track: the framed segmented-control box the buttons sit in"
|
|
2045
2120
|
},
|
|
2046
2121
|
{
|
|
2047
2122
|
"name": "label",
|
|
@@ -3533,6 +3608,15 @@
|
|
|
3533
3608
|
},
|
|
3534
3609
|
"default": "0"
|
|
3535
3610
|
},
|
|
3611
|
+
{
|
|
3612
|
+
"fieldName": "multiple",
|
|
3613
|
+
"name": "multiple",
|
|
3614
|
+
"description": "Multi-select mode: rows toggle instead of committing, each carries a\ndecorative checkbox indicator, and the listbox is `aria-multiselectable`",
|
|
3615
|
+
"type": {
|
|
3616
|
+
"text": "boolean"
|
|
3617
|
+
},
|
|
3618
|
+
"default": "false"
|
|
3619
|
+
},
|
|
3536
3620
|
{
|
|
3537
3621
|
"fieldName": "parent",
|
|
3538
3622
|
"name": "parent",
|
|
@@ -3567,6 +3651,14 @@
|
|
|
3567
3651
|
{
|
|
3568
3652
|
"name": "item",
|
|
3569
3653
|
"description": "One option row"
|
|
3654
|
+
},
|
|
3655
|
+
{
|
|
3656
|
+
"name": "indicator",
|
|
3657
|
+
"description": "The decorative checkbox box on an option row in `multiple` mode; border, fill and glyph draw with `currentColor`, so `color` recolours them together"
|
|
3658
|
+
},
|
|
3659
|
+
{
|
|
3660
|
+
"name": "mark",
|
|
3661
|
+
"description": "The check glyph inside a row indicator; draws with `currentColor`"
|
|
3570
3662
|
}
|
|
3571
3663
|
],
|
|
3572
3664
|
"cssProperties": [],
|
|
@@ -3644,6 +3736,16 @@
|
|
|
3644
3736
|
},
|
|
3645
3737
|
"default": "0"
|
|
3646
3738
|
},
|
|
3739
|
+
{
|
|
3740
|
+
"kind": "field",
|
|
3741
|
+
"name": "multiple",
|
|
3742
|
+
"privacy": "public",
|
|
3743
|
+
"description": "Multi-select mode: rows toggle instead of committing, each carries a\ndecorative checkbox indicator, and the listbox is `aria-multiselectable`",
|
|
3744
|
+
"type": {
|
|
3745
|
+
"text": "boolean"
|
|
3746
|
+
},
|
|
3747
|
+
"default": "false"
|
|
3748
|
+
},
|
|
3647
3749
|
{
|
|
3648
3750
|
"kind": "field",
|
|
3649
3751
|
"name": "parent",
|
|
@@ -3654,6 +3756,16 @@
|
|
|
3654
3756
|
},
|
|
3655
3757
|
"default": "null"
|
|
3656
3758
|
},
|
|
3759
|
+
{
|
|
3760
|
+
"kind": "field",
|
|
3761
|
+
"name": "selected",
|
|
3762
|
+
"privacy": "public",
|
|
3763
|
+
"description": "Values of the currently selected items in `multiple` mode; drives each\nrow's `aria-selected` and its indicator",
|
|
3764
|
+
"type": {
|
|
3765
|
+
"text": "(number | string)[]"
|
|
3766
|
+
},
|
|
3767
|
+
"default": "() => []"
|
|
3768
|
+
},
|
|
3657
3769
|
{
|
|
3658
3770
|
"kind": "field",
|
|
3659
3771
|
"name": "type",
|
|
@@ -5795,7 +5907,9 @@
|
|
|
5795
5907
|
"kind": "class",
|
|
5796
5908
|
"name": "CMenu",
|
|
5797
5909
|
"tagName": "c-menu",
|
|
5910
|
+
"description": "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.",
|
|
5798
5911
|
"csc": {
|
|
5912
|
+
"usage": "docs/c-menu/usage.md",
|
|
5799
5913
|
"subcomponents": [
|
|
5800
5914
|
"c-menu-item",
|
|
5801
5915
|
"c-menu-label"
|
|
@@ -6653,7 +6767,7 @@
|
|
|
6653
6767
|
"slots": [
|
|
6654
6768
|
{
|
|
6655
6769
|
"name": "default",
|
|
6656
|
-
"description": "The option's
|
|
6770
|
+
"description": "The option's content, rendered in the list row; wrap the label text in c-option-value when the option carries more than its label"
|
|
6657
6771
|
}
|
|
6658
6772
|
]
|
|
6659
6773
|
}
|
|
@@ -6686,6 +6800,10 @@
|
|
|
6686
6800
|
"kind": "class",
|
|
6687
6801
|
"name": "COptionValue",
|
|
6688
6802
|
"tagName": "c-option-value",
|
|
6803
|
+
"description": "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)`).",
|
|
6804
|
+
"csc": {
|
|
6805
|
+
"usage": "docs/c-option-value/usage.md"
|
|
6806
|
+
},
|
|
6689
6807
|
"attributes": [],
|
|
6690
6808
|
"cssParts": [],
|
|
6691
6809
|
"cssProperties": [],
|
|
@@ -6695,7 +6813,7 @@
|
|
|
6695
6813
|
"slots": [
|
|
6696
6814
|
{
|
|
6697
6815
|
"name": "default",
|
|
6698
|
-
"description": "The
|
|
6816
|
+
"description": "The option's label: the text c-select and c-autocomplete use for the option in the closed field, its tag and the filter, and the region c-autocomplete marks query matches in"
|
|
6699
6817
|
}
|
|
6700
6818
|
]
|
|
6701
6819
|
}
|
|
@@ -8146,9 +8264,12 @@
|
|
|
8146
8264
|
"kind": "class",
|
|
8147
8265
|
"name": "CSelect",
|
|
8148
8266
|
"tagName": "c-select",
|
|
8267
|
+
"description": "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`.",
|
|
8149
8268
|
"csc": {
|
|
8269
|
+
"usage": "docs/c-select/usage.md",
|
|
8150
8270
|
"subcomponents": [
|
|
8151
|
-
"c-option"
|
|
8271
|
+
"c-option",
|
|
8272
|
+
"c-option-value"
|
|
8152
8273
|
]
|
|
8153
8274
|
},
|
|
8154
8275
|
"attributes": [
|
|
@@ -8254,6 +8375,23 @@
|
|
|
8254
8375
|
},
|
|
8255
8376
|
"default": "false"
|
|
8256
8377
|
},
|
|
8378
|
+
{
|
|
8379
|
+
"fieldName": "maxTags",
|
|
8380
|
+
"name": "max-tags",
|
|
8381
|
+
"description": "In `multiple` mode, show at most this many selected-value tags and fold\nthe rest into one \"+N more\" tag; `0` shows no tags and reads \"N selected\"\ninstead; unset shows every tag",
|
|
8382
|
+
"type": {
|
|
8383
|
+
"text": "number"
|
|
8384
|
+
}
|
|
8385
|
+
},
|
|
8386
|
+
{
|
|
8387
|
+
"fieldName": "multiple",
|
|
8388
|
+
"name": "multiple",
|
|
8389
|
+
"description": "Allow selecting several options: rows toggle and the list stays open,\n`value` becomes an array of the selected values (items with\n`return-object`) in the order they were picked, and the picks show as\ntags inside the field. `option-as-selection` is ignored in this mode.\nArrays have no attribute form — bind `value` as a DOM property",
|
|
8390
|
+
"type": {
|
|
8391
|
+
"text": "boolean"
|
|
8392
|
+
},
|
|
8393
|
+
"default": "false"
|
|
8394
|
+
},
|
|
8257
8395
|
{
|
|
8258
8396
|
"fieldName": "name",
|
|
8259
8397
|
"name": "name",
|
|
@@ -8334,15 +8472,6 @@
|
|
|
8334
8472
|
"text": "boolean"
|
|
8335
8473
|
},
|
|
8336
8474
|
"default": "true"
|
|
8337
|
-
},
|
|
8338
|
-
{
|
|
8339
|
-
"fieldName": "value",
|
|
8340
|
-
"name": "value",
|
|
8341
|
-
"description": "Selected value (scalar, or object when return-object is set)",
|
|
8342
|
-
"type": {
|
|
8343
|
-
"text": "CSelectItem | null | number | string"
|
|
8344
|
-
},
|
|
8345
|
-
"default": "null"
|
|
8346
8475
|
}
|
|
8347
8476
|
],
|
|
8348
8477
|
"cssParts": [
|
|
@@ -8357,6 +8486,26 @@
|
|
|
8357
8486
|
{
|
|
8358
8487
|
"name": "item",
|
|
8359
8488
|
"description": "One option row in the list. Any `part` attribute set on content inside a slotted `<c-option>` is exported too, so `c-select::part(<name>)` reaches the consumer's own option markup"
|
|
8489
|
+
},
|
|
8490
|
+
{
|
|
8491
|
+
"name": "indicator",
|
|
8492
|
+
"description": "The decorative checkbox box on an option row in `multiple` mode; border, fill and glyph draw with `currentColor`, so `color` recolours them together (the c-checkbox recipe)"
|
|
8493
|
+
},
|
|
8494
|
+
{
|
|
8495
|
+
"name": "mark",
|
|
8496
|
+
"description": "The check glyph inside a row indicator; draws with `currentColor`"
|
|
8497
|
+
},
|
|
8498
|
+
{
|
|
8499
|
+
"name": "tags",
|
|
8500
|
+
"description": "The row of selected-value tags inside the field (`multiple` mode)"
|
|
8501
|
+
},
|
|
8502
|
+
{
|
|
8503
|
+
"name": "tag",
|
|
8504
|
+
"description": "One selected-value tag: the `c-tag` host, including the overflow tag"
|
|
8505
|
+
},
|
|
8506
|
+
{
|
|
8507
|
+
"name": "tag-root",
|
|
8508
|
+
"description": "The pill box inside each tag (the `c-tag` `root` part), for colours and borders"
|
|
8360
8509
|
}
|
|
8361
8510
|
],
|
|
8362
8511
|
"cssProperties": [],
|
|
@@ -8365,9 +8514,9 @@
|
|
|
8365
8514
|
{
|
|
8366
8515
|
"name": "changeValue",
|
|
8367
8516
|
"type": {
|
|
8368
|
-
"text": "CustomEvent<
|
|
8517
|
+
"text": "CustomEvent<CSelectValue>"
|
|
8369
8518
|
},
|
|
8370
|
-
"description": "Fired when the selection changes (an option is picked or the value is\ncleared), carrying the new value — the option's value, or the whole\n`{ name, value }` item when `return-object` is set; `null` when cleared. Also dispatched as `change-value` — bind that name in Vue templates."
|
|
8519
|
+
"description": "Fired when the selection changes (an option is picked or the value is\ncleared), carrying the new value — the option's value, or the whole\n`{ name, value }` item when `return-object` is set; `null` when cleared.\nIn `multiple` mode the whole array of picked values, in pick order\n(`[]` when cleared). Also dispatched as `change-value` — bind that name in Vue templates."
|
|
8371
8520
|
},
|
|
8372
8521
|
{
|
|
8373
8522
|
"name": "input",
|
|
@@ -8379,7 +8528,7 @@
|
|
|
8379
8528
|
{
|
|
8380
8529
|
"name": "update:value",
|
|
8381
8530
|
"type": {
|
|
8382
|
-
"text": "CustomEvent<
|
|
8531
|
+
"text": "CustomEvent<CSelectValue>"
|
|
8383
8532
|
},
|
|
8384
8533
|
"description": "Fired alongside `changeValue` with the same detail — the `v-model`\ncontract."
|
|
8385
8534
|
}
|
|
@@ -8507,6 +8656,25 @@
|
|
|
8507
8656
|
},
|
|
8508
8657
|
"default": "false"
|
|
8509
8658
|
},
|
|
8659
|
+
{
|
|
8660
|
+
"kind": "field",
|
|
8661
|
+
"name": "maxTags",
|
|
8662
|
+
"privacy": "public",
|
|
8663
|
+
"description": "In `multiple` mode, show at most this many selected-value tags and fold\nthe rest into one \"+N more\" tag; `0` shows no tags and reads \"N selected\"\ninstead; unset shows every tag",
|
|
8664
|
+
"type": {
|
|
8665
|
+
"text": "number"
|
|
8666
|
+
}
|
|
8667
|
+
},
|
|
8668
|
+
{
|
|
8669
|
+
"kind": "field",
|
|
8670
|
+
"name": "multiple",
|
|
8671
|
+
"privacy": "public",
|
|
8672
|
+
"description": "Allow selecting several options: rows toggle and the list stays open,\n`value` becomes an array of the selected values (items with\n`return-object`) in the order they were picked, and the picks show as\ntags inside the field. `option-as-selection` is ignored in this mode.\nArrays have no attribute form — bind `value` as a DOM property",
|
|
8673
|
+
"type": {
|
|
8674
|
+
"text": "boolean"
|
|
8675
|
+
},
|
|
8676
|
+
"default": "false"
|
|
8677
|
+
},
|
|
8510
8678
|
{
|
|
8511
8679
|
"kind": "field",
|
|
8512
8680
|
"name": "name",
|
|
@@ -8586,6 +8754,16 @@
|
|
|
8586
8754
|
"typeAlias": "CFieldSize"
|
|
8587
8755
|
}
|
|
8588
8756
|
},
|
|
8757
|
+
{
|
|
8758
|
+
"kind": "field",
|
|
8759
|
+
"name": "texts",
|
|
8760
|
+
"privacy": "public",
|
|
8761
|
+
"description": "UI text overrides (i18n), merged over the English defaults. Objects have\nno attribute form — bind as a DOM property (`:texts.prop` in Vue)",
|
|
8762
|
+
"type": {
|
|
8763
|
+
"text": "CSelectTexts"
|
|
8764
|
+
},
|
|
8765
|
+
"default": "() => ({})"
|
|
8766
|
+
},
|
|
8589
8767
|
{
|
|
8590
8768
|
"kind": "field",
|
|
8591
8769
|
"name": "valid",
|
|
@@ -8600,9 +8778,9 @@
|
|
|
8600
8778
|
"kind": "field",
|
|
8601
8779
|
"name": "value",
|
|
8602
8780
|
"privacy": "public",
|
|
8603
|
-
"description": "Selected value
|
|
8781
|
+
"description": "Selected value: the option's value, or the whole item with\n`return-object`; an array of them in `multiple` mode",
|
|
8604
8782
|
"type": {
|
|
8605
|
-
"text": "
|
|
8783
|
+
"text": "CSelectValue"
|
|
8606
8784
|
},
|
|
8607
8785
|
"default": "null"
|
|
8608
8786
|
},
|
|
@@ -10995,6 +11173,18 @@
|
|
|
10995
11173
|
},
|
|
10996
11174
|
"default": "false"
|
|
10997
11175
|
},
|
|
11176
|
+
{
|
|
11177
|
+
"fieldName": "closeLabel",
|
|
11178
|
+
"name": "close-label",
|
|
11179
|
+
"description": "Accessible name of the close button rendered when `closeable`",
|
|
11180
|
+
"type": {
|
|
11181
|
+
"text": "string"
|
|
11182
|
+
},
|
|
11183
|
+
"default": "'Remove'",
|
|
11184
|
+
"csc": {
|
|
11185
|
+
"freeform": true
|
|
11186
|
+
}
|
|
11187
|
+
},
|
|
10998
11188
|
{
|
|
10999
11189
|
"fieldName": "flat",
|
|
11000
11190
|
"name": "flat",
|
|
@@ -11065,6 +11255,19 @@
|
|
|
11065
11255
|
},
|
|
11066
11256
|
"default": "false"
|
|
11067
11257
|
},
|
|
11258
|
+
{
|
|
11259
|
+
"kind": "field",
|
|
11260
|
+
"name": "closeLabel",
|
|
11261
|
+
"privacy": "public",
|
|
11262
|
+
"description": "Accessible name of the close button rendered when `closeable`",
|
|
11263
|
+
"type": {
|
|
11264
|
+
"text": "string"
|
|
11265
|
+
},
|
|
11266
|
+
"default": "'Remove'",
|
|
11267
|
+
"csc": {
|
|
11268
|
+
"freeform": true
|
|
11269
|
+
}
|
|
11270
|
+
},
|
|
11068
11271
|
{
|
|
11069
11272
|
"kind": "field",
|
|
11070
11273
|
"name": "flat",
|