@pulzr/perses-timeseries-panel 0.1.2 → 0.1.3

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 (70) hide show
  1. package/README.md +2 -1
  2. package/__mf/js/{PulzrTimeSeriesChart.8f5010ba5c.js → PulzrTimeSeriesChart.8af05eb298.js} +2 -2
  3. package/__mf/js/async/{0.1f67a94360.js → 0.97d9b1e0c4.js} +2 -2
  4. package/__mf/js/async/{07.36ac3671c5.js → 07.f2f50f0b10.js} +2 -2
  5. package/__mf/js/async/{0p.58ba51c3d8.js → 0p.4e1d1fe39a.js} +2 -2
  6. package/__mf/js/async/{1.73bde7147c.js → 1.aceea72600.js} +2 -2
  7. package/__mf/js/async/{2.965b5a081a.js → 2.d99477aed1.js} +2 -2
  8. package/__mf/js/async/{24.c20b9c5a17.js → 24.317de98277.js} +1 -1
  9. package/__mf/js/async/{3.364f359293.js → 3.7d1614f6e7.js} +1 -1
  10. package/__mf/js/async/4.b3b501a5a4.js +1 -0
  11. package/__mf/js/async/{5.f4b8ab81b7.js → 5.900dc50d56.js} +1 -1
  12. package/__mf/js/async/{6.1c072abe87.js → 6.91e38df626.js} +1 -1
  13. package/__mf/js/async/{6x.3c32d29a25.js → 6x.fd1c612797.js} +1 -1
  14. package/__mf/js/async/{7.15f564c6f3.js → 7.dcc88aa9b6.js} +2 -2
  15. package/__mf/js/async/{9.f03162afcc.js → 9.c3bada9a67.js} +1 -1
  16. package/__mf/js/async/{__federation_expose_PulzrTimeSeriesChart.872d907273.js → __federation_expose_PulzrTimeSeriesChart.cde156b788.js} +1 -1
  17. package/__mf/js/async/{aw.c62047d59e.js → aw.70e118cbc9.js} +1 -1
  18. package/__mf/js/async/b.71a696a6e8.js +1 -0
  19. package/__mf/js/async/{c.db5f03155c.js → c.2d6088333b.js} +1 -1
  20. package/__mf/js/async/{f.629bfc34cd.js → f.96d3bb04bb.js} +2 -2
  21. package/__mf/js/async/{f6.a297b4c3b5.js → f6.89ff65957d.js} +1 -1
  22. package/__mf/js/async/{g.8f186fee46.js → g.692bd4d1a6.js} +1 -1
  23. package/__mf/js/async/{i.20d8c95685.js → i.e37122ab8c.js} +1 -1
  24. package/__mf/js/async/{k.9353f82963.js → k.6b0ad1bfcf.js} +2 -2
  25. package/__mf/js/async/kk.2c9a7e0b39.js +1 -0
  26. package/__mf/js/async/{m.8322f15461.js → m.4678fdbb11.js} +2 -2
  27. package/__mf/js/async/{n.07b91c8f3b.js → n.0f1729eb57.js} +1 -1
  28. package/__mf/js/async/{o.f00502c3dc.js → o.0d3a98da9a.js} +1 -1
  29. package/__mf/js/async/{o8.0d0f7ae8dd.js → o8.c61bd6ac39.js} +1 -1
  30. package/__mf/js/async/{os.48ffc14283.js → os.ad10d51845.js} +2 -2
  31. package/__mf/js/async/{p.f622a2635a.js → p.318393ba38.js} +2 -2
  32. package/__mf/js/async/{pj.dd52375d06.js → pj.99233c78ca.js} +1 -1
  33. package/__mf/js/async/{s.4d1c08522b.js → s.d7727bb096.js} +1 -1
  34. package/__mf/js/async/{s9.14445ad382.js → s9.fb2e5e8a04.js} +1 -1
  35. package/__mf/js/async/{se.3e1054cb2e.js → se.5e663361de.js} +2 -2
  36. package/__mf/js/async/{sp.823f3e93e8.js → sp.0f633853b4.js} +1 -1
  37. package/__mf/js/async/{sr.52e9bae874.js → sr.19b889668c.js} +1 -1
  38. package/__mf/js/async/{t.94a8ce332d.js → t.d2b9f3a9ba.js} +1 -1
  39. package/__mf/js/async/{tl.d9749e7d1e.js → tl.924f906110.js} +1 -1
  40. package/__mf/js/async/{uz.53202eb429.js → uz.0d07cc3f87.js} +1 -1
  41. package/__mf/js/async/{x.57044cf1d5.js → x.d9c364c1d4.js} +1 -1
  42. package/__mf/js/async/{xr.6ee20d6a04.js → xr.87b81c2efb.js} +1 -1
  43. package/__mf/js/async/{y.2d4e8c2b2e.js → y.cc71ee1d51.js} +1 -1
  44. package/__mf/js/async/{yk.d357453890.js → yk.b74f365b85.js} +2 -2
  45. package/__mf/js/{main.5302f40bb7.js → main.ad2fd370ef.js} +2 -2
  46. package/lib/time-series-chart-model.d.ts +2 -0
  47. package/lib/time-series-chart-model.d.ts.map +1 -1
  48. package/lib/time-series-chart-model.js.map +1 -1
  49. package/lib/utils/data-transform.d.ts.map +1 -1
  50. package/lib/utils/data-transform.js +3 -0
  51. package/lib/utils/data-transform.js.map +1 -1
  52. package/mf-manifest.json +42 -42
  53. package/mf-stats.json +42 -42
  54. package/package.json +1 -1
  55. package/__mf/js/async/4.21994aea94.js +0 -1
  56. package/__mf/js/async/b.d9e335c512.js +0 -1
  57. package/__mf/js/async/kk.54ddbdccb1.js +0 -1
  58. /package/__mf/js/async/{0.1f67a94360.js.LICENSE.txt → 0.97d9b1e0c4.js.LICENSE.txt} +0 -0
  59. /package/__mf/js/async/{07.36ac3671c5.js.LICENSE.txt → 07.f2f50f0b10.js.LICENSE.txt} +0 -0
  60. /package/__mf/js/async/{0p.58ba51c3d8.js.LICENSE.txt → 0p.4e1d1fe39a.js.LICENSE.txt} +0 -0
  61. /package/__mf/js/async/{1.73bde7147c.js.LICENSE.txt → 1.aceea72600.js.LICENSE.txt} +0 -0
  62. /package/__mf/js/async/{2.965b5a081a.js.LICENSE.txt → 2.d99477aed1.js.LICENSE.txt} +0 -0
  63. /package/__mf/js/async/{7.15f564c6f3.js.LICENSE.txt → 7.dcc88aa9b6.js.LICENSE.txt} +0 -0
  64. /package/__mf/js/async/{f.629bfc34cd.js.LICENSE.txt → f.96d3bb04bb.js.LICENSE.txt} +0 -0
  65. /package/__mf/js/async/{k.9353f82963.js.LICENSE.txt → k.6b0ad1bfcf.js.LICENSE.txt} +0 -0
  66. /package/__mf/js/async/{m.8322f15461.js.LICENSE.txt → m.4678fdbb11.js.LICENSE.txt} +0 -0
  67. /package/__mf/js/async/{os.48ffc14283.js.LICENSE.txt → os.ad10d51845.js.LICENSE.txt} +0 -0
  68. /package/__mf/js/async/{p.f622a2635a.js.LICENSE.txt → p.318393ba38.js.LICENSE.txt} +0 -0
  69. /package/__mf/js/async/{se.3e1054cb2e.js.LICENSE.txt → se.5e663361de.js.LICENSE.txt} +0 -0
  70. /package/__mf/js/async/{yk.d357453890.js.LICENSE.txt → yk.b74f365b85.js.LICENSE.txt} +0 -0
@@ -87,6 +87,8 @@ export type TimeSeriesChartVisualOptions = {
87
87
  pointRadius?: number;
88
88
  stack?: StackOptions;
89
89
  connectNulls?: boolean;
90
+ /** Bars at most this wide, in px: for a few days' bars not to fill the width. */
91
+ maxBarWidth?: number;
90
92
  };
91
93
  export declare const DEFAULT_FORMAT: FormatOptions;
92
94
  export declare const DEFAULT_Y_AXIS: TimeSeriesChartYAxisOptions;
