@gravity-ui/chartkit 8.11.0 → 9.0.0
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/LICENSE +1 -0
- package/README.md +47 -11
- package/build/cjs/components/ChartKit.css +31 -0
- package/build/cjs/components/ChartKit.d.ts +11 -0
- package/build/cjs/components/ChartKit.js +43 -0
- package/build/cjs/components/ChartKit.js.map +1 -0
- package/build/cjs/components/ErrorBoundary/ErrorBoundary.d.ts +23 -0
- package/build/cjs/components/ErrorBoundary/ErrorBoundary.js +53 -0
- package/build/cjs/components/ErrorBoundary/ErrorBoundary.js.map +1 -0
- package/build/cjs/components/Loader/Loader.d.ts +9 -0
- package/build/cjs/components/Loader/Loader.js +20 -0
- package/build/cjs/components/Loader/Loader.js.map +1 -0
- package/build/cjs/components/SplitPane/Pane.d.ts +14 -0
- package/build/cjs/components/SplitPane/Pane.js +32 -0
- package/build/cjs/components/SplitPane/Pane.js.map +1 -0
- package/build/cjs/components/SplitPane/Resizer.d.ts +18 -0
- package/build/cjs/components/SplitPane/Resizer.js +32 -0
- package/build/cjs/components/SplitPane/Resizer.js.map +1 -0
- package/build/cjs/components/SplitPane/SplitPane.d.ts +60 -0
- package/build/cjs/components/SplitPane/SplitPane.js +259 -0
- package/build/cjs/components/SplitPane/SplitPane.js.map +1 -0
- package/build/cjs/components/SplitPane/StyledSplitPane.css +45 -0
- package/build/cjs/components/SplitPane/StyledSplitPane.d.ts +9 -0
- package/build/cjs/components/SplitPane/StyledSplitPane.js +35 -0
- package/build/cjs/components/SplitPane/StyledSplitPane.js.map +1 -0
- package/build/cjs/components/SplitPane/constants.js +8 -0
- package/build/cjs/components/SplitPane/constants.js.map +1 -0
- package/build/cjs/components/SplitPane/index.d.ts +8 -0
- package/build/cjs/components/SplitPane/index.js +25 -0
- package/build/cjs/components/SplitPane/index.js.map +1 -0
- package/build/cjs/components/SplitPane/types.d.ts +2 -0
- package/build/cjs/components/SplitPane/types.js +3 -0
- package/build/cjs/components/SplitPane/types.js.map +1 -0
- package/build/cjs/components/SplitTooltip/SplitTooltip.d.ts +63 -0
- package/build/cjs/components/SplitTooltip/SplitTooltip.js +141 -0
- package/build/cjs/components/SplitTooltip/SplitTooltip.js.map +1 -0
- package/build/cjs/components/SplitTooltip/index.d.ts +2 -0
- package/build/cjs/components/SplitTooltip/index.js +7 -0
- package/build/cjs/components/SplitTooltip/index.js.map +1 -0
- package/build/cjs/constants/common.js +6 -0
- package/build/cjs/constants/common.js.map +1 -0
- package/build/cjs/constants/index.d.ts +3 -0
- package/build/cjs/constants/index.js +9 -0
- package/build/cjs/constants/index.js.map +1 -0
- package/build/cjs/constants/misc.js +23 -0
- package/build/cjs/constants/misc.js.map +1 -0
- package/build/cjs/constants/widget-data.js +51 -0
- package/build/cjs/constants/widget-data.js.map +1 -0
- package/build/cjs/hooks/index.d.ts +1 -0
- package/build/cjs/hooks/index.js +5 -0
- package/build/cjs/hooks/index.js.map +1 -0
- package/build/cjs/hooks/misc.js +13 -0
- package/build/cjs/hooks/misc.js.map +1 -0
- package/build/cjs/i18n/index.d.ts +79 -0
- package/build/cjs/i18n/index.js +22 -0
- package/build/cjs/i18n/index.js.map +1 -0
- package/build/cjs/index.d.ts +8 -0
- package/build/cjs/index.js +13 -0
- package/build/cjs/index.js.map +1 -0
- package/build/cjs/libs/chartkit-error/chartkit-error.js +28 -0
- package/build/cjs/libs/chartkit-error/chartkit-error.js.map +1 -0
- package/build/cjs/libs/index.d.ts +3 -0
- package/build/cjs/libs/index.js +10 -0
- package/build/cjs/libs/index.js.map +1 -0
- package/build/cjs/libs/settings/eventEmitter.js +28 -0
- package/build/cjs/libs/settings/eventEmitter.js.map +1 -0
- package/build/cjs/libs/settings/mergeSettingStrategy.js +35 -0
- package/build/cjs/libs/settings/mergeSettingStrategy.js.map +1 -0
- package/build/cjs/libs/settings/settings.d.ts +22 -0
- package/build/cjs/libs/settings/settings.js +46 -0
- package/build/cjs/libs/settings/settings.js.map +1 -0
- package/build/cjs/package.json +1 -0
- package/build/cjs/plugins/gravity-charts/index.d.ts +5 -0
- package/build/cjs/plugins/gravity-charts/index.js +19 -0
- package/build/cjs/plugins/gravity-charts/index.js.map +1 -0
- package/build/cjs/plugins/gravity-charts/renderer/GravityChartsWidget.d.ts +21 -0
- package/build/cjs/plugins/gravity-charts/renderer/GravityChartsWidget.js +72 -0
- package/build/cjs/plugins/gravity-charts/renderer/GravityChartsWidget.js.map +1 -0
- package/build/cjs/plugins/gravity-charts/renderer/utils.d.ts +2 -0
- package/build/cjs/plugins/gravity-charts/renderer/utils.js +20 -0
- package/build/cjs/plugins/gravity-charts/renderer/utils.js.map +1 -0
- package/build/cjs/plugins/gravity-charts/renderer/withSplitPane/TooltipContent.js +17 -0
- package/build/cjs/plugins/gravity-charts/renderer/withSplitPane/TooltipContent.js.map +1 -0
- package/build/cjs/plugins/gravity-charts/renderer/withSplitPane/useViewportSplitTooltipLayout.d.ts +3 -0
- package/build/cjs/plugins/gravity-charts/renderer/withSplitPane/useViewportSplitTooltipLayout.js +35 -0
- package/build/cjs/plugins/gravity-charts/renderer/withSplitPane/useViewportSplitTooltipLayout.js.map +1 -0
- package/build/cjs/plugins/gravity-charts/renderer/withSplitPane/withSplitPane.d.ts +8 -0
- package/build/cjs/plugins/gravity-charts/renderer/withSplitPane/withSplitPane.js +75 -0
- package/build/cjs/plugins/gravity-charts/renderer/withSplitPane/withSplitPane.js.map +1 -0
- package/build/cjs/plugins/gravity-charts/types.d.ts +6 -0
- package/build/cjs/plugins/gravity-charts/types.js +3 -0
- package/build/cjs/plugins/gravity-charts/types.js.map +1 -0
- package/build/cjs/plugins/highcharts/index.d.ts +4 -0
- package/build/cjs/plugins/highcharts/index.js +15 -0
- package/build/cjs/plugins/highcharts/index.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/HighchartsWidget.d.ts +31 -0
- package/build/cjs/plugins/highcharts/renderer/HighchartsWidget.js +10 -0
- package/build/cjs/plugins/highcharts/renderer/HighchartsWidget.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/components/HighchartsComponent.d.ts +579 -0
- package/build/cjs/plugins/highcharts/renderer/components/HighchartsComponent.js +157 -0
- package/build/cjs/plugins/highcharts/renderer/components/HighchartsComponent.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/components/HighchartsReact.d.ts +20 -0
- package/build/cjs/plugins/highcharts/renderer/components/HighchartsReact.js +78 -0
- package/build/cjs/plugins/highcharts/renderer/components/HighchartsReact.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/components/useElementSize.js +55 -0
- package/build/cjs/plugins/highcharts/renderer/components/useElementSize.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.d.ts +18 -0
- package/build/cjs/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.js +221 -0
- package/build/cjs/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/add-holidays.d.ts +3 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/add-holidays.js +47 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/add-holidays.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/comments/drawing.js +577 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/comments/drawing.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/config.js +1579 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/config.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/handleLegendItemClick.js +81 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/handleLegendItemClick.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/options.js +351 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/options.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/types.js +3 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/types.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/addShowInNavigatorToSeries.d.ts +10 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/addShowInNavigatorToSeries.js +47 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/addShowInNavigatorToSeries.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/buildNavigatorFallback.js +22 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/buildNavigatorFallback.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/calculatePrecision.js +26 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/calculatePrecision.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/concatStrings.js +6 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/concatStrings.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/getChartKitFormattedValue.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/getChartKitFormattedValue.js +20 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/getChartKitFormattedValue.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/getFormatOptionsFromLine.d.ts +3 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/getFormatOptionsFromLine.js +20 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/getFormatOptionsFromLine.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/getXAxisThresholdValue.js +25 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/getXAxisThresholdValue.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/index.d.ts +78 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/index.js +39 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/index.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/isNavigatorSeries.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/isNavigatorSeries.js +8 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/isNavigatorSeries.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/isSafari.js +16 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/isSafari.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/localStorage.js +26 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/localStorage.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/mergeArrayWithObject.js +15 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/mergeArrayWithObject.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/numberFormat.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/numberFormat.js +33 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/numberFormat.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/setNavigatorDefaultPeriod.d.ts +13 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/setNavigatorDefaultPeriod.js +33 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/setNavigatorDefaultPeriod.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/tooltip.d.ts +7 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/tooltip.js +30 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/config/utils/tooltip.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/constants.js +35 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/constants.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/graph.css +82 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/graph.d.ts +553 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/graph.js +94 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/graph.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/colors.js +20 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/colors.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/highcharts.js +376 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/highcharts.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/utils/calcucalteClosestPointManually.js +23 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/utils/calcucalteClosestPointManually.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/utils/index.d.ts +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/utils/index.js +6 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/highcharts/utils/index.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/prepare-data.js +186 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/prepare-data.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/constants.js +18 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/constants.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/helpers.js +10 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/helpers.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/index.d.ts +13 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/index.js +274 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/index.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/index.d.ts +6 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/index.js +27 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/index.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashDotLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashDotLineIcon.js +25 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashDotLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashLineIcon.js +30 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DotLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DotLineIcon.js +25 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DotLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotDotLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotDotLineIcon.js +23 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotDotLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotLineIcon.js +23 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashLineIcon.js +20 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotDotLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotDotLineIcon.js +23 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotDotLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotLineIcon.js +23 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashLineIcon.js +23 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDotLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDotLineIcon.js +25 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDotLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/SolidLineIcon.d.ts +2 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/SolidLineIcon.js +18 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/SolidLineIcon.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/index.d.ts +11 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/index.js +26 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/index.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/types.js +3 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/types.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/utils.js +10 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/utils.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/tooltip.css +313 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/types.d.ts +88 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/types.js +3 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/tooltip/types.js.map +1 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/types.d.ts +22 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/types.js +3 -0
- package/build/cjs/plugins/highcharts/renderer/helpers/types.js.map +1 -0
- package/build/cjs/plugins/highcharts/types/comments.js +3 -0
- package/build/cjs/plugins/highcharts/types/comments.js.map +1 -0
- package/build/cjs/plugins/highcharts/types/index.d.ts +4 -0
- package/build/cjs/plugins/highcharts/types/index.js +3 -0
- package/build/cjs/plugins/highcharts/types/index.js.map +1 -0
- package/build/cjs/plugins/highcharts/types/lib.js +6 -0
- package/build/cjs/plugins/highcharts/types/lib.js.map +1 -0
- package/build/cjs/plugins/highcharts/types/misc.d.ts +22 -0
- package/build/cjs/plugins/highcharts/types/misc.js +3 -0
- package/build/cjs/plugins/highcharts/types/misc.js.map +1 -0
- package/build/cjs/plugins/highcharts/types/widget.d.ts +117 -0
- package/build/cjs/plugins/highcharts/types/widget.js +3 -0
- package/build/cjs/plugins/highcharts/types/widget.js.map +1 -0
- package/build/cjs/plugins/indicator/index.d.ts +3 -0
- package/build/cjs/plugins/indicator/index.js +13 -0
- package/build/cjs/plugins/indicator/index.js.map +1 -0
- package/build/cjs/plugins/indicator/renderer/IndicatorItem.d.ts +7 -0
- package/build/cjs/plugins/indicator/renderer/IndicatorItem.js +21 -0
- package/build/cjs/plugins/indicator/renderer/IndicatorItem.js.map +1 -0
- package/build/cjs/plugins/indicator/renderer/IndicatorWidget.css +51 -0
- package/build/cjs/plugins/indicator/renderer/IndicatorWidget.d.ts +20 -0
- package/build/cjs/plugins/indicator/renderer/IndicatorWidget.js +38 -0
- package/build/cjs/plugins/indicator/renderer/IndicatorWidget.js.map +1 -0
- package/build/cjs/plugins/indicator/types.js +3 -0
- package/build/cjs/plugins/indicator/types.js.map +1 -0
- package/build/cjs/plugins/shared/format-number/format-number.d.ts +5 -0
- package/build/cjs/plugins/shared/format-number/format-number.js +97 -0
- package/build/cjs/plugins/shared/format-number/format-number.js.map +1 -0
- package/build/cjs/plugins/shared/format-number/i18n/i18n.js +13 -0
- package/build/cjs/plugins/shared/format-number/i18n/i18n.js.map +1 -0
- package/build/cjs/plugins/shared/format-number/types.js +3 -0
- package/build/cjs/plugins/shared/format-number/types.js.map +1 -0
- package/build/cjs/plugins/shared/index.d.ts +2 -0
- package/build/cjs/plugins/shared/index.js +6 -0
- package/build/cjs/plugins/shared/index.js.map +1 -0
- package/build/cjs/plugins/yagr/index.d.ts +3 -0
- package/build/cjs/plugins/yagr/index.js +11 -0
- package/build/cjs/plugins/yagr/index.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/YagrWidget.d.ts +24 -0
- package/build/cjs/plugins/yagr/renderer/YagrWidget.js +82 -0
- package/build/cjs/plugins/yagr/renderer/YagrWidget.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/polyfills.js +17 -0
- package/build/cjs/plugins/yagr/renderer/polyfills.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/helpers/escapeHTML.js +9 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/helpers/escapeHTML.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/index.d.ts +1 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/index.js +6 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/index.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/renderTooltip.d.ts +2 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/renderTooltip.js +72 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/renderTooltip.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/tooltip.css +306 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/tooltip.d.ts +3 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/tooltip.js +241 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/tooltip.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/types.js +3 -0
- package/build/cjs/plugins/yagr/renderer/tooltip/types.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/useWidgetData.d.ts +6 -0
- package/build/cjs/plugins/yagr/renderer/useWidgetData.js +31 -0
- package/build/cjs/plugins/yagr/renderer/useWidgetData.js.map +1 -0
- package/build/cjs/plugins/yagr/renderer/utils.d.ts +29 -0
- package/build/cjs/plugins/yagr/renderer/utils.js +154 -0
- package/build/cjs/plugins/yagr/renderer/utils.js.map +1 -0
- package/build/cjs/plugins/yagr/types.d.ts +32 -0
- package/build/cjs/plugins/yagr/types.js +3 -0
- package/build/cjs/plugins/yagr/types.js.map +1 -0
- package/build/cjs/types/index.d.ts +75 -0
- package/build/cjs/types/index.js +3 -0
- package/build/cjs/types/index.js.map +1 -0
- package/build/cjs/types/misc.js +3 -0
- package/build/cjs/types/misc.js.map +1 -0
- package/build/cjs/types/widget.d.ts +41 -0
- package/build/cjs/types/widget.js +3 -0
- package/build/cjs/types/widget.js.map +1 -0
- package/build/cjs/utils/cn.js +8 -0
- package/build/cjs/utils/cn.js.map +1 -0
- package/build/cjs/utils/common.js +14 -0
- package/build/cjs/utils/common.js.map +1 -0
- package/build/cjs/utils/getErrorMessage.d.ts +2 -0
- package/build/cjs/utils/getErrorMessage.js +9 -0
- package/build/cjs/utils/getErrorMessage.js.map +1 -0
- package/build/cjs/utils/index.d.ts +4 -0
- package/build/cjs/utils/index.js +12 -0
- package/build/cjs/utils/index.js.map +1 -0
- package/build/cjs/utils/merge.d.ts +19 -0
- package/build/cjs/utils/merge.js +154 -0
- package/build/cjs/utils/merge.js.map +1 -0
- package/build/cjs/utils/misc.d.ts +2 -0
- package/build/cjs/utils/misc.js +11 -0
- package/build/cjs/utils/misc.js.map +1 -0
- package/build/cjs/utils/performance.js +27 -0
- package/build/cjs/utils/performance.js.map +1 -0
- package/build/cjs/utils/react.js +9 -0
- package/build/cjs/utils/react.js.map +1 -0
- package/build/cjs/utils/throttle.d.ts +13 -0
- package/build/cjs/utils/throttle.js +47 -0
- package/build/cjs/utils/throttle.js.map +1 -0
- package/build/docs/INDEX.md +35 -9
- package/build/docs/guides/migration-to-v9.md +52 -0
- package/build/docs/guides/testing.md +12 -11
- package/build/esm/components/ChartKit.css +31 -0
- package/build/esm/components/ChartKit.d.ts +11 -0
- package/build/esm/components/ChartKit.js +39 -0
- package/build/esm/components/ChartKit.js.map +1 -0
- package/build/esm/components/ErrorBoundary/ErrorBoundary.d.ts +23 -0
- package/build/esm/components/ErrorBoundary/ErrorBoundary.js +48 -0
- package/build/esm/components/ErrorBoundary/ErrorBoundary.js.map +1 -0
- package/build/esm/components/Loader/Loader.css +7 -0
- package/build/esm/components/Loader/Loader.d.ts +9 -0
- package/build/esm/components/Loader/Loader.js +15 -0
- package/build/esm/components/Loader/Loader.js.map +1 -0
- package/build/esm/components/SplitPane/Pane.d.ts +14 -0
- package/build/esm/components/SplitPane/Pane.js +27 -0
- package/build/esm/components/SplitPane/Pane.js.map +1 -0
- package/build/esm/components/SplitPane/Resizer.d.ts +18 -0
- package/build/esm/components/SplitPane/Resizer.js +27 -0
- package/build/esm/components/SplitPane/Resizer.js.map +1 -0
- package/build/esm/components/SplitPane/SplitPane.d.ts +60 -0
- package/build/esm/components/SplitPane/SplitPane.js +254 -0
- package/build/esm/components/SplitPane/SplitPane.js.map +1 -0
- package/build/esm/components/SplitPane/StyledSplitPane.css +45 -0
- package/build/esm/components/SplitPane/StyledSplitPane.d.ts +9 -0
- package/build/esm/components/SplitPane/StyledSplitPane.js +30 -0
- package/build/esm/components/SplitPane/StyledSplitPane.js.map +1 -0
- package/build/esm/components/SplitPane/constants.d.ts +4 -0
- package/build/esm/components/SplitPane/constants.js +5 -0
- package/build/esm/components/SplitPane/constants.js.map +1 -0
- package/build/esm/components/SplitPane/index.d.ts +8 -0
- package/build/esm/components/SplitPane/index.js +19 -0
- package/build/esm/components/SplitPane/index.js.map +1 -0
- package/build/esm/components/SplitPane/types.d.ts +2 -0
- package/build/esm/components/SplitPane/types.js +2 -0
- package/build/esm/components/SplitPane/types.js.map +1 -0
- package/build/esm/components/SplitTooltip/SplitTooltip.d.ts +63 -0
- package/build/esm/components/SplitTooltip/SplitTooltip.js +133 -0
- package/build/esm/components/SplitTooltip/SplitTooltip.js.map +1 -0
- package/build/esm/components/SplitTooltip/index.d.ts +2 -0
- package/build/esm/components/SplitTooltip/index.js +2 -0
- package/build/esm/components/SplitTooltip/index.js.map +1 -0
- package/build/esm/constants/common.d.ts +1 -0
- package/build/esm/constants/common.js +3 -0
- package/build/esm/constants/common.js.map +1 -0
- package/build/esm/constants/index.d.ts +3 -0
- package/build/esm/constants/index.js +4 -0
- package/build/esm/constants/index.js.map +1 -0
- package/build/esm/constants/misc.d.ts +10 -0
- package/build/esm/constants/misc.js +20 -0
- package/build/esm/constants/misc.js.map +1 -0
- package/build/esm/constants/widget-data.d.ts +43 -0
- package/build/esm/constants/widget-data.js +48 -0
- package/build/esm/constants/widget-data.js.map +1 -0
- package/build/esm/hooks/index.d.ts +1 -0
- package/build/esm/hooks/index.js +2 -0
- package/build/esm/hooks/index.js.map +1 -0
- package/build/esm/hooks/misc.d.ts +1 -0
- package/build/esm/hooks/misc.js +9 -0
- package/build/esm/hooks/misc.js.map +1 -0
- package/build/esm/i18n/index.d.ts +79 -0
- package/build/esm/i18n/index.js +17 -0
- package/build/esm/i18n/index.js.map +1 -0
- package/build/esm/i18n/keysets/en.json +80 -0
- package/build/esm/i18n/keysets/ru.json +79 -0
- package/build/esm/index.d.ts +8 -0
- package/build/esm/index.js +7 -0
- package/build/esm/index.js.map +1 -0
- package/build/esm/libs/chartkit-error/chartkit-error.d.ts +18 -0
- package/build/esm/libs/chartkit-error/chartkit-error.js +23 -0
- package/build/esm/libs/chartkit-error/chartkit-error.js.map +1 -0
- package/build/esm/libs/index.d.ts +3 -0
- package/build/esm/libs/index.js +3 -0
- package/build/esm/libs/index.js.map +1 -0
- package/build/esm/libs/settings/eventEmitter.d.ts +11 -0
- package/build/esm/libs/settings/eventEmitter.js +24 -0
- package/build/esm/libs/settings/eventEmitter.js.map +1 -0
- package/build/esm/libs/settings/mergeSettingStrategy.d.ts +1 -0
- package/build/esm/libs/settings/mergeSettingStrategy.js +31 -0
- package/build/esm/libs/settings/mergeSettingStrategy.js.map +1 -0
- package/build/esm/libs/settings/settings.d.ts +22 -0
- package/build/esm/libs/settings/settings.js +42 -0
- package/build/esm/libs/settings/settings.js.map +1 -0
- package/build/esm/package.json +1 -0
- package/build/esm/plugins/gravity-charts/index.d.ts +5 -0
- package/build/esm/plugins/gravity-charts/index.js +11 -0
- package/build/esm/plugins/gravity-charts/index.js.map +1 -0
- package/build/esm/plugins/gravity-charts/renderer/GravityChartsWidget.d.ts +21 -0
- package/build/esm/plugins/gravity-charts/renderer/GravityChartsWidget.js +68 -0
- package/build/esm/plugins/gravity-charts/renderer/GravityChartsWidget.js.map +1 -0
- package/build/esm/plugins/gravity-charts/renderer/utils.d.ts +2 -0
- package/build/esm/plugins/gravity-charts/renderer/utils.js +17 -0
- package/build/esm/plugins/gravity-charts/renderer/utils.js.map +1 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/TooltipContent.d.ts +8 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/TooltipContent.js +13 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/TooltipContent.js.map +1 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/useViewportSplitTooltipLayout.d.ts +3 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/useViewportSplitTooltipLayout.js +30 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/useViewportSplitTooltipLayout.js.map +1 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/withSplitPane.d.ts +8 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/withSplitPane.js +71 -0
- package/build/esm/plugins/gravity-charts/renderer/withSplitPane/withSplitPane.js.map +1 -0
- package/build/esm/plugins/gravity-charts/types.d.ts +6 -0
- package/build/esm/plugins/gravity-charts/types.js +2 -0
- package/build/esm/plugins/gravity-charts/types.js.map +1 -0
- package/build/esm/plugins/highcharts/index.d.ts +4 -0
- package/build/esm/plugins/highcharts/index.js +10 -0
- package/build/esm/plugins/highcharts/index.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/HighchartsWidget.d.ts +31 -0
- package/build/esm/plugins/highcharts/renderer/HighchartsWidget.js +6 -0
- package/build/esm/plugins/highcharts/renderer/HighchartsWidget.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/components/HighchartsComponent.css +4 -0
- package/build/esm/plugins/highcharts/renderer/components/HighchartsComponent.d.ts +579 -0
- package/build/esm/plugins/highcharts/renderer/components/HighchartsComponent.js +152 -0
- package/build/esm/plugins/highcharts/renderer/components/HighchartsComponent.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/components/HighchartsReact.d.ts +20 -0
- package/build/esm/plugins/highcharts/renderer/components/HighchartsReact.js +74 -0
- package/build/esm/plugins/highcharts/renderer/components/HighchartsReact.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/components/useElementSize.d.ts +6 -0
- package/build/esm/plugins/highcharts/renderer/components/useElementSize.js +51 -0
- package/build/esm/plugins/highcharts/renderer/components/useElementSize.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/components/withSplitPane/WithSplitPane.css +4 -0
- package/build/esm/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.d.ts +18 -0
- package/build/esm/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.js +216 -0
- package/build/esm/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/add-holidays.d.ts +3 -0
- package/build/esm/plugins/highcharts/renderer/helpers/add-holidays.js +44 -0
- package/build/esm/plugins/highcharts/renderer/helpers/add-holidays.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/comments/drawing.d.ts +11 -0
- package/build/esm/plugins/highcharts/renderer/helpers/comments/drawing.js +570 -0
- package/build/esm/plugins/highcharts/renderer/helpers/comments/drawing.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/config.d.ts +582 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/config.js +1565 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/config.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/handleLegendItemClick.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/handleLegendItemClick.js +76 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/handleLegendItemClick.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/options.d.ts +468 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/options.js +348 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/options.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/types.d.ts +6 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/types.js +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/types.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/addShowInNavigatorToSeries.d.ts +10 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/addShowInNavigatorToSeries.js +43 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/addShowInNavigatorToSeries.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/buildNavigatorFallback.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/buildNavigatorFallback.js +18 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/buildNavigatorFallback.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/calculatePrecision.d.ts +5 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/calculatePrecision.js +21 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/calculatePrecision.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/concatStrings.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/concatStrings.js +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/concatStrings.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getChartKitFormattedValue.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getChartKitFormattedValue.js +16 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getChartKitFormattedValue.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getFormatOptionsFromLine.d.ts +3 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getFormatOptionsFromLine.js +16 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getFormatOptionsFromLine.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getXAxisThresholdValue.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getXAxisThresholdValue.js +21 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/getXAxisThresholdValue.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/index.d.ts +78 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/index.js +22 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/index.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/isNavigatorSeries.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/isNavigatorSeries.js +4 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/isNavigatorSeries.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/isSafari.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/isSafari.js +13 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/isSafari.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/localStorage.d.ts +5 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/localStorage.js +24 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/localStorage.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/mergeArrayWithObject.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/mergeArrayWithObject.js +11 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/mergeArrayWithObject.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/numberFormat.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/numberFormat.js +29 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/numberFormat.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/setNavigatorDefaultPeriod.d.ts +13 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/setNavigatorDefaultPeriod.js +28 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/setNavigatorDefaultPeriod.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/tooltip.d.ts +7 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/tooltip.js +25 -0
- package/build/esm/plugins/highcharts/renderer/helpers/config/utils/tooltip.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/constants.d.ts +29 -0
- package/build/esm/plugins/highcharts/renderer/helpers/constants.js +32 -0
- package/build/esm/plugins/highcharts/renderer/helpers/constants.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/graph.css +82 -0
- package/build/esm/plugins/highcharts/renderer/helpers/graph.d.ts +553 -0
- package/build/esm/plugins/highcharts/renderer/helpers/graph.js +92 -0
- package/build/esm/plugins/highcharts/renderer/helpers/graph.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/colors.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/colors.js +18 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/colors.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/highcharts.d.ts +5 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/highcharts.js +371 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/highcharts.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/utils/calcucalteClosestPointManually.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/utils/calcucalteClosestPointManually.js +20 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/utils/calcucalteClosestPointManually.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/utils/index.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/utils/index.js +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/highcharts/utils/index.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/prepare-data.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/prepare-data.js +182 -0
- package/build/esm/plugins/highcharts/renderer/helpers/prepare-data.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/constants.d.ts +13 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/constants.js +15 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/constants.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/helpers.d.ts +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/helpers.js +6 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/helpers.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/index.d.ts +13 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/index.js +269 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/index.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/index.d.ts +6 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/index.js +23 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/index.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashDotLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashDotLineIcon.js +21 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashDotLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashLineIcon.js +26 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DotLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DotLineIcon.js +21 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DotLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotDotLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotDotLineIcon.js +19 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotDotLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotLineIcon.js +19 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashLineIcon.js +16 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotDotLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotDotLineIcon.js +19 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotDotLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotLineIcon.js +19 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashLineIcon.js +19 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDotLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDotLineIcon.js +21 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDotLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/SolidLineIcon.d.ts +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/SolidLineIcon.js +14 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/SolidLineIcon.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/index.d.ts +11 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/index.js +12 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/index.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/types.d.ts +4 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/types.js +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/types.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/utils.d.ts +7 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/utils.js +6 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/utils.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/tooltip.css +313 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/types.d.ts +88 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/types.js +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/tooltip/types.js.map +1 -0
- package/build/esm/plugins/highcharts/renderer/helpers/types.d.ts +22 -0
- package/build/esm/plugins/highcharts/renderer/helpers/types.js +2 -0
- package/build/esm/plugins/highcharts/renderer/helpers/types.js.map +1 -0
- package/build/esm/plugins/highcharts/types/comments.d.ts +51 -0
- package/build/esm/plugins/highcharts/types/comments.js +2 -0
- package/build/esm/plugins/highcharts/types/comments.js.map +1 -0
- package/build/esm/plugins/highcharts/types/highcharts-extends.d.ts +53 -0
- package/build/esm/plugins/highcharts/types/index.d.ts +4 -0
- package/build/esm/plugins/highcharts/types/index.js +2 -0
- package/build/esm/plugins/highcharts/types/index.js.map +1 -0
- package/build/esm/plugins/highcharts/types/lib.js +2 -0
- package/build/esm/plugins/highcharts/types/lib.js.map +1 -0
- package/build/esm/plugins/highcharts/types/misc.d.ts +22 -0
- package/build/esm/plugins/highcharts/types/misc.js +2 -0
- package/build/esm/plugins/highcharts/types/misc.js.map +1 -0
- package/build/esm/plugins/highcharts/types/widget.d.ts +117 -0
- package/build/esm/plugins/highcharts/types/widget.js +2 -0
- package/build/esm/plugins/highcharts/types/widget.js.map +1 -0
- package/build/esm/plugins/indicator/index.d.ts +3 -0
- package/build/esm/plugins/indicator/index.js +9 -0
- package/build/esm/plugins/indicator/index.js.map +1 -0
- package/build/esm/plugins/indicator/renderer/IndicatorItem.d.ts +7 -0
- package/build/esm/plugins/indicator/renderer/IndicatorItem.js +16 -0
- package/build/esm/plugins/indicator/renderer/IndicatorItem.js.map +1 -0
- package/build/esm/plugins/indicator/renderer/IndicatorWidget.css +51 -0
- package/build/esm/plugins/indicator/renderer/IndicatorWidget.d.ts +20 -0
- package/build/esm/plugins/indicator/renderer/IndicatorWidget.js +34 -0
- package/build/esm/plugins/indicator/renderer/IndicatorWidget.js.map +1 -0
- package/build/esm/plugins/indicator/types.d.ts +15 -0
- package/build/esm/plugins/indicator/types.js +2 -0
- package/build/esm/plugins/indicator/types.js.map +1 -0
- package/build/esm/plugins/shared/format-number/format-number.d.ts +5 -0
- package/build/esm/plugins/shared/format-number/format-number.js +91 -0
- package/build/esm/plugins/shared/format-number/format-number.js.map +1 -0
- package/build/esm/plugins/shared/format-number/i18n/en.json +17 -0
- package/build/esm/plugins/shared/format-number/i18n/i18n.d.ts +5 -0
- package/build/esm/plugins/shared/format-number/i18n/i18n.js +9 -0
- package/build/esm/plugins/shared/format-number/i18n/i18n.js.map +1 -0
- package/build/esm/plugins/shared/format-number/i18n/ru.json +17 -0
- package/build/esm/plugins/shared/format-number/types.d.ts +14 -0
- package/build/esm/plugins/shared/format-number/types.js +2 -0
- package/build/esm/plugins/shared/format-number/types.js.map +1 -0
- package/build/esm/plugins/shared/index.d.ts +2 -0
- package/build/esm/plugins/shared/index.js +2 -0
- package/build/esm/plugins/shared/index.js.map +1 -0
- package/build/esm/plugins/yagr/index.d.ts +3 -0
- package/build/esm/plugins/yagr/index.js +7 -0
- package/build/esm/plugins/yagr/index.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/YagrWidget.css +4 -0
- package/build/esm/plugins/yagr/renderer/YagrWidget.d.ts +24 -0
- package/build/esm/plugins/yagr/renderer/YagrWidget.js +78 -0
- package/build/esm/plugins/yagr/renderer/YagrWidget.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/polyfills.js +16 -0
- package/build/esm/plugins/yagr/renderer/polyfills.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/tooltip/helpers/escapeHTML.d.ts +1 -0
- package/build/esm/plugins/yagr/renderer/tooltip/helpers/escapeHTML.js +6 -0
- package/build/esm/plugins/yagr/renderer/tooltip/helpers/escapeHTML.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/tooltip/index.d.ts +1 -0
- package/build/esm/plugins/yagr/renderer/tooltip/index.js +2 -0
- package/build/esm/plugins/yagr/renderer/tooltip/index.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/tooltip/renderTooltip.d.ts +2 -0
- package/build/esm/plugins/yagr/renderer/tooltip/renderTooltip.js +68 -0
- package/build/esm/plugins/yagr/renderer/tooltip/renderTooltip.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/tooltip/tooltip.css +306 -0
- package/build/esm/plugins/yagr/renderer/tooltip/tooltip.d.ts +3 -0
- package/build/esm/plugins/yagr/renderer/tooltip/tooltip.js +237 -0
- package/build/esm/plugins/yagr/renderer/tooltip/tooltip.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/tooltip/types.d.ts +74 -0
- package/build/esm/plugins/yagr/renderer/tooltip/types.js +2 -0
- package/build/esm/plugins/yagr/renderer/tooltip/types.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/useWidgetData.d.ts +6 -0
- package/build/esm/plugins/yagr/renderer/useWidgetData.js +26 -0
- package/build/esm/plugins/yagr/renderer/useWidgetData.js.map +1 -0
- package/build/esm/plugins/yagr/renderer/utils.d.ts +29 -0
- package/build/esm/plugins/yagr/renderer/utils.js +146 -0
- package/build/esm/plugins/yagr/renderer/utils.js.map +1 -0
- package/build/esm/plugins/yagr/types.d.ts +32 -0
- package/build/esm/plugins/yagr/types.js +2 -0
- package/build/esm/plugins/yagr/types.js.map +1 -0
- package/build/esm/types/index.d.ts +75 -0
- package/build/esm/types/index.js +2 -0
- package/build/esm/types/index.js.map +1 -0
- package/build/esm/types/misc.d.ts +4 -0
- package/build/esm/types/misc.js +2 -0
- package/build/esm/types/misc.js.map +1 -0
- package/build/esm/types/widget.d.ts +41 -0
- package/build/esm/types/widget.js +2 -0
- package/build/esm/types/widget.js.map +1 -0
- package/build/esm/utils/cn.d.ts +3 -0
- package/build/esm/utils/cn.js +5 -0
- package/build/esm/utils/cn.js.map +1 -0
- package/build/esm/utils/common.d.ts +2 -0
- package/build/esm/utils/common.js +9 -0
- package/build/esm/utils/common.js.map +1 -0
- package/build/esm/utils/getErrorMessage.d.ts +2 -0
- package/build/esm/utils/getErrorMessage.js +6 -0
- package/build/esm/utils/getErrorMessage.js.map +1 -0
- package/build/esm/utils/index.d.ts +4 -0
- package/build/esm/utils/index.js +5 -0
- package/build/esm/utils/index.js.map +1 -0
- package/build/esm/utils/merge.d.ts +19 -0
- package/build/esm/utils/merge.js +149 -0
- package/build/esm/utils/merge.js.map +1 -0
- package/build/esm/utils/misc.d.ts +2 -0
- package/build/esm/utils/misc.js +8 -0
- package/build/esm/utils/misc.js.map +1 -0
- package/build/esm/utils/performance.d.ts +5 -0
- package/build/esm/utils/performance.js +21 -0
- package/build/esm/utils/performance.js.map +1 -0
- package/build/esm/utils/react.d.ts +1 -0
- package/build/esm/utils/react.js +5 -0
- package/build/esm/utils/react.js.map +1 -0
- package/build/esm/utils/throttle.d.ts +13 -0
- package/build/esm/utils/throttle.js +44 -0
- package/build/esm/utils/throttle.js.map +1 -0
- package/package.json +85 -25
- package/build/components/ChartKit.css +0 -32
- package/build/components/ChartKit.d.ts +0 -11
- package/build/components/ChartKit.js +0 -42
- package/build/components/ErrorBoundary/ErrorBoundary.d.ts +0 -23
- package/build/components/ErrorBoundary/ErrorBoundary.js +0 -51
- package/build/components/Loader/Loader.d.ts +0 -9
- package/build/components/Loader/Loader.js +0 -16
- package/build/components/SplitPane/Pane.d.ts +0 -14
- package/build/components/SplitPane/Pane.js +0 -26
- package/build/components/SplitPane/Resizer.d.ts +0 -18
- package/build/components/SplitPane/Resizer.js +0 -26
- package/build/components/SplitPane/SplitPane.d.ts +0 -59
- package/build/components/SplitPane/SplitPane.js +0 -235
- package/build/components/SplitPane/StyledSplitPane.css +0 -52
- package/build/components/SplitPane/StyledSplitPane.d.ts +0 -9
- package/build/components/SplitPane/StyledSplitPane.js +0 -32
- package/build/components/SplitPane/constants.js +0 -4
- package/build/components/SplitPane/index.d.ts +0 -8
- package/build/components/SplitPane/index.js +0 -18
- package/build/components/SplitPane/types.d.ts +0 -2
- package/build/components/SplitTooltip/SplitTooltip.d.ts +0 -49
- package/build/components/SplitTooltip/SplitTooltip.js +0 -122
- package/build/components/SplitTooltip/index.d.ts +0 -2
- package/build/components/SplitTooltip/index.js +0 -1
- package/build/constants/common.js +0 -2
- package/build/constants/index.d.ts +0 -3
- package/build/constants/index.js +0 -3
- package/build/constants/misc.js +0 -19
- package/build/constants/widget-data.js +0 -47
- package/build/hooks/index.d.ts +0 -1
- package/build/hooks/index.js +0 -1
- package/build/hooks/misc.js +0 -8
- package/build/i18n/index.d.ts +0 -7
- package/build/i18n/index.js +0 -10
- package/build/index.d.ts +0 -8
- package/build/index.js +0 -6
- package/build/libs/chartkit-error/chartkit-error.js +0 -21
- package/build/libs/index.d.ts +0 -3
- package/build/libs/index.js +0 -2
- package/build/libs/settings/eventEmitter.js +0 -25
- package/build/libs/settings/mergeSettingStrategy.js +0 -31
- package/build/libs/settings/settings.d.ts +0 -22
- package/build/libs/settings/settings.js +0 -41
- package/build/plugins/gravity-charts/index.d.ts +0 -4
- package/build/plugins/gravity-charts/index.js +0 -7
- package/build/plugins/gravity-charts/renderer/GravityChartsWidget.d.ts +0 -22
- package/build/plugins/gravity-charts/renderer/GravityChartsWidget.js +0 -45
- package/build/plugins/gravity-charts/renderer/utils.d.ts +0 -2
- package/build/plugins/gravity-charts/renderer/utils.js +0 -18
- package/build/plugins/gravity-charts/renderer/withSplitPane/TooltipContent.js +0 -13
- package/build/plugins/gravity-charts/renderer/withSplitPane/useViewportSplitTooltipLayout.d.ts +0 -3
- package/build/plugins/gravity-charts/renderer/withSplitPane/useViewportSplitTooltipLayout.js +0 -29
- package/build/plugins/gravity-charts/renderer/withSplitPane/withSplitPane.d.ts +0 -4
- package/build/plugins/gravity-charts/renderer/withSplitPane/withSplitPane.js +0 -48
- package/build/plugins/gravity-charts/types.d.ts +0 -5
- package/build/plugins/gravity-charts/types.js +0 -1
- package/build/plugins/highcharts/index.d.ts +0 -4
- package/build/plugins/highcharts/index.js +0 -7
- package/build/plugins/highcharts/renderer/HighchartsWidget.d.ts +0 -32
- package/build/plugins/highcharts/renderer/HighchartsWidget.js +0 -6
- package/build/plugins/highcharts/renderer/components/HighchartsComponent.d.ts +0 -579
- package/build/plugins/highcharts/renderer/components/HighchartsComponent.js +0 -155
- package/build/plugins/highcharts/renderer/components/HighchartsReact.d.ts +0 -20
- package/build/plugins/highcharts/renderer/components/HighchartsReact.js +0 -74
- package/build/plugins/highcharts/renderer/components/useElementSize.js +0 -50
- package/build/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.d.ts +0 -18
- package/build/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.js +0 -217
- package/build/plugins/highcharts/renderer/helpers/add-holidays.d.ts +0 -3
- package/build/plugins/highcharts/renderer/helpers/add-holidays.js +0 -43
- package/build/plugins/highcharts/renderer/helpers/comments/drawing.js +0 -571
- package/build/plugins/highcharts/renderer/helpers/config/config.js +0 -1515
- package/build/plugins/highcharts/renderer/helpers/config/handleLegendItemClick.js +0 -75
- package/build/plugins/highcharts/renderer/helpers/config/options.js +0 -350
- package/build/plugins/highcharts/renderer/helpers/config/types.js +0 -1
- package/build/plugins/highcharts/renderer/helpers/config/utils/addShowInNavigatorToSeries.d.ts +0 -10
- package/build/plugins/highcharts/renderer/helpers/config/utils/addShowInNavigatorToSeries.js +0 -42
- package/build/plugins/highcharts/renderer/helpers/config/utils/buildNavigatorFallback.js +0 -17
- package/build/plugins/highcharts/renderer/helpers/config/utils/calculatePrecision.js +0 -20
- package/build/plugins/highcharts/renderer/helpers/config/utils/concatStrings.js +0 -1
- package/build/plugins/highcharts/renderer/helpers/config/utils/getChartKitFormattedValue.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/config/utils/getChartKitFormattedValue.js +0 -15
- package/build/plugins/highcharts/renderer/helpers/config/utils/getFormatOptionsFromLine.d.ts +0 -3
- package/build/plugins/highcharts/renderer/helpers/config/utils/getFormatOptionsFromLine.js +0 -15
- package/build/plugins/highcharts/renderer/helpers/config/utils/getXAxisThresholdValue.js +0 -20
- package/build/plugins/highcharts/renderer/helpers/config/utils/index.d.ts +0 -78
- package/build/plugins/highcharts/renderer/helpers/config/utils/index.js +0 -21
- package/build/plugins/highcharts/renderer/helpers/config/utils/isNavigatorSeries.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/config/utils/isNavigatorSeries.js +0 -3
- package/build/plugins/highcharts/renderer/helpers/config/utils/isSafari.js +0 -12
- package/build/plugins/highcharts/renderer/helpers/config/utils/localStorage.js +0 -23
- package/build/plugins/highcharts/renderer/helpers/config/utils/mergeArrayWithObject.js +0 -10
- package/build/plugins/highcharts/renderer/helpers/config/utils/numberFormat.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/config/utils/numberFormat.js +0 -19
- package/build/plugins/highcharts/renderer/helpers/config/utils/setNavigatorDefaultPeriod.d.ts +0 -13
- package/build/plugins/highcharts/renderer/helpers/config/utils/setNavigatorDefaultPeriod.js +0 -27
- package/build/plugins/highcharts/renderer/helpers/config/utils/tooltip.d.ts +0 -7
- package/build/plugins/highcharts/renderer/helpers/config/utils/tooltip.js +0 -25
- package/build/plugins/highcharts/renderer/helpers/constants.js +0 -31
- package/build/plugins/highcharts/renderer/helpers/graph.css +0 -98
- package/build/plugins/highcharts/renderer/helpers/graph.d.ts +0 -553
- package/build/plugins/highcharts/renderer/helpers/graph.js +0 -88
- package/build/plugins/highcharts/renderer/helpers/highcharts/colors.js +0 -17
- package/build/plugins/highcharts/renderer/helpers/highcharts/highcharts.js +0 -370
- package/build/plugins/highcharts/renderer/helpers/highcharts/utils/calcucalteClosestPointManually.js +0 -19
- package/build/plugins/highcharts/renderer/helpers/highcharts/utils/index.d.ts +0 -1
- package/build/plugins/highcharts/renderer/helpers/highcharts/utils/index.js +0 -1
- package/build/plugins/highcharts/renderer/helpers/prepare-data.js +0 -181
- package/build/plugins/highcharts/renderer/helpers/tooltip/constants.js +0 -14
- package/build/plugins/highcharts/renderer/helpers/tooltip/helpers.js +0 -5
- package/build/plugins/highcharts/renderer/helpers/tooltip/index.d.ts +0 -13
- package/build/plugins/highcharts/renderer/helpers/tooltip/index.js +0 -263
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/index.d.ts +0 -6
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/index.js +0 -22
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashDotLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashDotLineIcon.js +0 -20
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DashLineIcon.js +0 -25
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DotLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/DotLineIcon.js +0 -20
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotDotLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotDotLineIcon.js +0 -18
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashDotLineIcon.js +0 -18
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/LongDashLineIcon.js +0 -15
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotDotLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotDotLineIcon.js +0 -18
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashDotLineIcon.js +0 -18
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDashLineIcon.js +0 -18
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDotLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/ShortDotLineIcon.js +0 -20
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/SolidLineIcon.d.ts +0 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/SolidLineIcon.js +0 -13
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/index.d.ts +0 -11
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/template-icons/index.js +0 -11
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/types.js +0 -1
- package/build/plugins/highcharts/renderer/helpers/tooltip/render-shape-icon/utils.js +0 -5
- package/build/plugins/highcharts/renderer/helpers/tooltip/tooltip.css +0 -370
- package/build/plugins/highcharts/renderer/helpers/tooltip/types.d.ts +0 -88
- package/build/plugins/highcharts/renderer/helpers/tooltip/types.js +0 -1
- package/build/plugins/highcharts/renderer/helpers/types.d.ts +0 -22
- package/build/plugins/highcharts/renderer/helpers/types.js +0 -1
- package/build/plugins/highcharts/types/comments.js +0 -1
- package/build/plugins/highcharts/types/index.d.ts +0 -4
- package/build/plugins/highcharts/types/index.js +0 -1
- package/build/plugins/highcharts/types/misc.d.ts +0 -22
- package/build/plugins/highcharts/types/misc.js +0 -1
- package/build/plugins/highcharts/types/widget.d.ts +0 -117
- package/build/plugins/highcharts/types/widget.js +0 -1
- package/build/plugins/indicator/index.d.ts +0 -3
- package/build/plugins/indicator/index.js +0 -6
- package/build/plugins/indicator/renderer/IndicatorItem.d.ts +0 -7
- package/build/plugins/indicator/renderer/IndicatorItem.js +0 -15
- package/build/plugins/indicator/renderer/IndicatorWidget.css +0 -62
- package/build/plugins/indicator/renderer/IndicatorWidget.d.ts +0 -21
- package/build/plugins/indicator/renderer/IndicatorWidget.js +0 -34
- package/build/plugins/indicator/types.js +0 -1
- package/build/plugins/shared/format-number/format-number.d.ts +0 -5
- package/build/plugins/shared/format-number/format-number.js +0 -87
- package/build/plugins/shared/format-number/i18n/i18n.js +0 -8
- package/build/plugins/shared/format-number/types.js +0 -1
- package/build/plugins/shared/index.d.ts +0 -2
- package/build/plugins/shared/index.js +0 -1
- package/build/plugins/yagr/index.d.ts +0 -3
- package/build/plugins/yagr/index.js +0 -6
- package/build/plugins/yagr/renderer/YagrWidget.d.ts +0 -25
- package/build/plugins/yagr/renderer/YagrWidget.js +0 -79
- package/build/plugins/yagr/renderer/polyfills.js +0 -15
- package/build/plugins/yagr/renderer/tooltip/helpers/escapeHTML.js +0 -5
- package/build/plugins/yagr/renderer/tooltip/index.d.ts +0 -1
- package/build/plugins/yagr/renderer/tooltip/index.js +0 -1
- package/build/plugins/yagr/renderer/tooltip/renderTooltip.d.ts +0 -2
- package/build/plugins/yagr/renderer/tooltip/renderTooltip.js +0 -60
- package/build/plugins/yagr/renderer/tooltip/tooltip.css +0 -371
- package/build/plugins/yagr/renderer/tooltip/tooltip.d.ts +0 -3
- package/build/plugins/yagr/renderer/tooltip/tooltip.js +0 -230
- package/build/plugins/yagr/renderer/tooltip/types.js +0 -1
- package/build/plugins/yagr/renderer/useWidgetData.d.ts +0 -6
- package/build/plugins/yagr/renderer/useWidgetData.js +0 -26
- package/build/plugins/yagr/renderer/utils.d.ts +0 -29
- package/build/plugins/yagr/renderer/utils.js +0 -141
- package/build/plugins/yagr/types.d.ts +0 -32
- package/build/plugins/yagr/types.js +0 -1
- package/build/types/index.d.ts +0 -67
- package/build/types/index.js +0 -1
- package/build/types/misc.js +0 -1
- package/build/types/widget.d.ts +0 -41
- package/build/types/widget.js +0 -1
- package/build/utils/cn.js +0 -4
- package/build/utils/common.js +0 -8
- package/build/utils/getErrorMessage.d.ts +0 -2
- package/build/utils/getErrorMessage.js +0 -5
- package/build/utils/index.d.ts +0 -4
- package/build/utils/index.js +0 -4
- package/build/utils/misc.d.ts +0 -2
- package/build/utils/misc.js +0 -7
- package/build/utils/performance.js +0 -20
- package/build/utils/react.js +0 -4
- /package/build/{components → cjs/components}/Loader/Loader.css +0 -0
- /package/build/{components → cjs/components}/SplitPane/constants.d.ts +0 -0
- /package/build/{constants → cjs/constants}/common.d.ts +0 -0
- /package/build/{constants → cjs/constants}/misc.d.ts +0 -0
- /package/build/{constants → cjs/constants}/widget-data.d.ts +0 -0
- /package/build/{hooks → cjs/hooks}/misc.d.ts +0 -0
- /package/build/{i18n → cjs/i18n}/keysets/en.json +0 -0
- /package/build/{i18n → cjs/i18n}/keysets/ru.json +0 -0
- /package/build/{libs → cjs/libs}/chartkit-error/chartkit-error.d.ts +0 -0
- /package/build/{libs → cjs/libs}/settings/eventEmitter.d.ts +0 -0
- /package/build/{libs → cjs/libs}/settings/mergeSettingStrategy.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/gravity-charts/renderer/withSplitPane/TooltipContent.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/components/HighchartsComponent.css +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/components/useElementSize.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/components/withSplitPane/WithSplitPane.css +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/comments/drawing.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/config.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/handleLegendItemClick.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/options.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/types.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/utils/buildNavigatorFallback.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/utils/calculatePrecision.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/utils/concatStrings.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/utils/getXAxisThresholdValue.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/utils/isSafari.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/utils/localStorage.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/config/utils/mergeArrayWithObject.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/constants.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/highcharts/colors.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/highcharts/highcharts.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/highcharts/utils/calcucalteClosestPointManually.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/prepare-data.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/tooltip/constants.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/tooltip/helpers.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/tooltip/render-shape-icon/types.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/renderer/helpers/tooltip/render-shape-icon/utils.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/types/comments.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/types/highcharts-extends.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/highcharts/types/lib.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/indicator/types.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/shared/format-number/i18n/en.json +0 -0
- /package/build/{plugins → cjs/plugins}/shared/format-number/i18n/i18n.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/shared/format-number/i18n/ru.json +0 -0
- /package/build/{plugins → cjs/plugins}/shared/format-number/types.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/yagr/renderer/YagrWidget.css +0 -0
- /package/build/{components/SplitPane/types.js → cjs/plugins/yagr/renderer/polyfills.d.ts} +0 -0
- /package/build/{plugins → cjs/plugins}/yagr/renderer/tooltip/helpers/escapeHTML.d.ts +0 -0
- /package/build/{plugins → cjs/plugins}/yagr/renderer/tooltip/types.d.ts +0 -0
- /package/build/{types → cjs/types}/misc.d.ts +0 -0
- /package/build/{utils → cjs/utils}/cn.d.ts +0 -0
- /package/build/{utils → cjs/utils}/common.d.ts +0 -0
- /package/build/{utils → cjs/utils}/performance.d.ts +0 -0
- /package/build/{utils → cjs/utils}/react.d.ts +0 -0
- /package/build/{plugins/highcharts/types/lib.js → esm/plugins/highcharts/types/lib.d.ts} +0 -0
- /package/build/{plugins → esm/plugins}/yagr/renderer/polyfills.d.ts +0 -0
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SplitTooltipLayout = exports.SPLIT_TOOLTIP_MAIN_PANE_RATIO = exports.SPLIT_TOOLTIP_RESIZER_SIZE = void 0;
|
|
4
|
+
exports.getSplitTooltipLayout = getSplitTooltipLayout;
|
|
5
|
+
exports.getSplitTooltipMainPaneSize = getSplitTooltipMainPaneSize;
|
|
6
|
+
exports.getSplitTooltipSizeLimits = getSplitTooltipSizeLimits;
|
|
7
|
+
exports.SplitTooltip = SplitTooltip;
|
|
8
|
+
const tslib_1 = require("tslib");
|
|
9
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
10
|
+
const uikit_1 = require("@gravity-ui/uikit");
|
|
11
|
+
const SplitPane_1 = require("../SplitPane/index.js");
|
|
12
|
+
Object.defineProperty(exports, "SplitTooltipLayout", { enumerable: true, get: function () { return SplitPane_1.SplitLayout; } });
|
|
13
|
+
exports.SPLIT_TOOLTIP_RESIZER_SIZE = 24;
|
|
14
|
+
exports.SPLIT_TOOLTIP_MAIN_PANE_RATIO = 0.6;
|
|
15
|
+
const hiddenResizerStyle = { display: 'none' };
|
|
16
|
+
const defaultTooltipPaneStyle = { overflow: 'auto' };
|
|
17
|
+
function getSplitTooltipLayout(width, height, layout) {
|
|
18
|
+
return layout ?? (width > height ? SplitPane_1.SplitLayout.VERTICAL : SplitPane_1.SplitLayout.HORIZONTAL);
|
|
19
|
+
}
|
|
20
|
+
function getSplitTooltipMainPaneSize({ containerHeight, containerWidth, layout, mainPaneRatio = exports.SPLIT_TOOLTIP_MAIN_PANE_RATIO, minMainPaneSize, tooltipHeight, }) {
|
|
21
|
+
if (layout === SplitPane_1.SplitLayout.VERTICAL) {
|
|
22
|
+
return containerWidth * mainPaneRatio;
|
|
23
|
+
}
|
|
24
|
+
const { minSize } = getSplitTooltipSizeLimits(containerHeight, tooltipHeight, minMainPaneSize);
|
|
25
|
+
return Math.max(minMainPaneSize === undefined ? 0 : minSize, containerHeight - exports.SPLIT_TOOLTIP_RESIZER_SIZE - tooltipHeight);
|
|
26
|
+
}
|
|
27
|
+
function getSplitTooltipSizeLimits(containerHeight, tooltipHeight, minMainPaneSize, preserveManualSize = false) {
|
|
28
|
+
const availableSize = Math.max(0, containerHeight - exports.SPLIT_TOOLTIP_RESIZER_SIZE);
|
|
29
|
+
const contentSize = Math.max(0, availableSize - tooltipHeight);
|
|
30
|
+
const defaultMinSize = preserveManualSize ? 0 : Math.min(containerHeight / 3, contentSize);
|
|
31
|
+
const minSize = minMainPaneSize === undefined
|
|
32
|
+
? defaultMinSize
|
|
33
|
+
: Math.min(Math.max(0, minMainPaneSize), availableSize / 2);
|
|
34
|
+
const maxSize = preserveManualSize ? availableSize : Math.max(minSize, contentSize);
|
|
35
|
+
return { minSize, maxSize };
|
|
36
|
+
}
|
|
37
|
+
function SplitTooltipContent(props) {
|
|
38
|
+
const { containerHeight, containerWidth, enabled = true, renderMainPane, renderTooltip, layout: layoutProp, mainPaneRatio = exports.SPLIT_TOOLTIP_MAIN_PANE_RATIO, minMainPaneSize, preserveManualSize = false, resizerVisible, onMainPaneSizeChange, style, mainPaneStyle, tooltipPaneStyle, } = props;
|
|
39
|
+
const tooltipRef = react_1.default.useRef(null);
|
|
40
|
+
const layout = getSplitTooltipLayout(containerWidth, containerHeight, layoutProp);
|
|
41
|
+
const [tooltipHeight, setTooltipHeight] = react_1.default.useState(0);
|
|
42
|
+
const [userSize, setUserSize] = react_1.default.useState();
|
|
43
|
+
const lastNotificationRef = react_1.default.useRef(null);
|
|
44
|
+
const onMainPaneSizeChangeRef = react_1.default.useRef(onMainPaneSizeChange);
|
|
45
|
+
onMainPaneSizeChangeRef.current = onMainPaneSizeChange;
|
|
46
|
+
const handleTooltipResize = react_1.default.useCallback(() => {
|
|
47
|
+
if (enabled) {
|
|
48
|
+
const nextTooltipHeight = tooltipRef.current?.getBoundingClientRect().height ?? 0;
|
|
49
|
+
setTooltipHeight(nextTooltipHeight);
|
|
50
|
+
}
|
|
51
|
+
}, [enabled]);
|
|
52
|
+
(0, uikit_1.useResizeObserver)({
|
|
53
|
+
ref: tooltipRef,
|
|
54
|
+
onResize: handleTooltipResize,
|
|
55
|
+
});
|
|
56
|
+
react_1.default.useLayoutEffect(handleTooltipResize, [handleTooltipResize, layout, containerWidth]);
|
|
57
|
+
const { minSize, maxSize } = getSplitTooltipSizeLimits(containerHeight, tooltipHeight, minMainPaneSize, preserveManualSize);
|
|
58
|
+
const automaticSize = getSplitTooltipMainPaneSize({
|
|
59
|
+
containerHeight,
|
|
60
|
+
containerWidth,
|
|
61
|
+
layout,
|
|
62
|
+
mainPaneRatio,
|
|
63
|
+
minMainPaneSize,
|
|
64
|
+
tooltipHeight,
|
|
65
|
+
});
|
|
66
|
+
const [size, setSize] = react_1.default.useState(automaticSize);
|
|
67
|
+
const previousSizingRef = react_1.default.useRef({ layout, maxSize });
|
|
68
|
+
let effectiveSize = automaticSize;
|
|
69
|
+
if (!enabled) {
|
|
70
|
+
effectiveSize = layout === SplitPane_1.SplitLayout.HORIZONTAL ? containerHeight : containerWidth;
|
|
71
|
+
}
|
|
72
|
+
else if (layout === SplitPane_1.SplitLayout.HORIZONTAL) {
|
|
73
|
+
if (preserveManualSize) {
|
|
74
|
+
if (userSize !== undefined) {
|
|
75
|
+
effectiveSize = Math.max(minSize, Math.min(maxSize, userSize));
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
else if (previousSizingRef.current.layout === layout) {
|
|
79
|
+
effectiveSize =
|
|
80
|
+
size === previousSizingRef.current.maxSize
|
|
81
|
+
? maxSize
|
|
82
|
+
: Math.max(minSize, Math.min(maxSize, size));
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
react_1.default.useLayoutEffect(() => {
|
|
86
|
+
if (enabled) {
|
|
87
|
+
previousSizingRef.current = { layout, maxSize };
|
|
88
|
+
if (effectiveSize !== size) {
|
|
89
|
+
setSize(effectiveSize);
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}, [effectiveSize, enabled, layout, maxSize, size]);
|
|
93
|
+
react_1.default.useLayoutEffect(() => {
|
|
94
|
+
const previousNotification = lastNotificationRef.current;
|
|
95
|
+
if (previousNotification?.size === effectiveSize &&
|
|
96
|
+
previousNotification.layout === layout) {
|
|
97
|
+
return undefined;
|
|
98
|
+
}
|
|
99
|
+
const callback = onMainPaneSizeChangeRef.current;
|
|
100
|
+
if (!callback) {
|
|
101
|
+
return undefined;
|
|
102
|
+
}
|
|
103
|
+
lastNotificationRef.current = { layout, size: effectiveSize };
|
|
104
|
+
callback(effectiveSize, layout);
|
|
105
|
+
return undefined;
|
|
106
|
+
});
|
|
107
|
+
// SplitPane treats maxSize=0 as an offset from the container size, so disable dragging
|
|
108
|
+
// when no space remains after the resizer.
|
|
109
|
+
const allowResize = enabled && layout === SplitPane_1.SplitLayout.HORIZONTAL && containerWidth > 0 && maxSize > 0;
|
|
110
|
+
const renderProps = { layout, size: effectiveSize };
|
|
111
|
+
return (react_1.default.createElement(SplitPane_1.StyledSplitPane, { allowResize: allowResize, maxSize: maxSize, minSize: minSize, size: effectiveSize, split: layout, style: style, onChange: preserveManualSize ? setUserSize : setSize, resizerStyle: enabled && resizerVisible ? undefined : hiddenResizerStyle, paneOneRender: () => renderMainPane(renderProps), paneTwoRender: () => react_1.default.createElement("div", { ref: tooltipRef }, renderTooltip(renderProps)), pane1Style: mainPaneStyle, pane2Style: {
|
|
112
|
+
...defaultTooltipPaneStyle,
|
|
113
|
+
...((preserveManualSize || minMainPaneSize !== undefined) && {
|
|
114
|
+
minHeight: 0,
|
|
115
|
+
minWidth: 0,
|
|
116
|
+
}),
|
|
117
|
+
...tooltipPaneStyle,
|
|
118
|
+
...(!enabled && { display: 'none' }),
|
|
119
|
+
} }));
|
|
120
|
+
}
|
|
121
|
+
function SplitTooltip(props) {
|
|
122
|
+
const containerRef = react_1.default.useRef(null);
|
|
123
|
+
const [dimensions, setDimensions] = react_1.default.useState({ height: 0, width: 0, initialized: false });
|
|
124
|
+
const updateDimensions = react_1.default.useCallback(() => {
|
|
125
|
+
const rect = containerRef.current?.getBoundingClientRect();
|
|
126
|
+
const height = rect?.height ?? 0;
|
|
127
|
+
const width = rect?.width ?? 0;
|
|
128
|
+
setDimensions((previous) => ({
|
|
129
|
+
height,
|
|
130
|
+
width,
|
|
131
|
+
initialized: previous.initialized || (height > 0 && width > 0),
|
|
132
|
+
}));
|
|
133
|
+
}, []);
|
|
134
|
+
(0, uikit_1.useResizeObserver)({
|
|
135
|
+
ref: containerRef,
|
|
136
|
+
onResize: updateDimensions,
|
|
137
|
+
});
|
|
138
|
+
react_1.default.useLayoutEffect(updateDimensions, [updateDimensions]);
|
|
139
|
+
return (react_1.default.createElement("div", { ref: containerRef, style: { position: 'relative', height: '100%' } }, dimensions.initialized ? (react_1.default.createElement(SplitTooltipContent, { ...props, containerHeight: dimensions.height, containerWidth: dimensions.width })) : null));
|
|
140
|
+
}
|
|
141
|
+
//# sourceMappingURL=SplitTooltip.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SplitTooltip.js","sourceRoot":"../../../../src","sources":["components/SplitTooltip/SplitTooltip.tsx"],"names":[],"mappings":"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","sourcesContent":["import React from 'react';\n\nimport {useResizeObserver} from '@gravity-ui/uikit';\n\nimport {SplitLayout, StyledSplitPane} from '../SplitPane';\nimport type {SplitLayoutType} from '../SplitPane';\n\nexport const SPLIT_TOOLTIP_RESIZER_SIZE = 24;\nexport const SPLIT_TOOLTIP_MAIN_PANE_RATIO = 0.6;\n\nexport {SplitLayout as SplitTooltipLayout};\nexport type SplitTooltipLayout = SplitLayoutType;\n\nexport interface SplitTooltipRenderProps {\n /** The active pane layout. */\n layout: SplitTooltipLayout;\n /** The current size of the main pane in pixels. */\n size: number;\n}\n\nexport interface SplitTooltipProps {\n /** Whether to show the tooltip pane. Defaults to `true`. Disabling preserves the mounted main pane. */\n enabled?: boolean;\n /**\n * The controlled pane layout. When omitted, the layout is derived from the container size:\n * vertical when width is greater than height, horizontal otherwise.\n */\n layout?: SplitTooltipLayout;\n /** The share of the container width occupied by the main pane in vertical layout. Defaults to `0.6`. */\n mainPaneRatio?: number;\n /**\n * Minimum main pane height in pixels in horizontal layout. Does not apply in vertical layout.\n * Capped at half the height available after the resizer. When omitted, automatic sizing has no minimum.\n */\n minMainPaneSize?: number;\n /** Additional styles for the main pane. */\n mainPaneStyle?: React.CSSProperties;\n /** Called after initialization and whenever the main pane size or layout changes. */\n onMainPaneSizeChange?: (size: number, layout: SplitTooltipLayout) => void;\n /**\n * Preserves the manually selected horizontal main pane size across content, container and layout\n * changes, allowing the tooltip to shrink and scroll. Defaults to `false`.\n * Before the first drag, sizing follows the tooltip content in either mode.\n */\n preserveManualSize?: boolean;\n /** Renders the main pane with its current layout and size. */\n renderMainPane: (props: SplitTooltipRenderProps) => React.ReactNode;\n /** Renders the tooltip pane with the current main pane layout and size. */\n renderTooltip: (props: SplitTooltipRenderProps) => React.ReactNode;\n /** Controls the resizer visibility without hiding the tooltip pane. Defaults to `false`. */\n resizerVisible?: boolean;\n /** Additional styles for the split pane container. */\n style?: React.CSSProperties;\n /** Additional styles for the tooltip pane. */\n tooltipPaneStyle?: React.CSSProperties;\n}\n\ntype SplitTooltipContentProps = SplitTooltipProps & {\n containerHeight: number;\n containerWidth: number;\n};\n\nconst hiddenResizerStyle = {display: 'none'};\nconst defaultTooltipPaneStyle = {overflow: 'auto'};\n\nexport function getSplitTooltipLayout(\n width: number,\n height: number,\n layout?: SplitTooltipLayout,\n): SplitTooltipLayout {\n return layout ?? (width > height ? SplitLayout.VERTICAL : SplitLayout.HORIZONTAL);\n}\n\nexport function getSplitTooltipMainPaneSize({\n containerHeight,\n containerWidth,\n layout,\n mainPaneRatio = SPLIT_TOOLTIP_MAIN_PANE_RATIO,\n minMainPaneSize,\n tooltipHeight,\n}: {\n containerHeight: number;\n containerWidth: number;\n layout: SplitTooltipLayout;\n mainPaneRatio?: number;\n minMainPaneSize?: number;\n tooltipHeight: number;\n}) {\n if (layout === SplitLayout.VERTICAL) {\n return containerWidth * mainPaneRatio;\n }\n\n const {minSize} = getSplitTooltipSizeLimits(containerHeight, tooltipHeight, minMainPaneSize);\n return Math.max(\n minMainPaneSize === undefined ? 0 : minSize,\n containerHeight - SPLIT_TOOLTIP_RESIZER_SIZE - tooltipHeight,\n );\n}\n\nexport function getSplitTooltipSizeLimits(\n containerHeight: number,\n tooltipHeight: number,\n minMainPaneSize?: number,\n preserveManualSize = false,\n) {\n const availableSize = Math.max(0, containerHeight - SPLIT_TOOLTIP_RESIZER_SIZE);\n const contentSize = Math.max(0, availableSize - tooltipHeight);\n const defaultMinSize = preserveManualSize ? 0 : Math.min(containerHeight / 3, contentSize);\n const minSize =\n minMainPaneSize === undefined\n ? defaultMinSize\n : Math.min(Math.max(0, minMainPaneSize), availableSize / 2);\n const maxSize = preserveManualSize ? availableSize : Math.max(minSize, contentSize);\n\n return {minSize, maxSize};\n}\n\nfunction SplitTooltipContent(props: SplitTooltipContentProps) {\n const {\n containerHeight,\n containerWidth,\n enabled = true,\n renderMainPane,\n renderTooltip,\n layout: layoutProp,\n mainPaneRatio = SPLIT_TOOLTIP_MAIN_PANE_RATIO,\n minMainPaneSize,\n preserveManualSize = false,\n resizerVisible,\n onMainPaneSizeChange,\n style,\n mainPaneStyle,\n tooltipPaneStyle,\n } = props;\n const tooltipRef = React.useRef<HTMLDivElement | null>(null);\n const layout = getSplitTooltipLayout(containerWidth, containerHeight, layoutProp);\n const [tooltipHeight, setTooltipHeight] = React.useState(0);\n const [userSize, setUserSize] = React.useState<number>();\n const lastNotificationRef = React.useRef<{layout: SplitTooltipLayout; size: number} | null>(\n null,\n );\n const onMainPaneSizeChangeRef = React.useRef(onMainPaneSizeChange);\n onMainPaneSizeChangeRef.current = onMainPaneSizeChange;\n\n const handleTooltipResize = React.useCallback(() => {\n if (enabled) {\n const nextTooltipHeight = tooltipRef.current?.getBoundingClientRect().height ?? 0;\n setTooltipHeight(nextTooltipHeight);\n }\n }, [enabled]);\n\n useResizeObserver({\n ref: tooltipRef,\n onResize: handleTooltipResize,\n });\n\n React.useLayoutEffect(handleTooltipResize, [handleTooltipResize, layout, containerWidth]);\n\n const {minSize, maxSize} = getSplitTooltipSizeLimits(\n containerHeight,\n tooltipHeight,\n minMainPaneSize,\n preserveManualSize,\n );\n const automaticSize = getSplitTooltipMainPaneSize({\n containerHeight,\n containerWidth,\n layout,\n mainPaneRatio,\n minMainPaneSize,\n tooltipHeight,\n });\n const [size, setSize] = React.useState(automaticSize);\n const previousSizingRef = React.useRef({layout, maxSize});\n let effectiveSize = automaticSize;\n if (!enabled) {\n effectiveSize = layout === SplitLayout.HORIZONTAL ? containerHeight : containerWidth;\n } else if (layout === SplitLayout.HORIZONTAL) {\n if (preserveManualSize) {\n if (userSize !== undefined) {\n effectiveSize = Math.max(minSize, Math.min(maxSize, userSize));\n }\n } else if (previousSizingRef.current.layout === layout) {\n effectiveSize =\n size === previousSizingRef.current.maxSize\n ? maxSize\n : Math.max(minSize, Math.min(maxSize, size));\n }\n }\n\n React.useLayoutEffect(() => {\n if (enabled) {\n previousSizingRef.current = {layout, maxSize};\n if (effectiveSize !== size) {\n setSize(effectiveSize);\n }\n }\n }, [effectiveSize, enabled, layout, maxSize, size]);\n\n React.useLayoutEffect(() => {\n const previousNotification = lastNotificationRef.current;\n\n if (\n previousNotification?.size === effectiveSize &&\n previousNotification.layout === layout\n ) {\n return undefined;\n }\n\n const callback = onMainPaneSizeChangeRef.current;\n if (!callback) {\n return undefined;\n }\n\n lastNotificationRef.current = {layout, size: effectiveSize};\n callback(effectiveSize, layout);\n return undefined;\n });\n\n // SplitPane treats maxSize=0 as an offset from the container size, so disable dragging\n // when no space remains after the resizer.\n const allowResize =\n enabled && layout === SplitLayout.HORIZONTAL && containerWidth > 0 && maxSize > 0;\n const renderProps = {layout, size: effectiveSize};\n\n return (\n <StyledSplitPane\n allowResize={allowResize}\n maxSize={maxSize}\n minSize={minSize}\n size={effectiveSize}\n split={layout}\n style={style}\n onChange={preserveManualSize ? setUserSize : setSize}\n resizerStyle={enabled && resizerVisible ? undefined : hiddenResizerStyle}\n paneOneRender={() => renderMainPane(renderProps)}\n paneTwoRender={() => <div ref={tooltipRef}>{renderTooltip(renderProps)}</div>}\n pane1Style={mainPaneStyle}\n pane2Style={{\n ...defaultTooltipPaneStyle,\n ...((preserveManualSize || minMainPaneSize !== undefined) && {\n minHeight: 0,\n minWidth: 0,\n }),\n ...tooltipPaneStyle,\n ...(!enabled && {display: 'none'}),\n }}\n />\n );\n}\n\nexport function SplitTooltip(props: SplitTooltipProps) {\n const containerRef = React.useRef<HTMLDivElement | null>(null);\n const [dimensions, setDimensions] = React.useState({height: 0, width: 0, initialized: false});\n\n const updateDimensions = React.useCallback(() => {\n const rect = containerRef.current?.getBoundingClientRect();\n const height = rect?.height ?? 0;\n const width = rect?.width ?? 0;\n setDimensions((previous) => ({\n height,\n width,\n initialized: previous.initialized || (height > 0 && width > 0),\n }));\n }, []);\n\n useResizeObserver({\n ref: containerRef,\n onResize: updateDimensions,\n });\n\n React.useLayoutEffect(updateDimensions, [updateDimensions]);\n\n return (\n <div ref={containerRef} style={{position: 'relative', height: '100%'}}>\n {dimensions.initialized ? (\n <SplitTooltipContent\n {...props}\n containerHeight={dimensions.height}\n containerWidth={dimensions.width}\n />\n ) : null}\n </div>\n );\n}\n"]}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SplitTooltipLayout = exports.SplitTooltip = void 0;
|
|
4
|
+
var SplitTooltip_1 = require("./SplitTooltip.js");
|
|
5
|
+
Object.defineProperty(exports, "SplitTooltip", { enumerable: true, get: function () { return SplitTooltip_1.SplitTooltip; } });
|
|
6
|
+
Object.defineProperty(exports, "SplitTooltipLayout", { enumerable: true, get: function () { return SplitTooltip_1.SplitTooltipLayout; } });
|
|
7
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../../../../src","sources":["components/SplitTooltip/index.ts"],"names":[],"mappings":";;;AAAA,kDAAgE;AAAxD,4GAAA,YAAY,OAAA;AAAE,kHAAA,kBAAkB,OAAA","sourcesContent":["export {SplitTooltip, SplitTooltipLayout} from './SplitTooltip';\nexport type {SplitTooltipProps, SplitTooltipRenderProps} from './SplitTooltip';\n"]}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CHARTKIT_SCROLLABLE_NODE_CLASSNAME = void 0;
|
|
4
|
+
// This css class should be added for DOM element for correct calculation of scrollHeight
|
|
5
|
+
exports.CHARTKIT_SCROLLABLE_NODE_CLASSNAME = 'chartkit-scrollable-node';
|
|
6
|
+
//# sourceMappingURL=common.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"common.js","sourceRoot":"../../../src","sources":["constants/common.ts"],"names":[],"mappings":";;;AAAA,yFAAyF;AAC5E,QAAA,kCAAkC,GAAG,0BAA0B,CAAC","sourcesContent":["// This css class should be added for DOM element for correct calculation of scrollHeight\nexport const CHARTKIT_SCROLLABLE_NODE_CLASSNAME = 'chartkit-scrollable-node';\n"]}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CHARTKIT_SCROLLABLE_NODE_CLASSNAME = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
var common_1 = require("./common.js");
|
|
6
|
+
Object.defineProperty(exports, "CHARTKIT_SCROLLABLE_NODE_CLASSNAME", { enumerable: true, get: function () { return common_1.CHARTKIT_SCROLLABLE_NODE_CLASSNAME; } });
|
|
7
|
+
tslib_1.__exportStar(require("./widget-data.js"), exports);
|
|
8
|
+
tslib_1.__exportStar(require("./misc.js"), exports);
|
|
9
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../../../src","sources":["constants/index.ts"],"names":[],"mappings":";;;;AAAA,sCAA4D;AAApD,4HAAA,kCAAkC,OAAA;AAE1C,2DAA8B;AAC9B,oDAAuB","sourcesContent":["export {CHARTKIT_SCROLLABLE_NODE_CLASSNAME} from './common';\n\nexport * from './widget-data';\nexport * from './misc';\n"]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AVAILABLE_SCREEN_ORIENTATIONS = exports.ScreenOrientation = exports.IS_SCREEN_ORIENTATION_AVAILABLE = exports.IS_WINDOW_AVAILABLE = void 0;
|
|
4
|
+
function checkWindowAvailability() {
|
|
5
|
+
return typeof window === 'object';
|
|
6
|
+
}
|
|
7
|
+
exports.IS_WINDOW_AVAILABLE = checkWindowAvailability();
|
|
8
|
+
function checkScreenOrientationAvailability() {
|
|
9
|
+
// W3C spec implementation
|
|
10
|
+
return (exports.IS_WINDOW_AVAILABLE &&
|
|
11
|
+
typeof window.ScreenOrientation === 'function' &&
|
|
12
|
+
typeof screen.orientation.addEventListener === 'function' &&
|
|
13
|
+
typeof screen.orientation.type === 'string');
|
|
14
|
+
}
|
|
15
|
+
exports.IS_SCREEN_ORIENTATION_AVAILABLE = checkScreenOrientationAvailability();
|
|
16
|
+
exports.ScreenOrientation = {
|
|
17
|
+
PORTRAIT_PRIMARY: 'portrait-primary',
|
|
18
|
+
PORTRAIT_SECONDARY: 'portrait-secondary',
|
|
19
|
+
LANDSCAPE_PRIMARY: 'landscape-primary',
|
|
20
|
+
LANDSCAPE_SECONDARY: 'landscape-secondary',
|
|
21
|
+
};
|
|
22
|
+
exports.AVAILABLE_SCREEN_ORIENTATIONS = Object.values(exports.ScreenOrientation);
|
|
23
|
+
//# sourceMappingURL=misc.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"misc.js","sourceRoot":"../../../src","sources":["constants/misc.ts"],"names":[],"mappings":";;;AAAA,SAAS,uBAAuB;IAC5B,OAAO,OAAO,MAAM,KAAK,QAAQ,CAAC;AACtC,CAAC;AAEY,QAAA,mBAAmB,GAAG,uBAAuB,EAAE,CAAC;AAE7D,SAAS,kCAAkC;IACvC,0BAA0B;IAC1B,OAAO,CACH,2BAAmB;QACnB,OAAO,MAAM,CAAC,iBAAiB,KAAK,UAAU;QAC9C,OAAO,MAAM,CAAC,WAAW,CAAC,gBAAgB,KAAK,UAAU;QACzD,OAAO,MAAM,CAAC,WAAW,CAAC,IAAI,KAAK,QAAQ,CAC9C,CAAC;AACN,CAAC;AAEY,QAAA,+BAA+B,GAAG,kCAAkC,EAAE,CAAC;AAEvE,QAAA,iBAAiB,GAAG;IAC7B,gBAAgB,EAAE,kBAAkB;IACpC,kBAAkB,EAAE,oBAAoB;IACxC,iBAAiB,EAAE,mBAAmB;IACtC,mBAAmB,EAAE,qBAAqB;CACpC,CAAC;AAIE,QAAA,6BAA6B,GAAG,MAAM,CAAC,MAAM,CAAC,yBAAiB,CAAC,CAAC","sourcesContent":["function checkWindowAvailability() {\n return typeof window === 'object';\n}\n\nexport const IS_WINDOW_AVAILABLE = checkWindowAvailability();\n\nfunction checkScreenOrientationAvailability() {\n // W3C spec implementation\n return (\n IS_WINDOW_AVAILABLE &&\n typeof window.ScreenOrientation === 'function' &&\n typeof screen.orientation.addEventListener === 'function' &&\n typeof screen.orientation.type === 'string'\n );\n}\n\nexport const IS_SCREEN_ORIENTATION_AVAILABLE = checkScreenOrientationAvailability();\n\nexport const ScreenOrientation = {\n PORTRAIT_PRIMARY: 'portrait-primary',\n PORTRAIT_SECONDARY: 'portrait-secondary',\n LANDSCAPE_PRIMARY: 'landscape-primary',\n LANDSCAPE_SECONDARY: 'landscape-secondary',\n} as const;\n\nexport type ScreenOrientationType = (typeof ScreenOrientation)[keyof typeof ScreenOrientation];\n\nexport const AVAILABLE_SCREEN_ORIENTATIONS = Object.values(ScreenOrientation);\n"]}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.LayoutAlgorithm = exports.LineCap = exports.SymbolType = exports.DashStyle = exports.SeriesType = void 0;
|
|
4
|
+
exports.SeriesType = {
|
|
5
|
+
Area: 'area',
|
|
6
|
+
BarX: 'bar-x',
|
|
7
|
+
BarY: 'bar-y',
|
|
8
|
+
Line: 'line',
|
|
9
|
+
Pie: 'pie',
|
|
10
|
+
Scatter: 'scatter',
|
|
11
|
+
Treemap: 'treemap',
|
|
12
|
+
Waterfall: 'waterfall',
|
|
13
|
+
};
|
|
14
|
+
var DashStyle;
|
|
15
|
+
(function (DashStyle) {
|
|
16
|
+
DashStyle["Dash"] = "Dash";
|
|
17
|
+
DashStyle["DashDot"] = "DashDot";
|
|
18
|
+
DashStyle["Dot"] = "Dot";
|
|
19
|
+
DashStyle["LongDash"] = "LongDash";
|
|
20
|
+
DashStyle["LongDashDot"] = "LongDashDot";
|
|
21
|
+
DashStyle["LongDashDotDot"] = "LongDashDotDot";
|
|
22
|
+
DashStyle["ShortDash"] = "ShortDash";
|
|
23
|
+
DashStyle["ShortDashDot"] = "ShortDashDot";
|
|
24
|
+
DashStyle["ShortDashDotDot"] = "ShortDashDotDot";
|
|
25
|
+
DashStyle["ShortDot"] = "ShortDot";
|
|
26
|
+
DashStyle["Solid"] = "Solid";
|
|
27
|
+
})(DashStyle || (exports.DashStyle = DashStyle = {}));
|
|
28
|
+
var SymbolType;
|
|
29
|
+
(function (SymbolType) {
|
|
30
|
+
SymbolType["Circle"] = "circle";
|
|
31
|
+
SymbolType["Diamond"] = "diamond";
|
|
32
|
+
SymbolType["Square"] = "square";
|
|
33
|
+
SymbolType["Triangle"] = "triangle";
|
|
34
|
+
SymbolType["TriangleDown"] = "triangle-down";
|
|
35
|
+
})(SymbolType || (exports.SymbolType = SymbolType = {}));
|
|
36
|
+
var LineCap;
|
|
37
|
+
(function (LineCap) {
|
|
38
|
+
LineCap["Butt"] = "butt";
|
|
39
|
+
LineCap["Round"] = "round";
|
|
40
|
+
LineCap["Square"] = "square";
|
|
41
|
+
LineCap["None"] = "none";
|
|
42
|
+
})(LineCap || (exports.LineCap = LineCap = {}));
|
|
43
|
+
var LayoutAlgorithm;
|
|
44
|
+
(function (LayoutAlgorithm) {
|
|
45
|
+
LayoutAlgorithm["Binary"] = "binary";
|
|
46
|
+
LayoutAlgorithm["Dice"] = "dice";
|
|
47
|
+
LayoutAlgorithm["Slice"] = "slice";
|
|
48
|
+
LayoutAlgorithm["SliceDice"] = "slice-dice";
|
|
49
|
+
LayoutAlgorithm["Squarify"] = "squarify";
|
|
50
|
+
})(LayoutAlgorithm || (exports.LayoutAlgorithm = LayoutAlgorithm = {}));
|
|
51
|
+
//# sourceMappingURL=widget-data.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"widget-data.js","sourceRoot":"../../../src","sources":["constants/widget-data.ts"],"names":[],"mappings":";;;AAAa,QAAA,UAAU,GAAG;IACtB,IAAI,EAAE,MAAM;IACZ,IAAI,EAAE,OAAO;IACb,IAAI,EAAE,OAAO;IACb,IAAI,EAAE,MAAM;IACZ,GAAG,EAAE,KAAK;IACV,OAAO,EAAE,SAAS;IAClB,OAAO,EAAE,SAAS;IAClB,SAAS,EAAE,WAAW;CAChB,CAAC;AAEX,IAAY,SAYX;AAZD,WAAY,SAAS;IACjB,0BAAa,CAAA;IACb,gCAAmB,CAAA;IACnB,wBAAW,CAAA;IACX,kCAAqB,CAAA;IACrB,wCAA2B,CAAA;IAC3B,8CAAiC,CAAA;IACjC,oCAAuB,CAAA;IACvB,0CAA6B,CAAA;IAC7B,gDAAmC,CAAA;IACnC,kCAAqB,CAAA;IACrB,4BAAe,CAAA;AACnB,CAAC,EAZW,SAAS,yBAAT,SAAS,QAYpB;AAED,IAAY,UAMX;AAND,WAAY,UAAU;IAClB,+BAAiB,CAAA;IACjB,iCAAmB,CAAA;IACnB,+BAAiB,CAAA;IACjB,mCAAqB,CAAA;IACrB,4CAA8B,CAAA;AAClC,CAAC,EANW,UAAU,0BAAV,UAAU,QAMrB;AAED,IAAY,OAKX;AALD,WAAY,OAAO;IACf,wBAAa,CAAA;IACb,0BAAe,CAAA;IACf,4BAAiB,CAAA;IACjB,wBAAa,CAAA;AACjB,CAAC,EALW,OAAO,uBAAP,OAAO,QAKlB;AAED,IAAY,eAMX;AAND,WAAY,eAAe;IACvB,oCAAiB,CAAA;IACjB,gCAAa,CAAA;IACb,kCAAe,CAAA;IACf,2CAAwB,CAAA;IACxB,wCAAqB,CAAA;AACzB,CAAC,EANW,eAAe,+BAAf,eAAe,QAM1B","sourcesContent":["export const SeriesType = {\n Area: 'area',\n BarX: 'bar-x',\n BarY: 'bar-y',\n Line: 'line',\n Pie: 'pie',\n Scatter: 'scatter',\n Treemap: 'treemap',\n Waterfall: 'waterfall',\n} as const;\n\nexport enum DashStyle {\n Dash = 'Dash',\n DashDot = 'DashDot',\n Dot = 'Dot',\n LongDash = 'LongDash',\n LongDashDot = 'LongDashDot',\n LongDashDotDot = 'LongDashDotDot',\n ShortDash = 'ShortDash',\n ShortDashDot = 'ShortDashDot',\n ShortDashDotDot = 'ShortDashDotDot',\n ShortDot = 'ShortDot',\n Solid = 'Solid',\n}\n\nexport enum SymbolType {\n Circle = 'circle',\n Diamond = 'diamond',\n Square = 'square',\n Triangle = 'triangle',\n TriangleDown = 'triangle-down',\n}\n\nexport enum LineCap {\n Butt = 'butt',\n Round = 'round',\n Square = 'square',\n None = 'none',\n}\n\nexport enum LayoutAlgorithm {\n Binary = 'binary',\n Dice = 'dice',\n Slice = 'slice',\n SliceDice = 'slice-dice',\n Squarify = 'squarify',\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./misc.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../../../src","sources":["hooks/index.ts"],"names":[],"mappings":";;;AAAA,oDAAuB","sourcesContent":["export * from './misc';\n"]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.usePrevious = usePrevious;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
6
|
+
function usePrevious(value) {
|
|
7
|
+
const ref = react_1.default.useRef(undefined);
|
|
8
|
+
react_1.default.useEffect(() => {
|
|
9
|
+
ref.current = value;
|
|
10
|
+
}, [value]);
|
|
11
|
+
return ref.current;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=misc.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"misc.js","sourceRoot":"../../../src","sources":["hooks/misc.ts"],"names":[],"mappings":";;AAEA,kCAQC;;AAVD,0DAA0B;AAE1B,SAAgB,WAAW,CAAI,KAAQ;IACnC,MAAM,GAAG,GAAG,eAAK,CAAC,MAAM,CAAgB,SAAS,CAAC,CAAC;IAEnD,eAAK,CAAC,SAAS,CAAC,GAAG,EAAE;QACjB,GAAG,CAAC,OAAO,GAAG,KAAK,CAAC;IACxB,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC;IAEZ,OAAO,GAAG,CAAC,OAAO,CAAC;AACvB,CAAC","sourcesContent":["import React from 'react';\n\nexport function usePrevious<T>(value: T) {\n const ref = React.useRef<T | undefined>(undefined);\n\n React.useEffect(() => {\n ref.current = value;\n }, [value]);\n\n return ref.current;\n}\n"]}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import type { I18NFn } from '@gravity-ui/i18n';
|
|
2
|
+
import { I18N } from '@gravity-ui/i18n';
|
|
3
|
+
declare const i18nFactory: I18N;
|
|
4
|
+
declare const i18n: I18NFn<{
|
|
5
|
+
common: {
|
|
6
|
+
"tooltip-sum": string;
|
|
7
|
+
"tooltip-rest": string;
|
|
8
|
+
};
|
|
9
|
+
chartkit: {
|
|
10
|
+
error: string;
|
|
11
|
+
"legend-series-hide": string;
|
|
12
|
+
"legend-series-show": string;
|
|
13
|
+
"tooltip-point-format-size": string;
|
|
14
|
+
"tooltip-sum": string;
|
|
15
|
+
"tooltip-rest": string;
|
|
16
|
+
"error-incorrect-key-value-intro": string;
|
|
17
|
+
"error-incorrect-key": string;
|
|
18
|
+
"error-incorrect-value": string;
|
|
19
|
+
};
|
|
20
|
+
"chartkit-table": {
|
|
21
|
+
"message-no-data": string;
|
|
22
|
+
"paginator-rows": string;
|
|
23
|
+
};
|
|
24
|
+
"chartkit-ymap-legend": {
|
|
25
|
+
"label-more": string;
|
|
26
|
+
"label-hide": string;
|
|
27
|
+
"label-heatmap": string;
|
|
28
|
+
};
|
|
29
|
+
error: {
|
|
30
|
+
"label_no-data": string;
|
|
31
|
+
"label_unknown-plugin": string;
|
|
32
|
+
"label_unknown-error": string;
|
|
33
|
+
"label_invalid-axis-category-data-point": string;
|
|
34
|
+
"label_invalid-axis-datetime-data-point": string;
|
|
35
|
+
"label_invalid-axis-linear-data-point": string;
|
|
36
|
+
"label_invalid-pie-data-value": string;
|
|
37
|
+
"label_invalid-series-type": string;
|
|
38
|
+
"label_invalid-series-property": string;
|
|
39
|
+
"label_invalid-treemap-redundant-value": string;
|
|
40
|
+
"label_invalid-treemap-missing-value": string;
|
|
41
|
+
"label_invalid-y-axis-index": string;
|
|
42
|
+
};
|
|
43
|
+
highcharts: {
|
|
44
|
+
"reset-zoom-title": string;
|
|
45
|
+
"decimal-point": string;
|
|
46
|
+
"thousands-sep": string;
|
|
47
|
+
Mon: string;
|
|
48
|
+
Tue: string;
|
|
49
|
+
Wed: string;
|
|
50
|
+
Thu: string;
|
|
51
|
+
Fri: string;
|
|
52
|
+
Sat: string;
|
|
53
|
+
Sun: string;
|
|
54
|
+
Jan: string;
|
|
55
|
+
January: string;
|
|
56
|
+
Feb: string;
|
|
57
|
+
February: string;
|
|
58
|
+
Mar: string;
|
|
59
|
+
March: string;
|
|
60
|
+
Apr: string;
|
|
61
|
+
April: string;
|
|
62
|
+
May: string;
|
|
63
|
+
Jun: string;
|
|
64
|
+
June: string;
|
|
65
|
+
Jul: string;
|
|
66
|
+
July: string;
|
|
67
|
+
Aug: string;
|
|
68
|
+
August: string;
|
|
69
|
+
Sep: string;
|
|
70
|
+
September: string;
|
|
71
|
+
Oct: string;
|
|
72
|
+
October: string;
|
|
73
|
+
Nov: string;
|
|
74
|
+
November: string;
|
|
75
|
+
Dec: string;
|
|
76
|
+
December: string;
|
|
77
|
+
};
|
|
78
|
+
}>;
|
|
79
|
+
export { i18nFactory, i18n };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.i18n = exports.i18nFactory = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const i18n_1 = require("@gravity-ui/i18n");
|
|
6
|
+
const en_json_1 = tslib_1.__importDefault(require("./keysets/en.json"));
|
|
7
|
+
const ru_json_1 = tslib_1.__importDefault(require("./keysets/ru.json"));
|
|
8
|
+
const i18nFactory = new i18n_1.I18N();
|
|
9
|
+
exports.i18nFactory = i18nFactory;
|
|
10
|
+
const EN = 'en';
|
|
11
|
+
const RU = 'ru';
|
|
12
|
+
i18nFactory.registerKeysets(EN, en_json_1.default);
|
|
13
|
+
i18nFactory.registerKeysets(RU, ru_json_1.default);
|
|
14
|
+
// The keyset type is inferred from the argument, so declaration files inline it instead of
|
|
15
|
+
// importing the JSON: in the declarations of an ES module TypeScript requires an import
|
|
16
|
+
// attribute for that, and consumers without `resolveJsonModule` reject it altogether.
|
|
17
|
+
function bindI18n(_keysets) {
|
|
18
|
+
return i18nFactory.i18n.bind(i18nFactory);
|
|
19
|
+
}
|
|
20
|
+
const i18n = bindI18n(en_json_1.default);
|
|
21
|
+
exports.i18n = i18n;
|
|
22
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../../../src","sources":["i18n/index.ts"],"names":[],"mappings":";;;;AACA,2CAAsC;AAItC,wEAAmC;AACnC,wEAAmC;AAEnC,MAAM,WAAW,GAAG,IAAI,WAAI,EAAE,CAAC;AAgBvB,kCAAW;AAfnB,MAAM,EAAE,GAAiB,IAAI,CAAC;AAC9B,MAAM,EAAE,GAAiB,IAAI,CAAC;AAE9B,WAAW,CAAC,eAAe,CAAC,EAAE,EAAE,iBAAE,CAAC,CAAC;AACpC,WAAW,CAAC,eAAe,CAAC,EAAE,EAAE,iBAAE,CAAC,CAAC;AAEpC,2FAA2F;AAC3F,wFAAwF;AACxF,sFAAsF;AACtF,SAAS,QAAQ,CAAuB,QAAW;IAC/C,OAAO,WAAW,CAAC,IAAI,CAAC,IAAI,CAAC,WAAW,CAAc,CAAC;AAC3D,CAAC;AAED,MAAM,IAAI,GAAG,QAAQ,CAAC,iBAAE,CAAC,CAAC;AAEL,oBAAI","sourcesContent":["import type {I18NFn, KeysetData} from '@gravity-ui/i18n';\nimport {I18N} from '@gravity-ui/i18n';\n\nimport type {ChartKitLang} from '../types';\n\nimport en from './keysets/en.json';\nimport ru from './keysets/ru.json';\n\nconst i18nFactory = new I18N();\nconst EN: ChartKitLang = 'en';\nconst RU: ChartKitLang = 'ru';\n\ni18nFactory.registerKeysets(EN, en);\ni18nFactory.registerKeysets(RU, ru);\n\n// The keyset type is inferred from the argument, so declaration files inline it instead of\n// importing the JSON: in the declarations of an ES module TypeScript requires an import\n// attribute for that, and consumers without `resolveJsonModule` reject it altogether.\nfunction bindI18n<T extends KeysetData>(_keysets: T) {\n return i18nFactory.i18n.bind(i18nFactory) as I18NFn<T>;\n}\n\nconst i18n = bindI18n(en);\n\nexport {i18nFactory, i18n};\n"]}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ChartKit } from "./components/ChartKit.js";
|
|
2
|
+
import { settings } from "./libs/index.js";
|
|
3
|
+
export * from "./libs/chartkit-error/chartkit-error.js";
|
|
4
|
+
export { SplitTooltip, SplitTooltipLayout } from "./components/SplitTooltip/index.js";
|
|
5
|
+
export type { SplitTooltipProps, SplitTooltipRenderProps } from "./components/SplitTooltip/index.js";
|
|
6
|
+
export type { ChartKitLang, ChartKitOnLoadData, ChartKitOnRenderData, ChartKitOnChartLoad, ChartKitOnError, ChartKitPlugin, ChartKitProps, ChartKitRef, ChartKitWidgetRef, ChartKitType, ChartKitWidget, } from "./types/index.js";
|
|
7
|
+
export { settings };
|
|
8
|
+
export default ChartKit;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.settings = exports.SplitTooltipLayout = exports.SplitTooltip = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const ChartKit_1 = require("./components/ChartKit.js");
|
|
6
|
+
const libs_1 = require("./libs/index.js");
|
|
7
|
+
Object.defineProperty(exports, "settings", { enumerable: true, get: function () { return libs_1.settings; } });
|
|
8
|
+
tslib_1.__exportStar(require("./libs/chartkit-error/chartkit-error.js"), exports);
|
|
9
|
+
var SplitTooltip_1 = require("./components/SplitTooltip/index.js");
|
|
10
|
+
Object.defineProperty(exports, "SplitTooltip", { enumerable: true, get: function () { return SplitTooltip_1.SplitTooltip; } });
|
|
11
|
+
Object.defineProperty(exports, "SplitTooltipLayout", { enumerable: true, get: function () { return SplitTooltip_1.SplitTooltipLayout; } });
|
|
12
|
+
exports.default = ChartKit_1.ChartKit;
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../../src","sources":["index.ts"],"names":[],"mappings":";;;;AAAA,uDAA+C;AAC/C,0CAAgC;AAoBxB,yFApBA,eAAQ,OAoBA;AAlBhB,kFAAqD;AACrD,mEAA2E;AAAnE,4GAAA,YAAY,OAAA;AAAE,kHAAA,kBAAkB,OAAA;AAmBxC,kBAAe,mBAAQ,CAAC","sourcesContent":["import {ChartKit} from './components/ChartKit';\nimport {settings} from './libs';\n\nexport * from './libs/chartkit-error/chartkit-error';\nexport {SplitTooltip, SplitTooltipLayout} from './components/SplitTooltip';\nexport type {SplitTooltipProps, SplitTooltipRenderProps} from './components/SplitTooltip';\n\nexport type {\n ChartKitLang,\n ChartKitOnLoadData,\n ChartKitOnRenderData,\n ChartKitOnChartLoad,\n ChartKitOnError,\n ChartKitPlugin,\n ChartKitProps,\n ChartKitRef,\n ChartKitWidgetRef,\n ChartKitType,\n ChartKitWidget,\n} from './types';\n\nexport {settings};\n\nexport default ChartKit;\n"]}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isChartKitError = exports.ChartKitError = exports.CHARTKIT_ERROR_CODE = void 0;
|
|
4
|
+
exports.CHARTKIT_ERROR_CODE = {
|
|
5
|
+
NO_DATA: 'ERR.CK.NO_DATA',
|
|
6
|
+
INVALID_DATA: 'ERR.CK.INVALID_DATA',
|
|
7
|
+
UNKNOWN: 'ERR.CK.UNKNOWN_ERROR',
|
|
8
|
+
UNKNOWN_PLUGIN: 'ERR.CK.UNKNOWN_PLUGIN',
|
|
9
|
+
TOO_MANY_LINES: 'ERR.CK.TOO_MANY_LINES',
|
|
10
|
+
};
|
|
11
|
+
class ChartKitError extends Error {
|
|
12
|
+
code;
|
|
13
|
+
isCustomError = true;
|
|
14
|
+
constructor({ originalError, message, code = exports.CHARTKIT_ERROR_CODE.UNKNOWN, } = {}) {
|
|
15
|
+
super(message);
|
|
16
|
+
this.code = code;
|
|
17
|
+
if (originalError) {
|
|
18
|
+
this.name = originalError.name;
|
|
19
|
+
this.stack = originalError.stack;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
exports.ChartKitError = ChartKitError;
|
|
24
|
+
const isChartKitError = (error) => {
|
|
25
|
+
return error instanceof Error && 'isCustomError' in error;
|
|
26
|
+
};
|
|
27
|
+
exports.isChartKitError = isChartKitError;
|
|
28
|
+
//# sourceMappingURL=chartkit-error.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"chartkit-error.js","sourceRoot":"../../../../src","sources":["libs/chartkit-error/chartkit-error.ts"],"names":[],"mappings":";;;AAMa,QAAA,mBAAmB,GAAG;IAC/B,OAAO,EAAE,gBAAgB;IACzB,YAAY,EAAE,qBAAqB;IACnC,OAAO,EAAE,sBAAsB;IAC/B,cAAc,EAAE,uBAAuB;IACvC,cAAc,EAAE,uBAAuB;CAC1C,CAAC;AAEF,MAAa,aAAc,SAAQ,KAAK;IAC3B,IAAI,CAAkB;IACtB,aAAa,GAAG,IAAI,CAAC;IAE9B,YAAY,EACR,aAAa,EACb,OAAO,EACP,IAAI,GAAG,2BAAmB,CAAC,OAAO,MACf,EAAE;QACrB,KAAK,CAAC,OAAO,CAAC,CAAC;QAEf,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QAEjB,IAAI,aAAa,EAAE,CAAC;YAChB,IAAI,CAAC,IAAI,GAAG,aAAa,CAAC,IAAI,CAAC;YAC/B,IAAI,CAAC,KAAK,GAAG,aAAa,CAAC,KAAK,CAAC;QACrC,CAAC;IACL,CAAC;CACJ;AAlBD,sCAkBC;AAEM,MAAM,eAAe,GAAG,CAAC,KAAc,EAA0B,EAAE;IACtE,OAAO,KAAK,YAAY,KAAK,IAAI,eAAe,IAAI,KAAK,CAAC;AAC9D,CAAC,CAAC;AAFW,QAAA,eAAe,mBAE1B","sourcesContent":["export type ChartKitErrorArgs = {\n code?: number | string;\n originalError?: Error;\n message?: string;\n};\n\nexport const CHARTKIT_ERROR_CODE = {\n NO_DATA: 'ERR.CK.NO_DATA',\n INVALID_DATA: 'ERR.CK.INVALID_DATA',\n UNKNOWN: 'ERR.CK.UNKNOWN_ERROR',\n UNKNOWN_PLUGIN: 'ERR.CK.UNKNOWN_PLUGIN',\n TOO_MANY_LINES: 'ERR.CK.TOO_MANY_LINES',\n};\n\nexport class ChartKitError extends Error {\n readonly code: number | string;\n readonly isCustomError = true;\n\n constructor({\n originalError,\n message,\n code = CHARTKIT_ERROR_CODE.UNKNOWN,\n }: ChartKitErrorArgs = {}) {\n super(message);\n\n this.code = code;\n\n if (originalError) {\n this.name = originalError.name;\n this.stack = originalError.stack;\n }\n }\n}\n\nexport const isChartKitError = (error: unknown): error is ChartKitError => {\n return error instanceof Error && 'isCustomError' in error;\n};\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.settings = exports.isChartKitError = exports.ChartKitError = exports.CHARTKIT_ERROR_CODE = void 0;
|
|
4
|
+
var chartkit_error_1 = require("./chartkit-error/chartkit-error.js");
|
|
5
|
+
Object.defineProperty(exports, "CHARTKIT_ERROR_CODE", { enumerable: true, get: function () { return chartkit_error_1.CHARTKIT_ERROR_CODE; } });
|
|
6
|
+
Object.defineProperty(exports, "ChartKitError", { enumerable: true, get: function () { return chartkit_error_1.ChartKitError; } });
|
|
7
|
+
Object.defineProperty(exports, "isChartKitError", { enumerable: true, get: function () { return chartkit_error_1.isChartKitError; } });
|
|
8
|
+
var settings_1 = require("./settings/settings.js");
|
|
9
|
+
Object.defineProperty(exports, "settings", { enumerable: true, get: function () { return settings_1.settings; } });
|
|
10
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../../../src","sources":["libs/index.ts"],"names":[],"mappings":";;;AAAA,qEAAoG;AAA5F,qHAAA,mBAAmB,OAAA;AAAE,+GAAA,aAAa,OAAA;AAAE,iHAAA,eAAe,OAAA;AAE3D,mDAA6C;AAArC,oGAAA,QAAQ,OAAA","sourcesContent":["export {CHARTKIT_ERROR_CODE, ChartKitError, isChartKitError} from './chartkit-error/chartkit-error';\nexport type {ChartKitErrorArgs} from './chartkit-error/chartkit-error';\nexport {settings} from './settings/settings';\n"]}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EventEmitter = void 0;
|
|
4
|
+
class EventEmitter {
|
|
5
|
+
events = {};
|
|
6
|
+
on(type, event) {
|
|
7
|
+
if (this.events[type]) {
|
|
8
|
+
this.events[type].push(event);
|
|
9
|
+
}
|
|
10
|
+
else {
|
|
11
|
+
this.events[type] = [event];
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
off(type, eventId) {
|
|
15
|
+
if (this.events[type]) {
|
|
16
|
+
this.events[type] = this.events[type].filter(({ id }) => id !== eventId);
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
dispatch(type, args) {
|
|
20
|
+
if (this.events[type]) {
|
|
21
|
+
this.events[type].forEach(({ action }) => {
|
|
22
|
+
action(args);
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
exports.EventEmitter = EventEmitter;
|
|
28
|
+
//# sourceMappingURL=eventEmitter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"eventEmitter.js","sourceRoot":"../../../../src","sources":["libs/settings/eventEmitter.ts"],"names":[],"mappings":";;;AAKA,MAAa,YAAY;IACb,MAAM,GAAG,EAAiD,CAAC;IAEnE,EAAE,CAAiC,IAAY,EAAE,KAAqC;QAClF,IAAI,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC;YACpB,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QAClC,CAAC;aAAM,CAAC;YACJ,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;QAChC,CAAC;IACL,CAAC;IAED,GAAG,CAAiC,IAAY,EAAE,OAAe;QAC7D,IAAI,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC;YACpB,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,CAAC,EAAC,EAAE,EAAC,EAAE,EAAE,CAAC,EAAE,KAAK,OAAO,CAAC,CAAC;QAC3E,CAAC;IACL,CAAC;IAED,QAAQ,CAAiC,IAAY,EAAE,IAAuB;QAC1E,IAAI,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC;YACpB,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,EAAC,MAAM,EAAC,EAAE,EAAE;gBACnC,MAAM,CAAC,IAAI,CAAC,CAAC;YACjB,CAAC,CAAC,CAAC;QACP,CAAC;IACL,CAAC;CACJ;AAxBD,oCAwBC","sourcesContent":["type EventObject<T = unknown> = {\n id: string;\n action: (args: T) => void;\n};\n\nexport class EventEmitter<EventsMap = unknown> {\n private events = {} as Record<keyof EventsMap, EventObject<any>[]>;\n\n on<MapKey extends keyof EventsMap>(type: MapKey, event: EventObject<EventsMap[MapKey]>) {\n if (this.events[type]) {\n this.events[type].push(event);\n } else {\n this.events[type] = [event];\n }\n }\n\n off<MapKey extends keyof EventsMap>(type: MapKey, eventId: string) {\n if (this.events[type]) {\n this.events[type] = this.events[type].filter(({id}) => id !== eventId);\n }\n }\n\n dispatch<MapKey extends keyof EventsMap>(type: MapKey, args: EventsMap[MapKey]) {\n if (this.events[type]) {\n this.events[type].forEach(({action}) => {\n action(args);\n });\n }\n }\n}\n"]}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.mergeSettingStrategy = mergeSettingStrategy;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const isObject_1 = tslib_1.__importDefault(require("es-toolkit/compat/isObject"));
|
|
6
|
+
const merge_1 = require("../../utils/merge.js");
|
|
7
|
+
function mergeSettingStrategy(objValue, srcValue, key) {
|
|
8
|
+
if (key === 'plugins') {
|
|
9
|
+
const currentPlugins = [...objValue];
|
|
10
|
+
const newPlugins = [...srcValue];
|
|
11
|
+
// modify existing plugins
|
|
12
|
+
let newSettingsPlugins = currentPlugins.map((currentPlugin) => {
|
|
13
|
+
const newPluginIndex = newPlugins.findIndex(({ type }) => type === currentPlugin.type);
|
|
14
|
+
if (newPluginIndex !== -1) {
|
|
15
|
+
const newPlugin = newPlugins[newPluginIndex];
|
|
16
|
+
newPlugins.splice(newPluginIndex, 1);
|
|
17
|
+
return {
|
|
18
|
+
type: currentPlugin.type,
|
|
19
|
+
renderer: newPlugin.renderer,
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
return currentPlugin;
|
|
23
|
+
});
|
|
24
|
+
// add new plugins if it exist after modified
|
|
25
|
+
if (newPlugins.length > 0) {
|
|
26
|
+
newSettingsPlugins = [...newSettingsPlugins, ...newPlugins];
|
|
27
|
+
}
|
|
28
|
+
return newSettingsPlugins;
|
|
29
|
+
}
|
|
30
|
+
if ((0, isObject_1.default)(objValue)) {
|
|
31
|
+
return (0, merge_1.mergeWith)(objValue, srcValue, mergeSettingStrategy);
|
|
32
|
+
}
|
|
33
|
+
return srcValue;
|
|
34
|
+
}
|
|
35
|
+
//# sourceMappingURL=mergeSettingStrategy.js.map
|