@dialpad/dialtone-vue 3.120.0 → 3.120.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/chunks/_plugin-vue_export-helper-caHeSgYY.js +11 -0
- package/dist/chunks/_plugin-vue_export-helper-caHeSgYY.js.map +1 -0
- package/dist/chunks/_plugin-vue_export-helper-fhnQq0tA.js +10 -0
- package/dist/chunks/_plugin-vue_export-helper-fhnQq0tA.js.map +1 -0
- package/dist/chunks/{dropdown-eWOvBvwq.js → dropdown-Hn-TeTvZ.js} +151 -104
- package/dist/chunks/{dropdown-UO3UJalk.js.map → dropdown-Hn-TeTvZ.js.map} +1 -1
- package/dist/chunks/dropdown-w8Do29L5.js +442 -0
- package/dist/chunks/{dropdown-eWOvBvwq.js.map → dropdown-w8Do29L5.js.map} +1 -1
- package/dist/chunks/dropdown_constants-2pGCXy7m.js +8 -0
- package/dist/chunks/dropdown_constants-2pGCXy7m.js.map +1 -0
- package/dist/chunks/dropdown_constants-w1MXGC3Z.js +9 -0
- package/dist/chunks/dropdown_constants-w1MXGC3Z.js.map +1 -0
- package/dist/chunks/{icon_constants-OpYAAKwF.js → icon_constants-Dy4MEUJL.js} +7 -6
- package/dist/chunks/{icon_constants-2S_OSQ1t.js.map → icon_constants-Dy4MEUJL.js.map} +1 -1
- package/dist/chunks/icon_constants-QYpmdE0R.js +16 -0
- package/dist/chunks/{icon_constants-OpYAAKwF.js.map → icon_constants-QYpmdE0R.js.map} +1 -1
- package/dist/chunks/index-4qgKeErp.js +446 -0
- package/dist/chunks/{index-b4iXYvId.js.map → index-4qgKeErp.js.map} +1 -1
- package/dist/chunks/index-b_MgDylR.js +447 -0
- package/dist/chunks/{index-6tYeqbgP.js.map → index-b_MgDylR.js.map} +1 -1
- package/dist/chunks/{input-4UQWegUk.js → input-NmYDD5bn.js} +83 -60
- package/dist/chunks/{input-0Uksk4DP.js.map → input-NmYDD5bn.js.map} +1 -1
- package/dist/chunks/input-ttnte8zB.js +295 -0
- package/dist/chunks/{input-4UQWegUk.js.map → input-ttnte8zB.js.map} +1 -1
- package/dist/chunks/input_group-M-D25pOJ.js +152 -0
- package/dist/chunks/{input_group-bBKaq3Wi.js.map → input_group-M-D25pOJ.js.map} +1 -1
- package/dist/chunks/{input_group-bBKaq3Wi.js → input_group-jWnq2DJT.js} +27 -24
- package/dist/chunks/{input_group-AS760Cp7.js.map → input_group-jWnq2DJT.js.map} +1 -1
- package/dist/chunks/keyboard_list_navigation-ScXhrxya.js +284 -0
- package/dist/chunks/{keyboard_list_navigation-N74Bpdq7.js.map → keyboard_list_navigation-ScXhrxya.js.map} +1 -1
- package/dist/chunks/keyboard_list_navigation-fJnl_Iox.js +283 -0
- package/dist/chunks/{keyboard_list_navigation-F0O8nht0.js.map → keyboard_list_navigation-fJnl_Iox.js.map} +1 -1
- package/dist/chunks/link_constants-Huj7D_hm.js +22 -0
- package/dist/chunks/{link_constants-Kn6kP4i1.js.map → link_constants-Huj7D_hm.js.map} +1 -1
- package/dist/chunks/link_constants-nWVlXQBs.js +23 -0
- package/dist/chunks/{link_constants-vIUB92L4.js.map → link_constants-nWVlXQBs.js.map} +1 -1
- package/dist/chunks/list_item_constants-EiqkqZvP.js +13 -0
- package/dist/chunks/{list_item_constants-Tsz5CO1m.js.map → list_item_constants-EiqkqZvP.js.map} +1 -1
- package/dist/chunks/list_item_constants-u1xcN9Dd.js +14 -0
- package/dist/chunks/{list_item_constants-LTUc74pD.js.map → list_item_constants-u1xcN9Dd.js.map} +1 -1
- package/dist/chunks/modal-VgxXAQFP.js +105 -0
- package/dist/chunks/{modal-qEzlo0Sj.js.map → modal-VgxXAQFP.js.map} +1 -1
- package/dist/chunks/modal-XOr4kiNZ.js +106 -0
- package/dist/chunks/{modal-VuMFkZFH.js.map → modal-XOr4kiNZ.js.map} +1 -1
- package/dist/chunks/notice_action-WTucGhvr.js +222 -0
- package/dist/chunks/{notice_action-tJfD5Qw1.js.map → notice_action-WTucGhvr.js.map} +1 -1
- package/dist/chunks/notice_action-p-ePanW_.js +223 -0
- package/dist/chunks/{notice_action-jO199emq.js.map → notice_action-p-ePanW_.js.map} +1 -1
- package/dist/chunks/notice_constants-7Qt2CQEY.js +7 -0
- package/dist/chunks/{notice_constants-mC6al2Dm.js.map → notice_constants-7Qt2CQEY.js.map} +1 -1
- package/dist/chunks/notice_constants-UXo9e3bS.js +6 -0
- package/dist/chunks/{notice_constants-c--hBFQw.js.map → notice_constants-UXo9e3bS.js.map} +1 -1
- package/dist/chunks/popover_constants-JwBF9h1Z.js +143 -0
- package/dist/chunks/{popover_constants-hOEhklvr.js.map → popover_constants-JwBF9h1Z.js.map} +1 -1
- package/dist/chunks/popover_constants-Qkpb0yh2.js +144 -0
- package/dist/chunks/{popover_constants-qjlEkroB.js.map → popover_constants-Qkpb0yh2.js.map} +1 -1
- package/dist/chunks/{sr_only_close_button-7O-Ev8uM.js → sr_only_close_button-3EdsV-dH.js} +28 -24
- package/dist/chunks/{sr_only_close_button-iD7s1Pbj.js.map → sr_only_close_button-3EdsV-dH.js.map} +1 -1
- package/dist/chunks/sr_only_close_button-xGrHFjwA.js +91 -0
- package/dist/chunks/{sr_only_close_button-7O-Ev8uM.js.map → sr_only_close_button-xGrHFjwA.js.map} +1 -1
- package/dist/chunks/stack_constants-HraCekPm.js +15 -0
- package/dist/chunks/{stack_constants-m9Ickqw0.js.map → stack_constants-HraCekPm.js.map} +1 -1
- package/dist/chunks/stack_constants-SMzMWnAQ.js +14 -0
- package/dist/chunks/{stack_constants-u7tNqGtc.js.map → stack_constants-SMzMWnAQ.js.map} +1 -1
- package/dist/chunks/tab-RTDgnD9-.js +391 -0
- package/dist/chunks/{tab-at7WWglk.js.map → tab-RTDgnD9-.js.map} +1 -1
- package/dist/chunks/tab-qc3f42Yp.js +390 -0
- package/dist/chunks/{tab-GQZFMq83.js.map → tab-qc3f42Yp.js.map} +1 -1
- package/dist/common/constants.cjs +60 -0
- package/dist/{lib → common}/constants.cjs.map +1 -1
- package/dist/{lib → common}/constants.js +25 -18
- package/dist/{lib → common}/constants.js.map +1 -1
- package/dist/common/dates.cjs +72 -0
- package/dist/{lib → common}/dates.cjs.map +1 -1
- package/dist/common/dates.js +72 -0
- package/dist/{lib → common}/dates.js.map +1 -1
- package/dist/common/emoji.cjs +163 -0
- package/dist/common/emoji.cjs.map +1 -0
- package/dist/common/emoji.js +168 -0
- package/dist/common/emoji.js.map +1 -0
- package/dist/common/mixins.cjs +17 -0
- package/dist/{lib → common}/mixins.cjs.map +1 -1
- package/dist/common/mixins.js +17 -0
- package/dist/common/utils.cjs +243 -0
- package/dist/{lib → common}/utils.cjs.map +1 -1
- package/dist/common/utils.js +243 -0
- package/dist/{lib → common}/utils.js.map +1 -1
- package/dist/common/validators.cjs +23 -0
- package/dist/{lib → common}/validators.cjs.map +1 -1
- package/dist/common/validators.js +23 -0
- package/dist/{lib → common}/validators.js.map +1 -1
- package/dist/dialtone-vue.cjs +373 -1
- package/dist/dialtone-vue.cjs.map +1 -1
- package/dist/dialtone-vue.js +328 -327
- package/dist/dialtone-vue.js.map +1 -1
- package/dist/lib/attachment-carousel.cjs +345 -1
- package/dist/lib/attachment-carousel.cjs.map +1 -1
- package/dist/lib/attachment-carousel.js +126 -108
- package/dist/lib/attachment-carousel.js.map +1 -1
- package/dist/lib/avatar.cjs +447 -1
- package/dist/lib/avatar.cjs.map +1 -1
- package/dist/lib/avatar.js +135 -101
- package/dist/lib/avatar.js.map +1 -1
- package/dist/lib/badge.cjs +206 -1
- package/dist/lib/badge.cjs.map +1 -1
- package/dist/lib/badge.js +64 -48
- package/dist/lib/badge.js.map +1 -1
- package/dist/lib/banner.cjs +242 -2
- package/dist/lib/banner.cjs.map +1 -1
- package/dist/lib/banner.js +81 -71
- package/dist/lib/banner.js.map +1 -1
- package/dist/lib/breadcrumbs.cjs +150 -1
- package/dist/lib/breadcrumbs.cjs.map +1 -1
- package/dist/lib/breadcrumbs.js +60 -52
- package/dist/lib/breadcrumbs.js.map +1 -1
- package/dist/lib/button-group.cjs +41 -1
- package/dist/lib/button-group.cjs.map +1 -1
- package/dist/lib/button-group.js +15 -14
- package/dist/lib/button-group.js.map +1 -1
- package/dist/lib/button.cjs +356 -1
- package/dist/lib/button.cjs.map +1 -1
- package/dist/lib/button.js +108 -88
- package/dist/lib/button.js.map +1 -1
- package/dist/lib/callbar-button-with-popover.cjs +322 -1
- package/dist/lib/callbar-button-with-popover.cjs.map +1 -1
- package/dist/lib/callbar-button-with-popover.js +101 -83
- package/dist/lib/callbar-button-with-popover.js.map +1 -1
- package/dist/lib/callbar-button.cjs +200 -1
- package/dist/lib/callbar-button.cjs.map +1 -1
- package/dist/lib/callbar-button.js +52 -45
- package/dist/lib/callbar-button.js.map +1 -1
- package/dist/lib/callbox.cjs +217 -1
- package/dist/lib/callbox.cjs.map +1 -1
- package/dist/lib/callbox.js +80 -67
- package/dist/lib/callbox.js.map +1 -1
- package/dist/lib/card.cjs +91 -1
- package/dist/lib/card.cjs.map +1 -1
- package/dist/lib/card.js +27 -27
- package/dist/lib/card.js.map +1 -1
- package/dist/lib/checkbox-group.cjs +115 -1
- package/dist/lib/checkbox-group.cjs.map +1 -1
- package/dist/lib/checkbox-group.js +34 -23
- package/dist/lib/checkbox-group.js.map +1 -1
- package/dist/lib/checkbox.cjs +156 -1
- package/dist/lib/checkbox.cjs.map +1 -1
- package/dist/lib/checkbox.js +72 -60
- package/dist/lib/checkbox.js.map +1 -1
- package/dist/lib/chip.cjs +235 -1
- package/dist/lib/chip.cjs.map +1 -1
- package/dist/lib/chip.js +84 -67
- package/dist/lib/chip.js.map +1 -1
- package/dist/lib/codeblock.cjs +23 -2
- package/dist/lib/codeblock.cjs.map +1 -1
- package/dist/lib/codeblock.js +13 -13
- package/dist/lib/codeblock.js.map +1 -1
- package/dist/lib/collapsible.cjs +398 -1
- package/dist/lib/collapsible.cjs.map +1 -1
- package/dist/lib/collapsible.js +123 -100
- package/dist/lib/collapsible.js.map +1 -1
- package/dist/lib/combobox-multi-select.cjs +589 -1
- package/dist/lib/combobox-multi-select.cjs.map +1 -1
- package/dist/lib/combobox-multi-select.js +270 -177
- package/dist/lib/combobox-multi-select.js.map +1 -1
- package/dist/lib/combobox-with-popover.cjs +452 -1
- package/dist/lib/combobox-with-popover.cjs.map +1 -1
- package/dist/lib/combobox-with-popover.js +172 -127
- package/dist/lib/combobox-with-popover.js.map +1 -1
- package/dist/lib/combobox.cjs +18 -1
- package/dist/lib/combobox.cjs.map +1 -1
- package/dist/lib/combobox.js +9 -9
- package/dist/lib/contact-info.cjs +205 -1
- package/dist/lib/contact-info.cjs.map +1 -1
- package/dist/lib/contact-info.js +69 -60
- package/dist/lib/contact-info.js.map +1 -1
- package/dist/lib/contact-row.cjs +246 -1
- package/dist/lib/contact-row.cjs.map +1 -1
- package/dist/lib/contact-row.js +67 -63
- package/dist/lib/contact-row.js.map +1 -1
- package/dist/lib/datepicker.cjs +854 -1
- package/dist/lib/datepicker.cjs.map +1 -1
- package/dist/lib/datepicker.js +585 -441
- package/dist/lib/datepicker.js.map +1 -1
- package/dist/lib/description-list.cjs +116 -1
- package/dist/lib/description-list.cjs.map +1 -1
- package/dist/lib/description-list.js +56 -24
- package/dist/lib/description-list.js.map +1 -1
- package/dist/lib/dropdown.cjs +36 -1
- package/dist/lib/dropdown.cjs.map +1 -1
- package/dist/lib/dropdown.js +22 -21
- package/dist/lib/dropdown.js.map +1 -1
- package/dist/lib/editor.cjs +711 -1
- package/dist/lib/editor.cjs.map +1 -1
- package/dist/lib/editor.js +271 -235
- package/dist/lib/editor.js.map +1 -1
- package/dist/lib/emoji-picker.cjs +1277 -1
- package/dist/lib/emoji-picker.cjs.map +1 -1
- package/dist/lib/emoji-picker.js +859 -569
- package/dist/lib/emoji-picker.js.map +1 -1
- package/dist/lib/emoji-row.cjs +128 -1
- package/dist/lib/emoji-row.cjs.map +1 -1
- package/dist/lib/emoji-row.js +89 -75
- package/dist/lib/emoji-row.js.map +1 -1
- package/dist/lib/emoji-text-wrapper.cjs +102 -1
- package/dist/lib/emoji-text-wrapper.cjs.map +1 -1
- package/dist/lib/emoji-text-wrapper.js +42 -31
- package/dist/lib/emoji-text-wrapper.js.map +1 -1
- package/dist/lib/emoji.cjs +158 -1
- package/dist/lib/emoji.cjs.map +1 -1
- package/dist/lib/emoji.js +153 -6
- package/dist/lib/emoji.js.map +1 -1
- package/dist/lib/feed-item-row.cjs +296 -1
- package/dist/lib/feed-item-row.cjs.map +1 -1
- package/dist/lib/feed-item-row.js +119 -100
- package/dist/lib/feed-item-row.js.map +1 -1
- package/dist/lib/feed-pill.cjs +173 -1
- package/dist/lib/feed-pill.cjs.map +1 -1
- package/dist/lib/feed-pill.js +70 -57
- package/dist/lib/feed-pill.js.map +1 -1
- package/dist/lib/general-row.cjs +518 -1
- package/dist/lib/general-row.cjs.map +1 -1
- package/dist/lib/general-row.js +186 -148
- package/dist/lib/general-row.js.map +1 -1
- package/dist/lib/group-row.cjs +116 -1
- package/dist/lib/group-row.cjs.map +1 -1
- package/dist/lib/group-row.js +37 -35
- package/dist/lib/group-row.js.map +1 -1
- package/dist/lib/grouped-chip.cjs +96 -1
- package/dist/lib/grouped-chip.cjs.map +1 -1
- package/dist/lib/grouped-chip.js +51 -46
- package/dist/lib/grouped-chip.js.map +1 -1
- package/dist/lib/hovercard.cjs +223 -1
- package/dist/lib/hovercard.cjs.map +1 -1
- package/dist/lib/hovercard.js +115 -80
- package/dist/lib/hovercard.js.map +1 -1
- package/dist/lib/icon.cjs +58 -1
- package/dist/lib/icon.cjs.map +1 -1
- package/dist/lib/icon.js +20 -20
- package/dist/lib/icon.js.map +1 -1
- package/dist/lib/image-viewer.cjs +243 -1
- package/dist/lib/image-viewer.cjs.map +1 -1
- package/dist/lib/image-viewer.js +104 -80
- package/dist/lib/image-viewer.js.map +1 -1
- package/dist/lib/input-group.cjs +91 -1
- package/dist/lib/input-group.cjs.map +1 -1
- package/dist/lib/input-group.js +41 -39
- package/dist/lib/input-group.js.map +1 -1
- package/dist/lib/input.cjs +578 -1
- package/dist/lib/input.cjs.map +1 -1
- package/dist/lib/input.js +185 -137
- package/dist/lib/input.js.map +1 -1
- package/dist/lib/item-layout.cjs +91 -1
- package/dist/lib/item-layout.cjs.map +1 -1
- package/dist/lib/item-layout.js +45 -39
- package/dist/lib/item-layout.js.map +1 -1
- package/dist/lib/ivr-node.cjs +263 -1
- package/dist/lib/ivr-node.cjs.map +1 -1
- package/dist/lib/ivr-node.js +130 -112
- package/dist/lib/ivr-node.js.map +1 -1
- package/dist/lib/keyboard-shortcut.cjs +119 -1
- package/dist/lib/keyboard-shortcut.cjs.map +1 -1
- package/dist/lib/keyboard-shortcut.js +58 -48
- package/dist/lib/keyboard-shortcut.js.map +1 -1
- package/dist/lib/lazy-show.cjs +82 -1
- package/dist/lib/lazy-show.cjs.map +1 -1
- package/dist/lib/lazy-show.js +21 -19
- package/dist/lib/lazy-show.js.map +1 -1
- package/dist/lib/link.cjs +43 -1
- package/dist/lib/link.cjs.map +1 -1
- package/dist/lib/link.js +20 -19
- package/dist/lib/link.js.map +1 -1
- package/dist/lib/list-item-group.cjs +67 -1
- package/dist/lib/list-item-group.cjs.map +1 -1
- package/dist/lib/list-item-group.js +24 -22
- package/dist/lib/list-item-group.js.map +1 -1
- package/dist/lib/list-item.cjs +216 -1
- package/dist/lib/list-item.cjs.map +1 -1
- package/dist/lib/list-item.js +71 -60
- package/dist/lib/list-item.js.map +1 -1
- package/dist/lib/message-input.cjs +708 -1
- package/dist/lib/message-input.cjs.map +1 -1
- package/dist/lib/message-input.js +232 -206
- package/dist/lib/message-input.js.map +1 -1
- package/dist/lib/modal.cjs +444 -2
- package/dist/lib/modal.cjs.map +1 -1
- package/dist/lib/modal.js +153 -120
- package/dist/lib/modal.js.map +1 -1
- package/dist/lib/notice.cjs +197 -1
- package/dist/lib/notice.cjs.map +1 -1
- package/dist/lib/notice.js +66 -63
- package/dist/lib/notice.js.map +1 -1
- package/dist/lib/pagination.cjs +205 -1
- package/dist/lib/pagination.cjs.map +1 -1
- package/dist/lib/pagination.js +96 -81
- package/dist/lib/pagination.js.map +1 -1
- package/dist/lib/popover.cjs +1080 -1
- package/dist/lib/popover.cjs.map +1 -1
- package/dist/lib/popover.js +447 -267
- package/dist/lib/popover.js.map +1 -1
- package/dist/lib/presence.cjs +70 -1
- package/dist/lib/presence.cjs.map +1 -1
- package/dist/lib/presence.js +33 -27
- package/dist/lib/presence.js.map +1 -1
- package/dist/lib/radio-group.cjs +88 -1
- package/dist/lib/radio-group.cjs.map +1 -1
- package/dist/lib/radio-group.js +18 -18
- package/dist/lib/radio-group.js.map +1 -1
- package/dist/lib/radio.cjs +162 -1
- package/dist/lib/radio.cjs.map +1 -1
- package/dist/lib/radio.js +66 -57
- package/dist/lib/radio.js.map +1 -1
- package/dist/lib/rich-text-editor.cjs +1137 -1
- package/dist/lib/rich-text-editor.cjs.map +1 -1
- package/dist/lib/rich-text-editor.js +567 -386
- package/dist/lib/rich-text-editor.js.map +1 -1
- package/dist/lib/root-layout.cjs +158 -1
- package/dist/lib/root-layout.cjs.map +1 -1
- package/dist/lib/root-layout.js +33 -31
- package/dist/lib/root-layout.js.map +1 -1
- package/dist/lib/scroller.cjs +1090 -1
- package/dist/lib/scroller.cjs.map +1 -1
- package/dist/lib/scroller.js +668 -345
- package/dist/lib/scroller.js.map +1 -1
- package/dist/lib/select-menu.cjs +312 -1
- package/dist/lib/select-menu.cjs.map +1 -1
- package/dist/lib/select-menu.js +124 -79
- package/dist/lib/select-menu.js.map +1 -1
- package/dist/lib/settings-menu-button.cjs +77 -1
- package/dist/lib/settings-menu-button.cjs.map +1 -1
- package/dist/lib/settings-menu-button.js +31 -30
- package/dist/lib/settings-menu-button.js.map +1 -1
- package/dist/lib/skeleton.cjs +635 -1
- package/dist/lib/skeleton.cjs.map +1 -1
- package/dist/lib/skeleton.js +189 -152
- package/dist/lib/skeleton.js.map +1 -1
- package/dist/lib/stack.cjs +123 -1
- package/dist/lib/stack.cjs.map +1 -1
- package/dist/lib/stack.js +61 -53
- package/dist/lib/stack.js.map +1 -1
- package/dist/lib/tabs.cjs +102 -1
- package/dist/lib/tabs.cjs.map +1 -1
- package/dist/lib/tabs.js +47 -41
- package/dist/lib/tabs.js.map +1 -1
- package/dist/lib/time-pill.cjs +41 -1
- package/dist/lib/time-pill.cjs.map +1 -1
- package/dist/lib/time-pill.js +18 -14
- package/dist/lib/time-pill.js.map +1 -1
- package/dist/lib/toast.cjs +281 -1
- package/dist/lib/toast.cjs.map +1 -1
- package/dist/lib/toast.js +96 -74
- package/dist/lib/toast.js.map +1 -1
- package/dist/lib/toggle.cjs +192 -1
- package/dist/lib/toggle.cjs.map +1 -1
- package/dist/lib/toggle.js +60 -49
- package/dist/lib/toggle.js.map +1 -1
- package/dist/lib/tooltip-directive.cjs +84 -1
- package/dist/lib/tooltip-directive.cjs.map +1 -1
- package/dist/lib/tooltip-directive.js +56 -42
- package/dist/lib/tooltip-directive.js.map +1 -1
- package/dist/lib/tooltip.cjs +460 -1
- package/dist/lib/tooltip.cjs.map +1 -1
- package/dist/lib/tooltip.js +162 -103
- package/dist/lib/tooltip.js.map +1 -1
- package/dist/lib/top-banner-info.cjs +71 -1
- package/dist/lib/top-banner-info.cjs.map +1 -1
- package/dist/lib/top-banner-info.js +27 -22
- package/dist/lib/top-banner-info.js.map +1 -1
- package/dist/lib/unread-pill.cjs +73 -1
- package/dist/lib/unread-pill.cjs.map +1 -1
- package/dist/lib/unread-pill.js +28 -25
- package/dist/lib/unread-pill.js.map +1 -1
- package/dist/lib/validation-messages.cjs +89 -1
- package/dist/lib/validation-messages.cjs.map +1 -1
- package/dist/lib/validation-messages.js +41 -36
- package/dist/lib/validation-messages.js.map +1 -1
- package/dist/style.css +1257 -1
- package/dist/types/components/rich_text_editor/extensions/emoji/EmojiComponent.vue.d.ts +2 -2
- package/dist/types/components/rich_text_editor/extensions/mentions/MentionComponent.vue.d.ts +2 -2
- package/package.json +30 -29
- package/dist/chunks/_plugin-vue_export-helper-6_y-gaV6.js +0 -2
- package/dist/chunks/_plugin-vue_export-helper-6_y-gaV6.js.map +0 -1
- package/dist/chunks/_plugin-vue_export-helper-hUChTQA_.js +0 -10
- package/dist/chunks/_plugin-vue_export-helper-hUChTQA_.js.map +0 -1
- package/dist/chunks/dropdown-UO3UJalk.js +0 -2
- package/dist/chunks/dropdown_constants-EUcDxBrX.js +0 -9
- package/dist/chunks/dropdown_constants-EUcDxBrX.js.map +0 -1
- package/dist/chunks/dropdown_constants-KHFvVI2L.js +0 -2
- package/dist/chunks/dropdown_constants-KHFvVI2L.js.map +0 -1
- package/dist/chunks/icon_constants-2S_OSQ1t.js +0 -2
- package/dist/chunks/index-6tYeqbgP.js +0 -3
- package/dist/chunks/index-IBtQ5jRJ.js +0 -2
- package/dist/chunks/index-IBtQ5jRJ.js.map +0 -1
- package/dist/chunks/index-b4iXYvId.js +0 -399
- package/dist/chunks/index-mRmwpCBG.js +0 -256
- package/dist/chunks/index-mRmwpCBG.js.map +0 -1
- package/dist/chunks/input-0Uksk4DP.js +0 -2
- package/dist/chunks/input_group-AS760Cp7.js +0 -2
- package/dist/chunks/keyboard_list_navigation-F0O8nht0.js +0 -197
- package/dist/chunks/keyboard_list_navigation-N74Bpdq7.js +0 -2
- package/dist/chunks/link_constants-Kn6kP4i1.js +0 -2
- package/dist/chunks/link_constants-vIUB92L4.js +0 -16
- package/dist/chunks/list_item_constants-LTUc74pD.js +0 -13
- package/dist/chunks/list_item_constants-Tsz5CO1m.js +0 -2
- package/dist/chunks/modal-VuMFkZFH.js +0 -82
- package/dist/chunks/modal-qEzlo0Sj.js +0 -2
- package/dist/chunks/notice_action-jO199emq.js +0 -2
- package/dist/chunks/notice_action-tJfD5Qw1.js +0 -209
- package/dist/chunks/notice_constants-c--hBFQw.js +0 -6
- package/dist/chunks/notice_constants-mC6al2Dm.js +0 -2
- package/dist/chunks/popover_constants-hOEhklvr.js +0 -2
- package/dist/chunks/popover_constants-qjlEkroB.js +0 -114
- package/dist/chunks/sr_only_close_button-iD7s1Pbj.js +0 -3
- package/dist/chunks/stack_constants-m9Ickqw0.js +0 -2
- package/dist/chunks/stack_constants-u7tNqGtc.js +0 -13
- package/dist/chunks/tab-GQZFMq83.js +0 -367
- package/dist/chunks/tab-at7WWglk.js +0 -2
- package/dist/lib/constants.cjs +0 -2
- package/dist/lib/dates.cjs +0 -2
- package/dist/lib/dates.js +0 -57
- package/dist/lib/mixins.cjs +0 -2
- package/dist/lib/mixins.js +0 -17
- package/dist/lib/utils.cjs +0 -2
- package/dist/lib/utils.js +0 -171
- package/dist/lib/validators.cjs +0 -2
- package/dist/lib/validators.js +0 -12
- /package/dist/{lib → common}/mixins.js.map +0 -0
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { resolveComponent
|
|
3
|
-
import {
|
|
4
|
-
import { DtRecipeCallbarButton
|
|
5
|
-
import { DtPopover
|
|
6
|
-
import { DtButton
|
|
7
|
-
import { DtIcon
|
|
8
|
-
import "
|
|
1
|
+
import utils from "../common/utils.js";
|
|
2
|
+
import { resolveComponent, openBlock, createElementBlock, createVNode, withCtx, renderSlot, createBlock, mergeProps, normalizeClass, createCommentVNode } from "vue";
|
|
3
|
+
import { _export_sfc } from "../chunks/_plugin-vue_export-helper-caHeSgYY.js";
|
|
4
|
+
import { DtRecipeCallbarButton, CALLBAR_BUTTON_VALID_WIDTH_SIZE } from "./callbar-button.js";
|
|
5
|
+
import { DtPopover } from "./popover.js";
|
|
6
|
+
import { DtButton } from "./button.js";
|
|
7
|
+
import { DtIcon } from "./icon.js";
|
|
8
|
+
import "../common/constants.js";
|
|
9
9
|
import "./tooltip.js";
|
|
10
|
-
import "../chunks/popover_constants-
|
|
10
|
+
import "../chunks/popover_constants-Qkpb0yh2.js";
|
|
11
11
|
import "tippy.js";
|
|
12
12
|
import "./lazy-show.js";
|
|
13
|
-
import "../chunks/modal-
|
|
14
|
-
import "../chunks/sr_only_close_button-
|
|
15
|
-
import "../chunks/link_constants-
|
|
13
|
+
import "../chunks/modal-XOr4kiNZ.js";
|
|
14
|
+
import "../chunks/sr_only_close_button-3EdsV-dH.js";
|
|
15
|
+
import "../chunks/link_constants-nWVlXQBs.js";
|
|
16
16
|
import "@dialpad/dialtone-icons/vue3";
|
|
17
|
-
import "../chunks/icon_constants-
|
|
17
|
+
import "../chunks/icon_constants-Dy4MEUJL.js";
|
|
18
18
|
import "@dialpad/dialtone-icons/icons.json";
|
|
19
|
-
const
|
|
19
|
+
const _sfc_main = {
|
|
20
20
|
name: "DtRecipeCallbarButtonWithPopover",
|
|
21
|
-
components: { DtRecipeCallbarButton
|
|
21
|
+
components: { DtRecipeCallbarButton, DtPopover, DtButton, DtIcon },
|
|
22
22
|
/* inheritAttrs: false is generally an option we want to set on library
|
|
23
23
|
components. This allows any attributes passed in that are not recognized
|
|
24
24
|
as props to be passed down to another element or component using v-bind:$attrs
|
|
25
25
|
more info: https://vuejs.org/v2/api/#inheritAttrs */
|
|
26
|
-
inheritAttrs:
|
|
26
|
+
inheritAttrs: false,
|
|
27
27
|
props: {
|
|
28
28
|
/**
|
|
29
29
|
* Id for the item.
|
|
@@ -31,7 +31,7 @@ const k = {
|
|
|
31
31
|
id: {
|
|
32
32
|
type: String,
|
|
33
33
|
default() {
|
|
34
|
-
return
|
|
34
|
+
return utils.getUniqueString();
|
|
35
35
|
}
|
|
36
36
|
},
|
|
37
37
|
/**
|
|
@@ -40,15 +40,19 @@ const k = {
|
|
|
40
40
|
ariaLabel: {
|
|
41
41
|
type: String,
|
|
42
42
|
default: null,
|
|
43
|
-
validator: (
|
|
43
|
+
validator: (label) => {
|
|
44
|
+
return label || (void 0).$slots.default;
|
|
45
|
+
}
|
|
44
46
|
},
|
|
45
47
|
/**
|
|
46
48
|
* Aria label for the arrow. Cannot be empty.
|
|
47
49
|
*/
|
|
48
50
|
arrowButtonLabel: {
|
|
49
51
|
type: String,
|
|
50
|
-
required:
|
|
51
|
-
validator: (
|
|
52
|
+
required: true,
|
|
53
|
+
validator: (label) => {
|
|
54
|
+
return !!label;
|
|
55
|
+
}
|
|
52
56
|
},
|
|
53
57
|
/**
|
|
54
58
|
* The direction the popover displays relative to the anchor.
|
|
@@ -78,7 +82,7 @@ const k = {
|
|
|
78
82
|
*/
|
|
79
83
|
showCloseButton: {
|
|
80
84
|
type: Boolean,
|
|
81
|
-
default:
|
|
85
|
+
default: true
|
|
82
86
|
},
|
|
83
87
|
/**
|
|
84
88
|
* Determines whether the button should be disabled
|
|
@@ -87,7 +91,7 @@ const k = {
|
|
|
87
91
|
*/
|
|
88
92
|
disabled: {
|
|
89
93
|
type: Boolean,
|
|
90
|
-
default:
|
|
94
|
+
default: false
|
|
91
95
|
},
|
|
92
96
|
/**
|
|
93
97
|
* Forces showing the arrow, even if the button is disabled.
|
|
@@ -96,7 +100,7 @@ const k = {
|
|
|
96
100
|
*/
|
|
97
101
|
forceShowArrow: {
|
|
98
102
|
type: Boolean,
|
|
99
|
-
default:
|
|
103
|
+
default: false
|
|
100
104
|
},
|
|
101
105
|
/**
|
|
102
106
|
* Determines whether the button should have active styling
|
|
@@ -106,7 +110,7 @@ const k = {
|
|
|
106
110
|
*/
|
|
107
111
|
active: {
|
|
108
112
|
type: Boolean,
|
|
109
|
-
default:
|
|
113
|
+
default: false
|
|
110
114
|
},
|
|
111
115
|
/**
|
|
112
116
|
* Determines whether the button should have danger styling
|
|
@@ -116,7 +120,7 @@ const k = {
|
|
|
116
120
|
*/
|
|
117
121
|
danger: {
|
|
118
122
|
type: Boolean,
|
|
119
|
-
default:
|
|
123
|
+
default: false
|
|
120
124
|
},
|
|
121
125
|
/**
|
|
122
126
|
* We need this declaration because of how Vue3 informs the component about a listener.
|
|
@@ -151,7 +155,7 @@ const k = {
|
|
|
151
155
|
buttonWidthSize: {
|
|
152
156
|
type: String,
|
|
153
157
|
default: "xl",
|
|
154
|
-
validator: (
|
|
158
|
+
validator: (size) => CALLBAR_BUTTON_VALID_WIDTH_SIZE.includes(size)
|
|
155
159
|
},
|
|
156
160
|
/**
|
|
157
161
|
* Additional class name for the popover content wrapper element.
|
|
@@ -165,7 +169,7 @@ const k = {
|
|
|
165
169
|
*/
|
|
166
170
|
openPopover: {
|
|
167
171
|
type: Boolean,
|
|
168
|
-
default:
|
|
172
|
+
default: false
|
|
169
173
|
}
|
|
170
174
|
},
|
|
171
175
|
emits: [
|
|
@@ -187,7 +191,7 @@ const k = {
|
|
|
187
191
|
],
|
|
188
192
|
data() {
|
|
189
193
|
return {
|
|
190
|
-
open:
|
|
194
|
+
open: false
|
|
191
195
|
};
|
|
192
196
|
},
|
|
193
197
|
computed: {
|
|
@@ -198,12 +202,17 @@ const k = {
|
|
|
198
202
|
return this.buttonWidthSize === "sm" || this.buttonWidthSize === "md";
|
|
199
203
|
},
|
|
200
204
|
showPopover() {
|
|
201
|
-
|
|
205
|
+
if (!this.openPopover || this.open) {
|
|
206
|
+
this.syncOpenState();
|
|
207
|
+
return false;
|
|
208
|
+
}
|
|
209
|
+
return this.toggleOpen();
|
|
202
210
|
}
|
|
203
211
|
},
|
|
204
212
|
methods: {
|
|
205
|
-
arrowClick(
|
|
206
|
-
|
|
213
|
+
arrowClick(ev) {
|
|
214
|
+
this.$emit("arrow-click", ev);
|
|
215
|
+
return this.toggleOpen();
|
|
207
216
|
},
|
|
208
217
|
toggleOpen() {
|
|
209
218
|
return this.open = !this.open;
|
|
@@ -211,72 +220,81 @@ const k = {
|
|
|
211
220
|
syncOpenState() {
|
|
212
221
|
this.open = this.openPopover;
|
|
213
222
|
},
|
|
214
|
-
buttonClick(
|
|
215
|
-
this.$props.onClick
|
|
223
|
+
buttonClick(ev) {
|
|
224
|
+
if (!this.$props.onClick) {
|
|
225
|
+
this.arrowClick(ev);
|
|
226
|
+
} else {
|
|
227
|
+
this.$emit("click", ev);
|
|
228
|
+
}
|
|
216
229
|
},
|
|
217
|
-
onModalIsOpened(
|
|
218
|
-
this.open =
|
|
230
|
+
onModalIsOpened(isOpened) {
|
|
231
|
+
this.open = isOpened;
|
|
232
|
+
this.$emit("opened", isOpened);
|
|
219
233
|
}
|
|
220
234
|
}
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
"
|
|
231
|
-
|
|
232
|
-
|
|
235
|
+
};
|
|
236
|
+
const _hoisted_1 = { class: "dt-recipe--callbar-button-with-popover" };
|
|
237
|
+
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
238
|
+
const _component_dt_recipe_callbar_button = resolveComponent("dt-recipe-callbar-button");
|
|
239
|
+
const _component_dt_icon = resolveComponent("dt-icon");
|
|
240
|
+
const _component_dt_button = resolveComponent("dt-button");
|
|
241
|
+
const _component_dt_popover = resolveComponent("dt-popover");
|
|
242
|
+
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
243
|
+
createVNode(_component_dt_recipe_callbar_button, {
|
|
244
|
+
"aria-label": $props.ariaLabel,
|
|
245
|
+
disabled: $props.disabled,
|
|
246
|
+
active: $props.active,
|
|
247
|
+
danger: $props.danger,
|
|
248
|
+
"button-class": $props.buttonClass,
|
|
249
|
+
"button-width-size": $props.buttonWidthSize,
|
|
250
|
+
"text-class": $props.textClass,
|
|
233
251
|
class: "dt-recipe--callbar-button-with-popover--main-button",
|
|
234
|
-
onClick:
|
|
252
|
+
onClick: $options.buttonClick
|
|
235
253
|
}, {
|
|
236
|
-
icon:
|
|
237
|
-
|
|
254
|
+
icon: withCtx(() => [
|
|
255
|
+
renderSlot(_ctx.$slots, "icon")
|
|
238
256
|
]),
|
|
239
|
-
tooltip:
|
|
240
|
-
|
|
257
|
+
tooltip: withCtx(() => [
|
|
258
|
+
renderSlot(_ctx.$slots, "tooltip")
|
|
241
259
|
]),
|
|
242
|
-
default:
|
|
243
|
-
|
|
260
|
+
default: withCtx(() => [
|
|
261
|
+
renderSlot(_ctx.$slots, "default")
|
|
244
262
|
]),
|
|
245
263
|
_: 3
|
|
246
264
|
}, 8, ["aria-label", "disabled", "active", "danger", "button-class", "button-width-size", "text-class", "onClick"]),
|
|
247
|
-
|
|
265
|
+
$options.showArrowButton ? (openBlock(), createBlock(_component_dt_popover, mergeProps({
|
|
248
266
|
key: 0,
|
|
249
|
-
id:
|
|
250
|
-
modal:
|
|
251
|
-
open:
|
|
252
|
-
placement:
|
|
253
|
-
"initial-focus-element":
|
|
254
|
-
"show-close-button":
|
|
267
|
+
id: $props.id,
|
|
268
|
+
modal: false,
|
|
269
|
+
open: $data.open,
|
|
270
|
+
placement: $props.placement,
|
|
271
|
+
"initial-focus-element": $props.initialFocusElement,
|
|
272
|
+
"show-close-button": $props.showCloseButton,
|
|
255
273
|
offset: [0, 16],
|
|
256
274
|
padding: "none",
|
|
257
275
|
class: "dt-recipe--callbar-button-with-popover--popover-wrapper",
|
|
258
|
-
"dialog-class": ["dt-recipe--callbar-button-with-popover--popover",
|
|
276
|
+
"dialog-class": ["dt-recipe--callbar-button-with-popover--popover", $props.contentClass],
|
|
259
277
|
"header-class": "d-d-flex d-ai-center d-fw-normal d-px12"
|
|
260
|
-
},
|
|
261
|
-
"open-popover":
|
|
262
|
-
onOpened:
|
|
278
|
+
}, _ctx.$attrs, {
|
|
279
|
+
"open-popover": $options.showPopover,
|
|
280
|
+
onOpened: $options.onModalIsOpened
|
|
263
281
|
}), {
|
|
264
|
-
anchor:
|
|
265
|
-
|
|
282
|
+
anchor: withCtx(() => [
|
|
283
|
+
createVNode(_component_dt_button, {
|
|
266
284
|
circle: "",
|
|
267
285
|
importance: "clear",
|
|
268
286
|
size: "lg",
|
|
269
|
-
class:
|
|
287
|
+
class: normalizeClass([
|
|
270
288
|
"dt-recipe--callbar-button-with-popover--arrow",
|
|
271
|
-
{ "dt-recipe--callbar-button-with-popover--arrow--large":
|
|
289
|
+
{ "dt-recipe--callbar-button-with-popover--arrow--large": !$options.isCompactMode }
|
|
272
290
|
]),
|
|
273
291
|
width: "2rem",
|
|
274
|
-
"aria-label":
|
|
275
|
-
active:
|
|
276
|
-
onClick:
|
|
292
|
+
"aria-label": $props.arrowButtonLabel,
|
|
293
|
+
active: $data.open,
|
|
294
|
+
onClick: $options.arrowClick
|
|
277
295
|
}, {
|
|
278
|
-
icon:
|
|
279
|
-
|
|
296
|
+
icon: withCtx(() => [
|
|
297
|
+
createVNode(_component_dt_icon, {
|
|
280
298
|
name: "chevron-up",
|
|
281
299
|
class: "dt-recipe--callbar-button-with-popover--arrow__icon",
|
|
282
300
|
size: "200"
|
|
@@ -285,21 +303,21 @@ function A(t, z, e, P, i, n) {
|
|
|
285
303
|
_: 1
|
|
286
304
|
}, 8, ["class", "aria-label", "active", "onClick"])
|
|
287
305
|
]),
|
|
288
|
-
content:
|
|
289
|
-
|
|
306
|
+
content: withCtx(() => [
|
|
307
|
+
renderSlot(_ctx.$slots, "content")
|
|
290
308
|
]),
|
|
291
|
-
headerContent:
|
|
292
|
-
|
|
309
|
+
headerContent: withCtx(() => [
|
|
310
|
+
renderSlot(_ctx.$slots, "headerContent")
|
|
293
311
|
]),
|
|
294
|
-
footerContent:
|
|
295
|
-
|
|
312
|
+
footerContent: withCtx(() => [
|
|
313
|
+
renderSlot(_ctx.$slots, "footerContent")
|
|
296
314
|
]),
|
|
297
315
|
_: 3
|
|
298
|
-
}, 16, ["id", "open", "placement", "initial-focus-element", "show-close-button", "dialog-class", "open-popover", "onOpened"])) :
|
|
316
|
+
}, 16, ["id", "open", "placement", "initial-focus-element", "show-close-button", "dialog-class", "open-popover", "onOpened"])) : createCommentVNode("", true)
|
|
299
317
|
]);
|
|
300
318
|
}
|
|
301
|
-
const
|
|
319
|
+
const callbar_button_with_popover = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
302
320
|
export {
|
|
303
|
-
|
|
321
|
+
callbar_button_with_popover as DtRecipeCallbarButtonWithPopover
|
|
304
322
|
};
|
|
305
323
|
//# sourceMappingURL=callbar-button-with-popover.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"callbar-button-with-popover.js","sources":["../../recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue"],"sourcesContent":["<template>\n <div\n class=\"dt-recipe--callbar-button-with-popover\"\n >\n <dt-recipe-callbar-button\n :aria-label=\"ariaLabel\"\n :disabled=\"disabled\"\n :active=\"active\"\n :danger=\"danger\"\n :button-class=\"buttonClass\"\n :button-width-size=\"buttonWidthSize\"\n :text-class=\"textClass\"\n class=\"dt-recipe--callbar-button-with-popover--main-button\"\n @click=\"buttonClick\"\n >\n <template #icon>\n <slot name=\"icon\" />\n </template>\n <template #tooltip>\n <slot name=\"tooltip\" />\n </template>\n <slot />\n </dt-recipe-callbar-button>\n <dt-popover\n v-if=\"showArrowButton\"\n :id=\"id\"\n :modal=\"false\"\n :open=\"open\"\n :placement=\"placement\"\n :initial-focus-element=\"initialFocusElement\"\n :show-close-button=\"showCloseButton\"\n :offset=\"[0, 16]\"\n padding=\"none\"\n class=\"dt-recipe--callbar-button-with-popover--popover-wrapper\"\n :dialog-class=\"['dt-recipe--callbar-button-with-popover--popover', contentClass]\"\n header-class=\"d-d-flex d-ai-center d-fw-normal d-px12\"\n v-bind=\"$attrs\"\n :open-popover=\"showPopover\"\n @opened=\"onModalIsOpened\"\n >\n <template #anchor>\n <dt-button\n circle\n importance=\"clear\"\n size=\"lg\"\n :class=\"['dt-recipe--callbar-button-with-popover--arrow',\n { 'dt-recipe--callbar-button-with-popover--arrow--large': !isCompactMode }]\"\n width=\"2rem\"\n :aria-label=\"arrowButtonLabel\"\n :active=\"open\"\n @click=\"arrowClick\"\n >\n <template #icon>\n <dt-icon\n name=\"chevron-up\"\n class=\"dt-recipe--callbar-button-with-popover--arrow__icon\"\n size=\"200\"\n />\n </template>\n </dt-button>\n </template>\n <template #content>\n <slot name=\"content\" />\n </template>\n <template #headerContent>\n <slot name=\"headerContent\" />\n </template>\n <template #footerContent>\n <slot name=\"footerContent\" />\n </template>\n </dt-popover>\n </div>\n</template>\n\n<script>\nimport { DtButton } from '@/components/button';\nimport { DtPopover } from '@/components/popover';\nimport { DtIcon } from '@/components/icon';\nimport { DtRecipeCallbarButton, CALLBAR_BUTTON_VALID_WIDTH_SIZE } from '../callbar_button';\nimport utils from '@/common/utils';\n\nexport default {\n name: 'DtRecipeCallbarButtonWithPopover',\n\n components: { DtRecipeCallbarButton, DtPopover, DtButton, DtIcon },\n\n /* inheritAttrs: false is generally an option we want to set on library\n components. This allows any attributes passed in that are not recognized\n as props to be passed down to another element or component using v-bind:$attrs\n more info: https://vuejs.org/v2/api/#inheritAttrs */\n inheritAttrs: false,\n\n props: {\n /**\n * Id for the item.\n */\n id: {\n type: String,\n default () {\n return utils.getUniqueString();\n },\n },\n\n /**\n * Aria label for the button. If empty, it takes its value from the default slot.\n */\n ariaLabel: {\n type: String,\n default: null,\n validator: (label) => {\n return label || this.$slots.default;\n },\n },\n\n /**\n * Aria label for the arrow. Cannot be empty.\n */\n arrowButtonLabel: {\n type: String,\n required: true,\n validator: (label) => {\n return !!label;\n },\n },\n\n /**\n * The direction the popover displays relative to the anchor.\n * @values 'bottom', 'bottom-start', 'bottom-end',\n * 'right', 'right-start', 'right-end',\n * 'left', 'left-start', 'left-end',\n * 'top', 'top-start', 'top-end'\n * @default 'top'\n */\n placement: {\n type: String,\n default: 'top',\n },\n\n /**\n * The element that is focused when the popover is opened. This can be an\n * HTMLElement within the popover, a string starting with '#' which will\n * find the element by ID. 'first' which will automatically focus\n * the first element, or 'dialog' which will focus the dialog window itself.\n * If the dialog is modal this prop cannot be 'none'.\n */\n initialFocusElement: {\n type: String,\n default: 'first',\n },\n\n /**\n * Determines visibility for close button\n */\n showCloseButton: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Determines whether the button should be disabled\n * default is false.\n * @values true, false\n */\n disabled: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Forces showing the arrow, even if the button is disabled.\n * default is false\n * @values true, false\n */\n forceShowArrow: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Determines whether the button should have active styling\n * default is false.\n * @values true, false\n * @see https://dialtone.dialpad.com/components/button/\n */\n active: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Determines whether the button should have danger styling\n * default is false.\n * @values true, false\n * @see https://dialtone.dialpad.com/components/button/\n */\n danger: {\n type: Boolean,\n default: false,\n },\n\n /**\n * We need this declaration because of how Vue3 informs the component about a listener.\n * Spoiler alert: it doesn't.\n * Vue3 intends to work as a real pub-sub, meaning the publisher has not a clue of who the subscribers are.\n * This makes it impossible from the regular declaration (emits: ['click']) to check whether\n * we actually have a click handler or not.\n * We're hacking it by adding an onClick prop: https://github.com/vuejs/core/issues/5220\n */\n /* eslint-disable-next-line vue/no-unused-properties */\n onClick: {\n type: Function,\n default: null,\n },\n\n /**\n * Additional class name for the button wrapper element.\n */\n buttonClass: {\n type: [String, Array, Object],\n default: '',\n },\n\n /**\n * Additional class name for the button text.\n */\n textClass: {\n type: [String, Array, Object],\n default: '',\n },\n\n /*\n * Width size. Valid values are: 'xl', 'lg', 'md' and 'sm'.\n */\n buttonWidthSize: {\n type: String,\n default: 'xl',\n validator: size => CALLBAR_BUTTON_VALID_WIDTH_SIZE.includes(size),\n },\n\n /**\n * Additional class name for the popover content wrapper element.\n */\n contentClass: {\n type: [String, Array, Object],\n default: '',\n },\n\n /**\n * To auto open the modal popover.\n */\n openPopover: {\n type: Boolean,\n default: false,\n },\n },\n\n emits: [\n /**\n * Emitted when the arrow is clicked\n */\n 'arrow-click',\n\n /**\n * Native click event\n *\n * @event click\n * @type {PointerEvent | KeyboardEvent}\n */\n 'click',\n\n /**\n * Emitted when modal popover is opened or closed.\n */\n 'opened',\n ],\n\n data () {\n return {\n open: false,\n };\n },\n\n computed: {\n showArrowButton () {\n return this.forceShowArrow || !this.disabled;\n },\n\n isCompactMode () {\n return this.buttonWidthSize === 'sm' || this.buttonWidthSize === 'md';\n },\n\n showPopover () {\n if (!this.openPopover || this.open) {\n this.syncOpenState();\n return false;\n }\n\n return this.toggleOpen();\n },\n },\n\n methods: {\n arrowClick (ev) {\n this.$emit('arrow-click', ev);\n return this.toggleOpen();\n },\n\n toggleOpen () {\n return (this.open = !this.open);\n },\n\n syncOpenState () {\n this.open = this.openPopover;\n },\n\n buttonClick (ev) {\n // If no listener for the click event, the button click opens the popover\n // the same as if the arrow was clicked.\n if (!this.$props.onClick) {\n this.arrowClick(ev);\n } else {\n this.$emit('click', ev);\n }\n },\n\n onModalIsOpened (isOpened) {\n this.open = isOpened;\n this.$emit('opened', isOpened);\n },\n },\n\n};\n</script>\n\n<style lang=\"less\">\n.dt-recipe--callbar-button-with-popover--arrow {\n margin-top: var(--dt-space-350-negative);\n margin-left: calc(var(--dt-space-300-negative) * 5);\n width: var(--dt-size-500);\n height: var(--dt-size-500);\n padding: var(--dt-space-400);\n border-radius: var(--dt-size-300);\n\n &.d-btn--active {\n background: var(--dt-color-surface-moderate-opaque);\n }\n\n &--large {\n margin-left: var(--dt-space-550-negative);\n }\n\n &__icon {\n color: var(--dt-color-black-800);\n }\n}\n\n.dt-recipe--callbar-button-with-popover--popover {\n .d-popover__header {\n background: var(--dt-color-surface-contrast);\n color: var(--dt-color-foreground-primary-inverted);\n\n .d-btn {\n color: var(--dt-color-foreground-primary-inverted);\n }\n }\n}\n\n.dt-recipe--callbar-button-with-popover--button .d-tab--selected::after,\n.dt-recipe--callbar-button-with-popover--button .d-tab--selected:hover::after {\n --tab--bgc: var(--dt-color-surface-contrast);\n}\n.dt-recipe--callbar-button-with-popover--button .tab-group {\n display: flex;\n flex-direction: column;\n height: 100%;\n}\n\n.dt-recipe--callbar-button-with-popover--button .tab-content {\n flex: 1 1 100%;\n overflow-y: auto;\n}\n\n.dt-recipe--callbar-button-with-popover {\n display: flex;\n align-items: center;\n}\n</style>\n"],"names":["_sfc_main","DtRecipeCallbarButton","DtPopover","DtButton","DtIcon","utils","label","this","size","CALLBAR_BUTTON_VALID_WIDTH_SIZE","ev","isOpened","_hoisted_1","_openBlock","_createElementBlock","_createVNode","_component_dt_recipe_callbar_button","$props","$options","_renderSlot","_ctx","_createBlock","_component_dt_popover","_mergeProps","$data","_component_dt_button","_normalizeClass","_component_dt_icon"],"mappings":";;;;;;;;;;;;;;;;;;AAiFA,MAAKA,IAAU;AAAA,EACb,MAAM;AAAA,EAEN,YAAY,EAAE,uBAAAC,GAAuB,WAAAC,GAAW,UAAAC,GAAU,QAAAC,EAAQ;AAAA;AAAA;AAAA;AAAA;AAAA,EAMlE,cAAc;AAAA,EAEd,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,IAAI;AAAA,MACF,MAAM;AAAA,MACN,UAAW;AACT,eAAOC,EAAM;MACd;AAAA,IACF;AAAA;AAAA;AAAA;AAAA,IAKD,WAAW;AAAA,MACT,MAAM;AAAA,MACN,SAAS;AAAA,MACT,WAAW,CAACC,MACHA,KAASC,SAAK,OAAO;AAAA,IAE/B;AAAA;AAAA;AAAA;AAAA,IAKD,kBAAkB;AAAA,MAChB,MAAM;AAAA,MACN,UAAU;AAAA,MACV,WAAW,CAACD,MACH,CAAC,CAACA;AAAA,IAEZ;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAUD,WAAW;AAAA,MACT,MAAM;AAAA,MACN,SAAS;AAAA,IACV;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IASD,qBAAqB;AAAA,MACnB,MAAM;AAAA,MACN,SAAS;AAAA,IACV;AAAA;AAAA;AAAA;AAAA,IAKD,iBAAiB;AAAA,MACf,MAAM;AAAA,MACN,SAAS;AAAA,IACV;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOD,UAAU;AAAA,MACR,MAAM;AAAA,MACN,SAAS;AAAA,IACV;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOD,gBAAgB;AAAA,MACd,MAAM;AAAA,MACN,SAAS;AAAA,IACV;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAQD,QAAQ;AAAA,MACN,MAAM;AAAA,M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AAA,MAChB,SAAQ;AAAA,MACR,OAAM;AAAA,MACL,oEAAkEA,EAAY,YAAA;AAAA,MAC/E,gBAAa;AAAA,OACLG,EAAM,QAAA;AAAA,MACb,gBAAcF,EAAW;AAAA,MACzB,UAAQA,EAAe;AAAA;MAEb,UACT,MAkBY;AAAA,QAlBZH,EAkBYU,GAAA;AAAA,UAjBV,QAAA;AAAA,UACA,YAAW;AAAA,UACX,MAAK;AAAA,UACJ,OAAKC,EAAA;AAAA,YAAA;AAAA,uEAAkIR,EAAa,cAAA;AAAA,UAAA,CAAA;AAAA,UAErJ,OAAM;AAAA,UACL,cAAYD,EAAgB;AAAA,UAC5B,QAAQO,EAAI;AAAA,UACZ,SAAON,EAAU;AAAA;UAEP,QACT,MAIE;AAAA,YAJFH,EAIEY,GAAA;AAAA,cAHA,MAAK;AAAA,cACL,OAAM;AAAA,cACN,MAAK;AAAA;;;;;MAKF,WACT,MAAuB;AAAA,QAAvBR,EAAuBC,EAAA,QAAA,SAAA;AAAA;MAEd,iBACT,MAA6B;AAAA,QAA7BD,EAA6BC,EAAA,QAAA,eAAA;AAAA;MAEpB,iBACT,MAA6B;AAAA,QAA7BD,EAA6BC,EAAA,QAAA,eAAA;AAAA;;;;;;"}
|
|
1
|
+
{"version":3,"file":"callbar-button-with-popover.js","sources":["../../recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue"],"sourcesContent":["<template>\n <div\n class=\"dt-recipe--callbar-button-with-popover\"\n >\n <dt-recipe-callbar-button\n :aria-label=\"ariaLabel\"\n :disabled=\"disabled\"\n :active=\"active\"\n :danger=\"danger\"\n :button-class=\"buttonClass\"\n :button-width-size=\"buttonWidthSize\"\n :text-class=\"textClass\"\n class=\"dt-recipe--callbar-button-with-popover--main-button\"\n @click=\"buttonClick\"\n >\n <template #icon>\n <slot name=\"icon\" />\n </template>\n <template #tooltip>\n <slot name=\"tooltip\" />\n </template>\n <slot />\n </dt-recipe-callbar-button>\n <dt-popover\n v-if=\"showArrowButton\"\n :id=\"id\"\n :modal=\"false\"\n :open=\"open\"\n :placement=\"placement\"\n :initial-focus-element=\"initialFocusElement\"\n :show-close-button=\"showCloseButton\"\n :offset=\"[0, 16]\"\n padding=\"none\"\n class=\"dt-recipe--callbar-button-with-popover--popover-wrapper\"\n :dialog-class=\"['dt-recipe--callbar-button-with-popover--popover', contentClass]\"\n header-class=\"d-d-flex d-ai-center d-fw-normal d-px12\"\n v-bind=\"$attrs\"\n :open-popover=\"showPopover\"\n @opened=\"onModalIsOpened\"\n >\n <template #anchor>\n <dt-button\n circle\n importance=\"clear\"\n size=\"lg\"\n :class=\"['dt-recipe--callbar-button-with-popover--arrow',\n { 'dt-recipe--callbar-button-with-popover--arrow--large': !isCompactMode }]\"\n width=\"2rem\"\n :aria-label=\"arrowButtonLabel\"\n :active=\"open\"\n @click=\"arrowClick\"\n >\n <template #icon>\n <dt-icon\n name=\"chevron-up\"\n class=\"dt-recipe--callbar-button-with-popover--arrow__icon\"\n size=\"200\"\n />\n </template>\n </dt-button>\n </template>\n <template #content>\n <slot name=\"content\" />\n </template>\n <template #headerContent>\n <slot name=\"headerContent\" />\n </template>\n <template #footerContent>\n <slot name=\"footerContent\" />\n </template>\n </dt-popover>\n </div>\n</template>\n\n<script>\nimport { DtButton } from '@/components/button';\nimport { DtPopover } from '@/components/popover';\nimport { DtIcon } from '@/components/icon';\nimport { DtRecipeCallbarButton, CALLBAR_BUTTON_VALID_WIDTH_SIZE } from '../callbar_button';\nimport utils from '@/common/utils';\n\nexport default {\n name: 'DtRecipeCallbarButtonWithPopover',\n\n components: { DtRecipeCallbarButton, DtPopover, DtButton, DtIcon },\n\n /* inheritAttrs: false is generally an option we want to set on library\n components. This allows any attributes passed in that are not recognized\n as props to be passed down to another element or component using v-bind:$attrs\n more info: https://vuejs.org/v2/api/#inheritAttrs */\n inheritAttrs: false,\n\n props: {\n /**\n * Id for the item.\n */\n id: {\n type: String,\n default () {\n return utils.getUniqueString();\n },\n },\n\n /**\n * Aria label for the button. If empty, it takes its value from the default slot.\n */\n ariaLabel: {\n type: String,\n default: null,\n validator: (label) => {\n return label || this.$slots.default;\n },\n },\n\n /**\n * Aria label for the arrow. Cannot be empty.\n */\n arrowButtonLabel: {\n type: String,\n required: true,\n validator: (label) => {\n return !!label;\n },\n },\n\n /**\n * The direction the popover displays relative to the anchor.\n * @values 'bottom', 'bottom-start', 'bottom-end',\n * 'right', 'right-start', 'right-end',\n * 'left', 'left-start', 'left-end',\n * 'top', 'top-start', 'top-end'\n * @default 'top'\n */\n placement: {\n type: String,\n default: 'top',\n },\n\n /**\n * The element that is focused when the popover is opened. This can be an\n * HTMLElement within the popover, a string starting with '#' which will\n * find the element by ID. 'first' which will automatically focus\n * the first element, or 'dialog' which will focus the dialog window itself.\n * If the dialog is modal this prop cannot be 'none'.\n */\n initialFocusElement: {\n type: String,\n default: 'first',\n },\n\n /**\n * Determines visibility for close button\n */\n showCloseButton: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Determines whether the button should be disabled\n * default is false.\n * @values true, false\n */\n disabled: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Forces showing the arrow, even if the button is disabled.\n * default is false\n * @values true, false\n */\n forceShowArrow: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Determines whether the button should have active styling\n * default is false.\n * @values true, false\n * @see https://dialtone.dialpad.com/components/button/\n */\n active: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Determines whether the button should have danger styling\n * default is false.\n * @values true, false\n * @see https://dialtone.dialpad.com/components/button/\n */\n danger: {\n type: Boolean,\n default: false,\n },\n\n /**\n * We need this declaration because of how Vue3 informs the component about a listener.\n * Spoiler alert: it doesn't.\n * Vue3 intends to work as a real pub-sub, meaning the publisher has not a clue of who the subscribers are.\n * This makes it impossible from the regular declaration (emits: ['click']) to check whether\n * we actually have a click handler or not.\n * We're hacking it by adding an onClick prop: https://github.com/vuejs/core/issues/5220\n */\n /* eslint-disable-next-line vue/no-unused-properties */\n onClick: {\n type: Function,\n default: null,\n },\n\n /**\n * Additional class name for the button wrapper element.\n */\n buttonClass: {\n type: [String, Array, Object],\n default: '',\n },\n\n /**\n * Additional class name for the button text.\n */\n textClass: {\n type: [String, Array, Object],\n default: '',\n },\n\n /*\n * Width size. Valid values are: 'xl', 'lg', 'md' and 'sm'.\n */\n buttonWidthSize: {\n type: String,\n default: 'xl',\n validator: size => CALLBAR_BUTTON_VALID_WIDTH_SIZE.includes(size),\n },\n\n /**\n * Additional class name for the popover content wrapper element.\n */\n contentClass: {\n type: [String, Array, Object],\n default: '',\n },\n\n /**\n * To auto open the modal popover.\n */\n openPopover: {\n type: Boolean,\n default: false,\n },\n },\n\n emits: [\n /**\n * Emitted when the arrow is clicked\n */\n 'arrow-click',\n\n /**\n * Native click event\n *\n * @event click\n * @type {PointerEvent | KeyboardEvent}\n */\n 'click',\n\n /**\n * Emitted when modal popover is opened or closed.\n */\n 'opened',\n ],\n\n data () {\n return {\n open: false,\n };\n },\n\n computed: {\n showArrowButton () {\n return this.forceShowArrow || !this.disabled;\n },\n\n isCompactMode () {\n return this.buttonWidthSize === 'sm' || this.buttonWidthSize === 'md';\n },\n\n showPopover () {\n if (!this.openPopover || this.open) {\n this.syncOpenState();\n return false;\n }\n\n return this.toggleOpen();\n },\n },\n\n methods: {\n arrowClick (ev) {\n this.$emit('arrow-click', ev);\n return this.toggleOpen();\n },\n\n toggleOpen () {\n return (this.open = !this.open);\n },\n\n syncOpenState () {\n this.open = this.openPopover;\n },\n\n buttonClick (ev) {\n // If no listener for the click event, the button click opens the popover\n // the same as if the arrow was clicked.\n if (!this.$props.onClick) {\n this.arrowClick(ev);\n } else {\n this.$emit('click', ev);\n }\n },\n\n onModalIsOpened (isOpened) {\n this.open = isOpened;\n this.$emit('opened', isOpened);\n },\n },\n\n};\n</script>\n\n<style lang=\"less\">\n.dt-recipe--callbar-button-with-popover--arrow {\n margin-top: var(--dt-space-350-negative);\n margin-left: calc(var(--dt-space-300-negative) * 5);\n width: var(--dt-size-500);\n height: var(--dt-size-500);\n padding: var(--dt-space-400);\n border-radius: var(--dt-size-300);\n\n &.d-btn--active {\n background: var(--dt-color-surface-moderate-opaque);\n }\n\n &--large {\n margin-left: var(--dt-space-550-negative);\n }\n\n &__icon {\n color: var(--dt-color-black-800);\n }\n}\n\n.dt-recipe--callbar-button-with-popover--popover {\n .d-popover__header {\n background: var(--dt-color-surface-contrast);\n color: var(--dt-color-foreground-primary-inverted);\n\n .d-btn {\n color: var(--dt-color-foreground-primary-inverted);\n }\n }\n}\n\n.dt-recipe--callbar-button-with-popover--button .d-tab--selected::after,\n.dt-recipe--callbar-button-with-popover--button .d-tab--selected:hover::after {\n --tab--bgc: var(--dt-color-surface-contrast);\n}\n.dt-recipe--callbar-button-with-popover--button .tab-group {\n display: flex;\n flex-direction: column;\n height: 100%;\n}\n\n.dt-recipe--callbar-button-with-popover--button .tab-content {\n flex: 1 1 100%;\n overflow-y: auto;\n}\n\n.dt-recipe--callbar-button-with-popover {\n display: flex;\n align-items: center;\n}\n</style>\n"],"names":["this","_openBlock","_createElementBlock","_createVNode","_renderSlot","_createBlock","_mergeProps","_normalizeClass"],"mappings":";;;;;;;;;;;;;;;;;;AAiFA,MAAK,YAAU;AAAA,EACb,MAAM;AAAA,EAEN,YAAY,EAAE,uBAAuB,WAAW,UAAU,OAAQ;AAAA;AAAA;AAAA;AAAA;AAAA,EAMlE,cAAc;AAAA,EAEd,OAAO;AAAA;AAAA;AAAA;AAAA,IAIL,IAAI;AAAA,MACF,MAAM;AAAA,MACN,UAAW;AACT,eAAO,MAAM;MACd;AAAA,IACF;AAAA;AAAA;AAAA;AAAA,IAKD,WAAW;AAAA,MACT,MAAM;AAAA,MACN,SAAS;AAAA,MACT,WAAW,CAAC,UAAU;AACpB,eAAO,SAASA,SAAK,OAAO;AAAA,MAC7B;AAAA,IACF;AAAA;AAAA;AAAA;AAAA,IAKD,kBAAkB;AAAA,MAChB,MAAM;AAAA,MACN,UAAU;AAAA,MACV,WAAW,CAAC,UAAU;AACp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A,QAAvBC,WAAuB,KAAA,QAAA,SAAA;AAAA;MAEd,uBACT,MAA6B;AAAA,QAA7BA,WAA6B,KAAA,QAAA,eAAA;AAAA;MAEpB,uBACT,MAA6B;AAAA,QAA7BA,WAA6B,KAAA,QAAA,eAAA;AAAA;;;;;;"}
|
|
@@ -1,2 +1,201 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const common_utils = require("../common/utils.cjs");
|
|
4
|
+
const vue = require("vue");
|
|
5
|
+
const _pluginVue_exportHelper = require("../chunks/_plugin-vue_export-helper-fhnQq0tA.js");
|
|
6
|
+
const lib_button = require("./button.cjs");
|
|
7
|
+
const lib_tooltip = require("./tooltip.cjs");
|
|
8
|
+
require("../common/constants.cjs");
|
|
9
|
+
require("../chunks/link_constants-Huj7D_hm.js");
|
|
10
|
+
require("../chunks/popover_constants-JwBF9h1Z.js");
|
|
11
|
+
require("tippy.js");
|
|
12
|
+
require("./lazy-show.cjs");
|
|
13
|
+
const CALLBAR_BUTTON_VALID_WIDTH_SIZE = ["sm", "md", "lg", "xl"];
|
|
14
|
+
const _sfc_main = {
|
|
15
|
+
name: "DtRecipeCallbarButton",
|
|
16
|
+
components: { DtButton: lib_button.DtButton, DtTooltip: lib_tooltip.DtTooltip },
|
|
17
|
+
inheritAttrs: false,
|
|
18
|
+
props: {
|
|
19
|
+
/**
|
|
20
|
+
* Id for the item.
|
|
21
|
+
*/
|
|
22
|
+
id: {
|
|
23
|
+
type: String,
|
|
24
|
+
default() {
|
|
25
|
+
return common_utils.default.getUniqueString();
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
/**
|
|
29
|
+
* Determines whether the button should have active styling
|
|
30
|
+
* default is false.
|
|
31
|
+
* @values true, false
|
|
32
|
+
* @see https://dialtone.dialpad.com/components/button/
|
|
33
|
+
*/
|
|
34
|
+
active: {
|
|
35
|
+
type: Boolean,
|
|
36
|
+
default: false
|
|
37
|
+
},
|
|
38
|
+
/**
|
|
39
|
+
* Determines whether the button should have danger styling
|
|
40
|
+
* default is false.
|
|
41
|
+
* @values true, false
|
|
42
|
+
* @see https://dialtone.dialpad.com/components/button/
|
|
43
|
+
*/
|
|
44
|
+
danger: {
|
|
45
|
+
type: Boolean,
|
|
46
|
+
default: false
|
|
47
|
+
},
|
|
48
|
+
/**
|
|
49
|
+
* Determines whether the button should be disabled
|
|
50
|
+
* default is false.
|
|
51
|
+
* @values true, false
|
|
52
|
+
*/
|
|
53
|
+
disabled: {
|
|
54
|
+
type: Boolean,
|
|
55
|
+
default: false
|
|
56
|
+
},
|
|
57
|
+
/**
|
|
58
|
+
* Whether the button is a circle or not.
|
|
59
|
+
* @values true, false
|
|
60
|
+
* @see https://dialtone.dialpad.com/components/button/
|
|
61
|
+
*/
|
|
62
|
+
circle: {
|
|
63
|
+
type: Boolean,
|
|
64
|
+
default: false
|
|
65
|
+
},
|
|
66
|
+
/**
|
|
67
|
+
* Aria label for the button. If empty, it takes its value from the default slot.
|
|
68
|
+
*/
|
|
69
|
+
ariaLabel: {
|
|
70
|
+
type: String,
|
|
71
|
+
default: null,
|
|
72
|
+
validator: (label) => {
|
|
73
|
+
return label || (void 0).$slots.default;
|
|
74
|
+
}
|
|
75
|
+
},
|
|
76
|
+
/**
|
|
77
|
+
* Additional class name for the button wrapper element.
|
|
78
|
+
*/
|
|
79
|
+
buttonClass: {
|
|
80
|
+
type: [String, Array, Object],
|
|
81
|
+
default: ""
|
|
82
|
+
},
|
|
83
|
+
/**
|
|
84
|
+
* Additional class name for the button text.
|
|
85
|
+
*/
|
|
86
|
+
textClass: {
|
|
87
|
+
type: [String, Array, Object],
|
|
88
|
+
default: ""
|
|
89
|
+
},
|
|
90
|
+
/*
|
|
91
|
+
* Width size. Valid values are: 'xl', 'lg', 'md' and 'sm'.
|
|
92
|
+
*/
|
|
93
|
+
buttonWidthSize: {
|
|
94
|
+
type: String,
|
|
95
|
+
default: "xl",
|
|
96
|
+
validator: (size) => CALLBAR_BUTTON_VALID_WIDTH_SIZE.includes(size)
|
|
97
|
+
},
|
|
98
|
+
/**
|
|
99
|
+
* The fill and outline of the button associated with its visual importance.
|
|
100
|
+
* @values clear, outlined, primary
|
|
101
|
+
*/
|
|
102
|
+
importance: {
|
|
103
|
+
type: String,
|
|
104
|
+
default: ""
|
|
105
|
+
}
|
|
106
|
+
},
|
|
107
|
+
emits: [
|
|
108
|
+
/**
|
|
109
|
+
* Native click event
|
|
110
|
+
*
|
|
111
|
+
* @event click
|
|
112
|
+
* @type {PointerEvent | KeyboardEvent}
|
|
113
|
+
*/
|
|
114
|
+
"click"
|
|
115
|
+
],
|
|
116
|
+
computed: {
|
|
117
|
+
callbarButtonClass() {
|
|
118
|
+
return [
|
|
119
|
+
this.buttonClass,
|
|
120
|
+
"dt-recipe-callbar-button",
|
|
121
|
+
"d-px0",
|
|
122
|
+
{
|
|
123
|
+
"dt-recipe-callbar-button--circle": this.circle,
|
|
124
|
+
"dt-recipe-callbar-button--active": this.active,
|
|
125
|
+
"dt-recipe-callbar-button--danger": this.danger,
|
|
126
|
+
"d-btn--disabled d-bgc-transparent": this.disabled,
|
|
127
|
+
"d-fc-primary": !this.disabled
|
|
128
|
+
}
|
|
129
|
+
];
|
|
130
|
+
},
|
|
131
|
+
callbarButtonTextClass() {
|
|
132
|
+
return [
|
|
133
|
+
"d-fs-100 lg:d-d-none md:d-d-none sm:d-d-none",
|
|
134
|
+
this.textClass
|
|
135
|
+
];
|
|
136
|
+
},
|
|
137
|
+
buttonWidth() {
|
|
138
|
+
switch (this.buttonWidthSize) {
|
|
139
|
+
case "sm":
|
|
140
|
+
return "4.5rem";
|
|
141
|
+
case "md":
|
|
142
|
+
return "6rem";
|
|
143
|
+
default:
|
|
144
|
+
return "8.4rem";
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
buttonImportance() {
|
|
148
|
+
if (this.importance) {
|
|
149
|
+
return this.importance;
|
|
150
|
+
}
|
|
151
|
+
return this.circle ? "outlined" : "clear";
|
|
152
|
+
},
|
|
153
|
+
callbarButtonListeners() {
|
|
154
|
+
return {
|
|
155
|
+
...common_utils.extractVueListeners(this.$attrs),
|
|
156
|
+
click: (event) => this.$emit("click", event)
|
|
157
|
+
};
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
};
|
|
161
|
+
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
162
|
+
const _component_dt_button = vue.resolveComponent("dt-button");
|
|
163
|
+
const _component_dt_tooltip = vue.resolveComponent("dt-tooltip");
|
|
164
|
+
return vue.openBlock(), vue.createBlock(_component_dt_tooltip, {
|
|
165
|
+
id: $props.id,
|
|
166
|
+
offset: [0, 8]
|
|
167
|
+
}, {
|
|
168
|
+
anchor: vue.withCtx(() => [
|
|
169
|
+
vue.createElementVNode("span", {
|
|
170
|
+
class: vue.normalizeClass({ "dt-recipe-callbar-button--disabled": $props.disabled })
|
|
171
|
+
}, [
|
|
172
|
+
vue.createVNode(_component_dt_button, vue.mergeProps({
|
|
173
|
+
importance: $options.buttonImportance,
|
|
174
|
+
kind: "muted",
|
|
175
|
+
"icon-position": "top",
|
|
176
|
+
"aria-disabled": $props.disabled,
|
|
177
|
+
"aria-label": $props.ariaLabel,
|
|
178
|
+
"label-class": $options.callbarButtonTextClass,
|
|
179
|
+
width: $options.buttonWidth,
|
|
180
|
+
class: $options.callbarButtonClass
|
|
181
|
+
}, _ctx.$attrs, vue.toHandlers($options.callbarButtonListeners)), {
|
|
182
|
+
icon: vue.withCtx(() => [
|
|
183
|
+
vue.renderSlot(_ctx.$slots, "icon")
|
|
184
|
+
]),
|
|
185
|
+
default: vue.withCtx(() => [
|
|
186
|
+
vue.renderSlot(_ctx.$slots, "default")
|
|
187
|
+
]),
|
|
188
|
+
_: 3
|
|
189
|
+
}, 16, ["importance", "aria-disabled", "aria-label", "label-class", "width", "class"])
|
|
190
|
+
], 2)
|
|
191
|
+
]),
|
|
192
|
+
default: vue.withCtx(() => [
|
|
193
|
+
vue.renderSlot(_ctx.$slots, "tooltip")
|
|
194
|
+
]),
|
|
195
|
+
_: 3
|
|
196
|
+
}, 8, ["id"]);
|
|
197
|
+
}
|
|
198
|
+
const DtRecipeCallbarButton = /* @__PURE__ */ _pluginVue_exportHelper._export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
199
|
+
exports.CALLBAR_BUTTON_VALID_WIDTH_SIZE = CALLBAR_BUTTON_VALID_WIDTH_SIZE;
|
|
200
|
+
exports.DtRecipeCallbarButton = DtRecipeCallbarButton;
|
|
2
201
|
//# sourceMappingURL=callbar-button.cjs.map
|