@cscfi/csc-ui 4.0.0-rc.5 → 4.0.0-rc.7

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.
@@ -2380,6 +2380,15 @@
2380
2380
  "typeAlias": "CButtonVariant",
2381
2381
  "defaultable": true
2382
2382
  }
2383
+ },
2384
+ {
2385
+ "kind": "method",
2386
+ "name": "focus",
2387
+ "privacy": "public",
2388
+ "description": "Focus its button — its link under `href`, or the slotted button — as\n`focus()` does on a native button: the element renders no box of its own to\ntake it.",
2389
+ "csc": {
2390
+ "signature": "(options?: FocusOptions): void"
2391
+ }
2383
2392
  }
2384
2393
  ],
2385
2394
  "slots": [
@@ -5664,7 +5673,11 @@
5664
5673
  },
5665
5674
  {
5666
5675
  "name": "progress",
5667
- "description": "The progress bar along an uploading row's bottom edge"
5676
+ "description": "The progress track along an uploading row's bottom edge"
5677
+ },
5678
+ {
5679
+ "name": "progress-bar",
5680
+ "description": "The bar inside it showing the row's upload progress, or its looping sweep while indeterminate"
5668
5681
  }
5669
5682
  ],
5670
5683
  "cssProperties": [],
@@ -6361,6 +6374,15 @@
6361
6374
  "typeAlias": "CIconButtonVariant",
6362
6375
  "defaultable": true
6363
6376
  }
6377
+ },
6378
+ {
6379
+ "kind": "method",
6380
+ "name": "focus",
6381
+ "privacy": "public",
6382
+ "description": "Focus its button, as `focus()` does on a native button: the element renders\nno box of its own to take it.",
6383
+ "csc": {
6384
+ "signature": "(options?: FocusOptions): void"
6385
+ }
6364
6386
  }
6365
6387
  ],
