@watermarkinsights/ripple 0.0.0 → 0.1.0-alpha.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 (580) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +1 -1
  3. package/dist/cjs/app-globals-f836e216.js +103 -0
  4. package/dist/cjs/chartFunctions-608adb05.js +908 -0
  5. package/dist/cjs/{functions-f2333f02.js → functions-b188d5b3.js} +6137 -1590
  6. package/dist/cjs/index-786066a1.js +1880 -0
  7. package/dist/cjs/interfaces-8419be91.js +59 -0
  8. package/dist/cjs/intl-01531391.js +283 -0
  9. package/dist/cjs/loader.cjs.js +7 -14
  10. package/dist/cjs/priv-calendar.cjs.entry.js +608 -0
  11. package/dist/cjs/priv-chart-popover-old.cjs.entry.js +146 -0
  12. package/dist/cjs/priv-chart-popover_2.cjs.entry.js +194 -0
  13. package/dist/cjs/priv-navigator-button.cjs.entry.js +19 -19
  14. package/dist/cjs/priv-navigator-item.cjs.entry.js +24 -23
  15. package/dist/cjs/priv-option-list.cjs.entry.js +391 -0
  16. package/dist/cjs/ripple.cjs.js +25 -0
  17. package/dist/cjs/wm-action-menu_2.cjs.entry.js +471 -302
  18. package/dist/cjs/wm-button.cjs.entry.js +263 -142
  19. package/dist/cjs/wm-chart-bar.cjs.entry.js +441 -0
  20. package/dist/cjs/wm-chart-column.cjs.entry.js +544 -0
  21. package/dist/cjs/wm-chart-slice.cjs.entry.js +17 -12
  22. package/dist/cjs/wm-chart.cjs.entry.js +133 -478
  23. package/dist/cjs/wm-date-range.cjs.entry.js +526 -0
  24. package/dist/cjs/wm-datepicker.cjs.entry.js +285 -224
  25. package/dist/cjs/wm-file-list.cjs.entry.js +23 -0
  26. package/dist/cjs/wm-file.cjs.entry.js +210 -0
  27. package/dist/cjs/wm-flyout.cjs.entry.js +181 -0
  28. package/dist/cjs/wm-input.cjs.entry.js +121 -100
  29. package/dist/cjs/wm-line-chart.cjs.entry.js +541 -0
  30. package/dist/cjs/wm-modal-pss_3.cjs.entry.js +220 -0
  31. package/dist/cjs/wm-modal_3.cjs.entry.js +223 -0
  32. package/dist/cjs/wm-navigation_3.cjs.entry.js +188 -0
  33. package/dist/cjs/wm-navigator.cjs.entry.js +305 -250
  34. package/dist/cjs/wm-nested-select.cjs.entry.js +320 -0
  35. package/dist/cjs/wm-optgroup.cjs.entry.js +74 -0
  36. package/dist/cjs/wm-option_2.cjs.entry.js +517 -465
  37. package/dist/cjs/wm-pagination.cjs.entry.js +218 -165
  38. package/dist/cjs/wm-progress-indicator_3.cjs.entry.js +204 -0
  39. package/dist/cjs/wm-search.cjs.entry.js +182 -217
  40. package/dist/cjs/wm-snackbar.cjs.entry.js +158 -142
  41. package/dist/cjs/wm-tab-item_3.cjs.entry.js +317 -276
  42. package/dist/cjs/wm-tag-input.cjs.entry.js +940 -500
  43. package/dist/cjs/wm-tag-option.cjs.entry.js +43 -0
  44. package/dist/cjs/wm-textarea.cjs.entry.js +94 -0
  45. package/dist/cjs/wm-timepicker.cjs.entry.js +276 -349
  46. package/dist/cjs/wm-toggletip.cjs.entry.js +238 -114
  47. package/dist/cjs/wm-uploader.cjs.entry.js +322 -323
  48. package/dist/cjs/wm-wrapper.cjs.entry.js +12 -12
  49. package/dist/collection/collection-manifest.json +104 -34
  50. package/dist/collection/components/charts/chartFunctions.js +833 -0
  51. package/dist/collection/components/charts/priv-chart-popover/priv-chart-popover.css +995 -0
  52. package/dist/collection/components/charts/priv-chart-popover/priv-chart-popover.js +340 -0
  53. package/dist/collection/components/charts/priv-chart-popover-old/priv-chart-popover-old.css +990 -0
  54. package/dist/collection/components/charts/priv-chart-popover-old/priv-chart-popover-old.js +263 -0
  55. package/dist/collection/components/charts/wm-chart/wm-chart-slice.js +125 -0
  56. package/dist/collection/components/charts/wm-chart/wm-chart.css +1326 -0
  57. package/dist/collection/components/charts/wm-chart/wm-chart.js +422 -0
  58. package/dist/collection/components/charts/wm-chart-bar/wm-chart-bar.css +1116 -0
  59. package/dist/collection/components/charts/wm-chart-bar/wm-chart-bar.js +579 -0
  60. package/dist/collection/components/charts/wm-chart-column/wm-chart-column.css +1169 -0
  61. package/dist/collection/components/charts/wm-chart-column/wm-chart-column.js +688 -0
  62. package/dist/collection/components/charts/wm-chart-legend/wm-chart-legend.css +932 -0
  63. package/dist/collection/components/charts/wm-chart-legend/wm-chart-legend.js +194 -0
  64. package/dist/collection/components/charts/wm-line-chart/wm-line-chart.css +1208 -0
  65. package/dist/collection/components/charts/wm-line-chart/wm-line-chart.js +862 -0
  66. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-indicator.css +1326 -0
  67. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-indicator.js +264 -0
  68. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-monitor.css +967 -0
  69. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-monitor.js +151 -0
  70. package/dist/collection/components/charts/wm-progress-monitor/wm-progress-slice.js +121 -0
  71. package/dist/collection/components/datepickers/datepicker.css +1137 -0
  72. package/dist/collection/components/datepickers/priv-calendar/priv-calendar.css +1403 -0
  73. package/dist/collection/components/datepickers/priv-calendar/priv-calendar.js +881 -0
  74. package/dist/collection/components/datepickers/wm-date-range.js +870 -0
  75. package/dist/collection/components/datepickers/wm-datepicker.js +579 -0
  76. package/dist/collection/components/selects/priv-option-list/priv-option-list.css +999 -0
  77. package/dist/collection/components/selects/priv-option-list/priv-option-list.js +778 -0
  78. package/dist/collection/components/selects/wm-nested-select/wm-nested-select.css +1259 -0
  79. package/dist/collection/components/selects/wm-nested-select/wm-nested-select.js +626 -0
  80. package/dist/collection/components/selects/wm-optgroup/wm-optgroup.css +909 -0
  81. package/dist/collection/components/selects/wm-optgroup/wm-optgroup.js +258 -0
  82. package/dist/collection/components/selects/wm-option/wm-option.css +1033 -0
  83. package/dist/collection/components/selects/wm-option/wm-option.js +530 -0
  84. package/dist/collection/components/selects/wm-select/wm-select.css +1187 -0
  85. package/dist/collection/components/selects/wm-select/wm-select.js +705 -0
  86. package/dist/collection/components/wm-action-menu/wm-action-menu.css +1614 -50
  87. package/dist/collection/components/wm-action-menu/wm-action-menu.js +605 -387
  88. package/dist/collection/components/wm-button/wm-button.css +1440 -385
  89. package/dist/collection/components/wm-button/wm-button.js +538 -348
  90. package/dist/collection/components/wm-file/wm-file.css +1086 -0
  91. package/dist/collection/components/wm-file/wm-file.js +428 -0
  92. package/dist/collection/components/wm-file-list/wm-file-list.css +899 -0
  93. package/dist/collection/components/wm-file-list/wm-file-list.js +45 -0
  94. package/dist/collection/components/wm-flyout/wm-flyout.css +1117 -0
  95. package/dist/collection/components/wm-flyout/wm-flyout.js +449 -0
  96. package/dist/collection/components/wm-input/wm-input.css +965 -96
  97. package/dist/collection/components/wm-input/wm-input.js +466 -291
  98. package/dist/collection/components/wm-menuitem/wm-menuitem.css +919 -55
  99. package/dist/collection/components/wm-menuitem/wm-menuitem.js +402 -397
  100. package/dist/collection/components/wm-modal/wm-modal-footer.css +871 -28
  101. package/dist/collection/components/wm-modal/wm-modal-footer.js +139 -156
  102. package/dist/collection/components/wm-modal/wm-modal-header.css +864 -16
  103. package/dist/collection/components/wm-modal/wm-modal-header.js +76 -106
  104. package/dist/collection/components/wm-modal/wm-modal.css +921 -93
  105. package/dist/collection/components/wm-modal/wm-modal.js +337 -337
  106. package/dist/collection/components/wm-modal-pss/wm-modal-pss-footer.css +931 -0
  107. package/dist/collection/components/wm-modal-pss/wm-modal-pss-footer.js +138 -0
  108. package/dist/collection/components/wm-modal-pss/wm-modal-pss-header.css +925 -0
  109. package/dist/collection/components/wm-modal-pss/wm-modal-pss-header.js +82 -0
  110. package/dist/collection/components/wm-modal-pss/wm-modal-pss.css +1007 -0
  111. package/dist/collection/components/wm-modal-pss/wm-modal-pss.js +365 -0
  112. package/dist/collection/components/wm-navigation/wm-navigation-hamburger.css +926 -0
  113. package/dist/collection/components/wm-navigation/wm-navigation-hamburger.js +119 -0
  114. package/dist/collection/components/wm-navigation/wm-navigation-item.css +935 -0
  115. package/dist/collection/components/wm-navigation/wm-navigation-item.js +98 -0
  116. package/dist/collection/components/wm-navigation/wm-navigation.css +977 -0
  117. package/dist/collection/components/wm-navigation/wm-navigation.js +190 -0
  118. package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.css +868 -33
  119. package/dist/collection/components/wm-navigator/priv-navigator-button/priv-navigator-button.js +83 -94
  120. package/dist/collection/components/wm-navigator/priv-navigator-item/priv-navigator-item.css +876 -25
  121. package/dist/collection/components/wm-navigator/priv-navigator-item/priv-navigator-item.js +120 -110
  122. package/dist/collection/components/wm-navigator/wm-navigator.css +891 -38
  123. package/dist/collection/components/wm-navigator/wm-navigator.js +491 -456
  124. package/dist/collection/components/wm-pagination/wm-pagination.css +895 -68
  125. package/dist/collection/components/wm-pagination/wm-pagination.js +374 -340
  126. package/dist/collection/components/wm-search/wm-search.css +895 -73
  127. package/dist/collection/components/wm-search/wm-search.js +411 -421
  128. package/dist/collection/components/wm-snackbar/wm-snackbar.css +979 -160
  129. package/dist/collection/components/wm-snackbar/wm-snackbar.js +258 -235
  130. package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.css +904 -50
  131. package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.js +162 -198
  132. package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.css +922 -29
  133. package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.js +334 -292
  134. package/dist/collection/components/wm-tabs/wm-tab-panel/wm-tab-panel.css +862 -13
  135. package/dist/collection/components/wm-tabs/wm-tab-panel/wm-tab-panel.js +83 -100
  136. package/dist/collection/components/wm-tag-input/wm-tag-input.css +1212 -200
  137. package/dist/collection/components/wm-tag-input/wm-tag-input.js +1283 -702
  138. package/dist/collection/components/wm-tag-input/wm-tag-option/wm-tag-option.js +243 -0
  139. package/dist/collection/components/wm-textarea/wm-textarea.css +1065 -0
  140. package/dist/collection/components/wm-textarea/wm-textarea.js +319 -0
  141. package/dist/collection/components/wm-timepicker/wm-timepicker.css +962 -168
  142. package/dist/collection/components/wm-timepicker/wm-timepicker.js +539 -553
  143. package/dist/collection/components/wm-toggletip/wm-toggletip.css +1094 -148
  144. package/dist/collection/components/wm-toggletip/wm-toggletip.js +370 -211
  145. package/dist/collection/components/wm-uploader/wm-uploader.css +1756 -438
  146. package/dist/collection/components/wm-uploader/wm-uploader.js +607 -661
  147. package/dist/collection/components/wm-wrapper/wm-wrapper.js +26 -25
  148. package/dist/collection/dev/action-menu.js +18 -0
  149. package/dist/collection/dev/chart-bar.js +423 -0
  150. package/dist/collection/dev/chart-column.js +437 -0
  151. package/dist/collection/dev/chart-small.js +56 -0
  152. package/dist/collection/dev/chart.js +18 -0
  153. package/dist/collection/dev/date-range.js +6 -0
  154. package/dist/collection/dev/datepicker.js +46 -0
  155. package/dist/collection/dev/file-list.js +16 -0
  156. package/dist/collection/dev/file.js +0 -0
  157. package/dist/collection/dev/flyout.js +194 -0
  158. package/dist/collection/dev/input.js +6 -0
  159. package/dist/collection/dev/line-chart.js +45 -0
  160. package/dist/collection/dev/modal.js +48 -0
  161. package/dist/collection/dev/navigation.js +13 -0
  162. package/dist/collection/dev/navigator.js +34 -0
  163. package/dist/collection/dev/nested-select.js +36 -0
  164. package/dist/collection/dev/pagination.js +7 -0
  165. package/dist/collection/dev/progress-monitor.js +0 -0
  166. package/dist/collection/dev/pss-modal.js +8 -0
  167. package/dist/collection/dev/scripts.js +43 -14
  168. package/dist/collection/dev/search.js +72 -0
  169. package/dist/collection/dev/select.js +57 -0
  170. package/dist/collection/dev/snackbar.js +68 -0
  171. package/dist/collection/dev/tabs.js +44 -0
  172. package/dist/collection/dev/tag-input.js +32 -0
  173. package/dist/collection/dev/textarea.js +28 -0
  174. package/dist/collection/dev/timepicker.js +32 -0
  175. package/dist/collection/dev/toggletip.js +9 -0
  176. package/dist/collection/dev/uploader.js +139 -0
  177. package/dist/collection/global/__mocks__/functions.js +2 -1
  178. package/dist/collection/global/functions.js +853 -371
  179. package/dist/collection/global/global.js +88 -28
  180. package/dist/collection/global/interfaces.js +62 -39
  181. package/dist/collection/global/intl.js +274 -0
  182. package/dist/collection/global/services/__mocks__/http-service.js +112 -112
  183. package/dist/collection/global/services/http-service.js +41 -41
  184. package/dist/collection/lang/missing.js +43 -0
  185. package/dist/collection/lang/piglatin.js +11 -3
  186. package/dist/esm/app-globals-d0ca31a6.js +101 -0
  187. package/dist/esm/chartFunctions-4bc77b76.js +883 -0
  188. package/dist/esm/{functions-60034bf7.js → functions-de887809.js} +6110 -1584
  189. package/dist/esm/index-ef50bc01.js +1849 -0
  190. package/dist/esm/interfaces-7e50d034.js +55 -0
  191. package/dist/esm/intl-56b47a7b.js +277 -0
  192. package/dist/esm/loader.js +7 -14
  193. package/dist/esm/priv-calendar.entry.js +604 -0
  194. package/dist/esm/priv-chart-popover-old.entry.js +142 -0
  195. package/dist/esm/priv-chart-popover_2.entry.js +189 -0
  196. package/dist/esm/priv-navigator-button.entry.js +19 -19
  197. package/dist/esm/priv-navigator-item.entry.js +24 -23
  198. package/dist/esm/priv-option-list.entry.js +387 -0
  199. package/dist/esm/ripple.js +20 -0
  200. package/dist/esm/wm-action-menu_2.entry.js +471 -302
  201. package/dist/esm/wm-button.entry.js +263 -142
  202. package/dist/esm/wm-chart-bar.entry.js +437 -0
  203. package/dist/esm/wm-chart-column.entry.js +540 -0
  204. package/dist/esm/wm-chart-slice.entry.js +17 -12
  205. package/dist/esm/wm-chart.entry.js +133 -478
  206. package/dist/esm/wm-date-range.entry.js +522 -0
  207. package/dist/esm/wm-datepicker.entry.js +285 -224
  208. package/dist/esm/wm-file-list.entry.js +19 -0
  209. package/dist/esm/wm-file.entry.js +206 -0
  210. package/dist/esm/wm-flyout.entry.js +177 -0
  211. package/dist/esm/wm-input.entry.js +121 -100
  212. package/dist/esm/wm-line-chart.entry.js +537 -0
  213. package/dist/esm/wm-modal-pss_3.entry.js +214 -0
  214. package/dist/esm/wm-modal_3.entry.js +217 -0
  215. package/dist/esm/wm-navigation_3.entry.js +182 -0
  216. package/dist/esm/wm-navigator.entry.js +305 -250
  217. package/dist/esm/wm-nested-select.entry.js +316 -0
  218. package/dist/esm/wm-optgroup.entry.js +70 -0
  219. package/dist/esm/wm-option_2.entry.js +517 -465
  220. package/dist/esm/wm-pagination.entry.js +218 -165
  221. package/dist/esm/wm-progress-indicator_3.entry.js +198 -0
  222. package/dist/esm/wm-search.entry.js +182 -217
  223. package/dist/esm/wm-snackbar.entry.js +158 -142
  224. package/dist/esm/wm-tab-item_3.entry.js +317 -276
  225. package/dist/esm/wm-tag-input.entry.js +940 -500
  226. package/dist/esm/wm-tag-option.entry.js +39 -0
  227. package/dist/esm/wm-textarea.entry.js +90 -0
  228. package/dist/esm/wm-timepicker.entry.js +276 -349
  229. package/dist/esm/wm-toggletip.entry.js +238 -114
  230. package/dist/esm/wm-uploader.entry.js +322 -323
  231. package/dist/esm/wm-wrapper.entry.js +12 -12
  232. package/dist/esm-es5/app-globals-d0ca31a6.js +1 -0
  233. package/dist/esm-es5/chartFunctions-4bc77b76.js +1 -0
  234. package/dist/esm-es5/functions-de887809.js +1 -0
  235. package/dist/esm-es5/index-ef50bc01.js +1 -0
  236. package/dist/esm-es5/index.js +0 -0
  237. package/dist/esm-es5/interfaces-7e50d034.js +1 -0
  238. package/dist/esm-es5/intl-56b47a7b.js +1 -0
  239. package/dist/esm-es5/loader.js +1 -0
  240. package/dist/esm-es5/priv-calendar.entry.js +1 -0
  241. package/dist/esm-es5/priv-chart-popover-old.entry.js +1 -0
  242. package/dist/esm-es5/priv-chart-popover_2.entry.js +1 -0
  243. package/dist/esm-es5/priv-navigator-button.entry.js +1 -0
  244. package/dist/esm-es5/priv-navigator-item.entry.js +1 -0
  245. package/dist/esm-es5/priv-option-list.entry.js +1 -0
  246. package/dist/esm-es5/ripple.js +1 -0
  247. package/dist/esm-es5/wm-action-menu_2.entry.js +1 -0
  248. package/dist/esm-es5/wm-button.entry.js +1 -0
  249. package/dist/esm-es5/wm-chart-bar.entry.js +1 -0
  250. package/dist/esm-es5/wm-chart-column.entry.js +1 -0
  251. package/dist/esm-es5/wm-chart-slice.entry.js +1 -0
  252. package/dist/esm-es5/wm-chart.entry.js +1 -0
  253. package/dist/esm-es5/wm-date-range.entry.js +1 -0
  254. package/dist/esm-es5/wm-datepicker.entry.js +1 -0
  255. package/dist/esm-es5/wm-file-list.entry.js +1 -0
  256. package/dist/esm-es5/wm-file.entry.js +1 -0
  257. package/dist/esm-es5/wm-flyout.entry.js +1 -0
  258. package/dist/esm-es5/wm-input.entry.js +1 -0
  259. package/dist/esm-es5/wm-line-chart.entry.js +1 -0
  260. package/dist/esm-es5/wm-modal-pss_3.entry.js +1 -0
  261. package/dist/esm-es5/wm-modal_3.entry.js +1 -0
  262. package/dist/esm-es5/wm-navigation_3.entry.js +1 -0
  263. package/dist/esm-es5/wm-navigator.entry.js +1 -0
  264. package/dist/esm-es5/wm-nested-select.entry.js +1 -0
  265. package/dist/esm-es5/wm-optgroup.entry.js +1 -0
  266. package/dist/esm-es5/wm-option_2.entry.js +1 -0
  267. package/dist/esm-es5/wm-pagination.entry.js +1 -0
  268. package/dist/esm-es5/wm-progress-indicator_3.entry.js +1 -0
  269. package/dist/esm-es5/wm-search.entry.js +1 -0
  270. package/dist/esm-es5/wm-snackbar.entry.js +1 -0
  271. package/dist/esm-es5/wm-tab-item_3.entry.js +1 -0
  272. package/dist/esm-es5/wm-tag-input.entry.js +1 -0
  273. package/dist/esm-es5/wm-tag-option.entry.js +1 -0
  274. package/dist/esm-es5/wm-textarea.entry.js +1 -0
  275. package/dist/esm-es5/wm-timepicker.entry.js +1 -0
  276. package/dist/esm-es5/wm-toggletip.entry.js +1 -0
  277. package/dist/esm-es5/wm-uploader.entry.js +1 -0
  278. package/dist/esm-es5/wm-wrapper.entry.js +1 -0
  279. package/dist/index.js +1 -1
  280. package/dist/loader/cdn.js +1 -2
  281. package/dist/loader/index.cjs.js +1 -2
  282. package/dist/loader/index.d.ts +13 -2
  283. package/dist/loader/index.es2017.js +1 -2
  284. package/dist/loader/index.js +1 -2
  285. package/dist/loader/package.json +2 -1
  286. package/dist/ripple/index.esm.js +0 -0
  287. package/dist/ripple/p-03a6850a.entry.js +1 -0
  288. package/dist/ripple/p-0c3162d5.system.entry.js +1 -0
  289. package/dist/ripple/p-0ec71f08.system.entry.js +1 -0
  290. package/dist/ripple/p-1032c0db.system.entry.js +1 -0
  291. package/dist/ripple/p-117c3d78.system.js +2 -0
  292. package/dist/ripple/p-12024d3b.system.entry.js +1 -0
  293. package/dist/ripple/p-13152ac1.system.entry.js +1 -0
  294. package/dist/ripple/p-1318ae67.entry.js +1 -0
  295. package/dist/ripple/p-137bf0c0.system.entry.js +1 -0
  296. package/dist/ripple/p-13bb6faf.entry.js +1 -0
  297. package/dist/ripple/p-16ff8110.entry.js +1 -0
  298. package/dist/ripple/p-1825d519.system.entry.js +1 -0
  299. package/dist/ripple/p-18417851.entry.js +1 -0
  300. package/dist/ripple/p-1c655f6b.entry.js +1 -0
  301. package/dist/ripple/p-1ce77857.system.entry.js +1 -0
  302. package/dist/ripple/p-1d76061a.entry.js +1 -0
  303. package/dist/ripple/p-22b57f73.system.entry.js +1 -0
  304. package/dist/ripple/p-24dfbf1d.system.entry.js +1 -0
  305. package/dist/ripple/p-28996d67.system.entry.js +1 -0
  306. package/dist/ripple/p-30118d12.system.entry.js +1 -0
  307. package/dist/ripple/p-32f3581a.entry.js +1 -0
  308. package/dist/ripple/p-334d8711.system.js +1 -0
  309. package/dist/ripple/p-3c8c5933.js +1 -0
  310. package/dist/ripple/p-436bf381.system.entry.js +1 -0
  311. package/dist/ripple/p-43843597.system.entry.js +1 -0
  312. package/dist/ripple/p-45999149.system.js +1 -0
  313. package/dist/ripple/p-48b596ae.entry.js +1 -0
  314. package/dist/ripple/p-4bab5360.system.js +1 -0
  315. package/dist/ripple/p-4ff0db4d.entry.js +1 -0
  316. package/dist/ripple/p-50ea2036.system.js +1 -0
  317. package/dist/ripple/p-57f1bafd.system.entry.js +1 -0
  318. package/dist/ripple/p-5b0e9165.entry.js +1 -0
  319. package/dist/ripple/p-6266fcbf.system.entry.js +1 -0
  320. package/dist/ripple/p-646e22d3.system.entry.js +1 -0
  321. package/dist/ripple/p-6950e8ed.system.js +1 -0
  322. package/dist/ripple/p-6c6da5db.entry.js +1 -0
  323. package/dist/ripple/p-6d2af8d9.system.entry.js +1 -0
  324. package/dist/ripple/p-6d46f775.system.entry.js +1 -0
  325. package/dist/ripple/p-6de0efee.entry.js +1 -0
  326. package/dist/ripple/p-7833db63.entry.js +1 -0
  327. package/dist/ripple/p-7b7c32af.entry.js +1 -0
  328. package/dist/ripple/p-817aa29c.entry.js +1 -0
  329. package/dist/ripple/p-82c9bd47.entry.js +1 -0
  330. package/dist/ripple/p-8480138d.entry.js +1 -0
  331. package/dist/ripple/p-85ef702d.entry.js +1 -0
  332. package/dist/ripple/p-86bcd942.system.entry.js +1 -0
  333. package/dist/ripple/p-8799bce9.entry.js +1 -0
  334. package/dist/ripple/p-8ac14bb1.system.js +1 -0
  335. package/dist/ripple/p-8dcc8c0c.entry.js +1 -0
  336. package/dist/ripple/p-8fa572a8.entry.js +1 -0
  337. package/dist/ripple/p-904545cc.js +1 -0
  338. package/dist/ripple/p-90cb5d27.system.entry.js +1 -0
  339. package/dist/ripple/p-9202ef69.system.entry.js +1 -0
  340. package/dist/ripple/p-9f971522.system.entry.js +1 -0
  341. package/dist/ripple/p-a5dc49c1.system.entry.js +1 -0
  342. package/dist/ripple/p-a73fb160.system.entry.js +1 -0
  343. package/dist/ripple/p-a9580e7a.system.entry.js +1 -0
  344. package/dist/ripple/p-b04a6351.entry.js +1 -0
  345. package/dist/ripple/p-b09998e1.entry.js +1 -0
  346. package/dist/ripple/p-b3a86ec4.system.entry.js +1 -0
  347. package/dist/ripple/p-b501f06c.entry.js +1 -0
  348. package/dist/ripple/p-b957033b.entry.js +1 -0
  349. package/dist/ripple/p-c2258438.entry.js +1 -0
  350. package/dist/ripple/p-ca3abcc0.system.entry.js +1 -0
  351. package/dist/ripple/p-cc455a6c.system.entry.js +1 -0
  352. package/dist/ripple/p-cda66d45.js +1 -0
  353. package/dist/ripple/p-cde2ca4d.system.entry.js +1 -0
  354. package/dist/ripple/p-cdf9c0e9.entry.js +1 -0
  355. package/dist/ripple/p-d0858afa.js +2 -0
  356. package/dist/ripple/p-d37f8f66.js +1 -0
  357. package/dist/ripple/p-d4ae193e.js +1 -0
  358. package/dist/ripple/p-d4d769a7.system.js +1 -0
  359. package/dist/ripple/p-d6a9000f.system.entry.js +1 -0
  360. package/dist/ripple/p-d6cd9f79.entry.js +1 -0
  361. package/dist/ripple/p-d9e4335e.entry.js +1 -0
  362. package/dist/ripple/p-dadf3ed3.entry.js +1 -0
  363. package/dist/ripple/p-dc3684b5.entry.js +1 -0
  364. package/dist/ripple/p-dca94e24.entry.js +1 -0
  365. package/dist/ripple/p-dcd6acc5.system.entry.js +1 -0
  366. package/dist/ripple/p-dd81e308.entry.js +1 -0
  367. package/dist/ripple/p-e11d9b06.system.entry.js +1 -0
  368. package/dist/ripple/p-e36e71dc.system.entry.js +1 -0
  369. package/dist/ripple/p-e6a81600.entry.js +1 -0
  370. package/dist/ripple/p-ef7d84da.system.entry.js +1 -0
  371. package/dist/ripple/p-f1de3153.entry.js +1 -0
  372. package/dist/ripple/p-f3e84476.system.entry.js +1 -0
  373. package/dist/ripple/p-f4d27fea.system.entry.js +1 -0
  374. package/dist/ripple/p-fcf4bd61.system.entry.js +1 -0
  375. package/dist/ripple/p-fd02c124.entry.js +1 -0
  376. package/dist/ripple/p-ffa20853.entry.js +1 -0
  377. package/dist/ripple/ripple.esm.js +1 -0
  378. package/dist/ripple/ripple.js +127 -0
  379. package/dist/types/components/charts/chartFunctions.d.ts +54 -0
  380. package/dist/types/components/charts/priv-chart-popover/priv-chart-popover.d.ts +35 -0
  381. package/dist/types/components/charts/priv-chart-popover-old/priv-chart-popover-old.d.ts +26 -0
  382. package/dist/types/components/charts/wm-chart/wm-chart-slice.d.ts +11 -0
  383. package/dist/types/components/charts/wm-chart/wm-chart.d.ts +44 -0
  384. package/dist/types/components/charts/wm-chart-bar/wm-chart-bar.d.ts +62 -0
  385. package/dist/types/components/charts/wm-chart-column/wm-chart-column.d.ts +73 -0
  386. package/dist/types/components/charts/wm-chart-legend/wm-chart-legend.d.ts +26 -0
  387. package/dist/types/components/charts/wm-line-chart/wm-line-chart.d.ts +87 -0
  388. package/dist/types/components/charts/wm-progress-monitor/wm-progress-indicator.d.ts +34 -0
  389. package/dist/types/components/charts/wm-progress-monitor/wm-progress-monitor.d.ts +22 -0
  390. package/dist/types/components/charts/wm-progress-monitor/wm-progress-slice.d.ts +10 -0
  391. package/dist/types/components/datepickers/priv-calendar/priv-calendar.d.ts +89 -0
  392. package/dist/types/components/datepickers/wm-date-range.d.ts +73 -0
  393. package/dist/types/components/datepickers/wm-datepicker.d.ts +54 -0
  394. package/dist/types/components/selects/priv-option-list/priv-option-list.d.ts +71 -0
  395. package/dist/types/components/selects/wm-nested-select/wm-nested-select.d.ts +62 -0
  396. package/dist/types/components/selects/wm-optgroup/wm-optgroup.d.ts +21 -0
  397. package/dist/types/components/selects/wm-option/wm-option.d.ts +40 -0
  398. package/dist/types/components/selects/wm-select/wm-select.d.ts +66 -0
  399. package/dist/types/components/wm-action-menu/wm-action-menu.d.ts +54 -40
  400. package/dist/types/components/wm-button/wm-button.d.ts +43 -34
  401. package/dist/types/components/wm-file/wm-file.d.ts +48 -0
  402. package/dist/types/components/wm-file-list/wm-file-list.d.ts +5 -0
  403. package/dist/types/components/wm-flyout/wm-flyout.d.ts +48 -0
  404. package/dist/types/components/wm-input/wm-input.d.ts +50 -28
  405. package/dist/types/components/wm-menuitem/wm-menuitem.d.ts +26 -27
  406. package/dist/types/components/wm-modal/wm-modal-footer.d.ts +12 -13
  407. package/dist/types/components/wm-modal/wm-modal-header.d.ts +8 -10
  408. package/dist/types/components/wm-modal/wm-modal.d.ts +28 -31
  409. package/dist/types/components/wm-modal-pss/wm-modal-pss-footer.d.ts +14 -0
  410. package/dist/types/components/wm-modal-pss/wm-modal-pss-header.d.ts +10 -0
  411. package/dist/types/components/wm-modal-pss/wm-modal-pss.d.ts +35 -0
  412. package/dist/types/components/wm-navigation/wm-navigation-hamburger.d.ts +16 -0
  413. package/dist/types/components/wm-navigation/wm-navigation-item.d.ts +9 -0
  414. package/dist/types/components/wm-navigation/wm-navigation.d.ts +24 -0
  415. package/dist/types/components/wm-navigator/priv-navigator-button/priv-navigator-button.d.ts +6 -7
  416. package/dist/types/components/wm-navigator/priv-navigator-item/priv-navigator-item.d.ts +10 -10
  417. package/dist/types/components/wm-navigator/wm-navigator.d.ts +55 -57
  418. package/dist/types/components/wm-pagination/wm-pagination.d.ts +31 -28
  419. package/dist/types/components/wm-search/wm-search.d.ts +71 -75
  420. package/dist/types/components/wm-snackbar/wm-snackbar.d.ts +27 -28
  421. package/dist/types/components/wm-tabs/wm-tab-item/wm-tab-item.d.ts +30 -31
  422. package/dist/types/components/wm-tabs/wm-tab-list/wm-tab-list.d.ts +32 -48
  423. package/dist/types/components/wm-tabs/wm-tab-panel/wm-tab-panel.d.ts +14 -16
  424. package/dist/types/components/wm-tag-input/wm-tag-input.d.ts +121 -80
  425. package/dist/types/components/wm-tag-input/wm-tag-option/wm-tag-option.d.ts +18 -0
  426. package/dist/types/components/wm-textarea/wm-textarea.d.ts +31 -0
  427. package/dist/types/components/wm-timepicker/wm-timepicker.d.ts +49 -55
  428. package/dist/types/components/wm-toggletip/wm-toggletip.d.ts +36 -23
  429. package/dist/types/components/wm-uploader/wm-uploader.d.ts +64 -72
  430. package/dist/types/components/wm-wrapper/wm-wrapper.d.ts +4 -4
  431. package/dist/types/components.d.ts +1516 -211
  432. package/dist/types/global/__mocks__/functions.d.ts +2 -1
  433. package/dist/types/global/functions.d.ts +67 -11
  434. package/dist/types/global/interfaces.d.ts +152 -23
  435. package/dist/types/global/intl.d.ts +62 -0
  436. package/dist/types/global/services/__mocks__/http-service.d.ts +1 -1
  437. package/dist/types/stencil-public-runtime.d.ts +338 -219
  438. package/package.json +16 -22
  439. package/dist/cjs/app-globals-6b0c6e80.js +0 -110
  440. package/dist/cjs/app-globals-f1dd8fda.js +0 -47
  441. package/dist/cjs/componentlibrary.cjs.js +0 -20
  442. package/dist/cjs/css-shim-a7379e2b.js +0 -6
  443. package/dist/cjs/dom-3e7d9c3b.js +0 -75
  444. package/dist/cjs/functions-65513c61.js +0 -8360
  445. package/dist/cjs/global-6849642d.js +0 -38
  446. package/dist/cjs/http-service-494d81de.js +0 -57
  447. package/dist/cjs/http-service-9e8c4dd5.js +0 -57
  448. package/dist/cjs/index-298ebef1.js +0 -2976
  449. package/dist/cjs/interfaces-a3338581.js +0 -35
  450. package/dist/cjs/interfaces-b2beb752.js +0 -54
  451. package/dist/cjs/priv-chart-popover.cjs.entry.js +0 -89
  452. package/dist/cjs/priv-datepicker.cjs.entry.js +0 -672
  453. package/dist/cjs/shadow-css-09555044.js +0 -391
  454. package/dist/cjs/wm-action-menu.cjs.entry.js +0 -206
  455. package/dist/cjs/wm-menuitem.cjs.entry.js +0 -118
  456. package/dist/cjs/wm-modal-footer.cjs.entry.js +0 -43
  457. package/dist/cjs/wm-modal-header.cjs.entry.js +0 -45
  458. package/dist/cjs/wm-modal.cjs.entry.js +0 -149
  459. package/dist/cjs/wm-network-uploader.cjs.entry.js +0 -431
  460. package/dist/cjs/wm-option.cjs.entry.js +0 -123
  461. package/dist/cjs/wm-select.cjs.entry.js +0 -366
  462. package/dist/cjs/wm-tab-item.cjs.entry.js +0 -82
  463. package/dist/cjs/wm-tab-list.cjs.entry.js +0 -205
  464. package/dist/cjs/wm-tab-panel.cjs.entry.js +0 -42
  465. package/dist/collection/components/wm-chart/priv-chart-popover/priv-chart-popover.css +0 -132
  466. package/dist/collection/components/wm-chart/priv-chart-popover/priv-chart-popover.js +0 -232
  467. package/dist/collection/components/wm-chart/wm-chart-slice.js +0 -64
  468. package/dist/collection/components/wm-chart/wm-chart.css +0 -337
  469. package/dist/collection/components/wm-chart/wm-chart.js +0 -710
  470. package/dist/collection/components/wm-datepicker/priv-datepicker/priv-datepicker.css +0 -365
  471. package/dist/collection/components/wm-datepicker/priv-datepicker/priv-datepicker.js +0 -1003
  472. package/dist/collection/components/wm-datepicker/wm-datepicker.css +0 -211
  473. package/dist/collection/components/wm-datepicker/wm-datepicker.js +0 -445
  474. package/dist/collection/components/wm-option/wm-option.css +0 -162
  475. package/dist/collection/components/wm-option/wm-option.js +0 -394
  476. package/dist/collection/components/wm-select/wm-select.css +0 -315
  477. package/dist/collection/components/wm-select/wm-select.js +0 -676
  478. package/dist/collection/components/wm-uploader/wm-network-uploader/wm-network-uploader.css +0 -642
  479. package/dist/collection/components/wm-uploader/wm-network-uploader/wm-network-uploader.js +0 -753
  480. package/dist/componentlibrary/app-globals-18876ad3.js +0 -45
  481. package/dist/componentlibrary/app-globals-307a1083.js +0 -108
  482. package/dist/componentlibrary/componentlibrary.css +0 -84
  483. package/dist/componentlibrary/componentlibrary.esm.js +0 -1
  484. package/dist/componentlibrary/css-shim-bbdf0cc6.js +0 -4
  485. package/dist/componentlibrary/dom-1f98a75f.js +0 -73
  486. package/dist/componentlibrary/functions-316c1b23.js +0 -8340
  487. package/dist/componentlibrary/http-service-5d037e16.js +0 -52
  488. package/dist/componentlibrary/index-d5997567.js +0 -2938
  489. package/dist/componentlibrary/interfaces-50753346.js +0 -51
  490. package/dist/componentlibrary/p-01bdfed8.js +0 -16
  491. package/dist/componentlibrary/p-0ca70ed4.entry.js +0 -1
  492. package/dist/componentlibrary/p-126bde92.entry.js +0 -1
  493. package/dist/componentlibrary/p-12a67d93.entry.js +0 -1
  494. package/dist/componentlibrary/p-188deaf5.entry.js +0 -1
  495. package/dist/componentlibrary/p-2514df6f.entry.js +0 -1
  496. package/dist/componentlibrary/p-269b8a5f.entry.js +0 -1
  497. package/dist/componentlibrary/p-35e57079.entry.js +0 -1
  498. package/dist/componentlibrary/p-414e20f7.entry.js +0 -1
  499. package/dist/componentlibrary/p-43f1298b.js +0 -1
  500. package/dist/componentlibrary/p-4d387ec6.entry.js +0 -1
  501. package/dist/componentlibrary/p-59ba81d6.entry.js +0 -1
  502. package/dist/componentlibrary/p-5e3cbec8.entry.js +0 -1
  503. package/dist/componentlibrary/p-5e81e830.entry.js +0 -1
  504. package/dist/componentlibrary/p-64ff5040.js +0 -1
  505. package/dist/componentlibrary/p-68a871d3.entry.js +0 -1
  506. package/dist/componentlibrary/p-996a7395.entry.js +0 -1
  507. package/dist/componentlibrary/p-9b460452.entry.js +0 -1
  508. package/dist/componentlibrary/p-a416e410.entry.js +0 -1
  509. package/dist/componentlibrary/p-d550a94f.entry.js +0 -1
  510. package/dist/componentlibrary/p-e4735c23.entry.js +0 -1
  511. package/dist/componentlibrary/p-e725f388.entry.js +0 -1
  512. package/dist/componentlibrary/p-e9532ae5.entry.js +0 -1
  513. package/dist/componentlibrary/p-edf6f848.entry.js +0 -1
  514. package/dist/componentlibrary/p-fd8070fb.js +0 -1
  515. package/dist/componentlibrary/priv-chart-popover.entry.js +0 -85
  516. package/dist/componentlibrary/priv-datepicker.entry.js +0 -668
  517. package/dist/componentlibrary/priv-navigator-button.entry.js +0 -25
  518. package/dist/componentlibrary/priv-navigator-item.entry.js +0 -30
  519. package/dist/componentlibrary/shadow-css-67b66845.js +0 -389
  520. package/dist/componentlibrary/wm-action-menu.entry.js +0 -202
  521. package/dist/componentlibrary/wm-button.entry.js +0 -148
  522. package/dist/componentlibrary/wm-chart-slice.entry.js +0 -18
  523. package/dist/componentlibrary/wm-chart.entry.js +0 -504
  524. package/dist/componentlibrary/wm-datepicker.entry.js +0 -258
  525. package/dist/componentlibrary/wm-input.entry.js +0 -106
  526. package/dist/componentlibrary/wm-menuitem.entry.js +0 -114
  527. package/dist/componentlibrary/wm-modal-footer.entry.js +0 -39
  528. package/dist/componentlibrary/wm-modal-header.entry.js +0 -41
  529. package/dist/componentlibrary/wm-modal.entry.js +0 -145
  530. package/dist/componentlibrary/wm-navigator.entry.js +0 -275
  531. package/dist/componentlibrary/wm-network-uploader.entry.js +0 -427
  532. package/dist/componentlibrary/wm-option.entry.js +0 -119
  533. package/dist/componentlibrary/wm-pagination.entry.js +0 -172
  534. package/dist/componentlibrary/wm-search.entry.js +0 -227
  535. package/dist/componentlibrary/wm-select.entry.js +0 -362
  536. package/dist/componentlibrary/wm-snackbar.entry.js +0 -156
  537. package/dist/componentlibrary/wm-tab-item.entry.js +0 -78
  538. package/dist/componentlibrary/wm-tab-list.entry.js +0 -201
  539. package/dist/componentlibrary/wm-tab-panel.entry.js +0 -38
  540. package/dist/componentlibrary/wm-tag-input.entry.js +0 -509
  541. package/dist/componentlibrary/wm-timepicker.entry.js +0 -382
  542. package/dist/componentlibrary/wm-toggletip.entry.js +0 -124
  543. package/dist/componentlibrary/wm-uploader.entry.js +0 -338
  544. package/dist/componentlibrary/wm-wrapper.entry.js +0 -17
  545. package/dist/esm/app-globals-18876ad3.js +0 -45
  546. package/dist/esm/app-globals-307a1083.js +0 -108
  547. package/dist/esm/componentlibrary.js +0 -18
  548. package/dist/esm/css-shim-bbdf0cc6.js +0 -4
  549. package/dist/esm/dom-1f98a75f.js +0 -73
  550. package/dist/esm/functions-316c1b23.js +0 -8340
  551. package/dist/esm/global-430cb201.js +0 -36
  552. package/dist/esm/http-service-3dc3b3e7.js +0 -52
  553. package/dist/esm/http-service-5d037e16.js +0 -52
  554. package/dist/esm/index-d5997567.js +0 -2938
  555. package/dist/esm/interfaces-2b97fab2.js +0 -32
  556. package/dist/esm/interfaces-50753346.js +0 -51
  557. package/dist/esm/polyfills/css-shim.js +0 -1
  558. package/dist/esm/priv-chart-popover.entry.js +0 -85
  559. package/dist/esm/priv-datepicker.entry.js +0 -668
  560. package/dist/esm/shadow-css-67b66845.js +0 -389
  561. package/dist/esm/wm-action-menu.entry.js +0 -202
  562. package/dist/esm/wm-menuitem.entry.js +0 -114
  563. package/dist/esm/wm-modal-footer.entry.js +0 -39
  564. package/dist/esm/wm-modal-header.entry.js +0 -41
  565. package/dist/esm/wm-modal.entry.js +0 -145
  566. package/dist/esm/wm-network-uploader.entry.js +0 -427
  567. package/dist/esm/wm-option.entry.js +0 -119
  568. package/dist/esm/wm-select.entry.js +0 -362
  569. package/dist/esm/wm-tab-item.entry.js +0 -78
  570. package/dist/esm/wm-tab-list.entry.js +0 -201
  571. package/dist/esm/wm-tab-panel.entry.js +0 -38
  572. package/dist/types/components/wm-chart/priv-chart-popover/priv-chart-popover.d.ts +0 -23
  573. package/dist/types/components/wm-chart/wm-chart-slice.d.ts +0 -8
  574. package/dist/types/components/wm-chart/wm-chart.d.ts +0 -77
  575. package/dist/types/components/wm-datepicker/priv-datepicker/priv-datepicker.d.ts +0 -75
  576. package/dist/types/components/wm-datepicker/wm-datepicker.d.ts +0 -39
  577. package/dist/types/components/wm-option/wm-option.d.ts +0 -28
  578. package/dist/types/components/wm-select/wm-select.d.ts +0 -63
  579. package/dist/types/components/wm-uploader/wm-network-uploader/wm-network-uploader.d.ts +0 -85
  580. /package/dist/{componentlibrary/index.esm.js → collection/dev/button.js} +0 -0
