@gravity-ui/chartkit 8.12.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.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 -40
- 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 -60
- package/build/components/SplitPane/SplitPane.js +0 -243
- 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 -63
- package/build/components/SplitTooltip/SplitTooltip.js +0 -129
- 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 -70
- 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.js +0 -61
- 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 -75
- 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}/gravity-charts/renderer/withSplitPane/withSplitPane.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,259 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright 2015 tomkp
|
|
3
|
+
// Copyright 2022 YANDEX LLC
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.SplitPane = void 0;
|
|
6
|
+
const tslib_1 = require("tslib");
|
|
7
|
+
/* eslint-disable radix */
|
|
8
|
+
/* eslint-disable complexity */
|
|
9
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
10
|
+
const Pane_1 = require("./Pane.js");
|
|
11
|
+
const Resizer_1 = require("./Resizer.js");
|
|
12
|
+
function unFocus() {
|
|
13
|
+
window.getSelection()?.removeAllRanges();
|
|
14
|
+
}
|
|
15
|
+
function getDefaultSize(defaultSize, minSize, maxSize, draggedSize) {
|
|
16
|
+
if (typeof draggedSize === 'number') {
|
|
17
|
+
const min = typeof minSize === 'number' ? minSize : 0;
|
|
18
|
+
const max = typeof maxSize === 'number' && maxSize >= 0 ? maxSize : Infinity;
|
|
19
|
+
return Math.max(min, Math.min(max, draggedSize));
|
|
20
|
+
}
|
|
21
|
+
if (defaultSize !== undefined) {
|
|
22
|
+
return defaultSize;
|
|
23
|
+
}
|
|
24
|
+
return minSize;
|
|
25
|
+
}
|
|
26
|
+
function removeNullChildren(children) {
|
|
27
|
+
return react_1.default.Children.toArray(children).filter((c) => c);
|
|
28
|
+
}
|
|
29
|
+
// TODO: https://github.com/gravity-ui/charts/issues/14
|
|
30
|
+
class SplitPane extends react_1.default.Component {
|
|
31
|
+
static defaultProps = {
|
|
32
|
+
allowResize: true,
|
|
33
|
+
minSize: 50,
|
|
34
|
+
primary: 'first',
|
|
35
|
+
split: 'vertical',
|
|
36
|
+
paneClassName: '',
|
|
37
|
+
pane1ClassName: '',
|
|
38
|
+
pane2ClassName: '',
|
|
39
|
+
};
|
|
40
|
+
static getDerivedStateFromProps(nextProps, prevState) {
|
|
41
|
+
return SplitPane.getSizeUpdate(nextProps, prevState);
|
|
42
|
+
}
|
|
43
|
+
// we have to check values since gDSFP is called on every render and more in StrictMode
|
|
44
|
+
static getSizeUpdate(props, state) {
|
|
45
|
+
const newState = {};
|
|
46
|
+
const { instanceProps } = state;
|
|
47
|
+
if (instanceProps.size === props.size && props.size !== undefined) {
|
|
48
|
+
return {};
|
|
49
|
+
}
|
|
50
|
+
const newSize = props.size === undefined
|
|
51
|
+
? getDefaultSize(props.defaultSize, props.minSize, props.maxSize, state.draggedSize)
|
|
52
|
+
: props.size;
|
|
53
|
+
if (props.size !== undefined) {
|
|
54
|
+
newState.draggedSize = newSize;
|
|
55
|
+
}
|
|
56
|
+
const isPanel1Primary = props.primary === 'first';
|
|
57
|
+
newState[isPanel1Primary ? 'pane1Size' : 'pane2Size'] = newSize;
|
|
58
|
+
newState[isPanel1Primary ? 'pane2Size' : 'pane1Size'] = undefined;
|
|
59
|
+
newState.instanceProps = { size: props.size };
|
|
60
|
+
return newState;
|
|
61
|
+
}
|
|
62
|
+
splitPane = null;
|
|
63
|
+
pane1 = null;
|
|
64
|
+
pane2 = null;
|
|
65
|
+
constructor(props) {
|
|
66
|
+
super(props);
|
|
67
|
+
// order of setting panel sizes.
|
|
68
|
+
// 1. size
|
|
69
|
+
// 2. getDefaultSize(defaultSize, minsize, maxSize)
|
|
70
|
+
const { size, defaultSize, minSize, maxSize, primary } = props;
|
|
71
|
+
const initialSize = size === undefined ? getDefaultSize(defaultSize, minSize, maxSize) : size;
|
|
72
|
+
this.state = {
|
|
73
|
+
active: false,
|
|
74
|
+
resized: false,
|
|
75
|
+
position: 0,
|
|
76
|
+
draggedSize: 0,
|
|
77
|
+
pane1Size: primary === 'first' ? initialSize : undefined,
|
|
78
|
+
pane2Size: primary === 'second' ? initialSize : undefined,
|
|
79
|
+
// these are props that are needed in static functions. ie: gDSFP
|
|
80
|
+
instanceProps: {
|
|
81
|
+
size,
|
|
82
|
+
},
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
componentDidMount() {
|
|
86
|
+
document.addEventListener('mouseup', this.onMouseUp);
|
|
87
|
+
document.addEventListener('mousemove', this.onMouseMove);
|
|
88
|
+
document.addEventListener('touchmove', this.onTouchMove);
|
|
89
|
+
this.setState(SplitPane.getSizeUpdate(this.props, this.state));
|
|
90
|
+
}
|
|
91
|
+
componentDidUpdate(previousProps, previousState) {
|
|
92
|
+
if (this.state.active &&
|
|
93
|
+
(!this.props.allowResize || previousProps.split !== this.props.split)) {
|
|
94
|
+
this.props.onDragFinished?.(previousState.draggedSize);
|
|
95
|
+
this.setState({ active: false });
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
componentWillUnmount() {
|
|
99
|
+
document.removeEventListener('mouseup', this.onMouseUp);
|
|
100
|
+
document.removeEventListener('mousemove', this.onMouseMove);
|
|
101
|
+
document.removeEventListener('touchmove', this.onTouchMove);
|
|
102
|
+
}
|
|
103
|
+
render() {
|
|
104
|
+
const { allowResize, children, className, onResizerClick, onResizerDoubleClick, paneClassName, pane1ClassName, pane2ClassName, paneStyle, pane1Style: pane1StyleProps, pane2Style: pane2StyleProps, resizerClassName, resizerStyle, split, style: styleProps, } = this.props;
|
|
105
|
+
const { pane1Size, pane2Size } = this.state;
|
|
106
|
+
const disabledClass = allowResize ? '' : 'disabled';
|
|
107
|
+
const resizerClassNamesIncludingDefault = resizerClassName
|
|
108
|
+
? `${resizerClassName} ${Resizer_1.RESIZER_DEFAULT_CLASSNAME}`
|
|
109
|
+
: resizerClassName;
|
|
110
|
+
const notNullChildren = removeNullChildren(children);
|
|
111
|
+
const style = {
|
|
112
|
+
display: 'flex',
|
|
113
|
+
flex: 1,
|
|
114
|
+
height: '100%',
|
|
115
|
+
position: 'absolute',
|
|
116
|
+
outline: 'none',
|
|
117
|
+
overflow: 'hidden',
|
|
118
|
+
MozUserSelect: 'text',
|
|
119
|
+
WebkitUserSelect: 'text',
|
|
120
|
+
msUserSelect: 'text',
|
|
121
|
+
userSelect: 'text',
|
|
122
|
+
...styleProps,
|
|
123
|
+
};
|
|
124
|
+
if (split === 'vertical') {
|
|
125
|
+
Object.assign(style, {
|
|
126
|
+
flexDirection: 'row',
|
|
127
|
+
left: 0,
|
|
128
|
+
right: 0,
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
else {
|
|
132
|
+
Object.assign(style, {
|
|
133
|
+
bottom: 0,
|
|
134
|
+
flexDirection: 'column',
|
|
135
|
+
minHeight: '100%',
|
|
136
|
+
top: 0,
|
|
137
|
+
width: '100%',
|
|
138
|
+
});
|
|
139
|
+
}
|
|
140
|
+
const classes = ['SplitPane', className, split, disabledClass];
|
|
141
|
+
const pane1Style = { ...paneStyle, ...pane1StyleProps };
|
|
142
|
+
const pane2Style = { ...paneStyle, ...pane2StyleProps };
|
|
143
|
+
const pane1Classes = ['Pane1', paneClassName, pane1ClassName].join(' ');
|
|
144
|
+
const pane2Classes = ['Pane2', paneClassName, pane2ClassName].join(' ');
|
|
145
|
+
return (react_1.default.createElement("div", { className: classes.join(' '), ref: (node) => {
|
|
146
|
+
this.splitPane = node;
|
|
147
|
+
}, style: style },
|
|
148
|
+
react_1.default.createElement(Pane_1.Pane, { className: pane1Classes, key: "pane1", eleRef: (node) => {
|
|
149
|
+
this.pane1 = node;
|
|
150
|
+
}, size: pane1Size, split: split, style: pane1Style }, notNullChildren[0]),
|
|
151
|
+
react_1.default.createElement(Resizer_1.Resizer, { className: disabledClass, onClick: onResizerClick, onDoubleClick: onResizerDoubleClick, onMouseDown: this.onMouseDown, onTouchStart: this.onTouchStart, onTouchEnd: this.onMouseUp, key: "resizer", resizerClassName: resizerClassNamesIncludingDefault, split: split, style: resizerStyle || {} }),
|
|
152
|
+
react_1.default.createElement(Pane_1.Pane, { className: pane2Classes, key: "pane2", eleRef: (node) => {
|
|
153
|
+
this.pane2 = node;
|
|
154
|
+
}, size: pane2Size, split: split, style: pane2Style }, notNullChildren[1])));
|
|
155
|
+
}
|
|
156
|
+
onMouseDown = (event) => {
|
|
157
|
+
const eventWithTouches = Object.assign({}, event, {
|
|
158
|
+
touches: [{ clientX: event.clientX, clientY: event.clientY }],
|
|
159
|
+
});
|
|
160
|
+
this.onTouchStart(eventWithTouches);
|
|
161
|
+
};
|
|
162
|
+
onTouchStart = (event) => {
|
|
163
|
+
const { allowResize, onDragStarted, split } = this.props;
|
|
164
|
+
if (allowResize) {
|
|
165
|
+
unFocus();
|
|
166
|
+
const position = split === 'vertical' ? event.touches[0].clientX : event.touches[0].clientY;
|
|
167
|
+
if (typeof onDragStarted === 'function') {
|
|
168
|
+
onDragStarted();
|
|
169
|
+
}
|
|
170
|
+
this.setState({
|
|
171
|
+
active: true,
|
|
172
|
+
position,
|
|
173
|
+
});
|
|
174
|
+
}
|
|
175
|
+
};
|
|
176
|
+
onMouseMove = (event) => {
|
|
177
|
+
const eventWithTouches = Object.assign({}, event, {
|
|
178
|
+
touches: [{ clientX: event.clientX, clientY: event.clientY }],
|
|
179
|
+
});
|
|
180
|
+
this.onTouchMove(eventWithTouches);
|
|
181
|
+
};
|
|
182
|
+
onTouchMove = (event) => {
|
|
183
|
+
const { allowResize, maxSize, minSize, onChange, split, step } = this.props;
|
|
184
|
+
const { active, position } = this.state;
|
|
185
|
+
if (allowResize && active) {
|
|
186
|
+
unFocus();
|
|
187
|
+
const isPrimaryFirst = this.props.primary === 'first';
|
|
188
|
+
const ref = isPrimaryFirst ? this.pane1 : this.pane2;
|
|
189
|
+
const ref2 = isPrimaryFirst ? this.pane2 : this.pane1;
|
|
190
|
+
if (ref) {
|
|
191
|
+
const node = ref;
|
|
192
|
+
const node2 = ref2;
|
|
193
|
+
if (node.getBoundingClientRect) {
|
|
194
|
+
const width = node.getBoundingClientRect().width;
|
|
195
|
+
const height = node.getBoundingClientRect().height;
|
|
196
|
+
const current = split === 'vertical' ? event.touches[0].clientX : event.touches[0].clientY;
|
|
197
|
+
const size = split === 'vertical' ? width : height;
|
|
198
|
+
let positionDelta = position - current;
|
|
199
|
+
if (step) {
|
|
200
|
+
if (Math.abs(positionDelta) < step) {
|
|
201
|
+
return;
|
|
202
|
+
}
|
|
203
|
+
// Integer division
|
|
204
|
+
// eslint-disable-next-line no-bitwise
|
|
205
|
+
positionDelta = ~~(positionDelta / step) * step;
|
|
206
|
+
}
|
|
207
|
+
let sizeDelta = isPrimaryFirst ? positionDelta : -positionDelta;
|
|
208
|
+
const pane1Order = parseInt(window.getComputedStyle(node).order);
|
|
209
|
+
const pane2Order = parseInt(window.getComputedStyle(node2).order);
|
|
210
|
+
if (pane1Order > pane2Order) {
|
|
211
|
+
sizeDelta = -sizeDelta;
|
|
212
|
+
}
|
|
213
|
+
let newMaxSize = maxSize;
|
|
214
|
+
if (maxSize !== undefined && maxSize <= 0) {
|
|
215
|
+
const splitPane = this.splitPane;
|
|
216
|
+
if (split === 'vertical') {
|
|
217
|
+
newMaxSize = splitPane.getBoundingClientRect().width + maxSize;
|
|
218
|
+
}
|
|
219
|
+
else {
|
|
220
|
+
newMaxSize = splitPane.getBoundingClientRect().height + maxSize;
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
let newSize = size - sizeDelta;
|
|
224
|
+
const newPosition = position - positionDelta;
|
|
225
|
+
if (newSize < minSize) {
|
|
226
|
+
newSize = minSize;
|
|
227
|
+
}
|
|
228
|
+
else if (maxSize !== undefined && newSize > newMaxSize) {
|
|
229
|
+
newSize = newMaxSize;
|
|
230
|
+
}
|
|
231
|
+
else {
|
|
232
|
+
this.setState({
|
|
233
|
+
position: newPosition,
|
|
234
|
+
resized: true,
|
|
235
|
+
});
|
|
236
|
+
}
|
|
237
|
+
if (onChange)
|
|
238
|
+
onChange(newSize);
|
|
239
|
+
this.setState({
|
|
240
|
+
draggedSize: newSize,
|
|
241
|
+
[isPrimaryFirst ? 'pane1Size' : 'pane2Size']: newSize,
|
|
242
|
+
});
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
};
|
|
247
|
+
onMouseUp = () => {
|
|
248
|
+
const { allowResize, onDragFinished } = this.props;
|
|
249
|
+
const { active, draggedSize } = this.state;
|
|
250
|
+
if (allowResize && active) {
|
|
251
|
+
if (typeof onDragFinished === 'function') {
|
|
252
|
+
onDragFinished(draggedSize);
|
|
253
|
+
}
|
|
254
|
+
this.setState({ active: false });
|
|
255
|
+
}
|
|
256
|
+
};
|
|
257
|
+
}
|
|
258
|
+
exports.SplitPane = SplitPane;
|
|
259
|
+
//# sourceMappingURL=SplitPane.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SplitPane.js","sourceRoot":"../../../../src","sources":["components/SplitPane/SplitPane.tsx"],"names":[],"mappings":";AAAA,uBAAuB;AACvB,4BAA4B;;;;AAE5B,0BAA0B;AAC1B,+BAA+B;AAE/B,0DAA0B;AAE1B,oCAA4B;AAC5B,0CAA6D;AAmE7D,SAAS,OAAO;IACZ,MA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C,MAAM,EAAE,WAAW,EAAC,GAAG,IAAI,CAAC,KAAK,CAAC;QACzC,IAAI,WAAW,IAAI,MAAM,EAAE,CAAC;YACxB,IAAI,OAAO,cAAc,KAAK,UAAU,EAAE,CAAC;gBACvC,cAAc,CAAC,WAAW,CAAC,CAAC;YAChC,CAAC;YACD,IAAI,CAAC,QAAQ,CAAC,EAAC,MAAM,EAAE,KAAK,EAAC,CAAC,CAAC;QACnC,CAAC;IACL,CAAC,CAAC;;AAlUN,8BAmUC","sourcesContent":["// Copyright 2015 tomkp\n// Copyright 2022 YANDEX LLC\n\n/* eslint-disable radix */\n/* eslint-disable complexity */\n\nimport React from 'react';\n\nimport {Pane} from './Pane';\nimport {RESIZER_DEFAULT_CLASSNAME, Resizer} from './Resizer';\nimport type {SplitLayoutType} from './types';\n\nexport type SplitPaneProps = {\n allowResize?: boolean;\n children?: React.ReactNode;\n className?: string;\n primary?: 'first' | 'second';\n minSize?: number;\n maxSize?: number;\n defaultSize?: number;\n size?: number | string;\n split?: SplitLayoutType;\n onDragStarted?: () => void;\n onDragFinished?: (size?: number | string) => void;\n onChange?: (size: number) => void;\n onResizerClick?: React.MouseEventHandler;\n onResizerDoubleClick?: React.MouseEventHandler;\n style?: React.CSSProperties;\n resizerStyle?: React.CSSProperties;\n paneClassName?: string;\n pane1ClassName?: string;\n pane2ClassName?: string;\n paneStyle?: React.CSSProperties;\n pane1Style?: React.CSSProperties;\n pane2Style?: React.CSSProperties;\n resizerClassName?: string;\n step?: number;\n};\n\ntype DefaultProps = Required<\n Pick<\n SplitPaneProps,\n | 'allowResize'\n | 'minSize'\n | 'primary'\n | 'split'\n | 'paneClassName'\n | 'pane1ClassName'\n | 'pane2ClassName'\n >\n>;\n\ntype Props = Omit<\n SplitPaneProps,\n | 'allowResize'\n | 'minSize'\n | 'primary'\n | 'split'\n | 'paneClassName'\n | 'pane1ClassName'\n | 'pane2ClassName'\n> &\n DefaultProps;\n\ntype State = {\n active: boolean;\n position: number;\n resized: boolean;\n draggedSize?: number | string;\n pane1Size?: number | string;\n pane2Size?: number | string;\n instanceProps: {\n size?: number | string;\n };\n};\n\nfunction unFocus() {\n window.getSelection()?.removeAllRanges();\n}\n\nfunction getDefaultSize(\n defaultSize?: number,\n minSize?: number,\n maxSize?: number,\n draggedSize?: number | string,\n) {\n if (typeof draggedSize === 'number') {\n const min = typeof minSize === 'number' ? minSize : 0;\n const max = typeof maxSize === 'number' && maxSize >= 0 ? maxSize : Infinity;\n return Math.max(min, Math.min(max, draggedSize));\n }\n if (defaultSize !== undefined) {\n return defaultSize;\n }\n return minSize;\n}\n\nfunction removeNullChildren(children: React.ReactNode) {\n return React.Children.toArray(children).filter((c) => c);\n}\n\n// TODO: https://github.com/gravity-ui/charts/issues/14\nexport class SplitPane extends React.Component<Props, State> {\n static defaultProps: DefaultProps = {\n allowResize: true,\n minSize: 50,\n primary: 'first',\n split: 'vertical',\n paneClassName: '',\n pane1ClassName: '',\n pane2ClassName: '',\n };\n\n static getDerivedStateFromProps(nextProps: Props, prevState: State) {\n return SplitPane.getSizeUpdate(nextProps, prevState);\n }\n\n // we have to check values since gDSFP is called on every render and more in StrictMode\n static getSizeUpdate(props: Props, state: State) {\n const newState = {} as State;\n const {instanceProps} = state;\n\n if (instanceProps.size === props.size && props.size !== undefined) {\n return {};\n }\n\n const newSize =\n props.size === undefined\n ? getDefaultSize(props.defaultSize, props.minSize, props.maxSize, state.draggedSize)\n : props.size;\n\n if (props.size !== undefined) {\n newState.draggedSize = newSize;\n }\n\n const isPanel1Primary = props.primary === 'first';\n\n newState[isPanel1Primary ? 'pane1Size' : 'pane2Size'] = newSize;\n newState[isPanel1Primary ? 'pane2Size' : 'pane1Size'] = undefined;\n\n newState.instanceProps = {size: props.size};\n\n return newState;\n }\n\n splitPane: HTMLDivElement | null = null;\n private pane1: HTMLDivElement | null = null;\n private pane2: HTMLDivElement | null = null;\n\n constructor(props: Props) {\n super(props);\n\n // order of setting panel sizes.\n // 1. size\n // 2. getDefaultSize(defaultSize, minsize, maxSize)\n\n const {size, defaultSize, minSize, maxSize, primary} = props;\n\n const initialSize =\n size === undefined ? getDefaultSize(defaultSize, minSize, maxSize) : size;\n\n this.state = {\n active: false,\n resized: false,\n position: 0,\n draggedSize: 0,\n pane1Size: primary === 'first' ? initialSize : undefined,\n pane2Size: primary === 'second' ? initialSize : undefined,\n\n // these are props that are needed in static functions. ie: gDSFP\n instanceProps: {\n size,\n },\n };\n }\n\n componentDidMount() {\n document.addEventListener('mouseup', this.onMouseUp);\n document.addEventListener('mousemove', this.onMouseMove);\n document.addEventListener('touchmove', this.onTouchMove);\n this.setState(SplitPane.getSizeUpdate(this.props, this.state));\n }\n\n componentDidUpdate(previousProps: Props, previousState: State) {\n if (\n this.state.active &&\n (!this.props.allowResize || previousProps.split !== this.props.split)\n ) {\n this.props.onDragFinished?.(previousState.draggedSize);\n this.setState({active: false});\n }\n }\n\n componentWillUnmount() {\n document.removeEventListener('mouseup', this.onMouseUp);\n document.removeEventListener('mousemove', this.onMouseMove);\n document.removeEventListener('touchmove', this.onTouchMove);\n }\n\n render() {\n const {\n allowResize,\n children,\n className,\n onResizerClick,\n onResizerDoubleClick,\n paneClassName,\n pane1ClassName,\n pane2ClassName,\n paneStyle,\n pane1Style: pane1StyleProps,\n pane2Style: pane2StyleProps,\n resizerClassName,\n resizerStyle,\n split,\n style: styleProps,\n } = this.props;\n\n const {pane1Size, pane2Size} = this.state;\n\n const disabledClass = allowResize ? '' : 'disabled';\n const resizerClassNamesIncludingDefault = resizerClassName\n ? `${resizerClassName} ${RESIZER_DEFAULT_CLASSNAME}`\n : resizerClassName;\n\n const notNullChildren = removeNullChildren(children);\n\n const style: React.CSSProperties = {\n display: 'flex',\n flex: 1,\n height: '100%',\n position: 'absolute',\n outline: 'none',\n overflow: 'hidden',\n MozUserSelect: 'text',\n WebkitUserSelect: 'text',\n msUserSelect: 'text',\n userSelect: 'text',\n ...styleProps,\n };\n\n if (split === 'vertical') {\n Object.assign(style, {\n flexDirection: 'row',\n left: 0,\n right: 0,\n });\n } else {\n Object.assign(style, {\n bottom: 0,\n flexDirection: 'column',\n minHeight: '100%',\n top: 0,\n width: '100%',\n });\n }\n\n const classes = ['SplitPane', className, split, disabledClass];\n\n const pane1Style = {...paneStyle, ...pane1StyleProps};\n const pane2Style = {...paneStyle, ...pane2StyleProps};\n\n const pane1Classes = ['Pane1', paneClassName, pane1ClassName].join(' ');\n const pane2Classes = ['Pane2', paneClassName, pane2ClassName].join(' ');\n\n return (\n <div\n className={classes.join(' ')}\n ref={(node) => {\n this.splitPane = node;\n }}\n style={style}\n >\n <Pane\n className={pane1Classes}\n key=\"pane1\"\n eleRef={(node) => {\n this.pane1 = node;\n }}\n size={pane1Size}\n split={split}\n style={pane1Style}\n >\n {notNullChildren[0]}\n </Pane>\n <Resizer\n className={disabledClass}\n onClick={onResizerClick}\n onDoubleClick={onResizerDoubleClick}\n onMouseDown={this.onMouseDown}\n onTouchStart={this.onTouchStart}\n onTouchEnd={this.onMouseUp}\n key=\"resizer\"\n resizerClassName={resizerClassNamesIncludingDefault}\n split={split}\n style={resizerStyle || {}}\n />\n <Pane\n className={pane2Classes}\n key=\"pane2\"\n eleRef={(node) => {\n this.pane2 = node;\n }}\n size={pane2Size}\n split={split}\n style={pane2Style}\n >\n {notNullChildren[1]}\n </Pane>\n </div>\n );\n }\n\n private onMouseDown = (event: React.MouseEvent) => {\n const eventWithTouches = Object.assign({} as React.TouchEvent, event, {\n touches: [{clientX: event.clientX, clientY: event.clientY}],\n });\n this.onTouchStart(eventWithTouches);\n };\n\n private onTouchStart = (event: React.TouchEvent | TouchEvent) => {\n const {allowResize, onDragStarted, split} = this.props;\n if (allowResize) {\n unFocus();\n const position =\n split === 'vertical' ? event.touches[0].clientX : event.touches[0].clientY;\n\n if (typeof onDragStarted === 'function') {\n onDragStarted();\n }\n this.setState({\n active: true,\n position,\n });\n }\n };\n\n private onMouseMove = (event: React.MouseEvent | MouseEvent) => {\n const eventWithTouches = Object.assign({} as React.TouchEvent, event, {\n touches: [{clientX: event.clientX, clientY: event.clientY}],\n });\n this.onTouchMove(eventWithTouches);\n };\n\n private onTouchMove = (event: React.TouchEvent | TouchEvent) => {\n const {allowResize, maxSize, minSize, onChange, split, step} = this.props;\n const {active, position} = this.state;\n\n if (allowResize && active) {\n unFocus();\n const isPrimaryFirst = this.props.primary === 'first';\n const ref = isPrimaryFirst ? this.pane1 : this.pane2;\n const ref2 = isPrimaryFirst ? this.pane2 : this.pane1;\n if (ref) {\n const node = ref;\n const node2 = ref2;\n\n if (node.getBoundingClientRect) {\n const width = node.getBoundingClientRect().width;\n const height = node.getBoundingClientRect().height;\n const current =\n split === 'vertical' ? event.touches[0].clientX : event.touches[0].clientY;\n const size = split === 'vertical' ? width : height;\n let positionDelta = position - current;\n if (step) {\n if (Math.abs(positionDelta) < step) {\n return;\n }\n // Integer division\n // eslint-disable-next-line no-bitwise\n positionDelta = ~~(positionDelta / step) * step;\n }\n let sizeDelta = isPrimaryFirst ? positionDelta : -positionDelta;\n\n const pane1Order = parseInt(window.getComputedStyle(node).order);\n const pane2Order = parseInt(window.getComputedStyle(node2!).order);\n if (pane1Order > pane2Order) {\n sizeDelta = -sizeDelta;\n }\n\n let newMaxSize = maxSize;\n if (maxSize !== undefined && maxSize <= 0) {\n const splitPane = this.splitPane;\n if (split === 'vertical') {\n newMaxSize = splitPane!.getBoundingClientRect().width + maxSize;\n } else {\n newMaxSize = splitPane!.getBoundingClientRect().height + maxSize;\n }\n }\n\n let newSize = size - sizeDelta;\n const newPosition = position - positionDelta;\n\n if (newSize < minSize) {\n newSize = minSize;\n } else if (maxSize !== undefined && newSize > newMaxSize!) {\n newSize = newMaxSize!;\n } else {\n this.setState({\n position: newPosition,\n resized: true,\n });\n }\n\n if (onChange) onChange(newSize);\n\n this.setState({\n draggedSize: newSize,\n [isPrimaryFirst ? 'pane1Size' : 'pane2Size']: newSize,\n } as unknown as State);\n }\n }\n }\n };\n\n private onMouseUp = () => {\n const {allowResize, onDragFinished} = this.props;\n const {active, draggedSize} = this.state;\n if (allowResize && active) {\n if (typeof onDragFinished === 'function') {\n onDragFinished(draggedSize);\n }\n this.setState({active: false});\n }\n };\n}\n"]}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
.styled-split-pane__pane-resizer {
|
|
2
|
+
background: linear-gradient(to right, var(--g-color-base-generic), var(--g-color-base-generic)), linear-gradient(to right, var(--g-color-base-background), var(--g-color-base-background));
|
|
3
|
+
z-index: 1;
|
|
4
|
+
box-sizing: border-box;
|
|
5
|
+
position: relative;
|
|
6
|
+
}
|
|
7
|
+
.styled-split-pane__pane-resizer_hovered {
|
|
8
|
+
opacity: 0.5;
|
|
9
|
+
}
|
|
10
|
+
.styled-split-pane__pane-resizer.horizontal {
|
|
11
|
+
height: 24px;
|
|
12
|
+
min-height: 24px;
|
|
13
|
+
width: 100%;
|
|
14
|
+
}
|
|
15
|
+
.styled-split-pane__pane-resizer.horizontal:before {
|
|
16
|
+
content: "";
|
|
17
|
+
width: 28px;
|
|
18
|
+
margin-left: -14px;
|
|
19
|
+
height: 1px;
|
|
20
|
+
background-color: var(--highcarts-navigator-body);
|
|
21
|
+
left: 50%;
|
|
22
|
+
top: 10px;
|
|
23
|
+
position: absolute;
|
|
24
|
+
}
|
|
25
|
+
.styled-split-pane__pane-resizer.horizontal:after {
|
|
26
|
+
content: "";
|
|
27
|
+
width: 28px;
|
|
28
|
+
margin-left: -14px;
|
|
29
|
+
height: 1px;
|
|
30
|
+
background-color: var(--highcarts-navigator-body);
|
|
31
|
+
left: 50%;
|
|
32
|
+
top: 13px;
|
|
33
|
+
position: absolute;
|
|
34
|
+
}
|
|
35
|
+
.styled-split-pane__pane-resizer.vertical {
|
|
36
|
+
height: 100%;
|
|
37
|
+
width: 1px;
|
|
38
|
+
min-width: 1px;
|
|
39
|
+
}
|
|
40
|
+
.styled-split-pane .Pane {
|
|
41
|
+
height: 100%;
|
|
42
|
+
}
|
|
43
|
+
.styled-split-pane .Pane2 {
|
|
44
|
+
background: linear-gradient(to right, var(--g-color-infographics-tooltip-bg), var(--g-color-infographics-tooltip-bg)), linear-gradient(to right, var(--g-color-base-background), var(--g-color-base-background));
|
|
45
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { SplitPaneProps } from "./SplitPane.js";
|
|
3
|
+
import "./StyledSplitPane.css";
|
|
4
|
+
type Props = SplitPaneProps & {
|
|
5
|
+
paneOneRender: () => React.ReactNode;
|
|
6
|
+
paneTwoRender: () => React.ReactNode;
|
|
7
|
+
};
|
|
8
|
+
export declare const StyledSplitPane: ({ paneOneRender, paneTwoRender, ...splitPaneProps }: Props) => React.JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.StyledSplitPane = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const react_1 = tslib_1.__importDefault(require("react"));
|
|
6
|
+
const cn_1 = require("../../utils/cn.js");
|
|
7
|
+
const Pane_1 = require("./Pane.js");
|
|
8
|
+
const SplitPane_1 = require("./SplitPane.js");
|
|
9
|
+
require("./StyledSplitPane.css");
|
|
10
|
+
const b = (0, cn_1.cn)('styled-split-pane');
|
|
11
|
+
const resizerClassName = b('pane-resizer');
|
|
12
|
+
const StyledSplitPane = ({ paneOneRender, paneTwoRender, ...splitPaneProps }) => {
|
|
13
|
+
const splitPaneRef = react_1.default.useRef(null);
|
|
14
|
+
react_1.default.useEffect(() => {
|
|
15
|
+
const resizer = splitPaneRef.current?.splitPane?.getElementsByClassName(resizerClassName)[0];
|
|
16
|
+
const hoveredClassName = `${resizerClassName}_hovered`;
|
|
17
|
+
const onTouchStart = () => {
|
|
18
|
+
resizer?.classList.add(hoveredClassName);
|
|
19
|
+
};
|
|
20
|
+
const onTouchEnd = () => {
|
|
21
|
+
resizer?.classList.remove(hoveredClassName);
|
|
22
|
+
};
|
|
23
|
+
resizer?.addEventListener('touchstart', onTouchStart);
|
|
24
|
+
resizer?.addEventListener('touchend', onTouchEnd);
|
|
25
|
+
return function cleanup() {
|
|
26
|
+
resizer?.removeEventListener('touchstart', onTouchStart);
|
|
27
|
+
resizer?.removeEventListener('touchend', onTouchEnd);
|
|
28
|
+
};
|
|
29
|
+
}, []);
|
|
30
|
+
return (react_1.default.createElement(SplitPane_1.SplitPane, { ...splitPaneProps, ref: splitPaneRef, className: b(), resizerClassName: resizerClassName },
|
|
31
|
+
react_1.default.createElement(Pane_1.Pane, null, paneOneRender()),
|
|
32
|
+
react_1.default.createElement(Pane_1.Pane, null, paneTwoRender())));
|
|
33
|
+
};
|
|
34
|
+
exports.StyledSplitPane = StyledSplitPane;
|
|
35
|
+
//# sourceMappingURL=StyledSplitPane.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StyledSplitPane.js","sourceRoot":"../../../../src","sources":["components/SplitPane/StyledSplitPane.tsx"],"names":[],"mappings":";;;;AAAA,0DAA0B;AAE1B,0CAAkC;AAElC,oCAA4B;AAC5B,8CAAsC;AAGtC,iCAAgC;AAEhC,MAAM,CAAC,GAAG,IAAA,OAAE,EAAC,mBAAmB,CAAC,CAAC;AAClC,MAAM,gBAAgB,GAAG,CAAC,CAAC,cAAc,CAAC,CAAC;AAOpC,MAAM,eAAe,GAAG,CAAC,EAAC,aAAa,EAAE,aAAa,EAAE,GAAG,cAAc,EAAQ,EAAE,EAAE;IACxF,MAAM,YAAY,GAAG,eAAK,CAAC,MAAM,CAAkD,IAAI,CAAC,CAAC;IAEzF,eAAK,CAAC,SAAS,CAAC,GAAG,EAAE;QACjB,MAAM,OAAO,GACT,YAAY,CAAC,OAAO,EAAE,SAAS,EAAE,sBAAsB,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC,CAAC;QACjF,MAAM,gBAAgB,GAAG,GAAG,gBAAgB,UAAU,CAAC;QAEvD,MAAM,YAAY,GAAG,GAAG,EAAE;YACtB,OAAO,EAAE,SAAS,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;QAC7C,CAAC,CAAC;QAEF,MAAM,UAAU,GAAG,GAAG,EAAE;YACpB,OAAO,EAAE,SAAS,CAAC,MAAM,CAAC,gBAAgB,CAAC,CAAC;QAChD,CAAC,CAAC;QAEF,OAAO,EAAE,gBAAgB,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;QACtD,OAAO,EAAE,gBAAgB,CAAC,UAAU,EAAE,UAAU,CAAC,CAAC;QAElD,OAAO,SAAS,OAAO;YACnB,OAAO,EAAE,mBAAmB,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;YACzD,OAAO,EAAE,mBAAmB,CAAC,UAAU,EAAE,UAAU,CAAC,CAAC;QACzD,CAAC,CAAC;IACN,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,OAAO,CACH,8BAAC,qBAAS,OACF,cAAc,EAClB,GAAG,EAAE,YAAY,EACjB,SAAS,EAAE,CAAC,EAAE,EACd,gBAAgB,EAAE,gBAAgB;QAElC,8BAAC,WAAI,QAAE,aAAa,EAAE,CAAQ;QAC9B,8BAAC,WAAI,QAAE,aAAa,EAAE,CAAQ,CACtB,CACf,CAAC;AACN,CAAC,CAAC;AApCW,QAAA,eAAe,mBAoC1B","sourcesContent":["import React from 'react';\n\nimport {cn} from '../../utils/cn';\n\nimport {Pane} from './Pane';\nimport {SplitPane} from './SplitPane';\nimport type {SplitPaneProps} from './SplitPane';\n\nimport './StyledSplitPane.scss';\n\nconst b = cn('styled-split-pane');\nconst resizerClassName = b('pane-resizer');\n\ntype Props = SplitPaneProps & {\n paneOneRender: () => React.ReactNode;\n paneTwoRender: () => React.ReactNode;\n};\n\nexport const StyledSplitPane = ({paneOneRender, paneTwoRender, ...splitPaneProps}: Props) => {\n const splitPaneRef = React.useRef<SplitPane & {splitPane?: HTMLDivElement | null}>(null);\n\n React.useEffect(() => {\n const resizer =\n splitPaneRef.current?.splitPane?.getElementsByClassName(resizerClassName)[0];\n const hoveredClassName = `${resizerClassName}_hovered`;\n\n const onTouchStart = () => {\n resizer?.classList.add(hoveredClassName);\n };\n\n const onTouchEnd = () => {\n resizer?.classList.remove(hoveredClassName);\n };\n\n resizer?.addEventListener('touchstart', onTouchStart);\n resizer?.addEventListener('touchend', onTouchEnd);\n\n return function cleanup() {\n resizer?.removeEventListener('touchstart', onTouchStart);\n resizer?.removeEventListener('touchend', onTouchEnd);\n };\n }, []);\n\n return (\n <SplitPane\n {...splitPaneProps}\n ref={splitPaneRef}\n className={b()}\n resizerClassName={resizerClassName}\n >\n <Pane>{paneOneRender()}</Pane>\n <Pane>{paneTwoRender()}</Pane>\n </SplitPane>\n );\n};\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"../../../../src","sources":["components/SplitPane/constants.ts"],"names":[],"mappings":";;;AAAa,QAAA,WAAW,GAAG;IACvB,UAAU,EAAE,YAAY;IACxB,QAAQ,EAAE,UAAU;CACd,CAAC","sourcesContent":["export const SplitLayout = {\n HORIZONTAL: 'horizontal',\n VERTICAL: 'vertical',\n} as const;\n"]}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ScreenOrientationType } from "../../constants/index.js";
|
|
2
|
+
import { SplitLayoutType } from "./types.js";
|
|
3
|
+
export { SplitLayout } from "./constants.js";
|
|
4
|
+
export * from "./Pane.js";
|
|
5
|
+
export * from "./SplitPane.js";
|
|
6
|
+
export * from "./StyledSplitPane.js";
|
|
7
|
+
export * from "./types.js";
|
|
8
|
+
export declare function mapScreenOrientationTypeToSplitLayout(type: ScreenOrientationType): SplitLayoutType;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SplitLayout = void 0;
|
|
4
|
+
exports.mapScreenOrientationTypeToSplitLayout = mapScreenOrientationTypeToSplitLayout;
|
|
5
|
+
const tslib_1 = require("tslib");
|
|
6
|
+
var constants_1 = require("./constants.js");
|
|
7
|
+
Object.defineProperty(exports, "SplitLayout", { enumerable: true, get: function () { return constants_1.SplitLayout; } });
|
|
8
|
+
tslib_1.__exportStar(require("./Pane.js"), exports);
|
|
9
|
+
tslib_1.__exportStar(require("./SplitPane.js"), exports);
|
|
10
|
+
tslib_1.__exportStar(require("./StyledSplitPane.js"), exports);
|
|
11
|
+
tslib_1.__exportStar(require("./types.js"), exports);
|
|
12
|
+
function mapScreenOrientationTypeToSplitLayout(type) {
|
|
13
|
+
switch (type) {
|
|
14
|
+
case 'landscape-primary':
|
|
15
|
+
case 'landscape-secondary': {
|
|
16
|
+
return 'vertical';
|
|
17
|
+
}
|
|
18
|
+
case 'portrait-primary':
|
|
19
|
+
case 'portrait-secondary':
|
|
20
|
+
default: {
|
|
21
|
+
return 'horizontal';
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"../../../../src","sources":["components/SplitPane/index.ts"],"names":[],"mappings":";;;AAUA,sFAcC;;AApBD,4CAAwC;AAAhC,wGAAA,WAAW,OAAA;AACnB,oDAAuB;AACvB,yDAA4B;AAC5B,+DAAkC;AAClC,qDAAwB;AAExB,SAAgB,qCAAqC,CACjD,IAA2B;IAE3B,QAAQ,IAAI,EAAE,CAAC;QACX,KAAK,mBAAmB,CAAC;QACzB,KAAK,qBAAqB,CAAC,CAAC,CAAC;YACzB,OAAO,UAAU,CAAC;QACtB,CAAC;QACD,KAAK,kBAAkB,CAAC;QACxB,KAAK,oBAAoB,CAAC;QAC1B,OAAO,CAAC,CAAC,CAAC;YACN,OAAO,YAAY,CAAC;QACxB,CAAC;IACL,CAAC;AACL,CAAC","sourcesContent":["import {ScreenOrientationType} from '../../constants';\n\nimport {SplitLayoutType} from './types';\n\nexport {SplitLayout} from './constants';\nexport * from './Pane';\nexport * from './SplitPane';\nexport * from './StyledSplitPane';\nexport * from './types';\n\nexport function mapScreenOrientationTypeToSplitLayout(\n type: ScreenOrientationType,\n): SplitLayoutType {\n switch (type) {\n case 'landscape-primary':\n case 'landscape-secondary': {\n return 'vertical';\n }\n case 'portrait-primary':\n case 'portrait-secondary':\n default: {\n return 'horizontal';\n }\n }\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"../../../../src","sources":["components/SplitPane/types.ts"],"names":[],"mappings":"","sourcesContent":["import type {SplitLayout} from './constants';\n\nexport type SplitLayoutType = (typeof SplitLayout)[keyof typeof SplitLayout];\n"]}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { SplitLayout } from "../SplitPane/index.js";
|
|
3
|
+
import type { SplitLayoutType } from "../SplitPane/index.js";
|
|
4
|
+
export declare const SPLIT_TOOLTIP_RESIZER_SIZE = 24;
|
|
5
|
+
export declare const SPLIT_TOOLTIP_MAIN_PANE_RATIO = 0.6;
|
|
6
|
+
export { SplitLayout as SplitTooltipLayout };
|
|
7
|
+
export type SplitTooltipLayout = SplitLayoutType;
|
|
8
|
+
export interface SplitTooltipRenderProps {
|
|
9
|
+
/** The active pane layout. */
|
|
10
|
+
layout: SplitTooltipLayout;
|
|
11
|
+
/** The current size of the main pane in pixels. */
|
|
12
|
+
size: number;
|
|
13
|
+
}
|
|
14
|
+
export interface SplitTooltipProps {
|
|
15
|
+
/** Whether to show the tooltip pane. Defaults to `true`. Disabling preserves the mounted main pane. */
|
|
16
|
+
enabled?: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* The controlled pane layout. When omitted, the layout is derived from the container size:
|
|
19
|
+
* vertical when width is greater than height, horizontal otherwise.
|
|
20
|
+
*/
|
|
21
|
+
layout?: SplitTooltipLayout;
|
|
22
|
+
/** The share of the container width occupied by the main pane in vertical layout. Defaults to `0.6`. */
|
|
23
|
+
mainPaneRatio?: number;
|
|
24
|
+
/**
|
|
25
|
+
* Minimum main pane height in pixels in horizontal layout. Does not apply in vertical layout.
|
|
26
|
+
* Capped at half the height available after the resizer. When omitted, automatic sizing has no minimum.
|
|
27
|
+
*/
|
|
28
|
+
minMainPaneSize?: number;
|
|
29
|
+
/** Additional styles for the main pane. */
|
|
30
|
+
mainPaneStyle?: React.CSSProperties;
|
|
31
|
+
/** Called after initialization and whenever the main pane size or layout changes. */
|
|
32
|
+
onMainPaneSizeChange?: (size: number, layout: SplitTooltipLayout) => void;
|
|
33
|
+
/**
|
|
34
|
+
* Preserves the manually selected horizontal main pane size across content, container and layout
|
|
35
|
+
* changes, allowing the tooltip to shrink and scroll. Defaults to `false`.
|
|
36
|
+
* Before the first drag, sizing follows the tooltip content in either mode.
|
|
37
|
+
*/
|
|
38
|
+
preserveManualSize?: boolean;
|
|
39
|
+
/** Renders the main pane with its current layout and size. */
|
|
40
|
+
renderMainPane: (props: SplitTooltipRenderProps) => React.ReactNode;
|
|
41
|
+
/** Renders the tooltip pane with the current main pane layout and size. */
|
|
42
|
+
renderTooltip: (props: SplitTooltipRenderProps) => React.ReactNode;
|
|
43
|
+
/** Controls the resizer visibility without hiding the tooltip pane. Defaults to `false`. */
|
|
44
|
+
resizerVisible?: boolean;
|
|
45
|
+
/** Additional styles for the split pane container. */
|
|
46
|
+
style?: React.CSSProperties;
|
|
47
|
+
/** Additional styles for the tooltip pane. */
|
|
48
|
+
tooltipPaneStyle?: React.CSSProperties;
|
|
49
|
+
}
|
|
50
|
+
export declare function getSplitTooltipLayout(width: number, height: number, layout?: SplitTooltipLayout): SplitTooltipLayout;
|
|
51
|
+
export declare function getSplitTooltipMainPaneSize({ containerHeight, containerWidth, layout, mainPaneRatio, minMainPaneSize, tooltipHeight, }: {
|
|
52
|
+
containerHeight: number;
|
|
53
|
+
containerWidth: number;
|
|
54
|
+
layout: SplitTooltipLayout;
|
|
55
|
+
mainPaneRatio?: number;
|
|
56
|
+
minMainPaneSize?: number;
|
|
57
|
+
tooltipHeight: number;
|
|
58
|
+
}): number;
|
|
59
|
+
export declare function getSplitTooltipSizeLimits(containerHeight: number, tooltipHeight: number, minMainPaneSize?: number, preserveManualSize?: boolean): {
|
|
60
|
+
minSize: number;
|
|
61
|
+
maxSize: number;
|
|
62
|
+
};
|
|
63
|
+
export declare function SplitTooltip(props: SplitTooltipProps): React.JSX.Element;
|