@perses-dev/stat-chart-plugin 0.14.0 → 0.15.0-beta.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 (139) hide show
  1. package/__mf/js/StatChart.cfc077f0.js +7 -0
  2. package/__mf/js/async/121.dd7133cb.js +2 -0
  3. package/__mf/js/async/192.6939be34.js +1 -0
  4. package/__mf/js/async/2.8caf67bd.js +1 -0
  5. package/__mf/js/async/235.c6d2c4f5.js +1 -0
  6. package/__mf/js/async/274.7345c704.js +2 -0
  7. package/__mf/js/async/345.242802c4.js +29 -0
  8. package/__mf/js/async/354.6ea77f69.js +4 -0
  9. package/__mf/js/async/354.6ea77f69.js.LICENSE.txt +9 -0
  10. package/__mf/js/async/356.b00937de.js +1 -0
  11. package/__mf/js/async/392.559f0a15.js +2 -0
  12. package/__mf/js/async/449.6d8fc8b3.js +43 -0
  13. package/__mf/js/async/{580.4076ee7b.js.LICENSE.txt → 449.6d8fc8b3.js.LICENSE.txt} +41 -1
  14. package/__mf/js/async/470.16a500aa.js +2 -0
  15. package/__mf/js/async/570.34dc9996.js +2 -0
  16. package/__mf/js/async/587.7eb542f2.js +1 -0
  17. package/__mf/js/async/616.6b72e257.js +1 -0
  18. package/__mf/js/async/663.2de74425.js +1 -0
  19. package/__mf/js/async/{866.cb6cbc7a.js → 866.d7ad9e7a.js} +5 -5
  20. package/__mf/js/async/941.1589eeae.js +2 -0
  21. package/__mf/js/async/968.ebdf1f2d.js +1 -0
  22. package/__mf/js/async/970.f5882828.js +2 -0
  23. package/__mf/js/async/__federation_expose_StatChart.7973125b.js +1 -0
  24. package/__mf/js/async/lib-router.73f6cef1.js +2 -0
  25. package/__mf/js/{main.fe3736c5.js → main.cd844a8c.js} +3 -3
  26. package/lib/StatChart.d.ts +3 -3
  27. package/lib/StatChart.d.ts.map +1 -1
  28. package/lib/StatChart.js +4 -4
  29. package/lib/StatChart.js.map +1 -1
  30. package/lib/StatChartBase.d.ts +4 -4
  31. package/lib/StatChartBase.d.ts.map +1 -1
  32. package/lib/StatChartBase.js +12 -12
  33. package/lib/StatChartBase.js.map +1 -1
  34. package/lib/StatChartOptionsEditorSettings.d.ts +2 -2
  35. package/lib/StatChartOptionsEditorSettings.d.ts.map +1 -1
  36. package/lib/StatChartOptionsEditorSettings.js +8 -8
  37. package/lib/StatChartOptionsEditorSettings.js.map +1 -1
  38. package/lib/StatChartPanel.d.ts +4 -4
  39. package/lib/StatChartPanel.d.ts.map +1 -1
  40. package/lib/StatChartPanel.js +14 -9
  41. package/lib/StatChartPanel.js.map +1 -1
  42. package/lib/StatChartValueMappingEditor.d.ts +3 -3
  43. package/lib/StatChartValueMappingEditor.d.ts.map +1 -1
  44. package/lib/StatChartValueMappingEditor.js +1 -1
  45. package/lib/StatChartValueMappingEditor.js.map +1 -1
  46. package/lib/bootstrap.js +2 -2
  47. package/lib/getPluginModule.d.ts +1 -1
  48. package/lib/getPluginModule.d.ts.map +1 -1
  49. package/lib/getPluginModule.js +3 -1
  50. package/lib/getPluginModule.js.map +1 -1
  51. package/lib/index-federation.js +1 -1
  52. package/lib/index.js +7 -7
  53. package/lib/index.js.map +1 -1
  54. package/lib/setup-tests.d.ts +1 -1
  55. package/lib/setup-tests.d.ts.map +1 -1
  56. package/lib/setup-tests.js +2 -2
  57. package/lib/setup-tests.js.map +1 -1
  58. package/lib/stat-chart-model.d.ts +3 -3
  59. package/lib/stat-chart-model.d.ts.map +1 -1
  60. package/lib/stat-chart-model.js.map +1 -1
  61. package/lib/utils/calculate-font-size.d.ts +1 -1
  62. package/lib/utils/calculate-font-size.d.ts.map +1 -1
  63. package/lib/utils/calculate-font-size.js +2 -2
  64. package/lib/utils/calculate-font-size.js.map +1 -1
  65. package/lib/utils/calculate-value.d.ts +3 -2
  66. package/lib/utils/calculate-value.d.ts.map +1 -1
  67. package/lib/utils/calculate-value.js +1 -1
  68. package/lib/utils/calculate-value.js.map +1 -1
  69. package/lib/utils/data-transform.d.ts +3 -3
  70. package/lib/utils/data-transform.d.ts.map +1 -1
  71. package/lib/utils/data-transform.js.map +1 -1
  72. package/lib/utils/format-stat-chart-value.d.ts +1 -1
  73. package/lib/utils/format-stat-chart-value.d.ts.map +1 -1
  74. package/lib/utils/format-stat-chart-value.js +1 -1
  75. package/lib/utils/format-stat-chart-value.js.map +1 -1
  76. package/lib/utils/get-color.d.ts +2 -2
  77. package/lib/utils/get-color.d.ts.map +1 -1
  78. package/lib/utils/get-color.js +1 -1
  79. package/lib/utils/get-color.js.map +1 -1
  80. package/mf-manifest.json +29 -73
  81. package/mf-stats.json +29 -81
  82. package/package.json +10 -10
  83. package/__mf/js/StatChart.19a287b0.js +0 -7
  84. package/__mf/js/async/121.a33651ce.js +0 -2
  85. package/__mf/js/async/177.4dddf131.js +0 -1
  86. package/__mf/js/async/187.d7e6b2db.js +0 -7
  87. package/__mf/js/async/187.d7e6b2db.js.LICENSE.txt +0 -39
  88. package/__mf/js/async/192.0b251884.js +0 -1
  89. package/__mf/js/async/2.e8bdc16f.js +0 -1
  90. package/__mf/js/async/235.f388b6fd.js +0 -1
  91. package/__mf/js/async/274.b762faf5.js +0 -2
  92. package/__mf/js/async/356.3f7b970d.js +0 -1
  93. package/__mf/js/async/392.70b1a3c5.js +0 -2
  94. package/__mf/js/async/450.bdfbd76f.js +0 -1
  95. package/__mf/js/async/465.7c60371f.js +0 -2
  96. package/__mf/js/async/470.cc046da0.js +0 -2
  97. package/__mf/js/async/546.f27d00a1.js +0 -24
  98. package/__mf/js/async/546.f27d00a1.js.LICENSE.txt +0 -19
  99. package/__mf/js/async/558.e8f8691f.js +0 -1
  100. package/__mf/js/async/570.264704d1.js +0 -2
  101. package/__mf/js/async/580.4076ee7b.js +0 -66
  102. package/__mf/js/async/587.7d22fb82.js +0 -1
  103. package/__mf/js/async/588.c00e3759.js +0 -1
  104. package/__mf/js/async/616.22b37336.js +0 -1
  105. package/__mf/js/async/71.1f2caf38.js +0 -1
  106. package/__mf/js/async/721.5c1c6916.js +0 -1
  107. package/__mf/js/async/873.13ff7de6.js +0 -1
  108. package/__mf/js/async/941.230549f5.js +0 -2
  109. package/__mf/js/async/968.bfd3594f.js +0 -1
  110. package/__mf/js/async/978.98475f4b.js +0 -1
  111. package/__mf/js/async/__federation_expose_StatChart.f4a2f598.js +0 -1
  112. package/__mf/js/async/lib-router.6c58ccc7.js +0 -2
  113. package/lib/cjs/StatChart.js +0 -43
  114. package/lib/cjs/StatChartBase.js +0 -263
  115. package/lib/cjs/StatChartOptionsEditorSettings.js +0 -171
  116. package/lib/cjs/StatChartPanel.js +0 -130
  117. package/lib/cjs/StatChartValueMappingEditor.js +0 -36
  118. package/lib/cjs/bootstrap.js +0 -26
  119. package/lib/cjs/env.d.js +0 -14
  120. package/lib/cjs/getPluginModule.js +0 -39
  121. package/lib/cjs/index-federation.js +0 -55
  122. package/lib/cjs/index.js +0 -42
  123. package/lib/cjs/setup-tests.js +0 -19
  124. package/lib/cjs/stat-chart-model.js +0 -74
  125. package/lib/cjs/utils/calculate-font-size.js +0 -55
  126. package/lib/cjs/utils/calculate-value.js +0 -30
  127. package/lib/cjs/utils/data-transform.js +0 -36
  128. package/lib/cjs/utils/format-stat-chart-value.js +0 -34
  129. package/lib/cjs/utils/get-color.js +0 -66
  130. /package/__mf/css/async/{187.85c2cbf6.css → 449.85c2cbf6.css} +0 -0
  131. /package/__mf/js/async/{121.a33651ce.js.LICENSE.txt → 121.dd7133cb.js.LICENSE.txt} +0 -0
  132. /package/__mf/js/async/{274.b762faf5.js.LICENSE.txt → 274.7345c704.js.LICENSE.txt} +0 -0
  133. /package/__mf/js/async/{392.70b1a3c5.js.LICENSE.txt → 392.559f0a15.js.LICENSE.txt} +0 -0
  134. /package/__mf/js/async/{470.cc046da0.js.LICENSE.txt → 470.16a500aa.js.LICENSE.txt} +0 -0
  135. /package/__mf/js/async/{570.264704d1.js.LICENSE.txt → 570.34dc9996.js.LICENSE.txt} +0 -0
  136. /package/__mf/js/async/{866.cb6cbc7a.js.LICENSE.txt → 866.d7ad9e7a.js.LICENSE.txt} +0 -0
  137. /package/__mf/js/async/{941.230549f5.js.LICENSE.txt → 941.1589eeae.js.LICENSE.txt} +0 -0
  138. /package/__mf/js/async/{465.7c60371f.js.LICENSE.txt → 970.f5882828.js.LICENSE.txt} +0 -0
  139. /package/__mf/js/async/{lib-router.6c58ccc7.js.LICENSE.txt → lib-router.73f6cef1.js.LICENSE.txt} +0 -0
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/stat-chart-model.ts"],"sourcesContent":["// Copyright 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 { FontSizeOption, FormatOptions, ThresholdOptions, ValueMapping } from '@perses-dev/components';\nimport { CalculationType, OptionsEditorProps } from '@perses-dev/plugin-system';\nimport { Definition } from '@perses-dev/spec';\n\n/**\n * The schema for a StatChart panel.\n */\nexport interface StatChartDefinition extends Definition<StatChartOptions> {\n kind: 'StatChart';\n}\n\nexport type ColorMode = 'none' | 'value' | 'background_solid';\n\nexport type ColorModeLabelItem = {\n id: ColorMode;\n label: string;\n};\n\nexport const COLOR_MODE_LABELS: ColorModeLabelItem[] = [\n { id: 'none', label: 'None' },\n { id: 'value', label: 'Text' },\n { id: 'background_solid', label: 'Background' },\n];\n\nexport type legendMode = 'auto' | 'on' | 'off';\n\nexport type ShowLegendLabelItem = {\n id: legendMode;\n label: string;\n description?: string;\n};\n\nexport const SHOW_LEGEND_LABELS: ShowLegendLabelItem[] = [\n { id: 'auto', label: 'Auto', description: 'Show legend for multi-series, hide legend for single series' },\n { id: 'on', label: 'On', description: 'Always show legend' },\n { id: 'off', label: 'Off', description: 'Always hide legend' },\n];\n\nexport interface StatChartOptions {\n calculation: CalculationType;\n format: FormatOptions;\n metricLabel?: string;\n thresholds?: ThresholdOptions;\n sparkline?: StatChartSparklineOptions;\n valueFontSize?: FontSizeOption;\n mappings?: ValueMapping[];\n colorMode?: ColorMode;\n legendMode?: legendMode;\n}\n\nexport interface StatChartSparklineOptions {\n color?: string;\n width?: number;\n}\n\nexport type StatChartOptionsEditorProps = OptionsEditorProps<StatChartOptions>;\n\nexport function createInitialStatChartOptions(): StatChartOptions {\n return {\n calculation: 'last-number',\n format: {\n unit: 'decimal',\n },\n sparkline: {},\n legendMode: 'auto',\n };\n}\n"],"names":["COLOR_MODE_LABELS","id","label","SHOW_LEGEND_LABELS","description","createInitialStatChartOptions","calculation","format","unit","sparkline","legendMode"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAoBjC,OAAO,MAAMA,oBAA0C;IACrD;QAAEC,IAAI;QAAQC,OAAO;IAAO;IAC5B;QAAED,IAAI;QAASC,OAAO;IAAO;IAC7B;QAAED,IAAI;QAAoBC,OAAO;IAAa;CAC/C,CAAC;AAUF,OAAO,MAAMC,qBAA4C;IACvD;QAAEF,IAAI;QAAQC,OAAO;QAAQE,aAAa;IAA8D;IACxG;QAAEH,IAAI;QAAMC,OAAO;QAAME,aAAa;IAAqB;IAC3D;QAAEH,IAAI;QAAOC,OAAO;QAAOE,aAAa;IAAqB;CAC9D,CAAC;AAqBF,OAAO,SAASC;IACd,OAAO;QACLC,aAAa;QACbC,QAAQ;YACNC,MAAM;QACR;QACAC,WAAW,CAAC;QACZC,YAAY;IACd;AACF"}
1
+ {"version":3,"sources":["../../src/stat-chart-model.ts"],"sourcesContent":["// Copyright 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 type { FontSizeOption, FormatOptions, ThresholdOptions, ValueMapping } from '@perses-dev/components';\nimport type { CalculationType, OptionsEditorProps } from '@perses-dev/plugin-system';\nimport type { Definition } from '@perses-dev/spec';\n\n/**\n * The schema for a StatChart panel.\n */\nexport interface StatChartDefinition extends Definition<StatChartOptions> {\n kind: 'StatChart';\n}\n\nexport type ColorMode = 'none' | 'value' | 'background_solid';\n\nexport type ColorModeLabelItem = {\n id: ColorMode;\n label: string;\n};\n\nexport const COLOR_MODE_LABELS: ColorModeLabelItem[] = [\n { id: 'none', label: 'None' },\n { id: 'value', label: 'Text' },\n { id: 'background_solid', label: 'Background' },\n];\n\nexport type legendMode = 'auto' | 'on' | 'off';\n\nexport type ShowLegendLabelItem = {\n id: legendMode;\n label: string;\n description?: string;\n};\n\nexport const SHOW_LEGEND_LABELS: ShowLegendLabelItem[] = [\n { id: 'auto', label: 'Auto', description: 'Show legend for multi-series, hide legend for single series' },\n { id: 'on', label: 'On', description: 'Always show legend' },\n { id: 'off', label: 'Off', description: 'Always hide legend' },\n];\n\nexport interface StatChartOptions {\n calculation: CalculationType;\n format: FormatOptions;\n metricLabel?: string;\n thresholds?: ThresholdOptions;\n sparkline?: StatChartSparklineOptions;\n valueFontSize?: FontSizeOption;\n mappings?: ValueMapping[];\n colorMode?: ColorMode;\n legendMode?: legendMode;\n}\n\nexport interface StatChartSparklineOptions {\n color?: string;\n width?: number;\n}\n\nexport type StatChartOptionsEditorProps = OptionsEditorProps<StatChartOptions>;\n\nexport function createInitialStatChartOptions(): StatChartOptions {\n return {\n calculation: 'last-number',\n format: {\n unit: 'decimal',\n },\n sparkline: {},\n legendMode: 'auto',\n };\n}\n"],"names":["COLOR_MODE_LABELS","id","label","SHOW_LEGEND_LABELS","description","createInitialStatChartOptions","calculation","format","unit","sparkline","legendMode"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAoBjC,OAAO,MAAMA,oBAA0C;IACrD;QAAEC,IAAI;QAAQC,OAAO;IAAO;IAC5B;QAAED,IAAI;QAASC,OAAO;IAAO;IAC7B;QAAED,IAAI;QAAoBC,OAAO;IAAa;CAC/C,CAAC;AAUF,OAAO,MAAMC,qBAA4C;IACvD;QAAEF,IAAI;QAAQC,OAAO;QAAQE,aAAa;IAA8D;IACxG;QAAEH,IAAI;QAAMC,OAAO;QAAME,aAAa;IAAqB;IAC3D;QAAEH,IAAI;QAAOC,OAAO;QAAOE,aAAa;IAAqB;CAC9D,CAAC;AAqBF,OAAO,SAASC;IACd,OAAO;QACLC,aAAa;QACbC,QAAQ;YACNC,MAAM;QACR;QACAC,WAAW,CAAC;QACZC,YAAY;IACd;AACF"}
@@ -1,4 +1,4 @@
1
- import { FontSizeOption } from '@perses-dev/components';
1
+ import type { FontSizeOption } from '@perses-dev/components';
2
2
  interface CalculateFontSize {
3
3
  text: string;
4
4
  fontWeight: number;
@@ -1 +1 @@
1
- {"version":3,"file":"calculate-font-size.d.ts","sourceRoot":"","sources":["../../../src/utils/calculate-font-size.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,cAAc,EAAkB,MAAM,wBAAwB,CAAC;AAExE,UAAU,iBAAiB;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,gBAAgB,CAAC,EAAE,cAAc,CAAC;CACnC;AAcD;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,EACjC,IAAI,EACJ,UAAU,EACV,KAAK,EACL,MAAM,EACN,UAAU,EACV,OAAO,EACP,gBAAgB,GACjB,EAAE,iBAAiB,GAAG,MAAM,CA0B5B"}
1
+ {"version":3,"file":"calculate-font-size.d.ts","sourceRoot":"","sources":["../../../src/utils/calculate-font-size.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAC;AAG7D,UAAU,iBAAiB;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,gBAAgB,CAAC,EAAE,cAAc,CAAC;CACnC;AAcD;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,EACjC,IAAI,EACJ,UAAU,EACV,KAAK,EACL,MAAM,EACN,UAAU,EACV,OAAO,EACP,gBAAgB,GACjB,EAAE,iBAAiB,GAAG,MAAM,CA0B5B"}
@@ -10,7 +10,7 @@
10
10
  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
- import { useChartsTheme } from '@perses-dev/components';
13
+ import { useChartsTheme } from "@perses-dev/components";
14
14
  let canvasContext;
15
15
  function getGlobalCanvasContext() {
16
16
  if (!canvasContext) {
@@ -31,7 +31,7 @@ function getGlobalCanvasContext() {
31
31
  return Number(fontSizeOverride);
32
32
  }
33
33
  const textStyle = echartsTheme.textStyle;
34
- const fontSize = Number(textStyle?.fontSize) ?? 12;
34
+ const fontSize = Number(textStyle?.fontSize ?? 12);
35
35
  const fontFamily = textStyle?.fontFamily ?? 'Lato';
36
36
  // set the font on the canvas context
37
37
  const fontStyle = `${fontWeight} ${fontSize}px ${fontFamily}`;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/utils/calculate-font-size.ts"],"sourcesContent":["// Copyright 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 { FontSizeOption, useChartsTheme } from '@perses-dev/components';\n\ninterface CalculateFontSize {\n text: string;\n fontWeight: number;\n width: number;\n height: number;\n lineHeight: number;\n maxSize?: number;\n fontSizeOverride?: FontSizeOption;\n}\n\nlet canvasContext: CanvasRenderingContext2D | null;\n\nfunction getGlobalCanvasContext(): CanvasRenderingContext2D {\n if (!canvasContext) {\n canvasContext = document.createElement('canvas').getContext('2d');\n if (canvasContext === null) {\n throw new Error('Canvas context is null.');\n }\n }\n return canvasContext;\n}\n\n/**\n * Find the optimal font size given available space\n */\nexport function useOptimalFontSize({\n text,\n fontWeight,\n width,\n height,\n lineHeight,\n maxSize,\n fontSizeOverride,\n}: CalculateFontSize): number {\n const ctx = getGlobalCanvasContext();\n const { echartsTheme } = useChartsTheme();\n\n // if user has selected a font size in the settings, use it instead of calculating the optimal size\n if (fontSizeOverride !== undefined) {\n return Number(fontSizeOverride);\n }\n\n const textStyle = echartsTheme.textStyle;\n const fontSize = Number(textStyle?.fontSize) ?? 12;\n const fontFamily = textStyle?.fontFamily ?? 'Lato';\n\n // set the font on the canvas context\n const fontStyle = `${fontWeight} ${fontSize}px ${fontFamily}`;\n ctx.font = fontStyle;\n // measure the width of the text with the given font style\n const textMetrics: TextMetrics = ctx.measureText(text);\n\n // check how much bigger we can make the font while staying within the width and height\n const fontSizeBasedOnWidth = (width / textMetrics.width) * fontSize;\n const fontSizeBasedOnHeight = height / lineHeight;\n\n // return the smaller font size\n const finalFontSize = Math.min(fontSizeBasedOnHeight, fontSizeBasedOnWidth);\n return maxSize ? Math.min(finalFontSize, maxSize) : finalFontSize;\n}\n"],"names":["useChartsTheme","canvasContext","getGlobalCanvasContext","document","createElement","getContext","Error","useOptimalFontSize","text","fontWeight","width","height","lineHeight","maxSize","fontSizeOverride","ctx","echartsTheme","undefined","Number","textStyle","fontSize","fontFamily","fontStyle","font","textMetrics","measureText","fontSizeBasedOnWidth","fontSizeBasedOnHeight","finalFontSize","Math","min"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAAyBA,cAAc,QAAQ,yBAAyB;AAYxE,IAAIC;AAEJ,SAASC;IACP,IAAI,CAACD,eAAe;QAClBA,gBAAgBE,SAASC,aAAa,CAAC,UAAUC,UAAU,CAAC;QAC5D,IAAIJ,kBAAkB,MAAM;YAC1B,MAAM,IAAIK,MAAM;QAClB;IACF;IACA,OAAOL;AACT;AAEA;;CAEC,GACD,OAAO,SAASM,mBAAmB,EACjCC,IAAI,EACJC,UAAU,EACVC,KAAK,EACLC,MAAM,EACNC,UAAU,EACVC,OAAO,EACPC,gBAAgB,EACE;IAClB,MAAMC,MAAMb;IACZ,MAAM,EAAEc,YAAY,EAAE,GAAGhB;IAEzB,mGAAmG;IACnG,IAAIc,qBAAqBG,WAAW;QAClC,OAAOC,OAAOJ;IAChB;IAEA,MAAMK,YAAYH,aAAaG,SAAS;IACxC,MAAMC,WAAWF,OAAOC,WAAWC,aAAa;IAChD,MAAMC,aAAaF,WAAWE,cAAc;IAE5C,qCAAqC;IACrC,MAAMC,YAAY,GAAGb,WAAW,CAAC,EAAEW,SAAS,GAAG,EAAEC,YAAY;IAC7DN,IAAIQ,IAAI,GAAGD;IACX,0DAA0D;IAC1D,MAAME,cAA2BT,IAAIU,WAAW,CAACjB;IAEjD,uFAAuF;IACvF,MAAMkB,uBAAuB,AAAChB,QAAQc,YAAYd,KAAK,GAAIU;IAC3D,MAAMO,wBAAwBhB,SAASC;IAEvC,+BAA+B;IAC/B,MAAMgB,gBAAgBC,KAAKC,GAAG,CAACH,uBAAuBD;IACtD,OAAOb,UAAUgB,KAAKC,GAAG,CAACF,eAAef,WAAWe;AACtD"}
1
+ {"version":3,"sources":["../../../src/utils/calculate-font-size.ts"],"sourcesContent":["// Copyright 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 type { FontSizeOption } from '@perses-dev/components';\nimport { useChartsTheme } from '@perses-dev/components';\n\ninterface CalculateFontSize {\n text: string;\n fontWeight: number;\n width: number;\n height: number;\n lineHeight: number;\n maxSize?: number;\n fontSizeOverride?: FontSizeOption;\n}\n\nlet canvasContext: CanvasRenderingContext2D | null;\n\nfunction getGlobalCanvasContext(): CanvasRenderingContext2D {\n if (!canvasContext) {\n canvasContext = document.createElement('canvas').getContext('2d');\n if (canvasContext === null) {\n throw new Error('Canvas context is null.');\n }\n }\n return canvasContext;\n}\n\n/**\n * Find the optimal font size given available space\n */\nexport function useOptimalFontSize({\n text,\n fontWeight,\n width,\n height,\n lineHeight,\n maxSize,\n fontSizeOverride,\n}: CalculateFontSize): number {\n const ctx = getGlobalCanvasContext();\n const { echartsTheme } = useChartsTheme();\n\n // if user has selected a font size in the settings, use it instead of calculating the optimal size\n if (fontSizeOverride !== undefined) {\n return Number(fontSizeOverride);\n }\n\n const textStyle = echartsTheme.textStyle;\n const fontSize = Number(textStyle?.fontSize ?? 12);\n const fontFamily = textStyle?.fontFamily ?? 'Lato';\n\n // set the font on the canvas context\n const fontStyle = `${fontWeight} ${fontSize}px ${fontFamily}`;\n ctx.font = fontStyle;\n // measure the width of the text with the given font style\n const textMetrics: TextMetrics = ctx.measureText(text);\n\n // check how much bigger we can make the font while staying within the width and height\n const fontSizeBasedOnWidth = (width / textMetrics.width) * fontSize;\n const fontSizeBasedOnHeight = height / lineHeight;\n\n // return the smaller font size\n const finalFontSize = Math.min(fontSizeBasedOnHeight, fontSizeBasedOnWidth);\n return maxSize ? Math.min(finalFontSize, maxSize) : finalFontSize;\n}\n"],"names":["useChartsTheme","canvasContext","getGlobalCanvasContext","document","createElement","getContext","Error","useOptimalFontSize","text","fontWeight","width","height","lineHeight","maxSize","fontSizeOverride","ctx","echartsTheme","undefined","Number","textStyle","fontSize","fontFamily","fontStyle","font","textMetrics","measureText","fontSizeBasedOnWidth","fontSizeBasedOnHeight","finalFontSize","Math","min"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,cAAc,QAAQ,yBAAyB;AAYxD,IAAIC;AAEJ,SAASC;IACP,IAAI,CAACD,eAAe;QAClBA,gBAAgBE,SAASC,aAAa,CAAC,UAAUC,UAAU,CAAC;QAC5D,IAAIJ,kBAAkB,MAAM;YAC1B,MAAM,IAAIK,MAAM;QAClB;IACF;IACA,OAAOL;AACT;AAEA;;CAEC,GACD,OAAO,SAASM,mBAAmB,EACjCC,IAAI,EACJC,UAAU,EACVC,KAAK,EACLC,MAAM,EACNC,UAAU,EACVC,OAAO,EACPC,gBAAgB,EACE;IAClB,MAAMC,MAAMb;IACZ,MAAM,EAAEc,YAAY,EAAE,GAAGhB;IAEzB,mGAAmG;IACnG,IAAIc,qBAAqBG,WAAW;QAClC,OAAOC,OAAOJ;IAChB;IAEA,MAAMK,YAAYH,aAAaG,SAAS;IACxC,MAAMC,WAAWF,OAAOC,WAAWC,YAAY;IAC/C,MAAMC,aAAaF,WAAWE,cAAc;IAE5C,qCAAqC;IACrC,MAAMC,YAAY,GAAGb,WAAW,CAAC,EAAEW,SAAS,GAAG,EAAEC,YAAY;IAC7DN,IAAIQ,IAAI,GAAGD;IACX,0DAA0D;IAC1D,MAAME,cAA2BT,IAAIU,WAAW,CAACjB;IAEjD,uFAAuF;IACvF,MAAMkB,uBAAuB,AAAChB,QAAQc,YAAYd,KAAK,GAAIU;IAC3D,MAAMO,wBAAwBhB,SAASC;IAEvC,+BAA+B;IAC/B,MAAMgB,gBAAgBC,KAAKC,GAAG,CAACH,uBAAuBD;IACtD,OAAOb,UAAUgB,KAAKC,GAAG,CAACF,eAAef,WAAWe;AACtD"}
@@ -1,4 +1,5 @@
1
- import { CalculationsMap, CalculationType } from '@perses-dev/plugin-system';
2
- import { TimeSeries } from '@perses-dev/spec';
1
+ import type { CalculationType } from '@perses-dev/plugin-system';
2
+ import { CalculationsMap } from '@perses-dev/plugin-system';
3
+ import type { TimeSeries } from '@perses-dev/spec';
3
4
  export declare const calculateValue: (calculation: CalculationType, seriesData: TimeSeries) => ReturnType<(typeof CalculationsMap)[CalculationType]>;
4
5
  //# sourceMappingURL=calculate-value.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"calculate-value.d.ts","sourceRoot":"","sources":["../../../src/utils/calculate-value.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,eAAe,EAAE,eAAe,EAAuB,MAAM,2BAA2B,CAAC;AAClG,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAE9C,eAAO,MAAM,cAAc,GACzB,aAAa,eAAe,EAC5B,YAAY,UAAU,KACrB,UAAU,CAAC,CAAC,OAAO,eAAe,EAAE,eAAe,CAAC,CAMtD,CAAC"}
1
+ {"version":3,"file":"calculate-value.d.ts","sourceRoot":"","sources":["../../../src/utils/calculate-value.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,EAAE,eAAe,EAAuB,MAAM,2BAA2B,CAAC;AACjF,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAEnD,eAAO,MAAM,cAAc,GACzB,aAAa,eAAe,EAC5B,YAAY,UAAU,KACrB,UAAU,CAAC,CAAC,OAAO,eAAe,EAAE,eAAe,CAAC,CAMtD,CAAC"}
@@ -10,7 +10,7 @@
10
10
  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
- import { CalculationsMap, DEFAULT_CALCULATION } from '@perses-dev/plugin-system';
13
+ import { CalculationsMap, DEFAULT_CALCULATION } from "@perses-dev/plugin-system";
14
14
  export const calculateValue = (calculation, seriesData)=>{
15
15
  if (CalculationsMap[calculation] === undefined) {
16
16
  console.warn(`Invalid StatChart panel calculation ${calculation}, fallback to ${DEFAULT_CALCULATION}`);
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/utils/calculate-value.ts"],"sourcesContent":["// Copyright 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 { CalculationsMap, CalculationType, DEFAULT_CALCULATION } from '@perses-dev/plugin-system';\nimport { TimeSeries } from '@perses-dev/spec';\n\nexport const calculateValue = (\n calculation: CalculationType,\n seriesData: TimeSeries\n): ReturnType<(typeof CalculationsMap)[CalculationType]> => {\n if (CalculationsMap[calculation] === undefined) {\n console.warn(`Invalid StatChart panel calculation ${calculation}, fallback to ${DEFAULT_CALCULATION}`);\n }\n const calculate = CalculationsMap[calculation] ?? CalculationsMap[DEFAULT_CALCULATION];\n return calculate(seriesData.values);\n};\n"],"names":["CalculationsMap","DEFAULT_CALCULATION","calculateValue","calculation","seriesData","undefined","console","warn","calculate","values"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,eAAe,EAAmBC,mBAAmB,QAAQ,4BAA4B;AAGlG,OAAO,MAAMC,iBAAiB,CAC5BC,aACAC;IAEA,IAAIJ,eAAe,CAACG,YAAY,KAAKE,WAAW;QAC9CC,QAAQC,IAAI,CAAC,CAAC,oCAAoC,EAAEJ,YAAY,cAAc,EAAEF,qBAAqB;IACvG;IACA,MAAMO,YAAYR,eAAe,CAACG,YAAY,IAAIH,eAAe,CAACC,oBAAoB;IACtF,OAAOO,UAAUJ,WAAWK,MAAM;AACpC,EAAE"}
1
+ {"version":3,"sources":["../../../src/utils/calculate-value.ts"],"sourcesContent":["// Copyright 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 type { CalculationType } from '@perses-dev/plugin-system';\nimport { CalculationsMap, DEFAULT_CALCULATION } from '@perses-dev/plugin-system';\nimport type { TimeSeries } from '@perses-dev/spec';\n\nexport const calculateValue = (\n calculation: CalculationType,\n seriesData: TimeSeries,\n): ReturnType<(typeof CalculationsMap)[CalculationType]> => {\n if (CalculationsMap[calculation] === undefined) {\n console.warn(`Invalid StatChart panel calculation ${calculation}, fallback to ${DEFAULT_CALCULATION}`);\n }\n const calculate = CalculationsMap[calculation] ?? CalculationsMap[DEFAULT_CALCULATION];\n return calculate(seriesData.values);\n};\n"],"names":["CalculationsMap","DEFAULT_CALCULATION","calculateValue","calculation","seriesData","undefined","console","warn","calculate","values"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,eAAe,EAAEC,mBAAmB,QAAQ,4BAA4B;AAGjF,OAAO,MAAMC,iBAAiB,CAC5BC,aACAC;IAEA,IAAIJ,eAAe,CAACG,YAAY,KAAKE,WAAW;QAC9CC,QAAQC,IAAI,CAAC,CAAC,oCAAoC,EAAEJ,YAAY,cAAc,EAAEF,qBAAqB;IACvG;IACA,MAAMO,YAAYR,eAAe,CAACG,YAAY,IAAIH,eAAe,CAACC,oBAAoB;IACtF,OAAOO,UAAUJ,WAAWK,MAAM;AACpC,EAAE"}
@@ -1,5 +1,5 @@
1
- import { PersesChartsTheme } from '@perses-dev/components';
2
- import { LineSeriesOption } from 'echarts/charts';
3
- import { StatChartSparklineOptions } from '../stat-chart-model';
1
+ import type { PersesChartsTheme } from '@perses-dev/components';
2
+ import type { LineSeriesOption } from 'echarts/charts';
3
+ import type { StatChartSparklineOptions } from '../stat-chart-model';
4
4
  export declare function convertSparkline(chartsTheme: PersesChartsTheme, color: string, sparkline?: StatChartSparklineOptions): LineSeriesOption | undefined;
5
5
  //# sourceMappingURL=data-transform.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"data-transform.d.ts","sourceRoot":"","sources":["../../../src/utils/data-transform.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAEhE,wBAAgB,gBAAgB,CAC9B,WAAW,EAAE,iBAAiB,EAC9B,KAAK,EAAE,MAAM,EACb,SAAS,CAAC,EAAE,yBAAyB,GACpC,gBAAgB,GAAG,SAAS,CAc9B"}
1
+ {"version":3,"file":"data-transform.d.ts","sourceRoot":"","sources":["../../../src/utils/data-transform.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAChE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAEvD,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAErE,wBAAgB,gBAAgB,CAC9B,WAAW,EAAE,iBAAiB,EAC9B,KAAK,EAAE,MAAM,EACb,SAAS,CAAC,EAAE,yBAAyB,GACpC,gBAAgB,GAAG,SAAS,CAc9B"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/utils/data-transform.ts"],"sourcesContent":["// Copyright 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 { PersesChartsTheme } from '@perses-dev/components';\nimport { LineSeriesOption } from 'echarts/charts';\nimport { StatChartSparklineOptions } from '../stat-chart-model';\n\nexport function convertSparkline(\n chartsTheme: PersesChartsTheme,\n color: string,\n sparkline?: StatChartSparklineOptions\n): LineSeriesOption | undefined {\n if (sparkline === undefined) return;\n\n return {\n lineStyle: {\n width: sparkline.width ?? chartsTheme.sparkline.width,\n color,\n opacity: 1,\n },\n areaStyle: {\n color,\n opacity: 0.4,\n },\n };\n}\n"],"names":["convertSparkline","chartsTheme","color","sparkline","undefined","lineStyle","width","opacity","areaStyle"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAMjC,OAAO,SAASA,iBACdC,WAA8B,EAC9BC,KAAa,EACbC,SAAqC;IAErC,IAAIA,cAAcC,WAAW;IAE7B,OAAO;QACLC,WAAW;YACTC,OAAOH,UAAUG,KAAK,IAAIL,YAAYE,SAAS,CAACG,KAAK;YACrDJ;YACAK,SAAS;QACX;QACAC,WAAW;YACTN;YACAK,SAAS;QACX;IACF;AACF"}
1
+ {"version":3,"sources":["../../../src/utils/data-transform.ts"],"sourcesContent":["// Copyright 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 type { PersesChartsTheme } from '@perses-dev/components';\nimport type { LineSeriesOption } from 'echarts/charts';\n\nimport type { StatChartSparklineOptions } from '../stat-chart-model';\n\nexport function convertSparkline(\n chartsTheme: PersesChartsTheme,\n color: string,\n sparkline?: StatChartSparklineOptions,\n): LineSeriesOption | undefined {\n if (sparkline === undefined) return;\n\n return {\n lineStyle: {\n width: sparkline.width ?? chartsTheme.sparkline.width,\n color,\n opacity: 1,\n },\n areaStyle: {\n color,\n opacity: 0.4,\n },\n };\n}\n"],"names":["convertSparkline","chartsTheme","color","sparkline","undefined","lineStyle","width","opacity","areaStyle"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAOjC,OAAO,SAASA,iBACdC,WAA8B,EAC9BC,KAAa,EACbC,SAAqC;IAErC,IAAIA,cAAcC,WAAW;IAE7B,OAAO;QACLC,WAAW;YACTC,OAAOH,UAAUG,KAAK,IAAIL,YAAYE,SAAS,CAACG,KAAK;YACrDJ;YACAK,SAAS;QACX;QACAC,WAAW;YACTN;YACAK,SAAS;QACX;IACF;AACF"}
@@ -1,3 +1,3 @@
1
- import { FormatOptions } from '@perses-dev/components';
1
+ import type { FormatOptions } from '@perses-dev/components';
2
2
  export declare const formatStatChartValue: (value?: string | number | null, format?: FormatOptions) => string;
3
3
  //# sourceMappingURL=format-stat-chart-value.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"format-stat-chart-value.d.ts","sourceRoot":"","sources":["../../../src/utils/format-stat-chart-value.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,aAAa,EAAe,MAAM,wBAAwB,CAAC;AAEpE,eAAO,MAAM,oBAAoB,GAAI,QAAQ,MAAM,GAAG,MAAM,GAAG,IAAI,EAAE,SAAS,aAAa,KAAG,MAU7F,CAAC"}
1
+ {"version":3,"file":"format-stat-chart-value.d.ts","sourceRoot":"","sources":["../../../src/utils/format-stat-chart-value.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAG5D,eAAO,MAAM,oBAAoB,GAAI,QAAQ,MAAM,GAAG,MAAM,GAAG,IAAI,EAAE,SAAS,aAAa,KAAG,MAU7F,CAAC"}
@@ -10,7 +10,7 @@
10
10
  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
- import { formatValue } from '@perses-dev/components';
13
+ import { formatValue } from "@perses-dev/components";
14
14
  export const formatStatChartValue = (value, format)=>{
15
15
  if (value === null) {
16
16
  return 'null';
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/utils/format-stat-chart-value.ts"],"sourcesContent":["// Copyright 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 { FormatOptions, formatValue } from '@perses-dev/components';\n\nexport const formatStatChartValue = (value?: string | number | null, format?: FormatOptions): string => {\n if (value === null) {\n return 'null';\n } else if (typeof value === 'number') {\n return formatValue(value, format);\n } else if (value === undefined) {\n return '';\n } else {\n return value;\n }\n};\n"],"names":["formatValue","formatStatChartValue","value","format","undefined"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAAwBA,WAAW,QAAQ,yBAAyB;AAEpE,OAAO,MAAMC,uBAAuB,CAACC,OAAgCC;IACnE,IAAID,UAAU,MAAM;QAClB,OAAO;IACT,OAAO,IAAI,OAAOA,UAAU,UAAU;QACpC,OAAOF,YAAYE,OAAOC;IAC5B,OAAO,IAAID,UAAUE,WAAW;QAC9B,OAAO;IACT,OAAO;QACL,OAAOF;IACT;AACF,EAAE"}
1
+ {"version":3,"sources":["../../../src/utils/format-stat-chart-value.ts"],"sourcesContent":["// Copyright 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 type { FormatOptions } from '@perses-dev/components';\nimport { formatValue } from '@perses-dev/components';\n\nexport const formatStatChartValue = (value?: string | number | null, format?: FormatOptions): string => {\n if (value === null) {\n return 'null';\n } else if (typeof value === 'number') {\n return formatValue(value, format);\n } else if (value === undefined) {\n return '';\n } else {\n return value;\n }\n};\n"],"names":["formatValue","formatStatChartValue","value","format","undefined"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,WAAW,QAAQ,yBAAyB;AAErD,OAAO,MAAMC,uBAAuB,CAACC,OAAgCC;IACnE,IAAID,UAAU,MAAM;QAClB,OAAO;IACT,OAAO,IAAI,OAAOA,UAAU,UAAU;QACpC,OAAOF,YAAYE,OAAOC;IAC5B,OAAO,IAAID,UAAUE,WAAW;QAC9B,OAAO;IACT,OAAO;QACL,OAAOF;IACT;AACF,EAAE"}
@@ -1,5 +1,5 @@
1
- import { PersesChartsTheme } from '@perses-dev/components';
2
- import { StatChartOptions } from '../stat-chart-model';
1
+ import type { PersesChartsTheme } from '@perses-dev/components';
2
+ import type { StatChartOptions } from '../stat-chart-model';
3
3
  type StatChartValue = number | string | null;
4
4
  export declare function getStatChartColor(chartsTheme: PersesChartsTheme, spec?: StatChartOptions, value?: StatChartValue): string;
5
5
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"get-color.d.ts","sourceRoot":"","sources":["../../../src/utils/get-color.ts"],"names":[],"mappings":"AAaA,OAAO,EAAqB,iBAAiB,EAAkC,MAAM,wBAAwB,CAAC;AAC9G,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD,KAAK,cAAc,GAAG,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;AAE7C,wBAAgB,iBAAiB,CAC/B,WAAW,EAAE,iBAAiB,EAC9B,IAAI,CAAC,EAAE,gBAAgB,EACvB,KAAK,CAAC,EAAE,cAAc,GACrB,MAAM,CA4BR"}
1
+ {"version":3,"file":"get-color.d.ts","sourceRoot":"","sources":["../../../src/utils/get-color.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,iBAAiB,EAAkC,MAAM,wBAAwB,CAAC;AAGhG,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAE5D,KAAK,cAAc,GAAG,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;AAE7C,wBAAgB,iBAAiB,CAC/B,WAAW,EAAE,iBAAiB,EAC9B,IAAI,CAAC,EAAE,gBAAgB,EACvB,KAAK,CAAC,EAAE,cAAc,GACrB,MAAM,CA4BR"}
@@ -10,7 +10,7 @@
10
10
  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11
11
  // See the License for the specific language governing permissions and
12
12
  // limitations under the License.
13
- import { applyValueMapping } from '@perses-dev/components';
13
+ import { applyValueMapping } from "@perses-dev/components";
14
14
  export function getStatChartColor(chartsTheme, spec, value) {
15
15
  const { mappings, thresholds } = spec ?? {};
16
16
  // Determine the default color from thresholds or theme
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/utils/get-color.ts"],"sourcesContent":["// Copyright 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 { applyValueMapping, PersesChartsTheme, ThresholdOptions, ValueMapping } from '@perses-dev/components';\nimport { StatChartOptions } from '../stat-chart-model';\n\ntype StatChartValue = number | string | null;\n\nexport function getStatChartColor(\n chartsTheme: PersesChartsTheme,\n spec?: StatChartOptions,\n value?: StatChartValue\n): string {\n const { mappings, thresholds } = spec ?? {};\n\n // Determine the default color from thresholds or theme\n const defaultColor = thresholds?.defaultColor ?? chartsTheme.thresholds.defaultColor;\n\n if (value === undefined || value === null || value === '' || (!thresholds?.steps && !mappings)) {\n return defaultColor;\n }\n\n // Check mappings first\n if (mappings?.length) {\n const colorFromMappings = getColorFromMappings(value, mappings);\n if (colorFromMappings) {\n return colorFromMappings;\n }\n }\n\n // Check thresholds next\n if (thresholds) {\n const colorFromThresholds = getColorFromThresholds(value, thresholds, chartsTheme, defaultColor);\n if (colorFromThresholds) {\n return colorFromThresholds;\n }\n }\n\n // Fallback to default color\n return defaultColor;\n}\n\nfunction getColorFromMappings(value: StatChartValue, mappings: ValueMapping[]): string | null {\n if (mappings?.length && value !== undefined && value !== null) {\n const { color } = applyValueMapping(value, mappings);\n return color || null;\n }\n return null;\n}\n\nfunction getColorFromThresholds(\n value: StatChartValue,\n thresholds: ThresholdOptions,\n chartsTheme: PersesChartsTheme,\n defaultColor: string\n): string | null {\n if (thresholds?.steps && typeof value === 'number') {\n const matchingColors = thresholds.steps\n .map((step, index) => {\n if (value >= step.value) {\n return step.color ?? chartsTheme.thresholds.palette[index] ?? defaultColor;\n }\n return null;\n })\n .filter((color): color is string => color !== null);\n\n return matchingColors[matchingColors.length - 1] ?? null;\n }\n return null;\n}\n"],"names":["applyValueMapping","getStatChartColor","chartsTheme","spec","value","mappings","thresholds","defaultColor","undefined","steps","length","colorFromMappings","getColorFromMappings","colorFromThresholds","getColorFromThresholds","color","matchingColors","map","step","index","palette","filter"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAEjC,SAASA,iBAAiB,QAA2D,yBAAyB;AAK9G,OAAO,SAASC,kBACdC,WAA8B,EAC9BC,IAAuB,EACvBC,KAAsB;IAEtB,MAAM,EAAEC,QAAQ,EAAEC,UAAU,EAAE,GAAGH,QAAQ,CAAC;IAE1C,uDAAuD;IACvD,MAAMI,eAAeD,YAAYC,gBAAgBL,YAAYI,UAAU,CAACC,YAAY;IAEpF,IAAIH,UAAUI,aAAaJ,UAAU,QAAQA,UAAU,MAAO,CAACE,YAAYG,SAAS,CAACJ,UAAW;QAC9F,OAAOE;IACT;IAEA,uBAAuB;IACvB,IAAIF,UAAUK,QAAQ;QACpB,MAAMC,oBAAoBC,qBAAqBR,OAAOC;QACtD,IAAIM,mBAAmB;YACrB,OAAOA;QACT;IACF;IAEA,wBAAwB;IACxB,IAAIL,YAAY;QACd,MAAMO,sBAAsBC,uBAAuBV,OAAOE,YAAYJ,aAAaK;QACnF,IAAIM,qBAAqB;YACvB,OAAOA;QACT;IACF;IAEA,4BAA4B;IAC5B,OAAON;AACT;AAEA,SAASK,qBAAqBR,KAAqB,EAAEC,QAAwB;IAC3E,IAAIA,UAAUK,UAAUN,UAAUI,aAAaJ,UAAU,MAAM;QAC7D,MAAM,EAAEW,KAAK,EAAE,GAAGf,kBAAkBI,OAAOC;QAC3C,OAAOU,SAAS;IAClB;IACA,OAAO;AACT;AAEA,SAASD,uBACPV,KAAqB,EACrBE,UAA4B,EAC5BJ,WAA8B,EAC9BK,YAAoB;IAEpB,IAAID,YAAYG,SAAS,OAAOL,UAAU,UAAU;QAClD,MAAMY,iBAAiBV,WAAWG,KAAK,CACpCQ,GAAG,CAAC,CAACC,MAAMC;YACV,IAAIf,SAASc,KAAKd,KAAK,EAAE;gBACvB,OAAOc,KAAKH,KAAK,IAAIb,YAAYI,UAAU,CAACc,OAAO,CAACD,MAAM,IAAIZ;YAChE;YACA,OAAO;QACT,GACCc,MAAM,CAAC,CAACN,QAA2BA,UAAU;QAEhD,OAAOC,cAAc,CAACA,eAAeN,MAAM,GAAG,EAAE,IAAI;IACtD;IACA,OAAO;AACT"}
1
+ {"version":3,"sources":["../../../src/utils/get-color.ts"],"sourcesContent":["// Copyright 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 type { PersesChartsTheme, ThresholdOptions, ValueMapping } from '@perses-dev/components';\nimport { applyValueMapping } from '@perses-dev/components';\n\nimport type { StatChartOptions } from '../stat-chart-model';\n\ntype StatChartValue = number | string | null;\n\nexport function getStatChartColor(\n chartsTheme: PersesChartsTheme,\n spec?: StatChartOptions,\n value?: StatChartValue,\n): string {\n const { mappings, thresholds } = spec ?? {};\n\n // Determine the default color from thresholds or theme\n const defaultColor = thresholds?.defaultColor ?? chartsTheme.thresholds.defaultColor;\n\n if (value === undefined || value === null || value === '' || (!thresholds?.steps && !mappings)) {\n return defaultColor;\n }\n\n // Check mappings first\n if (mappings?.length) {\n const colorFromMappings = getColorFromMappings(value, mappings);\n if (colorFromMappings) {\n return colorFromMappings;\n }\n }\n\n // Check thresholds next\n if (thresholds) {\n const colorFromThresholds = getColorFromThresholds(value, thresholds, chartsTheme, defaultColor);\n if (colorFromThresholds) {\n return colorFromThresholds;\n }\n }\n\n // Fallback to default color\n return defaultColor;\n}\n\nfunction getColorFromMappings(value: StatChartValue, mappings: ValueMapping[]): string | null {\n if (mappings?.length && value !== undefined && value !== null) {\n const { color } = applyValueMapping(value, mappings);\n return color || null;\n }\n return null;\n}\n\nfunction getColorFromThresholds(\n value: StatChartValue,\n thresholds: ThresholdOptions,\n chartsTheme: PersesChartsTheme,\n defaultColor: string,\n): string | null {\n if (thresholds?.steps && typeof value === 'number') {\n const matchingColors = thresholds.steps\n .map((step, index) => {\n if (value >= step.value) {\n return step.color ?? chartsTheme.thresholds.palette[index] ?? defaultColor;\n }\n return null;\n })\n .filter((color): color is string => color !== null);\n\n return matchingColors[matchingColors.length - 1] ?? null;\n }\n return null;\n}\n"],"names":["applyValueMapping","getStatChartColor","chartsTheme","spec","value","mappings","thresholds","defaultColor","undefined","steps","length","colorFromMappings","getColorFromMappings","colorFromThresholds","getColorFromThresholds","color","matchingColors","map","step","index","palette","filter"],"mappings":"AAAA,+BAA+B;AAC/B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAGjC,SAASA,iBAAiB,QAAQ,yBAAyB;AAM3D,OAAO,SAASC,kBACdC,WAA8B,EAC9BC,IAAuB,EACvBC,KAAsB;IAEtB,MAAM,EAAEC,QAAQ,EAAEC,UAAU,EAAE,GAAGH,QAAQ,CAAC;IAE1C,uDAAuD;IACvD,MAAMI,eAAeD,YAAYC,gBAAgBL,YAAYI,UAAU,CAACC,YAAY;IAEpF,IAAIH,UAAUI,aAAaJ,UAAU,QAAQA,UAAU,MAAO,CAACE,YAAYG,SAAS,CAACJ,UAAW;QAC9F,OAAOE;IACT;IAEA,uBAAuB;IACvB,IAAIF,UAAUK,QAAQ;QACpB,MAAMC,oBAAoBC,qBAAqBR,OAAOC;QACtD,IAAIM,mBAAmB;YACrB,OAAOA;QACT;IACF;IAEA,wBAAwB;IACxB,IAAIL,YAAY;QACd,MAAMO,sBAAsBC,uBAAuBV,OAAOE,YAAYJ,aAAaK;QACnF,IAAIM,qBAAqB;YACvB,OAAOA;QACT;IACF;IAEA,4BAA4B;IAC5B,OAAON;AACT;AAEA,SAASK,qBAAqBR,KAAqB,EAAEC,QAAwB;IAC3E,IAAIA,UAAUK,UAAUN,UAAUI,aAAaJ,UAAU,MAAM;QAC7D,MAAM,EAAEW,KAAK,EAAE,GAAGf,kBAAkBI,OAAOC;QAC3C,OAAOU,SAAS;IAClB;IACA,OAAO;AACT;AAEA,SAASD,uBACPV,KAAqB,EACrBE,UAA4B,EAC5BJ,WAA8B,EAC9BK,YAAoB;IAEpB,IAAID,YAAYG,SAAS,OAAOL,UAAU,UAAU;QAClD,MAAMY,iBAAiBV,WAAWG,KAAK,CACpCQ,GAAG,CAAC,CAACC,MAAMC;YACV,IAAIf,SAASc,KAAKd,KAAK,EAAE;gBACvB,OAAOc,KAAKH,KAAK,IAAIb,YAAYI,UAAU,CAACc,OAAO,CAACD,MAAM,IAAIZ;YAChE;YACA,OAAO;QACT,GACCc,MAAM,CAAC,CAACN,QAA2BA,UAAU;QAEhD,OAAOC,cAAc,CAACA,eAAeN,MAAM,GAAG,EAAE,IAAI;IACtD;IACA,OAAO;AACT"}
package/mf-manifest.json CHANGED
@@ -5,11 +5,11 @@
5
5
  "name": "StatChart",
6
6
  "type": "app",
7
7
  "buildInfo": {
8
- "buildVersion": "0.14.0",
8
+ "buildVersion": "0.15.0-beta.1",
9
9
  "buildName": "@perses-dev/stat-chart-plugin"
10
10
  },
11
11
  "remoteEntry": {
12
- "name": "__mf/js/StatChart.19a287b0.js",
12
+ "name": "__mf/js/StatChart.cfc077f0.js",
13
13
  "path": "",
14
14
  "type": "global"
15
15
  },
@@ -19,9 +19,9 @@
19
19
  "zip": "",
20
20
  "api": ""
21
21
  },
22
- "globalName": "StatChart",
22
+ "globalName": "StatChart_0_15_0_beta_1",
23
23
  "pluginVersion": "2.6.0",
24
- "getPublicPath": "function() { const prefix = window.PERSES_PLUGIN_ASSETS_PATH || window.PERSES_APP_CONFIG?.api_prefix || \"\"; return prefix + \"/plugins/StatChart/\"; }"
24
+ "getPublicPath": "function() { const prefix = window.PERSES_PLUGIN_ASSETS_PATH || window.PERSES_APP_CONFIG?.api_prefix || \"\"; return prefix + \"/plugins/StatChart~0.15.0-beta.1/\"; }"
25
25
  },
26
26
  "shared": [
27
27
  {
@@ -34,7 +34,7 @@
34
34
  "js": {
35
35
  "async": [],
36
36
  "sync": [
37
- "__mf/js/async/274.b762faf5.js"
37
+ "__mf/js/async/274.7345c704.js"
38
38
  ]
39
39
  },
40
40
  "css": {
@@ -54,8 +54,8 @@
54
54
  "js": {
55
55
  "async": [],
56
56
  "sync": [
57
- "__mf/js/async/235.f388b6fd.js",
58
- "__mf/js/async/616.22b37336.js"
57
+ "__mf/js/async/235.c6d2c4f5.js",
58
+ "__mf/js/async/616.6b72e257.js"
59
59
  ]
60
60
  },
61
61
  "css": {
@@ -75,8 +75,8 @@
75
75
  "js": {
76
76
  "async": [],
77
77
  "sync": [
78
- "__mf/js/async/587.7d22fb82.js",
79
- "__mf/js/async/968.bfd3594f.js"
78
+ "__mf/js/async/587.7eb542f2.js",
79
+ "__mf/js/async/968.ebdf1f2d.js"
80
80
  ]
81
81
  },
82
82
  "css": {
@@ -89,20 +89,20 @@
89
89
  {
90
90
  "id": "StatChart:@perses-dev/components",
91
91
  "name": "@perses-dev/components",
92
- "version": "0.54.0",
92
+ "version": "0.55.0-beta.6",
93
93
  "singleton": true,
94
- "requiredVersion": "^0.54.0",
94
+ "requiredVersion": "^0.55.0-beta.6",
95
95
  "assets": {
96
96
  "js": {
97
97
  "async": [],
98
98
  "sync": [
99
- "__mf/js/async/187.d7e6b2db.js"
99
+ "__mf/js/async/449.6d8fc8b3.js"
100
100
  ]
101
101
  },
102
102
  "css": {
103
103
  "async": [],
104
104
  "sync": [
105
- "__mf/css/async/187.85c2cbf6.css"
105
+ "__mf/css/async/449.85c2cbf6.css"
106
106
  ]
107
107
  }
108
108
  },
@@ -111,14 +111,14 @@
111
111
  {
112
112
  "id": "StatChart:@perses-dev/plugin-system",
113
113
  "name": "@perses-dev/plugin-system",
114
- "version": "0.54.0",
114
+ "version": "0.55.0-beta.6",
115
115
  "singleton": true,
116
- "requiredVersion": "^0.54.0",
116
+ "requiredVersion": "^0.55.0-beta.6",
117
117
  "assets": {
118
118
  "js": {
119
119
  "async": [],
120
120
  "sync": [
121
- "__mf/js/async/546.f27d00a1.js"
121
+ "__mf/js/async/354.6ea77f69.js"
122
122
  ]
123
123
  },
124
124
  "css": {
@@ -138,27 +138,7 @@
138
138
  "js": {
139
139
  "async": [],
140
140
  "sync": [
141
- "__mf/js/async/192.0b251884.js"
142
- ]
143
- },
144
- "css": {
145
- "async": [],
146
- "sync": []
147
- }
148
- },
149
- "fallback": ""
150
- },
151
- {
152
- "id": "StatChart:echarts",
153
- "name": "echarts",
154
- "version": "5.5.0",
155
- "singleton": true,
156
- "requiredVersion": "^undefined",
157
- "assets": {
158
- "js": {
159
- "async": [],
160
- "sync": [
161
- "__mf/js/async/873.13ff7de6.js"
141
+ "__mf/js/async/192.6939be34.js"
162
142
  ]
163
143
  },
164
144
  "css": {
@@ -178,7 +158,7 @@
178
158
  "js": {
179
159
  "async": [],
180
160
  "sync": [
181
- "__mf/js/async/392.70b1a3c5.js"
161
+ "__mf/js/async/392.559f0a15.js"
182
162
  ]
183
163
  },
184
164
  "css": {
@@ -198,7 +178,7 @@
198
178
  "js": {
199
179
  "async": [],
200
180
  "sync": [
201
- "__mf/js/async/470.cc046da0.js"
181
+ "__mf/js/async/470.16a500aa.js"
202
182
  ]
203
183
  },
204
184
  "css": {
@@ -218,27 +198,7 @@
218
198
  "js": {
219
199
  "async": [],
220
200
  "sync": [
221
- "__mf/js/async/121.a33651ce.js"
222
- ]
223
- },
224
- "css": {
225
- "async": [],
226
- "sync": []
227
- }
228
- },
229
- "fallback": ""
230
- },
231
- {
232
- "id": "StatChart:date-fns-tz",
233
- "name": "date-fns-tz",
234
- "version": "3.2.0",
235
- "singleton": true,
236
- "requiredVersion": "^3.2.0",
237
- "assets": {
238
- "js": {
239
- "async": [],
240
- "sync": [
241
- "__mf/js/async/978.98475f4b.js"
201
+ "__mf/js/async/121.dd7133cb.js"
242
202
  ]
243
203
  },
244
204
  "css": {
@@ -257,26 +217,22 @@
257
217
  "assets": {
258
218
  "js": {
259
219
  "sync": [
260
- "__mf/js/async/465.7c60371f.js",
261
- "__mf/js/async/866.cb6cbc7a.js",
262
- "__mf/js/async/721.5c1c6916.js",
263
- "__mf/js/async/570.264704d1.js",
264
- "__mf/js/async/__federation_expose_StatChart.f4a2f598.js"
220
+ "__mf/js/async/970.f5882828.js",
221
+ "__mf/js/async/866.d7ad9e7a.js",
222
+ "__mf/js/async/570.34dc9996.js",
223
+ "__mf/js/async/__federation_expose_StatChart.7973125b.js"
265
224
  ],
266
225
  "async": [
267
- "__mf/js/async/588.c00e3759.js",
268
- "__mf/js/async/71.1f2caf38.js",
269
- "__mf/js/async/580.4076ee7b.js",
270
- "__mf/js/async/450.bdfbd76f.js",
271
- "__mf/js/async/lib-router.6c58ccc7.js",
272
- "__mf/js/async/356.3f7b970d.js",
273
- "__mf/js/async/177.4dddf131.js"
226
+ "__mf/js/async/345.242802c4.js",
227
+ "__mf/js/async/663.2de74425.js",
228
+ "__mf/js/async/lib-router.73f6cef1.js",
229
+ "__mf/js/async/356.b00937de.js"
274
230
  ]
275
231
  },
276
232
  "css": {
277
233
  "sync": [],
278
234
  "async": [
279
- "__mf/css/async/187.85c2cbf6.css"
235
+ "__mf/css/async/449.85c2cbf6.css"
280
236
  ]
281
237
  }
282
238
  },