@vonage/vivid 5.16.0 → 5.17.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/accordion/index.cjs +1 -1
- package/accordion/index.js +1 -1
- package/accordion-item/index.cjs +1 -1
- package/accordion-item/index.js +1 -1
- package/action-group/index.cjs +3 -3
- package/action-group/index.js +5 -5
- package/alert/index.cjs +3 -3
- package/alert/index.js +17 -17
- package/audio-player/index.cjs +16 -16
- package/audio-player/index.js +27 -27
- package/avatar/index.cjs +2 -2
- package/avatar/index.js +6 -6
- package/badge/index.cjs +2 -2
- package/badge/index.js +6 -6
- package/banner/index.cjs +3 -3
- package/banner/index.js +15 -15
- package/bundled/base-color-picker.cjs +2 -2
- package/bundled/base-color-picker.js +5 -5
- package/bundled/button.cjs +1 -1
- package/bundled/button.js +2 -2
- package/bundled/calendar-picker.template.cjs +2 -2
- package/bundled/calendar-picker.template.js +498 -498
- package/bundled/definition10.cjs +18 -30
- package/bundled/definition10.js +53 -155
- package/bundled/definition11.cjs +10 -19
- package/bundled/definition11.js +25 -74
- package/bundled/definition12.cjs +72 -18
- package/bundled/definition12.js +171 -107
- package/bundled/definition13.cjs +18 -17
- package/bundled/definition13.js +45 -65
- package/bundled/definition14.cjs +5 -10
- package/bundled/definition14.js +9 -27
- package/bundled/definition15.cjs +17 -71
- package/bundled/definition15.js +64 -181
- package/bundled/definition16.cjs +12 -4
- package/bundled/definition16.js +79 -14
- package/bundled/definition17.cjs +19 -13
- package/bundled/definition17.js +119 -70
- package/bundled/definition18.cjs +87 -12
- package/bundled/definition18.js +409 -52
- package/bundled/definition19.cjs +5 -87
- package/bundled/definition19.js +14 -422
- package/bundled/definition2.cjs +3 -3
- package/bundled/definition2.js +27 -27
- package/bundled/definition20.cjs +30 -5
- package/bundled/definition20.js +159 -9
- package/bundled/definition21.cjs +28 -19
- package/bundled/definition21.js +164 -47
- package/bundled/definition22.cjs +38 -23
- package/bundled/definition22.js +64 -82
- package/bundled/definition3.cjs +1 -1
- package/bundled/definition3.js +15 -15
- package/bundled/definition4.cjs +23 -38
- package/bundled/definition4.js +82 -64
- package/bundled/definition5.cjs +2 -2
- package/bundled/definition5.js +5 -5
- package/bundled/definition6.cjs +2 -2
- package/bundled/definition6.js +24 -24
- package/bundled/definition9.cjs +12 -30
- package/bundled/definition9.js +55 -148
- package/bundled/divider.cjs +1 -1
- package/bundled/divider.js +5 -5
- package/bundled/listbox.cjs +1 -1
- package/bundled/listbox.js +1 -1
- package/bundled/mixins.cjs +4 -4
- package/bundled/mixins.js +43 -43
- package/bundled/picker-field.template.cjs +7 -7
- package/bundled/picker-field.template.js +14 -14
- package/bundled/slider.template.cjs +7 -7
- package/bundled/slider.template.js +12 -12
- package/bundled/slottable-request.cjs +1 -1
- package/bundled/slottable-request.js +8 -38
- package/bundled/time-selection-picker.template.cjs +4 -4
- package/bundled/time-selection-picker.template.js +35 -35
- package/bundled/vivid-element.cjs +1 -1
- package/bundled/vivid-element.js +1 -1
- package/calendar/index.cjs +11 -11
- package/calendar/index.js +30 -237
- package/calendar-event/index.cjs +3 -3
- package/calendar-event/index.js +4 -4
- package/card/index.cjs +14 -11
- package/card/index.js +16 -13
- package/checkbox/index.cjs +1 -1
- package/checkbox/index.js +1 -1
- package/color-picker/definition.cjs +1 -1
- package/color-picker/definition.js +1 -1
- package/color-picker/index.cjs +6 -6
- package/color-picker/index.js +24 -24
- package/combobox/definition.cjs +1 -1
- package/combobox/definition.js +1 -1
- package/combobox/index.cjs +9 -8
- package/combobox/index.js +32 -28
- package/contextual-help/definition.cjs +1 -1
- package/contextual-help/definition.js +1 -1
- package/contextual-help/index.cjs +1 -1
- package/contextual-help/index.js +1 -1
- package/custom-elements.json +1027 -615
- package/data-grid/definition.js +1 -1
- package/data-grid/index.cjs +17 -17
- package/data-grid/index.js +261 -264
- package/date-picker/index.cjs +1 -1
- package/date-picker/index.js +12 -12
- package/date-range-picker/index.cjs +1 -1
- package/date-range-picker/index.js +7 -7
- package/date-time-picker/index.cjs +4 -4
- package/date-time-picker/index.js +24 -24
- package/dial-pad/index.cjs +3 -2
- package/dial-pad/index.js +6 -5
- package/dialog/index.cjs +4 -4
- package/dialog/index.js +5 -5
- package/divider/index.cjs +1 -1
- package/divider/index.js +1 -1
- package/fab/index.cjs +3 -3
- package/fab/index.js +8 -8
- package/file-picker/index.cjs +16 -13
- package/file-picker/index.js +31 -28
- package/header/index.cjs +4 -4
- package/header/index.js +5 -5
- package/index.cjs +24 -21
- package/index.js +11 -11
- package/lib/combobox/combobox.d.ts +0 -3
- package/lib/date-time-picker/date-time-picker.d.ts +0 -4
- package/lib/dial-pad/dial-pad.d.ts +6 -2
- package/lib/dialog/dialog.d.ts +0 -1
- package/lib/menu/menu.d.ts +0 -1
- package/lib/option/option.d.ts +0 -1
- package/lib/rich-text-editor/rte/exports.d.ts +1 -0
- package/lib/rich-text-editor/rte/features/alignment.d.ts +1 -1
- package/lib/rich-text-editor/rte/features/character-count.d.ts +21 -0
- package/lib/rich-text-editor/rte/features/font-size-picker.d.ts +1 -1
- package/lib/rich-text-editor/rte/features/internal/basic-text-blocks.d.ts +1 -1
- package/lib/rich-text-editor/rte/features/keyboard-shortcuts.d.ts +1 -1
- package/lib/rich-text-editor/rte/features/text-color-picker.d.ts +1 -1
- package/lib/rich-text-editor/rte/public-interface.d.ts +6 -0
- package/lib/searchable-select/option-tag.d.ts +0 -1
- package/lib/table/definition.d.ts +2 -1
- package/lib/table/table-header-cell.d.ts +3 -0
- package/lib/table/table-sorting-button.d.ts +415 -0
- package/lib/table/table-sorting-button.template.d.ts +3 -0
- package/locales/de-DE.cjs +4 -178
- package/locales/de-DE.js +2 -179
- package/locales/en-GB.cjs +4 -9
- package/locales/en-GB.js +2 -10
- package/locales/en-US.cjs +268 -2
- package/locales/en-US.js +265 -1
- package/locales/ja-JP.cjs +4 -171
- package/locales/ja-JP.js +2 -172
- package/locales/zh-CN.cjs +4 -172
- package/locales/zh-CN.js +2 -173
- package/menu/index.cjs +1 -1
- package/menu/index.js +1 -1
- package/menu-item/index.cjs +1 -1
- package/menu-item/index.js +1 -1
- package/nav-disclosure/index.cjs +3 -3
- package/nav-disclosure/index.js +8 -8
- package/nav-item/index.cjs +1 -1
- package/nav-item/index.js +7 -7
- package/note/index.cjs +2 -2
- package/note/index.js +6 -6
- package/number-field/index.cjs +4 -4
- package/number-field/index.js +31 -31
- package/option/definition.cjs +1 -1
- package/option/definition.js +1 -1
- package/option/index.cjs +1 -1
- package/option/index.js +1 -1
- package/package.json +7 -8
- package/pagination/index.cjs +3 -3
- package/pagination/index.js +15 -15
- package/popover/index.cjs +4 -4
- package/popover/index.js +5 -5
- package/progress/index.cjs +2 -2
- package/progress/index.js +5 -5
- package/radio/index.cjs +1 -1
- package/radio/index.js +1 -1
- package/radio-group/index.cjs +4 -4
- package/radio-group/index.js +10 -10
- package/range-slider/index.cjs +4 -4
- package/range-slider/index.js +17 -17
- package/rich-text-editor/definition.cjs +1 -0
- package/rich-text-editor/definition.js +2 -2
- package/rich-text-editor/index.cjs +13 -13
- package/rich-text-editor/index.js +1886 -1829
- package/rich-text-view/index.cjs +1 -1
- package/rich-text-view/index.js +8 -8
- package/searchable-select/index.cjs +12 -12
- package/searchable-select/index.js +25 -25
- package/select/index.cjs +1 -1
- package/select/index.js +1 -1
- package/selectable-box/index.cjs +7 -7
- package/selectable-box/index.js +11 -11
- package/shared/foundation/test-utilities/fixture.d.ts +1 -1
- package/shared/patterns/linkable.d.ts +1 -1
- package/simple-color-picker/index.cjs +3 -3
- package/simple-color-picker/index.js +10 -10
- package/split-button/index.cjs +5 -5
- package/split-button/index.js +10 -10
- package/status/index.cjs +2 -2
- package/status/index.js +12 -12
- package/switch/index.cjs +3 -3
- package/switch/index.js +5 -5
- package/tab/index.cjs +1 -1
- package/tab/index.js +1 -1
- package/tab-panel/index.cjs +1 -1
- package/tab-panel/index.js +1 -1
- package/table/definition.cjs +17 -14
- package/table/definition.js +3 -2
- package/table/index.cjs +19 -10
- package/table/index.js +69 -21
- package/tabs/index.cjs +2 -2
- package/tabs/index.js +4 -4
- package/tag/index.cjs +7 -7
- package/tag/index.js +9 -9
- package/tag-group/index.cjs +3 -3
- package/tag-group/index.js +5 -5
- package/text-area/index.cjs +2 -2
- package/text-area/index.js +12 -12
- package/text-field/definition.cjs +1 -1
- package/text-field/definition.js +1 -1
- package/text-field/index.cjs +1 -1
- package/text-field/index.js +1 -1
- package/time-picker/index.cjs +1 -1
- package/time-picker/index.js +1 -1
- package/toggletip/definition.cjs +1 -1
- package/toggletip/definition.js +1 -1
- package/toggletip/index.cjs +1 -1
- package/toggletip/index.js +1 -1
- package/tooltip/definition.cjs +1 -1
- package/tooltip/definition.js +1 -1
- package/tooltip/index.cjs +1 -1
- package/tooltip/index.js +1 -1
- package/tree-item/index.cjs +1 -1
- package/tree-item/index.js +1 -1
- package/tree-view/index.cjs +3 -3
- package/tree-view/index.js +17 -17
- package/unbundled/button.cjs +2 -2
- package/unbundled/button.js +2 -2
- package/unbundled/calendar-picker.template.cjs +4347 -9
- package/unbundled/calendar-picker.template.js +4345 -7
- package/unbundled/chunk.cjs +0 -22
- package/unbundled/definition13.cjs +1 -8
- package/unbundled/definition13.js +1 -8
- package/unbundled/definition14.cjs +2 -2
- package/unbundled/definition14.js +2 -2
- package/unbundled/definition2.cjs +1 -1
- package/unbundled/definition2.js +1 -1
- package/unbundled/definition21.cjs +1 -2
- package/unbundled/definition21.js +1 -2
- package/unbundled/definition22.cjs +7 -2
- package/unbundled/definition22.js +7 -2
- package/unbundled/definition24.cjs +98 -979
- package/unbundled/definition24.js +93 -974
- package/unbundled/definition25.cjs +37 -322
- package/unbundled/definition25.js +33 -318
- package/unbundled/definition26.cjs +317 -91
- package/unbundled/definition26.js +313 -87
- package/unbundled/definition27.cjs +94 -192
- package/unbundled/definition27.js +91 -183
- package/unbundled/definition28.cjs +387 -395
- package/unbundled/definition28.js +387 -395
- package/unbundled/definition29.cjs +189 -110
- package/unbundled/definition29.js +180 -107
- package/unbundled/definition30.cjs +520 -36
- package/unbundled/definition30.js +519 -35
- package/unbundled/definition32.cjs +477 -477
- package/unbundled/definition32.js +475 -475
- package/unbundled/definition33.cjs +87 -2
- package/unbundled/definition33.js +77 -4
- package/unbundled/definition35.cjs +2 -2
- package/unbundled/definition35.js +2 -2
- package/unbundled/definition36.cjs +1 -1
- package/unbundled/definition36.js +1 -1
- package/unbundled/definition37.cjs +6 -2
- package/unbundled/definition37.js +6 -2
- package/unbundled/definition38.cjs +7 -5
- package/unbundled/definition38.js +7 -5
- package/unbundled/definition39.cjs +1 -0
- package/unbundled/definition39.js +1 -0
- package/unbundled/definition42.cjs +22 -11
- package/unbundled/definition42.js +22 -11
- package/unbundled/definition49.cjs +3 -3
- package/unbundled/definition49.js +3 -3
- package/unbundled/definition56.cjs +437 -9506
- package/unbundled/definition56.js +340 -9415
- package/unbundled/definition57.cjs +5 -5
- package/unbundled/definition57.js +5 -5
- package/unbundled/definition58.cjs +4 -3
- package/unbundled/definition58.js +2 -1
- package/unbundled/definition59.cjs +4 -3
- package/unbundled/definition59.js +4 -3
- package/unbundled/definition62.cjs +2 -2
- package/unbundled/definition62.js +2 -2
- package/unbundled/definition64.cjs +1 -1
- package/unbundled/definition64.js +1 -1
- package/unbundled/definition71.cjs +2 -2
- package/unbundled/definition71.js +2 -2
- package/unbundled/definition72.cjs +1 -2
- package/unbundled/definition72.js +1 -2
- package/unbundled/definition75.cjs +3 -51711
- package/unbundled/definition75.js +1 -51711
- package/unbundled/listbox.cjs +1 -1
- package/unbundled/listbox.js +1 -1
- package/unbundled/localized.cjs +2 -2
- package/unbundled/localized.js +1 -1
- package/unbundled/picker-field.template.cjs +1 -1
- package/unbundled/picker-field.template.js +1 -1
- package/unbundled/slottable-request.cjs +2 -3168
- package/unbundled/slottable-request.js +3 -3097
- package/unbundled/time-selection-picker.template.cjs +1 -1
- package/unbundled/time-selection-picker.template.js +1 -1
- package/unbundled/vivid-element.cjs +1 -1
- package/unbundled/vivid-element.js +1 -1
- package/video-player/index.cjs +3 -3
- package/video-player/index.js +9 -9
- package/vivid.api.json +220 -282
- package/unbundled/chunk.js +0 -33
- package/unbundled/en-US.cjs +0 -447
- package/unbundled/en-US.js +0 -443
|
@@ -1,211 +1,119 @@
|
|
|
1
1
|
import { o as defineVividComponent, s as createRegisterFunction, t as VividElement } from "./vivid-element.js";
|
|
2
|
-
import { r as Icon, t as iconDefinition } from "./definition2.js";
|
|
3
2
|
import { t as __decorate } from "./decorate.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
* @public
|
|
14
|
-
*/
|
|
15
|
-
function isListboxOption(el) {
|
|
16
|
-
return isHTMLElement(el) && (el.getAttribute("role") === "option" || el instanceof HTMLOptionElement || el instanceof ListboxOption);
|
|
17
|
-
}
|
|
3
|
+
import { t as handleEscapeKeyAndStopPropogation } from "./dialog.js";
|
|
4
|
+
import { i as Popup, t as popupDefinition } from "./definition10.js";
|
|
5
|
+
import { n as anchorSlotTemplateFactory, t as Anchored } from "./anchored.js";
|
|
6
|
+
import { attr, html } from "@microsoft/fast-element";
|
|
7
|
+
import { classNames } from "@microsoft/fast-web-utilities";
|
|
8
|
+
//#region src/lib/tooltip/tooltip.scss?inline
|
|
9
|
+
var tooltip_default = ":host :host{display:var(--_popup-display,inline)}:host :host([slotted-anchor]){--_popup-display:contents}.control{pointer-events:none}.tooltip{width:var(--tooltip-inline-size,auto);box-sizing:border-box;color:var(--vvd-color-canvas-text);font:var(--vvd-typography-base-bold);max-inline-size:var(--tooltip-max-inline-size,30ch);padding:8px 12px}";
|
|
10
|
+
//#endregion
|
|
11
|
+
//#region src/lib/tooltip/tooltip.ts
|
|
18
12
|
/**
|
|
19
|
-
* An Option Custom HTML Element.
|
|
20
|
-
* Implements {@link https://www.w3.org/TR/wai-aria-1.1/#option | ARIA option }.
|
|
21
|
-
*
|
|
22
13
|
* @public
|
|
23
|
-
* @component
|
|
24
|
-
* @slot
|
|
25
|
-
* @
|
|
26
|
-
* @
|
|
27
|
-
* @
|
|
14
|
+
* @component tooltip
|
|
15
|
+
* @slot anchor - Used to set the anchor element for the tooltip.
|
|
16
|
+
* @testSelector byText byText
|
|
17
|
+
* @testQuery open open true
|
|
18
|
+
* @testQuery closed open false
|
|
28
19
|
*/
|
|
29
|
-
var
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
if (this.proxy instanceof HTMLOptionElement) this.proxy.selected = this.defaultSelected;
|
|
34
|
-
}
|
|
35
|
-
if (this.proxy instanceof HTMLOptionElement) this.proxy.defaultSelected = this.defaultSelected;
|
|
36
|
-
}
|
|
37
|
-
disabledChanged() {
|
|
38
|
-
/* v8 ignore if -- @preserve */
|
|
39
|
-
if (this.proxy instanceof HTMLOptionElement) this.proxy.disabled = this.disabled;
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* @deprecated Use `defaultSelected` instead.
|
|
43
|
-
*/
|
|
44
|
-
get selectedAttribute() {
|
|
45
|
-
return this.defaultSelected;
|
|
46
|
-
}
|
|
47
|
-
set selectedAttribute(value) {
|
|
48
|
-
this.defaultSelected = value;
|
|
49
|
-
}
|
|
50
|
-
selectedChanged() {
|
|
51
|
-
if (!this.dirtySelected) this.dirtySelected = true;
|
|
52
|
-
if (this.proxy instanceof HTMLOptionElement) this.proxy.selected = this.selected;
|
|
53
|
-
}
|
|
54
|
-
valueChanged() {
|
|
55
|
-
if (typeof this.value !== "string") {
|
|
56
|
-
this.value = "";
|
|
57
|
-
return;
|
|
58
|
-
}
|
|
59
|
-
if (this.proxy instanceof HTMLOptionElement) this.proxy.value = this.value;
|
|
60
|
-
}
|
|
61
|
-
get label() {
|
|
62
|
-
return this._label ?? this.text;
|
|
20
|
+
var Tooltip = class extends Anchored(VividElement) {
|
|
21
|
+
constructor(..._args) {
|
|
22
|
+
super(..._args);
|
|
23
|
+
this.open = false;
|
|
63
24
|
}
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
set text(value) {
|
|
68
|
-
this._text = value;
|
|
69
|
-
}
|
|
70
|
-
get text() {
|
|
71
|
-
return this._text ?? "";
|
|
72
|
-
}
|
|
73
|
-
/**
|
|
74
|
-
* Provides an accessible name for use by parent components.
|
|
75
|
-
* Note: Does not implement full accessible name computation, e.g. slotted content is missed.
|
|
76
|
-
* @internal
|
|
77
|
-
*/
|
|
78
|
-
_getAccessibleName() {
|
|
79
|
-
return this.ariaLabel || `${this.text}${this.textSecondary ? ` ${this.textSecondary}` : ""}`;
|
|
80
|
-
}
|
|
81
|
-
get form() {
|
|
82
|
-
return null;
|
|
25
|
+
connectedCallback() {
|
|
26
|
+
super.connectedCallback();
|
|
27
|
+
this.#updateListeners();
|
|
83
28
|
}
|
|
84
|
-
|
|
85
|
-
|
|
29
|
+
disconnectedCallback() {
|
|
30
|
+
super.disconnectedCallback();
|
|
31
|
+
this.#updateListeners();
|
|
86
32
|
}
|
|
87
33
|
/**
|
|
88
|
-
* From is inclusive, to is exclusive.
|
|
89
34
|
* @internal
|
|
90
35
|
*/
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
if (
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
this.
|
|
113
|
-
this
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
this.
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
if (
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
36
|
+
_anchorElChanged(oldValue, newValue) {
|
|
37
|
+
if (oldValue) this.#cleanupAnchor(oldValue);
|
|
38
|
+
if (newValue) this.#setupAnchor(newValue);
|
|
39
|
+
}
|
|
40
|
+
#setupAnchor(a) {
|
|
41
|
+
a.addEventListener("mouseover", this.#show);
|
|
42
|
+
a.addEventListener("mouseout", this.#hide);
|
|
43
|
+
a.addEventListener("focusin", this.#show);
|
|
44
|
+
a.addEventListener("focusout", this.#hide);
|
|
45
|
+
a.setAttribute("aria-haspopup", "true");
|
|
46
|
+
a.setAttribute("aria-expanded", String(this.open));
|
|
47
|
+
}
|
|
48
|
+
#cleanupAnchor(a) {
|
|
49
|
+
a.removeEventListener("mouseover", this.#show);
|
|
50
|
+
a.removeEventListener("mouseout", this.#hide);
|
|
51
|
+
a.removeEventListener("focusin", this.#show);
|
|
52
|
+
a.removeEventListener("focusout", this.#hide);
|
|
53
|
+
a.removeAttribute("aria-haspopup");
|
|
54
|
+
a.removeAttribute("aria-expanded");
|
|
55
|
+
}
|
|
56
|
+
#show = () => {
|
|
57
|
+
this.open = true;
|
|
58
|
+
this.#updateAnchorExpanded();
|
|
59
|
+
};
|
|
60
|
+
#hide = () => {
|
|
61
|
+
this.open = false;
|
|
62
|
+
this.#updateAnchorExpanded();
|
|
63
|
+
};
|
|
64
|
+
#updateAnchorExpanded() {
|
|
65
|
+
if (this._anchorEl) this._anchorEl.setAttribute("aria-expanded", String(this.open));
|
|
66
|
+
}
|
|
67
|
+
#updateListeners() {
|
|
68
|
+
document.removeEventListener("keydown", this.#closeOnEscape);
|
|
69
|
+
if (this.open && this.isConnected) document.addEventListener("keydown", this.#closeOnEscape);
|
|
70
|
+
}
|
|
71
|
+
#closeOnEscape = (e) => {
|
|
72
|
+
/* v8 ignore else -- @preserve */
|
|
73
|
+
if (e.key === "Escape") this.#hide();
|
|
74
|
+
};
|
|
124
75
|
/**
|
|
125
76
|
* @internal
|
|
126
77
|
*/
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
this.selected = this.defaultSelected;
|
|
131
|
-
this.dirtySelected = false;
|
|
132
|
-
}
|
|
78
|
+
openChanged(oldValue) {
|
|
79
|
+
if (oldValue === void 0) return;
|
|
80
|
+
this.#updateListeners();
|
|
133
81
|
}
|
|
134
82
|
};
|
|
135
|
-
__decorate([attr
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
if (value === false || value === "false") return false;
|
|
139
|
-
},
|
|
140
|
-
toView: (value) => value
|
|
141
|
-
} })], ListboxOption.prototype, "checked", void 0);
|
|
142
|
-
__decorate([attr({
|
|
143
|
-
attribute: "selected",
|
|
144
|
-
mode: "boolean"
|
|
145
|
-
})], ListboxOption.prototype, "defaultSelected", void 0);
|
|
146
|
-
__decorate([attr({ mode: "boolean" })], ListboxOption.prototype, "disabled", void 0);
|
|
147
|
-
__decorate([attr({
|
|
148
|
-
attribute: "current-selected",
|
|
149
|
-
mode: "boolean"
|
|
150
|
-
})], ListboxOption.prototype, "selected", void 0);
|
|
151
|
-
__decorate([attr({ attribute: "value" })], ListboxOption.prototype, "value", void 0);
|
|
152
|
-
__decorate([attr({ attribute: "label" })], ListboxOption.prototype, "_label", void 0);
|
|
153
|
-
__decorate([attr({ attribute: "text" })], ListboxOption.prototype, "_text", void 0);
|
|
154
|
-
__decorate([attr({ attribute: "text-secondary" })], ListboxOption.prototype, "textSecondary", void 0);
|
|
155
|
-
__decorate([observable], ListboxOption.prototype, "_highlighted", void 0);
|
|
156
|
-
__decorate([observable], ListboxOption.prototype, "_displayCheckmark", void 0);
|
|
157
|
-
__decorate([attr({ attribute: "matched-text" })], ListboxOption.prototype, "matchedText", void 0);
|
|
158
|
-
__decorate([observable], ListboxOption.prototype, "_vvdSearchText", void 0);
|
|
159
|
-
__decorate([volatile], ListboxOption.prototype, "_hasMatchedText", null);
|
|
160
|
-
__decorate([observable], ListboxOption.prototype, "_isNotMatching", void 0);
|
|
161
|
-
__decorate([volatile], ListboxOption.prototype, "_matchedRange", null);
|
|
162
|
-
__decorate([attr], ListboxOption.prototype, "connotation", void 0);
|
|
163
|
-
__decorate([attr({ attribute: "tag-connotation" })], ListboxOption.prototype, "tagConnotation", void 0);
|
|
83
|
+
__decorate([attr], Tooltip.prototype, "text", void 0);
|
|
84
|
+
__decorate([attr({ mode: "fromView" })], Tooltip.prototype, "placement", void 0);
|
|
85
|
+
__decorate([attr({ mode: "boolean" })], Tooltip.prototype, "open", void 0);
|
|
164
86
|
//#endregion
|
|
165
|
-
//#region src/lib/
|
|
166
|
-
var getClasses = (
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
${when((x) => x.text, html`<span class="text-primary">
|
|
170
|
-
${when((x) => x._hasMatchedText, html`${(x) => x.text.slice(0, x._matchedRange.from)}<span class="match"
|
|
171
|
-
>${(x) => x.text.slice(x._matchedRange.from, x._matchedRange.to)}</span
|
|
172
|
-
>`)}${(x) => x.text.slice(x._matchedRange.to)}
|
|
173
|
-
</span>`)}
|
|
174
|
-
${when((x) => x.textSecondary, html`<span class="text-secondary">${(x) => x.textSecondary}</span>`)}
|
|
175
|
-
</span>`)}`;
|
|
176
|
-
}
|
|
177
|
-
var ListboxOptionTemplate = (context) => {
|
|
178
|
-
const affixIconTemplate = affixIconTemplateFactory(context);
|
|
179
|
-
const iconTag = context.tagFor(Icon);
|
|
87
|
+
//#region src/lib/tooltip/tooltip.template.ts
|
|
88
|
+
var getClasses = ({ open }) => classNames("control", ["open", Boolean(open)]);
|
|
89
|
+
var TooltipTemplate = (context) => {
|
|
90
|
+
const popupTag = context.tagFor(Popup);
|
|
180
91
|
return html`
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
</div>
|
|
195
|
-
</template>
|
|
196
|
-
`;
|
|
92
|
+
${anchorSlotTemplateFactory()}
|
|
93
|
+
<${popupTag} class="${getClasses}" arrow alternate
|
|
94
|
+
:placement=${(x) => x.placement}
|
|
95
|
+
:anchor="${(x) => x._anchorEl}"
|
|
96
|
+
:open="${(x) => x.open}"
|
|
97
|
+
@keydown="${(x, c) => {
|
|
98
|
+
if (x.open && handleEscapeKeyAndStopPropogation(c.event)) x.open = false;
|
|
99
|
+
}}"
|
|
100
|
+
exportparts="vvd-theme-alternate">
|
|
101
|
+
<div part="vvd-theme-alternate" class="tooltip" role="tooltip">
|
|
102
|
+
${(x) => x.text}
|
|
103
|
+
</div>
|
|
104
|
+
</${popupTag}>`;
|
|
197
105
|
};
|
|
198
106
|
//#endregion
|
|
199
|
-
//#region src/lib/
|
|
107
|
+
//#region src/lib/tooltip/definition.ts
|
|
200
108
|
/**
|
|
201
109
|
* @internal
|
|
202
110
|
*/
|
|
203
|
-
var
|
|
111
|
+
var tooltipDefinition = defineVividComponent("tooltip", Tooltip, TooltipTemplate, [popupDefinition], { styles: tooltip_default });
|
|
204
112
|
/**
|
|
205
|
-
* Registers the
|
|
113
|
+
* Registers the tooltip elements with the design system.
|
|
206
114
|
*
|
|
207
115
|
* @param prefix - the prefix to use for the component name
|
|
208
116
|
*/
|
|
209
|
-
var
|
|
117
|
+
var registerTooltip = createRegisterFunction(tooltipDefinition);
|
|
210
118
|
//#endregion
|
|
211
|
-
export {
|
|
119
|
+
export { tooltipDefinition as n, Tooltip as r, registerTooltip as t };
|