@dialpad/dialtone-vue 3.219.0 → 3.220.0-next.2
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/dist/{attachment_carousel-CouFqFMw.js → attachment_carousel-1qxTI-NN.js} +5 -5
- package/dist/attachment_carousel-1qxTI-NN.js.map +1 -0
- package/dist/attachment_carousel-wnZS3vEt.cjs +2 -0
- package/dist/attachment_carousel-wnZS3vEt.cjs.map +1 -0
- package/dist/{combobox-DgClbLOg.js → combobox-BQBKrDTW.js} +36 -35
- package/dist/combobox-BQBKrDTW.js.map +1 -0
- package/dist/combobox-Da7wBh3G.cjs +3 -0
- package/dist/combobox-Da7wBh3G.cjs.map +1 -0
- package/dist/common/composables/useIndicatorAnimation.cjs +2 -0
- package/dist/common/composables/useIndicatorAnimation.cjs.map +1 -0
- package/dist/common/composables/useIndicatorAnimation.d.ts +18 -0
- package/dist/common/composables/useIndicatorAnimation.d.ts.map +1 -0
- package/dist/common/composables/useIndicatorAnimation.js +78 -0
- package/dist/common/composables/useIndicatorAnimation.js.map +1 -0
- package/dist/common/constants/index.cjs +1 -1
- package/dist/common/constants/index.cjs.map +1 -1
- package/dist/common/constants/index.d.ts +27 -21
- package/dist/common/constants/index.d.ts.map +1 -1
- package/dist/common/constants/index.js +25 -14
- package/dist/common/constants/index.js.map +1 -1
- package/dist/common/constants/sizes.cjs +2 -0
- package/dist/common/constants/sizes.cjs.map +1 -0
- package/dist/common/constants/sizes.d.ts +22 -0
- package/dist/common/constants/sizes.d.ts.map +1 -0
- package/dist/common/constants/sizes.js +19 -0
- package/dist/common/constants/sizes.js.map +1 -0
- package/dist/common/mixins/index.cjs +1 -1
- package/dist/common/mixins/index.d.ts +1 -0
- package/dist/common/mixins/index.js +2 -1
- package/dist/common/mixins/input.cjs +1 -1
- package/dist/common/mixins/input.cjs.map +1 -1
- package/dist/common/mixins/input.d.ts +27 -33
- package/dist/common/mixins/input.d.ts.map +1 -1
- package/dist/common/mixins/input.js +0 -8
- package/dist/common/mixins/input.js.map +1 -1
- package/dist/common/mixins/mode.cjs +2 -0
- package/dist/common/mixins/mode.cjs.map +1 -0
- package/dist/common/mixins/mode.d.ts +25 -0
- package/dist/common/mixins/mode.d.ts.map +1 -0
- package/dist/common/mixins/mode.js +62 -0
- package/dist/common/mixins/mode.js.map +1 -0
- package/dist/common/mode_constants.d.ts +37 -0
- package/dist/common/mode_constants.d.ts.map +1 -0
- package/dist/common/sr_only_close_button.vue.d.ts +53 -7
- package/dist/common/sr_only_close_button.vue.d.ts.map +1 -1
- package/dist/common/utils/index.cjs +1 -1
- package/dist/common/utils/index.cjs.map +1 -1
- package/dist/common/utils/index.d.ts +2 -8
- package/dist/common/utils/index.d.ts.map +1 -1
- package/dist/common/utils/index.js +79 -88
- package/dist/common/utils/index.js.map +1 -1
- package/dist/component-documentation.json +1 -1
- package/dist/components/avatar/avatar.vue.d.ts +85 -27
- package/dist/components/avatar/avatar.vue.d.ts.map +1 -1
- package/dist/components/avatar/avatar_constants.d.ts +86 -29
- package/dist/components/avatar/avatar_constants.d.ts.map +1 -1
- package/dist/components/avatar/index.d.ts +1 -1
- package/dist/components/badge/badge.vue.d.ts +1 -1
- package/dist/components/badge/badge.vue.d.ts.map +1 -1
- package/dist/components/badge/badge_constants.d.ts +1 -1
- package/dist/components/banner/banner.vue.d.ts +269 -34
- package/dist/components/banner/banner.vue.d.ts.map +1 -1
- package/dist/components/box/box.vue.d.ts +73 -0
- package/dist/components/box/box.vue.d.ts.map +1 -0
- package/dist/components/box/box_constants.d.ts +11 -0
- package/dist/components/box/box_constants.d.ts.map +1 -0
- package/dist/components/box/index.d.ts +3 -0
- package/dist/components/box/index.d.ts.map +1 -0
- package/dist/components/box/validators.d.ts +11 -0
- package/dist/components/box/validators.d.ts.map +1 -0
- package/dist/components/breadcrumbs/breadcrumb_item.vue.d.ts +26 -17
- package/dist/components/breadcrumbs/breadcrumb_item.vue.d.ts.map +1 -1
- package/dist/components/breadcrumbs/breadcrumbs.vue.d.ts +25 -16
- package/dist/components/button/button.vue.d.ts +53 -7
- package/dist/components/button/button.vue.d.ts.map +1 -1
- package/dist/components/button/button_constants.d.ts +29 -20
- package/dist/components/button/button_constants.d.ts.map +1 -1
- package/dist/components/card/card.vue.d.ts +0 -9
- package/dist/components/card/card.vue.d.ts.map +1 -1
- package/dist/components/checkbox/checkbox.vue.d.ts +183 -10
- package/dist/components/checkbox/checkbox.vue.d.ts.map +1 -1
- package/dist/components/checkbox/checkbox_constants.d.ts +2 -2
- package/dist/components/checkbox_group/checkbox_group.vue.d.ts +142 -0
- package/dist/components/chip/chip.vue.d.ts +62 -16
- package/dist/components/chip/chip.vue.d.ts.map +1 -1
- package/dist/components/chip/chip_constants.d.ts +24 -21
- package/dist/components/chip/chip_constants.d.ts.map +1 -1
- package/dist/components/codeblock/codeblock.vue.d.ts +25 -2
- package/dist/components/codeblock/codeblock.vue.d.ts.map +1 -1
- package/dist/components/codeblock/codeblock_constants.d.ts +9 -0
- package/dist/components/codeblock/codeblock_constants.d.ts.map +1 -0
- package/dist/components/collapsible/collapsible.vue.d.ts +53 -7
- package/dist/components/collapsible/collapsible.vue.d.ts.map +1 -1
- package/dist/components/combobox/combobox.vue.d.ts +113 -38
- package/dist/components/combobox/combobox.vue.d.ts.map +1 -1
- package/dist/components/combobox/combobox_empty-list.vue.d.ts +40 -7
- package/dist/components/combobox/combobox_empty-list.vue.d.ts.map +1 -1
- package/dist/components/combobox/combobox_loading-list.vue.d.ts +64 -22
- package/dist/components/combobox/combobox_loading-list.vue.d.ts.map +1 -1
- package/dist/components/combobox_multi_select/combobox_multi_select_constants.d.ts +16 -13
- package/dist/components/combobox_multi_select/combobox_multi_select_constants.d.ts.map +1 -1
- package/dist/components/combobox_with_popover/combobox_with_popover.vue.d.ts +399 -93
- package/dist/components/combobox_with_popover/combobox_with_popover.vue.d.ts.map +1 -1
- package/dist/components/datepicker/modules/month-year-picker.vue.d.ts.map +1 -1
- package/dist/components/dropdown/dropdown.vue.d.ts +175 -19
- package/dist/components/dropdown/dropdown.vue.d.ts.map +1 -1
- package/dist/components/emoji/emoji.vue.d.ts +24 -15
- package/dist/components/emoji_picker/emoji_picker.vue.d.ts +204 -22
- package/dist/components/emoji_picker/modules/emoji_search.vue.d.ts +204 -22
- package/dist/components/emoji_picker/modules/emoji_search.vue.d.ts.map +1 -1
- package/dist/components/emoji_picker/modules/emoji_tabset.vue.d.ts.map +1 -1
- package/dist/components/emoji_text_wrapper/emoji_text_wrapper.vue.d.ts +24 -15
- package/dist/components/emoji_text_wrapper/emoji_text_wrapper.vue.d.ts.map +1 -1
- package/dist/components/empty_state/empty_state.vue.d.ts.map +1 -1
- package/dist/components/empty_state/empty_state_constants.d.ts +52 -31
- package/dist/components/empty_state/empty_state_constants.d.ts.map +1 -1
- package/dist/components/filter_pill/filter_pill.vue.d.ts +4491 -0
- package/dist/components/filter_pill/filter_pill.vue.d.ts.map +1 -0
- package/dist/components/filter_pill/index.d.ts +2 -0
- package/dist/components/filter_pill/index.d.ts.map +1 -0
- package/dist/components/hovercard/hovercard.vue.d.ts +380 -41
- package/dist/components/hovercard/hovercard.vue.d.ts.map +1 -1
- package/dist/components/image_viewer/image_viewer.vue.d.ts +131 -14
- package/dist/components/image_viewer/image_viewer.vue.d.ts.map +1 -1
- package/dist/components/input/input.vue.d.ts +195 -19
- package/dist/components/input/input.vue.d.ts.map +1 -1
- package/dist/components/input/input_constants.d.ts +46 -48
- package/dist/components/input/input_constants.d.ts.map +1 -1
- package/dist/components/input_group/input_group.vue.d.ts +142 -0
- package/dist/components/input_group/input_group.vue.d.ts.map +1 -1
- package/dist/components/item_layout/item_layout.vue.d.ts +37 -6
- package/dist/components/item_layout/item_layout.vue.d.ts.map +1 -1
- package/dist/components/keyboard_shortcut/keyboard_shortcut.vue.d.ts +142 -0
- package/dist/components/keyboard_shortcut/keyboard_shortcut.vue.d.ts.map +1 -1
- package/dist/components/link/index.d.ts +1 -1
- package/dist/components/link/link.vue.d.ts +25 -6
- package/dist/components/link/link_constants.d.ts +4 -4
- package/dist/components/link/link_constants.d.ts.map +1 -1
- package/dist/components/list_item/list_item.vue.d.ts +40 -7
- package/dist/components/list_item/list_item.vue.d.ts.map +1 -1
- package/dist/components/modal/modal.vue.d.ts +292 -97
- package/dist/components/modal/modal.vue.d.ts.map +1 -1
- package/dist/components/modal/modal_constants.d.ts +7 -6
- package/dist/components/mode_island/index.d.ts +3 -0
- package/dist/components/mode_island/index.d.ts.map +1 -0
- package/dist/components/mode_island/mode_island.vue.d.ts +3 -0
- package/dist/components/mode_island/mode_island.vue.d.ts.map +1 -0
- package/dist/components/mode_island/mode_island_constants.d.ts +10 -0
- package/dist/components/mode_island/mode_island_constants.d.ts.map +1 -0
- package/dist/components/mode_island/utils.d.ts +12 -0
- package/dist/components/mode_island/utils.d.ts.map +1 -0
- package/dist/components/mode_island/validators.d.ts +6 -0
- package/dist/components/mode_island/validators.d.ts.map +1 -0
- package/dist/components/motion_text/motion_text_constants.d.ts +27 -23
- package/dist/components/motion_text/motion_text_constants.d.ts.map +1 -1
- package/dist/components/notice/notice.vue.d.ts +269 -34
- package/dist/components/notice/notice.vue.d.ts.map +1 -1
- package/dist/components/notice/notice_action.vue.d.ts +112 -20
- package/dist/components/notice/notice_action.vue.d.ts.map +1 -1
- package/dist/components/notice/notice_constants.d.ts.map +1 -1
- package/dist/components/notice/notice_content.vue.d.ts +144 -1
- package/dist/components/notice/notice_content.vue.d.ts.map +1 -1
- package/dist/components/notice/notice_icon.vue.d.ts +2 -2
- package/dist/components/notice/notice_icon.vue.d.ts.map +1 -1
- package/dist/components/pagination/pagination.vue.d.ts +56 -10
- package/dist/components/pagination/pagination.vue.d.ts.map +1 -1
- package/dist/components/popover/popover.vue.d.ts +163 -18
- package/dist/components/popover/popover.vue.d.ts.map +1 -1
- package/dist/components/popover/popover_header_footer.vue.d.ts +62 -7
- package/dist/components/popover/popover_header_footer.vue.d.ts.map +1 -1
- package/dist/components/radio/radio.vue.d.ts +178 -6
- package/dist/components/radio/radio.vue.d.ts.map +1 -1
- package/dist/components/radio/radio_constants.d.ts +2 -2
- package/dist/components/radio_group/radio_group.vue.d.ts +142 -0
- package/dist/components/rich_text_editor/extensions/channels/ChannelComponent.vue.d.ts +25 -6
- package/dist/components/rich_text_editor/extensions/channels/ChannelComponent.vue.d.ts.map +1 -1
- package/dist/components/rich_text_editor/extensions/channels/ChannelSuggestion.vue.d.ts.map +1 -1
- package/dist/components/rich_text_editor/extensions/emoji/EmojiComponent.vue.d.ts +24 -15
- package/dist/components/rich_text_editor/extensions/emoji/EmojiSuggestion.vue.d.ts +24 -15
- package/dist/components/rich_text_editor/extensions/mentions/MentionComponent.vue.d.ts +25 -6
- package/dist/components/rich_text_editor/extensions/mentions/MentionSuggestion.vue.d.ts +227 -27
- package/dist/components/rich_text_editor/extensions/mentions/MentionSuggestion.vue.d.ts.map +1 -1
- package/dist/components/rich_text_editor/extensions/slash_command/SlashCommandSuggestion.vue.d.ts +144 -1
- package/dist/components/rich_text_editor/extensions/slash_command/SlashCommandSuggestion.vue.d.ts.map +1 -1
- package/dist/components/rich_text_editor/extensions/suggestion/SuggestionList.vue.d.ts +40 -7
- package/dist/components/rich_text_editor/extensions/suggestion/SuggestionList.vue.d.ts.map +1 -1
- package/dist/components/rich_text_editor/extensions/variable/VariableComponent.vue.d.ts +411 -44
- package/dist/components/rich_text_editor/extensions/variable/VariableComponent.vue.d.ts.map +1 -1
- package/dist/components/rich_text_editor/rich_text_editor.vue.d.ts +59 -13
- package/dist/components/rich_text_editor/rich_text_editor.vue.d.ts.map +1 -1
- package/dist/components/root_layout/root_layout_constants.d.ts +2 -0
- package/dist/components/root_layout/root_layout_constants.d.ts.map +1 -1
- package/dist/components/scroller/modules/core_scroller.vue.d.ts +2 -2
- package/dist/components/scroller/modules/dynamic_scroller.vue.d.ts +12 -12
- package/dist/components/scroller/scroller.vue.d.ts +18 -18
- package/dist/components/segmented_control/index.d.ts +4 -0
- package/dist/components/segmented_control/index.d.ts.map +1 -0
- package/dist/components/segmented_control/segmented_control.vue.d.ts +226 -0
- package/dist/components/segmented_control/segmented_control.vue.d.ts.map +1 -0
- package/dist/components/segmented_control/segmented_control_constants.d.ts +41 -0
- package/dist/components/segmented_control/segmented_control_constants.d.ts.map +1 -0
- package/dist/components/segmented_control/segmented_control_item.vue.d.ts +35 -0
- package/dist/components/segmented_control/segmented_control_item.vue.d.ts.map +1 -0
- package/dist/components/select_menu/select_menu.vue.d.ts +189 -31
- package/dist/components/select_menu/select_menu.vue.d.ts.map +1 -1
- package/dist/components/select_menu/select_menu_constants.d.ts +14 -9
- package/dist/components/select_menu/select_menu_constants.d.ts.map +1 -1
- package/dist/components/skeleton/skeleton-list-item.vue.d.ts +13 -10
- package/dist/components/skeleton/skeleton-paragraph.vue.d.ts +3 -0
- package/dist/components/skeleton/skeleton-shape.vue.d.ts +5 -5
- package/dist/components/skeleton/skeleton-text.vue.d.ts +3 -0
- package/dist/components/skeleton/skeleton.vue.d.ts +24 -15
- package/dist/components/skeleton/skeleton_constants.d.ts +18 -13
- package/dist/components/skeleton/skeleton_constants.d.ts.map +1 -1
- package/dist/components/split_button/{split_button-omega.vue.d.ts → split_button-end.vue.d.ts} +64 -13
- package/dist/components/split_button/{split_button-omega.vue.d.ts.map → split_button-end.vue.d.ts.map} +1 -1
- package/dist/components/split_button/{split_button-alpha.vue.d.ts → split_button-start.vue.d.ts} +125 -11
- package/dist/components/split_button/split_button-start.vue.d.ts.map +1 -0
- package/dist/components/split_button/split_button.vue.d.ts +602 -78
- package/dist/components/split_button/split_button.vue.d.ts.map +1 -1
- package/dist/components/split_button/split_button_constants.d.ts +12 -7
- package/dist/components/split_button/split_button_constants.d.ts.map +1 -1
- package/dist/components/stack/stack_constants.d.ts.map +1 -1
- package/dist/components/tab/index.d.ts +1 -1
- package/dist/components/tab/tab.vue.d.ts +86 -11
- package/dist/components/tab/tab.vue.d.ts.map +1 -1
- package/dist/components/tab/tab_group.vue.d.ts +125 -10
- package/dist/components/tab/tab_group.vue.d.ts.map +1 -1
- package/dist/components/tab/tabs_constants.d.ts +23 -5
- package/dist/components/tab/tabs_constants.d.ts.map +1 -1
- package/dist/components/text/index.d.ts +3 -0
- package/dist/components/text/index.d.ts.map +1 -0
- package/dist/components/text/text.vue.d.ts +145 -0
- package/dist/components/text/text.vue.d.ts.map +1 -0
- package/dist/components/text/text_constants.d.ts +93 -0
- package/dist/components/text/text_constants.d.ts.map +1 -0
- package/dist/components/toast/layouts/toast_layout_alternate.vue.d.ts +264 -29
- package/dist/components/toast/layouts/toast_layout_alternate.vue.d.ts.map +1 -1
- package/dist/components/toast/layouts/toast_layout_alternate_icon.vue.d.ts +2 -2
- package/dist/components/toast/layouts/toast_layout_alternate_icon.vue.d.ts.map +1 -1
- package/dist/components/toast/layouts/toast_layout_default.vue.d.ts +267 -32
- package/dist/components/toast/layouts/toast_layout_default.vue.d.ts.map +1 -1
- package/dist/components/toast/toast.vue.d.ts +1125 -185
- package/dist/components/toast/toast.vue.d.ts.map +1 -1
- package/dist/components/toggle/toggle.vue.d.ts +19 -19
- package/dist/components/toggle/toggle.vue.d.ts.map +1 -1
- package/dist/components/toggle/toggle_constants.d.ts +6 -4
- package/dist/components/toggle/toggle_constants.d.ts.map +1 -1
- package/dist/components/tooltip/tooltip.vue.d.ts +31 -5
- package/dist/components/tooltip/tooltip.vue.d.ts.map +1 -1
- package/dist/{datepicker-LVDRC6Lf.js → datepicker-B2nhxiCg.js} +20 -24
- package/dist/datepicker-B2nhxiCg.js.map +1 -0
- package/dist/datepicker-CZrNL0Yn.cjs +2 -0
- package/dist/datepicker-CZrNL0Yn.cjs.map +1 -0
- package/dist/dialtone-vue.cjs +1 -1
- package/dist/dialtone-vue.css +1 -1
- package/dist/dialtone-vue.js +170 -150
- package/dist/directives/focusgroup_directive/focusgroup.d.ts +6 -0
- package/dist/directives/focusgroup_directive/focusgroup.d.ts.map +1 -0
- package/dist/directives/focusgroup_directive/focusgroup_constants.d.ts +74 -0
- package/dist/directives/focusgroup_directive/focusgroup_constants.d.ts.map +1 -0
- package/dist/directives/focusgroup_directive/focusgroup_utils.d.ts +15 -0
- package/dist/directives/focusgroup_directive/focusgroup_utils.d.ts.map +1 -0
- package/dist/directives/focusgroup_directive/index.d.ts +2 -0
- package/dist/directives/focusgroup_directive/index.d.ts.map +1 -0
- package/dist/directives/focustrap_directive/focustrap.d.ts +6 -0
- package/dist/directives/focustrap_directive/focustrap.d.ts.map +1 -0
- package/dist/directives/focustrap_directive/focustrap_constants.d.ts +7 -0
- package/dist/directives/focustrap_directive/focustrap_constants.d.ts.map +1 -0
- package/dist/directives/focustrap_directive/focustrap_utils.d.ts +5 -0
- package/dist/directives/focustrap_directive/focustrap_utils.d.ts.map +1 -0
- package/dist/directives/focustrap_directive/index.d.ts +2 -0
- package/dist/directives/focustrap_directive/index.d.ts.map +1 -0
- package/dist/directives/mode_directive/index.d.ts +2 -0
- package/dist/directives/mode_directive/index.d.ts.map +1 -0
- package/dist/directives/mode_directive/mode.d.ts +6 -0
- package/dist/directives/mode_directive/mode.d.ts.map +1 -0
- package/dist/directives/tooltip_directive/tooltip.d.ts.map +1 -1
- package/dist/emoji_picker-BQW4qRFg.cjs +2 -0
- package/dist/emoji_picker-BQW4qRFg.cjs.map +1 -0
- package/dist/{emoji_picker-tVHfpHDk.js → emoji_picker-BjgAohQy.js} +9 -8
- package/dist/emoji_picker-BjgAohQy.js.map +1 -0
- package/dist/index.d.ts +8 -0
- package/dist/lib/attachment-carousel/attachment-carousel.cjs +1 -1
- package/dist/lib/attachment-carousel/attachment-carousel.js +1 -1
- package/dist/lib/attachment-carousel/index.cjs +1 -1
- package/dist/lib/attachment-carousel/index.js +1 -1
- package/dist/lib/avatar/avatar-constants.cjs +1 -1
- package/dist/lib/avatar/avatar-constants.cjs.map +1 -1
- package/dist/lib/avatar/avatar-constants.js +111 -24
- package/dist/lib/avatar/avatar-constants.js.map +1 -1
- package/dist/lib/avatar/avatar.cjs +1 -1
- package/dist/lib/avatar/avatar.cjs.map +1 -1
- package/dist/lib/avatar/avatar.js +145 -84
- package/dist/lib/avatar/avatar.js.map +1 -1
- package/dist/lib/avatar/index.cjs +1 -1
- package/dist/lib/avatar/index.js +3 -3
- package/dist/lib/badge/badge-constants.cjs +1 -1
- package/dist/lib/badge/badge-constants.cjs.map +1 -1
- package/dist/lib/badge/badge-constants.js +1 -1
- package/dist/lib/badge/badge-constants.js.map +1 -1
- package/dist/lib/badge/badge.cjs +1 -1
- package/dist/lib/badge/badge.cjs.map +1 -1
- package/dist/lib/badge/badge.js +26 -14
- package/dist/lib/badge/badge.js.map +1 -1
- package/dist/lib/banner/banner.cjs +2 -2
- package/dist/lib/banner/banner.cjs.map +1 -1
- package/dist/lib/banner/banner.js +17 -16
- package/dist/lib/banner/banner.js.map +1 -1
- package/dist/lib/box/box-constants.cjs +2 -0
- package/dist/lib/box/box-constants.cjs.map +1 -0
- package/dist/lib/box/box-constants.js +103 -0
- package/dist/lib/box/box-constants.js.map +1 -0
- package/dist/lib/box/box.cjs +2 -0
- package/dist/lib/box/box.cjs.map +1 -0
- package/dist/lib/box/box.js +229 -0
- package/dist/lib/box/box.js.map +1 -0
- package/dist/lib/box/index.cjs +1 -0
- package/dist/lib/box/index.js +3 -0
- package/dist/lib/box/validators.cjs +2 -0
- package/dist/lib/box/validators.cjs.map +1 -0
- package/dist/lib/box/validators.js +7 -0
- package/dist/lib/box/validators.js.map +1 -0
- package/dist/lib/breadcrumbs/breadcrumb-item.cjs +1 -1
- package/dist/lib/breadcrumbs/breadcrumb-item.cjs.map +1 -1
- package/dist/lib/breadcrumbs/breadcrumb-item.js +29 -38
- package/dist/lib/breadcrumbs/breadcrumb-item.js.map +1 -1
- package/dist/lib/breadcrumbs/breadcrumbs.cjs +1 -1
- package/dist/lib/breadcrumbs/breadcrumbs.cjs.map +1 -1
- package/dist/lib/breadcrumbs/breadcrumbs.js +6 -6
- package/dist/lib/breadcrumbs/breadcrumbs.js.map +1 -1
- package/dist/lib/button/button-constants.cjs +1 -1
- package/dist/lib/button/button-constants.cjs.map +1 -1
- package/dist/lib/button/button-constants.js +17 -3
- package/dist/lib/button/button-constants.js.map +1 -1
- package/dist/lib/button/button.cjs +1 -1
- package/dist/lib/button/button.cjs.map +1 -1
- package/dist/lib/button/button.js +98 -15
- package/dist/lib/button/button.js.map +1 -1
- package/dist/lib/button-group/button-group.cjs.map +1 -1
- package/dist/lib/button-group/button-group.js.map +1 -1
- package/dist/lib/callbar-button/callbar-button.cjs +1 -1
- package/dist/lib/callbar-button/callbar-button.cjs.map +1 -1
- package/dist/lib/callbar-button/callbar-button.js +26 -27
- package/dist/lib/callbar-button/callbar-button.js.map +1 -1
- package/dist/lib/callbar-button-with-dropdown/callbar-button-with-dropdown.cjs +1 -1
- package/dist/lib/callbar-button-with-dropdown/callbar-button-with-dropdown.cjs.map +1 -1
- package/dist/lib/callbar-button-with-dropdown/callbar-button-with-dropdown.js +45 -36
- package/dist/lib/callbar-button-with-dropdown/callbar-button-with-dropdown.js.map +1 -1
- package/dist/lib/callbar-button-with-popover/callbar-button-with-popover.cjs +1 -1
- package/dist/lib/callbar-button-with-popover/callbar-button-with-popover.cjs.map +1 -1
- package/dist/lib/callbar-button-with-popover/callbar-button-with-popover.js +47 -38
- package/dist/lib/callbar-button-with-popover/callbar-button-with-popover.js.map +1 -1
- package/dist/lib/callbox/callbox.cjs +1 -1
- package/dist/lib/callbox/callbox.cjs.map +1 -1
- package/dist/lib/callbox/callbox.js +4 -4
- package/dist/lib/callbox/callbox.js.map +1 -1
- package/dist/lib/card/card.cjs +1 -1
- package/dist/lib/card/card.cjs.map +1 -1
- package/dist/lib/card/card.js +10 -18
- package/dist/lib/card/card.js.map +1 -1
- package/dist/lib/checkbox/checkbox-constants.cjs +1 -1
- package/dist/lib/checkbox/checkbox-constants.cjs.map +1 -1
- package/dist/lib/checkbox/checkbox-constants.js +2 -2
- package/dist/lib/checkbox/checkbox-constants.js.map +1 -1
- package/dist/lib/checkbox/checkbox.cjs +1 -1
- package/dist/lib/checkbox/checkbox.cjs.map +1 -1
- package/dist/lib/checkbox/checkbox.js +79 -28
- package/dist/lib/checkbox/checkbox.js.map +1 -1
- package/dist/lib/checkbox-group/checkboxes-decorator.cjs +1 -1
- package/dist/lib/checkbox-group/checkboxes-decorator.cjs.map +1 -1
- package/dist/lib/checkbox-group/checkboxes-decorator.js +0 -1
- package/dist/lib/checkbox-group/checkboxes-decorator.js.map +1 -1
- package/dist/lib/chip/chip-constants.cjs +1 -1
- package/dist/lib/chip/chip-constants.cjs.map +1 -1
- package/dist/lib/chip/chip-constants.js +9 -0
- package/dist/lib/chip/chip-constants.js.map +1 -1
- package/dist/lib/chip/chip.cjs +1 -1
- package/dist/lib/chip/chip.cjs.map +1 -1
- package/dist/lib/chip/chip.js +13 -13
- package/dist/lib/chip/chip.js.map +1 -1
- package/dist/lib/codeblock/codeblock-constants.cjs +2 -0
- package/dist/lib/codeblock/codeblock-constants.cjs.map +1 -0
- package/dist/lib/codeblock/codeblock-constants.js +20 -0
- package/dist/lib/codeblock/codeblock-constants.js.map +1 -0
- package/dist/lib/codeblock/codeblock.cjs +1 -2
- package/dist/lib/codeblock/codeblock.cjs.map +1 -1
- package/dist/lib/codeblock/codeblock.js +25 -14
- package/dist/lib/codeblock/codeblock.js.map +1 -1
- package/dist/lib/collapsible/collapsible.cjs +1 -1
- package/dist/lib/collapsible/collapsible.cjs.map +1 -1
- package/dist/lib/collapsible/collapsible.js +1 -1
- package/dist/lib/collapsible/collapsible.js.map +1 -1
- package/dist/lib/combobox/combobox.cjs +1 -1
- package/dist/lib/combobox/combobox.js +1 -1
- package/dist/lib/combobox/index.cjs +1 -1
- package/dist/lib/combobox/index.js +1 -1
- package/dist/lib/combobox-multi-select/combobox-multi-select-constants.cjs +1 -1
- package/dist/lib/combobox-multi-select/combobox-multi-select-constants.cjs.map +1 -1
- package/dist/lib/combobox-multi-select/combobox-multi-select-constants.js +6 -0
- package/dist/lib/combobox-multi-select/combobox-multi-select-constants.js.map +1 -1
- package/dist/lib/combobox-multi-select/combobox-multi-select.cjs +1 -1
- package/dist/lib/combobox-multi-select/combobox-multi-select.cjs.map +1 -1
- package/dist/lib/combobox-multi-select/combobox-multi-select.js +34 -33
- package/dist/lib/combobox-multi-select/combobox-multi-select.js.map +1 -1
- package/dist/lib/combobox-with-popover/combobox-with-popover.cjs +1 -1
- package/dist/lib/combobox-with-popover/combobox-with-popover.cjs.map +1 -1
- package/dist/lib/combobox-with-popover/combobox-with-popover.js +51 -46
- package/dist/lib/combobox-with-popover/combobox-with-popover.js.map +1 -1
- package/dist/lib/contact-centers-row/contact-centers-row.cjs +1 -1
- package/dist/lib/contact-centers-row/contact-centers-row.cjs.map +1 -1
- package/dist/lib/contact-centers-row/contact-centers-row.js +51 -45
- package/dist/lib/contact-centers-row/contact-centers-row.js.map +1 -1
- package/dist/lib/contact-info/contact-info.cjs +1 -1
- package/dist/lib/contact-info/contact-info.cjs.map +1 -1
- package/dist/lib/contact-info/contact-info.js +8 -8
- package/dist/lib/contact-info/contact-info.js.map +1 -1
- package/dist/lib/contact-row/contact-row.cjs +1 -1
- package/dist/lib/contact-row/contact-row.cjs.map +1 -1
- package/dist/lib/contact-row/contact-row.js +3 -3
- package/dist/lib/contact-row/contact-row.js.map +1 -1
- package/dist/lib/datepicker/datepicker.cjs +1 -1
- package/dist/lib/datepicker/datepicker.js +1 -1
- package/dist/lib/datepicker/index.cjs +1 -1
- package/dist/lib/datepicker/index.js +1 -1
- package/dist/lib/description-list/description-list.cjs +1 -1
- package/dist/lib/description-list/description-list.cjs.map +1 -1
- package/dist/lib/description-list/description-list.js +1 -1
- package/dist/lib/description-list/description-list.js.map +1 -1
- package/dist/lib/dropdown/dropdown-constants.cjs +1 -1
- package/dist/lib/dropdown/dropdown-constants.cjs.map +1 -1
- package/dist/lib/dropdown/dropdown-constants.js +2 -2
- package/dist/lib/dropdown/dropdown-constants.js.map +1 -1
- package/dist/lib/dropdown/dropdown-list.cjs +1 -1
- package/dist/lib/dropdown/dropdown-list.cjs.map +1 -1
- package/dist/lib/dropdown/dropdown-list.js +28 -16
- package/dist/lib/dropdown/dropdown-list.js.map +1 -1
- package/dist/lib/dropdown/dropdown.cjs +1 -1
- package/dist/lib/dropdown/dropdown.cjs.map +1 -1
- package/dist/lib/dropdown/dropdown.js +30 -26
- package/dist/lib/dropdown/dropdown.js.map +1 -1
- package/dist/lib/editor/EditorToolbarButton.cjs +1 -1
- package/dist/lib/editor/EditorToolbarButton.cjs.map +1 -1
- package/dist/lib/editor/EditorToolbarButton.js +1 -1
- package/dist/lib/editor/EditorToolbarButton.js.map +1 -1
- package/dist/lib/editor/EditorToolbarDropdownButton.cjs +1 -1
- package/dist/lib/editor/EditorToolbarDropdownButton.cjs.map +1 -1
- package/dist/lib/editor/EditorToolbarDropdownButton.js +1 -1
- package/dist/lib/editor/EditorToolbarDropdownButton.js.map +1 -1
- package/dist/lib/editor/EditorToolbarPopoverButton.cjs +1 -1
- package/dist/lib/editor/EditorToolbarPopoverButton.cjs.map +1 -1
- package/dist/lib/editor/EditorToolbarPopoverButton.js +1 -1
- package/dist/lib/editor/EditorToolbarPopoverButton.js.map +1 -1
- package/dist/lib/editor/editor.cjs +1 -1
- package/dist/lib/editor/editor.cjs.map +1 -1
- package/dist/lib/editor/editor.js +134 -135
- package/dist/lib/editor/editor.js.map +1 -1
- package/dist/lib/emoji-picker/emoji-picker.cjs +1 -1
- package/dist/lib/emoji-picker/emoji-picker.js +1 -1
- package/dist/lib/emoji-picker/index.cjs +1 -1
- package/dist/lib/emoji-picker/index.js +1 -1
- package/dist/lib/emoji-row/emoji-row.cjs +1 -1
- package/dist/lib/emoji-row/emoji-row.cjs.map +1 -1
- package/dist/lib/emoji-row/emoji-row.js +1 -1
- package/dist/lib/emoji-row/emoji-row.js.map +1 -1
- package/dist/lib/emoji-text-wrapper/emoji-text-wrapper.cjs.map +1 -1
- package/dist/lib/emoji-text-wrapper/emoji-text-wrapper.js.map +1 -1
- package/dist/lib/empty-state/empty-state-constants.cjs +1 -1
- package/dist/lib/empty-state/empty-state-constants.cjs.map +1 -1
- package/dist/lib/empty-state/empty-state-constants.js +37 -9
- package/dist/lib/empty-state/empty-state-constants.js.map +1 -1
- package/dist/lib/empty-state/empty-state.cjs +1 -1
- package/dist/lib/empty-state/empty-state.cjs.map +1 -1
- package/dist/lib/empty-state/empty-state.js +46 -26
- package/dist/lib/empty-state/empty-state.js.map +1 -1
- package/dist/lib/feed-item-pill/feed-item-pill.cjs +1 -1
- package/dist/lib/feed-item-pill/feed-item-pill.cjs.map +1 -1
- package/dist/lib/feed-item-pill/feed-item-pill.js +40 -42
- package/dist/lib/feed-item-pill/feed-item-pill.js.map +1 -1
- package/dist/lib/feed-item-row/feed-item-row.cjs +1 -1
- package/dist/lib/feed-item-row/feed-item-row.cjs.map +1 -1
- package/dist/lib/feed-item-row/feed-item-row.js +3 -3
- package/dist/lib/feed-item-row/feed-item-row.js.map +1 -1
- package/dist/lib/filter-pill/filter-pill.cjs +2 -0
- package/dist/lib/filter-pill/filter-pill.cjs.map +1 -0
- package/dist/lib/filter-pill/filter-pill.js +433 -0
- package/dist/lib/filter-pill/filter-pill.js.map +1 -0
- package/dist/lib/filter-pill/index.cjs +1 -0
- package/dist/lib/filter-pill/index.js +2 -0
- package/dist/lib/focusgroup-directive/focusgroup-constants.cjs +2 -0
- package/dist/lib/focusgroup-directive/focusgroup-constants.cjs.map +1 -0
- package/dist/lib/focusgroup-directive/focusgroup-constants.js +77 -0
- package/dist/lib/focusgroup-directive/focusgroup-constants.js.map +1 -0
- package/dist/lib/focusgroup-directive/focusgroup-utils.cjs +2 -0
- package/dist/lib/focusgroup-directive/focusgroup-utils.cjs.map +1 -0
- package/dist/lib/focusgroup-directive/focusgroup-utils.js +33 -0
- package/dist/lib/focusgroup-directive/focusgroup-utils.js.map +1 -0
- package/dist/lib/focusgroup-directive/focusgroup.cjs +2 -0
- package/dist/lib/focusgroup-directive/focusgroup.cjs.map +1 -0
- package/dist/lib/focusgroup-directive/focusgroup.js +143 -0
- package/dist/lib/focusgroup-directive/focusgroup.js.map +1 -0
- package/dist/lib/focusgroup-directive/index.cjs +1 -0
- package/dist/lib/focusgroup-directive/index.js +2 -0
- package/dist/lib/focustrap-directive/focustrap-constants.cjs +2 -0
- package/dist/lib/focustrap-directive/focustrap-constants.cjs.map +1 -0
- package/dist/lib/focustrap-directive/focustrap-constants.js +10 -0
- package/dist/lib/focustrap-directive/focustrap-constants.js.map +1 -0
- package/dist/lib/focustrap-directive/focustrap-utils.cjs +2 -0
- package/dist/lib/focustrap-directive/focustrap-utils.cjs.map +1 -0
- package/dist/lib/focustrap-directive/focustrap-utils.js +19 -0
- package/dist/lib/focustrap-directive/focustrap-utils.js.map +1 -0
- package/dist/lib/focustrap-directive/focustrap.cjs +2 -0
- package/dist/lib/focustrap-directive/focustrap.cjs.map +1 -0
- package/dist/lib/focustrap-directive/focustrap.js +96 -0
- package/dist/lib/focustrap-directive/focustrap.js.map +1 -0
- package/dist/lib/focustrap-directive/index.cjs +1 -0
- package/dist/lib/focustrap-directive/index.js +2 -0
- package/dist/lib/general-row/general-row.cjs +1 -1
- package/dist/lib/general-row/general-row.cjs.map +1 -1
- package/dist/lib/general-row/general-row.js +105 -61
- package/dist/lib/general-row/general-row.js.map +1 -1
- package/dist/lib/general-row/leftbar-general-row-icon.cjs +1 -1
- package/dist/lib/general-row/leftbar-general-row-icon.cjs.map +1 -1
- package/dist/lib/general-row/leftbar-general-row-icon.js +1 -1
- package/dist/lib/general-row/leftbar-general-row-icon.js.map +1 -1
- package/dist/lib/group-row/group-row.cjs +1 -1
- package/dist/lib/group-row/group-row.cjs.map +1 -1
- package/dist/lib/group-row/group-row.js +2 -2
- package/dist/lib/group-row/group-row.js.map +1 -1
- package/dist/lib/grouped-chip/grouped-chip.cjs +1 -1
- package/dist/lib/grouped-chip/grouped-chip.cjs.map +1 -1
- package/dist/lib/grouped-chip/grouped-chip.js +9 -9
- package/dist/lib/grouped-chip/grouped-chip.js.map +1 -1
- package/dist/lib/hovercard/hovercard.cjs +1 -1
- package/dist/lib/hovercard/hovercard.cjs.map +1 -1
- package/dist/lib/hovercard/hovercard.js +28 -24
- package/dist/lib/hovercard/hovercard.js.map +1 -1
- package/dist/lib/icon/icon.cjs +1 -1
- package/dist/lib/icon/icon.cjs.map +1 -1
- package/dist/lib/icon/icon.js +1 -1
- package/dist/lib/icon/icon.js.map +1 -1
- package/dist/lib/illustration/illustration.cjs +1 -1
- package/dist/lib/illustration/illustration.cjs.map +1 -1
- package/dist/lib/illustration/illustration.js +1 -1
- package/dist/lib/illustration/illustration.js.map +1 -1
- package/dist/lib/image-viewer/image-viewer.cjs +1 -1
- package/dist/lib/image-viewer/image-viewer.cjs.map +1 -1
- package/dist/lib/image-viewer/image-viewer.js +32 -31
- package/dist/lib/image-viewer/image-viewer.js.map +1 -1
- package/dist/lib/input/input-constants.cjs +1 -1
- package/dist/lib/input/input-constants.cjs.map +1 -1
- package/dist/lib/input/input-constants.js +25 -11
- package/dist/lib/input/input-constants.js.map +1 -1
- package/dist/lib/input/input.cjs +1 -1
- package/dist/lib/input/input.cjs.map +1 -1
- package/dist/lib/input/input.js +161 -79
- package/dist/lib/input/input.js.map +1 -1
- package/dist/lib/input-group/input-group.cjs +1 -1
- package/dist/lib/input-group/input-group.cjs.map +1 -1
- package/dist/lib/input-group/input-group.js +25 -15
- package/dist/lib/input-group/input-group.js.map +1 -1
- package/dist/lib/item-layout/item-layout.cjs +3 -3
- package/dist/lib/item-layout/item-layout.cjs.map +1 -1
- package/dist/lib/item-layout/item-layout.js +35 -12
- package/dist/lib/item-layout/item-layout.js.map +1 -1
- package/dist/lib/ivr-node/ivr-node.cjs +1 -1
- package/dist/lib/ivr-node/ivr-node.cjs.map +1 -1
- package/dist/lib/ivr-node/ivr-node.js +1 -1
- package/dist/lib/ivr-node/ivr-node.js.map +1 -1
- package/dist/lib/keyboard-shortcut/keyboard-shortcut.cjs +1 -1
- package/dist/lib/keyboard-shortcut/keyboard-shortcut.cjs.map +1 -1
- package/dist/lib/keyboard-shortcut/keyboard-shortcut.js +48 -38
- package/dist/lib/keyboard-shortcut/keyboard-shortcut.js.map +1 -1
- package/dist/lib/kitchen-sink/kitchen-sink-view.cjs +2 -0
- package/dist/lib/kitchen-sink/kitchen-sink-view.cjs.map +1 -0
- package/dist/lib/kitchen-sink/kitchen-sink-view.js +205 -0
- package/dist/lib/kitchen-sink/kitchen-sink-view.js.map +1 -0
- package/dist/lib/link/index.cjs +1 -1
- package/dist/lib/link/index.js +2 -2
- package/dist/lib/link/link-constants.cjs +1 -1
- package/dist/lib/link/link-constants.cjs.map +1 -1
- package/dist/lib/link/link-constants.js +7 -7
- package/dist/lib/link/link-constants.js.map +1 -1
- package/dist/lib/link/link.cjs +1 -1
- package/dist/lib/link/link.cjs.map +1 -1
- package/dist/lib/link/link.js +17 -2
- package/dist/lib/link/link.js.map +1 -1
- package/dist/lib/list-item/list-item.cjs +1 -1
- package/dist/lib/list-item/list-item.cjs.map +1 -1
- package/dist/lib/list-item/list-item.js +9 -5
- package/dist/lib/list-item/list-item.js.map +1 -1
- package/dist/lib/list-item-group/list-item-group.cjs +1 -1
- package/dist/lib/list-item-group/list-item-group.cjs.map +1 -1
- package/dist/lib/list-item-group/list-item-group.js +1 -1
- package/dist/lib/list-item-group/list-item-group.js.map +1 -1
- package/dist/lib/message-input/index.cjs +1 -1
- package/dist/lib/message-input/index.js +1 -1
- package/dist/lib/message-input/message-input-button.cjs +1 -1
- package/dist/lib/message-input/message-input-button.cjs.map +1 -1
- package/dist/lib/message-input/message-input-button.js +1 -1
- package/dist/lib/message-input/message-input-button.js.map +1 -1
- package/dist/lib/message-input/message-input-link.cjs +1 -1
- package/dist/lib/message-input/message-input-link.cjs.map +1 -1
- package/dist/lib/message-input/message-input-link.js +9 -9
- package/dist/lib/message-input/message-input-link.js.map +1 -1
- package/dist/lib/message-input/message-input-topbar.cjs +1 -1
- package/dist/lib/message-input/message-input-topbar.cjs.map +1 -1
- package/dist/lib/message-input/message-input-topbar.js +2 -2
- package/dist/lib/message-input/message-input-topbar.js.map +1 -1
- package/dist/lib/message-input/message-input.cjs +1 -1
- package/dist/lib/message-input/message-input.js +1 -1
- package/dist/lib/modal/modal-constants.cjs +1 -1
- package/dist/lib/modal/modal-constants.cjs.map +1 -1
- package/dist/lib/modal/modal-constants.js +3 -3
- package/dist/lib/modal/modal-constants.js.map +1 -1
- package/dist/lib/modal/modal.cjs +1 -1
- package/dist/lib/modal/modal.cjs.map +1 -1
- package/dist/lib/modal/modal.js +158 -157
- package/dist/lib/modal/modal.js.map +1 -1
- package/dist/lib/mode-directive/index.cjs +1 -0
- package/dist/lib/mode-directive/index.js +2 -0
- package/dist/lib/mode-directive/mode.cjs +2 -0
- package/dist/lib/mode-directive/mode.cjs.map +1 -0
- package/dist/lib/mode-directive/mode.js +67 -0
- package/dist/lib/mode-directive/mode.js.map +1 -0
- package/dist/lib/mode-island/index.cjs +1 -0
- package/dist/lib/mode-island/index.js +3 -0
- package/dist/lib/mode-island/mode-island-constants.cjs +2 -0
- package/dist/lib/mode-island/mode-island-constants.cjs.map +1 -0
- package/dist/lib/mode-island/mode-island-constants.js +10 -0
- package/dist/lib/mode-island/mode-island-constants.js.map +1 -0
- package/dist/lib/mode-island/mode-island.cjs +2 -0
- package/dist/lib/mode-island/mode-island.cjs.map +1 -0
- package/dist/lib/mode-island/mode-island.js +102 -0
- package/dist/lib/mode-island/mode-island.js.map +1 -0
- package/dist/lib/mode-island/utils.cjs +2 -0
- package/dist/lib/mode-island/utils.cjs.map +1 -0
- package/dist/lib/mode-island/utils.js +28 -0
- package/dist/lib/mode-island/utils.js.map +1 -0
- package/dist/lib/mode-island/validators.cjs +2 -0
- package/dist/lib/mode-island/validators.cjs.map +1 -0
- package/dist/lib/mode-island/validators.js +10 -0
- package/dist/lib/mode-island/validators.js.map +1 -0
- package/dist/lib/motion-text/motion-text-constants.cjs +1 -1
- package/dist/lib/motion-text/motion-text-constants.cjs.map +1 -1
- package/dist/lib/motion-text/motion-text-constants.js +18 -6
- package/dist/lib/motion-text/motion-text-constants.js.map +1 -1
- package/dist/lib/motion-text/motion-text.cjs +1 -1
- package/dist/lib/motion-text/motion-text.cjs.map +1 -1
- package/dist/lib/motion-text/motion-text.js +5 -7
- package/dist/lib/motion-text/motion-text.js.map +1 -1
- package/dist/lib/notice/notice-action.cjs +1 -1
- package/dist/lib/notice/notice-action.cjs.map +1 -1
- package/dist/lib/notice/notice-action.js +14 -14
- package/dist/lib/notice/notice-action.js.map +1 -1
- package/dist/lib/notice/notice-constants.cjs +1 -1
- package/dist/lib/notice/notice-constants.cjs.map +1 -1
- package/dist/lib/notice/notice-constants.js +2 -2
- package/dist/lib/notice/notice-constants.js.map +1 -1
- package/dist/lib/notice/notice-content.cjs +1 -1
- package/dist/lib/notice/notice-content.cjs.map +1 -1
- package/dist/lib/notice/notice-content.js +29 -12
- package/dist/lib/notice/notice-content.js.map +1 -1
- package/dist/lib/notice/notice-icon.cjs +1 -1
- package/dist/lib/notice/notice-icon.cjs.map +1 -1
- package/dist/lib/notice/notice-icon.js +4 -4
- package/dist/lib/notice/notice-icon.js.map +1 -1
- package/dist/lib/notice/notice.cjs +1 -1
- package/dist/lib/notice/notice.cjs.map +1 -1
- package/dist/lib/notice/notice.js +17 -16
- package/dist/lib/notice/notice.js.map +1 -1
- package/dist/lib/pagination/pagination.cjs +1 -1
- package/dist/lib/pagination/pagination.cjs.map +1 -1
- package/dist/lib/pagination/pagination.js +13 -12
- package/dist/lib/pagination/pagination.js.map +1 -1
- package/dist/lib/popover/popover-constants.cjs +1 -1
- package/dist/lib/popover/popover-constants.cjs.map +1 -1
- package/dist/lib/popover/popover-constants.js +6 -6
- package/dist/lib/popover/popover-constants.js.map +1 -1
- package/dist/lib/popover/popover-header-footer.cjs +1 -1
- package/dist/lib/popover/popover-header-footer.cjs.map +1 -1
- package/dist/lib/popover/popover-header-footer.js +11 -3
- package/dist/lib/popover/popover-header-footer.js.map +1 -1
- package/dist/lib/popover/popover.cjs +1 -1
- package/dist/lib/popover/popover.cjs.map +1 -1
- package/dist/lib/popover/popover.js +78 -58
- package/dist/lib/popover/popover.js.map +1 -1
- package/dist/lib/radio/radio-constants.cjs +1 -1
- package/dist/lib/radio/radio-constants.cjs.map +1 -1
- package/dist/lib/radio/radio-constants.js +2 -2
- package/dist/lib/radio/radio-constants.js.map +1 -1
- package/dist/lib/radio/radio.cjs +1 -1
- package/dist/lib/radio/radio.cjs.map +1 -1
- package/dist/lib/radio/radio.js +94 -31
- package/dist/lib/radio/radio.js.map +1 -1
- package/dist/lib/resizable/index.cjs +1 -1
- package/dist/lib/resizable/index.js +3 -3
- package/dist/lib/resizable/resizable-handle.cjs +1 -1
- package/dist/lib/resizable/resizable-handle.js +1 -1
- package/dist/lib/resizable/resizable-panel.cjs +1 -1
- package/dist/lib/resizable/resizable-panel.js +1 -1
- package/dist/lib/resizable/resizable.cjs +1 -1
- package/dist/lib/resizable/resizable.js +1 -1
- package/dist/lib/rich-text-editor/index.cjs +1 -1
- package/dist/lib/rich-text-editor/index.js +1 -1
- package/dist/lib/rich-text-editor/markdownRenderer.cjs +1 -1
- package/dist/lib/rich-text-editor/markdownRenderer.js +1 -1
- package/dist/lib/rich-text-editor/rich-text-editor.cjs +1 -1
- package/dist/lib/rich-text-editor/rich-text-editor.js +1 -1
- package/dist/lib/root-layout/root-layout-constants.cjs +1 -1
- package/dist/lib/root-layout/root-layout-constants.cjs.map +1 -1
- package/dist/lib/root-layout/root-layout-constants.js +2 -0
- package/dist/lib/root-layout/root-layout-constants.js.map +1 -1
- package/dist/lib/root-layout/root-layout.cjs +1 -1
- package/dist/lib/root-layout/root-layout.cjs.map +1 -1
- package/dist/lib/root-layout/root-layout.js +2 -2
- package/dist/lib/root-layout/root-layout.js.map +1 -1
- package/dist/lib/scroller/index.cjs +1 -1
- package/dist/lib/scroller/index.js +1 -1
- package/dist/lib/scroller/scroller.cjs +1 -1
- package/dist/lib/scroller/scroller.js +1 -1
- package/dist/lib/segmented-control/index.cjs +1 -0
- package/dist/lib/segmented-control/index.js +4 -0
- package/dist/lib/segmented-control/segmented-control-constants.cjs +2 -0
- package/dist/lib/segmented-control/segmented-control-constants.cjs.map +1 -0
- package/dist/lib/segmented-control/segmented-control-constants.js +41 -0
- package/dist/lib/segmented-control/segmented-control-constants.js.map +1 -0
- package/dist/lib/segmented-control/segmented-control-item.cjs +2 -0
- package/dist/lib/segmented-control/segmented-control-item.cjs.map +1 -0
- package/dist/lib/segmented-control/segmented-control-item.js +104 -0
- package/dist/lib/segmented-control/segmented-control-item.js.map +1 -0
- package/dist/lib/segmented-control/segmented-control.cjs +2 -0
- package/dist/lib/segmented-control/segmented-control.cjs.map +1 -0
- package/dist/lib/segmented-control/segmented-control.js +204 -0
- package/dist/lib/segmented-control/segmented-control.js.map +1 -0
- package/dist/lib/select-menu/select-menu-constants.cjs +1 -1
- package/dist/lib/select-menu/select-menu-constants.cjs.map +1 -1
- package/dist/lib/select-menu/select-menu-constants.js +7 -2
- package/dist/lib/select-menu/select-menu-constants.js.map +1 -1
- package/dist/lib/select-menu/select-menu.cjs +1 -1
- package/dist/lib/select-menu/select-menu.cjs.map +1 -1
- package/dist/lib/select-menu/select-menu.js +117 -58
- package/dist/lib/select-menu/select-menu.js.map +1 -1
- package/dist/lib/settings-menu-button/settings-menu-button.cjs +1 -1
- package/dist/lib/settings-menu-button/settings-menu-button.cjs.map +1 -1
- package/dist/lib/settings-menu-button/settings-menu-button.js +5 -5
- package/dist/lib/settings-menu-button/settings-menu-button.js.map +1 -1
- package/dist/lib/skeleton/skeleton-constants.cjs +1 -1
- package/dist/lib/skeleton/skeleton-constants.cjs.map +1 -1
- package/dist/lib/skeleton/skeleton-constants.js +10 -2
- package/dist/lib/skeleton/skeleton-constants.js.map +1 -1
- package/dist/lib/skeleton/skeleton-list-item.cjs +1 -1
- package/dist/lib/skeleton/skeleton-list-item.cjs.map +1 -1
- package/dist/lib/skeleton/skeleton-list-item.js +2 -2
- package/dist/lib/skeleton/skeleton-list-item.js.map +1 -1
- package/dist/lib/skeleton/skeleton-shape.cjs +1 -1
- package/dist/lib/skeleton/skeleton-shape.cjs.map +1 -1
- package/dist/lib/skeleton/skeleton-shape.js +3 -3
- package/dist/lib/skeleton/skeleton-shape.js.map +1 -1
- package/dist/lib/split-button/split-button-constants.cjs +1 -1
- package/dist/lib/split-button/split-button-constants.cjs.map +1 -1
- package/dist/lib/split-button/split-button-constants.js +5 -0
- package/dist/lib/split-button/split-button-constants.js.map +1 -1
- package/dist/lib/split-button/split-button-end.cjs +2 -0
- package/dist/lib/split-button/split-button-end.cjs.map +1 -0
- package/dist/lib/split-button/{split-button-omega.js → split-button-end.js} +9 -9
- package/dist/lib/split-button/split-button-end.js.map +1 -0
- package/dist/lib/split-button/split-button-start.cjs +2 -0
- package/dist/lib/split-button/split-button-start.cjs.map +1 -0
- package/dist/lib/split-button/split-button-start.js +182 -0
- package/dist/lib/split-button/split-button-start.js.map +1 -0
- package/dist/lib/split-button/split-button.cjs +1 -1
- package/dist/lib/split-button/split-button.cjs.map +1 -1
- package/dist/lib/split-button/split-button.js +246 -71
- package/dist/lib/split-button/split-button.js.map +1 -1
- package/dist/lib/stack/stack-constants.cjs +1 -1
- package/dist/lib/stack/stack-constants.cjs.map +1 -1
- package/dist/lib/stack/stack-constants.js +10 -2
- package/dist/lib/stack/stack-constants.js.map +1 -1
- package/dist/lib/stack/stack.cjs.map +1 -1
- package/dist/lib/stack/stack.js.map +1 -1
- package/dist/lib/tab/index.cjs +1 -1
- package/dist/lib/tab/index.js +5 -5
- package/dist/lib/tab/tab-group.cjs +1 -1
- package/dist/lib/tab/tab-group.cjs.map +1 -1
- package/dist/lib/tab/tab-group.js +173 -50
- package/dist/lib/tab/tab-group.js.map +1 -1
- package/dist/lib/tab/tab.cjs +1 -1
- package/dist/lib/tab/tab.cjs.map +1 -1
- package/dist/lib/tab/tab.js +108 -23
- package/dist/lib/tab/tab.js.map +1 -1
- package/dist/lib/tab/tabs-constants.cjs +1 -1
- package/dist/lib/tab/tabs-constants.cjs.map +1 -1
- package/dist/lib/tab/tabs-constants.js +33 -2
- package/dist/lib/tab/tabs-constants.js.map +1 -1
- package/dist/lib/text/index.cjs +1 -0
- package/dist/lib/text/index.js +3 -0
- package/dist/lib/text/text-constants.cjs +2 -0
- package/dist/lib/text/text-constants.cjs.map +1 -0
- package/dist/lib/text/text-constants.js +126 -0
- package/dist/lib/text/text-constants.js.map +1 -0
- package/dist/lib/text/text.cjs +2 -0
- package/dist/lib/text/text.cjs.map +1 -0
- package/dist/lib/text/text.js +150 -0
- package/dist/lib/text/text.js.map +1 -0
- package/dist/lib/toast/index.cjs +1 -1
- package/dist/lib/toast/index.js +1 -1
- package/dist/lib/toast/toast.cjs +1 -1
- package/dist/lib/toast/toast.js +1 -1
- package/dist/lib/toggle/toggle-constants.cjs +1 -1
- package/dist/lib/toggle/toggle-constants.cjs.map +1 -1
- package/dist/lib/toggle/toggle-constants.js +2 -0
- package/dist/lib/toggle/toggle-constants.js.map +1 -1
- package/dist/lib/toggle/toggle.cjs +1 -1
- package/dist/lib/toggle/toggle.cjs.map +1 -1
- package/dist/lib/toggle/toggle.js +24 -29
- package/dist/lib/toggle/toggle.js.map +1 -1
- package/dist/lib/tooltip/tooltip.cjs +1 -4
- package/dist/lib/tooltip/tooltip.cjs.map +1 -1
- package/dist/lib/tooltip/tooltip.js +36 -31
- package/dist/lib/tooltip/tooltip.js.map +1 -1
- package/dist/lib/tooltip-directive/tooltip.cjs +1 -1
- package/dist/lib/tooltip-directive/tooltip.cjs.map +1 -1
- package/dist/lib/tooltip-directive/tooltip.js +36 -35
- package/dist/lib/tooltip-directive/tooltip.js.map +1 -1
- package/dist/lib/top-banner-info/top-banner-info.cjs +1 -1
- package/dist/lib/top-banner-info/top-banner-info.cjs.map +1 -1
- package/dist/lib/top-banner-info/top-banner-info.js +4 -4
- package/dist/lib/top-banner-info/top-banner-info.js.map +1 -1
- package/dist/lib/unread-pill/unread-pill.cjs +1 -1
- package/dist/lib/unread-pill/unread-pill.cjs.map +1 -1
- package/dist/lib/unread-pill/unread-pill.js +1 -1
- package/dist/lib/unread-pill/unread-pill.js.map +1 -1
- package/dist/lib/validation-messages/validation-messages.cjs +1 -1
- package/dist/lib/validation-messages/validation-messages.cjs.map +1 -1
- package/dist/lib/validation-messages/validation-messages.js +2 -2
- package/dist/lib/validation-messages/validation-messages.js.map +1 -1
- package/dist/localization/en-US.cjs +5 -0
- package/dist/localization/en-US.cjs.map +1 -1
- package/dist/localization/en-US.js +1 -1
- package/dist/localization/en-US.js.map +1 -1
- package/dist/{markdownRenderer-DCgGQseq.cjs → markdownRenderer-Dsq-CiH9.cjs} +1 -1
- package/dist/{markdownRenderer-DCgGQseq.cjs.map → markdownRenderer-Dsq-CiH9.cjs.map} +1 -1
- package/dist/{markdownRenderer-D_P94RyM.js → markdownRenderer-k7_rQkox.js} +1 -1
- package/dist/{markdownRenderer-D_P94RyM.js.map → markdownRenderer-k7_rQkox.js.map} +1 -1
- package/dist/{message_input-CHlTsBGK.js → message_input-BYy1xKCy.js} +129 -130
- package/dist/message_input-BYy1xKCy.js.map +1 -0
- package/dist/message_input-sSCHhaeC.cjs +2 -0
- package/dist/message_input-sSCHhaeC.cjs.map +1 -0
- package/dist/mode_constants-CzYJW9ua.cjs +2 -0
- package/dist/mode_constants-CzYJW9ua.cjs.map +1 -0
- package/dist/mode_constants-tb7TL85q.js +14 -0
- package/dist/mode_constants-tb7TL85q.js.map +1 -0
- package/dist/recipes/buttons/callbar_button/callbar_button.vue.d.ts +85 -14
- package/dist/recipes/buttons/callbar_button/callbar_button.vue.d.ts.map +1 -1
- package/dist/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.d.ts +313 -41
- package/dist/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.d.ts.map +1 -1
- package/dist/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.d.ts +302 -41
- package/dist/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.d.ts.map +1 -1
- package/dist/recipes/cards/ivr_node/ivr_node.vue.d.ts +228 -35
- package/dist/recipes/cards/ivr_node/ivr_node.vue.d.ts.map +1 -1
- package/dist/recipes/chips/grouped_chip/grouped_chip.vue.d.ts +62 -16
- package/dist/recipes/chips/grouped_chip/grouped_chip.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/attachment_carousel/attachment_carousel.vue.d.ts +237 -28
- package/dist/recipes/conversation_view/attachment_carousel/attachment_carousel.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/attachment_carousel/media_components/image_carousel.vue.d.ts +184 -21
- package/dist/recipes/conversation_view/attachment_carousel/media_components/image_carousel.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/editor/EditorToolbarButton.vue.d.ts +53 -7
- package/dist/recipes/conversation_view/editor/EditorToolbarDropdownButton.vue.d.ts +228 -26
- package/dist/recipes/conversation_view/editor/EditorToolbarDropdownButton.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/editor/EditorToolbarPopoverButton.vue.d.ts +216 -25
- package/dist/recipes/conversation_view/editor/EditorToolbarPopoverButton.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/editor/editor.vue.d.ts +1163 -178
- package/dist/recipes/conversation_view/editor/editor.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/emoji_row/emoji_row.vue.d.ts +132 -42
- package/dist/recipes/conversation_view/emoji_row/emoji_row.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/feed_item_pill/feed_item_pill.vue.d.ts +91 -23
- package/dist/recipes/conversation_view/feed_item_pill/feed_item_pill.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/feed_item_row/feed_item_row.vue.d.ts +126 -35
- package/dist/recipes/conversation_view/feed_item_row/feed_item_row.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/message_input/extensions/meeting_pill/MeetingPill.vue.d.ts +90 -13
- package/dist/recipes/conversation_view/message_input/extensions/meeting_pill/MeetingPill.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/message_input/message_input.vue.d.ts +1622 -207
- package/dist/recipes/conversation_view/message_input/message_input.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/message_input/message_input_button.vue.d.ts +226 -12
- package/dist/recipes/conversation_view/message_input/message_input_button.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/message_input/message_input_link.vue.d.ts +636 -55
- package/dist/recipes/conversation_view/message_input/message_input_link.vue.d.ts.map +1 -1
- package/dist/recipes/conversation_view/message_input/message_input_topbar.vue.d.ts +226 -12
- package/dist/recipes/conversation_view/message_input/message_input_topbar.vue.d.ts.map +1 -1
- package/dist/recipes/header/settings_menu_button/settings_menu_button.vue.d.ts +53 -7
- package/dist/recipes/header/settings_menu_button/settings_menu_button.vue.d.ts.map +1 -1
- package/dist/recipes/item_layout/contact_info/contact_info.vue.d.ts +122 -33
- package/dist/recipes/item_layout/contact_info/contact_info.vue.d.ts.map +1 -1
- package/dist/recipes/leftbar/callbox/callbox.vue.d.ts +87 -29
- package/dist/recipes/leftbar/callbox/callbox.vue.d.ts.map +1 -1
- package/dist/recipes/leftbar/contact_centers_row/contact_centers_row.vue.d.ts +82 -28
- package/dist/recipes/leftbar/contact_centers_row/contact_centers_row.vue.d.ts.map +1 -1
- package/dist/recipes/leftbar/contact_row/contact_row.vue.d.ts +588 -72
- package/dist/recipes/leftbar/contact_row/contact_row.vue.d.ts.map +1 -1
- package/dist/recipes/leftbar/general_row/general_row.vue.d.ts +480 -31
- package/dist/recipes/leftbar/general_row/general_row.vue.d.ts.map +1 -1
- package/dist/recipes/leftbar/general_row/leftbar_general_row_icon.vue.d.ts.map +1 -1
- package/dist/recipes/leftbar/group_row/group_row.vue.d.ts +479 -30
- package/dist/recipes/leftbar/group_row/group_row.vue.d.ts.map +1 -1
- package/dist/recipes/leftbar/unread_pill/unread_pill.vue.d.ts.map +1 -1
- package/dist/recipes/notices/top_banner_info/top_banner_info.vue.d.ts.map +1 -1
- package/dist/{resizable-aOVGO_Os.cjs → resizable-DhowneUp.cjs} +2 -2
- package/dist/{resizable-aOVGO_Os.cjs.map → resizable-DhowneUp.cjs.map} +1 -1
- package/dist/{resizable-D4-peBOl.js → resizable-xcOu-0_w.js} +3 -3
- package/dist/{resizable-D4-peBOl.js.map → resizable-xcOu-0_w.js.map} +1 -1
- package/dist/{resizable_handle-BlKBiWnx.js → resizable_handle-BAZzCA_i.js} +3 -3
- package/dist/{resizable_handle-BlKBiWnx.js.map → resizable_handle-BAZzCA_i.js.map} +1 -1
- package/dist/{resizable_handle-RIKS8frB.cjs → resizable_handle-fjKg48eY.cjs} +2 -2
- package/dist/{resizable_handle-RIKS8frB.cjs.map → resizable_handle-fjKg48eY.cjs.map} +1 -1
- package/dist/{resizable_utils-DhuzXRdP.cjs → resizable_utils-BE4lK07_.cjs} +1 -1
- package/dist/{resizable_utils-DhuzXRdP.cjs.map → resizable_utils-BE4lK07_.cjs.map} +1 -1
- package/dist/{resizable_utils-BComtrMV.js → resizable_utils-DsKnGHKW.js} +1 -1
- package/dist/{resizable_utils-BComtrMV.js.map → resizable_utils-DsKnGHKW.js.map} +1 -1
- package/dist/{rich_text_editor-Ba67C4Uk.js → rich_text_editor-CEW74QNe.js} +637 -598
- package/dist/{rich_text_editor-Ba67C4Uk.js.map → rich_text_editor-CEW74QNe.js.map} +1 -1
- package/dist/rich_text_editor-immDiKq_.cjs +10 -0
- package/dist/{rich_text_editor-DMP5eTlf.cjs.map → rich_text_editor-immDiKq_.cjs.map} +1 -1
- package/dist/scroller-C15VLKNK.cjs +2 -0
- package/dist/scroller-C15VLKNK.cjs.map +1 -0
- package/dist/{scroller-BGVDh3sq.js → scroller-DPqcc_Wl.js} +6 -6
- package/dist/scroller-DPqcc_Wl.js.map +1 -0
- package/dist/shared/sr_only_close_button.cjs +1 -1
- package/dist/shared/sr_only_close_button.cjs.map +1 -1
- package/dist/shared/sr_only_close_button.js +1 -1
- package/dist/shared/sr_only_close_button.js.map +1 -1
- package/dist/toast-B1WZNMAm.cjs +2 -0
- package/dist/toast-B1WZNMAm.cjs.map +1 -0
- package/dist/{toast-DvPN-bCi.js → toast-DaH2KF7B.js} +52 -51
- package/dist/toast-DaH2KF7B.js.map +1 -0
- package/dist/{useResizableCalculations-DAajatT4.js → useResizableCalculations-2UpEXvfY.js} +2 -2
- package/dist/{useResizableCalculations-DAajatT4.js.map → useResizableCalculations-2UpEXvfY.js.map} +1 -1
- package/dist/{useResizableCalculations-BDITle3Q.cjs → useResizableCalculations-DPBjAFWQ.cjs} +2 -2
- package/dist/{useResizableCalculations-BDITle3Q.cjs.map → useResizableCalculations-DPBjAFWQ.cjs.map} +1 -1
- package/package.json +9 -7
- package/dist/attachment_carousel-BHxR7A76.cjs +0 -2
- package/dist/attachment_carousel-BHxR7A76.cjs.map +0 -1
- package/dist/attachment_carousel-CouFqFMw.js.map +0 -1
- package/dist/combobox-DgClbLOg.js.map +0 -1
- package/dist/combobox-DhjZxfUw.cjs +0 -3
- package/dist/combobox-DhjZxfUw.cjs.map +0 -1
- package/dist/components/split_button/split_button-alpha.vue.d.ts.map +0 -1
- package/dist/datepicker-DprRX9AH.cjs +0 -2
- package/dist/datepicker-DprRX9AH.cjs.map +0 -1
- package/dist/datepicker-LVDRC6Lf.js.map +0 -1
- package/dist/emoji_picker-Cl-T4BXK.cjs +0 -2
- package/dist/emoji_picker-Cl-T4BXK.cjs.map +0 -1
- package/dist/emoji_picker-tVHfpHDk.js.map +0 -1
- package/dist/lib/split-button/split-button-alpha.cjs +0 -2
- package/dist/lib/split-button/split-button-alpha.cjs.map +0 -1
- package/dist/lib/split-button/split-button-alpha.js +0 -107
- package/dist/lib/split-button/split-button-alpha.js.map +0 -1
- package/dist/lib/split-button/split-button-omega.cjs +0 -2
- package/dist/lib/split-button/split-button-omega.cjs.map +0 -1
- package/dist/lib/split-button/split-button-omega.js.map +0 -1
- package/dist/message_input-AWgvtwMV.cjs +0 -2
- package/dist/message_input-AWgvtwMV.cjs.map +0 -1
- package/dist/message_input-CHlTsBGK.js.map +0 -1
- package/dist/rich_text_editor-DMP5eTlf.cjs +0 -10
- package/dist/scroller-BGVDh3sq.js.map +0 -1
- package/dist/scroller-CjAsgjl9.cjs +0 -2
- package/dist/scroller-CjAsgjl9.cjs.map +0 -1
- package/dist/toast-DvPN-bCi.js.map +0 -1
- package/dist/toast-d8_zmgkL.cjs +0 -2
- package/dist/toast-d8_zmgkL.cjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"codeblock.js","names":[],"sources":["../../../components/codeblock/codeblock.vue"],"sourcesContent":["<template>\n <pre
|
|
1
|
+
{"version":3,"file":"codeblock.js","names":[],"sources":["../../../components/codeblock/codeblock.vue"],"sourcesContent":["<template>\n <pre\n class=\"d-codeblock\"\n :class=\"{ 'd-codeblock--bordered': bordered }\"\n ><code\n class=\"d-codeblock__code\"\n :class=\"`d-codeblock__code--${sizeClass}`\"\n >{{ text }}</code></pre> <!-- this must be a single line -->\n</template>\n\n<script>\nimport { CODEBLOCK_SIZES, CODEBLOCK_SIZE_MAP } from './codeblock_constants';\n\nexport default {\n compatConfig: { MODE: 3 },\n name: 'DtCodeblock',\n\n props: {\n /**\n * The text to display in the codeblock.\n */\n text: {\n type: String,\n required: true,\n },\n\n /**\n * Whether to render as a styled container block.\n */\n bordered: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Font size of the code block.\n * @values 100, 200, 300, 400\n */\n size: {\n type: [String, Number],\n default: 200,\n validator: (val) => CODEBLOCK_SIZES.includes(String(val)),\n },\n },\n\n computed: {\n sizeClass () {\n return CODEBLOCK_SIZE_MAP[String(this.size)] || String(this.size);\n },\n },\n};\n</script>\n"],"mappings":";;;;AAaA,IAAK,IAAU;CACb,cAAc,EAAE,MAAM,GAAG;CACzB,MAAM;CAEN,OAAO;EAIL,MAAM;GACJ,MAAM;GACN,UAAU;GACX;EAKD,UAAU;GACR,MAAM;GACN,SAAS;GACV;EAMD,MAAM;GACJ,MAAM,CAAC,QAAQ,OAAO;GACtB,SAAS;GACT,YAAY,MAAQ,EAAgB,SAAS,OAAO,EAAI,CAAC;GAC1D;EACF;CAED,UAAU,EACR,YAAa;AACX,SAAO,EAAmB,OAAO,KAAK,KAAK,KAAK,OAAO,KAAK,KAAK;IAEpE;CACF;;aAjDC,EAMwB,OAAA,EALtB,OAAK,EAAA,CAAC,eAAa,EAAA,yBACgB,EAAA,UAAQ,CAAA,CAAA,EAAA,EAAA,CAC5C,EAGiB,QAAA,EAFhB,OAAK,EAAA,CAAC,qBAAmB,sBACK,EAAA,YAAS,CAAA,EAAA,EAAA,EACrC,EAAA,KAAI,EAAA,EAAA,CAAA,EAAA,EAAA"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}}),require(`../../chunk-Bmb41Sf3.cjs`);const e=require(`../../common/utils/index.cjs`),t=require(`../../_plugin-vue_export-helper-D8jCH6HB.cjs`),n=require(`../button/button.cjs`),r=require(`./collapsible-lazy-show.cjs`),i=require(`../lazy-show/lazy-show.cjs`);let a=require(`vue`),o=require(`@dialpad/dialtone-icons/
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}}),require(`../../chunk-Bmb41Sf3.cjs`);const e=require(`../../common/utils/index.cjs`),t=require(`../../_plugin-vue_export-helper-D8jCH6HB.cjs`),n=require(`../button/button.cjs`),r=require(`./collapsible-lazy-show.cjs`),i=require(`../lazy-show/lazy-show.cjs`);let a=require(`vue`),o=require(`@dialpad/dialtone-icons/vue`);var s={compatConfig:{MODE:3},name:`DtCollapsible`,components:{DtButton:n.default,DtCollapsibleLazyShow:r.default,DtLazyShow:i.default,DtIconChevronDown:o.DtIconChevronDown,DtIconChevronRight:o.DtIconChevronRight},props:{anchorText:{type:String,default:null},open:{type:Boolean,default:null},id:{type:String,default(){return e.getUniqueString()}},elementType:{type:String,default:`div`},contentElementType:{type:String,default:`div`},anchorClass:{type:[String,Array,Object],default:null},contentClass:{type:[String,Array,Object],default:null},maxWidth:{type:String,default:null},maxHeight:{type:String,default:null},ariaLabel:{type:String,default:null},ariaLabelledBy:{type:String,default:null}},emits:[`update:open`,`opened`],data(){return{isOpen:!0}},computed:{labelledBy(){return this.ariaLabelledBy||!this.ariaLabel&&e.getUniqueString(`DtCollapsible__anchor`)},collapsibleListeners(){return e.extractVueListeners(this.$attrs)}},watch:{open:{handler:function(e){e!==null&&(this.isOpen=e)},immediate:!0}},created(){this.validateProperAnchor()},methods:{onLeaveTransitionComplete(){this.$emit(`opened`,!1),this.open!==null&&this.$emit(`update:open`,!1)},onEnterTransitionComplete(){this.$emit(`opened`,!0,this.$refs.content),this.open!==null&&this.$emit(`update:open`,!0)},defaultToggleOpen(){this.open===null&&this.toggleOpen()},toggleOpen(){this.isOpen=!this.isOpen},validateProperAnchor(){!this.anchorText&&!e.hasSlotContent(this.$slots.anchor)&&console.error(`anchor text and anchor slot content cannot both be falsy`)}}},c=[`id`],l=[`title`];function u(e,t,n,r,i,o){let s=(0,a.resolveComponent)(`dt-icon-chevron-down`),u=(0,a.resolveComponent)(`dt-icon-chevron-right`),d=(0,a.resolveComponent)(`dt-button`),f=(0,a.resolveComponent)(`dt-collapsible-lazy-show`);return(0,a.openBlock)(),(0,a.createBlock)((0,a.resolveDynamicComponent)(n.elementType),(0,a.mergeProps)({ref:`collapsible`},(0,a.toHandlers)(o.collapsibleListeners)),{default:(0,a.withCtx)(()=>[(0,a.createElementVNode)(`div`,{id:!n.ariaLabelledBy&&o.labelledBy,ref:`anchor`,class:(0,a.normalizeClass)(n.anchorClass)},[(0,a.renderSlot)(e.$slots,`anchor`,{attrs:{"aria-controls":n.id,"aria-expanded":i.isOpen.toString(),role:`button`}},()=>[(0,a.createVNode)(d,{importance:`clear`,kind:`muted`,"aria-controls":n.id,"aria-expanded":`${i.isOpen}`,style:(0,a.normalizeStyle)({width:n.maxWidth}),onClick:o.defaultToggleOpen},{default:(0,a.withCtx)(()=>[i.isOpen?((0,a.openBlock)(),(0,a.createBlock)(s,{key:0,class:`d-collapsible__icon`,size:`300`})):((0,a.openBlock)(),(0,a.createBlock)(u,{key:1,class:`d-collapsible__icon`,size:`300`})),(0,a.createElementVNode)(`span`,{class:`d-collapsible__anchor-text`,title:n.anchorText},(0,a.toDisplayString)(n.anchorText),9,l)]),_:1},8,[`aria-controls`,`aria-expanded`,`style`,`onClick`])])],10,c),(0,a.createVNode)(f,(0,a.mergeProps)({id:n.id,ref:`contentWrapper`,"aria-hidden":`${!i.isOpen}`,"aria-labelledby":o.labelledBy,"aria-label":n.ariaLabel,show:i.isOpen,"element-type":n.contentElementType,class:n.contentClass,style:{"max-height":n.maxHeight,"max-width":n.maxWidth},"data-qa":`dt-collapsible--content`,tabindex:`-1`,appear:``},(0,a.toHandlers)(o.collapsibleListeners),{onAfterLeave:o.onLeaveTransitionComplete,onAfterEnter:o.onEnterTransitionComplete}),{default:(0,a.withCtx)(()=>[(0,a.renderSlot)(e.$slots,`content`)]),_:3},16,[`id`,`aria-hidden`,`aria-labelledby`,`aria-label`,`show`,`element-type`,`class`,`style`,`onAfterLeave`,`onAfterEnter`])]),_:3},16)}var d=t.t(s,[[`render`,u]]);exports.default=d;
|
|
2
2
|
//# sourceMappingURL=collapsible.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collapsible.cjs","names":[],"sources":["../../../components/collapsible/collapsible.vue"],"sourcesContent":["<template>\n <component\n :is=\"elementType\"\n ref=\"collapsible\"\n v-on=\"collapsibleListeners\"\n >\n <!-- Element for capturing keypress events -->\n <div\n :id=\"!ariaLabelledBy && labelledBy\"\n ref=\"anchor\"\n :class=\"anchorClass\"\n >\n <!-- @slot Slot for the anchor element that toggles the collapsible content -->\n <slot\n name=\"anchor\"\n :attrs=\"{\n 'aria-controls': id,\n 'aria-expanded': isOpen.toString(),\n 'role': 'button',\n }\"\n >\n <dt-button\n importance=\"clear\"\n kind=\"muted\"\n :aria-controls=\"id\"\n :aria-expanded=\"`${isOpen}`\"\n :style=\"{\n 'width': maxWidth,\n }\"\n @click=\"defaultToggleOpen\"\n >\n <dt-icon-chevron-down\n v-if=\"isOpen\"\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <dt-icon-chevron-right\n v-else\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <span\n class=\"d-collapsible__anchor-text\"\n :title=\"anchorText\"\n >\n {{ anchorText }}\n </span>\n </dt-button>\n </slot>\n </div>\n <dt-collapsible-lazy-show\n :id=\"id\"\n ref=\"contentWrapper\"\n :aria-hidden=\"`${!isOpen}`\"\n :aria-labelledby=\"labelledBy\"\n :aria-label=\"ariaLabel\"\n :show=\"isOpen\"\n :element-type=\"contentElementType\"\n :class=\"contentClass\"\n :style=\"{\n 'max-height': maxHeight,\n 'max-width': maxWidth,\n }\"\n data-qa=\"dt-collapsible--content\"\n tabindex=\"-1\"\n appear\n v-on=\"collapsibleListeners\"\n @after-leave=\"onLeaveTransitionComplete\"\n @after-enter=\"onEnterTransitionComplete\"\n >\n <!-- @slot Slot for the collapsible element that is expanded by the anchor -->\n <slot\n name=\"content\"\n />\n </dt-collapsible-lazy-show>\n </component>\n</template>\n\n<script>\nimport { extractVueListeners, getUniqueString, hasSlotContent } from '@/common/utils';\nimport DtCollapsibleLazyShow from './collapsible_lazy_show.vue';\nimport { DtButton } from '@/components/button';\nimport { DtLazyShow } from '@/components/lazy_show';\nimport { DtIconChevronDown, DtIconChevronRight } from '@dialpad/dialtone-icons/
|
|
1
|
+
{"version":3,"file":"collapsible.cjs","names":[],"sources":["../../../components/collapsible/collapsible.vue"],"sourcesContent":["<template>\n <component\n :is=\"elementType\"\n ref=\"collapsible\"\n v-on=\"collapsibleListeners\"\n >\n <!-- Element for capturing keypress events -->\n <div\n :id=\"!ariaLabelledBy && labelledBy\"\n ref=\"anchor\"\n :class=\"anchorClass\"\n >\n <!-- @slot Slot for the anchor element that toggles the collapsible content -->\n <slot\n name=\"anchor\"\n :attrs=\"{\n 'aria-controls': id,\n 'aria-expanded': isOpen.toString(),\n 'role': 'button',\n }\"\n >\n <dt-button\n importance=\"clear\"\n kind=\"muted\"\n :aria-controls=\"id\"\n :aria-expanded=\"`${isOpen}`\"\n :style=\"{\n 'width': maxWidth,\n }\"\n @click=\"defaultToggleOpen\"\n >\n <dt-icon-chevron-down\n v-if=\"isOpen\"\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <dt-icon-chevron-right\n v-else\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <span\n class=\"d-collapsible__anchor-text\"\n :title=\"anchorText\"\n >\n {{ anchorText }}\n </span>\n </dt-button>\n </slot>\n </div>\n <dt-collapsible-lazy-show\n :id=\"id\"\n ref=\"contentWrapper\"\n :aria-hidden=\"`${!isOpen}`\"\n :aria-labelledby=\"labelledBy\"\n :aria-label=\"ariaLabel\"\n :show=\"isOpen\"\n :element-type=\"contentElementType\"\n :class=\"contentClass\"\n :style=\"{\n 'max-height': maxHeight,\n 'max-width': maxWidth,\n }\"\n data-qa=\"dt-collapsible--content\"\n tabindex=\"-1\"\n appear\n v-on=\"collapsibleListeners\"\n @after-leave=\"onLeaveTransitionComplete\"\n @after-enter=\"onEnterTransitionComplete\"\n >\n <!-- @slot Slot for the collapsible element that is expanded by the anchor -->\n <slot\n name=\"content\"\n />\n </dt-collapsible-lazy-show>\n </component>\n</template>\n\n<script>\nimport { extractVueListeners, getUniqueString, hasSlotContent } from '@/common/utils';\nimport DtCollapsibleLazyShow from './collapsible_lazy_show.vue';\nimport { DtButton } from '@/components/button';\nimport { DtLazyShow } from '@/components/lazy_show';\nimport { DtIconChevronDown, DtIconChevronRight } from '@dialpad/dialtone-icons/vue';\n\n/**\n * A collapsible is a component consisting of an interactive anchor that toggled the expandable/collapsible element.\n * @see https://dialtone.dialpad.com/components/collapsible.html\n */\nexport default {\n compatConfig: { MODE: 3 },\n name: 'DtCollapsible',\n\n components: {\n DtButton,\n DtCollapsibleLazyShow,\n DtLazyShow,\n DtIconChevronDown,\n DtIconChevronRight,\n },\n\n props: {\n /**\n * Text that is displayed on the anchor if nothing is passed in the slot.\n * Ignored if the anchor slot is used.\n */\n anchorText: {\n type: String,\n default: null,\n },\n\n /**\n * Controls whether the collapsible is shown. Leaving this null will have the collapsible start\n * expanded and trigger on click by default. If you set this value, the default trigger\n * behavior will be disabled, and you can control it as you need.\n * Supports .sync modifier\n * @values null, true, false\n */\n open: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The id of the content wrapper.\n */\n id: {\n type: String,\n default () { return getUniqueString(); },\n },\n\n /**\n * HTML element type (tag name) of the root element of the component.\n */\n elementType: {\n type: String,\n default: 'div',\n },\n\n /**\n * HTML element type (tag name) of the content wrapper element.\n */\n contentElementType: {\n type: String,\n default: 'div',\n },\n\n /**\n * Additional class name for the anchor wrapper element.\n */\n anchorClass: {\n type: [String, Array, Object],\n default: null,\n },\n\n /**\n * Additional class name for the content wrapper element.\n */\n contentClass: {\n type: [String, Array, Object],\n default: null,\n },\n\n /**\n * The maximum width of the anchor and collapsible element.\n * Possible units rem|px|%|em\n */\n maxWidth: {\n type: String,\n default: null,\n },\n\n /**\n * The maximum height of the collapsible element.\n * Possible units rem|px|%|em\n */\n maxHeight: {\n type: String,\n default: null,\n },\n\n /**\n * Label on the collapsible content. Should provide this or ariaLabelledBy but not both.\n */\n ariaLabel: {\n type: String,\n default: null,\n },\n\n /**\n * Id of the element that labels the collapsible content. Defaults to the anchor element.\n * Should provide this or ariaLabel but not both.\n */\n ariaLabelledBy: {\n type: String,\n default: null,\n },\n },\n\n emits: [\n /**\n * Event fired to sync the open prop with the parent component\n * @event update:open\n */\n 'update:open',\n\n /**\n * Event fired when the content is shown or hidden\n *\n * @event opened\n * @type {Boolean}\n */\n 'opened',\n ],\n\n data () {\n return {\n isOpen: true,\n };\n },\n\n computed: {\n labelledBy () {\n // aria-labelledby should be set only if aria-labelledby is passed as a prop, or if\n // there is no aria-label and the labelledby should point to the anchor\n return this.ariaLabelledBy || (!this.ariaLabel && getUniqueString('DtCollapsible__anchor'));\n },\n\n collapsibleListeners () {\n return extractVueListeners(this.$attrs);\n },\n },\n\n watch: {\n open: {\n handler: function (open) {\n if (open !== null) {\n this.isOpen = open;\n }\n },\n\n immediate: true,\n },\n },\n\n created () {\n this.validateProperAnchor();\n },\n\n methods: {\n onLeaveTransitionComplete () {\n this.$emit('opened', false);\n if (this.open !== null) {\n this.$emit('update:open', false);\n }\n },\n\n onEnterTransitionComplete () {\n this.$emit('opened', true, this.$refs.content);\n if (this.open !== null) {\n this.$emit('update:open', true);\n }\n },\n\n defaultToggleOpen () {\n if (this.open === null) {\n this.toggleOpen();\n }\n },\n\n toggleOpen () {\n this.isOpen = !this.isOpen;\n },\n\n validateProperAnchor () {\n if (!this.anchorText && !hasSlotContent(this.$slots.anchor)) {\n console.error('anchor text and anchor slot content cannot both be falsy');\n }\n },\n },\n};\n</script>\n"],"mappings":"8ZAyFA,IAAK,EAAU,CACb,aAAc,CAAE,KAAM,EAAG,CACzB,KAAM,gBAEN,WAAY,CACV,SAAA,EAAA,QACA,sBAAA,EAAA,QACA,WAAA,EAAA,QACA,kBAAA,EAAA,kBACA,mBAAA,EAAA,mBACD,CAED,MAAO,CAKL,WAAY,CACV,KAAM,OACN,QAAS,KACV,CASD,KAAM,CACJ,KAAM,QACN,QAAS,KACV,CAKD,GAAI,CACF,KAAM,OACN,SAAW,CAAE,OAAO,EAAA,iBAAiB,EACtC,CAKD,YAAa,CACX,KAAM,OACN,QAAS,MACV,CAKD,mBAAoB,CAClB,KAAM,OACN,QAAS,MACV,CAKD,YAAa,CACX,KAAM,CAAC,OAAQ,MAAO,OAAO,CAC7B,QAAS,KACV,CAKD,aAAc,CACZ,KAAM,CAAC,OAAQ,MAAO,OAAO,CAC7B,QAAS,KACV,CAMD,SAAU,CACR,KAAM,OACN,QAAS,KACV,CAMD,UAAW,CACT,KAAM,OACN,QAAS,KACV,CAKD,UAAW,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AW,QACX,KAAK,QACJ,gBAAe,EAAA,GACf,gBAAa,GAAK,EAAA,SAClB,OAAA,EAAA,EAAA,gBAAK,CAAA,MAAyB,EAAA,SAAA,CAAA,CAG9B,QAAO,EAAA,8CAMN,CAHM,EAAA,SAAA,EAAA,EAAA,YAAA,EAAA,EAAA,EAAA,aAGN,EAAA,OAFA,MAAM,sBACN,KAAK,8CAML,EAAA,OAFA,MAAM,sBACN,KAAK,kCAOA,OAAA,CAJL,MAAM,6BACL,MAAO,EAAA,kCAEL,EAAA,WAAU,CAAA,EAAA,EAAA,CAAA,CAAA,wFA6BM,GAAA,EAAA,EAAA,YAAA,CAvBxB,GAAI,EAAA,GACL,IAAI,iBACH,cAAW,GAAA,CAAM,EAAA,SACjB,kBAAiB,EAAA,WACjB,aAAY,EAAA,UACZ,KAAM,EAAA,OACN,eAAc,EAAA,mBACd,MAAO,EAAA,aACP,MAAK,cAA0B,EAAA,sBAAgC,EAAA,UAIhE,UAAQ,0BACR,SAAS,KACT,OAAA,qBAC2B,EAArB,qBAAoB,CAAA,CACzB,aAAa,EAAA,0BACb,aAAa,EAAA,uDAKZ,EAAA,EAAA,EAAA,YAAA,EAAA,OAAA,UAAA,CAAA,CAAA"}
|
|
@@ -4,7 +4,7 @@ import i from "../button/button.js";
|
|
|
4
4
|
import a from "./collapsible-lazy-show.js";
|
|
5
5
|
import o from "../lazy-show/lazy-show.js";
|
|
6
6
|
import { createBlock as s, createElementVNode as c, createVNode as l, mergeProps as u, normalizeClass as d, normalizeStyle as f, openBlock as p, renderSlot as m, resolveComponent as h, resolveDynamicComponent as g, toDisplayString as _, toHandlers as v, withCtx as y } from "vue";
|
|
7
|
-
import { DtIconChevronDown as b, DtIconChevronRight as x } from "@dialpad/dialtone-icons/
|
|
7
|
+
import { DtIconChevronDown as b, DtIconChevronRight as x } from "@dialpad/dialtone-icons/vue";
|
|
8
8
|
//#region components/collapsible/collapsible.vue
|
|
9
9
|
var S = {
|
|
10
10
|
compatConfig: { MODE: 3 },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collapsible.js","names":[],"sources":["../../../components/collapsible/collapsible.vue"],"sourcesContent":["<template>\n <component\n :is=\"elementType\"\n ref=\"collapsible\"\n v-on=\"collapsibleListeners\"\n >\n <!-- Element for capturing keypress events -->\n <div\n :id=\"!ariaLabelledBy && labelledBy\"\n ref=\"anchor\"\n :class=\"anchorClass\"\n >\n <!-- @slot Slot for the anchor element that toggles the collapsible content -->\n <slot\n name=\"anchor\"\n :attrs=\"{\n 'aria-controls': id,\n 'aria-expanded': isOpen.toString(),\n 'role': 'button',\n }\"\n >\n <dt-button\n importance=\"clear\"\n kind=\"muted\"\n :aria-controls=\"id\"\n :aria-expanded=\"`${isOpen}`\"\n :style=\"{\n 'width': maxWidth,\n }\"\n @click=\"defaultToggleOpen\"\n >\n <dt-icon-chevron-down\n v-if=\"isOpen\"\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <dt-icon-chevron-right\n v-else\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <span\n class=\"d-collapsible__anchor-text\"\n :title=\"anchorText\"\n >\n {{ anchorText }}\n </span>\n </dt-button>\n </slot>\n </div>\n <dt-collapsible-lazy-show\n :id=\"id\"\n ref=\"contentWrapper\"\n :aria-hidden=\"`${!isOpen}`\"\n :aria-labelledby=\"labelledBy\"\n :aria-label=\"ariaLabel\"\n :show=\"isOpen\"\n :element-type=\"contentElementType\"\n :class=\"contentClass\"\n :style=\"{\n 'max-height': maxHeight,\n 'max-width': maxWidth,\n }\"\n data-qa=\"dt-collapsible--content\"\n tabindex=\"-1\"\n appear\n v-on=\"collapsibleListeners\"\n @after-leave=\"onLeaveTransitionComplete\"\n @after-enter=\"onEnterTransitionComplete\"\n >\n <!-- @slot Slot for the collapsible element that is expanded by the anchor -->\n <slot\n name=\"content\"\n />\n </dt-collapsible-lazy-show>\n </component>\n</template>\n\n<script>\nimport { extractVueListeners, getUniqueString, hasSlotContent } from '@/common/utils';\nimport DtCollapsibleLazyShow from './collapsible_lazy_show.vue';\nimport { DtButton } from '@/components/button';\nimport { DtLazyShow } from '@/components/lazy_show';\nimport { DtIconChevronDown, DtIconChevronRight } from '@dialpad/dialtone-icons/
|
|
1
|
+
{"version":3,"file":"collapsible.js","names":[],"sources":["../../../components/collapsible/collapsible.vue"],"sourcesContent":["<template>\n <component\n :is=\"elementType\"\n ref=\"collapsible\"\n v-on=\"collapsibleListeners\"\n >\n <!-- Element for capturing keypress events -->\n <div\n :id=\"!ariaLabelledBy && labelledBy\"\n ref=\"anchor\"\n :class=\"anchorClass\"\n >\n <!-- @slot Slot for the anchor element that toggles the collapsible content -->\n <slot\n name=\"anchor\"\n :attrs=\"{\n 'aria-controls': id,\n 'aria-expanded': isOpen.toString(),\n 'role': 'button',\n }\"\n >\n <dt-button\n importance=\"clear\"\n kind=\"muted\"\n :aria-controls=\"id\"\n :aria-expanded=\"`${isOpen}`\"\n :style=\"{\n 'width': maxWidth,\n }\"\n @click=\"defaultToggleOpen\"\n >\n <dt-icon-chevron-down\n v-if=\"isOpen\"\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <dt-icon-chevron-right\n v-else\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <span\n class=\"d-collapsible__anchor-text\"\n :title=\"anchorText\"\n >\n {{ anchorText }}\n </span>\n </dt-button>\n </slot>\n </div>\n <dt-collapsible-lazy-show\n :id=\"id\"\n ref=\"contentWrapper\"\n :aria-hidden=\"`${!isOpen}`\"\n :aria-labelledby=\"labelledBy\"\n :aria-label=\"ariaLabel\"\n :show=\"isOpen\"\n :element-type=\"contentElementType\"\n :class=\"contentClass\"\n :style=\"{\n 'max-height': maxHeight,\n 'max-width': maxWidth,\n }\"\n data-qa=\"dt-collapsible--content\"\n tabindex=\"-1\"\n appear\n v-on=\"collapsibleListeners\"\n @after-leave=\"onLeaveTransitionComplete\"\n @after-enter=\"onEnterTransitionComplete\"\n >\n <!-- @slot Slot for the collapsible element that is expanded by the anchor -->\n <slot\n name=\"content\"\n />\n </dt-collapsible-lazy-show>\n </component>\n</template>\n\n<script>\nimport { extractVueListeners, getUniqueString, hasSlotContent } from '@/common/utils';\nimport DtCollapsibleLazyShow from './collapsible_lazy_show.vue';\nimport { DtButton } from '@/components/button';\nimport { DtLazyShow } from '@/components/lazy_show';\nimport { DtIconChevronDown, DtIconChevronRight } from '@dialpad/dialtone-icons/vue';\n\n/**\n * A collapsible is a component consisting of an interactive anchor that toggled the expandable/collapsible element.\n * @see https://dialtone.dialpad.com/components/collapsible.html\n */\nexport default {\n compatConfig: { MODE: 3 },\n name: 'DtCollapsible',\n\n components: {\n DtButton,\n DtCollapsibleLazyShow,\n DtLazyShow,\n DtIconChevronDown,\n DtIconChevronRight,\n },\n\n props: {\n /**\n * Text that is displayed on the anchor if nothing is passed in the slot.\n * Ignored if the anchor slot is used.\n */\n anchorText: {\n type: String,\n default: null,\n },\n\n /**\n * Controls whether the collapsible is shown. Leaving this null will have the collapsible start\n * expanded and trigger on click by default. If you set this value, the default trigger\n * behavior will be disabled, and you can control it as you need.\n * Supports .sync modifier\n * @values null, true, false\n */\n open: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The id of the content wrapper.\n */\n id: {\n type: String,\n default () { return getUniqueString(); },\n },\n\n /**\n * HTML element type (tag name) of the root element of the component.\n */\n elementType: {\n type: String,\n default: 'div',\n },\n\n /**\n * HTML element type (tag name) of the content wrapper element.\n */\n contentElementType: {\n type: String,\n default: 'div',\n },\n\n /**\n * Additional class name for the anchor wrapper element.\n */\n anchorClass: {\n type: [String, Array, Object],\n default: null,\n },\n\n /**\n * Additional class name for the content wrapper element.\n */\n contentClass: {\n type: [String, Array, Object],\n default: null,\n },\n\n /**\n * The maximum width of the anchor and collapsible element.\n * Possible units rem|px|%|em\n */\n maxWidth: {\n type: String,\n default: null,\n },\n\n /**\n * The maximum height of the collapsible element.\n * Possible units rem|px|%|em\n */\n maxHeight: {\n type: String,\n default: null,\n },\n\n /**\n * Label on the collapsible content. Should provide this or ariaLabelledBy but not both.\n */\n ariaLabel: {\n type: String,\n default: null,\n },\n\n /**\n * Id of the element that labels the collapsible content. Defaults to the anchor element.\n * Should provide this or ariaLabel but not both.\n */\n ariaLabelledBy: {\n type: String,\n default: null,\n },\n },\n\n emits: [\n /**\n * Event fired to sync the open prop with the parent component\n * @event update:open\n */\n 'update:open',\n\n /**\n * Event fired when the content is shown or hidden\n *\n * @event opened\n * @type {Boolean}\n */\n 'opened',\n ],\n\n data () {\n return {\n isOpen: true,\n };\n },\n\n computed: {\n labelledBy () {\n // aria-labelledby should be set only if aria-labelledby is passed as a prop, or if\n // there is no aria-label and the labelledby should point to the anchor\n return this.ariaLabelledBy || (!this.ariaLabel && getUniqueString('DtCollapsible__anchor'));\n },\n\n collapsibleListeners () {\n return extractVueListeners(this.$attrs);\n },\n },\n\n watch: {\n open: {\n handler: function (open) {\n if (open !== null) {\n this.isOpen = open;\n }\n },\n\n immediate: true,\n },\n },\n\n created () {\n this.validateProperAnchor();\n },\n\n methods: {\n onLeaveTransitionComplete () {\n this.$emit('opened', false);\n if (this.open !== null) {\n this.$emit('update:open', false);\n }\n },\n\n onEnterTransitionComplete () {\n this.$emit('opened', true, this.$refs.content);\n if (this.open !== null) {\n this.$emit('update:open', true);\n }\n },\n\n defaultToggleOpen () {\n if (this.open === null) {\n this.toggleOpen();\n }\n },\n\n toggleOpen () {\n this.isOpen = !this.isOpen;\n },\n\n validateProperAnchor () {\n if (!this.anchorText && !hasSlotContent(this.$slots.anchor)) {\n console.error('anchor text and anchor slot content cannot both be falsy');\n }\n },\n },\n};\n</script>\n"],"mappings":";;;;;;;;AAyFA,IAAK,IAAU;CACb,cAAc,EAAE,MAAM,GAAG;CACzB,MAAM;CAEN,YAAY;EACV,UAAA;EACA,uBAAA;EACA,YAAA;EACA;EACA;EACD;CAED,OAAO;EAKL,YAAY;GACV,MAAM;GACN,SAAS;GACV;EASD,MAAM;GACJ,MAAM;GACN,SAAS;GACV;EAKD,IAA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C,EA0EY,EAzEL,EAAA,YAAW,EADlB,EA0EY,EAxEV,KAAI,eAAa,EACjB,EAA2B,EAArB,qBAAoB,CAAA,EAAA;mBA6CpB,CA1CN,EA0CM,OAAA;GAzCH,IAAE,CAAG,EAAA,kBAAkB,EAAA;GACxB,KAAI;GACH,OAAK,EAAE,EAAA,YAAW;MAGnB,EAmCO,EAAA,QAAA,UAAA,EAjCJ,OAAK;oBAA+B,EAAA;oBAA+B,EAAA,OAAO,UAAQ;;aAiC9E,CA3BL,EA0BY,GAAA;GAzBV,YAAW;GACX,MAAK;GACJ,iBAAe,EAAA;GACf,iBAAa,GAAK,EAAA;GAClB,OAAK,EAAA,EAAA,OAAyB,EAAA,UAAA,CAAA;GAG9B,SAAO,EAAA;;oBAMN,CAHM,EAAA,UAAA,GAAA,EADR,EAIE,GAAA;;IAFA,OAAM;IACN,MAAK;eAEP,EAIE,GAAA;;IAFA,OAAM;IACN,MAAK;QAEP,EAKO,QAAA;IAJL,OAAM;IACL,OAAO,EAAA;QAEL,EAAA,WAAU,EAAA,GAAA,EAAA,CAAA,CAAA;;;;;;;iBAKrB,EAwB2B,GAxB3B,EAwB2B;GAvBxB,IAAI,EAAA;GACL,KAAI;GACH,eAAW,GAAA,CAAM,EAAA;GACjB,mBAAiB,EAAA;GACjB,cAAY,EAAA;GACZ,MAAM,EAAA;GACN,gBAAc,EAAA;GACd,OAAO,EAAA;GACP,OAAK;kBAA0B,EAAA;iBAAgC,EAAA;;GAIhE,WAAQ;GACR,UAAS;GACT,QAAA;KACA,EAA2B,EAArB,qBAAoB,EAAA;GACzB,cAAa,EAAA;GACb,cAAa,EAAA;;oBAKZ,CAFF,EAEE,EAAA,QAAA,UAAA,CAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require(`../../combobox-
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});const e=require(`../../combobox-Da7wBh3G.cjs`);exports.default=e.t;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "../../combobox-
|
|
1
|
+
import { t as e } from "../../combobox-BQBKrDTW.js";
|
|
2
2
|
export { e as default };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`../../combobox-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`../../combobox-Da7wBh3G.cjs`),t=require(`./combobox-constants.cjs`);exports.COMBOBOX_LABEL_SIZES=t.COMBOBOX_LABEL_SIZES,exports.DtCombobox=e.t;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});var e={EXTRA_SMALL:`xs`,SMALL:`sm`,DEFAULT:`md`},t={xs:`xs`,sm:`xs`,md:`sm`},n={xs:1.4,sm:.4,md:.2},r={MULTI_SELECT_SIZES:e,CHIP_SIZES:t,CHIP_TOP_POSITION:n};exports.CHIP_SIZES=t,exports.CHIP_TOP_POSITION=n,exports.MULTI_SELECT_SIZES=e,exports.default=r;
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});var e={EXTRA_SMALL:`xs`,SMALL:`sm`,DEFAULT:`md`},t={100:`xs`,200:`xs`,300:`sm`,xs:`xs`,sm:`xs`,md:`sm`},n={100:1.4,200:.4,300:.2,xs:1.4,sm:.4,md:.2},r={MULTI_SELECT_SIZES:e,CHIP_SIZES:t,CHIP_TOP_POSITION:n};exports.CHIP_SIZES=t,exports.CHIP_TOP_POSITION=n,exports.MULTI_SELECT_SIZES=e,exports.default=r;
|
|
2
2
|
//# sourceMappingURL=combobox-multi-select-constants.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox-multi-select-constants.cjs","names":[],"sources":["../../../components/combobox_multi_select/combobox_multi_select_constants.js"],"sourcesContent":["export const MULTI_SELECT_SIZES = {\n // Chip has no 'lg' and 'xl' size. So we don't support that in multi-select.\n EXTRA_SMALL: 'xs',\n SMALL: 'sm',\n DEFAULT: 'md',\n};\n\nexport const CHIP_SIZES = {\n xs: 'xs',\n sm: 'xs',\n md: 'sm',\n};\n\nexport const CHIP_TOP_POSITION = {\n xs: 1.4,\n sm: 0.4,\n md: 0.2,\n};\n\nexport default {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n};\n"],"mappings":"+FAAA,IAAa,EAAqB,CAEhC,YAAa,KACb,MAAO,KACP,QAAS,KACV,CAEY,EAAa,
|
|
1
|
+
{"version":3,"file":"combobox-multi-select-constants.cjs","names":[],"sources":["../../../components/combobox_multi_select/combobox_multi_select_constants.js"],"sourcesContent":["export const MULTI_SELECT_SIZES = {\n // Chip has no 'lg' and 'xl' size. So we don't support that in multi-select.\n EXTRA_SMALL: 'xs',\n SMALL: 'sm',\n DEFAULT: 'md',\n};\n\nexport const CHIP_SIZES = {\n // Numeric (preferred)\n 100: 'xs',\n 200: 'xs',\n 300: 'sm',\n // T-shirt aliases (deprecated)\n xs: 'xs',\n sm: 'xs',\n md: 'sm',\n};\n\nexport const CHIP_TOP_POSITION = {\n // Numeric (preferred)\n 100: 1.4,\n 200: 0.4,\n 300: 0.2,\n // T-shirt aliases (deprecated)\n xs: 1.4,\n sm: 0.4,\n md: 0.2,\n};\n\nexport default {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n};\n"],"mappings":"+FAAA,IAAa,EAAqB,CAEhC,YAAa,KACb,MAAO,KACP,QAAS,KACV,CAEY,EAAa,CAExB,IAAK,KACL,IAAK,KACL,IAAK,KAEL,GAAI,KACJ,GAAI,KACJ,GAAI,KACL,CAEY,EAAoB,CAE/B,IAAK,IACL,IAAK,GACL,IAAK,GAEL,GAAI,IACJ,GAAI,GACJ,GAAI,GACL,CAED,EAAe,CACb,qBACA,aACA,oBACD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox-multi-select-constants.js","names":[],"sources":["../../../components/combobox_multi_select/combobox_multi_select_constants.js"],"sourcesContent":["export const MULTI_SELECT_SIZES = {\n // Chip has no 'lg' and 'xl' size. So we don't support that in multi-select.\n EXTRA_SMALL: 'xs',\n SMALL: 'sm',\n DEFAULT: 'md',\n};\n\nexport const CHIP_SIZES = {\n xs: 'xs',\n sm: 'xs',\n md: 'sm',\n};\n\nexport const CHIP_TOP_POSITION = {\n xs: 1.4,\n sm: 0.4,\n md: 0.2,\n};\n\nexport default {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n};\n"],"mappings":";AAAA,IAAa,IAAqB;CAEhC,aAAa;CACb,OAAO;CACP,SAAS;CACV,EAEY,IAAa;
|
|
1
|
+
{"version":3,"file":"combobox-multi-select-constants.js","names":[],"sources":["../../../components/combobox_multi_select/combobox_multi_select_constants.js"],"sourcesContent":["export const MULTI_SELECT_SIZES = {\n // Chip has no 'lg' and 'xl' size. So we don't support that in multi-select.\n EXTRA_SMALL: 'xs',\n SMALL: 'sm',\n DEFAULT: 'md',\n};\n\nexport const CHIP_SIZES = {\n // Numeric (preferred)\n 100: 'xs',\n 200: 'xs',\n 300: 'sm',\n // T-shirt aliases (deprecated)\n xs: 'xs',\n sm: 'xs',\n md: 'sm',\n};\n\nexport const CHIP_TOP_POSITION = {\n // Numeric (preferred)\n 100: 1.4,\n 200: 0.4,\n 300: 0.2,\n // T-shirt aliases (deprecated)\n xs: 1.4,\n sm: 0.4,\n md: 0.2,\n};\n\nexport default {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n};\n"],"mappings":";AAAA,IAAa,IAAqB;CAEhC,aAAa;CACb,OAAO;CACP,SAAS;CACV,EAEY,IAAa;CAExB,KAAK;CACL,KAAK;CACL,KAAK;CAEL,IAAI;CACJ,IAAI;CACJ,IAAI;CACL,EAEY,IAAoB;CAE/B,KAAK;CACL,KAAK;CACL,KAAK;CAEL,IAAI;CACJ,IAAI;CACJ,IAAI;CACL,EAED,IAAe;CACb;CACA;CACA;CACD"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}}),require(`../../chunk-Bmb41Sf3.cjs`);const e=require(`../../common/validators/index.cjs`),t=require(`../../common/utils/index.cjs`),n=require(`../../_plugin-vue_export-helper-D8jCH6HB.cjs`),r=require(`../validation-messages/validation-messages.cjs`),i=require(`../chip/chip.cjs`),a=require(`../popover/popover-constants.cjs`),o=require(`../input/input.cjs`),s=require(`../combobox-with-popover/combobox-with-popover.cjs`),c=require(`./combobox-multi-select-constants.cjs`);let l=require(`vue`);var u={compatConfig:{MODE:3},name:`DtComboboxMultiSelect`,components:{DtComboboxWithPopover:s.default,DtInput:o.default,DtChip:i.default,DtValidationMessages:r.default},inheritAttrs:!1,props:{label:{type:String,required:!0},labelVisible:{type:Boolean,default:!0},description:{type:String,default:``},placeholder:{type:String,default:`Select one or start typing`},inputMessages:{type:Array,default:()=>[],validator:t=>e.validationMessageValidator(t)},showInputMessages:{type:Boolean,default:!0},loading:{type:Boolean,default:!1},loadingMessage:{type:String,default:`loading...`},showList:{type:Boolean,default:null},listMaxHeight:{type:String,default:`300px`},selectedItems:{type:Array,default:function(){return[]}},maxSelected:{type:Number,default:0},maxSelectedMessage:{type:Array,default:function(){return[]}},hasSuggestionList:{type:Boolean,default:!0},size:{type:String,default:`md`,validator:e=>Object.values(c.MULTI_SELECT_SIZES).includes(e)},appendTo:{type:[HTMLElement,String],default:`body`,validator:e=>a.POPOVER_APPEND_TO_VALUES.includes(e)||e instanceof HTMLElement},transition:{type:String,default:`fade`},collapseOnFocusOut:{type:Boolean,default:!1},listMaxWidth:{type:String,default:``},reservedRightSpace:{type:Number,default:64},chipMaxWidth:{type:String,default:``},inputClass:{type:[String,Object,Array],default:``},inputWrapperClass:{type:[String,Object,Array],default:``},disabled:{type:Boolean,default:!1}},emits:[`input`,`select`,`remove`,`max-selected`,`keyup`,`keydown`,`combobox-highlight`],data(){return{value:``,popoverOffset:[0,4],showValidationMessages:!1,resizeWindowObserver:null,initialInputHeight:null,CHIP_SIZES:c.CHIP_SIZES,hasSlotContent:t.hasSlotContent,inputFocused:!1,hideInputText:!1}},computed:{inputPlaceHolder(){return this.selectedItems?.length>0?``:this.placeholder},chipListeners(){return{keydown:e=>{this.onChipKeyDown(e),this.$emit(`keydown`,e)}}},inputListeners(){return{...t.extractVueListeners(this.$attrs),onInput:e=>{this.$emit(`input`,e),this.hasSuggestionList&&this.showComboboxList()},onKeydown:e=>{this.onInputKeyDown(e)},onKeyup:e=>{this.$emit(`keyup`,e)},onClick:()=>{this.hasSuggestionList&&this.showComboboxList()}}},chipWrapperClass(){return{[`d-recipe-combobox-multi-select__chip-wrapper-${this.size}--collapsed`]:!this.inputFocused&&this.collapseOnFocusOut}}},watch:{selectedItems:{deep:!0,handler:async function(){await this.initSelectedItems()}},chipMaxWidth:{async handler(){await this.initSelectedItems()}},async label(){await this.$nextTick(),this.setChipsTopPosition()},async description(){await this.$nextTick(),this.setChipsTopPosition()},size:{async handler(){await this.$nextTick();let e=this.getInput();this.revertInputPadding(e),this.initialInputHeight=e.getBoundingClientRect().height,this.setInputPadding(),this.setChipsTopPosition()}}},async mounted(){this.setInitialInputHeight(),this.resizeWindowObserver=new ResizeObserver(async()=>{this.setChipsTopPosition(),this.setInputPadding()}),this.resizeWindowObserver.observe(document.body),await this.initSelectedItems()},beforeUnmount(){this.resizeWindowObserver?.unobserve(document.body)},methods:{extractNonListeners:t.extractNonListeners,comboboxHighlight(e){this.$emit(`combobox-highlight`,e)},async initSelectedItems(){await this.$nextTick(),this.setInputPadding(),this.setChipsTopPosition(),this.setInputMinWidth(),this.checkMaxSelected()},onChipRemove(e){this.$emit(`remove`,e),this.$refs.input?.focus()},onComboboxSelect(e){this.loading||(this.value=``,this.$emit(`select`,e))},showComboboxList(){this.showList??this.$refs.comboboxWithPopover?.showComboboxList()},closeComboboxList(){this.showList??this.$refs.comboboxWithPopover?.closeComboboxList()},getChips(){if(!this.selectedItems.length||!this.$refs.chips)return null;let e=new Set;return this.selectedItems.map(n=>this.$refs.chips.find((r,i)=>e.has(i)?!1:t.returnFirstEl(r.$el)?.querySelector(`.d-chip__label`)?.textContent?.trim()===n?(e.add(i),!0):!1)).filter(Boolean).map(e=>t.returnFirstEl(e.$el))},getChipButtons(){let e=this.getChips();return e&&e.map(e=>t.returnFirstEl(e).querySelector(`button`))},getLastChipButton(){let e=this.getChipButtons();return e&&e[e.length-1]},getLastChip(){let e=this.getChips();return e&&e[e.length-1]},getFirstChip(){let e=this.getChips();return e&&e[0]},getInput(){return this.$refs.input?.$refs.input},onChipKeyDown(e){let t=e.code?.toLowerCase();t===`arrowleft`?this.navigateBetweenChips(e.target,!0):t===`arrowright`&&(e.target.id===this.getLastChipButton().id?this.moveFromChipToInput():this.navigateBetweenChips(e.target,!1))},onInputKeyDown(e){let t=e.code?.toLowerCase();if(this.selectedItems.length>0&&e.target.selectionStart===0){if(e.target.selectionEnd!==e.target.selectionStart)return;(t===`backspace`||t===`arrowleft`)&&this.moveFromInputToChip()}},moveFromInputToChip(){this.getLastChipButton().focus(),this.$refs.input?.blur(),this.closeComboboxList()},moveFromChipToInput(){this.getLastChipButton().blur(),this.$refs.input?.focus(),this.showComboboxList()},navigateBetweenChips(e,t){let n=this.getChipButtons().indexOf(e),r=t?n-1:n+1;r<0||r>=this.$refs.chips?.length||(this.getChipButtons()[n].blur(),this.getChipButtons()[r].focus(),this.closeComboboxList())},setChipsTopPosition(){let e=this.getInput();if(!e)return;let t=this.$refs.inputSlotWrapper,n=e.getBoundingClientRect().top-t.getBoundingClientRect().top,r=this.$refs.chipsWrapper;r.style.top=n-c.CHIP_TOP_POSITION[this.size]+`px`},setInputPadding(){let e=this.getLastChip(),t=this.getInput(),n=this.$refs.chipsWrapper;if(!t||(this.revertInputPadding(t),this.popoverOffset=[0,4],!e)||this.collapseOnFocusOut&&!this.inputFocused)return;let r=e.offsetLeft+this.getFullWidth(e),i=t.getBoundingClientRect().width-r;i>this.reservedRightSpace?t.style.paddingLeft=r+`px`:t.style.paddingLeft=`4px`;let a=n.getBoundingClientRect().height-4,o=e.getBoundingClientRect().height-4,s=i>this.reservedRightSpace?e.offsetTop+2:a+o-9;t.style.paddingTop=`${s}px`},revertInputPadding(e){e.style.paddingLeft=``,e.style.paddingTop=``,e.style.paddingBottom=``},getFullWidth(e){let t=window.getComputedStyle(e);return e.offsetWidth+parseInt(t.marginLeft)+parseInt(t.marginRight)},setInputMinWidth(){let e=this.getFirstChip(),t=this.getInput();t&&(e?t.style.minWidth=this.getFullWidth(e)+4+`px`:t.style.minWidth=``)},checkMaxSelected(){this.maxSelected!==0&&(this.selectedItems.length>this.maxSelected?(this.showValidationMessages=!0,this.$emit(`max-selected`)):this.showValidationMessages=!1)},setInitialInputHeight(){let e=this.getInput();e&&(this.initialInputHeight=e.getBoundingClientRect().height)},async handleInputFocusIn(){this.inputFocused=!0,this.collapseOnFocusOut&&(this.hideInputText=!1,await this.$nextTick(),this.setInputPadding())},async handleInputFocusOut(){if(this.inputFocused=!1,this.collapseOnFocusOut){this.hideInputText=!0;let e=this.getInput();if(!e||!e.style.paddingTop)return;this.revertInputPadding(e)}}}},d={ref:`header`},f={key:1,class:`d-recipe-combobox-multi-select__list--loading`},p={ref:`footer`};function m(e,t,n,r,i,a){let o=(0,l.resolveComponent)(`dt-chip`),s=(0,l.resolveComponent)(`dt-input`),c=(0,l.resolveComponent)(`dt-validation-messages`),u=(0,l.resolveComponent)(`dt-combobox-with-popover`);return(0,l.openBlock)(),(0,l.createBlock)(u,(0,l.mergeProps)({ref:`comboboxWithPopover`,label:n.label,"show-list":n.showList,"max-height":n.listMaxHeight,"max-width":n.listMaxWidth,"popover-offset":i.popoverOffset,"has-suggestion-list":n.hasSuggestionList,"content-width":`anchor`,"append-to":n.appendTo,transition:n.transition},a.extractNonListeners(e.$attrs),{onSelect:a.onComboboxSelect,onHighlight:a.comboboxHighlight}),(0,l.createSlots)({input:(0,l.withCtx)(({onInput:e})=>[(0,l.createElementVNode)(`span`,{ref:`inputSlotWrapper`,class:`d-recipe-combobox-multi-select__input-wrapper`,onFocusin:t[1]||(t[1]=(...e)=>a.handleInputFocusIn&&a.handleInputFocusIn(...e)),onFocusout:t[2]||(t[2]=(...e)=>a.handleInputFocusOut&&a.handleInputFocusOut(...e))},[(0,l.createElementVNode)(`span`,{ref:`chipsWrapper`,class:(0,l.normalizeClass)([`d-recipe-combobox-multi-select__chip-wrapper`,a.chipWrapperClass])},[((0,l.openBlock)(!0),(0,l.createElementBlock)(l.Fragment,null,(0,l.renderList)(n.selectedItems,(e,t)=>((0,l.openBlock)(),(0,l.createBlock)(o,(0,l.mergeProps)({ref_for:!0,ref:`chips`,key:`${t}-${e}`,"label-class":[`d-chip__label`],class:[`d-recipe-combobox-multi-select__chip`,{"d-recipe-combobox-multi-select__chip--truncate":!!n.chipMaxWidth}],style:{maxWidth:n.chipMaxWidth},size:i.CHIP_SIZES[n.size],disabled:n.disabled},(0,l.toHandlers)(a.chipListeners),{onKeydown:(0,l.withKeys)(t=>a.onChipRemove(e),[`backspace`]),onClose:t=>a.onChipRemove(e)}),{default:(0,l.withCtx)(()=>[(0,l.createTextVNode)((0,l.toDisplayString)(e),1)]),_:2},1040,[`class`,`style`,`size`,`disabled`,`onKeydown`,`onClose`]))),128))],2),(0,l.createVNode)(s,(0,l.mergeProps)({ref:`input`,modelValue:i.value,"onUpdate:modelValue":t[0]||(t[0]=e=>i.value=e),class:`d-recipe-combobox-multi-select__input`,"input-class":[n.inputClass,{"d-recipe-combobox-multi-select__input--hidden":i.hideInputText}],"input-wrapper-class":n.inputWrapperClass,disabled:n.disabled,"aria-label":n.label,label:n.labelVisible?n.label:``,description:n.description,placeholder:a.inputPlaceHolder,"show-messages":n.showInputMessages,messages:n.inputMessages,size:n.size},a.inputListeners,{onInput:e}),null,16,[`modelValue`,`input-class`,`input-wrapper-class`,`disabled`,`aria-label`,`label`,`description`,`placeholder`,`show-messages`,`messages`,`size`,`onInput`]),(0,l.createVNode)(c,{"validation-messages":n.maxSelectedMessage,"show-messages":i.showValidationMessages},null,8,[`validation-messages`,`show-messages`])],544)]),list:(0,l.withCtx)(()=>[(0,l.createElementVNode)(`div`,{ref:`list`,class:`d-recipe-combobox-multi-select__list`,onMousedown:t[3]||(t[3]=(0,l.withModifiers)(()=>{},[`prevent`]))},[n.loading?((0,l.openBlock)(),(0,l.createElementBlock)(`div`,f,(0,l.toDisplayString)(n.loadingMessage),1)):(0,l.renderSlot)(e.$slots,`list`,{key:0})],544)]),_:2},[i.hasSlotContent(e.$slots.header)?{name:`header`,fn:(0,l.withCtx)(()=>[(0,l.createElementVNode)(`div`,d,[(0,l.renderSlot)(e.$slots,`header`)],512)]),key:`0`}:void 0,i.hasSlotContent(e.$slots.footer)?{name:`footer`,fn:(0,l.withCtx)(()=>[(0,l.createElementVNode)(`div`,p,[(0,l.renderSlot)(e.$slots,`footer`)],512)]),key:`1`}:void 0]),1040,[`label`,`show-list`,`max-height`,`max-width`,`popover-offset`,`has-suggestion-list`,`append-to`,`transition`,`onSelect`,`onHighlight`])}var h=n.t(u,[[`render`,m]]);exports.default=h;
|
|
1
|
+
Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}}),require(`../../chunk-Bmb41Sf3.cjs`);const e=require(`../../common/constants/sizes.cjs`),t=require(`../../common/validators/index.cjs`),n=require(`../../common/utils/index.cjs`),r=require(`../../_plugin-vue_export-helper-D8jCH6HB.cjs`),i=require(`../validation-messages/validation-messages.cjs`),a=require(`../chip/chip.cjs`),o=require(`../popover/popover-constants.cjs`),s=require(`../input/input.cjs`),c=require(`../combobox-with-popover/combobox-with-popover.cjs`),l=require(`./combobox-multi-select-constants.cjs`);let u=require(`vue`);var d={compatConfig:{MODE:3},name:`DtComboboxMultiSelect`,components:{DtComboboxWithPopover:c.default,DtInput:s.default,DtChip:a.default,DtValidationMessages:i.default},inheritAttrs:!1,props:{label:{type:String,required:!0},showLabel:{type:Boolean,default:!0},description:{type:String,default:``},placeholder:{type:String,default:`Select one or start typing`},inputMessages:{type:Array,default:()=>[],validator:e=>t.validationMessageValidator(e)},showInputMessages:{type:Boolean,default:!0},loading:{type:Boolean,default:!1},loadingMessage:{type:String,default:`loading...`},showList:{type:Boolean,default:null},listMaxHeight:{type:String,default:`300px`},selectedItems:{type:Array,default:function(){return[]}},maxSelected:{type:Number,default:0},maxSelectedMessage:{type:Array,default:function(){return[]}},hasSuggestionList:{type:Boolean,default:!0},size:{type:[String,Number],default:300,validator:e=>Object.keys(l.CHIP_SIZES).includes(String(e))},appendTo:{type:[HTMLElement,String],default:`body`,validator:e=>o.POPOVER_APPEND_TO_VALUES.includes(e)||e instanceof HTMLElement},transition:{type:String,default:`fade`},collapseOnFocusOut:{type:Boolean,default:!1},listMaxWidth:{type:String,default:``},reservedRightSpace:{type:Number,default:64},chipMaxWidth:{type:String,default:``},inputClass:{type:[String,Object,Array],default:``},inputWrapperClass:{type:[String,Object,Array],default:``},disabled:{type:Boolean,default:!1}},emits:[`input`,`select`,`remove`,`max-selected`,`keyup`,`keydown`,`combobox-highlight`],data(){return{value:``,popoverOffset:[0,4],showValidationMessages:!1,resizeWindowObserver:null,initialInputHeight:null,CHIP_SIZES:l.CHIP_SIZES,hasSlotContent:n.hasSlotContent,inputFocused:!1,hideInputText:!1}},computed:{inputPlaceHolder(){return this.selectedItems?.length>0?``:this.placeholder},chipListeners(){return{keydown:e=>{this.onChipKeyDown(e),this.$emit(`keydown`,e)}}},inputListeners(){return{...n.extractVueListeners(this.$attrs),onInput:e=>{this.$emit(`input`,e),this.hasSuggestionList&&this.showComboboxList()},onKeydown:e=>{this.onInputKeyDown(e)},onKeyup:e=>{this.$emit(`keyup`,e)},onClick:()=>{this.hasSuggestionList&&this.showComboboxList()}}},chipWrapperClass(){return{[`d-recipe-combobox-multi-select__chip-wrapper-${e.COMPONENT_SIZES[String(this.size)]||this.size}--collapsed`]:!this.inputFocused&&this.collapseOnFocusOut}}},watch:{selectedItems:{deep:!0,handler:async function(){await this.initSelectedItems()}},chipMaxWidth:{async handler(){await this.initSelectedItems()}},async label(){await this.$nextTick(),this.setChipsTopPosition()},async description(){await this.$nextTick(),this.setChipsTopPosition()},size:{async handler(){await this.$nextTick();let e=this.getInput();this.revertInputPadding(e),this.initialInputHeight=e.getBoundingClientRect().height,this.setInputPadding(),this.setChipsTopPosition()}}},async mounted(){this.setInitialInputHeight(),this.resizeWindowObserver=new ResizeObserver(async()=>{this.setChipsTopPosition(),this.setInputPadding()}),this.resizeWindowObserver.observe(document.body),await this.initSelectedItems()},beforeUnmount(){this.resizeWindowObserver?.unobserve(document.body)},methods:{extractNonListeners:n.extractNonListeners,comboboxHighlight(e){this.$emit(`combobox-highlight`,e)},async initSelectedItems(){await this.$nextTick(),this.setInputPadding(),this.setChipsTopPosition(),this.setInputMinWidth(),this.checkMaxSelected()},onChipRemove(e){this.$emit(`remove`,e),this.$refs.input?.focus()},onComboboxSelect(e){this.loading||(this.value=``,this.$emit(`select`,e))},showComboboxList(){this.showList??this.$refs.comboboxWithPopover?.showComboboxList()},closeComboboxList(){this.showList??this.$refs.comboboxWithPopover?.closeComboboxList()},getChips(){if(!this.selectedItems.length||!this.$refs.chips)return null;let e=new Set;return this.selectedItems.map(t=>this.$refs.chips.find((r,i)=>e.has(i)?!1:n.returnFirstEl(r.$el)?.querySelector(`.d-chip__label`)?.textContent?.trim()===t?(e.add(i),!0):!1)).filter(Boolean).map(e=>n.returnFirstEl(e.$el))},getChipButtons(){let e=this.getChips();return e&&e.map(e=>n.returnFirstEl(e).querySelector(`button`))},getLastChipButton(){let e=this.getChipButtons();return e&&e[e.length-1]},getLastChip(){let e=this.getChips();return e&&e[e.length-1]},getFirstChip(){let e=this.getChips();return e&&e[0]},getInput(){return this.$refs.input?.$refs.input},onChipKeyDown(e){let t=e.code?.toLowerCase();t===`arrowleft`?this.navigateBetweenChips(e.target,!0):t===`arrowright`&&(e.target.id===this.getLastChipButton().id?this.moveFromChipToInput():this.navigateBetweenChips(e.target,!1))},onInputKeyDown(e){let t=e.code?.toLowerCase();if(this.selectedItems.length>0&&e.target.selectionStart===0){if(e.target.selectionEnd!==e.target.selectionStart)return;(t===`backspace`||t===`arrowleft`)&&this.moveFromInputToChip()}},moveFromInputToChip(){this.getLastChipButton().focus(),this.$refs.input?.blur(),this.closeComboboxList()},moveFromChipToInput(){this.getLastChipButton().blur(),this.$refs.input?.focus(),this.showComboboxList()},navigateBetweenChips(e,t){let n=this.getChipButtons().indexOf(e),r=t?n-1:n+1;r<0||r>=this.$refs.chips?.length||(this.getChipButtons()[n].blur(),this.getChipButtons()[r].focus(),this.closeComboboxList())},setChipsTopPosition(){let e=this.getInput();if(!e)return;let t=this.$refs.inputSlotWrapper,n=e.getBoundingClientRect().top-t.getBoundingClientRect().top,r=this.$refs.chipsWrapper;r.style.top=n-l.CHIP_TOP_POSITION[String(this.size)]+`px`},setInputPadding(){let e=this.getLastChip(),t=this.getInput(),n=this.$refs.chipsWrapper;if(!t||(this.revertInputPadding(t),this.popoverOffset=[0,4],!e)||this.collapseOnFocusOut&&!this.inputFocused)return;let r=e.offsetLeft+this.getFullWidth(e),i=t.getBoundingClientRect().width-r;i>this.reservedRightSpace?t.style.paddingInlineStart=r+`px`:t.style.paddingInlineStart=`4px`;let a=n.getBoundingClientRect().height-4,o=e.getBoundingClientRect().height-4,s=i>this.reservedRightSpace?e.offsetTop+2:a+o-9;t.style.paddingBlockStart=`${s}px`},revertInputPadding(e){e.style.paddingInlineStart=``,e.style.paddingBlockStart=``,e.style.paddingBlockEnd=``},getFullWidth(e){let t=window.getComputedStyle(e);return e.offsetWidth+parseInt(t.marginLeft)+parseInt(t.marginRight)},setInputMinWidth(){let e=this.getFirstChip(),t=this.getInput();t&&(e?t.style.minWidth=this.getFullWidth(e)+4+`px`:t.style.minWidth=``)},checkMaxSelected(){this.maxSelected!==0&&(this.selectedItems.length>this.maxSelected?(this.showValidationMessages=!0,this.$emit(`max-selected`)):this.showValidationMessages=!1)},setInitialInputHeight(){let e=this.getInput();e&&(this.initialInputHeight=e.getBoundingClientRect().height)},async handleInputFocusIn(){this.inputFocused=!0,this.collapseOnFocusOut&&(this.hideInputText=!1,await this.$nextTick(),this.setInputPadding())},async handleInputFocusOut(){if(this.inputFocused=!1,this.collapseOnFocusOut){this.hideInputText=!0;let e=this.getInput();if(!e||!e.style.paddingTop)return;this.revertInputPadding(e)}}}},f={ref:`header`},p={key:1,class:`d-recipe-combobox-multi-select__list--loading`},m={ref:`footer`};function h(e,t,n,r,i,a){let o=(0,u.resolveComponent)(`dt-chip`),s=(0,u.resolveComponent)(`dt-input`),c=(0,u.resolveComponent)(`dt-validation-messages`),l=(0,u.resolveComponent)(`dt-combobox-with-popover`);return(0,u.openBlock)(),(0,u.createBlock)(l,(0,u.mergeProps)({ref:`comboboxWithPopover`,label:n.label,"show-list":n.showList,"max-height":n.listMaxHeight,"max-width":n.listMaxWidth,"popover-offset":i.popoverOffset,"has-suggestion-list":n.hasSuggestionList,"content-width":`anchor`,"append-to":n.appendTo,transition:n.transition},a.extractNonListeners(e.$attrs),{onSelect:a.onComboboxSelect,onHighlight:a.comboboxHighlight}),(0,u.createSlots)({input:(0,u.withCtx)(({onInput:e})=>[(0,u.createElementVNode)(`span`,{ref:`inputSlotWrapper`,class:`d-recipe-combobox-multi-select__input-wrapper`,onFocusin:t[1]||(t[1]=(...e)=>a.handleInputFocusIn&&a.handleInputFocusIn(...e)),onFocusout:t[2]||(t[2]=(...e)=>a.handleInputFocusOut&&a.handleInputFocusOut(...e))},[(0,u.createElementVNode)(`span`,{ref:`chipsWrapper`,class:(0,u.normalizeClass)([`d-recipe-combobox-multi-select__chip-wrapper`,a.chipWrapperClass])},[((0,u.openBlock)(!0),(0,u.createElementBlock)(u.Fragment,null,(0,u.renderList)(n.selectedItems,(e,t)=>((0,u.openBlock)(),(0,u.createBlock)(o,(0,u.mergeProps)({ref_for:!0,ref:`chips`,key:`${t}-${e}`,"label-class":[`d-chip__label`],class:[`d-recipe-combobox-multi-select__chip`,{"d-recipe-combobox-multi-select__chip--truncate":!!n.chipMaxWidth}],style:{maxWidth:n.chipMaxWidth},size:i.CHIP_SIZES[String(n.size)],disabled:n.disabled},(0,u.toHandlers)(a.chipListeners),{onKeydown:(0,u.withKeys)(t=>a.onChipRemove(e),[`backspace`]),onClose:t=>a.onChipRemove(e)}),{default:(0,u.withCtx)(()=>[(0,u.createTextVNode)((0,u.toDisplayString)(e),1)]),_:2},1040,[`class`,`style`,`size`,`disabled`,`onKeydown`,`onClose`]))),128))],2),(0,u.createVNode)(s,(0,u.mergeProps)({ref:`input`,modelValue:i.value,"onUpdate:modelValue":t[0]||(t[0]=e=>i.value=e),class:`d-recipe-combobox-multi-select__input`,"input-class":[n.inputClass,{"d-recipe-combobox-multi-select__input--hidden":i.hideInputText}],"input-wrapper-class":n.inputWrapperClass,disabled:n.disabled,"aria-label":n.label,label:n.showLabel?n.label:``,description:n.description,placeholder:a.inputPlaceHolder,"show-messages":n.showInputMessages,messages:n.inputMessages,size:n.size},a.inputListeners,{onInput:e}),null,16,[`modelValue`,`input-class`,`input-wrapper-class`,`disabled`,`aria-label`,`label`,`description`,`placeholder`,`show-messages`,`messages`,`size`,`onInput`]),(0,u.createVNode)(c,{"validation-messages":n.maxSelectedMessage,"show-messages":i.showValidationMessages},null,8,[`validation-messages`,`show-messages`])],544)]),list:(0,u.withCtx)(()=>[(0,u.createElementVNode)(`div`,{ref:`list`,class:`d-recipe-combobox-multi-select__list`,onMousedown:t[3]||(t[3]=(0,u.withModifiers)(()=>{},[`prevent`]))},[n.loading?((0,u.openBlock)(),(0,u.createElementBlock)(`div`,p,(0,u.toDisplayString)(n.loadingMessage),1)):(0,u.renderSlot)(e.$slots,`list`,{key:0})],544)]),_:2},[i.hasSlotContent(e.$slots.header)?{name:`header`,fn:(0,u.withCtx)(()=>[(0,u.createElementVNode)(`div`,f,[(0,u.renderSlot)(e.$slots,`header`)],512)]),key:`0`}:void 0,i.hasSlotContent(e.$slots.footer)?{name:`footer`,fn:(0,u.withCtx)(()=>[(0,u.createElementVNode)(`div`,m,[(0,u.renderSlot)(e.$slots,`footer`)],512)]),key:`1`}:void 0]),1040,[`label`,`show-list`,`max-height`,`max-width`,`popover-offset`,`has-suggestion-list`,`append-to`,`transition`,`onSelect`,`onHighlight`])}var g=r.t(d,[[`render`,h]]);exports.default=g;
|
|
2
2
|
//# sourceMappingURL=combobox-multi-select.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox-multi-select.cjs","names":[],"sources":["../../../components/combobox_multi_select/combobox_multi_select.vue"],"sourcesContent":["<!-- eslint-disable vue/no-static-inline-styles -->\n<template>\n <dt-combobox-with-popover\n ref=\"comboboxWithPopover\"\n :label=\"label\"\n :show-list=\"showList\"\n :max-height=\"listMaxHeight\"\n :max-width=\"listMaxWidth\"\n :popover-offset=\"popoverOffset\"\n :has-suggestion-list=\"hasSuggestionList\"\n content-width=\"anchor\"\n :append-to=\"appendTo\"\n :transition=\"transition\"\n v-bind=\"extractNonListeners($attrs)\"\n @select=\"onComboboxSelect\"\n @highlight=\"comboboxHighlight\"\n >\n <template #input=\"{ onInput }\">\n <span\n ref=\"inputSlotWrapper\"\n class=\"d-recipe-combobox-multi-select__input-wrapper\"\n @focusin=\"handleInputFocusIn\"\n @focusout=\"handleInputFocusOut\"\n >\n <span\n ref=\"chipsWrapper\"\n :class=\"['d-recipe-combobox-multi-select__chip-wrapper', chipWrapperClass]\"\n >\n <dt-chip\n v-for=\"(item, index) in selectedItems\"\n ref=\"chips\"\n :key=\"`${index}-${item}`\"\n :label-class=\"['d-chip__label']\"\n :class=\"[\n 'd-recipe-combobox-multi-select__chip',\n { 'd-recipe-combobox-multi-select__chip--truncate': !!chipMaxWidth },\n ]\"\n :style=\"{ maxWidth: chipMaxWidth }\"\n :size=\"CHIP_SIZES[size]\"\n :disabled=\"disabled\"\n v-on=\"chipListeners\"\n @keydown.backspace=\"onChipRemove(item)\"\n @close=\"onChipRemove(item)\"\n >\n {{ item }}\n </dt-chip>\n </span>\n\n <dt-input\n ref=\"input\"\n v-model=\"value\"\n class=\"d-recipe-combobox-multi-select__input\"\n :input-class=\"[\n inputClass, {\n 'd-recipe-combobox-multi-select__input--hidden': hideInputText,\n }]\"\n :input-wrapper-class=\"inputWrapperClass\"\n :disabled=\"disabled\"\n :aria-label=\"label\"\n :label=\"labelVisible ? label : ''\"\n :description=\"description\"\n :placeholder=\"inputPlaceHolder\"\n :show-messages=\"showInputMessages\"\n :messages=\"inputMessages\"\n :size=\"size\"\n v-bind=\"inputListeners\"\n @input=\"onInput\"\n />\n\n <dt-validation-messages\n :validation-messages=\"maxSelectedMessage\"\n :show-messages=\"showValidationMessages\"\n />\n </span>\n </template>\n\n <!-- @slot slot for popover header -->\n <template\n v-if=\"hasSlotContent($slots.header)\"\n #header\n >\n <div ref=\"header\">\n <slot name=\"header\" />\n </div>\n </template>\n\n <!-- @slot slot for popover list -->\n <template #list>\n <div\n ref=\"list\"\n class=\"d-recipe-combobox-multi-select__list\"\n @mousedown.prevent\n >\n <slot\n v-if=\"!loading\"\n name=\"list\"\n />\n <div\n v-else\n class=\"d-recipe-combobox-multi-select__list--loading\"\n >\n {{ loadingMessage }}\n </div>\n </div>\n </template>\n\n <!-- @slot slot for popover footer -->\n <template\n v-if=\"hasSlotContent($slots.footer)\"\n #footer\n >\n <div ref=\"footer\">\n <slot name=\"footer\" />\n </div>\n </template>\n </dt-combobox-with-popover>\n</template>\n\n<script>\n/* eslint-disable max-lines */\nimport DtComboboxWithPopover from '@/components/combobox_with_popover/combobox_with_popover.vue';\nimport DtInput from '@/components/input/input.vue';\nimport DtChip from '@/components/chip/chip.vue';\nimport DtValidationMessages from '@/components/validation_messages/validation_messages.vue';\nimport { validationMessageValidator } from '@/common/validators';\nimport { extractVueListeners, extractNonListeners, hasSlotContent, returnFirstEl } from '@/common/utils';\nimport {\n POPOVER_APPEND_TO_VALUES,\n} from '@/components/popover/popover_constants';\nimport {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n} from './combobox_multi_select_constants';\n\nexport default {\n compatConfig: { MODE: 3 },\n name: 'DtComboboxMultiSelect',\n\n components: {\n DtComboboxWithPopover,\n DtInput,\n DtChip,\n DtValidationMessages,\n },\n\n inheritAttrs: false,\n\n props: {\n /**\n * String to use for the input label.\n */\n label: {\n type: String,\n required: true,\n },\n\n /**\n * Determines visibility of input label.\n * @values true, false\n */\n labelVisible: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Description for the input\n */\n description: {\n type: String,\n default: '',\n },\n\n /**\n * Input placeholder\n */\n placeholder: {\n type: String,\n default: 'Select one or start typing',\n },\n\n /**\n * Input validation messages\n */\n inputMessages: {\n type: Array,\n default: () => [],\n validator: inputMessages => {\n return validationMessageValidator(inputMessages);\n },\n },\n\n /**\n * Show input validation message\n */\n showInputMessages: {\n type: Boolean,\n default: true,\n },\n\n // @TODO: https://dialpad.atlassian.net/browse/DP-52324\n // type: {\n // type: String,\n // values: ['input', 'select'],\n // default: 'select',\n // },\n\n /**\n * Determines if the list is loading\n */\n loading: {\n type: Boolean,\n default: false,\n },\n\n /**\n * The message when the list is loading\n */\n loadingMessage: {\n type: String,\n default: 'loading...',\n },\n\n /**\n * Determines when to show the list element and also controls the aria-expanded attribute.\n * Leaving this null will have the combobox trigger on input focus by default.\n * If you set this value, the default trigger behavior will be disabled and you can\n * control it as you need.\n */\n showList: {\n type: Boolean,\n default: null,\n },\n\n /**\n * Determines maximum height for the popover before overflow.\n * Possible units rem|px|em\n */\n listMaxHeight: {\n type: String,\n default: '300px',\n },\n\n /**\n * The selected items\n */\n selectedItems: {\n type: Array,\n default: function () { return []; },\n },\n\n /**\n * Would be the maximum number of selections you can make. 0 is unlimited\n */\n maxSelected: {\n type: Number,\n default: 0,\n },\n\n /**\n * Max select message when the max selections is exceeded with the structure:\n * `[{\"message\": string, \"type\": VALIDATION_MESSAGE_TYPES }]`\n */\n maxSelectedMessage: {\n type: Array,\n default: function () { return []; },\n },\n\n /**\n * Displays the list when the combobox is focused, before the user has typed anything.\n * When this is enabled the list will not close after selection.\n */\n hasSuggestionList: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Size of the chip, one of `xs`, `sm`, `md`\n */\n size: {\n type: String,\n default: 'md',\n validator: (t) => Object.values(MULTI_SELECT_SIZES).includes(t),\n },\n\n /**\n * Sets the element to which the popover is going to append to.\n * 'body' will append to the nearest body (supports shadow DOM).\n * @values 'body', 'parent', HTMLElement,\n */\n appendTo: {\n type: [HTMLElement, String],\n default: 'body',\n validator: appendTo => {\n return POPOVER_APPEND_TO_VALUES.includes(appendTo) ||\n (appendTo instanceof HTMLElement);\n },\n },\n\n /**\n * Named transition when the content display is toggled.\n * @see DtLazyShow\n */\n transition: {\n type: String,\n default: 'fade',\n },\n\n /**\n * Determines whether the combobox should collapse to a single when losing focus.\n * @type {boolean}\n */\n collapseOnFocusOut: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Determines maximum width for the popover before overflow.\n * Possible units rem|px|em\n */\n listMaxWidth: {\n type: String,\n default: '',\n },\n\n /**\n * Amount of reserved space (in px) on the right side of the input\n * before the chips and the input caret jump to the next line.\n * default is 64\n */\n reservedRightSpace: {\n type: Number,\n default: 64,\n },\n\n /**\n * Determines the maximum width of a single chip. If the text within this chip exceeds the value\n * it will be truncated with ellipses.\n * Possible units rem|px|em\n */\n chipMaxWidth: {\n type: String,\n default: '',\n },\n\n /**\n * Additional class name for the input element.\n * Can accept String, Object, and Array, i.e. has the\n * same API as Vue's built-in handling of the class attribute.\n */\n inputClass: {\n type: [String, Object, Array],\n default: '',\n },\n\n /**\n * Additional class name for the input wrapper element.\n * Can accept all of String, Object, and Array, i.e. has the\n * same api as Vue's built-in handling of the class attribute.\n */\n inputWrapperClass: {\n type: [String, Object, Array],\n default: '',\n },\n\n /**\n * When true, disables the underlying input.\n */\n disabled: {\n type: Boolean,\n default: false,\n },\n },\n\n emits: [\n /**\n * Native input event\n *\n * @event input\n * @type {String }\n */\n 'input',\n\n /**\n * Event fired when item selected\n *\n * @event select\n * @type {Number}\n */\n 'select',\n\n /**\n * Event fired when item removed\n *\n * @event remove\n * @type {String}\n */\n 'remove',\n\n /**\n * Event fired when max selected items limit is reached\n *\n * @event max-selected\n * @type {Object}\n */\n 'max-selected',\n\n /**\n * Native keyup event\n *\n * @event keyup\n * @type {KeyboardEvent}\n */\n 'keyup',\n\n /**\n * Native keydown event\n *\n * @event keydown\n * @type {KeyboardEvent}\n */\n 'keydown',\n\n /**\n * Event fired when combobox item is highlighted\n *\n * @event combobox-highlight\n * @type {Object}\n */\n 'combobox-highlight',\n ],\n\n data () {\n return {\n value: '',\n popoverOffset: [0, 4],\n showValidationMessages: false,\n resizeWindowObserver: null,\n initialInputHeight: null,\n CHIP_SIZES,\n hasSlotContent,\n inputFocused: false,\n hideInputText: false,\n };\n },\n\n computed: {\n inputPlaceHolder () {\n return this.selectedItems?.length > 0 ? '' : this.placeholder;\n },\n\n chipListeners () {\n return {\n keydown: event => {\n this.onChipKeyDown(event);\n this.$emit('keydown', event);\n },\n };\n },\n\n inputListeners () {\n return {\n ...extractVueListeners(this.$attrs),\n onInput: event => {\n this.$emit('input', event);\n if (this.hasSuggestionList) {\n this.showComboboxList();\n }\n },\n\n onKeydown: event => {\n this.onInputKeyDown(event);\n },\n\n onKeyup: event => {\n this.$emit('keyup', event);\n },\n\n onClick: () => {\n if (this.hasSuggestionList) {\n this.showComboboxList();\n }\n },\n };\n },\n\n chipWrapperClass () {\n return {\n [`d-recipe-combobox-multi-select__chip-wrapper-${this.size}--collapsed`]: !this.inputFocused && this.collapseOnFocusOut,\n };\n },\n },\n\n watch: {\n selectedItems: {\n deep: true,\n handler: async function () {\n await this.initSelectedItems();\n },\n },\n\n chipMaxWidth: {\n async handler () {\n await this.initSelectedItems();\n },\n },\n\n async label () {\n await this.$nextTick();\n // Adjust the chips position if label changed\n this.setChipsTopPosition();\n },\n\n async description () {\n await this.$nextTick();\n // Adjust the chips position if description changed\n this.setChipsTopPosition();\n },\n\n size: {\n async handler () {\n await this.$nextTick();\n const input = this.getInput();\n this.revertInputPadding(input);\n this.initialInputHeight = input.getBoundingClientRect().height;\n this.setInputPadding();\n this.setChipsTopPosition();\n },\n },\n },\n\n async mounted () {\n this.setInitialInputHeight();\n // Recalculate chip position and input padding when resizing window\n this.resizeWindowObserver = new ResizeObserver(async () => {\n this.setChipsTopPosition();\n this.setInputPadding();\n });\n this.resizeWindowObserver.observe(document.body);\n\n await this.initSelectedItems();\n },\n\n beforeUnmount () {\n this.resizeWindowObserver?.unobserve(document.body);\n },\n\n methods: {\n extractNonListeners,\n comboboxHighlight (highlightIndex) {\n this.$emit('combobox-highlight', highlightIndex);\n },\n\n async initSelectedItems () {\n await this.$nextTick();\n this.setInputPadding();\n this.setChipsTopPosition();\n this.setInputMinWidth();\n this.checkMaxSelected();\n },\n\n onChipRemove (item) {\n this.$emit('remove', item);\n this.$refs.input?.focus();\n },\n\n onComboboxSelect (i) {\n if (this.loading) return;\n this.value = '';\n this.$emit('select', i);\n },\n\n showComboboxList () {\n if (this.showList != null) { return; }\n this.$refs.comboboxWithPopover?.showComboboxList();\n },\n\n closeComboboxList () {\n if (this.showList != null) { return; }\n this.$refs.comboboxWithPopover?.closeComboboxList();\n },\n\n getChips () {\n if (!this.selectedItems.length || !this.$refs.chips) return null;\n\n // Use the order from selectedItems to not rely on DOM order which may be stale.\n // Track matched indices to handle duplicate item names correctly.\n const matched = new Set();\n const chips = this.selectedItems.map(item => {\n return this.$refs.chips.find((chip, index) => {\n if (matched.has(index)) return false;\n const chipLabel = returnFirstEl(chip.$el)?.querySelector('.d-chip__label')?.textContent?.trim();\n if (chipLabel === item) {\n matched.add(index);\n return true;\n }\n return false;\n });\n });\n return chips.filter(Boolean).map(chip => returnFirstEl(chip.$el));\n },\n\n getChipButtons () {\n const chips = this.getChips();\n return chips && chips.map(chip => returnFirstEl(chip).querySelector('button'));\n },\n\n getLastChipButton () {\n const chipButtons = this.getChipButtons();\n return chipButtons && chipButtons[chipButtons.length - 1];\n },\n\n getLastChip () {\n const chips = this.getChips();\n return chips && chips[chips.length - 1];\n },\n\n getFirstChip () {\n const chips = this.getChips();\n return chips && chips[0];\n },\n\n getInput () {\n return this.$refs.input?.$refs.input;\n },\n\n onChipKeyDown (event) {\n const key = event.code?.toLowerCase();\n if (key === 'arrowleft') {\n // Move to the previous chip\n this.navigateBetweenChips(event.target, true);\n } else if (key === 'arrowright') {\n if (event.target.id === this.getLastChipButton().id) {\n // Move to the input if it's the last chip\n this.moveFromChipToInput();\n } else {\n // Move to the next chip\n this.navigateBetweenChips(event.target, false);\n }\n }\n },\n\n onInputKeyDown (event) {\n const key = event.code?.toLowerCase();\n // If the cursor is at the start of the text,\n // press 'backspace' or 'left' focuses the last chip\n if (this.selectedItems.length > 0 && event.target.selectionStart === 0) {\n // if there is selected text, do not focus the last chip\n if (event.target.selectionEnd !== event.target.selectionStart) {\n return;\n }\n if (key === 'backspace' || key === 'arrowleft') {\n this.moveFromInputToChip();\n }\n }\n },\n\n moveFromInputToChip () {\n this.getLastChipButton().focus();\n this.$refs.input?.blur();\n this.closeComboboxList();\n },\n\n moveFromChipToInput () {\n this.getLastChipButton().blur();\n this.$refs.input?.focus();\n this.showComboboxList();\n },\n\n navigateBetweenChips (target, toLeft) {\n const from = this.getChipButtons().indexOf(target);\n const to = toLeft ? from - 1 : from + 1;\n if (to < 0 || to >= this.$refs.chips?.length) {\n return;\n }\n this.getChipButtons()[from].blur();\n this.getChipButtons()[to].focus();\n this.closeComboboxList();\n },\n\n setChipsTopPosition () {\n // To place the chips in the input box\n // The chip \"top\" position should be the same line as the input box\n const input = this.getInput();\n if (!input) return;\n const inputSlotWrapper = this.$refs.inputSlotWrapper;\n const top = input.getBoundingClientRect().top -\n inputSlotWrapper.getBoundingClientRect().top;\n const chipsWrapper = this.$refs.chipsWrapper;\n chipsWrapper.style.top = (top - CHIP_TOP_POSITION[this.size]) + 'px';\n },\n\n setInputPadding () {\n const lastChip = this.getLastChip();\n const input = this.getInput();\n const chipsWrapper = this.$refs.chipsWrapper;\n if (!input) return;\n this.revertInputPadding(input);\n this.popoverOffset = [0, 4];\n if (!lastChip) return;\n // Avoid adding extra padding when the input is not focused if collapseOnFocusOut is true\n // This ensures the input returns to its original state when resizing\n if (this.collapseOnFocusOut && !this.inputFocused) return;\n\n // Get the position of the last chip\n // The input cursor should be the same \"top\" as that chip and next besides it\n const left = lastChip.offsetLeft + this.getFullWidth(lastChip);\n const spaceLeft = input.getBoundingClientRect().width - left;\n // input.style.paddingLeft = left + 'px';\n\n if (spaceLeft > this.reservedRightSpace) {\n input.style.paddingLeft = left + 'px';\n } else {\n input.style.paddingLeft = '4px';\n }\n\n // Get the chip wrapper height minus the 4px padding\n const chipsWrapperHeight = chipsWrapper.getBoundingClientRect().height - 4;\n const lastChipHeight = lastChip.getBoundingClientRect().height - 4;\n\n // Get lastChip offsetTop plus 2px of the input padding.\n const top = spaceLeft > this.reservedRightSpace\n ? lastChip.offsetTop + 2\n : (chipsWrapperHeight + lastChipHeight - 9);\n\n input.style.paddingTop = `${top}px`;\n },\n\n revertInputPadding (input) {\n input.style.paddingLeft = '';\n input.style.paddingTop = '';\n input.style.paddingBottom = '';\n },\n\n getFullWidth (el) {\n const styles = window.getComputedStyle(el);\n return el.offsetWidth + parseInt(styles.marginLeft) + parseInt(styles.marginRight);\n },\n\n setInputMinWidth () {\n // Ensure the width of the input is \"slightly bigger\" than the width of a single chip\n const firstChip = this.getFirstChip();\n const input = this.getInput();\n if (!input) return;\n if (firstChip) {\n // Add 4px buffer for typing room\n input.style.minWidth = (this.getFullWidth(firstChip) + 4) + 'px';\n } else {\n input.style.minWidth = '';\n }\n },\n\n checkMaxSelected () {\n if (this.maxSelected === 0) return;\n if (this.selectedItems.length > this.maxSelected) {\n this.showValidationMessages = true;\n this.$emit('max-selected');\n } else {\n this.showValidationMessages = false;\n }\n },\n\n setInitialInputHeight () {\n const input = this.getInput();\n if (!input) return;\n this.initialInputHeight = input.getBoundingClientRect().height;\n },\n\n async handleInputFocusIn () {\n this.inputFocused = true;\n if (this.collapseOnFocusOut) {\n this.hideInputText = false;\n await this.$nextTick();\n this.setInputPadding();\n }\n },\n\n async handleInputFocusOut () {\n this.inputFocused = false;\n if (this.collapseOnFocusOut) {\n this.hideInputText = true;\n const input = this.getInput();\n if (!input) return;\n // Hide the input text when is not on first line\n if (!input.style.paddingTop) {\n return;\n }\n this.revertInputPadding(input);\n }\n },\n },\n};\n</script>\n"],"mappings":"4kBAuIA,IAAK,EAAU,CACb,aAAc,CAAE,KAAM,EAAG,CACzB,KAAM,wBAEN,WAAY,CACV,sBAAA,EAAA,QACA,QAAA,EAAA,QACA,OAAA,EAAA,QACA,qBAAA,EAAA,QACD,CAED,aAAc,GAEd,MAAO,CAIL,MAAO,CACL,KAAM,OACN,SAAU,GACX,CAMD,aAAc,CACZ,KAAM,QACN,QAAS,GACV,CAKD,YAAa,CACX,KAAM,OACN,QAAS,GACV,CAKD,YAAa,CACX,KAAM,OACN,QAAS,6BACV,CAKD,cAAe,CACb,KAAM,MACN,YAAe,EAAE,CACjB,UAAW,GACF,EAAA,2BAA2B,EAAc,CAEnD,CAKD,kBAAmB,CACjB,KAAM,QACN,QAAS,GACV,CAYD,QAAS,CACP,KAAM,QACN,QAAS,GACV,CAKD,eAAgB,CACd,KAAM,OACN,QAAS,aACV,CAQD,SAAU,CACR,KAAM,QACN,QAAS,KACV,CAMD,cAAe,CACb,KAAM,OACN,QAAS,QACV,CAKD,cAAe,CACb,KAAM,MACN,QAAS,UAAY,CAAE,MAAO,EAAE,EACjC,CAKD,YAAa,CACX,KAAM,OACN,QAAS,EACV,CAMD,mBAAoB,CAClB,KAAM,MACN,QAAS,UAAY,CAAE,M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AA,CAAA,CAAA"}
|
|
1
|
+
{"version":3,"file":"combobox-multi-select.cjs","names":[],"sources":["../../../components/combobox_multi_select/combobox_multi_select.vue"],"sourcesContent":["<!-- eslint-disable vue/no-static-inline-styles -->\n<template>\n <dt-combobox-with-popover\n ref=\"comboboxWithPopover\"\n :label=\"label\"\n :show-list=\"showList\"\n :max-height=\"listMaxHeight\"\n :max-width=\"listMaxWidth\"\n :popover-offset=\"popoverOffset\"\n :has-suggestion-list=\"hasSuggestionList\"\n content-width=\"anchor\"\n :append-to=\"appendTo\"\n :transition=\"transition\"\n v-bind=\"extractNonListeners($attrs)\"\n @select=\"onComboboxSelect\"\n @highlight=\"comboboxHighlight\"\n >\n <template #input=\"{ onInput }\">\n <span\n ref=\"inputSlotWrapper\"\n class=\"d-recipe-combobox-multi-select__input-wrapper\"\n @focusin=\"handleInputFocusIn\"\n @focusout=\"handleInputFocusOut\"\n >\n <span\n ref=\"chipsWrapper\"\n :class=\"['d-recipe-combobox-multi-select__chip-wrapper', chipWrapperClass]\"\n >\n <dt-chip\n v-for=\"(item, index) in selectedItems\"\n ref=\"chips\"\n :key=\"`${index}-${item}`\"\n :label-class=\"['d-chip__label']\"\n :class=\"[\n 'd-recipe-combobox-multi-select__chip',\n { 'd-recipe-combobox-multi-select__chip--truncate': !!chipMaxWidth },\n ]\"\n :style=\"{ maxWidth: chipMaxWidth }\"\n :size=\"CHIP_SIZES[String(size)]\"\n :disabled=\"disabled\"\n v-on=\"chipListeners\"\n @keydown.backspace=\"onChipRemove(item)\"\n @close=\"onChipRemove(item)\"\n >\n {{ item }}\n </dt-chip>\n </span>\n\n <dt-input\n ref=\"input\"\n v-model=\"value\"\n class=\"d-recipe-combobox-multi-select__input\"\n :input-class=\"[\n inputClass, {\n 'd-recipe-combobox-multi-select__input--hidden': hideInputText,\n }]\"\n :input-wrapper-class=\"inputWrapperClass\"\n :disabled=\"disabled\"\n :aria-label=\"label\"\n :label=\"showLabel ? label : ''\"\n :description=\"description\"\n :placeholder=\"inputPlaceHolder\"\n :show-messages=\"showInputMessages\"\n :messages=\"inputMessages\"\n :size=\"size\"\n v-bind=\"inputListeners\"\n @input=\"onInput\"\n />\n\n <dt-validation-messages\n :validation-messages=\"maxSelectedMessage\"\n :show-messages=\"showValidationMessages\"\n />\n </span>\n </template>\n\n <!-- @slot slot for popover header -->\n <template\n v-if=\"hasSlotContent($slots.header)\"\n #header\n >\n <div ref=\"header\">\n <slot name=\"header\" />\n </div>\n </template>\n\n <!-- @slot slot for popover list -->\n <template #list>\n <div\n ref=\"list\"\n class=\"d-recipe-combobox-multi-select__list\"\n @mousedown.prevent\n >\n <slot\n v-if=\"!loading\"\n name=\"list\"\n />\n <div\n v-else\n class=\"d-recipe-combobox-multi-select__list--loading\"\n >\n {{ loadingMessage }}\n </div>\n </div>\n </template>\n\n <!-- @slot slot for popover footer -->\n <template\n v-if=\"hasSlotContent($slots.footer)\"\n #footer\n >\n <div ref=\"footer\">\n <slot name=\"footer\" />\n </div>\n </template>\n </dt-combobox-with-popover>\n</template>\n\n<script>\n/* eslint-disable max-lines */\nimport DtComboboxWithPopover from '@/components/combobox_with_popover/combobox_with_popover.vue';\nimport DtInput from '@/components/input/input.vue';\nimport DtChip from '@/components/chip/chip.vue';\nimport DtValidationMessages from '@/components/validation_messages/validation_messages.vue';\nimport { validationMessageValidator } from '@/common/validators';\nimport { extractVueListeners, extractNonListeners, hasSlotContent, returnFirstEl } from '@/common/utils';\nimport {\n POPOVER_APPEND_TO_VALUES,\n} from '@/components/popover/popover_constants';\nimport {\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n} from './combobox_multi_select_constants';\nimport { COMPONENT_SIZES } from '@/common/constants';\n\nexport default {\n compatConfig: { MODE: 3 },\n name: 'DtComboboxMultiSelect',\n\n components: {\n DtComboboxWithPopover,\n DtInput,\n DtChip,\n DtValidationMessages,\n },\n\n inheritAttrs: false,\n\n props: {\n /**\n * String to use for the input label.\n */\n label: {\n type: String,\n required: true,\n },\n\n /**\n * Determines visibility of input label.\n * @values true, false\n */\n showLabel: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Description for the input\n */\n description: {\n type: String,\n default: '',\n },\n\n /**\n * Input placeholder\n */\n placeholder: {\n type: String,\n default: 'Select one or start typing',\n },\n\n /**\n * Input validation messages\n */\n inputMessages: {\n type: Array,\n default: () => [],\n validator: inputMessages => {\n return validationMessageValidator(inputMessages);\n },\n },\n\n /**\n * Show input validation message\n */\n showInputMessages: {\n type: Boolean,\n default: true,\n },\n\n // @TODO: https://dialpad.atlassian.net/browse/DP-52324\n // type: {\n // type: String,\n // values: ['input', 'select'],\n // default: 'select',\n // },\n\n /**\n * Determines if the list is loading\n */\n loading: {\n type: Boolean,\n default: false,\n },\n\n /**\n * The message when the list is loading\n */\n loadingMessage: {\n type: String,\n default: 'loading...',\n },\n\n /**\n * Determines when to show the list element and also controls the aria-expanded attribute.\n * Leaving this null will have the combobox trigger on input focus by default.\n * If you set this value, the default trigger behavior will be disabled and you can\n * control it as you need.\n */\n showList: {\n type: Boolean,\n default: null,\n },\n\n /**\n * Determines maximum height for the popover before overflow.\n * Possible units rem|px|em\n */\n listMaxHeight: {\n type: String,\n default: '300px',\n },\n\n /**\n * The selected items\n */\n selectedItems: {\n type: Array,\n default: function () { return []; },\n },\n\n /**\n * Would be the maximum number of selections you can make. 0 is unlimited\n */\n maxSelected: {\n type: Number,\n default: 0,\n },\n\n /**\n * Max select message when the max selections is exceeded with the structure:\n * `[{\"message\": string, \"type\": VALIDATION_MESSAGE_TYPES }]`\n */\n maxSelectedMessage: {\n type: Array,\n default: function () { return []; },\n },\n\n /**\n * Displays the list when the combobox is focused, before the user has typed anything.\n * When this is enabled the list will not close after selection.\n */\n hasSuggestionList: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Size of the chip.\n * @values 100, 200, 300\n */\n size: {\n type: [String, Number],\n default: 300,\n validator: (t) => Object.keys(CHIP_SIZES).includes(String(t)),\n },\n\n /**\n * Sets the element to which the popover is going to append to.\n * 'body' will append to the nearest body (supports shadow DOM).\n * @values 'body', 'parent', HTMLElement,\n */\n appendTo: {\n type: [HTMLElement, String],\n default: 'body',\n validator: appendTo => {\n return POPOVER_APPEND_TO_VALUES.includes(appendTo) ||\n (appendTo instanceof HTMLElement);\n },\n },\n\n /**\n * Named transition when the content display is toggled.\n * @see DtLazyShow\n */\n transition: {\n type: String,\n default: 'fade',\n },\n\n /**\n * Determines whether the combobox should collapse to a single when losing focus.\n * @type {boolean}\n */\n collapseOnFocusOut: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Determines maximum width for the popover before overflow.\n * Possible units rem|px|em\n */\n listMaxWidth: {\n type: String,\n default: '',\n },\n\n /**\n * Amount of reserved space (in px) on the right side of the input\n * before the chips and the input caret jump to the next line.\n * default is 64\n */\n reservedRightSpace: {\n type: Number,\n default: 64,\n },\n\n /**\n * Determines the maximum width of a single chip. If the text within this chip exceeds the value\n * it will be truncated with ellipses.\n * Possible units rem|px|em\n */\n chipMaxWidth: {\n type: String,\n default: '',\n },\n\n /**\n * Additional class name for the input element.\n * Can accept String, Object, and Array, i.e. has the\n * same API as Vue's built-in handling of the class attribute.\n */\n inputClass: {\n type: [String, Object, Array],\n default: '',\n },\n\n /**\n * Additional class name for the input wrapper element.\n * Can accept all of String, Object, and Array, i.e. has the\n * same api as Vue's built-in handling of the class attribute.\n */\n inputWrapperClass: {\n type: [String, Object, Array],\n default: '',\n },\n\n /**\n * When true, disables the underlying input.\n */\n disabled: {\n type: Boolean,\n default: false,\n },\n },\n\n emits: [\n /**\n * Native input event\n *\n * @event input\n * @type {String }\n */\n 'input',\n\n /**\n * Event fired when item selected\n *\n * @event select\n * @type {Number}\n */\n 'select',\n\n /**\n * Event fired when item removed\n *\n * @event remove\n * @type {String}\n */\n 'remove',\n\n /**\n * Event fired when max selected items limit is reached\n *\n * @event max-selected\n * @type {Object}\n */\n 'max-selected',\n\n /**\n * Native keyup event\n *\n * @event keyup\n * @type {KeyboardEvent}\n */\n 'keyup',\n\n /**\n * Native keydown event\n *\n * @event keydown\n * @type {KeyboardEvent}\n */\n 'keydown',\n\n /**\n * Event fired when combobox item is highlighted\n *\n * @event combobox-highlight\n * @type {Object}\n */\n 'combobox-highlight',\n ],\n\n data () {\n return {\n value: '',\n popoverOffset: [0, 4],\n showValidationMessages: false,\n resizeWindowObserver: null,\n initialInputHeight: null,\n CHIP_SIZES,\n hasSlotContent,\n inputFocused: false,\n hideInputText: false,\n };\n },\n\n computed: {\n inputPlaceHolder () {\n return this.selectedItems?.length > 0 ? '' : this.placeholder;\n },\n\n chipListeners () {\n return {\n keydown: event => {\n this.onChipKeyDown(event);\n this.$emit('keydown', event);\n },\n };\n },\n\n inputListeners () {\n return {\n ...extractVueListeners(this.$attrs),\n onInput: event => {\n this.$emit('input', event);\n if (this.hasSuggestionList) {\n this.showComboboxList();\n }\n },\n\n onKeydown: event => {\n this.onInputKeyDown(event);\n },\n\n onKeyup: event => {\n this.$emit('keyup', event);\n },\n\n onClick: () => {\n if (this.hasSuggestionList) {\n this.showComboboxList();\n }\n },\n };\n },\n\n chipWrapperClass () {\n return {\n [`d-recipe-combobox-multi-select__chip-wrapper-${COMPONENT_SIZES[String(this.size)] || this.size}--collapsed`]: !this.inputFocused && this.collapseOnFocusOut,\n };\n },\n },\n\n watch: {\n selectedItems: {\n deep: true,\n handler: async function () {\n await this.initSelectedItems();\n },\n },\n\n chipMaxWidth: {\n async handler () {\n await this.initSelectedItems();\n },\n },\n\n async label () {\n await this.$nextTick();\n // Adjust the chips position if label changed\n this.setChipsTopPosition();\n },\n\n async description () {\n await this.$nextTick();\n // Adjust the chips position if description changed\n this.setChipsTopPosition();\n },\n\n size: {\n async handler () {\n await this.$nextTick();\n const input = this.getInput();\n this.revertInputPadding(input);\n this.initialInputHeight = input.getBoundingClientRect().height;\n this.setInputPadding();\n this.setChipsTopPosition();\n },\n },\n },\n\n async mounted () {\n this.setInitialInputHeight();\n // Recalculate chip position and input padding when resizing window\n this.resizeWindowObserver = new ResizeObserver(async () => {\n this.setChipsTopPosition();\n this.setInputPadding();\n });\n this.resizeWindowObserver.observe(document.body);\n\n await this.initSelectedItems();\n },\n\n beforeUnmount () {\n this.resizeWindowObserver?.unobserve(document.body);\n },\n\n methods: {\n extractNonListeners,\n comboboxHighlight (highlightIndex) {\n this.$emit('combobox-highlight', highlightIndex);\n },\n\n async initSelectedItems () {\n await this.$nextTick();\n this.setInputPadding();\n this.setChipsTopPosition();\n this.setInputMinWidth();\n this.checkMaxSelected();\n },\n\n onChipRemove (item) {\n this.$emit('remove', item);\n this.$refs.input?.focus();\n },\n\n onComboboxSelect (i) {\n if (this.loading) return;\n this.value = '';\n this.$emit('select', i);\n },\n\n showComboboxList () {\n if (this.showList != null) { return; }\n this.$refs.comboboxWithPopover?.showComboboxList();\n },\n\n closeComboboxList () {\n if (this.showList != null) { return; }\n this.$refs.comboboxWithPopover?.closeComboboxList();\n },\n\n getChips () {\n if (!this.selectedItems.length || !this.$refs.chips) return null;\n\n // Use the order from selectedItems to not rely on DOM order which may be stale.\n // Track matched indices to handle duplicate item names correctly.\n const matched = new Set();\n const chips = this.selectedItems.map(item => {\n return this.$refs.chips.find((chip, index) => {\n if (matched.has(index)) return false;\n const chipLabel = returnFirstEl(chip.$el)?.querySelector('.d-chip__label')?.textContent?.trim();\n if (chipLabel === item) {\n matched.add(index);\n return true;\n }\n return false;\n });\n });\n return chips.filter(Boolean).map(chip => returnFirstEl(chip.$el));\n },\n\n getChipButtons () {\n const chips = this.getChips();\n return chips && chips.map(chip => returnFirstEl(chip).querySelector('button'));\n },\n\n getLastChipButton () {\n const chipButtons = this.getChipButtons();\n return chipButtons && chipButtons[chipButtons.length - 1];\n },\n\n getLastChip () {\n const chips = this.getChips();\n return chips && chips[chips.length - 1];\n },\n\n getFirstChip () {\n const chips = this.getChips();\n return chips && chips[0];\n },\n\n getInput () {\n return this.$refs.input?.$refs.input;\n },\n\n onChipKeyDown (event) {\n const key = event.code?.toLowerCase();\n if (key === 'arrowleft') {\n // Move to the previous chip\n this.navigateBetweenChips(event.target, true);\n } else if (key === 'arrowright') {\n if (event.target.id === this.getLastChipButton().id) {\n // Move to the input if it's the last chip\n this.moveFromChipToInput();\n } else {\n // Move to the next chip\n this.navigateBetweenChips(event.target, false);\n }\n }\n },\n\n onInputKeyDown (event) {\n const key = event.code?.toLowerCase();\n // If the cursor is at the start of the text,\n // press 'backspace' or 'left' focuses the last chip\n if (this.selectedItems.length > 0 && event.target.selectionStart === 0) {\n // if there is selected text, do not focus the last chip\n if (event.target.selectionEnd !== event.target.selectionStart) {\n return;\n }\n if (key === 'backspace' || key === 'arrowleft') {\n this.moveFromInputToChip();\n }\n }\n },\n\n moveFromInputToChip () {\n this.getLastChipButton().focus();\n this.$refs.input?.blur();\n this.closeComboboxList();\n },\n\n moveFromChipToInput () {\n this.getLastChipButton().blur();\n this.$refs.input?.focus();\n this.showComboboxList();\n },\n\n navigateBetweenChips (target, toLeft) {\n const from = this.getChipButtons().indexOf(target);\n const to = toLeft ? from - 1 : from + 1;\n if (to < 0 || to >= this.$refs.chips?.length) {\n return;\n }\n this.getChipButtons()[from].blur();\n this.getChipButtons()[to].focus();\n this.closeComboboxList();\n },\n\n setChipsTopPosition () {\n // To place the chips in the input box\n // The chip \"top\" position should be the same line as the input box\n const input = this.getInput();\n if (!input) return;\n const inputSlotWrapper = this.$refs.inputSlotWrapper;\n const top = input.getBoundingClientRect().top -\n inputSlotWrapper.getBoundingClientRect().top;\n const chipsWrapper = this.$refs.chipsWrapper;\n chipsWrapper.style.top = (top - CHIP_TOP_POSITION[String(this.size)]) + 'px';\n },\n\n setInputPadding () {\n const lastChip = this.getLastChip();\n const input = this.getInput();\n const chipsWrapper = this.$refs.chipsWrapper;\n if (!input) return;\n this.revertInputPadding(input);\n this.popoverOffset = [0, 4];\n if (!lastChip) return;\n // Avoid adding extra padding when the input is not focused if collapseOnFocusOut is true\n // This ensures the input returns to its original state when resizing\n if (this.collapseOnFocusOut && !this.inputFocused) return;\n\n // Get the position of the last chip\n // The input cursor should be the same \"top\" as that chip and next besides it\n const left = lastChip.offsetLeft + this.getFullWidth(lastChip);\n const spaceLeft = input.getBoundingClientRect().width - left;\n // input.style.paddingLeft = left + 'px';\n\n if (spaceLeft > this.reservedRightSpace) {\n input.style.paddingInlineStart = left + 'px';\n } else {\n input.style.paddingInlineStart = '4px';\n }\n\n // Get the chip wrapper height minus the 4px padding\n const chipsWrapperHeight = chipsWrapper.getBoundingClientRect().height - 4;\n const lastChipHeight = lastChip.getBoundingClientRect().height - 4;\n\n // Get lastChip offsetTop plus 2px of the input padding.\n const top = spaceLeft > this.reservedRightSpace\n ? lastChip.offsetTop + 2\n : (chipsWrapperHeight + lastChipHeight - 9);\n\n input.style.paddingBlockStart = `${top}px`;\n },\n\n revertInputPadding (input) {\n input.style.paddingInlineStart = '';\n input.style.paddingBlockStart = '';\n input.style.paddingBlockEnd = '';\n },\n\n getFullWidth (el) {\n const styles = window.getComputedStyle(el);\n return el.offsetWidth + parseInt(styles.marginLeft) + parseInt(styles.marginRight);\n },\n\n setInputMinWidth () {\n // Ensure the width of the input is \"slightly bigger\" than the width of a single chip\n const firstChip = this.getFirstChip();\n const input = this.getInput();\n if (!input) return;\n if (firstChip) {\n // Add 4px buffer for typing room\n input.style.minWidth = (this.getFullWidth(firstChip) + 4) + 'px';\n } else {\n input.style.minWidth = '';\n }\n },\n\n checkMaxSelected () {\n if (this.maxSelected === 0) return;\n if (this.selectedItems.length > this.maxSelected) {\n this.showValidationMessages = true;\n this.$emit('max-selected');\n } else {\n this.showValidationMessages = false;\n }\n },\n\n setInitialInputHeight () {\n const input = this.getInput();\n if (!input) return;\n this.initialInputHeight = input.getBoundingClientRect().height;\n },\n\n async handleInputFocusIn () {\n this.inputFocused = true;\n if (this.collapseOnFocusOut) {\n this.hideInputText = false;\n await this.$nextTick();\n this.setInputPadding();\n }\n },\n\n async handleInputFocusOut () {\n this.inputFocused = false;\n if (this.collapseOnFocusOut) {\n this.hideInputText = true;\n const input = this.getInput();\n if (!input) return;\n // Hide the input text when is not on first line\n if (!input.style.paddingTop) {\n return;\n }\n this.revertInputPadding(input);\n }\n },\n },\n};\n</script>\n"],"mappings":"0nBAuIA,IAAK,EAAU,CACb,aAAc,CAAE,KAAM,EAAG,CACzB,KAAM,wBAEN,WAAY,CACV,sBAAA,EAAA,QACA,QAAA,EAAA,QACA,OAAA,EAAA,QACA,qBAAA,EAAA,QACD,CAED,aAAc,GAEd,MAAO,CAIL,MAAO,CACL,KAAM,OACN,SAAU,GACX,CAMD,UAAW,CACT,KAAM,QACN,QAAS,GACV,CAKD,YAAa,CACX,KAAM,OACN,QAAS,GACV,CAKD,YAAa,CACX,KAAM,OACN,QAAS,6BACV,CAKD,cAAe,CACb,KAAM,MACN,YAAe,EAAE,CACjB,UAAW,GACF,EAAA,2BAA2B,EAAc,CAEnD,CAKD,kBAAmB,CACjB,KAAM,QACN,QAAS,GACV,CAYD,QAAS,CACP,KAAM,QACN,QAAS,GACV,CAKD,eAAgB,CACd,KAAM,OACN,QAAS,aACV,CAQD,SAAU,CACR,KAAM,QACN,QAAS,KACV,CAMD,cAAe,CACb,KAAM,OACN,QAAS,QACV,CAKD,cAAe,CACb,KAAM,MACN,QAAS,UAAY,CAAE,MAAO,EAAE,EACjC,CAKD,YAAa,CACX,KAAM,OACN,QAAS,EACV,CAMD,mBAAoB,CAClB,KAAM,MACN,QAAS,UAAY,CAAE,MAAO,EAAE,EACjC,CAMD,kBAAmB,CACjB,KAAM,QACN,QAAS,GACV,CAMD,KAAM,CACJ,KAAM,CAAC,OAAQ,OAAO,CACtB,QAAS,IACT,UAAY,GAAM,OAAO,KAAK,EAAA,WAAW,CAAC,SAAS,OAAO,EAAE,CAAC,CAC9D,CAOD,SAAU,CACR,KAAM,CAAC,YAAa,OAAO,CAC3B,QAAS,OACT,UAAW,GACF,EAAA,yBAAyB,SAAS,EAAQ,EAC5C,aAAoB,YAE5B,CAMD,WAAY,CACV,KAAM,OACN,QAAS,OACV,CAMD,mB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YAAa,EAAA,YACb,YAAa,EAAA,iBACb,gBAAe,EAAA,kBACf,SAAU,EAAA,cACV,KAAM,EAAA,MACC,EAAA,eAAc,CACd,UAAO,CAAA,CAAA,KAAA,GAAA,CAAA,aAAA,cAAA,sBAAA,WAAA,aAAA,QAAA,cAAA,cAAA,gBAAA,WAAA,OAAA,UAAA,CAAA,mBAMf,EAAA,CAFC,sBAAqB,EAAA,mBACrB,gBAAe,EAAA,gFAgBX,MAAA,EAAA,EAAA,aAgBH,EAAA,EAAA,EAAA,oBAAA,MAAA,CAdJ,IAAI,OACJ,MAAM,uCACL,YAAS,EAAA,KAAA,EAAA,IAAA,EAAA,EAAA,mBAAV,GAAkB,CAAA,UAAA,CAAA,IAGT,EAAA,UAEP,EAAA,EAAA,YAAA,EAAA,EAAA,EAAA,oBAMI,MALN,GAAA,EAAA,EAAA,iBAIK,EAAA,eAAc,CAAA,EAAA,GAPV,EAAA,EAAA,YAEP,EAAA,OAAA,OAAA,CAAA,IAAA,EAAA,CAAA,CAKiB,CAAA,IAAA,CAAA,CAAA,OAvBf,EAAA,eAAe,EAAA,OAAO,OAAM,CAAA,MACjC,8BAIK,EAAA,EAAA,EAAA,oBAAA,MAFN,EAEM,EAAA,EAAA,EAAA,YADkB,EAAA,OAAA,SAAA,CAAA,CAAA,IAAA,CAAA,CAAA,iBA0BlB,EAAA,eAAe,EAAA,OAAO,OAAM,CAAA,MACjC,8BAIK,EAAA,EAAA,EAAA,oBAAA,MAFN,EAEM,EAAA,EAAA,EAAA,YADkB,EAAA,OAAA,SAAA,CAAA,CAAA,IAAA,CAAA,CAAA"}
|
|
@@ -1,22 +1,23 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import o from "
|
|
5
|
-
import s from "../
|
|
6
|
-
import
|
|
7
|
-
import l from "../
|
|
8
|
-
import u from "../
|
|
9
|
-
import
|
|
1
|
+
import { COMPONENT_SIZES as e } from "../../common/constants/sizes.js";
|
|
2
|
+
import { validationMessageValidator as t } from "../../common/validators/index.js";
|
|
3
|
+
import { extractNonListeners as n, extractVueListeners as r, hasSlotContent as i, returnFirstEl as a } from "../../common/utils/index.js";
|
|
4
|
+
import { t as o } from "../../_plugin-vue_export-helper-BTgDAbhb.js";
|
|
5
|
+
import s from "../validation-messages/validation-messages.js";
|
|
6
|
+
import c from "../chip/chip.js";
|
|
7
|
+
import { POPOVER_APPEND_TO_VALUES as l } from "../popover/popover-constants.js";
|
|
8
|
+
import u from "../input/input.js";
|
|
9
|
+
import d from "../combobox-with-popover/combobox-with-popover.js";
|
|
10
|
+
import { CHIP_SIZES as f, CHIP_TOP_POSITION as p } from "./combobox-multi-select-constants.js";
|
|
10
11
|
import { Fragment as m, createBlock as h, createElementBlock as g, createElementVNode as _, createSlots as v, createTextVNode as y, createVNode as b, mergeProps as x, normalizeClass as S, openBlock as C, renderList as w, renderSlot as T, resolveComponent as E, toDisplayString as D, toHandlers as O, withCtx as k, withKeys as A, withModifiers as j } from "vue";
|
|
11
12
|
//#region components/combobox_multi_select/combobox_multi_select.vue
|
|
12
13
|
var M = {
|
|
13
14
|
compatConfig: { MODE: 3 },
|
|
14
15
|
name: "DtComboboxMultiSelect",
|
|
15
16
|
components: {
|
|
16
|
-
DtComboboxWithPopover:
|
|
17
|
-
DtInput:
|
|
18
|
-
DtChip:
|
|
19
|
-
DtValidationMessages:
|
|
17
|
+
DtComboboxWithPopover: d,
|
|
18
|
+
DtInput: u,
|
|
19
|
+
DtChip: c,
|
|
20
|
+
DtValidationMessages: s
|
|
20
21
|
},
|
|
21
22
|
inheritAttrs: !1,
|
|
22
23
|
props: {
|
|
@@ -24,7 +25,7 @@ var M = {
|
|
|
24
25
|
type: String,
|
|
25
26
|
required: !0
|
|
26
27
|
},
|
|
27
|
-
|
|
28
|
+
showLabel: {
|
|
28
29
|
type: Boolean,
|
|
29
30
|
default: !0
|
|
30
31
|
},
|
|
@@ -39,7 +40,7 @@ var M = {
|
|
|
39
40
|
inputMessages: {
|
|
40
41
|
type: Array,
|
|
41
42
|
default: () => [],
|
|
42
|
-
validator: (
|
|
43
|
+
validator: (e) => t(e)
|
|
43
44
|
},
|
|
44
45
|
showInputMessages: {
|
|
45
46
|
type: Boolean,
|
|
@@ -82,14 +83,14 @@ var M = {
|
|
|
82
83
|
default: !0
|
|
83
84
|
},
|
|
84
85
|
size: {
|
|
85
|
-
type: String,
|
|
86
|
-
default:
|
|
87
|
-
validator: (e) => Object.
|
|
86
|
+
type: [String, Number],
|
|
87
|
+
default: 300,
|
|
88
|
+
validator: (e) => Object.keys(f).includes(String(e))
|
|
88
89
|
},
|
|
89
90
|
appendTo: {
|
|
90
91
|
type: [HTMLElement, String],
|
|
91
92
|
default: "body",
|
|
92
|
-
validator: (e) =>
|
|
93
|
+
validator: (e) => l.includes(e) || e instanceof HTMLElement
|
|
93
94
|
},
|
|
94
95
|
transition: {
|
|
95
96
|
type: String,
|
|
@@ -148,8 +149,8 @@ var M = {
|
|
|
148
149
|
showValidationMessages: !1,
|
|
149
150
|
resizeWindowObserver: null,
|
|
150
151
|
initialInputHeight: null,
|
|
151
|
-
CHIP_SIZES:
|
|
152
|
-
hasSlotContent:
|
|
152
|
+
CHIP_SIZES: f,
|
|
153
|
+
hasSlotContent: i,
|
|
153
154
|
inputFocused: !1,
|
|
154
155
|
hideInputText: !1
|
|
155
156
|
};
|
|
@@ -165,7 +166,7 @@ var M = {
|
|
|
165
166
|
},
|
|
166
167
|
inputListeners() {
|
|
167
168
|
return {
|
|
168
|
-
...
|
|
169
|
+
...r(this.$attrs),
|
|
169
170
|
onInput: (e) => {
|
|
170
171
|
this.$emit("input", e), this.hasSuggestionList && this.showComboboxList();
|
|
171
172
|
},
|
|
@@ -181,7 +182,7 @@ var M = {
|
|
|
181
182
|
};
|
|
182
183
|
},
|
|
183
184
|
chipWrapperClass() {
|
|
184
|
-
return { [`d-recipe-combobox-multi-select__chip-wrapper-${this.size}--collapsed`]: !this.inputFocused && this.collapseOnFocusOut };
|
|
185
|
+
return { [`d-recipe-combobox-multi-select__chip-wrapper-${e[String(this.size)] || this.size}--collapsed`]: !this.inputFocused && this.collapseOnFocusOut };
|
|
185
186
|
}
|
|
186
187
|
},
|
|
187
188
|
watch: {
|
|
@@ -215,7 +216,7 @@ var M = {
|
|
|
215
216
|
this.resizeWindowObserver?.unobserve(document.body);
|
|
216
217
|
},
|
|
217
218
|
methods: {
|
|
218
|
-
extractNonListeners:
|
|
219
|
+
extractNonListeners: n,
|
|
219
220
|
comboboxHighlight(e) {
|
|
220
221
|
this.$emit("combobox-highlight", e);
|
|
221
222
|
},
|
|
@@ -237,11 +238,11 @@ var M = {
|
|
|
237
238
|
getChips() {
|
|
238
239
|
if (!this.selectedItems.length || !this.$refs.chips) return null;
|
|
239
240
|
let e = /* @__PURE__ */ new Set();
|
|
240
|
-
return this.selectedItems.map((t) => this.$refs.chips.find((n, r) => e.has(r) ? !1 :
|
|
241
|
+
return this.selectedItems.map((t) => this.$refs.chips.find((n, r) => e.has(r) ? !1 : a(n.$el)?.querySelector(".d-chip__label")?.textContent?.trim() === t ? (e.add(r), !0) : !1)).filter(Boolean).map((e) => a(e.$el));
|
|
241
242
|
},
|
|
242
243
|
getChipButtons() {
|
|
243
244
|
let e = this.getChips();
|
|
244
|
-
return e && e.map((e) =>
|
|
245
|
+
return e && e.map((e) => a(e).querySelector("button"));
|
|
245
246
|
},
|
|
246
247
|
getLastChipButton() {
|
|
247
248
|
let e = this.getChipButtons();
|
|
@@ -283,18 +284,18 @@ var M = {
|
|
|
283
284
|
let e = this.getInput();
|
|
284
285
|
if (!e) return;
|
|
285
286
|
let t = this.$refs.inputSlotWrapper, n = e.getBoundingClientRect().top - t.getBoundingClientRect().top, r = this.$refs.chipsWrapper;
|
|
286
|
-
r.style.top = n -
|
|
287
|
+
r.style.top = n - p[String(this.size)] + "px";
|
|
287
288
|
},
|
|
288
289
|
setInputPadding() {
|
|
289
290
|
let e = this.getLastChip(), t = this.getInput(), n = this.$refs.chipsWrapper;
|
|
290
291
|
if (!t || (this.revertInputPadding(t), this.popoverOffset = [0, 4], !e) || this.collapseOnFocusOut && !this.inputFocused) return;
|
|
291
292
|
let r = e.offsetLeft + this.getFullWidth(e), i = t.getBoundingClientRect().width - r;
|
|
292
|
-
i > this.reservedRightSpace ? t.style.
|
|
293
|
+
i > this.reservedRightSpace ? t.style.paddingInlineStart = r + "px" : t.style.paddingInlineStart = "4px";
|
|
293
294
|
let a = n.getBoundingClientRect().height - 4, o = e.getBoundingClientRect().height - 4, s = i > this.reservedRightSpace ? e.offsetTop + 2 : a + o - 9;
|
|
294
|
-
t.style.
|
|
295
|
+
t.style.paddingBlockStart = `${s}px`;
|
|
295
296
|
},
|
|
296
297
|
revertInputPadding(e) {
|
|
297
|
-
e.style.
|
|
298
|
+
e.style.paddingInlineStart = "", e.style.paddingBlockStart = "", e.style.paddingBlockEnd = "";
|
|
298
299
|
},
|
|
299
300
|
getFullWidth(e) {
|
|
300
301
|
let t = window.getComputedStyle(e);
|
|
@@ -360,7 +361,7 @@ function I(e, t, n, r, i, a) {
|
|
|
360
361
|
"label-class": ["d-chip__label"],
|
|
361
362
|
class: ["d-recipe-combobox-multi-select__chip", { "d-recipe-combobox-multi-select__chip--truncate": !!n.chipMaxWidth }],
|
|
362
363
|
style: { maxWidth: n.chipMaxWidth },
|
|
363
|
-
size: i.CHIP_SIZES[n.size],
|
|
364
|
+
size: i.CHIP_SIZES[String(n.size)],
|
|
364
365
|
disabled: n.disabled
|
|
365
366
|
}, O(a.chipListeners), {
|
|
366
367
|
onKeydown: A((t) => a.onChipRemove(e), ["backspace"]),
|
|
@@ -385,7 +386,7 @@ function I(e, t, n, r, i, a) {
|
|
|
385
386
|
"input-wrapper-class": n.inputWrapperClass,
|
|
386
387
|
disabled: n.disabled,
|
|
387
388
|
"aria-label": n.label,
|
|
388
|
-
label: n.
|
|
389
|
+
label: n.showLabel ? n.label : "",
|
|
389
390
|
description: n.description,
|
|
390
391
|
placeholder: a.inputPlaceHolder,
|
|
391
392
|
"show-messages": n.showInputMessages,
|
|
@@ -437,7 +438,7 @@ function I(e, t, n, r, i, a) {
|
|
|
437
438
|
"onHighlight"
|
|
438
439
|
]);
|
|
439
440
|
}
|
|
440
|
-
var L = /* @__PURE__ */
|
|
441
|
+
var L = /* @__PURE__ */ o(M, [["render", I]]);
|
|
441
442
|
//#endregion
|
|
442
443
|
export { L as default };
|
|
443
444
|
|