@aquera/nile-visualization 0.1.0 → 0.3.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/dist/src/index.d.ts +57 -2
- package/dist/src/index.js +31 -0
- package/dist/src/internal/highcharts-provider.js +90 -0
- package/dist/src/internal/separated-chart-config.d.ts +5 -0
- package/dist/src/internal/separated-chart-config.js +16 -0
- package/dist/src/internal/types/ai-config.type.d.ts +9 -0
- package/dist/src/internal/types/ai-config.type.js +2 -0
- package/dist/src/internal/types/all-chart-config.type.d.ts +8 -0
- package/dist/src/internal/types/all-chart-config.type.js +2 -0
- package/dist/src/internal/types/aq-config.type.d.ts +13 -0
- package/dist/src/internal/types/aq-config.type.js +2 -0
- package/dist/src/internal/types/chart-anomaly-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-anomaly-config.type.js +2 -0
- package/dist/src/internal/types/chart-area-config.type.d.ts +17 -0
- package/dist/src/internal/types/chart-area-config.type.js +2 -0
- package/dist/src/internal/types/chart-area-negative-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-area-negative-config.type.js +2 -0
- package/dist/src/internal/types/chart-area-range-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-area-range-config.type.js +2 -0
- package/dist/src/internal/types/chart-area-spline-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-area-spline-config.type.js +2 -0
- package/dist/src/internal/types/chart-bar-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-bar-config.type.js +2 -0
- package/dist/src/internal/types/chart-bellcurve-config.type.d.ts +19 -0
- package/dist/src/internal/types/chart-bellcurve-config.type.js +2 -0
- package/dist/src/internal/types/chart-boxplot-config.type.d.ts +15 -0
- package/dist/src/internal/types/chart-boxplot-config.type.js +2 -0
- package/dist/src/internal/types/chart-bubble-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-bubble-config.type.js +2 -0
- package/dist/src/internal/types/chart-cluster-config.type.d.ts +15 -0
- package/dist/src/internal/types/chart-cluster-config.type.js +2 -0
- package/dist/src/internal/types/chart-column-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-column-config.type.js +2 -0
- package/dist/src/internal/types/chart-column-drilldown-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-column-drilldown-config.type.js +2 -0
- package/dist/src/internal/types/chart-column-pyramid-config.type.d.ts +11 -0
- package/dist/src/internal/types/chart-column-pyramid-config.type.js +2 -0
- package/dist/src/internal/types/chart-column-range-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-column-range-config.type.js +2 -0
- package/dist/src/internal/types/chart-config.type.d.ts +16 -0
- package/dist/src/internal/types/chart-config.type.js +2 -0
- package/dist/src/internal/types/chart-donut-config.type.d.ts +14 -0
- package/dist/src/internal/types/chart-donut-config.type.js +2 -0
- package/dist/src/internal/types/chart-dumbbell-config.type.d.ts +16 -0
- package/dist/src/internal/types/chart-dumbbell-config.type.js +2 -0
- package/dist/src/internal/types/chart-dumbbell-lower-config.type.d.ts +5 -0
- package/dist/src/internal/types/chart-dumbbell-lower-config.type.js +2 -0
- package/dist/src/internal/types/chart-dumbbell-upper-config.type.d.ts +5 -0
- package/dist/src/internal/types/chart-dumbbell-upper-config.type.js +2 -0
- package/dist/src/internal/types/chart-euler-config.type.d.ts +10 -0
- package/dist/src/internal/types/chart-euler-config.type.js +2 -0
- package/dist/src/internal/types/chart-fan-config.type.d.ts +17 -0
- package/dist/src/internal/types/chart-fan-config.type.js +2 -0
- package/dist/src/internal/types/chart-flame-config.type.d.ts +14 -0
- package/dist/src/internal/types/chart-flame-config.type.js +2 -0
- package/dist/src/internal/types/chart-funnel-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-funnel-config.type.js +2 -0
- package/dist/src/internal/types/chart-gauge-config.type.d.ts +14 -0
- package/dist/src/internal/types/chart-gauge-config.type.js +2 -0
- package/dist/src/internal/types/chart-histogram-config.type.d.ts +19 -0
- package/dist/src/internal/types/chart-histogram-config.type.js +2 -0
- package/dist/src/internal/types/chart-kpi-config.type.d.ts +21 -0
- package/dist/src/internal/types/chart-kpi-config.type.js +2 -0
- package/dist/src/internal/types/chart-line-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-line-config.type.js +2 -0
- package/dist/src/internal/types/chart-lollipop-config.type.d.ts +11 -0
- package/dist/src/internal/types/chart-lollipop-config.type.js +2 -0
- package/dist/src/internal/types/chart-pie-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-pie-config.type.js +2 -0
- package/dist/src/internal/types/chart-polygon-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-polygon-config.type.js +2 -0
- package/dist/src/internal/types/chart-radar-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-radar-config.type.js +2 -0
- package/dist/src/internal/types/chart-radial-bar-config.type.d.ts +16 -0
- package/dist/src/internal/types/chart-radial-bar-config.type.js +2 -0
- package/dist/src/internal/types/chart-scatter-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-scatter-config.type.js +2 -0
- package/dist/src/internal/types/chart-spiderweb-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-spiderweb-config.type.js +2 -0
- package/dist/src/internal/types/chart-spline-config.type.d.ts +12 -0
- package/dist/src/internal/types/chart-spline-config.type.js +2 -0
- package/dist/src/internal/types/chart-stacked-config.type.d.ts +15 -0
- package/dist/src/internal/types/chart-stacked-config.type.js +2 -0
- package/dist/src/internal/types/chart-timeline-config.type.d.ts +15 -0
- package/dist/src/internal/types/chart-timeline-config.type.js +2 -0
- package/dist/src/internal/types/chart-trendline-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-trendline-config.type.js +2 -0
- package/dist/src/internal/types/chart-variable-pie-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-variable-pie-config.type.js +2 -0
- package/dist/src/internal/types/chart-vector-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-vector-config.type.js +2 -0
- package/dist/src/internal/types/chart-waterfall-config.type.d.ts +11 -0
- package/dist/src/internal/types/chart-waterfall-config.type.js +2 -0
- package/dist/src/internal/types/chart-xrange-config.type.d.ts +13 -0
- package/dist/src/internal/types/chart-xrange-config.type.js +2 -0
- package/dist/src/internal/types/index.d.ts +50 -0
- package/dist/src/internal/types/index.js +2 -0
- package/dist/src/internal/types/nile-ai-widgets-config-input.type.d.ts +23 -0
- package/dist/src/internal/types/nile-ai-widgets-config-input.type.js +2 -0
- package/dist/src/internal/types/nile-chart-config-input.type.d.ts +7 -0
- package/dist/src/internal/types/nile-chart-config-input.type.js +2 -0
- package/dist/src/internal/types/primitive-chart-config.type.d.ts +32 -0
- package/dist/src/internal/types/primitive-chart-config.type.js +2 -0
- package/dist/src/internal/types/separated-chart-config-input.type.d.ts +7 -0
- package/dist/src/internal/types/separated-chart-config-input.type.js +2 -0
- package/dist/src/internal/types/switchable-config.type.d.ts +8 -0
- package/dist/src/internal/types/switchable-config.type.js +2 -0
- package/dist/src/nile-ai-panel/index.d.ts +1 -0
- package/dist/src/nile-ai-panel/nile-ai-panel.d.ts +8 -1
- package/dist/src/nile-ai-panel/nile-ai-panel.js +34 -0
- package/dist/src/nile-ai-sender/index.d.ts +1 -0
- package/dist/src/nile-ai-sender/nile-ai-sender.d.ts +8 -1
- package/dist/src/nile-ai-sender/nile-ai-sender.js +30 -0
- package/dist/src/nile-anomaly-chart/nile-anomaly-chart.d.ts +6 -0
- package/dist/src/nile-anomaly-chart/nile-anomaly-chart.js +41 -0
- package/dist/src/nile-area-chart/nile-area-chart.d.ts +6 -0
- package/dist/src/nile-area-chart/nile-area-chart.js +41 -0
- package/dist/src/nile-area-negative-chart/index.d.ts +2 -0
- package/dist/src/nile-area-negative-chart/index.js +2 -0
- package/dist/src/nile-area-negative-chart/nile-area-negative-chart.css.d.ts +1 -0
- package/dist/src/nile-area-negative-chart/nile-area-negative-chart.css.js +28 -0
- package/dist/src/nile-area-negative-chart/nile-area-negative-chart.d.ts +42 -0
- package/dist/src/nile-area-negative-chart/nile-area-negative-chart.js +178 -0
- package/dist/src/nile-area-range-chart/index.d.ts +2 -0
- package/dist/src/nile-area-range-chart/index.js +2 -0
- package/dist/src/nile-area-range-chart/nile-area-range-chart.css.d.ts +1 -0
- package/dist/src/nile-area-range-chart/nile-area-range-chart.css.js +28 -0
- package/dist/src/nile-area-range-chart/nile-area-range-chart.d.ts +41 -0
- package/dist/src/nile-area-range-chart/nile-area-range-chart.js +173 -0
- package/dist/src/nile-area-spline-chart/index.d.ts +2 -0
- package/dist/src/nile-area-spline-chart/index.js +2 -0
- package/dist/src/nile-area-spline-chart/nile-area-spline-chart.css.d.ts +1 -0
- package/dist/src/nile-area-spline-chart/nile-area-spline-chart.css.js +28 -0
- package/dist/src/nile-area-spline-chart/nile-area-spline-chart.d.ts +41 -0
- package/dist/src/nile-area-spline-chart/nile-area-spline-chart.js +174 -0
- package/dist/src/nile-bar-chart/nile-bar-chart.d.ts +6 -0
- package/dist/src/nile-bar-chart/nile-bar-chart.js +40 -1
- package/dist/src/nile-bellcurve-chart/index.d.ts +2 -0
- package/dist/src/nile-bellcurve-chart/index.js +2 -0
- package/dist/src/nile-bellcurve-chart/nile-bellcurve-chart.css.d.ts +1 -0
- package/dist/src/nile-bellcurve-chart/nile-bellcurve-chart.css.js +28 -0
- package/dist/src/nile-bellcurve-chart/nile-bellcurve-chart.d.ts +49 -0
- package/dist/src/nile-bellcurve-chart/nile-bellcurve-chart.js +258 -0
- package/dist/src/nile-boxplot-chart/index.d.ts +2 -0
- package/dist/src/nile-boxplot-chart/index.js +2 -0
- package/dist/src/nile-boxplot-chart/nile-boxplot-chart.css.d.ts +1 -0
- package/dist/src/nile-boxplot-chart/nile-boxplot-chart.css.js +28 -0
- package/dist/src/nile-boxplot-chart/nile-boxplot-chart.d.ts +58 -0
- package/dist/src/nile-boxplot-chart/nile-boxplot-chart.js +235 -0
- package/dist/src/nile-bubble-chart/nile-bubble-chart.d.ts +6 -0
- package/dist/src/nile-bubble-chart/nile-bubble-chart.js +39 -0
- package/dist/src/nile-chart/index.d.ts +3 -1
- package/dist/src/nile-chart/index.js +1 -0
- package/dist/src/nile-chart/nile-chart-config-builder.d.ts +4 -0
- package/dist/src/nile-chart/nile-chart-config-builder.js +13 -0
- package/dist/src/nile-chart/nile-chart-config.d.ts +76 -2
- package/dist/src/nile-chart/nile-chart.d.ts +16 -2
- package/dist/src/nile-chart/nile-chart.js +144 -14
- package/dist/src/nile-cluster-chart/index.d.ts +2 -0
- package/dist/src/nile-cluster-chart/index.js +2 -0
- package/dist/src/nile-cluster-chart/nile-cluster-chart.css.d.ts +1 -0
- package/dist/src/nile-cluster-chart/nile-cluster-chart.css.js +28 -0
- package/dist/src/nile-cluster-chart/nile-cluster-chart.d.ts +46 -0
- package/dist/src/nile-cluster-chart/nile-cluster-chart.js +196 -0
- package/dist/src/nile-column-chart/nile-column-chart.d.ts +6 -0
- package/dist/src/nile-column-chart/nile-column-chart.js +39 -0
- package/dist/src/nile-column-drilldown-chart/index.d.ts +2 -0
- package/dist/src/nile-column-drilldown-chart/index.js +2 -0
- package/dist/src/nile-column-drilldown-chart/nile-column-drilldown-chart.css.d.ts +1 -0
- package/dist/src/nile-column-drilldown-chart/nile-column-drilldown-chart.css.js +28 -0
- package/dist/src/nile-column-drilldown-chart/nile-column-drilldown-chart.d.ts +49 -0
- package/dist/src/nile-column-drilldown-chart/nile-column-drilldown-chart.js +186 -0
- package/dist/src/nile-column-pyramid-chart/index.d.ts +2 -0
- package/dist/src/nile-column-pyramid-chart/index.js +2 -0
- package/dist/src/nile-column-pyramid-chart/nile-column-pyramid-chart.css.d.ts +1 -0
- package/dist/src/nile-column-pyramid-chart/nile-column-pyramid-chart.css.js +28 -0
- package/dist/src/nile-column-pyramid-chart/nile-column-pyramid-chart.d.ts +39 -0
- package/dist/src/nile-column-pyramid-chart/nile-column-pyramid-chart.js +155 -0
- package/dist/src/nile-column-range-chart/index.d.ts +2 -0
- package/dist/src/nile-column-range-chart/index.js +2 -0
- package/dist/src/nile-column-range-chart/nile-column-range-chart.css.d.ts +1 -0
- package/dist/src/nile-column-range-chart/nile-column-range-chart.css.js +28 -0
- package/dist/src/nile-column-range-chart/nile-column-range-chart.d.ts +40 -0
- package/dist/src/nile-column-range-chart/nile-column-range-chart.js +169 -0
- package/dist/src/nile-donut-chart/nile-donut-chart.d.ts +6 -0
- package/dist/src/nile-donut-chart/nile-donut-chart.js +43 -0
- package/dist/src/nile-dumbbell-chart/index.d.ts +2 -0
- package/dist/src/nile-dumbbell-chart/index.js +2 -0
- package/dist/src/nile-dumbbell-chart/nile-dumbbell-chart.css.d.ts +1 -0
- package/dist/src/nile-dumbbell-chart/nile-dumbbell-chart.css.js +28 -0
- package/dist/src/nile-dumbbell-chart/nile-dumbbell-chart.d.ts +50 -0
- package/dist/src/nile-dumbbell-chart/nile-dumbbell-chart.js +217 -0
- package/dist/src/nile-dumbbell-lower-chart/index.d.ts +1 -0
- package/dist/src/nile-dumbbell-lower-chart/index.js +2 -0
- package/dist/src/nile-dumbbell-lower-chart/nile-dumbbell-lower-chart.css.d.ts +1 -0
- package/dist/src/nile-dumbbell-lower-chart/nile-dumbbell-lower-chart.css.js +28 -0
- package/dist/src/nile-dumbbell-lower-chart/nile-dumbbell-lower-chart.d.ts +40 -0
- package/dist/src/nile-dumbbell-lower-chart/nile-dumbbell-lower-chart.js +214 -0
- package/dist/src/nile-dumbbell-upper-chart/index.d.ts +1 -0
- package/dist/src/nile-dumbbell-upper-chart/index.js +2 -0
- package/dist/src/nile-dumbbell-upper-chart/nile-dumbbell-upper-chart.css.d.ts +1 -0
- package/dist/src/nile-dumbbell-upper-chart/nile-dumbbell-upper-chart.css.js +28 -0
- package/dist/src/nile-dumbbell-upper-chart/nile-dumbbell-upper-chart.d.ts +40 -0
- package/dist/src/nile-dumbbell-upper-chart/nile-dumbbell-upper-chart.js +214 -0
- package/dist/src/nile-euler-chart/index.d.ts +2 -0
- package/dist/src/nile-euler-chart/index.js +2 -0
- package/dist/src/nile-euler-chart/nile-euler-chart.css.d.ts +1 -0
- package/dist/src/nile-euler-chart/nile-euler-chart.css.js +28 -0
- package/dist/src/nile-euler-chart/nile-euler-chart.d.ts +38 -0
- package/dist/src/nile-euler-chart/nile-euler-chart.js +149 -0
- package/dist/src/nile-fan-chart/index.d.ts +2 -0
- package/dist/src/nile-fan-chart/index.js +2 -0
- package/dist/src/nile-fan-chart/nile-fan-chart.css.d.ts +1 -0
- package/dist/src/nile-fan-chart/nile-fan-chart.css.js +28 -0
- package/dist/src/nile-fan-chart/nile-fan-chart.d.ts +65 -0
- package/dist/src/nile-fan-chart/nile-fan-chart.js +257 -0
- package/dist/src/nile-flame-chart/index.d.ts +2 -0
- package/dist/src/nile-flame-chart/index.js +2 -0
- package/dist/src/nile-flame-chart/nile-flame-chart.css.d.ts +1 -0
- package/dist/src/nile-flame-chart/nile-flame-chart.css.js +28 -0
- package/dist/src/nile-flame-chart/nile-flame-chart.d.ts +60 -0
- package/dist/src/nile-flame-chart/nile-flame-chart.js +311 -0
- package/dist/src/nile-funnel-chart/index.d.ts +2 -0
- package/dist/src/nile-funnel-chart/index.js +2 -0
- package/dist/src/nile-funnel-chart/nile-funnel-chart.css.d.ts +1 -0
- package/dist/src/nile-funnel-chart/nile-funnel-chart.css.js +28 -0
- package/dist/src/nile-funnel-chart/nile-funnel-chart.d.ts +42 -0
- package/dist/src/nile-funnel-chart/nile-funnel-chart.js +189 -0
- package/dist/src/nile-gauge-chart/nile-gauge-chart.d.ts +6 -0
- package/dist/src/nile-gauge-chart/nile-gauge-chart.js +43 -0
- package/dist/src/nile-histogram-chart/index.d.ts +2 -0
- package/dist/src/nile-histogram-chart/index.js +2 -0
- package/dist/src/nile-histogram-chart/nile-histogram-chart.css.d.ts +1 -0
- package/dist/src/nile-histogram-chart/nile-histogram-chart.css.js +28 -0
- package/dist/src/nile-histogram-chart/nile-histogram-chart.d.ts +53 -0
- package/dist/src/nile-histogram-chart/nile-histogram-chart.js +263 -0
- package/dist/src/nile-inverted-area-chart/index.d.ts +2 -0
- package/dist/src/nile-inverted-area-chart/index.js +2 -0
- package/dist/src/nile-inverted-area-chart/nile-inverted-area-chart.css.d.ts +1 -0
- package/dist/src/nile-inverted-area-chart/nile-inverted-area-chart.css.js +28 -0
- package/dist/src/nile-inverted-area-chart/nile-inverted-area-chart.d.ts +40 -0
- package/dist/src/nile-inverted-area-chart/nile-inverted-area-chart.js +173 -0
- package/dist/src/nile-kpi-chart/index.d.ts +1 -1
- package/dist/src/nile-kpi-chart/nile-kpi-chart.d.ts +32 -0
- package/dist/src/nile-kpi-chart/nile-kpi-chart.js +60 -0
- package/dist/src/nile-line-chart/nile-line-chart.d.ts +6 -0
- package/dist/src/nile-line-chart/nile-line-chart.js +39 -0
- package/dist/src/nile-lollipop-chart/index.d.ts +2 -0
- package/dist/src/nile-lollipop-chart/index.js +2 -0
- package/dist/src/nile-lollipop-chart/nile-lollipop-chart.css.d.ts +1 -0
- package/dist/src/nile-lollipop-chart/nile-lollipop-chart.css.js +28 -0
- package/dist/src/nile-lollipop-chart/nile-lollipop-chart.d.ts +39 -0
- package/dist/src/nile-lollipop-chart/nile-lollipop-chart.js +174 -0
- package/dist/src/nile-pie-chart/nile-pie-chart.d.ts +6 -0
- package/dist/src/nile-pie-chart/nile-pie-chart.js +41 -0
- package/dist/src/nile-polygon-chart/index.d.ts +2 -0
- package/dist/src/nile-polygon-chart/index.js +2 -0
- package/dist/src/nile-polygon-chart/nile-polygon-chart.css.d.ts +1 -0
- package/dist/src/nile-polygon-chart/nile-polygon-chart.css.js +28 -0
- package/dist/src/nile-polygon-chart/nile-polygon-chart.d.ts +41 -0
- package/dist/src/nile-polygon-chart/nile-polygon-chart.js +167 -0
- package/dist/src/nile-radar-chart/nile-radar-chart.d.ts +6 -0
- package/dist/src/nile-radar-chart/nile-radar-chart.js +39 -0
- package/dist/src/nile-radial-bar-chart/index.d.ts +2 -0
- package/dist/src/nile-radial-bar-chart/index.js +2 -0
- package/dist/src/nile-radial-bar-chart/nile-radial-bar-chart.css.d.ts +1 -0
- package/dist/src/nile-radial-bar-chart/nile-radial-bar-chart.css.js +28 -0
- package/dist/src/nile-radial-bar-chart/nile-radial-bar-chart.d.ts +42 -0
- package/dist/src/nile-radial-bar-chart/nile-radial-bar-chart.js +191 -0
- package/dist/src/nile-scatter-chart/nile-scatter-chart.d.ts +6 -0
- package/dist/src/nile-scatter-chart/nile-scatter-chart.js +39 -0
- package/dist/src/nile-spiderweb-chart/index.d.ts +2 -0
- package/dist/src/nile-spiderweb-chart/index.js +2 -0
- package/dist/src/nile-spiderweb-chart/nile-spiderweb-chart.css.d.ts +1 -0
- package/dist/src/nile-spiderweb-chart/nile-spiderweb-chart.css.js +28 -0
- package/dist/src/nile-spiderweb-chart/nile-spiderweb-chart.d.ts +46 -0
- package/dist/src/nile-spiderweb-chart/nile-spiderweb-chart.js +191 -0
- package/dist/src/nile-spline-chart/nile-spline-chart.d.ts +6 -0
- package/dist/src/nile-spline-chart/nile-spline-chart.js +39 -0
- package/dist/src/nile-stacked-chart/index.d.ts +2 -0
- package/dist/src/nile-stacked-chart/index.js +2 -0
- package/dist/src/nile-stacked-chart/nile-stacked-chart.css.d.ts +1 -0
- package/dist/src/nile-stacked-chart/nile-stacked-chart.css.js +28 -0
- package/dist/src/nile-stacked-chart/nile-stacked-chart.d.ts +47 -0
- package/dist/src/nile-stacked-chart/nile-stacked-chart.js +216 -0
- package/dist/src/nile-timeline-chart/index.d.ts +2 -0
- package/dist/src/nile-timeline-chart/index.js +2 -0
- package/dist/src/nile-timeline-chart/nile-timeline-chart.css.d.ts +1 -0
- package/dist/src/nile-timeline-chart/nile-timeline-chart.css.js +28 -0
- package/dist/src/nile-timeline-chart/nile-timeline-chart.d.ts +58 -0
- package/dist/src/nile-timeline-chart/nile-timeline-chart.js +239 -0
- package/dist/src/nile-trendline-chart/nile-trendline-chart.d.ts +6 -0
- package/dist/src/nile-trendline-chart/nile-trendline-chart.js +41 -0
- package/dist/src/nile-variable-pie-chart/index.d.ts +2 -0
- package/dist/src/nile-variable-pie-chart/index.js +2 -0
- package/dist/src/nile-variable-pie-chart/nile-variable-pie-chart.css.d.ts +1 -0
- package/dist/src/nile-variable-pie-chart/nile-variable-pie-chart.css.js +28 -0
- package/dist/src/nile-variable-pie-chart/nile-variable-pie-chart.d.ts +42 -0
- package/dist/src/nile-variable-pie-chart/nile-variable-pie-chart.js +180 -0
- package/dist/src/nile-vector-chart/index.d.ts +2 -0
- package/dist/src/nile-vector-chart/index.js +2 -0
- package/dist/src/nile-vector-chart/nile-vector-chart.css.d.ts +1 -0
- package/dist/src/nile-vector-chart/nile-vector-chart.css.js +28 -0
- package/dist/src/nile-vector-chart/nile-vector-chart.d.ts +44 -0
- package/dist/src/nile-vector-chart/nile-vector-chart.js +181 -0
- package/dist/src/nile-waterfall-chart/nile-waterfall-chart.d.ts +6 -0
- package/dist/src/nile-waterfall-chart/nile-waterfall-chart.js +37 -0
- package/dist/src/nile-xrange-chart/index.d.ts +2 -0
- package/dist/src/nile-xrange-chart/index.js +2 -0
- package/dist/src/nile-xrange-chart/nile-xrange-chart.css.d.ts +1 -0
- package/dist/src/nile-xrange-chart/nile-xrange-chart.css.js +28 -0
- package/dist/src/nile-xrange-chart/nile-xrange-chart.d.ts +44 -0
- package/dist/src/nile-xrange-chart/nile-xrange-chart.js +193 -0
- package/package.json +12 -1
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { customElement, property, query } from 'lit/decorators.js';
|
|
3
|
+
import { html } from 'lit';
|
|
4
|
+
import { getHighcharts } from '../internal/highcharts-provider.js';
|
|
5
|
+
import NileElement from '../internal/nile-element.js';
|
|
6
|
+
import { applySeparatedChartConfig } from '../internal/separated-chart-config.js';
|
|
7
|
+
import { deepMerge } from '../internal/utils.js';
|
|
8
|
+
import { styles } from './nile-cluster-chart.css.js';
|
|
9
|
+
let NileClusterChart = class NileClusterChart extends NileElement {
|
|
10
|
+
constructor() {
|
|
11
|
+
super(...arguments);
|
|
12
|
+
this._hc = null;
|
|
13
|
+
this.chart = null;
|
|
14
|
+
this.resizeObserver = null;
|
|
15
|
+
/** Full chart configuration. Accepts separated `{ chart, aq }` input. */
|
|
16
|
+
this.config = null;
|
|
17
|
+
this.chartTitle = '';
|
|
18
|
+
this.chartSubtitle = '';
|
|
19
|
+
this.data = [];
|
|
20
|
+
this.categories = [];
|
|
21
|
+
this.options = {};
|
|
22
|
+
this.loading = false;
|
|
23
|
+
this.height = '400px';
|
|
24
|
+
this.yAxisTitle = '';
|
|
25
|
+
this.showLegend = true;
|
|
26
|
+
this.groupPadding = 0.14;
|
|
27
|
+
this.pointPadding = 0.08;
|
|
28
|
+
}
|
|
29
|
+
/** Apply `{ chart, aq }` config to individual properties. */
|
|
30
|
+
applyConfig(cfg) {
|
|
31
|
+
applySeparatedChartConfig(this, cfg);
|
|
32
|
+
}
|
|
33
|
+
connectedCallback() {
|
|
34
|
+
super.connectedCallback();
|
|
35
|
+
if (this.config)
|
|
36
|
+
this.applyConfig(this.config);
|
|
37
|
+
}
|
|
38
|
+
disconnectedCallback() {
|
|
39
|
+
super.disconnectedCallback();
|
|
40
|
+
this.destroyChart();
|
|
41
|
+
this.resizeObserver?.disconnect();
|
|
42
|
+
this.resizeObserver = null;
|
|
43
|
+
}
|
|
44
|
+
firstUpdated() {
|
|
45
|
+
this.initChart();
|
|
46
|
+
this.setupResizeObserver();
|
|
47
|
+
}
|
|
48
|
+
updated(changedProperties) {
|
|
49
|
+
if (changedProperties.has('config') && this.config) {
|
|
50
|
+
this.applyConfig(this.config);
|
|
51
|
+
return;
|
|
52
|
+
}
|
|
53
|
+
const props = [
|
|
54
|
+
'data',
|
|
55
|
+
'categories',
|
|
56
|
+
'chartTitle',
|
|
57
|
+
'chartSubtitle',
|
|
58
|
+
'options',
|
|
59
|
+
'height',
|
|
60
|
+
'yAxisTitle',
|
|
61
|
+
'loading',
|
|
62
|
+
'showLegend',
|
|
63
|
+
'groupPadding',
|
|
64
|
+
'pointPadding',
|
|
65
|
+
];
|
|
66
|
+
if (!props.some(p => changedProperties.has(p)))
|
|
67
|
+
return;
|
|
68
|
+
if (this.loading) {
|
|
69
|
+
this.destroyChart();
|
|
70
|
+
return;
|
|
71
|
+
}
|
|
72
|
+
if (this.chart) {
|
|
73
|
+
this.chart.update(this.buildOptions(), true, true);
|
|
74
|
+
}
|
|
75
|
+
else {
|
|
76
|
+
this.initChart();
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
setupResizeObserver() {
|
|
80
|
+
if (!this.chartContainer)
|
|
81
|
+
return;
|
|
82
|
+
this.resizeObserver = new ResizeObserver(() => {
|
|
83
|
+
this.chart?.reflow();
|
|
84
|
+
});
|
|
85
|
+
this.resizeObserver.observe(this.chartContainer);
|
|
86
|
+
}
|
|
87
|
+
buildOptions() {
|
|
88
|
+
const self = this;
|
|
89
|
+
return deepMerge({
|
|
90
|
+
chart: { type: 'column', height: this.height },
|
|
91
|
+
title: { text: this.chartTitle || undefined },
|
|
92
|
+
subtitle: { text: this.chartSubtitle || undefined },
|
|
93
|
+
xAxis: { categories: this.categories },
|
|
94
|
+
yAxis: { min: 0, title: { text: this.yAxisTitle || undefined } },
|
|
95
|
+
legend: { enabled: this.showLegend },
|
|
96
|
+
tooltip: { shared: true },
|
|
97
|
+
plotOptions: {
|
|
98
|
+
column: {
|
|
99
|
+
grouping: true,
|
|
100
|
+
groupPadding: this.groupPadding,
|
|
101
|
+
pointPadding: this.pointPadding,
|
|
102
|
+
borderWidth: 0,
|
|
103
|
+
borderRadius: 2,
|
|
104
|
+
dataLabels: { enabled: false },
|
|
105
|
+
},
|
|
106
|
+
series: {
|
|
107
|
+
cursor: 'pointer',
|
|
108
|
+
point: {
|
|
109
|
+
events: {
|
|
110
|
+
click() {
|
|
111
|
+
self.emit('nile-chart-click', {
|
|
112
|
+
point: this,
|
|
113
|
+
category: this.category,
|
|
114
|
+
value: this.y,
|
|
115
|
+
seriesName: this.series.name,
|
|
116
|
+
});
|
|
117
|
+
},
|
|
118
|
+
},
|
|
119
|
+
},
|
|
120
|
+
},
|
|
121
|
+
},
|
|
122
|
+
series: this.data.map(s => ({
|
|
123
|
+
type: 'column',
|
|
124
|
+
name: s.name,
|
|
125
|
+
data: s.data,
|
|
126
|
+
color: s.color,
|
|
127
|
+
})),
|
|
128
|
+
credits: { enabled: false },
|
|
129
|
+
}, this.options);
|
|
130
|
+
}
|
|
131
|
+
async initChart() {
|
|
132
|
+
if (this.loading || !this.chartContainer)
|
|
133
|
+
return;
|
|
134
|
+
if (!this._hc)
|
|
135
|
+
this._hc = await getHighcharts();
|
|
136
|
+
this.chart = this._hc.chart(this.chartContainer, this.buildOptions());
|
|
137
|
+
this.emit('nile-chart-ready', { chart: this.chart });
|
|
138
|
+
}
|
|
139
|
+
destroyChart() {
|
|
140
|
+
if (this.chart) {
|
|
141
|
+
this.chart.destroy();
|
|
142
|
+
this.chart = null;
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
render() {
|
|
146
|
+
if (this.loading) {
|
|
147
|
+
return html `<div class="chart-loading" style="height:${this.height}">Loading...</div>`;
|
|
148
|
+
}
|
|
149
|
+
return html `<div class="chart-container"></div>`;
|
|
150
|
+
}
|
|
151
|
+
};
|
|
152
|
+
NileClusterChart.styles = styles;
|
|
153
|
+
__decorate([
|
|
154
|
+
query('.chart-container')
|
|
155
|
+
], NileClusterChart.prototype, "chartContainer", void 0);
|
|
156
|
+
__decorate([
|
|
157
|
+
property({ type: Object })
|
|
158
|
+
], NileClusterChart.prototype, "config", void 0);
|
|
159
|
+
__decorate([
|
|
160
|
+
property({ type: String, attribute: 'chart-title' })
|
|
161
|
+
], NileClusterChart.prototype, "chartTitle", void 0);
|
|
162
|
+
__decorate([
|
|
163
|
+
property({ type: String, attribute: 'chart-subtitle' })
|
|
164
|
+
], NileClusterChart.prototype, "chartSubtitle", void 0);
|
|
165
|
+
__decorate([
|
|
166
|
+
property({ type: Array })
|
|
167
|
+
], NileClusterChart.prototype, "data", void 0);
|
|
168
|
+
__decorate([
|
|
169
|
+
property({ type: Array })
|
|
170
|
+
], NileClusterChart.prototype, "categories", void 0);
|
|
171
|
+
__decorate([
|
|
172
|
+
property({ type: Object })
|
|
173
|
+
], NileClusterChart.prototype, "options", void 0);
|
|
174
|
+
__decorate([
|
|
175
|
+
property({ type: Boolean, reflect: true })
|
|
176
|
+
], NileClusterChart.prototype, "loading", void 0);
|
|
177
|
+
__decorate([
|
|
178
|
+
property({ type: String })
|
|
179
|
+
], NileClusterChart.prototype, "height", void 0);
|
|
180
|
+
__decorate([
|
|
181
|
+
property({ type: String, attribute: 'y-axis-title' })
|
|
182
|
+
], NileClusterChart.prototype, "yAxisTitle", void 0);
|
|
183
|
+
__decorate([
|
|
184
|
+
property({ type: Boolean, attribute: 'show-legend' })
|
|
185
|
+
], NileClusterChart.prototype, "showLegend", void 0);
|
|
186
|
+
__decorate([
|
|
187
|
+
property({ type: Number, attribute: 'group-padding' })
|
|
188
|
+
], NileClusterChart.prototype, "groupPadding", void 0);
|
|
189
|
+
__decorate([
|
|
190
|
+
property({ type: Number, attribute: 'point-padding' })
|
|
191
|
+
], NileClusterChart.prototype, "pointPadding", void 0);
|
|
192
|
+
NileClusterChart = __decorate([
|
|
193
|
+
customElement('nile-cluster-chart')
|
|
194
|
+
], NileClusterChart);
|
|
195
|
+
export { NileClusterChart };
|
|
196
|
+
//# sourceMappingURL=nile-cluster-chart.js.map
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { CSSResultGroup, PropertyValues, TemplateResult } from 'lit';
|
|
2
2
|
import type Highcharts from 'highcharts';
|
|
3
3
|
import NileElement from '../internal/nile-element.js';
|
|
4
|
+
import type { NileChartConfigInputType } from '../internal/types/index.js';
|
|
4
5
|
export interface ColumnChartSeriesData {
|
|
5
6
|
name: string;
|
|
6
7
|
data: number[];
|
|
@@ -12,6 +13,8 @@ export declare class NileColumnChart extends NileElement {
|
|
|
12
13
|
private chart;
|
|
13
14
|
private resizeObserver;
|
|
14
15
|
private chartContainer;
|
|
16
|
+
/** Full chart configuration. Accepts separated { chart, aq } input. */
|
|
17
|
+
config: NileChartConfigInputType | null;
|
|
15
18
|
chartTitle: string;
|
|
16
19
|
chartSubtitle: string;
|
|
17
20
|
data: ColumnChartSeriesData[];
|
|
@@ -20,6 +23,9 @@ export declare class NileColumnChart extends NileElement {
|
|
|
20
23
|
loading: boolean;
|
|
21
24
|
height: string;
|
|
22
25
|
yAxisTitle: string;
|
|
26
|
+
/** Apply { chart, aq } config to individual properties. */
|
|
27
|
+
private applyConfig;
|
|
28
|
+
connectedCallback(): void;
|
|
23
29
|
disconnectedCallback(): void;
|
|
24
30
|
protected firstUpdated(): void;
|
|
25
31
|
protected updated(changedProperties: PropertyValues): void;
|
|
@@ -11,6 +11,8 @@ let NileColumnChart = class NileColumnChart extends NileElement {
|
|
|
11
11
|
this._hc = null;
|
|
12
12
|
this.chart = null;
|
|
13
13
|
this.resizeObserver = null;
|
|
14
|
+
/** Full chart configuration. Accepts separated { chart, aq } input. */
|
|
15
|
+
this.config = null;
|
|
14
16
|
this.chartTitle = '';
|
|
15
17
|
this.chartSubtitle = '';
|
|
16
18
|
this.data = [];
|
|
@@ -20,6 +22,36 @@ let NileColumnChart = class NileColumnChart extends NileElement {
|
|
|
20
22
|
this.height = '400px';
|
|
21
23
|
this.yAxisTitle = '';
|
|
22
24
|
}
|
|
25
|
+
/** Apply { chart, aq } config to individual properties. */
|
|
26
|
+
applyConfig(cfg) {
|
|
27
|
+
const { chart: c, aq } = cfg;
|
|
28
|
+
if (c) {
|
|
29
|
+
const col = c;
|
|
30
|
+
if (col.data)
|
|
31
|
+
this.data = col.data;
|
|
32
|
+
if (col.categories)
|
|
33
|
+
this.categories = col.categories;
|
|
34
|
+
if (col.yAxisTitle)
|
|
35
|
+
this.yAxisTitle = col.yAxisTitle;
|
|
36
|
+
if (col.height)
|
|
37
|
+
this.height = col.height;
|
|
38
|
+
if (col.loading !== undefined)
|
|
39
|
+
this.loading = col.loading;
|
|
40
|
+
if (col.options)
|
|
41
|
+
this.options = col.options;
|
|
42
|
+
}
|
|
43
|
+
if (aq) {
|
|
44
|
+
if (aq.chartTitle)
|
|
45
|
+
this.chartTitle = aq.chartTitle;
|
|
46
|
+
if (aq.chartSubtitle)
|
|
47
|
+
this.chartSubtitle = aq.chartSubtitle;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
connectedCallback() {
|
|
51
|
+
super.connectedCallback();
|
|
52
|
+
if (this.config)
|
|
53
|
+
this.applyConfig(this.config);
|
|
54
|
+
}
|
|
23
55
|
disconnectedCallback() {
|
|
24
56
|
super.disconnectedCallback();
|
|
25
57
|
this.destroyChart();
|
|
@@ -28,6 +60,10 @@ let NileColumnChart = class NileColumnChart extends NileElement {
|
|
|
28
60
|
}
|
|
29
61
|
firstUpdated() { this.initChart(); this.setupResizeObserver(); }
|
|
30
62
|
updated(changedProperties) {
|
|
63
|
+
if (changedProperties.has('config') && this.config) {
|
|
64
|
+
this.applyConfig(this.config);
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
31
67
|
const props = ['data', 'categories', 'chartTitle', 'chartSubtitle', 'options', 'height', 'yAxisTitle', 'loading'];
|
|
32
68
|
if (!props.some(p => changedProperties.has(p)))
|
|
33
69
|
return;
|
|
@@ -87,6 +123,9 @@ NileColumnChart.styles = styles;
|
|
|
87
123
|
__decorate([
|
|
88
124
|
query('.chart-container')
|
|
89
125
|
], NileColumnChart.prototype, "chartContainer", void 0);
|
|
126
|
+
__decorate([
|
|
127
|
+
property({ type: Object })
|
|
128
|
+
], NileColumnChart.prototype, "config", void 0);
|
|
90
129
|
__decorate([
|
|
91
130
|
property({ type: String, attribute: 'chart-title' })
|
|
92
131
|
], NileColumnChart.prototype, "chartTitle", void 0);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const styles: import("lit").CSSResult;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { css } from 'lit';
|
|
2
|
+
export const styles = css `
|
|
3
|
+
:host {
|
|
4
|
+
display: block;
|
|
5
|
+
width: 100%;
|
|
6
|
+
position: relative;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
:host([hidden]) {
|
|
10
|
+
display: none;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.chart-container {
|
|
14
|
+
width: 100%;
|
|
15
|
+
min-height: var(--nile-height-200px, var(--ng-height-200px));
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.chart-loading {
|
|
19
|
+
display: flex;
|
|
20
|
+
align-items: center;
|
|
21
|
+
justify-content: center;
|
|
22
|
+
min-height: inherit;
|
|
23
|
+
color: var(--nile-colors-neutral-700, var(--ng-colors-text-secondary-700));
|
|
24
|
+
font-family: var(--nile-font-family-serif, var(--ng-font-family-body));
|
|
25
|
+
font-size: var(--nile-type-scale-3, var(--ng-font-size-text-sm));
|
|
26
|
+
}
|
|
27
|
+
`;
|
|
28
|
+
//# sourceMappingURL=nile-column-drilldown-chart.css.js.map
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import type { CSSResultGroup, PropertyValues, TemplateResult } from 'lit';
|
|
2
|
+
import type Highcharts from 'highcharts';
|
|
3
|
+
import NileElement from '../internal/nile-element.js';
|
|
4
|
+
import type { SeparatedChartConfigInputType } from '../internal/types/separated-chart-config-input.type.js';
|
|
5
|
+
export interface ColumnDrilldownParentPoint {
|
|
6
|
+
name: string;
|
|
7
|
+
y: number;
|
|
8
|
+
drilldown: string;
|
|
9
|
+
}
|
|
10
|
+
export interface ColumnDrilldownSeriesConfig {
|
|
11
|
+
id: string;
|
|
12
|
+
name: string;
|
|
13
|
+
data: {
|
|
14
|
+
name: string;
|
|
15
|
+
y: number;
|
|
16
|
+
}[];
|
|
17
|
+
}
|
|
18
|
+
export declare class NileColumnDrilldownChart extends NileElement {
|
|
19
|
+
static styles: CSSResultGroup;
|
|
20
|
+
private _hc;
|
|
21
|
+
private chart;
|
|
22
|
+
private resizeObserver;
|
|
23
|
+
private chartContainer;
|
|
24
|
+
config: SeparatedChartConfigInputType | null;
|
|
25
|
+
chartTitle: string;
|
|
26
|
+
chartSubtitle: string;
|
|
27
|
+
data: ColumnDrilldownParentPoint[];
|
|
28
|
+
drilldownSeries: ColumnDrilldownSeriesConfig[];
|
|
29
|
+
seriesName: string;
|
|
30
|
+
yAxisTitle: string;
|
|
31
|
+
options: Highcharts.Options;
|
|
32
|
+
loading: boolean;
|
|
33
|
+
height: string;
|
|
34
|
+
private applyConfig;
|
|
35
|
+
connectedCallback(): void;
|
|
36
|
+
disconnectedCallback(): void;
|
|
37
|
+
protected firstUpdated(): void;
|
|
38
|
+
protected updated(changedProperties: PropertyValues): void;
|
|
39
|
+
private setupResizeObserver;
|
|
40
|
+
private buildOptions;
|
|
41
|
+
private initChart;
|
|
42
|
+
private destroyChart;
|
|
43
|
+
render(): TemplateResult;
|
|
44
|
+
}
|
|
45
|
+
declare global {
|
|
46
|
+
interface HTMLElementTagNameMap {
|
|
47
|
+
'nile-column-drilldown-chart': NileColumnDrilldownChart;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { customElement, property, query } from 'lit/decorators.js';
|
|
3
|
+
import { html } from 'lit';
|
|
4
|
+
import NileElement from '../internal/nile-element.js';
|
|
5
|
+
import { applySeparatedChartConfig } from '../internal/separated-chart-config.js';
|
|
6
|
+
import { getHighcharts } from '../internal/highcharts-provider.js';
|
|
7
|
+
import { deepMerge } from '../internal/utils.js';
|
|
8
|
+
import { styles } from './nile-column-drilldown-chart.css.js';
|
|
9
|
+
let NileColumnDrilldownChart = class NileColumnDrilldownChart extends NileElement {
|
|
10
|
+
constructor() {
|
|
11
|
+
super(...arguments);
|
|
12
|
+
this._hc = null;
|
|
13
|
+
this.chart = null;
|
|
14
|
+
this.resizeObserver = null;
|
|
15
|
+
this.config = null;
|
|
16
|
+
this.chartTitle = '';
|
|
17
|
+
this.chartSubtitle = '';
|
|
18
|
+
this.data = [];
|
|
19
|
+
this.drilldownSeries = [];
|
|
20
|
+
this.seriesName = '';
|
|
21
|
+
this.yAxisTitle = '';
|
|
22
|
+
this.options = {};
|
|
23
|
+
this.loading = false;
|
|
24
|
+
this.height = '400px';
|
|
25
|
+
}
|
|
26
|
+
applyConfig(cfg) {
|
|
27
|
+
applySeparatedChartConfig(this, cfg);
|
|
28
|
+
}
|
|
29
|
+
connectedCallback() {
|
|
30
|
+
super.connectedCallback();
|
|
31
|
+
if (this.config)
|
|
32
|
+
this.applyConfig(this.config);
|
|
33
|
+
}
|
|
34
|
+
disconnectedCallback() {
|
|
35
|
+
super.disconnectedCallback();
|
|
36
|
+
this.destroyChart();
|
|
37
|
+
this.resizeObserver?.disconnect();
|
|
38
|
+
this.resizeObserver = null;
|
|
39
|
+
}
|
|
40
|
+
firstUpdated() {
|
|
41
|
+
this.initChart();
|
|
42
|
+
this.setupResizeObserver();
|
|
43
|
+
}
|
|
44
|
+
updated(changedProperties) {
|
|
45
|
+
if (changedProperties.has('config') && this.config) {
|
|
46
|
+
this.applyConfig(this.config);
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
const props = [
|
|
50
|
+
'data',
|
|
51
|
+
'drilldownSeries',
|
|
52
|
+
'seriesName',
|
|
53
|
+
'chartTitle',
|
|
54
|
+
'chartSubtitle',
|
|
55
|
+
'options',
|
|
56
|
+
'height',
|
|
57
|
+
'yAxisTitle',
|
|
58
|
+
'loading',
|
|
59
|
+
];
|
|
60
|
+
if (!props.some(p => changedProperties.has(p)))
|
|
61
|
+
return;
|
|
62
|
+
if (this.loading) {
|
|
63
|
+
this.destroyChart();
|
|
64
|
+
return;
|
|
65
|
+
}
|
|
66
|
+
if (this.chart) {
|
|
67
|
+
this.chart.update(this.buildOptions(), true, true);
|
|
68
|
+
}
|
|
69
|
+
else {
|
|
70
|
+
this.initChart();
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
setupResizeObserver() {
|
|
74
|
+
if (!this.chartContainer)
|
|
75
|
+
return;
|
|
76
|
+
this.resizeObserver = new ResizeObserver(() => this.chart?.reflow());
|
|
77
|
+
this.resizeObserver.observe(this.chartContainer);
|
|
78
|
+
}
|
|
79
|
+
buildOptions() {
|
|
80
|
+
const self = this;
|
|
81
|
+
const drilldown = {
|
|
82
|
+
series: this.drilldownSeries.map(ds => ({
|
|
83
|
+
type: 'column',
|
|
84
|
+
id: ds.id,
|
|
85
|
+
name: ds.name,
|
|
86
|
+
data: ds.data.map(d => ({ name: d.name, y: d.y })),
|
|
87
|
+
})),
|
|
88
|
+
};
|
|
89
|
+
return deepMerge({
|
|
90
|
+
chart: { type: 'column', height: this.height },
|
|
91
|
+
title: { text: this.chartTitle || undefined },
|
|
92
|
+
subtitle: { text: this.chartSubtitle || undefined },
|
|
93
|
+
xAxis: { type: 'category' },
|
|
94
|
+
yAxis: { title: { text: this.yAxisTitle || undefined }, allowDecimals: false },
|
|
95
|
+
legend: { enabled: false },
|
|
96
|
+
plotOptions: {
|
|
97
|
+
series: {
|
|
98
|
+
cursor: 'pointer',
|
|
99
|
+
borderWidth: 0,
|
|
100
|
+
dataLabels: { enabled: true },
|
|
101
|
+
point: {
|
|
102
|
+
events: {
|
|
103
|
+
click() {
|
|
104
|
+
self.emit('nile-chart-click', {
|
|
105
|
+
point: this,
|
|
106
|
+
category: this.category,
|
|
107
|
+
value: this.y,
|
|
108
|
+
seriesName: this.series.name,
|
|
109
|
+
drilldown: this.options.drilldown,
|
|
110
|
+
});
|
|
111
|
+
},
|
|
112
|
+
},
|
|
113
|
+
},
|
|
114
|
+
},
|
|
115
|
+
},
|
|
116
|
+
series: [
|
|
117
|
+
{
|
|
118
|
+
type: 'column',
|
|
119
|
+
name: this.seriesName || 'Series',
|
|
120
|
+
data: this.data.map(d => ({ name: d.name, y: d.y, drilldown: d.drilldown })),
|
|
121
|
+
},
|
|
122
|
+
],
|
|
123
|
+
drilldown,
|
|
124
|
+
credits: { enabled: false },
|
|
125
|
+
}, this.options);
|
|
126
|
+
}
|
|
127
|
+
async initChart() {
|
|
128
|
+
if (this.loading || !this.chartContainer)
|
|
129
|
+
return;
|
|
130
|
+
if (!this._hc)
|
|
131
|
+
this._hc = await getHighcharts();
|
|
132
|
+
this.chart = this._hc.chart(this.chartContainer, this.buildOptions());
|
|
133
|
+
this.emit('nile-chart-ready', { chart: this.chart });
|
|
134
|
+
}
|
|
135
|
+
destroyChart() {
|
|
136
|
+
if (this.chart) {
|
|
137
|
+
this.chart.destroy();
|
|
138
|
+
this.chart = null;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
render() {
|
|
142
|
+
if (this.loading) {
|
|
143
|
+
return html `<div class="chart-loading" style="height:${this.height}">Loading...</div>`;
|
|
144
|
+
}
|
|
145
|
+
return html `<div class="chart-container"></div>`;
|
|
146
|
+
}
|
|
147
|
+
};
|
|
148
|
+
NileColumnDrilldownChart.styles = styles;
|
|
149
|
+
__decorate([
|
|
150
|
+
query('.chart-container')
|
|
151
|
+
], NileColumnDrilldownChart.prototype, "chartContainer", void 0);
|
|
152
|
+
__decorate([
|
|
153
|
+
property({ type: Object })
|
|
154
|
+
], NileColumnDrilldownChart.prototype, "config", void 0);
|
|
155
|
+
__decorate([
|
|
156
|
+
property({ type: String, attribute: 'chart-title' })
|
|
157
|
+
], NileColumnDrilldownChart.prototype, "chartTitle", void 0);
|
|
158
|
+
__decorate([
|
|
159
|
+
property({ type: String, attribute: 'chart-subtitle' })
|
|
160
|
+
], NileColumnDrilldownChart.prototype, "chartSubtitle", void 0);
|
|
161
|
+
__decorate([
|
|
162
|
+
property({ type: Array })
|
|
163
|
+
], NileColumnDrilldownChart.prototype, "data", void 0);
|
|
164
|
+
__decorate([
|
|
165
|
+
property({ type: Array })
|
|
166
|
+
], NileColumnDrilldownChart.prototype, "drilldownSeries", void 0);
|
|
167
|
+
__decorate([
|
|
168
|
+
property({ type: String, attribute: 'series-name' })
|
|
169
|
+
], NileColumnDrilldownChart.prototype, "seriesName", void 0);
|
|
170
|
+
__decorate([
|
|
171
|
+
property({ type: String, attribute: 'y-axis-title' })
|
|
172
|
+
], NileColumnDrilldownChart.prototype, "yAxisTitle", void 0);
|
|
173
|
+
__decorate([
|
|
174
|
+
property({ type: Object })
|
|
175
|
+
], NileColumnDrilldownChart.prototype, "options", void 0);
|
|
176
|
+
__decorate([
|
|
177
|
+
property({ type: Boolean, reflect: true })
|
|
178
|
+
], NileColumnDrilldownChart.prototype, "loading", void 0);
|
|
179
|
+
__decorate([
|
|
180
|
+
property({ type: String })
|
|
181
|
+
], NileColumnDrilldownChart.prototype, "height", void 0);
|
|
182
|
+
NileColumnDrilldownChart = __decorate([
|
|
183
|
+
customElement('nile-column-drilldown-chart')
|
|
184
|
+
], NileColumnDrilldownChart);
|
|
185
|
+
export { NileColumnDrilldownChart };
|
|
186
|
+
//# sourceMappingURL=nile-column-drilldown-chart.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const styles: import("lit").CSSResult;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { css } from 'lit';
|
|
2
|
+
export const styles = css `
|
|
3
|
+
:host {
|
|
4
|
+
display: block;
|
|
5
|
+
width: 100%;
|
|
6
|
+
position: relative;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
:host([hidden]) {
|
|
10
|
+
display: none;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.chart-container {
|
|
14
|
+
width: 100%;
|
|
15
|
+
min-height: var(--nile-height-200px, var(--ng-height-200px));
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.chart-loading {
|
|
19
|
+
display: flex;
|
|
20
|
+
align-items: center;
|
|
21
|
+
justify-content: center;
|
|
22
|
+
min-height: inherit;
|
|
23
|
+
color: var(--nile-colors-neutral-700, var(--ng-colors-text-secondary-700));
|
|
24
|
+
font-family: var(--nile-font-family-serif, var(--ng-font-family-body));
|
|
25
|
+
font-size: var(--nile-type-scale-3, var(--ng-font-size-text-sm));
|
|
26
|
+
}
|
|
27
|
+
`;
|
|
28
|
+
//# sourceMappingURL=nile-column-pyramid-chart.css.js.map
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { CSSResultGroup, PropertyValues, TemplateResult } from 'lit';
|
|
2
|
+
import type Highcharts from 'highcharts';
|
|
3
|
+
import NileElement from '../internal/nile-element.js';
|
|
4
|
+
import type { SeparatedChartConfigInputType } from '../internal/types/separated-chart-config-input.type.js';
|
|
5
|
+
export interface ColumnPyramidSeriesData {
|
|
6
|
+
name: string;
|
|
7
|
+
data: number[];
|
|
8
|
+
color?: string;
|
|
9
|
+
}
|
|
10
|
+
export declare class NileColumnPyramidChart extends NileElement {
|
|
11
|
+
static styles: CSSResultGroup;
|
|
12
|
+
private _hc;
|
|
13
|
+
private chart;
|
|
14
|
+
private resizeObserver;
|
|
15
|
+
private chartContainer;
|
|
16
|
+
config: SeparatedChartConfigInputType | null;
|
|
17
|
+
chartTitle: string;
|
|
18
|
+
chartSubtitle: string;
|
|
19
|
+
data: ColumnPyramidSeriesData[];
|
|
20
|
+
categories: string[];
|
|
21
|
+
options: Highcharts.Options;
|
|
22
|
+
loading: boolean;
|
|
23
|
+
height: string;
|
|
24
|
+
private applyConfig;
|
|
25
|
+
connectedCallback(): void;
|
|
26
|
+
disconnectedCallback(): void;
|
|
27
|
+
protected firstUpdated(): void;
|
|
28
|
+
protected updated(changedProperties: PropertyValues): void;
|
|
29
|
+
private setupResizeObserver;
|
|
30
|
+
private buildOptions;
|
|
31
|
+
private initChart;
|
|
32
|
+
private destroyChart;
|
|
33
|
+
render(): TemplateResult;
|
|
34
|
+
}
|
|
35
|
+
declare global {
|
|
36
|
+
interface HTMLElementTagNameMap {
|
|
37
|
+
'nile-column-pyramid-chart': NileColumnPyramidChart;
|
|
38
|
+
}
|
|
39
|
+
}
|