@watermarkinsights/ripple 5.13.0-alpha.3 → 5.13.0-alpha.4

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 (476) hide show
  1. package/dist/{components/index.js → ripple/app-globals-B7cOtGhY.js} +82 -3
  2. package/dist/{components/chartFunctions.js → ripple/chartFunctions-KaEM0xh0.js} +3 -2
  3. package/dist/{components/functions.js → ripple/functions-Dtrjc9kR.js} +7828 -146
  4. package/dist/ripple/index-CU5QNCKv.js +4167 -0
  5. package/dist/ripple/index.esm.js +1 -0
  6. package/dist/{collection/global/interfaces.js → ripple/interfaces-CrANcZM9.js} +6 -4
  7. package/dist/{esm/intl-DYVRT1s6.js → ripple/intl-BMoOWb_l.js} +1 -1
  8. package/dist/ripple/priv-calendar.entry.js +566 -0
  9. package/dist/ripple/{p-65db2c0f.entry.js → priv-chart-popover.entry.js} +134 -1
  10. package/dist/{esm-es5/wm-modal-pss-header.entry.js → ripple/priv-navigator-button.entry.js} +24 -1
  11. package/dist/ripple/priv-navigator-item.entry.js +30 -0
  12. package/dist/{esm-es5/wm-navigation.entry.js → ripple/priv-option-list.entry.js} +385 -1
  13. package/dist/ripple/ripple.css +1645 -1
  14. package/dist/ripple/ripple.esm.js +48 -1
  15. package/dist/ripple/wm-action-menu.entry.js +201 -0
  16. package/dist/{esm-es5/wm-navigator.entry.js → ripple/wm-button.entry.js} +197 -1
  17. package/dist/{esm → ripple}/wm-chart-slice.entry.js +1 -1
  18. package/dist/ripple/wm-chart.entry.js +157 -0
  19. package/dist/ripple/wm-date-range.entry.js +477 -0
  20. package/dist/ripple/wm-datepicker.entry.js +247 -0
  21. package/dist/ripple/wm-file-list.entry.js +18 -0
  22. package/dist/ripple/wm-file.entry.js +182 -0
  23. package/dist/ripple/wm-input.entry.js +111 -0
  24. package/dist/ripple/wm-line-chart.entry.js +449 -0
  25. package/dist/ripple/wm-menuitem.entry.js +125 -0
  26. package/dist/{esm-es5/priv-calendar.entry.js → ripple/wm-modal-footer.entry.js} +44 -1
  27. package/dist/{esm-es5/wm-chart.entry.js → ripple/wm-modal-header.entry.js} +36 -1
  28. package/dist/ripple/{p-2d41fbed.system.entry.js → wm-modal-pss-footer.entry.js} +40 -1
  29. package/dist/{esm-es5/wm-modal-header.entry.js → ripple/wm-modal-pss-header.entry.js} +39 -1
  30. package/dist/ripple/{p-d4481342.system.entry.js → wm-modal-pss.entry.js} +135 -1
  31. package/dist/ripple/wm-modal.entry.js +133 -0
  32. package/dist/ripple/wm-navigation-hamburger.entry.js +48 -0
  33. package/dist/{esm-es5 → ripple}/wm-navigation-item.entry.js +18 -1
  34. package/dist/ripple/{p-8a33538f.entry.js → wm-navigation.entry.js} +116 -1
  35. package/dist/ripple/wm-navigator.entry.js +368 -0
  36. package/dist/ripple/wm-nested-select.entry.js +308 -0
  37. package/dist/ripple/wm-optgroup.entry.js +68 -0
  38. package/dist/ripple/{p-997bdd2e.system.entry.js → wm-option.entry.js} +171 -1
  39. package/dist/ripple/wm-pagination.entry.js +223 -0
  40. package/dist/ripple/wm-progress-indicator.entry.js +107 -0
  41. package/dist/ripple/wm-progress-monitor.entry.js +71 -0
  42. package/dist/{esm → ripple}/wm-progress-slice.entry.js +1 -1
  43. package/dist/ripple/{p-d20ed498.entry.js → wm-search.entry.js} +208 -1
  44. package/dist/ripple/{p-e0c9798d.system.entry.js → wm-select.entry.js} +249 -1
  45. package/dist/ripple/wm-snackbar.entry.js +178 -0
  46. package/dist/{esm-es5 → ripple}/wm-tab-item.entry.js +63 -1
  47. package/dist/ripple/{p-8b9c4e3e.entry.js → wm-tab-list.entry.js} +175 -1
  48. package/dist/ripple/wm-tab-panel.entry.js +32 -0
  49. package/dist/ripple/wm-tag-input.entry.js +877 -0
  50. package/dist/{esm → ripple}/wm-tag-option.entry.js +2 -2
  51. package/dist/ripple/wm-textarea.entry.js +79 -0
  52. package/dist/ripple/wm-timepicker.entry.js +300 -0
  53. package/dist/{esm-es5/wm-progress-monitor.entry.js → ripple/wm-toggletip.entry.js} +176 -1
  54. package/dist/ripple/wm-uploader.entry.js +313 -0
  55. package/dist/{esm → ripple}/wm-wrapper.entry.js +1 -1
  56. package/package.json +30 -6
  57. package/dist/cjs/app-globals-DztnjEf7.js +0 -92
  58. package/dist/cjs/chartFunctions-CM2Nah_s.js +0 -731
  59. package/dist/cjs/functions-CoXfjC6r.js +0 -10450
  60. package/dist/cjs/index-Cig4P4gJ.js +0 -2082
  61. package/dist/cjs/index.cjs.js +0 -2
  62. package/dist/cjs/interfaces-C7YbtGnk.js +0 -37
  63. package/dist/cjs/intl-DVt1J717.js +0 -283
  64. package/dist/cjs/loader.cjs.js +0 -13
  65. package/dist/cjs/priv-calendar.cjs.entry.js +0 -568
  66. package/dist/cjs/priv-chart-popover.cjs.entry.js +0 -136
  67. package/dist/cjs/priv-navigator-button_2.cjs.entry.js +0 -54
  68. package/dist/cjs/priv-option-list_2.cjs.entry.js +0 -556
  69. package/dist/cjs/ripple.cjs.js +0 -25
  70. package/dist/cjs/wm-action-menu_4.cjs.entry.js +0 -702
  71. package/dist/cjs/wm-chart-slice.cjs.entry.js +0 -20
  72. package/dist/cjs/wm-chart.cjs.entry.js +0 -159
  73. package/dist/cjs/wm-date-range.cjs.entry.js +0 -479
  74. package/dist/cjs/wm-datepicker.cjs.entry.js +0 -249
  75. package/dist/cjs/wm-file-list.cjs.entry.js +0 -20
  76. package/dist/cjs/wm-file.cjs.entry.js +0 -184
  77. package/dist/cjs/wm-input.cjs.entry.js +0 -113
  78. package/dist/cjs/wm-line-chart.cjs.entry.js +0 -451
  79. package/dist/cjs/wm-modal-footer.cjs.entry.js +0 -46
  80. package/dist/cjs/wm-modal-header.cjs.entry.js +0 -38
  81. package/dist/cjs/wm-modal-pss-footer.cjs.entry.js +0 -42
  82. package/dist/cjs/wm-modal-pss-header.cjs.entry.js +0 -41
  83. package/dist/cjs/wm-modal-pss.cjs.entry.js +0 -137
  84. package/dist/cjs/wm-modal.cjs.entry.js +0 -135
  85. package/dist/cjs/wm-navigation-hamburger.cjs.entry.js +0 -50
  86. package/dist/cjs/wm-navigation-item.cjs.entry.js +0 -20
  87. package/dist/cjs/wm-navigation.cjs.entry.js +0 -118
  88. package/dist/cjs/wm-navigator.cjs.entry.js +0 -329
  89. package/dist/cjs/wm-nested-select.cjs.entry.js +0 -310
  90. package/dist/cjs/wm-optgroup.cjs.entry.js +0 -70
  91. package/dist/cjs/wm-pagination.cjs.entry.js +0 -225
  92. package/dist/cjs/wm-progress-indicator.cjs.entry.js +0 -109
  93. package/dist/cjs/wm-progress-monitor.cjs.entry.js +0 -73
  94. package/dist/cjs/wm-progress-slice.cjs.entry.js +0 -15
  95. package/dist/cjs/wm-search.cjs.entry.js +0 -210
  96. package/dist/cjs/wm-select.cjs.entry.js +0 -251
  97. package/dist/cjs/wm-tab-item.cjs.entry.js +0 -65
  98. package/dist/cjs/wm-tab-list.cjs.entry.js +0 -177
  99. package/dist/cjs/wm-tab-panel.cjs.entry.js +0 -34
  100. package/dist/cjs/wm-tag-input.cjs.entry.js +0 -879
  101. package/dist/cjs/wm-tag-option.cjs.entry.js +0 -37
  102. package/dist/cjs/wm-textarea.cjs.entry.js +0 -81
  103. package/dist/cjs/wm-timepicker.cjs.entry.js +0 -302
  104. package/dist/cjs/wm-toggletip.cjs.entry.js +0 -178
  105. package/dist/cjs/wm-uploader.cjs.entry.js +0 -315
  106. package/dist/cjs/wm-wrapper.cjs.entry.js +0 -19
  107. package/dist/collection/collection-manifest.json +0 -58
  108. package/dist/collection/components/charts/chartFunctions.js +0 -665
  109. package/dist/collection/components/charts/priv-chart-popover/priv-chart-popover.css +0 -908
  110. package/dist/collection/components/charts/priv-chart-popover/priv-chart-popover.js +0 -261
  111. package/dist/collection/components/charts/wm-chart/wm-chart-slice.js +0 -128
  112. package/dist/collection/components/charts/wm-chart/wm-chart.css +0 -1274
  113. package/dist/collection/components/charts/wm-chart/wm-chart.js +0 -445
  114. package/dist/collection/components/charts/wm-line-chart/wm-line-chart.css +0 -1067
  115. package/dist/collection/components/charts/wm-line-chart/wm-line-chart.js +0 -742
  116. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-indicator.css +0 -1274
  117. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-indicator.js +0 -271
  118. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-monitor.css +0 -909
  119. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-monitor.js +0 -154
  120. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-slice.js +0 -124
  121. package/dist/collection/components/datepickers/datepicker.css +0 -1044
  122. package/dist/collection/components/datepickers/priv-calendar/priv-calendar.css +0 -1279
  123. package/dist/collection/components/datepickers/priv-calendar/priv-calendar.js +0 -849
  124. package/dist/collection/components/datepickers/wm-date-range.js +0 -869
  125. package/dist/collection/components/datepickers/wm-datepicker.js +0 -538
  126. package/dist/collection/components/selects/priv-option-list/priv-option-list.css +0 -918
  127. package/dist/collection/components/selects/priv-option-list/priv-option-list.js +0 -791
  128. package/dist/collection/components/selects/wm-nested-select/wm-nested-select.css +0 -1181
  129. package/dist/collection/components/selects/wm-nested-select/wm-nested-select.js +0 -644
  130. package/dist/collection/components/selects/wm-optgroup/wm-optgroup.css +0 -830
  131. package/dist/collection/components/selects/wm-optgroup/wm-optgroup.js +0 -265
  132. package/dist/collection/components/selects/wm-option/wm-option.css +0 -931
  133. package/dist/collection/components/selects/wm-option/wm-option.js +0 -539
  134. package/dist/collection/components/selects/wm-select/wm-select.css +0 -1104
  135. package/dist/collection/components/selects/wm-select/wm-select.js +0 -606
  136. package/dist/collection/components/wm-action-menu/wm-action-menu.css +0 -891
  137. package/dist/collection/components/wm-action-menu/wm-action-menu.js +0 -444
  138. package/dist/collection/components/wm-button/wm-button.css +0 -1261
  139. package/dist/collection/components/wm-button/wm-button.js +0 -510
  140. package/dist/collection/components/wm-file/wm-file.css +0 -927
  141. package/dist/collection/components/wm-file/wm-file.js +0 -423
  142. package/dist/collection/components/wm-file-list/wm-file-list.css +0 -820
  143. package/dist/collection/components/wm-file-list/wm-file-list.js +0 -47
  144. package/dist/collection/components/wm-input/wm-input.css +0 -993
  145. package/dist/collection/components/wm-input/wm-input.js +0 -498
  146. package/dist/collection/components/wm-menuitem/wm-menuitem.css +0 -891
  147. package/dist/collection/components/wm-menuitem/wm-menuitem.js +0 -425
  148. package/dist/collection/components/wm-modal/wm-modal-footer.css +0 -845
  149. package/dist/collection/components/wm-modal/wm-modal-footer.js +0 -152
  150. package/dist/collection/components/wm-modal/wm-modal-header.css +0 -844
  151. package/dist/collection/components/wm-modal/wm-modal-header.js +0 -83
  152. package/dist/collection/components/wm-modal/wm-modal.css +0 -892
  153. package/dist/collection/components/wm-modal/wm-modal.js +0 -356
  154. package/dist/collection/components/wm-modal-pss/wm-modal-pss-footer.css +0 -852
  155. package/dist/collection/components/wm-modal-pss/wm-modal-pss-footer.js +0 -148
  156. package/dist/collection/components/wm-modal-pss/wm-modal-pss-header.css +0 -846
  157. package/dist/collection/components/wm-modal-pss/wm-modal-pss-header.js +0 -86
  158. package/dist/collection/components/wm-modal-pss/wm-modal-pss.css +0 -928
  159. package/dist/collection/components/wm-modal-pss/wm-modal-pss.js +0 -369
  160. package/dist/collection/components/wm-navigation/wm-navigation-hamburger.css +0 -847
  161. package/dist/collection/components/wm-navigation/wm-navigation-hamburger.js +0 -120
  162. package/dist/collection/components/wm-navigation/wm-navigation-item.css +0 -856
  163. package/dist/collection/components/wm-navigation/wm-navigation-item.js +0 -99
  164. package/dist/collection/components/wm-navigation/wm-navigation.css +0 -898
  165. package/dist/collection/components/wm-navigation/wm-navigation.js +0 -192
  166. package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.css +0 -850
  167. package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.js +0 -90
  168. package/dist/collection/components/wm-navigator/priv-navigator-item/priv-navigator-item.css +0 -830
  169. package/dist/collection/components/wm-navigator/priv-navigator-item/priv-navigator-item.js +0 -130
  170. package/dist/collection/components/wm-navigator/wm-navigator.css +0 -903
  171. package/dist/collection/components/wm-navigator/wm-navigator.js +0 -515
  172. package/dist/collection/components/wm-pagination/wm-pagination.css +0 -971
  173. package/dist/collection/components/wm-pagination/wm-pagination.js +0 -373
  174. package/dist/collection/components/wm-search/wm-search.css +0 -896
  175. package/dist/collection/components/wm-search/wm-search.js +0 -462
  176. package/dist/collection/components/wm-snackbar/wm-snackbar.css +0 -1078
  177. package/dist/collection/components/wm-snackbar/wm-snackbar.js +0 -280
  178. package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.css +0 -869
  179. package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.js +0 -187
  180. package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.css +0 -841
  181. package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.js +0 -276
  182. package/dist/collection/components/wm-tabs/wm-tab-panel/wm-tab-panel.css +0 -825
  183. package/dist/collection/components/wm-tabs/wm-tab-panel/wm-tab-panel.js +0 -97
  184. package/dist/collection/components/wm-tag-input/wm-tag-input.css +0 -1276
  185. package/dist/collection/components/wm-tag-input/wm-tag-input.js +0 -1245
  186. package/dist/collection/components/wm-tag-input/wm-tag-option/wm-tag-option.js +0 -251
  187. package/dist/collection/components/wm-textarea/wm-textarea.css +0 -980
  188. package/dist/collection/components/wm-textarea/wm-textarea.js +0 -331
  189. package/dist/collection/components/wm-timepicker/wm-timepicker.css +0 -1094
  190. package/dist/collection/components/wm-timepicker/wm-timepicker.js +0 -559
  191. package/dist/collection/components/wm-toggletip/wm-toggletip.css +0 -1152
  192. package/dist/collection/components/wm-toggletip/wm-toggletip.js +0 -295
  193. package/dist/collection/components/wm-uploader/wm-uploader.css +0 -1563
  194. package/dist/collection/components/wm-uploader/wm-uploader.js +0 -618
  195. package/dist/collection/components/wm-wrapper/wm-wrapper.js +0 -28
  196. package/dist/collection/dev/action-menu.js +0 -0
  197. package/dist/collection/dev/button.js +0 -0
  198. package/dist/collection/dev/chart-small.js +0 -56
  199. package/dist/collection/dev/chart.js +0 -18
  200. package/dist/collection/dev/date-range.js +0 -6
  201. package/dist/collection/dev/datepicker.js +0 -46
  202. package/dist/collection/dev/file-list.js +0 -16
  203. package/dist/collection/dev/file.js +0 -0
  204. package/dist/collection/dev/input.js +0 -6
  205. package/dist/collection/dev/line-chart.js +0 -0
  206. package/dist/collection/dev/modal.js +0 -48
  207. package/dist/collection/dev/navigation.js +0 -13
  208. package/dist/collection/dev/navigator.js +0 -34
  209. package/dist/collection/dev/nested-select.js +0 -36
  210. package/dist/collection/dev/pagination.js +0 -7
  211. package/dist/collection/dev/progress-monitor.js +0 -0
  212. package/dist/collection/dev/pss-modal.js +0 -8
  213. package/dist/collection/dev/scripts.js +0 -49
  214. package/dist/collection/dev/search.js +0 -72
  215. package/dist/collection/dev/select.js +0 -57
  216. package/dist/collection/dev/snackbar.js +0 -60
  217. package/dist/collection/dev/tabs.js +0 -44
  218. package/dist/collection/dev/tag-input.js +0 -32
  219. package/dist/collection/dev/textarea.js +0 -28
  220. package/dist/collection/dev/timepicker.js +0 -32
  221. package/dist/collection/dev/toggletip.js +0 -9
  222. package/dist/collection/dev/uploader.js +0 -139
  223. package/dist/collection/global/__mocks__/functions.js +0 -6
  224. package/dist/collection/global/functions.js +0 -825
  225. package/dist/collection/global/global.js +0 -88
  226. package/dist/collection/global/intl.js +0 -274
  227. package/dist/collection/global/services/__mocks__/http-service.js +0 -130
  228. package/dist/collection/global/services/http-service.js +0 -50
  229. package/dist/collection/lang/lang.js +0 -5
  230. package/dist/collection/lang/missing.js +0 -43
  231. package/dist/collection/lang/piglatin.js +0 -101
  232. package/dist/components/interfaces.js +0 -34
  233. package/dist/components/intl.js +0 -277
  234. package/dist/components/priv-calendar.js +0 -6
  235. package/dist/components/priv-calendar2.js +0 -592
  236. package/dist/components/priv-chart-popover.js +0 -6
  237. package/dist/components/priv-chart-popover2.js +0 -154
  238. package/dist/components/priv-navigator-button.js +0 -6
  239. package/dist/components/priv-navigator-button2.js +0 -42
  240. package/dist/components/priv-navigator-item.js +0 -6
  241. package/dist/components/priv-navigator-item2.js +0 -49
  242. package/dist/components/priv-option-list.js +0 -6
  243. package/dist/components/priv-option-list2.js +0 -421
  244. package/dist/components/wm-action-menu.js +0 -6
  245. package/dist/components/wm-action-menu2.js +0 -231
  246. package/dist/components/wm-button.js +0 -6
  247. package/dist/components/wm-button2.js +0 -231
  248. package/dist/components/wm-chart-slice.js +0 -41
  249. package/dist/components/wm-chart.js +0 -197
  250. package/dist/components/wm-date-range.js +0 -522
  251. package/dist/components/wm-datepicker.js +0 -287
  252. package/dist/components/wm-file-list.js +0 -38
  253. package/dist/components/wm-file.js +0 -228
  254. package/dist/components/wm-input.js +0 -152
  255. package/dist/components/wm-line-chart.js +0 -497
  256. package/dist/components/wm-menuitem.js +0 -6
  257. package/dist/components/wm-menuitem2.js +0 -146
  258. package/dist/components/wm-modal-footer.js +0 -73
  259. package/dist/components/wm-modal-header.js +0 -61
  260. package/dist/components/wm-modal-pss-footer.js +0 -69
  261. package/dist/components/wm-modal-pss-header.js +0 -64
  262. package/dist/components/wm-modal-pss.js +0 -162
  263. package/dist/components/wm-modal.js +0 -161
  264. package/dist/components/wm-navigation-hamburger.js +0 -70
  265. package/dist/components/wm-navigation-item.js +0 -40
  266. package/dist/components/wm-navigation.js +0 -144
  267. package/dist/components/wm-navigator.js +0 -369
  268. package/dist/components/wm-nested-select.js +0 -343
  269. package/dist/components/wm-optgroup.js +0 -107
  270. package/dist/components/wm-option.js +0 -6
  271. package/dist/components/wm-option2.js +0 -196
  272. package/dist/components/wm-pagination.js +0 -251
  273. package/dist/components/wm-progress-indicator.js +0 -144
  274. package/dist/components/wm-progress-monitor.js +0 -93
  275. package/dist/components/wm-progress-slice.js +0 -37
  276. package/dist/components/wm-search.js +0 -250
  277. package/dist/components/wm-select.js +0 -6
  278. package/dist/components/wm-select2.js +0 -294
  279. package/dist/components/wm-snackbar.js +0 -210
  280. package/dist/components/wm-tab-item.js +0 -85
  281. package/dist/components/wm-tab-list.js +0 -217
  282. package/dist/components/wm-tab-panel.js +0 -52
  283. package/dist/components/wm-tag-input.js +0 -919
  284. package/dist/components/wm-tag-option.js +0 -63
  285. package/dist/components/wm-textarea.js +0 -113
  286. package/dist/components/wm-timepicker.js +0 -333
  287. package/dist/components/wm-toggletip.js +0 -200
  288. package/dist/components/wm-uploader.js +0 -348
  289. package/dist/components/wm-wrapper.js +0 -34
  290. package/dist/esm/app-globals-9HoPoE5v.js +0 -90
  291. package/dist/esm/chartFunctions-BFCUD5JX.js +0 -714
  292. package/dist/esm/functions-ZDMCMR3o.js +0 -10410
  293. package/dist/esm/index-EopL5zo4.js +0 -2071
  294. package/dist/esm/index.js +0 -1
  295. package/dist/esm/interfaces-CyJHzEjr.js +0 -34
  296. package/dist/esm/loader.js +0 -11
  297. package/dist/esm/polyfills/core-js.js +0 -11
  298. package/dist/esm/polyfills/dom.js +0 -79
  299. package/dist/esm/polyfills/es5-html-element.js +0 -1
  300. package/dist/esm/polyfills/index.js +0 -34
  301. package/dist/esm/polyfills/system.js +0 -6
  302. package/dist/esm/priv-calendar.entry.js +0 -566
  303. package/dist/esm/priv-chart-popover.entry.js +0 -134
  304. package/dist/esm/priv-navigator-button_2.entry.js +0 -51
  305. package/dist/esm/priv-option-list_2.entry.js +0 -553
  306. package/dist/esm/ripple.js +0 -21
  307. package/dist/esm/wm-action-menu_4.entry.js +0 -697
  308. package/dist/esm/wm-chart.entry.js +0 -157
  309. package/dist/esm/wm-date-range.entry.js +0 -477
  310. package/dist/esm/wm-datepicker.entry.js +0 -247
  311. package/dist/esm/wm-file-list.entry.js +0 -18
  312. package/dist/esm/wm-file.entry.js +0 -182
  313. package/dist/esm/wm-input.entry.js +0 -111
  314. package/dist/esm/wm-line-chart.entry.js +0 -449
  315. package/dist/esm/wm-modal-footer.entry.js +0 -44
  316. package/dist/esm/wm-modal-header.entry.js +0 -36
  317. package/dist/esm/wm-modal-pss-footer.entry.js +0 -40
  318. package/dist/esm/wm-modal-pss-header.entry.js +0 -39
  319. package/dist/esm/wm-modal-pss.entry.js +0 -135
  320. package/dist/esm/wm-modal.entry.js +0 -133
  321. package/dist/esm/wm-navigation-hamburger.entry.js +0 -48
  322. package/dist/esm/wm-navigation-item.entry.js +0 -18
  323. package/dist/esm/wm-navigation.entry.js +0 -116
  324. package/dist/esm/wm-navigator.entry.js +0 -327
  325. package/dist/esm/wm-nested-select.entry.js +0 -308
  326. package/dist/esm/wm-optgroup.entry.js +0 -68
  327. package/dist/esm/wm-pagination.entry.js +0 -223
  328. package/dist/esm/wm-progress-indicator.entry.js +0 -107
  329. package/dist/esm/wm-progress-monitor.entry.js +0 -71
  330. package/dist/esm/wm-search.entry.js +0 -208
  331. package/dist/esm/wm-select.entry.js +0 -249
  332. package/dist/esm/wm-tab-item.entry.js +0 -63
  333. package/dist/esm/wm-tab-list.entry.js +0 -175
  334. package/dist/esm/wm-tab-panel.entry.js +0 -32
  335. package/dist/esm/wm-tag-input.entry.js +0 -877
  336. package/dist/esm/wm-textarea.entry.js +0 -79
  337. package/dist/esm/wm-timepicker.entry.js +0 -300
  338. package/dist/esm/wm-toggletip.entry.js +0 -176
  339. package/dist/esm/wm-uploader.entry.js +0 -313
  340. package/dist/esm-es5/app-globals-9HoPoE5v.js +0 -1
  341. package/dist/esm-es5/chartFunctions-BFCUD5JX.js +0 -1
  342. package/dist/esm-es5/functions-ZDMCMR3o.js +0 -1
  343. package/dist/esm-es5/index-EopL5zo4.js +0 -1
  344. package/dist/esm-es5/index.js +0 -0
  345. package/dist/esm-es5/interfaces-CyJHzEjr.js +0 -1
  346. package/dist/esm-es5/intl-DYVRT1s6.js +0 -1
  347. package/dist/esm-es5/loader.js +0 -1
  348. package/dist/esm-es5/priv-chart-popover.entry.js +0 -1
  349. package/dist/esm-es5/priv-navigator-button_2.entry.js +0 -1
  350. package/dist/esm-es5/priv-option-list_2.entry.js +0 -1
  351. package/dist/esm-es5/ripple.js +0 -1
  352. package/dist/esm-es5/wm-action-menu_4.entry.js +0 -1
  353. package/dist/esm-es5/wm-chart-slice.entry.js +0 -1
  354. package/dist/esm-es5/wm-date-range.entry.js +0 -1
  355. package/dist/esm-es5/wm-datepicker.entry.js +0 -1
  356. package/dist/esm-es5/wm-file-list.entry.js +0 -1
  357. package/dist/esm-es5/wm-file.entry.js +0 -1
  358. package/dist/esm-es5/wm-input.entry.js +0 -1
  359. package/dist/esm-es5/wm-line-chart.entry.js +0 -1
  360. package/dist/esm-es5/wm-modal-footer.entry.js +0 -1
  361. package/dist/esm-es5/wm-modal-pss-footer.entry.js +0 -1
  362. package/dist/esm-es5/wm-modal-pss.entry.js +0 -1
  363. package/dist/esm-es5/wm-modal.entry.js +0 -1
  364. package/dist/esm-es5/wm-navigation-hamburger.entry.js +0 -1
  365. package/dist/esm-es5/wm-nested-select.entry.js +0 -1
  366. package/dist/esm-es5/wm-optgroup.entry.js +0 -1
  367. package/dist/esm-es5/wm-pagination.entry.js +0 -1
  368. package/dist/esm-es5/wm-progress-indicator.entry.js +0 -1
  369. package/dist/esm-es5/wm-progress-slice.entry.js +0 -1
  370. package/dist/esm-es5/wm-search.entry.js +0 -1
  371. package/dist/esm-es5/wm-select.entry.js +0 -1
  372. package/dist/esm-es5/wm-tab-list.entry.js +0 -1
  373. package/dist/esm-es5/wm-tab-panel.entry.js +0 -1
  374. package/dist/esm-es5/wm-tag-input.entry.js +0 -1
  375. package/dist/esm-es5/wm-tag-option.entry.js +0 -1
  376. package/dist/esm-es5/wm-textarea.entry.js +0 -1
  377. package/dist/esm-es5/wm-timepicker.entry.js +0 -1
  378. package/dist/esm-es5/wm-toggletip.entry.js +0 -1
  379. package/dist/esm-es5/wm-uploader.entry.js +0 -1
  380. package/dist/esm-es5/wm-wrapper.entry.js +0 -1
  381. package/dist/index.cjs.js +0 -1
  382. package/dist/index.js +0 -1
  383. package/dist/loader/cdn.js +0 -2
  384. package/dist/loader/index.cjs.js +0 -2
  385. package/dist/loader/index.d.ts +0 -24
  386. package/dist/loader/index.es2017.js +0 -2
  387. package/dist/loader/index.js +0 -3
  388. package/dist/ripple/p-032f127e.entry.js +0 -1
  389. package/dist/ripple/p-0bd43518.system.entry.js +0 -1
  390. package/dist/ripple/p-0dccd9b4.system.entry.js +0 -1
  391. package/dist/ripple/p-0dffa9ff.system.entry.js +0 -1
  392. package/dist/ripple/p-10d2b86e.entry.js +0 -1
  393. package/dist/ripple/p-1818d7f9.entry.js +0 -1
  394. package/dist/ripple/p-18d22114.system.entry.js +0 -1
  395. package/dist/ripple/p-1a769629.system.entry.js +0 -1
  396. package/dist/ripple/p-271ba485.system.entry.js +0 -1
  397. package/dist/ripple/p-2f26b6ac.entry.js +0 -1
  398. package/dist/ripple/p-3065bbe5.system.entry.js +0 -1
  399. package/dist/ripple/p-306caa10.entry.js +0 -1
  400. package/dist/ripple/p-32f2f3b4.system.entry.js +0 -1
  401. package/dist/ripple/p-340b73a9.system.entry.js +0 -1
  402. package/dist/ripple/p-42f9cd3d.entry.js +0 -1
  403. package/dist/ripple/p-47b525bd.entry.js +0 -1
  404. package/dist/ripple/p-492a8a9f.entry.js +0 -1
  405. package/dist/ripple/p-4c316652.system.entry.js +0 -1
  406. package/dist/ripple/p-54aeadde.entry.js +0 -1
  407. package/dist/ripple/p-568e29d3.entry.js +0 -1
  408. package/dist/ripple/p-588a86ed.system.entry.js +0 -1
  409. package/dist/ripple/p-591fd100.entry.js +0 -1
  410. package/dist/ripple/p-5a6cbc14.system.entry.js +0 -1
  411. package/dist/ripple/p-5abe1171.system.entry.js +0 -1
  412. package/dist/ripple/p-5ae17300.system.entry.js +0 -1
  413. package/dist/ripple/p-5b02ae40.entry.js +0 -1
  414. package/dist/ripple/p-5e438798.system.entry.js +0 -1
  415. package/dist/ripple/p-5ed4177e.entry.js +0 -1
  416. package/dist/ripple/p-6133160d.system.entry.js +0 -1
  417. package/dist/ripple/p-620aff89.entry.js +0 -1
  418. package/dist/ripple/p-70ed57bf.entry.js +0 -1
  419. package/dist/ripple/p-735d033a.entry.js +0 -1
  420. package/dist/ripple/p-74b1e110.entry.js +0 -1
  421. package/dist/ripple/p-77a8306c.entry.js +0 -1
  422. package/dist/ripple/p-7886fe5e.system.entry.js +0 -1
  423. package/dist/ripple/p-7ce09692.system.entry.js +0 -1
  424. package/dist/ripple/p-7cf1d9eb.system.entry.js +0 -1
  425. package/dist/ripple/p-7e786c28.system.entry.js +0 -1
  426. package/dist/ripple/p-812615ae.entry.js +0 -1
  427. package/dist/ripple/p-90925ea9.entry.js +0 -1
  428. package/dist/ripple/p-959afdcf.entry.js +0 -1
  429. package/dist/ripple/p-9db5f78e.entry.js +0 -1
  430. package/dist/ripple/p-BexWEx3U.system.js +0 -1
  431. package/dist/ripple/p-BgmAsS86.system.js +0 -1
  432. package/dist/ripple/p-Buh1DT2-.js +0 -1
  433. package/dist/ripple/p-CLZytLAw.system.js +0 -1
  434. package/dist/ripple/p-CTau6pR2.system.js +0 -2
  435. package/dist/ripple/p-CwkTkxrj.system.js +0 -1
  436. package/dist/ripple/p-CyJHzEjr.js +0 -1
  437. package/dist/ripple/p-DXsimRMV.js +0 -1
  438. package/dist/ripple/p-EopL5zo4.js +0 -2
  439. package/dist/ripple/p-GXdCI-yj.system.js +0 -1
  440. package/dist/ripple/p-UJrCrAlw.system.js +0 -1
  441. package/dist/ripple/p-YWpyar7R.system.js +0 -1
  442. package/dist/ripple/p-ZDMCMR3o.js +0 -1
  443. package/dist/ripple/p-b0b94ac4.system.entry.js +0 -1
  444. package/dist/ripple/p-b12640bd.entry.js +0 -1
  445. package/dist/ripple/p-b16431b0.system.entry.js +0 -1
  446. package/dist/ripple/p-b43cc69f.entry.js +0 -1
  447. package/dist/ripple/p-b4917824.entry.js +0 -1
  448. package/dist/ripple/p-b55babe1.system.entry.js +0 -1
  449. package/dist/ripple/p-ba48d47a.entry.js +0 -1
  450. package/dist/ripple/p-ba8ca46b.system.entry.js +0 -1
  451. package/dist/ripple/p-bee35fef.entry.js +0 -1
  452. package/dist/ripple/p-c273bb1c.system.entry.js +0 -1
  453. package/dist/ripple/p-cdebe76b.system.entry.js +0 -1
  454. package/dist/ripple/p-ce9634a2.entry.js +0 -1
  455. package/dist/ripple/p-d3e6498c.system.entry.js +0 -1
  456. package/dist/ripple/p-d40b6ef1.system.entry.js +0 -1
  457. package/dist/ripple/p-d5bcab58.entry.js +0 -1
  458. package/dist/ripple/p-d7660e7d.entry.js +0 -1
  459. package/dist/ripple/p-d85f017a.system.entry.js +0 -1
  460. package/dist/ripple/p-da5ad94c.system.entry.js +0 -1
  461. package/dist/ripple/p-dcca5771.system.entry.js +0 -1
  462. package/dist/ripple/p-dd236f42.system.entry.js +0 -1
  463. package/dist/ripple/p-de33fd67.entry.js +0 -1
  464. package/dist/ripple/p-e3700f4c.entry.js +0 -1
  465. package/dist/ripple/p-e901154b.entry.js +0 -1
  466. package/dist/ripple/p-e9fc862d.entry.js +0 -1
  467. package/dist/ripple/p-ea885cf3.system.entry.js +0 -1
  468. package/dist/ripple/p-f4c4218c.system.entry.js +0 -1
  469. package/dist/ripple/p-f57eb234.system.entry.js +0 -1
  470. package/dist/ripple/p-f858f5f9.system.entry.js +0 -1
  471. package/dist/ripple/p-f8721463.system.entry.js +0 -1
  472. package/dist/ripple/p-f881be15.entry.js +0 -1
  473. package/dist/ripple/p-f98949ad.entry.js +0 -1
  474. package/dist/ripple/p-fdcbcdf5.entry.js +0 -1
  475. package/dist/ripple/p-sXfORL9J.js +0 -1
  476. package/dist/ripple/ripple.js +0 -127
