@fusion.dev/helix-headless 0.148.0 → 0.149.1
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 +6966 -1798
- package/dist/announcement/root/announcement-root.d.ts +5 -0
- package/dist/announcement/root/announcement-root.js +5 -2
- package/dist/area-chart/root/area-chart-root.d.ts +11 -0
- package/dist/area-chart/root/area-chart-root.js +20 -7
- package/dist/avatar/group/avatar-group.d.ts +10 -2
- package/dist/avatar/group/avatar-group.js +10 -5
- package/dist/badge/count.d.ts +6 -1
- package/dist/badge/count.js +3 -3
- package/dist/badge/root/badge-root.d.ts +6 -2
- package/dist/badge/root/badge-root.js +3 -3
- package/dist/bar-chart/root/bar-chart-root.d.ts +13 -1
- package/dist/bar-chart/root/bar-chart-root.js +17 -4
- package/dist/breadcrumbs/root/breadcrumbs-root.d.ts +8 -1
- package/dist/breadcrumbs/root/breadcrumbs-root.js +5 -2
- package/dist/button/root/button-root.d.ts +10 -1
- package/dist/button/root/button-root.js +3 -2
- package/dist/button-group/root/button-group-root.d.ts +3 -0
- package/dist/button-group/root/button-group-root.js +2 -2
- package/dist/callout/root/callout-root.d.ts +16 -2
- package/dist/callout/root/callout-root.js +16 -4
- package/dist/canvas/describe.d.ts +10 -0
- package/dist/canvas/describe.js +9 -0
- package/dist/canvas/neighbor.d.ts +17 -0
- package/dist/canvas/neighbor.js +1 -0
- package/dist/canvas/node/canvas-node.js +3 -2
- package/dist/canvas/root/canvas-root.d.ts +65 -8
- package/dist/canvas/root/canvas-root.js +115 -49
- package/dist/carousel/root/carousel-root.d.ts +5 -0
- package/dist/carousel/root/carousel-root.js +16 -5
- package/dist/chat/composer/chat-composer.d.ts +5 -0
- package/dist/chat/composer/chat-composer.js +4 -1
- package/dist/chat/message/chat-message.d.ts +9 -5
- package/dist/chat/message/chat-message.js +8 -4
- package/dist/chat/naming.js +2 -2
- package/dist/chat/root/chat-root.d.ts +27 -1
- package/dist/chat/root/chat-root.js +37 -9
- package/dist/checkbox/root/checkbox-root.d.ts +11 -0
- package/dist/checkbox/root/checkbox-root.js +8 -2
- package/dist/checkbox-group/root/checkbox-group-root.d.ts +11 -0
- package/dist/checkbox-group/root/checkbox-group-root.js +11 -3
- package/dist/code-block/root/code-block-root.d.ts +12 -2
- package/dist/code-block/root/code-block-root.js +12 -2
- package/dist/color-input/root/color-input-root.d.ts +13 -0
- package/dist/color-input/root/color-input-root.js +18 -5
- package/dist/color-picker/root/color-picker-root.d.ts +19 -3
- package/dist/color-picker/root/color-picker-root.js +47 -13
- package/dist/combobox/root/combobox-root.d.ts +36 -7
- package/dist/combobox/root/combobox-root.js +37 -12
- package/dist/command/root/command-root.d.ts +15 -6
- package/dist/command/root/command-root.js +9 -4
- package/dist/copy-button/root/copy-button-root.d.ts +5 -0
- package/dist/copy-button/root/copy-button-root.js +7 -2
- package/dist/data-table/root/data-table-root.d.ts +171 -29
- package/dist/data-table/root/data-table-root.js +268 -118
- package/dist/date-input/root/date-input-root.d.ts +32 -9
- package/dist/date-input/root/date-input-root.js +66 -44
- package/dist/date-picker/root/date-picker-root.d.ts +38 -15
- package/dist/date-picker/root/date-picker-root.js +52 -33
- package/dist/dialog/root/dialog-root.d.ts +12 -1
- package/dist/dialog/root/dialog-root.js +11 -4
- package/dist/donut-chart/root/donut-chart-root.d.ts +5 -0
- package/dist/donut-chart/root/donut-chart-root.js +8 -5
- package/dist/drawer/root/drawer-root.d.ts +12 -1
- package/dist/drawer/root/drawer-root.js +9 -2
- package/dist/drilldown/root/drilldown-root.d.ts +5 -0
- package/dist/drilldown/root/drilldown-root.js +4 -1
- package/dist/element-events.generated.js +25 -3
- package/dist/file-input/root/file-input-root.d.ts +18 -3
- package/dist/file-input/root/file-input-root.js +34 -17
- package/dist/filter-input/chip/filter-chip.d.ts +13 -0
- package/dist/filter-input/chip/filter-chip.js +6 -1
- package/dist/filter-input/menu/filter-menu.d.ts +5 -0
- package/dist/filter-input/menu/filter-menu.js +3 -1
- package/dist/filter-input/root/filter-input-root.d.ts +20 -3
- package/dist/filter-input/root/filter-input-root.js +8 -4
- package/dist/format-date/root/format-date-root.d.ts +20 -2
- package/dist/format-date/root/format-date-root.js +5 -2
- package/dist/graph/root/graph-model.d.ts +11 -0
- package/dist/graph/root/graph-model.js +4 -0
- package/dist/graph/root/graph-root.d.ts +78 -9
- package/dist/graph/root/graph-root.js +124 -27
- package/dist/heatmap/root/heatmap-root.d.ts +25 -4
- package/dist/heatmap/root/heatmap-root.js +27 -7
- package/dist/icon-button/root/icon-button-root.d.ts +5 -0
- package/dist/icon-button/root/icon-button-root.js +1 -0
- package/dist/input/root/input-root.d.ts +5 -0
- package/dist/input/root/input-root.js +4 -1
- package/dist/lightbox/root/lightbox-root.d.ts +14 -4
- package/dist/lightbox/root/lightbox-root.js +25 -7
- package/dist/line-chart/root/line-chart-root.d.ts +5 -0
- package/dist/line-chart/root/line-chart-root.js +4 -2
- package/dist/list/item/list-item.d.ts +32 -0
- package/dist/list/item/list-item.js +34 -7
- package/dist/list/root/list-root.d.ts +87 -0
- package/dist/list/root/list-root.js +112 -2
- package/dist/listbox/reorder/index.d.ts +1 -0
- package/dist/listbox/reorder/index.js +4 -0
- package/dist/listbox/reorder/listbox-reorder.d.ts +83 -0
- package/dist/listbox/reorder/listbox-reorder.js +151 -0
- package/dist/listbox/root/listbox-root.d.ts +68 -11
- package/dist/listbox/root/listbox-root.js +41 -9
- package/dist/loader/root/loader-root.d.ts +5 -0
- package/dist/loader/root/loader-root.js +3 -1
- package/dist/map/area/map-area.d.ts +5 -0
- package/dist/map/area/map-area.js +3 -1
- package/dist/map/buildings/map-buildings.d.ts +5 -0
- package/dist/map/buildings/map-buildings.js +3 -1
- package/dist/map/contours/map-contours.d.ts +5 -0
- package/dist/map/contours/map-contours.js +3 -1
- package/dist/map/landcover/map-landcover.d.ts +5 -0
- package/dist/map/landcover/map-landcover.js +3 -1
- package/dist/map/marker/map-marker.d.ts +16 -1
- package/dist/map/marker/map-marker.js +13 -5
- package/dist/map/points/map-points.d.ts +5 -0
- package/dist/map/points/map-points.js +6 -4
- package/dist/map/position/map-position.d.ts +5 -0
- package/dist/map/position/map-position.js +3 -1
- package/dist/map/raster/map-raster.d.ts +5 -0
- package/dist/map/raster/map-raster.js +3 -1
- package/dist/map/root/map-root.d.ts +33 -14
- package/dist/map/root/map-root.js +59 -22
- package/dist/map/route/map-route.d.ts +5 -0
- package/dist/map/route/map-route.js +3 -1
- package/dist/map/terrain/map-terrain.d.ts +5 -0
- package/dist/map/terrain/map-terrain.js +3 -1
- package/dist/menu/root/menu-root.d.ts +5 -0
- package/dist/menu/root/menu-root.js +3 -1
- package/dist/meter/root/meter-root.d.ts +16 -3
- package/dist/meter/root/meter-root.js +12 -5
- package/dist/navigation/root/navigation-root.d.ts +5 -0
- package/dist/navigation/root/navigation-root.js +3 -1
- package/dist/notifications/notification/notification.d.ts +5 -0
- package/dist/notifications/notification/notification.js +3 -1
- package/dist/notifications/root/notifications-root.d.ts +8 -0
- package/dist/notifications/root/notifications-root.js +10 -2
- package/dist/number-input/root/number-input-root.d.ts +21 -8
- package/dist/number-input/root/number-input-root.js +26 -11
- package/dist/object-inspector/root/object-inspector-root.d.ts +51 -12
- package/dist/object-inspector/root/object-inspector-root.js +21 -20
- package/dist/outline/root/outline-root.d.ts +5 -0
- package/dist/outline/root/outline-root.js +3 -1
- package/dist/pagination/root/pagination-root.d.ts +7 -1
- package/dist/pagination/root/pagination-root.js +16 -7
- package/dist/pagination/size/pagination-size.d.ts +7 -3
- package/dist/pagination/size/pagination-size.js +4 -2
- package/dist/pagination/summary/pagination-summary.d.ts +8 -6
- package/dist/pagination/summary/pagination-summary.js +4 -9
- package/dist/pin-input/code.d.ts +6 -6
- package/dist/pin-input/code.js +1 -5
- package/dist/pin-input/root/pin-input-root.d.ts +9 -3
- package/dist/pin-input/root/pin-input-root.js +6 -2
- package/dist/popover/root/popover-root.d.ts +12 -2
- package/dist/popover/root/popover-root.js +10 -4
- package/dist/progress/root/progress-root.d.ts +7 -2
- package/dist/progress/root/progress-root.js +5 -2
- package/dist/qr-code/name.d.ts +3 -2
- package/dist/qr-code/name.js +2 -2
- package/dist/qr-code/root/qr-code-root.d.ts +12 -2
- package/dist/qr-code/root/qr-code-root.js +9 -2
- package/dist/radio/group/radio-group.d.ts +11 -0
- package/dist/radio/group/radio-group.js +8 -2
- package/dist/rating/root/rating-root.d.ts +12 -1
- package/dist/rating/root/rating-root.js +10 -3
- package/dist/scatter-chart/root/scatter-chart-root.d.ts +20 -2
- package/dist/scatter-chart/root/scatter-chart-root.js +20 -5
- package/dist/select/root/select-root.d.ts +11 -0
- package/dist/select/root/select-root.js +13 -3
- package/dist/skip-link/root/skip-link-root.d.ts +5 -0
- package/dist/skip-link/root/skip-link-root.js +3 -1
- package/dist/slider/root/slider-root.d.ts +7 -2
- package/dist/slider/root/slider-root.js +11 -5
- package/dist/sparkline/readings.d.ts +15 -5
- package/dist/sparkline/readings.js +3 -3
- package/dist/sparkline/root/sparkline-root.d.ts +9 -4
- package/dist/sparkline/root/sparkline-root.js +9 -3
- package/dist/speed-dial/root/speed-dial-root.d.ts +5 -0
- package/dist/speed-dial/root/speed-dial-root.js +4 -1
- package/dist/splitter/root/splitter-root.d.ts +6 -1
- package/dist/splitter/root/splitter-root.js +9 -4
- package/dist/steps/root/steps-root.d.ts +9 -2
- package/dist/steps/root/steps-root.js +6 -3
- package/dist/steps/step/step.d.ts +12 -0
- package/dist/steps/step/step.js +11 -2
- package/dist/switch/root/switch-root.d.ts +11 -0
- package/dist/switch/root/switch-root.js +8 -2
- package/dist/table/column/table-column.d.ts +11 -4
- package/dist/table/column/table-column.js +15 -10
- package/dist/table/grid-controller.d.ts +8 -3
- package/dist/table/grid-controller.js +17 -11
- package/dist/table/root/table-root.d.ts +107 -5
- package/dist/table/root/table-root.js +122 -20
- package/dist/table/row/table-row.d.ts +42 -0
- package/dist/table/row/table-row.js +40 -1
- package/dist/tabs/root/tabs-root.d.ts +5 -0
- package/dist/tabs/root/tabs-root.js +3 -1
- package/dist/tag/group/tag-group.d.ts +5 -0
- package/dist/tag/group/tag-group.js +3 -1
- package/dist/tag/root/tag-root.d.ts +14 -1
- package/dist/tag/root/tag-root.js +11 -8
- package/dist/textarea/root/textarea-root.d.ts +5 -0
- package/dist/textarea/root/textarea-root.js +3 -1
- package/dist/time-input/root/time-input-root.d.ts +14 -7
- package/dist/time-input/root/time-input-root.js +43 -32
- package/dist/time-picker/root/time-picker-root.d.ts +15 -7
- package/dist/time-picker/root/time-picker-root.js +25 -12
- package/dist/toast/item/toast-item.d.ts +7 -0
- package/dist/toast/item/toast-item.js +1 -0
- package/dist/toast/root/toast-root.d.ts +9 -1
- package/dist/toast/root/toast-root.js +5 -4
- package/dist/toolbar/root/toolbar-root.d.ts +5 -0
- package/dist/toolbar/root/toolbar-root.js +5 -2
- package/dist/tooltip/root/tooltip-root.d.ts +27 -17
- package/dist/tour/root/tour-root.d.ts +8 -2
- package/dist/tour/root/tour-root.js +4 -2
- package/dist/tour/stop/tour-stop.d.ts +5 -0
- package/dist/tour/stop/tour-stop.js +6 -1
- package/dist/tree/grip.d.ts +5 -0
- package/dist/tree/grip.js +1 -0
- package/dist/tree/item/tree-item.d.ts +24 -0
- package/dist/tree/item/tree-item.js +27 -5
- package/dist/tree/root/tree-root.d.ts +66 -1
- package/dist/tree/root/tree-root.js +77 -5
- package/dist/trend/root/trend-root.d.ts +20 -4
- package/dist/trend/root/trend-root.js +20 -5
- package/dist/video/root/video-root.d.ts +12 -3
- package/dist/video/root/video-root.js +41 -14
- package/dist/video-playlist/menu/video-playlist-menu.d.ts +5 -0
- package/dist/video-playlist/menu/video-playlist-menu.js +3 -1
- package/dist/video-playlist/root/video-playlist-root.d.ts +5 -0
- package/dist/video-playlist/root/video-playlist-root.js +3 -1
- package/dist/virtual-list/root/virtual-list-root.d.ts +19 -3
- package/dist/virtual-list/root/virtual-list-root.js +5 -2
- package/lint.json +1 -1
- package/package.json +9 -8
- package/types/jsx.d.ts +4014 -1862
- package/types/vue.d.ts +1266 -624
- package/types/words.d.ts +3280 -0
- package/dist/toast/hotkey.d.ts +0 -22
- package/dist/toast/hotkey.js +0 -23
|
@@ -26,6 +26,11 @@ import type { MapTerrainEncoding } from '../terrain/map-terrain.js';
|
|
|
26
26
|
* @event {HelixMapPartChangeEvent} helix-map-part-change - The tiles, the unit, or the layer's name or color changed. Used by `connectMap`; pages do not need to listen for it.
|
|
27
27
|
*/
|
|
28
28
|
export declare class HelixHeadlessMapContours extends HelixElement {
|
|
29
|
+
/**
|
|
30
|
+
* The key this part's words are registered under, its styled tag:
|
|
31
|
+
* `registerWords('de', { 'helix-map-contours': { label: 'Höhenlinien' } })`.
|
|
32
|
+
*/
|
|
33
|
+
static words: string;
|
|
29
34
|
/** The elevation provider's credit, shown in the frame's footer. Links in it stay links. */
|
|
30
35
|
attribution?: string;
|
|
31
36
|
/** More about the lines. Read after the label in the frame's list. */
|
|
@@ -4,7 +4,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
4
4
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
|
-
import { customElement, HelixElement, HelixMapPartChangeEvent } from '@fusion.dev/helix-core';
|
|
7
|
+
import { customElement, HelixElement, HelixMapPartChangeEvent, words } from '@fusion.dev/helix-core';
|
|
8
8
|
import { nothing } from 'lit';
|
|
9
9
|
import { property } from 'lit/decorators.js';
|
|
10
10
|
let HelixHeadlessMapContours = class HelixHeadlessMapContours extends HelixElement {
|
|
@@ -16,6 +16,7 @@ let HelixHeadlessMapContours = class HelixHeadlessMapContours extends HelixEleme
|
|
|
16
16
|
this.label = 'Contour lines';
|
|
17
17
|
this.unit = 'meters';
|
|
18
18
|
}
|
|
19
|
+
static { this.words = 'helix-map-contours'; }
|
|
19
20
|
updated(changed) {
|
|
20
21
|
super.updated(changed);
|
|
21
22
|
this.dispatchEvent(new HelixMapPartChangeEvent({ kind: 'layer' }));
|
|
@@ -37,6 +38,7 @@ __decorate([
|
|
|
37
38
|
property()
|
|
38
39
|
], HelixHeadlessMapContours.prototype, "group", void 0);
|
|
39
40
|
__decorate([
|
|
41
|
+
words,
|
|
40
42
|
property()
|
|
41
43
|
], HelixHeadlessMapContours.prototype, "label", void 0);
|
|
42
44
|
__decorate([
|
|
@@ -22,6 +22,11 @@ import { nothing, type PropertyValues } from 'lit';
|
|
|
22
22
|
* @event {HelixMapPartChangeEvent} helix-map-part-change - The layer's name or color changed. Used by `connectMap`; pages do not need to listen for it.
|
|
23
23
|
*/
|
|
24
24
|
export declare class HelixHeadlessMapLandcover extends HelixElement {
|
|
25
|
+
/**
|
|
26
|
+
* The key this part's words are registered under, its styled tag:
|
|
27
|
+
* `registerWords('de', { 'helix-map-landcover': { label: 'Bodenbedeckung' } })`.
|
|
28
|
+
*/
|
|
29
|
+
static words: string;
|
|
25
30
|
/** More about the land cover. Read after the label in the frame's list. */
|
|
26
31
|
description?: string;
|
|
27
32
|
/**
|
|
@@ -4,7 +4,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
4
4
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
|
-
import { customElement, HelixElement, HelixMapPartChangeEvent } from '@fusion.dev/helix-core';
|
|
7
|
+
import { customElement, HelixElement, HelixMapPartChangeEvent, words } from '@fusion.dev/helix-core';
|
|
8
8
|
import { nothing } from 'lit';
|
|
9
9
|
import { property } from 'lit/decorators.js';
|
|
10
10
|
let HelixHeadlessMapLandcover = class HelixHeadlessMapLandcover extends HelixElement {
|
|
@@ -14,6 +14,7 @@ let HelixHeadlessMapLandcover = class HelixHeadlessMapLandcover extends HelixEle
|
|
|
14
14
|
this.layerKind = 'landcover';
|
|
15
15
|
this.label = 'Land cover';
|
|
16
16
|
}
|
|
17
|
+
static { this.words = 'helix-map-landcover'; }
|
|
17
18
|
updated(changed) {
|
|
18
19
|
super.updated(changed);
|
|
19
20
|
this.dispatchEvent(new HelixMapPartChangeEvent({ kind: 'layer' }));
|
|
@@ -29,6 +30,7 @@ __decorate([
|
|
|
29
30
|
property()
|
|
30
31
|
], HelixHeadlessMapLandcover.prototype, "group", void 0);
|
|
31
32
|
__decorate([
|
|
33
|
+
words,
|
|
32
34
|
property()
|
|
33
35
|
], HelixHeadlessMapLandcover.prototype, "label", void 0);
|
|
34
36
|
HelixHeadlessMapLandcover = __decorate([
|
|
@@ -41,6 +41,11 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
41
41
|
* @cssstate start - Shows its name before the point, because there was no room after it.
|
|
42
42
|
*/
|
|
43
43
|
export declare class HelixHeadlessMapMarker extends HelixElement {
|
|
44
|
+
/**
|
|
45
|
+
* The key this part's words are registered under, its styled tag:
|
|
46
|
+
* `registerWords('de', { 'helix-map-marker': { passedLabel: '{label}, besucht' } })`.
|
|
47
|
+
*/
|
|
48
|
+
static words: string;
|
|
44
49
|
/**
|
|
45
50
|
* @internal Whether the map's one tab stop is on this marker, written by the
|
|
46
51
|
* frame. Not a consumer's to set: the frame keeps exactly one.
|
|
@@ -105,7 +110,12 @@ export declare class HelixHeadlessMapMarker extends HelixElement {
|
|
|
105
110
|
* drawn muted, and its name is followed by `passed-label`.
|
|
106
111
|
*/
|
|
107
112
|
passed: boolean;
|
|
108
|
-
/**
|
|
113
|
+
/**
|
|
114
|
+
* What a passed place is called. `{label}` is its name.
|
|
115
|
+
*
|
|
116
|
+
* A word without `{label}`, such as `visited`, is written after the name
|
|
117
|
+
* with a comma, as before the sentence held the name.
|
|
118
|
+
*/
|
|
109
119
|
passedLabel: string;
|
|
110
120
|
/** Whether focus is on this marker as it is gathered, and so has to move on. */
|
|
111
121
|
private handingOver;
|
|
@@ -125,6 +135,11 @@ export declare class HelixHeadlessMapMarker extends HelixElement {
|
|
|
125
135
|
extent(): number;
|
|
126
136
|
/** Focuses the marker's button. The host draws no box of its own. */
|
|
127
137
|
focus(options?: FocusOptions): void;
|
|
138
|
+
/**
|
|
139
|
+
* A passed place's name in `passed-label`, or followed by a page's word
|
|
140
|
+
* that does not hold `{label}`.
|
|
141
|
+
*/
|
|
142
|
+
private passedSaid;
|
|
128
143
|
protected render(): TemplateResult;
|
|
129
144
|
}
|
|
130
145
|
declare global {
|
|
@@ -4,7 +4,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
4
4
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
|
-
import { customElement, HelixElement, HelixMapPartChangeEvent, PlacementController, } from '@fusion.dev/helix-core';
|
|
7
|
+
import { customElement, formatNumber, formatWords, HelixElement, HelixMapPartChangeEvent, PlacementController, words, wordsLocale, } from '@fusion.dev/helix-core';
|
|
8
8
|
import { html, nothing } from 'lit';
|
|
9
9
|
import { property, state } from 'lit/decorators.js';
|
|
10
10
|
const BOOKKEEPING = new Set([
|
|
@@ -28,9 +28,10 @@ let HelixHeadlessMapMarker = class HelixHeadlessMapMarker extends HelixElement {
|
|
|
28
28
|
this.placement = new PlacementController(this);
|
|
29
29
|
this.name = '';
|
|
30
30
|
this.passed = false;
|
|
31
|
-
this.passedLabel = 'passed';
|
|
31
|
+
this.passedLabel = '{label}, passed';
|
|
32
32
|
this.handingOver = false;
|
|
33
33
|
}
|
|
34
|
+
static { this.words = 'helix-map-marker'; }
|
|
34
35
|
place(properties) {
|
|
35
36
|
this.placement.set(properties);
|
|
36
37
|
this.toggleState('placed', this.placement.get('--_map-marker-x') !== undefined);
|
|
@@ -75,12 +76,18 @@ let HelixHeadlessMapMarker = class HelixHeadlessMapMarker extends HelixElement {
|
|
|
75
76
|
focus(options) {
|
|
76
77
|
this.partNamed('marker')?.focus(options);
|
|
77
78
|
}
|
|
79
|
+
passedSaid(name) {
|
|
80
|
+
return this.passedLabel.includes('{label}')
|
|
81
|
+
? formatWords(this, 'passedLabel', { label: name })
|
|
82
|
+
: html `${name}, ${this.passedLabel}`;
|
|
83
|
+
}
|
|
78
84
|
render() {
|
|
79
85
|
const cluster = this.gathered.length > 1;
|
|
80
|
-
const
|
|
86
|
+
const locale = cluster ? wordsLocale(this) : '';
|
|
87
|
+
const name = this.label ?? '';
|
|
81
88
|
return html `<span part="marker" role="button" tabindex=${this.current ? '0' : '-1'} ?hidden=${this.gatheredBy !== undefined}>
|
|
82
|
-
<span part="point" aria-hidden="true">${cluster ?
|
|
83
|
-
<span part="label">${cluster ? new Intl.ListFormat(
|
|
89
|
+
<span part="point" aria-hidden="true">${cluster ? formatNumber(this.gathered.length, locale) : nothing}<slot name="icon" ?hidden=${cluster} @slotchange=${() => this.requestUpdate()}></slot></span>
|
|
90
|
+
<span part="label">${cluster ? new Intl.ListFormat(locale, { type: 'conjunction' }).format(this.gathered) : this.passed ? this.passedSaid(name) : name}</span>
|
|
84
91
|
</span>`;
|
|
85
92
|
}
|
|
86
93
|
};
|
|
@@ -118,6 +125,7 @@ __decorate([
|
|
|
118
125
|
property({ type: Boolean })
|
|
119
126
|
], HelixHeadlessMapMarker.prototype, "passed", void 0);
|
|
120
127
|
__decorate([
|
|
128
|
+
words,
|
|
121
129
|
property({ attribute: 'passed-label' })
|
|
122
130
|
], HelixHeadlessMapMarker.prototype, "passedLabel", void 0);
|
|
123
131
|
HelixHeadlessMapMarker = __decorate([
|
|
@@ -71,6 +71,11 @@ export interface MapPointsCollection {
|
|
|
71
71
|
* @csspart places - The group of buttons, named by the layer's label.
|
|
72
72
|
*/
|
|
73
73
|
export declare class HelixHeadlessMapPoints extends HelixElement {
|
|
74
|
+
/**
|
|
75
|
+
* The key this part's words are registered under, its styled tag:
|
|
76
|
+
* `registerWords('de', { 'helix-map-points': { label: 'Orte' } })`.
|
|
77
|
+
*/
|
|
78
|
+
static words: string;
|
|
74
79
|
/** Combines nearby points into counts. Pressing a count zooms in to it. */
|
|
75
80
|
cluster: boolean;
|
|
76
81
|
/**
|
|
@@ -4,7 +4,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
4
4
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
|
-
import { customElement, HelixActivateEvent, HelixElement, HelixMapClusterEvent, HelixMapPartChangeEvent, isRtl, } from '@fusion.dev/helix-core';
|
|
7
|
+
import { customElement, formatWords, HelixActivateEvent, HelixElement, HelixMapClusterEvent, HelixMapPartChangeEvent, isRtl, words, } from '@fusion.dev/helix-core';
|
|
8
8
|
import { html, nothing } from 'lit';
|
|
9
9
|
import { property, state } from 'lit/decorators.js';
|
|
10
10
|
import { repeat } from 'lit/directives/repeat.js';
|
|
@@ -12,7 +12,7 @@ let HelixHeadlessMapPoints = class HelixHeadlessMapPoints extends HelixElement {
|
|
|
12
12
|
constructor() {
|
|
13
13
|
super(...arguments);
|
|
14
14
|
this.cluster = false;
|
|
15
|
-
this.countLabel = '{count} places';
|
|
15
|
+
this.countLabel = '{count, plural, one {# place} other {# places}}';
|
|
16
16
|
this.isMapLayer = true;
|
|
17
17
|
this.label = 'Places';
|
|
18
18
|
this.layerKind = 'points';
|
|
@@ -64,10 +64,10 @@ let HelixHeadlessMapPoints = class HelixHeadlessMapPoints extends HelixElement {
|
|
|
64
64
|
}
|
|
65
65
|
};
|
|
66
66
|
}
|
|
67
|
+
static { this.words = 'helix-map-points'; }
|
|
67
68
|
nameOf(one) {
|
|
68
69
|
if (one.count !== undefined) {
|
|
69
|
-
|
|
70
|
-
return this.countLabel.replace('{count}', new Intl.NumberFormat(lang).format(one.count));
|
|
70
|
+
return formatWords(this, 'countLabel', { count: one.count });
|
|
71
71
|
}
|
|
72
72
|
return one.label || one.value || '';
|
|
73
73
|
}
|
|
@@ -130,6 +130,7 @@ __decorate([
|
|
|
130
130
|
property({ type: Boolean })
|
|
131
131
|
], HelixHeadlessMapPoints.prototype, "cluster", void 0);
|
|
132
132
|
__decorate([
|
|
133
|
+
words,
|
|
133
134
|
property({ attribute: 'count-label' })
|
|
134
135
|
], HelixHeadlessMapPoints.prototype, "countLabel", void 0);
|
|
135
136
|
__decorate([
|
|
@@ -142,6 +143,7 @@ __decorate([
|
|
|
142
143
|
property()
|
|
143
144
|
], HelixHeadlessMapPoints.prototype, "group", void 0);
|
|
144
145
|
__decorate([
|
|
146
|
+
words,
|
|
145
147
|
property()
|
|
146
148
|
], HelixHeadlessMapPoints.prototype, "label", void 0);
|
|
147
149
|
__decorate([
|
|
@@ -32,6 +32,11 @@ import { type PropertyValues, type TemplateResult } from 'lit';
|
|
|
32
32
|
* @cssstate placed - Placed on the map by the connector.
|
|
33
33
|
*/
|
|
34
34
|
export declare class HelixHeadlessMapPosition extends HelixElement {
|
|
35
|
+
/**
|
|
36
|
+
* The key this part's words are registered under, its styled tag:
|
|
37
|
+
* `registerWords('de', { 'helix-map-position': { label: 'Aktueller Standort' } })`.
|
|
38
|
+
*/
|
|
39
|
+
static words: string;
|
|
35
40
|
/** How accurate the position is, in meters. Drawn as a ring with this radius. */
|
|
36
41
|
accuracy?: number;
|
|
37
42
|
/**
|
|
@@ -4,7 +4,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
4
4
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
|
-
import { customElement, HelixElement, HelixMapPartChangeEvent, PlacementController, } from '@fusion.dev/helix-core';
|
|
7
|
+
import { customElement, HelixElement, HelixMapPartChangeEvent, PlacementController, words, } from '@fusion.dev/helix-core';
|
|
8
8
|
import { html } from 'lit';
|
|
9
9
|
import { property, state } from 'lit/decorators.js';
|
|
10
10
|
let HelixHeadlessMapPosition = class HelixHeadlessMapPosition extends HelixElement {
|
|
@@ -17,6 +17,7 @@ let HelixHeadlessMapPosition = class HelixHeadlessMapPosition extends HelixEleme
|
|
|
17
17
|
this.spoken = '';
|
|
18
18
|
this.spokenAt = Number.NEGATIVE_INFINITY;
|
|
19
19
|
}
|
|
20
|
+
static { this.words = 'helix-map-position'; }
|
|
20
21
|
place(properties) {
|
|
21
22
|
this.placement.set(properties);
|
|
22
23
|
this.toggleState('placed', this.placement.get('--_map-position-x') !== undefined);
|
|
@@ -81,6 +82,7 @@ __decorate([
|
|
|
81
82
|
property({ reflect: true, type: Number })
|
|
82
83
|
], HelixHeadlessMapPosition.prototype, "heading", void 0);
|
|
83
84
|
__decorate([
|
|
85
|
+
words,
|
|
84
86
|
property()
|
|
85
87
|
], HelixHeadlessMapPosition.prototype, "label", void 0);
|
|
86
88
|
__decorate([
|
|
@@ -29,6 +29,11 @@ import { nothing, type PropertyValues } from 'lit';
|
|
|
29
29
|
* @event {HelixMapPartChangeEvent} helix-map-part-change - The tiles, the frame shown, the opacity, or where the tiles are drawn changed. Used by `connectMap`; pages do not need to listen for it.
|
|
30
30
|
*/
|
|
31
31
|
export declare class HelixHeadlessMapRaster extends HelixElement {
|
|
32
|
+
/**
|
|
33
|
+
* The key this part's words are registered under, its styled tag:
|
|
34
|
+
* `registerWords('de', { 'helix-map-raster': { label: 'Überlagerung' } })`.
|
|
35
|
+
*/
|
|
36
|
+
static words: string;
|
|
32
37
|
/** The tile provider's credit, shown in the frame's footer. Links in it stay links. */
|
|
33
38
|
attribution?: string;
|
|
34
39
|
/** More about the layer. Read after the label in the frame's list. */
|
|
@@ -4,7 +4,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
4
4
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
|
-
import { customElement, HelixElement, HelixMapPartChangeEvent } from '@fusion.dev/helix-core';
|
|
7
|
+
import { customElement, HelixElement, HelixMapPartChangeEvent, words } from '@fusion.dev/helix-core';
|
|
8
8
|
import { nothing } from 'lit';
|
|
9
9
|
import { property } from 'lit/decorators.js';
|
|
10
10
|
const framesConverter = {
|
|
@@ -22,6 +22,7 @@ let HelixHeadlessMapRaster = class HelixHeadlessMapRaster extends HelixElement {
|
|
|
22
22
|
this.opacity = 0.7;
|
|
23
23
|
this.playing = false;
|
|
24
24
|
}
|
|
25
|
+
static { this.words = 'helix-map-raster'; }
|
|
25
26
|
connectedCallback() {
|
|
26
27
|
super.connectedCallback();
|
|
27
28
|
if (this.hasUpdated) {
|
|
@@ -83,6 +84,7 @@ __decorate([
|
|
|
83
84
|
property({ type: Number })
|
|
84
85
|
], HelixHeadlessMapRaster.prototype, "interval", void 0);
|
|
85
86
|
__decorate([
|
|
87
|
+
words,
|
|
86
88
|
property()
|
|
87
89
|
], HelixHeadlessMapRaster.prototype, "label", void 0);
|
|
88
90
|
__decorate([
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { HelixElement, KeyboardNavigationController, type ViewportControlsPlacement, type
|
|
1
|
+
import { HelixElement, KeyboardNavigationController, type ViewportControlsPlacement, type ViewportPanDetail, type ViewportZoomDetail } from '@fusion.dev/helix-core';
|
|
2
2
|
import { nothing, type PropertyValues, type TemplateResult } from 'lit';
|
|
3
3
|
/**
|
|
4
4
|
* What `ViewportControlsPlacement` is called for a map.
|
|
@@ -142,6 +142,16 @@ declare const HelixHeadlessMap_base: (new (...args: any[]) => import("@fusion.de
|
|
|
142
142
|
* @cssstate using - A map with `gestures="activate"` has been pressed and has the gestures.
|
|
143
143
|
*/
|
|
144
144
|
export declare class HelixHeadlessMap extends HelixHeadlessMap_base {
|
|
145
|
+
/**
|
|
146
|
+
* The key this family's words are registered under, its styled tag:
|
|
147
|
+
* `registerWords('de', { 'helix-map': { layersLabel: 'Kartenebenen' } })`.
|
|
148
|
+
*/
|
|
149
|
+
static words: string;
|
|
150
|
+
/**
|
|
151
|
+
* The hint shown when the map, waiting to be pressed with
|
|
152
|
+
* `gestures="activate"`, is scrolled or swiped over.
|
|
153
|
+
*/
|
|
154
|
+
activateHintLabel: string;
|
|
145
155
|
/**
|
|
146
156
|
* The map's rotation, in degrees clockwise from north. `connectMap` keeps it
|
|
147
157
|
* current, and the Face north button's needle turns with it.
|
|
@@ -152,8 +162,15 @@ export declare class HelixHeadlessMap extends HelixHeadlessMap_base {
|
|
|
152
162
|
* the map zooms in, and pressing one zooms in to its places.
|
|
153
163
|
*/
|
|
154
164
|
cluster: boolean;
|
|
165
|
+
/**
|
|
166
|
+
* The name of the group of controls, read by screen readers, which names
|
|
167
|
+
* what the controls drive rather than the mechanism.
|
|
168
|
+
*/
|
|
169
|
+
controlsLabel: string;
|
|
155
170
|
/** The Face north button's label. */
|
|
156
171
|
faceNorthLabel: string;
|
|
172
|
+
/** The map's name where `label` is empty and the host has no `aria-label`. */
|
|
173
|
+
fallbackLabel: string;
|
|
157
174
|
/** What screen readers hear when the map is tilted back to looking straight down. */
|
|
158
175
|
flatLabel: string;
|
|
159
176
|
/** The Hybrid map type's name. */
|
|
@@ -207,18 +224,30 @@ export declare class HelixHeadlessMap extends HelixHeadlessMap_base {
|
|
|
207
224
|
standardLabel: string;
|
|
208
225
|
/**
|
|
209
226
|
* What screen readers hear when the map is tilted. `{degrees}` is the tilt
|
|
210
|
-
* from looking straight down
|
|
227
|
+
* from looking straight down, written in the locale, and each language
|
|
228
|
+
* writes the forms it has.
|
|
211
229
|
*/
|
|
212
230
|
tiltedLabel: string;
|
|
213
231
|
/** The 3D button's label. */
|
|
214
232
|
tiltLabel: string;
|
|
215
233
|
/**
|
|
216
234
|
* What screen readers hear when the map is turned. `{degrees}` is the way the
|
|
217
|
-
* top of the map faces, clockwise from north
|
|
235
|
+
* top of the map faces, clockwise from north, written in the locale, and
|
|
236
|
+
* each language writes the forms it has.
|
|
218
237
|
*/
|
|
219
238
|
turnedLabel: string;
|
|
239
|
+
/** The hint shown when one finger swipes over the map with `gestures="cooperative"`. */
|
|
240
|
+
twoFingerHintLabel: string;
|
|
241
|
+
/** The line shown while the map, with `gestures="activate"`, has the gestures. */
|
|
242
|
+
usingLabel: string;
|
|
220
243
|
/**
|
|
221
|
-
*
|
|
244
|
+
* The hint shown when the wheel scrolls past the map with
|
|
245
|
+
* `gestures="cooperative"`. `{key}` is ⌘ on a Mac and Ctrl elsewhere.
|
|
246
|
+
*/
|
|
247
|
+
wheelHintLabel: string;
|
|
248
|
+
/**
|
|
249
|
+
* What screen readers hear after a zoom. `{level}` is the zoom level,
|
|
250
|
+
* written in the locale.
|
|
222
251
|
*/
|
|
223
252
|
zoomedLabel: string;
|
|
224
253
|
/**
|
|
@@ -376,8 +405,6 @@ export declare class HelixHeadlessMap extends HelixHeadlessMap_base {
|
|
|
376
405
|
*/
|
|
377
406
|
private readonly handleMarkerKeydown;
|
|
378
407
|
private readonly handleMarkerKeyup;
|
|
379
|
-
/** What the map says about its gestures where the page does not say it. */
|
|
380
|
-
protected get restingGestureLabels(): ViewportGestureLabels;
|
|
381
408
|
/** Which gestures the renderer takes, which `connectMap` hears from here. */
|
|
382
409
|
protected gesturesChanged(): void;
|
|
383
410
|
/** A marker added or taken away is a walk of a different length. */
|
|
@@ -452,14 +479,6 @@ export declare class HelixHeadlessMap extends HelixHeadlessMap_base {
|
|
|
452
479
|
/** The events this family names, the surface naming none of its own. */
|
|
453
480
|
protected panEvent(detail: ViewportPanDetail): Event;
|
|
454
481
|
protected zoomEvent(detail: ViewportZoomDetail): Event;
|
|
455
|
-
/**
|
|
456
|
-
* What the group of controls is called.
|
|
457
|
-
*
|
|
458
|
-
* The surface is shared and this is the half that is a map: a reader meeting
|
|
459
|
-
* the group hears what it drives rather than "view controls", which names the
|
|
460
|
-
* mechanism.
|
|
461
|
-
*/
|
|
462
|
-
protected get restingControlsLabel(): string;
|
|
463
482
|
protected willUpdate(changed: PropertyValues): void;
|
|
464
483
|
/**
|
|
465
484
|
* The routes and areas, named, for a reader who cannot see the map.
|
|
@@ -4,7 +4,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
4
4
|
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
|
-
import { customElement,
|
|
7
|
+
import { customElement, focusItemOf, formatWords, HelixActivateEvent, HelixBeforeChangeEvent, HelixBeforeToggleEvent, HelixElement, HelixMapClusterEvent, HelixMapPanEvent, HelixMapPartChangeEvent, HelixMapReadyEvent, HelixMapRotateEvent, HelixMapTiltEvent, HelixMapZoomEvent, HelixToggleEvent, hostAria, KeyboardNavigationController, MixinViewport, requestChange, words, } from '@fusion.dev/helix-core';
|
|
8
8
|
import { buildings, cloudRain, dotsNine, leaf, mountains, path, polygon, stack, target, } from '@fusion.dev/helix-icons';
|
|
9
9
|
import { html, nothing } from 'lit';
|
|
10
10
|
import { property, state } from 'lit/decorators.js';
|
|
@@ -42,9 +42,12 @@ const SETTLES = 400;
|
|
|
42
42
|
let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement) {
|
|
43
43
|
constructor() {
|
|
44
44
|
super(...arguments);
|
|
45
|
+
this.activateHintLabel = 'Press the map to use it';
|
|
45
46
|
this.bearing = 0;
|
|
46
47
|
this.cluster = false;
|
|
48
|
+
this.controlsLabel = 'Map controls';
|
|
47
49
|
this.faceNorthLabel = 'Face north';
|
|
50
|
+
this.fallbackLabel = 'Map';
|
|
48
51
|
this.flatLabel = 'Looking straight down';
|
|
49
52
|
this.hybridLabel = 'Hybrid';
|
|
50
53
|
this.label = '';
|
|
@@ -61,9 +64,12 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
61
64
|
this.rotateRightLabel = 'Rotate right';
|
|
62
65
|
this.satelliteLabel = 'Satellite';
|
|
63
66
|
this.standardLabel = 'Standard';
|
|
64
|
-
this.tiltedLabel = 'Tilted {degrees}
|
|
67
|
+
this.tiltedLabel = '{degrees, plural, one {Tilted # degree} other {Tilted # degrees}}';
|
|
65
68
|
this.tiltLabel = 'Show in 3D';
|
|
66
|
-
this.turnedLabel = 'Facing {degrees}
|
|
69
|
+
this.turnedLabel = '{degrees, plural, one {Facing # degree} other {Facing # degrees}}';
|
|
70
|
+
this.twoFingerHintLabel = 'Use two fingers to move the map';
|
|
71
|
+
this.usingLabel = 'Using the map. Press Escape to scroll the page again.';
|
|
72
|
+
this.wheelHintLabel = 'Use {key} and scroll to zoom the map';
|
|
67
73
|
this.zoomedLabel = 'Zoom level {level}';
|
|
68
74
|
this.said = '';
|
|
69
75
|
this.asked = undefined;
|
|
@@ -150,6 +156,7 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
150
156
|
this.requestUpdate();
|
|
151
157
|
};
|
|
152
158
|
}
|
|
159
|
+
static { this.words = 'helix-map'; }
|
|
153
160
|
moved() {
|
|
154
161
|
if (!this.asked || performance.now() - this.asked.at > ASK_LAPSES) {
|
|
155
162
|
return;
|
|
@@ -176,8 +183,6 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
176
183
|
if (!asked) {
|
|
177
184
|
return;
|
|
178
185
|
}
|
|
179
|
-
const numbers = formatNumbers(this.closest('[lang]')?.getAttribute('lang') ?? '');
|
|
180
|
-
const degrees = (value) => numbers(Math.round(value));
|
|
181
186
|
const bearing = ((Math.round(this.bearing) % 360) + 360) % 360;
|
|
182
187
|
const words = {
|
|
183
188
|
down: this.movedDownLabel,
|
|
@@ -190,14 +195,14 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
190
195
|
: asked.kind === 'zoom'
|
|
191
196
|
? this.zoomLevel === undefined
|
|
192
197
|
? ''
|
|
193
|
-
:
|
|
198
|
+
: formatWords(this, 'zoomedLabel', { level: this.zoomLevel })
|
|
194
199
|
: asked.kind === 'tilt'
|
|
195
200
|
? Math.round(this.pitch) === 0
|
|
196
201
|
? this.flatLabel
|
|
197
|
-
:
|
|
202
|
+
: formatWords(this, 'tiltedLabel', { degrees: Math.round(this.pitch) })
|
|
198
203
|
: bearing === 0
|
|
199
204
|
? this.northLabel
|
|
200
|
-
:
|
|
205
|
+
: formatWords(this, 'turnedLabel', { degrees: bearing });
|
|
201
206
|
this.said = next !== '' && next === this.said ? `${next}\u00a0` : next;
|
|
202
207
|
}
|
|
203
208
|
ask(kind, side) {
|
|
@@ -305,14 +310,6 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
305
310
|
}
|
|
306
311
|
this.dispatchEvent(new HelixActivateEvent({ value: marker.name || marker.label || '' }));
|
|
307
312
|
}
|
|
308
|
-
get restingGestureLabels() {
|
|
309
|
-
return {
|
|
310
|
-
activate: 'Press the map to use it',
|
|
311
|
-
twoFinger: 'Use two fingers to move the map',
|
|
312
|
-
using: 'Using the map. Press Escape to scroll the page again.',
|
|
313
|
-
wheel: 'Use {key} and scroll to zoom the map',
|
|
314
|
-
};
|
|
315
|
-
}
|
|
316
313
|
gesturesChanged() {
|
|
317
314
|
this.dispatchEvent(new HelixMapPartChangeEvent({ kind: 'gestures' }));
|
|
318
315
|
}
|
|
@@ -464,6 +461,7 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
464
461
|
</div>`;
|
|
465
462
|
}
|
|
466
463
|
renderCompass(pan, rotate) {
|
|
464
|
+
const { faceNorthLabel } = this;
|
|
467
465
|
return html `<div part="compass">
|
|
468
466
|
${rotate
|
|
469
467
|
? html `<button part="rotate-left" aria-label=${this.rotateLeftLabel} type="button" @click=${() => this.rotate(-ROTATE_STEP)}>
|
|
@@ -485,7 +483,7 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
485
483
|
<slot name="pan-start-icon">${this.panGlyph('start')}</slot>
|
|
486
484
|
</button>`
|
|
487
485
|
: nothing}
|
|
488
|
-
<button part="face-north" aria-label=${
|
|
486
|
+
<button part="face-north" aria-label=${faceNorthLabel} type="button" style=${`--map-needle-turn: ${-this.bearing}deg`} @click=${() => this.faceNorth()}>
|
|
489
487
|
<slot name="face-north-icon">
|
|
490
488
|
<svg part="needle" aria-hidden="true" viewBox="0 0 16 16">
|
|
491
489
|
<path data-end="north" d="M8 1.5 10.5 8h-5Z" />
|
|
@@ -515,7 +513,7 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
515
513
|
if (!pan && !zoom && !rotate && !tilt && !fullscreen && menu === nothing) {
|
|
516
514
|
return nothing;
|
|
517
515
|
}
|
|
518
|
-
return html `<div part="controls" role="group" aria-label=${this.controlsLabel
|
|
516
|
+
return html `<div part="controls" role="group" aria-label=${this.controlsLabel}>
|
|
519
517
|
${fullscreen
|
|
520
518
|
? html `<button
|
|
521
519
|
part="fullscreen"
|
|
@@ -588,9 +586,6 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
588
586
|
this.ask('zoom');
|
|
589
587
|
return new HelixMapZoomEvent(detail);
|
|
590
588
|
}
|
|
591
|
-
get restingControlsLabel() {
|
|
592
|
-
return 'Map controls';
|
|
593
|
-
}
|
|
594
589
|
willUpdate(changed) {
|
|
595
590
|
super.willUpdate(changed);
|
|
596
591
|
hostAria(this.internals, { label: this.label });
|
|
@@ -613,7 +608,7 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
613
608
|
return html `<div
|
|
614
609
|
part="region"
|
|
615
610
|
role="group"
|
|
616
|
-
aria-label=${this.label || this.getAttribute('aria-label') ||
|
|
611
|
+
aria-label=${this.label || this.getAttribute('aria-label') || this.fallbackLabel}
|
|
617
612
|
aria-keyshortcuts=${this.keyShortcuts}
|
|
618
613
|
tabindex="0"
|
|
619
614
|
@focusin=${this.idle.stir}
|
|
@@ -640,6 +635,10 @@ let HelixHeadlessMap = class HelixHeadlessMap extends MixinViewport(HelixElement
|
|
|
640
635
|
</div>`;
|
|
641
636
|
}
|
|
642
637
|
};
|
|
638
|
+
__decorate([
|
|
639
|
+
words,
|
|
640
|
+
property({ attribute: 'activate-hint-label' })
|
|
641
|
+
], HelixHeadlessMap.prototype, "activateHintLabel", void 0);
|
|
643
642
|
__decorate([
|
|
644
643
|
property({ type: Number })
|
|
645
644
|
], HelixHeadlessMap.prototype, "bearing", void 0);
|
|
@@ -647,18 +646,30 @@ __decorate([
|
|
|
647
646
|
property({ type: Boolean })
|
|
648
647
|
], HelixHeadlessMap.prototype, "cluster", void 0);
|
|
649
648
|
__decorate([
|
|
649
|
+
words,
|
|
650
|
+
property({ attribute: 'controls-label' })
|
|
651
|
+
], HelixHeadlessMap.prototype, "controlsLabel", void 0);
|
|
652
|
+
__decorate([
|
|
653
|
+
words,
|
|
650
654
|
property({ attribute: 'face-north-label' })
|
|
651
655
|
], HelixHeadlessMap.prototype, "faceNorthLabel", void 0);
|
|
652
656
|
__decorate([
|
|
657
|
+
words,
|
|
658
|
+
property({ attribute: 'fallback-label' })
|
|
659
|
+
], HelixHeadlessMap.prototype, "fallbackLabel", void 0);
|
|
660
|
+
__decorate([
|
|
661
|
+
words,
|
|
653
662
|
property({ attribute: 'flat-label' })
|
|
654
663
|
], HelixHeadlessMap.prototype, "flatLabel", void 0);
|
|
655
664
|
__decorate([
|
|
665
|
+
words,
|
|
656
666
|
property({ attribute: 'hybrid-label' })
|
|
657
667
|
], HelixHeadlessMap.prototype, "hybridLabel", void 0);
|
|
658
668
|
__decorate([
|
|
659
669
|
property()
|
|
660
670
|
], HelixHeadlessMap.prototype, "label", void 0);
|
|
661
671
|
__decorate([
|
|
672
|
+
words,
|
|
662
673
|
property({ attribute: 'layers-label' })
|
|
663
674
|
], HelixHeadlessMap.prototype, "layersLabel", void 0);
|
|
664
675
|
__decorate([
|
|
@@ -668,48 +679,74 @@ __decorate([
|
|
|
668
679
|
property({ attribute: 'map-type', reflect: true })
|
|
669
680
|
], HelixHeadlessMap.prototype, "mapType", void 0);
|
|
670
681
|
__decorate([
|
|
682
|
+
words,
|
|
671
683
|
property({ attribute: 'map-type-label' })
|
|
672
684
|
], HelixHeadlessMap.prototype, "mapTypeLabel", void 0);
|
|
673
685
|
__decorate([
|
|
686
|
+
words,
|
|
674
687
|
property({ attribute: 'moved-down-label' })
|
|
675
688
|
], HelixHeadlessMap.prototype, "movedDownLabel", void 0);
|
|
676
689
|
__decorate([
|
|
690
|
+
words,
|
|
677
691
|
property({ attribute: 'moved-left-label' })
|
|
678
692
|
], HelixHeadlessMap.prototype, "movedLeftLabel", void 0);
|
|
679
693
|
__decorate([
|
|
694
|
+
words,
|
|
680
695
|
property({ attribute: 'moved-right-label' })
|
|
681
696
|
], HelixHeadlessMap.prototype, "movedRightLabel", void 0);
|
|
682
697
|
__decorate([
|
|
698
|
+
words,
|
|
683
699
|
property({ attribute: 'moved-up-label' })
|
|
684
700
|
], HelixHeadlessMap.prototype, "movedUpLabel", void 0);
|
|
685
701
|
__decorate([
|
|
702
|
+
words,
|
|
686
703
|
property({ attribute: 'north-label' })
|
|
687
704
|
], HelixHeadlessMap.prototype, "northLabel", void 0);
|
|
688
705
|
__decorate([
|
|
689
706
|
property({ type: Number })
|
|
690
707
|
], HelixHeadlessMap.prototype, "pitch", void 0);
|
|
691
708
|
__decorate([
|
|
709
|
+
words,
|
|
692
710
|
property({ attribute: 'rotate-left-label' })
|
|
693
711
|
], HelixHeadlessMap.prototype, "rotateLeftLabel", void 0);
|
|
694
712
|
__decorate([
|
|
713
|
+
words,
|
|
695
714
|
property({ attribute: 'rotate-right-label' })
|
|
696
715
|
], HelixHeadlessMap.prototype, "rotateRightLabel", void 0);
|
|
697
716
|
__decorate([
|
|
717
|
+
words,
|
|
698
718
|
property({ attribute: 'satellite-label' })
|
|
699
719
|
], HelixHeadlessMap.prototype, "satelliteLabel", void 0);
|
|
700
720
|
__decorate([
|
|
721
|
+
words,
|
|
701
722
|
property({ attribute: 'standard-label' })
|
|
702
723
|
], HelixHeadlessMap.prototype, "standardLabel", void 0);
|
|
703
724
|
__decorate([
|
|
725
|
+
words,
|
|
704
726
|
property({ attribute: 'tilted-label' })
|
|
705
727
|
], HelixHeadlessMap.prototype, "tiltedLabel", void 0);
|
|
706
728
|
__decorate([
|
|
729
|
+
words,
|
|
707
730
|
property({ attribute: 'tilt-label' })
|
|
708
731
|
], HelixHeadlessMap.prototype, "tiltLabel", void 0);
|
|
709
732
|
__decorate([
|
|
733
|
+
words,
|
|
710
734
|
property({ attribute: 'turned-label' })
|
|
711
735
|
], HelixHeadlessMap.prototype, "turnedLabel", void 0);
|
|
712
736
|
__decorate([
|
|
737
|
+
words,
|
|
738
|
+
property({ attribute: 'two-finger-hint-label' })
|
|
739
|
+
], HelixHeadlessMap.prototype, "twoFingerHintLabel", void 0);
|
|
740
|
+
__decorate([
|
|
741
|
+
words,
|
|
742
|
+
property({ attribute: 'using-label' })
|
|
743
|
+
], HelixHeadlessMap.prototype, "usingLabel", void 0);
|
|
744
|
+
__decorate([
|
|
745
|
+
words,
|
|
746
|
+
property({ attribute: 'wheel-hint-label' })
|
|
747
|
+
], HelixHeadlessMap.prototype, "wheelHintLabel", void 0);
|
|
748
|
+
__decorate([
|
|
749
|
+
words,
|
|
713
750
|
property({ attribute: 'zoomed-label' })
|
|
714
751
|
], HelixHeadlessMap.prototype, "zoomedLabel", void 0);
|
|
715
752
|
__decorate([
|
|
@@ -34,6 +34,11 @@ export declare const pointsConverter: {
|
|
|
34
34
|
* @event {HelixMapPartChangeEvent} helix-map-part-change - The route's points, progress, name, or color changed. Used by `connectMap`; pages do not need to listen for it.
|
|
35
35
|
*/
|
|
36
36
|
export declare class HelixHeadlessMapRoute extends HelixElement {
|
|
37
|
+
/**
|
|
38
|
+
* The key this part's words are registered under, its styled tag:
|
|
39
|
+
* `registerWords('de', { 'helix-map-route': { label: 'Route' } })`.
|
|
40
|
+
*/
|
|
41
|
+
static words: string;
|
|
37
42
|
/**
|
|
38
43
|
* More about the route, such as its distance or time. Read after its label
|
|
39
44
|
* in the frame's list.
|