@dialpad/dialtone-vue 2.153.0 → 2.154.1

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 (398) hide show
  1. package/dist/chunks/{dropdown-YdCyJ5Dq.js → dropdown-6UoczdUY.js} +41 -77
  2. package/dist/chunks/{dropdown-YdCyJ5Dq.js.map → dropdown-6UoczdUY.js.map} +1 -1
  3. package/dist/chunks/{dropdown-mjrYu_mK.js → dropdown-pHxnQPzT.js} +41 -77
  4. package/dist/chunks/{dropdown-mjrYu_mK.js.map → dropdown-pHxnQPzT.js.map} +1 -1
  5. package/dist/chunks/dropdown_constants-2pGCXy7m.js.map +1 -1
  6. package/dist/chunks/dropdown_constants-w1MXGC3Z.js.map +1 -1
  7. package/dist/chunks/{icon_constants-TdxqLsS2.js → icon_constants-Dy4MEUJL.js} +2 -3
  8. package/dist/chunks/icon_constants-Dy4MEUJL.js.map +1 -0
  9. package/dist/chunks/{icon_constants-VEA0wI5C.js → icon_constants-QYpmdE0R.js} +2 -3
  10. package/dist/chunks/icon_constants-QYpmdE0R.js.map +1 -0
  11. package/dist/chunks/{index-i65YVk-U.js → index-ODod4Oj_.js} +13 -5
  12. package/dist/chunks/{index-i65YVk-U.js.map → index-ODod4Oj_.js.map} +1 -1
  13. package/dist/chunks/{index-NYFNZeHH.js → index-anN_sx1F.js} +13 -5
  14. package/dist/chunks/{index-NYFNZeHH.js.map → index-anN_sx1F.js.map} +1 -1
  15. package/dist/chunks/{index-mBWay1Qb.js → index-eJ-WWRdf.js} +87 -122
  16. package/dist/chunks/{index-mBWay1Qb.js.map → index-eJ-WWRdf.js.map} +1 -1
  17. package/dist/chunks/{index-DyqUqjvI.js → index-gj1jEXP4.js} +87 -122
  18. package/dist/chunks/{index-DyqUqjvI.js.map → index-gj1jEXP4.js.map} +1 -1
  19. package/dist/chunks/{input-PhJeBN6r.js → input-6kbd8Pju.js} +9 -3
  20. package/dist/chunks/{input-PhJeBN6r.js.map → input-6kbd8Pju.js.map} +1 -1
  21. package/dist/chunks/{input-Hqw33WBe.js → input-Axw-wFj2.js} +9 -3
  22. package/dist/chunks/{input-Hqw33WBe.js.map → input-Axw-wFj2.js.map} +1 -1
  23. package/dist/chunks/{input_group-pE6ec9R3.js → input_group-m3cWYUfI.js} +2 -4
  24. package/dist/chunks/{input_group-ZI7aVGEp.js.map → input_group-m3cWYUfI.js.map} +1 -1
  25. package/dist/chunks/{input_group-ZI7aVGEp.js → input_group-qVZaS5Bb.js} +2 -4
  26. package/dist/chunks/{input_group-pE6ec9R3.js.map → input_group-qVZaS5Bb.js.map} +1 -1
  27. package/dist/chunks/{keyboard_list_navigation-YIqTuw1W.js → keyboard_list_navigation-ScXhrxya.js} +5 -6
  28. package/dist/chunks/{keyboard_list_navigation-x3D6RcC7.js.map → keyboard_list_navigation-ScXhrxya.js.map} +1 -1
  29. package/dist/chunks/{keyboard_list_navigation-x3D6RcC7.js → keyboard_list_navigation-fJnl_Iox.js} +5 -6
  30. package/dist/chunks/{keyboard_list_navigation-YIqTuw1W.js.map → keyboard_list_navigation-fJnl_Iox.js.map} +1 -1
  31. package/dist/chunks/link_constants-AfTWrr-n.js.map +1 -1
  32. package/dist/chunks/link_constants-x8NwdqmA.js.map +1 -1
  33. package/dist/chunks/list_item_constants-EiqkqZvP.js.map +1 -1
  34. package/dist/chunks/list_item_constants-u1xcN9Dd.js.map +1 -1
  35. package/dist/chunks/{modal-OaWxzqNt.js → modal-VgxXAQFP.js} +2 -4
  36. package/dist/chunks/{modal-OaWxzqNt.js.map → modal-VgxXAQFP.js.map} +1 -1
  37. package/dist/chunks/{modal-8X6poIZW.js → modal-XOr4kiNZ.js} +2 -4
  38. package/dist/chunks/{modal-8X6poIZW.js.map → modal-XOr4kiNZ.js.map} +1 -1
  39. package/dist/chunks/{notice_action-qQr3K2TC.js → notice_action-IRUoLX2d.js} +46 -71
  40. package/dist/chunks/{notice_action-qQr3K2TC.js.map → notice_action-IRUoLX2d.js.map} +1 -1
  41. package/dist/chunks/{notice_action-tEvvMg7Q.js → notice_action-P6uDyE9x.js} +46 -71
  42. package/dist/chunks/{notice_action-tEvvMg7Q.js.map → notice_action-P6uDyE9x.js.map} +1 -1
  43. package/dist/chunks/notice_constants-7Qt2CQEY.js.map +1 -1
  44. package/dist/chunks/notice_constants-UXo9e3bS.js.map +1 -1
  45. package/dist/chunks/{popover_constants-6YkPPbnk.js → popover_constants-WsOUIY-m.js} +47 -26
  46. package/dist/chunks/{popover_constants-6YkPPbnk.js.map → popover_constants-WsOUIY-m.js.map} +1 -1
  47. package/dist/chunks/{popover_constants-h9MD6WUt.js → popover_constants-XnGWXaxX.js} +47 -26
  48. package/dist/chunks/{popover_constants-h9MD6WUt.js.map → popover_constants-XnGWXaxX.js.map} +1 -1
  49. package/dist/chunks/{sr_only_close_button-IjMVfBDE.js → sr_only_close_button-81bHIpPu.js} +18 -24
  50. package/dist/chunks/{sr_only_close_button-IjMVfBDE.js.map → sr_only_close_button-81bHIpPu.js.map} +1 -1
  51. package/dist/chunks/{sr_only_close_button-2Q9Ny1Nc.js → sr_only_close_button-ZaGdAHz7.js} +18 -24
  52. package/dist/chunks/{sr_only_close_button-2Q9Ny1Nc.js.map → sr_only_close_button-ZaGdAHz7.js.map} +1 -1
  53. package/dist/chunks/stack_constants-HraCekPm.js.map +1 -1
  54. package/dist/chunks/stack_constants-SMzMWnAQ.js.map +1 -1
  55. package/dist/chunks/{tab-79yMX6m6.js → tab-FcsV5VmK.js} +68 -86
  56. package/dist/chunks/{tab-muPOS7JE.js.map → tab-FcsV5VmK.js.map} +1 -1
  57. package/dist/chunks/{tab-muPOS7JE.js → tab-V4cb44Ry.js} +68 -86
  58. package/dist/chunks/{tab-79yMX6m6.js.map → tab-V4cb44Ry.js.map} +1 -1
  59. package/dist/common/constants.cjs.map +1 -1
  60. package/dist/common/constants.js.map +1 -1
  61. package/dist/common/dates.cjs +1 -3
  62. package/dist/common/dates.cjs.map +1 -1
  63. package/dist/common/dates.js +1 -3
  64. package/dist/common/dates.js.map +1 -1
  65. package/dist/common/emoji.cjs +1 -1
  66. package/dist/common/emoji.js +1 -1
  67. package/dist/common/mixins.cjs +3 -3
  68. package/dist/common/mixins.js +3 -3
  69. package/dist/common/utils.cjs +44 -8
  70. package/dist/common/utils.cjs.map +1 -1
  71. package/dist/common/utils.js +44 -8
  72. package/dist/common/utils.js.map +1 -1
  73. package/dist/common/validators.cjs.map +1 -1
  74. package/dist/common/validators.js.map +1 -1
  75. package/dist/component-documentation.json +1 -1
  76. package/dist/dialtone-vue.cjs +12 -12
  77. package/dist/dialtone-vue.js +12 -12
  78. package/dist/lib/attachment-carousel.cjs +48 -172
  79. package/dist/lib/attachment-carousel.cjs.map +1 -1
  80. package/dist/lib/attachment-carousel.js +48 -172
  81. package/dist/lib/attachment-carousel.js.map +1 -1
  82. package/dist/lib/avatar.cjs +58 -75
  83. package/dist/lib/avatar.cjs.map +1 -1
  84. package/dist/lib/avatar.js +58 -75
  85. package/dist/lib/avatar.js.map +1 -1
  86. package/dist/lib/badge.cjs +20 -31
  87. package/dist/lib/badge.cjs.map +1 -1
  88. package/dist/lib/badge.js +20 -31
  89. package/dist/lib/badge.js.map +1 -1
  90. package/dist/lib/banner.cjs +29 -53
  91. package/dist/lib/banner.cjs.map +1 -1
  92. package/dist/lib/banner.js +29 -53
  93. package/dist/lib/banner.js.map +1 -1
  94. package/dist/lib/breadcrumbs.cjs +30 -36
  95. package/dist/lib/breadcrumbs.cjs.map +1 -1
  96. package/dist/lib/breadcrumbs.js +30 -36
  97. package/dist/lib/breadcrumbs.js.map +1 -1
  98. package/dist/lib/button-group.cjs +14 -7
  99. package/dist/lib/button-group.cjs.map +1 -1
  100. package/dist/lib/button-group.js +14 -7
  101. package/dist/lib/button-group.js.map +1 -1
  102. package/dist/lib/button.cjs +62 -55
  103. package/dist/lib/button.cjs.map +1 -1
  104. package/dist/lib/button.js +62 -55
  105. package/dist/lib/button.js.map +1 -1
  106. package/dist/lib/callbar-button-with-popover.cjs +23 -91
  107. package/dist/lib/callbar-button-with-popover.cjs.map +1 -1
  108. package/dist/lib/callbar-button-with-popover.js +23 -91
  109. package/dist/lib/callbar-button-with-popover.js.map +1 -1
  110. package/dist/lib/callbar-button.cjs +33 -49
  111. package/dist/lib/callbar-button.cjs.map +1 -1
  112. package/dist/lib/callbar-button.js +33 -49
  113. package/dist/lib/callbar-button.js.map +1 -1
  114. package/dist/lib/callbox.cjs +15 -78
  115. package/dist/lib/callbox.cjs.map +1 -1
  116. package/dist/lib/callbox.js +15 -78
  117. package/dist/lib/callbox.js.map +1 -1
  118. package/dist/lib/card.cjs +23 -16
  119. package/dist/lib/card.cjs.map +1 -1
  120. package/dist/lib/card.js +23 -16
  121. package/dist/lib/card.js.map +1 -1
  122. package/dist/lib/checkbox-group.cjs +15 -3
  123. package/dist/lib/checkbox-group.cjs.map +1 -1
  124. package/dist/lib/checkbox-group.js +15 -3
  125. package/dist/lib/checkbox-group.js.map +1 -1
  126. package/dist/lib/checkbox.cjs +16 -52
  127. package/dist/lib/checkbox.cjs.map +1 -1
  128. package/dist/lib/checkbox.js +16 -52
  129. package/dist/lib/checkbox.js.map +1 -1
  130. package/dist/lib/chip.cjs +26 -58
  131. package/dist/lib/chip.cjs.map +1 -1
  132. package/dist/lib/chip.js +26 -58
  133. package/dist/lib/chip.js.map +1 -1
  134. package/dist/lib/codeblock.cjs +11 -4
  135. package/dist/lib/codeblock.cjs.map +1 -1
  136. package/dist/lib/codeblock.js +11 -4
  137. package/dist/lib/codeblock.js.map +1 -1
  138. package/dist/lib/collapsible.cjs +34 -91
  139. package/dist/lib/collapsible.cjs.map +1 -1
  140. package/dist/lib/collapsible.js +34 -91
  141. package/dist/lib/collapsible.js.map +1 -1
  142. package/dist/lib/combobox-multi-select.cjs +38 -131
  143. package/dist/lib/combobox-multi-select.cjs.map +1 -1
  144. package/dist/lib/combobox-multi-select.js +38 -131
  145. package/dist/lib/combobox-multi-select.js.map +1 -1
  146. package/dist/lib/combobox-with-popover.cjs +39 -130
  147. package/dist/lib/combobox-with-popover.cjs.map +1 -1
  148. package/dist/lib/combobox-with-popover.js +39 -130
  149. package/dist/lib/combobox-with-popover.js.map +1 -1
  150. package/dist/lib/combobox.cjs +3 -3
  151. package/dist/lib/combobox.js +3 -3
  152. package/dist/lib/contact-centers-row.cjs +29 -86
  153. package/dist/lib/contact-centers-row.cjs.map +1 -1
  154. package/dist/lib/contact-centers-row.js +29 -86
  155. package/dist/lib/contact-centers-row.js.map +1 -1
  156. package/dist/lib/contact-info.cjs +31 -95
  157. package/dist/lib/contact-info.cjs.map +1 -1
  158. package/dist/lib/contact-info.js +31 -95
  159. package/dist/lib/contact-info.js.map +1 -1
  160. package/dist/lib/contact-row.cjs +18 -61
  161. package/dist/lib/contact-row.cjs.map +1 -1
  162. package/dist/lib/contact-row.js +18 -61
  163. package/dist/lib/contact-row.js.map +1 -1
  164. package/dist/lib/datepicker.cjs +102 -361
  165. package/dist/lib/datepicker.cjs.map +1 -1
  166. package/dist/lib/datepicker.js +102 -361
  167. package/dist/lib/datepicker.js.map +1 -1
  168. package/dist/lib/description-list.cjs +12 -11
  169. package/dist/lib/description-list.cjs.map +1 -1
  170. package/dist/lib/description-list.js +12 -11
  171. package/dist/lib/description-list.js.map +1 -1
  172. package/dist/lib/dropdown.cjs +17 -13
  173. package/dist/lib/dropdown.cjs.map +1 -1
  174. package/dist/lib/dropdown.js +17 -13
  175. package/dist/lib/dropdown.js.map +1 -1
  176. package/dist/lib/editor.cjs +109 -409
  177. package/dist/lib/editor.cjs.map +1 -1
  178. package/dist/lib/editor.js +109 -409
  179. package/dist/lib/editor.js.map +1 -1
  180. package/dist/lib/emoji-picker.cjs +234 -512
  181. package/dist/lib/emoji-picker.cjs.map +1 -1
  182. package/dist/lib/emoji-picker.js +234 -512
  183. package/dist/lib/emoji-picker.js.map +1 -1
  184. package/dist/lib/emoji-row.cjs +31 -69
  185. package/dist/lib/emoji-row.cjs.map +1 -1
  186. package/dist/lib/emoji-row.js +31 -69
  187. package/dist/lib/emoji-row.js.map +1 -1
  188. package/dist/lib/emoji-text-wrapper.cjs +22 -14
  189. package/dist/lib/emoji-text-wrapper.cjs.map +1 -1
  190. package/dist/lib/emoji-text-wrapper.js +22 -14
  191. package/dist/lib/emoji-text-wrapper.js.map +1 -1
  192. package/dist/lib/emoji.cjs +13 -40
  193. package/dist/lib/emoji.cjs.map +1 -1
  194. package/dist/lib/emoji.js +13 -40
  195. package/dist/lib/emoji.js.map +1 -1
  196. package/dist/lib/empty-state.cjs +12 -27
  197. package/dist/lib/empty-state.cjs.map +1 -1
  198. package/dist/lib/empty-state.js +12 -27
  199. package/dist/lib/empty-state.js.map +1 -1
  200. package/dist/lib/feed-item-row.cjs +27 -106
  201. package/dist/lib/feed-item-row.cjs.map +1 -1
  202. package/dist/lib/feed-item-row.js +27 -106
  203. package/dist/lib/feed-item-row.js.map +1 -1
  204. package/dist/lib/feed-pill.cjs +35 -90
  205. package/dist/lib/feed-pill.cjs.map +1 -1
  206. package/dist/lib/feed-pill.js +35 -90
  207. package/dist/lib/feed-pill.js.map +1 -1
  208. package/dist/lib/general-row.cjs +75 -184
  209. package/dist/lib/general-row.cjs.map +1 -1
  210. package/dist/lib/general-row.js +75 -184
  211. package/dist/lib/general-row.js.map +1 -1
  212. package/dist/lib/group-row.cjs +16 -27
  213. package/dist/lib/group-row.cjs.map +1 -1
  214. package/dist/lib/group-row.js +16 -27
  215. package/dist/lib/group-row.js.map +1 -1
  216. package/dist/lib/grouped-chip.cjs +20 -68
  217. package/dist/lib/grouped-chip.cjs.map +1 -1
  218. package/dist/lib/grouped-chip.js +20 -68
  219. package/dist/lib/grouped-chip.js.map +1 -1
  220. package/dist/lib/hovercard.cjs +41 -71
  221. package/dist/lib/hovercard.cjs.map +1 -1
  222. package/dist/lib/hovercard.js +41 -71
  223. package/dist/lib/hovercard.js.map +1 -1
  224. package/dist/lib/icon.cjs +12 -10
  225. package/dist/lib/icon.cjs.map +1 -1
  226. package/dist/lib/icon.js +12 -10
  227. package/dist/lib/icon.js.map +1 -1
  228. package/dist/lib/illustration.cjs +12 -9
  229. package/dist/lib/illustration.cjs.map +1 -1
  230. package/dist/lib/illustration.js +12 -9
  231. package/dist/lib/illustration.js.map +1 -1
  232. package/dist/lib/image-viewer.cjs +23 -88
  233. package/dist/lib/image-viewer.cjs.map +1 -1
  234. package/dist/lib/image-viewer.js +23 -88
  235. package/dist/lib/image-viewer.js.map +1 -1
  236. package/dist/lib/input-group.cjs +14 -24
  237. package/dist/lib/input-group.cjs.map +1 -1
  238. package/dist/lib/input-group.js +14 -24
  239. package/dist/lib/input-group.js.map +1 -1
  240. package/dist/lib/input.cjs +47 -109
  241. package/dist/lib/input.cjs.map +1 -1
  242. package/dist/lib/input.js +47 -109
  243. package/dist/lib/input.js.map +1 -1
  244. package/dist/lib/item-layout.cjs +11 -42
  245. package/dist/lib/item-layout.cjs.map +1 -1
  246. package/dist/lib/item-layout.js +11 -42
  247. package/dist/lib/item-layout.js.map +1 -1
  248. package/dist/lib/ivr-node.cjs +47 -135
  249. package/dist/lib/ivr-node.cjs.map +1 -1
  250. package/dist/lib/ivr-node.js +47 -135
  251. package/dist/lib/ivr-node.js.map +1 -1
  252. package/dist/lib/keyboard-shortcut.cjs +23 -35
  253. package/dist/lib/keyboard-shortcut.cjs.map +1 -1
  254. package/dist/lib/keyboard-shortcut.js +23 -35
  255. package/dist/lib/keyboard-shortcut.js.map +1 -1
  256. package/dist/lib/lazy-show.cjs +11 -15
  257. package/dist/lib/lazy-show.cjs.map +1 -1
  258. package/dist/lib/lazy-show.js +11 -15
  259. package/dist/lib/lazy-show.js.map +1 -1
  260. package/dist/lib/link.cjs +15 -9
  261. package/dist/lib/link.cjs.map +1 -1
  262. package/dist/lib/link.js +15 -9
  263. package/dist/lib/link.js.map +1 -1
  264. package/dist/lib/list-item-group.cjs +11 -17
  265. package/dist/lib/list-item-group.cjs.map +1 -1
  266. package/dist/lib/list-item-group.js +11 -17
  267. package/dist/lib/list-item-group.js.map +1 -1
  268. package/dist/lib/list-item.cjs +23 -42
  269. package/dist/lib/list-item.cjs.map +1 -1
  270. package/dist/lib/list-item.js +23 -42
  271. package/dist/lib/list-item.js.map +1 -1
  272. package/dist/lib/message-input.cjs +102 -360
  273. package/dist/lib/message-input.cjs.map +1 -1
  274. package/dist/lib/message-input.js +102 -360
  275. package/dist/lib/message-input.js.map +1 -1
  276. package/dist/lib/modal.cjs +36 -94
  277. package/dist/lib/modal.cjs.map +1 -1
  278. package/dist/lib/modal.js +36 -94
  279. package/dist/lib/modal.js.map +1 -1
  280. package/dist/lib/notice.cjs +21 -40
  281. package/dist/lib/notice.cjs.map +1 -1
  282. package/dist/lib/notice.js +21 -40
  283. package/dist/lib/notice.js.map +1 -1
  284. package/dist/lib/pagination.cjs +20 -81
  285. package/dist/lib/pagination.cjs.map +1 -1
  286. package/dist/lib/pagination.js +20 -81
  287. package/dist/lib/pagination.js.map +1 -1
  288. package/dist/lib/popover.cjs +75 -194
  289. package/dist/lib/popover.cjs.map +1 -1
  290. package/dist/lib/popover.js +76 -195
  291. package/dist/lib/popover.js.map +1 -1
  292. package/dist/lib/presence.cjs +22 -23
  293. package/dist/lib/presence.cjs.map +1 -1
  294. package/dist/lib/presence.js +22 -23
  295. package/dist/lib/presence.js.map +1 -1
  296. package/dist/lib/radio-group.cjs +11 -2
  297. package/dist/lib/radio-group.cjs.map +1 -1
  298. package/dist/lib/radio-group.js +11 -2
  299. package/dist/lib/radio-group.js.map +1 -1
  300. package/dist/lib/radio.cjs +15 -47
  301. package/dist/lib/radio.cjs.map +1 -1
  302. package/dist/lib/radio.js +15 -47
  303. package/dist/lib/radio.js.map +1 -1
  304. package/dist/lib/rich-text-editor.cjs +317 -336
  305. package/dist/lib/rich-text-editor.cjs.map +1 -1
  306. package/dist/lib/rich-text-editor.js +317 -336
  307. package/dist/lib/rich-text-editor.js.map +1 -1
  308. package/dist/lib/root-layout.cjs +15 -33
  309. package/dist/lib/root-layout.cjs.map +1 -1
  310. package/dist/lib/root-layout.js +15 -33
  311. package/dist/lib/root-layout.js.map +1 -1
  312. package/dist/lib/scrollbar-directive.cjs +422 -388
  313. package/dist/lib/scrollbar-directive.cjs.map +1 -1
  314. package/dist/lib/scrollbar-directive.js +422 -388
  315. package/dist/lib/scrollbar-directive.js.map +1 -1
  316. package/dist/lib/select-menu.cjs +33 -52
  317. package/dist/lib/select-menu.cjs.map +1 -1
  318. package/dist/lib/select-menu.js +33 -52
  319. package/dist/lib/select-menu.js.map +1 -1
  320. package/dist/lib/settings-menu-button.cjs +16 -42
  321. package/dist/lib/settings-menu-button.cjs.map +1 -1
  322. package/dist/lib/settings-menu-button.js +16 -42
  323. package/dist/lib/settings-menu-button.js.map +1 -1
  324. package/dist/lib/skeleton.cjs +93 -118
  325. package/dist/lib/skeleton.cjs.map +1 -1
  326. package/dist/lib/skeleton.js +93 -118
  327. package/dist/lib/skeleton.js.map +1 -1
  328. package/dist/lib/split-button.cjs +64 -164
  329. package/dist/lib/split-button.cjs.map +1 -1
  330. package/dist/lib/split-button.js +64 -164
  331. package/dist/lib/split-button.js.map +1 -1
  332. package/dist/lib/stack.cjs +33 -21
  333. package/dist/lib/stack.cjs.map +1 -1
  334. package/dist/lib/stack.js +33 -21
  335. package/dist/lib/stack.js.map +1 -1
  336. package/dist/lib/tabs.cjs +13 -20
  337. package/dist/lib/tabs.cjs.map +1 -1
  338. package/dist/lib/tabs.js +13 -20
  339. package/dist/lib/tabs.js.map +1 -1
  340. package/dist/lib/time-pill.cjs +11 -8
  341. package/dist/lib/time-pill.cjs.map +1 -1
  342. package/dist/lib/time-pill.js +11 -8
  343. package/dist/lib/time-pill.js.map +1 -1
  344. package/dist/lib/toast.cjs +21 -42
  345. package/dist/lib/toast.cjs.map +1 -1
  346. package/dist/lib/toast.js +21 -42
  347. package/dist/lib/toast.js.map +1 -1
  348. package/dist/lib/toggle.cjs +24 -28
  349. package/dist/lib/toggle.cjs.map +1 -1
  350. package/dist/lib/toggle.js +24 -28
  351. package/dist/lib/toggle.js.map +1 -1
  352. package/dist/lib/tooltip-directive.cjs +26 -32
  353. package/dist/lib/tooltip-directive.cjs.map +1 -1
  354. package/dist/lib/tooltip-directive.js +26 -32
  355. package/dist/lib/tooltip-directive.js.map +1 -1
  356. package/dist/lib/tooltip.cjs +21 -31
  357. package/dist/lib/tooltip.cjs.map +1 -1
  358. package/dist/lib/tooltip.js +22 -32
  359. package/dist/lib/tooltip.js.map +1 -1
  360. package/dist/lib/top-banner-info.cjs +21 -18
  361. package/dist/lib/top-banner-info.cjs.map +1 -1
  362. package/dist/lib/top-banner-info.js +21 -18
  363. package/dist/lib/top-banner-info.js.map +1 -1
  364. package/dist/lib/unread-pill.cjs +12 -18
  365. package/dist/lib/unread-pill.cjs.map +1 -1
  366. package/dist/lib/unread-pill.js +12 -18
  367. package/dist/lib/unread-pill.js.map +1 -1
  368. package/dist/lib/validation-messages.cjs +16 -23
  369. package/dist/lib/validation-messages.cjs.map +1 -1
  370. package/dist/lib/validation-messages.js +16 -23
  371. package/dist/lib/validation-messages.js.map +1 -1
  372. package/dist/style.css +9 -9
  373. package/dist/types/common/emoji/index.d.ts +59236 -2
  374. package/dist/types/common/emoji/index.d.ts.map +1 -1
  375. package/dist/types/components/button/button.vue.d.ts +1 -1
  376. package/dist/types/components/chip/chip.vue.d.ts +1 -1
  377. package/dist/types/components/combobox/combobox.vue.d.ts +1 -1
  378. package/dist/types/components/icon/icon.vue.d.ts +2 -2
  379. package/dist/types/components/icon/icon_constants.d.ts +1 -1
  380. package/dist/types/components/icon/icon_constants.d.ts.map +1 -1
  381. package/dist/types/components/illustration/illustration.vue.d.ts +2 -2
  382. package/dist/types/components/illustration/illustration_constants.d.ts +1 -1
  383. package/dist/types/components/illustration/illustration_constants.d.ts.map +1 -1
  384. package/dist/types/components/input/input.vue.d.ts +3 -2
  385. package/dist/types/components/input/input.vue.d.ts.map +1 -1
  386. package/dist/types/components/modal/modal.vue.d.ts +1 -1
  387. package/dist/types/components/rich_text_editor/rich_text_editor.vue.d.ts +1 -1
  388. package/dist/types/components/split_button/split_button-alpha.vue.d.ts +1 -1
  389. package/dist/types/components/toast/toast.vue.d.ts +1 -1
  390. package/dist/types/components/tooltip/tooltip.vue.d.ts +1 -1
  391. package/dist/types/recipes/comboboxes/combobox_with_popover/combobox_with_popover.vue.d.ts +1 -1
  392. package/dist/types/recipes/conversation_view/editor/editor.vue.d.ts +1 -1
  393. package/dist/types/recipes/conversation_view/feed_item_row/feed_item_row.vue.d.ts +1 -1
  394. package/dist/types/recipes/item_layout/contact_info/contact_info.vue.d.ts +15 -0
  395. package/dist/types/recipes/item_layout/contact_info/contact_info.vue.d.ts.map +1 -1
  396. package/package.json +2 -4
  397. package/dist/chunks/icon_constants-TdxqLsS2.js.map +0 -1
  398. package/dist/chunks/icon_constants-VEA0wI5C.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"collapsible.js","sources":["../../components/collapsible/collapsible_lazy_show.vue","../../components/collapsible/collapsible.vue"],"sourcesContent":["<template>\n <!-- applies the transition on initial render -->\n <transition\n :appear=\"appear\"\n enter-active-class=\"enter-active\"\n leave-active-class=\"leave-active\"\n :css=\"isCSSEnabled\"\n @before-enter=\"beforeEnter\"\n @enter=\"enter\"\n @after-enter=\"afterEnter\"\n @before-leave=\"beforeLeave\"\n @leave=\"leave\"\n @after-leave=\"afterLeave\"\n v-on=\"$listeners\"\n >\n <component\n :is=\"elementType\"\n v-show=\"show\"\n v-on=\"$listeners\"\n >\n <!-- @slot slot for Content within collapsible -->\n <slot v-if=\"initialized\" />\n </component>\n </transition>\n</template>\n\n<script>\nexport default {\n name: 'DtCollapsibleLazyShow',\n\n /******************\n * PROPS *\n ******************/\n props: {\n /**\n * Whether the child slot is shown.\n */\n show: {\n type: Boolean,\n default: null,\n },\n\n /**\n * Enable/Disable transition animation\n */\n appear: {\n type: Boolean,\n default: false,\n },\n\n /**\n * HTML element type (tag name) of the content wrapper element.\n */\n elementType: {\n type: String,\n default: 'div',\n },\n },\n\n /******************\n * DATA *\n ******************/\n data () {\n return {\n initialized: !!this.show,\n };\n },\n\n /******************\n * COMPUTED *\n ******************/\n computed: {\n /**\n * Set the css property to false when running tests only.\n * Refer to: https://vuejs.org/guide/built-ins/transition.html#javascript-hooks for details about\n * transition `css` property\n * @returns {boolean}\n */\n isCSSEnabled () {\n return process.env.NODE_ENV !== 'test';\n },\n },\n\n /******************\n * WATCH *\n ******************/\n watch: {\n show: function (newValue) {\n if (!newValue || this.initialized) return;\n\n this.initialized = true;\n },\n },\n\n methods: {\n /**\n * @param {HTMLElement} element\n */\n beforeEnter (element) {\n requestAnimationFrame(() => {\n if (!element.style.height) {\n element.style.height = '0px';\n }\n });\n },\n\n /**\n * @param {HTMLElement} element\n */\n enter (element) {\n requestAnimationFrame(() => {\n requestAnimationFrame(() => {\n element.style.height = `${element.scrollHeight}px`;\n });\n });\n },\n\n /**\n * @param {HTMLElement} element\n */\n afterEnter (element) {\n element.style.height = null;\n },\n\n /**\n * @param {HTMLElement} element\n */\n beforeLeave (element) {\n requestAnimationFrame(() => {\n if (!element.style.height) {\n element.style.height = `${element.offsetHeight}px`;\n }\n });\n },\n\n /**\n * @param {HTMLElement} element\n */\n leave (element) {\n requestAnimationFrame(() => {\n requestAnimationFrame(() => {\n element.style.height = '0px';\n });\n });\n },\n\n /**\n * @param {HTMLElement} element\n */\n afterLeave (element) {\n element.style.height = null;\n },\n },\n};\n</script>\n\n<style>\n .enter-active,\n .leave-active {\n overflow: hidden;\n transition: height var(--td300) var(--ttf-out-quint);\n }\n</style>\n","<template>\n <component\n :is=\"elementType\"\n ref=\"collapsible\"\n v-on=\"$listeners\"\n >\n <!-- Element for capturing keypress events -->\n <div\n :id=\"!ariaLabelledBy && labelledBy\"\n ref=\"anchor\"\n :class=\"anchorClass\"\n >\n <!-- @slot Slot for the anchor element that toggles the collapsible content -->\n <slot\n name=\"anchor\"\n :attrs=\"{\n 'aria-controls': id,\n 'aria-expanded': isOpen.toString(),\n 'role': 'button',\n }\"\n >\n <dt-button\n importance=\"clear\"\n kind=\"muted\"\n :aria-controls=\"id\"\n :aria-expanded=\"`${isOpen}`\"\n :style=\"{\n 'width': maxWidth,\n }\"\n @click=\"defaultToggleOpen\"\n >\n <dt-icon\n :name=\" isOpen ? 'chevron-down' : 'chevron-right'\"\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <span\n class=\"d-collapsible__anchor-text\"\n :title=\"anchorText\"\n >\n {{ anchorText }}\n </span>\n </dt-button>\n </slot>\n </div>\n <dt-collapsible-lazy-show\n :id=\"id\"\n ref=\"contentWrapper\"\n :aria-hidden=\"`${!isOpen}`\"\n :aria-labelledby=\"labelledBy\"\n :aria-label=\"ariaLabel\"\n :show=\"isOpen\"\n :element-type=\"contentElementType\"\n :class=\"contentClass\"\n :style=\"{\n 'max-height': maxHeight,\n 'max-width': maxWidth,\n }\"\n data-qa=\"dt-collapsible--content\"\n tabindex=\"-1\"\n appear\n v-on=\"$listeners\"\n @after-leave=\"onLeaveTransitionComplete\"\n @after-enter=\"onEnterTransitionComplete\"\n >\n <!-- @slot Slot for the collapsible element that is expanded by the anchor -->\n <slot\n name=\"content\"\n />\n </dt-collapsible-lazy-show>\n </component>\n</template>\n\n<script>\nimport { getUniqueString } from '@/common/utils';\nimport DtCollapsibleLazyShow from './collapsible_lazy_show.vue';\nimport { DtButton } from '@/components/button';\nimport { DtLazyShow } from '@/components/lazy_show';\nimport { DtIcon } from '@/components/icon';\n\n/**\n * A collapsible is a component consisting of an interactive anchor that toggled the expandable/collapsible element.\n * @see https://dialtone.dialpad.com/components/collapsible.html\n */\nexport default {\n name: 'DtCollapsible',\n\n components: {\n DtButton,\n DtCollapsibleLazyShow,\n DtLazyShow,\n DtIcon,\n },\n\n props: {\n /**\n * Text that is displayed on the anchor if nothing is passed in the slot.\n * Ignored if the anchor slot is used.\n */\n anchorText: {\n type: String,\n default: null,\n },\n\n /**\n * Controls whether the collapsible is shown. Leaving this null will have the collapsible start\n * expanded and trigger on click by default. If you set this value, the default trigger\n * behavior will be disabled, and you can control it as you need.\n * Supports .sync modifier\n * @values null, true, false\n */\n open: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The id of the content wrapper.\n */\n id: {\n type: String,\n default () { return getUniqueString(); },\n },\n\n /**\n * HTML element type (tag name) of the root element of the component.\n */\n elementType: {\n type: String,\n default: 'div',\n },\n\n /**\n * HTML element type (tag name) of the content wrapper element.\n */\n contentElementType: {\n type: String,\n default: 'div',\n },\n\n /**\n * Additional class name for the anchor wrapper element.\n */\n anchorClass: {\n type: [String, Array, Object],\n default: null,\n },\n\n /**\n * Additional class name for the content wrapper element.\n */\n contentClass: {\n type: [String, Array, Object],\n default: null,\n },\n\n /**\n * The maximum width of the anchor and collapsible element.\n * Possible units rem|px|%|em\n */\n maxWidth: {\n type: String,\n default: null,\n },\n\n /**\n * The maximum height of the collapsible element.\n * Possible units rem|px|%|em\n */\n maxHeight: {\n type: String,\n default: null,\n },\n\n /**\n * Label on the collapsible content. Should provide this or ariaLabelledBy but not both.\n */\n ariaLabel: {\n type: String,\n default: null,\n },\n\n /**\n * Id of the element that labels the collapsible content. Defaults to the anchor element.\n * Should provide this or ariaLabel but not both.\n */\n ariaLabelledBy: {\n type: String,\n default: null,\n },\n },\n\n emits: [\n /**\n * Event fired to sync the open prop with the parent component\n * @event update:open\n */\n 'update:open',\n\n /**\n * Event fired when the content is shown or hidden\n *\n * @event opened\n * @type {Boolean}\n */\n 'opened',\n ],\n\n data () {\n return {\n isOpen: true,\n };\n },\n\n computed: {\n labelledBy () {\n // aria-labelledby should be set only if aria-labelledby is passed as a prop, or if\n // there is no aria-label and the labelledby should point to the anchor\n return this.ariaLabelledBy || (!this.ariaLabel && getUniqueString('DtCollapsible__anchor'));\n },\n },\n\n watch: {\n open: {\n handler: function (open) {\n if (open !== null) {\n this.isOpen = open;\n }\n },\n\n immediate: true,\n },\n },\n\n mounted () {\n this.validateProperAnchor();\n },\n\n methods: {\n onLeaveTransitionComplete () {\n this.$emit('opened', false);\n if (this.open !== null) {\n this.$emit('update:open', false);\n }\n },\n\n onEnterTransitionComplete () {\n this.$emit('opened', true, this.$refs.content);\n if (this.open !== null) {\n this.$emit('update:open', true);\n }\n },\n\n defaultToggleOpen () {\n if (this.open === null) {\n this.toggleOpen();\n }\n },\n\n toggleOpen () {\n this.isOpen = !this.isOpen;\n },\n\n validateProperAnchor () {\n if (!this.anchorText && !this.$scopedSlots.anchor) {\n console.error('anchor text and anchor slot content cannot both be falsy');\n }\n },\n },\n};\n</script>\n"],"names":["_sfc_main","name","props","show","type","Boolean","default","appear","elementType","String","data","initialized","computed","isCSSEnabled","process","env","NODE_ENV","watch","newValue","methods","beforeEnter","element","requestAnimationFrame","style","height","enter","scrollHeight","afterEnter","beforeLeave","offsetHeight","leave","afterLeave","components","DtButton","DtCollapsibleLazyShow","DtLazyShow","DtIcon","anchorText","open","id","getUniqueString","contentElementType","anchorClass","Array","Object","contentClass","maxWidth","maxHeight","ariaLabel","ariaLabelledBy","emits","isOpen","labelledBy","handler","immediate","mounted","validateProperAnchor","onLeaveTransitionComplete","$emit","onEnterTransitionComplete","$refs","content","defaultToggleOpen","toggleOpen","$scopedSlots","anchor","console","error"],"mappings":";;;;;;;;;;;AA2BA,MAAAA,cAAA;AAAA,EACAC,MAAA;AAAA;AAAA;AAAA;AAAA,EAKAC,OAAA;AAAA;AAAA;AAAA;AAAA,IAIAC,MAAA;AAAA,MACAC,MAAAC;AAAAA,MACAC,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKAC,QAAA;AAAA,MACAH,MAAAC;AAAAA,MACAC,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKAE,aAAA;AAAA,MACAJ,MAAAK;AAAAA,MACAH,SAAA;AAAA,IACA;AAAA,EACA;AAAA;AAAA;AAAA;AAAA,EAKAI,OAAA;AACA,WAAA;AAAA,MACAC,aAAA,CAAA,CAAA,KAAAR;AAAAA;EAEA;AAAA;AAAA;AAA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;;;"}
