@dialpad/dialtone 9.103.0 → 9.104.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/dist/css/dialtone-default-theme.css +41 -0
  2. package/dist/css/dialtone-default-theme.min.css +1 -1
  3. package/dist/css/dialtone.css +41 -0
  4. package/dist/css/dialtone.min.css +1 -1
  5. package/dist/tokens/doc.json +17174 -17174
  6. package/dist/vue2/component-documentation.json +1 -1
  7. package/dist/vue2/dialtone-vue.cjs +2 -0
  8. package/dist/vue2/dialtone-vue.cjs.map +1 -1
  9. package/dist/vue2/dialtone-vue.js +42 -40
  10. package/dist/vue2/dialtone-vue.js.map +1 -1
  11. package/dist/vue2/lib/callbar-button-with-dropdown.cjs +5 -0
  12. package/dist/vue2/lib/callbar-button-with-dropdown.cjs.map +1 -0
  13. package/dist/vue2/lib/callbar-button-with-dropdown.js +5 -0
  14. package/dist/vue2/lib/callbar-button-with-dropdown.js.map +1 -0
  15. package/dist/vue2/recipes/buttons/callbar_button/callbar_button.vue.cjs +9 -1
  16. package/dist/vue2/recipes/buttons/callbar_button/callbar_button.vue.cjs.map +1 -1
  17. package/dist/vue2/recipes/buttons/callbar_button/callbar_button.vue.js +9 -1
  18. package/dist/vue2/recipes/buttons/callbar_button/callbar_button.vue.js.map +1 -1
  19. package/dist/vue2/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.cjs +258 -0
  20. package/dist/vue2/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.cjs.map +1 -0
  21. package/dist/vue2/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.js +258 -0
  22. package/dist/vue2/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.js.map +1 -0
  23. package/dist/vue2/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.cjs +9 -1
  24. package/dist/vue2/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.cjs.map +1 -1
  25. package/dist/vue2/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.js +9 -1
  26. package/dist/vue2/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.js.map +1 -1
  27. package/dist/vue2/types/index.d.ts +1 -0
  28. package/dist/vue2/types/recipes/buttons/callbar_button/callbar_button.vue.d.ts +9 -0
  29. package/dist/vue2/types/recipes/buttons/callbar_button/callbar_button.vue.d.ts.map +1 -1
  30. package/dist/vue2/types/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.d.ts +167 -0
  31. package/dist/vue2/types/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.d.ts.map +1 -0
  32. package/dist/vue2/types/recipes/buttons/callbar_button_with_dropdown/index.d.ts +2 -0
  33. package/dist/vue2/types/recipes/buttons/callbar_button_with_dropdown/index.d.ts.map +1 -0
  34. package/dist/vue2/types/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.d.ts +9 -0
  35. package/dist/vue2/types/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.d.ts.map +1 -1
  36. package/dist/vue3/component-documentation.json +1 -1
  37. package/dist/vue3/dialtone-vue.cjs +2 -0
  38. package/dist/vue3/dialtone-vue.cjs.map +1 -1
  39. package/dist/vue3/dialtone-vue.js +42 -40
  40. package/dist/vue3/dialtone-vue.js.map +1 -1
  41. package/dist/vue3/lib/callbar-button-with-dropdown.cjs +5 -0
  42. package/dist/vue3/lib/callbar-button-with-dropdown.cjs.map +1 -0
  43. package/dist/vue3/lib/callbar-button-with-dropdown.js +5 -0
  44. package/dist/vue3/lib/callbar-button-with-dropdown.js.map +1 -0
  45. package/dist/vue3/recipes/buttons/callbar_button/callbar_button.vue.cjs +10 -1
  46. package/dist/vue3/recipes/buttons/callbar_button/callbar_button.vue.cjs.map +1 -1
  47. package/dist/vue3/recipes/buttons/callbar_button/callbar_button.vue.js +10 -1
  48. package/dist/vue3/recipes/buttons/callbar_button/callbar_button.vue.js.map +1 -1
  49. package/dist/vue3/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.cjs +321 -0
  50. package/dist/vue3/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.cjs.map +1 -0
  51. package/dist/vue3/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.js +321 -0
  52. package/dist/vue3/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.js.map +1 -0
  53. package/dist/vue3/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.cjs +10 -1
  54. package/dist/vue3/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.cjs.map +1 -1
  55. package/dist/vue3/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.js +10 -1
  56. package/dist/vue3/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.js.map +1 -1
  57. package/dist/vue3/types/index.d.ts +1 -0
  58. package/dist/vue3/types/recipes/buttons/callbar_button/callbar_button.vue.d.ts +9 -0
  59. package/dist/vue3/types/recipes/buttons/callbar_button/callbar_button.vue.d.ts.map +1 -1
  60. package/dist/vue3/types/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.d.ts +180 -0
  61. package/dist/vue3/types/recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.d.ts.map +1 -0
  62. package/dist/vue3/types/recipes/buttons/callbar_button_with_dropdown/index.d.ts +2 -0
  63. package/dist/vue3/types/recipes/buttons/callbar_button_with_dropdown/index.d.ts.map +1 -0
  64. package/dist/vue3/types/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.d.ts +9 -0
  65. package/dist/vue3/types/recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.d.ts.map +1 -1
  66. package/package.json +3 -3
@@ -107,6 +107,7 @@ const scrollbar = require("./directives/scrollbar/scrollbar.cjs");
107
107
  const callbar_button = require("./recipes/buttons/callbar_button/callbar_button.vue.cjs");
108
108
  const callbar_button_constants = require("./recipes/buttons/callbar_button/callbar_button_constants.cjs");
109
109
  const callbar_button_with_popover = require("./recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.cjs");
110
+ const callbar_button_with_dropdown = require("./recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.cjs");
110
111
  const ivr_node = require("./recipes/cards/ivr_node/ivr_node.vue.cjs");
111
112
  const ivr_node_constants = require("./recipes/cards/ivr_node/ivr_node_constants.cjs");
112
113
  const grouped_chip = require("./recipes/chips/grouped_chip/grouped_chip.vue.cjs");
@@ -351,6 +352,7 @@ exports.DtScrollbarDirective = scrollbar.default;
351
352
  exports.DtRecipeCallbarButton = callbar_button.default;
352
353
  exports.CALLBAR_BUTTON_VALID_WIDTH_SIZE = callbar_button_constants.CALLBAR_BUTTON_VALID_WIDTH_SIZE;
353
354
  exports.DtRecipeCallbarButtonWithPopover = callbar_button_with_popover.default;
355
+ exports.DtRecipeCallbarButtonWithDropdown = callbar_button_with_dropdown.default;
354
356
  exports.DtRecipeIvrNode = ivr_node.default;
355
357
  exports.IVR_NODE_ASSIGN = ivr_node_constants.IVR_NODE_ASSIGN;