@@ -1,1245 +0,0 @@
1
- import { h, forceUpdate } from "@stencil/core";
2
- import { csvToArray, debounce, hideTooltip, intl, measureText, shouldOpenUp, showTooltip, truncateText, findPrev, findNext, } from "../../global/functions";
3
- import { globalMessages } from "../../global/intl";
4
- export class TagInput {
5
- constructor() {
6
- this.labelPosition = "top";
7
- this.requiredField = false;
8
- this.tagInputType = "dropdown";
9
- // dropdown variant
10
- this.addNew = true;
11
- this.characterLimit = 50;
12
- this.addNewHelpText = intl.formatMessage({
13
- id: "tagInput.addNewHelpText",
14
- defaultMessage: "Press the Enter or Comma key to add a new tag.",
15
- description: "Instructional text, where tag refers to a tag UI element that can be added to a list. Use imperative",
16
- });
17
- this.selectionHelpText = intl.formatMessage({
18
- id: "tagInput.selectionHelpText",
19
- defaultMessage: "Search and select a tag.",
20
- description: "Instructional text, where tag refers to a tag UI element that can be added to a list. Use imperative",
21
- });
22
- this.maxTagsReachedMessage = intl.formatMessage({
23
- id: "tagInput.maxTagsReached",
24
- defaultMessage: "No more tags can be added because the limit has been reached.",
25
- description: "Tag refers to a tag UI element that can be added to a list.",
26
- });
27
- this.tagAreaInstructions = intl.formatMessage({
28
- id: "tagInput.tagAreaInstructions",
29
- defaultMessage: "tag selection. Press Backspace or Delete to remove a tag.",
30
- description: "Label for a UI element where a user can select from a list of tags.",
31
- });
32
- this.tagsAddedMessage = intl.formatMessage({
33
- id: "tagInput.tagsAdded",
34
- defaultMessage: "Tags added",
35
- description: "Tag refers to a tag UI element that can be added to a list. Full message for context: 'Tags added: x/y",
36
- });
37
- this.noResultsMessage = intl.formatMessage({
38
- id: "tagInput.noResults",
39
- defaultMessage: "No results match your search.",
40
- });
41
- this.openUp = false;
42
- this.inModal = false;
43
- this.isKeying = false;
44
- this.isExpanded = false;
45
- this.liveRegionMessage = "";
46
- this.focusedColumn = 0;
47
- this.tagsList = []; // options to render as tags. This needs the be kept in state as tags should be shown in the order they are added
48
- this.debouncedUpdate = debounce(() => forceUpdate(this.el), 30);
49
- }
50
- addNewTagMessage(newTagName) {
51
- return intl.formatMessage({
52
- id: "tagInput.addNewTag",
53
- defaultMessage: "Add {newTagName}",
54
- description: "Button text to add a new tag to a list of tags",
55
- }, { newTagName: newTagName });
56
- }
57
- toggleKeyingOn() {
58
- this.isKeying = true;
59
- }
60
- toggleKeyingOff() {
61
- this.isKeying = false;
62
- }
63
- get isDropdown() {
64
- return this.tagInputType === "dropdown";
65
- }
66
- get isTable() {
67
- return this.tagInputType === "table";
68
- }
69
- get charCount() {
70
- return this.inputEl ? this.inputEl.value.length : 0;
71
- }
72
- get tooltipVisible() {
73
- return document.getElementById("wm-tooltip").classList.contains("show");
74
- }
75
- get optionEls() {
76
- return Array.from(this.el.querySelectorAll("wm-tag-option"));
77
- }
78
- // list of options matching user query
79
- get filteredOptionEls() {
80
- const query = this.inputEl ? this.inputEl.value.toLowerCase() : "";
81
- const list = Array.from(this.optionEls).filter((o) => {
82
- let values = "";
83
- if (this.isDropdown) {
84
- values = o.textContent.toLowerCase();
85
- }
86
- else if (this.isTable) {
87
- values = [o.col1, o.col2, o.col3, o.col4].join("").toLowerCase();
88
- }
89
- return values.includes(query);
90
- });
91
- return list;
92
- }
93
- // the ones that should be rendered as tags
94
- get taggedOptions() {
95
- return this.optionEls.filter((o) => o.selected || o.locked);
96
- }
97
- // for visual stuff (measuring, truncating...)
98
- get _tagEls() {
99
- return this.tagAreaEl ? Array.from(this.tagAreaEl.querySelectorAll(".tag")) : [];
100
- }
101
- get focusedTag() {
102
- if (this.focusedTagIndex !== undefined && this.focusedTagIndex >= 0) {
103
- return this._tagEls[this.focusedTagIndex];
104
- }
105
- }
106
- // get the wm-tag-option, given the internal representation (dropdown li or table tr)
107
- tagOptionFromEl(el) {
108
- return el.id === "add-new-btn" ? undefined : this.el.querySelector("#" + el.id);
109
- }
110
- // get the wm-tag-option, given the internal representation of a tag
111
- tagOptionFromTag(el) {
112
- const id = el.id.replace("tag-", "");
113
- return this.el.querySelector("#" + id);
114
- }
115
- // get the internal representation of a wm-tag-option
116
- elFromTagOption(el) {
117
- return this.el.shadowRoot.querySelector("#" + el.id);
118
- }
119
- // focusedOption state refers to the wm-tag-option. This gets the corresponding element in the shadow DOM, or the "Add New" button.
120
- get _focusedOption() {
121
- if (!!this.focusedOption) {
122
- return this.elFromTagOption(this.focusedOption);
123
- }
124
- else if (this.addNewButton && this.addNewButton.classList.contains("focused")) {
125
- return this.addNewButton;
126
- }
127
- }
128
- get _focusedCell() {
129
- if (!!this._focusedOption) {
130
- const allCells = Array.from(this._focusedOption.querySelectorAll("td"));
131
- const index = this.focusedColumn || 0;
132
- return allCells[index];
133
- }
134
- }
135
- get inputActiveDescendantId() {
136
- if (this._focusedOption) {
137
- if (this.isTable) {
138
- const cells = Array.from(this._focusedOption.querySelectorAll("td"));
139
- return cells[this.focusedColumn].id;
140
- }
141
- return this._focusedOption.id;
142
- }
143
- return null;
144
- }
145
- get tagLimitReached() {
146
- return !!(this.maxTags && this.taggedOptions.length >= this.maxTags);
147
- }
148
- get inputMinimumWidth() {
149
- if (this._tagEls) {
150
- // 150px is the minimum width of the input field, or the length of the placeholder text
151
- const inputElStyles = getComputedStyle(this.inputEl);
152
- const tagElStyles = getComputedStyle(this._tagEls[this._tagEls.length - 1]);
153
- const inputElBuffer = [
154
- inputElStyles.paddingLeft,
155
- inputElStyles.paddingRight,
156
- inputElStyles.marginLeft,
157
- inputElStyles.marginRight,
158
- tagElStyles.marginRight,
159
- ].reduce((prev, curr) => prev + parseInt(curr.replace("px", "")), 0);
160
- const minimumWidth = Math.max(150, measureText(this.inputEl, this.placeholder).width + inputElBuffer);
161
- return minimumWidth;
162
- }
163
- else {
164
- return 150;
165
- }
166
- }
167
- getTagName(o) {
168
- // when the user is typing and adding a new option, all we can pass is the text typed. so for the dropdown type the tag name is the identifier. It also takes care of duplicates. Table variant requires an id as the tag name is the first column but we want to allow duplicates here (e.g. people with the same name)
169
- return this.isDropdown ? o.textContent : o.col1;
170
- }
171
- isExistingTag(tag) {
172
- const list = this.optionEls.map((o) => this.getTagName(o).toLowerCase());
173
- return list.includes(tag.toLowerCase());
174
- }
175
- tagAddedMessage(tag) {
176
- return intl.formatMessage({
177
- id: "tagInput.tagAdded",
178
- defaultMessage: "{tagName} added.",
179
- description: "Confirmation for adding a tag UI element to a list of tags.",
180
- }, { tagName: tag });
181
- }
182
- tagRemovedMessage(tag) {
183
- return intl.formatMessage({
184
- id: "tagInput.tagRemoved",
185
- defaultMessage: "{tagName} removed.",
186
- description: "Confirmation for removing a tag UI element from a list of tags.",
187
- }, { tagName: tag });
188
- }
189
- tagAlreadyAddedMessage(tag) {
190
- return intl.formatMessage({
191
- id: "tagInput.tagAlreadyAdded",
192
- defaultMessage: "{tagName} has already been added.",
193
- description: "Alert for adding a tag UI element that is already included in the list.",
194
- }, { tagName: tag });
195
- }
196
- tagLockedMessage(tag) {
197
- return intl.formatMessage({
198
- id: "tagInput.tagLocked",
199
- defaultMessage: "{tagName} is locked and cannot be removed.",
200
- description: "Alert indicating a tag UI element cannot be removed from its list.",
201
- }, { tagName: tag });
202
- }
203
- isElOrChild(el) {
204
- return el === this.el || this.el.shadowRoot.contains(el) || this.el.contains(el);
205
- }
206
- componentWillLoad() {
207
- if (!this.placeholder) {
208
- this.placeholder = this.createPlaceholderDefault(this.addNew, this.optionEls.length > 0);
209
- }
210
- if (!this.label) {
211
- console.error("wm-tag-input must have a label property");
212
- }
213
- this.el.focus = () => {
214
- const firstFocusableTag = this._tagEls[0];
215
- if (firstFocusableTag) {
216
- this.tagAreaEl.focus();
217
- this.focusTag(firstFocusableTag);
218
- }
219
- else {
220
- this.inputEl.focus();
221
- }
222
- };
223
- // on resize of component, trigger componentDidRender -> positionInput
224
- const resizeObserver = new ResizeObserver(() => this.debouncedUpdate());
225
- resizeObserver.observe(this.el);
226
- // if within wm-modal, change max-height to vh unit
227
- if (this.el.closest("wm-modal")) {
228
- this.inModal = true;
229
- }
230
- const lockedTags = [];
231
- const regularTags = [];
232
- this.optionEls.forEach((o) => {
233
- if (o.locked) {
234
- lockedTags.push(o);
235
- }
236
- else if (o.selected) {
237
- regularTags.push(o);
238
- }
239
- });
240
- this.tagsList = [...lockedTags, ...regularTags];
241
- }
242
- componentDidLoad() {
243
- // Set up observer to announce changes in selected tags, or removed user-added tags
244
- const observerAnnouncer = new MutationObserver((optionListMutations) => optionListMutations.forEach((mutationRecord) => this.handleChangeAnnouncement(mutationRecord)));
245
- observerAnnouncer.observe(this.el, {
246
- subtree: true,
247
- attributes: true,
248
- attributeFilter: ["selected"],
249
- childList: true,
250
- });
251
- // Set up observer that ensures parent reload
252
- // when children wm-tag-options are removed
253
- const optionListObserver = new MutationObserver((optionListMutations) => optionListMutations.forEach((mutationRecord) => this.handleOptionListChange(mutationRecord)));
254
- optionListObserver.observe(this.el, {
255
- childList: true,
256
- });
257
- // Set up the observer that will handle focus
258
- // when tag list changes
259
- if (!!this.tagAreaEl) {
260
- const tagListObserver = new MutationObserver((tagListMutations) => tagListMutations.forEach((mutationRecord) => this.handleTagListChange(mutationRecord)));
261
- tagListObserver.observe(this.tagAreaEl, {
262
- childList: true,
263
- });
264
- }
265
- }
266
- handleChangeAnnouncement(mutationRecord) {
267
- const tagOptionEl = mutationRecord.target;
268
- if (mutationRecord.type == "childList" && mutationRecord.removedNodes.length > 0) {
269
- // announce deselection of user-added tag, whose element removal is picked up
270
- this.announce(this.tagRemovedMessage(mutationRecord.removedNodes[0].textContent));
271
- }
272
- else if (mutationRecord.type == "attributes") {
273
- const tagName = this.getTagName(tagOptionEl);
274
- // announce selection or deselection of all kinds of tags
275
- if (tagOptionEl.selected) {
276
- let changeAnnouncement = this.tagAddedMessage(tagName);
277
- if (this.tagLimitReached) {
278
- changeAnnouncement += ` ${this.maxTagsReachedMessage}`;
279
- }
280
- this.announce(changeAnnouncement);
281
- }
282
- else {
283
- this.announce(this.tagRemovedMessage(tagName));
284
- }
285
- }
286
- }
287
- handleOptionListChange(record) {
288
- const addedNodes = Array.from(record.addedNodes);
289
- if (addedNodes.length > 0) {
290
- addedNodes.forEach((n) => !this.tagsList.includes(n) && this.tagsList.push(n));
291
- }
292
- const removedNodes = Array.from(record.removedNodes);
293
- if (removedNodes.length > 0) {
294
- this.tagsList = this.tagsList.filter((t) => !removedNodes.includes(t));
295
- }
296
- }
297
- handleTagOptionSelected(ev) {
298
- const selOption = ev.target;
299
- this.tagsList = this.tagsList.concat(selOption);
300
- }
301
- handleTagOptionDeselected(ev) {
302
- const deselOption = ev.target;
303
- this.tagsList = this.tagsList.filter((t) => t != deselOption);
304
- }
305
- handleTagListChange(mutationRecord) {
306
- const addedTags = Array.from(mutationRecord.addedNodes);
307
- if (!!addedTags) {
308
- addedTags.forEach((t) => {
309
- t.classList.add("highlight");
310
- });
311
- }
312
- // there are 2 cases: the option still exists but is no longer selected,
313
- // or it was removed altogether
314
- const removedTag = mutationRecord.removedNodes[0];
315
- if (!!removedTag) {
316
- removedTag.classList.remove("highlight");
317
- // this is a trick. focusedTag gets the ref from an index. When an element
318
- // is removed it will fall back on the new element with that index if it exists
319
- if (this.focusedTag) {
320
- this.focusTag(this.focusedTag);
321
- }
322
- else if (this._tagEls.length > 0) {
323
- // Otherwise the last tag was deleted and we reassign to the new last tag.
324
- const tagToFocus = this._tagEls[this._tagEls.length - 1];
325
- this.focusTag(tagToFocus);
326
- }
327
- else {
328
- // unless there are no more tags...
329
- this.inputEl.focus();
330
- }
331
- }
332
- }
333
- componentDidRender() {
334
- this.positionInput();
335
- // check each tag if truncation is needed
336
- this._tagEls.forEach((tag) => {
337
- const textEl = tag.querySelector(".tag-text");
338
- const wrapper = this.el.shadowRoot.querySelector(".tags-and-input-wrapper");
339
- const leftBound = textEl.getBoundingClientRect().left;
340
- // the numbers represent spacing values for padding, margin, and delete icon
341
- const rightBound = wrapper.getBoundingClientRect().right - 10 - 8 - 28;
342
- const id = tag.id.replace("tag-", "");
343
- const optionEl = id && this.el.querySelector("#" + id);
344
- if (optionEl) {
345
- // tag text for table variant is first column text
346
- textEl.textContent = truncateText(textEl, this.getTagName(optionEl), rightBound - leftBound, 5);
347
- }
348
- });
349
- }
350
- createPlaceholderDefault(addNew, hasOptions) {
351
- const addAndSearchPlaceholder = intl.formatMessage({
352
- id: "tagInput.placeholderAddAndSearch",
353
- defaultMessage: "Add or search for a tag",
354
- description: "Placeholder text. Use imperative",
355
- });
356
- const searchPlaceholder = intl.formatMessage({
357
- id: "tagInput.placeholderSearch",
358
- defaultMessage: "Search and select a tag",
359
- description: "Placeholder text. Use imperative",
360
- });
361
- const addPlaceholder = intl.formatMessage({
362
- id: "tagInput.placeholderAdd",
363
- defaultMessage: "Add a new tag",
364
- description: "Placeholder text. Use imperative",
365
- });
366
- let placeholder = "";
367
- if (addNew && hasOptions) {
368
- placeholder = addAndSearchPlaceholder;
369
- }
370
- else if (!addNew && hasOptions) {
371
- placeholder = searchPlaceholder;
372
- }
373
- else if (addNew) {
374
- placeholder = addPlaceholder;
375
- }
376
- return placeholder;
377
- }
378
- handleClick(ev) {
379
- const el = ev.target;
380
- if (this.isDropdown && !this.el.contains(el) && this.isExpanded) {
381
- this.closeDropdown();
382
- }
383
- }
384
- announceError() {
385
- if (this.errorMessage) {
386
- setTimeout(() => this.announce(this.errorMessage), 100);
387
- }
388
- }
389
- handleOptionClick(ev) {
390
- ev.preventDefault();
391
- this.resetInput();
392
- let option;
393
- if (this.isTable) {
394
- option = ev.target;
395
- option = this.tagOptionFromEl(option.closest("tr"));
396
- }
397
- else {
398
- option = this.tagOptionFromEl(ev.target);
399
- }
400
- // if someone wants to attach a click event listener on wm-tag-option
401
- option.click();
402
- if (option.locked) {
403
- this.announce(this.tagLockedMessage(this.getTagName(option)));
404
- }
405
- else {
406
- option.selected
407
- ? this.isTable && option.emitDeselectedEvent() // dropdown doesn't deselect on option click
408
- : option.emitSelectedEvent();
409
- }
410
- }
411
- // From wm-button
412
- // we need to listen for scroll events during the capture phase because they do not bubble up
413
- // there can be layouts where the main content has 100vh and overflows
414
- // in these cases window will register no scroll events unless we catch on they way down
415
- dismissTooltip() {
416
- if (this.tooltipVisible) {
417
- hideTooltip();
418
- }
419
- }
420
- handleInputKeyDown(ev) {
421
- if (/^.$/.test(ev.key) && this.charCount >= this.characterLimit) {
422
- this.announce(this.generateCharacterLimitWarning(this.charCount, this.characterLimit));
423
- }
424
- switch (ev.key) {
425
- case "Enter":
426
- ev.preventDefault();
427
- this.handleInputEnter();
428
- break;
429
- case "ArrowDown":
430
- ev.preventDefault();
431
- this.handleInputArrowDown();
432
- break;
433
- case "ArrowUp":
434
- ev.preventDefault();
435
- this.handleInputArrowUp();
436
- break;
437
- case "ArrowLeft":
438
- if (this.isTable) {
439
- ev.preventDefault();
440
- this.focusPrevCell();
441
- }
442
- break;
443
- case "ArrowRight":
444
- if (this.isTable) {
445
- ev.preventDefault();
446
- this.focusNextCell();
447
- }
448
- break;
449
- case "Escape":
450
- if (this.isDropdown && this.isExpanded) {
451
- ev.preventDefault();
452
- this.closeDropdown();
453
- }
454
- break;
455
- case "ArrowLeft":
456
- case "Backspace":
457
- this.handleInputBackspace();
458
- break;
459
- }
460
- }
461
- handleInputFocus() {
462
- if (this.isDropdown) {
463
- this.openDropdown();
464
- this.clearOptionFocus();
465
- }
466
- }
467
- handleInputChanged(ev) {
468
- this.clearOptionFocus();
469
- if (this.isDropdown) {
470
- if (this.charCount >= this.characterLimit - 5) {
471
- this.announce(this.generateCharacterLimitWarning(this.charCount, this.characterLimit));
472
- }
473
- if (!this.isExpanded) {
474
- this.openDropdown();
475
- }
476
- }
477
- const val = ev.target.value;
478
- if (val.includes(",") && this.addNew) {
479
- this.addTags(val);
480
- }
481
- else {
482
- this.announceExistingOptions();
483
- }
484
- }
485
- handleInputEnter() {
486
- // user has selected an option in the list
487
- if (this.focusedOption) {
488
- if (this.focusedOption.locked) {
489
- this.announce(this.tagLockedMessage(this.getTagName(this.focusedOption)));
490
- }
491
- else {
492
- this.focusedOption.click();
493
- this.focusedOption.selected
494
- ? this.isTable && this.focusedOption.emitDeselectedEvent()
495
- : this.focusedOption.emitSelectedEvent();
496
- this.resetInput();
497
- }
498
- }
499
- else if (this.isDropdown) {
500
- // user is adding a new tag
501
- const tagName = this.inputEl.value;
502
- if (!!tagName) {
503
- this.isExistingTag(tagName) ? this.announce(this.tagAlreadyAddedMessage(tagName)) : this.addTags(tagName);
504
- this.resetInput();
505
- }
506
- }
507
- }
508
- handleInputArrowDown() {
509
- if (this.isDropdown) {
510
- if (!this.isExpanded) {
511
- this.openDropdown();
512
- }
513
- else {
514
- let items = [];
515
- // the id check prevents a bug where the ref is reassigned to the first option causing it to be added twice (after adding a new user option)
516
- if (this.addNewButton && this.addNewButton.id === "add-new-btn") {
517
- items.push(this.addNewButton);
518
- }
519
- this.filteredOptionEls.forEach((o) => {
520
- items.push(this.elFromTagOption(o));
521
- });
522
- const next = findNext(items, this._focusedOption, true);
523
- this.focusOption(next);
524
- }
525
- }
526
- else {
527
- const items = this.filteredOptionEls.map((o) => this.elFromTagOption(o));
528
- const next = findNext(items, this._focusedOption, true);
529
- this.focusOption(next);
530
- }
531
- }
532
- handleInputArrowUp() {
533
- if (this.isDropdown) {
534
- if (!this.isExpanded) {
535
- this.openDropdown();
536
- }
537
- else {
538
- let items = [];
539
- if (this.addNewButton) {
540
- items.push(this.addNewButton);
541
- }
542
- this.filteredOptionEls.forEach((o) => {
543
- items.push(this.elFromTagOption(o));
544
- });
545
- const prev = findPrev(items, this._focusedOption, true);
546
- this.focusOption(prev);
547
- }
548
- }
549
- else {
550
- const items = this.filteredOptionEls.map((o) => this.elFromTagOption(o));
551
- const prev = findPrev(items, this._focusedOption, true);
552
- this.focusOption(prev);
553
- }
554
- }
555
- handleInputBackspace() {
556
- if (this.inputEl.value === "" && this._tagEls.length > 0) {
557
- this.isKeying = true;
558
- // wait for events to finish firing before redirecting focus
559
- // prevents double input in input area and tag area
560
- window.requestAnimationFrame(() => {
561
- this.tagAreaEl.focus();
562
- this.focusTag(this._tagEls[this._tagEls.length - 1]);
563
- });
564
- }
565
- }
566
- handleTagAreaKeyDown(ev) {
567
- switch (ev.key) {
568
- case "ArrowLeft":
569
- case "ArrowUp":
570
- ev.preventDefault();
571
- if (this.focusedTag) {
572
- const prev = findPrev(this._tagEls, this.focusedTag, true);
573
- this.focusTag(prev);
574
- }
575
- break;
576
- case "ArrowRight":
577
- case "ArrowDown":
578
- ev.preventDefault();
579
- if (this.focusedTag) {
580
- const next = findNext(this._tagEls, this.focusedTag, true);
581
- this.focusTag(next);
582
- }
583
- break;
584
- case "Backspace":
585
- case "Delete":
586
- if (this.focusedTag) {
587
- const option = this.tagOptionFromTag(this.focusedTag);
588
- if (option.locked) {
589
- this.announce(this.tagLockedMessage(this.getTagName(option)));
590
- }
591
- else {
592
- option.emitDeselectedEvent();
593
- }
594
- }
595
- break;
596
- }
597
- }
598
- handleBlur(ev) {
599
- this.dismissTooltip();
600
- this.clearOptionFocus();
601
- const relTarget = ev.relatedTarget;
602
- if (!this.isElOrChild(relTarget)) {
603
- this.fieldWrapperEl.classList.remove("focused");
604
- if (this.isDropdown) {
605
- this.closeDropdown();
606
- }
607
- }
608
- }
609
- handleTagAreaFocus(ev) {
610
- if (this.isDropdown) {
611
- this.closeDropdown();
612
- }
613
- if (this._tagEls.length > 0) {
614
- const relTarget = ev.relatedTarget;
615
- if (relTarget && relTarget.id === "input") {
616
- const lastFocusableTag = this._tagEls[this._tagEls.length - 1];
617
- this.focusTag(lastFocusableTag);
618
- }
619
- else {
620
- const firstFocusableTag = this._tagEls[0];
621
- this.focusTag(firstFocusableTag);
622
- }
623
- }
624
- }
625
- focusPrevCell() {
626
- if (this.focusedOption) {
627
- if (this.focusedColumn > 0) {
628
- this.focusedColumn -= 1;
629
- }
630
- }
631
- }
632
- focusNextCell() {
633
- if (this._focusedOption) {
634
- const lastCellIdx = this._focusedOption.querySelectorAll("td").length - 1;
635
- if (this.focusedColumn < lastCellIdx) {
636
- this.focusedColumn += 1;
637
- }
638
- }
639
- }
640
- focusOption(optionToFocus) {
641
- if (optionToFocus) {
642
- // will be undefined for the "Add New" button
643
- this.focusedOption = this.tagOptionFromEl(optionToFocus);
644
- if (optionToFocus === this.addNewButton) {
645
- this.addNewButton.classList.add("focused");
646
- }
647
- else {
648
- this.addNewButton && this.addNewButton.classList.remove("focused");
649
- }
650
- if (this.isTable) {
651
- // tooltip
652
- const contentWrapper = this._focusedOption.querySelector(".cell-content-wrapper");
653
- const isTruncated = contentWrapper.scrollWidth > contentWrapper.clientWidth;
654
- this.dismissTooltip();
655
- if (isTruncated) {
656
- // innerText is necessary vs textContent, as innerText ignores sr-only / display: none text
657
- showTooltip("bottom", this._focusedOption, this._focusedOption.innerText);
658
- }
659
- }
660
- optionToFocus.scrollIntoView({ block: "nearest" });
661
- }
662
- }
663
- showTooltipIfTruncated(el) {
664
- const displayedText = el.querySelector(".tag-text").textContent;
665
- const id = el.id.replace("tag-", "");
666
- if (id) {
667
- const tagEl = this.el.querySelector("#" + id);
668
- const fullText = this.getTagName(tagEl);
669
- if (displayedText !== fullText && displayedText.includes("...")) {
670
- showTooltip("bottom", el, fullText);
671
- }
672
- }
673
- }
674
- focusTag(element) {
675
- // technically it's the tag area that has focus. This function handles the aria-activedescendant value within that parent
676
- this.focusedTagIndex = this._tagEls.indexOf(element);
677
- element.scrollIntoView({ block: "nearest" });
678
- window.requestAnimationFrame(() => {
679
- hideTooltip();
680
- this.showTooltipIfTruncated(element);
681
- });
682
- }
683
- clearOptionFocus() {
684
- this.focusedOption = undefined;
685
- this.focusedColumn = 0;
686
- }
687
- openDropdown() {
688
- // offset of -2px to avoid overlapping the focus border
689
- this.openUp = shouldOpenUp(this.el, this.dropdownEl.clientHeight, this.el.clientHeight, -2);
690
- this.isExpanded = true;
691
- }
692
- closeDropdown() {
693
- this.clearOptionFocus();
694
- this.isExpanded = false;
695
- }
696
- resetInput() {
697
- this.inputEl.value = "";
698
- }
699
- announce(message) {
700
- // \u00A0 is a non-breaking space character, which causes the message to be read as a new one
701
- if (this.liveRegionEl.textContent === message) {
702
- message += "\u00A0";
703
- }
704
- this.liveRegionMessage = message;
705
- }
706
- addTags(tagNames) {
707
- // covers both typing "," and pasting in text that includes ","
708
- // if tag added without "," (typing enter), split puts the whole string in an array
709
- const addedTags = tagNames.split(",").filter((t) => t.match(/\S/));
710
- addedTags.forEach((tag) => {
711
- this.wmTagInputTagAdded.emit(tag);
712
- });
713
- this.announce(this.tagAddedMessage(addedTags.join(", ")));
714
- this.resetInput();
715
- }
716
- announceExistingOptions() {
717
- // request animation frame to wait for re-rendering of filtered options
718
- window.requestAnimationFrame(() => {
719
- const numResults = this.filteredOptionEls.length;
720
- const existingOptionsMessage = intl.formatMessage({
721
- id: "tagInput.existingOptions",
722
- defaultMessage: "{num, plural, one {1 existing option.} other {# existing options.}}",
723
- }, { num: numResults });
724
- this.announce(existingOptionsMessage);
725
- });
726
- }
727
- generateCharacterLimitWarning(charCount, charLimit) {
728
- let message = globalMessages.getCharactersEntered(charCount, charLimit);
729
- if (charCount >= charLimit) {
730
- message += ` ${globalMessages.characterLimitReached}`;
731
- }
732
- return message;
733
- }
734
- positionInput() {
735
- if (this.tagAreaEl) {
736
- const lastTag = this._tagEls[this._tagEls.length - 1];
737
- // default placement to fall back to when no tags are present, or not enough space is available
738
- this.inputEl.style.position = "static";
739
- this.inputEl.style.width = "100%";
740
- this.inputEl.classList.add("extended");
741
- if (lastTag) {
742
- const spaceAvailable = this.tagAreaEl.getBoundingClientRect().right - lastTag.getBoundingClientRect().right;
743
- if (spaceAvailable >= this.inputMinimumWidth) {
744
- // because the input has right: 0px
745
- // all thats needed to properly place it is setting position: absolute, top, and width
746
- this.inputEl.style.position = "absolute";
747
- this.inputEl.style.top = lastTag.offsetTop.toString() + "px";
748
- this.inputEl.style.width = (spaceAvailable - 8).toString() + "px";
749
- this.inputEl.classList.remove("extended");
750
- }
751
- }
752
- }
753
- }
754
- handleTagMouseEnter(ev) {
755
- this.showTooltipIfTruncated(ev.target);
756
- }
757
- renderDropdown() {
758
- return (h("div", { class: `dropdown-wrapper ${this.isExpanded ? "open" : ""} ${this.openUp ? "upwards" : ""}`, ref: (el) => (this.dropdownEl = el) }, h("div", { id: "help-text", class: "help-text" }, this.renderHelpText()), h("ul", { class: "dropdown", id: "dropdown", role: "listbox", "aria-multiselectable": "true", "aria-expanded": this.isExpanded ? "true" : "false", "aria-label": this.label, tabindex: -1 }, this.inputEl && this.renderAddNewButton(), this.filteredOptionEls.map((o) => this.renderListItem(o)))));
759
- }
760
- renderHelpText() {
761
- if (this.helpText)
762
- return this.helpText;
763
- let helpText = "";
764
- if (this.optionEls.length > 0) {
765
- helpText = this.selectionHelpText;
766
- }
767
- if (this.addNew) {
768
- helpText += " " + this.addNewHelpText;
769
- }
770
- return helpText;
771
- }
772
- renderAddNewButton() {
773
- const inputValue = this.inputEl.value.trim();
774
- const hasNonWhiteSpaceCharacters = this.inputEl.value.match(/\S/);
775
- const optionAlreadyExists = this.isExistingTag(this.inputEl.value.trim());
776
- return (this.addNew &&
777
- hasNonWhiteSpaceCharacters &&
778
- !optionAlreadyExists && (h("li", { ref: (el) => (this.addNewButton = el), id: "add-new-btn", class: "add-new-btn", onClick: () => this.addTags(inputValue) }, this.addNewTagMessage(inputValue))));
779
- }
780
- renderTable() {
781
- return (h("div", { class: "table-wrapper", onScroll: () => this.dismissTooltip() }, h("table", { id: "table", role: "grid", class: `${this.colWidths ? "fixed-widths" : ""}`, "aria-label": this.label, "aria-multiselectable": "true" }, this.renderTableHeaders(), this.filteredOptionEls.length ? (this.filteredOptionEls.map((o) => this.renderTableRow(o))) : (h("div", { class: "no-results" }, this.noResultsMessage)))));
782
- }
783
- renderTableHeaders() {
784
- return (h("tr", { class: "headers", role: "row" }, csvToArray(this.colHeaders).map((header, idx) => {
785
- let overflowRule = "wrap";
786
- if (this.colWrap && csvToArray(this.colWrap)[idx]) {
787
- overflowRule = csvToArray(this.colWrap)[idx];
788
- }
789
- return (h("th", { class: `header-cell ${overflowRule}`, role: "columnheader",
790
- // @ts-ignore
791
- width: this.colWidths ? csvToArray(this.colWidths)[idx] : "" }, header));
792
- })));
793
- }
794
- renderTag(o) {
795
- const focused = this.focusedTag && this.focusedTag.id === "tag-" + o.id ? "focused" : "";
796
- const tagName = this.getTagName(o);
797
- return (h("li", { id: "tag-" + o.id, role: "option", class: `tag ${focused} ${o.locked ? "locked" : ""}`, "aria-describedby": `tag-${o.id}-description`, onMouseEnter: (ev) => this.handleTagMouseEnter(ev), onMouseLeave: hideTooltip }, h("span", { class: "sr-only" }, tagName), h("div", { class: "description", id: `tag-${o.id}-description` }, o.locked ? "locked" : ""), h("span", { class: "tag-text", "aria-hidden": "true" }, tagName), o.locked ? (h("div", { class: "svg-icon svg-locked" })) : (h("button", { class: "icon remove-btn", tabIndex: -1, onClick: () => o.emitDeselectedEvent() }, h("div", { class: "svg-icon svg-close" })))));
798
- }
799
- renderTags() {
800
- return this.tagsList.map((o) => this.renderTag(o));
801
- }
802
- renderTagCounter() {
803
- if (this.maxTags) {
804
- return (h("div", { class: "lower-row" }, h("div", { id: "max-tags" }, this.renderMaxTags())));
805
- }
806
- }
807
- renderMaxTags() {
808
- if (this.helpText) {
809
- return this.helpText;
810
- }
811
- else {
812
- let msg = `${this.tagsAddedMessage}: ${this.taggedOptions.length}/${this.maxTags}`;
813
- if (this.tagLimitReached) {
814
- msg += `- ${this.maxTagsReachedMessage}`;
815
- }
816
- return msg;
817
- }
818
- }
819
- handleCellMouseEnter(ev) {
820
- const cell = ev.target;
821
- const contentWrapper = cell.querySelector(".cell-content-wrapper");
822
- const isTruncated = contentWrapper.scrollWidth > contentWrapper.clientWidth;
823
- if (isTruncated) {
824
- // innerText is necessary vs textContent, as innerText ignores sr-only / display: none text
825
- showTooltip("bottom", cell, cell.innerText);
826
- }
827
- }
828
- renderTableCells(o) {
829
- const colValues = [o.col1, o.col2, o.col3, o.col4].filter((val) => !!val);
830
- return colValues.map((val, idx) => {
831
- const cellId = `${o.id}-col${idx + 1}`;
832
- let overflowRule = "wrap";
833
- if (this.colWrap && csvToArray(this.colWrap)[idx]) {
834
- overflowRule = csvToArray(this.colWrap)[idx];
835
- }
836
- const classes = {
837
- focused: !!this._focusedCell && cellId === this._focusedCell.id,
838
- };
839
- return (h("td", { id: cellId, class: classes, role: "gridcell", "aria-describedby": `${cellId}-description`, "aria-selected": o.selected ? "true" : "false", "aria-readonly": o.locked ? "true" : null, onMouseEnter: (ev) => this.handleCellMouseEnter(ev), onMouseLeave: () => hideTooltip() }, h("div", { class: `cell-content-wrapper ${overflowRule}` }, o.locked && idx == 0 && h("div", { class: "svg-icon svg-locked" }), val), h("div", { class: "description", id: `${cellId}-description` }, o.locked ? globalMessages.locked : "")));
840
- });
841
- }
842
- renderTableRow(o) {
843
- const classes = {
844
- selected: o.selected,
845
- locked: o.locked,
846
- focused: this.focusedOption && o === this.focusedOption ? true : false,
847
- };
848
- return (h("tr", { id: o.id, class: classes, onClick: (ev) => this.handleOptionClick(ev) }, this.renderTableCells(o)));
849
- }
850
- renderListItem(o) {
851
- if (!!this.inputEl) {
852
- const isFocused = this.focusedOption && o === this.focusedOption;
853
- return (h("li", { id: o.id, role: "option", class: `option ${isFocused ? "focused" : ""}`, "aria-selected": o.selected ? "true" : "false", onClick: (ev) => this.handleOptionClick(ev) }, o.textContent));
854
- }
855
- }
856
- render() {
857
- return (h("div", { key: 'c7c6274b246a075d3dde1a85c48f74a6f81e8488', class: `wrapper label-${this.labelPosition} ${this.errorMessage ? "invalid" : ""}` }, h("div", { key: 'e111c172efb9f67de292ea97c032eb0aceb5dd7b', class: "label-wrapper" }, h("label", { key: '41022ce3f8be12acda982a6b6fddd5703004278d', class: "label", htmlFor: "input" }, this.label, this.requiredField && (h("span", { key: '778554d1db5854adcc3629fa263a2c1b537bcf7f', class: "required", "aria-hidden": "true" }, "*")))), h("div", { key: 'e73b049d34b5de5f7599c7c09b325545a3be0c5e', class: `field-wrapper ${this.el.shadowRoot.activeElement === this.inputEl ? "focused" : ""} ${this.errorMessage ? "invalid" : ""}`, ref: (el) => (this.fieldWrapperEl = el) }, h("div", { key: 'd192eac4c59464f4002e99f77ad295c5e3917f38', class: "upper-row" }, h("div", { key: 'fde56c948d07ebfe7f0811bf516b8d466b8aaf20', class: "svg-icon svg-search" }), h("div", { key: '9831080c30d69e89aa482dc439a9210c5f6f0246', class: `tags-and-input-wrapper ${this.inModal ? "in-modal" : ""}` }, h("ul", { key: 'd9b2a3749cd06d1ad5ce381b99c04685cff97c62', ref: (el) => (this.tagAreaEl = el), class: `tag-area ${this.taggedOptions.length === 0 && "empty"} ${this.isKeying ? "user-is-keying" : ""}`, role: "listbox", "aria-activedescendant": this.focusedTag ? this.focusedTag.id : null, "aria-orientation": "horizontal", "aria-label": `${this.label} ${this.tagAreaInstructions}`, tabindex: this._tagEls.length > 0 ? 0 : -1, "aria-describedby": `info max-tags`, onFocus: (ev) => this.handleTagAreaFocus(ev), onBlur: (ev) => {
858
- this.focusedTagIndex = undefined;
859
- this.handleBlur(ev);
860
- }, onKeyDown: (ev) => this.handleTagAreaKeyDown(ev) }, this.renderTags()), h("input", { key: 'cd48d5e5c79157f76e67d89411e3471bd421cb82', id: "input", class: "input", role: "combobox", ref: (el) => (this.inputEl = el), autocomplete: "off", "aria-required": this.requiredField ? "true" : null, "aria-controls": this.tagInputType, "aria-describedby": `help-text${this.errorMessage ? " error " : ""} max-tags`, "aria-label": `${this.label} ${this.isDropdown ? globalMessages.getCharacterLimit(this.characterLimit) : ""}`, "aria-expanded": this.isDropdown ? this.isExpanded.toString() : null, "aria-activedescendant": this.inputActiveDescendantId, placeholder: this.placeholder, maxLength: this.isDropdown ? this.characterLimit : undefined, onInput: (ev) => this.handleInputChanged(ev), onBlur: (ev) => {
861
- this.handleBlur(ev);
862
- }, onFocus: () => this.handleInputFocus(), onKeyDown: (ev) => this.handleInputKeyDown(ev) })), this.isDropdown && (h("div", { key: 'f2bf5d26f43064e12e4a2b51ed3b7a531e30d0f1', class: "character-count" }, this.charCount, "/", this.characterLimit))), this.renderTagCounter(), this.isDropdown && this.renderDropdown()), this.info && (h("div", { key: 'aea747efbca0eb714301678e297052c9bcfb745c', id: "info", class: "info-text" }, this.info)), h("div", { key: 'fa5e0b55abbd2f9608bbea1161a9169adeaee627', id: "error" }, this.errorMessage), h("div", { key: '3f484bbc12775a17f5af366deeb0776808b38016', class: "sr-only", "aria-live": "polite", ref: (el) => (this.liveRegionEl = el), "aria-atomic": "true" }, this.liveRegionMessage), this.isTable && this.renderTable()));
863
- }
864
- static get is() { return "wm-tag-input"; }
865
- static get encapsulation() { return "shadow"; }
866
- static get delegatesFocus() { return true; }
867
- static get originalStyleUrls() {
868
- return {
869
- "$": ["wm-tag-input.scss"]
870
- };
871
- }
872
- static get styleUrls() {
873
- return {
874
- "$": ["wm-tag-input.css"]
875
- };
876
- }
877
- static get properties() {
878
- return {
879
- "label": {
880
- "type": "string",
881
- "attribute": "label",
882
- "mutable": false,
883
- "complexType": {
884
- "original": "string",
885
- "resolved": "string",
886
- "references": {}
887
- },
888
- "required": true,
889
- "optional": false,
890
- "docs": {
891
- "tags": [],
892
- "text": ""
893
- },
894
- "getter": false,
895
- "setter": false,
896
- "reflect": false
897
- },
898
- "errorMessage": {
899
- "type": "string",
900
- "attribute": "error-message",
901
- "mutable": false,
902
- "complexType": {
903
- "original": "string",
904
- "resolved": "string | undefined",
905
- "references": {}
906
- },
907
- "required": false,
908
- "optional": true,
909
- "docs": {
910
- "tags": [],
911
- "text": ""
912
- },
913
- "getter": false,
914
- "setter": false,
915
- "reflect": false
916
- },
917
- "info": {
918
- "type": "string",
919
- "attribute": "info",
920
- "mutable": false,
921
- "complexType": {
922
- "original": "string",
923
- "resolved": "string | undefined",
924
- "references": {}
925
- },
926
- "required": false,
927
- "optional": true,
928
- "docs": {
929
- "tags": [],
930
- "text": ""
931
- },
932
- "getter": false,
933
- "setter": false,
934
- "reflect": false
935
- },
936
- "labelPosition": {
937
- "type": "string",
938
- "attribute": "label-position",
939
- "mutable": false,
940
- "complexType": {
941
- "original": "\"top\" | \"left\" | \"none\"",
942
- "resolved": "\"left\" | \"none\" | \"top\"",
943
- "references": {}
944
- },
945
- "required": false,
946
- "optional": false,
947
- "docs": {
948
- "tags": [],
949
- "text": ""
950
- },
951
- "getter": false,
952
- "setter": false,
953
- "reflect": false,
954
- "defaultValue": "\"top\""
955
- },
956
- "maxTags": {
957
- "type": "number",
958
- "attribute": "max-tags",
959
- "mutable": false,
960
- "complexType": {
961
- "original": "number",
962
- "resolved": "number | undefined",
963
- "references": {}
964
- },
965
- "required": false,
966
- "optional": true,
967
- "docs": {
968
- "tags": [],
969
- "text": ""
970
- },
971
- "getter": false,
972
- "setter": false,
973
- "reflect": false
974
- },
975
- "placeholder": {
976
- "type": "string",
977
- "attribute": "placeholder",
978
- "mutable": true,
979
- "complexType": {
980
- "original": "string",
981
- "resolved": "string | undefined",
982
- "references": {}
983
- },
984
- "required": false,
985
- "optional": true,
986
- "docs": {
987
- "tags": [],
988
- "text": ""
989
- },
990
- "getter": false,
991
- "setter": false,
992
- "reflect": false
993
- },
994
- "requiredField": {
995
- "type": "boolean",
996
- "attribute": "required-field",
997
- "mutable": false,
998
- "complexType": {
999
- "original": "boolean",
1000
- "resolved": "boolean",
1001
- "references": {}
1002
- },
1003
- "required": false,
1004
- "optional": false,
1005
- "docs": {
1006
- "tags": [],
1007
- "text": ""
1008
- },
1009
- "getter": false,
1010
- "setter": false,
1011
- "reflect": false,
1012
- "defaultValue": "false"
1013
- },
1014
- "tagInputType": {
1015
- "type": "string",
1016
- "attribute": "tag-input-type",
1017
- "mutable": false,
1018
- "complexType": {
1019
- "original": "\"dropdown\" | \"table\"",
1020
- "resolved": "\"dropdown\" | \"table\"",
1021
- "references": {}
1022
- },
1023
- "required": false,
1024
- "optional": false,
1025
- "docs": {
1026
- "tags": [],
1027
- "text": ""
1028
- },
1029
- "getter": false,
1030
- "setter": false,
1031
- "reflect": false,
1032
- "defaultValue": "\"dropdown\""
1033
- },
1034
- "helpText": {
1035
- "type": "string",
1036
- "attribute": "help-text",
1037
- "mutable": false,
1038
- "complexType": {
1039
- "original": "string",
1040
- "resolved": "string | undefined",
1041
- "references": {}
1042
- },
1043
- "required": false,
1044
- "optional": true,
1045
- "docs": {
1046
- "tags": [],
1047
- "text": ""
1048
- },
1049
- "getter": false,
1050
- "setter": false,
1051
- "reflect": false
1052
- },
1053
- "addNew": {
1054
- "type": "boolean",
1055
- "attribute": "add-new",
1056
- "mutable": false,
1057
- "complexType": {
1058
- "original": "boolean",
1059
- "resolved": "boolean",
1060
- "references": {}
1061
- },
1062
- "required": false,
1063
- "optional": false,
1064
- "docs": {
1065
- "tags": [],
1066
- "text": ""
1067
- },
1068
- "getter": false,
1069
- "setter": false,
1070
- "reflect": false,
1071
- "defaultValue": "true"
1072
- },
1073
- "characterLimit": {
1074
- "type": "number",
1075
- "attribute": "character-limit",
1076
- "mutable": false,
1077
- "complexType": {
1078
- "original": "number",
1079
- "resolved": "number",
1080
- "references": {}
1081
- },
1082
- "required": false,
1083
- "optional": false,
1084
- "docs": {
1085
- "tags": [],
1086
- "text": ""
1087
- },
1088
- "getter": false,
1089
- "setter": false,
1090
- "reflect": false,
1091
- "defaultValue": "50"
1092
- },
1093
- "colHeaders": {
1094
- "type": "string",
1095
- "attribute": "col-headers",
1096
- "mutable": false,
1097
- "complexType": {
1098
- "original": "string",
1099
- "resolved": "string",
1100
- "references": {}
1101
- },
1102
- "required": true,
1103
- "optional": false,
1104
- "docs": {
1105
- "tags": [],
1106
- "text": ""
1107
- },
1108
- "getter": false,
1109
- "setter": false,
1110
- "reflect": false
1111
- },
1112
- "colWidths": {
1113
- "type": "string",
1114
- "attribute": "col-widths",
1115
- "mutable": false,
1116
- "complexType": {
1117
- "original": "string",
1118
- "resolved": "string | undefined",
1119
- "references": {}
1120
- },
1121
- "required": false,
1122
- "optional": true,
1123
- "docs": {
1124
- "tags": [],
1125
- "text": ""
1126
- },
1127
- "getter": false,
1128
- "setter": false,
1129
- "reflect": false
1130
- },
1131
- "colWrap": {
1132
- "type": "string",
1133
- "attribute": "col-wrap",
1134
- "mutable": false,
1135
- "complexType": {
1136
- "original": "string",
1137
- "resolved": "string | undefined",
1138
- "references": {}
1139
- },
1140
- "required": false,
1141
- "optional": true,
1142
- "docs": {
1143
- "tags": [],
1144
- "text": ""
1145
- },
1146
- "getter": false,
1147
- "setter": false,
1148
- "reflect": false
1149
- }
1150
- };
1151
- }
1152
- static get states() {
1153
- return {
1154
- "isKeying": {},
1155
- "isExpanded": {},
1156
- "liveRegionMessage": {},
1157
- "focusedOption": {},
1158
- "focusedColumn": {},
1159
- "focusedTagIndex": {},
1160
- "tagsList": {}
1161
- };
1162
- }
1163
- static get events() {
1164
- return [{
1165
- "method": "wmTagInputTagAdded",
1166
- "name": "wmTagInputTagAdded",
1167
- "bubbles": true,
1168
- "cancelable": true,
1169
- "composed": true,
1170
- "docs": {
1171
- "tags": [],
1172
- "text": ""
1173
- },
1174
- "complexType": {
1175
- "original": "any",
1176
- "resolved": "any",
1177
- "references": {}
1178
- }
1179
- }];
1180
- }
1181
- static get elementRef() { return "el"; }
1182
- static get watchers() {
1183
- return [{
1184
- "propName": "errorMessage",
1185
- "methodName": "announceError"
1186
- }];
1187
- }
1188
- static get listeners() {
1189
- return [{
1190
- "name": "wmUserIsKeying",
1191
- "method": "toggleKeyingOn",
1192
- "target": "window",
1193
- "capture": false,
1194
- "passive": false
1195
- }, {
1196
- "name": "wmUserIsTabbing",
1197
- "method": "toggleKeyingOn",
1198
- "target": "window",
1199
- "capture": false,
1200
- "passive": false
1201
- }, {
1202
- "name": "wmUserIsNotKeying",
1203
- "method": "toggleKeyingOff",
1204
- "target": "window",
1205
- "capture": false,
1206
- "passive": false
1207
- }, {
1208
- "name": "wmUserIsNotTabbing",
1209
- "method": "toggleKeyingOff",
1210
- "target": "window",
1211
- "capture": false,
1212
- "passive": false
1213
- }, {
1214
- "name": "privTagOptionSelected",
1215
- "method": "handleTagOptionSelected",
1216
- "target": undefined,
1217
- "capture": false,
1218
- "passive": false
1219
- }, {
1220
- "name": "privTagOptionDeselected",
1221
- "method": "handleTagOptionDeselected",
1222
- "target": undefined,
1223
- "capture": false,
1224
- "passive": false
1225
- }, {
1226
- "name": "click",
1227
- "method": "handleClick",
1228
- "target": "document",
1229
- "capture": false,
1230
- "passive": false
1231
- }, {
1232
- "name": "scroll",
1233
- "method": "dismissTooltip",
1234
- "target": "window",
1235
- "capture": true,
1236
- "passive": true
1237
- }, {
1238
- "name": "blur",
1239
- "method": "handleBlur",
1240
- "target": undefined,
1241
- "capture": false,
1242
- "passive": false
1243
- }];
1244
- }
1245
- }