@@ -1 +1 @@
1
- {"version":3,"file":"time-series-chart-model.d.ts","sourceRoot":"","sources":["../../src/time-series-chart-model.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,aAAa,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC9E,OAAO,KAAK,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AACvF,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAGnD;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,OAAO,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAE1D,wGAAwG;AACxG,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,QAAQ,GAAG,YAAY,GAAG,WAAW,CAAC;AAEjF;;GAEG;AACH,MAAM,WAAW,yBAA0B,SAAQ,UAAU,CAAC,sBAAsB,CAAC;IACnF,IAAI,EAAE,sBAAsB,CAAC;CAC9B;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,KAAK,CAAC,EAAE,2BAA2B,CAAC;IACpC,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B,MAAM,CAAC,EAAE,4BAA4B,CAAC;IACtC,OAAO,C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AG;IACH,IAAI;CACL,CAAC;AAGF,MAAM,MAAM,QAAQ,GAAG,SAAS,GAAG,CAAC,GAAG,EAAE,CAAC;AAG1C,eAAO,MAAM,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,QAAQ,CAAA;CAAE,CAI5E,CAAC;AAGF,eAAO,MAAM,gBAAgB;WAPyB,MAAM;SAAO,QAAQ;QAQ/D,MAAM;GAEf,CAAC;AAKJ,eAAO,MAAM,6BAA6B,MAAM,CAAC;AACjD,eAAO,MAAM,6BAA6B,MAAM,CAAC;AAEjD;;GAEG;AACH,wBAAgB,mCAAmC,IAAI,sBAAsB,CAE5E"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/time-series-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 { FormatOptions, ThresholdOptions } from '@perses-dev/components';\nimport type { LegendSpecOptions, OptionsEditorProps } from '@perses-dev/plugin-system';\nimport type { Definition } from '@perses-dev/spec';\nimport { schemeCategory10, schemeDark2, schemeSet1, schemeSet2, schemeSet3, schemeTableau10 } from 'd3-scale-chromatic';\n\n/**\n * Line style options for time series charts.\n */\nexport type LineStyleType = 'solid' | 'dashed' | 'dotted';\n\n/** How a line joins its points. The step names are Grafana's: stepBefore rises at the earlier point. */\nexport type LineInterpolation = 'linear' | 'smooth' | 'stepBefore' | 'stepAfter';\n\n/**\n * The schema for a TimeSeriesChart panel.\n */\nexport interface TimeSeriesChartDefinition extends Definition<TimeSeriesChartOptions> {\n kind: 'PulzrTimeSeriesChart';\n}\n\n/**\n * The Options object supported by the TimeSeriesChartPanel plugin.\n */\nexport interface TimeSeriesChartOptions {\n legend?: LegendSpecOptions;\n yAxis?: TimeSeriesChartYAxisOptions;\n thresholds?: ThresholdOptions;\n visual?: TimeSeriesChartVisualOptions;\n tooltip?: TooltipSpecOptions;\n querySettings?: QuerySettingsOptions[];\n}\n\nexport interface QuerySettingsOptions {\n queryIndex: number;\n colorMode?: 'fixed' | 'fixed-single';\n colorValue?: string;\n lineStyle?: LineStyleType;\n lineInterpolation?: LineInterpolation;\n areaOpacity?: number;\n format?: FormatOptions;\n /**\n * If true, the query's series values are negated for display so they render\n * below the X axis. The original (positive) values are preserved for legend\n * calculations and CSV export, matching Grafana's `transform: \"negative-Y\"` behavior.\n */\n negativeY?: boolean;\n stack?: boolean;\n}\n\nexport type TimeSeriesChartOptionsEditorProps = OptionsEditorProps<TimeSeriesChartOptions>;\n\nexport interface TimeSeriesChartYAxisOptions {\n show?: boolean;\n label?: string;\n format?: FormatOptions;\n min?: number;\n max?: number;\n logBase?: LOG_BASE;\n}\n\nexport interface TooltipSpecOptions {\n enablePinning: boolean;\n}\n\nexport type TimeSeriesChartPaletteMode = 'auto' | 'categorical';\n\nexport const CATEGORICAL_PALETTE_SCHEMES = {\n category10: schemeCategory10,\n tableau10: schemeTableau10,\n set1: schemeSet1,\n set2: schemeSet2,\n set3: schemeSet3,\n dark2: schemeDark2,\n} as const;\n\nexport type CategoricalPaletteName = keyof typeof CATEGORICAL_PALETTE_SCHEMES;\n\nexport const CATEGORICAL_PALETTE_NAMES = Object.keys(CATEGORICAL_PALETTE_SCHEMES) as CategoricalPaletteName[];\n\nexport interface CategoricalSchemeMetadata {\n label: string;\n}\n\nexport const CATEGORICAL_SCHEME_METADATA: Record<CategoricalPaletteName, CategoricalSchemeMetadata> = {\n category10: { label: 'D3 Category 10' },\n tableau10: { label: 'Tableau 10' },\n set1: { label: 'ColorBrewer Set 1' },\n set2: { label: 'ColorBrewer Set 2' },\n set3: { label: 'ColorBrewer Set 3' },\n dark2: { label: 'ColorBrewer Dark 2' },\n};\n\nexport type TimeSeriesChartPaletteOptions =\n | { mode: 'auto' }\n | {\n mode: 'categorical';\n // Omitting falls back to the ECharts theme palette.\n name?: CategoricalPaletteName;\n };\n\nexport const PALETTE_DROPDOWN_TOOLTIP =\n 'Auto derives a unique color from the series name — same name always maps to the same color across panels. ' +\n 'Categorical palettes assign colors from a fixed set by series order.';\n\nexport type TimeSeriesChartVisualOptions = {\n display?: 'line' | 'bar';\n lineWidth?: number;\n lineStyle?: LineStyleType;\n lineInterpolation?: LineInterpolation;\n areaOpacity?: number;\n /** Fill of a band: a query's series labelled band=lo and band=hi. */\n bandOpacity?: number;\n showPoints?: 'auto' | 'always';\n palette?: TimeSeriesChartPaletteOptions;\n pointRadius?: number;\n stack?: StackOptions;\n connectNulls?: boolean;\n};\n\nexport const DEFAULT_FORMAT: FormatOptions = {\n unit: 'decimal',\n shortValues: true,\n};\n\nexport const DEFAULT_Y_AXIS: TimeSeriesChartYAxisOptions = {\n show: true,\n label: '',\n format: DEFAULT_FORMAT,\n min: undefined,\n max: undefined,\n logBase: undefined,\n};\n\nexport const Y_AXIS_CONFIG = {\n show: { label: 'Show' },\n label: { label: 'Label' },\n unit: { label: 'Unit' },\n min: { label: 'Min' },\n max: { label: 'Max' },\n logBase: { label: 'Log Base' },\n};\n\nexport const DEFAULT_DISPLAY = 'line';\nexport const DEFAULT_LINE_WIDTH = 1.25;\nexport const DEFAULT_LINE_STYLE = 'solid';\nexport const DEFAULT_AREA_OPACITY = 0;\n// How much larger datapoint symbols are than line width, also applied in VisualOptionsEditor.\nexport const POINT_SIZE_OFFSET = 1.5;\nexport const DEFAULT_POINT_RADIUS = DEFAULT_LINE_WIDTH + POINT_SIZE_OFFSET;\nexport const DEFAULT_CONNECT_NULLS = false;\nexport const DEFAULT_BAND_OPACITY = 0.15;\n\n/** The label, and its two values, that mark a series as a band edge. */\nexport const BAND_LABEL = 'band';\nexport type BandEdge = 'lo' | 'hi';\n\nexport const DEFAULT_VISUAL: TimeSeriesChartVisualOptions = {\n display: DEFAULT_DISPLAY,\n lineWidth: DEFAULT_LINE_WIDTH,\n lineStyle: DEFAULT_LINE_STYLE,\n areaOpacity: DEFAULT_AREA_OPACITY,\n pointRadius: DEFAULT_POINT_RADIUS,\n connectNulls: DEFAULT_CONNECT_NULLS,\n};\n\n// Controls how often static threshold values should be plotted so threshold data shows\n// in tooltip without flicker.\nexport const THRESHOLD_PLOT_INTERVAL = 15;\n\nexport const VISUAL_CONFIG = {\n lineWidth: {\n label: 'Line Width',\n testId: 'slider-line-width',\n min: 0.25,\n max: 3,\n step: 0.25,\n },\n lineStyle: {\n label: 'Line Style',\n },\n lineInterpolation: {\n label: 'Line Interpolation',\n },\n bandOpacity: {\n label: 'Band Opacity',\n testId: 'slider-band-opacity',\n min: 0,\n max: 1,\n step: 0.05,\n },\n pointRadius: {\n label: 'Point Radius',\n testId: 'slider-point-radius',\n min: 0,\n max: 6,\n step: 0.25,\n },\n areaOpacity: {\n label: 'Area Opacity',\n testId: 'slider-area-opacity',\n min: 0,\n max: 1,\n step: 0.05,\n },\n stack: {\n label: 'Stack Series',\n },\n colorPalette: {\n label: 'Color Palette',\n },\n connectNulls: {\n label: 'Connect Nulls',\n },\n};\n\n// None is equivalent to undefined since stack is optional\nexport type StackOptions = 'none' | 'all'; // TODO: add percent option support\n\nexport const STACK_CONFIG = {\n none: { label: 'None' },\n all: { label: 'All' },\n // TODO: enable option after 'Percent' implemented\n // percent: { label: 'Percent', disabled: true }, // hidden since not implemented yet\n};\n\nexport const STACK_OPTIONS = Object.entries(STACK_CONFIG).map(([id, config]) => {\n return {\n id: id as StackOptions,\n ...config,\n };\n});\n\nexport const LINE_STYLE_CONFIG = {\n solid: { label: 'Solid' },\n dashed: { label: 'Dashes' },\n dotted: { label: 'Dots' },\n};\n\nexport const LINE_INTERPOLATION_CONFIG = {\n linear: { label: 'Linear' },\n smooth: { label: 'Smooth' },\n stepBefore: { label: 'Step before' },\n stepAfter: { label: 'Step after' },\n};\n\nexport const OPACITY_CONFIG = {\n label: 'Opacity',\n testId: 'slider-opacity',\n min: 0,\n max: 1,\n step: 0.05,\n};\n\n// LogBase outlines the allowed log bases for the log-supported charts.\nexport type LOG_BASE = undefined | 2 | 10;\n\n// Single source of truth for log base configuration\nexport const LOG_BASE_CONFIG: Record<string, { label: string; log: LOG_BASE }> = {\n none: { label: 'None', log: undefined },\n '2': { label: '2', log: 2 },\n '10': { label: '10', log: 10 },\n};\n\n// Options array for SettingsAutocomplete\nexport const LOG_BASE_OPTIONS = Object.entries(LOG_BASE_CONFIG).map(([id, config]) => ({\n id: id as string,\n ...config,\n}));\n\n// Both of these constants help produce a value that is LESS THAN the initial value.\n// For positive values, we multiply by a number less than 1 to get this outcome.\n// For negative values, we multiply to a number greater than 1 to get this outcome.\nexport const POSITIVE_MIN_VALUE_MULTIPLIER = 0.8;\nexport const NEGATIVE_MIN_VALUE_MULTIPLIER = 1.2;\n\n/**\n * Creates an initial/empty options object for the TimeSeriesChartPanel.\n */\nexport function createInitialTimeSeriesChartOptions(): TimeSeriesChartOptions {\n return {};\n}\n"],"names":["schemeCategory10","schemeDark2","schemeSet1","schemeSet2","schemeSet3","schemeTableau10","CATEGORICAL_PALETTE_SCHEMES","category10","tableau10","set1","set2","set3","dark2","CATEGORICAL_PALETTE_NAMES","Object","keys","CATEGORICAL_SCHEME_METADATA","label","PALETTE_DROPDOWN_TOOLTIP","DEFAULT_FORMAT","unit","shortValues","DEFAULT_Y_AXIS","show","format","min","undefined","max","logBase","Y_AXIS_CONFIG","DEFAULT_DISPLAY","DEFAULT_LINE_WIDTH","DEFAULT_LINE_STYLE","DEFAULT_AREA_OPACITY","POINT_SIZE_OFFSET","DEFAULT_POINT_RADIUS","DEFAULT_CONNECT_NULLS","DEFAULT_BAND_OPACITY","BAND_LABEL","DEFAULT_VISUAL","display","lineWidth","lineStyle","areaOpacity","pointRadius","connectNulls","THRESHOLD_PLOT_INTERVAL","VISUAL_CONFIG","testId","step","lineInterpolation","bandOpacity","stack","colorPalette","STACK_CONFIG","none","all","STACK_OPTIONS","entries","map","id","config","LINE_STYLE_CONFIG","solid","dashed","dotted","LINE_INTERPOLATION_CONFIG","linear","smooth","stepBefore","stepAfter","OPACITY_CONFIG","LOG_BASE_CONFIG","log","LOG_BASE_OPTIONS","POSITIVE_MIN_VALUE_MULTIPLIER","NEGATIVE_MIN_VALUE_MULTIPLIER","createInitialTimeSeriesChartOptions"],"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,gBAAgB,EAAEC,WAAW,EAAEC,UAAU,EAAEC,UAAU,EAAEC,UAAU,EAAEC,eAAe,QAAQ,qBAAqB;AA+DxH,OAAO,MAAMC,8BAA8B;IACzCC,YAAYP;IACZQ,WAAWH;IACXI,MAAMP;IACNQ,MAAMP;IACNQ,MAAMP;IACNQ,OAAOX;AACT,EAAW;AAIX,OAAO,MAAMY,4BAA4BC,OAAOC,IAAI,CAACT,6BAAyD;AAM9G,OAAO,MAAMU,8BAAyF;IACpGT,YAAY;QAAEU,OAAO;IAAiB;IACtCT,WAAW;QAAES,OAAO;IAAa;IACjCR,MAAM;QAAEQ,OAAO;IAAoB;IACnCP,MAAM;QAAEO,OAAO;IAAoB;IACnCN,MAAM;QAAEM,OAAO;IAAoB;IACnCL,OAAO;QAAEK,OAAO;IAAqB;AACvC,EAAE;AAUF,OAAO,MAAMC,2BACX,+GACA,uEAAuE;AAiBzE,OAAO,MAAMC,iBAAgC;IAC3CC,MAAM;IACNC,aAAa;AACf,EAAE;AAEF,OAAO,MAAMC,iBAA8C;IACzDC,MAAM;IACNN,OAAO;IACPO,QAAQL;IACRM,KAAKC;IACLC,KAAKD;IACLE,SAASF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c,gCAAgC,IAAI;AACjD,OAAO,MAAMC,gCAAgC,IAAI;AAEjD;;CAEC,GACD,OAAO,SAASC;IACd,OAAO,CAAC;AACV"}
1
+ {"version":3,"sources":["../../src/time-series-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 { FormatOptions, ThresholdOptions } from '@perses-dev/components';\nimport type { LegendSpecOptions, OptionsEditorProps } from '@perses-dev/plugin-system';\nimport type { Definition } from '@perses-dev/spec';\nimport { schemeCategory10, schemeDark2, schemeSet1, schemeSet2, schemeSet3, schemeTableau10 } from 'd3-scale-chromatic';\n\n/**\n * Line style options for time series charts.\n */\nexport type LineStyleType = 'solid' | 'dashed' | 'dotted';\n\n/** How a line joins its points. The step names are Grafana's: stepBefore rises at the earlier point. */\nexport type LineInterpolation = 'linear' | 'smooth' | 'stepBefore' | 'stepAfter';\n\n/**\n * The schema for a TimeSeriesChart panel.\n */\nexport interface TimeSeriesChartDefinition extends Definition<TimeSeriesChartOptions> {\n kind: 'PulzrTimeSeriesChart';\n}\n\n/**\n * The Options object supported by the TimeSeriesChartPanel plugin.\n */\nexport interface TimeSeriesChartOptions {\n legend?: LegendSpecOptions;\n yAxis?: TimeSeriesChartYAxisOptions;\n thresholds?: ThresholdOptions;\n visual?: TimeSeriesChartVisualOptions;\n tooltip?: TooltipSpecOptions;\n querySettings?: QuerySettingsOptions[];\n}\n\nexport interface QuerySettingsOptions {\n queryIndex: number;\n colorMode?: 'fixed' | 'fixed-single';\n colorValue?: string;\n lineStyle?: LineStyleType;\n lineInterpolation?: LineInterpolation;\n areaOpacity?: number;\n format?: FormatOptions;\n /**\n * If true, the query's series values are negated for display so they render\n * below the X axis. The original (positive) values are preserved for legend\n * calculations and CSV export, matching Grafana's `transform: \"negative-Y\"` behavior.\n */\n negativeY?: boolean;\n stack?: boolean;\n}\n\nexport type TimeSeriesChartOptionsEditorProps = OptionsEditorProps<TimeSeriesChartOptions>;\n\nexport interface TimeSeriesChartYAxisOptions {\n show?: boolean;\n label?: string;\n format?: FormatOptions;\n min?: number;\n max?: number;\n logBase?: LOG_BASE;\n}\n\nexport interface TooltipSpecOptions {\n enablePinning: boolean;\n}\n\nexport type TimeSeriesChartPaletteMode = 'auto' | 'categorical';\n\nexport const CATEGORICAL_PALETTE_SCHEMES = {\n category10: schemeCategory10,\n tableau10: schemeTableau10,\n set1: schemeSet1,\n set2: schemeSet2,\n set3: schemeSet3,\n dark2: schemeDark2,\n} as const;\n\nexport type CategoricalPaletteName = keyof typeof CATEGORICAL_PALETTE_SCHEMES;\n\nexport const CATEGORICAL_PALETTE_NAMES = Object.keys(CATEGORICAL_PALETTE_SCHEMES) as CategoricalPaletteName[];\n\nexport interface CategoricalSchemeMetadata {\n label: string;\n}\n\nexport const CATEGORICAL_SCHEME_METADATA: Record<CategoricalPaletteName, CategoricalSchemeMetadata> = {\n category10: { label: 'D3 Category 10' },\n tableau10: { label: 'Tableau 10' },\n set1: { label: 'ColorBrewer Set 1' },\n set2: { label: 'ColorBrewer Set 2' },\n set3: { label: 'ColorBrewer Set 3' },\n dark2: { label: 'ColorBrewer Dark 2' },\n};\n\nexport type TimeSeriesChartPaletteOptions =\n | { mode: 'auto' }\n | {\n mode: 'categorical';\n // Omitting falls back to the ECharts theme palette.\n name?: CategoricalPaletteName;\n };\n\nexport const PALETTE_DROPDOWN_TOOLTIP =\n 'Auto derives a unique color from the series name — same name always maps to the same color across panels. ' +\n 'Categorical palettes assign colors from a fixed set by series order.';\n\nexport type TimeSeriesChartVisualOptions = {\n display?: 'line' | 'bar';\n lineWidth?: number;\n lineStyle?: LineStyleType;\n lineInterpolation?: LineInterpolation;\n areaOpacity?: number;\n /** Fill of a band: a query's series labelled band=lo and band=hi. */\n bandOpacity?: number;\n showPoints?: 'auto' | 'always';\n palette?: TimeSeriesChartPaletteOptions;\n pointRadius?: number;\n stack?: StackOptions;\n connectNulls?: boolean;\n /** Bars at most this wide, in px: for a few days' bars not to fill the width. */\n maxBarWidth?: number;\n};\n\nexport const DEFAULT_FORMAT: FormatOptions = {\n unit: 'decimal',\n shortValues: true,\n};\n\nexport const DEFAULT_Y_AXIS: TimeSeriesChartYAxisOptions = {\n show: true,\n label: '',\n format: DEFAULT_FORMAT,\n min: undefined,\n max: undefined,\n logBase: undefined,\n};\n\nexport const Y_AXIS_CONFIG = {\n show: { label: 'Show' },\n label: { label: 'Label' },\n unit: { label: 'Unit' },\n min: { label: 'Min' },\n max: { label: 'Max' },\n logBase: { label: 'Log Base' },\n};\n\nexport const DEFAULT_DISPLAY = 'line';\nexport const DEFAULT_LINE_WIDTH = 1.25;\nexport const DEFAULT_LINE_STYLE = 'solid';\nexport const DEFAULT_AREA_OPACITY = 0;\n// How much larger datapoint symbols are than line width, also applied in VisualOptionsEditor.\nexport const POINT_SIZE_OFFSET = 1.5;\nexport const DEFAULT_POINT_RADIUS = DEFAULT_LINE_WIDTH + POINT_SIZE_OFFSET;\nexport const DEFAULT_CONNECT_NULLS = false;\nexport const DEFAULT_BAND_OPACITY = 0.15;\n\n/** The label, and its two values, that mark a series as a band edge. */\nexport const BAND_LABEL = 'band';\nexport type BandEdge = 'lo' | 'hi';\n\nexport const DEFAULT_VISUAL: TimeSeriesChartVisualOptions = {\n display: DEFAULT_DISPLAY,\n lineWidth: DEFAULT_LINE_WIDTH,\n lineStyle: DEFAULT_LINE_STYLE,\n areaOpacity: DEFAULT_AREA_OPACITY,\n pointRadius: DEFAULT_POINT_RADIUS,\n connectNulls: DEFAULT_CONNECT_NULLS,\n};\n\n// Controls how often static threshold values should be plotted so threshold data shows\n// in tooltip without flicker.\nexport const THRESHOLD_PLOT_INTERVAL = 15;\n\nexport const VISUAL_CONFIG = {\n lineWidth: {\n label: 'Line Width',\n testId: 'slider-line-width',\n min: 0.25,\n max: 3,\n step: 0.25,\n },\n lineStyle: {\n label: 'Line Style',\n },\n lineInterpolation: {\n label: 'Line Interpolation',\n },\n bandOpacity: {\n label: 'Band Opacity',\n testId: 'slider-band-opacity',\n min: 0,\n max: 1,\n step: 0.05,\n },\n pointRadius: {\n label: 'Point Radius',\n testId: 'slider-point-radius',\n min: 0,\n max: 6,\n step: 0.25,\n },\n areaOpacity: {\n label: 'Area Opacity',\n testId: 'slider-area-opacity',\n min: 0,\n max: 1,\n step: 0.05,\n },\n stack: {\n label: 'Stack Series',\n },\n colorPalette: {\n label: 'Color Palette',\n },\n connectNulls: {\n label: 'Connect Nulls',\n },\n};\n\n// None is equivalent to undefined since stack is optional\nexport type StackOptions = 'none' | 'all'; // TODO: add percent option support\n\nexport const STACK_CONFIG = {\n none: { label: 'None' },\n all: { label: 'All' },\n // TODO: enable option after 'Percent' implemented\n // percent: { label: 'Percent', disabled: true }, // hidden since not implemented yet\n};\n\nexport const STACK_OPTIONS = Object.entries(STACK_CONFIG).map(([id, config]) => {\n return {\n id: id as StackOptions,\n ...config,\n };\n});\n\nexport const LINE_STYLE_CONFIG = {\n solid: { label: 'Solid' },\n dashed: { label: 'Dashes' },\n dotted: { label: 'Dots' },\n};\n\nexport const LINE_INTERPOLATION_CONFIG = {\n linear: { label: 'Linear' },\n smooth: { label: 'Smooth' },\n stepBefore: { label: 'Step before' },\n stepAfter: { label: 'Step after' },\n};\n\nexport const OPACITY_CONFIG = {\n label: 'Opacity',\n testId: 'slider-opacity',\n min: 0,\n max: 1,\n step: 0.05,\n};\n\n// LogBase outlines the allowed log bases for the log-supported charts.\nexport type LOG_BASE = undefined | 2 | 10;\n\n// Single source of truth for log base configuration\nexport const LOG_BASE_CONFIG: Record<string, { label: string; log: LOG_BASE }> = {\n none: { label: 'None', log: undefined },\n '2': { label: '2', log: 2 },\n '10': { label: '10', log: 10 },\n};\n\n// Options array for SettingsAutocomplete\nexport const LOG_BASE_OPTIONS = Object.entries(LOG_BASE_CONFIG).map(([id, config]) => ({\n id: id as string,\n ...config,\n}));\n\n// Both of these constants help produce a value that is LESS THAN the initial value.\n// For positive values, we multiply by a number less than 1 to get this outcome.\n// For negative values, we multiply to a number greater than 1 to get this outcome.\nexport const POSITIVE_MIN_VALUE_MULTIPLIER = 0.8;\nexport const NEGATIVE_MIN_VALUE_MULTIPLIER = 1.2;\n\n/**\n * Creates an initial/empty options object for the TimeSeriesChartPanel.\n */\nexport function createInitialTimeSeriesChartOptions(): TimeSeriesChartOptions {\n return {};\n}\n"],"names":["schemeCategory10","schemeDark2","schemeSet1","schemeSet2","schemeSet3","schemeTableau10","CATEGORICAL_PALETTE_SCHEMES","category10","tableau10","set1","set2","set3","dark2","CATEGORICAL_PALETTE_NAMES","Object","keys","CATEGORICAL_SCHEME_METADATA","label","PALETTE_DROPDOWN_TOOLTIP","DEFAULT_FORMAT","unit","shortValues","DEFAULT_Y_AXIS","show","format","min","undefined","max","logBase","Y_AXIS_CONFIG","DEFAULT_DISPLAY","DEFAULT_LINE_WIDTH","DEFAULT_LINE_STYLE","DEFAULT_AREA_OPACITY","POINT_SIZE_OFFSET","DEFAULT_POINT_RADIUS","DEFAULT_CONNECT_NULLS","DEFAULT_BAND_OPACITY","BAND_LABEL","DEFAULT_VISUAL","display","lineWidth","lineStyle","areaOpacity","pointRadius","connectNulls","THRESHOLD_PLOT_INTERVAL","VISUAL_CONFIG","testId","step","lineInterpolation","bandOpacity","stack","colorPalette","STACK_CONFIG","none","all","STACK_OPTIONS","entries","map","id","config","LINE_STYLE_CONFIG","solid","dashed","dotted","LINE_INTERPOLATION_CONFIG","linear","smooth","stepBefore","stepAfter","OPACITY_CONFIG","LOG_BASE_CONFIG","log","LOG_BASE_OPTIONS","POSITIVE_MIN_VALUE_MULTIPLIER","NEGATIVE_MIN_VALUE_MULTIPLIER","createInitialTim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AAM,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,GAAG,gBAAgB,CA2B9G;AAED;;;GAGG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,gBAAgB,EAAE,GAAG,UAAU,EAAE,EACvC,GAAG,CAAC,EAAE,MAAM,EACZ,GAAG,CAAC,EAAE,MAAM,GACX,MAAM,CAMR;AA6BD;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,SAAS,GAAE,2BAAgC,GAAG,oBAAoB,CAgDnG;AAED;;;;;;;GAOG;AACH,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAI7C;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,GAAG,oBAAoB,EAAE,CAmBpG"}
@@ -53,6 +53,9 @@ export const EXEMPLAR_SYMBOL_SIZE = 14;
53
53
  color: paletteColor,
54
54
  stack: shouldStack ? 'all' : undefined,
55
55
  yAxisIndex: yAxisIndex,
56
+ ...visual.maxBarWidth ? {
57
+ barMaxWidth: visual.maxBarWidth
58
+ } : {},
56
59
  label: {
57
60
  show: false
58
61
  }
@@ -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 type {\n LegacyTimeSeries,\n EChartsDataFormat,\n EChartsValues,\n TimeSeriesOption,\n StepOptions,\n} from '@perses-dev/components';\nimport { OPTIMIZED_MODE_SERIES_LIMIT, getCommonTimeScale } from '@perses-dev/components';\nimport type { useTimeSeriesQueries, PanelData } from '@perses-dev/plugin-system';\nimport type { Exemplar, Labels, TimeScale, TimeSeries, TimeSeriesData, TimeSeriesValueTuple } from '@perses-dev/spec';\nimport type { YAXisComponentOption } from 'echarts';\nimport type { LineSeriesOption, BarSeriesOption, ScatterSeriesOption } from 'echarts/charts';\n\nimport type {\n TimeSeriesChartVisualOptions,\n TimeSeriesChartYAxisOptions,\n LineInterpolation,\n LineStyleType,\n} from '../time-series-chart-model';\nimport {\n DEFAULT_AREA_OPACITY,\n DEFAULT_CONNECT_NULLS,\n DEFAULT_LINE_WIDTH,\n DEFAULT_POINT_RADIUS,\n DEFAULT_Y_AXIS,\n POSITIVE_MIN_VALUE_MULTIPLIER,\n NEGATIVE_MIN_VALUE_MULTIPLIER,\n} from '../time-series-chart-model';\n\nexport type RunningQueriesState = ReturnType<typeof useTimeSeriesQueries>;\n\nexport const EMPTY_GRAPH_DATA: EChartsDataFormat = {\n timeSeries: [],\n xAxis: [],\n legendItems: [],\n};\n\nexport const HIDE_DATAPOINTS_LIMIT = 70;\n\nexport const BLUR_FADEOUT_OPACITY = 0.5;\n\nexport const EXEMPLAR_SERIES_ID_PREFIX = 'exemplar-';\n\nexport const EXEMPLAR_SYMBOL_SIZE = 14;\n\n/**\n * The exemplars of one series, converted to a chart-friendly shape with the\n * rendering attributes (color, y axis) of the matching time series.\n */\nexport interface ExemplarChartData {\n seriesId: string;\n seriesName: string;\n color: string;\n seriesLabels?: Labels;\n yAxisIndex?: number;\n /**\n * When the matching series is rendered with `querySettings.negativeY`, its values are\n * visually negated so it renders below the X axis. The same transform is applied to\n * the exemplar markers' plotted Y values so they stay next to their series. The\n * original (positive) values remain on each `exemplar` for metadata display.\n */\n negativeY?: boolean;\n exemplars: Exemplar[];\n}\n\n/**\n * Given a list of running queries, calculates a common time scale for use on\n * the x axis (i.e. start/end dates and a step that is divisible into all of\n * the queries' steps).\n */\nexport function getCommonTimeScaleForQueries(queries: Array<PanelData<TimeSeriesData>>): TimeScale | undefined {\n const seriesData = queries.map((query) => query.data);\n return getCommonTimeScale(seriesData);\n}\n\n/**\n * Gets ECharts line series option properties for regular trends\n */\nexport function getTimeSeries(\n id: string,\n datasetIndex: number,\n formattedName: string,\n visual: TimeSeriesChartVisualOptions,\n timeScale: TimeScale,\n paletteColor: string,\n querySettings?: {\n lineStyle?: LineStyleType;\n lineInterpolation?: LineInterpolation;\n areaOpacity?: number;\n stack?: boolean;\n },\n yAxisIndex?: number,\n visibleSeriesCount = 1,\n): TimeSeriesOption {\n const lineWidth = visual.lineWidth ?? DEFAULT_LINE_WIDTH;\n const pointRadius = visual.pointRadius ?? DEFAULT_POINT_RADIUS;\n const shouldStack = querySettings?.stack !== undefined ? querySettings.stack : visual.stack === 'all';\n const areaOpacity = querySettings?.areaOpacity ?? visual.areaOpacity ?? DEFAULT_AREA_OPACITY;\n\n // Show automatic point markers only on short, sparse charts. Dense charts\n // otherwise create a symbol for every sample across every visible series.\n const minuteMs = 60000;\n let showPoints = timeScale.rangeMs <= minuteMs * 15 && visibleSeriesCount <= HIDE_DATAPOINTS_LIMIT;\n // Allows overriding default behavior and opt-in to always show all symbols (can hurt performance)\n if (visual.showPoints === 'always') {\n showPoints = true;\n }\n\n if (visual.display === 'bar') {\n const series: BarSeriesOption = {\n type: 'bar',\n id: id,\n datasetIndex,\n name: formattedName,\n color: paletteColor,\n stack: shouldStack ? 'all' : undefined,\n yAxisIndex: yAxisIndex,\n label: {\n show: false,\n },\n };\n return series;\n }\n\n const series: LineSeriesOption = {\n type: 'line',\n id: id,\n datasetIndex,\n name: formattedName,\n connectNulls: visual.connectNulls ?? DEFAULT_CONNECT_NULLS,\n color: paletteColor,\n stack: shouldStack ? 'all' : undefined,\n yAxisIndex: yAxisIndex,\n sampling: 'lttb',\n progressiveThreshold: OPTIMIZED_MODE_SERIES_LIMIT, // https://echarts.apache.org/en/option.html#series-lines.progressiveThreshold\n showSymbol: showPoints,\n showAllSymbol: true,\n symbolSize: pointRadius,\n lineStyle: {\n width: lineWidth,\n type: (querySettings?.lineStyle ?? visual.lineStyle) as LineStyleType,\n },\n ...interpolationOption(querySettings?.lineInterpolation ?? visual.lineInterpolation),\n // ECharts builds an area polygon whenever areaStyle is set, including at opacity 0.\n ...(areaOpacity > 0 ? { areaStyle: { opacity: areaOpacity } } : {}),\n // https://echarts.apache.org/en/option.html#series-line.emphasis\n emphasis: {\n focus: 'series',\n disabled: areaOpacity > 0, // prevents flicker when moving cursor between shaded regions\n lineStyle: {\n width: lineWidth + 1,\n opacity: 1,\n type: visual.lineStyle,\n },\n },\n blur: {\n lineStyle: {\n width: lineWidth,\n opacity: BLUR_FADEOUT_OPACITY,\n type: visual.lineStyle,\n },\n },\n };\n return series;\n}\n\n/** ECharts' line options for an interpolation. Linear is ECharts' default. */\nexport function interpolationOption(interpolation?: LineInterpolation): Pick<LineSeriesOption, 'smooth' | 'step'> {\n switch (interpolation) {\n case 'smooth':\n return { smooth: true };\n case 'stepBefore':\n return { step: 'start' };\n case 'stepAfter':\n return { step: 'end' };\n default:\n return {};\n }\n}\n\n/**\n * The two ECharts series that fill a band between `lo` and `hi`: an invisible\n * lower edge, and the band's height stacked on it with an area. They carry\n * their own data rather than a dataset, and so must come after every series\n * that has one: the tooltip reads datasets by series index, and would\n * otherwise show the band's height as its upper edge.\n */\nexport function getBandSeries(\n id: string,\n lo: TimeSeriesValueTuple[],\n hi: TimeSeriesValueTuple[],\n color: string,\n opacity: number,\n yAxisIndex = 0,\n interpolation?: LineInterpolation,\n): [LineSeriesOption, LineSeriesOption] {\n const highAt = new Map(hi);\n const height = lo.map(([t, low]): [number, number | null] => {\n const high = highAt.get(t);\n return [t, low === null || high === null || high === undefined ? null : high - low];\n });\n const edge: LineSeriesOption = {\n type: 'line',\n stack: id,\n color,\n yAxisIndex,\n silent: true,\n showSymbol: false,\n lineStyle: { opacity: 0 },\n emphasis: { disabled: true },\n tooltip: { show: false },\n z: 1,\n ...interpolationOption(interpolation),\n };\n return [\n { ...edge, id: `${id}-lo`, data: lo },\n { ...edge, id: `${id}-hi`, data: height, areaStyle: { opacity, color } },\n ];\n}\n\n/**\n * Gets an ECharts scatter series rendering exemplar markers for a single series.\n * Each data item embeds its exemplar (and series labels) so the metadata dialog\n * can be populated when a marker is clicked.\n */\nexport function getExemplarSeries(data: ExemplarChartData): ScatterSeriesOption {\n return {\n type: 'scatter',\n id: `${EXEMPLAR_SERIES_ID_PREFIX}${data.seriesId}`,\n name: data.seriesName,\n color: data.color,\n yAxisIndex: data.yAxisIndex,\n symbol: 'diamond',\n symbolSize: EXEMPLAR_SYMBOL_SIZE,\n z: 10,\n cursor: 'pointer',\n data: data.exemplars.map((exemplar) => ({\n // The plotted Y value is negated when negativeY is enabled for the matching series,\n // while `exemplar.value` keeps the original value for the metadata tooltip.\n value: [exemplar.timestamp, data.negativeY ? -exemplar.value : exemplar.value],\n exemplar,\n seriesLabels: data.seriesLabels,\n })),\n };\n}\n\n/**\n * Gets threshold-specific line series styles\n * markLine cannot be used since it does not update yAxis max / min\n * and threshold data needs to show in the tooltip\n */\nexport function getThresholdSeries(name: string, threshold: StepOptions, seriesIndex: number): LineSeriesOption {\n return {\n type: 'line',\n name: name,\n id: name,\n datasetId: name,\n datasetIndex: seriesIndex,\n color: threshold.color,\n label: {\n show: false,\n },\n lineStyle: {\n type: 'dashed',\n width: 2,\n },\n emphasis: {\n focus: 'series',\n lineStyle: {\n width: 2.5,\n },\n },\n blur: {\n lineStyle: {\n opacity: BLUR_FADEOUT_OPACITY,\n },\n },\n };\n}\n\n/**\n * Converts percent threshold into absolute step value\n * If max is undefined, use the max value from time series data as default\n */\nexport function convertPercentThreshold(\n percent: number,\n data: LegacyTimeSeries[] | TimeSeries[],\n max?: number,\n min?: number,\n): number {\n const percentDecimal = percent / 100;\n const adjustedMax = max ?? findMax(data);\n const adjustedMin = min ?? 0;\n const total = adjustedMax - adjustedMin;\n return percentDecimal * total + adjustedMin;\n}\n\nfunction findMax(data: LegacyTimeSeries[] | TimeSeries[]): number {\n let max = 0;\n if (data.length && data[0] !== undefined && (data as TimeSeries[])[0]?.values) {\n (data as TimeSeries[]).forEach((series) => {\n series.values.forEach((valueTuple: TimeSeriesValueTuple) => {\n const [_, value] = valueTuple;\n // Use the absolute value so percent thresholds compute correctly against\n // negated series (e.g. when `querySettings[].negativeY` is enabled).\n if (typeof value === 'number' && Math.abs(value) > max) {\n max = Math.abs(value);\n }\n });\n });\n } else {\n (data as LegacyTimeSeries[]).forEach((series) => {\n if (series.data !== undefined) {\n series.data.forEach((value: EChartsValues) => {\n if (typeof value === 'number' && Math.abs(value) > max) {\n max = Math.abs(value);\n }\n });\n }\n });\n }\n return max;\n}\n\n/**\n * Converts Perses panel yAxis from dashboard spec to ECharts supported yAxis options.\n * Handles both linear and logarithmic scales with appropriate min/max calculations.\n */\nexport function convertPanelYAxis(inputAxis: TimeSeriesChartYAxisOptions = {}): YAXisComponentOption {\n // Determine the appropriate min value based on scale type and user input\n let minValue: YAXisComponentOption['min'];\n if (inputAxis.logBase !== undefined) {\n // For logarithmic scales without explicit min:\n // Let ECharts auto-calculate the range based on data to avoid issues with\n // function-based calculations which can result in improper ranges (e.g., 1-10)\n minValue = undefined;\n } else if (inputAxis?.min !== undefined) {\n // User explicitly set a min value - use it for both linear and log scales\n minValue = inputAxis.min;\n } else {\n // For linear scales without explicit min:\n // Use dynamic calculation with padding for better visualization\n // https://echarts.apache.org/en/option.html#yAxis.min\n minValue = (value): number => {\n if (value.min >= 0 && value.min <= 1) {\n // Helps with PercentDecimal units, or datasets that return 0 or 1 booleans\n return 0;\n }\n\n // Note: We can tweak the MULTIPLIER constants if we want\n // TODO: Experiment with using a padding that is based on the difference between max value and min value\n if (value.min > 0) {\n return roundDown(value.min * POSITIVE_MIN_VALUE_MULTIPLIER);\n } else {\n return roundDown(value.min * NEGATIVE_MIN_VALUE_MULTIPLIER);\n }\n };\n }\n\n // Build the yAxis configuration\n const yAxis = {\n show: inputAxis?.show ?? DEFAULT_Y_AXIS.show,\n min: minValue,\n max: inputAxis?.max,\n } satisfies YAXisComponentOption;\n\n // Apply logarithmic scale settings if requested\n if (inputAxis.logBase !== undefined) {\n return {\n ...yAxis,\n type: 'log',\n logBase: inputAxis.logBase,\n };\n }\n\n return yAxis;\n}\n\n/**\n * Rounds down to nearest number with one significant digit.\n *\n * Examples:\n * 1. 675 --> 600\n * 2. 0.567 --> 0.5\n * 3. -12 --> -20\n */\nexport function roundDown(num: number): number {\n const magnitude = Math.floor(Math.log10(Math.abs(num)));\n const firstDigit = Math.floor(num / Math.pow(10, magnitude));\n return Number((firstDigit * Math.pow(10, magnitude)).toPrecision(1));\n}\n\n/**\n * A series' values on the chart's time scale, with nulls for the steps it has\n * no value for, so a line breaks where data is missing.\n *\n * Perses's own (getTimeSeriesValues in @perses-dev/components) moves each value\n * onto startMs + n * stepMs. A calendar day, week or month is not a fixed\n * number of ms: across a clock change a day is 23 or 25 hours, and a month is\n * 28 to 31 days. There a value lands on the next step, a day late, and a null\n * breaks the line before it. Here each value keeps its own time, and a null\n * marks only a step missing between two values; a value within half a step of\n * where one was expected is that step's.\n */\nexport function getTimeSeriesValues(series: TimeSeries, timeScale: TimeScale): TimeSeriesValueTuple[] {\n const { stepMs, endMs } = timeScale;\n const values: TimeSeriesValueTuple[] = [];\n let expected = timeScale.startMs;\n for (const [t, value] of series.values) {\n while (expected + stepMs / 2 < t) {\n values.push([expected, null]);\n expected += stepMs;\n }\n values.push([t, value]);\n // Never back: a value before the scale's start, or out of order, does not\n // send the nulls after it back over steps already passed.\n expected = Math.max(expected, t + stepMs);\n }\n while (expected <= endMs) {\n values.push([expected, null]);\n expected += stepMs;\n }\n return values;\n}\n"],"names":["OPTIMIZED_MODE_SERIES_LIMIT","getCommonTimeScale","DEFAULT_AREA_OPACITY","DEFAULT_CONNECT_NULLS","DEFAULT_LINE_WIDTH","DEFAULT_POINT_RADIUS","DEFAULT_Y_AXIS","POSITIVE_MIN_VALUE_MULTIPLIER","NEGATIVE_MIN_VALUE_MULTIPLIER","EMPTY_GRAPH_DATA","timeSeries","xAxis","legendItems","HIDE_DATAPOINTS_LIMIT","BLUR_FADEOUT_OPACITY","EXEMPLAR_SERIES_ID_PREFIX","EXEMPLAR_SYMBOL_SIZE","getCommonTimeScaleForQueries","queries","seriesData","map","query","data","getTimeSeries","id","datasetIndex","formattedName","visual","timeScale","paletteColor","querySettings","yAxisIndex","visibleSeriesCount","lineWidth","pointRadius","shouldStack","stack","undefined","areaOpacity","minuteMs","showPoints","rangeMs","display","series","type","name","color","label","show","connectNulls","sampling","progressiveThreshold","showSymbol","showAllSymbol","symbolSize","lineStyle","width","interpolationOption","lineInterpolation","areaStyle","opacity","emphasis","focus","disabled","blur","interpolation","smooth","step","getBandSeries","lo","hi","highAt","Map","height","t","low","high","get","edge","silent","tooltip","z","getExemplarSeries","seriesId","seriesName","symbol","cursor","exemplars","exemplar","value","timestamp","negativeY","seriesLabels","getThresholdSeries","threshold","seriesIndex","datasetId","convertPercentThreshold","percent","max","min","percentDecimal","adjustedMax","findMax","adjustedMin","total","length","values","forEach","valueTuple","_","Math","abs","convertPanelYAxis","inputAxis","minValue","logBase","roundDown","yAxis","num","magnitude","floor","log10","firstDigit","pow","Number","toPrecision","getTimeSeriesValues","stepMs","endMs","expected","startMs","push"],"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;AASjC,SAASA,2BAA2B,EAAEC,kBAAkB,QAAQ,yBAAyB;AAYzF,SACEC,oBAAoB,EACpBC,qBAAqB,EACrBC,kBAAkB,EAClBC,oBAAoB,EACpBC,cAAc,EACdC,6BAA6B,EAC7BC,6BAA6B,QACxB,gCAA6B;AAIpC,OAAO,MAAMC,mBAAsC;IACjDC,YAAY,EAAE;IACdC,OAAO,EAAE;IAC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E,MAAM,EAAEoG,MAAM,EAAEC,KAAK,EAAE,GAAGrG;IAC1B,MAAM+E,SAAiC,EAAE;IACzC,IAAIuB,WAAWtG,UAAUuG,OAAO;IAChC,KAAK,MAAM,CAACzD,GAAGe,MAAM,IAAI9C,OAAOgE,MAAM,CAAE;QACtC,MAAOuB,WAAWF,SAAS,IAAItD,EAAG;YAChCiC,OAAOyB,IAAI,CAAC;gBAACF;gBAAU;aAAK;YAC5BA,YAAYF;QACd;QACArB,OAAOyB,IAAI,CAAC;YAAC1D;YAAGe;SAAM;QACtB,0EAA0E;QAC1E,0DAA0D;QAC1DyC,WAAWnB,KAAKZ,GAAG,CAAC+B,UAAUxD,IAAIsD;IACpC;IACA,MAAOE,YAAYD,MAAO;QACxBtB,OAAOyB,IAAI,CAAC;YAACF;YAAU;SAAK;QAC5BA,YAAYF;IACd;IACA,OAAOrB;AACT"}
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 {\n LegacyTimeSeries,\n EChartsDataFormat,\n EChartsValues,\n TimeSeriesOption,\n StepOptions,\n} from '@perses-dev/components';\nimport { OPTIMIZED_MODE_SERIES_LIMIT, getCommonTimeScale } from '@perses-dev/components';\nimport type { useTimeSeriesQueries, PanelData } from '@perses-dev/plugin-system';\nimport type { Exemplar, Labels, TimeScale, TimeSeries, TimeSeriesData, TimeSeriesValueTuple } from '@perses-dev/spec';\nimport type { YAXisComponentOption } from 'echarts';\nimport type { LineSeriesOption, BarSeriesOption, ScatterSeriesOption } from 'echarts/charts';\n\nimport type {\n TimeSeriesChartVisualOptions,\n TimeSeriesChartYAxisOptions,\n LineInterpolation,\n LineStyleType,\n} from '../time-series-chart-model';\nimport {\n DEFAULT_AREA_OPACITY,\n DEFAULT_CONNECT_NULLS,\n DEFAULT_LINE_WIDTH,\n DEFAULT_POINT_RADIUS,\n DEFAULT_Y_AXIS,\n POSITIVE_MIN_VALUE_MULTIPLIER,\n NEGATIVE_MIN_VALUE_MULTIPLIER,\n} from '../time-series-chart-model';\n\nexport type RunningQueriesState = ReturnType<typeof useTimeSeriesQueries>;\n\nexport const EMPTY_GRAPH_DATA: EChartsDataFormat = {\n timeSeries: [],\n xAxis: [],\n legendItems: [],\n};\n\nexport const HIDE_DATAPOINTS_LIMIT = 70;\n\nexport const BLUR_FADEOUT_OPACITY = 0.5;\n\nexport const EXEMPLAR_SERIES_ID_PREFIX = 'exemplar-';\n\nexport const EXEMPLAR_SYMBOL_SIZE = 14;\n\n/**\n * The exemplars of one series, converted to a chart-friendly shape with the\n * rendering attributes (color, y axis) of the matching time series.\n */\nexport interface ExemplarChartData {\n seriesId: string;\n seriesName: string;\n color: string;\n seriesLabels?: Labels;\n yAxisIndex?: number;\n /**\n * When the matching series is rendered with `querySettings.negativeY`, its values are\n * visually negated so it renders below the X axis. The same transform is applied to\n * the exemplar markers' plotted Y values so they stay next to their series. The\n * original (positive) values remain on each `exemplar` for metadata display.\n */\n negativeY?: boolean;\n exemplars: Exemplar[];\n}\n\n/**\n * Given a list of running queries, calculates a common time scale for use on\n * the x axis (i.e. start/end dates and a step that is divisible into all of\n * the queries' steps).\n */\nexport function getCommonTimeScaleForQueries(queries: Array<PanelData<TimeSeriesData>>): TimeScale | undefined {\n const seriesData = queries.map((query) => query.data);\n return getCommonTimeScale(seriesData);\n}\n\n/**\n * Gets ECharts line series option properties for regular trends\n */\nexport function getTimeSeries(\n id: string,\n datasetIndex: number,\n formattedName: string,\n visual: TimeSeriesChartVisualOptions,\n timeScale: TimeScale,\n paletteColor: string,\n querySettings?: {\n lineStyle?: LineStyleType;\n lineInterpolation?: LineInterpolation;\n areaOpacity?: number;\n stack?: boolean;\n },\n yAxisIndex?: number,\n visibleSeriesCount = 1,\n): TimeSeriesOption {\n const lineWidth = visual.lineWidth ?? DEFAULT_LINE_WIDTH;\n const pointRadius = visual.pointRadius ?? DEFAULT_POINT_RADIUS;\n const shouldStack = querySettings?.stack !== undefined ? querySettings.stack : visual.stack === 'all';\n const areaOpacity = querySettings?.areaOpacity ?? visual.areaOpacity ?? DEFAULT_AREA_OPACITY;\n\n // Show automatic point markers only on short, sparse charts. Dense charts\n // otherwise create a symbol for every sample across every visible series.\n const minuteMs = 60000;\n let showPoints = timeScale.rangeMs <= minuteMs * 15 && visibleSeriesCount <= HIDE_DATAPOINTS_LIMIT;\n // Allows overriding default behavior and opt-in to always show all symbols (can hurt performance)\n if (visual.showPoints === 'always') {\n showPoints = true;\n }\n\n if (visual.display === 'bar') {\n const series: BarSeriesOption = {\n type: 'bar',\n id: id,\n datasetIndex,\n name: formattedName,\n color: paletteColor,\n stack: shouldStack ? 'all' : undefined,\n yAxisIndex: yAxisIndex,\n ...(visual.maxBarWidth ? { barMaxWidth: visual.maxBarWidth } : {}),\n label: {\n show: false,\n },\n };\n return series;\n }\n\n const series: LineSeriesOption = {\n type: 'line',\n id: id,\n datasetIndex,\n name: formattedName,\n connectNulls: visual.connectNulls ?? DEFAULT_CONNECT_NULLS,\n color: paletteColor,\n stack: shouldStack ? 'all' : undefined,\n yAxisIndex: yAxisIndex,\n sampling: 'lttb',\n progressiveThreshold: OPTIMIZED_MODE_SERIES_LIMIT, // https://echarts.apache.org/en/option.html#series-lines.progressiveThreshold\n showSymbol: showPoints,\n showAllSymbol: true,\n symbolSize: pointRadius,\n lineStyle: {\n width: lineWidth,\n type: (querySettings?.lineStyle ?? visual.lineStyle) as LineStyleType,\n },\n ...interpolationOption(querySettings?.lineInterpolation ?? visual.lineInterpolation),\n // ECharts builds an area polygon whenever areaStyle is set, including at opacity 0.\n ...(areaOpacity > 0 ? { areaStyle: { opacity: areaOpacity } } : {}),\n // https://echarts.apache.org/en/option.html#series-line.emphasis\n emphasis: {\n focus: 'series',\n disabled: areaOpacity > 0, // prevents flicker when moving cursor between shaded regions\n lineStyle: {\n width: lineWidth + 1,\n opacity: 1,\n type: visual.lineStyle,\n },\n },\n blur: {\n lineStyle: {\n width: lineWidth,\n opacity: BLUR_FADEOUT_OPACITY,\n type: visual.lineStyle,\n },\n },\n };\n return series;\n}\n\n/** ECharts' line options for an interpolation. Linear is ECharts' default. */\nexport function interpolationOption(interpolation?: LineInterpolation): Pick<LineSeriesOption, 'smooth' | 'step'> {\n switch (interpolation) {\n case 'smooth':\n return { smooth: true };\n case 'stepBefore':\n return { step: 'start' };\n case 'stepAfter':\n return { step: 'end' };\n default:\n return {};\n }\n}\n\n/**\n * The two ECharts series that fill a band between `lo` and `hi`: an invisible\n * lower edge, and the band's height stacked on it with an area. They carry\n * their own data rather than a dataset, and so must come after every series\n * that has one: the tooltip reads datasets by series index, and would\n * otherwise show the band's height as its upper edge.\n */\nexport function getBandSeries(\n id: string,\n lo: TimeSeriesValueTuple[],\n hi: TimeSeriesValueTuple[],\n color: string,\n opacity: number,\n yAxisIndex = 0,\n interpolation?: LineInterpolation,\n): [LineSeriesOption, LineSeriesOption] {\n const highAt = new Map(hi);\n const height = lo.map(([t, low]): [number, number | null] => {\n const high = highAt.get(t);\n return [t, low === null || high === null || high === undefined ? null : high - low];\n });\n const edge: LineSeriesOption = {\n type: 'line',\n stack: id,\n color,\n yAxisIndex,\n silent: true,\n showSymbol: false,\n lineStyle: { opacity: 0 },\n emphasis: { disabled: true },\n tooltip: { show: false },\n z: 1,\n ...interpolationOption(interpolation),\n };\n return [\n { ...edge, id: `${id}-lo`, data: lo },\n { ...edge, id: `${id}-hi`, data: height, areaStyle: { opacity, color } },\n ];\n}\n\n/**\n * Gets an ECharts scatter series rendering exemplar markers for a single series.\n * Each data item embeds its exemplar (and series labels) so the metadata dialog\n * can be populated when a marker is clicked.\n */\nexport function getExemplarSeries(data: ExemplarChartData): ScatterSeriesOption {\n return {\n type: 'scatter',\n id: `${EXEMPLAR_SERIES_ID_PREFIX}${data.seriesId}`,\n name: data.seriesName,\n color: data.color,\n yAxisIndex: data.yAxisIndex,\n symbol: 'diamond',\n symbolSize: EXEMPLAR_SYMBOL_SIZE,\n z: 10,\n cursor: 'pointer',\n data: data.exemplars.map((exemplar) => ({\n // The plotted Y value is negated when negativeY is enabled for the matching series,\n // while `exemplar.value` keeps the original value for the metadata tooltip.\n value: [exemplar.timestamp, data.negativeY ? -exemplar.value : exemplar.value],\n exemplar,\n seriesLabels: data.seriesLabels,\n })),\n };\n}\n\n/**\n * Gets threshold-specific line series styles\n * markLine cannot be used since it does not update yAxis max / min\n * and threshold data needs to show in the tooltip\n */\nexport function getThresholdSeries(name: string, threshold: StepOptions, seriesIndex: number): LineSeriesOption {\n return {\n type: 'line',\n name: name,\n id: name,\n datasetId: name,\n datasetIndex: seriesIndex,\n color: threshold.color,\n label: {\n show: false,\n },\n lineStyle: {\n type: 'dashed',\n width: 2,\n },\n emphasis: {\n focus: 'series',\n lineStyle: {\n width: 2.5,\n },\n },\n blur: {\n lineStyle: {\n opacity: BLUR_FADEOUT_OPACITY,\n },\n },\n };\n}\n\n/**\n * Converts percent threshold into absolute step value\n * If max is undefined, use the max value from time series data as default\n */\nexport function convertPercentThreshold(\n percent: number,\n data: LegacyTimeSeries[] | TimeSeries[],\n max?: number,\n min?: number,\n): number {\n const percentDecimal = percent / 100;\n const adjustedMax = max ?? findMax(data);\n const adjustedMin = min ?? 0;\n const total = adjustedMax - adjustedMin;\n return percentDecimal * total + adjustedMin;\n}\n\nfunction findMax(data: LegacyTimeSeries[] | TimeSeries[]): number {\n let max = 0;\n if (data.length && data[0] !== undefined && (data as TimeSeries[])[0]?.values) {\n (data as TimeSeries[]).forEach((series) => {\n series.values.forEach((valueTuple: TimeSeriesValueTuple) => {\n const [_, value] = valueTuple;\n // Use the absolute value so percent thresholds compute correctly against\n // negated series (e.g. when `querySettings[].negativeY` is enabled).\n if (typeof value === 'number' && Math.abs(value) > max) {\n max = Math.abs(value);\n }\n });\n });\n } else {\n (data as LegacyTimeSeries[]).forEach((series) => {\n if (series.data !== undefined) {\n series.data.forEach((value: EChartsValues) => {\n if (typeof value === 'number' && Math.abs(value) > max) {\n max = Math.abs(value);\n }\n });\n }\n });\n }\n return max;\n}\n\n/**\n * Converts Perses panel yAxis from dashboard spec to ECharts supported yAxis options.\n * Handles both linear and logarithmic scales with appropriate min/max calculations.\n */\nexport function convertPanelYAxis(inputAxis: TimeSeriesChartYAxisOptions = {}): YAXisComponentOption {\n // Determine the appropriate min value based on scale type and user input\n let minValue: YAXisComponentOption['min'];\n if (inputAxis.logBase !== undefined) {\n // For logarithmic scales without explicit min:\n // Let ECharts auto-calculate the range based on data to avoid issues with\n // function-based calculations which can result in improper ranges (e.g., 1-10)\n minValue = undefined;\n } else if (inputAxis?.min !== undefined) {\n // User explicitly set a min value - use it for both linear and log scales\n minValue = inputAxis.min;\n } else {\n // For linear scales without explicit min:\n // Use dynamic calculation with padding for better visualization\n // https://echarts.apache.org/en/option.html#yAxis.min\n minValue = (value): number => {\n if (value.min >= 0 && value.min <= 1) {\n // Helps with PercentDecimal units, or datasets that return 0 or 1 booleans\n return 0;\n }\n\n // Note: We can tweak the MULTIPLIER constants if we want\n // TODO: Experiment with using a padding that is based on the difference between max value and min value\n if (value.min > 0) {\n return roundDown(value.min * POSITIVE_MIN_VALUE_MULTIPLIER);\n } else {\n return roundDown(value.min * NEGATIVE_MIN_VALUE_MULTIPLIER);\n }\n };\n }\n\n // Build the yAxis configuration\n const yAxis = {\n show: inputAxis?.show ?? DEFAULT_Y_AXIS.show,\n min: minValue,\n max: inputAxis?.max,\n } satisfies YAXisComponentOption;\n\n // Apply logarithmic scale settings if requested\n if (inputAxis.logBase !== undefined) {\n return {\n ...yAxis,\n type: 'log',\n logBase: inputAxis.logBase,\n };\n }\n\n return yAxis;\n}\n\n/**\n * Rounds down to nearest number with one significant digit.\n *\n * Examples:\n * 1. 675 --> 600\n * 2. 0.567 --> 0.5\n * 3. -12 --> -20\n */\nexport function roundDown(num: number): number {\n const magnitude = Math.floor(Math.log10(Math.abs(num)));\n const firstDigit = Math.floor(num / Math.pow(10, magnitude));\n return Number((firstDigit * Math.pow(10, magnitude)).toPrecision(1));\n}\n\n/**\n * A series' values on the chart's time scale, with nulls for the steps it has\n * no value for, so a line breaks where data is missing.\n *\n * Perses's own (getTimeSeriesValues in @perses-dev/components) moves each value\n * onto startMs + n * stepMs. A calendar day, week or month is not a fixed\n * number of ms: across a clock change a day is 23 or 25 hours, and a month is\n * 28 to 31 days. There a value lands on the next step, a day late, and a null\n * breaks the line before it. Here each value keeps its own time, and a null\n * marks only a step missing between two values; a value within half a step of\n * where one was expected is that step's.\n */\nexport function getTimeSeriesValues(series: TimeSeries, timeScale: TimeScale): TimeSeriesValueTuple[] {\n const { stepMs, endMs } = timeScale;\n const values: TimeSeriesValueTuple[] = [];\n let expected = timeScale.startMs;\n for (const [t, value] of series.values) {\n while (expected + stepMs / 2 < t) {\n values.push([expected, null]);\n expected += stepMs;\n }\n values.push([t, value]);\n // Never back: a value before the scale's start, or out of order, does not\n // send the nulls after it back over steps already passed.\n expected = Math.max(expected, t + stepMs);\n }\n while (expected <= endMs) {\n values.push([expected, null]);\n expected += stepMs;\n }\n return values;\n}\n"],"names":["OPTIMIZED_MODE_SERIES_LIMIT","getCommonTimeScale","DEFAULT_AREA_OPACITY","DEFAULT_CONNECT_NULLS","DEFAULT_LINE_WIDTH","DEFAULT_POINT_RADIUS","DEFAULT_Y_AXIS","POSITIVE_MIN_VALUE_MULTIPLIER","NEGATIVE_MIN_VALUE_MULTIPLIER","EMPTY_GRAPH_DATA","timeSeries","xAxis","legendItems","HIDE_DATAPOINTS_LIMIT","BLUR_FADEOUT_OPACITY","EXEMPLAR_SERIES_ID_PREFIX","EXEMPLAR_SYMBOL_SIZE","getCommonTimeScaleForQueries","queries","seriesData","map","query","data","getTimeSeries","id","datasetIndex","formattedName","visual","timeScale","paletteColor","querySettings","yAxisIndex","visibleSeriesCount","lineWidth","pointRadius","shouldStack","stack","undefined","areaOpacity","minuteMs","showPoints","rangeMs","display","series","type","name","color","maxBarWidth","barMaxWidth","label","show","connectNulls","sampling","progressiveThreshold","showSymbol","showAllSymbol","symbolSize","lineStyle","width","interpolationOption","lineInterpolation","areaStyle","opacity","emphasis","focus","disabled","blur","interpolation","smooth","step","getBandSeries","lo","hi","highAt","Map","height","t","low","high","get","edge","silent","tooltip","z","getExemplarSeries","seriesId","seriesName","symbol","cursor","exemplars","exemplar","value","timestamp","negativeY","seriesLabels","getThresholdSeries","threshold","seriesIndex","datasetId","convertPercentThreshold","percent","max","min","percentDecimal","adjustedMax","findMax","adjustedMin","total","length","values","forEach","valueTuple","_","Math","abs","convertPanelYAxis","inputAxis","minValue","logBase","roundDown","yAxis","num","magnitude","floor","log10","firstDigit","pow","Number","toPrecision","getTimeSeriesValues","stepMs","endMs","expected","startMs","push"],"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;AASjC,SAASA,2BAA2B,EAAEC,kBAAkB,QAAQ,yBAAyB;AAYzF,SACEC,oBAAoB,EACpBC,qBAAqB,EACrBC,kBAAkB,EAClBC,oBAAoB,EACpBC,cAAc,EACdC,6BAA6B,EAC7BC,6BAA6B,QACxB,gCAA6B;AAIpC,OAAO,MAAMC,mBAAsC;IACjDC,YAAY,EAAE;IACdC,OAAO,EAAE;IACTC,aAAa,EAAE;AACjB,EAAE;AAEF,OAAO,MAAMC,wBAAwB,GAAG;AAExC,OAAO,MAAMC,uBAAuB,IAAI;AAExC,OAAO,MAAMC,4BAA4B,YAAY;AAErD,OAAO,MAAMC,uBAAuB,GAAG;AA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E;IACzC,IAAIuB,WAAWxG,UAAUyG,OAAO;IAChC,KAAK,MAAM,CAACzD,GAAGe,MAAM,IAAIhD,OAAOkE,MAAM,CAAE;QACtC,MAAOuB,WAAWF,SAAS,IAAItD,EAAG;YAChCiC,OAAOyB,IAAI,CAAC;gBAACF;gBAAU;aAAK;YAC5BA,YAAYF;QACd;QACArB,OAAOyB,IAAI,CAAC;YAAC1D;YAAGe;SAAM;QACtB,0EAA0E;QAC1E,0DAA0D;QAC1DyC,WAAWnB,KAAKZ,GAAG,CAAC+B,UAAUxD,IAAIsD;IACpC;IACA,MAAOE,YAAYD,MAAO;QACxBtB,OAAOyB,IAAI,CAAC;YAACF;YAAU;SAAK;QAC5BA,YAAYF;IACd;IACA,OAAOrB;AACT"}
package/mf-manifest.json CHANGED
@@ -5,11 +5,11 @@
5
5
  "name": "PulzrTimeSeriesChart",
6
6
  "type": "app",
7
7
  "buildInfo": {
8
- "buildVersion": "0.1.2",
8
+ "buildVersion": "0.1.3",
9
9
  "buildName": "@pulzr/perses-timeseries-panel"
10
10
  },
11
11
  "remoteEntry": {
12
- "name": "__mf/js/PulzrTimeSeriesChart.8f5010ba5c.js",
12
+ "name": "__mf/js/PulzrTimeSeriesChart.8af05eb298.js",
13
13
  "path": "",
14
14
  "type": "global"
15
15
  },
@@ -19,9 +19,9 @@
19
19
  "zip": "",
20
20
  "api": ""
21
21
  },
22
- "globalName": "PulzrTimeSeriesChart_0_1_2",
22
+ "globalName": "PulzrTimeSeriesChart_0_1_3",
23
23
  "pluginVersion": "2.9.3",
24
- "getPublicPath": "function() { return (window.PERSES_PLUGIN_ASSETS_PATH || window.PERSES_APP_CONFIG?.api_prefix || \"\") + \"/plugins/PulzrTimeSeriesChart~0.1.2/\"; }"
24
+ "getPublicPath": "function() { return (window.PERSES_PLUGIN_ASSETS_PATH || window.PERSES_APP_CONFIG?.api_prefix || \"\") + \"/plugins/PulzrTimeSeriesChart~0.1.3/\"; }"
25
25
  },
26
26
  "shared": [
27
27
  {
@@ -34,7 +34,7 @@
34
34
  "js": {
35
35
  "async": [],
36
36
  "sync": [
37
- "__mf/js/async/0p.58ba51c3d8.js"
37
+ "__mf/js/async/0p.4e1d1fe39a.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/6.1c072abe87.js",
58
- "__mf/js/async/o.f00502c3dc.js"
57
+ "__mf/js/async/6.91e38df626.js",
58
+ "__mf/js/async/o.0d3a98da9a.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/24.c20b9c5a17.js",
79
- "__mf/js/async/f6.a297b4c3b5.js"
78
+ "__mf/js/async/24.317de98277.js",
79
+ "__mf/js/async/f6.89ff65957d.js"
80
80
  ]
81
81
  },
82
82
  "css": {
@@ -96,8 +96,8 @@
96
96
  "js": {
97
97
  "async": [],
98
98
  "sync": [
99
- "__mf/js/async/n.07b91c8f3b.js",
100
- "__mf/js/async/yk.d357453890.js"
99
+ "__mf/js/async/n.0f1729eb57.js",
100
+ "__mf/js/async/yk.b74f365b85.js"
101
101
  ]
102
102
  },
103
103
  "css": {
@@ -117,7 +117,7 @@
117
117
  "js": {
118
118
  "async": [],
119
119
  "sync": [
120
- "__mf/js/async/m.8322f15461.js"
120
+ "__mf/js/async/m.4678fdbb11.js"
121
121
  ]
122
122
  },
123
123
  "css": {
@@ -139,7 +139,7 @@
139
139
  "js": {
140
140
  "async": [],
141
141
  "sync": [
142
- "__mf/js/async/7.15f564c6f3.js"
142
+ "__mf/js/async/7.dcc88aa9b6.js"
143
143
  ]
144
144
  },
145
145
  "css": {
@@ -159,7 +159,7 @@
159
159
  "js": {
160
160
  "async": [],
161
161
  "sync": [
162
- "__mf/js/async/6x.3c32d29a25.js"
162
+ "__mf/js/async/6x.fd1c612797.js"
163
163
  ]
164
164
  },
165
165
  "css": {
@@ -179,7 +179,7 @@
179
179
  "js": {
180
180
  "async": [],
181
181
  "sync": [
182
- "__mf/js/async/y.2d4e8c2b2e.js"
182
+ "__mf/js/async/y.cc71ee1d51.js"
183
183
  ]
184
184
  },
185
185
  "css": {
@@ -199,7 +199,7 @@
199
199
  "js": {
200
200
  "async": [],
201
201
  "sync": [
202
- "__mf/js/async/s.4d1c08522b.js"
202
+ "__mf/js/async/s.d7727bb096.js"
203
203
  ]
204
204
  },
205
205
  "css": {
@@ -219,7 +219,7 @@
219
219
  "js": {
220
220
  "async": [],
221
221
  "sync": [
222
- "__mf/js/async/xr.6ee20d6a04.js"
222
+ "__mf/js/async/xr.87b81c2efb.js"
223
223
  ]
224
224
  },
225
225
  "css": {
@@ -239,7 +239,7 @@
239
239
  "js": {
240
240
  "async": [],
241
241
  "sync": [
242
- "__mf/js/async/os.48ffc14283.js"
242
+ "__mf/js/async/os.ad10d51845.js"
243
243
  ]
244
244
  },
245
245
  "css": {
@@ -259,7 +259,7 @@
259
259
  "js": {
260
260
  "async": [],
261
261
  "sync": [
262
- "__mf/js/async/f.629bfc34cd.js"
262
+ "__mf/js/async/f.96d3bb04bb.js"
263
263
  ]
264
264
  },
265
265
  "css": {
@@ -279,7 +279,7 @@
279
279
  "js": {
280
280
  "async": [],
281
281
  "sync": [
282
- "__mf/js/async/pj.dd52375d06.js"
282
+ "__mf/js/async/pj.99233c78ca.js"
283
283
  ]
284
284
  },
285
285
  "css": {
@@ -299,7 +299,7 @@
299
299
  "js": {
300
300
  "async": [],
301
301
  "sync": [
302
- "__mf/js/async/07.36ac3671c5.js"
302
+ "__mf/js/async/07.f2f50f0b10.js"
303
303
  ]
304
304
  },
305
305
  "css": {
@@ -319,8 +319,8 @@
319
319
  "js": {
320
320
  "async": [],
321
321
  "sync": [
322
- "__mf/js/async/2.965b5a081a.js",
323
- "__mf/js/async/p.f622a2635a.js"
322
+ "__mf/js/async/2.d99477aed1.js",
323
+ "__mf/js/async/p.318393ba38.js"
324
324
  ]
325
325
  },
326
326
  "css": {
@@ -340,7 +340,7 @@
340
340
  "js": {
341
341
  "async": [],
342
342
  "sync": [
343
- "__mf/js/async/0.1f67a94360.js"
343
+ "__mf/js/async/0.97d9b1e0c4.js"
344
344
  ]
345
345
  },
346
346
  "css": {
@@ -360,7 +360,7 @@
360
360
  "js": {
361
361
  "async": [],
362
362
  "sync": [
363
- "__mf/js/async/s9.14445ad382.js"
363
+ "__mf/js/async/s9.fb2e5e8a04.js"
364
364
  ]
365
365
  },
366
366
  "css": {
@@ -379,25 +379,25 @@
379
379
  "assets": {
380
380
  "js": {
381
381
  "sync": [
382
- "__mf/js/async/g.8f186fee46.js",
383
- "__mf/js/async/k.9353f82963.js",
384
- "__mf/js/async/se.3e1054cb2e.js",
385
- "__mf/js/async/uz.53202eb429.js",
386
- "__mf/js/async/t.94a8ce332d.js",
387
- "__mf/js/async/__federation_expose_PulzrTimeSeriesChart.872d907273.js"
382
+ "__mf/js/async/g.692bd4d1a6.js",
383
+ "__mf/js/async/k.6b0ad1bfcf.js",
384
+ "__mf/js/async/se.5e663361de.js",
385
+ "__mf/js/async/uz.0d07cc3f87.js",
386
+ "__mf/js/async/t.d2b9f3a9ba.js",
387
+ "__mf/js/async/__federation_expose_PulzrTimeSeriesChart.cde156b788.js"
388
388
  ],
389
389
  "async": [
390
- "__mf/js/async/o8.0d0f7ae8dd.js",
391
- "__mf/js/async/sp.823f3e93e8.js",
392
- "__mf/js/async/1.73bde7147c.js",
393
- "__mf/js/async/5.f4b8ab81b7.js",
394
- "__mf/js/async/i.20d8c95685.js",
395
- "__mf/js/async/tl.d9749e7d1e.js",
396
- "__mf/js/async/c.db5f03155c.js",
397
- "__mf/js/async/aw.c62047d59e.js",
398
- "__mf/js/async/x.57044cf1d5.js",
399
- "__mf/js/async/sr.52e9bae874.js",
400
- "__mf/js/async/4.21994aea94.js"
390
+ "__mf/js/async/o8.c61bd6ac39.js",
391
+ "__mf/js/async/sp.0f633853b4.js",
392
+ "__mf/js/async/1.aceea72600.js",
393
+ "__mf/js/async/5.900dc50d56.js",
394
+ "__mf/js/async/i.e37122ab8c.js",
395
+ "__mf/js/async/tl.924f906110.js",
396
+ "__mf/js/async/c.2d6088333b.js",
397
+ "__mf/js/async/aw.70e118cbc9.js",
398
+ "__mf/js/async/x.d9c364c1d4.js",
399
+ "__mf/js/async/sr.19b889668c.js",
400
+ "__mf/js/async/4.b3b501a5a4.js"
401
401
  ]
402
402
  },
403
403
  "css": {