356
358
  exports.IVR_NODE_BRANCH = ivr_node_constants.IVR_NODE_BRANCH;
@@ -1 +1 @@
1
- {"version":3,"file":"dialtone-vue.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"dialtone-vue.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -105,34 +105,35 @@ import { default as default65 } from "./directives/scrollbar/scrollbar.js";
105
105
  import { default as default66 } from "./recipes/buttons/callbar_button/callbar_button.vue.js";
106
106
  import { CALLBAR_BUTTON_VALID_WIDTH_SIZE } from "./recipes/buttons/callbar_button/callbar_button_constants.js";
107
107
  import { default as default67 } from "./recipes/buttons/callbar_button_with_popover/callbar_button_with_popover.vue.js";
108
- import { default as default68 } from "./recipes/cards/ivr_node/ivr_node.vue.js";
108
+ import { default as default68 } from "./recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.js";
109
+ import { default as default69 } from "./recipes/cards/ivr_node/ivr_node.vue.js";
109
110
  import { IVR_NODE_ASSIGN, IVR_NODE_BRANCH, IVR_NODE_CUSTOMER_DATA, IVR_NODE_EXPERT, IVR_NODE_GO_TO, IVR_NODE_HANGUP, IVR_NODE_ICON_TYPES, IVR_NODE_LABELS, IVR_NODE_PROMPT_COLLECT, IVR_NODE_PROMPT_MENU, IVR_NODE_PROMPT_PLAY, IVR_NODE_TRANSFER } from "./recipes/cards/ivr_node/ivr_node_constants.js";
110
- import { default as default69 } from "./recipes/chips/grouped_chip/grouped_chip.vue.js";
111
- import { default as default70 } from "./recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue.js";
111
+ import { default as default70 } from "./recipes/chips/grouped_chip/grouped_chip.vue.js";
112
+ import { default as default71 } from "./recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue.js";
112
113
  import { CHIP_SIZES, CHIP_TOP_POSITION, MULTI_SELECT_SIZES } from "./recipes/comboboxes/combobox_multi_select/combobox_multi_select_constants.js";
113
- import { default as default71 } from "./recipes/comboboxes/combobox_with_popover/combobox_with_popover.vue.js";
114
- import { default as default72 } from "./recipes/conversation_view/attachment_carousel/attachment_carousel.vue.js";
115
- import { default as default73 } from "./recipes/conversation_view/editor/editor.vue.js";
116
- import { default as default74 } from "./recipes/conversation_view/emoji_row/emoji_row.vue.js";
114
+ import { default as default72 } from "./recipes/comboboxes/combobox_with_popover/combobox_with_popover.vue.js";
115
+ import { default as default73 } from "./recipes/conversation_view/attachment_carousel/attachment_carousel.vue.js";
116
+ import { default as default74 } from "./recipes/conversation_view/editor/editor.vue.js";
117
+ import { default as default75 } from "./recipes/conversation_view/emoji_row/emoji_row.vue.js";
117
118
  import { REACTIONS_ATTRIBUTES } from "./recipes/conversation_view/emoji_row/emoji_row_constants.js";
118
- import { default as default75 } from "./recipes/conversation_view/feed_item_pill/feed_item_pill.vue.js";
119
+ import { default as default76 } from "./recipes/conversation_view/feed_item_pill/feed_item_pill.vue.js";
119
120
  import { FEED_ITEM_PILL_BORDER_COLORS } from "./recipes/conversation_view/feed_item_pill/feed_item_pill_constants.js";
120
- import { default as default76 } from "./recipes/conversation_view/feed_item_row/feed_item_row.vue.js";
121
+ import { default as default77 } from "./recipes/conversation_view/feed_item_row/feed_item_row.vue.js";
121
122
  import { DEFAULT_FEED_ROW_STATE, FEED_ROW_STATE_BACKGROUND_COLOR } from "./recipes/conversation_view/feed_item_row/feed_item_row_constants.js";
122
- import { default as default77 } from "./recipes/conversation_view/message_input/message_input.vue.js";
123
- import { default as default78 } from "./recipes/conversation_view/time_pill/time_pill.vue.js";
124
- import { default as default79 } from "./recipes/header/settings_menu_button/settings_menu_button.vue.js";
125
- import { default as default80 } from "./recipes/item_layout/contact_info/contact_info.vue.js";
126
- import { default as default81 } from "./recipes/leftbar/callbox/callbox.vue.js";
123
+ import { default as default78 } from "./recipes/conversation_view/message_input/message_input.vue.js";
124
+ import { default as default79 } from "./recipes/conversation_view/time_pill/time_pill.vue.js";
125
+ import { default as default80 } from "./recipes/header/settings_menu_button/settings_menu_button.vue.js";
126
+ import { default as default81 } from "./recipes/item_layout/contact_info/contact_info.vue.js";
127
+ import { default as default82 } from "./recipes/leftbar/callbox/callbox.vue.js";
127
128
  import { CALLBOX_BADGE_COLORS, CALLBOX_BORDER_COLORS } from "./recipes/leftbar/callbox/callbox_constants.js";
128
- import { default as default82 } from "./recipes/leftbar/contact_centers_row/contact_centers_row.vue.js";
129
- import { default as default83 } from "./recipes/leftbar/contact_row/contact_row.vue.js";
130
- import { default as default84 } from "./recipes/leftbar/general_row/general_row.vue.js";
129
+ import { default as default83 } from "./recipes/leftbar/contact_centers_row/contact_centers_row.vue.js";
130
+ import { default as default84 } from "./recipes/leftbar/contact_row/contact_row.vue.js";
131
+ import { default as default85 } from "./recipes/leftbar/general_row/general_row.vue.js";
131
132
  import { LEFTBAR_GENERAL_ROW_CONTACT_CENTER_COLORS, LEFTBAR_GENERAL_ROW_CONTACT_CENTER_VALIDATION_ERROR, LEFTBAR_GENERAL_ROW_ICON_SIZES, LEFTBAR_GENERAL_ROW_TYPES } from "./recipes/leftbar/general_row/general_row_constants.js";
132
- import { default as default85 } from "./recipes/leftbar/group_row/group_row.vue.js";
133
- import { default as default86 } from "./recipes/leftbar/unread_pill/unread_pill.vue.js";
133
+ import { default as default86 } from "./recipes/leftbar/group_row/group_row.vue.js";
134
+ import { default as default87 } from "./recipes/leftbar/unread_pill/unread_pill.vue.js";
134
135
  import { UNREAD_PILL_DIRECTIONS, UNREAD_PILL_KINDS } from "./recipes/leftbar/unread_pill/unread_pill_constants.js";
135
- import { default as default87 } from "./recipes/notices/top_banner_info/top_banner_info.vue.js";
136
+ import { default as default88 } from "./recipes/notices/top_banner_info/top_banner_info.vue.js";
136
137
  import { COLOR_CODES } from "./recipes/notices/top_banner_info/top_banner_info_constants.js";
137
138
  export {
138
139
  AVATAR_COLORS,
@@ -221,28 +222,29 @@ export {
221
222
  default44 as DtPresence,
222
223
  default45 as DtRadio,
223
224
  default46 as DtRadioGroup,
224
- default72 as DtRecipeAttachmentCarousel,
225
+ default73 as DtRecipeAttachmentCarousel,
225
226
  default66 as DtRecipeCallbarButton,
227
+ default68 as DtRecipeCallbarButtonWithDropdown,
226
228
  default67 as DtRecipeCallbarButtonWithPopover,
227
- default81 as DtRecipeCallbox,
228
- default70 as DtRecipeComboboxMultiSelect,
229
- default71 as DtRecipeComboboxWithPopover,
230
- default82 as DtRecipeContactCentersRow,
231
- default80 as DtRecipeContactInfo,
232
- default83 as DtRecipeContactRow,
233
- default73 as DtRecipeEditor,
234
- default74 as DtRecipeEmojiRow,
235
- default75 as DtRecipeFeedItemPill,
236
- default76 as DtRecipeFeedItemRow,
237
- default84 as DtRecipeGeneralRow,
238
- default85 as DtRecipeGroupRow,
239
- default69 as DtRecipeGroupedChip,
240
- default68 as DtRecipeIvrNode,
241
- default77 as DtRecipeMessageInput,
242
- default79 as DtRecipeSettingsMenuButton,
243
- default78 as DtRecipeTimePill,
244
- default87 as DtRecipeTopBannerInfo,
245
- default86 as DtRecipeUnreadPill,
229
+ default82 as DtRecipeCallbox,
230
+ default71 as DtRecipeComboboxMultiSelect,
231
+ default72 as DtRecipeComboboxWithPopover,
232
+ default83 as DtRecipeContactCentersRow,
233
+ default81 as DtRecipeContactInfo,
234
+ default84 as DtRecipeContactRow,
235
+ default74 as DtRecipeEditor,
236
+ default75 as DtRecipeEmojiRow,
237
+ default76 as DtRecipeFeedItemPill,
238
+ default77 as DtRecipeFeedItemRow,
239
+ default85 as DtRecipeGeneralRow,
240
+ default86 as DtRecipeGroupRow,
241
+ default70 as DtRecipeGroupedChip,
242
+ default69 as DtRecipeIvrNode,
243
+ default78 as DtRecipeMessageInput,
244
+ default80 as DtRecipeSettingsMenuButton,
245
+ default79 as DtRecipeTimePill,
246
+ default88 as DtRecipeTopBannerInfo,
247
+ default87 as DtRecipeUnreadPill,
246
248
  default47 as DtRichTextEditor,
247
249
  default48 as DtRootLayout,
248
250
  default65 as DtScrollbarDirective,
@@ -1 +1 @@
1
- {"version":3,"file":"dialtone-vue.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"dialtone-vue.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const callbar_button_with_dropdown = require("../recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.cjs");
4
+ exports.DtRecipeCallbarButtonWithDropdown = callbar_button_with_dropdown.default;
5
+ //# sourceMappingURL=callbar-button-with-dropdown.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"callbar-button-with-dropdown.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
@@ -0,0 +1,5 @@
1
+ import { default as default2 } from "../recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue.js";
2
+ export {
3
+ default2 as DtRecipeCallbarButtonWithDropdown
4
+ };
5
+ //# sourceMappingURL=callbar-button-with-dropdown.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"callbar-button-with-dropdown.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -120,6 +120,14 @@ const _sfc_main = {
120
120
  tooltipText: {
121
121
  type: String,
122
122
  default: void 0
123
+ },
124
+ /**
125
+ * Whether there is a delay before the tooltip shows on hover/focus.
126
+ * @values true, false
127
+ */
128
+ tooltipDelay: {
129
+ type: Boolean,
130
+ default: void 0
123
131
  }
124
132
  },
125
133
  emits: [
@@ -176,7 +184,7 @@ const _sfc_main = {
176
184
  };
177
185
  var _sfc_render = function render() {
178
186
  var _vm = this, _c = _vm._self._c;
179
- return _c("dt-tooltip", { attrs: { "id": _vm.id, "inverted": _vm.invertedTooltip, "show": _vm.showTooltip, "offset": [0, 24] }, scopedSlots: _vm._u([{ key: "anchor", fn: function() {
187
+ return _c("dt-tooltip", { attrs: { "id": _vm.id, "inverted": _vm.invertedTooltip, "delay": _vm.tooltipDelay, "show": _vm.showTooltip, "offset": [0, 24] }, scopedSlots: _vm._u([{ key: "anchor", fn: function() {
180
188
  return [_c("span", { class: { "d-recipe-callbar-button--disabled": _vm.disabled } }, [_c("dt-button", _vm._g(_vm._b({ class: _vm.callbarButtonClass, attrs: { "importance": _vm.buttonImportance, "kind": "muted", "icon-position": "top", "aria-disabled": _vm.disabled, "aria-label": _vm.ariaLabel, "label-class": _vm.callbarButtonTextClass, "width": _vm.buttonWidth }, scopedSlots: _vm._u([{ key: "icon", fn: function() {
181
189
  return [_vm._t("icon")];
182
190
  }, proxy: true }], null, true) }, "dt-button", _vm.$attrs, false), _vm.callbarButtonListeners), [_vm._t("default")], 2)], 1)];
@@ -1 +1 @@
1
- {"version":3,"file":"callbar_button.vue.cjs","sources":["../../../../recipes/buttons/callbar_button/callbar_button.vue"],"sourcesContent":["<template>\n <dt-tooltip\n :id=\"id\"\n :inverted=\"invertedTooltip\"\n :show=\"showTooltip\"\n :offset=\"[0, 24]\"\n >\n <template #anchor>\n <span\n :class=\"{ 'd-recipe-callbar-button--disabled': disabled }\"\n >\n <dt-button\n :importance=\"buttonImportance\"\n kind=\"muted\"\n icon-position=\"top\"\n :aria-disabled=\"disabled\"\n :aria-label=\"ariaLabel\"\n :label-class=\"callbarButtonTextClass\"\n :width=\"buttonWidth\"\n :class=\"callbarButtonClass\"\n v-bind=\"$attrs\"\n v-on=\"callbarButtonListeners\"\n >\n <slot />\n <template #icon>\n <slot name=\"icon\" />\n </template>\n </dt-button>\n </span>\n </template>\n <slot name=\"tooltip\">\n {{ tooltipText }}\n </slot>\n </dt-tooltip>\n</template>\n\n<script>\nimport { CALLBAR_BUTTON_VALID_WIDTH_SIZE } from './callbar_button_constants';\nimport { DtButton } from '@/components/button';\nimport { DtTooltip } from '@/components/tooltip';\nimport utils from '@/common/utils';\n\nexport default {\n name: 'DtRecipeCallbarButton',\n\n components: { DtButton, DtTooltip },\n\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 * 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 * 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 * Whether the button is a circle or not.\n * @values true, false\n * @see https://dialtone.dialpad.com/components/button/\n */\n circle: {\n type: Boolean,\n default: false,\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 * 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 * The fill and outline of the button associated with its visual importance.\n * @values clear, outlined, primary\n */\n importance: {\n type: String,\n default: '',\n },\n\n /**\n * Whether the tooltip has an inverted background color.\n * @values true, false\n */\n invertedTooltip: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Use this if you would like to manually override the logic for when the tooltip shows.\n * Otherwise it will just show on hover/focus.\n * @values null, true, false\n */\n showTooltip: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The message that displays in the tooltip. This will be overridden by the tooltip slot.\n */\n tooltipText: {\n type: String,\n default: undefined,\n },\n\n },\n\n emits: [\n /**\n * Native click event\n *\n * @event click\n * @type {PointerEvent | KeyboardEvent}\n */\n 'click',\n ],\n\n computed: {\n callbarButtonClass () {\n return [\n this.buttonClass,\n 'd-recipe-callbar-button',\n {\n 'd-recipe-callbar-button--circle': this.circle,\n 'd-recipe-callbar-button--active': this.active,\n 'd-recipe-callbar-button--danger': this.danger,\n 'd-btn--disabled': this.disabled,\n }];\n },\n\n callbarButtonTextClass () {\n return [\n 'd-recipe-callbar-button__text',\n this.textClass,\n ];\n },\n\n buttonWidth () {\n switch (this.buttonWidthSize) {\n case 'sm':\n return '4.5rem';\n case 'md':\n return '6rem';\n default:\n return '8.4rem';\n }\n },\n\n buttonImportance () {\n if (this.importance) {\n return this.importance;\n }\n return this.circle ? 'outlined' : 'clear';\n },\n\n callbarButtonListeners () {\n return {\n ...this.$listeners,\n click: (event) => this.$emit('click', event),\n };\n },\n },\n};\n</script>\n"],"names":["Dt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A;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,iBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,aAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,aAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA,EAEA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA;AAAA,EACA;AAAA,EAEA,UAAA;AAAA,IACA,qBAAA;AACA,aAAA;AAAA,QACA,KAAA;AAAA,QACA;AAAA,QACA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mBAAA,KAAA;AAAA,QACA;AAAA,MAAA;AAAA,IACA;AAAA,IAEA,yBAAA;AACA,aAAA;AAAA,QACA;AAAA,QACA,KAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,cAAA;AACA,cAAA,KAAA,iBAAA;AAAA,QACA,KAAA;AACA,iBAAA;AAAA,QACA,KAAA;AACA,iBAAA;AAAA,QACA;AACA,iBAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,mBAAA;AACA,UAAA,KAAA,YAAA;AACA,eAAA,KAAA;AAAA,MACA;AACA,aAAA,KAAA,SAAA,aAAA;AAAA,IACA;AAAA,IAEA,yBAAA;AACA,aAAA;AAAA,QACA,GAAA,KAAA;AAAA,QACA,OAAA,CAAA,UAAA,KAAA,MAAA,SAAA,KAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"callbar_button.vue.cjs","sources":["../../../../recipes/buttons/callbar_button/callbar_button.vue"],"sourcesContent":["<template>\n <dt-tooltip\n :id=\"id\"\n :inverted=\"invertedTooltip\"\n :delay=\"tooltipDelay\"\n :show=\"showTooltip\"\n :offset=\"[0, 24]\"\n >\n <template #anchor>\n <span\n :class=\"{ 'd-recipe-callbar-button--disabled': disabled }\"\n >\n <dt-button\n :importance=\"buttonImportance\"\n kind=\"muted\"\n icon-position=\"top\"\n :aria-disabled=\"disabled\"\n :aria-label=\"ariaLabel\"\n :label-class=\"callbarButtonTextClass\"\n :width=\"buttonWidth\"\n :class=\"callbarButtonClass\"\n v-bind=\"$attrs\"\n v-on=\"callbarButtonListeners\"\n >\n <slot />\n <template #icon>\n <slot name=\"icon\" />\n </template>\n </dt-button>\n </span>\n </template>\n <slot name=\"tooltip\">\n {{ tooltipText }}\n </slot>\n </dt-tooltip>\n</template>\n\n<script>\nimport { CALLBAR_BUTTON_VALID_WIDTH_SIZE } from './callbar_button_constants';\nimport { DtButton } from '@/components/button';\nimport { DtTooltip } from '@/components/tooltip';\nimport utils from '@/common/utils';\n\nexport default {\n name: 'DtRecipeCallbarButton',\n\n components: { DtButton, DtTooltip },\n\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 * 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 * 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 * Whether the button is a circle or not.\n * @values true, false\n * @see https://dialtone.dialpad.com/components/button/\n */\n circle: {\n type: Boolean,\n default: false,\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 * 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 * The fill and outline of the button associated with its visual importance.\n * @values clear, outlined, primary\n */\n importance: {\n type: String,\n default: '',\n },\n\n /**\n * Whether the tooltip has an inverted background color.\n * @values true, false\n */\n invertedTooltip: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Use this if you would like to manually override the logic for when the tooltip shows.\n * Otherwise it will just show on hover/focus.\n * @values null, true, false\n */\n showTooltip: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The message that displays in the tooltip. This will be overridden by the tooltip slot.\n */\n tooltipText: {\n type: String,\n default: undefined,\n },\n\n /**\n * Whether there is a delay before the tooltip shows on hover/focus.\n * @values true, false\n */\n tooltipDelay: {\n type: Boolean,\n default: undefined,\n },\n },\n\n emits: [\n /**\n * Native click event\n *\n * @event click\n * @type {PointerEvent | KeyboardEvent}\n */\n 'click',\n ],\n\n computed: {\n callbarButtonClass () {\n return [\n this.buttonClass,\n 'd-recipe-callbar-button',\n {\n 'd-recipe-callbar-button--circle': this.circle,\n 'd-recipe-callbar-button--active': this.active,\n 'd-recipe-callbar-button--danger': this.danger,\n 'd-btn--disabled': this.disabled,\n }];\n },\n\n callbarButtonTextClass () {\n return [\n 'd-recipe-callbar-button__text',\n this.textClass,\n ];\n },\n\n buttonWidth () {\n switch (this.buttonWidthSize) {\n case 'sm':\n return '4.5rem';\n case 'md':\n return '6rem';\n default:\n return '8.4rem';\n }\n },\n\n buttonImportance () {\n if (this.importance) {\n return this.importance;\n }\n return this.circle ? 'outlined' : 'clear';\n },\n\n callbarButtonListeners () {\n return {\n ...this.$listeners,\n click: (event) => this.$emit('click', event),\n };\n },\n },\n};\n</script>\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ooltipText: {
119
119
  type: String,
120
120
  default: void 0
121
+ },
122
+ /**
123
+ * Whether there is a delay before the tooltip shows on hover/focus.
124
+ * @values true, false
125
+ */
126
+ tooltipDelay: {
127
+ type: Boolean,
128
+ default: void 0
121
129
  }
122
130
  },
123
131
  emits: [
@@ -174,7 +182,7 @@ const _sfc_main = {
174
182
  };
175
183
  var _sfc_render = function render() {
176
184
  var _vm = this, _c = _vm._self._c;
177
- return _c("dt-tooltip", { attrs: { "id": _vm.id, "inverted": _vm.invertedTooltip, "show": _vm.showTooltip, "offset": [0, 24] }, scopedSlots: _vm._u([{ key: "anchor", fn: function() {
185
+ return _c("dt-tooltip", { attrs: { "id": _vm.id, "inverted": _vm.invertedTooltip, "delay": _vm.tooltipDelay, "show": _vm.showTooltip, "offset": [0, 24] }, scopedSlots: _vm._u([{ key: "anchor", fn: function() {
178
186
  return [_c("span", { class: { "d-recipe-callbar-button--disabled": _vm.disabled } }, [_c("dt-button", _vm._g(_vm._b({ class: _vm.callbarButtonClass, attrs: { "importance": _vm.buttonImportance, "kind": "muted", "icon-position": "top", "aria-disabled": _vm.disabled, "aria-label": _vm.ariaLabel, "label-class": _vm.callbarButtonTextClass, "width": _vm.buttonWidth }, scopedSlots: _vm._u([{ key: "icon", fn: function() {
179
187
  return [_vm._t("icon")];
180
188
  }, proxy: true }], null, true) }, "dt-button", _vm.$attrs, false), _vm.callbarButtonListeners), [_vm._t("default")], 2)], 1)];
@@ -1 +1 @@
1
- {"version":3,"file":"callbar_button.vue.js","sources":["../../../../recipes/buttons/callbar_button/callbar_button.vue"],"sourcesContent":["<template>\n <dt-tooltip\n :id=\"id\"\n :inverted=\"invertedTooltip\"\n :show=\"showTooltip\"\n :offset=\"[0, 24]\"\n >\n <template #anchor>\n <span\n :class=\"{ 'd-recipe-callbar-button--disabled': disabled }\"\n >\n <dt-button\n :importance=\"buttonImportance\"\n kind=\"muted\"\n icon-position=\"top\"\n :aria-disabled=\"disabled\"\n :aria-label=\"ariaLabel\"\n :label-class=\"callbarButtonTextClass\"\n :width=\"buttonWidth\"\n :class=\"callbarButtonClass\"\n v-bind=\"$attrs\"\n v-on=\"callbarButtonListeners\"\n >\n <slot />\n <template #icon>\n <slot name=\"icon\" />\n </template>\n </dt-button>\n </span>\n </template>\n <slot name=\"tooltip\">\n {{ tooltipText }}\n </slot>\n </dt-tooltip>\n</template>\n\n<script>\nimport { CALLBAR_BUTTON_VALID_WIDTH_SIZE } from './callbar_button_constants';\nimport { DtButton } from '@/components/button';\nimport { DtTooltip } from '@/components/tooltip';\nimport utils from '@/common/utils';\n\nexport default {\n name: 'DtRecipeCallbarButton',\n\n components: { DtButton, DtTooltip },\n\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 * 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 * 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 * Whether the button is a circle or not.\n * @values true, false\n * @see https://dialtone.dialpad.com/components/button/\n */\n circle: {\n type: Boolean,\n default: false,\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 * 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 * The fill and outline of the button associated with its visual importance.\n * @values clear, outlined, primary\n */\n importance: {\n type: String,\n default: '',\n },\n\n /**\n * Whether the tooltip has an inverted background color.\n * @values true, false\n */\n invertedTooltip: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Use this if you would like to manually override the logic for when the tooltip shows.\n * Otherwise it will just show on hover/focus.\n * @values null, true, false\n */\n showTooltip: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The message that displays in the tooltip. This will be overridden by the tooltip slot.\n */\n tooltipText: {\n type: String,\n default: undefined,\n },\n\n },\n\n emits: [\n /**\n * Native click event\n *\n * @event click\n * @type {PointerEvent | KeyboardEvent}\n */\n 'click',\n ],\n\n computed: {\n callbarButtonClass () {\n return [\n this.buttonClass,\n 'd-recipe-callbar-button',\n {\n 'd-recipe-callbar-button--circle': this.circle,\n 'd-recipe-callbar-button--active': this.active,\n 'd-recipe-callbar-button--danger': this.danger,\n 'd-btn--disabled': this.disabled,\n }];\n },\n\n callbarButtonTextClass () {\n return [\n 'd-recipe-callbar-button__text',\n this.textClass,\n ];\n },\n\n buttonWidth () {\n switch (this.buttonWidthSize) {\n case 'sm':\n return '4.5rem';\n case 'md':\n return '6rem';\n default:\n return '8.4rem';\n }\n },\n\n buttonImportance () {\n if (this.importance) {\n return this.importance;\n }\n return this.circle ? 'outlined' : 'clear';\n },\n\n callbarButtonListeners () {\n return {\n ...this.$listeners,\n click: (event) => this.$emit('click', event),\n };\n },\n },\n};\n</script>\n"],"names":["this"],"mappings":";;;;;AA0CA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA,EAAA,UAAA,UAAA;AAAA,EAEA,cAAA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA,IAIA,IAAA;AAAA,MACA,MAAA;AAAA,MACA,UAAA;AACA,eAAA,MAAA;MACA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAQA,QAAA;AAAA,MACA,M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EACA;AAAA,EAEA,UAAA;AAAA,IACA,qBAAA;AACA,aAAA;AAAA,QACA,KAAA;AAAA,QACA;AAAA,QACA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mBAAA,KAAA;AAAA,QACA;AAAA,MAAA;AAAA,IACA;AAAA,IAEA,yBAAA;AACA,aAAA;AAAA,QACA;AAAA,QACA,KAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,cAAA;AACA,cAAA,KAAA,iBAAA;AAAA,QACA,KAAA;AACA,iBAAA;AAAA,QACA,KAAA;AACA,iBAAA;AAAA,QACA;AACA,iBAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,mBAAA;AACA,UAAA,KAAA,YAAA;AACA,eAAA,KAAA;AAAA,MACA;AACA,aAAA,KAAA,SAAA,aAAA;AAAA,IACA;AAAA,IAEA,yBAAA;AACA,aAAA;AAAA,QACA,GAAA,KAAA;AAAA,QACA,OAAA,CAAA,UAAA,KAAA,MAAA,SAAA,KAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"callbar_button.vue.js","sources":["../../../../recipes/buttons/callbar_button/callbar_button.vue"],"sourcesContent":["<template>\n <dt-tooltip\n :id=\"id\"\n :inverted=\"invertedTooltip\"\n :delay=\"tooltipDelay\"\n :show=\"showTooltip\"\n :offset=\"[0, 24]\"\n >\n <template #anchor>\n <span\n :class=\"{ 'd-recipe-callbar-button--disabled': disabled }\"\n >\n <dt-button\n :importance=\"buttonImportance\"\n kind=\"muted\"\n icon-position=\"top\"\n :aria-disabled=\"disabled\"\n :aria-label=\"ariaLabel\"\n :label-class=\"callbarButtonTextClass\"\n :width=\"buttonWidth\"\n :class=\"callbarButtonClass\"\n v-bind=\"$attrs\"\n v-on=\"callbarButtonListeners\"\n >\n <slot />\n <template #icon>\n <slot name=\"icon\" />\n </template>\n </dt-button>\n </span>\n </template>\n <slot name=\"tooltip\">\n {{ tooltipText }}\n </slot>\n </dt-tooltip>\n</template>\n\n<script>\nimport { CALLBAR_BUTTON_VALID_WIDTH_SIZE } from './callbar_button_constants';\nimport { DtButton } from '@/components/button';\nimport { DtTooltip } from '@/components/tooltip';\nimport utils from '@/common/utils';\n\nexport default {\n name: 'DtRecipeCallbarButton',\n\n components: { DtButton, DtTooltip },\n\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 * 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 * 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 * Whether the button is a circle or not.\n * @values true, false\n * @see https://dialtone.dialpad.com/components/button/\n */\n circle: {\n type: Boolean,\n default: false,\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 * 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 * The fill and outline of the button associated with its visual importance.\n * @values clear, outlined, primary\n */\n importance: {\n type: String,\n default: '',\n },\n\n /**\n * Whether the tooltip has an inverted background color.\n * @values true, false\n */\n invertedTooltip: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Use this if you would like to manually override the logic for when the tooltip shows.\n * Otherwise it will just show on hover/focus.\n * @values null, true, false\n */\n showTooltip: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The message that displays in the tooltip. This will be overridden by the tooltip slot.\n */\n tooltipText: {\n type: String,\n default: undefined,\n },\n\n /**\n * Whether there is a delay before the tooltip shows on hover/focus.\n * @values true, false\n */\n tooltipDelay: {\n type: Boolean,\n default: undefined,\n },\n },\n\n emits: [\n /**\n * Native click event\n *\n * @event click\n * @type {PointerEvent | KeyboardEvent}\n */\n 'click',\n ],\n\n computed: {\n callbarButtonClass () {\n return [\n this.buttonClass,\n 'd-recipe-callbar-button',\n {\n 'd-recipe-callbar-button--circle': this.circle,\n 'd-recipe-callbar-button--active': this.active,\n 'd-recipe-callbar-button--danger': this.danger,\n 'd-btn--disabled': this.disabled,\n }];\n },\n\n callbarButtonTextClass () {\n return [\n 'd-recipe-callbar-button__text',\n this.textClass,\n ];\n },\n\n buttonWidth () {\n switch (this.buttonWidthSize) {\n case 'sm':\n return '4.5rem';\n case 'md':\n return '6rem';\n default:\n return '8.4rem';\n }\n },\n\n buttonImportance () {\n if (this.importance) {\n return this.importance;\n }\n return this.circle ? 'outlined' : 'clear';\n },\n\n callbarButtonListeners () {\n return {\n ...this.$listeners,\n click: (event) => this.$emit('click', event),\n };\n },\n },\n};\n</script>\n"],"names":["this"],"mappings":";;;;;AA2CA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA,EAAA,UAAA,UAAA;AAAA,EAEA,cAAA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA,IAIA,IAAA;AAAA,MACA,MAAA;AAAA,MACA,UAAA;AACA,eAAA,MAAA;MACA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAQA,QAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAQ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;AAAA,EACA;AAAA,EAEA,UAAA;AAAA,IACA,qBAAA;AACA,aAAA;AAAA,QACA,KAAA;AAAA,QACA;AAAA,QACA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mCAAA,KAAA;AAAA,UACA,mBAAA,KAAA;AAAA,QACA;AAAA,MAAA;AAAA,IACA;AAAA,IAEA,yBAAA;AACA,aAAA;AAAA,QACA;AAAA,QACA,KAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,cAAA;AACA,cAAA,KAAA,iBAAA;AAAA,QACA,KAAA;AACA,iBAAA;AAAA,QACA,KAAA;AACA,iBAAA;AAAA,QACA;AACA,iBAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,mBAAA;AACA,UAAA,KAAA,YAAA;AACA,eAAA,KAAA;AAAA,MACA;AACA,aAAA,KAAA,SAAA,aAAA;AAAA,IACA;AAAA,IAEA,yBAAA;AACA,aAAA;AAAA,QACA,GAAA,KAAA;AAAA,QACA,OAAA,CAAA,UAAA,KAAA,MAAA,SAAA,KAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,258 @@
1
+ "use strict";
2
+ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
+ const vue2 = require("@dialpad/dialtone-icons/vue2");
4
+ const common_utils = require("../../../common/utils.cjs");
5
+ const _pluginVue2_normalizer = require("../../../_virtual/_plugin-vue2_normalizer.cjs");
6
+ const callbar_button = require("../callbar_button/callbar_button.vue.cjs");
7
+ const dropdown = require("../../../components/dropdown/dropdown.vue.cjs");
8
+ const button = require("../../../components/button/button.vue.cjs");
9
+ const callbar_button_constants = require("../callbar_button/callbar_button_constants.cjs");
10
+ const _sfc_main = {
11
+ name: "DtRecipeCallbarButtonWithDropdown",
12
+ components: { DtRecipeCallbarButton: callbar_button.default, DtDropdown: dropdown.default, DtButton: button.default, DtIconChevronUp: vue2.DtIconChevronUp },
13
+ /* inheritAttrs: false is generally an option we want to set on library
14
+ components. This allows any attributes passed in that are not recognized
15
+ as props to be passed down to another element or component using v-bind:$attrs
16
+ more info: https://vuejs.org/v2/api/#inheritAttrs */
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
+ * Aria label for the button. If empty, it takes its value from the default slot.
30
+ */
31
+ ariaLabel: {
32
+ type: String,
33
+ default: null,
34
+ validator: (label) => {
35
+ return label || (void 0).$slots.default;
36
+ }
37
+ },
38
+ /**
39
+ * Aria label for the arrow. Cannot be empty.
40
+ */
41
+ arrowButtonLabel: {
42
+ type: String,
43
+ required: true,
44
+ validator: (label) => {
45
+ return !!label;
46
+ }
47
+ },
48
+ /**
49
+ * The direction the dropdown displays relative to the anchor.
50
+ * @values 'bottom', 'bottom-start', 'bottom-end',
51
+ * 'right', 'right-start', 'right-end',
52
+ * 'left', 'left-start', 'left-end',
53
+ * 'top', 'top-start', 'top-end'
54
+ * @default 'top'
55
+ */
56
+ placement: {
57
+ type: String,
58
+ default: "top"
59
+ },
60
+ /**
61
+ * If the dropdown does not fit in the direction described by "placement",
62
+ * it will attempt to change it's direction to the "fallbackPlacements".
63
+ *
64
+ * @values top, top-start, top-end,
65
+ * right, right-start, right-end,
66
+ * left, left-start, left-end,
67
+ * bottom, bottom-start, bottom-end,
68
+ * auto, auto-start, auto-end
69
+ * */
70
+ fallbackPlacements: {
71
+ type: Array,
72
+ default: () => {
73
+ return ["auto"];
74
+ }
75
+ },
76
+ /**
77
+ * Determines whether the button should be disabled
78
+ * default is false.
79
+ * @values true, false
80
+ */
81
+ disabled: {
82
+ type: Boolean,
83
+ default: false
84
+ },
85
+ /**
86
+ * Forces showing the arrow, even if the button is disabled.
87
+ * default is false
88
+ * @values true, false
89
+ */
90
+ forceShowArrow: {
91
+ type: Boolean,
92
+ default: false
93
+ },
94
+ /**
95
+ * Determines whether the button should have active styling
96
+ * default is false.
97
+ * @values true, false
98
+ * @see https://dialtone.dialpad.com/components/button/
99
+ */
100
+ active: {
101
+ type: Boolean,
102
+ default: false
103
+ },
104
+ /**
105
+ * Determines whether the button should have danger styling
106
+ * default is false.
107
+ * @values true, false
108
+ * @see https://dialtone.dialpad.com/components/button/
109
+ */
110
+ danger: {
111
+ type: Boolean,
112
+ default: false
113
+ },
114
+ /**
115
+ * Additional class name for the button wrapper element.
116
+ */
117
+ buttonClass: {
118
+ type: [String, Array, Object],
119
+ default: ""
120
+ },
121
+ /**
122
+ * Additional class name for the button text.
123
+ */
124
+ textClass: {
125
+ type: [String, Array, Object],
126
+ default: ""
127
+ },
128
+ /*
129
+ * Width size. Valid values are: 'xl', 'lg', 'md' and 'sm'.
130
+ */
131
+ buttonWidthSize: {
132
+ type: String,
133
+ default: "xl",
134
+ validator: (size) => callbar_button_constants.CALLBAR_BUTTON_VALID_WIDTH_SIZE.includes(size)
135
+ },
136
+ /**
137
+ * Whether the tooltip has an inverted background color.
138
+ * @values true, false
139
+ */
140
+ invertedTooltip: {
141
+ type: Boolean,
142
+ default: false
143
+ },
144
+ /**
145
+ * Use this if you would like to manually override the logic for when the tooltip shows.
146
+ * Otherwise it will just show on hover/focus.
147
+ * @values null, true, false
148
+ */
149
+ showTooltip: {
150
+ type: Boolean,
151
+ default: null
152
+ },
153
+ /**
154
+ * The message that displays in the tooltip. This will be overridden by the tooltip slot.
155
+ */
156
+ tooltipText: {
157
+ type: String,
158
+ default: void 0
159
+ },
160
+ /**
161
+ * Whether there is a delay before the tooltip shows on hover/focus.
162
+ * @values true, false
163
+ */
164
+ tooltipDelay: {
165
+ type: Boolean,
166
+ default: void 0
167
+ }
168
+ },
169
+ emits: [
170
+ /**
171
+ * Emitted when the arrow is clicked
172
+ */
173
+ "arrow-click",
174
+ /**
175
+ * Native click event
176
+ *
177
+ * @event click
178
+ * @type {PointerEvent | KeyboardEvent}
179
+ */
180
+ "click",
181
+ /**
182
+ * Emitted when modal dropdown is opened or closed.
183
+ */
184
+ "opened"
185
+ ],
186
+ data() {
187
+ return {
188
+ open: false
189
+ };
190
+ },
191
+ computed: {
192
+ showArrowButton() {
193
+ return this.forceShowArrow || !this.disabled;
194
+ },
195
+ isCompactMode() {
196
+ return this.buttonWidthSize === "sm" || this.buttonWidthSize === "md";
197
+ },
198
+ showDropdown() {
199
+ if (!this.openDropdown || this.open) {
200
+ this.syncOpenState();
201
+ return false;
202
+ }
203
+ return this.toggleOpen();
204
+ }
205
+ },
206
+ mounted() {
207
+ common_utils.warnIfUnmounted(this.$el, this.$options.name);
208
+ },
209
+ methods: {
210
+ arrowClick(ev) {
211
+ this.$emit("arrow-click", ev);
212
+ return this.toggleOpen();
213
+ },
214
+ toggleOpen() {
215
+ return this.open = !this.open;
216
+ },
217
+ syncOpenState() {
218
+ this.open = this.openDropdown;
219
+ },
220
+ buttonClick(ev) {
221
+ if (!this.$listeners.click) {
222
+ this.arrowClick(ev);
223
+ } else {
224
+ this.$emit("click", ev);
225
+ }
226
+ },
227
+ onModalIsOpened(isOpened) {
228
+ this.open = isOpened;
229
+ this.$emit("opened", isOpened);
230
+ }
231
+ }
232
+ };
233
+ var _sfc_render = function render() {
234
+ var _vm = this, _c = _vm._self._c;
235
+ return _c("div", { staticClass: "dt-recipe--callbar-button-with-dropdown" }, [_c("dt-recipe-callbar-button", { staticClass: "dt-recipe--callbar-button-with-dropdown--main-button", attrs: { "aria-label": _vm.ariaLabel, "disabled": _vm.disabled, "active": _vm.active, "danger": _vm.danger, "button-class": _vm.buttonClass, "button-width-size": _vm.buttonWidthSize, "text-class": _vm.textClass, "inverted-tooltip": _vm.invertedTooltip, "show-tooltip": _vm.showTooltip, "tooltip-text": _vm.tooltipText, "tooltip-delay": _vm.tooltipDelay }, on: { "click": _vm.buttonClick }, scopedSlots: _vm._u([{ key: "icon", fn: function() {
236
+ return [_vm._t("icon")];
237
+ }, proxy: true }, { key: "tooltip", fn: function() {
238
+ return [_vm._t("tooltip")];
239
+ }, proxy: true }], null, true) }, [_vm._t("default")], 2), _vm.showArrowButton ? _c("dt-dropdown", _vm._b({ staticClass: "dt-recipe--callbar-button-with-dropdown--dropdown-wrapper", attrs: { "id": _vm.id, "open": _vm.open, "placement": _vm.placement, "fallback-placements": _vm.fallbackPlacements, "padding": "none" }, on: { "opened": _vm.onModalIsOpened }, scopedSlots: _vm._u([{ key: "anchor", fn: function() {
240
+ return [_c("dt-button", { class: [
241
+ "dt-recipe--callbar-button-with-dropdown--arrow",
242
+ { "dt-recipe--callbar-button-with-dropdown--arrow--large": !_vm.isCompactMode }
243
+ ], attrs: { "circle": "", "importance": "clear", "size": "lg", "width": "2rem", "aria-label": _vm.arrowButtonLabel, "active": _vm.open }, on: { "click": _vm.arrowClick }, scopedSlots: _vm._u([{ key: "icon", fn: function() {
244
+ return [_c("dt-icon-chevron-up", { staticClass: "dt-recipe--callbar-button-with-dropdown--arrow__icon", attrs: { "size": "200" } })];
245
+ }, proxy: true }], null, false, 887776886) })];
246
+ }, proxy: true }, { key: "list", fn: function() {
247
+ return [_vm._t("list")];
248
+ }, proxy: true }], null, true) }, "dt-dropdown", _vm.$attrs, false)) : _vm._e()], 1);
249
+ };
250
+ var _sfc_staticRenderFns = [];
251
+ var __component__ = /* @__PURE__ */ _pluginVue2_normalizer.default(
252
+ _sfc_main,
253
+ _sfc_render,
254
+ _sfc_staticRenderFns
255
+ );
256
+ const callbar_button_with_dropdown = __component__.exports;
257
+ exports.default = callbar_button_with_dropdown;
258
+ //# sourceMappingURL=callbar_button_with_dropdown.vue.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"callbar_button_with_dropdown.vue.cjs","sources":["../../../../recipes/buttons/callbar_button_with_dropdown/callbar_button_with_dropdown.vue"],"sourcesContent":["<template>\n <div\n class=\"dt-recipe--callbar-button-with-dropdown\"\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 :inverted-tooltip=\"invertedTooltip\"\n :show-tooltip=\"showTooltip\"\n :tooltip-text=\"tooltipText\"\n :tooltip-delay=\"tooltipDelay\"\n class=\"dt-recipe--callbar-button-with-dropdown--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-dropdown\n v-if=\"showArrowButton\"\n :id=\"id\"\n :open=\"open\"\n :placement=\"placement\"\n :fallback-placements=\"fallbackPlacements\"\n padding=\"none\"\n class=\"dt-recipe--callbar-button-with-dropdown--dropdown-wrapper\"\n v-bind=\"$attrs\"\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-dropdown--arrow',\n { 'dt-recipe--callbar-button-with-dropdown--arrow--large': !isCompactMode }]\"\n width=\"2rem\"\n :aria-label=\"arrowButtonLabel\"\n :active=\"open\"\n @click=\"arrowClick\"\n >\n <template #icon>\n <dt-icon-chevron-up\n class=\"dt-recipe--callbar-button-with-dropdown--arrow__icon\"\n size=\"200\"\n />\n </template>\n </dt-button>\n </template>\n <template #list>\n <slot name=\"list\" />\n </template>\n </dt-dropdown>\n </div>\n</template>\n\n<script>\nimport { DtButton } from '@/components/button';\nimport { DtDropdown } from '@/components/dropdown';\nimport { DtIconChevronUp } from '@dialpad/dialtone-icons/vue2';\nimport { DtRecipeCallbarButton, CALLBAR_BUTTON_VALID_WIDTH_SIZE } from '../callbar_button';\nimport utils, { warnIfUnmounted } from '@/common/utils';\n\nexport default {\n name: 'DtRecipeCallbarButtonWithDropdown',\n\n components: { DtRecipeCallbarButton, DtDropdown, DtButton, DtIconChevronUp },\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 dropdown 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 * If the dropdown does not fit in the direction described by \"placement\",\n * it will attempt to change it's direction to the \"fallbackPlacements\".\n *\n * @values top, top-start, top-end,\n * right, right-start, right-end,\n * left, left-start, left-end,\n * bottom, bottom-start, bottom-end,\n * auto, auto-start, auto-end\n * */\n fallbackPlacements: {\n type: Array,\n default: () => {\n return ['auto'];\n },\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 * 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 * Whether the tooltip has an inverted background color.\n * @values true, false\n */\n invertedTooltip: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Use this if you would like to manually override the logic for when the tooltip shows.\n * Otherwise it will just show on hover/focus.\n * @values null, true, false\n */\n showTooltip: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The message that displays in the tooltip. This will be overridden by the tooltip slot.\n */\n tooltipText: {\n type: String,\n default: undefined,\n },\n\n /**\n * Whether there is a delay before the tooltip shows on hover/focus.\n * @values true, false\n */\n tooltipDelay: {\n type: Boolean,\n default: undefined,\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 dropdown 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 showDropdown () {\n if (!this.openDropdown || this.open) {\n this.syncOpenState();\n return false;\n }\n\n return this.toggleOpen();\n },\n },\n\n mounted () {\n warnIfUnmounted(this.$el, this.$options.name);\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.openDropdown;\n },\n\n buttonClick (ev) {\n // If no listener for the click event, the button click opens the dropdown\n // the same as if the arrow was clicked.\n if (!this.$listeners.click) {\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"],"names":["DtRecipeCallbarButton","DtDropdown","DtButton","DtIconChevronUp","utils","this","CALLBAR_BUTTON_VALID_WIDTH_SIZE","warnIfUnmounted"],"mappings":";;;;;;;;;AAwEA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA,EAAA,uBAAAA,eAAA,SAAA,YAAAC,kBAAAC,UAAAA,OAAAA,SAAAC,iBAAAA,KAAAA,gBAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAMA,cAAA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA,IAIA,IAAA;AAAA,MACA,MAAA;AAAA,MACA,UAAA;AACA,eAAAC,aAAAA,QAAA;MACA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,WAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,MACA,WAAA,CAAA,UAAA;AACA,eAAA,SAAAC,SAAA,OAAA;AAAA,MACA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,kBAAA;AAAA,MACA,MAAA;AAAA,MACA,UAAA;AAAA,MACA,WAAA,CAAA,UAAA;AACA,eAAA,CAAA,CAAA;AAAA,MACA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAUA,WAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAYA,oBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA,MAAA;AACA,eAAA,CAAA,MAAA;AAAA,MACA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,UAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAOA,gBAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAA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