1
+ {"version":3,"file":"collapsible.js","sources":["../../components/collapsible/collapsible_lazy_show.vue","../../components/collapsible/collapsible.vue"],"sourcesContent":["<template>\n <!-- applies the transition on initial render -->\n <transition\n :appear=\"appear\"\n enter-active-class=\"enter-active\"\n leave-active-class=\"leave-active\"\n :css=\"isCSSEnabled\"\n @before-enter=\"beforeEnter\"\n @enter=\"enter\"\n @after-enter=\"afterEnter\"\n @before-leave=\"beforeLeave\"\n @leave=\"leave\"\n @after-leave=\"afterLeave\"\n v-on=\"$listeners\"\n >\n <component\n :is=\"elementType\"\n v-show=\"show\"\n v-on=\"$listeners\"\n >\n <!-- @slot slot for Content within collapsible -->\n <slot v-if=\"initialized\" />\n </component>\n </transition>\n</template>\n\n<script>\nexport default {\n name: 'DtCollapsibleLazyShow',\n\n /******************\n * PROPS *\n ******************/\n props: {\n /**\n * Whether the child slot is shown.\n */\n show: {\n type: Boolean,\n default: null,\n },\n\n /**\n * Enable/Disable transition animation\n */\n appear: {\n type: Boolean,\n default: false,\n },\n\n /**\n * HTML element type (tag name) of the content wrapper element.\n */\n elementType: {\n type: String,\n default: 'div',\n },\n },\n\n /******************\n * DATA *\n ******************/\n data () {\n return {\n initialized: !!this.show,\n };\n },\n\n /******************\n * COMPUTED *\n ******************/\n computed: {\n /**\n * Set the css property to false when running tests only.\n * Refer to: https://vuejs.org/guide/built-ins/transition.html#javascript-hooks for details about\n * transition `css` property\n * @returns {boolean}\n */\n isCSSEnabled () {\n return process.env.NODE_ENV !== 'test';\n },\n },\n\n /******************\n * WATCH *\n ******************/\n watch: {\n show: function (newValue) {\n if (!newValue || this.initialized) return;\n\n this.initialized = true;\n },\n },\n\n methods: {\n /**\n * @param {HTMLElement} element\n */\n beforeEnter (element) {\n requestAnimationFrame(() => {\n if (!element.style.height) {\n element.style.height = '0px';\n }\n });\n },\n\n /**\n * @param {HTMLElement} element\n */\n enter (element) {\n requestAnimationFrame(() => {\n requestAnimationFrame(() => {\n element.style.height = `${element.scrollHeight}px`;\n });\n });\n },\n\n /**\n * @param {HTMLElement} element\n */\n afterEnter (element) {\n element.style.height = null;\n },\n\n /**\n * @param {HTMLElement} element\n */\n beforeLeave (element) {\n requestAnimationFrame(() => {\n if (!element.style.height) {\n element.style.height = `${element.offsetHeight}px`;\n }\n });\n },\n\n /**\n * @param {HTMLElement} element\n */\n leave (element) {\n requestAnimationFrame(() => {\n requestAnimationFrame(() => {\n element.style.height = '0px';\n });\n });\n },\n\n /**\n * @param {HTMLElement} element\n */\n afterLeave (element) {\n element.style.height = null;\n },\n },\n};\n</script>\n\n<style>\n .enter-active,\n .leave-active {\n overflow: hidden;\n transition: height var(--td300) var(--ttf-out-quint);\n }\n</style>\n","<template>\n <component\n :is=\"elementType\"\n ref=\"collapsible\"\n v-on=\"$listeners\"\n >\n <!-- Element for capturing keypress events -->\n <div\n :id=\"!ariaLabelledBy && labelledBy\"\n ref=\"anchor\"\n :class=\"anchorClass\"\n >\n <!-- @slot Slot for the anchor element that toggles the collapsible content -->\n <slot\n name=\"anchor\"\n :attrs=\"{\n 'aria-controls': id,\n 'aria-expanded': isOpen.toString(),\n 'role': 'button',\n }\"\n >\n <dt-button\n importance=\"clear\"\n kind=\"muted\"\n :aria-controls=\"id\"\n :aria-expanded=\"`${isOpen}`\"\n :style=\"{\n 'width': maxWidth,\n }\"\n @click=\"defaultToggleOpen\"\n >\n <dt-icon\n :name=\" isOpen ? 'chevron-down' : 'chevron-right'\"\n class=\"d-collapsible__icon\"\n size=\"300\"\n />\n <span\n class=\"d-collapsible__anchor-text\"\n :title=\"anchorText\"\n >\n {{ anchorText }}\n </span>\n </dt-button>\n </slot>\n </div>\n <dt-collapsible-lazy-show\n :id=\"id\"\n ref=\"contentWrapper\"\n :aria-hidden=\"`${!isOpen}`\"\n :aria-labelledby=\"labelledBy\"\n :aria-label=\"ariaLabel\"\n :show=\"isOpen\"\n :element-type=\"contentElementType\"\n :class=\"contentClass\"\n :style=\"{\n 'max-height': maxHeight,\n 'max-width': maxWidth,\n }\"\n data-qa=\"dt-collapsible--content\"\n tabindex=\"-1\"\n appear\n v-on=\"$listeners\"\n @after-leave=\"onLeaveTransitionComplete\"\n @after-enter=\"onEnterTransitionComplete\"\n >\n <!-- @slot Slot for the collapsible element that is expanded by the anchor -->\n <slot\n name=\"content\"\n />\n </dt-collapsible-lazy-show>\n </component>\n</template>\n\n<script>\nimport { getUniqueString } from '@/common/utils';\nimport DtCollapsibleLazyShow from './collapsible_lazy_show.vue';\nimport { DtButton } from '@/components/button';\nimport { DtLazyShow } from '@/components/lazy_show';\nimport { DtIcon } from '@/components/icon';\n\n/**\n * A collapsible is a component consisting of an interactive anchor that toggled the expandable/collapsible element.\n * @see https://dialtone.dialpad.com/components/collapsible.html\n */\nexport default {\n name: 'DtCollapsible',\n\n components: {\n DtButton,\n DtCollapsibleLazyShow,\n DtLazyShow,\n DtIcon,\n },\n\n props: {\n /**\n * Text that is displayed on the anchor if nothing is passed in the slot.\n * Ignored if the anchor slot is used.\n */\n anchorText: {\n type: String,\n default: null,\n },\n\n /**\n * Controls whether the collapsible is shown. Leaving this null will have the collapsible start\n * expanded and trigger on click by default. If you set this value, the default trigger\n * behavior will be disabled, and you can control it as you need.\n * Supports .sync modifier\n * @values null, true, false\n */\n open: {\n type: Boolean,\n default: null,\n },\n\n /**\n * The id of the content wrapper.\n */\n id: {\n type: String,\n default () { return getUniqueString(); },\n },\n\n /**\n * HTML element type (tag name) of the root element of the component.\n */\n elementType: {\n type: String,\n default: 'div',\n },\n\n /**\n * HTML element type (tag name) of the content wrapper element.\n */\n contentElementType: {\n type: String,\n default: 'div',\n },\n\n /**\n * Additional class name for the anchor wrapper element.\n */\n anchorClass: {\n type: [String, Array, Object],\n default: null,\n },\n\n /**\n * Additional class name for the content wrapper element.\n */\n contentClass: {\n type: [String, Array, Object],\n default: null,\n },\n\n /**\n * The maximum width of the anchor and collapsible element.\n * Possible units rem|px|%|em\n */\n maxWidth: {\n type: String,\n default: null,\n },\n\n /**\n * The maximum height of the collapsible element.\n * Possible units rem|px|%|em\n */\n maxHeight: {\n type: String,\n default: null,\n },\n\n /**\n * Label on the collapsible content. Should provide this or ariaLabelledBy but not both.\n */\n ariaLabel: {\n type: String,\n default: null,\n },\n\n /**\n * Id of the element that labels the collapsible content. Defaults to the anchor element.\n * Should provide this or ariaLabel but not both.\n */\n ariaLabelledBy: {\n type: String,\n default: null,\n },\n },\n\n emits: [\n /**\n * Event fired to sync the open prop with the parent component\n * @event update:open\n */\n 'update:open',\n\n /**\n * Event fired when the content is shown or hidden\n *\n * @event opened\n * @type {Boolean}\n */\n 'opened',\n ],\n\n data () {\n return {\n isOpen: true,\n };\n },\n\n computed: {\n labelledBy () {\n // aria-labelledby should be set only if aria-labelledby is passed as a prop, or if\n // there is no aria-label and the labelledby should point to the anchor\n return this.ariaLabelledBy || (!this.ariaLabel && getUniqueString('DtCollapsible__anchor'));\n },\n },\n\n watch: {\n open: {\n handler: function (open) {\n if (open !== null) {\n this.isOpen = open;\n }\n },\n\n immediate: true,\n },\n },\n\n mounted () {\n this.validateProperAnchor();\n },\n\n methods: {\n onLeaveTransitionComplete () {\n this.$emit('opened', false);\n if (this.open !== null) {\n this.$emit('update:open', false);\n }\n },\n\n onEnterTransitionComplete () {\n this.$emit('opened', true, this.$refs.content);\n if (this.open !== null) {\n this.$emit('update:open', true);\n }\n },\n\n defaultToggleOpen () {\n if (this.open === null) {\n this.toggleOpen();\n }\n },\n\n toggleOpen () {\n this.isOpen = !this.isOpen;\n },\n\n validateProperAnchor () {\n if (!this.anchorText && !this.$scopedSlots.anchor) {\n console.error('anchor text and anchor slot content cannot both be falsy');\n }\n },\n },\n};\n</script>\n"],"names":["_sfc_main"],"mappings":";;;;;;;;;;;AA2BA,MAAAA,cAAA;AAAA,EACA,MAAA;AAAA;AAAA;AAAA;AAAA,EAKA,OAAA;AAAA;AAAA;AAAA;AAAA,IAIA,MAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AA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5
  const lib_chip = require("./chip.cjs");
6
6
  const lib_validationMessages = require("./validation-messages.cjs");
7
7
  const common_validators = require("../common/validators.cjs");
8
- const popover_constants = require("../chunks/popover_constants-h9MD6WUt.js");
9
- const sr_only_close_button = require("../chunks/sr_only_close_button-2Q9Ny1Nc.js");
8
+ const popover_constants = require("../chunks/popover_constants-XnGWXaxX.js");
9
+ const sr_only_close_button = require("../chunks/sr_only_close_button-ZaGdAHz7.js");
10
10
  const common_utils = require("../common/utils.cjs");
11
11
  const _pluginVue2_normalizer = require("../chunks/_plugin-vue2_normalizer-1aBeR4AK.js");
12
- require("../chunks/index-DyqUqjvI.js");
13
- require("../chunks/keyboard_list_navigation-x3D6RcC7.js");
12
+ require("../chunks/index-gj1jEXP4.js");
13
+ require("../chunks/keyboard_list_navigation-fJnl_Iox.js");
14
14
  require("./list-item.cjs");
15
15
  require("../chunks/list_item_constants-EiqkqZvP.js");
16
16
  require("./item-layout.cjs");
17
17
  require("./icon.cjs");
18
18
  require("@dialpad/dialtone-icons/vue2");
19
- require("../chunks/icon_constants-VEA0wI5C.js");
19
+ require("../chunks/icon_constants-QYpmdE0R.js");
20
20
  require("@dialpad/dialtone-icons/icons.json");
21
21
  require("../common/constants.cjs");
22
22
  require("vue");
23
23
  require("./skeleton.cjs");
24
24
  require("./popover.cjs");
25
25
  require("@linusborg/vue-simple-portal");
26
- require("../chunks/modal-OaWxzqNt.js");
26
+ require("../chunks/modal-VgxXAQFP.js");
27
27
  require("./button.cjs");
28
28
  require("../chunks/link_constants-x8NwdqmA.js");
29
29
  require("./lazy-show.cjs");
30
30
  require("tippy.js");
31
31
  require("../chunks/dropdown_constants-2pGCXy7m.js");
32
- require("../chunks/input-Hqw33WBe.js");
32
+ require("../chunks/input-Axw-wFj2.js");
33
33
  const MULTI_SELECT_SIZES = {
34
34
  // Chip has no 'lg' and 'xl' size. So we don't support that in multi-select.
35
35
  EXTRA_SMALL: "xs",
@@ -541,132 +541,39 @@ const _sfc_main = {
541
541
  };
542
542
  var _sfc_render = function render() {
543
543
  var _vm = this, _c = _vm._self._c;
544
- return _c("dt-recipe-combobox-with-popover", {
545
- ref: "comboboxWithPopover",
546
- attrs: {
547
- "label": _vm.label,
548
- "show-list": _vm.showList,
549
- "max-height": _vm.listMaxHeight,
550
- "max-width": _vm.listMaxWidth,
551
- "popover-offset": _vm.popoverOffset,
552
- "has-suggestion-list": _vm.hasSuggestionList,
553
- "visually-hidden-close-label": _vm.visuallyHiddenCloseLabel,
554
- "visually-hidden-close": _vm.visuallyHiddenClose,
555
- "content-width": "anchor",
556
- "append-to": _vm.appendTo,
557
- "transition": _vm.transition
558
- },
559
- on: {
560
- "select": _vm.onComboboxSelect,
561
- "highlight": _vm.comboboxHighlight
562
- },
563
- scopedSlots: _vm._u([{
564
- key: "input",
565
- fn: function({
566
- onInput
567
- }) {
568
- return [_c("span", {
569
- ref: "inputSlotWrapper",
570
- staticClass: "combobox__input-wrapper",
571
- on: {
572
- "focusin": _vm.handleInputFocusIn,
573
- "focusout": _vm.handleInputFocusOut
574
- }
575
- }, [_c("span", {
576
- ref: "chipsWrapper",
577
- class: ["combobox__chip-wrapper", _vm.chipWrapperClass]
578
- }, _vm._l(_vm.selectedItemsWithKeys, function({
579
- item,
580
- key
581
- }) {
582
- return _c("dt-chip", _vm._g({
583
- key,
584
- ref: "chips",
585
- refInFor: true,
586
- staticClass: "combobox__chip",
587
- attrs: {
588
- "label-class": ["d-chip__label"],
589
- "close-button-props": {
590
- ariaLabel: "close"
591
- },
592
- "size": _vm.CHIP_SIZES[_vm.size]
593
- },
594
- on: {
595
- "keyup": function($event) {
596
- if (!$event.type.indexOf("key") && _vm._k($event.keyCode, "backspace", void 0, $event.key, void 0))
597
- return null;
598
- return _vm.onChipRemove(item);
599
- },
600
- "close": function($event) {
601
- return _vm.onChipRemove(item);
602
- }
603
- }
604
- }, _vm.chipListeners), [_vm._v(" " + _vm._s(item) + " ")]);
605
- }), 1), _c("dt-input", _vm._g({
606
- ref: "input",
607
- staticClass: "combobox__input",
608
- attrs: {
609
- "aria-label": _vm.label,
610
- "label": _vm.labelVisible ? _vm.label : "",
611
- "description": _vm.description,
612
- "placeholder": _vm.inputPlaceHolder,
613
- "show-messages": _vm.showInputMessages,
614
- "messages": _vm.inputMessages,
615
- "size": _vm.size
616
- },
617
- on: {
618
- "input": onInput
619
- },
620
- model: {
621
- value: _vm.value,
622
- callback: function($$v) {
623
- _vm.value = $$v;
624
- },
625
- expression: "value"
626
- }
627
- }, _vm.inputListeners)), _c("dt-validation-messages", {
628
- attrs: {
629
- "validation-messages": _vm.maxSelectedMessage,
630
- "show-messages": _vm.showValidationMessages
631
- }
632
- })], 1)];
633
- }
634
- }, _vm.$slots.header ? {
635
- key: "header",
636
- fn: function() {
637
- return [_c("div", {
638
- ref: "header"
639
- }, [_vm._t("header")], 2)];
640
- },
641
- proxy: true
642
- } : null, {
643
- key: "list",
644
- fn: function() {
645
- return [_c("div", {
646
- ref: "list",
647
- on: {
648
- "mousedown": function($event) {
649
- $event.preventDefault();
650
- }
651
- }
652
- }, [!_vm.loading ? _vm._t("list") : _c("div", {
653
- staticClass: "combobox__list--loading"
654
- }, [_vm._v(" " + _vm._s(_vm.loadingMessage) + " ")])], 2)];
655
- },
656
- proxy: true
657
- }, _vm.$slots.footer ? {
658
- key: "footer",
659
- fn: function() {
660
- return [_c("div", {
661
- ref: "footer"
662
- }, [_vm._t("footer")], 2)];
663
- },
664
- proxy: true
665
- } : null], null, true)
666
- });
544
+ return _c("dt-recipe-combobox-with-popover", { ref: "comboboxWithPopover", attrs: { "label": _vm.label, "show-list": _vm.showList, "max-height": _vm.listMaxHeight, "max-width": _vm.listMaxWidth, "popover-offset": _vm.popoverOffset, "has-suggestion-list": _vm.hasSuggestionList, "visually-hidden-close-label": _vm.visuallyHiddenCloseLabel, "visually-hidden-close": _vm.visuallyHiddenClose, "content-width": "anchor", "append-to": _vm.appendTo, "transition": _vm.transition }, on: { "select": _vm.onComboboxSelect, "highlight": _vm.comboboxHighlight }, scopedSlots: _vm._u([{ key: "input", fn: function({ onInput }) {
545
+ return [_c("span", { ref: "inputSlotWrapper", staticClass: "combobox__input-wrapper", on: { "focusin": _vm.handleInputFocusIn, "focusout": _vm.handleInputFocusOut } }, [_c("span", { ref: "chipsWrapper", class: ["combobox__chip-wrapper", _vm.chipWrapperClass] }, _vm._l(_vm.selectedItemsWithKeys, function({ item, key }) {
546
+ return _c("dt-chip", _vm._g({ key, ref: "chips", refInFor: true, staticClass: "combobox__chip", attrs: { "label-class": ["d-chip__label"], "close-button-props": { ariaLabel: "close" }, "size": _vm.CHIP_SIZES[_vm.size] }, on: { "keyup": function($event) {
547
+ if (!$event.type.indexOf("key") && _vm._k($event.keyCode, "backspace", void 0, $event.key, void 0))
548
+ return null;
549
+ return _vm.onChipRemove(item);
550
+ }, "close": function($event) {
551
+ return _vm.onChipRemove(item);
552
+ } } }, _vm.chipListeners), [_vm._v(" " + _vm._s(item) + " ")]);
553
+ }), 1), _c("dt-input", _vm._g({ ref: "input", staticClass: "combobox__input", attrs: { "aria-label": _vm.label, "label": _vm.labelVisible ? _vm.label : "", "description": _vm.description, "placeholder": _vm.inputPlaceHolder, "show-messages": _vm.showInputMessages, "messages": _vm.inputMessages, "size": _vm.size }, on: { "input": onInput }, model: { value: _vm.value, callback: function($$v) {
554
+ _vm.value = $$v;
555
+ }, expression: "value" } }, _vm.inputListeners)), _c("dt-validation-messages", { attrs: { "validation-messages": _vm.maxSelectedMessage, "show-messages": _vm.showValidationMessages } })], 1)];
556
+ } }, _vm.$slots.header ? { key: "header", fn: function() {
557
+ return [_c("div", { ref: "header" }, [_vm._t("header")], 2)];
558
+ }, proxy: true } : null, { key: "list", fn: function() {
559
+ return [_c("div", { ref: "list", on: { "mousedown": function($event) {
560
+ $event.preventDefault();
561
+ } } }, [!_vm.loading ? _vm._t("list") : _c("div", { staticClass: "combobox__list--loading" }, [_vm._v(" " + _vm._s(_vm.loadingMessage) + " ")])], 2)];
562
+ }, proxy: true }, _vm.$slots.footer ? { key: "footer", fn: function() {
563
+ return [_c("div", { ref: "footer" }, [_vm._t("footer")], 2)];
564
+ }, proxy: true } : null], null, true) });
667
565
  };
668
566
  var _sfc_staticRenderFns = [];
669
- var __component__ = /* @__PURE__ */ _pluginVue2_normalizer.normalizeComponent(_sfc_main, _sfc_render, _sfc_staticRenderFns, false, null, "e9045f30", null, null);
567
+ var __component__ = /* @__PURE__ */ _pluginVue2_normalizer.normalizeComponent(
568
+ _sfc_main,
569
+ _sfc_render,
570
+ _sfc_staticRenderFns,
571
+ false,
572
+ null,
573
+ "e9045f30",
574
+ null,
575
+ null
576
+ );
670
577
  const combobox_multi_select = __component__.exports;
671
578
  exports.CHIP_SIZES = CHIP_SIZES;
672
579
  exports.CHIP_TOP_POSITION = CHIP_TOP_POSITION;
@@ -1 +1 @@
1
- {"version":3,"file":"combobox-multi-select.cjs","sources":["../../recipes/comboboxes/combobox_multi_select/combobox_multi_select_constants.js","../../recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue"],"sourcesContent":["export const MULTI_SELECT_SIZES = {\n // Chip has no 'lg' and 'xl' size. So we don't support that in multi-select.\n EXTRA_SMALL: 'xs',\n SMALL: 'sm',\n DEFAULT: 'md',\n};\n\nexport const CHIP_SIZES = {\n xs: 'xs',\n sm: 'xs',\n md: 'sm',\n};\n\nexport const CHIP_TOP_POSITION = {\n xs: 1.4,\n sm: 0.4,\n md: 0.2,\n};\n\nexport default {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n};\n","<template>\n <dt-recipe-combobox-with-popover\n ref=\"comboboxWithPopover\"\n :label=\"label\"\n :show-list=\"showList\"\n :max-height=\"listMaxHeight\"\n :max-width=\"listMaxWidth\"\n :popover-offset=\"popoverOffset\"\n :has-suggestion-list=\"hasSuggestionList\"\n :visually-hidden-close-label=\"visuallyHiddenCloseLabel\"\n :visually-hidden-close=\"visuallyHiddenClose\"\n content-width=\"anchor\"\n :append-to=\"appendTo\"\n :transition=\"transition\"\n @select=\"onComboboxSelect\"\n @highlight=\"comboboxHighlight\"\n >\n <template #input=\"{ onInput }\">\n <span\n ref=\"inputSlotWrapper\"\n class=\"combobox__input-wrapper\"\n @focusin=\"handleInputFocusIn\"\n @focusout=\"handleInputFocusOut\"\n >\n <span\n ref=\"chipsWrapper\"\n :class=\"['combobox__chip-wrapper', chipWrapperClass]\"\n >\n <dt-chip\n v-for=\"({ item, key }) in selectedItemsWithKeys\"\n ref=\"chips\"\n :key=\"key\"\n :label-class=\"['d-chip__label']\"\n class=\"combobox__chip\"\n :close-button-props=\"{ ariaLabel: 'close' }\"\n :size=\"CHIP_SIZES[size]\"\n v-on=\"chipListeners\"\n @keyup.backspace=\"onChipRemove(item)\"\n @close=\"onChipRemove(item)\"\n >\n {{ item }}\n </dt-chip>\n </span>\n\n <dt-input\n ref=\"input\"\n v-model=\"value\"\n class=\"combobox__input\"\n :aria-label=\"label\"\n :label=\"labelVisible ? label : ''\"\n :description=\"description\"\n :placeholder=\"inputPlaceHolder\"\n :show-messages=\"showInputMessages\"\n :messages=\"inputMessages\"\n :size=\"size\"\n v-on=\"inputListeners\"\n @input=\"onInput\"\n />\n\n <dt-validation-messages\n :validation-messages=\"maxSelectedMessage\"\n :show-messages=\"showValidationMessages\"\n />\n </span>\n </template>\n\n <!-- @slot slot for popover header -->\n <template\n v-if=\"$slots.header\"\n #header\n >\n <div ref=\"header\">\n <slot name=\"header\" />\n </div>\n </template>\n\n <!-- @slot slot for popover list -->\n <template #list>\n <div\n ref=\"list\"\n @mousedown.prevent\n >\n <slot\n v-if=\"!loading\"\n name=\"list\"\n />\n <div\n v-else\n class=\"combobox__list--loading\"\n >\n {{ loadingMessage }}\n </div>\n </div>\n </template>\n\n <!-- @slot slot for popover footer -->\n <template\n v-if=\"$slots.footer\"\n #footer\n >\n <div ref=\"footer\">\n <slot name=\"footer\" />\n </div>\n </template>\n </dt-recipe-combobox-with-popover>\n</template>\n\n<script>\n/* eslint-disable max-lines */\nimport DtRecipeComboboxWithPopover from '@/recipes/comboboxes/combobox_with_popover/combobox_with_popover.vue';\nimport DtInput from '@/components/input/input.vue';\nimport DtChip from '@/components/chip/chip.vue';\nimport DtValidationMessages from '@/components/validation_messages/validation_messages.vue';\nimport { validationMessageValidator } from '@/common/validators';\nimport {\n POPOVER_APPEND_TO_VALUES,\n} from '@/components/popover/popover_constants';\nimport {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n} from './combobox_multi_select_constants';\nimport SrOnlyCloseButtonMixin from '@/common/mixins/sr_only_close_button';\nimport { getUniqueString } from '@/common/utils';\n\nexport default {\n name: 'DtRecipeComboboxMultiSelect',\n\n components: {\n DtRecipeComboboxWithPopover,\n DtInput,\n DtChip,\n DtValidationMessages,\n },\n\n mixins: [SrOnlyCloseButtonMixin],\n\n props: {\n /**\n * String to use for the input label.\n */\n label: {\n type: String,\n required: true,\n },\n\n /**\n * Determines visibility of input label.\n * @values true, false\n */\n labelVisible: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Description for the input\n */\n description: {\n type: String,\n default: '',\n },\n\n /**\n * Input placeholder\n */\n placeholder: {\n type: String,\n default: 'Select one or start typing',\n },\n\n /**\n * Input validation messages\n */\n inputMessages: {\n type: Array,\n default: () => [],\n validator: inputMessages => {\n return validationMessageValidator(inputMessages);\n },\n },\n\n /**\n * Show input validation message\n */\n showInputMessages: {\n type: Boolean,\n default: true,\n },\n\n // @TODO: https://dialpad.atlassian.net/browse/DP-52324\n // type: {\n // type: String,\n // values: ['input', 'select'],\n // default: 'select',\n // },\n\n /**\n * Determines if the list is loading\n */\n loading: {\n type: Boolean,\n default: false,\n },\n\n /**\n * The message when the list is loading\n */\n loadingMessage: {\n type: String,\n default: 'loading...',\n },\n\n /**\n * Determines when to show the list element and also controls the aria-expanded attribute.\n * Leaving this null will have the combobox trigger on input focus by default.\n * If you set this value, the default trigger behavior will be disabled and you can\n * control it as you need.\n */\n showList: {\n type: Boolean,\n default: null,\n },\n\n /**\n * Determines maximum height for the popover before overflow.\n * Possible units rem|px|em\n */\n listMaxHeight: {\n type: String,\n default: '300px',\n },\n\n /**\n * The selected items\n */\n selectedItems: {\n type: Array,\n default: function () { return []; },\n },\n\n /**\n * Would be the maximum number of selections you can make. 0 is unlimited\n */\n maxSelected: {\n type: Number,\n default: 0,\n },\n\n /**\n * Max select message when the max selections is exceeded with the structure:\n * `[{\"message\": string, \"type\": VALIDATION_MESSAGE_TYPES }]`\n */\n maxSelectedMessage: {\n type: Array,\n default: function () { return []; },\n },\n\n /**\n * Displays the list when the combobox is focused, before the user has typed anything.\n * When this is enabled the list will not close after selection.\n */\n hasSuggestionList: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Size of the chip, one of `xs`, `sm`, `md`\n */\n size: {\n type: String,\n default: 'md',\n validator: (t) => Object.values(MULTI_SELECT_SIZES).includes(t),\n },\n\n /**\n * Sets the element to which the popover is going to append to.\n * 'body' will append to the nearest body (supports shadow DOM).\n * @values 'body', 'parent', HTMLElement,\n */\n appendTo: {\n type: [HTMLElement, String],\n default: 'body',\n validator: appendTo => {\n return POPOVER_APPEND_TO_VALUES.includes(appendTo) ||\n (appendTo instanceof HTMLElement);\n },\n },\n\n /**\n * Named transition when the content display is toggled.\n * @see DtLazyShow\n */\n transition: {\n type: String,\n default: 'fade',\n },\n\n /**\n * Determines whether the combobox should collapse to a single when losing focus.\n * @type {boolean}\n */\n collapseOnFocusOut: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Determines maximum width for the popover before overflow.\n * Possible units rem|px|em\n */\n listMaxWidth: {\n type: String,\n default: '',\n },\n },\n\n emits: [\n /**\n * Native input event\n *\n * @event input\n * @type {String }\n */\n 'input',\n\n /**\n * Event fired when item selected\n *\n * @event select\n * @type {Number}\n */\n 'select',\n\n /**\n * Event fired when item removed\n *\n * @event remove\n * @type {String}\n */\n 'remove',\n\n /**\n * Event fired when max selected items limit is reached\n *\n * @event max-selected\n * @type {Object}\n */\n 'max-selected',\n\n /**\n * Native keyup event\n *\n * @event keyup\n * @type {KeyboardEvent}\n */\n 'keyup',\n\n /**\n * Event fired when combobox item is highlighted\n *\n * @event combobox-highlight\n * @type {Object}\n */\n 'combobox-highlight',\n ],\n\n data () {\n return {\n value: '',\n popoverOffset: [0, 4],\n showValidationMessages: false,\n resizeWindowObserver: null,\n initialInputHeight: null,\n CHIP_SIZES,\n inputFocused: false,\n };\n },\n\n computed: {\n inputPlaceHolder () {\n return this.selectedItems?.length > 0 ? '' : this.placeholder;\n },\n\n chipListeners () {\n return {\n ...this.$listeners,\n keyup: event => {\n this.onChipKeyup(event);\n this.$emit('keyup', event);\n },\n };\n },\n\n inputListeners () {\n return {\n ...this.$listeners,\n input: event => {\n this.$emit('input', event);\n if (this.hasSuggestionList) {\n this.showComboboxList();\n }\n },\n\n keyup: event => {\n this.onInputKeyup(event);\n this.$emit('keyup', event);\n },\n\n click: event => {\n if (this.hasSuggestionList) {\n this.showComboboxList();\n }\n },\n };\n },\n\n selectedItemsWithKeys () {\n return this.selectedItems.map(selectedItem => ({\n item: selectedItem,\n key: getUniqueString(selectedItem),\n }));\n },\n\n chipWrapperClass () {\n return {\n [`combobox__chip-wrapper-${this.size}--collapsed`]: !this.inputFocused && this.collapseOnFocusOut,\n };\n },\n },\n\n watch: {\n selectedItems: {\n async handler () {\n this.initSelectedItems();\n },\n },\n\n async label () {\n await this.$nextTick();\n // Adjust the chips position if label changed\n this.setChipsTopPosition();\n },\n\n async description () {\n await this.$nextTick();\n // Adjust the chips position if description changed\n this.setChipsTopPosition();\n },\n\n size: {\n async handler () {\n await this.$nextTick();\n const input = this.getInput();\n this.revertInputPadding(input);\n this.initialInputHeight = input.getBoundingClientRect().height;\n this.setInputPadding();\n this.setChipsTopPosition();\n },\n },\n },\n\n mounted () {\n this.setInitialInputHeight();\n // Recalculate chip position and input padding when resizing window\n this.resizeWindowObserver = new ResizeObserver(async () => {\n this.setChipsTopPosition();\n this.setInputPadding();\n });\n this.resizeWindowObserver.observe(document.body);\n\n this.initSelectedItems();\n },\n\n beforeDestroy () {\n this.resizeWindowObserver?.unobserve(document.body);\n },\n\n methods: {\n comboboxHighlight (highlightIndex) {\n this.$emit('combobox-highlight', highlightIndex);\n },\n\n async initSelectedItems () {\n await this.$nextTick();\n this.setInputPadding();\n this.setChipsTopPosition();\n this.setInputMinWidth();\n this.checkMaxSelected();\n },\n\n onChipRemove (item) {\n this.$emit('remove', item);\n this.$refs.input?.focus();\n },\n\n onComboboxSelect (i) {\n this.value = '';\n this.$emit('select', i);\n },\n\n showComboboxList () {\n if (this.showList != null) { return; }\n this.$refs.comboboxWithPopover?.showComboboxList();\n },\n\n closeComboboxList () {\n if (this.showList != null) { return; }\n this.$refs.comboboxWithPopover?.closeComboboxList();\n },\n\n getChipButtons () {\n return this.$refs.chips && this.$refs.chips.map(chip => chip.$el.querySelector('button'));\n },\n\n getChips () {\n return this.$refs.chips && this.$refs.chips.map(chip => chip.$el);\n },\n\n getLastChipButton () {\n return this.$refs.chips && this.getChipButtons()[this.getChipButtons().length - 1];\n },\n\n getLastChip () {\n return this.$refs.chips && this.getChips()[this.getChips().length - 1];\n },\n\n getFirstChip () {\n return this.$refs.chips && this.getChips()[0];\n },\n\n getInput () {\n return this.$refs.input?.$refs.input;\n },\n\n onChipKeyup (event) {\n const key = event.code?.toLowerCase();\n if (key === 'arrowleft') {\n // Move to the previous chip\n this.navigateBetweenChips(event.target, true);\n } else if (key === 'arrowright') {\n if (event.target.id === this.getLastChipButton().id) {\n // Move to the input if it's the last chip\n this.moveFromChipToInput();\n } else {\n // Move to the next chip\n this.navigateBetweenChips(event.target, false);\n }\n }\n },\n\n onInputKeyup (event) {\n const key = event.code?.toLowerCase();\n // If the cursor is at the start of the text,\n // press 'backspace' or 'left' focuses the last chip\n if (this.selectedItems.length > 0 && event.target.selectionStart === 0) {\n if (key === 'backspace' || key === 'arrowleft') {\n this.moveFromInputToChip();\n }\n }\n },\n\n moveFromInputToChip () {\n this.getLastChipButton().focus();\n this.$refs.input?.blur();\n this.closeComboboxList();\n },\n\n moveFromChipToInput () {\n this.getLastChipButton().blur();\n this.$refs.input?.focus();\n this.showComboboxList();\n },\n\n navigateBetweenChips (target, toLeft) {\n const from = this.getChipButtons().indexOf(target);\n const to = toLeft ? from - 1 : from + 1;\n if (to < 0 || to >= this.$refs.chips?.length) {\n return;\n }\n this.getChipButtons()[from].blur();\n this.getChipButtons()[to].focus();\n this.closeComboboxList();\n },\n\n setChipsTopPosition () {\n // To place the chips in the input box\n // The chip \"top\" position should be the same line as the input box\n const input = this.getInput();\n if (!input) return;\n const inputSlotWrapper = this.$refs.inputSlotWrapper;\n const top = input.getBoundingClientRect().top -\n inputSlotWrapper.getBoundingClientRect().top;\n const chipsWrapper = this.$refs.chipsWrapper;\n chipsWrapper.style.top = (top - CHIP_TOP_POSITION[this.size]) + 'px';\n },\n\n setInputPadding () {\n const lastChip = this.getLastChip();\n const input = this.getInput();\n const chipsWrapper = this.$refs.chipsWrapper;\n if (!input) return;\n this.revertInputPadding(input);\n this.popoverOffset = [0, 4];\n if (!lastChip) return;\n // Avoid adding extra padding when the input is not focused if collapseOnFocusOut is true\n // This ensures the input returns to its original state when resizing\n if (this.collapseOnFocusOut && !this.inputFocused) return;\n\n // Get the position of the last chip\n // The input cursor should be the same \"top\" as that chip and next besides it\n const left = lastChip.offsetLeft + this.getFullWidth(lastChip);\n input.style.paddingLeft = left + 'px';\n\n // Get the chip size minus the 4px padding\n const chipsSize = chipsWrapper.getBoundingClientRect().height - 4;\n\n // Get lastChip offsetTop plus 2px of the input padding.\n const top = lastChip.offsetTop + 2;\n\n // Add padding to Top only if the chips need more space\n if (chipsSize > this.initialInputHeight) {\n input.style.paddingTop = `${top}px`;\n }\n },\n\n revertInputPadding (input) {\n input.style.paddingLeft = '';\n input.style.paddingTop = '';\n input.style.paddingBottom = '';\n },\n\n getFullWidth (el) {\n const styles = window.getComputedStyle(el);\n return el.offsetWidth + parseInt(styles.marginLeft) + parseInt(styles.marginRight);\n },\n\n setInputMinWidth () {\n // Ensure the width of the input is \"slightly bigger\" than the width of a single chip\n const firstChip = this.getFirstChip();\n const input = this.getInput();\n if (!input) return;\n if (firstChip) {\n // Add 4px buffer for typing room\n input.style.minWidth = (this.getFullWidth(firstChip) + 4) + 'px';\n } else {\n input.style.minWidth = '';\n }\n },\n\n checkMaxSelected () {\n if (this.maxSelected === 0) return;\n if (this.selectedItems.length > this.maxSelected) {\n this.showValidationMessages = true;\n this.$emit('max-selected');\n } else {\n this.showValidationMessages = false;\n }\n },\n\n setInitialInputHeight () {\n const input = this.getInput();\n if (!input) return;\n this.initialInputHeight = input.getBoundingClientRect().height;\n },\n\n async handleInputFocusIn () {\n this.inputFocused = true;\n if (this.collapseOnFocusOut) {\n await this.$nextTick();\n this.setInputPadding();\n }\n },\n\n async handleInputFocusOut () {\n this.inputFocused = false;\n if (this.collapseOnFocusOut) {\n const input = this.getInput();\n if (!input) return;\n this.revertInputPadding(input);\n }\n },\n },\n};\n</script>\n\n<style scoped lang=\"less\">\n.combobox__input-wrapper {\n position: relative;\n display: block;\n}\n\n.combobox__chip-wrapper {\n position: absolute;\n margin-left: var(--dt-space-200);\n margin-right: var(--dt-space-200);\n padding-left: var(--dt-space-100);\n max-width: calc(var(--dt-size-100-percent) - var(--dt-space-400));\n max-height: initial;\n overflow-y: visible;\n}\n\n.combobox__chip-wrapper-md--collapsed {\n max-height: 2.8rem;\n overflow-y: hidden;\n}\n\n.combobox__chip-wrapper-sm--collapsed,\n.combobox__chip-wrapper-xs--collapsed {\n max-height: 2.5rem;\n overflow-y: hidden;\n}\n\n.combobox__chip {\n margin-top: var(--dt-space-300);\n margin-left: var(--dt-space-200);\n margin-right: var(--dt-space-200);\n z-index: var(--zi-base1);\n max-width: var(--dt-size-100-percent);\n}\n\n.combobox__input {\n flex-grow: 1;\n}\n\n.combobox__list--loading {\n text-align: center;\n padding-top: var(--dt-space-500);\n padding-bottom: var(--dt-space-500);\n}\n</style>\n"],"names":["MULTI_SELECT_SIZES","EXTRA_SMALL","SMALL","DEFAULT","CHIP_SIZES","xs","sm","md","CHIP_TOP_POSITION","_sfc_main","name","components","DtRecipeComboboxWithPopover","DtInput","DtChip","DtValidationMessages","mixins","SrOnlyCloseButtonMixin","props","label","type","String","required","labelVisible","Boolean","default","description","placeholder","inputMessages","Array","validator","validationMessageValidator","showInputMessages","loading","loadingMessage","showList","listMaxHeight","selectedItems","maxSelected","Number","maxSelectedMessage","hasSuggestionList","size","t","Object","values","includes","appendTo","HTMLElement","POPOVER_APPEND_TO_VALUES","transition","collapseOnFocusOut","listMaxWidth","emits","data","value","popoverOffset","showValidationMessages","resizeWindowObserver","initialInputHeight","inputFocused","computed","inputPlaceHolder","length","chipListeners","$listeners","keyup","event","onChipKeyup","$emit","inputListeners","input","showComboboxList","onInputKeyup","click","selectedItemsWithKeys","map","selectedItem","item","key","getUniqueString","chipWrapperClass","watch","handler","initSelectedItems","$nextTick","setChipsTopPosition","getInput","revertInputPadding","getBoundingClientRect","height","setInputPadding","mounted","setInitialInputHeight","ResizeObserver","observe","document","body","beforeDestroy","unobserve","methods","comboboxHighlight","highlightIndex","setInputMinWidth","checkMaxSelected","onChipRemove","$refs","focus","onComboboxSelect","i","comboboxWithPopover","closeComboboxList","getChipButtons","chips","chip","$el","querySelector","getChips","getLastChipButton","getLastChip","getFirstChip","code","toLowerCase","navigateBetweenChips","target","id","moveFromChipToInput","selectionStart","moveFromInputToChip","blur","toLeft","from","indexOf","to","inputSlotWrapper","top","chipsWrapper","style","lastChip","left","offsetLeft","getFullWidth","paddingLeft","chipsSize","offsetTop","paddingTop","paddingBottom","el","styles","window","getComputedStyle","offsetWidth","parseInt","marginLeft","marginRight","firstChip","minWidth","handleInputFocusIn","handleInputFocusOut"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAO,MAAMA,qBAAqB;AAAA;AAAA,EAEhCC,aAAa;AAAA,EACbC,OAAO;AAAA,EACPC,SAAS;AACX;AAEO,MAAMC,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UAAA,KAAAD,cAAA0B,SAAA,KAAAzB,aAAA;AACA,aAAAmB,yBAAA;AACA,aAAAY,MAAA,cAAA;AAAA,MACA,OAAA;AACA,aAAAZ,yBAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEAoC,wBAAA;AACA,YAAAtB,QAAA,KAAAgB;AACA,UAAA,CAAAhB;AAAA;AACA,WAAAZ,qBAAAY,MAAAkB,sBAAA,EAAAC;AAAAA,IACA;AAAA,IAEA,MAAAmE,qBAAA;AACA,WAAAjG,eAAA;AACA,UAAA,KAAAT,oBAAA;AACA,cAAA,KAAAkC;AACA,aAAAM,gBAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,MAAAmE,sBAAA;AACA,WAAAlG,eAAA;AACA,UAAA,KAAAT,oBAAA;AACA,cAAAoB,QAAA,KAAAgB;AACA,YAAA,CAAAhB;AAAA;AACA,aAAAiB,mBAAAjB,KAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"combobox-multi-select.cjs","sources":["../../recipes/comboboxes/combobox_multi_select/combobox_multi_select_constants.js","../../recipes/comboboxes/combobox_multi_select/combobox_multi_select.vue"],"sourcesContent":["export const MULTI_SELECT_SIZES = {\n // Chip has no 'lg' and 'xl' size. So we don't support that in multi-select.\n EXTRA_SMALL: 'xs',\n SMALL: 'sm',\n DEFAULT: 'md',\n};\n\nexport const CHIP_SIZES = {\n xs: 'xs',\n sm: 'xs',\n md: 'sm',\n};\n\nexport const CHIP_TOP_POSITION = {\n xs: 1.4,\n sm: 0.4,\n md: 0.2,\n};\n\nexport default {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n};\n","<template>\n <dt-recipe-combobox-with-popover\n ref=\"comboboxWithPopover\"\n :label=\"label\"\n :show-list=\"showList\"\n :max-height=\"listMaxHeight\"\n :max-width=\"listMaxWidth\"\n :popover-offset=\"popoverOffset\"\n :has-suggestion-list=\"hasSuggestionList\"\n :visually-hidden-close-label=\"visuallyHiddenCloseLabel\"\n :visually-hidden-close=\"visuallyHiddenClose\"\n content-width=\"anchor\"\n :append-to=\"appendTo\"\n :transition=\"transition\"\n @select=\"onComboboxSelect\"\n @highlight=\"comboboxHighlight\"\n >\n <template #input=\"{ onInput }\">\n <span\n ref=\"inputSlotWrapper\"\n class=\"combobox__input-wrapper\"\n @focusin=\"handleInputFocusIn\"\n @focusout=\"handleInputFocusOut\"\n >\n <span\n ref=\"chipsWrapper\"\n :class=\"['combobox__chip-wrapper', chipWrapperClass]\"\n >\n <dt-chip\n v-for=\"({ item, key }) in selectedItemsWithKeys\"\n ref=\"chips\"\n :key=\"key\"\n :label-class=\"['d-chip__label']\"\n class=\"combobox__chip\"\n :close-button-props=\"{ ariaLabel: 'close' }\"\n :size=\"CHIP_SIZES[size]\"\n v-on=\"chipListeners\"\n @keyup.backspace=\"onChipRemove(item)\"\n @close=\"onChipRemove(item)\"\n >\n {{ item }}\n </dt-chip>\n </span>\n\n <dt-input\n ref=\"input\"\n v-model=\"value\"\n class=\"combobox__input\"\n :aria-label=\"label\"\n :label=\"labelVisible ? label : ''\"\n :description=\"description\"\n :placeholder=\"inputPlaceHolder\"\n :show-messages=\"showInputMessages\"\n :messages=\"inputMessages\"\n :size=\"size\"\n v-on=\"inputListeners\"\n @input=\"onInput\"\n />\n\n <dt-validation-messages\n :validation-messages=\"maxSelectedMessage\"\n :show-messages=\"showValidationMessages\"\n />\n </span>\n </template>\n\n <!-- @slot slot for popover header -->\n <template\n v-if=\"$slots.header\"\n #header\n >\n <div ref=\"header\">\n <slot name=\"header\" />\n </div>\n </template>\n\n <!-- @slot slot for popover list -->\n <template #list>\n <div\n ref=\"list\"\n @mousedown.prevent\n >\n <slot\n v-if=\"!loading\"\n name=\"list\"\n />\n <div\n v-else\n class=\"combobox__list--loading\"\n >\n {{ loadingMessage }}\n </div>\n </div>\n </template>\n\n <!-- @slot slot for popover footer -->\n <template\n v-if=\"$slots.footer\"\n #footer\n >\n <div ref=\"footer\">\n <slot name=\"footer\" />\n </div>\n </template>\n </dt-recipe-combobox-with-popover>\n</template>\n\n<script>\n/* eslint-disable max-lines */\nimport DtRecipeComboboxWithPopover from '@/recipes/comboboxes/combobox_with_popover/combobox_with_popover.vue';\nimport DtInput from '@/components/input/input.vue';\nimport DtChip from '@/components/chip/chip.vue';\nimport DtValidationMessages from '@/components/validation_messages/validation_messages.vue';\nimport { validationMessageValidator } from '@/common/validators';\nimport {\n POPOVER_APPEND_TO_VALUES,\n} from '@/components/popover/popover_constants';\nimport {\n MULTI_SELECT_SIZES,\n CHIP_SIZES,\n CHIP_TOP_POSITION,\n} from './combobox_multi_select_constants';\nimport SrOnlyCloseButtonMixin from '@/common/mixins/sr_only_close_button';\nimport { getUniqueString } from '@/common/utils';\n\nexport default {\n name: 'DtRecipeComboboxMultiSelect',\n\n components: {\n DtRecipeComboboxWithPopover,\n DtInput,\n DtChip,\n DtValidationMessages,\n },\n\n mixins: [SrOnlyCloseButtonMixin],\n\n props: {\n /**\n * String to use for the input label.\n */\n label: {\n type: String,\n required: true,\n },\n\n /**\n * Determines visibility of input label.\n * @values true, false\n */\n labelVisible: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Description for the input\n */\n description: {\n type: String,\n default: '',\n },\n\n /**\n * Input placeholder\n */\n placeholder: {\n type: String,\n default: 'Select one or start typing',\n },\n\n /**\n * Input validation messages\n */\n inputMessages: {\n type: Array,\n default: () => [],\n validator: inputMessages => {\n return validationMessageValidator(inputMessages);\n },\n },\n\n /**\n * Show input validation message\n */\n showInputMessages: {\n type: Boolean,\n default: true,\n },\n\n // @TODO: https://dialpad.atlassian.net/browse/DP-52324\n // type: {\n // type: String,\n // values: ['input', 'select'],\n // default: 'select',\n // },\n\n /**\n * Determines if the list is loading\n */\n loading: {\n type: Boolean,\n default: false,\n },\n\n /**\n * The message when the list is loading\n */\n loadingMessage: {\n type: String,\n default: 'loading...',\n },\n\n /**\n * Determines when to show the list element and also controls the aria-expanded attribute.\n * Leaving this null will have the combobox trigger on input focus by default.\n * If you set this value, the default trigger behavior will be disabled and you can\n * control it as you need.\n */\n showList: {\n type: Boolean,\n default: null,\n },\n\n /**\n * Determines maximum height for the popover before overflow.\n * Possible units rem|px|em\n */\n listMaxHeight: {\n type: String,\n default: '300px',\n },\n\n /**\n * The selected items\n */\n selectedItems: {\n type: Array,\n default: function () { return []; },\n },\n\n /**\n * Would be the maximum number of selections you can make. 0 is unlimited\n */\n maxSelected: {\n type: Number,\n default: 0,\n },\n\n /**\n * Max select message when the max selections is exceeded with the structure:\n * `[{\"message\": string, \"type\": VALIDATION_MESSAGE_TYPES }]`\n */\n maxSelectedMessage: {\n type: Array,\n default: function () { return []; },\n },\n\n /**\n * Displays the list when the combobox is focused, before the user has typed anything.\n * When this is enabled the list will not close after selection.\n */\n hasSuggestionList: {\n type: Boolean,\n default: true,\n },\n\n /**\n * Size of the chip, one of `xs`, `sm`, `md`\n */\n size: {\n type: String,\n default: 'md',\n validator: (t) => Object.values(MULTI_SELECT_SIZES).includes(t),\n },\n\n /**\n * Sets the element to which the popover is going to append to.\n * 'body' will append to the nearest body (supports shadow DOM).\n * @values 'body', 'parent', HTMLElement,\n */\n appendTo: {\n type: [HTMLElement, String],\n default: 'body',\n validator: appendTo => {\n return POPOVER_APPEND_TO_VALUES.includes(appendTo) ||\n (appendTo instanceof HTMLElement);\n },\n },\n\n /**\n * Named transition when the content display is toggled.\n * @see DtLazyShow\n */\n transition: {\n type: String,\n default: 'fade',\n },\n\n /**\n * Determines whether the combobox should collapse to a single when losing focus.\n * @type {boolean}\n */\n collapseOnFocusOut: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Determines maximum width for the popover before overflow.\n * Possible units rem|px|em\n */\n listMaxWidth: {\n type: String,\n default: '',\n },\n },\n\n emits: [\n /**\n * Native input event\n *\n * @event input\n * @type {String }\n */\n 'input',\n\n /**\n * Event fired when item selected\n *\n * @event select\n * @type {Number}\n */\n 'select',\n\n /**\n * Event fired when item removed\n *\n * @event remove\n * @type {String}\n */\n 'remove',\n\n /**\n * Event fired when max selected items limit is reached\n *\n * @event max-selected\n * @type {Object}\n */\n 'max-selected',\n\n /**\n * Native keyup event\n *\n * @event keyup\n * @type {KeyboardEvent}\n */\n 'keyup',\n\n /**\n * Event fired when combobox item is highlighted\n *\n * @event combobox-highlight\n * @type {Object}\n */\n 'combobox-highlight',\n ],\n\n data () {\n return {\n value: '',\n popoverOffset: [0, 4],\n showValidationMessages: false,\n resizeWindowObserver: null,\n initialInputHeight: null,\n CHIP_SIZES,\n inputFocused: false,\n };\n },\n\n computed: {\n inputPlaceHolder () {\n return this.selectedItems?.length > 0 ? '' : this.placeholder;\n },\n\n chipListeners () {\n return {\n ...this.$listeners,\n keyup: event => {\n this.onChipKeyup(event);\n this.$emit('keyup', event);\n },\n };\n },\n\n inputListeners () {\n return {\n ...this.$listeners,\n input: event => {\n this.$emit('input', event);\n if (this.hasSuggestionList) {\n this.showComboboxList();\n }\n },\n\n keyup: event => {\n this.onInputKeyup(event);\n this.$emit('keyup', event);\n },\n\n click: event => {\n if (this.hasSuggestionList) {\n this.showComboboxList();\n }\n },\n };\n },\n\n selectedItemsWithKeys () {\n return this.selectedItems.map(selectedItem => ({\n item: selectedItem,\n key: getUniqueString(selectedItem),\n }));\n },\n\n chipWrapperClass () {\n return {\n [`combobox__chip-wrapper-${this.size}--collapsed`]: !this.inputFocused && this.collapseOnFocusOut,\n };\n },\n },\n\n watch: {\n selectedItems: {\n async handler () {\n this.initSelectedItems();\n },\n },\n\n async label () {\n await this.$nextTick();\n // Adjust the chips position if label changed\n this.setChipsTopPosition();\n },\n\n async description () {\n await this.$nextTick();\n // Adjust the chips position if description changed\n this.setChipsTopPosition();\n },\n\n size: {\n async handler () {\n await this.$nextTick();\n const input = this.getInput();\n this.revertInputPadding(input);\n this.initialInputHeight = input.getBoundingClientRect().height;\n this.setInputPadding();\n this.setChipsTopPosition();\n },\n },\n },\n\n mounted () {\n this.setInitialInputHeight();\n // Recalculate chip position and input padding when resizing window\n this.resizeWindowObserver = new ResizeObserver(async () => {\n this.setChipsTopPosition();\n this.setInputPadding();\n });\n this.resizeWindowObserver.observe(document.body);\n\n this.initSelectedItems();\n },\n\n beforeDestroy () {\n this.resizeWindowObserver?.unobserve(document.body);\n },\n\n methods: {\n comboboxHighlight (highlightIndex) {\n this.$emit('combobox-highlight', highlightIndex);\n },\n\n async initSelectedItems () {\n await this.$nextTick();\n this.setInputPadding();\n this.setChipsTopPosition();\n this.setInputMinWidth();\n this.checkMaxSelected();\n },\n\n onChipRemove (item) {\n this.$emit('remove', item);\n this.$refs.input?.focus();\n },\n\n onComboboxSelect (i) {\n this.value = '';\n this.$emit('select', i);\n },\n\n showComboboxList () {\n if (this.showList != null) { return; }\n this.$refs.comboboxWithPopover?.showComboboxList();\n },\n\n closeComboboxList () {\n if (this.showList != null) { return; }\n this.$refs.comboboxWithPopover?.closeComboboxList();\n },\n\n getChipButtons () {\n return this.$refs.chips && this.$refs.chips.map(chip => chip.$el.querySelector('button'));\n },\n\n getChips () {\n return this.$refs.chips && this.$refs.chips.map(chip => chip.$el);\n },\n\n getLastChipButton () {\n return this.$refs.chips && this.getChipButtons()[this.getChipButtons().length - 1];\n },\n\n getLastChip () {\n return this.$refs.chips && this.getChips()[this.getChips().length - 1];\n },\n\n getFirstChip () {\n return this.$refs.chips && this.getChips()[0];\n },\n\n getInput () {\n return this.$refs.input?.$refs.input;\n },\n\n onChipKeyup (event) {\n const key = event.code?.toLowerCase();\n if (key === 'arrowleft') {\n // Move to the previous chip\n this.navigateBetweenChips(event.target, true);\n } else if (key === 'arrowright') {\n if (event.target.id === this.getLastChipButton().id) {\n // Move to the input if it's the last chip\n this.moveFromChipToInput();\n } else {\n // Move to the next chip\n this.navigateBetweenChips(event.target, false);\n }\n }\n },\n\n onInputKeyup (event) {\n const key = event.code?.toLowerCase();\n // If the cursor is at the start of the text,\n // press 'backspace' or 'left' focuses the last chip\n if (this.selectedItems.length > 0 && event.target.selectionStart === 0) {\n if (key === 'backspace' || key === 'arrowleft') {\n this.moveFromInputToChip();\n }\n }\n },\n\n moveFromInputToChip () {\n this.getLastChipButton().focus();\n this.$refs.input?.blur();\n this.closeComboboxList();\n },\n\n moveFromChipToInput () {\n this.getLastChipButton().blur();\n this.$refs.input?.focus();\n this.showComboboxList();\n },\n\n navigateBetweenChips (target, toLeft) {\n const from = this.getChipButtons().indexOf(target);\n const to = toLeft ? from - 1 : from + 1;\n if (to < 0 || to >= this.$refs.chips?.length) {\n return;\n }\n this.getChipButtons()[from].blur();\n this.getChipButtons()[to].focus();\n this.closeComboboxList();\n },\n\n setChipsTopPosition () {\n // To place the chips in the input box\n // The chip \"top\" position should be the same line as the input box\n const input = this.getInput();\n if (!input) return;\n const inputSlotWrapper = this.$refs.inputSlotWrapper;\n const top = input.getBoundingClientRect().top -\n inputSlotWrapper.getBoundingClientRect().top;\n const chipsWrapper = this.$refs.chipsWrapper;\n chipsWrapper.style.top = (top - CHIP_TOP_POSITION[this.size]) + 'px';\n },\n\n setInputPadding () {\n const lastChip = this.getLastChip();\n const input = this.getInput();\n const chipsWrapper = this.$refs.chipsWrapper;\n if (!input) return;\n this.revertInputPadding(input);\n this.popoverOffset = [0, 4];\n if (!lastChip) return;\n // Avoid adding extra padding when the input is not focused if collapseOnFocusOut is true\n // This ensures the input returns to its original state when resizing\n if (this.collapseOnFocusOut && !this.inputFocused) return;\n\n // Get the position of the last chip\n // The input cursor should be the same \"top\" as that chip and next besides it\n const left = lastChip.offsetLeft + this.getFullWidth(lastChip);\n input.style.paddingLeft = left + 'px';\n\n // Get the chip size minus the 4px padding\n const chipsSize = chipsWrapper.getBoundingClientRect().height - 4;\n\n // Get lastChip offsetTop plus 2px of the input padding.\n const top = lastChip.offsetTop + 2;\n\n // Add padding to Top only if the chips need more space\n if (chipsSize > this.initialInputHeight) {\n input.style.paddingTop = `${top}px`;\n }\n },\n\n revertInputPadding (input) {\n input.style.paddingLeft = '';\n input.style.paddingTop = '';\n input.style.paddingBottom = '';\n },\n\n getFullWidth (el) {\n const styles = window.getComputedStyle(el);\n return el.offsetWidth + parseInt(styles.marginLeft) + parseInt(styles.marginRight);\n },\n\n setInputMinWidth () {\n // Ensure the width of the input is \"slightly bigger\" than the width of a single chip\n const firstChip = this.getFirstChip();\n const input = this.getInput();\n if (!input) return;\n if (firstChip) {\n // Add 4px buffer for typing room\n input.style.minWidth = (this.getFullWidth(firstChip) + 4) + 'px';\n } else {\n input.style.minWidth = '';\n }\n },\n\n checkMaxSelected () {\n if (this.maxSelected === 0) return;\n if (this.selectedItems.length > this.maxSelected) {\n this.showValidationMessages = true;\n this.$emit('max-selected');\n } else {\n this.showValidationMessages = false;\n }\n },\n\n setInitialInputHeight () {\n const input = this.getInput();\n if (!input) return;\n this.initialInputHeight = input.getBoundingClientRect().height;\n },\n\n async handleInputFocusIn () {\n this.inputFocused = true;\n if (this.collapseOnFocusOut) {\n await this.$nextTick();\n this.setInputPadding();\n }\n },\n\n async handleInputFocusOut () {\n this.inputFocused = false;\n if (this.collapseOnFocusOut) {\n const input = this.getInput();\n if (!input) return;\n this.revertInputPadding(input);\n }\n },\n },\n};\n</script>\n\n<style scoped lang=\"less\">\n.combobox__input-wrapper {\n position: relative;\n display: block;\n}\n\n.combobox__chip-wrapper {\n position: absolute;\n margin-left: var(--dt-space-200);\n margin-right: var(--dt-space-200);\n padding-left: var(--dt-space-100);\n max-width: calc(var(--dt-size-100-percent) - var(--dt-space-400));\n max-height: initial;\n overflow-y: visible;\n}\n\n.combobox__chip-wrapper-md--collapsed {\n max-height: 2.8rem;\n overflow-y: hidden;\n}\n\n.combobox__chip-wrapper-sm--collapsed,\n.combobox__chip-wrapper-xs--collapsed {\n max-height: 2.5rem;\n overflow-y: hidden;\n}\n\n.combobox__chip {\n margin-top: var(--dt-space-300);\n margin-left: var(--dt-space-200);\n margin-right: var(--dt-space-200);\n z-index: var(--zi-base1);\n max-width: var(--dt-size-100-percent);\n}\n\n.combobox__input {\n flex-grow: 1;\n}\n\n.combobox__list--loading {\n text-align: center;\n padding-top: var(--dt-space-500);\n padding-bottom: var(--dt-space-500);\n}\n</style>\n"],"names":["DtRecipeComboboxWithPopover","DtInput","DtChip","DtValidationMessages","SrOnlyCloseButtonMixin","validationMessageValidator","POPOVER_APPEND_TO_VALUES","getUniqueString"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAY,MAAC,qBAAqB;AAAA;AAAA,EAEhC,aAAa;AAAA,EACb,OAAO;AAAA,EACP,SAAS;AACX;AAEY,MAAC,aAAa;AAAA,EACxB,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AACN;AAEY,MAAC,oBAAoB;AAAA,EAC/B,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AACN;AC4GA,MAAA,YAAA;AAAA,EACA,MAAA;AAAA,EAEA,YAAA;AAAA,IACA,6BAAAA,wBAAA;AAAA,IACA,SAAAC,UAAA;AAAA,IACA,QAAAC,SAAA;AAAA,IACA,sBAAAC,uBAAA;AAAA,EACA;AAAA,EAEA,QAAA,CAAAC,qBAAAA,sBAAA;AAAA,EAEA,OAAA;AAAA;AAAA;AAAA;AAAA,IAIA,OAAA;AAAA,MACA,MAAA;AAAA,MACA,UAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA;AAAA,IAMA,cAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,aAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,aAAA;AAAA,MACA,MAAA;AAAA,MACA,SAAA;AAAA,IACA;AAAA;AAAA;AAAA;AAAA,IAKA,eAAA;AAAA,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BAAA,MAAA,sBAAA,EAAA;AAAA,IACA;AAAA,IAEA,MAAA,qBAAA;AACA,WAAA,eAAA;AACA,UAAA,KAAA,oBAAA;AACA,cAAA,KAAA;AACA,aAAA,gBAAA;AAAA,MACA;AAAA,IACA;AAAA,IAEA,MAAA,sBAAA;AACA,WAAA,eAAA;AACA,UAAA,KAAA,oBAAA;AACA,cAAA,QAAA,KAAA;AACA,YAAA,CAAA;AAAA;AACA,aAAA,mBAAA,KAAA;AAAA,MACA;AAAA,IACA;AAAA,EACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -3,31 +3,31 @@ import { DtInput } from "./input.js";
3
3
  import { DtChip } from "./chip.js";
4
4
  import { DtValidationMessages } from "./validation-messages.js";
5
5
  import { validationMessageValidator } from "../common/validators.js";
6
- import { POPOVER_APPEND_TO_VALUES } from "../chunks/popover_constants-6YkPPbnk.js";
7
- import { SrOnlyCloseButtonMixin } from "../chunks/sr_only_close_button-IjMVfBDE.js";
6
+ import { POPOVER_APPEND_TO_VALUES } from "../chunks/popover_constants-WsOUIY-m.js";
7
+ import { SrOnlyCloseButtonMixin } from "../chunks/sr_only_close_button-81bHIpPu.js";
8
8
  import { getUniqueString } from "../common/utils.js";
9
9
  import { normalizeComponent } from "../chunks/_plugin-vue2_normalizer-sOSkiPF3.js";
10
- import "../chunks/index-mBWay1Qb.js";
11
- import "../chunks/keyboard_list_navigation-YIqTuw1W.js";
10
+ import "../chunks/index-eJ-WWRdf.js";
11
+ import "../chunks/keyboard_list_navigation-ScXhrxya.js";
12
12
  import "./list-item.js";
13
13
  import "../chunks/list_item_constants-u1xcN9Dd.js";
14
14
  import "./item-layout.js";
15
15
  import "./icon.js";
16
16
  import "@dialpad/dialtone-icons/vue2";
17
- import "../chunks/icon_constants-TdxqLsS2.js";
17
+ import "../chunks/icon_constants-Dy4MEUJL.js";
18
18
  import "@dialpad/dialtone-icons/icons.json";
19
19
  import "../common/constants.js";
20
20
  import "vue";
21
21
  import "./skeleton.js";
22
22
  import "./popover.js";
23
23
  import "@linusborg/vue-simple-portal";
24
- import "../chunks/modal-8X6poIZW.js";
24
+ import "../chunks/modal-XOr4kiNZ.js";
25
25
  import "./button.js";
26
26
  import "../chunks/link_constants-AfTWrr-n.js";
27
27
  import "./lazy-show.js";
28
28
  import "tippy.js";
29
29
  import "../chunks/dropdown_constants-w1MXGC3Z.js";
30
- import "../chunks/input-PhJeBN6r.js";
30
+ import "../chunks/input-6kbd8Pju.js";
31
31
  const MULTI_SELECT_SIZES = {
32
32
  // Chip has no 'lg' and 'xl' size. So we don't support that in multi-select.
33
33
  EXTRA_SMALL: "xs",
@@ -539,132 +539,39 @@ const _sfc_main = {
539
539
  };
540
540
  var _sfc_render = function render() {
541
541
  var _vm = this, _c = _vm._self._c;
542
- return _c("dt-recipe-combobox-with-popover", {
543
- ref: "comboboxWithPopover",
544
- attrs: {
545
- "label": _vm.label,
546
- "show-list": _vm.showList,
547
- "max-height": _vm.listMaxHeight,
548
- "max-width": _vm.listMaxWidth,
549
- "popover-offset": _vm.popoverOffset,
550
- "has-suggestion-list": _vm.hasSuggestionList,
551
- "visually-hidden-close-label": _vm.visuallyHiddenCloseLabel,
552
- "visually-hidden-close": _vm.visuallyHiddenClose,
553
- "content-width": "anchor",
554
- "append-to": _vm.appendTo,
555
- "transition": _vm.transition
556
- },
557
- on: {
558
- "select": _vm.onComboboxSelect,
559
- "highlight": _vm.comboboxHighlight
560
- },
561
- scopedSlots: _vm._u([{
562
- key: "input",
563
- fn: function({
564
- onInput
565
- }) {
566
- return [_c("span", {
567
- ref: "inputSlotWrapper",
568
- staticClass: "combobox__input-wrapper",
569
- on: {
570
- "focusin": _vm.handleInputFocusIn,
571
- "focusout": _vm.handleInputFocusOut
572
- }
573
- }, [_c("span", {
574
- ref: "chipsWrapper",
575
- class: ["combobox__chip-wrapper", _vm.chipWrapperClass]
576
- }, _vm._l(_vm.selectedItemsWithKeys, function({
577
- item,
578
- key
579
- }) {
580
- return _c("dt-chip", _vm._g({
581
- key,
582
- ref: "chips",
583
- refInFor: true,
584
- staticClass: "combobox__chip",
585
- attrs: {
586
- "label-class": ["d-chip__label"],
587
- "close-button-props": {
588
- ariaLabel: "close"
589
- },
590
- "size": _vm.CHIP_SIZES[_vm.size]
591
- },
592
- on: {
593
- "keyup": function($event) {
594
- if (!$event.type.indexOf("key") && _vm._k($event.keyCode, "backspace", void 0, $event.key, void 0))
595
- return null;
596
- return _vm.onChipRemove(item);
597
- },
598
- "close": function($event) {
599
- return _vm.onChipRemove(item);
600
- }
601
- }
602
- }, _vm.chipListeners), [_vm._v(" " + _vm._s(item) + " ")]);
603
- }), 1), _c("dt-input", _vm._g({
604
- ref: "input",
605
- staticClass: "combobox__input",
606
- attrs: {
607
- "aria-label": _vm.label,
608
- "label": _vm.labelVisible ? _vm.label : "",
609
- "description": _vm.description,
610
- "placeholder": _vm.inputPlaceHolder,
611
- "show-messages": _vm.showInputMessages,
612
- "messages": _vm.inputMessages,
613
- "size": _vm.size
614
- },
615
- on: {
616
- "input": onInput
617
- },
618
- model: {
619
- value: _vm.value,
620
- callback: function($$v) {
621
- _vm.value = $$v;
622
- },
623
- expression: "value"
624
- }
625
- }, _vm.inputListeners)), _c("dt-validation-messages", {
626
- attrs: {
627
- "validation-messages": _vm.maxSelectedMessage,
628
- "show-messages": _vm.showValidationMessages
629
- }
630
- })], 1)];
631
- }
632
- }, _vm.$slots.header ? {
633
- key: "header",
634
- fn: function() {
635
- return [_c("div", {
636
- ref: "header"
637
- }, [_vm._t("header")], 2)];
638
- },
639
- proxy: true
640
- } : null, {
641
- key: "list",
642
- fn: function() {
643
- return [_c("div", {
644
- ref: "list",
645
- on: {
646
- "mousedown": function($event) {
647
- $event.preventDefault();
648
- }
649
- }
650
- }, [!_vm.loading ? _vm._t("list") : _c("div", {
651
- staticClass: "combobox__list--loading"
652
- }, [_vm._v(" " + _vm._s(_vm.loadingMessage) + " ")])], 2)];
653
- },
654
- proxy: true
655
- }, _vm.$slots.footer ? {
656
- key: "footer",
657
- fn: function() {
658
- return [_c("div", {
659
- ref: "footer"
660
- }, [_vm._t("footer")], 2)];
661
- },
662
- proxy: true
663
- } : null], null, true)
664
- });
542
+ return _c("dt-recipe-combobox-with-popover", { ref: "comboboxWithPopover", attrs: { "label": _vm.label, "show-list": _vm.showList, "max-height": _vm.listMaxHeight, "max-width": _vm.listMaxWidth, "popover-offset": _vm.popoverOffset, "has-suggestion-list": _vm.hasSuggestionList, "visually-hidden-close-label": _vm.visuallyHiddenCloseLabel, "visually-hidden-close": _vm.visuallyHiddenClose, "content-width": "anchor", "append-to": _vm.appendTo, "transition": _vm.transition }, on: { "select": _vm.onComboboxSelect, "highlight": _vm.comboboxHighlight }, scopedSlots: _vm._u([{ key: "input", fn: function({ onInput }) {
543
+ return [_c("span", { ref: "inputSlotWrapper", staticClass: "combobox__input-wrapper", on: { "focusin": _vm.handleInputFocusIn, "focusout": _vm.handleInputFocusOut } }, [_c("span", { ref: "chipsWrapper", class: ["combobox__chip-wrapper", _vm.chipWrapperClass] }, _vm._l(_vm.selectedItemsWithKeys, function({ item, key }) {
544
+ return _c("dt-chip", _vm._g({ key, ref: "chips", refInFor: true, staticClass: "combobox__chip", attrs: { "label-class": ["d-chip__label"], "close-button-props": { ariaLabel: "close" }, "size": _vm.CHIP_SIZES[_vm.size] }, on: { "keyup": function($event) {
545
+ if (!$event.type.indexOf("key") && _vm._k($event.keyCode, "backspace", void 0, $event.key, void 0))
546
+ return null;
547
+ return _vm.onChipRemove(item);
548
+ }, "close": function($event) {
549
+ return _vm.onChipRemove(item);
550
+ } } }, _vm.chipListeners), [_vm._v(" " + _vm._s(item) + " ")]);
551
+ }), 1), _c("dt-input", _vm._g({ ref: "input", staticClass: "combobox__input", attrs: { "aria-label": _vm.label, "label": _vm.labelVisible ? _vm.label : "", "description": _vm.description, "placeholder": _vm.inputPlaceHolder, "show-messages": _vm.showInputMessages, "messages": _vm.inputMessages, "size": _vm.size }, on: { "input": onInput }, model: { value: _vm.value, callback: function($$v) {
552
+ _vm.value = $$v;
553
+ }, expression: "value" } }, _vm.inputListeners)), _c("dt-validation-messages", { attrs: { "validation-messages": _vm.maxSelectedMessage, "show-messages": _vm.showValidationMessages } })], 1)];
554
+ } }, _vm.$slots.header ? { key: "header", fn: function() {
555
+ return [_c("div", { ref: "header" }, [_vm._t("header")], 2)];
556
+ }, proxy: true } : null, { key: "list", fn: function() {
557
+ return [_c("div", { ref: "list", on: { "mousedown": function($event) {
558
+ $event.preventDefault();
559
+ } } }, [!_vm.loading ? _vm._t("list") : _c("div", { staticClass: "combobox__list--loading" }, [_vm._v(" " + _vm._s(_vm.loadingMessage) + " ")])], 2)];
560
+ }, proxy: true }, _vm.$slots.footer ? { key: "footer", fn: function() {
561
+ return [_c("div", { ref: "footer" }, [_vm._t("footer")], 2)];
562
+ }, proxy: true } : null], null, true) });
665
563
  };
666
564
  var _sfc_staticRenderFns = [];
667
- var __component__ = /* @__PURE__ */ normalizeComponent(_sfc_main, _sfc_render, _sfc_staticRenderFns, false, null, "e9045f30", null, null);
565
+ var __component__ = /* @__PURE__ */ normalizeComponent(
566
+ _sfc_main,
567
+ _sfc_render,
568
+ _sfc_staticRenderFns,
569
+ false,
570
+ null,
571
+ "e9045f30",
572
+ null,
573
+ null
574
+ );
668
575
  const combobox_multi_select = __component__.exports;
669
576
  export {
670
577
  CHIP_SIZES,