@perses-dev/components 0.39.0 → 0.40.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (328) hide show
  1. package/dist/BarChart/BarChart.d.ts +2 -2
  2. package/dist/BarChart/BarChart.d.ts.map +1 -1
  3. package/dist/BarChart/BarChart.js +8 -8
  4. package/dist/BarChart/BarChart.js.map +1 -1
  5. package/dist/BarChart/index.js.map +1 -1
  6. package/dist/ColorPicker/ColorPicker.js.map +1 -1
  7. package/dist/ColorPicker/index.js.map +1 -1
  8. package/dist/ContentWithLegend/ContentWithLegend.js.map +1 -1
  9. package/dist/ContentWithLegend/index.js.map +1 -1
  10. package/dist/ContentWithLegend/model/content-with-legend-model.d.ts +1 -1
  11. package/dist/ContentWithLegend/model/content-with-legend-model.js +19 -19
  12. package/dist/ContentWithLegend/model/content-with-legend-model.js.map +1 -1
  13. package/dist/DateTimeRangePicker/AbsoluteTimePicker.d.ts.map +1 -1
  14. package/dist/DateTimeRangePicker/AbsoluteTimePicker.js +6 -22
  15. package/dist/DateTimeRangePicker/AbsoluteTimePicker.js.map +1 -1
  16. package/dist/DateTimeRangePicker/DateTimeRangePicker.js.map +1 -1
  17. package/dist/DateTimeRangePicker/TimeRangeSelector.js.map +1 -1
  18. package/dist/DateTimeRangePicker/index.js.map +1 -1
  19. package/dist/DateTimeRangePicker/utils.js.map +1 -1
  20. package/dist/Dialog/Dialog.js.map +1 -1
  21. package/dist/Dialog/DiscardChangesConfirmationDialog.js.map +1 -1
  22. package/dist/Dialog/index.js.map +1 -1
  23. package/dist/Drawer/Drawer.js.map +1 -1
  24. package/dist/Drawer/index.js.map +1 -1
  25. package/dist/EChart/EChart.js +2 -2
  26. package/dist/EChart/EChart.js.map +1 -1
  27. package/dist/EChart/index.js.map +1 -1
  28. package/dist/ErrorAlert.js.map +1 -1
  29. package/dist/ErrorBoundary.js.map +1 -1
  30. package/dist/FontSizeSelector/FontSizeSelector.js.map +1 -1
  31. package/dist/FontSizeSelector/index.js.map +1 -1
  32. package/dist/FormatControls/FormatControls.d.ts +9 -0
  33. package/dist/FormatControls/FormatControls.d.ts.map +1 -0
  34. package/dist/{UnitSelector/UnitSelector.js → FormatControls/FormatControls.js} +26 -26
  35. package/dist/FormatControls/FormatControls.js.map +1 -0
  36. package/dist/FormatControls/index.d.ts +2 -0
  37. package/dist/FormatControls/index.d.ts.map +1 -0
  38. package/dist/{UnitSelector → FormatControls}/index.js +1 -1
  39. package/dist/FormatControls/index.js.map +1 -0
  40. package/dist/GaugeChart/GaugeChart.d.ts +3 -3
  41. package/dist/GaugeChart/GaugeChart.d.ts.map +1 -1
  42. package/dist/GaugeChart/GaugeChart.js +11 -11
  43. package/dist/GaugeChart/GaugeChart.js.map +1 -1
  44. package/dist/GaugeChart/index.js.map +1 -1
  45. package/dist/InfoTooltip/InfoTooltip.js.map +1 -1
  46. package/dist/InfoTooltip/index.js.map +1 -1
  47. package/dist/JSONEditor.js.map +1 -1
  48. package/dist/Legend/CompactLegend.js.map +1 -1
  49. package/dist/Legend/Legend.js +3 -3
  50. package/dist/Legend/Legend.js.map +1 -1
  51. package/dist/Legend/LegendColorBadge.js.map +1 -1
  52. package/dist/Legend/ListLegend.js.map +1 -1
  53. package/dist/Legend/ListLegendItem.js +2 -2
  54. package/dist/Legend/ListLegendItem.js.map +1 -1
  55. package/dist/Legend/TableLegend.js.map +1 -1
  56. package/dist/Legend/index.js.map +1 -1
  57. package/dist/Legend/legend-model.js.map +1 -1
  58. package/dist/LineChart/LineChart.d.ts +2 -2
  59. package/dist/LineChart/LineChart.d.ts.map +1 -1
  60. package/dist/LineChart/LineChart.js +12 -12
  61. package/dist/LineChart/LineChart.js.map +1 -1
  62. package/dist/LineChart/index.js.map +1 -1
  63. package/dist/ModeSelector/ModeSelector.js.map +1 -1
  64. package/dist/ModeSelector/index.js.map +1 -1
  65. package/dist/OptionsEditorLayout/OptionsEditorColumn.js.map +1 -1
  66. package/dist/OptionsEditorLayout/OptionsEditorControl.js.map +1 -1
  67. package/dist/OptionsEditorLayout/OptionsEditorGrid.js.map +1 -1
  68. package/dist/OptionsEditorLayout/OptionsEditorGroup.js.map +1 -1
  69. package/dist/OptionsEditorLayout/index.js.map +1 -1
  70. package/dist/RefreshIntervalPicker/RefreshIntervalPicker.js.map +1 -1
  71. package/dist/RefreshIntervalPicker/index.js.map +1 -1
  72. package/dist/SettingsAutocomplete/SettingsAutocomplete.js +2 -2
  73. package/dist/SettingsAutocomplete/SettingsAutocomplete.js.map +1 -1
  74. package/dist/SettingsAutocomplete/index.js.map +1 -1
  75. package/dist/SortSelector/SortSelector.js.map +1 -1
  76. package/dist/SortSelector/index.js.map +1 -1
  77. package/dist/StatChart/StatChart.d.ts +2 -2
  78. package/dist/StatChart/StatChart.d.ts.map +1 -1
  79. package/dist/StatChart/StatChart.js +7 -7
  80. package/dist/StatChart/StatChart.js.map +1 -1
  81. package/dist/StatChart/calculateFontSize.js +4 -4
  82. package/dist/StatChart/calculateFontSize.js.map +1 -1
  83. package/dist/StatChart/index.js.map +1 -1
  84. package/dist/Table/InnerTable.js.map +1 -1
  85. package/dist/Table/Table.js.map +1 -1
  86. package/dist/Table/TableBody.js.map +1 -1
  87. package/dist/Table/TableCell.js +2 -2
  88. package/dist/Table/TableCell.js.map +1 -1
  89. package/dist/Table/TableCheckbox.js.map +1 -1
  90. package/dist/Table/TableHead.js.map +1 -1
  91. package/dist/Table/TableHeaderCell.js.map +1 -1
  92. package/dist/Table/TableRow.js.map +1 -1
  93. package/dist/Table/VirtualizedTable.js +6 -6
  94. package/dist/Table/VirtualizedTable.js.map +1 -1
  95. package/dist/Table/VirtualizedTableContainer.js.map +1 -1
  96. package/dist/Table/hooks/useTableKeyboardNav.js.map +1 -1
  97. package/dist/Table/hooks/useVirtualizedTableKeyboardNav.js +20 -20
  98. package/dist/Table/hooks/useVirtualizedTableKeyboardNav.js.map +1 -1
  99. package/dist/Table/index.js.map +1 -1
  100. package/dist/Table/model/table-model.js +9 -9
  101. package/dist/Table/model/table-model.js.map +1 -1
  102. package/dist/ThresholdsEditor/ThresholdColorPicker.js +1 -1
  103. package/dist/ThresholdsEditor/ThresholdColorPicker.js.map +1 -1
  104. package/dist/ThresholdsEditor/ThresholdInput.js +1 -1
  105. package/dist/ThresholdsEditor/ThresholdInput.js.map +1 -1
  106. package/dist/ThresholdsEditor/ThresholdsEditor.js +17 -17
  107. package/dist/ThresholdsEditor/ThresholdsEditor.js.map +1 -1
  108. package/dist/ThresholdsEditor/index.js.map +1 -1
  109. package/dist/TimeChart/TimeChart.d.ts +2 -2
  110. package/dist/TimeChart/TimeChart.d.ts.map +1 -1
  111. package/dist/TimeChart/TimeChart.js +12 -12
  112. package/dist/TimeChart/TimeChart.js.map +1 -1
  113. package/dist/TimeChart/index.js.map +1 -1
  114. package/dist/TimeSeriesTooltip/LineChartTooltip.d.ts +2 -2
  115. package/dist/TimeSeriesTooltip/LineChartTooltip.d.ts.map +1 -1
  116. package/dist/TimeSeriesTooltip/LineChartTooltip.js +7 -7
  117. package/dist/TimeSeriesTooltip/LineChartTooltip.js.map +1 -1
  118. package/dist/TimeSeriesTooltip/SeriesInfo.js +2 -2
  119. package/dist/TimeSeriesTooltip/SeriesInfo.js.map +1 -1
  120. package/dist/TimeSeriesTooltip/SeriesLabelsStack.js.map +1 -1
  121. package/dist/TimeSeriesTooltip/SeriesMarker.js.map +1 -1
  122. package/dist/TimeSeriesTooltip/TimeChartTooltip.d.ts +2 -2
  123. package/dist/TimeSeriesTooltip/TimeChartTooltip.d.ts.map +1 -1
  124. package/dist/TimeSeriesTooltip/TimeChartTooltip.js +4 -4
  125. package/dist/TimeSeriesTooltip/TimeChartTooltip.js.map +1 -1
  126. package/dist/TimeSeriesTooltip/TooltipContent.js.map +1 -1
  127. package/dist/TimeSeriesTooltip/TooltipHeader.js +6 -6
  128. package/dist/TimeSeriesTooltip/TooltipHeader.js.map +1 -1
  129. package/dist/TimeSeriesTooltip/index.js.map +1 -1
  130. package/dist/TimeSeriesTooltip/nearby-series.d.ts +7 -7
  131. package/dist/TimeSeriesTooltip/nearby-series.d.ts.map +1 -1
  132. package/dist/TimeSeriesTooltip/nearby-series.js +29 -29
  133. package/dist/TimeSeriesTooltip/nearby-series.js.map +1 -1
  134. package/dist/TimeSeriesTooltip/tooltip-model.js.map +1 -1
  135. package/dist/TimeSeriesTooltip/utils.js +3 -3
  136. package/dist/TimeSeriesTooltip/utils.js.map +1 -1
  137. package/dist/YAxisLabel.js.map +1 -1
  138. package/dist/cjs/BarChart/BarChart.js +17 -15
  139. package/dist/cjs/BarChart/index.js +10 -8
  140. package/dist/cjs/ColorPicker/ColorPicker.js +15 -13
  141. package/dist/cjs/ColorPicker/index.js +10 -8
  142. package/dist/cjs/ContentWithLegend/ContentWithLegend.js +12 -10
  143. package/dist/cjs/ContentWithLegend/index.js +10 -8
  144. package/dist/cjs/ContentWithLegend/model/content-with-legend-model.js +27 -23
  145. package/dist/cjs/DateTimeRangePicker/AbsoluteTimePicker.js +29 -43
  146. package/dist/cjs/DateTimeRangePicker/DateTimeRangePicker.js +12 -10
  147. package/dist/cjs/DateTimeRangePicker/TimeRangeSelector.js +13 -11
  148. package/dist/cjs/DateTimeRangePicker/index.js +12 -10
  149. package/dist/cjs/DateTimeRangePicker/utils.js +9 -5
  150. package/dist/cjs/Dialog/Dialog.js +15 -13
  151. package/dist/cjs/Dialog/DiscardChangesConfirmationDialog.js +11 -9
  152. package/dist/cjs/Dialog/index.js +11 -9
  153. package/dist/cjs/Drawer/Drawer.js +5 -3
  154. package/dist/cjs/Drawer/index.js +10 -8
  155. package/dist/cjs/EChart/EChart.js +12 -10
  156. package/dist/cjs/EChart/index.js +10 -8
  157. package/dist/cjs/ErrorAlert.js +5 -3
  158. package/dist/cjs/ErrorBoundary.js +4 -2
  159. package/dist/cjs/FontSizeSelector/FontSizeSelector.js +8 -6
  160. package/dist/cjs/FontSizeSelector/index.js +10 -8
  161. package/dist/cjs/{UnitSelector/UnitSelector.js → FormatControls/FormatControls.js} +38 -36
  162. package/dist/cjs/{UnitSelector → FormatControls}/index.js +10 -8
  163. package/dist/cjs/GaugeChart/GaugeChart.js +22 -18
  164. package/dist/cjs/GaugeChart/index.js +10 -8
  165. package/dist/cjs/InfoTooltip/InfoTooltip.js +13 -11
  166. package/dist/cjs/InfoTooltip/index.js +10 -8
  167. package/dist/cjs/JSONEditor.js +10 -8
  168. package/dist/cjs/Legend/CompactLegend.js +9 -7
  169. package/dist/cjs/Legend/Legend.js +15 -13
  170. package/dist/cjs/Legend/LegendColorBadge.js +7 -5
  171. package/dist/cjs/Legend/ListLegend.js +10 -8
  172. package/dist/cjs/Legend/ListLegendItem.js +12 -10
  173. package/dist/cjs/Legend/TableLegend.js +7 -5
  174. package/dist/cjs/Legend/index.js +11 -9
  175. package/dist/cjs/Legend/legend-model.js +3 -1
  176. package/dist/cjs/LineChart/LineChart.js +24 -22
  177. package/dist/cjs/LineChart/index.js +10 -8
  178. package/dist/cjs/ModeSelector/ModeSelector.js +8 -6
  179. package/dist/cjs/ModeSelector/index.js +10 -8
  180. package/dist/cjs/OptionsEditorLayout/OptionsEditorColumn.js +6 -4
  181. package/dist/cjs/OptionsEditorLayout/OptionsEditorControl.js +16 -14
  182. package/dist/cjs/OptionsEditorLayout/OptionsEditorGrid.js +5 -3
  183. package/dist/cjs/OptionsEditorLayout/OptionsEditorGroup.js +11 -9
  184. package/dist/cjs/OptionsEditorLayout/index.js +13 -11
  185. package/dist/cjs/RefreshIntervalPicker/RefreshIntervalPicker.js +8 -6
  186. package/dist/cjs/RefreshIntervalPicker/index.js +10 -8
  187. package/dist/cjs/SettingsAutocomplete/SettingsAutocomplete.js +12 -10
  188. package/dist/cjs/SettingsAutocomplete/index.js +10 -8
  189. package/dist/cjs/SortSelector/SortSelector.js +8 -6
  190. package/dist/cjs/SortSelector/index.js +10 -8
  191. package/dist/cjs/StatChart/StatChart.js +20 -18
  192. package/dist/cjs/StatChart/calculateFontSize.js +9 -7
  193. package/dist/cjs/StatChart/index.js +10 -8
  194. package/dist/cjs/Table/InnerTable.js +5 -3
  195. package/dist/cjs/Table/Table.js +15 -13
  196. package/dist/cjs/Table/TableBody.js +5 -3
  197. package/dist/cjs/Table/TableCell.js +10 -8
  198. package/dist/cjs/Table/TableCheckbox.js +5 -3
  199. package/dist/cjs/Table/TableHead.js +5 -3
  200. package/dist/cjs/Table/TableHeaderCell.js +8 -6
  201. package/dist/cjs/Table/TableRow.js +5 -3
  202. package/dist/cjs/Table/VirtualizedTable.js +32 -30
  203. package/dist/cjs/Table/VirtualizedTableContainer.js +5 -3
  204. package/dist/cjs/Table/hooks/useTableKeyboardNav.js +3 -1
  205. package/dist/cjs/Table/hooks/useVirtualizedTableKeyboardNav.js +23 -21
  206. package/dist/cjs/Table/index.js +14 -10
  207. package/dist/cjs/Table/model/table-model.js +15 -11
  208. package/dist/cjs/ThresholdsEditor/ThresholdColorPicker.js +15 -13
  209. package/dist/cjs/ThresholdsEditor/ThresholdInput.js +14 -12
  210. package/dist/cjs/ThresholdsEditor/ThresholdsEditor.js +44 -42
  211. package/dist/cjs/ThresholdsEditor/index.js +10 -8
  212. package/dist/cjs/TimeChart/TimeChart.js +31 -29
  213. package/dist/cjs/TimeChart/index.js +10 -8
  214. package/dist/cjs/TimeSeriesTooltip/LineChartTooltip.js +28 -26
  215. package/dist/cjs/TimeSeriesTooltip/SeriesInfo.js +17 -15
  216. package/dist/cjs/TimeSeriesTooltip/SeriesLabelsStack.js +15 -13
  217. package/dist/cjs/TimeSeriesTooltip/SeriesMarker.js +5 -3
  218. package/dist/cjs/TimeSeriesTooltip/TimeChartTooltip.js +22 -20
  219. package/dist/cjs/TimeSeriesTooltip/TooltipContent.js +7 -5
  220. package/dist/cjs/TimeSeriesTooltip/TooltipHeader.js +34 -32
  221. package/dist/cjs/TimeSeriesTooltip/index.js +19 -17
  222. package/dist/cjs/TimeSeriesTooltip/nearby-series.js +56 -38
  223. package/dist/cjs/TimeSeriesTooltip/tooltip-model.js +51 -17
  224. package/dist/cjs/TimeSeriesTooltip/utils.js +17 -13
  225. package/dist/cjs/YAxisLabel.js +6 -4
  226. package/dist/cjs/context/ChartsProvider.js +16 -8
  227. package/dist/cjs/context/SnackbarProvider.js +6 -2
  228. package/dist/cjs/context/TimeZoneProvider.js +13 -7
  229. package/dist/cjs/context/index.js +12 -10
  230. package/dist/cjs/index.js +41 -39
  231. package/dist/cjs/model/graph.js +9 -3
  232. package/dist/cjs/model/index.js +12 -10
  233. package/dist/cjs/test/index.js +10 -8
  234. package/dist/cjs/test/render.js +7 -5
  235. package/dist/cjs/test-utils/index.js +10 -8
  236. package/dist/cjs/test-utils/theme.js +6 -2
  237. package/dist/cjs/theme/component-overrides/alert.js +3 -1
  238. package/dist/cjs/theme/component-overrides/paper.js +3 -1
  239. package/dist/cjs/theme/index.js +10 -8
  240. package/dist/cjs/theme/palette/background.js +6 -2
  241. package/dist/cjs/theme/palette/colors/blue.js +3 -1
  242. package/dist/cjs/theme/palette/colors/common.js +6 -2
  243. package/dist/cjs/theme/palette/colors/green.js +3 -1
  244. package/dist/cjs/theme/palette/colors/grey.js +3 -1
  245. package/dist/cjs/theme/palette/colors/index.js +17 -15
  246. package/dist/cjs/theme/palette/colors/orange.js +3 -1
  247. package/dist/cjs/theme/palette/colors/purple.js +3 -1
  248. package/dist/cjs/theme/palette/colors/red.js +3 -1
  249. package/dist/cjs/theme/palette/error.js +3 -1
  250. package/dist/cjs/theme/palette/grey.js +3 -1
  251. package/dist/cjs/theme/palette/index.js +10 -8
  252. package/dist/cjs/theme/palette/palette-options.js +3 -1
  253. package/dist/cjs/theme/palette/primary.js +3 -1
  254. package/dist/cjs/theme/palette/secondary.js +3 -1
  255. package/dist/cjs/theme/palette/success.js +3 -1
  256. package/dist/cjs/theme/palette/text.js +3 -1
  257. package/dist/cjs/theme/palette/warning.js +3 -1
  258. package/dist/cjs/theme/theme.js +5 -3
  259. package/dist/cjs/theme/typography.js +3 -1
  260. package/dist/cjs/utils/axis.js +8 -4
  261. package/dist/cjs/utils/chart-actions.js +26 -10
  262. package/dist/cjs/utils/combine-sx.js +3 -1
  263. package/dist/cjs/utils/component-ids.js +3 -1
  264. package/dist/cjs/utils/format.js +16 -8
  265. package/dist/cjs/utils/index.js +15 -13
  266. package/dist/cjs/utils/mathjs.js +3 -1
  267. package/dist/cjs/utils/theme-gen.js +12 -10
  268. package/dist/context/ChartsProvider.js.map +1 -1
  269. package/dist/context/SnackbarProvider.js.map +1 -1
  270. package/dist/context/TimeZoneProvider.js.map +1 -1
  271. package/dist/context/index.js.map +1 -1
  272. package/dist/index.d.ts +1 -1
  273. package/dist/index.d.ts.map +1 -1
  274. package/dist/index.js +1 -1
  275. package/dist/index.js.map +1 -1
  276. package/dist/model/graph.js.map +1 -1
  277. package/dist/model/index.js.map +1 -1
  278. package/dist/test/index.js.map +1 -1
  279. package/dist/test/render.js.map +1 -1
  280. package/dist/test/setup-tests.js.map +1 -1
  281. package/dist/test-utils/index.js.map +1 -1
  282. package/dist/test-utils/theme.js.map +1 -1
  283. package/dist/theme/component-overrides/alert.js.map +1 -1
  284. package/dist/theme/component-overrides/paper.js.map +1 -1
  285. package/dist/theme/index.d.ts +1 -0
  286. package/dist/theme/index.d.ts.map +1 -1
  287. package/dist/theme/index.js.map +1 -1
  288. package/dist/theme/palette/background.d.ts.map +1 -1
  289. package/dist/theme/palette/background.js +3 -1
  290. package/dist/theme/palette/background.js.map +1 -1
  291. package/dist/theme/palette/colors/blue.js.map +1 -1
  292. package/dist/theme/palette/colors/common.js.map +1 -1
  293. package/dist/theme/palette/colors/green.js.map +1 -1
  294. package/dist/theme/palette/colors/grey.js.map +1 -1
  295. package/dist/theme/palette/colors/index.js.map +1 -1
  296. package/dist/theme/palette/colors/orange.js.map +1 -1
  297. package/dist/theme/palette/colors/purple.js.map +1 -1
  298. package/dist/theme/palette/colors/red.js.map +1 -1
  299. package/dist/theme/palette/error.js.map +1 -1
  300. package/dist/theme/palette/grey.js.map +1 -1
  301. package/dist/theme/palette/index.js.map +1 -1
  302. package/dist/theme/palette/palette-options.js.map +1 -1
  303. package/dist/theme/palette/primary.js.map +1 -1
  304. package/dist/theme/palette/secondary.js.map +1 -1
  305. package/dist/theme/palette/success.js.map +1 -1
  306. package/dist/theme/palette/text.js.map +1 -1
  307. package/dist/theme/palette/warning.js.map +1 -1
  308. package/dist/theme/theme.js.map +1 -1
  309. package/dist/theme/typography.js.map +1 -1
  310. package/dist/utils/axis.d.ts +2 -2
  311. package/dist/utils/axis.d.ts.map +1 -1
  312. package/dist/utils/axis.js.map +1 -1
  313. package/dist/utils/chart-actions.js +2 -2
  314. package/dist/utils/chart-actions.js.map +1 -1
  315. package/dist/utils/combine-sx.js.map +1 -1
  316. package/dist/utils/component-ids.js.map +1 -1
  317. package/dist/utils/format.js.map +1 -1
  318. package/dist/utils/index.js.map +1 -1
  319. package/dist/utils/mathjs.js.map +1 -1
  320. package/dist/utils/theme-gen.js +7 -7
  321. package/dist/utils/theme-gen.js.map +1 -1
  322. package/package.json +7 -6
  323. package/dist/UnitSelector/UnitSelector.d.ts +0 -9
  324. package/dist/UnitSelector/UnitSelector.d.ts.map +0 -1
  325. package/dist/UnitSelector/UnitSelector.js.map +0 -1
  326. package/dist/UnitSelector/index.d.ts +0 -2
  327. package/dist/UnitSelector/index.d.ts.map +0 -1
  328. package/dist/UnitSelector/index.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"background.d.ts","sourceRoot":"","sources":["../../../src/theme/palette/background.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAG5D,eAAO,MAAM,UAAU,SAAU,WAAW,KAAG,cAAc,CAAC,YAAY,CAoBzE,CAAC"}
