@fusion.dev/helix-headless 0.105.0 → 0.106.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/custom-elements.json +7324 -3890
- package/dist/accordion/item/accordion-item.d.ts +17 -16
- package/dist/accordion/root/accordion-root.d.ts +13 -17
- package/dist/announcement/root/announcement-root.d.ts +24 -31
- package/dist/app-header/root/app-header-root.d.ts +14 -14
- package/dist/area-chart/root/area-chart-root.d.ts +29 -48
- package/dist/avatar/group/avatar-group.d.ts +6 -8
- package/dist/avatar/root/avatar-root.d.ts +11 -11
- package/dist/badge/root/badge-root.d.ts +14 -15
- package/dist/bar-chart/root/bar-chart-root.d.ts +40 -44
- package/dist/blockquote/root/blockquote-root.d.ts +5 -7
- package/dist/breadcrumbs/breadcrumb/breadcrumb.d.ts +25 -33
- package/dist/breadcrumbs/root/breadcrumbs-root.d.ts +12 -11
- package/dist/button/root/button-root.d.ts +16 -17
- package/dist/button-group/root/button-group-root.d.ts +9 -10
- package/dist/callout/root/callout-root.d.ts +10 -15
- package/dist/canvas/edge/canvas-edge.d.ts +21 -21
- package/dist/canvas/node/canvas-node.d.ts +43 -45
- package/dist/canvas/root/canvas-root.d.ts +100 -99
- package/dist/card/root/card-root.d.ts +10 -12
- package/dist/carousel/root/carousel-root.d.ts +32 -33
- package/dist/chat/composer/chat-composer.d.ts +24 -26
- package/dist/chat/message/chat-message.d.ts +30 -33
- package/dist/chat/root/chat-root.d.ts +63 -80
- package/dist/checkbox/root/checkbox-root.d.ts +30 -32
- package/dist/checkbox-group/root/checkbox-group-root.d.ts +25 -25
- package/dist/code/root/code-root.d.ts +6 -10
- package/dist/code-block/root/code-block-root.d.ts +35 -48
- package/dist/color-input/root/color-input-root.d.ts +52 -56
- package/dist/color-picker/root/color-picker-root.d.ts +49 -49
- package/dist/combobox/root/combobox-root.d.ts +52 -53
- package/dist/command/root/command-root.d.ts +35 -40
- package/dist/copy-button/root/copy-button-root.d.ts +24 -26
- package/dist/data-table/root/data-table-root.d.ts +106 -107
- package/dist/date-input/root/date-input-root.d.ts +54 -53
- package/dist/date-picker/root/date-picker-root.d.ts +25 -21
- package/dist/description-list/item/description-list-item.d.ts +7 -7
- package/dist/description-list/root/description-list-root.d.ts +10 -15
- package/dist/dialog/root/dialog-root.d.ts +22 -19
- package/dist/divider/root/divider-root.d.ts +12 -13
- package/dist/donut-chart/root/donut-chart-root.d.ts +19 -20
- package/dist/drawer/root/drawer-root.d.ts +19 -18
- package/dist/drilldown/item/drilldown-item.d.ts +28 -28
- package/dist/drilldown/root/drilldown-root.d.ts +22 -28
- package/dist/element-events.generated.js +7 -0
- package/dist/empty/root/empty-root.d.ts +16 -19
- package/dist/file-input/root/file-input-root.d.ts +32 -32
- package/dist/filter-input/chip/filter-chip.d.ts +36 -39
- package/dist/filter-input/field/filter-field.d.ts +25 -31
- package/dist/filter-input/menu/filter-menu.d.ts +50 -47
- package/dist/filter-input/operator/filter-operator.d.ts +15 -20
- package/dist/filter-input/root/filter-input-root.d.ts +80 -98
- package/dist/format-date/root/format-date-root.d.ts +19 -27
- package/dist/heatmap/root/heatmap-root.d.ts +40 -41
- package/dist/icon/root/icon-root.d.ts +21 -23
- package/dist/icon-button/root/icon-button-root.d.ts +12 -14
- package/dist/image/root/image-root.d.ts +30 -30
- package/dist/input/root/input-root.d.ts +36 -35
- package/dist/kbd/root/kbd-root.d.ts +13 -15
- package/dist/legend/root/legend-root.d.ts +18 -16
- package/dist/lightbox/item/lightbox-item.d.ts +13 -15
- package/dist/lightbox/root/lightbox-root.d.ts +40 -41
- package/dist/line-chart/root/line-chart-root.d.ts +20 -29
- package/dist/list/item/list-item.d.ts +17 -22
- package/dist/list/root/list-root.d.ts +6 -7
- package/dist/listbox/root/listbox-root.d.ts +42 -41
- package/dist/loader/root/loader-root.d.ts +16 -20
- package/dist/map/area/map-area.d.ts +6 -0
- package/dist/map/area/map-area.js +3 -0
- package/dist/map/buildings/map-buildings.d.ts +45 -0
- package/dist/map/buildings/map-buildings.js +37 -0
- package/dist/map/contours/map-contours.d.ts +61 -0
- package/dist/map/contours/map-contours.js +54 -0
- package/dist/map/index.d.ts +7 -0
- package/dist/map/index.js +5 -0
- package/dist/map/landcover/map-landcover.d.ts +47 -0
- package/dist/map/landcover/map-landcover.js +37 -0
- package/dist/map/marker/map-marker.d.ts +11 -4
- package/dist/map/marker/map-marker.js +13 -1
- package/dist/map/points/map-points.d.ts +7 -1
- package/dist/map/points/map-points.js +3 -0
- package/dist/map/raster/map-raster.d.ts +84 -0
- package/dist/map/raster/map-raster.js +96 -0
- package/dist/map/root/map-root.d.ts +169 -7
- package/dist/map/root/map-root.js +352 -4
- package/dist/map/route/map-route.d.ts +6 -0
- package/dist/map/route/map-route.js +3 -0
- package/dist/map/terrain/map-terrain.d.ts +68 -0
- package/dist/map/terrain/map-terrain.js +58 -0
- package/dist/megamenu/root/megamenu-root.d.ts +27 -25
- package/dist/menu/item/menu-item.d.ts +30 -31
- package/dist/menu/root/menu-root.d.ts +25 -29
- package/dist/meter/root/meter-root.d.ts +22 -21
- package/dist/navigation/root/navigation-root.d.ts +13 -16
- package/dist/notifications/group/notification-group.d.ts +27 -28
- package/dist/notifications/notification/notification.d.ts +35 -42
- package/dist/notifications/root/notifications-root.d.ts +22 -24
- package/dist/number-input/root/number-input-root.d.ts +46 -50
- package/dist/object-inspector/root/object-inspector-root.d.ts +46 -58
- package/dist/option/group/option-group.d.ts +11 -11
- package/dist/option/root/option-root.d.ts +28 -33
- package/dist/outline/root/outline-root.d.ts +18 -17
- package/dist/pagination/root/pagination-root.d.ts +37 -39
- package/dist/pagination/size/pagination-size.d.ts +37 -43
- package/dist/pagination/summary/pagination-summary.d.ts +12 -14
- package/dist/pin-input/root/pin-input-root.d.ts +32 -38
- package/dist/popover/root/popover-root.d.ts +16 -21
- package/dist/progress/root/progress-root.d.ts +16 -14
- package/dist/qr-code/root/qr-code-root.d.ts +22 -25
- package/dist/quote/root/quote-root.d.ts +5 -6
- package/dist/radio/group/radio-group.d.ts +26 -28
- package/dist/radio/root/radio-root.d.ts +24 -28
- package/dist/rating/root/rating-root.d.ts +27 -30
- package/dist/scatter-chart/root/scatter-chart-root.d.ts +43 -55
- package/dist/scroll-area/root/scroll-area-root.d.ts +15 -21
- package/dist/select/root/select-root.d.ts +41 -44
- package/dist/skeleton/root/skeleton-root.d.ts +7 -8
- package/dist/skip-link/root/skip-link-root.d.ts +21 -28
- package/dist/slider/root/slider-root.d.ts +36 -39
- package/dist/sparkline/root/sparkline-root.d.ts +22 -28
- package/dist/speed-dial/item/speed-dial-item.d.ts +21 -21
- package/dist/speed-dial/root/speed-dial-root.d.ts +25 -27
- package/dist/splitter/root/splitter-root.d.ts +37 -41
- package/dist/stat/group/stat-group.d.ts +4 -4
- package/dist/stat/root/stat-root.d.ts +8 -9
- package/dist/steps/root/steps-root.d.ts +11 -14
- package/dist/steps/step/step.d.ts +22 -29
- package/dist/switch/root/switch-root.d.ts +20 -24
- package/dist/table/cell/table-cell.d.ts +18 -8
- package/dist/table/cell/table-cell.js +5 -1
- package/dist/table/column/table-column.d.ts +62 -55
- package/dist/table/root/table-root.d.ts +16 -17
- package/dist/table/row/table-row.d.ts +3 -3
- package/dist/tabs/panel/tab-panel.d.ts +3 -3
- package/dist/tabs/root/tabs-root.d.ts +19 -17
- package/dist/tabs/tab/tab.d.ts +6 -6
- package/dist/tag/root/tag-root.d.ts +11 -12
- package/dist/textarea/root/textarea-root.d.ts +29 -32
- package/dist/time-input/root/time-input-root.d.ts +70 -69
- package/dist/time-picker/root/time-picker-root.d.ts +58 -66
- package/dist/timeline/item/timeline-item.d.ts +18 -24
- package/dist/timeline/root/timeline-root.d.ts +13 -21
- package/dist/toast/item/toast-item.d.ts +21 -22
- package/dist/toast/root/toast-root.d.ts +18 -23
- package/dist/toggle/group/toggle-group.d.ts +23 -25
- package/dist/toggle/root/toggle-root.d.ts +8 -8
- package/dist/toolbar/root/toolbar-root.d.ts +7 -10
- package/dist/tooltip/root/tooltip-root.d.ts +41 -47
- package/dist/tour/root/tour-root.d.ts +24 -26
- package/dist/tour/stop/tour-stop.d.ts +39 -48
- package/dist/tree/item/tree-item.d.ts +23 -25
- package/dist/tree/root/tree-root.d.ts +13 -12
- package/dist/trend/root/trend-root.d.ts +18 -19
- package/dist/video/root/video-root.d.ts +108 -101
- package/dist/video-playlist/item/video-playlist-item.d.ts +23 -28
- package/dist/video-playlist/menu/video-playlist-menu.d.ts +17 -21
- package/dist/video-playlist/root/video-playlist-root.d.ts +21 -25
- package/dist/virtual-list/root/virtual-list-root.d.ts +27 -26
- package/package.json +5 -5
- package/types/jsx.d.ts +10363 -9520
- package/types/svelte.d.ts +5 -0
- package/types/vue.d.ts +1440 -1032
|
@@ -5,30 +5,27 @@ declare const HelixHeadlessSlider_base: (new (...args: any[]) => import("@fusion
|
|
|
5
5
|
* @summary A value chosen from a range by dragging.
|
|
6
6
|
*
|
|
7
7
|
* @description
|
|
8
|
-
*
|
|
9
|
-
* page keys and the touch target
|
|
10
|
-
*
|
|
11
|
-
* platform for a finger.
|
|
8
|
+
* Renders a native `<input type="range">`, so the drag, the arrow keys, Home,
|
|
9
|
+
* End, the page keys, and the touch target come from the platform. A native
|
|
10
|
+
* range has a hit area larger than its thumb, sized for a finger.
|
|
12
11
|
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* value. `valueAsNumber` is there for arithmetic.
|
|
12
|
+
* The value is a string, like every other form control's, and
|
|
13
|
+
* `MixinControllerValue` holds text. Use `valueAsNumber` for arithmetic.
|
|
16
14
|
*
|
|
17
|
-
*
|
|
18
|
-
* styled and
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
15
|
+
* Marks are drawn by the component. The ticks of a `<datalist>` cannot be
|
|
16
|
+
* styled, and Firefox does not render them for a range. Marks are decoration.
|
|
17
|
+
* `step` sets where the value can land, and the input enforces it whether or
|
|
18
|
+
* not marks are drawn. `markers` is a count, so a slider from zero to a hundred
|
|
19
|
+
* does not draw a hundred and one marks by accident.
|
|
22
20
|
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
21
|
+
* A range with two thumbs is two inputs stacked on one track, because there is
|
|
22
|
+
* no native two-thumb range. Each thumb keeps its own value.
|
|
25
23
|
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
* off the control and the marker beside the label is all it does.
|
|
24
|
+
* `required` comes with the field mixin and cannot fail. A range is never
|
|
25
|
+
* empty: the platform shows its midpoint when no value is set, and `willUpdate`
|
|
26
|
+
* seeds that midpoint into `defaultValue`, so the value matches the handle from
|
|
27
|
+
* the first render. HTML does not apply `required` to a range either, so it is
|
|
28
|
+
* not set on the input. It only adds the marker beside the label.
|
|
32
29
|
*
|
|
33
30
|
* @since 0.1.0
|
|
34
31
|
* @status stable
|
|
@@ -36,33 +33,33 @@ declare const HelixHeadlessSlider_base: (new (...args: any[]) => import("@fusion
|
|
|
36
33
|
* @aliases Range, Range input
|
|
37
34
|
* @documentation https://fusion.dev/helix/components/slider
|
|
38
35
|
*
|
|
39
|
-
* @event {Event} change -
|
|
40
|
-
* @event {HelixBeforeChangeEvent} helix-before-change - Fired as the value changes
|
|
41
|
-
* @event {Event} input -
|
|
36
|
+
* @event {Event} change - Fired when the user releases the thumb.
|
|
37
|
+
* @event {HelixBeforeChangeEvent} helix-before-change - Fired as the value changes. Cancelable: call `preventDefault()` to keep the current value.
|
|
38
|
+
* @event {Event} input - Fired after the value changes.
|
|
42
39
|
*
|
|
43
40
|
* @csspart control - The range input.
|
|
44
|
-
* @csspart feedback -
|
|
45
|
-
* @csspart field - The row
|
|
46
|
-
* @csspart hint -
|
|
47
|
-
* @csspart label - The
|
|
48
|
-
* @csspart marker - One mark.
|
|
41
|
+
* @csspart feedback - The error message under the track.
|
|
42
|
+
* @csspart field - The row that holds the control and its readout.
|
|
43
|
+
* @csspart hint - The help text under the track, shown while there is no error.
|
|
44
|
+
* @csspart label - The label above the track.
|
|
45
|
+
* @csspart marker - One mark on the track.
|
|
49
46
|
* @csspart marker-label - The value a mark stands at, when `marker-labels` is set.
|
|
50
47
|
* @csspart markers - The row of marks along the track.
|
|
51
|
-
* @csspart output - The current value, shown beside
|
|
48
|
+
* @csspart output - The current value, shown beside the track.
|
|
52
49
|
*
|
|
53
50
|
* @cssproperty --slider-fraction - The value as a fraction of the range, 0 to 1.
|
|
54
51
|
* @cssproperty --slider-from - Where a range's filled span starts, as a fraction of the track, 0 to 1.
|
|
55
52
|
* @cssproperty --slider-marker-at - Where one marker sits, as a percentage of the track.
|
|
56
53
|
* @cssproperty --slider-to - Where a range's filled span ends, as a fraction of the track, 0 to 1.
|
|
57
54
|
*
|
|
58
|
-
* @cssstate invalid -
|
|
55
|
+
* @cssstate invalid - The slider has an error to show, from the browser's validation or from your `feedback`.
|
|
59
56
|
*/
|
|
60
57
|
export declare class HelixHeadlessSlider extends HelixHeadlessSlider_base {
|
|
61
58
|
protected readonly aria: AriaForwardController;
|
|
62
59
|
/** Typed or dragged, so every edit is announced. See `announcesInput`. */
|
|
63
60
|
protected readonly announcesInput = true;
|
|
64
61
|
/**
|
|
65
|
-
*
|
|
62
|
+
* Shows the value at each mark.
|
|
66
63
|
*/
|
|
67
64
|
markerLabels: boolean;
|
|
68
65
|
/**
|
|
@@ -82,11 +79,11 @@ export declare class HelixHeadlessSlider extends HelixHeadlessSlider_base {
|
|
|
82
79
|
*/
|
|
83
80
|
markers: number;
|
|
84
81
|
/**
|
|
85
|
-
* The largest value
|
|
82
|
+
* The largest value that can be chosen.
|
|
86
83
|
*/
|
|
87
84
|
max: number;
|
|
88
85
|
/**
|
|
89
|
-
*
|
|
86
|
+
* The name of a range's upper thumb, read after the slider's label.
|
|
90
87
|
*
|
|
91
88
|
* **Named with the label rather than instead of it.** Each thumb was
|
|
92
89
|
* `aria-label="${label} maximum"`, which overrode the `<label>` and read the
|
|
@@ -96,13 +93,13 @@ export declare class HelixHeadlessSlider extends HelixHeadlessSlider_base {
|
|
|
96
93
|
*/
|
|
97
94
|
maximumLabel: string;
|
|
98
95
|
/**
|
|
99
|
-
* The smallest value
|
|
96
|
+
* The smallest value that can be chosen.
|
|
100
97
|
*/
|
|
101
98
|
min: number;
|
|
102
|
-
/**
|
|
99
|
+
/** The name of a range's lower thumb, read after the slider's label. */
|
|
103
100
|
minimumLabel: string;
|
|
104
101
|
/**
|
|
105
|
-
*
|
|
102
|
+
* The direction the track runs. `vertical` stands it on end.
|
|
106
103
|
*
|
|
107
104
|
* For a level rather than a quantity: a fader, a channel, anything a reader
|
|
108
105
|
* pictures as high and low rather than as less and more. Absent is
|
|
@@ -115,7 +112,7 @@ export declare class HelixHeadlessSlider extends HelixHeadlessSlider_base {
|
|
|
115
112
|
*/
|
|
116
113
|
orientation?: 'horizontal' | 'vertical';
|
|
117
114
|
/**
|
|
118
|
-
*
|
|
115
|
+
* Adds a second thumb, so the value is a pair.
|
|
119
116
|
*
|
|
120
117
|
* The pair is one string, `"10,50"`, which is what a form submits and what
|
|
121
118
|
* `MixinControllerValue` already holds. `valueAsNumber` reads the lower of
|
|
@@ -123,7 +120,7 @@ export declare class HelixHeadlessSlider extends HelixHeadlessSlider_base {
|
|
|
123
120
|
*/
|
|
124
121
|
range: boolean;
|
|
125
122
|
/**
|
|
126
|
-
*
|
|
123
|
+
* Shows the chosen value beside the track.
|
|
127
124
|
*/
|
|
128
125
|
showValue: boolean;
|
|
129
126
|
/**
|
|
@@ -214,7 +211,7 @@ export declare class HelixHeadlessSlider extends HelixHeadlessSlider_base {
|
|
|
214
211
|
private snapped;
|
|
215
212
|
protected willUpdate(changed: PropertyValues): void;
|
|
216
213
|
protected updated(changed: PropertyValues): void;
|
|
217
|
-
/** How far one press of an arrow key moves
|
|
214
|
+
/** How far one press of an arrow key moves the thumb. */
|
|
218
215
|
step: number;
|
|
219
216
|
protected render(): TemplateResult;
|
|
220
217
|
}
|
|
@@ -1,35 +1,29 @@
|
|
|
1
1
|
import { type Curve, HelixElement, SourceController } from '@fusion.dev/helix-core';
|
|
2
2
|
import { type PropertyValues, type TemplateResult } from 'lit';
|
|
3
3
|
/**
|
|
4
|
-
* @summary A
|
|
4
|
+
* @summary A small chart with no axes that shows the shape of a series beside its number.
|
|
5
5
|
*
|
|
6
6
|
* @description
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* place of the one sentence that carries the meaning, so `values` is the list
|
|
12
|
-
* and `label` is the sentence.
|
|
7
|
+
* Takes its numbers from the `values` attribute. The other charts read a table,
|
|
8
|
+
* but a table behind a small trend line would be read aloud row by row. Set
|
|
9
|
+
* `values` to the data and `label` to the one sentence a screen reader
|
|
10
|
+
* announces.
|
|
13
11
|
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
* table behind it, and it wins where both are given.
|
|
12
|
+
* This follows the library's rule that a content property is the fallback for
|
|
13
|
+
* its slot, as with `Tooltip`'s `content` and `Avatar`'s `name`. Use `for` when
|
|
14
|
+
* a sparkline has a real table behind it. `for` wins when both are set.
|
|
18
15
|
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* stops. So an unlabeled sparkline is `aria-hidden`, and a labeled one is an
|
|
23
|
-
* image named by its sentence.
|
|
16
|
+
* Without a `label` the sparkline is decorative and `aria-hidden`, for example
|
|
17
|
+
* beside a stat that already says "Sessions, 1,102". With a `label` it is an
|
|
18
|
+
* image named by that sentence.
|
|
24
19
|
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
* way.
|
|
20
|
+
* Place it beside a `Stat`, because a change beside a figure is a second fact,
|
|
21
|
+
* as `Stat`'s own spec says. `Trend` is composed the same way.
|
|
28
22
|
*
|
|
29
|
-
* The
|
|
30
|
-
*
|
|
31
|
-
* and CSS cannot,
|
|
32
|
-
* without measuring anything
|
|
23
|
+
* The component writes the properties listed below, and the stylesheet that
|
|
24
|
+
* draws the sparkline reads them. Do not set them yourself. They carry numbers
|
|
25
|
+
* the component computes and CSS cannot, so a stylesheet can draw the sparkline
|
|
26
|
+
* without measuring anything.
|
|
33
27
|
*
|
|
34
28
|
* @since 0.1.0
|
|
35
29
|
* @status stable
|
|
@@ -38,8 +32,8 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
38
32
|
* @documentation https://fusion.dev/helix/components/sparkline
|
|
39
33
|
*
|
|
40
34
|
* @csspart area - The region between the line and the bottom of its range.
|
|
41
|
-
* @csspart bar - One column,
|
|
42
|
-
* @csspart line - The path
|
|
35
|
+
* @csspart bar - One column, drawn when `plot="bar"`.
|
|
36
|
+
* @csspart line - The line's path.
|
|
43
37
|
* @csspart svg - The drawing.
|
|
44
38
|
* @csspart terminus - The mark on the last value.
|
|
45
39
|
* @csspart wash-end - The far stop of the area's gradient.
|
|
@@ -50,7 +44,7 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
50
44
|
*/
|
|
51
45
|
export declare class HelixHeadlessSparkline extends HelixElement {
|
|
52
46
|
/**
|
|
53
|
-
* How the line
|
|
47
|
+
* How the line is drawn from one reading to the next.
|
|
54
48
|
*
|
|
55
49
|
* **`smooth` is the resting curve.** A straight segment asserts nothing about
|
|
56
50
|
* the values between two readings and a curve invents them, which is why
|
|
@@ -79,7 +73,7 @@ export declare class HelixHeadlessSparkline extends HelixElement {
|
|
|
79
73
|
*/
|
|
80
74
|
curve?: Curve;
|
|
81
75
|
/**
|
|
82
|
-
* The id of a table to read
|
|
76
|
+
* The id of a table to read the readings from, when a table holds the data.
|
|
83
77
|
*
|
|
84
78
|
* The first column of numbers is the series drawn. This wins over `values`,
|
|
85
79
|
* because a table is the readable representation and a list of numbers in an
|
|
@@ -90,7 +84,7 @@ export declare class HelixHeadlessSparkline extends HelixElement {
|
|
|
90
84
|
*/
|
|
91
85
|
for: string;
|
|
92
86
|
/**
|
|
93
|
-
*
|
|
87
|
+
* A sentence that describes what the line shows.
|
|
94
88
|
*
|
|
95
89
|
* "Sessions rose from 1,240 to 1,318 and fell to 1,102 over fourteen days" is
|
|
96
90
|
* the accessible representation of a sparkline, and a list of the fourteen
|
|
@@ -1,19 +1,16 @@
|
|
|
1
1
|
import { HelixElement } from '@fusion.dev/helix-core';
|
|
2
2
|
import { type TemplateResult } from 'lit';
|
|
3
3
|
/**
|
|
4
|
-
* @summary One action in a speed dial:
|
|
4
|
+
* @summary One action in a speed dial: an icon and a name beside it.
|
|
5
5
|
*
|
|
6
6
|
* @description
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
* screen can take, which is exactly what `role="menu"` was written for. The
|
|
11
|
-
* roles follow the contents.
|
|
7
|
+
* Each item is a command, so it has the `menuitem` role. A megamenu holds
|
|
8
|
+
* destinations, so it is a disclosure of links. A speed dial holds actions,
|
|
9
|
+
* which is what `role="menu"` is for.
|
|
12
10
|
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
* being there, so it is read, searched and translated like anything else.
|
|
11
|
+
* The name is text rendered beside the icon, and it is the accessible name. A
|
|
12
|
+
* `title` on an icon shows only on hover. Visible text is read, searched, and
|
|
13
|
+
* translated like other text.
|
|
17
14
|
*
|
|
18
15
|
* @since 0.1.0
|
|
19
16
|
* @status stable
|
|
@@ -22,21 +19,21 @@ import { type TemplateResult } from 'lit';
|
|
|
22
19
|
* @documentation https://fusion.dev/helix/components/speed-dial
|
|
23
20
|
*
|
|
24
21
|
* @slot - The action's name.
|
|
25
|
-
* @slot icon - The
|
|
22
|
+
* @slot icon - The action's icon, the main way the action is recognized.
|
|
26
23
|
*
|
|
27
|
-
* @event {HelixSelectEvent} helix-select -
|
|
24
|
+
* @event {HelixSelectEvent} helix-select - The action was chosen. Cancelable: cancel it to keep the dial open.
|
|
28
25
|
*
|
|
29
|
-
* @csspart icon - The
|
|
30
|
-
* @csspart item - The control.
|
|
31
|
-
* @csspart label - The name beside
|
|
26
|
+
* @csspart icon - The box that holds the icon.
|
|
27
|
+
* @csspart item - The control for the action.
|
|
28
|
+
* @csspart label - The action's name, beside the icon.
|
|
32
29
|
*/
|
|
33
30
|
export declare class HelixHeadlessSpeedDialItem extends HelixElement {
|
|
34
31
|
/**
|
|
35
|
-
* Whether the action
|
|
32
|
+
* Whether the action is disabled, so it cannot be chosen.
|
|
36
33
|
*/
|
|
37
34
|
disabled: boolean;
|
|
38
35
|
/**
|
|
39
|
-
*
|
|
36
|
+
* The action's value, sent in `helix-select` when the action is chosen.
|
|
40
37
|
*/
|
|
41
38
|
value: string;
|
|
42
39
|
/**
|
|
@@ -45,14 +42,17 @@ export declare class HelixHeadlessSpeedDialItem extends HelixElement {
|
|
|
45
42
|
* protected. Not a consumer's to read or set.
|
|
46
43
|
*/
|
|
47
44
|
readonly isSpeedDialItem = true;
|
|
48
|
-
/** Puts focus on the control inside
|
|
45
|
+
/** Puts focus on the control inside the item. */
|
|
49
46
|
focus(): void;
|
|
50
|
-
/**
|
|
47
|
+
/**
|
|
48
|
+
* Moves focus to the action. Part of `NavigableItem`, which the shared
|
|
49
|
+
* keyboard controller uses for the arrow keys.
|
|
50
|
+
*/
|
|
51
51
|
focusItem(): void;
|
|
52
|
-
/** Chooses the action,
|
|
52
|
+
/** Chooses the action, the same as pressing it. */
|
|
53
53
|
select(): void;
|
|
54
54
|
/**
|
|
55
|
-
* Whether
|
|
55
|
+
* Whether the action has focus, which is what selected means in a speed dial.
|
|
56
56
|
*
|
|
57
57
|
* Asked of the document rather than of the shadow root: focus lands on the
|
|
58
58
|
* control inside this element and the platform retargets it, so from outside
|
|
@@ -2,29 +2,26 @@ import { HelixElement, KeyboardNavigationController, type Placement, PopoverCont
|
|
|
2
2
|
import { type PropertyValues, type TemplateResult } from 'lit';
|
|
3
3
|
declare const HelixHeadlessSpeedDial_base: (new (...args: any[]) => import("@fusion.dev/helix-core").MixinControllerOpenInterface) & typeof HelixElement;
|
|
4
4
|
/**
|
|
5
|
-
* @summary A button that
|
|
5
|
+
* @summary A floating button that opens a short list of the main actions on a screen.
|
|
6
6
|
*
|
|
7
7
|
* @description
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
* `
|
|
13
|
-
* differs: a dial has no submenus, no headers, no checkable rows and no long
|
|
14
|
-
* list to type ahead through, and shipping it as an appearance of `Menu` would
|
|
15
|
-
* mean defining what a dial with a submenu in it does.
|
|
8
|
+
* A speed dial is a menu. Its items are commands, so it uses `role="menu"` and
|
|
9
|
+
* `menuitem`, and it is built from the same pieces as `Menu`:
|
|
10
|
+
* - `KeyboardNavigationController` for the arrow keys
|
|
11
|
+
* - `PopoverController` for the panel
|
|
12
|
+
* - `MixinControllerOpen` for open and closed
|
|
16
13
|
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
* There is no `helix-fab`, because it would re-declare `emphasis`, `tone`,
|
|
20
|
-
* `label` and a size around a control that already has all four. A round raised
|
|
21
|
-
* button is a shape, and where it sits is `data-dock` in the base layer.
|
|
14
|
+
* It is a separate component because a speed dial has no submenus, headers,
|
|
15
|
+
* checkable items, or type-ahead.
|
|
22
16
|
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
17
|
+
* You slot the trigger. The usual floating action button is `IconButton` with
|
|
18
|
+
* `shape="circle"` and `raised`. There is no `helix-fab`, because `IconButton`
|
|
19
|
+
* already has `emphasis`, `tone`, `label`, and a size. Position the button with
|
|
20
|
+
* `data-dock` in the base layer.
|
|
21
|
+
*
|
|
22
|
+
* All four arrow keys move through the actions, because a speed dial has no
|
|
23
|
+
* nested levels to reserve the horizontal pair for. This is the default
|
|
24
|
+
* behavior of the keyboard controller.
|
|
28
25
|
*
|
|
29
26
|
* @since 0.1.0
|
|
30
27
|
* @status stable
|
|
@@ -33,21 +30,21 @@ declare const HelixHeadlessSpeedDial_base: (new (...args: any[]) => import("@fus
|
|
|
33
30
|
* @documentation https://fusion.dev/helix/components/speed-dial
|
|
34
31
|
*
|
|
35
32
|
* @slot - The actions.
|
|
36
|
-
* @slot trigger - The control that opens
|
|
33
|
+
* @slot trigger - The control that opens the actions. Without one, a button named by `label` is drawn.
|
|
37
34
|
*
|
|
38
|
-
* @event {HelixBeforeCloseEvent} helix-before-close -
|
|
39
|
-
* @event {HelixBeforeOpenEvent} helix-before-open -
|
|
40
|
-
* @event {HelixSelectEvent} helix-select -
|
|
41
|
-
* @event {Event} toggle -
|
|
35
|
+
* @event {HelixBeforeCloseEvent} helix-before-close - The actions are about to close. Cancelable: cancel it to keep them open.
|
|
36
|
+
* @event {HelixBeforeOpenEvent} helix-before-open - The actions are about to open. Cancelable: cancel it to keep them closed.
|
|
37
|
+
* @event {HelixSelectEvent} helix-select - An action was chosen. The action sends the event, and the dial closes after it. Cancelable: cancel it to keep the dial open.
|
|
38
|
+
* @event {Event} toggle - The dial opened or closed. The event carries `newState` and `oldState`.
|
|
42
39
|
*
|
|
43
40
|
* @csspart actions - The region the actions are drawn in.
|
|
44
|
-
* @csspart trigger - The default trigger,
|
|
41
|
+
* @csspart trigger - The default trigger, drawn when none is slotted.
|
|
45
42
|
*
|
|
46
43
|
* @cssstate open - While the actions are out.
|
|
47
44
|
*/
|
|
48
45
|
export declare class HelixHeadlessSpeedDial extends HelixHeadlessSpeedDial_base {
|
|
49
46
|
/**
|
|
50
|
-
*
|
|
47
|
+
* Accessible name for the trigger and the set of actions it opens.
|
|
51
48
|
*/
|
|
52
49
|
label: string;
|
|
53
50
|
/**
|
|
@@ -55,7 +52,8 @@ export declare class HelixHeadlessSpeedDial extends HelixHeadlessSpeedDial_base
|
|
|
55
52
|
*/
|
|
56
53
|
offset: number;
|
|
57
54
|
/**
|
|
58
|
-
*
|
|
55
|
+
* The direction the actions open in. They move to another side if that side
|
|
56
|
+
* does not fit.
|
|
59
57
|
*
|
|
60
58
|
* Up by default, because the control this hangs off is usually docked to the
|
|
61
59
|
* bottom of the window and there is nothing below it to fan into.
|
|
@@ -1,38 +1,32 @@
|
|
|
1
1
|
import { HelixElement } from '@fusion.dev/helix-core';
|
|
2
2
|
import { type PropertyValues, type TemplateResult } from 'lit';
|
|
3
3
|
/**
|
|
4
|
-
* @summary Two panes and a divider
|
|
4
|
+
* @summary Two panes and a divider that you can move.
|
|
5
5
|
*
|
|
6
6
|
* @description
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
* single divider never had.
|
|
7
|
+
* A splitter has one axis. Nest splitters to get two axes and three-pane or
|
|
8
|
+
* four-pane layouts.
|
|
10
9
|
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
* and a splitter with no corner yet is a splitter with two working dividers.
|
|
10
|
+
* When a splitter is slotted into a pane of another at a right angle, a corner
|
|
11
|
+
* handle appears where the dividers cross. It shows the `move` cursor, responds
|
|
12
|
+
* to both arrow axes, and a drag moves both dividers at once. The corner is
|
|
13
|
+
* added at `firstUpdated` and is not in the server markup. Before it appears,
|
|
14
|
+
* both dividers work on their own.
|
|
17
15
|
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
* bounds. A drag in progress is a state
|
|
21
|
-
*
|
|
16
|
+
* The divider has `role="separator"` and `aria-valuenow`. Drag it with a
|
|
17
|
+
* pointer or move it with the arrow keys, and press `Home` or `End` to move it
|
|
18
|
+
* to its bounds. A drag in progress is tracked as a state, so both dividers a
|
|
19
|
+
* corner moves stay lit for as long as they move.
|
|
22
20
|
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
* that stops short of the edge gives a reader no way to put a pane away.
|
|
21
|
+
* By default, `min` and `max` let the divider reach either edge, so you can
|
|
22
|
+
* drag a pane fully closed. Set them to limit the range.
|
|
26
23
|
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
* yet. `collapsed-size` keeps a sliver showing where a pane has a tab strip
|
|
34
|
-
* worth leaving, and collapse overrides `min` and `max`, which is what those
|
|
35
|
-
* are for.
|
|
24
|
+
* A pane can be collapsed, which is a separate state from a divider at the
|
|
25
|
+
* edge. `collapsed` names the shut pane, `start` or `end`, and the pane opens
|
|
26
|
+
* back to the position where the collapsing gesture began. A drag records that position
|
|
27
|
+
* on press, and every other way of collapsing records it in `settle`.
|
|
28
|
+
* `collapsed-size` keeps a sliver of the pane visible, such as a tab strip.
|
|
29
|
+
* Collapsing overrides `min` and `max`.
|
|
36
30
|
*
|
|
37
31
|
* @since 0.1.0
|
|
38
32
|
* @status stable
|
|
@@ -40,16 +34,16 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
40
34
|
* @aliases SplitPane, Resizable, SplitView
|
|
41
35
|
* @documentation https://fusion.dev/helix/components/splitter
|
|
42
36
|
*
|
|
43
|
-
* @slot end - The pane after
|
|
37
|
+
* @slot end - The pane after the divider.
|
|
44
38
|
* @slot start - The pane before the divider.
|
|
45
39
|
*
|
|
46
|
-
* @event {HelixBeforeCollapseEvent} helix-before-collapse - Fired before a pane shuts or reopens, whether or not the resize that
|
|
47
|
-
* @event {HelixBeforeResizeEvent} helix-before-resize - Fired before the divider settles, and only
|
|
40
|
+
* @event {HelixBeforeCollapseEvent} helix-before-collapse - Fired before a pane shuts or reopens, whether or not the resize that caused it was allowed. It carries its own position, because a shut pane sits at `collapsed-size`. Cancelable: canceling it leaves the pane as it was and the divider where the gesture put it.
|
|
41
|
+
* @event {HelixBeforeResizeEvent} helix-before-resize - Fired before the divider settles, and only when the gesture moved it. A press that moved nothing, a drag that came back, an arrow key with no room left, and a corner that moved only the other divider do not fire it. Cancelable: canceling it leaves the position to you and keeps the rest of the gesture, so a collapse the gesture reached still fires `helix-before-collapse`, which you can also cancel. A dragged divider stays where it was dropped until you set your own `position`.
|
|
48
42
|
*
|
|
49
43
|
* @csspart corner - The handle where two dividers cross, added on the client.
|
|
50
|
-
* @csspart end - The box
|
|
44
|
+
* @csspart end - The box that holds the second pane.
|
|
51
45
|
* @csspart separator - The divider itself.
|
|
52
|
-
* @csspart start - The box
|
|
46
|
+
* @csspart start - The box that holds the first pane.
|
|
53
47
|
*
|
|
54
48
|
* @cssproperty --splitter-corner-at - Where a nested splitter crosses this one, as a percentage.
|
|
55
49
|
* @cssproperty --splitter-position - Where the divider sits, as a percentage of the box.
|
|
@@ -71,7 +65,7 @@ export declare class HelixHeadlessSplitter extends HelixElement {
|
|
|
71
65
|
get collapsed(): 'end' | 'start' | undefined;
|
|
72
66
|
set collapsed(next: 'end' | 'start' | undefined);
|
|
73
67
|
/**
|
|
74
|
-
*
|
|
68
|
+
* The divider's value while a pane is shut, as text in place of a number.
|
|
75
69
|
*
|
|
76
70
|
* **A shut pane is off the scale the divider reports**, which is `min` to
|
|
77
71
|
* `max`, the sliver a drag keeps. The divider said a value outside its own
|
|
@@ -89,27 +83,27 @@ export declare class HelixHeadlessSplitter extends HelixElement {
|
|
|
89
83
|
*/
|
|
90
84
|
collapsedSize: number;
|
|
91
85
|
/**
|
|
92
|
-
*
|
|
86
|
+
* The name of the handle where two dividers cross, read by screen readers.
|
|
93
87
|
*/
|
|
94
88
|
cornerLabel: string;
|
|
95
89
|
/**
|
|
96
|
-
* Which pane starts shut,
|
|
90
|
+
* Which pane starts shut, when `collapsed` is not set.
|
|
97
91
|
*/
|
|
98
92
|
defaultCollapsed?: 'end' | 'start';
|
|
99
93
|
/**
|
|
100
|
-
* Where the divider starts,
|
|
94
|
+
* Where the divider starts, when `position` is not set.
|
|
101
95
|
*/
|
|
102
96
|
defaultPosition: number;
|
|
103
97
|
/**
|
|
104
|
-
*
|
|
98
|
+
* The divider's name, read by screen readers.
|
|
105
99
|
*/
|
|
106
100
|
label: string;
|
|
107
101
|
/**
|
|
108
|
-
*
|
|
102
|
+
* How close the divider can come to the end, in the same units as `min`.
|
|
109
103
|
*/
|
|
110
104
|
max: number | string;
|
|
111
105
|
/**
|
|
112
|
-
*
|
|
106
|
+
* How close the divider can come to the start.
|
|
113
107
|
*
|
|
114
108
|
* A bare number is a percentage, which is what this always took. A CSS length
|
|
115
109
|
* is resolved against the splitter's own box along its axis, so `min="15rem"`
|
|
@@ -178,7 +172,7 @@ export declare class HelixHeadlessSplitter extends HelixElement {
|
|
|
178
172
|
get position(): number;
|
|
179
173
|
set position(next: number);
|
|
180
174
|
/**
|
|
181
|
-
* How far one arrow press moves
|
|
175
|
+
* How far one arrow key press moves the divider, as a percentage.
|
|
182
176
|
*/
|
|
183
177
|
step: number;
|
|
184
178
|
/** The position, whoever set it, and `undefined` until somebody has. */
|
|
@@ -270,7 +264,8 @@ export declare class HelixHeadlessSplitter extends HelixElement {
|
|
|
270
264
|
*/
|
|
271
265
|
private origin;
|
|
272
266
|
/**
|
|
273
|
-
* Moves the divider,
|
|
267
|
+
* Moves the divider. With `settled` set, it also fires the events for a
|
|
268
|
+
* finished move.
|
|
274
269
|
*
|
|
275
270
|
* Public because a corner on a nested splitter has to drive the one it is
|
|
276
271
|
* nested in, and that is the whole of what it needs: the pair are not
|
|
@@ -322,7 +317,8 @@ export declare class HelixHeadlessSplitter extends HelixElement {
|
|
|
322
317
|
*/
|
|
323
318
|
private watchWidth;
|
|
324
319
|
/**
|
|
325
|
-
* Public because a nested splitter compares
|
|
320
|
+
* Whether the panes are stacked. Public because a nested splitter compares
|
|
321
|
+
* its axis with the one it is in.
|
|
326
322
|
*
|
|
327
323
|
* The one place the axis is decided, which is why `auto` costs a single line
|
|
328
324
|
* here rather than a pass over seventeen readers: the drag, the arrow keys and
|
|
@@ -4,9 +4,9 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
4
4
|
* @summary A row of related measurements.
|
|
5
5
|
*
|
|
6
6
|
* @description
|
|
7
|
-
*
|
|
8
|
-
* order
|
|
9
|
-
*
|
|
7
|
+
* Screen readers announce the stats as a group. The figures are read together
|
|
8
|
+
* and their order has no meaning, so the group does not announce positions such
|
|
9
|
+
* as "1 of 4".
|
|
10
10
|
*
|
|
11
11
|
* @since 0.1.0
|
|
12
12
|
* @status stable
|
|
@@ -17,7 +17,7 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
17
17
|
*/
|
|
18
18
|
export declare class HelixHeadlessStatGroup extends HelixElement {
|
|
19
19
|
/**
|
|
20
|
-
* Accessible name for the
|
|
20
|
+
* Accessible name for the group.
|
|
21
21
|
*/
|
|
22
22
|
label: string;
|
|
23
23
|
protected willUpdate(changed: PropertyValues): void;
|