@perses-dev/status-history-chart-plugin 0.13.0 → 0.14.0-beta.2
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.
- package/__mf/js/StatusHistoryChart.b562e547.js +7 -0
- package/__mf/js/async/121.7c7dfd24.js +2 -0
- package/__mf/js/async/192.e0378d27.js +1 -0
- package/__mf/js/async/2.854844cd.js +1 -0
- package/__mf/js/async/235.7a97cc35.js +1 -0
- package/__mf/js/async/274.ba37d2a5.js +2 -0
- package/__mf/js/async/356.c6abe355.js +1 -0
- package/__mf/js/async/392.28f62ac0.js +2 -0
- package/__mf/js/async/470.5e20d4ce.js +2 -0
- package/__mf/js/async/481.c5d339b8.js +2 -0
- package/__mf/js/async/496.e922287d.js +1 -0
- package/__mf/js/async/525.581e52cb.js +2 -0
- package/__mf/js/async/587.8c8aa1fd.js +1 -0
- package/__mf/js/async/588.478d90f1.js +1 -0
- package/__mf/js/async/616.66d420a8.js +1 -0
- package/__mf/js/async/623.5838e6aa.js +1 -0
- package/__mf/js/async/628.447b1f89.js +3 -0
- package/__mf/js/async/644.06760cb8.js +110 -0
- package/__mf/js/async/71.2c2c2fe4.js +1 -0
- package/__mf/js/async/77.f97bba54.js +1 -0
- package/__mf/js/async/788.d10cf35c.js +43 -0
- package/__mf/js/async/{464.d426dd00.js.LICENSE.txt → 788.d10cf35c.js.LICENSE.txt} +41 -1
- package/__mf/js/async/873.6eef1fae.js +1 -0
- package/__mf/js/async/941.b4bb3575.js +2 -0
- package/__mf/js/async/947.3bd98a2b.js +2 -0
- package/__mf/js/async/968.f63cc1d1.js +1 -0
- package/__mf/js/async/978.63d6babd.js +1 -0
- package/__mf/js/async/__federation_expose_StatusHistoryChart.fb6fe4d9.js +23 -0
- package/__mf/js/async/lib-router.67526781.js +2 -0
- package/__mf/js/{main.3e9b5ca3.js → main.91a9d666.js} +2 -2
- package/lib/StatusHistoryChart.d.ts +3 -3
- package/lib/StatusHistoryChart.d.ts.map +1 -1
- package/lib/StatusHistoryChart.js +4 -4
- package/lib/StatusHistoryChart.js.map +1 -1
- package/lib/StatusHistoryChartBase.d.ts +3 -3
- package/lib/StatusHistoryChartBase.d.ts.map +1 -1
- package/lib/StatusHistoryChartBase.js +10 -10
- package/lib/StatusHistoryChartBase.js.map +1 -1
- package/lib/StatusHistoryChartOptionsEditorSettings.d.ts +2 -2
- package/lib/StatusHistoryChartOptionsEditorSettings.d.ts.map +1 -1
- package/lib/StatusHistoryChartOptionsEditorSettings.js +4 -4
- package/lib/StatusHistoryChartOptionsEditorSettings.js.map +1 -1
- package/lib/StatusHistoryPanel.d.ts +4 -4
- package/lib/StatusHistoryPanel.d.ts.map +1 -1
- package/lib/StatusHistoryPanel.js +7 -7
- package/lib/StatusHistoryPanel.js.map +1 -1
- package/lib/StatusHistoryTooltip.d.ts +2 -2
- package/lib/StatusHistoryTooltip.d.ts.map +1 -1
- package/lib/StatusHistoryTooltip.js +2 -2
- package/lib/StatusHistoryTooltip.js.map +1 -1
- package/lib/StatusHistoryValueMappingEditor.d.ts +3 -3
- package/lib/StatusHistoryValueMappingEditor.d.ts.map +1 -1
- package/lib/StatusHistoryValueMappingEditor.js +1 -1
- package/lib/StatusHistoryValueMappingEditor.js.map +1 -1
- package/lib/bootstrap.js +2 -2
- package/lib/getPluginModule.d.ts +1 -1
- package/lib/getPluginModule.d.ts.map +1 -1
- package/lib/getPluginModule.js +3 -1
- package/lib/getPluginModule.js.map +1 -1
- package/lib/index-federation.js +1 -1
- package/lib/index.js +6 -6
- package/lib/index.js.map +1 -1
- package/lib/setup-tests.d.ts +1 -1
- package/lib/setup-tests.d.ts.map +1 -1
- package/lib/setup-tests.js +2 -2
- package/lib/setup-tests.js.map +1 -1
- package/lib/status-history-model.d.ts +2 -2
- package/lib/status-history-model.d.ts.map +1 -1
- package/lib/status-history-model.js.map +1 -1
- package/lib/utils/data-transform.d.ts +5 -5
- package/lib/utils/data-transform.d.ts.map +1 -1
- package/lib/utils/data-transform.js +4 -4
- package/lib/utils/data-transform.js.map +1 -1
- package/lib/utils/get-color.js +1 -2
- package/lib/utils/get-color.js.map +1 -1
- package/lib/utils/get-formatted-axis-label.js +1 -1
- package/lib/utils/get-timescale.d.ts +2 -2
- package/lib/utils/get-timescale.d.ts.map +1 -1
- package/lib/utils/get-timescale.js +1 -1
- package/lib/utils/get-timescale.js.map +1 -1
- package/lib/utils/get-tooltip-position.d.ts +1 -1
- package/lib/utils/get-tooltip-position.d.ts.map +1 -1
- package/lib/utils/get-tooltip-position.js.map +1 -1
- package/lib/utils/index.js +5 -5
- package/lib/utils/index.js.map +1 -1
- package/mf-manifest.json +35 -34
- package/mf-stats.json +37 -36
- package/package.json +10 -10
- package/__mf/js/StatusHistoryChart.946b9620.js +0 -7
- package/__mf/js/async/121.4774256d.js +0 -2
- package/__mf/js/async/177.b42019ec.js +0 -1
- package/__mf/js/async/187.e35200d2.js +0 -7
- package/__mf/js/async/187.e35200d2.js.LICENSE.txt +0 -39
- package/__mf/js/async/189.50a773ab.js +0 -2
- package/__mf/js/async/192.5c2ccbc8.js +0 -1
- package/__mf/js/async/2.51860681.js +0 -1
- package/__mf/js/async/235.82ceb925.js +0 -1
- package/__mf/js/async/274.00260b59.js +0 -2
- package/__mf/js/async/356.3f5befdf.js +0 -1
- package/__mf/js/async/392.6e9f16f1.js +0 -2
- package/__mf/js/async/464.d426dd00.js +0 -39
- package/__mf/js/async/470.d7ccfb94.js +0 -2
- package/__mf/js/async/481.7e46c8f8.js +0 -1
- package/__mf/js/async/525.9cf2cd99.js +0 -2
- package/__mf/js/async/558.68d38020.js +0 -1
- package/__mf/js/async/587.96ffef24.js +0 -1
- package/__mf/js/async/588.09ddb723.js +0 -1
- package/__mf/js/async/616.d292bca5.js +0 -1
- package/__mf/js/async/623.d2ed4458.js +0 -1
- package/__mf/js/async/644.51078a40.js +0 -110
- package/__mf/js/async/71.88cfb0f7.js +0 -1
- package/__mf/js/async/873.3b862492.js +0 -1
- package/__mf/js/async/941.8225ba98.js +0 -2
- package/__mf/js/async/968.bd2564b8.js +0 -1
- package/__mf/js/async/978.144b77a4.js +0 -1
- package/__mf/js/async/981.5ec29a41.js +0 -24
- package/__mf/js/async/981.5ec29a41.js.LICENSE.txt +0 -19
- package/__mf/js/async/__federation_expose_StatusHistoryChart.c43ab053.js +0 -23
- package/__mf/js/async/lib-router.33e6a460.js +0 -2
- package/lib/cjs/StatusHistoryChart.js +0 -43
- package/lib/cjs/StatusHistoryChartBase.js +0 -147
- package/lib/cjs/StatusHistoryChartOptionsEditorSettings.js +0 -78
- package/lib/cjs/StatusHistoryPanel.js +0 -77
- package/lib/cjs/StatusHistoryTooltip.js +0 -55
- package/lib/cjs/StatusHistoryValueMappingEditor.js +0 -36
- package/lib/cjs/bootstrap.js +0 -26
- package/lib/cjs/env.d.js +0 -14
- package/lib/cjs/getPluginModule.js +0 -39
- package/lib/cjs/index-federation.js +0 -55
- package/lib/cjs/index.js +0 -41
- package/lib/cjs/setup-tests.js +0 -19
- package/lib/cjs/status-history-model.js +0 -25
- package/lib/cjs/utils/data-transform.js +0 -136
- package/lib/cjs/utils/get-color.js +0 -125
- package/lib/cjs/utils/get-formatted-axis-label.js +0 -48
- package/lib/cjs/utils/get-timescale.js +0 -27
- package/lib/cjs/utils/get-tooltip-position.js +0 -35
- package/lib/cjs/utils/index.js +0 -34
- /package/__mf/css/async/{187.85c2cbf6.css → 788.85c2cbf6.css} +0 -0
- /package/__mf/js/async/{121.4774256d.js.LICENSE.txt → 121.7c7dfd24.js.LICENSE.txt} +0 -0
- /package/__mf/js/async/{274.00260b59.js.LICENSE.txt → 274.ba37d2a5.js.LICENSE.txt} +0 -0
- /package/__mf/js/async/{392.6e9f16f1.js.LICENSE.txt → 392.28f62ac0.js.LICENSE.txt} +0 -0
- /package/__mf/js/async/{470.d7ccfb94.js.LICENSE.txt → 470.5e20d4ce.js.LICENSE.txt} +0 -0
- /package/__mf/js/async/{189.50a773ab.js.LICENSE.txt → 481.c5d339b8.js.LICENSE.txt} +0 -0
- /package/__mf/js/async/{525.9cf2cd99.js.LICENSE.txt → 525.581e52cb.js.LICENSE.txt} +0 -0
- /package/__mf/js/async/{644.51078a40.js.LICENSE.txt → 644.06760cb8.js.LICENSE.txt} +0 -0
- /package/__mf/js/async/{941.8225ba98.js.LICENSE.txt → 941.b4bb3575.js.LICENSE.txt} +0 -0
- /package/__mf/js/async/{lib-router.33e6a460.js.LICENSE.txt → lib-router.67526781.js.LICENSE.txt} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/StatusHistoryChart.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 { PanelPlugin } from '@perses-dev/plugin-system';\n\nimport {
|
|
1
|
+
{"version":3,"sources":["../../src/StatusHistoryChart.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 { PanelPlugin } from '@perses-dev/plugin-system';\n\nimport type { StatusHistoryChartOptions } from './status-history-model';\nimport { createInitialStatusHistoryChartOptions } from './status-history-model';\nimport { StatusHistoryChartOptionsEditorSettings } from './StatusHistoryChartOptionsEditorSettings';\nimport type { StatusHistoryChartPanelProps } from './StatusHistoryPanel';\nimport { StatusHistoryPanel } from './StatusHistoryPanel';\nimport { StatusHistoryValueMappingEditor } from './StatusHistoryValueMappingEditor';\n\nexport const StatusHistoryChart: PanelPlugin<StatusHistoryChartOptions, StatusHistoryChartPanelProps> = {\n PanelComponent: StatusHistoryPanel,\n supportedQueryTypes: ['TimeSeriesQuery'],\n panelOptionsEditorComponents: [\n { label: 'Settings', content: StatusHistoryChartOptionsEditorSettings },\n { label: 'Value mapping', content: StatusHistoryValueMappingEditor },\n ],\n createInitialOptions: createInitialStatusHistoryChartOptions,\n};\n"],"names":["createInitialStatusHistoryChartOptions","StatusHistoryChartOptionsEditorSettings","StatusHistoryPanel","StatusHistoryValueMappingEditor","StatusHistoryChart","PanelComponent","supportedQueryTypes","panelOptionsEditorComponents","label","content","createInitialOptions"],"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;AAKjC,SAASA,sCAAsC,QAAQ,4BAAyB;AAChF,SAASC,uCAAuC,QAAQ,+CAA4C;AAEpG,SAASC,kBAAkB,QAAQ,0BAAuB;AAC1D,SAASC,+BAA+B,QAAQ,uCAAoC;AAEpF,OAAO,MAAMC,qBAA2F;IACtGC,gBAAgBH;IAChBI,qBAAqB;QAAC;KAAkB;IACxCC,8BAA8B;QAC5B;YAAEC,OAAO;YAAYC,SAASR;QAAwC;QACtE;YAAEO,OAAO;YAAiBC,SAASN;QAAgC;KACpE;IACDO,sBAAsBV;AACxB,EAAE"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import type { TimeScale } from '@perses-dev/spec';
|
|
2
|
+
import type { LegendComponentOption } from 'echarts/components';
|
|
3
|
+
import type { FC } from 'react';
|
|
4
4
|
export type StatusHistoryData = [number, number, number | undefined];
|
|
5
5
|
export interface StatusHistoryDataItem {
|
|
6
6
|
value: StatusHistoryData;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusHistoryChartBase.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryChartBase.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"StatusHistoryChartBase.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryChartBase.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAGlD,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAUhE,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAehC,MAAM,MAAM,iBAAiB,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,CAAC;AAErE,MAAM,WAAW,qBAAqB;IACpC,KAAK,EAAE,iBAAiB,CAAC;IACzB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,SAAS,CAAC,EAAE;QACV,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,CAAC;CACH;AAED,MAAM,WAAW,2BAA2B;IAC1C,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,qBAAqB,EAAE,CAAC;IAC9B,eAAe,EAAE,MAAM,EAAE,CAAC;IAC1B,eAAe,EAAE,MAAM,EAAE,CAAC;IAC1B,MAAM,CAAC,EAAE,qBAAqB,CAAC;IAC/B,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,MAAM,CAAC,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,GAAG,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CAC3D;AAED,eAAO,MAAM,sBAAsB,EAAE,EAAE,CAAC,2BAA2B,CA8GlE,CAAC"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
1
|
// Copyright The Perses Authors
|
|
3
2
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
3
|
// you may not use this file except in compliance with the License.
|
|
@@ -11,15 +10,16 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
11
10
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
11
|
// See the License for the specific language governing permissions and
|
|
13
12
|
// limitations under the License.
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import { generateTooltipHTML } from
|
|
22
|
-
|
|
13
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
|
+
import { Box, Typography, useTheme } from "@mui/material";
|
|
15
|
+
import { EChart, useChartsTheme, useTimeZone } from "@perses-dev/components";
|
|
16
|
+
import { HeatmapChart as EChartsHeatmapChart } from "echarts/charts";
|
|
17
|
+
import { GridComponent, DatasetComponent, TitleComponent, TooltipComponent, VisualMapComponent } from "echarts/components";
|
|
18
|
+
import { use as registerECharts } from "echarts/core";
|
|
19
|
+
import { CanvasRenderer } from "echarts/renderers";
|
|
20
|
+
import { generateTooltipHTML } from "./StatusHistoryTooltip.js";
|
|
21
|
+
import { getFormattedStatusHistoryAxisLabel } from "./utils/get-formatted-axis-label.js";
|
|
22
|
+
registerECharts([
|
|
23
23
|
EChartsHeatmapChart,
|
|
24
24
|
VisualMapComponent,
|
|
25
25
|
GridComponent,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/StatusHistoryChartBase.tsx"],"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 { Box,
|
|
1
|
+
{"version":3,"sources":["../../src/StatusHistoryChartBase.tsx"],"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 { SxProps } from '@mui/material';\nimport { Box, Typography, useTheme } from '@mui/material';\nimport { EChart, useChartsTheme, useTimeZone } from '@perses-dev/components';\nimport type { TimeScale } from '@perses-dev/spec';\nimport type { EChartsCoreOption, TitleComponentOption } from 'echarts';\nimport { HeatmapChart as EChartsHeatmapChart } from 'echarts/charts';\nimport type { LegendComponentOption } from 'echarts/components';\nimport {\n GridComponent,\n DatasetComponent,\n TitleComponent,\n TooltipComponent,\n VisualMapComponent,\n} from 'echarts/components';\nimport { use as registerECharts } from 'echarts/core';\nimport { CanvasRenderer } from 'echarts/renderers';\nimport type { FC } from 'react';\n\nimport { generateTooltipHTML } from './StatusHistoryTooltip';\nimport { getFormattedStatusHistoryAxisLabel } from './utils/get-formatted-axis-label';\n\nregisterECharts([\n EChartsHeatmapChart,\n VisualMapComponent,\n GridComponent,\n DatasetComponent,\n TitleComponent,\n TooltipComponent,\n CanvasRenderer,\n]);\n\nexport type StatusHistoryData = [number, number, number | undefined];\n\nexport interface StatusHistoryDataItem {\n value: StatusHistoryData;\n label?: string;\n itemStyle?: {\n color?: string;\n borderColor?: string;\n borderWidth?: number;\n };\n}\n\nexport interface StatusHistoryChartBaseProps {\n height: number;\n data: StatusHistoryDataItem[];\n xAxisCategories: number[];\n yAxisCategories: string[];\n legend?: LegendComponentOption;\n timeScale?: TimeScale;\n colors?: Array<{ value: number | string; color: string }>;\n}\n\nexport const StatusHistoryChartBase: FC<StatusHistoryChartBaseProps> = (props) => {\n const { height, data, xAxisCategories, yAxisCategories, timeScale, colors } = props;\n\n const { timeZone } = useTimeZone();\n const chartsTheme = useChartsTheme();\n const theme = useTheme();\n\n const noDataTextStyle = (chartsTheme.noDataOption.title as TitleComponentOption).textStyle as SxProps;\n\n const option: EChartsCoreOption = {\n tooltip: {\n appendToBody: true,\n formatter: (params: { data: StatusHistoryDataItem; marker: string }) => {\n return generateTooltipHTML({\n data: params.data.value,\n label: params.data.label,\n marker: params.marker,\n xAxisCategories,\n yAxisCategories,\n theme,\n });\n },\n },\n grid: {\n top: '5%',\n bottom: '5%',\n },\n xAxis: {\n type: 'category',\n data: xAxisCategories,\n axisLine: {\n show: false,\n },\n splitArea: {\n show: false,\n },\n axisLabel: {\n hideOverlap: true,\n formatter: getFormattedStatusHistoryAxisLabel(timeScale?.rangeMs ?? 0, timeZone),\n },\n },\n yAxis: {\n type: 'category',\n data: yAxisCategories,\n axisLine: {\n show: false,\n },\n splitArea: {\n show: false,\n interval: 0,\n },\n splitLine: {\n show: false,\n },\n axisLabel: {\n interval: 0,\n },\n },\n visualMap: {\n show: false,\n type: 'piecewise',\n pieces: colors,\n },\n series: [\n {\n name: 'Status history',\n type: 'heatmap',\n coordinateSystem: 'cartesian2d',\n data: data,\n label: {\n show: false,\n },\n itemStyle: {\n borderWidth: 1,\n borderType: 'solid',\n borderColor: '#ffffff',\n },\n emphasis: {\n itemStyle: {\n opacity: 0.5,\n },\n },\n },\n ],\n };\n\n return (\n <Box\n style={{ height: height }}\n sx={{\n overflow: 'auto',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n }}\n >\n {data.length ? (\n <EChart\n style={{\n width: '100%',\n height: height,\n }}\n option={option}\n theme={chartsTheme.echartsTheme}\n />\n ) : (\n <Typography sx={{ ...noDataTextStyle }}>No data</Typography>\n )}\n </Box>\n );\n};\n"],"names":["Box","Typography","useTheme","EChart","useChartsTheme","useTimeZone","HeatmapChart","EChartsHeatmapChart","GridComponent","DatasetComponent","TitleComponent","TooltipComponent","VisualMapComponent","use","registerECharts","CanvasRenderer","generateTooltipHTML","getFormattedStatusHistoryAxisLabel","StatusHistoryChartBase","props","height","data","xAxisCategories","yAxisCategories","timeScale","colors","timeZone","chartsTheme","theme","noDataTextStyle","noDataOption","title","textStyle","option","tooltip","appendToBody","formatter","params","value","label","marker","grid","top","bottom","xAxis","type","axisLine","show","splitArea","axisLabel","hideOverlap","rangeMs","yAxis","interval","splitLine","visualMap","pieces","series","name","coordinateSystem","itemStyle","borderWidth","borderType","borderColor","emphasis","opacity","style","sx","overflow","display","justifyContent","alignItems","length","width","echartsTheme"],"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,GAAG,EAAEC,UAAU,EAAEC,QAAQ,QAAQ,gBAAgB;AAC1D,SAASC,MAAM,EAAEC,cAAc,EAAEC,WAAW,QAAQ,yBAAyB;AAG7E,SAASC,gBAAgBC,mBAAmB,QAAQ,iBAAiB;AAErE,SACEC,aAAa,EACbC,gBAAgB,EAChBC,cAAc,EACdC,gBAAgB,EAChBC,kBAAkB,QACb,qBAAqB;AAC5B,SAASC,OAAOC,eAAe,QAAQ,eAAe;AACtD,SAASC,cAAc,QAAQ,oBAAoB;AAGnD,SAASC,mBAAmB,QAAQ,4BAAyB;AAC7D,SAASC,kCAAkC,QAAQ,sCAAmC;AAEtFH,gBAAgB;IACdP;IACAK;IACAJ;IACAC;IACAC;IACAC;IACAI;CACD;AAwBD,OAAO,MAAMG,yBAA0D,CAACC;IACtE,MAAM,EAAEC,MAAM,EAAEC,IAAI,EAAEC,eAAe,EAAEC,eAAe,EAAEC,SAAS,EAAEC,MAAM,EAAE,GAAGN;IAE9E,MAAM,EAAEO,QAAQ,EAAE,GAAGrB;IACrB,MAAMsB,cAAcvB;IACpB,MAAMwB,QAAQ1B;IAEd,MAAM2B,kBAAkB,AAACF,YAAYG,YAAY,CAACC,KAAK,CAA0BC,SAAS;IAE1F,MAAMC,SAA4B;QAChCC,SAAS;YACPC,cAAc;YACdC,WAAW,CAACC;gBACV,OAAOrB,oBAAoB;oBACzBK,MAAMgB,OAAOhB,IAAI,CAACiB,KAAK;oBACvBC,OAAOF,OAAOhB,IAAI,CAACkB,KAAK;oBACxBC,QAAQH,OAAOG,MAAM;oBACrBlB;oBACAC;oBACAK;gBACF;YACF;QACF;QACAa,MAAM;YACJC,KAAK;YACLC,QAAQ;QACV;QACAC,OAAO;YACLC,MAAM;YACNxB,MAAMC;YACNwB,UAAU;gBACRC,MAAM;YACR;YACAC,WAAW;gBACTD,MAAM;YACR;YACAE,WAAW;gBACTC,aAAa;gBACbd,WAAWnB,mCAAmCO,WAAW2B,WAAW,GAAGzB;YACzE;QACF;QACA0B,OAAO;YACLP,MAAM;YACNxB,MAAME;YACNuB,UAAU;gBACRC,MAAM;YACR;YACAC,WAAW;gBACTD,MAAM;gBACNM,UAAU;YACZ;YACAC,WAAW;gBACTP,MAAM;YACR;YACAE,WAAW;gBACTI,UAAU;YACZ;QACF;QACAE,WAAW;YACTR,MAAM;YACNF,MAAM;YACNW,QAAQ/B;QACV;QACAgC,QAAQ;YACN;gBACEC,MAAM;gBACNb,MAAM;gBACNc,kBAAkB;gBAClBtC,MAAMA;gBACNkB,OAAO;oBACLQ,MAAM;gBACR;gBACAa,WAAW;oBACTC,aAAa;oBACbC,YAAY;oBACZC,aAAa;gBACf;gBACAC,UAAU;oBACRJ,WAAW;wBACTK,SAAS;oBACX;gBACF;YACF;SACD;IACH;IAEA,qBACE,KAACjE;QACCkE,OAAO;YAAE9C,QAAQA;QAAO;QACxB+C,IAAI;YACFC,UAAU;YACVC,SAAS;YACTC,gBAAgB;YAChBC,YAAY;QACd;kBAEClD,KAAKmD,MAAM,iBACV,KAACrE;YACC+D,OAAO;gBACLO,OAAO;gBACPrD,QAAQA;YACV;YACAa,QAAQA;YACRL,OAAOD,YAAY+C,YAAY;2BAGjC,KAACzE;YAAWkE,IAAI;gBAAE,GAAGtC,eAAe;YAAC;sBAAG;;;AAIhD,EAAE"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ReactElement } from 'react';
|
|
2
|
-
import { StatusHistroyChartEditorProps } from './status-history-model.js';
|
|
1
|
+
import type { ReactElement } from 'react';
|
|
2
|
+
import type { StatusHistroyChartEditorProps } from './status-history-model.js';
|
|
3
3
|
export declare function StatusHistoryChartOptionsEditorSettings(props: StatusHistroyChartEditorProps): ReactElement;
|
|
4
4
|
//# sourceMappingURL=StatusHistoryChartOptionsEditorSettings.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusHistoryChartOptionsEditorSettings.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryChartOptionsEditorSettings.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"StatusHistoryChartOptionsEditorSettings.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryChartOptionsEditorSettings.tsx"],"names":[],"mappings":"AAmBA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAE1C,OAAO,KAAK,EAA6B,6BAA6B,EAAE,MAAM,2BAA2B,CAAC;AAE1G,wBAAgB,uCAAuC,CAAC,KAAK,EAAE,6BAA6B,GAAG,YAAY,CAqD1G"}
|
|
@@ -11,10 +11,10 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
11
11
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
12
|
// See the License for the specific language governing permissions and
|
|
13
13
|
// limitations under the License.
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
14
|
+
import { Button } from "@mui/material";
|
|
15
|
+
import { OptionsEditorGroup, OptionsEditorGrid, OptionsEditorColumn, SortSelector } from "@perses-dev/components";
|
|
16
|
+
import { LegendOptionsEditor } from "@perses-dev/plugin-system";
|
|
17
|
+
import { produce } from "immer";
|
|
18
18
|
export function StatusHistoryChartOptionsEditorSettings(props) {
|
|
19
19
|
const { onChange, value } = props;
|
|
20
20
|
const handleLegendChange = (newLegend)=>{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/StatusHistoryChartOptionsEditorSettings.tsx"],"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 {
|
|
1
|
+
{"version":3,"sources":["../../src/StatusHistoryChartOptionsEditorSettings.tsx"],"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 { Button } from '@mui/material';\nimport type { SortOption, SortSelectorProps } from '@perses-dev/components';\nimport { OptionsEditorGroup, OptionsEditorGrid, OptionsEditorColumn, SortSelector } from '@perses-dev/components';\nimport type { LegendOptionsEditorProps } from '@perses-dev/plugin-system';\nimport { LegendOptionsEditor } from '@perses-dev/plugin-system';\nimport { produce } from 'immer';\nimport type { ReactElement } from 'react';\n\nimport type { StatusHistoryChartOptions, StatusHistroyChartEditorProps } from './status-history-model.js';\n\nexport function StatusHistoryChartOptionsEditorSettings(props: StatusHistroyChartEditorProps): ReactElement {\n const { onChange, value } = props;\n\n const handleLegendChange: LegendOptionsEditorProps['onChange'] = (newLegend) => {\n // TODO (sjcobb): fix type, add position, fix glitch\n onChange(\n produce(value, (draft: StatusHistoryChartOptions) => {\n draft.legend = newLegend;\n }),\n );\n };\n\n const handleSortChange: SortSelectorProps['onChange'] = (newSort: SortOption) => {\n onChange(\n produce(value, (draft: StatusHistoryChartOptions) => {\n draft.sorting = newSort;\n }),\n );\n };\n\n return (\n <OptionsEditorGrid>\n <OptionsEditorColumn>\n <LegendOptionsEditor\n calculation=\"aggregation\"\n showValuesEditor={false}\n value={value.legend}\n onChange={handleLegendChange}\n />\n <OptionsEditorGroup title=\"Visual\">\n <SortSelector value={value.sorting} onChange={handleSortChange} />\n </OptionsEditorGroup>\n </OptionsEditorColumn>\n <OptionsEditorColumn>\n <OptionsEditorGroup title=\"Reset Settings\">\n <Button\n variant=\"outlined\"\n color=\"secondary\"\n onClick={() => {\n onChange(\n produce(value, (draft: StatusHistoryChartOptions) => {\n // reset button removes all optional panel options\n draft.legend = undefined;\n }),\n );\n }}\n >\n Reset To Defaults\n </Button>\n </OptionsEditorGroup>\n </OptionsEditorColumn>\n </OptionsEditorGrid>\n );\n}\n"],"names":["Button","OptionsEditorGroup","OptionsEditorGrid","OptionsEditorColumn","SortSelector","LegendOptionsEditor","produce","StatusHistoryChartOptionsEditorSettings","props","onChange","value","handleLegendChange","newLegend","draft","legend","handleSortChange","newSort","sorting","calculation","showValuesEditor","title","variant","color","onClick","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,SAASA,MAAM,QAAQ,gBAAgB;AAEvC,SAASC,kBAAkB,EAAEC,iBAAiB,EAAEC,mBAAmB,EAAEC,YAAY,QAAQ,yBAAyB;AAElH,SAASC,mBAAmB,QAAQ,4BAA4B;AAChE,SAASC,OAAO,QAAQ,QAAQ;AAKhC,OAAO,SAASC,wCAAwCC,KAAoC;IAC1F,MAAM,EAAEC,QAAQ,EAAEC,KAAK,EAAE,GAAGF;IAE5B,MAAMG,qBAA2D,CAACC;QAChE,oDAAoD;QACpDH,SACEH,QAAQI,OAAO,CAACG;YACdA,MAAMC,MAAM,GAAGF;QACjB;IAEJ;IAEA,MAAMG,mBAAkD,CAACC;QACvDP,SACEH,QAAQI,OAAO,CAACG;YACdA,MAAMI,OAAO,GAAGD;QAClB;IAEJ;IAEA,qBACE,MAACd;;0BACC,MAACC;;kCACC,KAACE;wBACCa,aAAY;wBACZC,kBAAkB;wBAClBT,OAAOA,MAAMI,MAAM;wBACnBL,UAAUE;;kCAEZ,KAACV;wBAAmBmB,OAAM;kCACxB,cAAA,KAAChB;4BAAaM,OAAOA,MAAMO,OAAO;4BAAER,UAAUM;;;;;0BAGlD,KAACZ;0BACC,cAAA,KAACF;oBAAmBmB,OAAM;8BACxB,cAAA,KAACpB;wBACCqB,SAAQ;wBACRC,OAAM;wBACNC,SAAS;4BACPd,SACEH,QAAQI,OAAO,CAACG;gCACd,kDAAkD;gCAClDA,MAAMC,MAAM,GAAGU;4BACjB;wBAEJ;kCACD;;;;;;AAOX"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { PanelProps } from '@perses-dev/plugin-system';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { StatusHistoryChartOptions } from './status-history-model.js';
|
|
1
|
+
import type { PanelProps } from '@perses-dev/plugin-system';
|
|
2
|
+
import type { TimeSeriesData } from '@perses-dev/spec';
|
|
3
|
+
import type { ReactElement } from 'react';
|
|
4
|
+
import type { StatusHistoryChartOptions } from './status-history-model.js';
|
|
5
5
|
export type StatusHistoryChartPanelProps = PanelProps<StatusHistoryChartOptions, TimeSeriesData>;
|
|
6
6
|
export declare function StatusHistoryPanel(props: StatusHistoryChartPanelProps): ReactElement | null;
|
|
7
7
|
//# sourceMappingURL=StatusHistoryPanel.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusHistoryPanel.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryPanel.tsx"],"names":[],"mappings":"AAeA,OAAO,EAAE,UAAU,
|
|
1
|
+
{"version":3,"file":"StatusHistoryPanel.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryPanel.tsx"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAE5D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAEvD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAG1C,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,2BAA2B,CAAC;AAI3E,MAAM,MAAM,4BAA4B,GAAG,UAAU,CAAC,yBAAyB,EAAE,cAAc,CAAC,CAAC;AAEjG,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,4BAA4B,GAAG,YAAY,GAAG,IAAI,CAoD3F"}
|
|
@@ -11,13 +11,13 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
11
11
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
12
|
// See the License for the specific language governing permissions and
|
|
13
13
|
// limitations under the License.
|
|
14
|
-
import { Box } from
|
|
15
|
-
import { ContentWithLegend, useChartsTheme } from
|
|
16
|
-
import { validateLegendSpec } from
|
|
17
|
-
import { merge } from
|
|
18
|
-
import { useMemo } from
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
14
|
+
import { Box } from "@mui/material";
|
|
15
|
+
import { ContentWithLegend, useChartsTheme } from "@perses-dev/components";
|
|
16
|
+
import { validateLegendSpec } from "@perses-dev/plugin-system";
|
|
17
|
+
import { merge } from "lodash";
|
|
18
|
+
import { useMemo } from "react";
|
|
19
|
+
import { StatusHistoryChartBase } from "./StatusHistoryChartBase.js";
|
|
20
|
+
import { useStatusHistoryDataModel } from "./utils/data-transform.js";
|
|
21
21
|
export function StatusHistoryPanel(props) {
|
|
22
22
|
const { spec, contentDimensions, queryResults } = props;
|
|
23
23
|
const legend = useMemo(()=>{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/StatusHistoryPanel.tsx"],"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 { Box } from '@mui/material';\nimport { ContentWithLegend, useChartsTheme } from '@perses-dev/components';\nimport { PanelProps
|
|
1
|
+
{"version":3,"sources":["../../src/StatusHistoryPanel.tsx"],"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 { Box } from '@mui/material';\nimport { ContentWithLegend, useChartsTheme } from '@perses-dev/components';\nimport type { PanelProps } from '@perses-dev/plugin-system';\nimport { validateLegendSpec } from '@perses-dev/plugin-system';\nimport type { TimeSeriesData } from '@perses-dev/spec';\nimport { merge } from 'lodash';\nimport type { ReactElement } from 'react';\nimport { useMemo } from 'react';\n\nimport type { StatusHistoryChartOptions } from './status-history-model.js';\nimport { StatusHistoryChartBase } from './StatusHistoryChartBase';\nimport { useStatusHistoryDataModel } from './utils/data-transform';\n\nexport type StatusHistoryChartPanelProps = PanelProps<StatusHistoryChartOptions, TimeSeriesData>;\n\nexport function StatusHistoryPanel(props: StatusHistoryChartPanelProps): ReactElement | null {\n const { spec, contentDimensions, queryResults } = props;\n\n const legend = useMemo(() => {\n return spec.legend && validateLegendSpec(spec.legend) ? merge({}, spec.legend) : undefined;\n }, [spec.legend]);\n\n const chartsTheme = useChartsTheme();\n const PADDING = chartsTheme.container.padding.default;\n\n const { statusHistoryData, yAxisCategories, xAxisCategories, legendItems, timeScale, colors } =\n useStatusHistoryDataModel(queryResults, chartsTheme.echartsTheme.color as string[], spec);\n\n const adjustedContentDimensions: typeof contentDimensions = contentDimensions\n ? {\n width: contentDimensions.width - PADDING * 2,\n height: contentDimensions.height - PADDING * 2,\n }\n : undefined;\n\n return (\n <Box sx={{ padding: `${PADDING}px` }}>\n <ContentWithLegend\n width={adjustedContentDimensions?.width ?? 400}\n height={adjustedContentDimensions?.height ?? 1000}\n legendSize={legend?.size}\n legendProps={\n legend && {\n options: legend,\n data: legendItems || [],\n selectedItems: 'ALL',\n onSelectedItemsChange: () => null,\n }\n }\n >\n {({ height, width }) => {\n return (\n <Box sx={{ height, width }}>\n <StatusHistoryChartBase\n xAxisCategories={xAxisCategories}\n yAxisCategories={yAxisCategories}\n data={statusHistoryData ?? []}\n timeScale={timeScale}\n height={height}\n colors={colors}\n />\n </Box>\n );\n }}\n </ContentWithLegend>\n </Box>\n );\n}\n"],"names":["Box","ContentWithLegend","useChartsTheme","validateLegendSpec","merge","useMemo","StatusHistoryChartBase","useStatusHistoryDataModel","StatusHistoryPanel","props","spec","contentDimensions","queryResults","legend","undefined","chartsTheme","PADDING","container","padding","default","statusHistoryData","yAxisCategories","xAxisCategories","legendItems","timeScale","colors","echartsTheme","color","adjustedContentDimensions","width","height","sx","legendSize","size","legendProps","options","data","selectedItems","onSelectedItemsChange"],"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,GAAG,QAAQ,gBAAgB;AACpC,SAASC,iBAAiB,EAAEC,cAAc,QAAQ,yBAAyB;AAE3E,SAASC,kBAAkB,QAAQ,4BAA4B;AAE/D,SAASC,KAAK,QAAQ,SAAS;AAE/B,SAASC,OAAO,QAAQ,QAAQ;AAGhC,SAASC,sBAAsB,QAAQ,8BAA2B;AAClE,SAASC,yBAAyB,QAAQ,4BAAyB;AAInE,OAAO,SAASC,mBAAmBC,KAAmC;IACpE,MAAM,EAAEC,IAAI,EAAEC,iBAAiB,EAAEC,YAAY,EAAE,GAAGH;IAElD,MAAMI,SAASR,QAAQ;QACrB,OAAOK,KAAKG,MAAM,IAAIV,mBAAmBO,KAAKG,MAAM,IAAIT,MAAM,CAAC,GAAGM,KAAKG,MAAM,IAAIC;IACnF,GAAG;QAACJ,KAAKG,MAAM;KAAC;IAEhB,MAAME,cAAcb;IACpB,MAAMc,UAAUD,YAAYE,SAAS,CAACC,OAAO,CAACC,OAAO;IAErD,MAAM,EAAEC,iBAAiB,EAAEC,eAAe,EAAEC,eAAe,EAAEC,WAAW,EAAEC,SAAS,EAAEC,MAAM,EAAE,GAC3FlB,0BAA0BK,cAAcG,YAAYW,YAAY,CAACC,KAAK,EAAcjB;IAEtF,MAAMkB,4BAAsDjB,oBACxD;QACEkB,OAAOlB,kBAAkBkB,KAAK,GAAGb,UAAU;QAC3Cc,QAAQnB,kBAAkBmB,MAAM,GAAGd,UAAU;IAC/C,IACAF;IAEJ,qBACE,KAACd;QAAI+B,IAAI;YAAEb,SAAS,GAAGF,QAAQ,EAAE,CAAC;QAAC;kBACjC,cAAA,KAACf;YACC4B,OAAOD,2BAA2BC,SAAS;YAC3CC,QAAQF,2BAA2BE,UAAU;YAC7CE,YAAYnB,QAAQoB;YACpBC,aACErB,UAAU;gBACRsB,SAAStB;gBACTuB,MAAMb,eAAe,EAAE;gBACvBc,eAAe;gBACfC,uBAAuB,IAAM;YAC/B;sBAGD,CAAC,EAAER,MAAM,EAAED,KAAK,EAAE;gBACjB,qBACE,KAAC7B;oBAAI+B,IAAI;wBAAED;wBAAQD;oBAAM;8BACvB,cAAA,KAACvB;wBACCgB,iBAAiBA;wBACjBD,iBAAiBA;wBACjBe,MAAMhB,qBAAqB,EAAE;wBAC7BI,WAAWA;wBACXM,QAAQA;wBACRL,QAAQA;;;YAIhB;;;AAIR"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Theme } from '@mui/material';
|
|
2
|
-
import { StatusHistoryData } from './StatusHistoryChartBase';
|
|
1
|
+
import type { Theme } from '@mui/material';
|
|
2
|
+
import type { StatusHistoryData } from './StatusHistoryChartBase';
|
|
3
3
|
interface CustomTooltipProps {
|
|
4
4
|
data: StatusHistoryData;
|
|
5
5
|
label?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusHistoryTooltip.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryTooltip.ts"],"names":[],"mappings":"AAaA,OAAO,
|
|
1
|
+
{"version":3,"file":"StatusHistoryTooltip.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryTooltip.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAI3C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAElE,UAAU,kBAAkB;IAC1B,IAAI,EAAE,iBAAiB,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,eAAe,EAAE,MAAM,EAAE,CAAC;IAC1B,eAAe,EAAE,MAAM,EAAE,CAAC;IAC1B,KAAK,EAAE,KAAK,CAAC;CACd;AAED,wBAAgB,mBAAmB,CAAC,EAClC,IAAI,EACJ,KAAK,EACL,MAAM,EACN,eAAe,EACf,eAAe,EACf,KAAK,GACN,EAAE,kBAAkB,GAAG,MAAM,CAmC7B"}
|
|
@@ -10,8 +10,8 @@
|
|
|
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 { css } from
|
|
14
|
-
import { getDateAndTime } from
|
|
13
|
+
import { css } from "@mui/material";
|
|
14
|
+
import { getDateAndTime } from "@perses-dev/components";
|
|
15
15
|
export function generateTooltipHTML({ data, label, marker, xAxisCategories, yAxisCategories, theme }) {
|
|
16
16
|
const [x, y] = data;
|
|
17
17
|
const xAxisLabel = xAxisCategories[x];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/StatusHistoryTooltip.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 {
|
|
1
|
+
{"version":3,"sources":["../../src/StatusHistoryTooltip.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 { Theme } from '@mui/material';\nimport { css } from '@mui/material';\nimport { getDateAndTime } from '@perses-dev/components';\n\nimport type { StatusHistoryData } from './StatusHistoryChartBase';\n\ninterface CustomTooltipProps {\n data: StatusHistoryData;\n label?: string;\n marker: string;\n xAxisCategories: number[];\n yAxisCategories: string[];\n theme: Theme;\n}\n\nexport function generateTooltipHTML({\n data,\n label,\n marker,\n xAxisCategories,\n yAxisCategories,\n theme,\n}: CustomTooltipProps): string {\n const [x, y] = data;\n const xAxisLabel = xAxisCategories[x];\n\n const { formattedDate, formattedTime } = getDateAndTime(xAxisLabel);\n\n const tooltipHeader = css`\n border-bottom: 1px solid ${theme.palette.grey[500]};\n padding-bottom: 8px;\n `;\n\n const tooltipContentStyles = css`\n display: flex;\n justify-content: space-between;\n padding-top: 8px;\n `;\n\n const labelStyles = css`\n margin-right: 16px;\n `;\n\n return `\n <div>\n <div style=\"${tooltipHeader.styles}\">${formattedDate} - ${formattedTime}</div>\n <div style=\"${tooltipContentStyles.styles}\">\n <div style=\"${labelStyles.styles}\">\n ${marker}\n <strong>${yAxisCategories[y]}</strong>\n </div>\n <div>\n ${label}\n </div>\n </div>\n </div>\n `;\n}\n"],"names":["css","getDateAndTime","generateTooltipHTML","data","label","marker","xAxisCategories","yAxisCategories","theme","x","y","xAxisLabel","formattedDate","formattedTime","tooltipHeader","palette","grey","tooltipContentStyles","labelStyles","styles"],"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,GAAG,QAAQ,gBAAgB;AACpC,SAASC,cAAc,QAAQ,yBAAyB;AAaxD,OAAO,SAASC,oBAAoB,EAClCC,IAAI,EACJC,KAAK,EACLC,MAAM,EACNC,eAAe,EACfC,eAAe,EACfC,KAAK,EACc;IACnB,MAAM,CAACC,GAAGC,EAAE,GAAGP;IACf,MAAMQ,aAAaL,eAAe,CAACG,EAAE;IAErC,MAAM,EAAEG,aAAa,EAAEC,aAAa,EAAE,GAAGZ,eAAeU;IAExD,MAAMG,gBAAgBd,GAAG,CAAC;6BACC,EAAEQ,MAAMO,OAAO,CAACC,IAAI,CAAC,IAAI,CAAC;;EAErD,CAAC;IAED,MAAMC,uBAAuBjB,GAAG,CAAC;;;;EAIjC,CAAC;IAED,MAAMkB,cAAclB,GAAG,CAAC;;EAExB,CAAC;IAED,OAAO,CAAC;;kBAEQ,EAAEc,cAAcK,MAAM,CAAC,EAAE,EAAEP,cAAc,GAAG,EAAEC,cAAc;kBAC5D,EAAEI,qBAAqBE,MAAM,CAAC;oBAC5B,EAAED,YAAYC,MAAM,CAAC;UAC/B,EAAEd,OAAO;kBACD,EAAEE,eAAe,CAACG,EAAE,CAAC;;;UAG7B,EAAEN,MAAM;;;;EAIhB,CAAC;AACH"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { OptionsEditorProps } from '@perses-dev/plugin-system';
|
|
2
|
-
import { FC } from 'react';
|
|
3
|
-
import { StatusHistoryChartOptions } from './status-history-model';
|
|
1
|
+
import type { OptionsEditorProps } from '@perses-dev/plugin-system';
|
|
2
|
+
import type { FC } from 'react';
|
|
3
|
+
import type { StatusHistoryChartOptions } from './status-history-model';
|
|
4
4
|
export type StatusHistoryValueMappingEditorProps = OptionsEditorProps<StatusHistoryChartOptions>;
|
|
5
5
|
export declare const StatusHistoryValueMappingEditor: FC<StatusHistoryValueMappingEditorProps>;
|
|
6
6
|
//# sourceMappingURL=StatusHistoryValueMappingEditor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusHistoryValueMappingEditor.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryValueMappingEditor.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"StatusHistoryValueMappingEditor.d.ts","sourceRoot":"","sources":["../../src/StatusHistoryValueMappingEditor.tsx"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAEhC,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,wBAAwB,CAAC;AAExE,MAAM,MAAM,oCAAoC,GAAG,kBAAkB,CAAC,yBAAyB,CAAC,CAAC;AAEjG,eAAO,MAAM,+BAA+B,EAAE,EAAE,CAAC,oCAAoC,CAMpF,CAAC"}
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
// See the License for the specific language governing permissions and
|
|
12
12
|
// limitations under the License.
|
|
13
13
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
|
-
import { ValueMappingsEditor } from
|
|
14
|
+
import { ValueMappingsEditor } from "@perses-dev/components";
|
|
15
15
|
export const StatusHistoryValueMappingEditor = ({ onChange, value })=>{
|
|
16
16
|
function handleValueMappingChange(mappings) {
|
|
17
17
|
onChange({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/StatusHistoryValueMappingEditor.tsx"],"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 {
|
|
1
|
+
{"version":3,"sources":["../../src/StatusHistoryValueMappingEditor.tsx"],"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 { ValueMapping } from '@perses-dev/components';\nimport { ValueMappingsEditor } from '@perses-dev/components';\nimport type { OptionsEditorProps } from '@perses-dev/plugin-system';\nimport type { FC } from 'react';\n\nimport type { StatusHistoryChartOptions } from './status-history-model';\n\nexport type StatusHistoryValueMappingEditorProps = OptionsEditorProps<StatusHistoryChartOptions>;\n\nexport const StatusHistoryValueMappingEditor: FC<StatusHistoryValueMappingEditorProps> = ({ onChange, value }) => {\n function handleValueMappingChange(mappings: ValueMapping[]): void {\n onChange({ ...value, mappings });\n }\n\n return <ValueMappingsEditor mappings={value.mappings ?? []} onChange={handleValueMappingChange} />;\n};\n"],"names":["ValueMappingsEditor","StatusHistoryValueMappingEditor","onChange","value","handleValueMappingChange","mappings"],"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,mBAAmB,QAAQ,yBAAyB;AAQ7D,OAAO,MAAMC,kCAA4E,CAAC,EAAEC,QAAQ,EAAEC,KAAK,EAAE;IAC3G,SAASC,yBAAyBC,QAAwB;QACxDH,SAAS;YAAE,GAAGC,KAAK;YAAEE;QAAS;IAChC;IAEA,qBAAO,KAACL;QAAoBK,UAAUF,MAAME,QAAQ,IAAI,EAAE;QAAEH,UAAUE;;AACxE,EAAE"}
|
package/lib/bootstrap.js
CHANGED
|
@@ -11,8 +11,8 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
11
11
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
12
|
// See the License for the specific language governing permissions and
|
|
13
13
|
// limitations under the License.
|
|
14
|
-
import React from
|
|
15
|
-
import ReactDOM from
|
|
14
|
+
import React from "react";
|
|
15
|
+
import ReactDOM from "react-dom/client";
|
|
16
16
|
const root = ReactDOM.createRoot(document.getElementById('root'));
|
|
17
17
|
root.render(/*#__PURE__*/ _jsx(React.StrictMode, {}));
|
|
18
18
|
|
package/lib/getPluginModule.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getPluginModule.d.ts","sourceRoot":"","sources":["../../src/getPluginModule.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,oBAAoB,EAAoB,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"getPluginModule.d.ts","sourceRoot":"","sources":["../../src/getPluginModule.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,oBAAoB,EAAoB,MAAM,2BAA2B,CAAC;AAIxF;;GAEG;AACH,wBAAgB,eAAe,IAAI,oBAAoB,CAUtD"}
|
package/lib/getPluginModule.js
CHANGED
|
@@ -10,7 +10,9 @@
|
|
|
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 packageJson from
|
|
13
|
+
import packageJson from "../package.json" with {
|
|
14
|
+
type: 'json'
|
|
15
|
+
};
|
|
14
16
|
/**
|
|
15
17
|
* Returns the plugin module information from package.json
|
|
16
18
|
*/ export function getPluginModule() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/getPluginModule.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 { PluginModuleResource, PluginModuleSpec } from '@perses-dev/plugin-system';\nimport packageJson from '../package.json';\n\n/**\n * Returns the plugin module information from package.json\n */\nexport function getPluginModule(): PluginModuleResource {\n const { name, version, perses } = packageJson;\n return {\n kind: 'PluginModule',\n metadata: {\n name,\n version,\n },\n spec: perses as PluginModuleSpec,\n };\n}\n"],"names":["packageJson","getPluginModule","name","version","perses","kind","metadata","spec"],"mappings":"AAAA,+BAA+B;AAC/B,oEAAoE;AACpE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,sEAAsE;AACtE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;
|
|
1
|
+
{"version":3,"sources":["../../src/getPluginModule.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 { PluginModuleResource, PluginModuleSpec } from '@perses-dev/plugin-system';\n\nimport packageJson from '../package.json' with { type: 'json' };\n\n/**\n * Returns the plugin module information from package.json\n */\nexport function getPluginModule(): PluginModuleResource {\n const { name, version, perses } = packageJson;\n return {\n kind: 'PluginModule',\n metadata: {\n name,\n version,\n },\n spec: perses as PluginModuleSpec,\n };\n}\n"],"names":["packageJson","type","getPluginModule","name","version","perses","kind","metadata","spec"],"mappings":"AAAA,+BAA+B;AAC/B,oEAAoE;AACpE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,6CAA6C;AAC7C,EAAE;AACF,sEAAsE;AACtE,sEAAsE;AACtE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;AAIjC,OAAOA,iBAAiB,uBAAuB;IAAEC,MAAM;AAAO,EAAE;AAEhE;;CAEC,GACD,OAAO,SAASC;IACd,MAAM,EAAEC,IAAI,EAAEC,OAAO,EAAEC,MAAM,EAAE,GAAGL;IAClC,OAAO;QACLM,MAAM;QACNC,UAAU;YACRJ;YACAC;QACF;QACAI,MAAMH;IACR;AACF"}
|
package/lib/index-federation.js
CHANGED
|
@@ -10,6 +10,6 @@
|
|
|
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(
|
|
13
|
+
import("./bootstrap.js");
|
|
14
14
|
|
|
15
15
|
//# sourceMappingURL=index-federation.js.map
|
package/lib/index.js
CHANGED
|
@@ -10,11 +10,11 @@
|
|
|
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
|
-
export { getPluginModule } from
|
|
14
|
-
export * from
|
|
15
|
-
export * from
|
|
16
|
-
export * from
|
|
17
|
-
export * from
|
|
18
|
-
export * from
|
|
13
|
+
export { getPluginModule } from "./getPluginModule.js";
|
|
14
|
+
export * from "./status-history-model.js";
|
|
15
|
+
export * from "./StatusHistoryChart.js";
|
|
16
|
+
export * from "./StatusHistoryChartOptionsEditorSettings.js";
|
|
17
|
+
export * from "./StatusHistoryPanel.js";
|
|
18
|
+
export * from "./StatusHistoryValueMappingEditor.js";
|
|
19
19
|
|
|
20
20
|
//# sourceMappingURL=index.js.map
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/index.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\nexport { getPluginModule } from './getPluginModule';\nexport * from './status-history-model';\nexport * from './StatusHistoryChart';\nexport * from './StatusHistoryChartOptionsEditorSettings';\nexport * from './StatusHistoryPanel';\nexport * from './StatusHistoryValueMappingEditor';\n"],"names":["getPluginModule"],"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,QAAQ,
|
|
1
|
+
{"version":3,"sources":["../../src/index.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\nexport { getPluginModule } from './getPluginModule';\nexport * from './status-history-model';\nexport * from './StatusHistoryChart';\nexport * from './StatusHistoryChartOptionsEditorSettings';\nexport * from './StatusHistoryPanel';\nexport * from './StatusHistoryValueMappingEditor';\n"],"names":["getPluginModule"],"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,QAAQ,uBAAoB;AACpD,cAAc,4BAAyB;AACvC,cAAc,0BAAuB;AACrC,cAAc,+CAA4C;AAC1D,cAAc,0BAAuB;AACrC,cAAc,uCAAoC"}
|
package/lib/setup-tests.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import '@testing-library/jest-dom';
|
|
1
|
+
import '@testing-library/jest-dom/vitest';
|
|
2
2
|
//# sourceMappingURL=setup-tests.d.ts.map
|
package/lib/setup-tests.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setup-tests.d.ts","sourceRoot":"","sources":["../../src/setup-tests.ts"],"names":[],"mappings":"AAaA,OAAO,
|
|
1
|
+
{"version":3,"file":"setup-tests.d.ts","sourceRoot":"","sources":["../../src/setup-tests.ts"],"names":[],"mappings":"AAaA,OAAO,kCAAkC,CAAC"}
|
package/lib/setup-tests.js
CHANGED
|
@@ -10,8 +10,8 @@
|
|
|
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
|
|
13
|
+
import "@testing-library/jest-dom/vitest";
|
|
14
14
|
// Always mock e-charts during tests since we don't have a proper canvas in jsdom
|
|
15
|
-
|
|
15
|
+
vi.mock('echarts/core');
|
|
16
16
|
|
|
17
17
|
//# sourceMappingURL=setup-tests.js.map
|
package/lib/setup-tests.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/setup-tests.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 '@testing-library/jest-dom';\n\n// Always mock e-charts during tests since we don't have a proper canvas in jsdom\
|
|
1
|
+
{"version":3,"sources":["../../src/setup-tests.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 '@testing-library/jest-dom/vitest';\n\n// Always mock e-charts during tests since we don't have a proper canvas in jsdom\nvi.mock('echarts/core');\n"],"names":["vi","mock"],"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,OAAO,mCAAmC;AAE1C,iFAAiF;AACjFA,GAAGC,IAAI,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ValueMapping } from '@perses-dev/components';
|
|
2
|
-
import { LegendSpecOptions, OptionsEditorProps } from '@perses-dev/plugin-system';
|
|
1
|
+
import type { ValueMapping } from '@perses-dev/components';
|
|
2
|
+
import type { LegendSpecOptions, OptionsEditorProps } from '@perses-dev/plugin-system';
|
|
3
3
|
export declare function createInitialStatusHistoryChartOptions(): Record<string, unknown>;
|
|
4
4
|
export interface StatusHistoryChartOptions {
|
|
5
5
|
legend?: LegendSpecOptions;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"status-history-model.d.ts","sourceRoot":"","sources":["../../src/status-history-model.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"status-history-model.d.ts","sourceRoot":"","sources":["../../src/status-history-model.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,KAAK,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAEvF,wBAAgB,sCAAsC,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAEhF;AAED,MAAM,WAAW,yBAAyB;IACxC,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,QAAQ,CAAC,EAAE,YAAY,EAAE,CAAC;IAC1B,OAAO,CAAC,EAAE,oBAAoB,CAAC;CAChC;AAED,MAAM,MAAM,oBAAoB,GAAG,KAAK,GAAG,MAAM,CAAC;AAElD,MAAM,MAAM,6BAA6B,GAAG,kBAAkB,CAAC,yBAAyB,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/status-history-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 { ValueMapping } from '@perses-dev/components';\nimport { LegendSpecOptions, OptionsEditorProps } from '@perses-dev/plugin-system';\n\nexport function createInitialStatusHistoryChartOptions(): Record<string, unknown> {\n return {};\n}\n\nexport interface StatusHistoryChartOptions {\n legend?: LegendSpecOptions;\n mappings?: ValueMapping[];\n sorting?: StatusHistorySorting;\n}\n\nexport type StatusHistorySorting = 'asc' | 'desc';\n\nexport type StatusHistroyChartEditorProps = OptionsEditorProps<StatusHistoryChartOptions>;\n"],"names":["createInitialStatusHistoryChartOptions"],"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;AAKjC,OAAO,SAASA;IACd,OAAO,CAAC;AACV"}
|
|
1
|
+
{"version":3,"sources":["../../src/status-history-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 { ValueMapping } from '@perses-dev/components';\nimport type { LegendSpecOptions, OptionsEditorProps } from '@perses-dev/plugin-system';\n\nexport function createInitialStatusHistoryChartOptions(): Record<string, unknown> {\n return {};\n}\n\nexport interface StatusHistoryChartOptions {\n legend?: LegendSpecOptions;\n mappings?: ValueMapping[];\n sorting?: StatusHistorySorting;\n}\n\nexport type StatusHistorySorting = 'asc' | 'desc';\n\nexport type StatusHistroyChartEditorProps = OptionsEditorProps<StatusHistoryChartOptions>;\n"],"names":["createInitialStatusHistoryChartOptions"],"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;AAKjC,OAAO,SAASA;IACd,OAAO,CAAC;AACV"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { LegendItem } from '@perses-dev/components';
|
|
2
|
-
import { PanelData } from '@perses-dev/plugin-system';
|
|
3
|
-
import { TimeScale, TimeSeriesData } from '@perses-dev/spec';
|
|
4
|
-
import { StatusHistoryChartOptions } from '../status-history-model';
|
|
5
|
-
import { StatusHistoryDataItem } from '../StatusHistoryChartBase';
|
|
1
|
+
import type { LegendItem } from '@perses-dev/components';
|
|
2
|
+
import type { PanelData } from '@perses-dev/plugin-system';
|
|
3
|
+
import type { TimeScale, TimeSeriesData } from '@perses-dev/spec';
|
|
4
|
+
import type { StatusHistoryChartOptions } from '../status-history-model';
|
|
5
|
+
import type { StatusHistoryDataItem } from '../StatusHistoryChartBase';
|
|
6
6
|
interface StatusHistoryDataModel {
|
|
7
7
|
legendItems: LegendItem[];
|
|
8
8
|
statusHistoryData: StatusHistoryDataItem[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"data-transform.d.ts","sourceRoot":"","sources":["../../../src/utils/data-transform.ts"],"names":[],"mappings":"AAaA,OAAO,
|
|
1
|
+
{"version":3,"file":"data-transform.d.ts","sourceRoot":"","sources":["../../../src/utils/data-transform.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAEzD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAGlE,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,yBAAyB,CAAC;AACzE,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAIvE,UAAU,sBAAsB;IAC9B,WAAW,EAAE,UAAU,EAAE,CAAC;IAC1B,iBAAiB,EAAE,qBAAqB,EAAE,CAAC;IAC3C,eAAe,EAAE,MAAM,EAAE,CAAC;IAC1B,eAAe,EAAE,MAAM,EAAE,CAAC;IAC1B,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,MAAM,EAAE,KAAK,CAAC;QACZ,KAAK,EAAE,MAAM,GAAG,MAAM,CAAC;QACvB,KAAK,EAAE,MAAM,CAAC;KACf,CAAC,CAAC;CACJ;AAcD,wBAAgB,yBAAyB,CACvC,YAAY,EAAE,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC,EAC9C,WAAW,EAAE,MAAM,EAAE,EACrB,IAAI,EAAE,yBAAyB,GAC9B,sBAAsB,CAwGxB"}
|
|
@@ -10,10 +10,10 @@
|
|
|
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
|
|
14
|
-
import { useMemo } from
|
|
15
|
-
import { FALLBACK_COLOR, getColorsForValues } from
|
|
16
|
-
import { getCommonTimeScaleForQueries } from
|
|
13
|
+
import { applyValueMapping } from "@perses-dev/components";
|
|
14
|
+
import { useMemo } from "react";
|
|
15
|
+
import { FALLBACK_COLOR, getColorsForValues } from "./get-color.js";
|
|
16
|
+
import { getCommonTimeScaleForQueries } from "./get-timescale.js";
|
|
17
17
|
function generateCompleteTimestamps(timescale) {
|
|
18
18
|
if (!timescale) {
|
|
19
19
|
return [];
|
|
@@ -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 {
|
|
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 { LegendItem } from '@perses-dev/components';\nimport { applyValueMapping } from '@perses-dev/components';\nimport type { PanelData } from '@perses-dev/plugin-system';\nimport type { TimeScale, TimeSeriesData } from '@perses-dev/spec';\nimport { useMemo } from 'react';\n\nimport type { StatusHistoryChartOptions } from '../status-history-model';\nimport type { StatusHistoryDataItem } from '../StatusHistoryChartBase';\nimport { FALLBACK_COLOR, getColorsForValues } from './get-color';\nimport { getCommonTimeScaleForQueries } from './get-timescale';\n\ninterface StatusHistoryDataModel {\n legendItems: LegendItem[];\n statusHistoryData: StatusHistoryDataItem[];\n xAxisCategories: number[];\n yAxisCategories: string[];\n timeScale?: TimeScale;\n colors: Array<{\n value: string | number;\n color: string;\n }>;\n}\n\nfunction generateCompleteTimestamps(timescale?: TimeScale): number[] {\n if (!timescale) {\n return [];\n }\n const { startMs, endMs, stepMs } = timescale;\n const timestamps: number[] = [];\n for (let time = startMs; time <= endMs; time += stepMs) {\n timestamps.push(time);\n }\n return timestamps;\n}\n\nexport function useStatusHistoryDataModel(\n queryResults: Array<PanelData<TimeSeriesData>>,\n themeColors: string[],\n spec: StatusHistoryChartOptions,\n): StatusHistoryDataModel {\n return useMemo(() => {\n if (!queryResults || queryResults.length === 0) {\n return {\n legendItems: [],\n statusHistoryData: [],\n xAxisCategories: [],\n yAxisCategories: [],\n colors: [],\n };\n }\n\n const allSeries = queryResults.reduce<TimeSeriesData['series']>((acc, { data }) => {\n if (data && data.series) {\n acc.push(...data.series);\n }\n return acc;\n }, []);\n\n if (spec.sorting) {\n allSeries.sort((a, b) => {\n const nameA = a.formattedName || '';\n const nameB = b.formattedName || '';\n if (spec.sorting === 'asc') {\n return nameA.localeCompare(nameA);\n } else {\n return nameB.localeCompare(nameB);\n }\n });\n }\n\n const timeScale = getCommonTimeScaleForQueries(queryResults);\n const statusHistoryData: StatusHistoryDataItem[] = [];\n const yAxisCategories: string[] = [];\n const legendSet = new Set<number>();\n const hasValueMappings = spec.mappings?.length;\n\n const xAxisCategories = generateCompleteTimestamps(timeScale);\n\n allSeries.forEach((item) => {\n const instance = item.formattedName || '';\n yAxisCategories.push(instance);\n const yIndex = yAxisCategories.length - 1;\n item.values.forEach(([time, value]) => {\n const itemIndexOnXaxis = xAxisCategories.findIndex((v) => v === time);\n if (value !== null && itemIndexOnXaxis !== -1) {\n let itemLabel: string | number = value;\n if (hasValueMappings) {\n const mappedValue = applyValueMapping(value, spec.mappings);\n itemLabel = mappedValue.value;\n }\n legendSet.add(value);\n statusHistoryData.push({\n value: [itemIndexOnXaxis, yIndex, value],\n label: String(itemLabel),\n });\n }\n });\n });\n\n const uniqueValues = Array.from(legendSet);\n const colorsForValues = getColorsForValues(uniqueValues, themeColors);\n\n // get colors from theme and generate colors if not provided\n const colors = uniqueValues.map((value, index) => {\n let valueColor: string = colorsForValues[index] ?? FALLBACK_COLOR;\n\n if (hasValueMappings) {\n const mappedValue = applyValueMapping(value, spec.mappings);\n valueColor = mappedValue.color ?? valueColor;\n }\n\n return {\n value,\n color: valueColor,\n };\n });\n\n const legendItems: LegendItem[] = uniqueValues.map((value, idx) => {\n let label = String(value);\n\n if (hasValueMappings) {\n const mappedValue = applyValueMapping(value, spec.mappings);\n label = String(mappedValue.value);\n }\n\n const color = colors.find((i) => i.value === value)?.color || FALLBACK_COLOR;\n\n return {\n id: `${idx}-${value}`,\n label,\n color,\n };\n });\n\n return {\n xAxisCategories,\n yAxisCategories,\n legendItems,\n statusHistoryData,\n timeScale,\n colors,\n };\n }, [queryResults, themeColors, spec]);\n}\n"],"names":["applyValueMapping","useMemo","FALLBACK_COLOR","getColorsForValues","getCommonTimeScaleForQueries","generateCompleteTimestamps","timescale","startMs","endMs","stepMs","timestamps","time","push","useStatusHistoryDataModel","queryResults","themeColors","spec","length","legendItems","statusHistoryData","xAxisCategories","yAxisCategories","colors","allSeries","reduce","acc","data","series","sorting","sort","a","b","nameA","formattedName","nameB","localeCompare","timeScale","legendSet","Set","hasValueMappings","mappings","forEach","item","instance","yIndex","values","value","itemIndexOnXaxis","findIndex","v","itemLabel","mappedValue","add","label","String","uniqueValues","Array","from","colorsForValues","map","index","valueColor","color","idx","find","i","id"],"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;AAG3D,SAASC,OAAO,QAAQ,QAAQ;AAIhC,SAASC,cAAc,EAAEC,kBAAkB,QAAQ,iBAAc;AACjE,SAASC,4BAA4B,QAAQ,qBAAkB;AAc/D,SAASC,2BAA2BC,SAAqB;IACvD,IAAI,CAACA,WAAW;QACd,OAAO,EAAE;IACX;IACA,MAAM,EAAEC,OAAO,EAAEC,KAAK,EAAEC,MAAM,EAAE,GAAGH;IACnC,MAAMI,aAAuB,EAAE;IAC/B,IAAK,IAAIC,OAAOJ,SAASI,QAAQH,OAAOG,QAAQF,OAAQ;QACtDC,WAAWE,IAAI,CAACD;IAClB;IACA,OAAOD;AACT;AAEA,OAAO,SAASG,0BACdC,YAA8C,EAC9CC,WAAqB,EACrBC,IAA+B;IAE/B,OAAOf,QAAQ;QACb,IAAI,CAACa,gBAAgBA,aAAaG,MAAM,KAAK,GAAG;YAC9C,OAAO;gBACLC,aAAa,EAAE;gBACfC,mBAAmB,EAAE;gBACrBC,iBAAiB,EAAE;gBACnBC,iBAAiB,EAAE;gBACnBC,QAAQ,EAAE;YACZ;QACF;QAEA,MAAMC,YAAYT,aAAaU,MAAM,CAA2B,CAACC,KAAK,EAAEC,IAAI,EAAE;YAC5E,IAAIA,QAAQA,KAAKC,MAAM,EAAE;gBACvBF,IAAIb,IAAI,IAAIc,KAAKC,MAAM;YACzB;YACA,OAAOF;QACT,GAAG,EAAE;QAEL,IAAIT,KAAKY,OAAO,EAAE;YAChBL,UAAUM,IAAI,CAAC,CAACC,GAAGC;gBACjB,MAAMC,QAAQF,EAAEG,aAAa,IAAI;gBACjC,MAAMC,QAAQH,EAAEE,aAAa,IAAI;gBACjC,IAAIjB,KAAKY,OAAO,KAAK,OAAO;oBAC1B,OAAOI,MAAMG,aAAa,CAACH;gBAC7B,OAAO;oBACL,OAAOE,MAAMC,aAAa,CAACD;gBAC7B;YACF;QACF;QAEA,MAAME,YAAYhC,6BAA6BU;QAC/C,MAAMK,oBAA6C,EAAE;QACrD,MAAME,kBAA4B,EAAE;QACpC,MAAMgB,YAAY,IAAIC;QACtB,MAAMC,mBAAmBvB,KAAKwB,QAAQ,EAAEvB;QAExC,MAAMG,kBAAkBf,2BAA2B+B;QAEnDb,UAAUkB,OAAO,CAAC,CAACC;YACjB,MAAMC,WAAWD,KAAKT,aAAa,IAAI;YACvCZ,gBAAgBT,IAAI,CAAC+B;YACrB,MAAMC,SAASvB,gBAAgBJ,MAAM,GAAG;YACxCyB,KAAKG,MAAM,CAACJ,OAAO,CAAC,CAAC,CAAC9B,MAAMmC,MAAM;gBAChC,MAAMC,mBAAmB3B,gBAAgB4B,SAAS,CAAC,CAACC,IAAMA,MAAMtC;gBAChE,IAAImC,UAAU,QAAQC,qBAAqB,CAAC,GAAG;oBAC7C,IAAIG,YAA6BJ;oBACjC,IAAIP,kBAAkB;wBACpB,MAAMY,cAAcnD,kBAAkB8C,OAAO9B,KAAKwB,QAAQ;wBAC1DU,YAAYC,YAAYL,KAAK;oBAC/B;oBACAT,UAAUe,GAAG,CAACN;oBACd3B,kBAAkBP,IAAI,CAAC;wBACrBkC,OAAO;4BAACC;4BAAkBH;4BAAQE;yBAAM;wBACxCO,OAAOC,OAAOJ;oBAChB;gBACF;YACF;QACF;QAEA,MAAMK,eAAeC,MAAMC,IAAI,CAACpB;QAChC,MAAMqB,kBAAkBvD,mBAAmBoD,cAAcxC;QAEzD,4DAA4D;QAC5D,MAAMO,SAASiC,aAAaI,GAAG,CAAC,CAACb,OAAOc;YACtC,IAAIC,aAAqBH,eAAe,CAACE,MAAM,IAAI1D;YAEnD,IAAIqC,kBAAkB;gBACpB,MAAMY,cAAcnD,kBAAkB8C,OAAO9B,KAAKwB,QAAQ;gBAC1DqB,aAAaV,YAAYW,KAAK,IAAID;YACpC;YAEA,OAAO;gBACLf;gBACAgB,OAAOD;YACT;QACF;QAEA,MAAM3C,cAA4BqC,aAAaI,GAAG,CAAC,CAACb,OAAOiB;YACzD,IAAIV,QAAQC,OAAOR;YAEnB,IAAIP,kBAAkB;gBACpB,MAAMY,cAAcnD,kBAAkB8C,OAAO9B,KAAKwB,QAAQ;gBAC1Da,QAAQC,OAAOH,YAAYL,KAAK;YAClC;YAEA,MAAMgB,QAAQxC,OAAO0C,IAAI,CAAC,CAACC,IAAMA,EAAEnB,KAAK,KAAKA,QAAQgB,SAAS5D;YAE9D,OAAO;gBACLgE,IAAI,GAAGH,IAAI,CAAC,EAAEjB,OAAO;gBACrBO;gBACAS;YACF;QACF;QAEA,OAAO;YACL1C;YACAC;YACAH;YACAC;YACAiB;YACAd;QACF;IACF,GAAG;QAACR;QAAcC;QAAaC;KAAK;AACtC"}
|