@gitlab/ui 92.1.1 → 92.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (449) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/bin/migrate_custom_utils_to_tw.bundled.mjs +11 -3
  3. package/dist/components/experimental/duo/chat/components/duo_chat_context/duo_chat_context_item_popover/duo_chat_context_item_popover.js +29 -1
  4. package/dist/components/experimental/duo/chat/components/duo_chat_context/duo_chat_context_item_selections/duo_chat_context_item_selections.js +18 -1
  5. package/dist/components/experimental/duo/chat/components/duo_chat_message/duo_chat_message.js +4 -6
  6. package/dist/components/experimental/duo/chat/constants.js +2 -1
  7. package/dist/index.css +4 -2
  8. package/dist/index.css.map +1 -1
  9. package/dist/tailwind.css +1 -1
  10. package/dist/tailwind.css.map +1 -1
  11. package/dist/vendor/bootstrap-vue/src/components/form/index.js +0 -4
  12. package/dist/vendor/bootstrap-vue/src/components/index.js +0 -48
  13. package/dist/vendor/bootstrap-vue/src/components/layout/index.js +0 -6
  14. package/dist/vendor/bootstrap-vue/src/components/nav/index.js +0 -6
  15. package/dist/vendor/bootstrap-vue/src/components/navbar/index.js +1 -8
  16. package/dist/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-tooltip.js +2 -6
  17. package/dist/vendor/bootstrap-vue/src/constants/classes.js +1 -2
  18. package/dist/vendor/bootstrap-vue/src/constants/components.js +1 -51
  19. package/dist/vendor/bootstrap-vue/src/constants/events.js +1 -12
  20. package/dist/vendor/bootstrap-vue/src/constants/key-codes.js +1 -5
  21. package/dist/vendor/bootstrap-vue/src/constants/props.js +1 -4
  22. package/dist/vendor/bootstrap-vue/src/constants/regex.js +1 -20
  23. package/dist/vendor/bootstrap-vue/src/constants/slots.js +1 -33
  24. package/dist/vendor/bootstrap-vue/src/directives/toggle/toggle.js +1 -1
  25. package/dist/vendor/bootstrap-vue/src/index.js +0 -74
  26. package/dist/vendor/bootstrap-vue/src/utils/array.js +1 -3
  27. package/dist/vendor/bootstrap-vue/src/utils/inspect.js +1 -3
  28. package/dist/vendor/bootstrap-vue/src/utils/math.js +1 -3
  29. package/dist/vendor/bootstrap-vue/src/utils/object.js +1 -6
  30. package/dist/vendor/bootstrap-vue/src/utils/props.js +2 -8
  31. package/dist/vendor/bootstrap-vue/src/utils/string.js +1 -10
  32. package/package.json +1 -1
  33. package/src/components/base/accordion/accordion_item.scss +3 -3
  34. package/src/components/base/alert/alert.scss +3 -3
  35. package/src/components/base/avatar_labeled/avatar_labeled.scss +2 -2
  36. package/src/components/base/avatars_inline/avatars_inline.scss +1 -1
  37. package/src/components/base/badge/badge.scss +2 -2
  38. package/src/components/base/banner/banner.scss +2 -2
  39. package/src/components/base/breadcrumb/breadcrumb.scss +3 -3
  40. package/src/components/base/broadcast_message/broadcast_message.scss +3 -3
  41. package/src/components/base/button/button.scss +26 -16
  42. package/src/components/base/card/card.scss +1 -1
  43. package/src/components/base/datepicker/datepicker.scss +10 -10
  44. package/src/components/base/drawer/drawer.scss +5 -5
  45. package/src/components/base/dropdown/dropdown.scss +28 -28
  46. package/src/components/base/dropdown/dropdown_divider.scss +3 -3
  47. package/src/components/base/dropdown/dropdown_item.scss +9 -9
  48. package/src/components/base/dropdown/dropdown_section_header.scss +2 -2
  49. package/src/components/base/dropdown/dropdown_text.scss +1 -1
  50. package/src/components/base/filtered_search/filtered_search.scss +7 -7
  51. package/src/components/base/filtered_search/filtered_search_suggestion.scss +1 -1
  52. package/src/components/base/filtered_search/filtered_search_suggestion_list.scss +3 -3
  53. package/src/components/base/filtered_search/filtered_search_term.scss +2 -2
  54. package/src/components/base/filtered_search/filtered_search_token.scss +4 -4
  55. package/src/components/base/filtered_search/filtered_search_token_segment.scss +2 -2
  56. package/src/components/base/form/form_checkbox/form_checkbox.scss +10 -10
  57. package/src/components/base/form/form_group/form_group.scss +5 -5
  58. package/src/components/base/form/form_input/form_input.scss +2 -2
  59. package/src/components/base/form/form_select/form_select.scss +2 -2
  60. package/src/components/base/keyset_pagination/keyset_pagination.scss +1 -1
  61. package/src/components/base/label/label.scss +1 -1
  62. package/src/components/base/loading_icon/loading_icon.scss +1 -1
  63. package/src/components/base/markdown/markdown.scss +33 -33
  64. package/src/components/base/modal/modal.scss +11 -11
  65. package/src/components/base/new_dropdowns/dropdown.scss +14 -14
  66. package/src/components/base/new_dropdowns/dropdown_item.scss +9 -9
  67. package/src/components/base/new_dropdowns/listbox/listbox.scss +1 -1
  68. package/src/components/base/pagination/pagination.scss +3 -3
  69. package/src/components/base/path/path.scss +5 -5
  70. package/src/components/base/popover/popover.scss +5 -5
  71. package/src/components/base/search_box_by_click/search_box_by_click.scss +2 -2
  72. package/src/components/base/search_box_by_type/search_box_by_type.scss +4 -4
  73. package/src/components/base/table/table.scss +4 -4
  74. package/src/components/base/tabs/tabs/tabs.scss +10 -10
  75. package/src/components/base/toast/toast.scss +7 -7
  76. package/src/components/base/toggle/toggle.scss +6 -6
  77. package/src/components/base/token/token.scss +5 -5
  78. package/src/components/base/tooltip/tooltip.scss +3 -3
  79. package/src/components/charts/legend/legend.scss +4 -4
  80. package/src/components/charts/series_label/series_label.scss +1 -1
  81. package/src/components/experimental/duo/chat/components/duo_chat_context/duo_chat_context_item_popover/duo_chat_context_item_popover.vue +62 -30
  82. package/src/components/experimental/duo/chat/components/duo_chat_context/duo_chat_context_item_selections/duo_chat_context_item_selections.vue +29 -10
  83. package/src/components/experimental/duo/chat/components/duo_chat_message/duo_chat_message.scss +1 -1
  84. package/src/components/experimental/duo/chat/components/duo_chat_message/duo_chat_message.vue +11 -6
  85. package/src/components/experimental/duo/chat/constants.js +2 -0
  86. package/src/components/experimental/duo/chat/duo_chat.scss +4 -4
  87. package/src/components/shared_components/charts/tooltip_default_format.scss +1 -1
  88. package/src/scss/bootstrap_vue.scss +0 -18
  89. package/src/scss/typescale/_index.scss +9 -9
  90. package/src/vendor/bootstrap-vue/nuxt/index.js +0 -8
  91. package/src/vendor/bootstrap-vue/src/_utilities.scss +0 -9
  92. package/src/vendor/bootstrap-vue/src/_variables.scss +0 -52
  93. package/src/vendor/bootstrap-vue/src/components/form/index.d.ts +0 -3
  94. package/src/vendor/bootstrap-vue/src/components/form/index.js +1 -4
  95. package/src/vendor/bootstrap-vue/src/components/form/package.json +0 -12
  96. package/src/vendor/bootstrap-vue/src/components/index.d.ts +0 -24
  97. package/src/vendor/bootstrap-vue/src/components/index.js +0 -48
  98. package/src/vendor/bootstrap-vue/src/components/index.scss +0 -15
  99. package/src/vendor/bootstrap-vue/src/components/layout/index.d.ts +0 -6
  100. package/src/vendor/bootstrap-vue/src/components/layout/index.js +1 -5
  101. package/src/vendor/bootstrap-vue/src/components/layout/package.json +0 -67
  102. package/src/vendor/bootstrap-vue/src/components/modal/README.md +0 -1
  103. package/src/vendor/bootstrap-vue/src/components/nav/index.d.ts +0 -6
  104. package/src/vendor/bootstrap-vue/src/components/nav/index.js +1 -5
  105. package/src/vendor/bootstrap-vue/src/components/nav/package.json +0 -45
  106. package/src/vendor/bootstrap-vue/src/components/navbar/README.md +0 -5
  107. package/src/vendor/bootstrap-vue/src/components/navbar/index.d.ts +1 -7
  108. package/src/vendor/bootstrap-vue/src/components/navbar/index.js +2 -7
  109. package/src/vendor/bootstrap-vue/src/components/navbar/package.json +0 -75
  110. package/src/vendor/bootstrap-vue/src/components/table/README.md +1 -2
  111. package/src/vendor/bootstrap-vue/src/components/tabs/README.md +2 -2
  112. package/src/vendor/bootstrap-vue/src/components/toast/README.md +1 -3
  113. package/src/vendor/bootstrap-vue/src/components/tooltip/helpers/bv-tooltip.js +2 -6
  114. package/src/vendor/bootstrap-vue/src/constants/classes.js +0 -1
  115. package/src/vendor/bootstrap-vue/src/constants/components.js +0 -50
  116. package/src/vendor/bootstrap-vue/src/constants/events.js +0 -11
  117. package/src/vendor/bootstrap-vue/src/constants/key-codes.js +0 -4
  118. package/src/vendor/bootstrap-vue/src/constants/props.js +0 -3
  119. package/src/vendor/bootstrap-vue/src/constants/regex.js +0 -19
  120. package/src/vendor/bootstrap-vue/src/constants/slots.js +0 -32
  121. package/src/vendor/bootstrap-vue/src/directives/toggle/README.md +5 -23
  122. package/src/vendor/bootstrap-vue/src/directives/toggle/package.json +1 -1
  123. package/src/vendor/bootstrap-vue/src/directives/toggle/toggle.js +1 -1
  124. package/src/vendor/bootstrap-vue/src/index.js +0 -122
  125. package/src/vendor/bootstrap-vue/src/index.scss +0 -3
  126. package/src/vendor/bootstrap-vue/src/utils/array.js +0 -5
  127. package/src/vendor/bootstrap-vue/src/utils/config.spec.js +15 -15
  128. package/src/vendor/bootstrap-vue/src/utils/inspect.js +0 -4
  129. package/src/vendor/bootstrap-vue/src/utils/math.js +0 -4
  130. package/src/vendor/bootstrap-vue/src/utils/object.js +0 -5
  131. package/src/vendor/bootstrap-vue/src/utils/props.js +1 -7
  132. package/src/vendor/bootstrap-vue/src/utils/string.js +0 -9
  133. package/src/vendor/bootstrap-vue/src/utils/string.spec.js +1 -20
  134. package/translations.js +3 -0
  135. package/dist/vendor/bootstrap-vue/src/components/alert/alert.js +0 -179
  136. package/dist/vendor/bootstrap-vue/src/components/alert/index.js +0 -11
  137. package/dist/vendor/bootstrap-vue/src/components/aspect/aspect.js +0 -67
  138. package/dist/vendor/bootstrap-vue/src/components/aspect/index.js +0 -11
  139. package/dist/vendor/bootstrap-vue/src/components/avatar/avatar-group.js +0 -67
  140. package/dist/vendor/bootstrap-vue/src/components/avatar/avatar.js +0 -266
  141. package/dist/vendor/bootstrap-vue/src/components/avatar/index.js +0 -14
  142. package/dist/vendor/bootstrap-vue/src/components/button-toolbar/button-toolbar.js +0 -112
  143. package/dist/vendor/bootstrap-vue/src/components/button-toolbar/index.js +0 -12
  144. package/dist/vendor/bootstrap-vue/src/components/calendar/calendar.js +0 -1010
  145. package/dist/vendor/bootstrap-vue/src/components/calendar/index.js +0 -11
  146. package/dist/vendor/bootstrap-vue/src/components/card/card-body.js +0 -63
  147. package/dist/vendor/bootstrap-vue/src/components/card/card-footer.js +0 -48
  148. package/dist/vendor/bootstrap-vue/src/components/card/card-group.js +0 -33
  149. package/dist/vendor/bootstrap-vue/src/components/card/card-header.js +0 -48
  150. package/dist/vendor/bootstrap-vue/src/components/card/card-img-lazy.js +0 -46
  151. package/dist/vendor/bootstrap-vue/src/components/card/card-img.js +0 -58
  152. package/dist/vendor/bootstrap-vue/src/components/card/card-sub-title.js +0 -35
  153. package/dist/vendor/bootstrap-vue/src/components/card/card-text.js +0 -31
  154. package/dist/vendor/bootstrap-vue/src/components/card/card-title.js +0 -33
  155. package/dist/vendor/bootstrap-vue/src/components/card/card.js +0 -123
  156. package/dist/vendor/bootstrap-vue/src/components/card/index.js +0 -38
  157. package/dist/vendor/bootstrap-vue/src/components/embed/embed.js +0 -50
  158. package/dist/vendor/bootstrap-vue/src/components/embed/index.js +0 -11
  159. package/dist/vendor/bootstrap-vue/src/components/form/form-datalist.js +0 -52
  160. package/dist/vendor/bootstrap-vue/src/components/form-btn-label-control/bv-form-btn-label-control.js +0 -261
  161. package/dist/vendor/bootstrap-vue/src/components/form-datepicker/form-datepicker.js +0 -310
  162. package/dist/vendor/bootstrap-vue/src/components/form-datepicker/index.js +0 -12
  163. package/dist/vendor/bootstrap-vue/src/components/form-file/form-file.js +0 -561
  164. package/dist/vendor/bootstrap-vue/src/components/form-file/index.js +0 -12
  165. package/dist/vendor/bootstrap-vue/src/components/form-rating/form-rating.js +0 -402
  166. package/dist/vendor/bootstrap-vue/src/components/form-rating/index.js +0 -12
  167. package/dist/vendor/bootstrap-vue/src/components/form-spinbutton/form-spinbutton.js +0 -555
  168. package/dist/vendor/bootstrap-vue/src/components/form-spinbutton/index.js +0 -12
  169. package/dist/vendor/bootstrap-vue/src/components/form-tags/form-tag.js +0 -97
  170. package/dist/vendor/bootstrap-vue/src/components/form-tags/form-tags.js +0 -806
  171. package/dist/vendor/bootstrap-vue/src/components/form-tags/index.js +0 -16
  172. package/dist/vendor/bootstrap-vue/src/components/form-timepicker/form-timepicker.js +0 -281
  173. package/dist/vendor/bootstrap-vue/src/components/form-timepicker/index.js +0 -12
  174. package/dist/vendor/bootstrap-vue/src/components/image/img-lazy.js +0 -157
  175. package/dist/vendor/bootstrap-vue/src/components/image/img.js +0 -124
  176. package/dist/vendor/bootstrap-vue/src/components/image/index.js +0 -14
  177. package/dist/vendor/bootstrap-vue/src/components/jumbotron/index.js +0 -11
  178. package/dist/vendor/bootstrap-vue/src/components/jumbotron/jumbotron.js +0 -98
  179. package/dist/vendor/bootstrap-vue/src/components/layout/container.js +0 -41
  180. package/dist/vendor/bootstrap-vue/src/components/layout/row.js +0 -113
  181. package/dist/vendor/bootstrap-vue/src/components/list-group/index.js +0 -14
  182. package/dist/vendor/bootstrap-vue/src/components/list-group/list-group-item.js +0 -78
  183. package/dist/vendor/bootstrap-vue/src/components/list-group/list-group.js +0 -42
  184. package/dist/vendor/bootstrap-vue/src/components/media/index.js +0 -17
  185. package/dist/vendor/bootstrap-vue/src/components/media/media-aside.js +0 -41
  186. package/dist/vendor/bootstrap-vue/src/components/media/media-body.js +0 -31
  187. package/dist/vendor/bootstrap-vue/src/components/media/media.js +0 -61
  188. package/dist/vendor/bootstrap-vue/src/components/nav/nav-form.js +0 -45
  189. package/dist/vendor/bootstrap-vue/src/components/nav/nav-text.js +0 -26
  190. package/dist/vendor/bootstrap-vue/src/components/navbar/navbar-nav.js +0 -46
  191. package/dist/vendor/bootstrap-vue/src/components/navbar/navbar-toggle.js +0 -89
  192. package/dist/vendor/bootstrap-vue/src/components/overlay/index.js +0 -11
  193. package/dist/vendor/bootstrap-vue/src/components/overlay/overlay.js +0 -163
  194. package/dist/vendor/bootstrap-vue/src/components/pagination/index.js +0 -11
  195. package/dist/vendor/bootstrap-vue/src/components/pagination/pagination.js +0 -135
  196. package/dist/vendor/bootstrap-vue/src/components/pagination-nav/index.js +0 -11
  197. package/dist/vendor/bootstrap-vue/src/components/pagination-nav/pagination-nav.js +0 -299
  198. package/dist/vendor/bootstrap-vue/src/components/sidebar/index.js +0 -15
  199. package/dist/vendor/bootstrap-vue/src/components/sidebar/sidebar.js +0 -432
  200. package/dist/vendor/bootstrap-vue/src/components/skeleton/index.js +0 -23
  201. package/dist/vendor/bootstrap-vue/src/components/skeleton/skeleton-icon.js +0 -47
  202. package/dist/vendor/bootstrap-vue/src/components/skeleton/skeleton-img.js +0 -60
  203. package/dist/vendor/bootstrap-vue/src/components/skeleton/skeleton-table.js +0 -64
  204. package/dist/vendor/bootstrap-vue/src/components/skeleton/skeleton-wrapper.js +0 -46
  205. package/dist/vendor/bootstrap-vue/src/components/skeleton/skeleton.js +0 -49
  206. package/dist/vendor/bootstrap-vue/src/components/spinner/index.js +0 -11
  207. package/dist/vendor/bootstrap-vue/src/components/spinner/spinner.js +0 -55
  208. package/dist/vendor/bootstrap-vue/src/components/time/index.js +0 -11
  209. package/dist/vendor/bootstrap-vue/src/components/time/time.js +0 -600
  210. package/dist/vendor/bootstrap-vue/src/constants/date.js +0 -8
  211. package/dist/vendor/bootstrap-vue/src/mixins/card.js +0 -22
  212. package/dist/vendor/bootstrap-vue/src/mixins/pagination.js +0 -598
  213. package/dist/vendor/bootstrap-vue/src/utils/date.js +0 -135
  214. package/src/vendor/bootstrap-vue/src/_custom-controls.scss +0 -30
  215. package/src/vendor/bootstrap-vue/src/components/alert/README.md +0 -280
  216. package/src/vendor/bootstrap-vue/src/components/alert/alert.js +0 -185
  217. package/src/vendor/bootstrap-vue/src/components/alert/alert.spec.js +0 -442
  218. package/src/vendor/bootstrap-vue/src/components/alert/index.d.ts +0 -13
  219. package/src/vendor/bootstrap-vue/src/components/alert/index.js +0 -8
  220. package/src/vendor/bootstrap-vue/src/components/alert/package.json +0 -72
  221. package/src/vendor/bootstrap-vue/src/components/aspect/README.md +0 -65
  222. package/src/vendor/bootstrap-vue/src/components/aspect/aspect.js +0 -65
  223. package/src/vendor/bootstrap-vue/src/components/aspect/aspect.spec.js +0 -121
  224. package/src/vendor/bootstrap-vue/src/components/aspect/index.d.ts +0 -11
  225. package/src/vendor/bootstrap-vue/src/components/aspect/index.js +0 -8
  226. package/src/vendor/bootstrap-vue/src/components/aspect/package.json +0 -26
  227. package/src/vendor/bootstrap-vue/src/components/avatar/README.md +0 -567
  228. package/src/vendor/bootstrap-vue/src/components/avatar/_avatar.scss +0 -148
  229. package/src/vendor/bootstrap-vue/src/components/avatar/avatar-group.js +0 -75
  230. package/src/vendor/bootstrap-vue/src/components/avatar/avatar-group.spec.js +0 -74
  231. package/src/vendor/bootstrap-vue/src/components/avatar/avatar.js +0 -228
  232. package/src/vendor/bootstrap-vue/src/components/avatar/avatar.spec.js +0 -355
  233. package/src/vendor/bootstrap-vue/src/components/avatar/index.d.ts +0 -14
  234. package/src/vendor/bootstrap-vue/src/components/avatar/index.js +0 -9
  235. package/src/vendor/bootstrap-vue/src/components/avatar/index.scss +0 -1
  236. package/src/vendor/bootstrap-vue/src/components/avatar/package.json +0 -149
  237. package/src/vendor/bootstrap-vue/src/components/button-toolbar/README.md +0 -109
  238. package/src/vendor/bootstrap-vue/src/components/button-toolbar/button-toolbar.js +0 -117
  239. package/src/vendor/bootstrap-vue/src/components/button-toolbar/button-toolbar.spec.js +0 -185
  240. package/src/vendor/bootstrap-vue/src/components/button-toolbar/index.d.ts +0 -11
  241. package/src/vendor/bootstrap-vue/src/components/button-toolbar/index.js +0 -11
  242. package/src/vendor/bootstrap-vue/src/components/button-toolbar/package.json +0 -32
  243. package/src/vendor/bootstrap-vue/src/components/calendar/README.md +0 -735
  244. package/src/vendor/bootstrap-vue/src/components/calendar/_calendar.scss +0 -78
  245. package/src/vendor/bootstrap-vue/src/components/calendar/calendar.js +0 -1146
  246. package/src/vendor/bootstrap-vue/src/components/calendar/calendar.spec.js +0 -466
  247. package/src/vendor/bootstrap-vue/src/components/calendar/index.d.ts +0 -28
  248. package/src/vendor/bootstrap-vue/src/components/calendar/index.js +0 -8
  249. package/src/vendor/bootstrap-vue/src/components/calendar/index.scss +0 -1
  250. package/src/vendor/bootstrap-vue/src/components/calendar/package.json +0 -317
  251. package/src/vendor/bootstrap-vue/src/components/card/README.md +0 -729
  252. package/src/vendor/bootstrap-vue/src/components/card/_card-img.scss +0 -7
  253. package/src/vendor/bootstrap-vue/src/components/card/card-body.js +0 -69
  254. package/src/vendor/bootstrap-vue/src/components/card/card-body.spec.js +0 -142
  255. package/src/vendor/bootstrap-vue/src/components/card/card-footer.js +0 -48
  256. package/src/vendor/bootstrap-vue/src/components/card/card-footer.spec.js +0 -98
  257. package/src/vendor/bootstrap-vue/src/components/card/card-group.js +0 -33
  258. package/src/vendor/bootstrap-vue/src/components/card/card-group.spec.js +0 -75
  259. package/src/vendor/bootstrap-vue/src/components/card/card-header.js +0 -48
  260. package/src/vendor/bootstrap-vue/src/components/card/card-header.spec.js +0 -98
  261. package/src/vendor/bootstrap-vue/src/components/card/card-img-lazy.js +0 -47
  262. package/src/vendor/bootstrap-vue/src/components/card/card-img-lazy.spec.js +0 -204
  263. package/src/vendor/bootstrap-vue/src/components/card/card-img.js +0 -50
  264. package/src/vendor/bootstrap-vue/src/components/card/card-img.spec.js +0 -208
  265. package/src/vendor/bootstrap-vue/src/components/card/card-sub-title.js +0 -35
  266. package/src/vendor/bootstrap-vue/src/components/card/card-sub-title.spec.js +0 -60
  267. package/src/vendor/bootstrap-vue/src/components/card/card-text.js +0 -25
  268. package/src/vendor/bootstrap-vue/src/components/card/card-text.spec.js +0 -48
  269. package/src/vendor/bootstrap-vue/src/components/card/card-title.js +0 -33
  270. package/src/vendor/bootstrap-vue/src/components/card/card-title.spec.js +0 -45
  271. package/src/vendor/bootstrap-vue/src/components/card/card.js +0 -140
  272. package/src/vendor/bootstrap-vue/src/components/card/card.spec.js +0 -296
  273. package/src/vendor/bootstrap-vue/src/components/card/index.d.ts +0 -38
  274. package/src/vendor/bootstrap-vue/src/components/card/index.js +0 -40
  275. package/src/vendor/bootstrap-vue/src/components/card/index.scss +0 -1
  276. package/src/vendor/bootstrap-vue/src/components/card/package.json +0 -262
  277. package/src/vendor/bootstrap-vue/src/components/embed/README.md +0 -63
  278. package/src/vendor/bootstrap-vue/src/components/embed/embed.js +0 -51
  279. package/src/vendor/bootstrap-vue/src/components/embed/embed.spec.js +0 -110
  280. package/src/vendor/bootstrap-vue/src/components/embed/index.d.ts +0 -11
  281. package/src/vendor/bootstrap-vue/src/components/embed/index.js +0 -8
  282. package/src/vendor/bootstrap-vue/src/components/embed/package.json +0 -29
  283. package/src/vendor/bootstrap-vue/src/components/form/form-datalist.js +0 -42
  284. package/src/vendor/bootstrap-vue/src/components/form/form-datalist.spec.js +0 -57
  285. package/src/vendor/bootstrap-vue/src/components/form-btn-label-control/_form-btn-label-control.scss +0 -125
  286. package/src/vendor/bootstrap-vue/src/components/form-btn-label-control/bv-form-btn-label-control.js +0 -278
  287. package/src/vendor/bootstrap-vue/src/components/form-btn-label-control/index.scss +0 -1
  288. package/src/vendor/bootstrap-vue/src/components/form-btn-label-control/package.json +0 -5
  289. package/src/vendor/bootstrap-vue/src/components/form-datepicker/README.md +0 -694
  290. package/src/vendor/bootstrap-vue/src/components/form-datepicker/_form-datepicker.scss +0 -1
  291. package/src/vendor/bootstrap-vue/src/components/form-datepicker/form-datepicker.js +0 -342
  292. package/src/vendor/bootstrap-vue/src/components/form-datepicker/form-datepicker.spec.js +0 -562
  293. package/src/vendor/bootstrap-vue/src/components/form-datepicker/index.d.ts +0 -12
  294. package/src/vendor/bootstrap-vue/src/components/form-datepicker/index.js +0 -11
  295. package/src/vendor/bootstrap-vue/src/components/form-datepicker/index.scss +0 -1
  296. package/src/vendor/bootstrap-vue/src/components/form-datepicker/package.json +0 -420
  297. package/src/vendor/bootstrap-vue/src/components/form-file/README.md +0 -357
  298. package/src/vendor/bootstrap-vue/src/components/form-file/_form-file.scss +0 -61
  299. package/src/vendor/bootstrap-vue/src/components/form-file/form-file.js +0 -575
  300. package/src/vendor/bootstrap-vue/src/components/form-file/form-file.spec.js +0 -885
  301. package/src/vendor/bootstrap-vue/src/components/form-file/index.d.ts +0 -13
  302. package/src/vendor/bootstrap-vue/src/components/form-file/index.js +0 -11
  303. package/src/vendor/bootstrap-vue/src/components/form-file/index.scss +0 -1
  304. package/src/vendor/bootstrap-vue/src/components/form-file/package.json +0 -131
  305. package/src/vendor/bootstrap-vue/src/components/form-rating/README.md +0 -526
  306. package/src/vendor/bootstrap-vue/src/components/form-rating/_form-rating.scss +0 -57
  307. package/src/vendor/bootstrap-vue/src/components/form-rating/form-rating.js +0 -411
  308. package/src/vendor/bootstrap-vue/src/components/form-rating/form-rating.spec.js +0 -544
  309. package/src/vendor/bootstrap-vue/src/components/form-rating/index.d.ts +0 -14
  310. package/src/vendor/bootstrap-vue/src/components/form-rating/index.js +0 -8
  311. package/src/vendor/bootstrap-vue/src/components/form-rating/index.scss +0 -1
  312. package/src/vendor/bootstrap-vue/src/components/form-rating/package.json +0 -166
  313. package/src/vendor/bootstrap-vue/src/components/form-spinbutton/README.md +0 -411
  314. package/src/vendor/bootstrap-vue/src/components/form-spinbutton/_spinbutton.scss +0 -76
  315. package/src/vendor/bootstrap-vue/src/components/form-spinbutton/form-spinbutton.js +0 -572
  316. package/src/vendor/bootstrap-vue/src/components/form-spinbutton/form-spinbutton.spec.js +0 -731
  317. package/src/vendor/bootstrap-vue/src/components/form-spinbutton/index.d.ts +0 -12
  318. package/src/vendor/bootstrap-vue/src/components/form-spinbutton/index.js +0 -11
  319. package/src/vendor/bootstrap-vue/src/components/form-spinbutton/index.scss +0 -1
  320. package/src/vendor/bootstrap-vue/src/components/form-spinbutton/package.json +0 -150
  321. package/src/vendor/bootstrap-vue/src/components/form-tags/README.md +0 -880
  322. package/src/vendor/bootstrap-vue/src/components/form-tags/_form-tags.scss +0 -70
  323. package/src/vendor/bootstrap-vue/src/components/form-tags/form-tag.js +0 -94
  324. package/src/vendor/bootstrap-vue/src/components/form-tags/form-tag.spec.js +0 -166
  325. package/src/vendor/bootstrap-vue/src/components/form-tags/form-tags.js +0 -891
  326. package/src/vendor/bootstrap-vue/src/components/form-tags/form-tags.spec.js +0 -920
  327. package/src/vendor/bootstrap-vue/src/components/form-tags/index.d.ts +0 -16
  328. package/src/vendor/bootstrap-vue/src/components/form-tags/index.js +0 -14
  329. package/src/vendor/bootstrap-vue/src/components/form-tags/index.scss +0 -1
  330. package/src/vendor/bootstrap-vue/src/components/form-tags/package.json +0 -440
  331. package/src/vendor/bootstrap-vue/src/components/form-timepicker/README.md +0 -450
  332. package/src/vendor/bootstrap-vue/src/components/form-timepicker/_form-timepicker.scss +0 -1
  333. package/src/vendor/bootstrap-vue/src/components/form-timepicker/form-timepicker.js +0 -308
  334. package/src/vendor/bootstrap-vue/src/components/form-timepicker/form-timepicker.spec.js +0 -440
  335. package/src/vendor/bootstrap-vue/src/components/form-timepicker/index.d.ts +0 -12
  336. package/src/vendor/bootstrap-vue/src/components/form-timepicker/index.js +0 -11
  337. package/src/vendor/bootstrap-vue/src/components/form-timepicker/index.scss +0 -1
  338. package/src/vendor/bootstrap-vue/src/components/form-timepicker/package.json +0 -255
  339. package/src/vendor/bootstrap-vue/src/components/image/README.md +0 -322
  340. package/src/vendor/bootstrap-vue/src/components/image/img-lazy.js +0 -161
  341. package/src/vendor/bootstrap-vue/src/components/image/img-lazy.spec.js +0 -96
  342. package/src/vendor/bootstrap-vue/src/components/image/img.js +0 -139
  343. package/src/vendor/bootstrap-vue/src/components/image/img.spec.js +0 -255
  344. package/src/vendor/bootstrap-vue/src/components/image/index.d.ts +0 -14
  345. package/src/vendor/bootstrap-vue/src/components/image/index.js +0 -12
  346. package/src/vendor/bootstrap-vue/src/components/image/package.json +0 -152
  347. package/src/vendor/bootstrap-vue/src/components/jumbotron/README.md +0 -109
  348. package/src/vendor/bootstrap-vue/src/components/jumbotron/index.d.ts +0 -11
  349. package/src/vendor/bootstrap-vue/src/components/jumbotron/index.js +0 -8
  350. package/src/vendor/bootstrap-vue/src/components/jumbotron/jumbotron.js +0 -103
  351. package/src/vendor/bootstrap-vue/src/components/jumbotron/jumbotron.spec.js +0 -254
  352. package/src/vendor/bootstrap-vue/src/components/jumbotron/package.json +0 -66
  353. package/src/vendor/bootstrap-vue/src/components/layout/container.js +0 -40
  354. package/src/vendor/bootstrap-vue/src/components/layout/container.spec.js +0 -75
  355. package/src/vendor/bootstrap-vue/src/components/layout/row.js +0 -111
  356. package/src/vendor/bootstrap-vue/src/components/layout/row.spec.js +0 -138
  357. package/src/vendor/bootstrap-vue/src/components/list-group/README.md +0 -291
  358. package/src/vendor/bootstrap-vue/src/components/list-group/index.d.ts +0 -14
  359. package/src/vendor/bootstrap-vue/src/components/list-group/index.js +0 -12
  360. package/src/vendor/bootstrap-vue/src/components/list-group/list-group-item.js +0 -76
  361. package/src/vendor/bootstrap-vue/src/components/list-group/list-group-item.spec.js +0 -286
  362. package/src/vendor/bootstrap-vue/src/components/list-group/list-group.js +0 -42
  363. package/src/vendor/bootstrap-vue/src/components/list-group/list-group.spec.js +0 -132
  364. package/src/vendor/bootstrap-vue/src/components/list-group/package.json +0 -52
  365. package/src/vendor/bootstrap-vue/src/components/media/README.md +0 -183
  366. package/src/vendor/bootstrap-vue/src/components/media/_media.scss +0 -9
  367. package/src/vendor/bootstrap-vue/src/components/media/index.d.ts +0 -17
  368. package/src/vendor/bootstrap-vue/src/components/media/index.js +0 -14
  369. package/src/vendor/bootstrap-vue/src/components/media/index.scss +0 -1
  370. package/src/vendor/bootstrap-vue/src/components/media/media-aside.js +0 -45
  371. package/src/vendor/bootstrap-vue/src/components/media/media-aside.spec.js +0 -79
  372. package/src/vendor/bootstrap-vue/src/components/media/media-body.js +0 -25
  373. package/src/vendor/bootstrap-vue/src/components/media/media-body.spec.js +0 -47
  374. package/src/vendor/bootstrap-vue/src/components/media/media.js +0 -52
  375. package/src/vendor/bootstrap-vue/src/components/media/media.spec.js +0 -149
  376. package/src/vendor/bootstrap-vue/src/components/media/package.json +0 -65
  377. package/src/vendor/bootstrap-vue/src/components/nav/nav-form.js +0 -50
  378. package/src/vendor/bootstrap-vue/src/components/nav/nav-form.spec.js +0 -93
  379. package/src/vendor/bootstrap-vue/src/components/nav/nav-text.js +0 -18
  380. package/src/vendor/bootstrap-vue/src/components/nav/nav-text.spec.js +0 -30
  381. package/src/vendor/bootstrap-vue/src/components/navbar/navbar-nav.js +0 -45
  382. package/src/vendor/bootstrap-vue/src/components/navbar/navbar-nav.spec.js +0 -105
  383. package/src/vendor/bootstrap-vue/src/components/navbar/navbar-toggle.js +0 -84
  384. package/src/vendor/bootstrap-vue/src/components/navbar/navbar-toggle.spec.js +0 -189
  385. package/src/vendor/bootstrap-vue/src/components/overlay/README.md +0 -815
  386. package/src/vendor/bootstrap-vue/src/components/overlay/index.d.ts +0 -11
  387. package/src/vendor/bootstrap-vue/src/components/overlay/index.js +0 -8
  388. package/src/vendor/bootstrap-vue/src/components/overlay/overlay.js +0 -162
  389. package/src/vendor/bootstrap-vue/src/components/overlay/overlay.spec.js +0 -257
  390. package/src/vendor/bootstrap-vue/src/components/overlay/package.json +0 -130
  391. package/src/vendor/bootstrap-vue/src/components/pagination/README.md +0 -430
  392. package/src/vendor/bootstrap-vue/src/components/pagination/_pagination.scss +0 -26
  393. package/src/vendor/bootstrap-vue/src/components/pagination/index.d.ts +0 -11
  394. package/src/vendor/bootstrap-vue/src/components/pagination/index.js +0 -8
  395. package/src/vendor/bootstrap-vue/src/components/pagination/index.scss +0 -1
  396. package/src/vendor/bootstrap-vue/src/components/pagination/package.json +0 -295
  397. package/src/vendor/bootstrap-vue/src/components/pagination/pagination.js +0 -138
  398. package/src/vendor/bootstrap-vue/src/components/pagination/pagination.spec.js +0 -1198
  399. package/src/vendor/bootstrap-vue/src/components/pagination-nav/README.md +0 -544
  400. package/src/vendor/bootstrap-vue/src/components/pagination-nav/_pagination-nav.scss +0 -2
  401. package/src/vendor/bootstrap-vue/src/components/pagination-nav/index.d.ts +0 -11
  402. package/src/vendor/bootstrap-vue/src/components/pagination-nav/index.js +0 -8
  403. package/src/vendor/bootstrap-vue/src/components/pagination-nav/index.scss +0 -1
  404. package/src/vendor/bootstrap-vue/src/components/pagination-nav/package.json +0 -315
  405. package/src/vendor/bootstrap-vue/src/components/pagination-nav/pagination-nav.js +0 -281
  406. package/src/vendor/bootstrap-vue/src/components/pagination-nav/pagination-nav.spec.js +0 -671
  407. package/src/vendor/bootstrap-vue/src/components/sidebar/README.md +0 -406
  408. package/src/vendor/bootstrap-vue/src/components/sidebar/_sidebar.scss +0 -97
  409. package/src/vendor/bootstrap-vue/src/components/sidebar/index.d.ts +0 -11
  410. package/src/vendor/bootstrap-vue/src/components/sidebar/index.js +0 -10
  411. package/src/vendor/bootstrap-vue/src/components/sidebar/index.scss +0 -1
  412. package/src/vendor/bootstrap-vue/src/components/sidebar/package.json +0 -239
  413. package/src/vendor/bootstrap-vue/src/components/sidebar/sidebar.js +0 -438
  414. package/src/vendor/bootstrap-vue/src/components/sidebar/sidebar.spec.js +0 -404
  415. package/src/vendor/bootstrap-vue/src/components/skeleton/README.md +0 -275
  416. package/src/vendor/bootstrap-vue/src/components/skeleton/_skeleton.scss +0 -141
  417. package/src/vendor/bootstrap-vue/src/components/skeleton/index.d.ts +0 -23
  418. package/src/vendor/bootstrap-vue/src/components/skeleton/index.js +0 -18
  419. package/src/vendor/bootstrap-vue/src/components/skeleton/index.scss +0 -1
  420. package/src/vendor/bootstrap-vue/src/components/skeleton/package.json +0 -136
  421. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton-icon.js +0 -45
  422. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton-icon.spec.js +0 -86
  423. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton-img.js +0 -49
  424. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton-img.spec.js +0 -139
  425. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton-table.js +0 -58
  426. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton-table.spec.js +0 -119
  427. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton-wrapper.js +0 -47
  428. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton-wrapper.spec.js +0 -48
  429. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton.js +0 -46
  430. package/src/vendor/bootstrap-vue/src/components/skeleton/skeleton.spec.js +0 -126
  431. package/src/vendor/bootstrap-vue/src/components/spinner/README.md +0 -229
  432. package/src/vendor/bootstrap-vue/src/components/spinner/index.d.ts +0 -11
  433. package/src/vendor/bootstrap-vue/src/components/spinner/index.js +0 -8
  434. package/src/vendor/bootstrap-vue/src/components/spinner/package.json +0 -38
  435. package/src/vendor/bootstrap-vue/src/components/spinner/spinner.js +0 -54
  436. package/src/vendor/bootstrap-vue/src/components/spinner/spinner.spec.js +0 -305
  437. package/src/vendor/bootstrap-vue/src/components/time/README.md +0 -431
  438. package/src/vendor/bootstrap-vue/src/components/time/_time.scss +0 -41
  439. package/src/vendor/bootstrap-vue/src/components/time/index.d.ts +0 -27
  440. package/src/vendor/bootstrap-vue/src/components/time/index.js +0 -8
  441. package/src/vendor/bootstrap-vue/src/components/time/index.scss +0 -1
  442. package/src/vendor/bootstrap-vue/src/components/time/package.json +0 -123
  443. package/src/vendor/bootstrap-vue/src/components/time/time.js +0 -601
  444. package/src/vendor/bootstrap-vue/src/components/time/time.spec.js +0 -330
  445. package/src/vendor/bootstrap-vue/src/constants/date.js +0 -7
  446. package/src/vendor/bootstrap-vue/src/mixins/card.js +0 -23
  447. package/src/vendor/bootstrap-vue/src/mixins/pagination.js +0 -670
  448. package/src/vendor/bootstrap-vue/src/utils/date.js +0 -130
  449. package/src/vendor/bootstrap-vue/src/utils/date.spec.js +0 -159
