@vonage/vivid 4.24.0 → 4.25.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 +12314 -4711
- package/elevation/index.cjs +1 -1
- package/elevation/index.js +1 -1
- package/index.cjs +112 -150
- package/index.js +37 -35
- package/lib/accordion-item/accordion-item.d.ts +6 -0
- package/lib/action-group/action-group.d.ts +6 -0
- package/lib/alert/alert.d.ts +20 -0
- package/lib/audio-player/audio-player.d.ts +6 -0
- package/lib/badge/badge.d.ts +9 -1
- package/lib/banner/banner.d.ts +25 -0
- package/lib/breadcrumb/breadcrumb.d.ts +6 -0
- package/lib/breadcrumb-item/breadcrumb-item.d.ts +63 -7
- package/lib/button/button.d.ts +732 -7
- package/lib/button/locale.d.ts +3 -0
- package/lib/calendar-event/calendar-event.d.ts +6 -0
- package/lib/card/card.d.ts +394 -2
- package/lib/card/card.template.d.ts +2 -1
- package/lib/checkbox/checkbox.d.ts +1822 -5
- package/lib/combobox/combobox.d.ts +1827 -20
- package/lib/data-grid/data-grid-cell.d.ts +339 -1
- package/lib/data-grid/locale.d.ts +5 -0
- package/lib/date-picker/date-picker.d.ts +1676 -207
- package/lib/date-range-picker/date-range-picker.d.ts +840 -107
- package/lib/date-time-picker/date-time-picker.d.ts +1678 -209
- package/lib/dial-pad/dial-pad.d.ts +8 -0
- package/lib/dialog/dialog.d.ts +12 -0
- package/lib/divider/divider.d.ts +6 -0
- package/lib/fab/fab.d.ts +6 -0
- package/lib/file-picker/file-picker.d.ts +1508 -30
- package/lib/header/header.d.ts +6 -0
- package/lib/icon/icon.d.ts +1 -0
- package/lib/icon/icon.template.d.ts +2 -1
- package/lib/menu/menu.d.ts +16 -7
- package/lib/menu/name.d.ts +1 -0
- package/lib/menu-item/menu-item.d.ts +14 -2
- package/lib/nav/nav.d.ts +6 -0
- package/lib/nav-disclosure/nav-disclosure.d.ts +13 -0
- package/lib/nav-item/nav-item.d.ts +405 -3
- package/lib/note/note.d.ts +6 -0
- package/lib/number-field/number-field.d.ts +1857 -36
- package/lib/option/option.d.ts +12 -0
- package/lib/progress/progress.d.ts +6 -0
- package/lib/progress-ring/progress-ring.d.ts +6 -0
- package/lib/radio/radio.d.ts +1137 -4
- package/lib/radio-group/radio-group.d.ts +20 -2
- package/lib/range-slider/range-slider.d.ts +752 -5
- package/lib/rich-text-editor/definition.d.ts +2 -2
- package/lib/rich-text-editor/facades/vivid-prose-mirror.facade.d.ts +3 -1
- package/lib/rich-text-editor/locale.d.ts +1 -0
- package/lib/rich-text-editor/menubar/menubar.d.ts +6 -0
- package/lib/rich-text-editor/rich-text-editor.d.ts +352 -2
- package/lib/searchable-select/option-tag.d.ts +6 -0
- package/lib/searchable-select/searchable-select.d.ts +1857 -36
- package/lib/select/select.d.ts +1843 -28
- package/lib/selectable-box/selectable-box.d.ts +6 -0
- package/lib/slider/slider.d.ts +384 -2
- package/lib/split-button/split-button.d.ts +18 -0
- package/lib/switch/switch.d.ts +386 -3
- package/lib/tab/tab.d.ts +18 -1
- package/lib/tab-panel/tab-panel.d.ts +6 -0
- package/lib/tag/tag.d.ts +12 -0
- package/lib/tag-group/tag-group.d.ts +6 -0
- package/lib/text-area/text-area.d.ts +2174 -19
- package/lib/text-field/text-field.d.ts +2195 -31
- package/lib/time-picker/time-picker.d.ts +839 -106
- package/lib/toggletip/toggletip.d.ts +10 -4
- package/lib/tooltip/tooltip.d.ts +10 -4
- package/lib/tree-item/tree-item.d.ts +12 -0
- package/lib/tree-view/tree-view.d.ts +6 -0
- package/lib/video-player/video-player.d.ts +6 -0
- package/lib/visually-hidden/definition.d.ts +4 -0
- package/lib/visually-hidden/visually-hidden.d.ts +3 -0
- package/lib/visually-hidden/visually-hidden.template.d.ts +3 -0
- package/locales/de-DE.cjs +33 -1
- package/locales/de-DE.js +33 -1
- package/locales/en-GB.cjs +33 -1
- package/locales/en-GB.js +33 -1
- package/locales/en-US.cjs +33 -1
- package/locales/en-US.js +33 -1
- package/locales/ja-JP.cjs +33 -1
- package/locales/ja-JP.js +33 -1
- package/locales/zh-CN.cjs +33 -1
- package/locales/zh-CN.js +33 -1
- package/menu/index.cjs +1 -1
- package/menu/index.js +1 -1
- package/nav/index.cjs +1 -1
- package/nav/index.js +1 -1
- package/nav-disclosure/index.cjs +1 -1
- package/nav-disclosure/index.js +1 -1
- package/nav-item/index.cjs +1 -1
- package/nav-item/index.js +1 -1
- package/note/index.cjs +1 -1
- package/note/index.js +1 -1
- package/number-field/index.cjs +1 -1
- package/number-field/index.js +1 -1
- package/option/index.cjs +1 -1
- package/option/index.js +1 -1
- package/package.json +1 -1
- package/pagination/index.cjs +1 -1
- package/pagination/index.js +1 -1
- package/popup/index.cjs +1 -1
- package/popup/index.js +1 -1
- package/progress/index.cjs +1 -1
- package/progress/index.js +1 -1
- package/progress-ring/index.cjs +1 -1
- package/progress-ring/index.js +1 -1
- package/radio/index.cjs +1 -1
- package/radio/index.js +1 -1
- package/radio-group/index.cjs +1 -1
- package/radio-group/index.js +1 -1
- package/range-slider/index.cjs +1 -1
- package/range-slider/index.js +1 -1
- package/rich-text-editor/index.cjs +1 -1
- package/rich-text-editor/index.js +1 -1
- package/searchable-select/index.cjs +1 -1
- package/searchable-select/index.js +1 -1
- package/select/index.cjs +1 -1
- package/select/index.js +1 -1
- package/selectable-box/index.cjs +1 -1
- package/selectable-box/index.js +1 -1
- package/shared/affix.cjs +13 -7
- package/shared/affix.js +13 -8
- package/shared/aria/delegates-aria.d.ts +6 -0
- package/shared/aria/host-semantics.d.ts +6 -0
- package/shared/breadcrumb-item.cjs +2 -5
- package/shared/breadcrumb-item.js +2 -5
- package/shared/button.cjs +13 -11
- package/shared/button.js +13 -11
- package/shared/calendar-picker.template.cjs +3 -3
- package/shared/calendar-picker.template.js +1 -1
- package/shared/char-count.cjs +92 -0
- package/shared/char-count.js +90 -0
- package/shared/definition.js +1 -1
- package/shared/definition10.js +1 -1
- package/shared/definition11.cjs +27 -44
- package/shared/definition11.js +28 -45
- package/shared/definition12.js +1 -1
- package/shared/definition13.js +1 -1
- package/shared/definition14.cjs +53 -22
- package/shared/definition14.js +54 -23
- package/shared/definition15.cjs +31 -36
- package/shared/definition15.js +30 -36
- package/shared/definition16.cjs +43 -63
- package/shared/definition16.js +42 -63
- package/shared/definition17.cjs +8 -4
- package/shared/definition17.js +8 -4
- package/shared/definition18.cjs +10 -14
- package/shared/definition18.js +9 -14
- package/shared/definition19.cjs +85 -100
- package/shared/definition19.js +75 -91
- package/shared/definition2.js +1 -1
- package/shared/definition20.cjs +15 -20
- package/shared/definition20.js +14 -20
- package/shared/definition21.cjs +22 -3
- package/shared/definition21.js +23 -4
- package/shared/definition22.cjs +4 -4
- package/shared/definition22.js +5 -5
- package/shared/definition23.cjs +5 -38
- package/shared/definition23.js +5 -37
- package/shared/definition24.cjs +2 -7
- package/shared/definition24.js +3 -8
- package/shared/definition25.js +1 -1
- package/shared/definition26.cjs +157 -171
- package/shared/definition26.js +156 -171
- package/shared/definition27.cjs +1 -1
- package/shared/definition27.js +2 -2
- package/shared/definition28.cjs +32 -17
- package/shared/definition28.js +33 -18
- package/shared/definition29.js +1 -1
- package/shared/definition3.js +1 -1
- package/shared/definition30.cjs +96 -482
- package/shared/definition30.js +99 -482
- package/shared/definition31.cjs +334 -57
- package/shared/definition31.js +333 -56
- package/shared/definition32.cjs +104 -19
- package/shared/definition32.js +105 -20
- package/shared/definition33.cjs +67 -15
- package/shared/definition33.js +66 -14
- package/shared/definition34.cjs +15 -50
- package/shared/definition34.js +14 -49
- package/shared/definition35.cjs +28 -397
- package/shared/definition35.js +27 -397
- package/shared/definition36.cjs +404 -54
- package/shared/definition36.js +404 -55
- package/shared/definition37.cjs +57 -234
- package/shared/definition37.js +57 -233
- package/shared/definition38.cjs +221 -66
- package/shared/definition38.js +220 -65
- package/shared/definition39.cjs +52 -44
- package/shared/definition39.js +51 -43
- package/shared/definition4.cjs +31 -24
- package/shared/definition4.js +33 -26
- package/shared/definition40.cjs +56 -266
- package/shared/definition40.js +55 -265
- package/shared/definition41.cjs +285 -142
- package/shared/definition41.js +285 -142
- package/shared/definition42.cjs +156 -564
- package/shared/definition42.js +156 -565
- package/shared/definition43.cjs +554 -14378
- package/shared/definition43.js +553 -14377
- package/shared/definition44.cjs +14418 -1155
- package/shared/definition44.js +14417 -1156
- package/shared/definition45.cjs +1049 -677
- package/shared/definition45.js +1050 -678
- package/shared/definition46.cjs +848 -113
- package/shared/definition46.js +847 -112
- package/shared/definition47.cjs +125 -90
- package/shared/definition47.js +124 -89
- package/shared/definition48.cjs +88 -455
- package/shared/definition48.js +87 -454
- package/shared/definition49.cjs +466 -109
- package/shared/definition49.js +466 -109
- package/shared/definition5.cjs +8 -7
- package/shared/definition5.js +6 -5
- package/shared/definition50.cjs +106 -106
- package/shared/definition50.js +105 -105
- package/shared/definition51.cjs +136 -15
- package/shared/definition51.js +135 -14
- package/shared/definition52.cjs +16 -115
- package/shared/definition52.js +15 -114
- package/shared/definition53.cjs +78 -412
- package/shared/definition53.js +77 -410
- package/shared/definition54.cjs +445 -23
- package/shared/definition54.js +443 -22
- package/shared/definition55.cjs +22 -136
- package/shared/definition55.js +21 -135
- package/shared/definition56.cjs +95 -291
- package/shared/definition56.js +95 -292
- package/shared/definition57.cjs +192 -480
- package/shared/definition57.js +190 -479
- package/shared/definition58.cjs +411 -24
- package/shared/definition58.js +410 -24
- package/shared/definition59.cjs +27 -144
- package/shared/definition59.js +27 -143
- package/shared/definition6.js +1 -1
- package/shared/definition60.cjs +83 -54
- package/shared/definition60.js +82 -53
- package/shared/definition61.cjs +78 -166
- package/shared/definition61.js +77 -164
- package/shared/definition62.cjs +143 -232
- package/shared/definition62.js +141 -231
- package/shared/definition63.cjs +234 -69417
- package/shared/definition63.js +233 -69416
- package/shared/definition64.cjs +69454 -28
- package/shared/definition64.js +69453 -27
- package/shared/definition65.cjs +28 -2168
- package/shared/definition65.js +27 -2166
- package/shared/definition66.cjs +27 -0
- package/shared/definition66.js +23 -0
- package/shared/definition67.cjs +2195 -0
- package/shared/definition67.js +2190 -0
- package/shared/definition7.cjs +11 -2
- package/shared/definition7.js +12 -3
- package/shared/definition8.cjs +24 -11
- package/shared/definition8.js +26 -13
- package/shared/definition9.cjs +1 -2
- package/shared/definition9.js +2 -3
- package/shared/delegates-aria.js +1 -1
- package/shared/deprecation/replaced-props.d.ts +20 -0
- package/shared/divider.cjs +41 -0
- package/shared/divider.js +38 -0
- package/shared/feedback/feedback-message.d.ts +345 -0
- package/shared/feedback/locale.d.ts +4 -0
- package/{lib/text-anchor/text-anchor.d.ts → shared/feedback/mixins.d.ts} +62 -39
- package/shared/form-associated.cjs +124 -100
- package/shared/form-associated.js +125 -101
- package/shared/form-element.cjs +84 -0
- package/shared/form-element.js +82 -0
- package/shared/foundation/button/button.d.ts +378 -2
- package/shared/foundation/form-associated/form-associated.d.ts +753 -49
- package/shared/foundation/listbox/listbox.d.ts +1 -1
- package/shared/foundation/vivid-element/vivid-element.d.ts +14 -0
- package/shared/host-semantics.js +1 -1
- package/shared/key-codes.js +1 -1
- package/shared/linkable.cjs +70 -0
- package/shared/linkable.js +68 -0
- package/shared/localization/Locale.d.ts +14 -0
- package/shared/mixins.cjs +306 -0
- package/shared/mixins.js +300 -0
- package/shared/patterns/affix.d.ts +16 -1
- package/shared/patterns/anchored.d.ts +20 -8
- package/shared/patterns/char-count/char-count.d.ts +351 -0
- package/shared/patterns/char-count/index.d.ts +1 -0
- package/shared/patterns/char-count/locale.d.ts +4 -0
- package/shared/patterns/form-elements/form-element.d.ts +744 -0
- package/shared/patterns/form-elements/index.d.ts +3 -1
- package/shared/patterns/form-elements/with-error-text.d.ts +1122 -0
- package/shared/patterns/form-elements/with-success-text.d.ts +341 -0
- package/shared/patterns/index.d.ts +2 -0
- package/shared/patterns/linkable.d.ts +394 -0
- package/shared/patterns/localized.d.ts +6 -0
- package/shared/patterns/trapped-focus.d.ts +6 -0
- package/shared/picker-field/mixins/calendar-picker.d.ts +420 -52
- package/shared/picker-field/mixins/calendar-picker.template.d.ts +420 -52
- package/shared/picker-field/mixins/inline-time-picker/inline-time-picker.d.ts +6 -0
- package/shared/picker-field/mixins/min-max-calendar-picker.d.ts +843 -107
- package/shared/picker-field/mixins/single-date-picker.d.ts +1259 -155
- package/shared/picker-field/mixins/single-value-picker.d.ts +417 -49
- package/shared/picker-field/mixins/time-selection-picker.d.ts +842 -106
- package/shared/picker-field/mixins/time-selection-picker.template.d.ts +839 -103
- package/shared/picker-field/picker-field.d.ts +1491 -15
- package/shared/picker-field.template.cjs +13 -22
- package/shared/picker-field.template.js +14 -23
- package/shared/repeat.js +1 -1
- package/shared/slider.template.cjs +1 -1
- package/shared/slider.template.js +1 -1
- package/shared/time-selection-picker.template.cjs +10 -15
- package/shared/time-selection-picker.template.js +10 -16
- package/shared/vivid-element.cjs +53 -4
- package/shared/vivid-element.js +53 -3
- package/shared/with-error-text.cjs +56 -0
- package/shared/with-error-text.js +54 -0
- package/shared/with-success-text.cjs +23 -0
- package/shared/with-success-text.js +21 -0
- package/side-drawer/index.cjs +1 -1
- package/side-drawer/index.js +1 -1
- package/slider/index.cjs +1 -1
- package/slider/index.js +1 -1
- package/split-button/index.cjs +1 -1
- package/split-button/index.js +1 -1
- package/styles/core/all.css +1 -1
- package/styles/core/theme.css +1 -1
- package/styles/core/typography.css +1 -1
- package/styles/tokens/theme-dark.css +4 -4
- package/styles/tokens/theme-light.css +4 -4
- package/styles/tokens/vivid-2-compat.css +1 -1
- package/switch/index.cjs +1 -1
- package/switch/index.js +1 -1
- 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/tabs/index.cjs +1 -1
- package/tabs/index.js +1 -1
- package/tag/index.cjs +1 -1
- package/tag/index.js +1 -1
- package/tag-group/index.cjs +1 -1
- package/tag-group/index.js +1 -1
- package/text-area/index.cjs +1 -1
- package/text-area/index.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/index.cjs +1 -1
- package/toggletip/index.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 +1 -1
- package/tree-view/index.js +1 -1
- package/video-player/index.cjs +1 -1
- package/video-player/index.js +1 -1
- package/visually-hidden/index.cjs +5 -0
- package/visually-hidden/index.js +3 -0
- package/vivid.api.json +744 -1490
- package/lib/checkbox/checkbox.form-associated.d.ts +0 -11
- package/lib/file-picker/file-picker.form-associated.d.ts +0 -11
- package/lib/number-field/number-field.form-associated.d.ts +0 -11
- package/lib/radio/radio.form-associated.d.ts +0 -13
- package/lib/range-slider/range-slider.form-associated.d.ts +0 -11
- package/lib/searchable-select/searchable-select.form-associated.d.ts +0 -11
- package/lib/select/select.form-associated.d.ts +0 -11
- package/lib/slider/slider.form-associated.d.ts +0 -11
- package/lib/switch/switch.form-associated.d.ts +0 -11
- package/lib/text-anchor/definition.d.ts +0 -2
- package/lib/text-anchor/text-anchor.template.d.ts +0 -3
- package/lib/text-area/text-area.form-associated.d.ts +0 -11
- package/lib/text-field/text-field.form-associated.d.ts +0 -11
- package/shared/anchor.cjs +0 -49
- package/shared/anchor.js +0 -47
- package/shared/apply-mixins.cjs +0 -23
- package/shared/apply-mixins.js +0 -21
- package/shared/applyMixinsWithObservables.cjs +0 -15
- package/shared/applyMixinsWithObservables.js +0 -13
- package/shared/direction.cjs +0 -17
- package/shared/direction.js +0 -15
- package/shared/form-elements.cjs +0 -209
- package/shared/form-elements.js +0 -202
- package/shared/foundation/anchor/anchor.d.ts +0 -11
- package/shared/foundation/utilities/apply-mixins.d.ts +0 -1
- package/shared/patterns/form-elements/form-elements.d.ts +0 -58
- package/shared/picker-field/picker-field.form-associated.d.ts +0 -11
- package/shared/text-anchor.cjs +0 -38
- package/shared/text-anchor.js +0 -36
- package/shared/text-anchor.template.cjs +0 -35
- package/shared/text-anchor.template.js +0 -33
- package/shared/utils/applyMixinsWithObservables.d.ts +0 -1
- package/text-anchor/index.cjs +0 -17
- package/text-anchor/index.js +0 -15
package/shared/definition46.js
CHANGED
|
@@ -1,156 +1,891 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { D as
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
1
|
+
import { P as Popup, p as popupDefinition } from './definition67.js';
|
|
2
|
+
import { i as iconDefinition } from './definition28.js';
|
|
3
|
+
import { l as listboxOptionDefinition } from './definition37.js';
|
|
4
|
+
import { D as DOM, O as Observable, o as observable, a as attr, v as volatile, h as html, d as createRegisterFunction, f as defineVividComponent } from './vivid-element.js';
|
|
5
|
+
import { W as WithLightDOMFeedback, f as feedbackMessageDefinition } from './mixins.js';
|
|
6
|
+
import { L as Listbox } from './listbox.js';
|
|
7
|
+
import { H as HostSemantics, a as applyHostSemantics } from './host-semantics.js';
|
|
8
|
+
import { F as FormAssociated } from './form-associated.js';
|
|
9
|
+
import { i as inRange } from './numbers.js';
|
|
10
|
+
import { W as WithErrorText } from './with-error-text.js';
|
|
11
|
+
import { W as WithSuccessText } from './with-success-text.js';
|
|
12
|
+
import { F as FormElement } from './form-element.js';
|
|
13
|
+
import { A as AffixIconWithTrailing, a as affixIconTemplateFactory, I as IconWrapper } from './affix.js';
|
|
14
|
+
import { u as uniqueId } from './strings.js';
|
|
15
|
+
import { a as keySpace, b as keyEscape, c as keyTab, d as keyEnd, e as keyArrowUp, f as keyArrowDown, g as keyHome, k as keyEnter } from './key-codes.js';
|
|
16
|
+
import { L as ListboxOption } from './option.js';
|
|
17
|
+
import { c as chevronTemplateFactory } from './definition11.js';
|
|
18
|
+
import { h as handleEscapeKeyAndStopPropogation } from './index.js';
|
|
19
|
+
import { r as ref } from './ref.js';
|
|
7
20
|
import { w as when } from './when.js';
|
|
21
|
+
import { s as slotted } from './slotted.js';
|
|
22
|
+
import { c as classNames } from './class-names.js';
|
|
8
23
|
|
|
9
|
-
const styles = "
|
|
24
|
+
const styles = ".chevron{display:flex;flex-shrink:0;font:var(--vvd-typography-base-extended);transform:rotate(0);transition:transform .2s}:host([data-expanded=true]) .chevron,:host([open]) .chevron{transform:rotate(180deg)}:host(:focus-visible){outline:none}:host{display:inline-flex;flex-direction:column;gap:4px;--_low-ink-color: var(--vvd-color-neutral-600);--focus-stroke-gap-color: transparent}:host([disabled]){--_low-ink-color: var(--vvd-color-neutral-400);cursor:not-allowed}.label{color:var(--vvd-color-canvas-text);contain:inline-size;font:var(--vvd-typography-base)}.control{--_appearance-color-text: var(--vvd-color-canvas-text);--_appearance-color-fill: var(--vvd-color-canvas);--_appearance-color-outline: var(--vvd-color-neutral-500)}.control.appearance-ghost{--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: transparent;--_appearance-color-outline: transparent}.control:where(.hover,:hover):where(:not(.disabled,:disabled,.readonly)){--_appearance-color-text: var(--vvd-color-canvas-text);--_appearance-color-fill: var(--vvd-color-canvas);--_appearance-color-outline: var(--vvd-color-neutral-700)}.control:where(.hover,:hover):where(:not(.disabled,:disabled,.readonly)).appearance-ghost{--_appearance-color-text: var(--_connotation-color-firm);--_appearance-color-fill: var(--_connotation-color-faint);--_appearance-color-outline: transparent}.control:where(.disabled,:disabled){--_appearance-color-text: var(--vvd-color-neutral-300);--_appearance-color-fill: var(--vvd-color-neutral-100);--_appearance-color-outline: var(--vvd-color-neutral-300)}.control:where(.disabled,:disabled).appearance-ghost{--_appearance-color-text: var(--vvd-color-neutral-300);--_appearance-color-fill: transparent;--_appearance-color-outline: transparent}.control:where(.readonly):where(:not(.disabled,:disabled)){--_appearance-color-text: var(--vvd-color-canvas-text);--_appearance-color-fill: var(--vvd-color-neutral-200);--_appearance-color-outline: var(--vvd-color-neutral-400)}.control:where(.readonly):where(:not(.disabled,:disabled)).appearance-ghost{--_appearance-color-text: var(--vvd-color-neutral-600);--_appearance-color-fill: transparent;--_appearance-color-outline: transparent}.control:where(.error):where(:not(.disabled,:disabled)){--_appearance-color-text: notSet;--_appearance-color-fill: var(--vvd-color-alert-50);--_appearance-color-outline: var(--vvd-color-alert-500)}.control:where(.error):where(:not(.disabled,:disabled)).appearance-ghost{--_appearance-color-text: notSet;--_appearance-color-fill: var(--vvd-color-alert-50);--_appearance-color-outline: transparent}.control:where(.success):where(:not(.disabled,:disabled)){--_appearance-color-text: notSet;--_appearance-color-fill: var(--vvd-color-success-50);--_appearance-color-outline: var(--vvd-color-success-500)}.control:where(.success):where(:not(.disabled,:disabled)).appearance-ghost{--_appearance-color-text: notSet;--_appearance-color-fill: var(--vvd-color-success-50);--_appearance-color-outline: transparent}.control{--_connotation-color-primary: var(--vvd-select-accent-primary, var(--vvd-color-canvas-text));--_connotation-color-primary-text: var(--vvd-select-accent-primary-text, var(--vvd-color-canvas));--_connotation-color-primary-increment: var(--vvd-select-accent-primary-increment, var(--vvd-color-neutral-800));--_connotation-color-intermediate: var(--vvd-select-accent-intermediate, var(--vvd-color-neutral-500));--_connotation-color-faint: var(--vvd-select-accent-faint, var(--vvd-color-neutral-50));--_connotation-color-soft: var(--vvd-select-accent-soft, var(--vvd-color-neutral-100));--_connotation-color-firm: var(--vvd-select-accent-firm, var(--vvd-color-canvas-text));--_connotation-color-fierce: var(--vvd-select-accent-fierce, var(--vvd-color-neutral-700))}.control{border-radius:var(--_select-control-border-radius);block-size:var(--_select-block-size);padding-inline:var(--_select-padding-inline)}.control{--_select-icon-size: calc(1px*(40 + 4*clamp(-1, var(--vvd-size-density, 0), 2))/2) ;--_select-block-size: calc(1px*(40 + 4*clamp(-1, var(--vvd-size-density, 0), 2))) ;--_select-padding-inline: calc(1px*(40 + 4*clamp(-1, var(--vvd-size-density, 0), 2))*.4) ;display:flex;align-items:center;justify-content:space-between;background-color:var(--_appearance-color-fill);box-shadow:inset 0 0 0 1px var(--_appearance-color-outline);color:var(--_appearance-color-text);font:var(--vvd-typography-base);gap:8px;transition:box-shadow .2s,background-color .2s}.control.size-condensed{--_select-icon-size: calc(1px*(40 + 4*clamp(-1, var(--vvd-size-density, 0), 2))*.4) ;--_select-block-size: calc(1px*(32 + 4*clamp(-1, var(--vvd-size-density, 0), 2))) ;--_select-padding-inline: calc(1px*(24 + 4*clamp(-1, var(--vvd-size-density, 0), 2))/2) }.control.size-condensed:not(.shape-pill){--_select-control-border-radius: 4px}.control-wrapper{position:relative}.control:not(.disabled){cursor:pointer}.control.disabled{pointer-events:none}.control:not(.shape-pill){--_select-control-border-radius: 8px}.control.shape-pill{--_select-control-border-radius: 24px}:host(:focus-visible) .control{box-shadow:0 0 0 4px color-mix(in srgb,var(--vvd-color-cta-500),transparent 85%),inset 0 0 0 3px var(--focus-stroke-gap-color, currentColor);outline:1px solid var(--focus-stroke-color, var(--vvd-color-cta-500));outline-offset:calc(-1px - var(--focus-inset, 0px))}.listbox{display:flex;max-height:var(--select-height, 408px);flex-direction:column;padding:4px;gap:2px;overflow-y:auto}:host([multiple]:focus-visible) .listbox{box-shadow:0 0 0 4px color-mix(in srgb,var(--vvd-color-cta-500),transparent 85%),inset 0 0 0 3px var(--focus-stroke-gap-color, currentColor);outline:1px solid var(--focus-stroke-color, var(--vvd-color-cta-500));outline-offset:calc(-1px - var(--focus-inset, 0px));border-radius:8px}.selected-value{display:flex;overflow:hidden;flex-grow:1;align-items:center;column-gap:12px;white-space:nowrap}.selected-value .text{overflow:hidden;max-inline-size:100%;text-overflow:ellipsis}.control.shows-placeholder .selected-value .text{color:var(--vvd-color-neutral-600)}.selected-value slot[name=icon]{flex:0 0 var(--_select-icon-size);font-size:var(--_select-icon-size);line-height:1}.control.has-meta .selected-value{padding-inline-end:8px}.feedback-wrapper{display:contents}::part(popup-base){inline-size:max-content;min-inline-size:var(--_select-fixed-width, 100%)}:host([multiple]) ::part(popup-base){position:static}";
|
|
10
25
|
|
|
11
26
|
var __defProp = Object.defineProperty;
|
|
27
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
12
28
|
var __decorateClass = (decorators, target, key, kind) => {
|
|
13
|
-
var result = void 0 ;
|
|
29
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
|
|
14
30
|
for (var i = decorators.length - 1, decorator; i >= 0; i--)
|
|
15
31
|
if (decorator = decorators[i])
|
|
16
|
-
result = (decorator(target, key, result) ) || result;
|
|
17
|
-
if (result) __defProp(target, key, result);
|
|
32
|
+
result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
33
|
+
if (kind && result) __defProp(target, key, result);
|
|
18
34
|
return result;
|
|
19
35
|
};
|
|
20
|
-
class
|
|
36
|
+
class Select extends WithLightDOMFeedback(
|
|
37
|
+
WithErrorText(
|
|
38
|
+
WithSuccessText(
|
|
39
|
+
FormElement(HostSemantics(AffixIconWithTrailing(FormAssociated(Listbox))))
|
|
40
|
+
)
|
|
41
|
+
)
|
|
42
|
+
) {
|
|
21
43
|
constructor() {
|
|
22
44
|
super(...arguments);
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
this.
|
|
45
|
+
/**
|
|
46
|
+
* @internal
|
|
47
|
+
*/
|
|
48
|
+
this.proxy = document.createElement("select");
|
|
49
|
+
this.activeIndex = -1;
|
|
50
|
+
/**
|
|
51
|
+
* The start index when checking a range of options.
|
|
52
|
+
*
|
|
53
|
+
* @internal
|
|
54
|
+
*/
|
|
55
|
+
this.rangeStartIndex = -1;
|
|
56
|
+
this.open = false;
|
|
57
|
+
/**
|
|
58
|
+
* The unique id for the internal listbox element.
|
|
59
|
+
*
|
|
60
|
+
* @internal
|
|
61
|
+
*/
|
|
62
|
+
this.listboxId = uniqueId("listbox-");
|
|
63
|
+
this.maxHeight = 0;
|
|
64
|
+
this.fixedDropdown = false;
|
|
65
|
+
this.placeholderOption = null;
|
|
66
|
+
this._feedbackWrapper = null;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Returns the last checked option.
|
|
70
|
+
*
|
|
71
|
+
* @internal
|
|
72
|
+
*/
|
|
73
|
+
get activeOption() {
|
|
74
|
+
return this.options[this.activeIndex];
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Returns the list of checked options.
|
|
78
|
+
*
|
|
79
|
+
* @internal
|
|
80
|
+
*/
|
|
81
|
+
get checkedOptions() {
|
|
82
|
+
return this.options.filter((o) => o.checked);
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Returns the index of the first selected option.
|
|
86
|
+
*
|
|
87
|
+
* @internal
|
|
88
|
+
*/
|
|
89
|
+
get firstSelectedOptionIndex() {
|
|
90
|
+
return this.options.indexOf(this.firstSelectedOption);
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Updates the `ariaActiveDescendant` property when the active index changes.
|
|
94
|
+
*
|
|
95
|
+
* @internal
|
|
96
|
+
*/
|
|
97
|
+
activeIndexChanged(_, next) {
|
|
98
|
+
this._activeDescendant = this.options[next]?.id ?? "";
|
|
99
|
+
this.focusAndScrollOptionIntoView();
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Toggles the checked state for the currently active option.
|
|
103
|
+
*
|
|
104
|
+
* @remarks
|
|
105
|
+
* Multiple-selection mode only.
|
|
106
|
+
*
|
|
107
|
+
* @internal
|
|
108
|
+
*/
|
|
109
|
+
checkActiveIndex() {
|
|
110
|
+
const activeItem = this.activeOption;
|
|
111
|
+
if (activeItem) {
|
|
112
|
+
activeItem.checked = true;
|
|
113
|
+
}
|
|
27
114
|
}
|
|
28
115
|
/**
|
|
116
|
+
* Sets the active index to the first option and marks it as checked.
|
|
117
|
+
*
|
|
118
|
+
* @remarks
|
|
119
|
+
* Multi-selection mode only.
|
|
120
|
+
*
|
|
121
|
+
* @param preserveChecked - mark all options unchecked before changing the active index
|
|
122
|
+
*
|
|
29
123
|
* @internal
|
|
30
124
|
*/
|
|
31
|
-
|
|
32
|
-
if (
|
|
33
|
-
|
|
34
|
-
|
|
125
|
+
checkFirstOption(preserveChecked) {
|
|
126
|
+
if (preserveChecked) {
|
|
127
|
+
if (this.rangeStartIndex === -1) {
|
|
128
|
+
this.rangeStartIndex = this.activeIndex + 1;
|
|
129
|
+
}
|
|
130
|
+
this.options.forEach((o, i) => {
|
|
131
|
+
o.checked = inRange(i, this.rangeStartIndex);
|
|
132
|
+
});
|
|
133
|
+
} else {
|
|
134
|
+
this.uncheckAllOptions();
|
|
135
|
+
}
|
|
136
|
+
this.activeIndex = 0;
|
|
137
|
+
this.checkActiveIndex();
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* Decrements the active index and sets the matching option as checked.
|
|
141
|
+
*
|
|
142
|
+
* @remarks
|
|
143
|
+
* Multi-selection mode only.
|
|
144
|
+
*
|
|
145
|
+
* @param preserveChecked - mark all options unchecked before changing the active index
|
|
146
|
+
*
|
|
147
|
+
* @internal
|
|
148
|
+
*/
|
|
149
|
+
checkLastOption(preserveChecked) {
|
|
150
|
+
if (preserveChecked) {
|
|
151
|
+
if (this.rangeStartIndex === -1) {
|
|
152
|
+
this.rangeStartIndex = this.activeIndex;
|
|
153
|
+
}
|
|
154
|
+
this.options.forEach((o, i) => {
|
|
155
|
+
o.checked = inRange(i, this.rangeStartIndex, this.length);
|
|
156
|
+
});
|
|
157
|
+
} else {
|
|
158
|
+
this.uncheckAllOptions();
|
|
159
|
+
}
|
|
160
|
+
this.activeIndex = this.length - 1;
|
|
161
|
+
this.checkActiveIndex();
|
|
35
162
|
}
|
|
36
163
|
/**
|
|
164
|
+
* Increments the active index and marks the matching option as checked.
|
|
165
|
+
*
|
|
166
|
+
* @remarks
|
|
167
|
+
* Multiple-selection mode only.
|
|
168
|
+
*
|
|
169
|
+
* @param preserveChecked - mark all options unchecked before changing the active index
|
|
170
|
+
*
|
|
37
171
|
* @internal
|
|
38
172
|
*/
|
|
39
|
-
|
|
40
|
-
if (
|
|
41
|
-
|
|
173
|
+
checkNextOption(preserveChecked) {
|
|
174
|
+
if (preserveChecked) {
|
|
175
|
+
if (this.rangeStartIndex === -1) {
|
|
176
|
+
this.rangeStartIndex = this.activeIndex;
|
|
177
|
+
}
|
|
178
|
+
this.options.forEach((o, i) => {
|
|
179
|
+
o.checked = inRange(i, this.rangeStartIndex, this.activeIndex + 1);
|
|
180
|
+
});
|
|
181
|
+
} else {
|
|
182
|
+
this.uncheckAllOptions();
|
|
183
|
+
}
|
|
184
|
+
this.activeIndex += this.activeIndex < this.length - 1 ? 1 : 0;
|
|
185
|
+
this.checkActiveIndex();
|
|
186
|
+
}
|
|
187
|
+
/**
|
|
188
|
+
* Decrements the active index and marks the matching option as checked.
|
|
189
|
+
*
|
|
190
|
+
* @remarks
|
|
191
|
+
* Multiple-selection mode only.
|
|
192
|
+
*
|
|
193
|
+
* @param preserveChecked - mark all options unchecked before changing the active index
|
|
194
|
+
*
|
|
195
|
+
* @internal
|
|
196
|
+
*/
|
|
197
|
+
checkPreviousOption(preserveChecked) {
|
|
198
|
+
if (preserveChecked) {
|
|
199
|
+
if (this.rangeStartIndex === -1) {
|
|
200
|
+
this.rangeStartIndex = this.activeIndex;
|
|
201
|
+
}
|
|
202
|
+
if (this.checkedOptions.length === 1) {
|
|
203
|
+
this.rangeStartIndex += 1;
|
|
204
|
+
}
|
|
205
|
+
this.options.forEach((o, i) => {
|
|
206
|
+
o.checked = inRange(i, this.activeIndex, this.rangeStartIndex);
|
|
207
|
+
});
|
|
208
|
+
} else {
|
|
209
|
+
this.uncheckAllOptions();
|
|
210
|
+
}
|
|
211
|
+
this.activeIndex -= this.activeIndex > 0 ? 1 : 0;
|
|
212
|
+
this.checkActiveIndex();
|
|
213
|
+
}
|
|
214
|
+
/**
|
|
215
|
+
* @internal
|
|
216
|
+
*/
|
|
217
|
+
focusAndScrollOptionIntoView() {
|
|
218
|
+
super.focusAndScrollOptionIntoView(this.activeOption);
|
|
219
|
+
}
|
|
220
|
+
/**
|
|
221
|
+
* In multiple-selection mode:
|
|
222
|
+
* If any options are selected, the first selected option is checked when
|
|
223
|
+
* the listbox receives focus. If no options are selected, the first
|
|
224
|
+
* selectable option is checked.
|
|
225
|
+
*
|
|
226
|
+
* @internal
|
|
227
|
+
*/
|
|
228
|
+
focusinHandler(e) {
|
|
229
|
+
if (!this.multiple) {
|
|
230
|
+
return super.focusinHandler(e);
|
|
231
|
+
}
|
|
232
|
+
if (!this.shouldSkipFocus && e.target === e.currentTarget) {
|
|
233
|
+
this.uncheckAllOptions();
|
|
234
|
+
if (this.activeIndex === -1) {
|
|
235
|
+
this.activeIndex = this.firstSelectedOptionIndex !== -1 ? this.firstSelectedOptionIndex : 0;
|
|
236
|
+
}
|
|
237
|
+
this.checkActiveIndex();
|
|
238
|
+
this.setSelectedOptions();
|
|
239
|
+
this.focusAndScrollOptionIntoView();
|
|
240
|
+
}
|
|
241
|
+
this.shouldSkipFocus = false;
|
|
242
|
+
}
|
|
243
|
+
/**
|
|
244
|
+
* Sets an option as selected and gives it focus.
|
|
245
|
+
*
|
|
246
|
+
* @public
|
|
247
|
+
*/
|
|
248
|
+
setSelectedOptions() {
|
|
249
|
+
if (!this.multiple) {
|
|
250
|
+
super.setSelectedOptions();
|
|
251
|
+
return;
|
|
252
|
+
}
|
|
253
|
+
if (this.$fastController.isConnected && this.options) {
|
|
254
|
+
this.selectedOptions = this.options.filter((o) => o.selected);
|
|
255
|
+
this.focusAndScrollOptionIntoView();
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
/**
|
|
259
|
+
* Toggles the selected state of the provided options. If any provided items
|
|
260
|
+
* are in an unselected state, all items are set to selected. If every
|
|
261
|
+
* provided item is selected, they are all unselected.
|
|
262
|
+
*
|
|
263
|
+
* @internal
|
|
264
|
+
*/
|
|
265
|
+
toggleSelectedForAllCheckedOptions() {
|
|
266
|
+
const enabledCheckedOptions = this.checkedOptions.filter(
|
|
267
|
+
(o) => !o.disabled
|
|
268
|
+
);
|
|
269
|
+
const force = !enabledCheckedOptions.every((o) => o.selected);
|
|
270
|
+
enabledCheckedOptions.forEach((o) => o.selected = force);
|
|
271
|
+
this.selectedIndex = this.options.indexOf(
|
|
272
|
+
enabledCheckedOptions[enabledCheckedOptions.length - 1]
|
|
273
|
+
);
|
|
274
|
+
this.setSelectedOptions();
|
|
275
|
+
this.updateValue(true);
|
|
276
|
+
}
|
|
277
|
+
/**
|
|
278
|
+
* @internal
|
|
279
|
+
*/
|
|
280
|
+
typeaheadBufferChanged(prev, next) {
|
|
281
|
+
if (!this.multiple) {
|
|
282
|
+
super.typeaheadBufferChanged(prev, next);
|
|
283
|
+
return;
|
|
284
|
+
}
|
|
285
|
+
if (this.$fastController.isConnected) {
|
|
286
|
+
const typeaheadMatches = this.getTypeaheadMatches();
|
|
287
|
+
const activeIndex = this.options.indexOf(typeaheadMatches[0]);
|
|
288
|
+
if (activeIndex > -1) {
|
|
289
|
+
this.activeIndex = activeIndex;
|
|
290
|
+
this.uncheckAllOptions();
|
|
291
|
+
this.checkActiveIndex();
|
|
292
|
+
}
|
|
293
|
+
this.typeaheadExpired = false;
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
/**
|
|
297
|
+
* Unchecks all options.
|
|
298
|
+
*
|
|
299
|
+
* @remarks
|
|
300
|
+
* Multiple-selection mode only.
|
|
301
|
+
*
|
|
302
|
+
* @param preserveChecked - reset the rangeStartIndex
|
|
303
|
+
*
|
|
304
|
+
* @internal
|
|
305
|
+
*/
|
|
306
|
+
uncheckAllOptions(preserveChecked = false) {
|
|
307
|
+
this.options.forEach((o) => o.checked = false);
|
|
308
|
+
if (!preserveChecked) {
|
|
309
|
+
this.rangeStartIndex = -1;
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
/**
|
|
313
|
+
* Sets focus when the open property changes.
|
|
314
|
+
*
|
|
315
|
+
* @internal
|
|
316
|
+
*/
|
|
317
|
+
openChanged(prev, next) {
|
|
318
|
+
if (!this.collapsible) {
|
|
319
|
+
return;
|
|
320
|
+
}
|
|
321
|
+
if (this.open) {
|
|
322
|
+
this.focusAndScrollOptionIntoView();
|
|
323
|
+
this.indexWhenOpened = this.selectedIndex;
|
|
324
|
+
DOM.queueUpdate(() => this.focus());
|
|
325
|
+
return;
|
|
326
|
+
}
|
|
327
|
+
const didClose = prev === true && next === false;
|
|
328
|
+
const selectionChangedWhileOpen = this.indexWhenOpened !== this.selectedIndex;
|
|
329
|
+
if (didClose && selectionChangedWhileOpen) {
|
|
330
|
+
this.updateValue(true);
|
|
331
|
+
}
|
|
332
|
+
}
|
|
333
|
+
get collapsible() {
|
|
334
|
+
return !this.multiple;
|
|
335
|
+
}
|
|
336
|
+
/**
|
|
337
|
+
* @internal
|
|
338
|
+
*/
|
|
339
|
+
valueChanged(prev, next) {
|
|
340
|
+
let nextValue = next;
|
|
341
|
+
if (this.length) {
|
|
342
|
+
const selectedIndex = this._options.findIndex((el) => el.value === next);
|
|
343
|
+
const prevSelectedValue = this._options[this.selectedIndex]?.value ?? null;
|
|
344
|
+
const nextSelectedValue = this._options[selectedIndex]?.value ?? null;
|
|
345
|
+
if (selectedIndex === -1 || prevSelectedValue !== nextSelectedValue) {
|
|
346
|
+
nextValue = "";
|
|
347
|
+
this.selectedIndex = selectedIndex;
|
|
348
|
+
}
|
|
349
|
+
nextValue = this.firstSelectedOption?.value ?? nextValue;
|
|
350
|
+
}
|
|
351
|
+
if (next !== nextValue) {
|
|
352
|
+
this.value = nextValue;
|
|
353
|
+
return;
|
|
354
|
+
}
|
|
355
|
+
super.valueChanged(prev, next);
|
|
356
|
+
this.updateDisplayValue();
|
|
357
|
+
}
|
|
358
|
+
/**
|
|
359
|
+
* Sets the value and display value to match the first selected option.
|
|
360
|
+
*
|
|
361
|
+
* @param shouldEmit - if true, the input and change events will be emitted
|
|
362
|
+
*
|
|
363
|
+
* @internal
|
|
364
|
+
*/
|
|
365
|
+
updateValue(shouldEmit) {
|
|
366
|
+
if (this.$fastController.isConnected) {
|
|
367
|
+
this.value = this.firstSelectedOption?.value ?? "";
|
|
368
|
+
}
|
|
369
|
+
if (shouldEmit) {
|
|
370
|
+
this.$emit("input");
|
|
371
|
+
this.$emit("change", this, {
|
|
372
|
+
bubbles: true,
|
|
373
|
+
composed: void 0
|
|
374
|
+
});
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
/**
|
|
378
|
+
* Updates the proxy value when the selected index changes.
|
|
379
|
+
*
|
|
380
|
+
* @param prev - the previous selected index
|
|
381
|
+
* @param next - the next selected index
|
|
382
|
+
*
|
|
383
|
+
* @internal
|
|
384
|
+
*/
|
|
385
|
+
selectedIndexChanged(prev, next) {
|
|
386
|
+
super.selectedIndexChanged(prev, next);
|
|
387
|
+
this.updateValue();
|
|
388
|
+
}
|
|
389
|
+
/**
|
|
390
|
+
* Handle opening and closing the listbox when the select is clicked.
|
|
391
|
+
*
|
|
392
|
+
* @param e - the mouse event
|
|
393
|
+
* @internal
|
|
394
|
+
*/
|
|
395
|
+
clickHandler(e) {
|
|
396
|
+
if (this.disabled) {
|
|
397
|
+
return;
|
|
398
|
+
}
|
|
399
|
+
const clickedOption = e.target.closest(
|
|
400
|
+
`option,[role=option]`
|
|
401
|
+
);
|
|
402
|
+
if (clickedOption && clickedOption.disabled) {
|
|
403
|
+
return;
|
|
404
|
+
}
|
|
405
|
+
if (this.multiple) {
|
|
406
|
+
this.uncheckAllOptions();
|
|
407
|
+
this.activeIndex = this.options.indexOf(clickedOption);
|
|
408
|
+
this.checkActiveIndex();
|
|
409
|
+
this.toggleSelectedForAllCheckedOptions();
|
|
410
|
+
} else {
|
|
411
|
+
super.clickHandler(e);
|
|
412
|
+
}
|
|
413
|
+
if (this.collapsible) {
|
|
414
|
+
this.open = !this.open;
|
|
415
|
+
}
|
|
42
416
|
return true;
|
|
43
417
|
}
|
|
418
|
+
/**
|
|
419
|
+
* Handles focus state when the element or its children lose focus.
|
|
420
|
+
*
|
|
421
|
+
* @param e - The focus event
|
|
422
|
+
* @internal
|
|
423
|
+
*/
|
|
424
|
+
focusoutHandler(e) {
|
|
425
|
+
if (this.multiple) {
|
|
426
|
+
this.uncheckAllOptions();
|
|
427
|
+
}
|
|
428
|
+
if (!this.open) {
|
|
429
|
+
return true;
|
|
430
|
+
}
|
|
431
|
+
const focusTarget = e.relatedTarget;
|
|
432
|
+
if (this.isSameNode(focusTarget)) {
|
|
433
|
+
this.focus();
|
|
434
|
+
return;
|
|
435
|
+
}
|
|
436
|
+
if (!this.options.includes(focusTarget)) {
|
|
437
|
+
this.open = false;
|
|
438
|
+
if (this.indexWhenOpened !== this.selectedIndex) {
|
|
439
|
+
this.updateValue(true);
|
|
440
|
+
}
|
|
441
|
+
}
|
|
442
|
+
}
|
|
443
|
+
/**
|
|
444
|
+
* Updates the value when an option's value changes.
|
|
445
|
+
*
|
|
446
|
+
* @param source - the source object
|
|
447
|
+
* @param propertyName - the property to evaluate
|
|
448
|
+
*
|
|
449
|
+
* @internal
|
|
450
|
+
*/
|
|
451
|
+
handleChange(source, propertyName) {
|
|
452
|
+
super.handleChange(source, propertyName);
|
|
453
|
+
if (propertyName === "value") {
|
|
454
|
+
this.updateValue();
|
|
455
|
+
}
|
|
456
|
+
}
|
|
457
|
+
/**
|
|
458
|
+
* Prevents focus when a scrollbar is clicked.
|
|
459
|
+
*
|
|
460
|
+
* @param e - the mouse event object
|
|
461
|
+
*
|
|
462
|
+
* @internal
|
|
463
|
+
*/
|
|
464
|
+
mousedownHandler(e) {
|
|
465
|
+
if (e.offsetX >= 0 && e.offsetX <= this.listbox.scrollWidth) {
|
|
466
|
+
return super.mousedownHandler(e);
|
|
467
|
+
}
|
|
468
|
+
return this.collapsible;
|
|
469
|
+
}
|
|
470
|
+
/**
|
|
471
|
+
* @internal
|
|
472
|
+
*/
|
|
473
|
+
multipleChanged(_, next) {
|
|
474
|
+
this.options.forEach((o) => {
|
|
475
|
+
o.checked = next ? false : void 0;
|
|
476
|
+
});
|
|
477
|
+
this.setSelectedOptions();
|
|
478
|
+
if (this.proxy) {
|
|
479
|
+
this.proxy.multiple = next;
|
|
480
|
+
}
|
|
481
|
+
}
|
|
482
|
+
/**
|
|
483
|
+
* Updates the selectedness of each option when the list of selected options changes.
|
|
484
|
+
*
|
|
485
|
+
* @param prev - the previous list of selected options
|
|
486
|
+
* @param next - the current list of selected options
|
|
487
|
+
*
|
|
488
|
+
* @internal
|
|
489
|
+
*/
|
|
490
|
+
selectedOptionsChanged(prev, next) {
|
|
491
|
+
super.selectedOptionsChanged(prev, next);
|
|
492
|
+
this.options.forEach((o, i) => {
|
|
493
|
+
const proxyOption = this.proxy.options.item(i);
|
|
494
|
+
if (proxyOption) {
|
|
495
|
+
proxyOption.selected = o.selected;
|
|
496
|
+
}
|
|
497
|
+
});
|
|
498
|
+
}
|
|
499
|
+
/**
|
|
500
|
+
* Resets and fills the proxy to match the component's options.
|
|
501
|
+
*
|
|
502
|
+
* @internal
|
|
503
|
+
*/
|
|
504
|
+
setProxyOptions() {
|
|
505
|
+
if (this.proxy instanceof HTMLSelectElement && this.options) {
|
|
506
|
+
this.proxy.length = 0;
|
|
507
|
+
this.options.forEach((option) => {
|
|
508
|
+
const proxyOption = option.proxy || (option instanceof HTMLOptionElement ? option.cloneNode() : null);
|
|
509
|
+
if (proxyOption) {
|
|
510
|
+
this.proxy.options.add(proxyOption);
|
|
511
|
+
}
|
|
512
|
+
});
|
|
513
|
+
}
|
|
514
|
+
}
|
|
515
|
+
/**
|
|
516
|
+
* Handles keydown actions when the select is in multiple selection mode.
|
|
517
|
+
*
|
|
518
|
+
* @internal
|
|
519
|
+
*/
|
|
520
|
+
multipleKeydownHandler(e) {
|
|
521
|
+
if (this.disabled) {
|
|
522
|
+
return;
|
|
523
|
+
}
|
|
524
|
+
const { key, shiftKey } = e;
|
|
525
|
+
this.shouldSkipFocus = false;
|
|
526
|
+
switch (key) {
|
|
527
|
+
case keyHome: {
|
|
528
|
+
this.checkFirstOption(shiftKey);
|
|
529
|
+
return;
|
|
530
|
+
}
|
|
531
|
+
case keyArrowDown: {
|
|
532
|
+
this.checkNextOption(shiftKey);
|
|
533
|
+
return;
|
|
534
|
+
}
|
|
535
|
+
case keyArrowUp: {
|
|
536
|
+
this.checkPreviousOption(shiftKey);
|
|
537
|
+
return;
|
|
538
|
+
}
|
|
539
|
+
case keyEnd: {
|
|
540
|
+
this.checkLastOption(shiftKey);
|
|
541
|
+
return;
|
|
542
|
+
}
|
|
543
|
+
case keyTab: {
|
|
544
|
+
this.focusAndScrollOptionIntoView();
|
|
545
|
+
return;
|
|
546
|
+
}
|
|
547
|
+
case keyEscape: {
|
|
548
|
+
this.uncheckAllOptions();
|
|
549
|
+
this.checkActiveIndex();
|
|
550
|
+
return;
|
|
551
|
+
}
|
|
552
|
+
case keySpace: {
|
|
553
|
+
e.preventDefault();
|
|
554
|
+
if (this.typeaheadExpired) {
|
|
555
|
+
this.toggleSelectedForAllCheckedOptions();
|
|
556
|
+
return;
|
|
557
|
+
}
|
|
558
|
+
}
|
|
559
|
+
default: {
|
|
560
|
+
if (key.length === 1) {
|
|
561
|
+
this.handleTypeAhead(`${key}`);
|
|
562
|
+
}
|
|
563
|
+
return;
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
}
|
|
567
|
+
/**
|
|
568
|
+
* Handle keyboard interaction for the select.
|
|
569
|
+
*
|
|
570
|
+
* @param e - the keyboard event
|
|
571
|
+
* @internal
|
|
572
|
+
*/
|
|
573
|
+
keydownHandler(e) {
|
|
574
|
+
const selectedIndexBefore = this.selectedIndex;
|
|
575
|
+
if (this.multiple) {
|
|
576
|
+
this.multipleKeydownHandler(e);
|
|
577
|
+
} else {
|
|
578
|
+
super.keydownHandler(e);
|
|
579
|
+
}
|
|
580
|
+
const key = e.key;
|
|
581
|
+
switch (key) {
|
|
582
|
+
case keySpace: {
|
|
583
|
+
e.preventDefault();
|
|
584
|
+
if (this.collapsible && this.typeaheadExpired) {
|
|
585
|
+
this.open = !this.open;
|
|
586
|
+
}
|
|
587
|
+
break;
|
|
588
|
+
}
|
|
589
|
+
case keyHome:
|
|
590
|
+
case keyEnd: {
|
|
591
|
+
e.preventDefault();
|
|
592
|
+
break;
|
|
593
|
+
}
|
|
594
|
+
case keyEnter: {
|
|
595
|
+
e.preventDefault();
|
|
596
|
+
this.open = !this.open;
|
|
597
|
+
break;
|
|
598
|
+
}
|
|
599
|
+
case keyEscape: {
|
|
600
|
+
if (this.collapsible && this.open) {
|
|
601
|
+
e.preventDefault();
|
|
602
|
+
this.open = false;
|
|
603
|
+
}
|
|
604
|
+
break;
|
|
605
|
+
}
|
|
606
|
+
case keyTab: {
|
|
607
|
+
if (this.collapsible && this.open) {
|
|
608
|
+
e.preventDefault();
|
|
609
|
+
this.open = false;
|
|
610
|
+
}
|
|
611
|
+
return true;
|
|
612
|
+
}
|
|
613
|
+
}
|
|
614
|
+
if (this.collapsible && !this.open && this.selectedIndex !== selectedIndexBefore) {
|
|
615
|
+
this.updateValue(true);
|
|
616
|
+
}
|
|
617
|
+
return !(e.key === keyArrowDown || e.key === keyArrowUp);
|
|
618
|
+
}
|
|
619
|
+
connectedCallback() {
|
|
620
|
+
super.connectedCallback();
|
|
621
|
+
this.addEventListener("focusout", this.focusoutHandler);
|
|
622
|
+
this.addEventListener("contentchange", this.updateDisplayValue);
|
|
623
|
+
}
|
|
624
|
+
disconnectedCallback() {
|
|
625
|
+
this.removeEventListener("focusout", this.focusoutHandler);
|
|
626
|
+
this.removeEventListener("contentchange", this.updateDisplayValue);
|
|
627
|
+
super.disconnectedCallback();
|
|
628
|
+
}
|
|
629
|
+
/**
|
|
630
|
+
*
|
|
631
|
+
* @internal
|
|
632
|
+
*/
|
|
633
|
+
updateDisplayValue() {
|
|
634
|
+
if (this.collapsible) {
|
|
635
|
+
Observable.notify(this, "displayValue");
|
|
636
|
+
}
|
|
637
|
+
}
|
|
638
|
+
get displayValue() {
|
|
639
|
+
Observable.track(this, "displayValue");
|
|
640
|
+
return this.firstSelectedOption?.getAttribute("label") ?? this.firstSelectedOption?.text ?? this.placeholder ?? "";
|
|
641
|
+
}
|
|
642
|
+
setDefaultSelectedOption() {
|
|
643
|
+
const options = Array.from(this.children).filter(
|
|
644
|
+
Listbox.slottedOptionFilter
|
|
645
|
+
);
|
|
646
|
+
const selectedIndex = options.findIndex(
|
|
647
|
+
(el) => el.hasAttribute("selected") || el.selected || el.value === this.value
|
|
648
|
+
);
|
|
649
|
+
if (selectedIndex === -1 && !this.placeholderOption) {
|
|
650
|
+
this.selectedIndex = 0;
|
|
651
|
+
return;
|
|
652
|
+
}
|
|
653
|
+
if (selectedIndex !== -1 || this.placeholder !== "") {
|
|
654
|
+
this.selectedIndex = selectedIndex;
|
|
655
|
+
return;
|
|
656
|
+
}
|
|
657
|
+
}
|
|
658
|
+
/*
|
|
659
|
+
* @internal
|
|
660
|
+
*/
|
|
661
|
+
slottedOptionsChanged(prev, next) {
|
|
662
|
+
this.options.forEach((o) => {
|
|
663
|
+
const notifier = Observable.getNotifier(o);
|
|
664
|
+
notifier.unsubscribe(this, "value");
|
|
665
|
+
});
|
|
666
|
+
super.slottedOptionsChanged(prev, next);
|
|
667
|
+
this.options.forEach((o) => {
|
|
668
|
+
const notifier = Observable.getNotifier(o);
|
|
669
|
+
notifier.subscribe(this, "value");
|
|
670
|
+
});
|
|
671
|
+
this.setProxyOptions();
|
|
672
|
+
this.updateValue();
|
|
673
|
+
const scale = this.getAttribute("scale") || this.scale;
|
|
674
|
+
next.forEach((element) => {
|
|
675
|
+
if (scale) {
|
|
676
|
+
element.setAttribute("scale", scale);
|
|
677
|
+
element.scale = scale;
|
|
678
|
+
}
|
|
679
|
+
});
|
|
680
|
+
this.proxy.value = this.value;
|
|
681
|
+
this.validate();
|
|
682
|
+
}
|
|
683
|
+
formResetCallback() {
|
|
684
|
+
this.setProxyOptions();
|
|
685
|
+
super.setDefaultSelectedOption();
|
|
686
|
+
if (this.selectedIndex === -1) {
|
|
687
|
+
this.selectedIndex = 0;
|
|
688
|
+
}
|
|
689
|
+
if (this.placeholder) {
|
|
690
|
+
this.selectedIndex = -1;
|
|
691
|
+
}
|
|
692
|
+
}
|
|
44
693
|
}
|
|
45
694
|
__decorateClass([
|
|
46
|
-
|
|
47
|
-
],
|
|
695
|
+
observable
|
|
696
|
+
], Select.prototype, "activeIndex", 2);
|
|
697
|
+
// @ts-expect-error Type is incorrectly non-optional
|
|
48
698
|
__decorateClass([
|
|
49
699
|
attr({ mode: "boolean" })
|
|
50
|
-
],
|
|
700
|
+
], Select.prototype, "multiple", 2);
|
|
701
|
+
__decorateClass([
|
|
702
|
+
attr({ attribute: "open", mode: "boolean" })
|
|
703
|
+
], Select.prototype, "open", 2);
|
|
704
|
+
__decorateClass([
|
|
705
|
+
volatile
|
|
706
|
+
], Select.prototype, "collapsible", 1);
|
|
707
|
+
__decorateClass([
|
|
708
|
+
observable
|
|
709
|
+
], Select.prototype, "control", 2);
|
|
710
|
+
__decorateClass([
|
|
711
|
+
observable
|
|
712
|
+
], Select.prototype, "maxHeight", 2);
|
|
713
|
+
__decorateClass([
|
|
714
|
+
observable
|
|
715
|
+
], Select.prototype, "_anchor", 2);
|
|
51
716
|
__decorateClass([
|
|
52
|
-
attr(
|
|
53
|
-
],
|
|
717
|
+
attr()
|
|
718
|
+
], Select.prototype, "scale", 2);
|
|
54
719
|
__decorateClass([
|
|
55
720
|
attr
|
|
56
|
-
],
|
|
721
|
+
], Select.prototype, "appearance", 2);
|
|
57
722
|
__decorateClass([
|
|
58
|
-
attr
|
|
59
|
-
],
|
|
723
|
+
attr
|
|
724
|
+
], Select.prototype, "shape", 2);
|
|
60
725
|
__decorateClass([
|
|
61
|
-
attr({ mode: "boolean" })
|
|
62
|
-
],
|
|
726
|
+
attr({ mode: "boolean", attribute: "fixed-dropdown" })
|
|
727
|
+
], Select.prototype, "fixedDropdown", 2);
|
|
728
|
+
__decorateClass([
|
|
729
|
+
attr
|
|
730
|
+
], Select.prototype, "placeholder", 2);
|
|
731
|
+
__decorateClass([
|
|
732
|
+
observable
|
|
733
|
+
], Select.prototype, "placeholderOption", 2);
|
|
734
|
+
__decorateClass([
|
|
735
|
+
observable
|
|
736
|
+
], Select.prototype, "_feedbackWrapper", 2);
|
|
737
|
+
__decorateClass([
|
|
738
|
+
observable
|
|
739
|
+
], Select.prototype, "metaSlottedContent", 2);
|
|
63
740
|
|
|
64
|
-
const
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
741
|
+
const getStateClasses = ({
|
|
742
|
+
shape,
|
|
743
|
+
disabled,
|
|
744
|
+
appearance,
|
|
745
|
+
metaSlottedContent,
|
|
746
|
+
errorValidationMessage,
|
|
747
|
+
successText,
|
|
748
|
+
placeholder,
|
|
749
|
+
value,
|
|
750
|
+
scale
|
|
70
751
|
}) => classNames(
|
|
71
|
-
"
|
|
72
|
-
[`
|
|
73
|
-
[
|
|
74
|
-
["
|
|
75
|
-
["
|
|
76
|
-
["
|
|
752
|
+
["disabled", disabled],
|
|
753
|
+
[`appearance-${appearance}`, Boolean(appearance)],
|
|
754
|
+
[`shape-${shape}`, Boolean(shape)],
|
|
755
|
+
["has-meta", Boolean(metaSlottedContent?.length)],
|
|
756
|
+
["error", Boolean(errorValidationMessage)],
|
|
757
|
+
["success", !!successText],
|
|
758
|
+
["shows-placeholder", Boolean(placeholder) && !value],
|
|
759
|
+
[`size-${scale}`, Boolean(scale)]
|
|
77
760
|
);
|
|
78
|
-
function
|
|
79
|
-
|
|
761
|
+
function renderLabel() {
|
|
762
|
+
return html` <label
|
|
763
|
+
for="${(x) => x.multiple ? null : "control"}"
|
|
764
|
+
class="label"
|
|
765
|
+
id="label"
|
|
766
|
+
>
|
|
767
|
+
${(x) => x.label}
|
|
768
|
+
</label>`;
|
|
769
|
+
}
|
|
770
|
+
function renderPlaceholder(context) {
|
|
771
|
+
const optionTag = context.tagFor(ListboxOption);
|
|
772
|
+
return html`
|
|
773
|
+
<${optionTag} ${ref("placeholderOption")}
|
|
774
|
+
text="${(x) => x.placeholder}" hidden disabled>
|
|
775
|
+
</${optionTag}>`;
|
|
80
776
|
}
|
|
81
|
-
function
|
|
82
|
-
const
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
)}
|
|
777
|
+
function selectValue(context) {
|
|
778
|
+
const affixIconTemplate = affixIconTemplateFactory(context);
|
|
779
|
+
const chevronTemplate = chevronTemplateFactory(context);
|
|
780
|
+
return html` <div
|
|
781
|
+
class="control ${getStateClasses}"
|
|
782
|
+
${ref("_anchor")}
|
|
783
|
+
id="control"
|
|
784
|
+
?disabled="${(x) => x.disabled}"
|
|
785
|
+
>
|
|
786
|
+
<div class="selected-value">
|
|
787
|
+
${(x) => affixIconTemplate(x.icon, IconWrapper.Slot)}
|
|
788
|
+
<span class="text">${(x) => x.displayValue}</span>
|
|
789
|
+
<slot name="meta" ${slotted("metaSlottedContent")}></slot>
|
|
790
|
+
</div>
|
|
791
|
+
${chevronTemplate}
|
|
792
|
+
</div>`;
|
|
793
|
+
}
|
|
794
|
+
function setFixedDropdownVarWidth(x) {
|
|
795
|
+
return x.open && x.fixedDropdown ? `--_select-fixed-width: ${Math.round(x.getBoundingClientRect().width)}px` : null;
|
|
100
796
|
}
|
|
101
|
-
function
|
|
102
|
-
const
|
|
103
|
-
return html
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
797
|
+
function renderControl(context) {
|
|
798
|
+
const popupTag = context.tagFor(Popup);
|
|
799
|
+
return html`
|
|
800
|
+
${when((x) => x.label, renderLabel())}
|
|
801
|
+
<div class="control-wrapper">
|
|
802
|
+
${when((x) => !x.multiple, selectValue(context))}
|
|
803
|
+
<${popupTag} class="popup"
|
|
804
|
+
style="${setFixedDropdownVarWidth}"
|
|
805
|
+
?open="${(x) => x.collapsible ? x.open : true}"
|
|
806
|
+
:anchor="${(x) => x._anchor}"
|
|
807
|
+
placement="bottom-start"
|
|
808
|
+
strategy="${(x) => x.fixedDropdown ? null : "absolute"}">
|
|
809
|
+
<div class="listbox"
|
|
810
|
+
id="${(x) => x.listboxId}"
|
|
811
|
+
role="listbox"
|
|
812
|
+
aria-multiselectable="${(x) => x.multiple}"
|
|
813
|
+
aria-label="${(x) => x.multiple && !x.label && x.ariaLabel ? x.ariaLabel : null}"
|
|
814
|
+
aria-labelledby="${(x) => x.multiple && x.label ? "label" : null}"
|
|
815
|
+
?disabled="${(x) => x.disabled}"
|
|
816
|
+
?hidden="${(x) => x.collapsible ? !x.open : false}"
|
|
817
|
+
${ref("listbox")}>
|
|
818
|
+
${when((x) => x.placeholder, renderPlaceholder(context))}
|
|
819
|
+
<slot
|
|
820
|
+
${slotted({
|
|
821
|
+
filter: Listbox.slottedOptionFilter,
|
|
822
|
+
flatten: true,
|
|
823
|
+
property: "slottedOptions"
|
|
824
|
+
})}>
|
|
825
|
+
</slot>
|
|
826
|
+
</div>
|
|
827
|
+
</${popupTag}>
|
|
828
|
+
</div>
|
|
829
|
+
`;
|
|
120
830
|
}
|
|
121
|
-
|
|
122
|
-
return
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
831
|
+
function ifNotFromFeedback(handler) {
|
|
832
|
+
return (x, c) => {
|
|
833
|
+
if (!c.event.composedPath().includes(x._feedbackWrapper)) {
|
|
834
|
+
return handler(x, c.event);
|
|
835
|
+
}
|
|
836
|
+
return true;
|
|
837
|
+
};
|
|
838
|
+
}
|
|
839
|
+
const SelectTemplate = (context) => {
|
|
840
|
+
return html`
|
|
841
|
+
<template
|
|
842
|
+
class="base"
|
|
843
|
+
${applyHostSemantics({
|
|
844
|
+
role: "combobox",
|
|
845
|
+
ariaLabel: (x) => x.ariaLabel ?? x.label,
|
|
846
|
+
ariaHasPopup: (x) => x.collapsible ? "listbox" : "false",
|
|
847
|
+
ariaExpanded: (x) => x.open,
|
|
848
|
+
ariaDisabled: (x) => x.disabled
|
|
130
849
|
})}
|
|
131
|
-
|
|
132
|
-
|
|
850
|
+
aria-controls="${(x) => x.listboxId}"
|
|
851
|
+
aria-activedescendant="${(x) => x._activeDescendant}"
|
|
852
|
+
aria-describedby="${(x) => x._feedbackDescribedBy}"
|
|
853
|
+
tabindex="${(x) => !x.disabled ? "0" : null}"
|
|
854
|
+
@click="${ifNotFromFeedback((x, e) => x.clickHandler(e))}"
|
|
855
|
+
@focusin="${ifNotFromFeedback((x, e) => x.focusinHandler(e))}"
|
|
856
|
+
@focusout="${ifNotFromFeedback(
|
|
857
|
+
(x, e) => x.focusoutHandler(e)
|
|
858
|
+
)}"
|
|
859
|
+
@keydown="${ifNotFromFeedback((x, e) => {
|
|
860
|
+
x.open && handleEscapeKeyAndStopPropogation(e);
|
|
861
|
+
return x.keydownHandler(e);
|
|
862
|
+
})}"
|
|
863
|
+
@mousedown="${ifNotFromFeedback(
|
|
864
|
+
(x, e) => x.mousedownHandler(e)
|
|
865
|
+
)}"
|
|
133
866
|
>
|
|
134
|
-
${
|
|
135
|
-
<
|
|
136
|
-
|
|
137
|
-
|
|
867
|
+
${renderControl(context)}
|
|
868
|
+
<div class="feedback-wrapper" ${ref("_feedbackWrapper")}>
|
|
869
|
+
${(x) => x._getFeedbackTemplate(context)}
|
|
870
|
+
</div>
|
|
871
|
+
</template>
|
|
872
|
+
`;
|
|
138
873
|
};
|
|
139
874
|
|
|
140
|
-
const
|
|
141
|
-
"
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
[
|
|
875
|
+
const selectDefinition = defineVividComponent(
|
|
876
|
+
"select",
|
|
877
|
+
Select,
|
|
878
|
+
SelectTemplate,
|
|
879
|
+
[
|
|
880
|
+
popupDefinition,
|
|
881
|
+
iconDefinition,
|
|
882
|
+
listboxOptionDefinition,
|
|
883
|
+
feedbackMessageDefinition
|
|
884
|
+
],
|
|
145
885
|
{
|
|
146
|
-
styles
|
|
147
|
-
shadowOptions: {
|
|
148
|
-
delegatesFocus: true
|
|
149
|
-
}
|
|
886
|
+
styles
|
|
150
887
|
}
|
|
151
888
|
);
|
|
152
|
-
const
|
|
153
|
-
selectableBoxDefinition
|
|
154
|
-
);
|
|
889
|
+
const registerSelect = createRegisterFunction(selectDefinition);
|
|
155
890
|
|
|
156
|
-
export {
|
|
891
|
+
export { Select as S, registerSelect as r, selectDefinition as s };
|