@@ -0,0 +1,862 @@
1
+ import { h, Host, forceUpdate } from "@stencil/core";
2
+ import { csvToArray, debounce, transposeMatrix, getSmallestSkipInterval, wrapAround, calcPercentageInRange, } from "../../../global/functions";
3
+ import { getInterval, inferDecimalPlacesForUnitValue, suffixNumber } from "../chartFunctions";
4
+ import { chartMessages, globalMessages, lineChartMessages } from "../../../global/intl";
5
+ export class LineChart {
6
+ constructor() {
7
+ this.minTickWidth = 120;
8
+ this.lineStyles = [
9
+ { color: "#8b86ca", icon: "triangle" }, // lavender
10
+ { color: "#2e1b46", icon: "circle" }, // midnight
11
+ { color: "#0089e4", icon: "square" }, // blue
12
+ { color: "#088000", icon: "star" }, // forest
13
+ { color: "#ea8500", icon: "rhombus" }, // orange
14
+ { color: "#d54f41", icon: "triangle-inverted" }, // red
15
+ { color: "#146ca9", icon: "pentagon" }, // blue
16
+ ];
17
+ this.debouncedResize = debounce(async () => {
18
+ forceUpdate(this.el);
19
+ }, 100);
20
+ this.label = undefined;
21
+ this.description = "";
22
+ this.xAxisLabel = undefined;
23
+ this.yAxisLabel = undefined;
24
+ this.showGrid = true;
25
+ this.lineData = undefined;
26
+ this.units = "null,null";
27
+ this.labelWidth = "120px";
28
+ this.highlightQualifier = lineChartMessages.highlightQualifier;
29
+ this.highlightStart = undefined;
30
+ this.highlightEnd = undefined;
31
+ this.visibilityToggles = false;
32
+ this.showDeltas = false;
33
+ this.yRange = undefined;
34
+ this.spotlightData = undefined;
35
+ this.decimalPlaces = undefined;
36
+ this.parsedLineData = {};
37
+ this.popoverIndex = -1;
38
+ this.focusedLine = -1;
39
+ this.hiddenLines = [];
40
+ this.isTabbing = false;
41
+ this.announcement = "";
42
+ }
43
+ get xIntervals() {
44
+ const firstLine = Object.values(this.parsedLineData)[0];
45
+ return firstLine ? Object.keys(firstLine) : [];
46
+ }
47
+ get yIntervals() {
48
+ if (Object.keys(this.parsedLineData).length === 0)
49
+ return [];
50
+ let yIntervals = [];
51
+ if (this.yRange) {
52
+ yIntervals = csvToArray(this.yRange).map((val) => parseFloat(val));
53
+ }
54
+ else {
55
+ // gather all yValues
56
+ let allYValues = [];
57
+ const lines = Object.values(this.parsedLineData).flat();
58
+ lines.forEach((line) => allYValues.push(...Object.values(line)));
59
+ const filteredYValues = allYValues.filter((val) => val !== null);
60
+ // Clamp to integers for clean intervals
61
+ let minYValue = Math.floor(Math.min(...filteredYValues));
62
+ let maxYValue = Math.ceil(Math.max(...filteredYValues));
63
+ if (minYValue === maxYValue) {
64
+ // If the axis bounds are identical (flat line), add some grid height
65
+ minYValue -= 1;
66
+ maxYValue += 1;
67
+ }
68
+ // calculate neat yInterval
69
+ let interval = getInterval(maxYValue - minYValue, 4);
70
+ // find new min below smallest yValue that divides cleanly by interval
71
+ let counter = interval;
72
+ while (minYValue % interval !== 0 && counter > 0) {
73
+ minYValue--;
74
+ counter--;
75
+ }
76
+ // calculate new interval using new min
77
+ interval = getInterval(maxYValue - minYValue, 4);
78
+ let current = minYValue;
79
+ // determine top interval, no more than one tick above max yValue
80
+ while (current <= maxYValue + interval) {
81
+ yIntervals.push(current);
82
+ current += interval;
83
+ }
84
+ }
85
+ return yIntervals.reverse();
86
+ }
87
+ get intervalInfo() {
88
+ const maxTicks = this.plotAreaEl && this.plotAreaEl.clientWidth > 0
89
+ ? Math.round(this.plotAreaEl.clientWidth / this.minTickWidth)
90
+ : this.xIntervals.length;
91
+ return getSmallestSkipInterval(this.xIntervals, maxTicks);
92
+ }
93
+ get displayedXIntervals() {
94
+ return this.intervalInfo.skippedList;
95
+ }
96
+ get dataPointMatrix() {
97
+ if (Object.keys(this.parsedLineData).length === 0)
98
+ return [];
99
+ return Object.entries(this.parsedLineData).map((entry) => this.buildLineDataPointDetails(entry[0], entry[1]));
100
+ }
101
+ get popoverData() {
102
+ return transposeMatrix(this.dataPointMatrix);
103
+ }
104
+ get spotlightXValue() {
105
+ if (this.spotlightData) {
106
+ const keys = Object.keys(this.spotlightData).filter((key) => key !== "label");
107
+ return keys[0];
108
+ }
109
+ return undefined;
110
+ }
111
+ get spotlightYValue() {
112
+ if (this.spotlightData && this.spotlightXValue) {
113
+ const raw = this.spotlightData[this.spotlightXValue];
114
+ if (typeof raw !== "number") {
115
+ return undefined;
116
+ }
117
+ return raw;
118
+ }
119
+ return undefined;
120
+ }
121
+ parseData() {
122
+ if (typeof this.lineData === "string") {
123
+ this.parsedLineData = JSON.parse(this.lineData);
124
+ }
125
+ else {
126
+ this.parsedLineData = this.lineData;
127
+ }
128
+ }
129
+ get hasPartialInterval() {
130
+ // if chart width is too small, an odd # of intervals like 1,2,3,4,5,6,7 can be shortened to 1,3,5,7 or 1,4,7
131
+ // but an even # like 1,2,3,4,5,6,7,8 will be shortened to 1,3,5,7 (can't show first and last interval)
132
+ // in these cases, show a partial interval must be shown in order to still provide space to plot the 8th data point
133
+ // e.g intervals will be 1-3, 3-5, 5-7, 7-8
134
+ return this.intervalInfo.skipInterval > 0 && this.xIntervals.length % 2 === 0;
135
+ }
136
+ get parsedUnits() {
137
+ return csvToArray(this.units).map((unit) => (unit === "null" ? null : unit));
138
+ }
139
+ get visibilityToggleEls() {
140
+ return this.legendEl.querySelectorAll("wm-button");
141
+ }
142
+ get lineEls() {
143
+ return this.plotAreaEl.querySelectorAll(".line");
144
+ }
145
+ get firstVisibleLineIdx() {
146
+ let firstVisibleLineIdx = 0;
147
+ while (this.hiddenLines.includes(firstVisibleLineIdx)) {
148
+ firstVisibleLineIdx++;
149
+ }
150
+ return firstVisibleLineIdx < this.dataPointMatrix.length ? firstVisibleLineIdx : -1;
151
+ }
152
+ get pointEls() {
153
+ return this.plotAreaEl.querySelectorAll(".point");
154
+ }
155
+ toggleTabbingOn() {
156
+ this.isTabbing = true;
157
+ }
158
+ toggleTabbingOff() {
159
+ this.isTabbing = false;
160
+ }
161
+ componentWillLoad() {
162
+ this.parseData();
163
+ }
164
+ componentDidLoad() {
165
+ const resizeObserver = new ResizeObserver(() => this.debouncedResize());
166
+ resizeObserver.observe(this.el);
167
+ }
168
+ handleVisibilityToggleKeydown(ev, toggleIdx) {
169
+ switch (ev.key) {
170
+ case "Tab":
171
+ if (!ev.shiftKey && this.firstVisibleLineIdx !== -1) {
172
+ ev.preventDefault();
173
+ this.announce(this.lineFocusMessage(this.firstVisibleLineIdx));
174
+ const point = this.lineEls[this.firstVisibleLineIdx].querySelector(".point");
175
+ point && this.focusDataPointByEl(point);
176
+ }
177
+ break;
178
+ case "ArrowUp":
179
+ case "ArrowLeft":
180
+ ev.preventDefault();
181
+ const prevToggleIdx = wrapAround(toggleIdx, -1, this.dataPointMatrix.length - 1);
182
+ this.visibilityToggleEls[prevToggleIdx].focus();
183
+ break;
184
+ case "ArrowDown":
185
+ case "ArrowRight":
186
+ ev.preventDefault();
187
+ const nextToggleIdx = wrapAround(toggleIdx, 1, this.dataPointMatrix.length - 1);
188
+ this.visibilityToggleEls[nextToggleIdx].focus();
189
+ break;
190
+ }
191
+ }
192
+ handleDataPointKeydown(ev) {
193
+ const curPointEl = ev.target;
194
+ switch (ev.key) {
195
+ case "Tab":
196
+ if (ev.shiftKey && this.visibilityToggles) {
197
+ ev.preventDefault();
198
+ this.visibilityToggleEls[0].focus();
199
+ }
200
+ break;
201
+ case "ArrowUp":
202
+ ev.preventDefault();
203
+ this.navigatePointsVertically(curPointEl, -1);
204
+ break;
205
+ case "ArrowDown":
206
+ ev.preventDefault();
207
+ this.navigatePointsVertically(curPointEl, 1);
208
+ break;
209
+ case "ArrowLeft":
210
+ ev.preventDefault();
211
+ this.navigatePointsHorizontally(curPointEl, -1);
212
+ break;
213
+ case "ArrowRight":
214
+ ev.preventDefault();
215
+ this.navigatePointsHorizontally(curPointEl, 1);
216
+ break;
217
+ }
218
+ }
219
+ navigatePointsVertically(originPoint, stepAmount) {
220
+ const pointElsInColumn = Array.from(this.pointEls).filter((p) => p.dataset.pointidx == originPoint.dataset.pointidx);
221
+ if (pointElsInColumn.length > 1) {
222
+ const nextPointIdx = wrapAround(pointElsInColumn.indexOf(originPoint), stepAmount, pointElsInColumn.length - 1);
223
+ const nextVerticalPoint = pointElsInColumn[nextPointIdx];
224
+ const idx = nextVerticalPoint.dataset.lineidx;
225
+ const msg = idx && this.lineFocusMessage(parseInt(idx));
226
+ msg && this.announce(msg);
227
+ this.focusDataPointByEl(nextVerticalPoint);
228
+ }
229
+ }
230
+ navigatePointsHorizontally(originPoint, stepAmount) {
231
+ const linePoints = Array.from(originPoint.parentElement.querySelectorAll(".point"));
232
+ if (linePoints.length > 1) {
233
+ const nextPointIdxInDirection = wrapAround(linePoints.indexOf(originPoint), stepAmount, linePoints.length - 1);
234
+ const nextHorizontalPoint = linePoints[nextPointIdxInDirection];
235
+ this.focusDataPointByEl(nextHorizontalPoint);
236
+ }
237
+ }
238
+ announce(message) {
239
+ // \u00A0 is a non-breaking space character, which causes the message to be read as a new one
240
+ if (this.liveRegionEl.textContent === message) {
241
+ message += "\u00A0";
242
+ }
243
+ this.announcement = message;
244
+ }
245
+ lineFocusMessage(lineIdx) {
246
+ const label = this.dataPointMatrix[lineIdx][0].lineLabel;
247
+ const numDataPoints = this.dataPointMatrix[lineIdx].filter((datapoint) => datapoint.yValue !== null).length;
248
+ const focusMessage = lineChartMessages.getLineFocusAnnouncement(label, lineIdx + 1, this.dataPointMatrix.length, numDataPoints);
249
+ return focusMessage;
250
+ }
251
+ focusDataPointByEl(pointEl) {
252
+ this.pointEls.forEach((point) => (point.tabIndex = -1));
253
+ pointEl.tabIndex = 0;
254
+ pointEl.focus();
255
+ }
256
+ formatDisplayYValue(yValue) {
257
+ if (this.decimalPlaces === undefined) {
258
+ return new Intl.NumberFormat().format(yValue);
259
+ }
260
+ return yValue.toFixed(this.decimalPlaces);
261
+ }
262
+ formatYAxisIntervalLabel(intervalValue) {
263
+ var _a;
264
+ const decimalPlaces = (_a = this.decimalPlaces) !== null && _a !== void 0 ? _a : inferDecimalPlacesForUnitValue(intervalValue);
265
+ let absFormattedValue = suffixNumber(Math.abs(intervalValue), decimalPlaces);
266
+ if (intervalValue < 0) {
267
+ absFormattedValue = "-" + absFormattedValue;
268
+ }
269
+ return absFormattedValue;
270
+ }
271
+ buildLineDataPointDetails(lineLabel, line) {
272
+ let dataPointDetailsList = [];
273
+ const lineDataPoints = Object.entries(line);
274
+ let isHighlighted;
275
+ lineDataPoints.forEach((entry, pointIdx) => {
276
+ const [xValue, yValue] = entry;
277
+ let xPositionPercent = (100 / (lineDataPoints.length - 1)) * pointIdx;
278
+ const yPositionPercent = yValue === null
279
+ ? null
280
+ : 100 - calcPercentageInRange(yValue, this.yIntervals[this.yIntervals.length - 1], this.yIntervals[0]);
281
+ // add space between first points and y-axis
282
+ if (pointIdx === 0) {
283
+ xPositionPercent +=
284
+ this.plotAreaEl && this.plotAreaEl.clientWidth > 0 ? (8 / this.plotAreaEl.clientWidth) * 100 : 1;
285
+ }
286
+ if (xValue === this.highlightStart && !isHighlighted) {
287
+ isHighlighted = true;
288
+ }
289
+ dataPointDetailsList.push({
290
+ lineLabel: lineLabel,
291
+ xValue: xValue,
292
+ yValue: yValue,
293
+ xPositionPercent: xPositionPercent,
294
+ yPositionPercent: yPositionPercent,
295
+ highlighted: isHighlighted,
296
+ });
297
+ // because highlight range is inclusive, disable after pushing details
298
+ if (xValue === this.highlightEnd && isHighlighted) {
299
+ isHighlighted = false;
300
+ }
301
+ });
302
+ return dataPointDetailsList;
303
+ }
304
+ toggleLineVisibility(lineIdx) {
305
+ if (this.hiddenLines.includes(lineIdx)) {
306
+ this.hiddenLines = this.hiddenLines.filter((num) => num !== lineIdx);
307
+ }
308
+ else {
309
+ this.hiddenLines.push(lineIdx);
310
+ }
311
+ forceUpdate(this.el);
312
+ }
313
+ resetDataPointFocus() {
314
+ this.popoverIndex = -1;
315
+ this.pointEls.forEach((point) => (point.tabIndex = -1));
316
+ if (this.firstVisibleLineIdx !== -1) {
317
+ const lineEl = this.lineEls[this.firstVisibleLineIdx];
318
+ const linePointEl = lineEl.querySelectorAll(".point")[0];
319
+ linePointEl.tabIndex = 0;
320
+ }
321
+ }
322
+ calcDelta(dataPoint, prevDataPoint) {
323
+ let delta;
324
+ if (dataPoint.yValue === null || prevDataPoint.yValue === null) {
325
+ // display "No data" when either of the datapoints is missing
326
+ delta = lineChartMessages.noData;
327
+ }
328
+ else if (dataPoint.yValue == prevDataPoint.yValue) {
329
+ // display "0%" if datapoints are equal
330
+ delta = "0%";
331
+ }
332
+ else if (prevDataPoint.yValue == 0) {
333
+ // display "-" for % increase if prev data point is 0, as the technical number would be infinity
334
+ delta = "-";
335
+ }
336
+ else {
337
+ const changePercent = ((dataPoint.yValue - prevDataPoint.yValue) / prevDataPoint.yValue) * 100;
338
+ const roundedPercent = Math.round(changePercent * 100) / 100;
339
+ delta = `${roundedPercent > 0 ? "+" : ""}${roundedPercent}%`;
340
+ }
341
+ return delta;
342
+ }
343
+ renderLegend() {
344
+ var _a;
345
+ const lineLabels = Object.keys(this.parsedLineData);
346
+ return (h("div", { ref: (el) => (this.legendEl = el), class: "legend" }, ((_a = this.spotlightData) === null || _a === void 0 ? void 0 : _a.label) && (h("div", { class: "legend-label" }, h("div", { class: "svg-icon svg-spotlight" }), this.spotlightData.label)), lineLabels.map((lineLabel, lineIdx) => {
347
+ const isHidden = this.hiddenLines.includes(lineIdx);
348
+ const isFaded = this.focusedLine !== -1 && this.focusedLine !== lineIdx;
349
+ return (h("div", { id: `legend-label-${lineIdx}`, class: `legend-label ${isFaded ? "faded" : ""}`, onMouseEnter: () => (this.focusedLine = isHidden ? -1 : lineIdx), onMouseLeave: () => (this.focusedLine = -1) }, this.renderIcon(lineIdx), lineLabel, this.visibilityToggles && this.renderVisibilityToggle(lineLabel, lineIdx, isHidden)));
350
+ })));
351
+ }
352
+ renderVisibilityToggle(lineLabel, lineIdx, isHidden) {
353
+ return (h("wm-button", { id: `visibility-button-${lineIdx}`, class: "visibility-toggle", "label-for-identical-buttons": `${lineIdx === 0 ? lineChartMessages.getToggleButtonLabel(this.dataPointMatrix.length) : ""} ${isHidden ? globalMessages.show : globalMessages.hide} ${lineLabel} ${lineChartMessages.getToggleButtonState(isHidden)}`, "button-type": "navigational", tooltip: isHidden ? globalMessages.show : globalMessages.hide, tooltipPosition: "bottom", icon: isHidden ? "#hide" : "#show", onClick: () => this.toggleLineVisibility(lineIdx), onKeyDown: (ev) => this.handleVisibilityToggleKeydown(ev, lineIdx), onFocus: () => (this.popoverIndex = -1) }));
354
+ }
355
+ renderIcon(lineIdx) {
356
+ const { color, icon } = this.lineStyles[lineIdx];
357
+ return h("div", { style: { color: color }, class: `svg-icon svg-shape-${icon}` });
358
+ }
359
+ renderXIntervals() {
360
+ const gridStyle = {
361
+ "--columns": `.5fr repeat(${this.xIntervals.length - 2}, 1fr) .5fr`,
362
+ };
363
+ return (h("div", { class: "x-intervals", style: gridStyle }, this.xIntervals.map((interval) => (h("span", { class: `x-interval ${this.displayedXIntervals.includes(interval) ? "" : "hidden"}` }, interval)))));
364
+ }
365
+ renderYIntervals() {
366
+ return (h("div", { ref: (el) => (this.yIntervalsEl = el), class: "y-intervals" }, this.yIntervals.map((yInterval, idx) => {
367
+ const percentFromTop = (100 / (this.yIntervals.length - 1)) * idx;
368
+ return (h("span", { class: "y-interval", style: { top: `${percentFromTop}%` } }, this.formatYAxisIntervalLabel(yInterval)));
369
+ })));
370
+ }
371
+ renderData() {
372
+ return this.dataPointMatrix.map((_, lineIdx) => {
373
+ let focusState = this.focusedLine === lineIdx ? "focused" : "faded";
374
+ const isHidden = this.hiddenLines.includes(lineIdx);
375
+ return (h("div", { class: `line ${this.focusedLine !== -1 ? focusState : ""} ${isHidden ? "hidden" : ""}` }, this.renderLines(lineIdx), this.renderPoints(lineIdx)));
376
+ });
377
+ }
378
+ renderPoints(lineIdx) {
379
+ const lineDataPoints = this.dataPointMatrix[lineIdx];
380
+ return (h("div", { class: "line-icons" }, lineDataPoints.map((dataPoint, pointIdx) => {
381
+ var _a;
382
+ const { lineLabel, xValue, yValue, xPositionPercent, yPositionPercent, highlighted } = dataPoint;
383
+ if (yValue !== null) {
384
+ const { color, icon } = this.lineStyles[lineIdx];
385
+ const firstPointTabIndex = lineIdx === 0 && pointIdx === 0 ? 0 : undefined;
386
+ const iconStyle = {
387
+ color: color,
388
+ "--xPosition": xPositionPercent + "%",
389
+ "--yPosition": yPositionPercent + "%",
390
+ };
391
+ let ariaLabel = `${lineLabel} ${highlighted ? this.highlightQualifier : ""} ${this.xAxisLabel} ${xValue + (this.parsedUnits[0] ? this.parsedUnits[0] : "")}, ${this.yAxisLabel}: ${this.formatDisplayYValue(yValue)}${this.parsedUnits[1] ? this.parsedUnits[1] : ""}`;
392
+ if (this.showDeltas && pointIdx > 0) {
393
+ const prevDataPoint = lineDataPoints[pointIdx - 1];
394
+ const changeSinceMessage = lineChartMessages.getChangeSince(prevDataPoint.xValue);
395
+ ariaLabel += `, ${changeSinceMessage} ${this.calcDelta(dataPoint, prevDataPoint)}`;
396
+ }
397
+ if (((_a = this.spotlightData) === null || _a === void 0 ? void 0 : _a.label) && this.spotlightYValue !== undefined) {
398
+ ariaLabel += `, ${this.spotlightData.label} ${this.xAxisLabel} ${this.spotlightXValue + (this.parsedUnits[0] ? this.parsedUnits[0] : "")}, ${this.yAxisLabel}: ${this.formatDisplayYValue(this.spotlightYValue)}${this.parsedUnits[1] ? this.parsedUnits[1] : ""}`;
399
+ }
400
+ return (h("span", { id: `${lineLabel}-${pointIdx}`, role: "img", "aria-label": ariaLabel, tabIndex: firstPointTabIndex, class: `point svg-icon svg-shape-${icon}`, style: iconStyle, "data-lineidx": lineIdx, "data-pointidx": pointIdx, "data-xvalue": xValue, onKeyDown: (ev) => this.handleDataPointKeydown(ev), onFocus: () => (this.popoverIndex = pointIdx), onClick: (ev) => this.focusDataPointByEl(ev.target), onMouseEnter: () => (this.popoverIndex = pointIdx) }, h("span", { class: `point-bg svg-icon svg-shape-${icon}` })));
401
+ }
402
+ })));
403
+ }
404
+ renderLines(lineIdx) {
405
+ const lineDataPoints = this.dataPointMatrix[lineIdx];
406
+ return (h("svg", { class: "line-svg" }, lineDataPoints.map((dataPoint, pointIdx) => {
407
+ const shouldDraw = dataPoint.yValue !== null &&
408
+ pointIdx !== lineDataPoints.length - 1 &&
409
+ lineDataPoints[pointIdx + 1].yValue !== null;
410
+ if (shouldDraw) {
411
+ const { color } = this.lineStyles[lineIdx];
412
+ const { xPositionPercent: xStart, yPositionPercent: yStart } = dataPoint;
413
+ const { xPositionPercent: xEnd, yPositionPercent: yEnd } = lineDataPoints[pointIdx + 1];
414
+ return (h("line", { x1: xStart + "%", y1: yStart + "%", x2: xEnd + "%", y2: yEnd + "%", stroke: color, "stroke-width": "2px" }));
415
+ }
416
+ })));
417
+ }
418
+ renderSpotlight() {
419
+ if (!this.spotlightData || !this.spotlightXValue || this.spotlightYValue === undefined)
420
+ return "";
421
+ const yPositionPercent = 100 -
422
+ calcPercentageInRange(this.spotlightYValue, this.yIntervals[this.yIntervals.length - 1], this.yIntervals[0]);
423
+ const xIndex = this.xIntervals.indexOf(this.spotlightXValue);
424
+ const iconXPositionPercent = xIndex >= 0 ? (100 / (this.xIntervals.length - 1)) * xIndex : null;
425
+ return (h("div", { class: "spotlight", style: { "--yPosition": yPositionPercent + "%" } }, this.spotlightXValue && (h("div", { class: "spotlight-icon", style: { "--xPosition": iconXPositionPercent + "%" } }))));
426
+ }
427
+ renderHoverAreas() {
428
+ const hoverAreaStyle = { "--columns": `.5fr repeat(${this.xIntervals.length - 2}, 1fr) .5fr` };
429
+ return (h("div", { class: "hover-area-wrapper", style: hoverAreaStyle, onMouseLeave: () => (this.popoverIndex = -1) }, this.xIntervals.map((_, idx) => (h("div", { onMouseEnter: () => (this.popoverIndex = idx) })))));
430
+ }
431
+ renderPopover() {
432
+ const hasPopoverData = this.popoverData &&
433
+ this.popoverData[this.popoverIndex] &&
434
+ this.plotAreaEl.querySelector(`.point[data-xvalue="${this.dataPointMatrix[0][this.popoverIndex].xValue}"]`);
435
+ if (!hasPopoverData) {
436
+ return "";
437
+ }
438
+ const displayedPopoverData = this.popoverData[this.popoverIndex];
439
+ const xPosition = displayedPopoverData[0].xPositionPercent;
440
+ const yPositions = displayedPopoverData
441
+ .map((point) => point.yPositionPercent)
442
+ .filter((yPosition) => yPosition !== null);
443
+ const averageYPosition = yPositions.reduce((acc, cur) => acc + cur, 0) / yPositions.length;
444
+ const referencePointEl = this.plotAreaEl.querySelector(`.point[data-xvalue="${this.dataPointMatrix[0][this.popoverIndex].xValue}"]`);
445
+ const componentBoundingClientRect = this.el.getBoundingClientRect();
446
+ const referencePointBoundingClientRect = referencePointEl.getBoundingClientRect();
447
+ const rightSpaceAvailable = componentBoundingClientRect.right - referencePointBoundingClientRect.right;
448
+ const leftSpaceAvailable = referencePointBoundingClientRect.left - componentBoundingClientRect.left;
449
+ const hasRoomRight = rightSpaceAvailable >= (this.popoverEl ? Math.min(this.popoverEl.clientWidth, 400) : 400);
450
+ const hasRoomLeft = leftSpaceAvailable >= (this.popoverEl ? Math.min(this.popoverEl.clientWidth, 400) : 400);
451
+ const percentMargin = (8 / this.plotAreaEl.clientWidth) * 100;
452
+ let popoverStyle = {
453
+ "--leftPosition": hasRoomRight ? xPosition + percentMargin + "%" : "unset",
454
+ "--rightPosition": hasRoomLeft ? 100 - xPosition + percentMargin + "%" : "unset",
455
+ "--topPosition": averageYPosition + "%",
456
+ transform: "translateY(-50%)", // vertically center for averageYPosition
457
+ };
458
+ if (!hasRoomLeft && !hasRoomRight) {
459
+ // if there's not enough room to the left and right, position "detached" from the data points towards the top of the chart
460
+ const displaceLeft = `0px - ${this.labelWidth} - 20px - ${this.yIntervalsEl.clientWidth + "px"} + ${this.el.scrollLeft + "px"} + 2px`;
461
+ popoverStyle = {
462
+ "--leftPosition": `0%`,
463
+ "--topPosition": "0%",
464
+ maxWidth: Math.min(this.el.clientWidth - 2, 400) + "px", // take up no more max-width than is visually available
465
+ transform: `translateX(calc(${displaceLeft}))`, // align with left edge of component
466
+ };
467
+ }
468
+ return (h("div", { ref: (el) => (this.popoverEl = el), class: "popover", style: popoverStyle }, h("div", { class: "title" }, displayedPopoverData[0].xValue, this.parsedUnits[0] && h("span", { class: "unit --x" }, "(", this.parsedUnits[0], ")")), this.showDeltas && this.popoverIndex > 0 && (h("div", { class: "comparison-title" }, lineChartMessages.getChangeSince(this.popoverData[this.popoverIndex - 1][0].xValue))), this.renderPopoverTable()));
469
+ }
470
+ renderPopoverTable() {
471
+ var _a;
472
+ const displayedPopoverData = this.popoverData[this.popoverIndex];
473
+ const displayedSpotlightYValue = this.spotlightYValue !== undefined ? this.formatDisplayYValue(this.spotlightYValue) : "";
474
+ return (h("table", { class: "popover-table" }, this.spotlightXValue === displayedPopoverData[0].xValue && (h("tr", { class: "popover-row" }, h("td", null, h("div", { class: "svg-icon svg-spotlight" })), h("td", { class: "row-label" }, (_a = this.spotlightData) === null || _a === void 0 ? void 0 : _a.label), h("td", { class: "row-value" }, displayedSpotlightYValue, displayedSpotlightYValue !== "" && this.parsedUnits[1] && (h("span", { class: "unit --y" }, this.parsedUnits[1]))))), displayedPopoverData.map((dataPoint, lineIdx) => {
475
+ if (!this.hiddenLines.includes(lineIdx)) {
476
+ const { lineLabel, yValue } = dataPoint;
477
+ const prevDataPoint = this.popoverIndex > 0 ? this.popoverData[this.popoverIndex - 1][lineIdx] : null;
478
+ const displayYValue = yValue !== null ? this.formatDisplayYValue(yValue) : null;
479
+ return (h("tr", { class: "popover-row" }, h("td", null, this.renderIcon(lineIdx)), h("td", { class: "row-label" }, lineLabel), h("td", { class: "row-value" }, displayYValue !== null && displayYValue !== void 0 ? displayYValue : lineChartMessages.noData, yValue !== null && this.parsedUnits[1] && h("span", { class: "unit --y" }, this.parsedUnits[1])), this.showDeltas && prevDataPoint && this.renderDeltas(dataPoint, prevDataPoint)));
480
+ }
481
+ })));
482
+ }
483
+ renderDeltas(dataPoint, prevDataPoint) {
484
+ const delta = this.calcDelta(dataPoint, prevDataPoint);
485
+ const deltaColor = delta.toString()[0] == "+" || delta == "-" ? "positive" : delta.toString()[0] == "-" ? "negative" : "";
486
+ return prevDataPoint && h("td", { class: `delta --${deltaColor}` }, delta);
487
+ }
488
+ renderHoverIndicator() {
489
+ const hasIndicatorData = this.dataPointMatrix.length > 0 && this.dataPointMatrix[0][this.popoverIndex];
490
+ if (!hasIndicatorData) {
491
+ return "";
492
+ }
493
+ const xPosition = this.dataPointMatrix[0][this.popoverIndex].xPositionPercent;
494
+ const indicatorStyle = { "--xPosition": xPosition + "%" };
495
+ return h("div", { class: "hover-indicator", style: indicatorStyle });
496
+ }
497
+ renderVerticalGridlines() {
498
+ var _a;
499
+ const gridlineSpacing = this.dataPointMatrix[0] && this.displayedXIntervals[1]
500
+ ? (_a = this.dataPointMatrix[0][this.xIntervals.indexOf(this.displayedXIntervals[1])]) === null || _a === void 0 ? void 0 : _a.xPositionPercent
501
+ : 0;
502
+ return (h("div", { class: `vertical-gridlines ${this.hasPartialInterval ? "" : "right-border"} ${!this.showGrid && "axis-only"}`, style: { "--gridlineSpacing": gridlineSpacing + "%" } }));
503
+ }
504
+ renderHorizontalGridlines() {
505
+ const gridlineSpacing = 100 / (this.yIntervals.length - 1);
506
+ return (h("div", { class: `horizontal-gridlines ${!this.showGrid && "axis-only"}`, style: { "--gridlineSpacing": gridlineSpacing + "%" } }));
507
+ }
508
+ renderHighlight() {
509
+ var _a, _b;
510
+ if (this.highlightStart) {
511
+ const startIdx = this.xIntervals.indexOf(this.highlightStart);
512
+ if (startIdx === -1 || !((_a = this.dataPointMatrix[0]) === null || _a === void 0 ? void 0 : _a[startIdx])) {
513
+ return null;
514
+ }
515
+ const startPercentage = this.dataPointMatrix[0][startIdx].xPositionPercent;
516
+ const endIdx = this.highlightEnd ? this.xIntervals.indexOf(this.highlightEnd) : -1;
517
+ const endPercentage = endIdx !== -1 && ((_b = this.dataPointMatrix[0]) === null || _b === void 0 ? void 0 : _b[endIdx]) ? 100 - this.dataPointMatrix[0][endIdx].xPositionPercent : 0;
518
+ const highlightStyle = { "--startPercentage": startPercentage + "%", "--endPercentage": endPercentage + "%" };
519
+ return h("div", { class: "highlight", style: highlightStyle });
520
+ }
521
+ }
522
+ render() {
523
+ return (h(Host, { key: 'bd45cc4a8e504d1cf78695efc383efa9748be2b3', onBlur: () => this.resetDataPointFocus(), onMouseLeave: () => (this.popoverIndex = -1) }, h("div", { key: '6892697f23725192a825d36a723f94b1c4822b29', class: "component-wrapper", role: "application", "aria-roledescription": chartMessages.interactiveChart, "aria-label": this.label, "aria-describedby": "chart-description" }, this.renderLegend(), h("div", { key: '2c770afd1e4215b2096eb52eb563b0b4dbecd3c1', class: "chart-wrapper" }, h("div", { key: '42e893d736e04afbf58db3ff7b8f4388b1c17078', class: "chart-label --y-axis", style: { "--labelWidth": this.labelWidth } }, this.yAxisLabel, this.parsedUnits[1] && ` (${this.parsedUnits[1]})`), this.renderYIntervals(), h("div", { key: 'fd09da97e4b5a3648bbf5405922cc0e528c9a4bc', ref: (el) => (this.plotAreaEl = el), class: "plot-area" }, this.renderVerticalGridlines(), this.renderHorizontalGridlines(), this.renderHighlight(), this.renderData(), this.renderHoverAreas(), this.renderSpotlight()), this.popoverIndex !== -1 && this.renderHoverIndicator(), this.popoverIndex !== -1 && this.renderPopover(), this.renderXIntervals(), h("div", { key: '774407a72ca3f664bf34b47b9f7de96944491414', class: "chart-label --x-axis" }, this.xAxisLabel, this.parsedUnits[0] && ` (${this.parsedUnits[0]})`)), h("div", { key: '1a8366917ebe7da6597d2343183ecfef1e7f6ac1', id: "chart-description", class: "sr-only" }, `${lineChartMessages.instructions} ${this.description}`), h("div", { key: 'b8137240f0ad5c6a7ac83e9a65f0ccf22a5f9588', ref: (el) => (this.liveRegionEl = el), "aria-live": "polite", class: "sr-only" }, this.announcement))));
524
+ }
525
+ static get is() { return "wm-line-chart"; }
526
+ static get encapsulation() { return "shadow"; }
527
+ static get originalStyleUrls() {
528
+ return {
529
+ "$": ["wm-line-chart.scss"]
530
+ };
531
+ }
532
+ static get styleUrls() {
533
+ return {
534
+ "$": ["wm-line-chart.css"]
535
+ };
536
+ }
537
+ static get properties() {
538
+ return {
539
+ "label": {
540
+ "type": "string",
541
+ "mutable": false,
542
+ "complexType": {
543
+ "original": "string",
544
+ "resolved": "string",
545
+ "references": {}
546
+ },
547
+ "required": true,
548
+ "optional": false,
549
+ "docs": {
550
+ "tags": [],
551
+ "text": ""
552
+ },
553
+ "attribute": "label",
554
+ "reflect": false
555
+ },
556
+ "description": {
557
+ "type": "string",
558
+ "mutable": false,
559
+ "complexType": {
560
+ "original": "string",
561
+ "resolved": "string",
562
+ "references": {}
563
+ },
564
+ "required": false,
565
+ "optional": false,
566
+ "docs": {
567
+ "tags": [],
568
+ "text": ""
569
+ },
570
+ "attribute": "description",
571
+ "reflect": false,
572
+ "defaultValue": "\"\""
573
+ },
574
+ "xAxisLabel": {
575
+ "type": "string",
576
+ "mutable": false,
577
+ "complexType": {
578
+ "original": "string",
579
+ "resolved": "string",
580
+ "references": {}
581
+ },
582
+ "required": true,
583
+ "optional": false,
584
+ "docs": {
585
+ "tags": [],
586
+ "text": ""
587
+ },
588
+ "attribute": "x-axis-label",
589
+ "reflect": false
590
+ },
591
+ "yAxisLabel": {
592
+ "type": "string",
593
+ "mutable": false,
594
+ "complexType": {
595
+ "original": "string",
596
+ "resolved": "string",
597
+ "references": {}
598
+ },
599
+ "required": true,
600
+ "optional": false,
601
+ "docs": {
602
+ "tags": [],
603
+ "text": ""
604
+ },
605
+ "attribute": "y-axis-label",
606
+ "reflect": false
607
+ },
608
+ "showGrid": {
609
+ "type": "boolean",
610
+ "mutable": false,
611
+ "complexType": {
612
+ "original": "boolean",
613
+ "resolved": "boolean",
614
+ "references": {}
615
+ },
616
+ "required": false,
617
+ "optional": false,
618
+ "docs": {
619
+ "tags": [],
620
+ "text": ""
621
+ },
622
+ "attribute": "show-grid",
623
+ "reflect": false,
624
+ "defaultValue": "true"
625
+ },
626
+ "lineData": {
627
+ "type": "string",
628
+ "mutable": true,
629
+ "complexType": {
630
+ "original": "string | LineChartData",
631
+ "resolved": "string | { [lineLabel: string]: Line; }",
632
+ "references": {
633
+ "LineChartData": {
634
+ "location": "import",
635
+ "path": "../../../global/interfaces",
636
+ "id": "src/global/interfaces.ts::LineChartData"
637
+ }
638
+ }
639
+ },
640
+ "required": true,
641
+ "optional": false,
642
+ "docs": {
643
+ "tags": [],
644
+ "text": ""
645
+ },
646
+ "attribute": "line-data",
647
+ "reflect": false
648
+ },
649
+ "units": {
650
+ "type": "string",
651
+ "mutable": false,
652
+ "complexType": {
653
+ "original": "string",
654
+ "resolved": "string",
655
+ "references": {}
656
+ },
657
+ "required": false,
658
+ "optional": false,
659
+ "docs": {
660
+ "tags": [],
661
+ "text": ""
662
+ },
663
+ "attribute": "units",
664
+ "reflect": false,
665
+ "defaultValue": "\"null,null\""
666
+ },
667
+ "labelWidth": {
668
+ "type": "string",
669
+ "mutable": false,
670
+ "complexType": {
671
+ "original": "string",
672
+ "resolved": "string",
673
+ "references": {}
674
+ },
675
+ "required": false,
676
+ "optional": false,
677
+ "docs": {
678
+ "tags": [],
679
+ "text": ""
680
+ },
681
+ "attribute": "label-width",
682
+ "reflect": false,
683
+ "defaultValue": "\"120px\""
684
+ },
685
+ "highlightQualifier": {
686
+ "type": "string",
687
+ "mutable": false,
688
+ "complexType": {
689
+ "original": "string",
690
+ "resolved": "string",
691
+ "references": {}
692
+ },
693
+ "required": false,
694
+ "optional": false,
695
+ "docs": {
696
+ "tags": [],
697
+ "text": ""
698
+ },
699
+ "attribute": "highlight-qualifier",
700
+ "reflect": false,
701
+ "defaultValue": "lineChartMessages.highlightQualifier"
702
+ },
703
+ "highlightStart": {
704
+ "type": "string",
705
+ "mutable": false,
706
+ "complexType": {
707
+ "original": "string",
708
+ "resolved": "string | undefined",
709
+ "references": {}
710
+ },
711
+ "required": false,
712
+ "optional": true,
713
+ "docs": {
714
+ "tags": [],
715
+ "text": ""
716
+ },
717
+ "attribute": "highlight-start",
718
+ "reflect": false
719
+ },
720
+ "highlightEnd": {
721
+ "type": "string",
722
+ "mutable": false,
723
+ "complexType": {
724
+ "original": "string",
725
+ "resolved": "string | undefined",
726
+ "references": {}
727
+ },
728
+ "required": false,
729
+ "optional": true,
730
+ "docs": {
731
+ "tags": [],
732
+ "text": ""
733
+ },
734
+ "attribute": "highlight-end",
735
+ "reflect": false
736
+ },
737
+ "visibilityToggles": {
738
+ "type": "boolean",
739
+ "mutable": false,
740
+ "complexType": {
741
+ "original": "boolean",
742
+ "resolved": "boolean",
743
+ "references": {}
744
+ },
745
+ "required": false,
746
+ "optional": false,
747
+ "docs": {
748
+ "tags": [],
749
+ "text": ""
750
+ },
751
+ "attribute": "visibility-toggles",
752
+ "reflect": false,
753
+ "defaultValue": "false"
754
+ },
755
+ "showDeltas": {
756
+ "type": "boolean",
757
+ "mutable": false,
758
+ "complexType": {
759
+ "original": "boolean",
760
+ "resolved": "boolean",
761
+ "references": {}
762
+ },
763
+ "required": false,
764
+ "optional": false,
765
+ "docs": {
766
+ "tags": [],
767
+ "text": ""
768
+ },
769
+ "attribute": "show-deltas",
770
+ "reflect": false,
771
+ "defaultValue": "false"
772
+ },
773
+ "yRange": {
774
+ "type": "string",
775
+ "mutable": false,
776
+ "complexType": {
777
+ "original": "string",
778
+ "resolved": "string | undefined",
779
+ "references": {}
780
+ },
781
+ "required": false,
782
+ "optional": true,
783
+ "docs": {
784
+ "tags": [],
785
+ "text": ""
786
+ },
787
+ "attribute": "y-range",
788
+ "reflect": false
789
+ },
790
+ "spotlightData": {
791
+ "type": "unknown",
792
+ "mutable": false,
793
+ "complexType": {
794
+ "original": "SpotlightData",
795
+ "resolved": "SpotlightData | undefined",
796
+ "references": {
797
+ "SpotlightData": {
798
+ "location": "import",
799
+ "path": "../../../global/interfaces",
800
+ "id": "src/global/interfaces.ts::SpotlightData"
801
+ }
802
+ }
803
+ },
804
+ "required": false,
805
+ "optional": true,
806
+ "docs": {
807
+ "tags": [],
808
+ "text": ""
809
+ }
810
+ },
811
+ "decimalPlaces": {
812
+ "type": "number",
813
+ "mutable": false,
814
+ "complexType": {
815
+ "original": "number",
816
+ "resolved": "number | undefined",
817
+ "references": {}
818
+ },
819
+ "required": false,
820
+ "optional": true,
821
+ "docs": {
822
+ "tags": [],
823
+ "text": ""
824
+ },
825
+ "attribute": "decimal-places",
826
+ "reflect": false
827
+ }
828
+ };
829
+ }
830
+ static get states() {
831
+ return {
832
+ "parsedLineData": {},
833
+ "popoverIndex": {},
834
+ "focusedLine": {},
835
+ "hiddenLines": {},
836
+ "isTabbing": {},
837
+ "announcement": {}
838
+ };
839
+ }
840
+ static get elementRef() { return "el"; }
841
+ static get watchers() {
842
+ return [{
843
+ "propName": "lineData",
844
+ "methodName": "parseData"
845
+ }];
846
+ }
847
+ static get listeners() {
848
+ return [{
849
+ "name": "wmUserIsTabbing",
850
+ "method": "toggleTabbingOn",
851
+ "target": "window",
852
+ "capture": false,
853
+ "passive": false
854
+ }, {
855
+ "name": "wmUserIsNotTabbing",
856
+ "method": "toggleTabbingOff",
857
+ "target": "window",
858
+ "capture": false,
859
+ "passive": false
860
+ }];
861
+ }
862
+ }