6366
6388
  "slots": [
@@ -10037,7 +10059,7 @@
10037
10059
  {
10038
10060
  "fieldName": "hideDetails",
10039
10061
  "name": "hide-details",
10040
- "description": "Hides the details line (the percentage and `label`); `label` still\nnames the bar.",
10062
+ "description": "Hides the details line (the percentage and `label`); `label` still\nnames the progress bar.",
10041
10063
  "type": {
10042
10064
  "text": "boolean"
10043
10065
  },
@@ -10046,7 +10068,7 @@
10046
10068
  {
10047
10069
  "fieldName": "indeterminate",
10048
10070
  "name": "indeterminate",
10049
- "description": "Replaces the fill with a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
10071
+ "description": "Turns the bar into a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
10050
10072
  "type": {
10051
10073
  "text": "boolean"
10052
10074
  },
@@ -10067,7 +10089,7 @@
10067
10089
  {
10068
10090
  "fieldName": "singleLine",
10069
10091
  "name": "single-line",
10070
- "description": "Places the details line beside the bar instead of below it.",
10092
+ "description": "Places the details line beside the progress track instead of below it.",
10071
10093
  "type": {
10072
10094
  "text": "boolean"
10073
10095
  },
@@ -10076,7 +10098,7 @@
10076
10098
  {
10077
10099
  "fieldName": "value",
10078
10100
  "name": "value",
10079
- "description": "Completion percentage, 0 to 100. The fill clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
10101
+ "description": "Completion percentage, 0 to 100. The bar clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
10080
10102
  "type": {
10081
10103
  "text": "number"
10082
10104
  },
@@ -10086,11 +10108,15 @@
10086
10108
  "cssParts": [
10087
10109
  {
10088
10110
  "name": "root",
10089
- "description": "The outer flex wrapper around the bar and the details line"
10111
+ "description": "The outer flex wrapper around the progress track and the details line"
10112
+ },
10113
+ {
10114
+ "name": "track",
10115
+ "description": "The progress track: the ground the bar grows along, carrying the progressbar role. Its padding is the frame around the bar"
10090
10116
  },
10091
10117
  {
10092
10118
  "name": "bar",
10093
- "description": "The visible track of the progress bar, wrapping the native `<progress>` element"
10119
+ "description": "The bar showing the value: the fill, or the looping sweep while indeterminate"
10094
10120
  },
10095
10121
  {
10096
10122
  "name": "details",
@@ -10105,7 +10131,7 @@
10105
10131
  "kind": "field",
10106
10132
  "name": "hideDetails",
10107
10133
  "privacy": "public",
10108
- "description": "Hides the details line (the percentage and `label`); `label` still\nnames the bar.",
10134
+ "description": "Hides the details line (the percentage and `label`); `label` still\nnames the progress bar.",
10109
10135
  "type": {
10110
10136
  "text": "boolean"
10111
10137
  },
@@ -10115,7 +10141,7 @@
10115
10141
  "kind": "field",
10116
10142
  "name": "indeterminate",
10117
10143
  "privacy": "public",
10118
- "description": "Replaces the fill with a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
10144
+ "description": "Turns the bar into a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
10119
10145
  "type": {
10120
10146
  "text": "boolean"
10121
10147
  },
@@ -10138,7 +10164,7 @@
10138
10164
  "kind": "field",
10139
10165
  "name": "singleLine",
10140
10166
  "privacy": "public",
10141
- "description": "Places the details line beside the bar instead of below it.",
10167
+ "description": "Places the details line beside the progress track instead of below it.",
10142
10168
  "type": {
10143
10169
  "text": "boolean"
10144
10170
  },
@@ -10148,7 +10174,7 @@
10148
10174
  "kind": "field",
10149
10175
  "name": "value",
10150
10176
  "privacy": "public",
10151
- "description": "Completion percentage, 0 to 100. The fill clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
10177
+ "description": "Completion percentage, 0 to 100. The bar clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
10152
10178
  "type": {
10153
10179
  "text": "number"
10154
10180
  },
@@ -125,6 +125,9 @@ platform; with a slotted button, the page's own `<button>` is the control and
125
125
  `root` only paints. When only an icon is slotted, provide an accessible name on the
126
126
  host, e.g. `aria-label="Close"`.
127
127
 
128
+ The element's `focus()` focuses that control, as on a native button, so a
129
+ page can move focus to it and a menu or popover returns focus to it.
130
+
128
131
  ## Customization
129
132
 
130
133
  Restyle via CSS parts from your own stylesheet:
@@ -74,6 +74,7 @@ element ids (`aria-controls`, `aria-describedby`, …) give the button the
74
74
  elements the ids name in your page. Without an `aria-label` the button is named only by
75
75
  the text in its content, which is usually nothing or the badge count; visually
76
76
  hidden slotted text also names it, and keeps naming it while `loading`.
77
+ The element's `focus()` focuses the inner button, as on a native button.
77
78
 
78
79
  To show the name to sighted users too, put the button in a `c-tooltip`'s
79
80
  `trigger` slot. The tooltip text is announced as a description, so the
@@ -1,8 +1,8 @@
1
1
  A horizontal progress bar that fills a track to a known completion percentage, with an optional details line showing the value and a label.
2
2
 
3
- Bind the completion percentage to `value` (0–100; out-of-range values are clamped for the fill). By default a details line renders below the bar — the percentage plus whatever the `label` prop supplies (e.g. "57 % Uploading files"). Hide it with `hide-details`, or place it beside the bar with `single-line`.
3
+ Bind the completion percentage to `value` (0–100; out-of-range values are clamped for the bar). By default a details line renders below the progress track — the percentage plus whatever the `label` prop supplies (e.g. "57 % Uploading files"). Hide it with `hide-details`, or place it beside the track with `single-line`.
4
4
 
5
- For work of unknown duration the `indeterminate` prop replaces the fill with a looping sweep and hides the details line.
5
+ For work of unknown duration the `indeterminate` prop turns the bar into a looping sweep and hides the details line.
6
6
 
7
7
  ## When to use
8
8
 
@@ -12,12 +12,31 @@ For work of unknown duration the `indeterminate` prop replaces the fill with a l
12
12
 
13
13
  ## Details line
14
14
 
15
- The details line shows the raw `value` even when the fill clamps it, and a negative value renders the line in the error role — a hook for signalling a failed transfer while keeping the bar itself empty.
15
+ The details line shows the raw `value` even when the bar clamps it, and a negative value renders the line in the error role — a hook for signalling a failed transfer while keeping the bar itself empty.
16
16
 
17
17
  ## Accessibility
18
18
 
19
- The bar is a native `<progress>` element exposing `role="progressbar"` with `aria-valuenow` while determinate; in indeterminate mode no value is exposed. The host mirrors `aria-busy` (true while indeterminate) and a `title` tooltip with the current percentage. The bar is named by `label`, or, where a visible label would be redundant (a table cell), by an `aria-label` on the element. Name every bar.
19
+ The progress track is the element with `role="progressbar"`, exposing `aria-valuenow` (0 to 100) while determinate; in indeterminate mode no value is exposed. The host mirrors `aria-busy` (true while indeterminate) and a `title` tooltip with the current percentage. The progress bar is named by `label`, or, where a visible label would be redundant (a table cell), by an `aria-label` on the element. Name every progress bar.
20
20
 
21
21
  ## Customization
22
22
 
23
- Restyle via the parts: `::part(root)` (the outer wrapper), `::part(bar)` (the visible track around the native `<progress>`), and `::part(details)` (the percentage/label line). Colours default to the primary fill on a muted surface track.
23
+ Restyle via the parts:
24
+
25
+ - `::part(track)`: the progress track the bar grows along. Its `background-color` is the track's colour, its `height` the bar's thickness plus the frame, and its `padding` the frame around the bar.
26
+ - `::part(bar)`: the bar showing the value, also the indeterminate sweep. Its `background-color` is the bar's colour.
27
+ - `::part(root)`: the wrapper around the track and the details line.
28
+ - `::part(details)`: the percentage and label line.
29
+
30
+ By default the bar paints the primary role on a muted track. In a forced-colors mode (Windows High Contrast) the bar paints the system highlight colour whatever its `::part()` colour.
31
+
32
+ ```css
33
+ c-progress-bar.quota::part(track) {
34
+ background-color: var(--c-surface-sunken);
35
+ height: 12px;
36
+ padding: 2px;
37
+ }
38
+
39
+ c-progress-bar.quota::part(bar) {
40
+ background-color: var(--c-warning);
41
+ }
42
+ ```
@@ -479,7 +479,11 @@
479
479
  { "name": "::part(rejected)", "description": "One rejected file's row" },
480
480
  {
481
481
  "name": "::part(progress)",
482
- "description": "The progress bar along an uploading row's bottom edge"
482
+ "description": "The progress track along an uploading row's bottom edge"
483
+ },
484
+ {
485
+ "name": "::part(progress-bar)",
486
+ "description": "The bar inside it showing the row's upload progress, or its looping sweep while indeterminate"
483
487
  },
484
488
  {
485
489
  "name": "::part(root)",
@@ -693,11 +697,15 @@
693
697
  },
694
698
  {
695
699
  "name": "::part(root)",
696
- "description": "The outer flex wrapper around the bar and the details line"
700
+ "description": "The outer flex wrapper around the progress track and the details line"
701
+ },
702
+ {
703
+ "name": "::part(track)",
704
+ "description": "The progress track: the ground the bar grows along, carrying the progressbar role. Its padding is the frame around the bar"
697
705
  },
698
706
  {
699
707
  "name": "::part(bar)",
700
- "description": "The visible track of the progress bar, wrapping the native `<progress>` element"
708
+ "description": "The bar showing the value: the fill, or the looping sweep while indeterminate"
701
709
  },
702
710
  {
703
711
  "name": "::part(details)",
@@ -213,7 +213,7 @@
213
213
  },
214
214
  {
215
215
  "name": "c-button",
216
- "description": "Buttons trigger actions — submitting a form, opening a modal, confirming a choice. Use one filled button (the default `appearance`) per view for its main action; other actions use `appearance=\"outlined\"`, `\"ghost\"` or `\"text\"`.\n---\n\n\n### **Slots:**\n - **default** - Button label content, or a slotted `<button>` (ADR-0085):\nthe page's own native button, which a password manager reading the form's\nsubmit button finds. Its own `type`, `disabled`, `name`, `value` and\n`form` apply; the element paints its look.\n- **icon** - Leading icon, vertically centered before the label.\n- **description** - Secondary text rendered below the label.\n\n### **CSS Parts:**\n - **root** - The native `<button>` / `<a>` element carrying the visual styling.\n- **content** - Layout wrapper for the label, icon and description.\n- **description** - Wrapper of the `description` slot.",
216
+ "description": "Buttons trigger actions — submitting a form, opening a modal, confirming a choice. Use one filled button (the default `appearance`) per view for its main action; other actions use `appearance=\"outlined\"`, `\"ghost\"` or `\"text\"`.\n---\n\n\n### **Methods:**\n - **focus()** - Focus its button — its link under `href`, or the slotted button — as\n`focus()` does on a native button: the element renders no box of its own to\ntake it.\n\n### **Slots:**\n - **default** - Button label content, or a slotted `<button>` (ADR-0085):\nthe page's own native button, which a password manager reading the form's\nsubmit button finds. Its own `type`, `disabled`, `name`, `value` and\n`form` apply; the element paints its look.\n- **icon** - Leading icon, vertically centered before the label.\n- **description** - Secondary text rendered below the label.\n\n### **CSS Parts:**\n - **root** - The native `<button>` / `<a>` element carrying the visual styling.\n- **content** - Layout wrapper for the label, icon and description.\n- **description** - Wrapper of the `description` slot.",
217
217
  "attributes": [
218
218
  {
219
219
  "name": "active",
@@ -816,7 +816,7 @@
816
816
  },
817
817
  {
818
818
  "name": "c-file-upload",
819
- "description": "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.\n---\n\n\n### **Events:**\n - **change** - Fired with the new list of file entries.\n- **input** - Native bubbling input event fired with every value change so a plain Vue\n`v-model` works. No detail.\n- **reject** - Fired after an add that refused files, listing each with its reason —\na type outside `accept`, a file over `max-size`, a file already held,\none beyond `max-files`, or a folder. The refused files never join the\nvalue.\n- **update:value** - v-model contract event, fired with `change`.\n\n### **Methods:**\n - **focus()** - Focus its drop zone's button, as `focus()` does on a native control: the element renders\nno box of its own to take it.\n- **startUploads()** - Queue every `local` file entry for the upload function — how a `manual`\nfield starts; files added after the call wait for the next one. Fires the\nvalue events once when it starts any. Does nothing without an upload function\n\n### **CSS Parts:**\n - **root** - The field: label, drop zone, message line and file list. The whole of it takes a drop\n- **label** - The label above the drop zone\n- **drop-zone** - The dashed drop zone — the large button, or the `compact` row\n- **message** - The hint/error message area under the drop zone (always reserved unless `hide-message`)\n- **list** - The list of file entries and rejected files\n- **entry** - One file entry's row\n- **rejected** - One rejected file's row\n- **progress** - The progress bar along an uploading row's bottom edge",
819
+ "description": "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.\n---\n\n\n### **Events:**\n - **change** - Fired with the new list of file entries.\n- **input** - Native bubbling input event fired with every value change so a plain Vue\n`v-model` works. No detail.\n- **reject** - Fired after an add that refused files, listing each with its reason —\na type outside `accept`, a file over `max-size`, a file already held,\none beyond `max-files`, or a folder. The refused files never join the\nvalue.\n- **update:value** - v-model contract event, fired with `change`.\n\n### **Methods:**\n - **focus()** - Focus its drop zone's button, as `focus()` does on a native control: the element renders\nno box of its own to take it.\n- **startUploads()** - Queue every `local` file entry for the upload function — how a `manual`\nfield starts; files added after the call wait for the next one. Fires the\nvalue events once when it starts any. Does nothing without an upload function\n\n### **CSS Parts:**\n - **root** - The field: label, drop zone, message line and file list. The whole of it takes a drop\n- **label** - The label above the drop zone\n- **drop-zone** - The dashed drop zone — the large button, or the `compact` row\n- **message** - The hint/error message area under the drop zone (always reserved unless `hide-message`)\n- **list** - The list of file entries and rejected files\n- **entry** - One file entry's row\n- **rejected** - One rejected file's row\n- **progress** - The progress track along an uploading row's bottom edge\n- **progress-bar** - The bar inside it showing the row's upload progress, or its looping sweep while indeterminate",
820
820
  "attributes": [
821
821
  {
822
822
  "name": "accept",
@@ -908,7 +908,7 @@
908
908
  },
909
909
  {
910
910
  "name": "c-icon-button",
911
- "description": "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.\n---\n\n\n### **Slots:**\n - **default** - The icon: a `c-icon` or an `<svg>`; it wins over `path`\n\n### **CSS Parts:**\n - **root** - The native `<button>` element carrying the visual styling\n- **content** - Inner wrapper around the slotted icon or loading spinner\n- **badge** - The count bubble at the button's top-right corner, shown by `badge`",
911
+ "description": "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.\n---\n\n\n### **Methods:**\n - **focus()** - Focus its button, as `focus()` does on a native button: the element renders\nno box of its own to take it.\n\n### **Slots:**\n - **default** - The icon: a `c-icon` or an `<svg>`; it wins over `path`\n\n### **CSS Parts:**\n - **root** - The native `<button>` element carrying the visual styling\n- **content** - Inner wrapper around the slotted icon or loading spinner\n- **badge** - The count bubble at the button's top-right corner, shown by `badge`",
912
912
  "attributes": [
913
913
  {
914
914
  "name": "appearance",
@@ -1664,16 +1664,16 @@
1664
1664
  },
1665
1665
  {
1666
1666
  "name": "c-progress-bar",
1667
- "description": "A horizontal progress bar that fills a track to a known completion percentage, with an optional details line showing the value and a label.\n---\n\n\n### **CSS Parts:**\n - **root** - The outer flex wrapper around the bar and the details line\n- **bar** - The visible track of the progress bar, wrapping the native `<progress>` element\n- **details** - The percentage and label text line",
1667
+ "description": "A horizontal progress bar that fills a track to a known completion percentage, with an optional details line showing the value and a label.\n---\n\n\n### **CSS Parts:**\n - **root** - The outer flex wrapper around the progress track and the details line\n- **track** - The progress track: the ground the bar grows along, carrying the progressbar role. Its padding is the frame around the bar\n- **bar** - The bar showing the value: the fill, or the looping sweep while indeterminate\n- **details** - The percentage and label text line",
1668
1668
  "attributes": [
1669
1669
  {
1670
1670
  "name": "hide-details",
1671
- "description": "Hides the details line (the percentage and `label`); `label` still\nnames the bar.",
1671
+ "description": "Hides the details line (the percentage and `label`); `label` still\nnames the progress bar.",
1672
1672
  "values": []
1673
1673
  },
1674
1674
  {
1675
1675
  "name": "indeterminate",
1676
- "description": "Replaces the fill with a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
1676
+ "description": "Turns the bar into a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
1677
1677
  "values": []
1678
1678
  },
1679
1679
  {
@@ -1683,12 +1683,12 @@
1683
1683
  },
1684
1684
  {
1685
1685
  "name": "single-line",
1686
- "description": "Places the details line beside the bar instead of below it.",
1686
+ "description": "Places the details line beside the progress track instead of below it.",
1687
1687
  "values": []
1688
1688
  },
1689
1689
  {
1690
1690
  "name": "value",
1691
- "description": "Completion percentage, 0 to 100. The fill clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
1691
+ "description": "Completion percentage, 0 to 100. The bar clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
1692
1692
  "values": []
1693
1693
  }
1694
1694
  ],
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
3
3
  "name": "@cscfi/csc-ui",
4
- "version": "4.0.0-rc.5",
4
+ "version": "4.0.0-rc.7",
5
5
  "description-markup": "markdown",
6
6
  "contributions": {
7
7
  "html": {
@@ -694,7 +694,7 @@
694
694
  },
695
695
  {
696
696
  "name": "c-button",
697
- "description": "Buttons trigger actions — submitting a form, opening a modal, confirming a choice. Use one filled button (the default `appearance`) per view for its main action; other actions use `appearance=\"outlined\"`, `\"ghost\"` or `\"text\"`.\n---\n\n\n### **Slots:**\n - **default** - Button label content, or a slotted `<button>` (ADR-0085):\nthe page's own native button, which a password manager reading the form's\nsubmit button finds. Its own `type`, `disabled`, `name`, `value` and\n`form` apply; the element paints its look.\n- **icon** - Leading icon, vertically centered before the label.\n- **description** - Secondary text rendered below the label.\n\n### **CSS Parts:**\n - **root** - The native `<button>` / `<a>` element carrying the visual styling.\n- **content** - Layout wrapper for the label, icon and description.\n- **description** - Wrapper of the `description` slot.",
697
+ "description": "Buttons trigger actions — submitting a form, opening a modal, confirming a choice. Use one filled button (the default `appearance`) per view for its main action; other actions use `appearance=\"outlined\"`, `\"ghost\"` or `\"text\"`.\n---\n\n\n### **Methods:**\n - **focus()** - Focus its button — its link under `href`, or the slotted button — as\n`focus()` does on a native button: the element renders no box of its own to\ntake it.\n\n### **Slots:**\n - **default** - Button label content, or a slotted `<button>` (ADR-0085):\nthe page's own native button, which a password manager reading the form's\nsubmit button finds. Its own `type`, `disabled`, `name`, `value` and\n`form` apply; the element paints its look.\n- **icon** - Leading icon, vertically centered before the label.\n- **description** - Secondary text rendered below the label.\n\n### **CSS Parts:**\n - **root** - The native `<button>` / `<a>` element carrying the visual styling.\n- **content** - Layout wrapper for the label, icon and description.\n- **description** - Wrapper of the `description` slot.",
698
698
  "doc-url": "",
699
699
  "attributes": [
700
700
  {
@@ -2483,7 +2483,7 @@
2483
2483
  },
2484
2484
  {
2485
2485
  "name": "c-file-upload",
2486
- "description": "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.\n---\n\n\n### **Events:**\n - **change** - Fired with the new list of file entries.\n- **input** - Native bubbling input event fired with every value change so a plain Vue\n`v-model` works. No detail.\n- **reject** - Fired after an add that refused files, listing each with its reason —\na type outside `accept`, a file over `max-size`, a file already held,\none beyond `max-files`, or a folder. The refused files never join the\nvalue.\n- **update:value** - v-model contract event, fired with `change`.\n\n### **Methods:**\n - **focus()** - Focus its drop zone's button, as `focus()` does on a native control: the element renders\nno box of its own to take it.\n- **startUploads()** - Queue every `local` file entry for the upload function — how a `manual`\nfield starts; files added after the call wait for the next one. Fires the\nvalue events once when it starts any. Does nothing without an upload function\n\n### **CSS Parts:**\n - **root** - The field: label, drop zone, message line and file list. The whole of it takes a drop\n- **label** - The label above the drop zone\n- **drop-zone** - The dashed drop zone — the large button, or the `compact` row\n- **message** - The hint/error message area under the drop zone (always reserved unless `hide-message`)\n- **list** - The list of file entries and rejected files\n- **entry** - One file entry's row\n- **rejected** - One rejected file's row\n- **progress** - The progress bar along an uploading row's bottom edge",
2486
+ "description": "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.\n---\n\n\n### **Events:**\n - **change** - Fired with the new list of file entries.\n- **input** - Native bubbling input event fired with every value change so a plain Vue\n`v-model` works. No detail.\n- **reject** - Fired after an add that refused files, listing each with its reason —\na type outside `accept`, a file over `max-size`, a file already held,\none beyond `max-files`, or a folder. The refused files never join the\nvalue.\n- **update:value** - v-model contract event, fired with `change`.\n\n### **Methods:**\n - **focus()** - Focus its drop zone's button, as `focus()` does on a native control: the element renders\nno box of its own to take it.\n- **startUploads()** - Queue every `local` file entry for the upload function — how a `manual`\nfield starts; files added after the call wait for the next one. Fires the\nvalue events once when it starts any. Does nothing without an upload function\n\n### **CSS Parts:**\n - **root** - The field: label, drop zone, message line and file list. The whole of it takes a drop\n- **label** - The label above the drop zone\n- **drop-zone** - The dashed drop zone — the large button, or the `compact` row\n- **message** - The hint/error message area under the drop zone (always reserved unless `hide-message`)\n- **list** - The list of file entries and rejected files\n- **entry** - One file entry's row\n- **rejected** - One rejected file's row\n- **progress** - The progress track along an uploading row's bottom edge\n- **progress-bar** - The bar inside it showing the row's upload progress, or its looping sweep while indeterminate",
2487
2487
  "doc-url": "",
2488
2488
  "attributes": [
2489
2489
  {
@@ -2802,7 +2802,7 @@
2802
2802
  },
2803
2803
  {
2804
2804
  "name": "c-icon-button",
2805
- "description": "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.\n---\n\n\n### **Slots:**\n - **default** - The icon: a `c-icon` or an `<svg>`; it wins over `path`\n\n### **CSS Parts:**\n - **root** - The native `<button>` element carrying the visual styling\n- **content** - Inner wrapper around the slotted icon or loading spinner\n- **badge** - The count bubble at the button's top-right corner, shown by `badge`",
2805
+ "description": "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.\n---\n\n\n### **Methods:**\n - **focus()** - Focus its button, as `focus()` does on a native button: the element renders\nno box of its own to take it.\n\n### **Slots:**\n - **default** - The icon: a `c-icon` or an `<svg>`; it wins over `path`\n\n### **CSS Parts:**\n - **root** - The native `<button>` element carrying the visual styling\n- **content** - Inner wrapper around the slotted icon or loading spinner\n- **badge** - The count bubble at the button's top-right corner, shown by `badge`",
2806
2806
  "doc-url": "",
2807
2807
  "attributes": [
2808
2808
  {
@@ -4845,12 +4845,12 @@
4845
4845
  },
4846
4846
  {
4847
4847
  "name": "c-progress-bar",
4848
- "description": "A horizontal progress bar that fills a track to a known completion percentage, with an optional details line showing the value and a label.\n---\n\n\n### **CSS Parts:**\n - **root** - The outer flex wrapper around the bar and the details line\n- **bar** - The visible track of the progress bar, wrapping the native `<progress>` element\n- **details** - The percentage and label text line",
4848
+ "description": "A horizontal progress bar that fills a track to a known completion percentage, with an optional details line showing the value and a label.\n---\n\n\n### **CSS Parts:**\n - **root** - The outer flex wrapper around the progress track and the details line\n- **track** - The progress track: the ground the bar grows along, carrying the progressbar role. Its padding is the frame around the bar\n- **bar** - The bar showing the value: the fill, or the looping sweep while indeterminate\n- **details** - The percentage and label text line",
4849
4849
  "doc-url": "",
4850
4850
  "attributes": [
4851
4851
  {
4852
4852
  "name": "hide-details",
4853
- "description": "Hides the details line (the percentage and `label`); `label` still\nnames the bar.",
4853
+ "description": "Hides the details line (the percentage and `label`); `label` still\nnames the progress bar.",
4854
4854
  "value": {
4855
4855
  "type": "boolean",
4856
4856
  "default": "false"
@@ -4858,7 +4858,7 @@
4858
4858
  },
4859
4859
  {
4860
4860
  "name": "indeterminate",
4861
- "description": "Replaces the fill with a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
4861
+ "description": "Turns the bar into a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
4862
4862
  "value": {
4863
4863
  "type": "boolean",
4864
4864
  "default": "false"
@@ -4874,7 +4874,7 @@
4874
4874
  },
4875
4875
  {
4876
4876
  "name": "single-line",
4877
- "description": "Places the details line beside the bar instead of below it.",
4877
+ "description": "Places the details line beside the progress track instead of below it.",
4878
4878
  "value": {
4879
4879
  "type": "boolean",
4880
4880
  "default": "false"
@@ -4882,7 +4882,7 @@
4882
4882
  },
4883
4883
  {
4884
4884
  "name": "value",
4885
- "description": "Completion percentage, 0 to 100. The fill clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
4885
+ "description": "Completion percentage, 0 to 100. The bar clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
4886
4886
  "value": {
4887
4887
  "type": "number",
4888
4888
  "default": "0"
@@ -4895,12 +4895,12 @@
4895
4895
  "properties": [
4896
4896
  {
4897
4897
  "name": "hideDetails",
4898
- "description": "Hides the details line (the percentage and `label`); `label` still\nnames the bar.",
4898
+ "description": "Hides the details line (the percentage and `label`); `label` still\nnames the progress bar.",
4899
4899
  "type": "boolean"
4900
4900
  },
4901
4901
  {
4902
4902
  "name": "indeterminate",
4903
- "description": "Replaces the fill with a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
4903
+ "description": "Turns the bar into a looping sweep for work of unknown duration,\nhiding the details line and exposing no value.",
4904
4904
  "type": "boolean"
4905
4905
  },
4906
4906
  {
@@ -4910,12 +4910,12 @@
4910
4910
  },
4911
4911
  {
4912
4912
  "name": "singleLine",
4913
- "description": "Places the details line beside the bar instead of below it.",
4913
+ "description": "Places the details line beside the progress track instead of below it.",
4914
4914
  "type": "boolean"
4915
4915
  },
4916
4916
  {
4917
4917
  "name": "value",
4918
- "description": "Completion percentage, 0 to 100. The fill clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
4918
+ "description": "Completion percentage, 0 to 100. The bar clamps a value outside that\nrange; the details line shows it as given, a negative one in the error\ncolour.",
4919
4919
  "type": "number"
4920
4920
  }
4921
4921
  ],
@@ -8733,7 +8733,11 @@
8733
8733
  },
8734
8734
  {
8735
8735
  "name": "part(progress)",
8736
- "description": "The progress bar along an uploading row's bottom edge"
8736
+ "description": "The progress track along an uploading row's bottom edge"
8737
+ },
8738
+ {
8739
+ "name": "part(progress-bar)",
8740
+ "description": "The bar inside it showing the row's upload progress, or its looping sweep while indeterminate"
8737
8741
  },
8738
8742
  {
8739
8743
  "name": "part(root)",
@@ -8953,11 +8957,15 @@
8953
8957
  },
8954
8958
  {
8955
8959
  "name": "part(root)",
8956
- "description": "The outer flex wrapper around the bar and the details line"
8960
+ "description": "The outer flex wrapper around the progress track and the details line"
8961
+ },
8962
+ {
8963
+ "name": "part(track)",
8964
+ "description": "The progress track: the ground the bar grows along, carrying the progressbar role. Its padding is the frame around the bar"
8957
8965
  },
8958
8966
  {
8959
8967
  "name": "part(bar)",
8960
- "description": "The visible track of the progress bar, wrapping the native `<progress>` element"
8968
+ "description": "The bar showing the value: the fill, or the looping sweep while indeterminate"
8961
8969
  },
8962
8970
  {
8963
8971
  "name": "part(details)",
@@ -135,7 +135,9 @@ interface CButtonProps {
135
135
  }
136
136
  declare const _default: typeof __VLS_export;
137
137
  export default _default;
138
- declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<CButtonProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<CButtonProps> & Readonly<{}>, {
138
+ declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<CButtonProps, {
139
+ focus: (options?: FocusOptions) => void;
140
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<CButtonProps> & Readonly<{}>, {
139
141
  text: boolean;
140
142
  outlined: boolean;
141
143
  value: number | string;
@@ -88,7 +88,9 @@ interface CIconButtonProps {
88
88
  }
89
89
  declare const _default: typeof __VLS_export;
90
90
  export default _default;
91
- declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<CIconButtonProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<CIconButtonProps> & Readonly<{}>, {
91
+ declare const __VLS_export: __VLS_WithSlots<import("vue").DefineComponent<CIconButtonProps, {
92
+ focus: (options?: FocusOptions) => void;
93
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<CIconButtonProps> & Readonly<{}>, {
92
94
  path: string;
93
95
  text: boolean;
94
96
  outlined: boolean;
@@ -1,11 +1,11 @@
1
1
  interface CProgressBarProps {
2
2
  /**
3
3
  * Hides the details line (the percentage and `label`); `label` still
4
- * names the bar.
4
+ * names the progress bar.
5
5
  */
6
6
  hideDetails?: boolean;
7
7
  /**
8
- * Replaces the fill with a looping sweep for work of unknown duration,
8
+ * Turns the bar into a looping sweep for work of unknown duration,
9
9
  * hiding the details line and exposing no value.
10
10
  */
11
11
  indeterminate?: boolean;
@@ -17,11 +17,11 @@ interface CProgressBarProps {
17
17
  */
18
18
  label?: string;
19
19
  /**
20
- * Places the details line beside the bar instead of below it.
20
+ * Places the details line beside the progress track instead of below it.
21
21
  */
22
22
  singleLine?: boolean;
23
23
  /**
24
- * Completion percentage, 0 to 100. The fill clamps a value outside that
24
+ * Completion percentage, 0 to 100. The bar clamps a value outside that
25
25
  * range; the details line shows it as given, a negative one in the error
26
26
  * colour.
27
27
  */
@@ -345,6 +345,12 @@ export interface CButtonElement extends Omit<HTMLElement, 'active' | 'appearance
345
345
  * for a destructive action.
346
346
  */
347
347
  variant?: 'danger' | 'info' | 'primary' | 'secondary' | 'success' | 'warning';
348
+ /**
349
+ * Focus its button — its link under `href`, or the slotted button — as
350
+ * `focus()` does on a native button: the element renders no box of its own to
351
+ * take it.
352
+ */
353
+ focus(options?: FocusOptions): void;
348
354
  }
349
355
  /** Events dispatched by `<c-button-group>`. */
350
356
  export interface CButtonGroupElementEventMap {
@@ -1056,6 +1062,11 @@ export interface CIconButtonElement extends Omit<HTMLElement, 'appearance' | 'ba
1056
1062
  * for a destructive action.
1057
1063
  */
1058
1064
  variant?: 'danger' | 'info' | 'primary' | 'secondary' | 'success' | 'warning';
1065
+ /**
1066
+ * Focus its button, as `focus()` does on a native button: the element renders
1067
+ * no box of its own to take it.
1068
+ */
1069
+ focus(options?: FocusOptions): void;
1059
1070
  }
1060
1071
  /** A text link to another page or resource: a native `<a>` in the link colour, with an optional underline. */
1061
1072
  export interface CLinkElement extends Omit<HTMLElement, 'href' | 'target' | 'underline'> {
@@ -1613,11 +1624,11 @@ export interface CPopoverElement extends Omit<HTMLElement, 'distance' | 'heading
1613
1624
  export interface CProgressBarElement extends Omit<HTMLElement, 'hideDetails' | 'indeterminate' | 'label' | 'singleLine' | 'value'> {
1614
1625
  /**
1615
1626
  * Hides the details line (the percentage and `label`); `label` still
1616
- * names the bar.
1627
+ * names the progress bar.
1617
1628
  */
1618
1629
  hideDetails?: boolean;
1619
1630
  /**
1620
- * Replaces the fill with a looping sweep for work of unknown duration,
1631
+ * Turns the bar into a looping sweep for work of unknown duration,
1621
1632
  * hiding the details line and exposing no value.
1622
1633
  */
1623
1634
  indeterminate?: boolean;
@@ -1626,10 +1637,10 @@ export interface CProgressBarElement extends Omit<HTMLElement, 'hideDetails' | '
1626
1637
  * accessible name.
1627
1638
  */
1628
1639
  label?: string;
1629
- /** Places the details line beside the bar instead of below it. */
1640
+ /** Places the details line beside the progress track instead of below it. */
1630
1641
  singleLine?: boolean;
1631
1642
  /**
1632
- * Completion percentage, 0 to 100. The fill clamps a value outside that
1643
+ * Completion percentage, 0 to 100. The bar clamps a value outside that
1633
1644
  * range; the details line shows it as given, a negative one in the error
1634
1645
  * colour.
1635
1646
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cscfi/csc-ui",
3
- "version": "4.0.0-rc.5",
3
+ "version": "4.0.0-rc.7",
4
4
  "description": "The CSC Design System's components as native custom elements: one set of c-* tags for plain HTML, Vue, React and Angular.",
5
5
  "type": "module",
6
6
  "main": "./dist/csc-ui.js",