1
+ {"version":3,"file":"background.d.ts","sourceRoot":"","sources":["../../../src/theme/palette/background.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAG5D,eAAO,MAAM,UAAU,SAAU,WAAW,KAAG,cAAc,CAAC,YAAY,CAsBzE,CAAC"}
@@ -20,13 +20,15 @@ export const background = (mode)=>{
20
20
  default: white,
21
21
  paper: grey[50],
22
22
  tooltip: grey[100],
23
+ lighter: grey[50],
23
24
  border: grey[100]
24
25
  } : {
25
26
  navigation,
26
27
  overlay,
27
28
  default: grey[900],
28
29
  paper: grey[850],
29
- tooltip: grey[700],
30
+ tooltip: grey[600],
31
+ lighter: grey[700],
30
32
  border: grey[600]
31
33
  };
32
34
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/background.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, PaletteOptions } from '@mui/material';\nimport { blue, grey, white } from './colors';\n\nexport const background = (mode: PaletteMode): PaletteOptions['background'] => {\n const navigation = blue[150];\n const overlay = 'rgba(21, 23, 33, 0.75)'; // grey[900] with opacity 75%\n return mode === 'light'\n ? {\n navigation,\n overlay,\n default: white,\n paper: grey[50],\n tooltip: grey[100],\n border: grey[100],\n }\n : {\n navigation,\n overlay,\n default: grey[900],\n paper: grey[850],\n tooltip: grey[700],\n border: grey[600],\n };\n};\n"],"names":["blue","grey","white","background","mode","navigation","overlay","default","paper","tooltip","border"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,EAAEC,IAAI,EAAEC,KAAK,QAAQ,UAAU,CAAC;AAE7C,OAAO,MAAMC,UAAU,GAAG,CAACC,IAAiB,GAAmC;IAC7E,MAAMC,UAAU,GAAGL,IAAI,CAAC,GAAG,CAAC,AAAC;IAC7B,MAAMM,OAAO,GAAG,wBAAwB,AAAC,EAAC,6BAA6B;IACvE,OAAOF,IAAI,KAAK,OAAO,GACnB;QACEC,UAAU;QACVC,OAAO;QACPC,OAAO,EAAEL,KAAK;QACdM,KAAK,EAAEP,IAAI,CAAC,EAAE,CAAC;QACfQ,OAAO,EAAER,IAAI,CAAC,GAAG,CAAC;QAClBS,MAAM,EAAET,IAAI,CAAC,GAAG,CAAC;KAClB,GACD;QACEI,UAAU;QACVC,OAAO;QACPC,OAAO,EAAEN,IAAI,CAAC,GAAG,CAAC;QAClBO,KAAK,EAAEP,IAAI,CAAC,GAAG,CAAC;QAChBQ,OAAO,EAAER,IAAI,CAAC,GAAG,CAAC;QAClBS,MAAM,EAAET,IAAI,CAAC,GAAG,CAAC;KAClB,CAAC;AACR,CAAC,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/background.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, PaletteOptions } from '@mui/material';\nimport { blue, grey, white } from './colors';\n\nexport const background = (mode: PaletteMode): PaletteOptions['background'] => {\n const navigation = blue[150];\n const overlay = 'rgba(21, 23, 33, 0.75)'; // grey[900] with opacity 75%\n return mode === 'light'\n ? {\n navigation,\n overlay,\n default: white,\n paper: grey[50],\n tooltip: grey[100],\n lighter: grey[50],\n border: grey[100],\n }\n : {\n navigation,\n overlay,\n default: grey[900],\n paper: grey[850],\n tooltip: grey[600],\n lighter: grey[700],\n border: grey[600],\n };\n};\n"],"names":["blue","grey","white","background","mode","navigation","overlay","default","paper","tooltip","lighter","border"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,EAAEC,IAAI,EAAEC,KAAK,QAAQ,WAAW;AAE7C,OAAO,MAAMC,aAAa,CAACC;IACzB,MAAMC,aAAaL,IAAI,CAAC,IAAI;IAC5B,MAAMM,UAAU,0BAA0B,6BAA6B;IACvE,OAAOF,SAAS,UACZ;QACEC;QACAC;QACAC,SAASL;QACTM,OAAOP,IAAI,CAAC,GAAG;QACfQ,SAASR,IAAI,CAAC,IAAI;QAClBS,SAAST,IAAI,CAAC,GAAG;QACjBU,QAAQV,IAAI,CAAC,IAAI;IACnB,IACA;QACEI;QACAC;QACAC,SAASN,IAAI,CAAC,IAAI;QAClBO,OAAOP,IAAI,CAAC,IAAI;QAChBQ,SAASR,IAAI,CAAC,IAAI;QAClBS,SAAST,IAAI,CAAC,IAAI;QAClBU,QAAQV,IAAI,CAAC,IAAI;IACnB;AACN,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/theme/palette/colors/blue.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const blue: PersesColor = {\n 50: '#E7F1FC',\n 100: '#D0E3FA',\n 150: '#B8D5F7',\n 200: '#A1C7F5',\n 300: '#72ABF0',\n 400: '#438FEB',\n 500: '#1473E6',\n 600: '#105CB8',\n 700: '#0C458A',\n 800: '#082E5C',\n 850: '#062345',\n 900: '#04172E',\n 950: '#020C17',\n};\n"],"names":["blue"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,IAAI,GAAgB;AAC/B,IAAA,EAAE,EAAE,SAAS;AACb,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;CACf,CAAC"}
1
+ {"version":3,"sources":["../../../../src/theme/palette/colors/blue.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const blue: PersesColor = {\n 50: '#E7F1FC',\n 100: '#D0E3FA',\n 150: '#B8D5F7',\n 200: '#A1C7F5',\n 300: '#72ABF0',\n 400: '#438FEB',\n 500: '#1473E6',\n 600: '#105CB8',\n 700: '#0C458A',\n 800: '#082E5C',\n 850: '#062345',\n 900: '#04172E',\n 950: '#020C17',\n};\n"],"names":["blue"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,OAAoB;IAC/B,IAAI;IACJ,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;AACP,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/theme/palette/colors/common.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport const white = '#FFFFFF';\nexport const black = '#000000';\n"],"names":["white","black"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,OAAO,MAAMA,KAAK,GAAG,SAAS,CAAC;AAC/B,OAAO,MAAMC,KAAK,GAAG,SAAS,CAAC"}
1
+ {"version":3,"sources":["../../../../src/theme/palette/colors/common.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport const white = '#FFFFFF';\nexport const black = '#000000';\n"],"names":["white","black"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,OAAO,MAAMA,QAAQ,UAAU;AAC/B,OAAO,MAAMC,QAAQ,UAAU"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/theme/palette/colors/green.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const green: PersesColor = {\n 50: '#EAF9F1',\n 100: '#D5F2E3',\n 150: '#C1ECD4',\n 200: '#ACE5C6',\n 300: '#82D9AA',\n 400: '#59CC8D',\n 500: '#2FBF71',\n 600: '#26995A',\n 700: '#1C7344',\n 800: '#134C2D',\n 850: '#0E3922',\n 900: '#092617',\n 950: '#05130B',\n};\n"],"names":["green"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,KAAK,GAAgB;AAChC,IAAA,EAAE,EAAE,SAAS;AACb,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;CACf,CAAC"}
1
+ {"version":3,"sources":["../../../../src/theme/palette/colors/green.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const green: PersesColor = {\n 50: '#EAF9F1',\n 100: '#D5F2E3',\n 150: '#C1ECD4',\n 200: '#ACE5C6',\n 300: '#82D9AA',\n 400: '#59CC8D',\n 500: '#2FBF71',\n 600: '#26995A',\n 700: '#1C7344',\n 800: '#134C2D',\n 850: '#0E3922',\n 900: '#092617',\n 950: '#05130B',\n};\n"],"names":["green"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,QAAqB;IAChC,IAAI;IACJ,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;AACP,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/theme/palette/colors/grey.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const grey: PersesColor = {\n 50: '#F0F1F6',\n 100: '#E1E3ED',\n 150: '#D2D5E4',\n 200: '#C3C7DB',\n 300: '#A4ACC8',\n 400: '#8690B6',\n 500: '#717CA4',\n 600: '#535D83',\n 700: '#3E4662',\n 800: '#2A2E42',\n 850: '#1F2331',\n 900: '#151721',\n 950: '#0A0C10',\n};\n"],"names":["grey"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,IAAI,GAAgB;AAC/B,IAAA,EAAE,EAAE,SAAS;AACb,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;CACf,CAAC"}
1
+ {"version":3,"sources":["../../../../src/theme/palette/colors/grey.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const grey: PersesColor = {\n 50: '#F0F1F6',\n 100: '#E1E3ED',\n 150: '#D2D5E4',\n 200: '#C3C7DB',\n 300: '#A4ACC8',\n 400: '#8690B6',\n 500: '#717CA4',\n 600: '#535D83',\n 700: '#3E4662',\n 800: '#2A2E42',\n 850: '#1F2331',\n 900: '#151721',\n 950: '#0A0C10',\n};\n"],"names":["grey"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,OAAoB;IAC/B,IAAI;IACJ,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;AACP,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/theme/palette/colors/index.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport * from './blue';\nexport * from './common';\nexport * from './green';\nexport * from './grey';\nexport * from './orange';\nexport * from './purple';\nexport * from './red';\nexport * from './types';\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,OAAO,CAAC;AACtB,cAAc,SAAS,CAAC"}
1
+ {"version":3,"sources":["../../../../src/theme/palette/colors/index.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport * from './blue';\nexport * from './common';\nexport * from './green';\nexport * from './grey';\nexport * from './orange';\nexport * from './purple';\nexport * from './red';\nexport * from './types';\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,cAAc,SAAS;AACvB,cAAc,WAAW;AACzB,cAAc,UAAU;AACxB,cAAc,SAAS;AACvB,cAAc,WAAW;AACzB,cAAc,WAAW;AACzB,cAAc,QAAQ;AACtB,cAAc,UAAU"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/theme/palette/colors/orange.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const orange: PersesColor = {\n 50: '#FFF5E8',\n 100: '#FFECD2',\n 150: '#FFE2BB',\n 200: '#FFD9A4',\n 300: '#FFC577',\n 400: '#FFB249',\n 500: '#FF9F1C',\n 600: '#CC7F16',\n 700: '#995F11',\n 800: '#66400B',\n 850: '#4D3008',\n 900: '#332006',\n 950: '#1A1003',\n};\n"],"names":["orange"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,MAAM,GAAgB;AACjC,IAAA,EAAE,EAAE,SAAS;AACb,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;CACf,CAAC"}
1
+ {"version":3,"sources":["../../../../src/theme/palette/colors/orange.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const orange: PersesColor = {\n 50: '#FFF5E8',\n 100: '#FFECD2',\n 150: '#FFE2BB',\n 200: '#FFD9A4',\n 300: '#FFC577',\n 400: '#FFB249',\n 500: '#FF9F1C',\n 600: '#CC7F16',\n 700: '#995F11',\n 800: '#66400B',\n 850: '#4D3008',\n 900: '#332006',\n 950: '#1A1003',\n};\n"],"names":["orange"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,SAAsB;IACjC,IAAI;IACJ,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;AACP,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/theme/palette/colors/purple.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const purple: PersesColor = {\n 50: '#EFE9FD',\n 100: '#E0D2FC',\n 150: '#D0BCFA',\n 200: '#C1A6F8',\n 300: '#A179F5',\n 400: '#824DF1',\n 500: '#6320EE',\n 600: '#4F1ABE',\n 700: '#3B138F',\n 800: '#280D5F',\n 850: '#1E0A47',\n 900: '#140630',\n 950: '#0A0318',\n};\n"],"names":["purple"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,MAAM,GAAgB;AACjC,IAAA,EAAE,EAAE,SAAS;AACb,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;CACf,CAAC"}
1
+ {"version":3,"sources":["../../../../src/theme/palette/colors/purple.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const purple: PersesColor = {\n 50: '#EFE9FD',\n 100: '#E0D2FC',\n 150: '#D0BCFA',\n 200: '#C1A6F8',\n 300: '#A179F5',\n 400: '#824DF1',\n 500: '#6320EE',\n 600: '#4F1ABE',\n 700: '#3B138F',\n 800: '#280D5F',\n 850: '#1E0A47',\n 900: '#140630',\n 950: '#0A0318',\n};\n"],"names":["purple"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,SAAsB;IACjC,IAAI;IACJ,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;AACP,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/theme/palette/colors/red.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const red: PersesColor = {\n 50: '#FDEDED',\n 100: '#FBDADA',\n 150: '#F9C8C8',\n 200: '#F7B5B5',\n 300: '#F29191',\n 400: '#EE6C6C',\n 500: '#EA4747',\n 600: '#BD3939',\n 700: '#902B2B',\n 800: '#621D1D',\n 850: '#4C1616',\n 900: '#350F0F',\n 950: '#1F0808',\n};\n"],"names":["red"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,GAAG,GAAgB;AAC9B,IAAA,EAAE,EAAE,SAAS;AACb,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;AACd,IAAA,GAAG,EAAE,SAAS;CACf,CAAC"}
1
+ {"version":3,"sources":["../../../../src/theme/palette/colors/red.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PersesColor } from './types';\n\nexport const red: PersesColor = {\n 50: '#FDEDED',\n 100: '#FBDADA',\n 150: '#F9C8C8',\n 200: '#F7B5B5',\n 300: '#F29191',\n 400: '#EE6C6C',\n 500: '#EA4747',\n 600: '#BD3939',\n 700: '#902B2B',\n 800: '#621D1D',\n 850: '#4C1616',\n 900: '#350F0F',\n 950: '#1F0808',\n};\n"],"names":["red"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAO,MAAMA,MAAmB;IAC9B,IAAI;IACJ,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;AACP,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/error.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, SimplePaletteColorOptions } from '@mui/material';\nimport { red } from './colors';\n\nexport const error = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: red[500],\n dark: red[600],\n light: red[50],\n }\n : {\n main: red[400],\n dark: red[800],\n light: red[300],\n };\n};\n"],"names":["red","error","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,GAAG,QAAQ,UAAU,CAAC;AAE/B,OAAO,MAAMC,KAAK,GAAG,CAACC,IAAiB,GAAgC;IACrE,OAAOA,IAAI,KAAK,OAAO,GACnB;QACEC,IAAI,EAAEH,GAAG,CAAC,GAAG,CAAC;QACdI,IAAI,EAAEJ,GAAG,CAAC,GAAG,CAAC;QACdK,KAAK,EAAEL,GAAG,CAAC,EAAE,CAAC;KACf,GACD;QACEG,IAAI,EAAEH,GAAG,CAAC,GAAG,CAAC;QACdI,IAAI,EAAEJ,GAAG,CAAC,GAAG,CAAC;QACdK,KAAK,EAAEL,GAAG,CAAC,GAAG,CAAC;KAChB,CAAC;AACR,CAAC,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/error.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, SimplePaletteColorOptions } from '@mui/material';\nimport { red } from './colors';\n\nexport const error = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: red[500],\n dark: red[600],\n light: red[50],\n }\n : {\n main: red[400],\n dark: red[800],\n light: red[300],\n };\n};\n"],"names":["red","error","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,GAAG,QAAQ,WAAW;AAE/B,OAAO,MAAMC,QAAQ,CAACC;IACpB,OAAOA,SAAS,UACZ;QACEC,MAAMH,GAAG,CAAC,IAAI;QACdI,MAAMJ,GAAG,CAAC,IAAI;QACdK,OAAOL,GAAG,CAAC,GAAG;IAChB,IACA;QACEG,MAAMH,GAAG,CAAC,IAAI;QACdI,MAAMJ,GAAG,CAAC,IAAI;QACdK,OAAOL,GAAG,CAAC,IAAI;IACjB;AACN,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/grey.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteOptions, PaletteMode } from '@mui/material';\nimport { grey } from './colors/grey';\n\nexport const greyOption = (mode: PaletteMode): PaletteOptions['grey'] => {\n return mode === 'light'\n ? {\n 50: grey[50],\n 100: grey[100],\n 200: grey[200],\n 300: grey[300],\n 400: grey[400],\n 500: grey[500],\n 600: grey[600],\n 700: grey[700],\n 800: grey[800],\n 900: grey[900],\n 950: grey[950],\n }\n : // Reverse greys from darkest to lightest for Dark mode\n {\n 50: grey[950],\n 100: grey[900],\n 200: grey[800],\n 300: grey[700],\n 400: grey[600],\n 500: grey[500],\n 600: grey[400],\n 700: grey[300],\n 800: grey[200],\n 900: grey[100],\n 950: grey[50],\n };\n};\n"],"names":["grey","greyOption","mode"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,QAAQ,eAAe,CAAC;AAErC,OAAO,MAAMC,UAAU,GAAG,CAACC,IAAiB,GAA6B;IACvE,OAAOA,IAAI,KAAK,OAAO,GACnB;AACE,QAAA,EAAE,EAAEF,IAAI,CAAC,EAAE,CAAC;AACZ,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;KACf,GAED;AACE,QAAA,EAAE,EAAEA,IAAI,CAAC,GAAG,CAAC;AACb,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,GAAG,CAAC;AACd,QAAA,GAAG,EAAEA,IAAI,CAAC,EAAE,CAAC;KACd,CAAC;AACR,CAAC,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/grey.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteOptions, PaletteMode } from '@mui/material';\nimport { grey } from './colors/grey';\n\nexport const greyOption = (mode: PaletteMode): PaletteOptions['grey'] => {\n return mode === 'light'\n ? {\n 50: grey[50],\n 100: grey[100],\n 200: grey[200],\n 300: grey[300],\n 400: grey[400],\n 500: grey[500],\n 600: grey[600],\n 700: grey[700],\n 800: grey[800],\n 900: grey[900],\n 950: grey[950],\n }\n : // Reverse greys from darkest to lightest for Dark mode\n {\n 50: grey[950],\n 100: grey[900],\n 200: grey[800],\n 300: grey[700],\n 400: grey[600],\n 500: grey[500],\n 600: grey[400],\n 700: grey[300],\n 800: grey[200],\n 900: grey[100],\n 950: grey[50],\n };\n};\n"],"names":["grey","greyOption","mode"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,QAAQ,gBAAgB;AAErC,OAAO,MAAMC,aAAa,CAACC;IACzB,OAAOA,SAAS,UACZ;QACE,IAAIF,IAAI,CAAC,GAAG;QACZ,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;IAChB,IAEA;QACE,IAAIA,IAAI,CAAC,IAAI;QACb,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,IAAI;QACd,KAAKA,IAAI,CAAC,GAAG;IACf;AACN,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/index.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport * from './palette-options';\nexport type { PersesColor, HexColor } from './colors';\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,cAAc,mBAAmB,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/index.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport * from './palette-options';\nexport type { PersesColor, HexColor } from './colors';\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,cAAc,oBAAoB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/palette-options.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, PaletteOptions } from '@mui/material';\nimport { text } from './text';\nimport { background } from './background';\nimport { greyOption } from './grey';\nimport { black, white } from './colors/common';\nimport { primary } from './primary';\nimport { secondary } from './secondary';\nimport { blue, green, grey, orange, purple, red } from './colors';\nimport { error } from './error';\nimport { success } from './success';\nimport { warning } from './warning';\n\n/**\n * Returns the MUI PaletteOptions for the given mode.\n */\nexport function getPaletteOptions(mode: PaletteMode): PaletteOptions {\n // Palette options should be split out into their own files with functions\n // for creating the option values based on light/dark mode\n return {\n mode,\n primary: primary(mode),\n secondary: secondary(mode),\n grey: greyOption(mode),\n background: background(mode),\n text: text(mode),\n error: error(mode),\n warning: warning(mode),\n info: primary(mode),\n success: success(mode),\n common: {\n white,\n black,\n },\n\n // custom colors\n designSystem: {\n blue,\n green,\n grey,\n orange,\n purple,\n red,\n },\n };\n}\n"],"names":["text","background","greyOption","black","white","primary","secondary","blue","green","grey","orange","purple","red","error","success","warning","getPaletteOptions","mode","info","common","designSystem"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,QAAQ,QAAQ,CAAC;AAC9B,SAASC,UAAU,QAAQ,cAAc,CAAC;AAC1C,SAASC,UAAU,QAAQ,QAAQ,CAAC;AACpC,SAASC,KAAK,EAAEC,KAAK,QAAQ,iBAAiB,CAAC;AAC/C,SAASC,OAAO,QAAQ,WAAW,CAAC;AACpC,SAASC,SAAS,QAAQ,aAAa,CAAC;AACxC,SAASC,IAAI,EAAEC,KAAK,EAAEC,IAAI,EAAEC,MAAM,EAAEC,MAAM,EAAEC,GAAG,QAAQ,UAAU,CAAC;AAClE,SAASC,KAAK,QAAQ,SAAS,CAAC;AAChC,SAASC,OAAO,QAAQ,WAAW,CAAC;AACpC,SAASC,OAAO,QAAQ,WAAW,CAAC;AAEpC;;CAEC,GACD,OAAO,SAASC,iBAAiB,CAACC,IAAiB,EAAkB;IACnE,0EAA0E;IAC1E,0DAA0D;IAC1D,OAAO;QACLA,IAAI;QACJZ,OAAO,EAAEA,OAAO,CAACY,IAAI,CAAC;QACtBX,SAAS,EAAEA,SAAS,CAACW,IAAI,CAAC;QAC1BR,IAAI,EAAEP,UAAU,CAACe,IAAI,CAAC;QACtBhB,UAAU,EAAEA,UAAU,CAACgB,IAAI,CAAC;QAC5BjB,IAAI,EAAEA,IAAI,CAACiB,IAAI,CAAC;QAChBJ,KAAK,EAAEA,KAAK,CAACI,IAAI,CAAC;QAClBF,OAAO,EAAEA,OAAO,CAACE,IAAI,CAAC;QACtBC,IAAI,EAAEb,OAAO,CAACY,IAAI,CAAC;QACnBH,OAAO,EAAEA,OAAO,CAACG,IAAI,CAAC;QACtBE,MAAM,EAAE;YACNf,KAAK;YACLD,KAAK;SACN;QAED,gBAAgB;QAChBiB,YAAY,EAAE;YACZb,IAAI;YACJC,KAAK;YACLC,IAAI;YACJC,MAAM;YACNC,MAAM;YACNC,GAAG;SACJ;KACF,CAAC;AACJ,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/palette-options.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, PaletteOptions } from '@mui/material';\nimport { text } from './text';\nimport { background } from './background';\nimport { greyOption } from './grey';\nimport { black, white } from './colors/common';\nimport { primary } from './primary';\nimport { secondary } from './secondary';\nimport { blue, green, grey, orange, purple, red } from './colors';\nimport { error } from './error';\nimport { success } from './success';\nimport { warning } from './warning';\n\n/**\n * Returns the MUI PaletteOptions for the given mode.\n */\nexport function getPaletteOptions(mode: PaletteMode): PaletteOptions {\n // Palette options should be split out into their own files with functions\n // for creating the option values based on light/dark mode\n return {\n mode,\n primary: primary(mode),\n secondary: secondary(mode),\n grey: greyOption(mode),\n background: background(mode),\n text: text(mode),\n error: error(mode),\n warning: warning(mode),\n info: primary(mode),\n success: success(mode),\n common: {\n white,\n black,\n },\n\n // custom colors\n designSystem: {\n blue,\n green,\n grey,\n orange,\n purple,\n red,\n },\n };\n}\n"],"names":["text","background","greyOption","black","white","primary","secondary","blue","green","grey","orange","purple","red","error","success","warning","getPaletteOptions","mode","info","common","designSystem"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,QAAQ,SAAS;AAC9B,SAASC,UAAU,QAAQ,eAAe;AAC1C,SAASC,UAAU,QAAQ,SAAS;AACpC,SAASC,KAAK,EAAEC,KAAK,QAAQ,kBAAkB;AAC/C,SAASC,OAAO,QAAQ,YAAY;AACpC,SAASC,SAAS,QAAQ,cAAc;AACxC,SAASC,IAAI,EAAEC,KAAK,EAAEC,IAAI,EAAEC,MAAM,EAAEC,MAAM,EAAEC,GAAG,QAAQ,WAAW;AAClE,SAASC,KAAK,QAAQ,UAAU;AAChC,SAASC,OAAO,QAAQ,YAAY;AACpC,SAASC,OAAO,QAAQ,YAAY;AAEpC;;CAEC,GACD,OAAO,SAASC,kBAAkBC,IAAiB;IACjD,0EAA0E;IAC1E,0DAA0D;IAC1D,OAAO;QACLA;QACAZ,SAASA,QAAQY;QACjBX,WAAWA,UAAUW;QACrBR,MAAMP,WAAWe;QACjBhB,YAAYA,WAAWgB;QACvBjB,MAAMA,KAAKiB;QACXJ,OAAOA,MAAMI;QACbF,SAASA,QAAQE;QACjBC,MAAMb,QAAQY;QACdH,SAASA,QAAQG;QACjBE,QAAQ;YACNf;YACAD;QACF;QAEA,gBAAgB;QAChBiB,cAAc;YACZb;YACAC;YACAC;YACAC;YACAC;YACAC;QACF;IACF;AACF"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/primary.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, SimplePaletteColorOptions } from '@mui/material';\nimport { blue } from './colors';\n\nexport const primary = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: blue[500],\n dark: blue[600],\n light: blue[50],\n }\n : {\n main: blue[400],\n dark: blue[800],\n light: blue[200],\n };\n};\n"],"names":["blue","primary","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,QAAQ,UAAU,CAAC;AAEhC,OAAO,MAAMC,OAAO,GAAG,CAACC,IAAiB,GAAgC;IACvE,OAAOA,IAAI,KAAK,OAAO,GACnB;QACEC,IAAI,EAAEH,IAAI,CAAC,GAAG,CAAC;QACfI,IAAI,EAAEJ,IAAI,CAAC,GAAG,CAAC;QACfK,KAAK,EAAEL,IAAI,CAAC,EAAE,CAAC;KAChB,GACD;QACEG,IAAI,EAAEH,IAAI,CAAC,GAAG,CAAC;QACfI,IAAI,EAAEJ,IAAI,CAAC,GAAG,CAAC;QACfK,KAAK,EAAEL,IAAI,CAAC,GAAG,CAAC;KACjB,CAAC;AACR,CAAC,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/primary.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, SimplePaletteColorOptions } from '@mui/material';\nimport { blue } from './colors';\n\nexport const primary = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: blue[500],\n dark: blue[600],\n light: blue[50],\n }\n : {\n main: blue[400],\n dark: blue[800],\n light: blue[200],\n };\n};\n"],"names":["blue","primary","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,QAAQ,WAAW;AAEhC,OAAO,MAAMC,UAAU,CAACC;IACtB,OAAOA,SAAS,UACZ;QACEC,MAAMH,IAAI,CAAC,IAAI;QACfI,MAAMJ,IAAI,CAAC,IAAI;QACfK,OAAOL,IAAI,CAAC,GAAG;IACjB,IACA;QACEG,MAAMH,IAAI,CAAC,IAAI;QACfI,MAAMJ,IAAI,CAAC,IAAI;QACfK,OAAOL,IAAI,CAAC,IAAI;IAClB;AACN,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/secondary.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { SimplePaletteColorOptions, PaletteMode } from '@mui/material';\nimport { grey, white } from './colors';\n\nexport const secondary = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: grey[600],\n dark: grey[900],\n light: grey[100],\n }\n : {\n main: white,\n dark: white,\n light: white,\n };\n};\n"],"names":["grey","white","secondary","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,EAAEC,KAAK,QAAQ,UAAU,CAAC;AAEvC,OAAO,MAAMC,SAAS,GAAG,CAACC,IAAiB,GAAgC;IACzE,OAAOA,IAAI,KAAK,OAAO,GACnB;QACEC,IAAI,EAAEJ,IAAI,CAAC,GAAG,CAAC;QACfK,IAAI,EAAEL,IAAI,CAAC,GAAG,CAAC;QACfM,KAAK,EAAEN,IAAI,CAAC,GAAG,CAAC;KACjB,GACD;QACEI,IAAI,EAAEH,KAAK;QACXI,IAAI,EAAEJ,KAAK;QACXK,KAAK,EAAEL,KAAK;KACb,CAAC;AACR,CAAC,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/secondary.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { SimplePaletteColorOptions, PaletteMode } from '@mui/material';\nimport { grey, white } from './colors';\n\nexport const secondary = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: grey[600],\n dark: grey[900],\n light: grey[100],\n }\n : {\n main: white,\n dark: white,\n light: white,\n };\n};\n"],"names":["grey","white","secondary","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,EAAEC,KAAK,QAAQ,WAAW;AAEvC,OAAO,MAAMC,YAAY,CAACC;IACxB,OAAOA,SAAS,UACZ;QACEC,MAAMJ,IAAI,CAAC,IAAI;QACfK,MAAML,IAAI,CAAC,IAAI;QACfM,OAAON,IAAI,CAAC,IAAI;IAClB,IACA;QACEI,MAAMH;QACNI,MAAMJ;QACNK,OAAOL;IACT;AACN,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/success.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, SimplePaletteColorOptions } from '@mui/material';\nimport { green } from './colors';\n\nexport const success = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: green[500],\n dark: green[700],\n light: green[50],\n }\n : {\n main: green[400],\n dark: green[800],\n light: green[300],\n };\n};\n"],"names":["green","success","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,KAAK,QAAQ,UAAU,CAAC;AAEjC,OAAO,MAAMC,OAAO,GAAG,CAACC,IAAiB,GAAgC;IACvE,OAAOA,IAAI,KAAK,OAAO,GACnB;QACEC,IAAI,EAAEH,KAAK,CAAC,GAAG,CAAC;QAChBI,IAAI,EAAEJ,KAAK,CAAC,GAAG,CAAC;QAChBK,KAAK,EAAEL,KAAK,CAAC,EAAE,CAAC;KACjB,GACD;QACEG,IAAI,EAAEH,KAAK,CAAC,GAAG,CAAC;QAChBI,IAAI,EAAEJ,KAAK,CAAC,GAAG,CAAC;QAChBK,KAAK,EAAEL,KAAK,CAAC,GAAG,CAAC;KAClB,CAAC;AACR,CAAC,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/success.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, SimplePaletteColorOptions } from '@mui/material';\nimport { green } from './colors';\n\nexport const success = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: green[500],\n dark: green[700],\n light: green[50],\n }\n : {\n main: green[400],\n dark: green[800],\n light: green[300],\n };\n};\n"],"names":["green","success","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,KAAK,QAAQ,WAAW;AAEjC,OAAO,MAAMC,UAAU,CAACC;IACtB,OAAOA,SAAS,UACZ;QACEC,MAAMH,KAAK,CAAC,IAAI;QAChBI,MAAMJ,KAAK,CAAC,IAAI;QAChBK,OAAOL,KAAK,CAAC,GAAG;IAClB,IACA;QACEG,MAAMH,KAAK,CAAC,IAAI;QAChBI,MAAMJ,KAAK,CAAC,IAAI;QAChBK,OAAOL,KAAK,CAAC,IAAI;IACnB;AACN,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/text.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteOptions, PaletteMode } from '@mui/material';\nimport { grey, white, blue } from './colors';\n\nexport const text = (mode: PaletteMode): PaletteOptions['text'] => {\n const navigation = grey[800];\n const accent = grey[300];\n return mode === 'light'\n ? {\n navigation,\n accent,\n primary: grey[800],\n secondary: grey[700],\n disabled: grey[300],\n link: blue[500],\n linkHover: blue[600],\n }\n : {\n navigation,\n accent,\n primary: white,\n secondary: grey[50],\n disabled: grey[600],\n link: blue[400],\n linkHover: blue[500],\n };\n};\n"],"names":["grey","white","blue","text","mode","navigation","accent","primary","secondary","disabled","link","linkHover"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,EAAEC,KAAK,EAAEC,IAAI,QAAQ,UAAU,CAAC;AAE7C,OAAO,MAAMC,IAAI,GAAG,CAACC,IAAiB,GAA6B;IACjE,MAAMC,UAAU,GAAGL,IAAI,CAAC,GAAG,CAAC,AAAC;IAC7B,MAAMM,MAAM,GAAGN,IAAI,CAAC,GAAG,CAAC,AAAC;IACzB,OAAOI,IAAI,KAAK,OAAO,GACnB;QACEC,UAAU;QACVC,MAAM;QACNC,OAAO,EAAEP,IAAI,CAAC,GAAG,CAAC;QAClBQ,SAAS,EAAER,IAAI,CAAC,GAAG,CAAC;QACpBS,QAAQ,EAAET,IAAI,CAAC,GAAG,CAAC;QACnBU,IAAI,EAAER,IAAI,CAAC,GAAG,CAAC;QACfS,SAAS,EAAET,IAAI,CAAC,GAAG,CAAC;KACrB,GACD;QACEG,UAAU;QACVC,MAAM;QACNC,OAAO,EAAEN,KAAK;QACdO,SAAS,EAAER,IAAI,CAAC,EAAE,CAAC;QACnBS,QAAQ,EAAET,IAAI,CAAC,GAAG,CAAC;QACnBU,IAAI,EAAER,IAAI,CAAC,GAAG,CAAC;QACfS,SAAS,EAAET,IAAI,CAAC,GAAG,CAAC;KACrB,CAAC;AACR,CAAC,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/text.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteOptions, PaletteMode } from '@mui/material';\nimport { grey, white, blue } from './colors';\n\nexport const text = (mode: PaletteMode): PaletteOptions['text'] => {\n const navigation = grey[800];\n const accent = grey[300];\n return mode === 'light'\n ? {\n navigation,\n accent,\n primary: grey[800],\n secondary: grey[700],\n disabled: grey[300],\n link: blue[500],\n linkHover: blue[600],\n }\n : {\n navigation,\n accent,\n primary: white,\n secondary: grey[50],\n disabled: grey[600],\n link: blue[400],\n linkHover: blue[500],\n };\n};\n"],"names":["grey","white","blue","text","mode","navigation","accent","primary","secondary","disabled","link","linkHover"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,IAAI,EAAEC,KAAK,EAAEC,IAAI,QAAQ,WAAW;AAE7C,OAAO,MAAMC,OAAO,CAACC;IACnB,MAAMC,aAAaL,IAAI,CAAC,IAAI;IAC5B,MAAMM,SAASN,IAAI,CAAC,IAAI;IACxB,OAAOI,SAAS,UACZ;QACEC;QACAC;QACAC,SAASP,IAAI,CAAC,IAAI;QAClBQ,WAAWR,IAAI,CAAC,IAAI;QACpBS,UAAUT,IAAI,CAAC,IAAI;QACnBU,MAAMR,IAAI,CAAC,IAAI;QACfS,WAAWT,IAAI,CAAC,IAAI;IACtB,IACA;QACEG;QACAC;QACAC,SAASN;QACTO,WAAWR,IAAI,CAAC,GAAG;QACnBS,UAAUT,IAAI,CAAC,IAAI;QACnBU,MAAMR,IAAI,CAAC,IAAI;QACfS,WAAWT,IAAI,CAAC,IAAI;IACtB;AACN,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/theme/palette/warning.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, SimplePaletteColorOptions } from '@mui/material';\nimport { orange } from './colors';\n\nexport const warning = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: orange[500],\n dark: orange[700],\n light: orange[50],\n }\n : {\n main: orange[400],\n dark: orange[800],\n light: orange[300],\n };\n};\n"],"names":["orange","warning","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,MAAM,QAAQ,UAAU,CAAC;AAElC,OAAO,MAAMC,OAAO,GAAG,CAACC,IAAiB,GAAgC;IACvE,OAAOA,IAAI,KAAK,OAAO,GACnB;QACEC,IAAI,EAAEH,MAAM,CAAC,GAAG,CAAC;QACjBI,IAAI,EAAEJ,MAAM,CAAC,GAAG,CAAC;QACjBK,KAAK,EAAEL,MAAM,CAAC,EAAE,CAAC;KAClB,GACD;QACEG,IAAI,EAAEH,MAAM,CAAC,GAAG,CAAC;QACjBI,IAAI,EAAEJ,MAAM,CAAC,GAAG,CAAC;QACjBK,KAAK,EAAEL,MAAM,CAAC,GAAG,CAAC;KACnB,CAAC;AACR,CAAC,CAAC"}
1
+ {"version":3,"sources":["../../../src/theme/palette/warning.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { PaletteMode, SimplePaletteColorOptions } from '@mui/material';\nimport { orange } from './colors';\n\nexport const warning = (mode: PaletteMode): SimplePaletteColorOptions => {\n return mode === 'light'\n ? {\n main: orange[500],\n dark: orange[700],\n light: orange[50],\n }\n : {\n main: orange[400],\n dark: orange[800],\n light: orange[300],\n };\n};\n"],"names":["orange","warning","mode","main","dark","light"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,MAAM,QAAQ,WAAW;AAElC,OAAO,MAAMC,UAAU,CAACC;IACtB,OAAOA,SAAS,UACZ;QACEC,MAAMH,MAAM,CAAC,IAAI;QACjBI,MAAMJ,MAAM,CAAC,IAAI;QACjBK,OAAOL,MAAM,CAAC,GAAG;IACnB,IACA;QACEG,MAAMH,MAAM,CAAC,IAAI;QACjBI,MAAMJ,MAAM,CAAC,IAAI;QACjBK,OAAOL,MAAM,CAAC,IAAI;IACpB;AACN,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/theme/theme.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { createTheme, PaletteMode, ThemeOptions, Theme } from '@mui/material';\nimport { MuiAlert } from './component-overrides/alert';\nimport { MuiPaper } from './component-overrides/paper';\nimport { getPaletteOptions } from './palette/palette-options';\nimport { typography } from './typography';\n\nconst getModalBackgroundStyle = ({ theme }: { theme: Omit<Theme, 'components'> }) => {\n const backgroundStyle =\n theme.palette.mode === 'light'\n ? {}\n : {\n backgroundImage: 'unset',\n backgroundColor: theme.palette.designSystem.grey[800],\n };\n return {\n ...backgroundStyle,\n };\n};\n\n/**\n * Gets theme used by all components for the provided mode. For more details, see:\n * - Base colors, typography, sizing - go/chrono-ui-theme\n * - Material UI defaults: https://material-ui.com/customization/default-theme/\n * - Material UI variables: https://material-ui.com/customization/theming/#theme-configuration-variables\n * - Material UI global overrides and default props: https://material-ui.com/customization/globals/#css\n *\n * Need to reinstantiate the theme everytime to support switching between light and dark themes\n * https://github.com/mui-org/material-ui/issues/18831\n */\nexport function getTheme(mode: PaletteMode) {\n const theme = createTheme({\n palette: getPaletteOptions(mode),\n typography,\n mixins: {},\n components,\n });\n return theme;\n}\n\n// Overrides for component default prop values and styles go here\nconst components: ThemeOptions['components'] = {\n MuiAlert,\n MuiFormControl: {\n defaultProps: {\n size: 'small',\n },\n },\n MuiPaper,\n MuiTextField: {\n defaultProps: {\n size: 'small',\n },\n },\n MuiDrawer: {\n styleOverrides: {\n paper: getModalBackgroundStyle,\n },\n },\n MuiDialog: {\n styleOverrides: {\n paper: getModalBackgroundStyle,\n },\n },\n MuiPopover: {\n styleOverrides: {\n paper: getModalBackgroundStyle,\n },\n },\n};\n"],"names":["createTheme","MuiAlert","MuiPaper","getPaletteOptions","typography","getModalBackgroundStyle","theme","backgroundStyle","palette","mode","backgroundImage","backgroundColor","designSystem","grey","getTheme","mixins","components","MuiFormControl","defaultProps","size","MuiTextField","MuiDrawer","styleOverrides","paper","MuiDialog","MuiPopover"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,WAAW,QAA0C,eAAe,CAAC;AAC9E,SAASC,QAAQ,QAAQ,6BAA6B,CAAC;AACvD,SAASC,QAAQ,QAAQ,6BAA6B,CAAC;AACvD,SAASC,iBAAiB,QAAQ,2BAA2B,CAAC;AAC9D,SAASC,UAAU,QAAQ,cAAc,CAAC;AAE1C,MAAMC,uBAAuB,GAAG,CAAC,EAAEC,KAAK,CAAA,EAAwC,GAAK;IACnF,MAAMC,eAAe,GACnBD,KAAK,CAACE,OAAO,CAACC,IAAI,KAAK,OAAO,GAC1B,EAAE,GACF;QACEC,eAAe,EAAE,OAAO;QACxBC,eAAe,EAAEL,KAAK,CAACE,OAAO,CAACI,YAAY,CAACC,IAAI,CAAC,GAAG,CAAC;KACtD,AAAC;IACR,OAAO;QACL,GAAGN,eAAe;KACnB,CAAC;AACJ,CAAC,AAAC;AAEF;;;;;;;;;CASC,GACD,OAAO,SAASO,QAAQ,CAACL,IAAiB,EAAE;IAC1C,MAAMH,KAAK,GAAGN,WAAW,CAAC;QACxBQ,OAAO,EAAEL,iBAAiB,CAACM,IAAI,CAAC;QAChCL,UAAU;QACVW,MAAM,EAAE,EAAE;QACVC,UAAU;KACX,CAAC,AAAC;IACH,OAAOV,KAAK,CAAC;AACf,CAAC;AAED,iEAAiE;AACjE,MAAMU,UAAU,GAA+B;IAC7Cf,QAAQ;IACRgB,cAAc,EAAE;QACdC,YAAY,EAAE;YACZC,IAAI,EAAE,OAAO;SACd;KACF;IACDjB,QAAQ;IACRkB,YAAY,EAAE;QACZF,YAAY,EAAE;YACZC,IAAI,EAAE,OAAO;SACd;KACF;IACDE,SAAS,EAAE;QACTC,cAAc,EAAE;YACdC,KAAK,EAAElB,uBAAuB;SAC/B;KACF;IACDmB,SAAS,EAAE;QACTF,cAAc,EAAE;YACdC,KAAK,EAAElB,uBAAuB;SAC/B;KACF;IACDoB,UAAU,EAAE;QACVH,cAAc,EAAE;YACdC,KAAK,EAAElB,uBAAuB;SAC/B;KACF;CACF,AAAC"}
1
+ {"version":3,"sources":["../../src/theme/theme.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { createTheme, PaletteMode, ThemeOptions, Theme } from '@mui/material';\nimport { MuiAlert } from './component-overrides/alert';\nimport { MuiPaper } from './component-overrides/paper';\nimport { getPaletteOptions } from './palette/palette-options';\nimport { typography } from './typography';\n\nconst getModalBackgroundStyle = ({ theme }: { theme: Omit<Theme, 'components'> }) => {\n const backgroundStyle =\n theme.palette.mode === 'light'\n ? {}\n : {\n backgroundImage: 'unset',\n backgroundColor: theme.palette.designSystem.grey[800],\n };\n return {\n ...backgroundStyle,\n };\n};\n\n/**\n * Gets theme used by all components for the provided mode. For more details, see:\n * - Base colors, typography, sizing - go/chrono-ui-theme\n * - Material UI defaults: https://material-ui.com/customization/default-theme/\n * - Material UI variables: https://material-ui.com/customization/theming/#theme-configuration-variables\n * - Material UI global overrides and default props: https://material-ui.com/customization/globals/#css\n *\n * Need to reinstantiate the theme everytime to support switching between light and dark themes\n * https://github.com/mui-org/material-ui/issues/18831\n */\nexport function getTheme(mode: PaletteMode) {\n const theme = createTheme({\n palette: getPaletteOptions(mode),\n typography,\n mixins: {},\n components,\n });\n return theme;\n}\n\n// Overrides for component default prop values and styles go here\nconst components: ThemeOptions['components'] = {\n MuiAlert,\n MuiFormControl: {\n defaultProps: {\n size: 'small',\n },\n },\n MuiPaper,\n MuiTextField: {\n defaultProps: {\n size: 'small',\n },\n },\n MuiDrawer: {\n styleOverrides: {\n paper: getModalBackgroundStyle,\n },\n },\n MuiDialog: {\n styleOverrides: {\n paper: getModalBackgroundStyle,\n },\n },\n MuiPopover: {\n styleOverrides: {\n paper: getModalBackgroundStyle,\n },\n },\n};\n"],"names":["createTheme","MuiAlert","MuiPaper","getPaletteOptions","typography","getModalBackgroundStyle","theme","backgroundStyle","palette","mode","backgroundImage","backgroundColor","designSystem","grey","getTheme","mixins","components","MuiFormControl","defaultProps","size","MuiTextField","MuiDrawer","styleOverrides","paper","MuiDialog","MuiPopover"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,WAAW,QAA0C,gBAAgB;AAC9E,SAASC,QAAQ,QAAQ,8BAA8B;AACvD,SAASC,QAAQ,QAAQ,8BAA8B;AACvD,SAASC,iBAAiB,QAAQ,4BAA4B;AAC9D,SAASC,UAAU,QAAQ,eAAe;AAE1C,MAAMC,0BAA0B,CAAC,EAAEC,MAAK,EAAwC;IAC9E,MAAMC,kBACJD,MAAME,QAAQC,SAAS,UACnB,CAAC,IACD;QACEC,iBAAiB;QACjBC,iBAAiBL,MAAME,QAAQI,aAAaC,IAAI,CAAC,IAAI;IACvD;IACN,OAAO;QACL,GAAGN,eAAe;IACpB;AACF;AAEA;;;;;;;;;CASC,GACD,OAAO,SAASO,SAASL,IAAiB;IACxC,MAAMH,QAAQN,YAAY;QACxBQ,SAASL,kBAAkBM;QAC3BL;QACAW,QAAQ,CAAC;QACTC;IACF;IACA,OAAOV;AACT;AAEA,iEAAiE;AACjE,MAAMU,aAAyC;IAC7Cf;IACAgB,gBAAgB;QACdC,cAAc;YACZC,MAAM;QACR;IACF;IACAjB;IACAkB,cAAc;QACZF,cAAc;YACZC,MAAM;QACR;IACF;IACAE,WAAW;QACTC,gBAAgB;YACdC,OAAOlB;QACT;IACF;IACAmB,WAAW;QACTF,gBAAgB;YACdC,OAAOlB;QACT;IACF;IACAoB,YAAY;QACVH,gBAAgB;YACdC,OAAOlB;QACT;IACF;AACF"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/theme/typography.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport '@fontsource/lato/300.css';\nimport '@fontsource/lato/400.css';\nimport '@fontsource/lato/700.css';\nimport '@fontsource/lato/900.css';\nimport { ThemeOptions } from '@mui/material';\n\n// Font weights need to correspond with the imports at the top of the file\n// (Lato supports 100, 300, 400, 700, 900)\nconst fontWeightLight = 300;\nconst fontWeightRegular = 400;\nconst fontWeightMedium = 700;\nconst fontWeightBold = 900;\n\n/**\n * Theme typography options that are the same across both the dark and light themes.\n */\nexport const typography: ThemeOptions['typography'] = {\n fontFamily: '\"Lato\", sans-serif',\n\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold,\n\n h1: {\n fontSize: '1.5rem', // 24px\n fontWeight: fontWeightMedium,\n lineHeight: '32px',\n },\n h2: {\n fontSize: '1.25rem', // 20px\n fontWeight: fontWeightMedium,\n lineHeight: '28px',\n },\n h3: {\n fontSize: '1rem', // 16px\n fontWeight: fontWeightMedium,\n lineHeight: '24px',\n },\n h4: {\n fontSize: '0.875rem', // 14px\n fontWeight: fontWeightMedium,\n lineHeight: '22px',\n },\n h5: undefined,\n h6: undefined,\n\n body1: {\n fontSize: '0.875rem', // 14px\n fontWeight: fontWeightRegular,\n lineHeight: '20px',\n },\n body2: {\n fontSize: '0.75rem', // 12px\n fontWeight: fontWeightRegular,\n lineHeight: '18px',\n },\n subtitle1: {\n fontSize: '1rem', // 16px\n fontWeight: fontWeightRegular,\n lineHeight: '24px',\n letterSpacing: '0.02rem',\n },\n subtitle2: {\n fontSize: '0.875rem', // 14px\n fontWeight: fontWeightMedium,\n lineHeight: '22px',\n letterSpacing: '0.03rem',\n textTransform: 'uppercase',\n },\n\n button: {\n // 14px\n fontSize: '0.875rem',\n fontWeight: fontWeightMedium,\n // 20 px\n lineHeight: '1.25rem',\n textTransform: 'none',\n letterSpacing: '0.03rem',\n },\n caption: {\n fontSize: '0.6875rem', // 11px\n fontWeight: fontWeightRegular,\n lineHeight: '16px',\n },\n};\n"],"names":["fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","typography","fontFamily","h1","fontSize","fontWeight","lineHeight","h2","h3","h4","h5","undefined","h6","body1","body2","subtitle1","letterSpacing","subtitle2","textTransform","button","caption"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,OAAO,0BAA0B,CAAC;AAClC,OAAO,0BAA0B,CAAC;AAClC,OAAO,0BAA0B,CAAC;AAClC,OAAO,0BAA0B,CAAC;AAGlC,0EAA0E;AAC1E,0CAA0C;AAC1C,MAAMA,eAAe,GAAG,GAAG,AAAC;AAC5B,MAAMC,iBAAiB,GAAG,GAAG,AAAC;AAC9B,MAAMC,gBAAgB,GAAG,GAAG,AAAC;AAC7B,MAAMC,cAAc,GAAG,GAAG,AAAC;AAE3B;;CAEC,GACD,OAAO,MAAMC,UAAU,GAA+B;IACpDC,UAAU,EAAE,oBAAoB;IAEhCL,eAAe;IACfC,iBAAiB;IACjBC,gBAAgB;IAChBC,cAAc;IAEdG,EAAE,EAAE;QACFC,QAAQ,EAAE,QAAQ;QAClBC,UAAU,EAAEN,gBAAgB;QAC5BO,UAAU,EAAE,MAAM;KACnB;IACDC,EAAE,EAAE;QACFH,QAAQ,EAAE,SAAS;QACnBC,UAAU,EAAEN,gBAAgB;QAC5BO,UAAU,EAAE,MAAM;KACnB;IACDE,EAAE,EAAE;QACFJ,QAAQ,EAAE,MAAM;QAChBC,UAAU,EAAEN,gBAAgB;QAC5BO,UAAU,EAAE,MAAM;KACnB;IACDG,EAAE,EAAE;QACFL,QAAQ,EAAE,UAAU;QACpBC,UAAU,EAAEN,gBAAgB;QAC5BO,UAAU,EAAE,MAAM;KACnB;IACDI,EAAE,EAAEC,SAAS;IACbC,EAAE,EAAED,SAAS;IAEbE,KAAK,EAAE;QACLT,QAAQ,EAAE,UAAU;QACpBC,UAAU,EAAEP,iBAAiB;QAC7BQ,UAAU,EAAE,MAAM;KACnB;IACDQ,KAAK,EAAE;QACLV,QAAQ,EAAE,SAAS;QACnBC,UAAU,EAAEP,iBAAiB;QAC7BQ,UAAU,EAAE,MAAM;KACnB;IACDS,SAAS,EAAE;QACTX,QAAQ,EAAE,MAAM;QAChBC,UAAU,EAAEP,iBAAiB;QAC7BQ,UAAU,EAAE,MAAM;QAClBU,aAAa,EAAE,SAAS;KACzB;IACDC,SAAS,EAAE;QACTb,QAAQ,EAAE,UAAU;QACpBC,UAAU,EAAEN,gBAAgB;QAC5BO,UAAU,EAAE,MAAM;QAClBU,aAAa,EAAE,SAAS;QACxBE,aAAa,EAAE,WAAW;KAC3B;IAEDC,MAAM,EAAE;QACN,OAAO;QACPf,QAAQ,EAAE,UAAU;QACpBC,UAAU,EAAEN,gBAAgB;QAC5B,QAAQ;QACRO,UAAU,EAAE,SAAS;QACrBY,aAAa,EAAE,MAAM;QACrBF,aAAa,EAAE,SAAS;KACzB;IACDI,OAAO,EAAE;QACPhB,QAAQ,EAAE,WAAW;QACrBC,UAAU,EAAEP,iBAAiB;QAC7BQ,UAAU,EAAE,MAAM;KACnB;CACF,CAAC"}
1
+ {"version":3,"sources":["../../src/theme/typography.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport '@fontsource/lato/300.css';\nimport '@fontsource/lato/400.css';\nimport '@fontsource/lato/700.css';\nimport '@fontsource/lato/900.css';\nimport { ThemeOptions } from '@mui/material';\n\n// Font weights need to correspond with the imports at the top of the file\n// (Lato supports 100, 300, 400, 700, 900)\nconst fontWeightLight = 300;\nconst fontWeightRegular = 400;\nconst fontWeightMedium = 700;\nconst fontWeightBold = 900;\n\n/**\n * Theme typography options that are the same across both the dark and light themes.\n */\nexport const typography: ThemeOptions['typography'] = {\n fontFamily: '\"Lato\", sans-serif',\n\n fontWeightLight,\n fontWeightRegular,\n fontWeightMedium,\n fontWeightBold,\n\n h1: {\n fontSize: '1.5rem', // 24px\n fontWeight: fontWeightMedium,\n lineHeight: '32px',\n },\n h2: {\n fontSize: '1.25rem', // 20px\n fontWeight: fontWeightMedium,\n lineHeight: '28px',\n },\n h3: {\n fontSize: '1rem', // 16px\n fontWeight: fontWeightMedium,\n lineHeight: '24px',\n },\n h4: {\n fontSize: '0.875rem', // 14px\n fontWeight: fontWeightMedium,\n lineHeight: '22px',\n },\n h5: undefined,\n h6: undefined,\n\n body1: {\n fontSize: '0.875rem', // 14px\n fontWeight: fontWeightRegular,\n lineHeight: '20px',\n },\n body2: {\n fontSize: '0.75rem', // 12px\n fontWeight: fontWeightRegular,\n lineHeight: '18px',\n },\n subtitle1: {\n fontSize: '1rem', // 16px\n fontWeight: fontWeightRegular,\n lineHeight: '24px',\n letterSpacing: '0.02rem',\n },\n subtitle2: {\n fontSize: '0.875rem', // 14px\n fontWeight: fontWeightMedium,\n lineHeight: '22px',\n letterSpacing: '0.03rem',\n textTransform: 'uppercase',\n },\n\n button: {\n // 14px\n fontSize: '0.875rem',\n fontWeight: fontWeightMedium,\n // 20 px\n lineHeight: '1.25rem',\n textTransform: 'none',\n letterSpacing: '0.03rem',\n },\n caption: {\n fontSize: '0.6875rem', // 11px\n fontWeight: fontWeightRegular,\n lineHeight: '16px',\n },\n};\n"],"names":["fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","typography","fontFamily","h1","fontSize","fontWeight","lineHeight","h2","h3","h4","h5","undefined","h6","body1","body2","subtitle1","letterSpacing","subtitle2","textTransform","button","caption"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,OAAO,2BAA2B;AAClC,OAAO,2BAA2B;AAClC,OAAO,2BAA2B;AAClC,OAAO,2BAA2B;AAGlC,0EAA0E;AAC1E,0CAA0C;AAC1C,MAAMA,kBAAkB;AACxB,MAAMC,oBAAoB;AAC1B,MAAMC,mBAAmB;AACzB,MAAMC,iBAAiB;AAEvB;;CAEC,GACD,OAAO,MAAMC,aAAyC;IACpDC,YAAY;IAEZL;IACAC;IACAC;IACAC;IAEAG,IAAI;QACFC,UAAU;QACVC,YAAYN;QACZO,YAAY;IACd;IACAC,IAAI;QACFH,UAAU;QACVC,YAAYN;QACZO,YAAY;IACd;IACAE,IAAI;QACFJ,UAAU;QACVC,YAAYN;QACZO,YAAY;IACd;IACAG,IAAI;QACFL,UAAU;QACVC,YAAYN;QACZO,YAAY;IACd;IACAI,IAAIC;IACJC,IAAID;IAEJE,OAAO;QACLT,UAAU;QACVC,YAAYP;QACZQ,YAAY;IACd;IACAQ,OAAO;QACLV,UAAU;QACVC,YAAYP;QACZQ,YAAY;IACd;IACAS,WAAW;QACTX,UAAU;QACVC,YAAYP;QACZQ,YAAY;QACZU,eAAe;IACjB;IACAC,WAAW;QACTb,UAAU;QACVC,YAAYN;QACZO,YAAY;QACZU,eAAe;QACfE,eAAe;IACjB;IAEAC,QAAQ;QACN,OAAO;QACPf,UAAU;QACVC,YAAYN;QACZ,QAAQ;QACRO,YAAY;QACZY,eAAe;QACfF,eAAe;IACjB;IACAI,SAAS;QACPhB,UAAU;QACVC,YAAYP;QACZQ,YAAY;IACd;AACF,EAAE"}
@@ -1,6 +1,6 @@
1
1
  import type { XAXisComponentOption, YAXisComponentOption } from 'echarts';
2
- import { UnitOptions } from '@perses-dev/core';
3
- export declare function getFormattedAxis(axis?: YAXisComponentOption | XAXisComponentOption, unit?: UnitOptions): ({
2
+ import { FormatOptions } from '@perses-dev/core';
3
+ export declare function getFormattedAxis(axis?: YAXisComponentOption | XAXisComponentOption, unit?: FormatOptions): ({
4
4
  type: string;
5
5
  boundaryGap: (string | number)[];
6
6
  axisLabel: {
@@ -1 +1 @@
1
- {"version":3,"file":"axis.d.ts","sourceRoot":"","sources":["../../src/utils/axis.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,oBAAoB,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAC1E,OAAO,EAAe,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAK5D,wBAAgB,gBAAgB,CAAC,IAAI,CAAC,EAAE,oBAAoB,GAAG,oBAAoB,EAAE,IAAI,CAAC,EAAE,WAAW;;;;2BAM9E,MAAM;;iEAM9B;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,UAM1C"}
1
+ {"version":3,"file":"axis.d.ts","sourceRoot":"","sources":["../../src/utils/axis.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,oBAAoB,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAC1E,OAAO,EAAe,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAK9D,wBAAgB,gBAAgB,CAAC,IAAI,CAAC,EAAE,oBAAoB,GAAG,oBAAoB,EAAE,IAAI,CAAC,EAAE,aAAa;;;;2BAMhF,MAAM;;iEAM9B;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,UAM1C"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/axis.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport merge from 'lodash/merge';\nimport type { XAXisComponentOption, YAXisComponentOption } from 'echarts';\nimport { formatValue, UnitOptions } from '@perses-dev/core';\n\n/*\n * Populate yAxis or xAxis properties, returns an Array since multiple axes will be supported in the future\n */\nexport function getFormattedAxis(axis?: YAXisComponentOption | XAXisComponentOption, unit?: UnitOptions) {\n // TODO: support alternate yAxis that shows on right side\n const AXIS_DEFAULT = {\n type: 'value',\n boundaryGap: [0, '10%'],\n axisLabel: {\n formatter: (value: number) => {\n return formatValue(value, unit);\n },\n },\n };\n return [merge(AXIS_DEFAULT, axis)];\n}\n\n/**\n * Calculate date range, used as a fallback when xAxis time range not passed as prop\n */\nexport function getDateRange(data: number[]) {\n const defaultRange = 3600000; // hour in ms\n if (data.length === 0) return defaultRange;\n const lastDatum = data[data.length - 1];\n if (data[0] === undefined || lastDatum === undefined) return defaultRange;\n return lastDatum - data[0];\n}\n"],"names":["merge","formatValue","getFormattedAxis","axis","unit","AXIS_DEFAULT","type","boundaryGap","axisLabel","formatter","value","getDateRange","data","defaultRange","length","lastDatum","undefined"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,OAAOA,KAAK,MAAM,cAAc,CAAC;AAEjC,SAASC,WAAW,QAAqB,kBAAkB,CAAC;AAE5D;;CAEC,GACD,OAAO,SAASC,gBAAgB,CAACC,IAAkD,EAAEC,IAAkB,EAAE;IACvG,yDAAyD;IACzD,MAAMC,YAAY,GAAG;QACnBC,IAAI,EAAE,OAAO;QACbC,WAAW,EAAE;AAAC,aAAC;YAAE,KAAK;SAAC;QACvBC,SAAS,EAAE;YACTC,SAAS,EAAE,CAACC,KAAa,GAAK;gBAC5B,OAAOT,WAAW,CAACS,KAAK,EAAEN,IAAI,CAAC,CAAC;YAClC,CAAC;SACF;KACF,AAAC;IACF,OAAO;QAACJ,KAAK,CAACK,YAAY,EAAEF,IAAI,CAAC;KAAC,CAAC;AACrC,CAAC;AAED;;CAEC,GACD,OAAO,SAASQ,YAAY,CAACC,IAAc,EAAE;IAC3C,MAAMC,YAAY,GAAG,OAAO,AAAC,EAAC,aAAa;IAC3C,IAAID,IAAI,CAACE,MAAM,KAAK,CAAC,EAAE,OAAOD,YAAY,CAAC;IAC3C,MAAME,SAAS,GAAGH,IAAI,CAACA,IAAI,CAACE,MAAM,GAAG,CAAC,CAAC,AAAC;IACxC,IAAIF,IAAI,CAAC,CAAC,CAAC,KAAKI,SAAS,IAAID,SAAS,KAAKC,SAAS,EAAE,OAAOH,YAAY,CAAC;IAC1E,OAAOE,SAAS,GAAGH,IAAI,CAAC,CAAC,CAAC,CAAC;AAC7B,CAAC"}
1
+ {"version":3,"sources":["../../src/utils/axis.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport merge from 'lodash/merge';\nimport type { XAXisComponentOption, YAXisComponentOption } from 'echarts';\nimport { formatValue, FormatOptions } from '@perses-dev/core';\n\n/*\n * Populate yAxis or xAxis properties, returns an Array since multiple axes will be supported in the future\n */\nexport function getFormattedAxis(axis?: YAXisComponentOption | XAXisComponentOption, unit?: FormatOptions) {\n // TODO: support alternate yAxis that shows on right side\n const AXIS_DEFAULT = {\n type: 'value',\n boundaryGap: [0, '10%'],\n axisLabel: {\n formatter: (value: number) => {\n return formatValue(value, unit);\n },\n },\n };\n return [merge(AXIS_DEFAULT, axis)];\n}\n\n/**\n * Calculate date range, used as a fallback when xAxis time range not passed as prop\n */\nexport function getDateRange(data: number[]) {\n const defaultRange = 3600000; // hour in ms\n if (data.length === 0) return defaultRange;\n const lastDatum = data[data.length - 1];\n if (data[0] === undefined || lastDatum === undefined) return defaultRange;\n return lastDatum - data[0];\n}\n"],"names":["merge","formatValue","getFormattedAxis","axis","unit","AXIS_DEFAULT","type","boundaryGap","axisLabel","formatter","value","getDateRange","data","defaultRange","length","lastDatum","undefined"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,OAAOA,WAAW,eAAe;AAEjC,SAASC,WAAW,QAAuB,mBAAmB;AAE9D;;CAEC,GACD,OAAO,SAASC,iBAAiBC,IAAkD,EAAEC,IAAoB;IACvG,yDAAyD;IACzD,MAAMC,eAAe;QACnBC,MAAM;QACNC,aAAa;YAAC;YAAG;SAAM;QACvBC,WAAW;YACTC,WAAW,CAACC;gBACV,OAAOT,YAAYS,OAAON;YAC5B;QACF;IACF;IACA,OAAO;QAACJ,MAAMK,cAAcF;KAAM;AACpC;AAEA;;CAEC,GACD,OAAO,SAASQ,aAAaC,IAAc;IACzC,MAAMC,eAAe,SAAS,aAAa;IAC3C,IAAID,KAAKE,WAAW,GAAG,OAAOD;IAC9B,MAAME,YAAYH,IAAI,CAACA,KAAKE,SAAS,EAAE;IACvC,IAAIF,IAAI,CAAC,EAAE,KAAKI,aAAaD,cAAcC,WAAW,OAAOH;IAC7D,OAAOE,YAAYH,IAAI,CAAC,EAAE;AAC5B"}
@@ -118,8 +118,8 @@ import { PINNED_CROSSHAIR_SERIES_NAME } from '../model';
118
118
  /*
119
119
  * Determine whether a markLine was pushed into the final series, which means crosshair was already pinned onClick
120
120
  */ export function checkCrosshairPinnedStatus(seriesMapping) {
121
- var ref;
122
- const isCrosshairPinned = ((ref = seriesMapping[seriesMapping.length - 1]) === null || ref === void 0 ? void 0 : ref.name) === PINNED_CROSSHAIR_SERIES_NAME;
121
+ var _seriesMapping_;
122
+ const isCrosshairPinned = ((_seriesMapping_ = seriesMapping[seriesMapping.length - 1]) === null || _seriesMapping_ === void 0 ? void 0 : _seriesMapping_.name) === PINNED_CROSSHAIR_SERIES_NAME;
123
123
  return isCrosshairPinned;
124
124
  }
125
125
  /*
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/chart-actions.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { ECharts as EChartsInstance } from 'echarts/core';\nimport { TimeSeries, TimeSeriesValueTuple } from '@perses-dev/core';\nimport { DatapointInfo, PINNED_CROSSHAIR_SERIES_NAME, TimeChartSeriesMapping } from '../model';\n\nexport interface ZoomEventData {\n start: number;\n end: number;\n // TODO: remove startIndex and endIndex once LineChart is deprecated\n startIndex?: number;\n endIndex?: number;\n}\n\n/**\n * Enable dataZoom without requring user to click toolbox icon.\n * https://stackoverflow.com/questions/57183297/is-there-a-way-to-use-zoom-of-type-select-without-showing-the-toolbar\n */\nexport function enableDataZoom(chart: EChartsInstance) {\n const chartModel = chart['_model'];\n if (chartModel === undefined) return;\n if (chartModel.option.toolbox !== undefined && chartModel.option.toolbox.length > 0) {\n // check if hidden data zoom icon is unselected (if selected it would be 'emphasis' instead of 'normal')\n if (chartModel.option.toolbox[0].feature.dataZoom.iconStatus.zoom === 'normal') {\n chart.dispatchAction({\n type: 'takeGlobalCursor',\n key: 'dataZoomSelect',\n dataZoomSelectActive: true,\n });\n }\n }\n}\n\n/**\n * Restore chart to original state before zoom or other actions were dispatched\n */\nexport function restoreChart(chart: EChartsInstance) {\n // TODO: support incremental unzoom instead of restore to original state\n chart.dispatchAction({\n type: 'restore', // https://echarts.apache.org/en/api.html#events.restore\n });\n}\n\n/*\n * Clear all highlighted series when cursor exits canvas\n * https://echarts.apache.org/en/api.html#action.downplay\n */\nexport function clearHighlightedSeries(chart: EChartsInstance, totalSeries: number) {\n if (chart.dispatchAction !== undefined) {\n for (let i = 0; i < totalSeries; i++) {\n chart.dispatchAction({\n type: 'downplay',\n seriesIndex: i,\n });\n }\n }\n}\n\n/*\n * Convert a point from pixel coordinate to logical coordinate.\n * Used to determine if cursor is over chart canvas and closest datapoint.\n * https://echarts.apache.org/en/api.html#echartsInstance.convertFromPixel\n */\nexport function getPointInGrid(cursorCoordX: number, cursorCoordY: number, chart?: EChartsInstance) {\n if (chart === undefined) {\n return null;\n }\n\n const pointInPixel = [cursorCoordX, cursorCoordY];\n if (!chart.containPixel('grid', pointInPixel)) {\n return null;\n }\n\n const pointInGrid: number[] = chart.convertFromPixel('grid', pointInPixel);\n return pointInGrid;\n}\n\n/*\n * TimeSeriesChart tooltip is built custom to support finding nearby series instead of single or all series.\n * This means ECharts actions need to be dispatched manually for series highlighting, datapoint select state, etc.\n * More info: https://echarts.apache.org/en/api.html#action\n */\nexport function batchDispatchNearbySeriesActions(\n chart: EChartsInstance,\n nearbySeriesIndexes: number[],\n emphasizedSeriesIndexes: number[],\n nonEmphasizedSeriesIndexes: number[],\n emphasizedDatapoints: DatapointInfo[],\n duplicateDatapoints: DatapointInfo[]\n) {\n // Accounts for multiple series that are rendered direct on top of eachother.\n // Only applies select state to the datapoint that is visible to avoid color mismatch.\n const lastEmphasizedDatapoint =\n duplicateDatapoints.length > 0\n ? duplicateDatapoints[duplicateDatapoints.length - 1]\n : emphasizedDatapoints[emphasizedDatapoints.length - 1];\n if (lastEmphasizedDatapoint !== undefined) {\n // Corresponds to select options inside getTimeSeries util.\n // https://echarts.apache.org/en/option.html#series-line.select.itemStyle\n chart.dispatchAction({\n type: 'select',\n seriesIndex: lastEmphasizedDatapoint.seriesIndex,\n dataIndex: lastEmphasizedDatapoint.dataIndex,\n // Shared crosshair should not emphasize datapoints on adjacent charts.\n escapeConnect: true, // TODO: try to remove escapeConnect and match by seriesName for cross panel correlation\n });\n }\n\n // Clears emphasis state of all lines that are not emphasized.\n // Emphasized is a subset of just the nearby series that are closest to cursor.\n chart.dispatchAction({\n type: 'downplay',\n seriesIndex: nonEmphasizedSeriesIndexes,\n });\n\n // https://echarts.apache.org/en/api.html#action.highlight\n if (emphasizedSeriesIndexes.length > 0) {\n // Fadeout opacity of all series not closest to cursor.\n chart.dispatchAction({\n type: 'highlight',\n seriesIndex: emphasizedSeriesIndexes,\n notBlur: false, // ensure blur IS triggered, this is default but setting so it is explicit\n escapeConnect: true, // shared crosshair should not emphasize series on adjacent charts\n });\n } else {\n // When no emphasized series with bold text, notBlur allows opacity fadeout to not trigger.\n chart.dispatchAction({\n type: 'highlight',\n seriesIndex: nearbySeriesIndexes,\n notBlur: true, // do not trigger blur state when cursor is not immediately close to any series\n escapeConnect: true, // shared crosshair should not emphasize series on adjacent charts\n });\n\n // Clears selected datapoints since no bold series in tooltip, restore does not impact highlighting\n chart.dispatchAction({\n type: 'toggleSelect', // https://echarts.apache.org/en/api.html#action.toggleSelect\n });\n }\n}\n\n/*\n * Determine whether a markLine was pushed into the final series, which means crosshair was already pinned onClick\n */\nexport function checkCrosshairPinnedStatus(seriesMapping: TimeChartSeriesMapping) {\n const isCrosshairPinned = seriesMapping[seriesMapping.length - 1]?.name === PINNED_CROSSHAIR_SERIES_NAME;\n return isCrosshairPinned;\n}\n\n/*\n * Find closest timestamp to logical x coordinate returned from echartsInstance.convertFromPixel\n * Used to find nearby series in time series tooltip.\n */\nexport function getClosestTimestamp(timeSeriesValues?: TimeSeriesValueTuple[], cursorX?: number): number | null {\n if (timeSeriesValues === undefined || cursorX === undefined) {\n return null;\n }\n\n let currentClosestTimestamp: number | null = null;\n let currentClosestDistance = Infinity;\n\n for (const [timestamp] of timeSeriesValues) {\n const distance = Math.abs(timestamp - cursorX);\n if (distance < currentClosestDistance) {\n currentClosestTimestamp = timestamp;\n currentClosestDistance = distance;\n }\n }\n return currentClosestTimestamp;\n}\n\n/*\n * Find closest timestamp in full dataset, used to snap crosshair into place onClick when tooltip is pinned.\n */\nexport function getClosestTimestampInFullDataset(data: TimeSeries[], cursorX?: number): number | null {\n if (cursorX === undefined) {\n return null;\n }\n const totalSeries = data.length;\n let closestTimestamp = null;\n for (let seriesIdx = 0; seriesIdx < totalSeries; seriesIdx++) {\n const currentDataset = totalSeries > 0 ? data[seriesIdx] : null;\n if (currentDataset == null) break;\n const currentValues: TimeSeriesValueTuple[] = currentDataset.values;\n closestTimestamp = getClosestTimestamp(currentValues, cursorX);\n }\n return closestTimestamp;\n}\n"],"names":["PINNED_CROSSHAIR_SERIES_NAME","enableDataZoom","chart","chartModel","undefined","option","toolbox","length","feature","dataZoom","iconStatus","zoom","dispatchAction","type","key","dataZoomSelectActive","restoreChart","clearHighlightedSeries","totalSeries","i","seriesIndex","getPointInGrid","cursorCoordX","cursorCoordY","pointInPixel","containPixel","pointInGrid","convertFromPixel","batchDispatchNearbySeriesActions","nearbySeriesIndexes","emphasizedSeriesIndexes","nonEmphasizedSeriesIndexes","emphasizedDatapoints","duplicateDatapoints","lastEmphasizedDatapoint","dataIndex","escapeConnect","notBlur","checkCrosshairPinnedStatus","seriesMapping","isCrosshairPinned","name","getClosestTimestamp","timeSeriesValues","cursorX","currentClosestTimestamp","currentClosestDistance","Infinity","timestamp","distance","Math","abs","getClosestTimestampInFullDataset","data","closestTimestamp","seriesIdx","currentDataset","currentValues","values"],"mappings":"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"}
1
+ {"version":3,"sources":["../../src/utils/chart-actions.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { ECharts as EChartsInstance } from 'echarts/core';\nimport { TimeSeries, TimeSeriesValueTuple } from '@perses-dev/core';\nimport { DatapointInfo, PINNED_CROSSHAIR_SERIES_NAME, TimeChartSeriesMapping } from '../model';\n\nexport interface ZoomEventData {\n start: number;\n end: number;\n // TODO: remove startIndex and endIndex once LineChart is deprecated\n startIndex?: number;\n endIndex?: number;\n}\n\n/**\n * Enable dataZoom without requring user to click toolbox icon.\n * https://stackoverflow.com/questions/57183297/is-there-a-way-to-use-zoom-of-type-select-without-showing-the-toolbar\n */\nexport function enableDataZoom(chart: EChartsInstance) {\n const chartModel = chart['_model'];\n if (chartModel === undefined) return;\n if (chartModel.option.toolbox !== undefined && chartModel.option.toolbox.length > 0) {\n // check if hidden data zoom icon is unselected (if selected it would be 'emphasis' instead of 'normal')\n if (chartModel.option.toolbox[0].feature.dataZoom.iconStatus.zoom === 'normal') {\n chart.dispatchAction({\n type: 'takeGlobalCursor',\n key: 'dataZoomSelect',\n dataZoomSelectActive: true,\n });\n }\n }\n}\n\n/**\n * Restore chart to original state before zoom or other actions were dispatched\n */\nexport function restoreChart(chart: EChartsInstance) {\n // TODO: support incremental unzoom instead of restore to original state\n chart.dispatchAction({\n type: 'restore', // https://echarts.apache.org/en/api.html#events.restore\n });\n}\n\n/*\n * Clear all highlighted series when cursor exits canvas\n * https://echarts.apache.org/en/api.html#action.downplay\n */\nexport function clearHighlightedSeries(chart: EChartsInstance, totalSeries: number) {\n if (chart.dispatchAction !== undefined) {\n for (let i = 0; i < totalSeries; i++) {\n chart.dispatchAction({\n type: 'downplay',\n seriesIndex: i,\n });\n }\n }\n}\n\n/*\n * Convert a point from pixel coordinate to logical coordinate.\n * Used to determine if cursor is over chart canvas and closest datapoint.\n * https://echarts.apache.org/en/api.html#echartsInstance.convertFromPixel\n */\nexport function getPointInGrid(cursorCoordX: number, cursorCoordY: number, chart?: EChartsInstance) {\n if (chart === undefined) {\n return null;\n }\n\n const pointInPixel = [cursorCoordX, cursorCoordY];\n if (!chart.containPixel('grid', pointInPixel)) {\n return null;\n }\n\n const pointInGrid: number[] = chart.convertFromPixel('grid', pointInPixel);\n return pointInGrid;\n}\n\n/*\n * TimeSeriesChart tooltip is built custom to support finding nearby series instead of single or all series.\n * This means ECharts actions need to be dispatched manually for series highlighting, datapoint select state, etc.\n * More info: https://echarts.apache.org/en/api.html#action\n */\nexport function batchDispatchNearbySeriesActions(\n chart: EChartsInstance,\n nearbySeriesIndexes: number[],\n emphasizedSeriesIndexes: number[],\n nonEmphasizedSeriesIndexes: number[],\n emphasizedDatapoints: DatapointInfo[],\n duplicateDatapoints: DatapointInfo[]\n) {\n // Accounts for multiple series that are rendered direct on top of eachother.\n // Only applies select state to the datapoint that is visible to avoid color mismatch.\n const lastEmphasizedDatapoint =\n duplicateDatapoints.length > 0\n ? duplicateDatapoints[duplicateDatapoints.length - 1]\n : emphasizedDatapoints[emphasizedDatapoints.length - 1];\n if (lastEmphasizedDatapoint !== undefined) {\n // Corresponds to select options inside getTimeSeries util.\n // https://echarts.apache.org/en/option.html#series-line.select.itemStyle\n chart.dispatchAction({\n type: 'select',\n seriesIndex: lastEmphasizedDatapoint.seriesIndex,\n dataIndex: lastEmphasizedDatapoint.dataIndex,\n // Shared crosshair should not emphasize datapoints on adjacent charts.\n escapeConnect: true, // TODO: try to remove escapeConnect and match by seriesName for cross panel correlation\n });\n }\n\n // Clears emphasis state of all lines that are not emphasized.\n // Emphasized is a subset of just the nearby series that are closest to cursor.\n chart.dispatchAction({\n type: 'downplay',\n seriesIndex: nonEmphasizedSeriesIndexes,\n });\n\n // https://echarts.apache.org/en/api.html#action.highlight\n if (emphasizedSeriesIndexes.length > 0) {\n // Fadeout opacity of all series not closest to cursor.\n chart.dispatchAction({\n type: 'highlight',\n seriesIndex: emphasizedSeriesIndexes,\n notBlur: false, // ensure blur IS triggered, this is default but setting so it is explicit\n escapeConnect: true, // shared crosshair should not emphasize series on adjacent charts\n });\n } else {\n // When no emphasized series with bold text, notBlur allows opacity fadeout to not trigger.\n chart.dispatchAction({\n type: 'highlight',\n seriesIndex: nearbySeriesIndexes,\n notBlur: true, // do not trigger blur state when cursor is not immediately close to any series\n escapeConnect: true, // shared crosshair should not emphasize series on adjacent charts\n });\n\n // Clears selected datapoints since no bold series in tooltip, restore does not impact highlighting\n chart.dispatchAction({\n type: 'toggleSelect', // https://echarts.apache.org/en/api.html#action.toggleSelect\n });\n }\n}\n\n/*\n * Determine whether a markLine was pushed into the final series, which means crosshair was already pinned onClick\n */\nexport function checkCrosshairPinnedStatus(seriesMapping: TimeChartSeriesMapping) {\n const isCrosshairPinned = seriesMapping[seriesMapping.length - 1]?.name === PINNED_CROSSHAIR_SERIES_NAME;\n return isCrosshairPinned;\n}\n\n/*\n * Find closest timestamp to logical x coordinate returned from echartsInstance.convertFromPixel\n * Used to find nearby series in time series tooltip.\n */\nexport function getClosestTimestamp(timeSeriesValues?: TimeSeriesValueTuple[], cursorX?: number): number | null {\n if (timeSeriesValues === undefined || cursorX === undefined) {\n return null;\n }\n\n let currentClosestTimestamp: number | null = null;\n let currentClosestDistance = Infinity;\n\n for (const [timestamp] of timeSeriesValues) {\n const distance = Math.abs(timestamp - cursorX);\n if (distance < currentClosestDistance) {\n currentClosestTimestamp = timestamp;\n currentClosestDistance = distance;\n }\n }\n return currentClosestTimestamp;\n}\n\n/*\n * Find closest timestamp in full dataset, used to snap crosshair into place onClick when tooltip is pinned.\n */\nexport function getClosestTimestampInFullDataset(data: TimeSeries[], cursorX?: number): number | null {\n if (cursorX === undefined) {\n return null;\n }\n const totalSeries = data.length;\n let closestTimestamp = null;\n for (let seriesIdx = 0; seriesIdx < totalSeries; seriesIdx++) {\n const currentDataset = totalSeries > 0 ? data[seriesIdx] : null;\n if (currentDataset == null) break;\n const currentValues: TimeSeriesValueTuple[] = currentDataset.values;\n closestTimestamp = getClosestTimestamp(currentValues, cursorX);\n }\n return closestTimestamp;\n}\n"],"names":["PINNED_CROSSHAIR_SERIES_NAME","enableDataZoom","chart","chartModel","undefined","option","toolbox","length","feature","dataZoom","iconStatus","zoom","dispatchAction","type","key","dataZoomSelectActive","restoreChart","clearHighlightedSeries","totalSeries","i","seriesIndex","getPointInGrid","cursorCoordX","cursorCoordY","pointInPixel","containPixel","pointInGrid","convertFromPixel","batchDispatchNearbySeriesActions","nearbySeriesIndexes","emphasizedSeriesIndexes","nonEmphasizedSeriesIndexes","emphasizedDatapoints","duplicateDatapoints","lastEmphasizedDatapoint","dataIndex","escapeConnect","notBlur","checkCrosshairPinnedStatus","seriesMapping","isCrosshairPinned","name","getClosestTimestamp","timeSeriesValues","cursorX","currentClosestTimestamp","currentClosestDistance","Infinity","timestamp","distance","Math","abs","getClosestTimestampInFullDataset","data","closestTimestamp","seriesIdx","currentDataset","currentValues","values"],"mappings":"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"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/combine-sx.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { SxProps, Theme } from '@mui/material';\n\n/**\n * Combines sx props from multiple sources. Useful when creating a component and\n * you want consumers to be able to provide SxProps that should be combined with\n * some built-in styles.\n */\nexport function combineSx(...sxProps: Array<SxProps<Theme> | undefined>): SxProps<Theme> {\n return sxProps.flatMap((sx) => {\n if (sx === undefined) return [];\n if (Array.isArray(sx)) return sx;\n return [sx];\n });\n}\n"],"names":["combineSx","sxProps","flatMap","sx","undefined","Array","isArray"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC;;;;CAIC,GACD,OAAO,SAASA,SAAS,CAAC,GAAGC,OAAO,AAAmC,EAAkB;IACvF,OAAOA,OAAO,CAACC,OAAO,CAAC,CAACC,EAAE,GAAK;QAC7B,IAAIA,EAAE,KAAKC,SAAS,EAAE,OAAO,EAAE,CAAC;QAChC,IAAIC,KAAK,CAACC,OAAO,CAACH,EAAE,CAAC,EAAE,OAAOA,EAAE,CAAC;QACjC,OAAO;YAACA,EAAE;SAAC,CAAC;IACd,CAAC,CAAC,CAAC;AACL,CAAC"}
1
+ {"version":3,"sources":["../../src/utils/combine-sx.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { SxProps, Theme } from '@mui/material';\n\n/**\n * Combines sx props from multiple sources. Useful when creating a component and\n * you want consumers to be able to provide SxProps that should be combined with\n * some built-in styles.\n */\nexport function combineSx(...sxProps: Array<SxProps<Theme> | undefined>): SxProps<Theme> {\n return sxProps.flatMap((sx) => {\n if (sx === undefined) return [];\n if (Array.isArray(sx)) return sx;\n return [sx];\n });\n}\n"],"names":["combineSx","sxProps","flatMap","sx","undefined","Array","isArray"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC;;;;CAIC,GACD,OAAO,SAASA,UAAU,GAAGC,OAA0C;IACrE,OAAOA,QAAQC,QAAQ,CAACC;QACtB,IAAIA,OAAOC,WAAW,OAAO,EAAE;QAC/B,IAAIC,MAAMC,QAAQH,KAAK,OAAOA;QAC9B,OAAO;YAACA;SAAG;IACb;AACF"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/component-ids.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { useRef } from 'react';\n\ndeclare global {\n // eslint-disable-next-line no-var\n var useIdValue: number;\n}\n\n/**\n * Generates a unique (stable) ID for a component. Should be replaced with React.useId once we support only React 18.\n */\nexport function useId(prefix: string) {\n if (globalThis.useIdValue === undefined) {\n globalThis.useIdValue = 0;\n }\n\n const id = useRef<string | undefined>(undefined);\n if (id.current === undefined) {\n id.current = `${prefix}-${globalThis.useIdValue++}`;\n }\n return id.current;\n}\n"],"names":["useRef","useId","prefix","globalThis","useIdValue","undefined","id","current"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,MAAM,QAAQ,OAAO,CAAC;AAO/B;;CAEC,GACD,OAAO,SAASC,KAAK,CAACC,MAAc,EAAE;IACpC,IAAIC,UAAU,CAACC,UAAU,KAAKC,SAAS,EAAE;QACvCF,UAAU,CAACC,UAAU,GAAG,CAAC,CAAC;IAC5B,CAAC;IAED,MAAME,EAAE,GAAGN,MAAM,CAAqBK,SAAS,CAAC,AAAC;IACjD,IAAIC,EAAE,CAACC,OAAO,KAAKF,SAAS,EAAE;QAC5BC,EAAE,CAACC,OAAO,GAAG,CAAC,EAAEL,MAAM,CAAC,CAAC,EAAEC,UAAU,CAACC,UAAU,EAAE,CAAC,CAAC,CAAC;IACtD,CAAC;IACD,OAAOE,EAAE,CAACC,OAAO,CAAC;AACpB,CAAC"}
1
+ {"version":3,"sources":["../../src/utils/component-ids.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { useRef } from 'react';\n\ndeclare global {\n // eslint-disable-next-line no-var\n var useIdValue: number;\n}\n\n/**\n * Generates a unique (stable) ID for a component. Should be replaced with React.useId once we support only React 18.\n */\nexport function useId(prefix: string) {\n if (globalThis.useIdValue === undefined) {\n globalThis.useIdValue = 0;\n }\n\n const id = useRef<string | undefined>(undefined);\n if (id.current === undefined) {\n id.current = `${prefix}-${globalThis.useIdValue++}`;\n }\n return id.current;\n}\n"],"names":["useRef","useId","prefix","globalThis","useIdValue","undefined","id","current"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,MAAM,QAAQ,QAAQ;AAO/B;;CAEC,GACD,OAAO,SAASC,MAAMC,MAAc;IAClC,IAAIC,WAAWC,eAAeC,WAAW;QACvCF,WAAWC,aAAa;IAC1B;IAEA,MAAME,KAAKN,OAA2BK;IACtC,IAAIC,GAAGC,YAAYF,WAAW;QAC5BC,GAAGC,UAAU,CAAC,EAAEL,OAAO,CAAC,EAAEC,WAAWC,aAAa,CAAC;IACrD;IACA,OAAOE,GAAGC;AACZ"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/format.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { formatInTimeZone } from 'date-fns-tz';\nimport { format } from 'date-fns';\n\nexport function dateFormatOptionsWithTimeZone(dateFormatOptions: Intl.DateTimeFormatOptions, timeZone?: string) {\n /*\n * if timeZone is provided, and is not local|browser,\n * then set timeZone option (recognize UTC regardless of uppercase/lowercase)\n * otherwise, default to browser timeZone setting\n */\n if (timeZone) {\n const lowerTimeZone = timeZone.toLowerCase();\n if (lowerTimeZone !== 'local' && lowerTimeZone !== 'browser') {\n return {\n ...dateFormatOptions,\n timeZone: lowerTimeZone === 'utc' ? 'UTC' : timeZone,\n };\n }\n }\n return dateFormatOptions;\n}\n\nexport function formatWithTimeZone(date: Date, formatString: string, timeZone?: string) {\n /*\n * if timeZone is provided, and is not local|browser,\n * then format using timeZone option (recognize UTC regardless of uppercase/lowercase)\n * otherwise, format without timeZone option, defaulting to browser timeZone setting\n */\n const lowerTimeZone = timeZone?.toLowerCase();\n if (!timeZone || lowerTimeZone === 'local' || lowerTimeZone === 'browser') {\n return format(date, formatString);\n } else {\n return formatInTimeZone(date, lowerTimeZone === 'utc' ? 'UTC' : timeZone, formatString);\n }\n}\n\n/*\n * Determines time granularity for axis labels, defaults to hh:mm\n */\nexport function getFormattedDate(value: number, rangeMs: number, timeZone?: string) {\n const dateFormatOptions: Intl.DateTimeFormatOptions = dateFormatOptionsWithTimeZone(\n {\n hour: 'numeric',\n minute: 'numeric',\n hourCycle: 'h23',\n },\n timeZone\n );\n const thirtyMinMs = 1800000;\n const dayMs = 86400000;\n if (rangeMs <= thirtyMinMs) {\n dateFormatOptions.second = 'numeric';\n } else if (rangeMs >= dayMs) {\n dateFormatOptions.month = 'numeric';\n dateFormatOptions.day = 'numeric';\n }\n const DATE_FORMAT = new Intl.DateTimeFormat(undefined, dateFormatOptions);\n // remove comma when month / day present\n return DATE_FORMAT.format(value).replace(/, /g, ' ');\n}\n\n// https://echarts.apache.org/en/option.html#xAxis.axisLabel.formatter\nexport function getFormattedAxisLabel(rangeMs: number) {\n const dayMs = 86400000;\n const monthMs = 2629440000;\n const yearMs = 31536000000;\n\n // more than 5 years\n if (rangeMs > yearMs * 5) {\n return '{yyyy}';\n }\n\n // more than 2 years\n if (rangeMs > yearMs * 2) {\n return '{MMM} {yyyy}';\n }\n\n // between 5 days to 6 months\n if (rangeMs > dayMs * 5 && rangeMs < monthMs * 6) {\n return '{MM}/{dd}'; // 12/01\n }\n\n // between 2 and 5 days\n if (rangeMs > dayMs * 2 && rangeMs <= dayMs * 5) {\n return '{MM}/{dd} {HH}:{mm}'; // 12/01 12:30\n }\n\n return {\n year: '{yearStyle|{yyyy}}\\n{monthStyle|{MMM}}',\n month: '{MMM}', // Jan, Feb, ...\n day: '{MM}/{dd}',\n };\n}\n"],"names":["formatInTimeZone","format","dateFormatOptionsWithTimeZone","dateFormatOptions","timeZone","lowerTimeZone","toLowerCase","formatWithTimeZone","date","formatString","getFormattedDate","value","rangeMs","hour","minute","hourCycle","thirtyMinMs","dayMs","second","month","day","DATE_FORMAT","Intl","DateTimeFormat","undefined","replace","getFormattedAxisLabel","monthMs","yearMs","year"],"mappings":"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"}
1
+ {"version":3,"sources":["../../src/utils/format.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { formatInTimeZone } from 'date-fns-tz';\nimport { format } from 'date-fns';\n\nexport function dateFormatOptionsWithTimeZone(dateFormatOptions: Intl.DateTimeFormatOptions, timeZone?: string) {\n /*\n * if timeZone is provided, and is not local|browser,\n * then set timeZone option (recognize UTC regardless of uppercase/lowercase)\n * otherwise, default to browser timeZone setting\n */\n if (timeZone) {\n const lowerTimeZone = timeZone.toLowerCase();\n if (lowerTimeZone !== 'local' && lowerTimeZone !== 'browser') {\n return {\n ...dateFormatOptions,\n timeZone: lowerTimeZone === 'utc' ? 'UTC' : timeZone,\n };\n }\n }\n return dateFormatOptions;\n}\n\nexport function formatWithTimeZone(date: Date, formatString: string, timeZone?: string) {\n /*\n * if timeZone is provided, and is not local|browser,\n * then format using timeZone option (recognize UTC regardless of uppercase/lowercase)\n * otherwise, format without timeZone option, defaulting to browser timeZone setting\n */\n const lowerTimeZone = timeZone?.toLowerCase();\n if (!timeZone || lowerTimeZone === 'local' || lowerTimeZone === 'browser') {\n return format(date, formatString);\n } else {\n return formatInTimeZone(date, lowerTimeZone === 'utc' ? 'UTC' : timeZone, formatString);\n }\n}\n\n/*\n * Determines time granularity for axis labels, defaults to hh:mm\n */\nexport function getFormattedDate(value: number, rangeMs: number, timeZone?: string) {\n const dateFormatOptions: Intl.DateTimeFormatOptions = dateFormatOptionsWithTimeZone(\n {\n hour: 'numeric',\n minute: 'numeric',\n hourCycle: 'h23',\n },\n timeZone\n );\n const thirtyMinMs = 1800000;\n const dayMs = 86400000;\n if (rangeMs <= thirtyMinMs) {\n dateFormatOptions.second = 'numeric';\n } else if (rangeMs >= dayMs) {\n dateFormatOptions.month = 'numeric';\n dateFormatOptions.day = 'numeric';\n }\n const DATE_FORMAT = new Intl.DateTimeFormat(undefined, dateFormatOptions);\n // remove comma when month / day present\n return DATE_FORMAT.format(value).replace(/, /g, ' ');\n}\n\n// https://echarts.apache.org/en/option.html#xAxis.axisLabel.formatter\nexport function getFormattedAxisLabel(rangeMs: number) {\n const dayMs = 86400000;\n const monthMs = 2629440000;\n const yearMs = 31536000000;\n\n // more than 5 years\n if (rangeMs > yearMs * 5) {\n return '{yyyy}';\n }\n\n // more than 2 years\n if (rangeMs > yearMs * 2) {\n return '{MMM} {yyyy}';\n }\n\n // between 5 days to 6 months\n if (rangeMs > dayMs * 5 && rangeMs < monthMs * 6) {\n return '{MM}/{dd}'; // 12/01\n }\n\n // between 2 and 5 days\n if (rangeMs > dayMs * 2 && rangeMs <= dayMs * 5) {\n return '{MM}/{dd} {HH}:{mm}'; // 12/01 12:30\n }\n\n return {\n year: '{yearStyle|{yyyy}}\\n{monthStyle|{MMM}}',\n month: '{MMM}', // Jan, Feb, ...\n day: '{MM}/{dd}',\n };\n}\n"],"names":["formatInTimeZone","format","dateFormatOptionsWithTimeZone","dateFormatOptions","timeZone","lowerTimeZone","toLowerCase","formatWithTimeZone","date","formatString","getFormattedDate","value","rangeMs","hour","minute","hourCycle","thirtyMinMs","dayMs","second","month","day","DATE_FORMAT","Intl","DateTimeFormat","undefined","replace","getFormattedAxisLabel","monthMs","yearMs","year"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,gBAAgB,QAAQ,cAAc;AAC/C,SAASC,MAAM,QAAQ,WAAW;AAElC,OAAO,SAASC,8BAA8BC,iBAA6C,EAAEC,QAAiB;IAC5G;;;;GAIC,GACD,IAAIA,UAAU;QACZ,MAAMC,gBAAgBD,SAASE;QAC/B,IAAID,kBAAkB,WAAWA,kBAAkB,WAAW;YAC5D,OAAO;gBACL,GAAGF,iBAAiB;gBACpBC,UAAUC,kBAAkB,QAAQ,QAAQD;YAC9C;QACF;IACF;IACA,OAAOD;AACT;AAEA,OAAO,SAASI,mBAAmBC,IAAU,EAAEC,YAAoB,EAAEL,QAAiB;IACpF;;;;GAIC,GACD,MAAMC,gBAAgBD,qBAAAA,sBAAAA,KAAAA,IAAAA,SAAUE;IAChC,IAAI,CAACF,YAAYC,kBAAkB,WAAWA,kBAAkB,WAAW;QACzE,OAAOJ,OAAOO,MAAMC;IACtB,OAAO;QACL,OAAOT,iBAAiBQ,MAAMH,kBAAkB,QAAQ,QAAQD,UAAUK;IAC5E;AACF;AAEA;;CAEC,GACD,OAAO,SAASC,iBAAiBC,KAAa,EAAEC,OAAe,EAAER,QAAiB;IAChF,MAAMD,oBAAgDD,8BACpD;QACEW,MAAM;QACNC,QAAQ;QACRC,WAAW;IACb,GACAX;IAEF,MAAMY,cAAc;IACpB,MAAMC,QAAQ;IACd,IAAIL,WAAWI,aAAa;QAC1Bb,kBAAkBe,SAAS;IAC7B,OAAO,IAAIN,WAAWK,OAAO;QAC3Bd,kBAAkBgB,QAAQ;QAC1BhB,kBAAkBiB,MAAM;IAC1B;IACA,MAAMC,cAAc,IAAIC,KAAKC,eAAeC,WAAWrB;IACvD,wCAAwC;IACxC,OAAOkB,YAAYpB,OAAOU,OAAOc,QAAQ,OAAO;AAClD;AAEA,sEAAsE;AACtE,OAAO,SAASC,sBAAsBd,OAAe;IACnD,MAAMK,QAAQ;IACd,MAAMU,UAAU;IAChB,MAAMC,SAAS;IAEf,oBAAoB;IACpB,IAAIhB,UAAUgB,SAAS,GAAG;QACxB,OAAO;IACT;IAEA,oBAAoB;IACpB,IAAIhB,UAAUgB,SAAS,GAAG;QACxB,OAAO;IACT;IAEA,6BAA6B;IAC7B,IAAIhB,UAAUK,QAAQ,KAAKL,UAAUe,UAAU,GAAG;QAChD,OAAO,aAAa,QAAQ;IAC9B;IAEA,uBAAuB;IACvB,IAAIf,UAAUK,QAAQ,KAAKL,WAAWK,QAAQ,GAAG;QAC/C,OAAO,uBAAuB,cAAc;IAC9C;IAEA,OAAO;QACLY,MAAM;QACNV,OAAO;QACPC,KAAK;IACP;AACF"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/index.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport * from './axis';\nexport * from './chart-actions';\nexport * from './combine-sx';\nexport * from './component-ids';\nexport * from './format';\nexport * from './theme-gen';\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,cAAc,QAAQ,CAAC;AACvB,cAAc,iBAAiB,CAAC;AAChC,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC"}
1
+ {"version":3,"sources":["../../src/utils/index.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nexport * from './axis';\nexport * from './chart-actions';\nexport * from './combine-sx';\nexport * from './component-ids';\nexport * from './format';\nexport * from './theme-gen';\n"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,cAAc,SAAS;AACvB,cAAc,kBAAkB;AAChC,cAAc,eAAe;AAC7B,cAAc,kBAAkB;AAChC,cAAc,WAAW;AACzB,cAAc,cAAc"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/mathjs.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { roundDependencies, create } from 'mathjs';\n\n// This ensures we get a minimal mathjs bundle for just what we need (see https://mathjs.org/docs/custom_bundling.html)\nconst { round } = create({ roundDependencies });\nexport { round };\n"],"names":["roundDependencies","create","round"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,iBAAiB,EAAEC,MAAM,QAAQ,QAAQ,CAAC;AAEnD,uHAAuH;AACvH,MAAM,EAAEC,KAAK,CAAA,EAAE,GAAGD,MAAM,CAAC;IAAED,iBAAiB;CAAE,CAAC,AAAC;AAChD,SAASE,KAAK,GAAG"}
1
+ {"version":3,"sources":["../../src/utils/mathjs.ts"],"sourcesContent":["// Copyright 2023 The Perses Authors\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\nimport { roundDependencies, create } from 'mathjs';\n\n// This ensures we get a minimal mathjs bundle for just what we need (see https://mathjs.org/docs/custom_bundling.html)\nconst { round } = create({ roundDependencies });\nexport { round };\n"],"names":["roundDependencies","create","round"],"mappings":"AAAA,oCAAoC;AACpC,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,iBAAiB,EAAEC,MAAM,QAAQ,SAAS;AAEnD,uHAAuH;AACvH,MAAM,EAAEC,MAAK,EAAE,GAAGD,OAAO;IAAED;AAAkB;AAC7C,SAASE,KAAK,GAAG"}