@@ -1,806 +0,0 @@
1
- import { extend } from '../../vue';
2
- import { NAME_FORM_TAGS } from '../../constants/components';
3
- import { EVENT_NAME_FOCUSIN, EVENT_NAME_FOCUSOUT, EVENT_NAME_TAG_STATE, EVENT_OPTIONS_PASSIVE, EVENT_NAME_FOCUS, EVENT_NAME_BLUR } from '../../constants/events';
4
- import { CODE_ENTER, CODE_BACKSPACE, CODE_DELETE } from '../../constants/key-codes';
5
- import { PROP_TYPE_ARRAY, PROP_TYPE_STRING, PROP_TYPE_BOOLEAN, PROP_TYPE_ARRAY_STRING, PROP_TYPE_OBJECT, PROP_TYPE_ARRAY_OBJECT_STRING, PROP_TYPE_NUMBER, PROP_TYPE_FUNCTION } from '../../constants/props';
6
- import { RX_SPACES } from '../../constants/regex';
7
- import { SLOT_NAME_ADD_BUTTON_TEXT, SLOT_NAME_DEFAULT } from '../../constants/slots';
8
- import { arrayIncludes, concat } from '../../utils/array';
9
- import { cssEscape } from '../../utils/css-escape';
10
- import { closest, matches, requestAF, attemptFocus, attemptBlur, select } from '../../utils/dom';
11
- import { eventOn, eventOff, stopEvent } from '../../utils/events';
12
- import { identity } from '../../utils/identity';
13
- import { isString, isNumber, isEvent } from '../../utils/inspect';
14
- import { looseEqual } from '../../utils/loose-equal';
15
- import { makeModelMixin } from '../../utils/model';
16
- import { sortKeys, omit, pick } from '../../utils/object';
17
- import { makePropsConfigurable, makeProp, hasPropFunction } from '../../utils/props';
18
- import { escapeRegExp, trim, toString, trimLeft } from '../../utils/string';
19
- import { props as props$2, formControlMixin } from '../../mixins/form-control';
20
- import { props as props$3, formSizeMixin } from '../../mixins/form-size';
21
- import { props as props$4, formStateMixin } from '../../mixins/form-state';
22
- import { props as props$1, idMixin } from '../../mixins/id';
23
- import { listenersMixin } from '../../mixins/listeners';
24
- import { normalizeSlotMixin } from '../../mixins/normalize-slot';
25
- import { BButton } from '../button/button';
26
- import { BFormInvalidFeedback } from '../form/form-invalid-feedback';
27
- import { BFormText } from '../form/form-text';
28
- import { BFormTag } from './form-tag';
29
-
30
- // Tagged input form control
31
-
32
- // --- Constants ---
33
-
34
- const {
35
- mixin: modelMixin,
36
- props: modelProps,
37
- prop: MODEL_PROP_NAME,
38
- event: MODEL_EVENT_NAME
39
- } = makeModelMixin('value', {
40
- type: PROP_TYPE_ARRAY,
41
- defaultValue: []
42
- });
43
-
44
- // Supported input types (for built in input)
45
- const TYPES = ['text', 'email', 'tel', 'url', 'number'];
46
-
47
- // Default ignore input focus selector
48
- const DEFAULT_INPUT_FOCUS_SELECTOR = ['.b-form-tag', 'button', 'input', 'select'].join(' ');
49
-
50
- // --- Helper methods ---
51
-
52
- // Escape special chars in string and replace
53
- // contiguous spaces with a whitespace match
54
- const escapeRegExpChars = str => escapeRegExp(str).replace(RX_SPACES, '\\s');
55
-
56
- // Remove leading/trailing spaces from array of tags and remove duplicates
57
- const cleanTags = tags => {
58
- return concat(tags).map(tag => trim(toString(tag))).filter((tag, index, arr) => tag.length > 0 && arr.indexOf(tag) === index);
59
- };
60
-
61
- // Processes an input/change event, normalizing string or event argument
62
- const processEventValue = event => isString(event) ? event : isEvent(event) ? event.target.value || '' : '';
63
-
64
- // Returns a fresh empty `tagsState` object
65
- const cleanTagsState = () => ({
66
- all: [],
67
- valid: [],
68
- invalid: [],
69
- duplicate: []
70
- });
71
-
72
- // --- Props ---
73
-
74
- const props = makePropsConfigurable(sortKeys({
75
- ...props$1,
76
- ...modelProps,
77
- ...props$2,
78
- ...props$3,
79
- ...props$4,
80
- addButtonText: makeProp(PROP_TYPE_STRING, 'Add'),
81
- addButtonVariant: makeProp(PROP_TYPE_STRING, 'outline-secondary'),
82
- // Enable change event triggering tag addition
83
- // Handy if using <select> as the input
84
- addOnChange: makeProp(PROP_TYPE_BOOLEAN, false),
85
- duplicateTagText: makeProp(PROP_TYPE_STRING, 'Duplicate tag(s)'),
86
- feedbackAriaLive: makeProp(PROP_TYPE_STRING, 'assertive'),
87
- // Disable the input focus behavior when clicking
88
- // on element matching the selector (or selectors)
89
- ignoreInputFocusSelector: makeProp(PROP_TYPE_ARRAY_STRING, DEFAULT_INPUT_FOCUS_SELECTOR),
90
- // Additional attributes to add to the input element
91
- inputAttrs: makeProp(PROP_TYPE_OBJECT, {}),
92
- inputClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),
93
- inputId: makeProp(PROP_TYPE_STRING),
94
- inputType: makeProp(PROP_TYPE_STRING, 'text', value => {
95
- return arrayIncludes(TYPES, value);
96
- }),
97
- invalidTagText: makeProp(PROP_TYPE_STRING, 'Invalid tag(s)'),
98
- limit: makeProp(PROP_TYPE_NUMBER),
99
- limitTagsText: makeProp(PROP_TYPE_STRING, 'Tag limit reached'),
100
- // Disable ENTER key from triggering tag addition
101
- noAddOnEnter: makeProp(PROP_TYPE_BOOLEAN, false),
102
- // Disable the focus ring on the root element
103
- noOuterFocus: makeProp(PROP_TYPE_BOOLEAN, false),
104
- noTagRemove: makeProp(PROP_TYPE_BOOLEAN, false),
105
- placeholder: makeProp(PROP_TYPE_STRING, 'Add tag...'),
106
- // Enable deleting last tag in list when CODE_BACKSPACE is
107
- // pressed and input is empty
108
- removeOnDelete: makeProp(PROP_TYPE_BOOLEAN, false),
109
- // Character (or characters) that trigger adding tags
110
- separator: makeProp(PROP_TYPE_ARRAY_STRING),
111
- tagClass: makeProp(PROP_TYPE_ARRAY_OBJECT_STRING),
112
- tagPills: makeProp(PROP_TYPE_BOOLEAN, false),
113
- tagRemoveLabel: makeProp(PROP_TYPE_STRING, 'Remove tag'),
114
- tagRemovedLabel: makeProp(PROP_TYPE_STRING, 'Tag removed'),
115
- tagValidator: makeProp(PROP_TYPE_FUNCTION),
116
- tagVariant: makeProp(PROP_TYPE_STRING, 'secondary')
117
- }), NAME_FORM_TAGS);
118
-
119
- // --- Main component ---
120
-
121
- // @vue/component
122
- const BFormTags = /*#__PURE__*/extend({
123
- name: NAME_FORM_TAGS,
124
- mixins: [listenersMixin, idMixin, modelMixin, formControlMixin, formSizeMixin, formStateMixin, normalizeSlotMixin],
125
- props,
126
- data() {
127
- return {
128
- hasFocus: false,
129
- newTag: '',
130
- tags: [],
131
- // Tags that were removed
132
- removedTags: [],
133
- // Populated when tags are parsed
134
- tagsState: cleanTagsState(),
135
- focusState: null
136
- };
137
- },
138
- computed: {
139
- computedInputId() {
140
- return this.inputId || this.safeId('__input__');
141
- },
142
- computedInputType() {
143
- // We only allow certain types
144
- return arrayIncludes(TYPES, this.inputType) ? this.inputType : 'text';
145
- },
146
- computedInputAttrs() {
147
- const {
148
- disabled,
149
- form
150
- } = this;
151
- return {
152
- // Merge in user supplied attributes
153
- ...this.inputAttrs,
154
- // Must have attributes
155
- id: this.computedInputId,
156
- value: this.newTag,
157
- disabled,
158
- form
159
- };
160
- },
161
- computedInputHandlers() {
162
- return {
163
- ...omit(this.bvListeners, [EVENT_NAME_FOCUSIN, EVENT_NAME_FOCUSOUT]),
164
- blur: this.onInputBlur,
165
- change: this.onInputChange,
166
- focus: this.onInputFocus,
167
- input: this.onInputInput,
168
- keydown: this.onInputKeydown,
169
- reset: this.reset
170
- };
171
- },
172
- computedSeparator() {
173
- // Merge the array into a string
174
- return concat(this.separator).filter(isString).filter(identity).join('');
175
- },
176
- computedSeparatorRegExp() {
177
- // We use a computed prop here to precompile the RegExp
178
- // The RegExp is a character class RE in the form of `/[abc]+/`
179
- // where a, b, and c are the valid separator characters
180
- // -> `tags = str.split(/[abc]+/).filter(t => t)`
181
- const separator = this.computedSeparator;
182
- return separator ? new RegExp(`[${escapeRegExpChars(separator)}]+`) : null;
183
- },
184
- computedJoiner() {
185
- // When tag(s) are invalid or duplicate, we leave them
186
- // in the input so that the user can see them
187
- // If there are more than one tag in the input, we use the
188
- // first separator character as the separator in the input
189
- // We append a space if the first separator is not a space
190
- const joiner = this.computedSeparator.charAt(0);
191
- return joiner !== ' ' ? `${joiner} ` : joiner;
192
- },
193
- computeIgnoreInputFocusSelector() {
194
- // Normalize to an single selector with selectors separated by `,`
195
- return concat(this.ignoreInputFocusSelector).filter(identity).join(',').trim();
196
- },
197
- disableAddButton() {
198
- // If 'Add' button should be disabled
199
- // If the input contains at least one tag that can
200
- // be added, then the 'Add' button should be enabled
201
- const newTag = trim(this.newTag);
202
- return newTag === '' || !this.splitTags(newTag).some(t => !arrayIncludes(this.tags, t) && this.validateTag(t));
203
- },
204
- duplicateTags() {
205
- return this.tagsState.duplicate;
206
- },
207
- hasDuplicateTags() {
208
- return this.duplicateTags.length > 0;
209
- },
210
- invalidTags() {
211
- return this.tagsState.invalid;
212
- },
213
- hasInvalidTags() {
214
- return this.invalidTags.length > 0;
215
- },
216
- isLimitReached() {
217
- const {
218
- limit
219
- } = this;
220
- return isNumber(limit) && limit >= 0 && this.tags.length >= limit;
221
- }
222
- },
223
- watch: {
224
- [MODEL_PROP_NAME](newValue) {
225
- this.tags = cleanTags(newValue);
226
- },
227
- tags(newValue, oldValue) {
228
- // Update the `v-model` (if it differs from the value prop)
229
- if (!looseEqual(newValue, this[MODEL_PROP_NAME])) {
230
- this.$emit(MODEL_EVENT_NAME, newValue);
231
- }
232
- if (!looseEqual(newValue, oldValue)) {
233
- newValue = concat(newValue).filter(identity);
234
- oldValue = concat(oldValue).filter(identity);
235
- this.removedTags = oldValue.filter(old => !arrayIncludes(newValue, old));
236
- }
237
- },
238
- tagsState(newValue, oldValue) {
239
- // Emit a tag-state event when the `tagsState` object changes
240
- if (!looseEqual(newValue, oldValue)) {
241
- this.$emit(EVENT_NAME_TAG_STATE, newValue.valid, newValue.invalid, newValue.duplicate);
242
- }
243
- }
244
- },
245
- created() {
246
- // We do this in created to make sure an input event emits
247
- // if the cleaned tags are not equal to the value prop
248
- this.tags = cleanTags(this[MODEL_PROP_NAME]);
249
- },
250
- mounted() {
251
- // Listen for form reset events, to reset the tags input
252
- const $form = closest('form', this.$el);
253
- if ($form) {
254
- eventOn($form, 'reset', this.reset, EVENT_OPTIONS_PASSIVE);
255
- }
256
- },
257
- beforeDestroy() {
258
- const $form = closest('form', this.$el);
259
- if ($form) {
260
- eventOff($form, 'reset', this.reset, EVENT_OPTIONS_PASSIVE);
261
- }
262
- },
263
- methods: {
264
- addTag(newTag) {
265
- newTag = isString(newTag) ? newTag : this.newTag;
266
- /* istanbul ignore next */
267
- if (this.disabled || trim(newTag) === '' || this.isLimitReached) {
268
- // Early exit
269
- return;
270
- }
271
- const parsed = this.parseTags(newTag);
272
- // Add any new tags to the `tags` array, or if the
273
- // array of `allTags` is empty, we clear the input
274
- if (parsed.valid.length > 0 || parsed.all.length === 0) {
275
- // Clear the user input element (and leave in any invalid/duplicate tag(s)
276
- /* istanbul ignore if: full testing to be added later */
277
- if (matches(this.getInput(), 'select')) {
278
- // The following is needed to properly
279
- // work with `<select>` elements
280
- this.newTag = '';
281
- } else {
282
- const invalidAndDuplicates = [...parsed.invalid, ...parsed.duplicate];
283
- this.newTag = parsed.all.filter(tag => arrayIncludes(invalidAndDuplicates, tag)).join(this.computedJoiner).concat(invalidAndDuplicates.length > 0 ? this.computedJoiner.charAt(0) : '');
284
- }
285
- }
286
- if (parsed.valid.length > 0) {
287
- // We add the new tags in one atomic operation
288
- // to trigger reactivity once (instead of once per tag)
289
- // We do this after we update the new tag input value
290
- // `concat()` can be faster than array spread, when both args are arrays
291
- this.tags = concat(this.tags, parsed.valid);
292
- }
293
- this.tagsState = parsed;
294
- // Attempt to re-focus the input (specifically for when using the Add
295
- // button, as the button disappears after successfully adding a tag
296
- this.focus();
297
- },
298
- removeTag(tag) {
299
- /* istanbul ignore next */
300
- if (this.disabled) {
301
- return;
302
- }
303
- // TODO:
304
- // Add `onRemoveTag(tag)` user method, which if returns `false`
305
- // will prevent the tag from being removed (i.e. confirmation)
306
- // Or emit cancelable `BvEvent`
307
- this.tags = this.tags.filter(t => t !== tag);
308
- },
309
- reset() {
310
- this.newTag = '';
311
- this.tags = [];
312
- this.$nextTick(() => {
313
- this.removedTags = [];
314
- this.tagsState = cleanTagsState();
315
- });
316
- },
317
- // --- Input element event handlers ---
318
- onInputInput(event) {
319
- /* istanbul ignore next: hard to test composition events */
320
- if (this.disabled || isEvent(event) && event.target.composing) {
321
- // `event.target.composing` is set by Vue (`v-model` directive)
322
- // https://github.com/vuejs/vue/blob/dev/src/platforms/web/runtime/directives/model.js
323
- return;
324
- }
325
- let newTag = processEventValue(event);
326
- const separatorRe = this.computedSeparatorRegExp;
327
- if (this.newTag !== newTag) {
328
- this.newTag = newTag;
329
- }
330
- // We ignore leading whitespace for the following
331
- newTag = trimLeft(newTag);
332
- if (separatorRe && separatorRe.test(newTag.slice(-1))) {
333
- // A trailing separator character was entered, so add the tag(s)
334
- // Note: More than one tag on input event is possible via copy/paste
335
- this.addTag();
336
- } else {
337
- // Validate (parse tags) on input event
338
- this.tagsState = newTag === '' ? cleanTagsState() : this.parseTags(newTag);
339
- }
340
- },
341
- onInputChange(event) {
342
- // Change is triggered on `<input>` blur, or `<select>` selected
343
- // This event is opt-in
344
- if (!this.disabled && this.addOnChange) {
345
- const newTag = processEventValue(event);
346
- /* istanbul ignore next */
347
- if (this.newTag !== newTag) {
348
- this.newTag = newTag;
349
- }
350
- this.addTag();
351
- }
352
- },
353
- onInputKeydown(event) {
354
- // Early exit
355
- /* istanbul ignore next */
356
- if (this.disabled || !isEvent(event)) {
357
- return;
358
- }
359
- const {
360
- keyCode
361
- } = event;
362
- const value = event.target.value || '';
363
- /* istanbul ignore else: testing to be added later */
364
- if (!this.noAddOnEnter && keyCode === CODE_ENTER) {
365
- // Attempt to add the tag when user presses enter
366
- stopEvent(event, {
367
- propagation: false
368
- });
369
- this.addTag();
370
- } else if (this.removeOnDelete && (keyCode === CODE_BACKSPACE || keyCode === CODE_DELETE) && value === '') {
371
- // Remove the last tag if the user pressed backspace/delete and the input is empty
372
- stopEvent(event, {
373
- propagation: false
374
- });
375
- this.tags = this.tags.slice(0, -1);
376
- }
377
- },
378
- // --- Wrapper event handlers ---
379
- onClick(event) {
380
- const {
381
- computeIgnoreInputFocusSelector: ignoreFocusSelector
382
- } = this;
383
- if (!ignoreFocusSelector || !closest(ignoreFocusSelector, event.target, true)) {
384
- this.$nextTick(() => {
385
- this.focus();
386
- });
387
- }
388
- },
389
- onInputFocus(event) {
390
- if (this.focusState !== 'out') {
391
- this.focusState = 'in';
392
- this.$nextTick(() => {
393
- requestAF(() => {
394
- if (this.hasFocus) {
395
- this.$emit(EVENT_NAME_FOCUS, event);
396
- this.focusState = null;
397
- }
398
- });
399
- });
400
- }
401
- },
402
- onInputBlur(event) {
403
- if (this.focusState !== 'in') {
404
- this.focusState = 'out';
405
- this.$nextTick(() => {
406
- requestAF(() => {
407
- if (!this.hasFocus) {
408
- this.$emit(EVENT_NAME_BLUR, event);
409
- this.focusState = null;
410
- }
411
- });
412
- });
413
- }
414
- },
415
- onFocusin(event) {
416
- this.hasFocus = true;
417
- this.$emit(EVENT_NAME_FOCUSIN, event);
418
- },
419
- onFocusout(event) {
420
- this.hasFocus = false;
421
- this.$emit(EVENT_NAME_FOCUSOUT, event);
422
- },
423
- handleAutofocus() {
424
- this.$nextTick(() => {
425
- requestAF(() => {
426
- if (this.autofocus) {
427
- this.focus();
428
- }
429
- });
430
- });
431
- },
432
- // --- Public methods ---
433
- focus() {
434
- if (!this.disabled) {
435
- attemptFocus(this.getInput());
436
- }
437
- },
438
- blur() {
439
- if (!this.disabled) {
440
- attemptBlur(this.getInput());
441
- }
442
- },
443
- // --- Private methods ---
444
- splitTags(newTag) {
445
- // Split the input into an array of raw tags
446
- newTag = toString(newTag);
447
- const separatorRe = this.computedSeparatorRegExp;
448
- // Split the tag(s) via the optional separator
449
- // Normally only a single tag is provided, but copy/paste
450
- // can enter multiple tags in a single operation
451
- return (separatorRe ? newTag.split(separatorRe) : [newTag]).map(trim).filter(identity);
452
- },
453
- parseTags(newTag) {
454
- // Takes `newTag` value and parses it into `validTags`,
455
- // `invalidTags`, and duplicate tags as an object
456
- // Split the input into raw tags
457
- const tags = this.splitTags(newTag);
458
- // Base results
459
- const parsed = {
460
- all: tags,
461
- valid: [],
462
- invalid: [],
463
- duplicate: []
464
- };
465
- // Parse the unique tags
466
- tags.forEach(tag => {
467
- if (arrayIncludes(this.tags, tag) || arrayIncludes(parsed.valid, tag)) {
468
- // Unique duplicate tags
469
- if (!arrayIncludes(parsed.duplicate, tag)) {
470
- parsed.duplicate.push(tag);
471
- }
472
- } else if (this.validateTag(tag)) {
473
- // We only add unique/valid tags
474
- parsed.valid.push(tag);
475
- } else {
476
- // Unique invalid tags
477
- if (!arrayIncludes(parsed.invalid, tag)) {
478
- parsed.invalid.push(tag);
479
- }
480
- }
481
- });
482
- return parsed;
483
- },
484
- validateTag(tag) {
485
- const {
486
- tagValidator
487
- } = this;
488
- return hasPropFunction(tagValidator) ? tagValidator(tag) : true;
489
- },
490
- getInput() {
491
- // Returns the input element reference (or null if not found)
492
- // We need to escape `computedInputId` since it can be user-provided
493
- return select(`#${cssEscape(this.computedInputId)}`, this.$el);
494
- },
495
- // Default User Interface render
496
- defaultRender(_ref) {
497
- let {
498
- addButtonText,
499
- addButtonVariant,
500
- addTag,
501
- disableAddButton,
502
- disabled,
503
- duplicateTagText,
504
- inputAttrs,
505
- inputClass,
506
- inputHandlers,
507
- inputType,
508
- invalidTagText,
509
- isDuplicate,
510
- isInvalid,
511
- isLimitReached,
512
- limitTagsText,
513
- noTagRemove,
514
- placeholder,
515
- removeTag,
516
- tagClass,
517
- tagPills,
518
- tagRemoveLabel,
519
- tagVariant,
520
- tags
521
- } = _ref;
522
- const h = this.$createElement;
523
-
524
- // Make the list of tags
525
- const $tags = tags.map(tag => {
526
- tag = toString(tag);
527
- return h(BFormTag, {
528
- class: tagClass,
529
- // `BFormTag` will auto generate an ID
530
- // so we do not need to set the ID prop
531
- props: {
532
- disabled,
533
- noRemove: noTagRemove,
534
- pill: tagPills,
535
- removeLabel: tagRemoveLabel,
536
- tag: 'li',
537
- title: tag,
538
- variant: tagVariant
539
- },
540
- on: {
541
- remove: () => removeTag(tag)
542
- },
543
- key: `tags_${tag}`
544
- }, tag);
545
- });
546
-
547
- // Feedback IDs if needed
548
- const invalidFeedbackId = invalidTagText && isInvalid ? this.safeId('__invalid_feedback__') : null;
549
- const duplicateFeedbackId = duplicateTagText && isDuplicate ? this.safeId('__duplicate_feedback__') : null;
550
- const limitFeedbackId = limitTagsText && isLimitReached ? this.safeId('__limit_feedback__') : null;
551
-
552
- // Compute the `aria-describedby` attribute value
553
- const ariaDescribedby = [inputAttrs['aria-describedby'], invalidFeedbackId, duplicateFeedbackId, limitFeedbackId].filter(identity).join(' ');
554
-
555
- // Input
556
- const $input = h('input', {
557
- staticClass: 'b-form-tags-input w-100 flex-grow-1 p-0 m-0 bg-transparent border-0',
558
- class: inputClass,
559
- style: {
560
- outline: 0,
561
- minWidth: '5rem'
562
- },
563
- attrs: {
564
- ...inputAttrs,
565
- 'aria-describedby': ariaDescribedby || null,
566
- type: inputType,
567
- placeholder: placeholder || null
568
- },
569
- domProps: {
570
- value: inputAttrs.value
571
- },
572
- on: inputHandlers,
573
- // Directive needed to get `event.target.composing` set (if needed)
574
- directives: [{
575
- name: 'model',
576
- value: inputAttrs.value
577
- }],
578
- ref: 'input'
579
- });
580
-
581
- // Add button
582
- const $button = h(BButton, {
583
- staticClass: 'b-form-tags-button py-0',
584
- class: {
585
- // Only show the button if the tag can be added
586
- // We use the `invisible` class instead of not rendering
587
- // the button, so that we maintain layout to prevent
588
- // the user input from jumping around
589
- invisible: disableAddButton
590
- },
591
- style: {
592
- fontSize: '90%'
593
- },
594
- props: {
595
- disabled: disableAddButton || isLimitReached,
596
- variant: addButtonVariant
597
- },
598
- on: {
599
- click: () => addTag()
600
- },
601
- ref: 'button'
602
- }, [this.normalizeSlot(SLOT_NAME_ADD_BUTTON_TEXT) || addButtonText]);
603
-
604
- // ID of the tags + input `<ul>` list
605
- // Note we could concatenate `inputAttrs.id` with '__tag_list__'
606
- // but `inputId` may be `null` until after mount
607
- // `safeId()` returns `null`, if no user provided ID,
608
- // until after mount when a unique ID is generated
609
- const tagListId = this.safeId('__tag_list__');
610
- const $field = h('li', {
611
- staticClass: 'b-form-tags-field flex-grow-1',
612
- attrs: {
613
- role: 'none',
614
- 'aria-live': 'off',
615
- 'aria-controls': tagListId
616
- },
617
- key: 'tags_field'
618
- }, [h('div', {
619
- staticClass: 'd-flex',
620
- attrs: {
621
- role: 'group'
622
- }
623
- }, [$input, $button])]);
624
-
625
- // Wrap in an unordered list element (we use a list for accessibility)
626
- const $ul = h('ul', {
627
- staticClass: 'b-form-tags-list list-unstyled mb-0 d-flex flex-wrap align-items-center',
628
- attrs: {
629
- id: tagListId
630
- },
631
- key: 'tags_list'
632
- }, [$tags, $field]);
633
-
634
- // Assemble the feedback
635
- let $feedback = h();
636
- if (invalidTagText || duplicateTagText || limitTagsText) {
637
- // Add an aria live region for the invalid/duplicate tag
638
- // messages if the user has not disabled the messages
639
- const {
640
- feedbackAriaLive: ariaLive,
641
- computedJoiner: joiner
642
- } = this;
643
-
644
- // Invalid tag feedback if needed (error)
645
- let $invalid = h();
646
- if (invalidFeedbackId) {
647
- $invalid = h(BFormInvalidFeedback, {
648
- props: {
649
- id: invalidFeedbackId,
650
- ariaLive,
651
- forceShow: true
652
- },
653
- key: 'tags_invalid_feedback'
654
- }, [this.invalidTagText, ': ', this.invalidTags.join(joiner)]);
655
- }
656
-
657
- // Duplicate tag feedback if needed (warning, not error)
658
- let $duplicate = h();
659
- if (duplicateFeedbackId) {
660
- $duplicate = h(BFormText, {
661
- props: {
662
- id: duplicateFeedbackId,
663
- ariaLive
664
- },
665
- key: 'tags_duplicate_feedback'
666
- }, [this.duplicateTagText, ': ', this.duplicateTags.join(joiner)]);
667
- }
668
-
669
- // Limit tags feedback if needed (warning, not error)
670
- let $limit = h();
671
- if (limitFeedbackId) {
672
- $limit = h(BFormText, {
673
- props: {
674
- id: limitFeedbackId,
675
- ariaLive
676
- },
677
- key: 'tags_limit_feedback'
678
- }, [limitTagsText]);
679
- }
680
- $feedback = h('div', {
681
- attrs: {
682
- 'aria-live': 'polite',
683
- 'aria-atomic': 'true'
684
- },
685
- key: 'tags_feedback'
686
- }, [$invalid, $duplicate, $limit]);
687
- }
688
-
689
- // Return the content
690
- return [$ul, $feedback];
691
- }
692
- },
693
- render(h) {
694
- const {
695
- name,
696
- disabled,
697
- required,
698
- form,
699
- tags,
700
- computedInputId,
701
- hasFocus,
702
- noOuterFocus
703
- } = this;
704
-
705
- // Scoped slot properties
706
- const scope = {
707
- // Array of tags (shallow copy to prevent mutations)
708
- tags: tags.slice(),
709
- // <input> v-bind:inputAttrs
710
- inputAttrs: this.computedInputAttrs,
711
- // We don't include this in the attrs, as users may want to override this
712
- inputType: this.computedInputType,
713
- // <input> v-on:inputHandlers
714
- inputHandlers: this.computedInputHandlers,
715
- // Methods
716
- removeTag: this.removeTag,
717
- addTag: this.addTag,
718
- reset: this.reset,
719
- // <input> :id="inputId"
720
- inputId: computedInputId,
721
- // Invalid/Duplicate state information
722
- isInvalid: this.hasInvalidTags,
723
- invalidTags: this.invalidTags.slice(),
724
- isDuplicate: this.hasDuplicateTags,
725
- duplicateTags: this.duplicateTags.slice(),
726
- isLimitReached: this.isLimitReached,
727
- // If the 'Add' button should be disabled
728
- disableAddButton: this.disableAddButton,
729
- // Pass-through props
730
- ...pick(this.$props, ['addButtonText', 'addButtonVariant', 'disabled', 'duplicateTagText', 'form', 'inputClass', 'invalidTagText', 'limit', 'limitTagsText', 'noTagRemove', 'placeholder', 'required', 'separator', 'size', 'state', 'tagClass', 'tagPills', 'tagRemoveLabel', 'tagVariant'])
731
- };
732
-
733
- // Generate the user interface
734
- const $content = this.normalizeSlot(SLOT_NAME_DEFAULT, scope) || this.defaultRender(scope);
735
-
736
- // Generate the `aria-live` region for the current value(s)
737
- const $output = h('output', {
738
- staticClass: 'sr-only',
739
- attrs: {
740
- id: this.safeId('__selected_tags__'),
741
- role: 'status',
742
- for: computedInputId,
743
- 'aria-live': hasFocus ? 'polite' : 'off',
744
- 'aria-atomic': 'true',
745
- 'aria-relevant': 'additions text'
746
- }
747
- }, this.tags.join(', '));
748
-
749
- // Removed tag live region
750
- const $removed = h('div', {
751
- staticClass: 'sr-only',
752
- attrs: {
753
- id: this.safeId('__removed_tags__'),
754
- role: 'status',
755
- 'aria-live': hasFocus ? 'assertive' : 'off',
756
- 'aria-atomic': 'true'
757
- }
758
- }, this.removedTags.length > 0 ? `(${this.tagRemovedLabel}) ${this.removedTags.join(', ')}` : '');
759
-
760
- // Add hidden inputs for form submission
761
- let $hidden = h();
762
- if (name && !disabled) {
763
- // We add hidden inputs for each tag if a name is provided
764
- // When there are currently no tags, a visually hidden input
765
- // with empty value is rendered for proper required handling
766
- const hasTags = tags.length > 0;
767
- $hidden = (hasTags ? tags : ['']).map(tag => {
768
- return h('input', {
769
- class: {
770
- 'sr-only': !hasTags
771
- },
772
- attrs: {
773
- type: hasTags ? 'hidden' : 'text',
774
- value: tag,
775
- required,
776
- name,
777
- form
778
- },
779
- key: `tag_input_${tag}`
780
- });
781
- });
782
- }
783
-
784
- // Return the rendered output
785
- return h('div', {
786
- staticClass: 'b-form-tags form-control h-auto',
787
- class: [{
788
- focus: hasFocus && !noOuterFocus && !disabled,
789
- disabled
790
- }, this.sizeFormClass, this.stateClass],
791
- attrs: {
792
- id: this.safeId(),
793
- role: 'group',
794
- tabindex: disabled || noOuterFocus ? null : '-1',
795
- 'aria-describedby': this.safeId('__selected_tags__')
796
- },
797
- on: {
798
- click: this.onClick,
799
- focusin: this.onFocusin,
800
- focusout: this.onFocusout
801
- }
802
- }, [$output, $removed, $content, $hidden]);
803
- }
804
- });
805
-
806
- export { BFormTags };