@ironsource/shared-ui 2.1.12-rc.9 → 2.1.12-test.100

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 (354) hide show
  1. package/ButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_adb49e50_lang.css +1 -0
  2. package/ButtonV4.vue_vue_type_style_index_0_scoped_852be7ec_lang.css +1 -0
  3. package/Chart.vue_vue_type_style_index_0_scoped_060d02be_lang.css +1 -0
  4. package/ChartHeader.vue_vue_type_style_index_0_scoped_d90c583e_lang.css +1 -0
  5. package/ChartHeaderTrend.vue_vue_type_style_index_0_scoped_ca558859_lang.css +1 -0
  6. package/ChartLegend.vue_vue_type_style_index_0_scoped_9c4df598_lang.css +1 -0
  7. package/ChartPlane.vue_vue_type_style_index_0_scoped_a685cf5e_lang.css +1 -0
  8. package/ChartTooltip.vue_vue_type_style_index_0_scoped_9623dbbd_lang.css +1 -0
  9. package/ChipDropdownTrigger.vue_vue_type_style_index_0_scoped_38354f10_lang.css +1 -0
  10. package/ColumnConfigurator.vue_vue_type_style_index_0_scoped_702ad52e_lang.css +1 -0
  11. package/ColumnPicker.vue_vue_type_style_index_0_scoped_ea8c7024_lang.css +1 -0
  12. package/ConditionalDropdown.vue_vue_type_style_index_0_scoped_8cc86a27_lang.css +1 -0
  13. package/DataGrid.vue_vue_type_style_index_0_scoped_7e61692c_lang.css +1 -0
  14. package/DataGridHeader.vue_vue_type_style_index_0_scoped_0e826456_lang.css +1 -0
  15. package/DataGridRowsCounter.vue_vue_type_style_index_0_scoped_e38c881a_lang.css +1 -0
  16. package/DialogFooter.vue_vue_type_style_index_0_scoped_8b7f64fe_lang.css +1 -0
  17. package/DialogHeader.vue_vue_type_style_index_0_scoped_9a814ec3_lang.css +1 -0
  18. package/DialogV4.vue_vue_type_style_index_0_scoped_cc99f1e3_lang.css +1 -0
  19. package/DropdownV4.vue_vue_type_style_index_0_scoped_a594c97e_lang.css +1 -0
  20. package/DropdownV4.vue_vue_type_style_index_1_lang.css +1 -1
  21. package/EmptyStateV4.vue_vue_type_style_index_0_scoped_76757f22_lang.css +1 -0
  22. package/FieldLabel.vue_vue_type_style_index_0_scoped_921d4087_lang.css +1 -0
  23. package/FormRow.vue_vue_type_style_index_0_scoped_2d5a3057_lang.css +1 -0
  24. package/IconButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_99e51ecc_lang.css +1 -0
  25. package/Link.vue_vue_type_style_index_0_scoped_1a766750_lang.css +1 -0
  26. package/LoaderBars.vue_vue_type_style_index_0_scoped_d976ec65_lang.css +1 -0
  27. package/MultipleDataGrid.vue_vue_type_style_index_0_scoped_3caa1d7b_lang.css +1 -0
  28. package/OptionChip.vue_vue_type_style_index_0_scoped_538e4a21_lang.css +1 -0
  29. package/OptionV4.vue_vue_type_style_index_0_scoped_752a357d_lang.css +1 -0
  30. package/RadioButton.vue_vue_type_style_index_0_scoped_dac25b9f_lang.css +1 -0
  31. package/RemoveButton.vue_vue_type_style_index_0_scoped_ca7fc11d_lang.css +1 -0
  32. package/SectionDropdown.vue_vue_type_style_index_0_scoped_cfad60a8_lang.css +1 -0
  33. package/SectionHeaderText.vue_vue_type_style_index_0_scoped_0b8d3d79_lang.css +1 -0
  34. package/SettingsHeader.vue_vue_type_style_index_0_scoped_a869d327_lang.css +1 -0
  35. package/ShowMoreLink.vue_vue_type_style_index_0_scoped_9fc3bc1b_lang.css +1 -0
  36. package/SortableItem.vue_vue_type_style_index_0_scoped_c72be7ed_lang.css +1 -0
  37. package/SortableItemLabel.vue_vue_type_style_index_0_scoped_a534c7af_lang.css +1 -0
  38. package/SortableList.vue_vue_type_style_index_0_scoped_9aec4e9b_lang.css +1 -0
  39. package/SortableSelectableList.vue_vue_type_style_index_0_scoped_40b0a4de_lang.css +1 -0
  40. package/SubHeader.vue_vue_type_style_index_0_scoped_e6008b6c_lang.css +1 -0
  41. package/SwitchV4.vue_vue_type_style_index_0_scoped_cd6621a7_lang.css +1 -0
  42. package/TagsField.vue_vue_type_style_index_0_scoped_9760426b_lang.css +1 -0
  43. package/TagsFieldChip.vue_vue_type_style_index_0_scoped_d186b7ef_lang.css +1 -0
  44. package/TextField.vue_vue_type_style_index_0_scoped_3b7a3661_lang.css +1 -0
  45. package/ToggleButtonGroupAB.vue_vue_type_style_index_0_scoped_2076b5ab_lang.css +1 -0
  46. package/Tooltip.vue_vue_type_style_index_0_scoped_20630944_lang.css +1 -0
  47. package/TooltipHeader.vue_vue_type_style_index_0_scoped_da3532aa_lang.css +1 -0
  48. package/TooltipV4.vue_vue_type_style_index_0_scoped_8a451e54_lang.css +1 -0
  49. package/TooltipV4.vue_vue_type_style_index_1_lang.css +1 -1
  50. package/TreeDropdown.vue_vue_type_style_index_0_scoped_63dc057e_lang.css +1 -0
  51. package/components/appIcon/index.d.ts +3 -3
  52. package/components/banner/Banner.vue.d.ts +3 -3
  53. package/components/banner/index.d.ts +7 -7
  54. package/components/button/common/consts.d.ts +1 -0
  55. package/components/button/v3/Button.vue.d.ts +3 -3
  56. package/components/button/v3/ButtonBase.vue.d.ts +3 -3
  57. package/components/button/v3/IconButton.vue.d.ts +3 -3
  58. package/components/button/v3/index.d.ts +14 -14
  59. package/components/button/v4/ButtonV4.vue.d.ts +5 -3
  60. package/components/button/v4/ButtonV4.vue.js +4 -4
  61. package/components/button/v4/ButtonV4.vue2.js +28 -27
  62. package/components/button/v4/ToggleButtonGroupAB.vue.js +3 -3
  63. package/components/button/v4/ToggleButtonGroupAB.vue2.js +40 -44
  64. package/components/chart/Chart.vue.d.ts +128 -10
  65. package/components/chart/Chart.vue.js +4 -4
  66. package/components/chart/Chart.vue2.js +152 -86
  67. package/components/chart/ChartHeader.vue.d.ts +41 -7
  68. package/components/chart/ChartHeader.vue.js +2 -2
  69. package/components/chart/ChartHeader.vue2.js +67 -65
  70. package/components/chart/ChartHeaderTrend.vue.d.ts +24 -5
  71. package/components/chart/ChartHeaderTrend.vue.js +3 -3
  72. package/components/chart/ChartHeaderTrend.vue2.js +89 -21
  73. package/components/chart/ChartLegend.vue.d.ts +29 -0
  74. package/components/chart/ChartLegend.vue.js +2 -2
  75. package/components/chart/ChartLegend.vue2.js +88 -65
  76. package/components/chart/ChartPlane.vue.d.ts +111 -13
  77. package/components/chart/ChartPlane.vue.js +4 -4
  78. package/components/chart/ChartPlane.vue2.js +321 -240
  79. package/components/chart/ChartStoryArgs.d.ts +63 -2
  80. package/components/chart/ChartTooltip.vue.d.ts +27 -2
  81. package/components/chart/ChartTooltip.vue.js +2 -2
  82. package/components/chart/ChartTooltip.vue2.js +52 -54
  83. package/components/chart/LegendSorting.vue.d.ts +42 -0
  84. package/components/chart/LegendSorting.vue.js +47 -0
  85. package/components/chart/LegendSorting.vue2.js +4 -0
  86. package/components/chart/SettingsHeader.vue.d.ts +20 -3
  87. package/components/chart/SettingsHeader.vue.js +3 -3
  88. package/components/chart/SettingsHeader.vue2.js +39 -31
  89. package/components/chart/SubHeader.vue.d.ts +52 -0
  90. package/components/chart/SubHeader.vue.js +7 -0
  91. package/components/chart/SubHeader.vue2.js +61 -0
  92. package/components/chart/TooltipHeader.vue.d.ts +50 -0
  93. package/components/chart/TooltipHeader.vue.js +7 -0
  94. package/components/chart/TooltipHeader.vue2.js +69 -0
  95. package/components/chart/colorPalette.d.ts +5 -0
  96. package/components/chart/colorPalette.js +68 -0
  97. package/components/chart/composables/useChartHeight.d.ts +2 -2
  98. package/components/chart/composables/useChartHeight.js +16 -14
  99. package/components/chart/composables/useColorsMap.d.ts +5 -3
  100. package/components/chart/composables/useColorsMap.js +43 -12
  101. package/components/chart/consts.d.ts +29 -8
  102. package/components/chart/consts.js +45 -26
  103. package/components/chart/index.d.ts +492 -76
  104. package/components/chart/mockData.d.ts +33 -5
  105. package/components/chart/types.d.ts +35 -6
  106. package/components/chart/types.js +5 -2
  107. package/components/chart/utils/highlightUtils.d.ts +3 -0
  108. package/components/chart/utils/highlightUtils.js +18 -0
  109. package/components/chart/utils/utils.d.ts +3 -3
  110. package/components/chart/utils/utils.js +25 -10
  111. package/components/checkbox/v3/Checkbox.vue.d.ts +3 -3
  112. package/components/checkbox/v3/index.d.ts +7 -7
  113. package/components/columnConfigurator/ColumnConfigurator.types.d.ts +12 -0
  114. package/components/columnConfigurator/ColumnConfigurator.vue.d.ts +61 -0
  115. package/components/columnConfigurator/ColumnConfigurator.vue.js +7 -0
  116. package/components/columnConfigurator/ColumnConfigurator.vue2.js +113 -0
  117. package/components/columnConfigurator/SectionDropdown.vue.d.ts +39 -0
  118. package/components/columnConfigurator/SectionDropdown.vue.js +7 -0
  119. package/components/columnConfigurator/SectionDropdown.vue2.js +57 -0
  120. package/components/columnConfigurator/SectionHeaderText.vue.d.ts +34 -0
  121. package/components/columnConfigurator/SectionHeaderText.vue.js +7 -0
  122. package/components/columnConfigurator/SectionHeaderText.vue2.js +22 -0
  123. package/components/columnConfigurator/ShowMoreLink.vue.d.ts +33 -0
  124. package/components/columnConfigurator/ShowMoreLink.vue.js +7 -0
  125. package/components/columnConfigurator/ShowMoreLink.vue2.js +41 -0
  126. package/components/columnConfigurator/consts.d.ts +1 -0
  127. package/components/columnConfigurator/consts.js +4 -0
  128. package/components/columnConfigurator/index.d.ts +73 -0
  129. package/components/columnConfigurator/index.js +6 -0
  130. package/components/columnConfigurator/mockData.d.ts +30 -0
  131. package/components/columnConfigurator/utils.d.ts +2 -0
  132. package/components/columnConfigurator/utils.js +18 -0
  133. package/components/columnPicker/ColumnPicker.vue.d.ts +119 -0
  134. package/components/columnPicker/ColumnPicker.vue.js +7 -0
  135. package/components/columnPicker/ColumnPicker.vue2.js +322 -0
  136. package/components/columnPicker/OptionChip.vue.d.ts +53 -0
  137. package/components/columnPicker/OptionChip.vue.js +7 -0
  138. package/components/columnPicker/OptionChip.vue2.js +46 -0
  139. package/components/columnPicker/RemoveButton.vue.d.ts +38 -0
  140. package/components/columnPicker/RemoveButton.vue.js +7 -0
  141. package/components/columnPicker/RemoveButton.vue2.js +35 -0
  142. package/components/columnPicker/index.d.ts +388 -0
  143. package/components/columnPicker/index.js +6 -0
  144. package/components/columnPicker/mockData.d.ts +8 -0
  145. package/components/dateRange/common/DateRange.common.js +100 -94
  146. package/components/dateRange/common/DateServices.common.d.ts +7 -1
  147. package/components/dateRange/common/DateServices.common.js +88 -92
  148. package/components/dateRange/common/consts.common.d.ts +5 -0
  149. package/components/dateRange/common/consts.common.js +9 -3
  150. package/components/dateRange/v3/DateRange.vue.d.ts +3 -3
  151. package/components/dateRange/v3/DateRangePicker.vue.d.ts +3 -3
  152. package/components/dateRange/v3/index.d.ts +7 -7
  153. package/components/dateRange/v4/DateRangePickerV4.vue.d.ts +3 -3
  154. package/components/dateRange/v4/DateRangeV4.vue.d.ts +3 -3
  155. package/components/dateRange/v4/index.d.ts +7 -7
  156. package/components/dialog/v3/Dialog.vue.d.ts +3 -3
  157. package/components/dialog/v3/index.d.ts +46 -46
  158. package/components/dialog/v4/DialogFooter.vue.d.ts +78 -0
  159. package/components/dialog/v4/DialogFooter.vue.js +7 -0
  160. package/components/dialog/v4/DialogFooter.vue2.js +60 -0
  161. package/components/dialog/v4/DialogHeader.vue.d.ts +60 -0
  162. package/components/dialog/v4/DialogHeader.vue.js +7 -0
  163. package/components/dialog/v4/DialogHeader.vue2.js +58 -0
  164. package/components/dialog/v4/DialogV4.vue.d.ts +13 -12
  165. package/components/dialog/v4/DialogV4.vue.js +4 -4
  166. package/components/dialog/v4/DialogV4.vue2.js +65 -107
  167. package/components/dialog/v4/index.d.ts +164 -164
  168. package/components/dropdown/common/Dropdown.common.d.ts +1 -0
  169. package/components/dropdown/common/Dropdown.common.js +108 -103
  170. package/components/dropdown/v3/Dropdown.vue.d.ts +2 -2
  171. package/components/dropdown/v3/index.d.ts +39 -39
  172. package/components/dropdown/v4/ButtonDropdownTrigger.vue.d.ts +1 -0
  173. package/components/dropdown/v4/ButtonDropdownTrigger.vue.js +3 -3
  174. package/components/dropdown/v4/ButtonDropdownTrigger.vue2.js +16 -13
  175. package/components/dropdown/v4/ChipDropdownTrigger.vue.d.ts +5 -0
  176. package/components/dropdown/v4/ChipDropdownTrigger.vue.js +3 -3
  177. package/components/dropdown/v4/ChipDropdownTrigger.vue2.js +64 -54
  178. package/components/dropdown/v4/ConditionalDropdown.vue.d.ts +22 -9
  179. package/components/dropdown/v4/ConditionalDropdown.vue.js +3 -3
  180. package/components/dropdown/v4/ConditionalDropdown.vue2.js +205 -176
  181. package/components/dropdown/v4/DropdownV4.vue.d.ts +41 -1
  182. package/components/dropdown/v4/DropdownV4.vue.js +4 -4
  183. package/components/dropdown/v4/DropdownV4.vue2.js +269 -206
  184. package/components/dropdown/v4/IconButtonDropdownTrigger.vue.d.ts +11 -0
  185. package/components/dropdown/v4/IconButtonDropdownTrigger.vue.js +4 -4
  186. package/components/dropdown/v4/IconButtonDropdownTrigger.vue2.js +12 -10
  187. package/components/dropdown/v4/OptionV4.vue.d.ts +23 -5
  188. package/components/dropdown/v4/OptionV4.vue.js +3 -3
  189. package/components/dropdown/v4/OptionV4.vue2.js +162 -117
  190. package/components/dropdown/v4/TreeDropdown.vue.d.ts +11 -1
  191. package/components/dropdown/v4/TreeDropdown.vue.js +2 -2
  192. package/components/dropdown/v4/TreeDropdown.vue2.js +155 -151
  193. package/components/dropdown/v4/dropdownStoryArgs.d.ts +8 -0
  194. package/components/dropdown/v4/index.d.ts +760 -162
  195. package/components/emptyState/v4/EmptyStateV4.vue.d.ts +5 -0
  196. package/components/emptyState/v4/EmptyStateV4.vue.js +2 -2
  197. package/components/emptyState/v4/EmptyStateV4.vue2.js +37 -34
  198. package/components/emptyState/v4/index.d.ts +20 -1
  199. package/components/forms/FormRow.vue.d.ts +9 -2
  200. package/components/forms/FormRow.vue.js +3 -3
  201. package/components/forms/FormRow.vue2.js +25 -14
  202. package/components/forms/index.d.ts +25 -5
  203. package/components/includeExclude/IncludeExclude.vue.d.ts +1 -1
  204. package/components/includeExclude/IncludeExcludeChipFilter.vue.d.ts +1 -1
  205. package/components/includeExclude/IncludeExcludeDragDrop.vue.d.ts +1 -1
  206. package/components/includeExclude/IncludeExcludeOption.vue.d.ts +1 -1
  207. package/components/includeExclude/IncludeExcludeOptionDraggable.vue.d.ts +1 -1
  208. package/components/includeExclude/index.d.ts +110 -110
  209. package/components/input/v4/TextField.vue.d.ts +12 -0
  210. package/components/input/v4/TextField.vue.js +3 -3
  211. package/components/input/v4/TextField.vue2.js +129 -105
  212. package/components/input/v4/index.d.ts +46 -2
  213. package/components/link/Link.vue.d.ts +95 -0
  214. package/components/link/Link.vue.js +7 -0
  215. package/components/link/Link.vue2.js +65 -0
  216. package/components/link/index.d.ts +296 -0
  217. package/components/link/index.js +6 -0
  218. package/components/radioButton/v3/RadioButton.vue.d.ts +5 -0
  219. package/components/radioButton/v3/RadioButton.vue.js +3 -3
  220. package/components/radioButton/v3/RadioButton.vue2.js +42 -39
  221. package/components/radioButton/v3/index.d.ts +20 -1
  222. package/components/search/v3/index.d.ts +3 -3
  223. package/components/shared/FieldLabel.vue.d.ts +19 -7
  224. package/components/shared/FieldLabel.vue.js +3 -3
  225. package/components/shared/FieldLabel.vue2.js +50 -37
  226. package/components/sortableList/LoaderBars.vue.d.ts +34 -0
  227. package/components/sortableList/LoaderBars.vue.js +7 -0
  228. package/components/sortableList/LoaderBars.vue2.js +25 -0
  229. package/components/sortableList/SortableItem.vue.d.ts +17 -2
  230. package/components/sortableList/SortableItem.vue.js +5 -5
  231. package/components/sortableList/SortableItem.vue2.js +86 -70
  232. package/components/sortableList/SortableItemLabel.vue.js +3 -3
  233. package/components/sortableList/SortableItemLabel.vue2.js +26 -23
  234. package/components/sortableList/SortableList.types.d.ts +1 -0
  235. package/components/sortableList/SortableList.vue.d.ts +12 -2
  236. package/components/sortableList/SortableList.vue.js +5 -5
  237. package/components/sortableList/SortableList.vue2.js +111 -113
  238. package/components/sortableList/SortableSelectableList.vue.d.ts +107 -0
  239. package/components/sortableList/SortableSelectableList.vue.js +7 -0
  240. package/components/sortableList/SortableSelectableList.vue2.js +128 -0
  241. package/components/sortableList/composables/useDraggableHelpers.d.ts +5 -0
  242. package/components/sortableList/composables/useDraggableHelpers.js +20 -0
  243. package/components/sortableList/composables/useHoverEffect.js +1 -1
  244. package/components/sortableList/consts.d.ts +2 -0
  245. package/components/sortableList/consts.js +4 -2
  246. package/components/sortableList/index.d.ts +77 -39
  247. package/components/switch/v4/SwitchV4.vue.d.ts +16 -0
  248. package/components/switch/v4/SwitchV4.vue.js +3 -3
  249. package/components/switch/v4/SwitchV4.vue2.js +39 -24
  250. package/components/switch/v4/index.d.ts +29 -0
  251. package/components/table/common/Table.common.d.ts +0 -1
  252. package/components/table/common/Table.common.js +38 -39
  253. package/components/table/common/Table.types.d.ts +2 -0
  254. package/components/table/common/consts.d.ts +3 -0
  255. package/components/table/common/consts.js +7 -4
  256. package/components/table/v4/DataGrid.vue.d.ts +24 -7
  257. package/components/table/v4/DataGrid.vue.js +4 -4
  258. package/components/table/v4/DataGrid.vue2.js +381 -302
  259. package/components/table/v4/DataGridHeader.vue.d.ts +85 -0
  260. package/components/table/v4/DataGridHeader.vue.js +7 -0
  261. package/components/table/v4/DataGridHeader.vue2.js +84 -0
  262. package/components/table/v4/DataGridRowsCounter.vue.js +3 -3
  263. package/components/table/v4/DataGridRowsCounter.vue2.js +12 -12
  264. package/components/table/v4/MultipleDataGrid.vue.d.ts +8 -7
  265. package/components/table/v4/MultipleDataGrid.vue.js +2 -2
  266. package/components/table/v4/MultipleDataGrid.vue2.js +91 -90
  267. package/components/table/v4/index.d.ts +600 -298
  268. package/components/table/v4/index.js +7 -4
  269. package/components/table/v4/storyUtils.d.ts +27 -0
  270. package/components/tabs/v3/Tabs.vue.d.ts +3 -3
  271. package/components/tabs/v3/index.d.ts +7 -7
  272. package/components/tagsField/TagsField.types.d.ts +4 -0
  273. package/components/tagsField/TagsField.vue.d.ts +65 -0
  274. package/components/tagsField/TagsField.vue.js +7 -0
  275. package/components/tagsField/TagsField.vue2.js +90 -0
  276. package/components/tagsField/TagsFieldChip.vue.d.ts +45 -0
  277. package/components/tagsField/TagsFieldChip.vue.js +7 -0
  278. package/components/tagsField/TagsFieldChip.vue2.js +81 -0
  279. package/components/tagsField/consts.d.ts +1 -0
  280. package/components/tagsField/consts.js +4 -0
  281. package/components/tagsField/index.d.ts +75 -0
  282. package/components/tagsField/index.js +6 -0
  283. package/components/tooltip/common/Tooltip.types.d.ts +1 -0
  284. package/components/tooltip/v3/Tooltip.vue.d.ts +4 -4
  285. package/components/tooltip/v3/Tooltip.vue.js +2 -2
  286. package/components/tooltip/v3/Tooltip.vue2.js +1 -1
  287. package/components/tooltip/v3/index.d.ts +7 -7
  288. package/components/tooltip/v4/TooltipV4.vue.d.ts +9 -4
  289. package/components/tooltip/v4/TooltipV4.vue.js +2 -2
  290. package/components/tooltip/v4/TooltipV4.vue2.js +18 -17
  291. package/components/tooltip/v4/index.d.ts +27 -8
  292. package/components/typography/Text.vue.d.ts +3 -3
  293. package/components/typography/index.d.ts +7 -7
  294. package/composables/useDateService.d.ts +7 -0
  295. package/composables/useDateService.js +10 -0
  296. package/composables/useFormValidation.d.ts +1 -0
  297. package/composables/useFormValidation.js +32 -27
  298. package/consts/common.d.ts +1 -0
  299. package/consts/common.js +4 -0
  300. package/consts/regex.d.ts +1 -0
  301. package/consts/regex.js +2 -1
  302. package/index.d.ts +5309 -3205
  303. package/index.js +138 -116
  304. package/mocks/apps.d.ts +1 -0
  305. package/mocks/optionsWithIcons.d.ts +2 -0
  306. package/package.json +22 -1
  307. package/testids/index.d.ts +47 -1
  308. package/testids/index.js +40 -32
  309. package/utils/date.d.ts +1 -0
  310. package/utils/date.js +9 -0
  311. package/utils/formatNumbers.d.ts +1 -1
  312. package/utils/formatNumbers.js +38 -21
  313. package/utils/object.d.ts +2 -0
  314. package/utils/object.js +9 -5
  315. package/utils/search.js +1 -1
  316. package/utils/text.d.ts +3 -0
  317. package/utils/text.js +24 -5
  318. package/utils/totals.d.ts +5 -0
  319. package/utils/totals.js +9 -0
  320. package/utils/utils.d.ts +1 -0
  321. package/utils/utils.js +4 -0
  322. package/ButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_604dfc6f_lang.css +0 -1
  323. package/ButtonV4.vue_vue_type_style_index_0_scoped_bdfce3aa_lang.css +0 -1
  324. package/Chart.vue_vue_type_style_index_0_scoped_78d3f5a8_lang.css +0 -1
  325. package/ChartHeader.vue_vue_type_style_index_0_scoped_32001725_lang.css +0 -1
  326. package/ChartHeaderTrend.vue_vue_type_style_index_0_scoped_e4c673e7_lang.css +0 -1
  327. package/ChartLegend.vue_vue_type_style_index_0_scoped_532f23bc_lang.css +0 -1
  328. package/ChartPlane.vue_vue_type_style_index_0_scoped_4396faf6_lang.css +0 -1
  329. package/ChartTooltip.vue_vue_type_style_index_0_scoped_25d0e129_lang.css +0 -1
  330. package/ChipDropdownTrigger.vue_vue_type_style_index_0_scoped_e43ac1c9_lang.css +0 -1
  331. package/ConditionalDropdown.vue_vue_type_style_index_0_scoped_8d5521da_lang.css +0 -1
  332. package/DataGrid.vue_vue_type_style_index_0_scoped_6b54ac22_lang.css +0 -1
  333. package/DataGridRowsCounter.vue_vue_type_style_index_0_scoped_ef699ec5_lang.css +0 -1
  334. package/DialogV4.vue_vue_type_style_index_0_scoped_37da643b_lang.css +0 -1
  335. package/DropdownV4.vue_vue_type_style_index_0_scoped_d154c5da_lang.css +0 -1
  336. package/EmptyStateV4.vue_vue_type_style_index_0_scoped_18728498_lang.css +0 -1
  337. package/FieldLabel.vue_vue_type_style_index_0_scoped_96ee1c98_lang.css +0 -1
  338. package/FormRow.vue_vue_type_style_index_0_scoped_fc3897fd_lang.css +0 -1
  339. package/IconButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_59fb505a_lang.css +0 -1
  340. package/MultipleDataGrid.vue_vue_type_style_index_0_scoped_020a9896_lang.css +0 -1
  341. package/OptionV4.vue_vue_type_style_index_0_scoped_1e8837dc_lang.css +0 -1
  342. package/RadioButton.vue_vue_type_style_index_0_scoped_3c6b715c_lang.css +0 -1
  343. package/SettingsHeader.vue_vue_type_style_index_0_scoped_9b6cd9d9_lang.css +0 -1
  344. package/SortableItem.vue_vue_type_style_index_0_scoped_48542664_lang.css +0 -1
  345. package/SortableItemLabel.vue_vue_type_style_index_0_scoped_f2ced2f4_lang.css +0 -1
  346. package/SortableList.vue_vue_type_style_index_0_scoped_8f267f88_lang.css +0 -1
  347. package/SwitchV4.vue_vue_type_style_index_0_scoped_c2e356f5_lang.css +0 -1
  348. package/TextField.vue_vue_type_style_index_0_scoped_fce3948c_lang.css +0 -1
  349. package/ToggleButtonGroupAB.vue_vue_type_style_index_0_scoped_c81a7d3e_lang.css +0 -1
  350. package/Tooltip.vue_vue_type_style_index_0_scoped_9020a179_lang.css +0 -1
  351. package/TooltipV4.vue_vue_type_style_index_0_scoped_66eab856_lang.css +0 -1
  352. package/TreeDropdown.vue_vue_type_style_index_0_scoped_4ba9e4bd_lang.css +0 -1
  353. package/components/chart/composables/useChartValues.d.ts +0 -12
  354. package/components/chart/composables/useChartValues.js +0 -32
