@fusion.dev/helix-headless 0.0.0-dev → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/custom-elements.json +4513 -4483
- package/dist/accordion/item/accordion-item.d.ts +13 -15
- package/dist/accordion/item/accordion-item.js +15 -17
- package/dist/announcement/root/announcement-root.d.ts +7 -25
- package/dist/announcement/root/announcement-root.js +7 -20
- package/dist/app-header/root/app-header-root.d.ts +10 -17
- package/dist/app-header/root/app-header-root.js +9 -18
- package/dist/avatar/group/avatar-group.d.ts +10 -19
- package/dist/avatar/group/avatar-group.js +12 -17
- package/dist/avatar/root/avatar-root.d.ts +8 -8
- package/dist/avatar/root/avatar-root.js +19 -20
- package/dist/badge/root/badge-root.d.ts +6 -6
- package/dist/badge/root/badge-root.js +13 -13
- package/dist/bar-chart/root/bar-chart-root.d.ts +21 -29
- package/dist/bar-chart/root/bar-chart-root.js +42 -57
- package/dist/breadcrumbs/breadcrumb/breadcrumb.d.ts +12 -18
- package/dist/breadcrumbs/breadcrumb/breadcrumb.js +13 -16
- package/dist/breadcrumbs/root/breadcrumbs-root.d.ts +9 -28
- package/dist/breadcrumbs/root/breadcrumbs-root.js +9 -28
- package/dist/button/root/button-root.d.ts +84 -94
- package/dist/button/root/button-root.js +82 -92
- package/dist/callout/root/callout-root.d.ts +4 -5
- package/dist/carousel/root/carousel-root.d.ts +59 -71
- package/dist/carousel/root/carousel-root.js +73 -101
- package/dist/chat/composer/chat-composer.d.ts +29 -33
- package/dist/chat/composer/chat-composer.js +40 -44
- package/dist/chat/message/chat-message.d.ts +25 -25
- package/dist/chat/message/chat-message.js +26 -26
- package/dist/chat/root/chat-root.d.ts +28 -41
- package/dist/chat/root/chat-root.js +27 -40
- package/dist/checkbox/root/checkbox-root.d.ts +10 -12
- package/dist/checkbox/root/checkbox-root.js +29 -35
- package/dist/checkbox-group/root/checkbox-group-root.d.ts +32 -45
- package/dist/checkbox-group/root/checkbox-group-root.js +53 -79
- package/dist/code-block/root/code-block-root.d.ts +3 -4
- package/dist/code-block/root/code-block-root.js +8 -12
- package/dist/color-input/root/color-input-root.d.ts +36 -37
- package/dist/color-input/root/color-input-root.js +29 -34
- package/dist/color-picker/color.d.ts +7 -8
- package/dist/color-picker/color.js +7 -8
- package/dist/color-picker/root/color-picker-root.d.ts +55 -57
- package/dist/color-picker/root/color-picker-root.js +60 -64
- package/dist/combobox/root/combobox-root.d.ts +53 -58
- package/dist/combobox/root/combobox-root.js +85 -94
- package/dist/command/root/command-root.d.ts +8 -8
- package/dist/command/root/command-root.js +29 -33
- package/dist/copy-button/root/copy-button-root.d.ts +21 -24
- package/dist/copy-button/root/copy-button-root.js +25 -35
- package/dist/data-table/root/data-table-root.d.ts +77 -76
- package/dist/data-table/root/data-table-root.js +95 -84
- package/dist/data-table/root/order.d.ts +2 -2
- package/dist/data-table/root/order.js +1 -3
- package/dist/date-input/root/date-input-root.d.ts +88 -93
- package/dist/date-input/root/date-input-root.js +147 -158
- package/dist/date-picker/root/date-picker-root.d.ts +75 -83
- package/dist/date-picker/root/date-picker-root.js +120 -143
- package/dist/dialog/root/dialog-root.d.ts +41 -24
- package/dist/dialog/root/dialog-root.js +47 -24
- package/dist/divider/root/divider-root.d.ts +5 -6
- package/dist/divider/root/divider-root.js +4 -5
- package/dist/donut-chart/root/donut-chart-root.d.ts +22 -25
- package/dist/donut-chart/root/donut-chart-root.js +37 -51
- package/dist/drawer/root/drawer-root.d.ts +24 -29
- package/dist/drawer/root/drawer-root.js +15 -22
- package/dist/drilldown/item/drilldown-item.d.ts +14 -14
- package/dist/drilldown/item/drilldown-item.js +24 -26
- package/dist/drilldown/root/drilldown-root.d.ts +8 -10
- package/dist/drilldown/root/drilldown-root.js +6 -7
- package/dist/element-events.generated.js +1 -1
- package/dist/file-input/root/file-input-root.d.ts +20 -24
- package/dist/file-input/root/file-input-root.js +42 -57
- package/dist/format-date/root/format-date-root.js +1 -1
- package/dist/heatmap/root/buckets.d.ts +8 -8
- package/dist/heatmap/root/buckets.js +8 -8
- package/dist/heatmap/root/heatmap-root.d.ts +57 -63
- package/dist/heatmap/root/heatmap-root.js +72 -83
- package/dist/icon/root/icon-root.d.ts +4 -4
- package/dist/icon/root/icon-root.js +9 -9
- package/dist/icon-button/root/icon-button-root.d.ts +4 -6
- package/dist/icon-button/root/icon-button-root.js +4 -6
- package/dist/image/root/image-root.d.ts +49 -59
- package/dist/image/root/image-root.js +55 -65
- package/dist/index.d.ts +5 -5
- package/dist/index.js +5 -5
- package/dist/input/root/input-root.d.ts +61 -85
- package/dist/input/root/input-root.js +79 -106
- package/dist/kbd/root/kbd-root.d.ts +8 -7
- package/dist/kbd/root/kbd-root.js +71 -11
- package/dist/legend/root/legend-root.d.ts +1 -1
- package/dist/legend/root/legend-root.js +4 -5
- package/dist/line-chart/root/line-chart-root.d.ts +26 -30
- package/dist/line-chart/root/line-chart-root.js +10 -10
- package/dist/list/item/list-item.d.ts +14 -18
- package/dist/list/item/list-item.js +18 -22
- package/dist/list/root/list-root.d.ts +4 -4
- package/dist/list/root/list-root.js +3 -3
- package/dist/listbox/root/listbox-root.d.ts +31 -58
- package/dist/listbox/root/listbox-root.js +66 -109
- package/dist/megamenu/root/megamenu-root.d.ts +34 -35
- package/dist/megamenu/root/megamenu-root.js +53 -58
- package/dist/menu/item/menu-item.d.ts +39 -53
- package/dist/menu/item/menu-item.js +50 -64
- package/dist/menu/root/menu-root.d.ts +30 -40
- package/dist/menu/root/menu-root.js +49 -82
- package/dist/meter/root/meter-root.d.ts +49 -53
- package/dist/meter/root/meter-root.js +22 -27
- package/dist/navigation/root/navigation-root.js +11 -19
- package/dist/notifications/notification/notification.d.ts +16 -22
- package/dist/notifications/notification/notification.js +21 -27
- package/dist/notifications/root/notifications-root.d.ts +31 -39
- package/dist/notifications/root/notifications-root.js +41 -52
- package/dist/number-input/root/number-input-root.d.ts +31 -33
- package/dist/number-input/root/number-input-root.js +37 -39
- package/dist/option/root/option-root.d.ts +73 -74
- package/dist/option/root/option-root.js +62 -64
- package/dist/outline/root/outline-root.d.ts +38 -44
- package/dist/outline/root/outline-root.js +66 -82
- package/dist/pagination/root/pagination-root.d.ts +87 -92
- package/dist/pagination/root/pagination-root.js +116 -123
- package/dist/pagination/size/pagination-size.d.ts +31 -50
- package/dist/pagination/size/pagination-size.js +35 -55
- package/dist/pagination/summary/pagination-summary.d.ts +12 -12
- package/dist/pagination/summary/pagination-summary.js +18 -18
- package/dist/pin-input/root/pin-input-root.d.ts +53 -70
- package/dist/pin-input/root/pin-input-root.js +74 -94
- package/dist/popover/root/popover-root.d.ts +15 -20
- package/dist/popover/root/popover-root.js +19 -36
- package/dist/progress/root/progress-root.d.ts +12 -14
- package/dist/progress/root/progress-root.js +22 -25
- package/dist/qr-code/root/qr-code-root.d.ts +11 -11
- package/dist/qr-code/root/qr-code-root.js +12 -14
- package/dist/radio/group/radio-group.js +19 -26
- package/dist/radio/root/radio-root.d.ts +12 -13
- package/dist/radio/root/radio-root.js +12 -13
- package/dist/rating/root/rating-root.d.ts +25 -30
- package/dist/rating/root/rating-root.js +43 -50
- package/dist/scroll-area/root/scroll-area-root.d.ts +11 -14
- package/dist/scroll-area/root/scroll-area-root.js +39 -33
- package/dist/select/root/select-root.d.ts +7 -12
- package/dist/select/root/select-root.js +40 -55
- package/dist/slider/root/slider-root.d.ts +53 -60
- package/dist/slider/root/slider-root.js +74 -85
- package/dist/sparkline/root/sparkline-root.d.ts +43 -47
- package/dist/sparkline/root/sparkline-root.js +23 -32
- package/dist/speed-dial/item/speed-dial-item.d.ts +6 -6
- package/dist/speed-dial/item/speed-dial-item.js +9 -9
- package/dist/speed-dial/root/speed-dial-root.d.ts +21 -25
- package/dist/speed-dial/root/speed-dial-root.js +32 -40
- package/dist/splitter/root/splitter-root.d.ts +98 -111
- package/dist/splitter/root/splitter-root.js +96 -123
- package/dist/stat/root/stat-root.d.ts +2 -7
- package/dist/stat/root/stat-root.js +0 -5
- package/dist/steps/step/step.d.ts +19 -24
- package/dist/steps/step/step.js +27 -32
- package/dist/switch/root/switch-root.js +2 -2
- package/dist/table/column/table-column.d.ts +54 -60
- package/dist/table/column/table-column.js +95 -68
- package/dist/table/root/table-root.d.ts +5 -6
- package/dist/table/root/table-root.js +7 -10
- package/dist/tabs/panel/tab-panel.d.ts +21 -25
- package/dist/tabs/panel/tab-panel.js +25 -29
- package/dist/tabs/root/tabs-root.d.ts +25 -34
- package/dist/tabs/root/tabs-root.js +22 -28
- package/dist/tabs/tab/tab.d.ts +12 -12
- package/dist/tabs/tab/tab.js +19 -20
- package/dist/textarea/root/textarea-root.d.ts +36 -36
- package/dist/textarea/root/textarea-root.js +43 -47
- package/dist/time-input/root/time-input-root.d.ts +58 -68
- package/dist/time-input/root/time-input-root.js +62 -77
- package/dist/time-picker/root/time-picker-root.d.ts +73 -79
- package/dist/time-picker/root/time-picker-root.js +72 -84
- package/dist/timeline/item/timeline-item.d.ts +8 -11
- package/dist/timeline/item/timeline-item.js +8 -11
- package/dist/timeline/root/timeline-root.d.ts +5 -7
- package/dist/timeline/root/timeline-root.js +5 -7
- package/dist/toast/item/toast-item.d.ts +9 -27
- package/dist/toast/item/toast-item.js +19 -41
- package/dist/toast/root/toast-root.d.ts +10 -14
- package/dist/toast/root/toast-root.js +4 -5
- package/dist/toggle/group/toggle-group.d.ts +6 -15
- package/dist/toggle/group/toggle-group.js +21 -36
- package/dist/toggle/root/toggle-root.d.ts +26 -27
- package/dist/toggle/root/toggle-root.js +30 -31
- package/dist/toolbar/root/toolbar-root.d.ts +7 -10
- package/dist/toolbar/root/toolbar-root.js +10 -14
- package/dist/tooltip/root/tooltip-root.d.ts +52 -59
- package/dist/tooltip/root/tooltip-root.js +98 -93
- package/dist/tour/root/tour-root.d.ts +19 -23
- package/dist/tour/root/tour-root.js +31 -41
- package/dist/tour/stop/tour-stop.d.ts +14 -15
- package/dist/tour/stop/tour-stop.js +31 -34
- package/dist/tree/item/tree-item.d.ts +30 -35
- package/dist/tree/item/tree-item.js +43 -55
- package/dist/tree/root/tree-root.d.ts +7 -10
- package/dist/tree/root/tree-root.js +33 -42
- package/dist/trend/root/trend-root.d.ts +3 -5
- package/dist/trend/root/trend-root.js +5 -9
- package/dist/video/root/video-root.d.ts +100 -124
- package/dist/video/root/video-root.js +142 -176
- package/dist/video-playlist/item/video-playlist-item.d.ts +16 -16
- package/dist/video-playlist/item/video-playlist-item.js +24 -24
- package/dist/video-playlist/menu/video-playlist-menu.d.ts +5 -8
- package/dist/video-playlist/menu/video-playlist-menu.js +20 -29
- package/dist/video-playlist/root/video-playlist-root.d.ts +16 -11
- package/dist/video-playlist/root/video-playlist-root.js +21 -25
- package/dist/virtual-list/root/virtual-list-root.d.ts +8 -12
- package/dist/virtual-list/root/virtual-list-root.js +11 -16
- package/jsx.d.ts +9797 -12561
- package/package.json +6 -6
- package/vue.d.ts +2684 -3228
|
@@ -49,16 +49,12 @@ import '../../tooltip/index.js';
|
|
|
49
49
|
*/
|
|
50
50
|
export declare class HelixHeadlessCopyButton extends HelixHeadlessIconButton {
|
|
51
51
|
/**
|
|
52
|
-
* What
|
|
52
|
+
* What it is called, and says, after one.
|
|
53
53
|
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
* meaning has nothing to act on; where a consumer changes the type, what it
|
|
57
|
-
* submits is what it copies, which is the reading anybody would expect of one
|
|
58
|
-
* property called `value`. Declared here rather than inherited because the
|
|
59
|
-
* clipboard is what this component is about and its own page should say so.
|
|
54
|
+
* `attribute` written out, because Lit lowercases a property name rather than
|
|
55
|
+
* dash-casing it, and `copiedlabel` is not what anyone would type.
|
|
60
56
|
*/
|
|
61
|
-
|
|
57
|
+
copiedLabel: string;
|
|
62
58
|
/**
|
|
63
59
|
* What it is called, and says, before a press.
|
|
64
60
|
*
|
|
@@ -68,12 +64,16 @@ export declare class HelixHeadlessCopyButton extends HelixHeadlessIconButton {
|
|
|
68
64
|
*/
|
|
69
65
|
label: string;
|
|
70
66
|
/**
|
|
71
|
-
* What
|
|
67
|
+
* What goes on the clipboard.
|
|
72
68
|
*
|
|
73
|
-
* `
|
|
74
|
-
*
|
|
69
|
+
* **Narrows `Button.value`, which is the submit value, and the two agree.**
|
|
70
|
+
* A copy button is `type="button"` and never submits, so the inherited
|
|
71
|
+
* meaning has nothing to act on; where a consumer changes the type, what it
|
|
72
|
+
* submits is what it copies, which is the reading anybody would expect of one
|
|
73
|
+
* property called `value`. Declared here rather than inherited because the
|
|
74
|
+
* clipboard is what this component is about and its own page should say so.
|
|
75
75
|
*/
|
|
76
|
-
|
|
76
|
+
value: string;
|
|
77
77
|
/**
|
|
78
78
|
* The words for the state it is in, used twice on purpose.
|
|
79
79
|
*
|
|
@@ -88,19 +88,16 @@ export declare class HelixHeadlessCopyButton extends HelixHeadlessIconButton {
|
|
|
88
88
|
/**
|
|
89
89
|
* The write, the confirmation, the timer and the event, all of them shared.
|
|
90
90
|
*
|
|
91
|
-
* **
|
|
92
|
-
*
|
|
93
|
-
*
|
|
94
|
-
*
|
|
95
|
-
*
|
|
96
|
-
* object exists and the write rejects. A copy button that does nothing is
|
|
97
|
-
* indistinguishable from a broken one, and this one was doing nothing in the
|
|
98
|
-
* one place a reader is most likely to try it.
|
|
91
|
+
* **Never reach for `navigator.clipboard.writeText` directly.** It is inert in
|
|
92
|
+
* a sandboxed iframe without `allow-same-origin`, which is the sandbox every
|
|
93
|
+
* example on the docs site runs in, and guarding on the API existing does not
|
|
94
|
+
* help there: the object exists and the write rejects. A copy button that does
|
|
95
|
+
* nothing is indistinguishable from a broken one.
|
|
99
96
|
*
|
|
100
|
-
* The controller
|
|
101
|
-
*
|
|
102
|
-
*
|
|
103
|
-
*
|
|
97
|
+
* The controller carries the `execCommand` fallback, checks the host is still
|
|
98
|
+
* connected after the await (writing is asynchronous, so `hostDisconnected`
|
|
99
|
+
* can run before there is a timer to clear), and registers itself so the timer
|
|
100
|
+
* is released without an override here.
|
|
104
101
|
*/
|
|
105
102
|
private readonly clipboard;
|
|
106
103
|
private get copied();
|
|
@@ -65,16 +65,12 @@ let HelixHeadlessCopyButton = HelixHeadlessCopyButton_1 = class HelixHeadlessCop
|
|
|
65
65
|
constructor() {
|
|
66
66
|
super(...arguments);
|
|
67
67
|
/**
|
|
68
|
-
* What
|
|
68
|
+
* What it is called, and says, after one.
|
|
69
69
|
*
|
|
70
|
-
*
|
|
71
|
-
*
|
|
72
|
-
* meaning has nothing to act on; where a consumer changes the type, what it
|
|
73
|
-
* submits is what it copies, which is the reading anybody would expect of one
|
|
74
|
-
* property called `value`. Declared here rather than inherited because the
|
|
75
|
-
* clipboard is what this component is about and its own page should say so.
|
|
70
|
+
* `attribute` written out, because Lit lowercases a property name rather than
|
|
71
|
+
* dash-casing it, and `copiedlabel` is not what anyone would type.
|
|
76
72
|
*/
|
|
77
|
-
this.
|
|
73
|
+
this.copiedLabel = 'Copied';
|
|
78
74
|
/**
|
|
79
75
|
* What it is called, and says, before a press.
|
|
80
76
|
*
|
|
@@ -84,35 +80,29 @@ let HelixHeadlessCopyButton = HelixHeadlessCopyButton_1 = class HelixHeadlessCop
|
|
|
84
80
|
*/
|
|
85
81
|
this.label = 'Copy';
|
|
86
82
|
/**
|
|
87
|
-
* What
|
|
88
|
-
*
|
|
89
|
-
* `attribute` written out, because Lit lowercases a property name rather than
|
|
90
|
-
* dash-casing it, and `copiedlabel` is not what anyone would type.
|
|
91
|
-
*/
|
|
92
|
-
this.copiedLabel = 'Copied';
|
|
93
|
-
/*
|
|
94
|
-
* Whether the confirmation is showing.
|
|
83
|
+
* What goes on the clipboard.
|
|
95
84
|
*
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
*
|
|
85
|
+
* **Narrows `Button.value`, which is the submit value, and the two agree.**
|
|
86
|
+
* A copy button is `type="button"` and never submits, so the inherited
|
|
87
|
+
* meaning has nothing to act on; where a consumer changes the type, what it
|
|
88
|
+
* submits is what it copies, which is the reading anybody would expect of one
|
|
89
|
+
* property called `value`. Declared here rather than inherited because the
|
|
90
|
+
* clipboard is what this component is about and its own page should say so.
|
|
99
91
|
*/
|
|
92
|
+
this.value = '';
|
|
100
93
|
/**
|
|
101
94
|
* The write, the confirmation, the timer and the event, all of them shared.
|
|
102
95
|
*
|
|
103
|
-
* **
|
|
104
|
-
*
|
|
105
|
-
*
|
|
106
|
-
*
|
|
107
|
-
*
|
|
108
|
-
* object exists and the write rejects. A copy button that does nothing is
|
|
109
|
-
* indistinguishable from a broken one, and this one was doing nothing in the
|
|
110
|
-
* one place a reader is most likely to try it.
|
|
96
|
+
* **Never reach for `navigator.clipboard.writeText` directly.** It is inert in
|
|
97
|
+
* a sandboxed iframe without `allow-same-origin`, which is the sandbox every
|
|
98
|
+
* example on the docs site runs in, and guarding on the API existing does not
|
|
99
|
+
* help there: the object exists and the write rejects. A copy button that does
|
|
100
|
+
* nothing is indistinguishable from a broken one.
|
|
111
101
|
*
|
|
112
|
-
* The controller
|
|
113
|
-
*
|
|
114
|
-
*
|
|
115
|
-
*
|
|
102
|
+
* The controller carries the `execCommand` fallback, checks the host is still
|
|
103
|
+
* connected after the await (writing is asynchronous, so `hostDisconnected`
|
|
104
|
+
* can run before there is a timer to clear), and registers itself so the timer
|
|
105
|
+
* is released without an override here.
|
|
116
106
|
*/
|
|
117
107
|
this.clipboard = new CopyController(this, { after: CONFIRM });
|
|
118
108
|
this.handleCopy = async () => {
|
|
@@ -211,14 +201,14 @@ let HelixHeadlessCopyButton = HelixHeadlessCopyButton_1 = class HelixHeadlessCop
|
|
|
211
201
|
}
|
|
212
202
|
};
|
|
213
203
|
__decorate([
|
|
214
|
-
property()
|
|
215
|
-
], HelixHeadlessCopyButton.prototype, "
|
|
204
|
+
property({ attribute: 'copied-label' })
|
|
205
|
+
], HelixHeadlessCopyButton.prototype, "copiedLabel", void 0);
|
|
216
206
|
__decorate([
|
|
217
207
|
property()
|
|
218
208
|
], HelixHeadlessCopyButton.prototype, "label", void 0);
|
|
219
209
|
__decorate([
|
|
220
|
-
property(
|
|
221
|
-
], HelixHeadlessCopyButton.prototype, "
|
|
210
|
+
property()
|
|
211
|
+
], HelixHeadlessCopyButton.prototype, "value", void 0);
|
|
222
212
|
HelixHeadlessCopyButton = HelixHeadlessCopyButton_1 = __decorate([
|
|
223
213
|
customElement('helix-headless-copy-button')
|
|
224
214
|
], HelixHeadlessCopyButton);
|
|
@@ -21,12 +21,8 @@ declare const HelixHeadlessDataTable_base: (new (...args: any[]) => import("@fus
|
|
|
21
21
|
* </helix-data-table>
|
|
22
22
|
* ```
|
|
23
23
|
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
* a person wrote out; the repeated `page`, `page-size` and `total` attributes on
|
|
27
|
-
* the three pagination elements are placeholders whose own comments name the fix
|
|
28
|
-
* as "a data table composing a pagination inside itself", and `helix-table`
|
|
29
|
-
* already carried `@aliases DataTable`: a name claimed and not kept.
|
|
24
|
+
* `helix-table` takes rows as markup and is the right component for a table of
|
|
25
|
+
* twelve things a person wrote out.
|
|
30
26
|
*
|
|
31
27
|
* **Sort and filter apply to the whole set, never the page.** Sorting the drawn
|
|
32
28
|
* window is correct on the first screen and wrong on every other one, which is
|
|
@@ -46,10 +42,10 @@ declare const HelixHeadlessDataTable_base: (new (...args: any[]) => import("@fus
|
|
|
46
42
|
* `helix-table` where the content has to be in the served HTML and the result is
|
|
47
43
|
* small enough to write out; use this where the result is large, and accept that
|
|
48
44
|
* the first paint is a shell. The obvious workaround, a `columns` property
|
|
49
|
-
* beside the markup columns, is deliberately not offered:
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
45
|
+
* beside the markup columns, is deliberately not offered: it splits one source
|
|
46
|
+
* of truth for the columns into two that nothing checks against each other, and
|
|
47
|
+
* a table rendering one way on the server and another in the browser is that
|
|
48
|
+
* failure with a hydration mismatch on top.
|
|
53
49
|
*
|
|
54
50
|
* **Every axis is controlled or uncontrolled, and that is what makes a server
|
|
55
51
|
* mode fall out rather than be bolted on.** `sort`, `filter`, `page` and
|
|
@@ -97,17 +93,21 @@ export declare class HelixHeadlessDataTable extends HelixHeadlessDataTable_base
|
|
|
97
93
|
*/
|
|
98
94
|
static shadowRootOptions: ShadowRootInit;
|
|
99
95
|
/**
|
|
100
|
-
*
|
|
101
|
-
*
|
|
102
|
-
* A property and not an attribute: it is an array. Left alone this element
|
|
103
|
-
* filters, sorts and pages it; in `server` mode it is the page the consumer
|
|
104
|
-
* already fetched and none of the three is applied.
|
|
105
|
-
*
|
|
106
|
-
* **Read, never written.** Sorting produces a new array rather than reordering
|
|
107
|
-
* this one, because a consumer's array may be the same object their own state
|
|
108
|
-
* holds and reordering it under them is a mutation they did not ask for.
|
|
96
|
+
* Query to open with, where nothing declared one.
|
|
109
97
|
*/
|
|
110
|
-
|
|
98
|
+
defaultFilter: string;
|
|
99
|
+
/**
|
|
100
|
+
* Page to open on, where nothing declared one.
|
|
101
|
+
*/
|
|
102
|
+
defaultPage: number;
|
|
103
|
+
/**
|
|
104
|
+
* Page size to open with, where nothing declared one.
|
|
105
|
+
*/
|
|
106
|
+
defaultPageSize: number;
|
|
107
|
+
/**
|
|
108
|
+
* Order to open on, where nothing declared one.
|
|
109
|
+
*/
|
|
110
|
+
defaultSort: string;
|
|
111
111
|
/**
|
|
112
112
|
* The field naming a row's stable identity.
|
|
113
113
|
*
|
|
@@ -119,75 +119,60 @@ export declare class HelixHeadlessDataTable extends HelixHeadlessDataTable_base
|
|
|
119
119
|
* that works and is worth setting anyway.
|
|
120
120
|
*/
|
|
121
121
|
key: string;
|
|
122
|
-
/**
|
|
123
|
-
* Whether this element does the work or asks the consumer to.
|
|
124
|
-
*
|
|
125
|
-
* `client` filters, sorts and pages `rows` itself. `server` applies none of
|
|
126
|
-
* them: `rows` is the page, `total` is the size of the whole result, and the
|
|
127
|
-
* three events are requests the consumer answers by fetching. Past some size
|
|
128
|
-
* the client cannot hold the data, so this is not an optimization, it is the
|
|
129
|
-
* only mode that works, and it is here from the start because adding it later
|
|
130
|
-
* inverts the data flow.
|
|
131
|
-
*/
|
|
132
|
-
mode: 'client' | 'server';
|
|
133
|
-
/**
|
|
134
|
-
* How many rows the whole result has, where this element cannot count them.
|
|
135
|
-
*
|
|
136
|
-
* Only read in `server` mode, where `rows` is one page and its length says
|
|
137
|
-
* nothing about the result. Ignored in `client` mode rather than trusted,
|
|
138
|
-
* because two sources for one count is the mistake, and here the array is the
|
|
139
|
-
* one that cannot be stale.
|
|
140
|
-
*/
|
|
141
|
-
total: number;
|
|
142
|
-
/**
|
|
143
|
-
* Accessible name for the grid.
|
|
144
|
-
*/
|
|
145
|
-
label: string;
|
|
146
122
|
/**
|
|
147
123
|
* The order, as `field:direction`.
|
|
148
124
|
*
|
|
149
125
|
* Set it and this element defers: a reader's click fires `helix-sort` and
|
|
150
126
|
* changes nothing until a new value arrives. `default-sort` seeds an order this
|
|
151
127
|
* element then owns.
|
|
152
|
-
*
|
|
153
|
-
*
|
|
154
128
|
*/
|
|
155
129
|
get sort(): string;
|
|
156
130
|
set sort(next: string);
|
|
157
131
|
/**
|
|
158
|
-
*
|
|
132
|
+
* Accessible name for the grid.
|
|
159
133
|
*/
|
|
160
|
-
|
|
134
|
+
label: string;
|
|
161
135
|
/**
|
|
162
136
|
* What the rows are narrowed to, as one query across every column.
|
|
163
137
|
*
|
|
164
138
|
* One query rather than a predicate per column, which is what a reader means
|
|
165
139
|
* by a search box above a table. It matches on each column's ordering value,
|
|
166
140
|
* so search and sort cannot disagree about what a column holds.
|
|
167
|
-
*
|
|
168
|
-
*
|
|
169
141
|
*/
|
|
170
142
|
get filter(): string;
|
|
171
143
|
set filter(next: string);
|
|
172
144
|
/**
|
|
173
|
-
*
|
|
145
|
+
* Whether this element does the work or asks the consumer to.
|
|
146
|
+
*
|
|
147
|
+
* `client` filters, sorts and pages `rows` itself. `server` applies none of
|
|
148
|
+
* them: `rows` is the page, `total` is the size of the whole result, and the
|
|
149
|
+
* three events are requests the consumer answers by fetching. Past some size
|
|
150
|
+
* the client cannot hold the data, so this is not an optimization, it is the
|
|
151
|
+
* only mode that works, and it is here from the start because adding it later
|
|
152
|
+
* inverts the data flow.
|
|
174
153
|
*/
|
|
175
|
-
|
|
154
|
+
mode: 'client' | 'server';
|
|
176
155
|
/**
|
|
177
156
|
* The page on show, from 1.
|
|
178
157
|
*
|
|
179
158
|
* Clamped on the way out, so what this reports is the page it drew: a
|
|
180
159
|
* bookmarked link to page 99 of a result that has since shrunk reads back as
|
|
181
160
|
* the last page rather than as 99.
|
|
182
|
-
*
|
|
183
|
-
*
|
|
184
161
|
*/
|
|
185
162
|
get page(): number;
|
|
186
163
|
set page(next: number);
|
|
187
164
|
/**
|
|
188
|
-
*
|
|
165
|
+
* The whole result, in the order it arrived.
|
|
166
|
+
*
|
|
167
|
+
* A property and not an attribute: it is an array. Left alone this element
|
|
168
|
+
* filters, sorts and pages it; in `server` mode it is the page the consumer
|
|
169
|
+
* already fetched and none of the three is applied.
|
|
170
|
+
*
|
|
171
|
+
* **Read, never written.** Sorting produces a new array rather than reordering
|
|
172
|
+
* this one, because a consumer's array may be the same object their own state
|
|
173
|
+
* holds and reordering it under them is a mutation they did not ask for.
|
|
189
174
|
*/
|
|
190
|
-
|
|
175
|
+
rows: readonly DataRow[];
|
|
191
176
|
/**
|
|
192
177
|
* How many rows a page holds. Zero is every row, which is what "no paging" means.
|
|
193
178
|
*
|
|
@@ -200,9 +185,14 @@ export declare class HelixHeadlessDataTable extends HelixHeadlessDataTable_base
|
|
|
200
185
|
get pageSize(): number;
|
|
201
186
|
set pageSize(next: number);
|
|
202
187
|
/**
|
|
203
|
-
*
|
|
188
|
+
* How many rows the whole result has, where this element cannot count them.
|
|
189
|
+
*
|
|
190
|
+
* Only read in `server` mode, where `rows` is one page and its length says
|
|
191
|
+
* nothing about the result. Ignored in `client` mode rather than trusted,
|
|
192
|
+
* because two sources for one count is the mistake, and here the array is the
|
|
193
|
+
* one that cannot be stale.
|
|
204
194
|
*/
|
|
205
|
-
|
|
195
|
+
total: number;
|
|
206
196
|
/**
|
|
207
197
|
* Whether to draw a pagination under the grid.
|
|
208
198
|
*
|
|
@@ -245,19 +235,18 @@ export declare class HelixHeadlessDataTable extends HelixHeadlessDataTable_base
|
|
|
245
235
|
* which means the out-of-the-box arrangement is the unbounded one and nothing
|
|
246
236
|
* about it says that a result of any size will simply be drawn.
|
|
247
237
|
*
|
|
248
|
-
* **Windowing was
|
|
249
|
-
*
|
|
238
|
+
* **Windowing was refused**, which is worth recording because it is the
|
|
239
|
+
* obvious answer. This element already has two mechanisms: `paginated` with a
|
|
250
240
|
* `page-size`, and `mode="server"` where `rows` is one page, `total` is the
|
|
251
241
|
* whole result and `aria-rowcount` already reports the result rather than the
|
|
252
242
|
* window, which is the hard half of virtualization done correctly. A third
|
|
253
|
-
*
|
|
254
|
-
*
|
|
255
|
-
*
|
|
256
|
-
*
|
|
243
|
+
* would fight the first two, and virtualizing a grid means variable row
|
|
244
|
+
* heights, a sticky header and keeping `aria-rowindex` honest against a result
|
|
245
|
+
* the element is no longer holding. `VirtualizeController` exists for the case
|
|
246
|
+
* where the rows are a flat list and this is not that.
|
|
257
247
|
*
|
|
258
|
-
*
|
|
259
|
-
*
|
|
260
|
-
* server render is one nobody can act on and one that would print per request.
|
|
248
|
+
* Warned once per element, in a browser only: a warning during a server render
|
|
249
|
+
* is one nobody can act on and one that would print per request.
|
|
261
250
|
*/
|
|
262
251
|
private warnIfCrowded;
|
|
263
252
|
/**
|
|
@@ -317,13 +306,11 @@ export declare class HelixHeadlessDataTable extends HelixHeadlessDataTable_base
|
|
|
317
306
|
/**
|
|
318
307
|
* Says on the toolbar and the footer whether anything is in them.
|
|
319
308
|
*
|
|
320
|
-
* **
|
|
321
|
-
*
|
|
322
|
-
*
|
|
323
|
-
*
|
|
324
|
-
*
|
|
325
|
-
* children. Both verified in a browser. A table with no toolbar paid the gap
|
|
326
|
-
* above the grid for one that was not there.
|
|
309
|
+
* **A stylesheet cannot ask.** `[part="toolbar"]:has(> slot:not(:has(*)))` is
|
|
310
|
+
* two faults at once: `:has()` may not be nested inside `:has()`, so the
|
|
311
|
+
* selector fails to parse and the whole rule is discarded; and
|
|
312
|
+
* `slot:not(:has(*))` is as true of a filled slot as of an empty one, because
|
|
313
|
+
* assigned nodes are not a slot's DOM children. Both verified in a browser.
|
|
327
314
|
*/
|
|
328
315
|
private markEmpty;
|
|
329
316
|
/**
|
|
@@ -337,6 +324,21 @@ export declare class HelixHeadlessDataTable extends HelixHeadlessDataTable_base
|
|
|
337
324
|
*/
|
|
338
325
|
private markRegion;
|
|
339
326
|
protected updated(changed: PropertyValues): void;
|
|
327
|
+
/**
|
|
328
|
+
* Tells each column which way it is ordered, if it is the one.
|
|
329
|
+
*
|
|
330
|
+
* **The table owns the sort and the column carries the semantics**, which is
|
|
331
|
+
* the only arrangement that can be right: `role="columnheader"` is on the
|
|
332
|
+
* column, so `aria-sort` has to be there too, and the value is a fact about
|
|
333
|
+
* the table's `sort` rather than about any column. Pushed down here rather
|
|
334
|
+
* than pulled up there, because a column asking its parent would have to know
|
|
335
|
+
* what kind of parent it has, and it is slotted into two.
|
|
336
|
+
*
|
|
337
|
+
* In `updated` and after `assign`, so the order announced is the order the
|
|
338
|
+
* rows are already in. Announced before the rows moved is the sort a reader is
|
|
339
|
+
* told about being one they cannot see yet.
|
|
340
|
+
*/
|
|
341
|
+
private announceSort;
|
|
340
342
|
/** Columns arrive from the light DOM, which changes no property here. */
|
|
341
343
|
private readonly handleSlotChange;
|
|
342
344
|
private renderCell;
|
|
@@ -360,8 +362,7 @@ export declare class HelixHeadlessDataTable extends HelixHeadlessDataTable_base
|
|
|
360
362
|
* node passes through the slot in the flattened tree, and does not work in
|
|
361
363
|
* happy-dom, which does not implement that propagation: measured, the host
|
|
362
364
|
* hears the click and the slot does not. A spec written against the slot fails
|
|
363
|
-
* in the suite while the component is correct
|
|
364
|
-
* flattened tree could as easily have gone the other way.
|
|
365
|
+
* in the suite while the component is correct.
|
|
365
366
|
*
|
|
366
367
|
* Added here rather than in the template because there is nothing in the
|
|
367
368
|
* shadow tree to attach it to, and removed on disconnect because this element
|