@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,38 +5,38 @@ declare const HelixHeadlessAccordionItem_base: (new (...args: any[]) => import("
|
|
|
5
5
|
* @summary One collapsible section of an accordion.
|
|
6
6
|
*
|
|
7
7
|
* @description
|
|
8
|
-
*
|
|
9
|
-
*
|
|
8
|
+
* Holds its own open state. Used alone, outside an accordion, it works as a
|
|
9
|
+
* disclosure.
|
|
10
10
|
*
|
|
11
|
-
* Content stays mounted when closed, so it can animate and
|
|
12
|
-
* present in server-rendered HTML. Closed content
|
|
13
|
-
* `inert
|
|
14
|
-
*
|
|
15
|
-
* `display`
|
|
11
|
+
* Content stays mounted when the item is closed, so it can animate and its text
|
|
12
|
+
* is present in server-rendered HTML. Closed content has both `hidden` and
|
|
13
|
+
* `inert`. `hidden` collapses it when no stylesheet is loaded. `inert` keeps it
|
|
14
|
+
* out of the tab order and the accessibility tree after the styled tier's
|
|
15
|
+
* `display` overrides `hidden`.
|
|
16
16
|
*
|
|
17
17
|
* @since 0.1.0
|
|
18
18
|
* @status stable
|
|
19
19
|
* @aliases Collapsible, Expander, Disclosure
|
|
20
20
|
* @documentation https://fusion.dev/helix/components/accordion
|
|
21
21
|
*
|
|
22
|
-
* @slot - The content
|
|
23
|
-
* @slot summary - The
|
|
22
|
+
* @slot - The content shown when the section is open.
|
|
23
|
+
* @slot summary - The text of the button that opens and closes the section. Always shown.
|
|
24
24
|
*
|
|
25
|
-
* @event {HelixBeforeCloseEvent} helix-before-close -
|
|
26
|
-
* @event {HelixBeforeOpenEvent} helix-before-open -
|
|
27
|
-
* @event {Event} toggle -
|
|
25
|
+
* @event {HelixBeforeCloseEvent} helix-before-close - The section is about to close. Cancelable: cancel it to keep it open.
|
|
26
|
+
* @event {HelixBeforeOpenEvent} helix-before-open - The section is about to open. Cancelable: cancel it to keep it closed.
|
|
27
|
+
* @event {Event} toggle - The section opened or closed. The event carries `newState` and `oldState`.
|
|
28
28
|
*
|
|
29
29
|
* @csspart chevron - The open and close indicator.
|
|
30
30
|
* @csspart container - The outer wrapper.
|
|
31
|
-
* @csspart content - The
|
|
31
|
+
* @csspart content - The region that holds the content.
|
|
32
32
|
* @csspart content-inner - The clipping box inside the animated region.
|
|
33
|
-
* @csspart trigger - The
|
|
33
|
+
* @csspart trigger - The button that opens and closes the section, holding the summary.
|
|
34
34
|
*
|
|
35
35
|
* @cssstate open - While the item is open.
|
|
36
36
|
*/
|
|
37
37
|
export declare class HelixHeadlessAccordionItem extends HelixHeadlessAccordionItem_base {
|
|
38
38
|
/**
|
|
39
|
-
* Where the
|
|
39
|
+
* Where the chevron sits, or `none` for no chevron.
|
|
40
40
|
*
|
|
41
41
|
* `auto` resolves to `end`, which is where a reader scanning a list of
|
|
42
42
|
* summaries expects it: the label starts at the same x on every row, and the
|
|
@@ -49,7 +49,8 @@ export declare class HelixHeadlessAccordionItem extends HelixHeadlessAccordionIt
|
|
|
49
49
|
/** The chevron, or nothing when suppressed. */
|
|
50
50
|
private renderChevron;
|
|
51
51
|
/**
|
|
52
|
-
* A group name
|
|
52
|
+
* A group name. Opening an item closes the other items with the same name,
|
|
53
|
+
* as `<details name>` does.
|
|
53
54
|
*
|
|
54
55
|
* **Two ways of saying the same thing, and the platform's one does not need a
|
|
55
56
|
* parent.** An accordion's `mode` makes its own children exclusive, which
|
|
@@ -2,27 +2,23 @@ import { HelixElement, KeyboardNavigationController } from '@fusion.dev/helix-co
|
|
|
2
2
|
import { type TemplateResult } from 'lit';
|
|
3
3
|
import { HelixHeadlessAccordionItem } from '../item/accordion-item.js';
|
|
4
4
|
/**
|
|
5
|
-
* @summary
|
|
5
|
+
* @summary A group of collapsible sections.
|
|
6
6
|
*
|
|
7
7
|
* @description
|
|
8
|
-
* Holds the mode
|
|
9
|
-
*
|
|
10
|
-
* closes its peers itself.
|
|
8
|
+
* Holds the mode. Each item coordinates itself: when you click an item, it
|
|
9
|
+
* finds the nearest accordion, reads the mode, and closes the other items.
|
|
11
10
|
*
|
|
12
|
-
*
|
|
13
|
-
* and is not composed, because overlays nest and an inner
|
|
14
|
-
*
|
|
15
|
-
* opened by listening for it.
|
|
11
|
+
* The accordion does not listen for items opening. `helix-before-open` does not
|
|
12
|
+
* bubble and is not composed, because overlays nest and an inner overlay's
|
|
13
|
+
* events must stay separate from the outer one's.
|
|
16
14
|
*
|
|
17
|
-
*
|
|
18
|
-
* item added
|
|
15
|
+
* Items are found when they are clicked, so there is no registry to keep up to
|
|
16
|
+
* date. An item added after render coordinates on its first click. Items are
|
|
17
|
+
* matched with `instanceof HelixHeadlessAccordionItem`, so the headless tier
|
|
18
|
+
* does not depend on the styled tier's tag names.
|
|
19
19
|
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* The keyboard listener is the controller's and is attached on connect, so
|
|
24
|
-
* none of it runs on the server, where there is no tree to walk and no events
|
|
25
|
-
* to hear.
|
|
20
|
+
* The keyboard listener belongs to the controller and is attached on connect,
|
|
21
|
+
* so it does not run on the server.
|
|
26
22
|
*
|
|
27
23
|
* @since 0.1.0
|
|
28
24
|
* @status stable
|
|
@@ -44,7 +40,7 @@ export declare class HelixHeadlessAccordion extends HelixElement {
|
|
|
44
40
|
* `collapsible` alongside `multiple` expressible and meaningless.
|
|
45
41
|
*/
|
|
46
42
|
mode?: 'single' | 'single-collapsible';
|
|
47
|
-
/**
|
|
43
|
+
/** The accordion's own items, in the order they are written. Browser only. */
|
|
48
44
|
get items(): HelixHeadlessAccordionItem[];
|
|
49
45
|
protected readonly keys: KeyboardNavigationController;
|
|
50
46
|
protected render(): TemplateResult;
|
|
@@ -2,33 +2,26 @@ import { ArrivalController, HelixElement } from '@fusion.dev/helix-core';
|
|
|
2
2
|
import { type PropertyValues, type TemplateResult } from 'lit';
|
|
3
3
|
declare const HelixHeadlessAnnouncement_base: (new (...args: any[]) => import("@fusion.dev/helix-core").DismissibleElement) & typeof HelixElement;
|
|
4
4
|
/**
|
|
5
|
-
* @summary A page
|
|
5
|
+
* @summary A message for the whole page, shown above its header, that can be dismissed.
|
|
6
6
|
*
|
|
7
7
|
* @description
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* is
|
|
12
|
-
* other.
|
|
8
|
+
* An announcement is a banner above the page header with news about the whole
|
|
9
|
+
* site or session, such as a trial ending, a degraded service, or a change of
|
|
10
|
+
* terms. For a passage inside a document, use `Callout`, which stays where it
|
|
11
|
+
* is placed and cannot be dismissed.
|
|
13
12
|
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
* announcement would cut across a screen-reader user on every page load, before
|
|
18
|
-
* they had read anything. Politeness costs a moment and is never wrong; the tone
|
|
19
|
-
* does not change that, because an error that was always there is still not an
|
|
20
|
-
* interruption.
|
|
13
|
+
* The announcement is always a polite live region, whatever its `tone`.
|
|
14
|
+
* `role="alert"` is assertive and interrupts a screen reader, so an
|
|
15
|
+
* announcement served with the page would interrupt on every page load.
|
|
21
16
|
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
* the page is filled at once and says nothing, being no news.
|
|
17
|
+
* The live region is its own part. When the announcement appears after the page
|
|
18
|
+
* has loaded, the message is written into the region one frame later, so screen
|
|
19
|
+
* readers read it reliably. When the announcement is in the served HTML, the
|
|
20
|
+
* region is filled at once and nothing is read out.
|
|
27
21
|
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
* `helix-dismiss` is a refusal.
|
|
22
|
+
* The dismiss button fires `helix-dismiss`, and the announcement stays in the
|
|
23
|
+
* document, so remove it in your listener. The event is cancelable, and
|
|
24
|
+
* `dismiss()` returns `false` when a listener calls `preventDefault()`.
|
|
32
25
|
*
|
|
33
26
|
* @since 0.1.0
|
|
34
27
|
* @status stable
|
|
@@ -37,20 +30,20 @@ declare const HelixHeadlessAnnouncement_base: (new (...args: any[]) => import("@
|
|
|
37
30
|
* @documentation https://fusion.dev/helix/components/announcement
|
|
38
31
|
*
|
|
39
32
|
* @slot - The message.
|
|
40
|
-
* @slot actions -
|
|
41
|
-
* @slot icon - Replaces the
|
|
33
|
+
* @slot actions - Actions for the message, usually a link or a button.
|
|
34
|
+
* @slot icon - Replaces the icon inside the dismiss button.
|
|
42
35
|
*
|
|
43
|
-
* @event {HelixDismissEvent} helix-dismiss -
|
|
36
|
+
* @event {HelixDismissEvent} helix-dismiss - The dismiss button was pressed. The announcement does not remove itself, so remove it in response. Cancelable.
|
|
44
37
|
*
|
|
45
|
-
* @csspart actions - The
|
|
46
|
-
* @csspart content - The message
|
|
47
|
-
* @csspart dismiss - The
|
|
48
|
-
* @csspart dismiss-mark - The
|
|
49
|
-
* @csspart live -
|
|
38
|
+
* @csspart actions - The region after the message that holds the actions.
|
|
39
|
+
* @csspart content - The region that holds the message.
|
|
40
|
+
* @csspart dismiss - The button that dismisses the announcement.
|
|
41
|
+
* @csspart dismiss-mark - The icon on the dismiss button, shown when the `icon` slot is empty.
|
|
42
|
+
* @csspart live - A copy of the message in a live region, read by screen readers when the announcement appears after the page has loaded. Visually hidden in the styled tier.
|
|
50
43
|
*/
|
|
51
44
|
export declare class HelixHeadlessAnnouncement extends HelixHeadlessAnnouncement_base {
|
|
52
45
|
/**
|
|
53
|
-
*
|
|
46
|
+
* The band's color.
|
|
54
47
|
*
|
|
55
48
|
* Paint only: unlike `Callout`, no value here draws a mark, changes the label,
|
|
56
49
|
* or moves the live region off polite. `neutral` is the resting value, said
|
|
@@ -4,18 +4,17 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
4
4
|
* @summary Page-level banner holding brand, navigation, and actions.
|
|
5
5
|
*
|
|
6
6
|
* @description
|
|
7
|
-
* Tracks whether the page has scrolled and
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
7
|
+
* Tracks whether the page has scrolled and sets the custom state `scrolled`, so
|
|
8
|
+
* the styled tier can lift the bar without a scroll handler of its own. The
|
|
9
|
+
* state is read when the element connects. A fresh load starts at the top,
|
|
10
|
+
* which matches the server markup, and a reload partway down the page is
|
|
11
|
+
* corrected on hydration.
|
|
12
12
|
*
|
|
13
|
-
*
|
|
14
|
-
* onto its own host is one the server did not send
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
* it.
|
|
13
|
+
* The element uses a custom state because an attribute such as `data-scrolled`,
|
|
14
|
+
* written onto its own host, is one the server did not send. A hydrating
|
|
15
|
+
* framework would report a mismatch whenever the page reloads far enough down.
|
|
16
|
+
* `ElementInternals.states` is not in the DOM, so hydration has nothing to
|
|
17
|
+
* compare. Select the state with `:state(scrolled)`.
|
|
19
18
|
*
|
|
20
19
|
* @since 0.1.0
|
|
21
20
|
* @status stable
|
|
@@ -28,9 +27,10 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
28
27
|
* @slot start - Leading content, usually a wordmark.
|
|
29
28
|
*
|
|
30
29
|
* @event {HelixScrolledEvent} helix-scrolled - Fired when the page crosses the
|
|
31
|
-
* threshold, with the new state. A custom state cannot be observed the
|
|
32
|
-
* attribute
|
|
33
|
-
*
|
|
30
|
+
* scroll threshold, with the new state. A custom state cannot be observed the
|
|
31
|
+
* way an attribute can, so listen for this event to follow it. The event uses
|
|
32
|
+
* the header's own threshold and hysteresis, so you do not need a second scroll
|
|
33
|
+
* listener.
|
|
34
34
|
*
|
|
35
35
|
* @csspart content - The middle region.
|
|
36
36
|
* @csspart end - The trailing region.
|
|
@@ -16,60 +16,40 @@ export interface AreaStack {
|
|
|
16
16
|
}
|
|
17
17
|
declare const HelixHeadlessAreaChart_base: typeof HelixElement & (new (...args: any[]) => import("@fusion.dev/helix-core").MixinChartSourceInterface);
|
|
18
18
|
/**
|
|
19
|
-
* @summary
|
|
19
|
+
* @summary A chart that shows how a total is made up over time, as bands stacked on one another.
|
|
20
20
|
*
|
|
21
21
|
* @description
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
* thickness of a band.
|
|
22
|
+
* Shows how a total is made up. Each numeric column of the table is a part, the
|
|
23
|
+
* parts add up to the total at each reading, and the top edge is that total.
|
|
24
|
+
* The thickness of a band is that part's amount.
|
|
26
25
|
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
* the
|
|
30
|
-
* is made up.
|
|
26
|
+
* Use `LineChart` with `area` to show how each series moved: it fills each
|
|
27
|
+
* series from the floor separately, so the fills overlap. Use this chart to
|
|
28
|
+
* show the composition: it stacks the series.
|
|
31
29
|
*
|
|
32
|
-
* **
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
* own range because a line claims a position; a band claims an amount.
|
|
30
|
+
* **The value axis always starts at zero**, as in `BarChart`, because a band's
|
|
31
|
+
* thickness is its value. For the same reason there is no streamgraph mode,
|
|
32
|
+
* which moves the baseline. To show how the composition changed, set `share`.
|
|
36
33
|
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
* carries no alias for it. What it has instead is `share`, which answers the
|
|
41
|
-
* question a streamgraph is usually reached for, how the composition changed,
|
|
42
|
-
* without giving up a floor a reader can measure against.
|
|
34
|
+
* Band edges are straight between readings by default. A smoothed curve through
|
|
35
|
+
* one sum can dip below the curve through the sum beneath it, which draws a
|
|
36
|
+
* part as less than zero. Other curves:
|
|
43
37
|
*
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
* ordered. `curve="smooth"` is there for a stack that is read as a shape.
|
|
38
|
+
* - `curve="smooth"`: for a stack read as an overall shape.
|
|
39
|
+
* - `curve="step"`: holds each reading and jumps at the midpoint, so stacked
|
|
40
|
+
* edges stay in order, as with `straight`. Use it for a quantity that changes
|
|
41
|
+
* at a moment, such as a headcount or a price.
|
|
49
42
|
*
|
|
50
|
-
* `
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
* it holds one, jumps at the midpoint, and holds the next. So two stepped edges
|
|
54
|
-
* that are ordered at every reading are ordered everywhere between them, which
|
|
55
|
-
* is what `straight` is chosen for. It is the curve for a quantity that changes
|
|
56
|
-
* at a moment rather than across an interval, a headcount or a price, where a
|
|
57
|
-
* sloped edge claims a gradual change nothing measured.
|
|
43
|
+
* `share` draws each reading as 100 percent, so the top edge is flat and the
|
|
44
|
+
* bands show each part's share. Use it to see which part grew. The default
|
|
45
|
+
* shows whether the total grew.
|
|
58
46
|
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
*
|
|
47
|
+
* The drawing is `aria-hidden`. The text summary gives the latest reading's
|
|
48
|
+
* total and each part's share of it, and the table beside the chart has every
|
|
49
|
+
* number.
|
|
62
50
|
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
65
|
-
* number; what the drawing adds is the composition, so the summary says the
|
|
66
|
-
* latest reading's total and each part's share of it. The drawing itself is
|
|
67
|
-
* `aria-hidden`.
|
|
68
|
-
*
|
|
69
|
-
* Every numeric column is a part. A table that carries its own total column
|
|
70
|
-
* would count it twice, so leave it out of the table the chart reads.
|
|
71
|
-
* A negative reading is drawn as none: a part of a whole cannot be less than
|
|
72
|
-
* nothing, and a band that folded under its neighbor would say it was.
|
|
51
|
+
* Every numeric column is a part, so leave a total column out of the table the
|
|
52
|
+
* chart reads, or it is counted twice. A negative reading is drawn as zero.
|
|
73
53
|
*
|
|
74
54
|
* @since 0.1.0
|
|
75
55
|
* @status stable
|
|
@@ -86,7 +66,7 @@ declare const HelixHeadlessAreaChart_base: typeof HelixElement & (new (...args:
|
|
|
86
66
|
* @csspart line - The top edge of one part's band.
|
|
87
67
|
* @csspart mark - The invisible point the tooltip is anchored to.
|
|
88
68
|
* @csspart plot - The drawing.
|
|
89
|
-
* @csspart summary - The total and
|
|
69
|
+
* @csspart summary - The total and each part's share at the latest reading, written as a sentence for screen readers.
|
|
90
70
|
* @csspart svg - The drawing surface the bands sit on.
|
|
91
71
|
* @csspart tooltip - The bubble, forwarded from `Tooltip`.
|
|
92
72
|
* @csspart tooltip-anchor - The `Tooltip` element itself.
|
|
@@ -134,14 +114,15 @@ export declare class HelixHeadlessAreaChart extends HelixHeadlessAreaChart_base
|
|
|
134
114
|
*/
|
|
135
115
|
gridlines?: 'both' | 'category' | 'value';
|
|
136
116
|
/**
|
|
137
|
-
*
|
|
117
|
+
* Draws each reading as a hundred percent, so each band shows its share of
|
|
118
|
+
* the total.
|
|
138
119
|
*
|
|
139
120
|
* Absent stacks the amounts, so the top edge is the total. Set, every reading
|
|
140
121
|
* fills the height and the bands are shares of it.
|
|
141
122
|
*/
|
|
142
123
|
share: boolean;
|
|
143
124
|
/**
|
|
144
|
-
*
|
|
125
|
+
* The name for the sum of the parts, shown in the tooltip and the summary.
|
|
145
126
|
*/
|
|
146
127
|
totalLabel: string;
|
|
147
128
|
private warnedAboutNegatives;
|
|
@@ -14,16 +14,14 @@ export declare const FOLDS_UP_TO = 12;
|
|
|
14
14
|
* @summary Overlapping avatars, with a count for the ones not shown.
|
|
15
15
|
*
|
|
16
16
|
* @description
|
|
17
|
-
* A part of `Avatar`
|
|
18
|
-
* is about nothing else.
|
|
17
|
+
* A part of `Avatar` that arranges avatars.
|
|
19
18
|
*
|
|
20
|
-
*
|
|
21
|
-
* is
|
|
22
|
-
*
|
|
19
|
+
* The group computes the overflow count from `max` and renders the "+3" itself.
|
|
20
|
+
* There is no slot for it, because the number has to match which avatars are
|
|
21
|
+
* hidden.
|
|
23
22
|
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
* name is still built from all of them.
|
|
23
|
+
* Avatars past `max` stay in the DOM and are hidden. Changing `max` re-renders
|
|
24
|
+
* nothing, and the accessible name is still built from all of them.
|
|
27
25
|
*
|
|
28
26
|
* @since 0.1.0
|
|
29
27
|
* @status stable
|
|
@@ -3,19 +3,19 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
3
3
|
/** Initials for a name: first letter of the first and last words. */
|
|
4
4
|
export declare const initialsOf: (name: string) => string;
|
|
5
5
|
/**
|
|
6
|
-
* @summary
|
|
6
|
+
* @summary A person or entity, shown as an image or as their initials.
|
|
7
7
|
*
|
|
8
8
|
* @description
|
|
9
|
-
* Shows `src` until it fails to load. Without an image, or after a failure,
|
|
10
|
-
*
|
|
9
|
+
* Shows `src` until it fails to load. Without an image, or after a failure, the
|
|
10
|
+
* default slot is shown, and its own fallback is the initials.
|
|
11
11
|
*
|
|
12
|
-
* The host carries the accessible name, taken from `name
|
|
13
|
-
* empty `alt` and the initials are hidden from assistive technology
|
|
14
|
-
*
|
|
15
|
-
*
|
|
12
|
+
* The host carries the accessible name, taken from `name`. The `<img>` has an
|
|
13
|
+
* empty `alt` and the initials are hidden from assistive technology, so the
|
|
14
|
+
* name is announced once. Set `aria-label` on the host to override `name` when
|
|
15
|
+
* a person's name does not describe what the avatar stands for.
|
|
16
16
|
*
|
|
17
|
-
* `load` and `error` are
|
|
18
|
-
* stop at the shadow boundary
|
|
17
|
+
* `load` and `error` are re-dispatched from the host, because they are not
|
|
18
|
+
* composed and would otherwise stop at the shadow boundary.
|
|
19
19
|
*
|
|
20
20
|
* @since 0.1.0
|
|
21
21
|
* @status stable
|
|
@@ -45,8 +45,8 @@ export declare class HelixHeadlessAvatar extends HelixElement {
|
|
|
45
45
|
*/
|
|
46
46
|
src: string;
|
|
47
47
|
/**
|
|
48
|
-
*
|
|
49
|
-
*
|
|
48
|
+
* The image's state: `loading` while it is on its way, `loaded` once it
|
|
49
|
+
* arrives, or `error` when it fails and the initials replace it.
|
|
50
50
|
*
|
|
51
51
|
* Read-only to a consumer: it is a report rather than a setting, and the same
|
|
52
52
|
* report `Image` gives, for the same reason. `load` and `error` fire once, so
|
|
@@ -1,23 +1,22 @@
|
|
|
1
1
|
import { HelixElement } from '@fusion.dev/helix-core';
|
|
2
2
|
import { type TemplateResult } from 'lit';
|
|
3
3
|
/**
|
|
4
|
-
* @summary
|
|
4
|
+
* @summary A count or a dot pinned to the corner of another element.
|
|
5
5
|
*
|
|
6
6
|
* @description
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
* not a container that happens to hold an icon.
|
|
7
|
+
* Badge wraps the element it decorates and pins an indicator to its corner, so
|
|
8
|
+
* the wrapped element keeps its place in the layout.
|
|
10
9
|
*
|
|
11
|
-
*
|
|
12
|
-
* shows no mark at all, an absent one shows a bare dot, and any other value
|
|
13
|
-
* shows the value. `max` caps the top: past it the indicator reads `{max}+`
|
|
14
|
-
* rather than growing to fit, since a corner mark that widens with its value
|
|
15
|
-
* pushes the layout around.
|
|
10
|
+
* What the indicator shows depends on `value`:
|
|
16
11
|
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
12
|
+
* - A `value` of zero shows no indicator.
|
|
13
|
+
* - No `value` shows a dot.
|
|
14
|
+
* - Any other value shows the value. Above `max`, the indicator shows `{max}+`,
|
|
15
|
+
* so its width stays the same as the count grows.
|
|
16
|
+
*
|
|
17
|
+
* A count is announced from its own text, and `label` replaces that with a
|
|
18
|
+
* fuller name, such as `4 unread`. A dot needs a `label`. Without one, the dot
|
|
19
|
+
* is a colored circle that screen readers do not announce.
|
|
21
20
|
*
|
|
22
21
|
* @since 0.1.0
|
|
23
22
|
* @status stable
|
|
@@ -31,13 +30,13 @@ import { type TemplateResult } from 'lit';
|
|
|
31
30
|
*/
|
|
32
31
|
export declare class HelixHeadlessBadge extends HelixElement {
|
|
33
32
|
/**
|
|
34
|
-
*
|
|
33
|
+
* The badge's name, read by screen readers.
|
|
35
34
|
*
|
|
36
35
|
* Required for a dot, which has no text to read.
|
|
37
36
|
*/
|
|
38
37
|
label: string;
|
|
39
38
|
/**
|
|
40
|
-
*
|
|
39
|
+
* The largest number the badge shows.
|
|
41
40
|
*
|
|
42
41
|
* Past it the indicator reads `{max}+`.
|
|
43
42
|
*/
|