@@ -1,91 +1,93 @@
1
- import "../../ChartHeader.vue_vue_type_style_index_0_scoped_32001725_lang.css"; import { defineComponent as b, computed as k, openBlock as r, createElementBlock as C, normalizeClass as w, createElementVNode as i, createVNode as n, unref as a, withCtx as d, renderSlot as B, createTextVNode as m, toDisplayString as f, createBlock as c, createCommentVNode as u, isRef as S } from "vue";
2
- import p from "../typography/v4/Typography.vue.js";
3
- import g from "../switch/v4/SwitchV4.vue.js";
4
- import { ChartType as l } from "./types.js";
5
- import x from "../tooltip/v4/TooltipV4.vue.js";
6
- import y from "./ChartHeaderTrend.vue.js";
7
- const D = { class: "header-texts" }, N = { class: "header-row" }, L = { class: "header-row" }, U = /* @__PURE__ */ b({
1
+ import "../../ChartHeader.vue_vue_type_style_index_0_scoped_d90c583e_lang.css"; import { defineComponent as I, computed as p, openBlock as o, createElementBlock as S, mergeProps as u, unref as t, createElementVNode as c, createVNode as T, createSlots as w, withCtx as y, renderSlot as x, createTextVNode as B, toDisplayString as E, createBlock as d, normalizeProps as b, createCommentVNode as l, isRef as D } from "vue";
2
+ import H from "../typography/v4/Typography.vue.js";
3
+ import N from "../switch/v4/SwitchV4.vue.js";
4
+ import P from "../chip/v4/ChipV4.vue.js";
5
+ import { ChartType as n, TrendDirection as $ } from "./types.js";
6
+ import V from "./ChartHeaderTrend.vue.js";
7
+ import g from "./SubHeader.vue.js";
8
+ import { useTestIdAttrs as A } from "../../utils/testIds.js";
9
+ import { ChartTestIdModifiers as s } from "../../testids/index.js";
10
+ const L = { class: "header-texts" }, R = { class: "header-row" }, U = { class: "header-actions" }, J = /* @__PURE__ */ I({
8
11
  __name: "ChartHeader",
9
12
  props: {
10
- chartType: { default: l.Line },
13
+ chartType: { default: n.Line },
11
14
  typeSwitcher: { type: Boolean, default: !0 },
12
15
  header: { default: "" },
13
16
  subheader: { default: "" },
17
+ subheaderTooltip: { default: null },
18
+ trendTooltip: { default: null },
14
19
  compact: { type: Boolean, default: !1 },
15
20
  trendValue: { default: null },
16
- trendDirection: { default: "up" }
21
+ trendDirection: { default: $.UP },
22
+ noteText: { default: "" },
23
+ testId: { default: "" }
17
24
  },
18
25
  emits: ["update:chartType"],
19
26
  setup(e, { emit: v }) {
20
- const V = e, h = [
21
- { id: l.Line, icon: "chart-line-up" },
22
- { id: l.Bar, icon: "chart-bar" },
23
- { id: l.StackedLine, icon: "chart-line" }
24
- ], o = k({
27
+ const a = e, h = [
28
+ { id: n.Line, icon: "chart-line-up" },
29
+ { id: n.Bar, icon: "chart-bar" },
30
+ { id: n.StackedLine, icon: "chart-line" }
31
+ ], i = p({
25
32
  get() {
26
- return h.find(({ id: t }) => t === V.chartType);
33
+ return h.find(({ id: r }) => r === a.chartType);
27
34
  },
28
- set(t) {
29
- v("update:chartType", t.id);
35
+ set(r) {
36
+ v("update:chartType", r.id);
30
37
  }
31
- });
32
- return (t, s) => (r(), C("div", {
33
- class: w(["chart-header", { "chart-header--compact": e.compact }])
34
- }, [
35
- i("div", D, [
36
- i("div", N, [
37
- n(a(x), {
38
- placement: "right",
39
- disabled: !t.$slots["subheader-tooltip"]
40
- }, {
41
- tooltip: d(() => [
42
- B(t.$slots, "subheader-tooltip", {}, void 0, !0)
43
- ]),
44
- default: d(() => [
45
- n(a(p), {
46
- class: "subheader",
47
- variant: "h5"
48
- }, {
49
- default: d(() => [
50
- m(f(e.subheader + (e.compact ? ":" : "")), 1)
51
- ]),
52
- _: 1
53
- })
38
+ }), m = p(() => ({
39
+ value: a.trendValue,
40
+ direction: a.trendDirection,
41
+ trendTooltip: a.trendTooltip,
42
+ testId: a.testId
43
+ })), k = A(a.testId, s);
44
+ return (r, f) => (o(), S("div", u({
45
+ class: ["chart-header", { "chart-header--compact": e.compact }]
46
+ }, t(k)[t(s).HEADER]), [
47
+ c("div", L, [
48
+ T(g, {
49
+ subheader: e.subheader,
50
+ "subheader-tooltip": e.subheaderTooltip,
51
+ "show-separator": e.compact && (!!e.header || !!e.trendValue)
52
+ }, w({ _: 2 }, [
53
+ r.$slots["subheader-tooltip"] ? {
54
+ name: "subheader-tooltip",
55
+ fn: y(() => [
56
+ x(r.$slots, "subheader-tooltip", {}, void 0, !0)
54
57
  ]),
55
- _: 3
56
- }, 8, ["disabled"])
57
- ]),
58
- i("div", L, [
59
- n(a(p), {
58
+ key: "0"
59
+ } : void 0
60
+ ]), 1032, ["subheader", "subheader-tooltip", "show-separator"]),
61
+ c("div", R, [
62
+ T(t(H), {
60
63
  class: "header-text",
61
64
  variant: e.compact ? "h5" : "chart2"
62
65
  }, {
63
- default: d(() => [
64
- m(f(e.header), 1)
66
+ default: y(() => [
67
+ B(E(e.header), 1)
65
68
  ]),
66
69
  _: 1
67
70
  }, 8, ["variant"]),
68
- !e.compact && e.trendValue !== null ? (r(), c(y, {
69
- key: 0,
70
- value: e.trendValue,
71
- direction: e.trendDirection
72
- }, null, 8, ["value", "direction"])) : u("", !0)
71
+ !e.compact && e.trendValue !== null ? (o(), d(V, b(u({ key: 0 }, t(m))), null, 16)) : l("", !0)
73
72
  ]),
74
- e.compact && e.trendValue !== null ? (r(), c(y, {
75
- key: 0,
76
- value: e.trendValue,
77
- direction: e.trendDirection
78
- }, null, 8, ["value", "direction"])) : u("", !0)
73
+ e.compact && e.trendValue !== null ? (o(), d(V, b(u({ key: 0 }, t(m))), null, 16)) : l("", !0)
79
74
  ]),
80
- e.typeSwitcher ? (r(), c(a(g), {
81
- key: 0,
82
- modelValue: a(o),
83
- "onUpdate:modelValue": s[0] || (s[0] = (T) => S(o) ? o.value = T : null),
84
- options: h
85
- }, null, 8, ["modelValue"])) : u("", !0)
86
- ], 2));
75
+ c("div", U, [
76
+ e.noteText ? (o(), d(t(P), {
77
+ key: 0,
78
+ label: `Note: ${e.noteText}`
79
+ }, null, 8, ["label"])) : l("", !0),
80
+ e.typeSwitcher ? (o(), d(t(N), {
81
+ key: 1,
82
+ modelValue: t(i),
83
+ "onUpdate:modelValue": f[0] || (f[0] = (C) => D(i) ? i.value = C : null),
84
+ options: h,
85
+ "test-id": `${e.testId}-${t(s).TYPE_SWITCHER}`
86
+ }, null, 8, ["modelValue", "test-id"])) : l("", !0)
87
+ ])
88
+ ], 16));
87
89
  }
88
90
  });
89
91
  export {
90
- U as default
92
+ J as default
91
93
  };
@@ -1,18 +1,37 @@
1
+ import { TrendDirection } from '@/components/chart/types';
1
2
  declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
2
3
  value?: number | string;
3
- direction?: 'up' | 'down';
4
+ direction?: TrendDirection;
5
+ trendTooltip?: {
6
+ header?: string;
7
+ rangeCurrent?: string;
8
+ rangePrevious?: string;
9
+ };
10
+ testId?: string;
4
11
  }>, {
5
12
  value: any;
6
- direction: string;
13
+ direction: TrendDirection;
14
+ trendTooltip: any;
15
+ testId: string;
7
16
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
8
17
  value?: number | string;
9
- direction?: 'up' | 'down';
18
+ direction?: TrendDirection;
19
+ trendTooltip?: {
20
+ header?: string;
21
+ rangeCurrent?: string;
22
+ rangePrevious?: string;
23
+ };
24
+ testId?: string;
10
25
  }>, {
11
26
  value: any;
12
- direction: string;
27
+ direction: TrendDirection;
28
+ trendTooltip: any;
29
+ testId: string;
13
30
  }>>>, {
14
31
  value: number | string;
15
- direction: 'up' | 'down';
32
+ testId: string;
33
+ direction: TrendDirection;
34
+ trendTooltip: any;
16
35
  }>;
17
36
  export default _default;
18
37
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
@@ -1,7 +1,7 @@
1
1
  import e from "./ChartHeaderTrend.vue2.js";
2
2
  /* empty css */import o from "../../_virtual/_plugin-vue_export-helper.js";
3
- // import "../../ChartHeaderTrend.vue_vue_type_style_index_0_scoped_e4c673e7_lang.css"; //*');
4
- const s = /* @__PURE__ */ o(e, [["__scopeId", "data-v-e4c673e7"]]);
3
+ // import "../../ChartHeaderTrend.vue_vue_type_style_index_0_scoped_ca558859_lang.css"; //*');
4
+ const a = /* @__PURE__ */ o(e, [["__scopeId", "data-v-ca558859"]]);
5
5
  export {
6
- s as default
6
+ a as default
7
7
  };
@@ -1,32 +1,100 @@
1
- import "../../ChartHeaderTrend.vue_vue_type_style_index_0_scoped_e4c673e7_lang.css"; import { defineComponent as a, openBlock as n, createElementBlock as o, normalizeClass as i, createVNode as t, unref as r, withCtx as c, createTextVNode as l, toDisplayString as d } from "vue";
2
- import m from "../typography/v4/Typography.vue.js";
3
- import p from "../icon/v4/IconV4.vue.js";
1
+ import "../../ChartHeaderTrend.vue_vue_type_style_index_0_scoped_ca558859_lang.css"; import { defineComponent as I, computed as p, openBlock as n, createElementBlock as m, mergeProps as C, unref as e, createVNode as i, withCtx as o, createElementVNode as u, createBlock as c, createTextVNode as a, toDisplayString as l, createCommentVNode as s, pushScopeId as _, popScopeId as x } from "vue";
2
+ import d from "../typography/v4/Typography.vue.js";
3
+ import b from "../icon/v4/IconV4.vue.js";
4
4
  import "../icon/v4/IconFlag.vue.js";
5
- const y = /* @__PURE__ */ a({
5
+ import k from "../tooltip/v4/TooltipV4.vue.js";
6
+ import { TrendDirection as f } from "./types.js";
7
+ import { useTestIdAttrs as N } from "../../utils/testIds.js";
8
+ import { ChartTestIdModifiers as T } from "../../testids/index.js";
9
+ const h = (t) => (_("data-v-ca558859"), t = t(), x(), t), P = { class: "trend-tooltip" }, E = {
10
+ key: 2,
11
+ class: "separator"
12
+ }, S = /* @__PURE__ */ h(() => /* @__PURE__ */ u("hr", null, null, -1)), V = /* @__PURE__ */ h(() => /* @__PURE__ */ u("hr", null, null, -1)), M = /* @__PURE__ */ I({
6
13
  __name: "ChartHeaderTrend",
7
14
  props: {
8
15
  value: { default: null },
9
- direction: { default: "up" }
16
+ direction: { default: f.UP },
17
+ trendTooltip: { default: null },
18
+ testId: { default: "" }
10
19
  },
11
- setup(e) {
12
- return (u, s) => (n(), o("div", {
13
- class: i(["chart-trend", [`chart-trend--${e.direction}`]])
14
- }, [
15
- t(r(p), {
16
- class: "trend-icon",
17
- type: "bold",
18
- name: `arrow-${e.direction}`,
19
- size: "13px"
20
- }, null, 8, ["name"]),
21
- t(r(m), { variant: "chipLabel" }, {
22
- default: c(() => [
23
- l(d(e.value), 1)
20
+ setup(t) {
21
+ const r = t, v = p(
22
+ () => r.trendTooltip?.header || r.trendTooltip?.rangeCurrent || r.trendTooltip?.rangePrevious
23
+ ), g = p(
24
+ () => r.direction === f.NEUTRAL ? "minus" : `arrow-${r.direction}`
25
+ ), y = N(r.testId, T);
26
+ return (w, A) => (n(), m("div", C({
27
+ class: ["chart-trend", [`chart-trend--${t.direction}`]]
28
+ }, e(y)[e(T).TREND]), [
29
+ i(e(k), {
30
+ disabled: !e(v)
31
+ }, {
32
+ tooltip: o(() => [
33
+ u("div", P, [
34
+ t.trendTooltip?.header ? (n(), c(e(d), {
35
+ key: 0,
36
+ class: "trend-tooltip__header",
37
+ variant: "subtitle2"
38
+ }, {
39
+ default: o(() => [
40
+ a(l(t.trendTooltip.header), 1)
41
+ ]),
42
+ _: 1
43
+ })) : s("", !0),
44
+ t.trendTooltip?.rangeCurrent ? (n(), c(e(d), {
45
+ key: 1,
46
+ variant: "body2",
47
+ class: "trend-tooltip__text"
48
+ }, {
49
+ default: o(() => [
50
+ a(l(t.trendTooltip.rangeCurrent), 1)
51
+ ]),
52
+ _: 1
53
+ })) : s("", !0),
54
+ t.trendTooltip?.rangeCurrent && t.trendTooltip?.rangePrevious ? (n(), m("div", E, [
55
+ S,
56
+ i(e(d), {
57
+ class: "separator__text",
58
+ variant: "caption"
59
+ }, {
60
+ default: o(() => [
61
+ a(" vs. ")
62
+ ]),
63
+ _: 1
64
+ }),
65
+ V
66
+ ])) : s("", !0),
67
+ t.trendTooltip?.rangePrevious ? (n(), c(e(d), {
68
+ key: 3,
69
+ variant: "body2",
70
+ class: "trend-tooltip__text"
71
+ }, {
72
+ default: o(() => [
73
+ a(l(t.trendTooltip.rangePrevious), 1)
74
+ ]),
75
+ _: 1
76
+ })) : s("", !0)
77
+ ])
78
+ ]),
79
+ default: o(() => [
80
+ i(e(b), {
81
+ class: "trend-icon",
82
+ type: "bold",
83
+ name: e(g),
84
+ size: "15px"
85
+ }, null, 8, ["name"]),
86
+ i(e(d), { variant: "chipLabel" }, {
87
+ default: o(() => [
88
+ a(l(t.value), 1)
89
+ ]),
90
+ _: 1
91
+ })
24
92
  ]),
25
93
  _: 1
26
- })
27
- ], 2));
94
+ }, 8, ["disabled"])
95
+ ], 16));
28
96
  }
29
97
  });
30
98
  export {
31
- y as default
99
+ M as default
32
100
  };
@@ -2,37 +2,66 @@ import { LegendItem } from '@/components/chart/types';
2
2
  declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
3
3
  items: LegendItem[];
4
4
  visibleIds: unknown[];
5
+ highlightedId?: string | number;
5
6
  minVisible?: number;
6
7
  maxVisible?: number;
7
8
  maxLimitTooltipText?: string;
9
+ sortSelected?: unknown;
10
+ sortOptions?: unknown[];
11
+ sortOptionNameKey?: string;
12
+ testId?: string;
8
13
  }>, {
9
14
  items: () => any[];
10
15
  visibleIds: () => any[];
16
+ highlightedId: any;
11
17
  minVisible: number;
12
18
  maxVisible: number;
13
19
  maxLimitTooltipText: string;
20
+ sortSelected: any;
21
+ sortOptions: () => any[];
22
+ sortOptionNameKey: string;
23
+ testId: string;
14
24
  }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
15
25
  "update:visibleIds": (visibleIds: unknown[]) => void;
26
+ "update:sortSelected": (sortOption: unknown) => void;
27
+ "update:highlightedId": (id: string | number) => void;
16
28
  }, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
17
29
  items: LegendItem[];
18
30
  visibleIds: unknown[];
31
+ highlightedId?: string | number;
19
32
  minVisible?: number;
20
33
  maxVisible?: number;
21
34
  maxLimitTooltipText?: string;
35
+ sortSelected?: unknown;
36
+ sortOptions?: unknown[];
37
+ sortOptionNameKey?: string;
38
+ testId?: string;
22
39
  }>, {
23
40
  items: () => any[];
24
41
  visibleIds: () => any[];
42
+ highlightedId: any;
25
43
  minVisible: number;
26
44
  maxVisible: number;
27
45
  maxLimitTooltipText: string;
46
+ sortSelected: any;
47
+ sortOptions: () => any[];
48
+ sortOptionNameKey: string;
49
+ testId: string;
28
50
  }>>> & {
29
51
  "onUpdate:visibleIds"?: (visibleIds: unknown[]) => any;
52
+ "onUpdate:sortSelected"?: (sortOption: unknown) => any;
53
+ "onUpdate:highlightedId"?: (id: string | number) => any;
30
54
  }, {
55
+ testId: string;
31
56
  items: LegendItem[];
32
57
  visibleIds: unknown[];
58
+ highlightedId: string | number;
33
59
  minVisible: number;
34
60
  maxVisible: number;
35
61
  maxLimitTooltipText: string;
62
+ sortSelected: any;
63
+ sortOptions: unknown[];
64
+ sortOptionNameKey: string;
36
65
  }>;
37
66
  export default _default;
38
67
  type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
@@ -1,7 +1,7 @@
1
1
  import e from "./ChartLegend.vue2.js";
2
2
  /* empty css */import o from "../../_virtual/_plugin-vue_export-helper.js";
3
- // import "../../ChartLegend.vue_vue_type_style_index_0_scoped_532f23bc_lang.css"; //*');
4
- const c = /* @__PURE__ */ o(e, [["__scopeId", "data-v-532f23bc"]]);
3
+ // import "../../ChartLegend.vue_vue_type_style_index_0_scoped_9c4df598_lang.css"; //*');
4
+ const c = /* @__PURE__ */ o(e, [["__scopeId", "data-v-9c4df598"]]);
5
5
  export {
6
6
  c as default
7
7
  };
@@ -1,133 +1,156 @@
1
- import "../../ChartLegend.vue_vue_type_style_index_0_scoped_532f23bc_lang.css"; import { defineComponent as S, ref as P, computed as m, openBlock as s, createElementBlock as c, createElementVNode as r, createVNode as d, unref as o, mergeProps as I, withCtx as p, createTextVNode as b, Fragment as A, renderList as F, normalizeClass as H, withModifiers as U, createBlock as k, createCommentVNode as L, toDisplayString as g } from "vue";
2
- import { useVirtualList as z } from "@vueuse/core";
3
- import f from "../typography/v4/Typography.vue.js";
4
- import R from "../checkbox/v4/CheckboxV4.vue.js";
5
- import q from "../search/v4/SearchV4.vue.js";
6
- import { DEFAULT_MIN_VISIBLE as G, DEFAULT_MAX_VISIBLE as X } from "./consts.js";
7
- import $ from "../icon/v4/IconV4.vue.js";
1
+ import "../../ChartLegend.vue_vue_type_style_index_0_scoped_9c4df598_lang.css"; import { defineComponent as F, ref as G, computed as b, openBlock as n, createElementBlock as u, mergeProps as v, unref as o, createElementVNode as r, createVNode as c, createBlock as g, isRef as H, createCommentVNode as x, withCtx as p, createTextVNode as k, Fragment as z, renderList as K, normalizeClass as q, withModifiers as X, toDisplayString as E } from "vue";
2
+ import { useVModel as _, useVirtualList as j } from "@vueuse/core";
3
+ import y from "../typography/v4/Typography.vue.js";
4
+ import J from "../checkbox/v4/CheckboxV4.vue.js";
5
+ import Q from "../search/v4/SearchV4.vue.js";
6
+ import { DEFAULT_MIN_VISIBLE as W, DEFAULT_MAX_VISIBLE as Y } from "./consts.js";
7
+ import Z from "../icon/v4/IconV4.vue.js";
8
8
  import "../icon/v4/IconFlag.vue.js";
9
- import j from "../tooltip/v4/TooltipV4.vue.js";
10
- const J = { class: "chart-legend" }, K = { class: "search-box" }, O = {
9
+ import ee from "../tooltip/v4/TooltipV4.vue.js";
10
+ import te from "./LegendSorting.vue.js";
11
+ import { useTestIdAttrs as oe } from "../../utils/testIds.js";
12
+ import { ChartTestIdModifiers as L } from "../../testids/index.js";
13
+ const le = { class: "search-box" }, se = {
11
14
  key: 0,
12
15
  class: "empty-list"
13
- }, Q = ["onClick"], W = { class: "label-container" }, ne = /* @__PURE__ */ S({
16
+ }, ie = ["onMouseenter"], ne = ["onClick"], ae = { class: "label-container" }, xe = /* @__PURE__ */ F({
14
17
  __name: "ChartLegend",
15
18
  props: {
16
19
  items: { default: () => [] },
17
20
  visibleIds: { default: () => [] },
18
- minVisible: { default: G },
19
- maxVisible: { default: X },
20
- maxLimitTooltipText: { default: "" }
21
+ highlightedId: { default: null },
22
+ minVisible: { default: W },
23
+ maxVisible: { default: Y },
24
+ maxLimitTooltipText: { default: "" },
25
+ sortSelected: { default: null },
26
+ sortOptions: { default: () => [] },
27
+ sortOptionNameKey: { default: "" },
28
+ testId: { default: "" }
21
29
  },
22
- emits: ["update:visibleIds"],
23
- setup(h, { emit: T }) {
24
- const l = h, y = 32, u = P(""), C = m(() => {
25
- const t = u.value.toLowerCase();
30
+ emits: ["update:visibleIds", "update:sortSelected", "update:highlightedId"],
31
+ setup(i, { emit: m }) {
32
+ const l = i, M = 32, f = _(l, "sortSelected", m), T = _(l, "highlightedId", m), N = (t) => {
33
+ T.value = a(t) ? t.id : null;
34
+ }, w = () => {
35
+ T.value = null;
36
+ }, h = G(""), S = b(() => {
37
+ const t = h.value.toLowerCase();
26
38
  return l.items.filter(
27
- (i) => i.label.toLowerCase().includes(t)
39
+ (s) => s.label.toLowerCase().includes(t)
28
40
  );
29
- }), a = (t) => l.visibleIds.includes(t.id), v = m(
41
+ }), a = (t) => l.visibleIds.includes(t.id), C = b(
30
42
  () => l.visibleIds.length >= l.maxVisible
31
- ), V = m(
43
+ ), D = b(
32
44
  () => l.visibleIds.length <= l.minVisible
33
- ), n = (t) => V.value && a(t) || v.value && !a(t), w = (t) => !l.maxLimitTooltipText || a(t) || !v.value, E = (t, i) => {
34
- T(
45
+ ), d = (t) => D.value && a(t) || C.value && !a(t), O = (t) => !l.maxLimitTooltipText || a(t) || !C.value, A = (t, s) => {
46
+ m(
35
47
  "update:visibleIds",
36
- t ? [...l.visibleIds, i.id] : l.visibleIds.filter((e) => e !== i.id)
48
+ t ? [...l.visibleIds, s.id] : l.visibleIds.filter((e) => e !== s.id)
37
49
  );
38
- }, { list: x, containerProps: N, wrapperProps: B } = z(C, {
39
- itemHeight: y,
50
+ }, { list: V, containerProps: B, wrapperProps: R } = j(S, {
51
+ itemHeight: M,
40
52
  overscan: 10
41
- }), D = (t) => {
42
- n(t) || E(!a(t), t);
43
- };
44
- return (t, i) => (s(), c("div", J, [
45
- r("div", K, [
46
- d(o(q), {
47
- modelValue: u.value,
48
- "onUpdate:modelValue": i[0] || (i[0] = (e) => u.value = e)
49
- }, null, 8, ["modelValue"])
53
+ }), $ = (t) => {
54
+ d(t) || A(!a(t), t);
55
+ }, P = oe(l.testId, L);
56
+ return (t, s) => (n(), u("div", v({ class: "chart-legend" }, o(P)[o(L).LEGEND_CONTAINER]), [
57
+ r("div", le, [
58
+ c(o(Q), {
59
+ modelValue: h.value,
60
+ "onUpdate:modelValue": s[0] || (s[0] = (e) => h.value = e),
61
+ "test-id": i.testId
62
+ }, null, 8, ["modelValue", "test-id"]),
63
+ i.sortOptions?.length > 0 ? (n(), g(te, {
64
+ key: 0,
65
+ selected: o(f),
66
+ "onUpdate:selected": s[1] || (s[1] = (e) => H(f) ? f.value = e : null),
67
+ options: i.sortOptions,
68
+ "option-name-key": i.sortOptionNameKey,
69
+ "test-id": `${i.testId}-${o(L).LEGEND_SORT}`
70
+ }, null, 8, ["selected", "options", "option-name-key", "test-id"])) : x("", !0)
50
71
  ]),
51
- r("div", I({ class: "legend" }, o(N)), [
52
- r("ul", I({ class: "legend__list" }, o(B)), [
53
- o(x).length === 0 ? (s(), c("li", O, [
54
- d(o(f), { variant: "body2" }, {
72
+ r("div", v({ class: "legend" }, o(B)), [
73
+ r("ul", v({ class: "legend__list" }, o(R)), [
74
+ o(V).length === 0 ? (n(), u("li", se, [
75
+ c(o(y), { variant: "body2" }, {
55
76
  default: p(() => [
56
- b("No results")
77
+ k("No results")
57
78
  ]),
58
79
  _: 1
59
80
  })
60
- ])) : (s(!0), c(A, { key: 1 }, F(o(x), ({ data: e, index: M }) => (s(), c("li", {
61
- key: M,
62
- class: H({ "disabled-item": n(e) })
81
+ ])) : (n(!0), u(z, { key: 1 }, K(o(V), ({ data: e, index: U }) => (n(), u("li", {
82
+ key: U,
83
+ class: q({ "disabled-item": d(e) }),
84
+ onMouseenter: (I) => N(e),
85
+ onMouseleave: w
63
86
  }, [
64
- d(o(j), {
65
- text: h.maxLimitTooltipText,
66
- disabled: w(e),
87
+ c(o(ee), {
88
+ text: i.maxLimitTooltipText,
89
+ disabled: O(e),
67
90
  class: "disabled-tooltip"
68
91
  }, {
69
92
  default: p(() => [
70
93
  r("div", {
71
94
  class: "item-wrapper",
72
- onClick: (_) => D(e)
95
+ onClick: (I) => $(e)
73
96
  }, [
74
- d(o(R), {
97
+ c(o(J), {
75
98
  color: e.color,
76
99
  "is-checked": a(e),
77
- disabled: n(e),
78
- onClick: i[1] || (i[1] = U(
79
- (_) => {
80
- _.stopPropagation();
100
+ disabled: d(e),
101
+ onClick: s[2] || (s[2] = X(
102
+ (I) => {
103
+ I.stopPropagation();
81
104
  },
82
105
  ["stop"]
83
106
  ))
84
107
  }, null, 8, ["color", "is-checked", "disabled"]),
85
- e.icon ? (s(), k(o($), {
108
+ e.icon ? (n(), g(o(Z), {
86
109
  key: 0,
87
110
  class: "icon-color",
88
111
  type: e.iconType,
89
112
  name: e.icon,
90
113
  size: "16px"
91
- }, null, 8, ["type", "name"])) : L("", !0),
92
- r("div", W, [
93
- d(o(f), {
114
+ }, null, 8, ["type", "name"])) : x("", !0),
115
+ r("div", ae, [
116
+ c(o(y), {
94
117
  variant: "body2",
95
118
  class: "legend-label",
96
119
  "is-truncated": "",
97
- "with-tooltip": !n(e),
120
+ "with-tooltip": !d(e),
98
121
  "tooltip-text": e.label,
99
122
  "tooltip-placement": "left"
100
123
  }, {
101
124
  default: p(() => [
102
- b(g(e.label), 1)
125
+ k(E(e.label), 1)
103
126
  ]),
104
127
  _: 2
105
128
  }, 1032, ["with-tooltip", "tooltip-text"]),
106
- e.caption ? (s(), k(o(f), {
129
+ e.caption ? (n(), g(o(y), {
107
130
  key: 0,
108
131
  variant: "caption",
109
132
  class: "legend-caption legend-label",
110
133
  "is-truncated": "",
111
- "with-tooltip": !n(e),
134
+ "with-tooltip": !d(e),
112
135
  "tooltip-text": e.caption,
113
136
  "tooltip-placement": "left"
114
137
  }, {
115
138
  default: p(() => [
116
- b(g(e.caption), 1)
139
+ k(E(e.caption), 1)
117
140
  ]),
118
141
  _: 2
119
- }, 1032, ["with-tooltip", "tooltip-text"])) : L("", !0)
142
+ }, 1032, ["with-tooltip", "tooltip-text"])) : x("", !0)
120
143
  ])
121
- ], 8, Q)
144
+ ], 8, ne)
122
145
  ]),
123
146
  _: 2
124
147
  }, 1032, ["text", "disabled"])
125
- ], 2))), 128))
148
+ ], 42, ie))), 128))
126
149
  ], 16)
127
150
  ], 16)
128
- ]));
151
+ ], 16));
129
152
  }
130
153
  });
131
154
  export {
132
- ne as default
155
+ xe as default
133
156
  };