@fusion.dev/helix-headless 0.167.0 → 0.169.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 +20 -2
- package/dist/avatar/root/avatar-root.d.ts +3 -1
- package/dist/avatar/root/avatar-root.js +2 -2
- package/dist/navigation/root/navigation-root.d.ts +22 -0
- package/dist/navigation/root/navigation-root.js +3 -0
- package/lint.json +1 -1
- package/package.json +5 -5
- package/types/jsx.d.ts +90 -4
- package/types/vue.d.ts +23 -1
package/custom-elements.json
CHANGED
|
@@ -5613,7 +5613,7 @@
|
|
|
5613
5613
|
"text": "'error' | 'loaded' | 'loading'"
|
|
5614
5614
|
},
|
|
5615
5615
|
"default": "'loading'",
|
|
5616
|
-
"description": "The image's state: `loading` while it is on its way, `loaded` once it\narrives, or `error` when it fails and the initials replace it. An avatar\nwith no `src` has no image to wait for, and reports `error` as well, since\nthe initials are what it shows.\n\nRead-only to a consumer: it is a report rather than a setting, and the same\nreport `Image` gives, for the same reason. `load` and `error` fire once, so\na listener bound after the picture settled hears neither, which is the\nplatform on an `<img>` too, and this is what that listener asks instead.\nMirrored to `data-status` rather than reflected, as `Image` explains."
|
|
5616
|
+
"description": "The image's state: `loading` while it is on its way, `loaded` once it\narrives, or `error` when it fails and the initials replace it. An avatar\nwith no `src` has no image to wait for, and reports `error` as well, since\nthe initials are what it shows.\n\nRead-only to a consumer: it is a report rather than a setting, and the same\nreport `Image` gives, for the same reason. `load` and `error` fire once, so\na listener bound after the picture settled hears neither, which is the\nplatform on an `<img>` too, and this is what that listener asks instead.\nMirrored to `data-status` rather than reflected, as `Image` explains, once a\npicture has loaded or failed. An avatar with no `src` reports `error` here\nand as `:state(error)`, and writes no `data-status`."
|
|
5617
5617
|
},
|
|
5618
5618
|
{
|
|
5619
5619
|
"kind": "field",
|
|
@@ -113053,6 +113053,16 @@
|
|
|
113053
113053
|
"attribute": "orientation",
|
|
113054
113054
|
"reflects": true
|
|
113055
113055
|
},
|
|
113056
|
+
{
|
|
113057
|
+
"kind": "field",
|
|
113058
|
+
"name": "variant",
|
|
113059
|
+
"type": {
|
|
113060
|
+
"text": "'segmented' | 'underlined' | undefined"
|
|
113061
|
+
},
|
|
113062
|
+
"description": "How the destinations are drawn, with `Tabs`' three values and for the same\nreasons.\n\nUnset is a pill under the current destination with nothing behind the row,\nfor a bar inside other chrome. `underlined` is a rule under the row and a\nthicker one under the current destination, for a bar that heads a page, as\na repository's or a project's sections do. `segmented` puts the pill in a\nframed, sunken track, for a short set that reads as one control.\n\n**The same words as `Tabs`, because a reader cannot tell the two apart.**\nNavigation moves between pages and tabs between the panels of one page,\nand the bar looks the same either way. A console whose sections are pages\ncould not draw them the way its underlined tabs were drawn.\n\nDown a column, `underlined` stands the rule and the mark along the\ncolumn's inline end.\n\nReflected and left unset by default, so the host carries nothing a\nconsumer's server markup does not already have.",
|
|
113063
|
+
"attribute": "variant",
|
|
113064
|
+
"reflects": true
|
|
113065
|
+
},
|
|
113056
113066
|
{
|
|
113057
113067
|
"kind": "field",
|
|
113058
113068
|
"name": "current",
|
|
@@ -113484,6 +113494,14 @@
|
|
|
113484
113494
|
},
|
|
113485
113495
|
"description": "Stacks the destinations in a column, for a sidebar, where unset is a row\nfor a header or a footer. The marker follows the current destination down\nthe column as it does along the row.",
|
|
113486
113496
|
"fieldName": "orientation"
|
|
113497
|
+
},
|
|
113498
|
+
{
|
|
113499
|
+
"name": "variant",
|
|
113500
|
+
"type": {
|
|
113501
|
+
"text": "'segmented' | 'underlined' | undefined"
|
|
113502
|
+
},
|
|
113503
|
+
"description": "How the destinations are drawn, with `Tabs`' three values and for the same\nreasons.\n\nUnset is a pill under the current destination with nothing behind the row,\nfor a bar inside other chrome. `underlined` is a rule under the row and a\nthicker one under the current destination, for a bar that heads a page, as\na repository's or a project's sections do. `segmented` puts the pill in a\nframed, sunken track, for a short set that reads as one control.\n\n**The same words as `Tabs`, because a reader cannot tell the two apart.**\nNavigation moves between pages and tabs between the panels of one page,\nand the bar looks the same either way. A console whose sections are pages\ncould not draw them the way its underlined tabs were drawn.\n\nDown a column, `underlined` stands the rule and the mark along the\ncolumn's inline end.\n\nReflected and left unset by default, so the host carries nothing a\nconsumer's server markup does not already have.",
|
|
113504
|
+
"fieldName": "variant"
|
|
113487
113505
|
}
|
|
113488
113506
|
],
|
|
113489
113507
|
"cssStates": [
|
|
@@ -196364,6 +196382,6 @@
|
|
|
196364
196382
|
],
|
|
196365
196383
|
"helix": {
|
|
196366
196384
|
"package": "@fusion.dev/helix-headless",
|
|
196367
|
-
"version": "0.
|
|
196385
|
+
"version": "0.169.0"
|
|
196368
196386
|
}
|
|
196369
196387
|
}
|
|
@@ -95,7 +95,9 @@ export declare class HelixHeadlessAvatar extends HelixElement {
|
|
|
95
95
|
* report `Image` gives, for the same reason. `load` and `error` fire once, so
|
|
96
96
|
* a listener bound after the picture settled hears neither, which is the
|
|
97
97
|
* platform on an `<img>` too, and this is what that listener asks instead.
|
|
98
|
-
* Mirrored to `data-status` rather than reflected, as `Image` explains
|
|
98
|
+
* Mirrored to `data-status` rather than reflected, as `Image` explains, once a
|
|
99
|
+
* picture has loaded or failed. An avatar with no `src` reports `error` here
|
|
100
|
+
* and as `:state(error)`, and writes no `data-status`.
|
|
99
101
|
*/
|
|
100
102
|
status: 'error' | 'loaded' | 'loading';
|
|
101
103
|
/**
|
|
@@ -78,8 +78,8 @@ let HelixHeadlessAvatar = class HelixHeadlessAvatar extends HelixElement {
|
|
|
78
78
|
if (changed.has('src') || changed.has('fallbackDelay')) {
|
|
79
79
|
this.startWait();
|
|
80
80
|
}
|
|
81
|
-
if (changed.has('status')) {
|
|
82
|
-
if (this.status === 'loading') {
|
|
81
|
+
if (changed.has('status') || changed.has('src')) {
|
|
82
|
+
if (this.status === 'loading' || this.src === '') {
|
|
83
83
|
this.removeAttribute('data-status');
|
|
84
84
|
}
|
|
85
85
|
else {
|
|
@@ -90,6 +90,28 @@ export declare class HelixHeadlessNavigation extends HelixElement {
|
|
|
90
90
|
* the column as it does along the row.
|
|
91
91
|
*/
|
|
92
92
|
orientation?: 'vertical';
|
|
93
|
+
/**
|
|
94
|
+
* How the destinations are drawn, with `Tabs`' three values and for the same
|
|
95
|
+
* reasons.
|
|
96
|
+
*
|
|
97
|
+
* Unset is a pill under the current destination with nothing behind the row,
|
|
98
|
+
* for a bar inside other chrome. `underlined` is a rule under the row and a
|
|
99
|
+
* thicker one under the current destination, for a bar that heads a page, as
|
|
100
|
+
* a repository's or a project's sections do. `segmented` puts the pill in a
|
|
101
|
+
* framed, sunken track, for a short set that reads as one control.
|
|
102
|
+
*
|
|
103
|
+
* **The same words as `Tabs`, because a reader cannot tell the two apart.**
|
|
104
|
+
* Navigation moves between pages and tabs between the panels of one page,
|
|
105
|
+
* and the bar looks the same either way. A console whose sections are pages
|
|
106
|
+
* could not draw them the way its underlined tabs were drawn.
|
|
107
|
+
*
|
|
108
|
+
* Down a column, `underlined` stands the rule and the mark along the
|
|
109
|
+
* column's inline end.
|
|
110
|
+
*
|
|
111
|
+
* Reflected and left unset by default, so the host carries nothing a
|
|
112
|
+
* consumer's server markup does not already have.
|
|
113
|
+
*/
|
|
114
|
+
variant?: 'segmented' | 'underlined';
|
|
93
115
|
private current;
|
|
94
116
|
/** The disclosures among the destinations that are open. */
|
|
95
117
|
private readonly opened;
|
|
@@ -155,6 +155,9 @@ __decorate([
|
|
|
155
155
|
__decorate([
|
|
156
156
|
property({ reflect: true })
|
|
157
157
|
], HelixHeadlessNavigation.prototype, "orientation", void 0);
|
|
158
|
+
__decorate([
|
|
159
|
+
property({ reflect: true })
|
|
160
|
+
], HelixHeadlessNavigation.prototype, "variant", void 0);
|
|
158
161
|
HelixHeadlessNavigation = __decorate([
|
|
159
162
|
customElement('helix-headless-navigation')
|
|
160
163
|
], HelixHeadlessNavigation);
|