@hisptz/dhis2-analytics 1.0.66 → 2.0.0-alpha.1
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/components/ChartAnalytics/ChartAnalytics.stories.js +254 -0
- package/dist/components/ChartAnalytics/ChartAnalytics.stories.js.map +1 -0
- package/dist/components/ChartAnalytics/DHIS2Chart.js +36 -0
- package/dist/components/ChartAnalytics/DHIS2Chart.js.map +1 -0
- package/dist/components/ChartAnalytics/components/DownloadMenu/components/Menu.js +52 -0
- package/dist/components/ChartAnalytics/components/DownloadMenu/components/Menu.js.map +1 -0
- package/dist/components/ChartAnalytics/components/DownloadMenu/constants/menu.js +42 -0
- package/dist/components/ChartAnalytics/components/DownloadMenu/constants/menu.js.map +1 -0
- package/dist/components/ChartAnalytics/components/DownloadMenu/index.js +65 -0
- package/dist/components/ChartAnalytics/components/DownloadMenu/index.js.map +1 -0
- package/dist/components/ChartAnalytics/components/DownloadMenu/interfaces/menu.js +3 -0
- package/dist/components/ChartAnalytics/components/DownloadMenu/interfaces/menu.js.map +1 -0
- package/dist/components/ChartAnalytics/hooks/useChart.js +43 -0
- package/dist/components/ChartAnalytics/hooks/useChart.js.map +1 -0
- package/dist/components/ChartAnalytics/index.js +3 -0
- package/dist/components/ChartAnalytics/index.js.map +1 -0
- package/dist/components/ChartAnalytics/models/bar.js +21 -0
- package/dist/components/ChartAnalytics/models/bar.js.map +1 -0
- package/{build/es → dist}/components/ChartAnalytics/models/column.js +12 -9
- package/dist/components/ChartAnalytics/models/column.js.map +1 -0
- package/dist/components/ChartAnalytics/models/index.js +114 -0
- package/dist/components/ChartAnalytics/models/index.js.map +1 -0
- package/{build/es → dist}/components/ChartAnalytics/models/line.js +10 -7
- package/dist/components/ChartAnalytics/models/line.js.map +1 -0
- package/dist/components/ChartAnalytics/models/multi-series.js +112 -0
- package/dist/components/ChartAnalytics/models/multi-series.js.map +1 -0
- package/dist/components/ChartAnalytics/models/pie.js +53 -0
- package/dist/components/ChartAnalytics/models/pie.js.map +1 -0
- package/dist/components/ChartAnalytics/services/export.js +35 -0
- package/dist/components/ChartAnalytics/services/export.js.map +1 -0
- package/dist/components/ChartAnalytics/styles/custom-highchart.css +40 -0
- package/dist/components/ChartAnalytics/styles/custom-highchart.css.map +1 -0
- package/dist/components/ChartAnalytics/types/props.js +3 -0
- package/dist/components/ChartAnalytics/types/props.js.map +1 -0
- package/dist/components/ChartAnalytics/utils/chart.js +130 -0
- package/dist/components/ChartAnalytics/utils/chart.js.map +1 -0
- package/dist/components/CircularProgressDashboard/CircularProgressIndicator.js +66 -0
- package/dist/components/CircularProgressDashboard/CircularProgressIndicator.js.map +1 -0
- package/dist/components/CircularProgressDashboard/CircularProgressIndicator.stories.js +42 -0
- package/dist/components/CircularProgressDashboard/CircularProgressIndicator.stories.js.map +1 -0
- package/dist/components/CircularProgressDashboard/index.js +4 -0
- package/dist/components/CircularProgressDashboard/index.js.map +1 -0
- package/dist/components/CircularProgressDashboard/types/props.js +3 -0
- package/dist/components/CircularProgressDashboard/types/props.js.map +1 -0
- package/dist/components/DHIS2PivotTable/DHIS2PivotTable.js +26 -0
- package/dist/components/DHIS2PivotTable/DHIS2PivotTable.js.map +1 -0
- package/dist/components/DHIS2PivotTable/DHIS2PivotTable.stories.js +30 -0
- package/dist/components/DHIS2PivotTable/DHIS2PivotTable.stories.js.map +1 -0
- package/dist/components/DHIS2PivotTable/components/Table/index.js +10 -0
- package/dist/components/DHIS2PivotTable/components/Table/index.js.map +1 -0
- package/dist/components/DHIS2PivotTable/components/TableBody/TableBody.module.css +11 -0
- package/dist/components/DHIS2PivotTable/components/TableBody/TableBody.module.css.map +1 -0
- package/dist/components/DHIS2PivotTable/components/TableBody/index.js +106 -0
- package/dist/components/DHIS2PivotTable/components/TableBody/index.js.map +1 -0
- package/dist/components/DHIS2PivotTable/components/TableHeaders/TableHeaders.module.css +10 -0
- package/dist/components/DHIS2PivotTable/components/TableHeaders/TableHeaders.module.css.map +1 -0
- package/dist/components/DHIS2PivotTable/components/TableHeaders/index.js +94 -0
- package/dist/components/DHIS2PivotTable/components/TableHeaders/index.js.map +1 -0
- package/dist/components/DHIS2PivotTable/index.js +4 -0
- package/dist/components/DHIS2PivotTable/index.js.map +1 -0
- package/dist/components/DHIS2PivotTable/interfaces/index.js +3 -0
- package/dist/components/DHIS2PivotTable/interfaces/index.js.map +1 -0
- package/dist/components/DHIS2PivotTable/services/engine.js +87 -0
- package/dist/components/DHIS2PivotTable/services/engine.js.map +1 -0
- package/dist/components/DHIS2PivotTable/state/engine.js +17 -0
- package/dist/components/DHIS2PivotTable/state/engine.js.map +1 -0
- package/dist/components/Map/DHIS2Map.js +65 -0
- package/dist/components/Map/DHIS2Map.js.map +1 -0
- package/dist/components/Map/DHIS2Map.stories.js +366 -0
- package/dist/components/Map/DHIS2Map.stories.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfigModal.js +41 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfigModal.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfigModal.stories.js +34 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfigModal.stories.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfiguration.js +26 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfiguration.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfiguration.stories.js +21 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfiguration.stories.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/AggregationSelector.js +67 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/AggregationSelector.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/ColorConfig.js +134 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/ColorConfig.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/Name.js +44 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/Name.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/PeriodSelector.js +67 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/PeriodSelector.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/StylesConfig.js +24 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/StylesConfig.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/TypeField.js +67 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/components/TypeField.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/hooks/data.js +45 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/hooks/data.js.map +1 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/index.js +4 -0
- package/dist/components/Map/components/EarthEngineLayerConfiguration/index.js.map +1 -0
- package/dist/components/Map/components/MapArea/index.js +100 -0
- package/dist/components/Map/components/MapArea/index.js.map +1 -0
- package/dist/components/Map/components/MapArea/interfaces/index.js +3 -0
- package/dist/components/Map/components/MapArea/interfaces/index.js.map +1 -0
- package/dist/components/Map/components/MapControls/components/CustomControl/index.js +16 -0
- package/dist/components/Map/components/MapControls/components/CustomControl/index.js.map +1 -0
- package/dist/components/Map/components/MapControls/components/DownloadControl/index.js +15 -0
- package/dist/components/Map/components/MapControls/components/DownloadControl/index.js.map +1 -0
- package/dist/components/Map/components/MapControls/components/FullscreenControl/index.js +13 -0
- package/dist/components/Map/components/MapControls/components/FullscreenControl/index.js.map +1 -0
- package/dist/components/Map/components/MapControls/index.js +35 -0
- package/dist/components/Map/components/MapControls/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/BoundaryLayer/hooks/useBoundaryData.js +10 -0
- package/dist/components/Map/components/MapLayer/components/BoundaryLayer/hooks/useBoundaryData.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/BoundaryLayer/index.js +52 -0
- package/dist/components/Map/components/MapLayer/components/BoundaryLayer/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/components/EarthEngineLegend.js +100 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/components/EarthEngineLegend.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/constants/index.js +457 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/constants/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/hooks/index.js +32 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/hooks/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/index.js +197 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/interfaces/index.js +3 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/interfaces/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/services/api.js +31466 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/services/api.js.map +1 -0
- package/{build/es → dist}/components/Map/components/MapLayer/components/GoogleEngineLayer/services/engine.js +106 -146
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/services/engine.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/utils/index.js +93 -0
- package/dist/components/Map/components/MapLayer/components/GoogleEngineLayer/utils/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/LegendArea/LegendArea.module.css +10 -0
- package/dist/components/Map/components/MapLayer/components/LegendArea/LegendArea.module.css.map +1 -0
- package/dist/components/Map/components/MapLayer/components/LegendArea/components/LegendCardHeader/index.js +17 -0
- package/dist/components/Map/components/MapLayer/components/LegendArea/components/LegendCardHeader/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/LegendArea/index.js +179 -0
- package/dist/components/Map/components/MapLayer/components/LegendArea/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/PointLayer/components/PointLegend/index.js +92 -0
- package/dist/components/Map/components/MapLayer/components/PointLayer/components/PointLegend/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/PointLayer/hooks/index.js +11 -0
- package/dist/components/Map/components/MapLayer/components/PointLayer/hooks/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/PointLayer/index.js +48 -0
- package/dist/components/Map/components/MapLayer/components/PointLayer/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubble.js +64 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubble.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubbles.js +130 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubbles.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/index.js +41 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/index.js +50 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/components/ChoroplethLegend.js +56 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/components/ChoroplethLegend.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/index.js +40 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/CustomTooltip/index.js +40 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/components/CustomTooltip/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/hooks/config.js +12 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/hooks/config.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/index.js +55 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/styles/legends.css +56 -0
- package/dist/components/Map/components/MapLayer/components/ThematicLayer/styles/legends.css.map +1 -0
- package/dist/components/Map/components/MapLayer/index.js +32 -0
- package/dist/components/Map/components/MapLayer/index.js.map +1 -0
- package/dist/components/Map/components/MapLayer/interfaces/index.js +10 -0
- package/dist/components/Map/components/MapLayer/interfaces/index.js.map +1 -0
- package/dist/components/Map/components/MapProvider/components/MapLayerProvider/hooks/index.js +405 -0
- package/dist/components/Map/components/MapProvider/components/MapLayerProvider/hooks/index.js.map +1 -0
- package/dist/components/Map/components/MapProvider/components/MapLayerProvider/index.js +115 -0
- package/dist/components/Map/components/MapProvider/components/MapLayerProvider/index.js.map +1 -0
- package/dist/components/Map/components/MapProvider/hooks/index.js +16 -0
- package/dist/components/Map/components/MapProvider/hooks/index.js.map +1 -0
- package/dist/components/Map/components/MapProvider/index.js +95 -0
- package/dist/components/Map/components/MapProvider/index.js.map +1 -0
- package/dist/components/Map/components/MapUpdater/index.js +11 -0
- package/dist/components/Map/components/MapUpdater/index.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfigModal.js +41 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfigModal.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfigModal.stories.js +24 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfigModal.stories.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfiguration.js +174 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfiguration.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfiguration.stories.js +21 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfiguration.stories.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/components/ColorScale/index.js +36 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/components/ColorScale/index.js.map +1 -0
- package/{build/es/components/Map → dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect}/constants/colors.js +18 -3
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/constants/colors.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/index.js +71 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/index.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/styles/ColorScale.module.css +15 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/styles/ColorScale.module.css.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/styles/ColorScaleSelect.module.css +12 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/styles/ColorScaleSelect.module.css.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/utils/colors.js +82 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/utils/colors.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/CustomLegend/index.js +57 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/CustomLegend/index.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/IndicatorSelectorModal/index.js +44 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/IndicatorSelectorModal/index.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/LegendSetSelector/index.js +60 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/LegendSetSelector/index.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/RadiusField.js +54 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/RadiusField.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/TypeField.js +63 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/components/TypeField.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/index.js +5 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/index.js.map +1 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/types/index.js +3 -0
- package/dist/components/Map/components/ThematicLayerConfiguration/types/index.js.map +1 -0
- package/{build/es/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect → dist/components/Map}/constants/colors.js +19 -3
- package/dist/components/Map/constants/colors.js.map +1 -0
- package/dist/components/Map/constants/legendSet.js +23 -0
- package/dist/components/Map/constants/legendSet.js.map +1 -0
- package/dist/components/Map/hooks/map.js +44 -0
- package/dist/components/Map/hooks/map.js.map +1 -0
- package/dist/components/Map/index.js +7 -0
- package/dist/components/Map/index.js.map +1 -0
- package/dist/components/Map/interfaces/index.js +3 -0
- package/dist/components/Map/interfaces/index.js.map +1 -0
- package/dist/components/Map/state/index.js +18 -0
- package/dist/components/Map/state/index.js.map +1 -0
- package/dist/components/Map/utils/colors.js +85 -0
- package/dist/components/Map/utils/colors.js.map +1 -0
- package/dist/components/Map/utils/helpers.js +18 -0
- package/dist/components/Map/utils/helpers.js.map +1 -0
- package/dist/components/Map/utils/map.js +138 -0
- package/dist/components/Map/utils/map.js.map +1 -0
- package/dist/components/SingleValueContainer/SingleValueContainer.stories.js +145 -0
- package/dist/components/SingleValueContainer/SingleValueContainer.stories.js.map +1 -0
- package/dist/components/SingleValueContainer/SingleValueVisualizer.js +44 -0
- package/dist/components/SingleValueContainer/SingleValueVisualizer.js.map +1 -0
- package/dist/components/SingleValueContainer/components/SingleValueItem/SingleValueItem.js +49 -0
- package/dist/components/SingleValueContainer/components/SingleValueItem/SingleValueItem.js.map +1 -0
- package/dist/components/SingleValueContainer/components/SingleValueItem/SingleValuePercentage.js +22 -0
- package/dist/components/SingleValueContainer/components/SingleValueItem/SingleValuePercentage.js.map +1 -0
- package/dist/components/SingleValueContainer/index.js +5 -0
- package/dist/components/SingleValueContainer/index.js.map +1 -0
- package/dist/components/SingleValueContainer/styles/SingleValueContainer.module.css +32 -0
- package/dist/components/SingleValueContainer/styles/SingleValueContainer.module.css.map +1 -0
- package/dist/components/SingleValueContainer/types/props.js +3 -0
- package/dist/components/SingleValueContainer/types/props.js.map +1 -0
- package/dist/components/Visualization/components/AnalyticsDataProvider/index.js +94 -0
- package/dist/components/Visualization/components/AnalyticsDataProvider/index.js.map +1 -0
- package/dist/components/Visualization/components/DimensionsProvider/index.js +35 -0
- package/dist/components/Visualization/components/DimensionsProvider/index.js.map +1 -0
- package/dist/components/Visualization/components/LayoutProvider/index.js +18 -0
- package/dist/components/Visualization/components/LayoutProvider/index.js.map +1 -0
- package/dist/components/Visualization/components/VisualizationDimensionSelector/index.js +85 -0
- package/dist/components/Visualization/components/VisualizationDimensionSelector/index.js.map +1 -0
- package/dist/components/Visualization/components/VisualizationProvider/index.js +19 -0
- package/dist/components/Visualization/components/VisualizationProvider/index.js.map +1 -0
- package/dist/components/Visualization/components/VisualizationSelector/index.js +167 -0
- package/dist/components/Visualization/components/VisualizationSelector/index.js.map +1 -0
- package/dist/components/Visualization/components/VisualizationTypeProvider/index.js +27 -0
- package/dist/components/Visualization/components/VisualizationTypeProvider/index.js.map +1 -0
- package/dist/components/Visualization/components/VisualizationTypeSelector/index.js +55 -0
- package/dist/components/Visualization/components/VisualizationTypeSelector/index.js.map +1 -0
- package/dist/components/Visualization/index.js +113 -0
- package/dist/components/Visualization/index.js.map +1 -0
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -0
- package/dist/types/components/ChartAnalytics/DHIS2Chart.d.ts +26 -0
- package/dist/types/components/ChartAnalytics/DHIS2Chart.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/components/DownloadMenu/components/Menu.d.ts +3 -3
- package/dist/types/components/ChartAnalytics/components/DownloadMenu/components/Menu.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/components/DownloadMenu/constants/menu.d.ts +1 -0
- package/dist/types/components/ChartAnalytics/components/DownloadMenu/constants/menu.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/components/DownloadMenu/index.d.ts +3 -2
- package/dist/types/components/ChartAnalytics/components/DownloadMenu/index.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/components/DownloadMenu/interfaces/menu.d.ts +1 -0
- package/dist/types/components/ChartAnalytics/components/DownloadMenu/interfaces/menu.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/hooks/useChart.d.ts +3 -2
- package/dist/types/components/ChartAnalytics/hooks/useChart.d.ts.map +1 -0
- package/dist/types/components/ChartAnalytics/index.d.ts +2 -0
- package/dist/types/components/ChartAnalytics/index.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/models/bar.d.ts +2 -1
- package/dist/types/components/ChartAnalytics/models/bar.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/models/column.d.ts +2 -1
- package/dist/types/components/ChartAnalytics/models/column.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/models/index.d.ts +2 -1
- package/dist/types/components/ChartAnalytics/models/index.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/models/line.d.ts +2 -1
- package/dist/types/components/ChartAnalytics/models/line.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/models/multi-series.d.ts +2 -1
- package/dist/types/components/ChartAnalytics/models/multi-series.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/models/pie.d.ts +2 -1
- package/dist/types/components/ChartAnalytics/models/pie.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/services/export.d.ts +1 -0
- package/dist/types/components/ChartAnalytics/services/export.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/types/props.d.ts +1 -0
- package/dist/types/components/ChartAnalytics/types/props.d.ts.map +1 -0
- package/{build → dist}/types/components/ChartAnalytics/utils/chart.d.ts +3 -2
- package/dist/types/components/ChartAnalytics/utils/chart.d.ts.map +1 -0
- package/dist/types/components/CircularProgressDashboard/CircularProgressIndicator.d.ts +6 -0
- package/dist/types/components/CircularProgressDashboard/CircularProgressIndicator.d.ts.map +1 -0
- package/dist/types/components/CircularProgressDashboard/index.d.ts +3 -0
- package/dist/types/components/CircularProgressDashboard/index.d.ts.map +1 -0
- package/{build → dist}/types/components/CircularProgressDashboard/types/props.d.ts +1 -0
- package/dist/types/components/CircularProgressDashboard/types/props.d.ts.map +1 -0
- package/{build/types/components/CustomPivotTable/index.d.ts → dist/types/components/DHIS2PivotTable/DHIS2PivotTable.d.ts} +8 -12
- package/dist/types/components/DHIS2PivotTable/DHIS2PivotTable.d.ts.map +1 -0
- package/dist/types/components/DHIS2PivotTable/components/Table/index.d.ts +9 -0
- package/dist/types/components/DHIS2PivotTable/components/Table/index.d.ts.map +1 -0
- package/dist/types/components/DHIS2PivotTable/components/TableBody/index.d.ts +2 -0
- package/dist/types/components/DHIS2PivotTable/components/TableBody/index.d.ts.map +1 -0
- package/dist/types/components/DHIS2PivotTable/components/TableHeaders/index.d.ts +2 -0
- package/dist/types/components/DHIS2PivotTable/components/TableHeaders/index.d.ts.map +1 -0
- package/dist/types/components/DHIS2PivotTable/index.d.ts +3 -0
- package/dist/types/components/DHIS2PivotTable/index.d.ts.map +1 -0
- package/{build/types/components/CustomPivotTable → dist/types/components/DHIS2PivotTable}/interfaces/index.d.ts +1 -0
- package/dist/types/components/DHIS2PivotTable/interfaces/index.d.ts.map +1 -0
- package/{build/types/components/CustomPivotTable → dist/types/components/DHIS2PivotTable}/services/engine.d.ts +4 -3
- package/dist/types/components/DHIS2PivotTable/services/engine.d.ts.map +1 -0
- package/dist/types/components/DHIS2PivotTable/state/engine.d.ts +8 -0
- package/dist/types/components/DHIS2PivotTable/state/engine.d.ts.map +1 -0
- package/dist/types/components/Map/DHIS2Map.d.ts +9 -0
- package/dist/types/components/Map/DHIS2Map.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfigModal.d.ts +10 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfigModal.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfiguration.d.ts +9 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfiguration.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/AggregationSelector.d.ts +2 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/AggregationSelector.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/ColorConfig.d.ts +2 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/ColorConfig.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/Name.d.ts +2 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/Name.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/PeriodSelector.d.ts +2 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/PeriodSelector.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/StylesConfig.d.ts +2 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/StylesConfig.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/TypeField.d.ts +4 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/components/TypeField.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/hooks/data.d.ts +8 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/hooks/data.d.ts.map +1 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/index.d.ts +3 -0
- package/dist/types/components/Map/components/EarthEngineLayerConfiguration/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapArea/index.d.ts +2 -1
- package/dist/types/components/Map/components/MapArea/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapArea/interfaces/index.d.ts +1 -0
- package/dist/types/components/Map/components/MapArea/interfaces/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapControls/components/CustomControl/index.d.ts +2 -1
- package/dist/types/components/Map/components/MapControls/components/CustomControl/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapControls/components/DownloadControl/index.d.ts +2 -2
- package/dist/types/components/Map/components/MapControls/components/DownloadControl/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapControls/components/FullscreenControl/index.d.ts +1 -0
- package/dist/types/components/Map/components/MapControls/components/FullscreenControl/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapControls/index.d.ts +6 -0
- package/dist/types/components/Map/components/MapControls/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapLayer/components/BoundaryLayer/hooks/useBoundaryData.d.ts +2 -0
- package/dist/types/components/Map/components/MapLayer/components/BoundaryLayer/hooks/useBoundaryData.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/BoundaryLayer/index.d.ts +6 -6
- package/dist/types/components/Map/components/MapLayer/components/BoundaryLayer/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/GoogleEngineLayer/components/EarthEngineLegend.d.ts +4 -3
- package/dist/types/components/Map/components/MapLayer/components/GoogleEngineLayer/components/EarthEngineLegend.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/GoogleEngineLayer/constants/index.d.ts +2 -1
- package/dist/types/components/Map/components/MapLayer/components/GoogleEngineLayer/constants/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/GoogleEngineLayer/hooks/index.d.ts +3 -2
- package/dist/types/components/Map/components/MapLayer/components/GoogleEngineLayer/hooks/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapLayer/components/GoogleEngineLayer/index.d.ts +4 -0
- package/dist/types/components/Map/components/MapLayer/components/GoogleEngineLayer/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/GoogleEngineLayer/interfaces/index.d.ts +2 -1
- package/dist/types/components/Map/components/MapLayer/components/GoogleEngineLayer/interfaces/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/GoogleEngineLayer/services/engine.d.ts +3 -2
- package/dist/types/components/Map/components/MapLayer/components/GoogleEngineLayer/services/engine.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/GoogleEngineLayer/utils/index.d.ts +3 -2
- package/dist/types/components/Map/components/MapLayer/components/GoogleEngineLayer/utils/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/LegendArea/components/LegendCardHeader/index.d.ts +3 -3
- package/dist/types/components/Map/components/MapLayer/components/LegendArea/components/LegendCardHeader/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/LegendArea/index.d.ts +4 -4
- package/dist/types/components/Map/components/MapLayer/components/LegendArea/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/PointLayer/components/PointLegend/index.d.ts +1 -0
- package/dist/types/components/Map/components/MapLayer/components/PointLayer/components/PointLegend/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapLayer/components/PointLayer/hooks/index.d.ts +3 -0
- package/dist/types/components/Map/components/MapLayer/components/PointLayer/hooks/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapLayer/components/PointLayer/index.d.ts +2 -0
- package/dist/types/components/Map/components/MapLayer/components/PointLayer/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubble.d.ts +2 -2
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubble.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubbles.d.ts +3 -2
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubbles.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/index.d.ts +2 -1
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/index.d.ts +3 -3
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/components/ChoroplethLegend.d.ts +4 -3
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/components/ChoroplethLegend.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/index.d.ts +12 -0
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/CustomTooltip/index.d.ts +5 -0
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/components/CustomTooltip/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/hooks/config.d.ts +3 -0
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/hooks/config.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/index.d.ts +5 -0
- package/dist/types/components/Map/components/MapLayer/components/ThematicLayer/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/index.d.ts +3 -3
- package/dist/types/components/Map/components/MapLayer/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapLayer/interfaces/index.d.ts +5 -4
- package/dist/types/components/Map/components/MapLayer/interfaces/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapProvider/components/MapLayerProvider/hooks/index.d.ts +1 -0
- package/dist/types/components/Map/components/MapProvider/components/MapLayerProvider/hooks/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapProvider/components/MapLayerProvider/index.d.ts +7 -0
- package/dist/types/components/Map/components/MapProvider/components/MapLayerProvider/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapProvider/hooks/index.d.ts +4 -3
- package/dist/types/components/Map/components/MapProvider/hooks/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/MapProvider/index.d.ts +3 -0
- package/dist/types/components/Map/components/MapProvider/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/MapUpdater/index.d.ts +2 -2
- package/dist/types/components/Map/components/MapUpdater/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfigModal.d.ts +3 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfigModal.d.ts.map +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfiguration.d.ts +3 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfiguration.d.ts.map +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/components/ColorScale/index.d.ts +8 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/components/ColorScale/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/constants/colors.d.ts +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/constants/colors.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/index.d.ts +2 -2
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/utils/colors.d.ts +2 -1
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/utils/colors.d.ts.map +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/CustomLegend/index.d.ts +2 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/CustomLegend/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/ThematicLayerConfiguration/components/IndicatorSelectorModal/index.d.ts +2 -2
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/IndicatorSelectorModal/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/components/ThematicLayerConfiguration/components/LegendSetSelector/index.d.ts +2 -2
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/LegendSetSelector/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/RadiusField.d.ts +2 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/RadiusField.d.ts.map +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/TypeField.d.ts +2 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/components/TypeField.d.ts.map +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/index.d.ts +4 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/index.d.ts.map +1 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/types/index.d.ts +15 -0
- package/dist/types/components/Map/components/ThematicLayerConfiguration/types/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/constants/colors.d.ts +1 -0
- package/dist/types/components/Map/constants/colors.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/constants/legendSet.d.ts +1 -0
- package/dist/types/components/Map/constants/legendSet.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/hooks/map.d.ts +1 -0
- package/dist/types/components/Map/hooks/map.d.ts.map +1 -0
- package/dist/types/components/Map/index.d.ts +6 -0
- package/dist/types/components/Map/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/interfaces/index.d.ts +3 -2
- package/dist/types/components/Map/interfaces/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/state/index.d.ts +3 -2
- package/dist/types/components/Map/state/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/utils/colors.d.ts +2 -1
- package/dist/types/components/Map/utils/colors.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/utils/helpers.d.ts +1 -0
- package/dist/types/components/Map/utils/helpers.d.ts.map +1 -0
- package/{build → dist}/types/components/Map/utils/map.d.ts +1 -0
- package/dist/types/components/Map/utils/map.d.ts.map +1 -0
- package/dist/types/components/SingleValueContainer/SingleValueVisualizer.d.ts +11 -0
- package/dist/types/components/SingleValueContainer/SingleValueVisualizer.d.ts.map +1 -0
- package/{build → dist}/types/components/SingleValueContainer/components/SingleValueItem/SingleValueItem.d.ts +2 -1
- package/dist/types/components/SingleValueContainer/components/SingleValueItem/SingleValueItem.d.ts.map +1 -0
- package/{build → dist}/types/components/SingleValueContainer/components/SingleValueItem/SingleValuePercentage.d.ts +2 -1
- package/dist/types/components/SingleValueContainer/components/SingleValueItem/SingleValuePercentage.d.ts.map +1 -0
- package/dist/types/components/SingleValueContainer/index.d.ts +4 -0
- package/dist/types/components/SingleValueContainer/index.d.ts.map +1 -0
- package/{build → dist}/types/components/SingleValueContainer/types/props.d.ts +3 -1
- package/dist/types/components/SingleValueContainer/types/props.d.ts.map +1 -0
- package/{build → dist}/types/components/Visualization/components/AnalyticsDataProvider/index.d.ts +2 -1
- package/dist/types/components/Visualization/components/AnalyticsDataProvider/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Visualization/components/DimensionsProvider/index.d.ts +2 -1
- package/dist/types/components/Visualization/components/DimensionsProvider/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Visualization/components/LayoutProvider/index.d.ts +3 -2
- package/dist/types/components/Visualization/components/LayoutProvider/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Visualization/components/VisualizationDimensionSelector/index.d.ts +3 -3
- package/dist/types/components/Visualization/components/VisualizationDimensionSelector/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Visualization/components/VisualizationProvider/index.d.ts +5 -4
- package/dist/types/components/Visualization/components/VisualizationProvider/index.d.ts.map +1 -0
- package/dist/types/components/Visualization/components/VisualizationSelector/index.d.ts +23 -0
- package/dist/types/components/Visualization/components/VisualizationSelector/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Visualization/components/VisualizationTypeProvider/index.d.ts +3 -2
- package/dist/types/components/Visualization/components/VisualizationTypeProvider/index.d.ts.map +1 -0
- package/dist/types/components/Visualization/components/VisualizationTypeSelector/index.d.ts +2 -0
- package/dist/types/components/Visualization/components/VisualizationTypeSelector/index.d.ts.map +1 -0
- package/{build → dist}/types/components/Visualization/index.d.ts +8 -8
- package/dist/types/components/Visualization/index.d.ts.map +1 -0
- package/dist/types/index.d.ts +7 -0
- package/dist/types/index.d.ts.map +1 -0
- package/package.json +59 -63
- package/README.md +0 -45
- package/build/cjs/components/ChartAnalytics/ChartAnalytics.test.js +0 -51
- package/build/cjs/components/ChartAnalytics/components/DownloadMenu/components/Menu.js +0 -48
- package/build/cjs/components/ChartAnalytics/components/DownloadMenu/constants/menu.js +0 -34
- package/build/cjs/components/ChartAnalytics/components/DownloadMenu/index.js +0 -65
- package/build/cjs/components/ChartAnalytics/components/DownloadMenu/interfaces/menu.js +0 -1
- package/build/cjs/components/ChartAnalytics/hooks/useChart.js +0 -38
- package/build/cjs/components/ChartAnalytics/index.js +0 -86
- package/build/cjs/components/ChartAnalytics/models/bar.js +0 -24
- package/build/cjs/components/ChartAnalytics/models/column.js +0 -53
- package/build/cjs/components/ChartAnalytics/models/index.js +0 -112
- package/build/cjs/components/ChartAnalytics/models/line.js +0 -35
- package/build/cjs/components/ChartAnalytics/models/multi-series.js +0 -111
- package/build/cjs/components/ChartAnalytics/models/pie.js +0 -53
- package/build/cjs/components/ChartAnalytics/services/export.js +0 -50
- package/build/cjs/components/ChartAnalytics/styles/custom-highchart.css +0 -48
- package/build/cjs/components/ChartAnalytics/types/props.js +0 -1
- package/build/cjs/components/ChartAnalytics/utils/chart.js +0 -138
- package/build/cjs/components/CircularProgressDashboard/CircularProgressIndicator.test.js +0 -13
- package/build/cjs/components/CircularProgressDashboard/index.js +0 -64
- package/build/cjs/components/CircularProgressDashboard/types/props.js +0 -1
- package/build/cjs/components/CustomPivotTable/components/Table/index.js +0 -16
- package/build/cjs/components/CustomPivotTable/components/TableBody/TableBody.module.css +0 -12
- package/build/cjs/components/CustomPivotTable/components/TableBody/index.js +0 -109
- package/build/cjs/components/CustomPivotTable/components/TableHeaders/TableHeaders.module.css +0 -10
- package/build/cjs/components/CustomPivotTable/components/TableHeaders/index.js +0 -89
- package/build/cjs/components/CustomPivotTable/index.js +0 -30
- package/build/cjs/components/CustomPivotTable/interfaces/index.js +0 -1
- package/build/cjs/components/CustomPivotTable/services/engine.js +0 -89
- package/build/cjs/components/CustomPivotTable/state/engine.js +0 -23
- package/build/cjs/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfigModal.stories.js +0 -32
- package/build/cjs/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfiguration.stories.js +0 -40
- package/build/cjs/components/Map/components/EarthEngineLayerConfiguration/index.js +0 -458
- package/build/cjs/components/Map/components/MapArea/index.js +0 -101
- package/build/cjs/components/Map/components/MapArea/interfaces/index.js +0 -1
- package/build/cjs/components/Map/components/MapControls/components/CustomControl/index.js +0 -32
- package/build/cjs/components/Map/components/MapControls/components/DownloadControl/index.js +0 -25
- package/build/cjs/components/Map/components/MapControls/components/FullscreenControl/index.js +0 -13
- package/build/cjs/components/Map/components/MapControls/index.js +0 -42
- package/build/cjs/components/Map/components/MapLayer/components/BoundaryLayer/hooks/useBoundaryData.js +0 -13
- package/build/cjs/components/Map/components/MapLayer/components/BoundaryLayer/index.js +0 -51
- package/build/cjs/components/Map/components/MapLayer/components/GoogleEngineLayer/components/EarthEngineLegend.js +0 -104
- package/build/cjs/components/Map/components/MapLayer/components/GoogleEngineLayer/constants/index.js +0 -379
- package/build/cjs/components/Map/components/MapLayer/components/GoogleEngineLayer/hooks/index.js +0 -36
- package/build/cjs/components/Map/components/MapLayer/components/GoogleEngineLayer/index.js +0 -200
- package/build/cjs/components/Map/components/MapLayer/components/GoogleEngineLayer/interfaces/index.js +0 -1
- package/build/cjs/components/Map/components/MapLayer/components/GoogleEngineLayer/services/api.js +0 -15
- package/build/cjs/components/Map/components/MapLayer/components/GoogleEngineLayer/services/engine.js +0 -403
- package/build/cjs/components/Map/components/MapLayer/components/GoogleEngineLayer/utils/index.js +0 -124
- package/build/cjs/components/Map/components/MapLayer/components/LegendArea/LegendArea.module.css +0 -12
- package/build/cjs/components/Map/components/MapLayer/components/LegendArea/components/LegendCardHeader/index.js +0 -26
- package/build/cjs/components/Map/components/MapLayer/components/LegendArea/index.js +0 -180
- package/build/cjs/components/Map/components/MapLayer/components/PointLayer/components/PointLegend/index.js +0 -86
- package/build/cjs/components/Map/components/MapLayer/components/PointLayer/hooks/index.js +0 -14
- package/build/cjs/components/Map/components/MapLayer/components/PointLayer/index.js +0 -46
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubble.js +0 -57
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubbles.js +0 -145
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/index.js +0 -43
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/index.js +0 -56
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/components/ChoroplethLegend.js +0 -61
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/index.js +0 -43
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/components/CustomTooltip/index.js +0 -35
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/hooks/config.js +0 -15
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/index.js +0 -57
- package/build/cjs/components/Map/components/MapLayer/components/ThematicLayer/styles/legends.css +0 -62
- package/build/cjs/components/Map/components/MapLayer/index.js +0 -40
- package/build/cjs/components/Map/components/MapLayer/interfaces/index.js +0 -8
- package/build/cjs/components/Map/components/MapProvider/components/MapLayerProvider/hooks/index.js +0 -399
- package/build/cjs/components/Map/components/MapProvider/components/MapLayerProvider/index.js +0 -116
- package/build/cjs/components/Map/components/MapProvider/hooks/index.js +0 -19
- package/build/cjs/components/Map/components/MapProvider/index.js +0 -121
- package/build/cjs/components/Map/components/MapUpdater/index.js +0 -24
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfigModal.stories.js +0 -32
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfiguration.stories.js +0 -40
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/components/ColorScale/index.js +0 -40
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/constants/colors.js +0 -428
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/index.js +0 -63
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/styles/ColorScale.module.css +0 -15
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/styles/ColorScaleSelect.module.css +0 -12
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/utils/colors.js +0 -72
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/CustomLegend/index.js +0 -71
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/IndicatorSelectorModal/index.js +0 -47
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/components/LegendSetSelector/index.js +0 -79
- package/build/cjs/components/Map/components/ThematicLayerConfiguration/index.js +0 -265
- package/build/cjs/components/Map/constants/colors.js +0 -429
- package/build/cjs/components/Map/constants/legendSet.js +0 -22
- package/build/cjs/components/Map/hooks/map.js +0 -52
- package/build/cjs/components/Map/index.js +0 -108
- package/build/cjs/components/Map/interfaces/index.js +0 -1
- package/build/cjs/components/Map/state/index.js +0 -23
- package/build/cjs/components/Map/utils/colors.js +0 -78
- package/build/cjs/components/Map/utils/helpers.js +0 -25
- package/build/cjs/components/Map/utils/map.js +0 -161
- package/build/cjs/components/SingleValueContainer/SingleValueContainer.test.js +0 -23
- package/build/cjs/components/SingleValueContainer/components/SingleValueItem/SingleValueItem.js +0 -54
- package/build/cjs/components/SingleValueContainer/components/SingleValueItem/SingleValuePercentage.js +0 -24
- package/build/cjs/components/SingleValueContainer/index.js +0 -59
- package/build/cjs/components/SingleValueContainer/styles/SingleValueContainer.module.css +0 -39
- package/build/cjs/components/SingleValueContainer/types/props.js +0 -1
- package/build/cjs/components/Visualization/components/AnalyticsDataProvider/index.js +0 -102
- package/build/cjs/components/Visualization/components/DimensionsProvider/index.js +0 -56
- package/build/cjs/components/Visualization/components/LayoutProvider/index.js +0 -31
- package/build/cjs/components/Visualization/components/VisualizationDimensionSelector/index.js +0 -77
- package/build/cjs/components/Visualization/components/VisualizationProvider/index.js +0 -29
- package/build/cjs/components/Visualization/components/VisualizationSelector/index.js +0 -180
- package/build/cjs/components/Visualization/components/VisualizationTypeProvider/index.js +0 -40
- package/build/cjs/components/Visualization/components/VisualizationTypeSelector/index.js +0 -54
- package/build/cjs/components/Visualization/index.js +0 -96
- package/build/cjs/index.js +0 -71
- package/build/cjs/locales/en/translations.json +0 -138
- package/build/cjs/locales/index.js +0 -22
- package/build/es/components/ChartAnalytics/ChartAnalytics.test.js +0 -46
- package/build/es/components/ChartAnalytics/components/DownloadMenu/components/Menu.js +0 -41
- package/build/es/components/ChartAnalytics/components/DownloadMenu/constants/menu.js +0 -26
- package/build/es/components/ChartAnalytics/components/DownloadMenu/index.js +0 -57
- package/build/es/components/ChartAnalytics/components/DownloadMenu/interfaces/menu.js +0 -1
- package/build/es/components/ChartAnalytics/hooks/useChart.js +0 -32
- package/build/es/components/ChartAnalytics/index.js +0 -40
- package/build/es/components/ChartAnalytics/models/bar.js +0 -16
- package/build/es/components/ChartAnalytics/models/index.js +0 -105
- package/build/es/components/ChartAnalytics/models/multi-series.js +0 -104
- package/build/es/components/ChartAnalytics/models/pie.js +0 -46
- package/build/es/components/ChartAnalytics/services/export.js +0 -36
- package/build/es/components/ChartAnalytics/styles/custom-highchart.css +0 -48
- package/build/es/components/ChartAnalytics/types/props.js +0 -1
- package/build/es/components/ChartAnalytics/utils/chart.js +0 -127
- package/build/es/components/CircularProgressDashboard/CircularProgressIndicator.test.js +0 -10
- package/build/es/components/CircularProgressDashboard/index.js +0 -42
- package/build/es/components/CircularProgressDashboard/types/props.js +0 -1
- package/build/es/components/CustomPivotTable/components/Table/index.js +0 -9
- package/build/es/components/CustomPivotTable/components/TableBody/TableBody.module.css +0 -12
- package/build/es/components/CustomPivotTable/components/TableBody/index.js +0 -100
- package/build/es/components/CustomPivotTable/components/TableHeaders/TableHeaders.module.css +0 -10
- package/build/es/components/CustomPivotTable/components/TableHeaders/index.js +0 -82
- package/build/es/components/CustomPivotTable/index.js +0 -22
- package/build/es/components/CustomPivotTable/interfaces/index.js +0 -1
- package/build/es/components/CustomPivotTable/services/engine.js +0 -82
- package/build/es/components/CustomPivotTable/state/engine.js +0 -14
- package/build/es/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfigModal.stories.js +0 -23
- package/build/es/components/Map/components/EarthEngineLayerConfiguration/EarthEngineLayerConfiguration.stories.js +0 -31
- package/build/es/components/Map/components/EarthEngineLayerConfiguration/index.js +0 -448
- package/build/es/components/Map/components/MapArea/index.js +0 -91
- package/build/es/components/Map/components/MapArea/interfaces/index.js +0 -1
- package/build/es/components/Map/components/MapControls/components/CustomControl/index.js +0 -25
- package/build/es/components/Map/components/MapControls/components/DownloadControl/index.js +0 -18
- package/build/es/components/Map/components/MapControls/components/FullscreenControl/index.js +0 -6
- package/build/es/components/Map/components/MapControls/index.js +0 -35
- package/build/es/components/Map/components/MapLayer/components/BoundaryLayer/hooks/useBoundaryData.js +0 -7
- package/build/es/components/Map/components/MapLayer/components/BoundaryLayer/index.js +0 -41
- package/build/es/components/Map/components/MapLayer/components/GoogleEngineLayer/components/EarthEngineLegend.js +0 -93
- package/build/es/components/Map/components/MapLayer/components/GoogleEngineLayer/constants/index.js +0 -369
- package/build/es/components/Map/components/MapLayer/components/GoogleEngineLayer/hooks/index.js +0 -29
- package/build/es/components/Map/components/MapLayer/components/GoogleEngineLayer/index.js +0 -191
- package/build/es/components/Map/components/MapLayer/components/GoogleEngineLayer/interfaces/index.js +0 -1
- package/build/es/components/Map/components/MapLayer/components/GoogleEngineLayer/services/api.js +0 -15
- package/build/es/components/Map/components/MapLayer/components/GoogleEngineLayer/utils/index.js +0 -111
- package/build/es/components/Map/components/MapLayer/components/LegendArea/LegendArea.module.css +0 -12
- package/build/es/components/Map/components/MapLayer/components/LegendArea/components/LegendCardHeader/index.js +0 -19
- package/build/es/components/Map/components/MapLayer/components/LegendArea/index.js +0 -171
- package/build/es/components/Map/components/MapLayer/components/PointLayer/components/PointLegend/index.js +0 -76
- package/build/es/components/Map/components/MapLayer/components/PointLayer/hooks/index.js +0 -8
- package/build/es/components/Map/components/MapLayer/components/PointLayer/index.js +0 -39
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubble.js +0 -49
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/components/Bubbles.js +0 -133
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/components/BubbleLegend/index.js +0 -33
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/components/Bubble/index.js +0 -47
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/components/ChoroplethLegend.js +0 -50
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/index.js +0 -36
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/components/CustomTooltip/index.js +0 -28
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/hooks/config.js +0 -9
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/index.js +0 -50
- package/build/es/components/Map/components/MapLayer/components/ThematicLayer/styles/legends.css +0 -62
- package/build/es/components/Map/components/MapLayer/index.js +0 -33
- package/build/es/components/Map/components/MapLayer/interfaces/index.js +0 -1
- package/build/es/components/Map/components/MapProvider/components/MapLayerProvider/hooks/index.js +0 -391
- package/build/es/components/Map/components/MapProvider/components/MapLayerProvider/index.js +0 -107
- package/build/es/components/Map/components/MapProvider/hooks/index.js +0 -11
- package/build/es/components/Map/components/MapProvider/index.js +0 -112
- package/build/es/components/Map/components/MapUpdater/index.js +0 -17
- package/build/es/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfigModal.stories.js +0 -23
- package/build/es/components/Map/components/ThematicLayerConfiguration/ThematicLayerConfiguration.stories.js +0 -31
- package/build/es/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/components/ColorScale/index.js +0 -33
- package/build/es/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/index.js +0 -53
- package/build/es/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/styles/ColorScale.module.css +0 -15
- package/build/es/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/styles/ColorScaleSelect.module.css +0 -12
- package/build/es/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/utils/colors.js +0 -56
- package/build/es/components/Map/components/ThematicLayerConfiguration/components/CustomLegend/index.js +0 -64
- package/build/es/components/Map/components/ThematicLayerConfiguration/components/IndicatorSelectorModal/index.js +0 -38
- package/build/es/components/Map/components/ThematicLayerConfiguration/components/LegendSetSelector/index.js +0 -70
- package/build/es/components/Map/components/ThematicLayerConfiguration/index.js +0 -254
- package/build/es/components/Map/constants/legendSet.js +0 -15
- package/build/es/components/Map/hooks/map.js +0 -44
- package/build/es/components/Map/index.js +0 -51
- package/build/es/components/Map/interfaces/index.js +0 -1
- package/build/es/components/Map/state/index.js +0 -14
- package/build/es/components/Map/utils/colors.js +0 -61
- package/build/es/components/Map/utils/helpers.js +0 -14
- package/build/es/components/Map/utils/map.js +0 -147
- package/build/es/components/SingleValueContainer/SingleValueContainer.test.js +0 -20
- package/build/es/components/SingleValueContainer/components/SingleValueItem/SingleValueItem.js +0 -47
- package/build/es/components/SingleValueContainer/components/SingleValueItem/SingleValuePercentage.js +0 -17
- package/build/es/components/SingleValueContainer/index.js +0 -30
- package/build/es/components/SingleValueContainer/styles/SingleValueContainer.module.css +0 -39
- package/build/es/components/SingleValueContainer/types/props.js +0 -1
- package/build/es/components/Visualization/components/AnalyticsDataProvider/index.js +0 -93
- package/build/es/components/Visualization/components/DimensionsProvider/index.js +0 -44
- package/build/es/components/Visualization/components/LayoutProvider/index.js +0 -20
- package/build/es/components/Visualization/components/VisualizationDimensionSelector/index.js +0 -68
- package/build/es/components/Visualization/components/VisualizationProvider/index.js +0 -22
- package/build/es/components/Visualization/components/VisualizationSelector/index.js +0 -166
- package/build/es/components/Visualization/components/VisualizationTypeProvider/index.js +0 -25
- package/build/es/components/Visualization/components/VisualizationTypeSelector/index.js +0 -45
- package/build/es/components/Visualization/index.js +0 -89
- package/build/es/index.js +0 -7
- package/build/es/locales/en/translations.json +0 -138
- package/build/es/locales/index.js +0 -13
- package/build/types/components/ChartAnalytics/index.d.ts +0 -7
- package/build/types/components/CircularProgressDashboard/index.d.ts +0 -4
- package/build/types/components/CustomPivotTable/components/Table/index.d.ts +0 -12
- package/build/types/components/CustomPivotTable/components/TableBody/index.d.ts +0 -2
- package/build/types/components/CustomPivotTable/components/TableHeaders/index.d.ts +0 -2
- package/build/types/components/CustomPivotTable/state/engine.d.ts +0 -7
- package/build/types/components/Map/components/EarthEngineLayerConfiguration/index.d.ts +0 -17
- package/build/types/components/Map/components/MapControls/index.d.ts +0 -6
- package/build/types/components/Map/components/MapLayer/components/BoundaryLayer/hooks/useBoundaryData.d.ts +0 -1
- package/build/types/components/Map/components/MapLayer/components/GoogleEngineLayer/index.d.ts +0 -4
- package/build/types/components/Map/components/MapLayer/components/PointLayer/hooks/index.d.ts +0 -2
- package/build/types/components/Map/components/MapLayer/components/PointLayer/index.d.ts +0 -2
- package/build/types/components/Map/components/MapLayer/components/ThematicLayer/components/Choropleth/index.d.ts +0 -12
- package/build/types/components/Map/components/MapLayer/components/ThematicLayer/components/CustomTooltip/index.d.ts +0 -5
- package/build/types/components/Map/components/MapLayer/components/ThematicLayer/hooks/config.d.ts +0 -2
- package/build/types/components/Map/components/MapLayer/components/ThematicLayer/index.d.ts +0 -5
- package/build/types/components/Map/components/MapProvider/components/MapLayerProvider/index.d.ts +0 -6
- package/build/types/components/Map/components/MapProvider/index.d.ts +0 -3
- package/build/types/components/Map/components/ThematicLayerConfiguration/components/ColorScaleSelect/components/ColorScale/index.d.ts +0 -8
- package/build/types/components/Map/components/ThematicLayerConfiguration/components/CustomLegend/index.d.ts +0 -2
- package/build/types/components/Map/components/ThematicLayerConfiguration/index.d.ts +0 -18
- package/build/types/components/Map/index.d.ts +0 -8
- package/build/types/components/SingleValueContainer/index.d.ts +0 -6
- package/build/types/components/Visualization/components/VisualizationSelector/index.d.ts +0 -23
- package/build/types/components/Visualization/components/VisualizationTypeSelector/index.d.ts +0 -2
- package/build/types/index.d.ts +0 -6
- /package/{LICENSE → LICENCE} +0 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { createContext, useContext, useState } from 'react';
|
|
3
|
+
|
|
4
|
+
const LayoutState = createContext(void 0);
|
|
5
|
+
function useLayout() {
|
|
6
|
+
return [useContext(LayoutState) ?? { rows: [], filters: [], columns: [] }];
|
|
7
|
+
}
|
|
8
|
+
function LayoutProvider({
|
|
9
|
+
defaultLayout,
|
|
10
|
+
children
|
|
11
|
+
}) {
|
|
12
|
+
const [layout, setLayout] = useState(defaultLayout);
|
|
13
|
+
return /* @__PURE__ */ jsx(LayoutState.Provider, { value: layout, children });
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export { LayoutProvider, LayoutState, useLayout };
|
|
17
|
+
//# sourceMappingURL=out.js.map
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../src/components/Visualization/components/LayoutProvider/index.tsx"],"names":[],"mappings":"AA2BE;AA3BF,SAAgB,eAAe,YAAY,gBAAgB;AAcpD,MAAM,cAAc,cAAkC,MAAS;AAE/D,SAAS,YAAY;AAC3B,SAAO,CAAC,WAAW,WAAW,KAAK,EAAE,MAAM,CAAC,GAAG,SAAS,CAAC,GAAG,SAAS,CAAC,EAAE,CAAC;AAC1E;AAEO,SAAS,eAAe;AAAA,EAC9B;AAAA,EACA;AACD,GAAwB;AACvB,QAAM,CAAC,QAAQ,SAAS,IAAI,SAAS,aAAa;AAElD,SACC,oBAAC,YAAY,UAAZ,EAAqB,OAAO,QAAS,UAAS;AAEjD","sourcesContent":["import React, { createContext, useContext, useState } from \"react\";\nimport { Dimension } from \"../DimensionsProvider/index.js\";\n\nexport interface Layout {\n\trows: Dimension[];\n\tcolumns: Dimension[];\n\tfilters: Dimension[];\n}\n\nexport interface LayoutProviderProps {\n\tchildren: React.ReactNode;\n\tdefaultLayout: Layout;\n}\n\nexport const LayoutState = createContext<Layout | undefined>(undefined);\n\nexport function useLayout() {\n\treturn [useContext(LayoutState) ?? { rows: [], filters: [], columns: [] }];\n}\n\nexport function LayoutProvider({\n\tdefaultLayout,\n\tchildren,\n}: LayoutProviderProps) {\n\tconst [layout, setLayout] = useState(defaultLayout);\n\n\treturn (\n\t\t<LayoutState.Provider value={layout}>{children}</LayoutState.Provider>\n\t);\n}\n"]}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
2
|
+
import { useMemo, useState, useCallback } from 'react';
|
|
3
|
+
import { Tooltip, Button, IconClock24, IconLocation24 } from '@dhis2/ui';
|
|
4
|
+
import i18n from '@dhis2/d2-i18n';
|
|
5
|
+
import { useDimensions } from '../DimensionsProvider/index.js';
|
|
6
|
+
import { PeriodSelectorModal, OrgUnitSelectorModal } from '@hisptz/dhis2-ui';
|
|
7
|
+
import { getOrgUnitSelectionFromIds } from '../VisualizationSelector/index.js';
|
|
8
|
+
import { getOrgUnitsSelection } from '../../../Map/utils/map.js';
|
|
9
|
+
|
|
10
|
+
function VisualizationDimensionSelector({
|
|
11
|
+
showPeriodSelector,
|
|
12
|
+
showOrgUnitSelector
|
|
13
|
+
}) {
|
|
14
|
+
const [dimensions, setDimensions] = useDimensions();
|
|
15
|
+
const periods = useMemo(() => dimensions.pe, [dimensions.pe]);
|
|
16
|
+
const orgUnitSelection = useMemo(
|
|
17
|
+
() => getOrgUnitSelectionFromIds(dimensions.ou ?? []),
|
|
18
|
+
[dimensions.ou]
|
|
19
|
+
);
|
|
20
|
+
const [openFilter, setOpenFilter] = useState();
|
|
21
|
+
const onFilterUpdate = useCallback(
|
|
22
|
+
(type) => (data) => {
|
|
23
|
+
setOpenFilter(void 0);
|
|
24
|
+
if (type === "ou") {
|
|
25
|
+
setDimensions({
|
|
26
|
+
dimension: "ou",
|
|
27
|
+
value: getOrgUnitsSelection(data)
|
|
28
|
+
});
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
if (type === "pe") {
|
|
32
|
+
setDimensions({ dimension: "pe", value: data });
|
|
33
|
+
return;
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
[setDimensions]
|
|
37
|
+
);
|
|
38
|
+
return /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsxs("div", { style: { display: "flex", gap: 8 }, children: [
|
|
39
|
+
showPeriodSelector && /* @__PURE__ */ jsx(Tooltip, { content: i18n.t("Period"), children: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
40
|
+
/* @__PURE__ */ jsx(
|
|
41
|
+
PeriodSelectorModal,
|
|
42
|
+
{
|
|
43
|
+
position: "middle",
|
|
44
|
+
enablePeriodSelector: true,
|
|
45
|
+
selectedPeriods: periods,
|
|
46
|
+
onClose: () => setOpenFilter(void 0),
|
|
47
|
+
hide: openFilter !== "pe",
|
|
48
|
+
onUpdate: onFilterUpdate("pe")
|
|
49
|
+
}
|
|
50
|
+
),
|
|
51
|
+
/* @__PURE__ */ jsx(
|
|
52
|
+
Button,
|
|
53
|
+
{
|
|
54
|
+
onClick: () => setOpenFilter("pe"),
|
|
55
|
+
icon: /* @__PURE__ */ jsx(IconClock24, {})
|
|
56
|
+
}
|
|
57
|
+
)
|
|
58
|
+
] }) }),
|
|
59
|
+
showOrgUnitSelector && /* @__PURE__ */ jsx(Tooltip, { content: i18n.t("Location"), children: /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
60
|
+
/* @__PURE__ */ jsx(
|
|
61
|
+
OrgUnitSelectorModal,
|
|
62
|
+
{
|
|
63
|
+
showUserOptions: true,
|
|
64
|
+
searchable: true,
|
|
65
|
+
title: i18n.t("Select location(s)"),
|
|
66
|
+
value: orgUnitSelection,
|
|
67
|
+
onClose: () => setOpenFilter(void 0),
|
|
68
|
+
hide: openFilter !== "ou",
|
|
69
|
+
onUpdate: onFilterUpdate("ou")
|
|
70
|
+
}
|
|
71
|
+
),
|
|
72
|
+
/* @__PURE__ */ jsx(
|
|
73
|
+
Button,
|
|
74
|
+
{
|
|
75
|
+
onClick: () => setOpenFilter("ou"),
|
|
76
|
+
icon: /* @__PURE__ */ jsx(IconLocation24, {})
|
|
77
|
+
}
|
|
78
|
+
)
|
|
79
|
+
] }) })
|
|
80
|
+
] }) });
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export { VisualizationDimensionSelector };
|
|
84
|
+
//# sourceMappingURL=out.js.map
|
|
85
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../src/components/Visualization/components/VisualizationDimensionSelector/index.tsx"],"names":[],"mappings":"AA+CM,mBACC,KADD;AA/CN,SAAgB,aAAa,SAAS,gBAAgB;AACtD,SAAS,QAAQ,aAAa,gBAAgB,eAAe;AAC7D,OAAO,UAAU;AACjB,SAAS,qBAAqB;AAC9B,SAAS,sBAAsB,2BAA2B;AAE1D,SAAS,kCAAkC;AAC3C,SAAS,4BAA4B;AAE9B,SAAS,+BAA+B;AAAA,EAC9C;AAAA,EACA;AACD,GAGG;AACF,QAAM,CAAC,YAAY,aAAa,IAAI,cAAc;AAClD,QAAM,UAAU,QAAQ,MAAM,WAAW,IAAI,CAAC,WAAW,EAAE,CAAC;AAC5D,QAAM,mBAAmB;AAAA,IACxB,MAAM,2BAA2B,WAAW,MAAM,CAAC,CAAC;AAAA,IACpD,CAAC,WAAW,EAAE;AAAA,EACf;AACA,QAAM,CAAC,YAAY,aAAa,IAAI,SAAkC;AAEtE,QAAM,iBAAiB;AAAA,IACtB,CAAC,SAAsB,CAAC,SAAiC;AACxD,oBAAc,MAAS;AACvB,UAAI,SAAS,MAAM;AAClB,sBAAc;AAAA,UACb,WAAW;AAAA,UACX,OAAO,qBAAqB,IAAI;AAAA,QACjC,CAAC;AACD;AAAA,MACD;AACA,UAAI,SAAS,MAAM;AAClB,sBAAc,EAAE,WAAW,MAAM,OAAO,KAAK,CAAC;AAC9C;AAAA,MACD;AAAA,IACD;AAAA,IACA,CAAC,aAAa;AAAA,EACf;AAEA,SACC,gCACC,+BAAC,SAAI,OAAO,EAAE,SAAS,QAAQ,KAAK,EAAE,GACpC;AAAA,0BACA,oBAAC,WAAQ,SAAS,KAAK,EAAE,QAAQ,GAChC,2CACC;AAAA;AAAA,QAAC;AAAA;AAAA,UACA,UAAS;AAAA,UACT,sBAAoB;AAAA,UACpB,iBAAiB;AAAA,UACjB,SAAS,MAAM,cAAc,MAAS;AAAA,UACtC,MAAM,eAAe;AAAA,UACrB,UAAU,eAAe,IAAI;AAAA;AAAA,MAC9B;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACA,SAAS,MAAM,cAAc,IAAI;AAAA,UACjC,MAAM,oBAAC,eAAY;AAAA;AAAA,MACpB;AAAA,OACD,GACD;AAAA,IAEA,uBACA,oBAAC,WAAQ,SAAS,KAAK,EAAE,UAAU,GAClC,2CACC;AAAA;AAAA,QAAC;AAAA;AAAA,UACA,iBAAe;AAAA,UACf,YAAU;AAAA,UACV,OAAO,KAAK,EAAE,oBAAoB;AAAA,UAClC,OAAO;AAAA,UACP,SAAS,MAAM,cAAc,MAAS;AAAA,UACtC,MAAM,eAAe;AAAA,UACrB,UAAU,eAAe,IAAI;AAAA;AAAA,MAC9B;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACA,SAAS,MAAM,cAAc,IAAI;AAAA,UACjC,MAAM,oBAAC,kBAAe;AAAA;AAAA,MACvB;AAAA,OACD,GACD;AAAA,KAEF,GACD;AAEF","sourcesContent":["import React, { useCallback, useMemo, useState } from \"react\";\nimport { Button, IconClock24, IconLocation24, Tooltip } from \"@dhis2/ui\";\nimport i18n from \"@dhis2/d2-i18n\";\nimport { useDimensions } from \"../DimensionsProvider/index.js\";\nimport { OrgUnitSelectorModal, PeriodSelectorModal } from \"@hisptz/dhis2-ui\";\nimport { OrgUnitSelection } from \"@hisptz/dhis2-utils\";\nimport { getOrgUnitSelectionFromIds } from \"../VisualizationSelector/index.js\";\nimport { getOrgUnitsSelection } from \"../../../Map/utils/map.js\";\n\nexport function VisualizationDimensionSelector({\n\tshowPeriodSelector,\n\tshowOrgUnitSelector,\n}: {\n\tshowPeriodSelector?: boolean;\n\tshowOrgUnitSelector?: boolean;\n}) {\n\tconst [dimensions, setDimensions] = useDimensions();\n\tconst periods = useMemo(() => dimensions.pe, [dimensions.pe]);\n\tconst orgUnitSelection = useMemo(\n\t\t() => getOrgUnitSelectionFromIds(dimensions.ou ?? []),\n\t\t[dimensions.ou],\n\t);\n\tconst [openFilter, setOpenFilter] = useState<\"pe\" | \"ou\" | undefined>();\n\n\tconst onFilterUpdate = useCallback(\n\t\t(type: \"ou\" | \"pe\") => (data: OrgUnitSelection | any) => {\n\t\t\tsetOpenFilter(undefined);\n\t\t\tif (type === \"ou\") {\n\t\t\t\tsetDimensions({\n\t\t\t\t\tdimension: \"ou\",\n\t\t\t\t\tvalue: getOrgUnitsSelection(data),\n\t\t\t\t});\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (type === \"pe\") {\n\t\t\t\tsetDimensions({ dimension: \"pe\", value: data });\n\t\t\t\treturn;\n\t\t\t}\n\t\t},\n\t\t[setDimensions],\n\t);\n\n\treturn (\n\t\t<>\n\t\t\t<div style={{ display: \"flex\", gap: 8 }}>\n\t\t\t\t{showPeriodSelector && (\n\t\t\t\t\t<Tooltip content={i18n.t(\"Period\")}>\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t<PeriodSelectorModal\n\t\t\t\t\t\t\t\tposition=\"middle\"\n\t\t\t\t\t\t\t\tenablePeriodSelector\n\t\t\t\t\t\t\t\tselectedPeriods={periods}\n\t\t\t\t\t\t\t\tonClose={() => setOpenFilter(undefined)}\n\t\t\t\t\t\t\t\thide={openFilter !== \"pe\"}\n\t\t\t\t\t\t\t\tonUpdate={onFilterUpdate(\"pe\")}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\tonClick={() => setOpenFilter(\"pe\")}\n\t\t\t\t\t\t\t\ticon={<IconClock24 />}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</>\n\t\t\t\t\t</Tooltip>\n\t\t\t\t)}\n\t\t\t\t{showOrgUnitSelector && (\n\t\t\t\t\t<Tooltip content={i18n.t(\"Location\")}>\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t<OrgUnitSelectorModal\n\t\t\t\t\t\t\t\tshowUserOptions\n\t\t\t\t\t\t\t\tsearchable\n\t\t\t\t\t\t\t\ttitle={i18n.t(\"Select location(s)\")}\n\t\t\t\t\t\t\t\tvalue={orgUnitSelection}\n\t\t\t\t\t\t\t\tonClose={() => setOpenFilter(undefined)}\n\t\t\t\t\t\t\t\thide={openFilter !== \"ou\"}\n\t\t\t\t\t\t\t\tonUpdate={onFilterUpdate(\"ou\")}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\tonClick={() => setOpenFilter(\"ou\")}\n\t\t\t\t\t\t\t\ticon={<IconLocation24 />}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</>\n\t\t\t\t\t</Tooltip>\n\t\t\t\t)}\n\t\t\t</div>\n\t\t</>\n\t);\n}\n"]}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { LayoutProvider } from '../LayoutProvider/index.js';
|
|
3
|
+
import { DimensionsProvider } from '../DimensionsProvider/index.js';
|
|
4
|
+
import { AnalyticsDataProvider } from '../AnalyticsDataProvider/index.js';
|
|
5
|
+
import { VisualizationTypeProvider } from '../VisualizationTypeProvider/index.js';
|
|
6
|
+
|
|
7
|
+
function VisualizationProvider({
|
|
8
|
+
layout,
|
|
9
|
+
dimensions,
|
|
10
|
+
children,
|
|
11
|
+
type,
|
|
12
|
+
config
|
|
13
|
+
}) {
|
|
14
|
+
return /* @__PURE__ */ jsx(DimensionsProvider, { dimensions, children: /* @__PURE__ */ jsx(VisualizationTypeProvider, { config, defaultType: type, children: /* @__PURE__ */ jsx(LayoutProvider, { defaultLayout: layout, children: /* @__PURE__ */ jsx(AnalyticsDataProvider, { children }) }) }) });
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export { VisualizationProvider };
|
|
18
|
+
//# sourceMappingURL=out.js.map
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../src/components/Visualization/components/VisualizationProvider/index.tsx"],"names":[],"mappings":"AA8BK;AA7BL,SAAiB,sBAAsB;AAEvC,SAAS,0BAA0B;AACnC,SAAS,6BAA6B;AACtC;AAAA,EAEC;AAAA,OACM;AAWA,SAAS,sBAAsB;AAAA,EACrC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD,GAA+B;AAC9B,SACC,oBAAC,sBAAmB,YACnB,8BAAC,6BAA0B,QAAgB,aAAa,MACvD,8BAAC,kBAAe,eAAe,QAC9B,8BAAC,yBAAuB,UAAS,GAClC,GACD,GACD;AAEF","sourcesContent":["import React from \"react\";\nimport { Layout, LayoutProvider } from \"../LayoutProvider/index.js\";\nimport { AnalyticsDimension } from \"@hisptz/dhis2-utils\";\nimport { DimensionsProvider } from \"../DimensionsProvider/index.js\";\nimport { AnalyticsDataProvider } from \"../AnalyticsDataProvider/index.js\";\nimport {\n\tVisualizationType,\n\tVisualizationTypeProvider,\n} from \"../VisualizationTypeProvider/index.js\";\nimport { VisualizationConfig } from \"../../index.js\";\n\nexport interface VisualizationProviderProps {\n\tchildren: React.ReactNode;\n\tlayout: Layout;\n\tdimensions: AnalyticsDimension;\n\ttype: VisualizationType;\n\tconfig: VisualizationConfig;\n}\n\nexport function VisualizationProvider({\n\tlayout,\n\tdimensions,\n\tchildren,\n\ttype,\n\tconfig,\n}: VisualizationProviderProps) {\n\treturn (\n\t\t<DimensionsProvider dimensions={dimensions}>\n\t\t\t<VisualizationTypeProvider config={config} defaultType={type}>\n\t\t\t\t<LayoutProvider defaultLayout={layout}>\n\t\t\t\t\t<AnalyticsDataProvider>{children}</AnalyticsDataProvider>\n\t\t\t\t</LayoutProvider>\n\t\t\t</VisualizationTypeProvider>\n\t\t</DimensionsProvider>\n\t);\n}\n"]}
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
2
|
+
import { useMemo } from 'react';
|
|
3
|
+
import { useVisualizationType } from '../VisualizationTypeProvider/index.js';
|
|
4
|
+
import { useAnalyticsData } from '../AnalyticsDataProvider/index.js';
|
|
5
|
+
import { CircularLoader } from '@dhis2/ui';
|
|
6
|
+
import { DHIS2PivotTable } from '../../../DHIS2PivotTable/index.js';
|
|
7
|
+
import { useLayout } from '../LayoutProvider/index.js';
|
|
8
|
+
import { forEach, set, mapValues, findIndex, find, filter } from 'lodash';
|
|
9
|
+
import { useDimensions } from '../DimensionsProvider/index.js';
|
|
10
|
+
import i18n from '@dhis2/d2-i18n';
|
|
11
|
+
import { DHIS2Chart } from '../../../ChartAnalytics/index.js';
|
|
12
|
+
import { DHIS2Map } from '../../../Map/index.js';
|
|
13
|
+
|
|
14
|
+
function getDimensionLabel(dimension) {
|
|
15
|
+
switch (dimension) {
|
|
16
|
+
case "pe":
|
|
17
|
+
return i18n.t("Period");
|
|
18
|
+
case "ou":
|
|
19
|
+
return i18n.t("Organisation unit");
|
|
20
|
+
case "dx":
|
|
21
|
+
return i18n.t("Data");
|
|
22
|
+
default:
|
|
23
|
+
return "";
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
function getOrgUnitSelectionFromIds(ous) {
|
|
27
|
+
const orgUnitSelection = {
|
|
28
|
+
orgUnits: []
|
|
29
|
+
};
|
|
30
|
+
forEach(ous, (ou) => {
|
|
31
|
+
if (ou === "USER_ORGUNIT") {
|
|
32
|
+
set(orgUnitSelection, ["userOrgUnit"], true);
|
|
33
|
+
} else if (ou === "USER_ORGUNIT_CHILDREN") {
|
|
34
|
+
set(orgUnitSelection, ["userSubUnit"], true);
|
|
35
|
+
} else if (ou === "USER_ORGUNIT_GRANDCHILDREN") {
|
|
36
|
+
set(orgUnitSelection, ["userSubX2Unit"], true);
|
|
37
|
+
} else {
|
|
38
|
+
const orgUnits = [...orgUnitSelection.orgUnits ?? []];
|
|
39
|
+
orgUnits.push({
|
|
40
|
+
id: ou,
|
|
41
|
+
children: [],
|
|
42
|
+
path: ""
|
|
43
|
+
});
|
|
44
|
+
set(orgUnitSelection, ["orgUnits"], orgUnits);
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
return orgUnitSelection;
|
|
48
|
+
}
|
|
49
|
+
function PivotTableRenderer({
|
|
50
|
+
options
|
|
51
|
+
}) {
|
|
52
|
+
const [layout] = useLayout();
|
|
53
|
+
const { analytics } = useAnalyticsData();
|
|
54
|
+
const sanitizedLayout = useMemo(() => {
|
|
55
|
+
return mapValues(
|
|
56
|
+
layout,
|
|
57
|
+
(dimension) => dimension.map((dimension2) => ({
|
|
58
|
+
dimension: dimension2,
|
|
59
|
+
label: getDimensionLabel(dimension2)
|
|
60
|
+
}))
|
|
61
|
+
);
|
|
62
|
+
}, [layout]);
|
|
63
|
+
if (!analytics) {
|
|
64
|
+
return null;
|
|
65
|
+
}
|
|
66
|
+
return /* @__PURE__ */ jsx(
|
|
67
|
+
DHIS2PivotTable,
|
|
68
|
+
{
|
|
69
|
+
tableProps: {
|
|
70
|
+
scrollHeight: options.scrollHeight ?? "100%",
|
|
71
|
+
scrollWidth: options.scrollWidth ?? "100%",
|
|
72
|
+
width: options.width ?? "100%"
|
|
73
|
+
},
|
|
74
|
+
analytics,
|
|
75
|
+
config: { layout: sanitizedLayout, options }
|
|
76
|
+
}
|
|
77
|
+
);
|
|
78
|
+
}
|
|
79
|
+
function ChartRenderer({ options }) {
|
|
80
|
+
const { analytics } = useAnalyticsData();
|
|
81
|
+
if (!analytics) {
|
|
82
|
+
return null;
|
|
83
|
+
}
|
|
84
|
+
return /* @__PURE__ */ jsx(DHIS2Chart, { analytics, config: { ...options } });
|
|
85
|
+
}
|
|
86
|
+
function MapRenderer({
|
|
87
|
+
options
|
|
88
|
+
}) {
|
|
89
|
+
const [dimensions] = useDimensions();
|
|
90
|
+
const { analytics } = useAnalyticsData();
|
|
91
|
+
const orgUnitSelection = useMemo(() => {
|
|
92
|
+
return getOrgUnitSelectionFromIds(dimensions.ou ?? []);
|
|
93
|
+
}, [dimensions.ou]);
|
|
94
|
+
const thematicLayers = useMemo(() => {
|
|
95
|
+
const valueIndex = findIndex(analytics.headers, ["name", "value"]) ?? -1;
|
|
96
|
+
return analytics.metaData?.dimensions["dx"]?.map((dataId) => {
|
|
97
|
+
const config = find(options.thematicLayers, ["id", dataId]);
|
|
98
|
+
const data = analytics.metaData?.dimensions?.ou?.map((ouId) => {
|
|
99
|
+
const values = filter(
|
|
100
|
+
analytics.rows,
|
|
101
|
+
(row) => row.includes(dataId) && row.includes(ouId)
|
|
102
|
+
);
|
|
103
|
+
const value = values.reduce(
|
|
104
|
+
(acc, value2) => acc + parseFloat(value2[valueIndex]),
|
|
105
|
+
0
|
|
106
|
+
);
|
|
107
|
+
return {
|
|
108
|
+
data: value,
|
|
109
|
+
dataItem: dataId,
|
|
110
|
+
orgUnit: ouId
|
|
111
|
+
};
|
|
112
|
+
}) ?? [];
|
|
113
|
+
return {
|
|
114
|
+
...config,
|
|
115
|
+
data
|
|
116
|
+
};
|
|
117
|
+
}) ?? [];
|
|
118
|
+
}, [analytics]);
|
|
119
|
+
return /* @__PURE__ */ jsx(
|
|
120
|
+
DHIS2Map,
|
|
121
|
+
{
|
|
122
|
+
orgUnitSelection,
|
|
123
|
+
thematicLayers
|
|
124
|
+
}
|
|
125
|
+
);
|
|
126
|
+
}
|
|
127
|
+
function VisualizationSelector({ config }) {
|
|
128
|
+
const [type] = useVisualizationType();
|
|
129
|
+
const { analytics, loading } = useAnalyticsData();
|
|
130
|
+
if (loading) {
|
|
131
|
+
return /* @__PURE__ */ jsx(
|
|
132
|
+
"div",
|
|
133
|
+
{
|
|
134
|
+
style: {
|
|
135
|
+
width: "100%",
|
|
136
|
+
height: "100%",
|
|
137
|
+
display: "flex",
|
|
138
|
+
justifyContent: "center",
|
|
139
|
+
alignItems: "center"
|
|
140
|
+
},
|
|
141
|
+
children: /* @__PURE__ */ jsx(CircularLoader, { small: true })
|
|
142
|
+
}
|
|
143
|
+
);
|
|
144
|
+
}
|
|
145
|
+
if (!analytics) {
|
|
146
|
+
return null;
|
|
147
|
+
}
|
|
148
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
149
|
+
type === "pivotTable" && /* @__PURE__ */ jsx(
|
|
150
|
+
PivotTableRenderer,
|
|
151
|
+
{
|
|
152
|
+
options: config?.pivotTable
|
|
153
|
+
}
|
|
154
|
+
),
|
|
155
|
+
type === "chart" && /* @__PURE__ */ jsx(ChartRenderer, { options: config?.chart }),
|
|
156
|
+
type === "map" && /* @__PURE__ */ jsx(
|
|
157
|
+
MapRenderer,
|
|
158
|
+
{
|
|
159
|
+
options: config?.map
|
|
160
|
+
}
|
|
161
|
+
)
|
|
162
|
+
] });
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
export { ChartRenderer, MapRenderer, PivotTableRenderer, VisualizationSelector, getDimensionLabel, getOrgUnitSelectionFromIds };
|
|
166
|
+
//# sourceMappingURL=out.js.map
|
|
167
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../src/components/Visualization/components/VisualizationSelector/index.tsx"],"names":["dimension","value"],"mappings":"AAqFE,SA6FA,UA7FA,KA6FA,YA7FA;AArFF,SAAgB,eAAe;AAC/B,SAAS,4BAA4B;AACrC,SAAS,wBAAwB;AACjC,SAAS,sBAAsB;AAC/B;AAAA,EACC;AAAA,OAEM;AACP,SAAS,iBAAiB;AAC1B,SAAS,QAAQ,MAAM,WAAW,SAAS,WAAW,WAAW;AACjE,SAAoB,qBAAqB;AACzC,OAAO,UAAU;AACjB,SAAsB,kBAAkB;AAExC,SAAS,gBAA0B;AAY5B,SAAS,kBAAkB,WAAsB;AACvD,UAAQ,WAAW;AAAA,IAClB,KAAK;AACJ,aAAO,KAAK,EAAE,QAAQ;AAAA,IACvB,KAAK;AACJ,aAAO,KAAK,EAAE,mBAAmB;AAAA,IAClC,KAAK;AACJ,aAAO,KAAK,EAAE,MAAM;AAAA,IACrB;AACC,aAAO;AAAA,EACT;AACD;AAEO,SAAS,2BAA2B,KAAe;AACzD,QAAM,mBAAqC;AAAA,IAC1C,UAAU,CAAC;AAAA,EACZ;AACA,UAAQ,KAAK,CAAC,OAAO;AACpB,QAAI,OAAO,gBAAgB;AAC1B,UAAI,kBAAkB,CAAC,aAAa,GAAG,IAAI;AAAA,IAC5C,WAAW,OAAO,yBAAyB;AAC1C,UAAI,kBAAkB,CAAC,aAAa,GAAG,IAAI;AAAA,IAC5C,WAAW,OAAO,8BAA8B;AAC/C,UAAI,kBAAkB,CAAC,eAAe,GAAG,IAAI;AAAA,IAC9C,OAAO;AACN,YAAM,WAAW,CAAC,GAAI,iBAAiB,YAAY,CAAC,CAAE;AACtD,eAAS,KAAK;AAAA,QACb,IAAI;AAAA,QACJ,UAAU,CAAC;AAAA,QACX,MAAM;AAAA,MACP,CAAC;AACD,UAAI,kBAAkB,CAAC,UAAU,GAAG,QAAQ;AAAA,IAC7C;AAAA,EACD,CAAC;AACD,SAAO;AACR;AAEO,SAAS,mBAAmB;AAAA,EAClC;AACD,GAEG;AACF,QAAM,CAAC,MAAM,IAAI,UAAU;AAC3B,QAAM,EAAE,UAAU,IAAI,iBAAiB;AAEvC,QAAM,kBAAkB,QAAQ,MAAM;AACrC,WAAO;AAAA,MAAU;AAAA,MAAQ,CAAC,cACzB,UAAU,IAAI,CAACA,gBAAe;AAAA,QAC7B,WAAAA;AAAA,QACA,OAAO,kBAAkBA,UAAS;AAAA,MACnC,EAAE;AAAA,IACH;AAAA,EACD,GAAG,CAAC,MAAM,CAAC;AAEX,MAAI,CAAC,WAAW;AACf,WAAO;AAAA,EACR;AAEA,SACC;AAAA,IAAC;AAAA;AAAA,MACA,YAAY;AAAA,QACX,cAAc,QAAQ,gBAAgB;AAAA,QACtC,aAAa,QAAQ,eAAe;AAAA,QACpC,OAAO,QAAQ,SAAS;AAAA,MACzB;AAAA,MACA;AAAA,MACA,QAAQ,EAAE,QAAQ,iBAAiB,QAAQ;AAAA;AAAA,EAC5C;AAEF;AAEO,SAAS,cAAc,EAAE,QAAQ,GAA6B;AACpE,QAAM,EAAE,UAAU,IAAI,iBAAiB;AACvC,MAAI,CAAC,WAAW;AACf,WAAO;AAAA,EACR;AACA,SAAO,oBAAC,cAAW,WAAsB,QAAQ,EAAE,GAAG,QAAQ,GAAG;AAClE;AAEO,SAAS,YAAY;AAAA,EAC3B;AACD,GAEG;AACF,QAAM,CAAC,UAAU,IAAI,cAAc;AACnC,QAAM,EAAE,UAAU,IAAI,iBAAiB;AACvC,QAAM,mBAAqC,QAAQ,MAAM;AACxD,WAAO,2BAA2B,WAAW,MAAM,CAAC,CAAC;AAAA,EACtD,GAAG,CAAC,WAAW,EAAE,CAAC;AAElB,QAAM,iBAAwC,QAAQ,MAAM;AAC3D,UAAM,aACL,UAAU,UAAU,SAAS,CAAC,QAAQ,OAAO,CAAC,KAAK;AACpD,WACC,UAAU,UAAU,WAAW,IAAI,GAAG,IAAI,CAAC,WAAW;AACrD,YAAM,SAAS,KAAK,QAAQ,gBAAgB,CAAC,MAAM,MAAM,CAAC;AAC1D,YAAM,OACL,UAAU,UAAU,YAAY,IAAI,IAAI,CAAC,SAAS;AACjD,cAAM,SAAS;AAAA,UACd,UAAU;AAAA,UACV,CAAC,QAAQ,IAAI,SAAS,MAAM,KAAK,IAAI,SAAS,IAAI;AAAA,QACnD;AACA,cAAM,QAAQ,OAAO;AAAA,UACpB,CAAC,KAAKC,WAAU,MAAM,WAAWA,OAAM,UAAU,CAAC;AAAA,UAClD;AAAA,QACD;AACA,eAAO;AAAA,UACN,MAAM;AAAA,UACN,UAAU;AAAA,UACV,SAAS;AAAA,QACV;AAAA,MACD,CAAC,KAAK,CAAC;AACR,aAAO;AAAA,QACN,GAAG;AAAA,QACH;AAAA,MACD;AAAA,IACD,CAAC,KAAK,CAAC;AAAA,EAET,GAAG,CAAC,SAAS,CAAC;AAEd,SACC;AAAA,IAAC;AAAA;AAAA,MACA;AAAA,MACA;AAAA;AAAA,EACD;AAEF;AAEO,SAAS,sBAAsB,EAAE,OAAO,GAA+B;AAC7E,QAAM,CAAC,IAAI,IAAI,qBAAqB;AACpC,QAAM,EAAE,WAAW,QAAQ,IAAI,iBAAiB;AAEhD,MAAI,SAAS;AACZ,WACC;AAAA,MAAC;AAAA;AAAA,QACA,OAAO;AAAA,UACN,OAAO;AAAA,UACP,QAAQ;AAAA,UACR,SAAS;AAAA,UACT,gBAAgB;AAAA,UAChB,YAAY;AAAA,QACb;AAAA,QAEA,8BAAC,kBAAe,OAAK,MAAC;AAAA;AAAA,IACvB;AAAA,EAEF;AACA,MAAI,CAAC,WAAW;AACf,WAAO;AAAA,EACR;AAEA,SACC,iCACE;AAAA,aAAS,gBACT;AAAA,MAAC;AAAA;AAAA,QACA,SAAS,QAAQ;AAAA;AAAA,IAClB;AAAA,IAEA,SAAS,WACT,oBAAC,iBAAc,SAAS,QAAQ,OAAsB;AAAA,IAEtD,SAAS,SACT;AAAA,MAAC;AAAA;AAAA,QACA,SACC,QAAQ;AAAA;AAAA,IAKV;AAAA,KAEF;AAEF","sourcesContent":["import React, { useMemo } from \"react\";\nimport { useVisualizationType } from \"../VisualizationTypeProvider/index.js\";\nimport { useAnalyticsData } from \"../AnalyticsDataProvider/index.js\";\nimport { CircularLoader } from \"@dhis2/ui\";\nimport {\n\tDHIS2PivotTable,\n\tDHIS2PivotTableOptions,\n} from \"../../../DHIS2PivotTable/index.js\";\nimport { useLayout } from \"../LayoutProvider/index.js\";\nimport { filter, find, findIndex, forEach, mapValues, set } from \"lodash\";\nimport { Dimension, useDimensions } from \"../DimensionsProvider/index.js\";\nimport i18n from \"@dhis2/d2-i18n\";\nimport { ChartConfig, DHIS2Chart } from \"../../../ChartAnalytics/index.js\";\nimport { VisualizationConfig } from \"../../index.js\";\nimport { DHIS2Map, MapProps } from \"../../../Map/index.js\";\nimport { OrgUnitSelection } from \"@hisptz/dhis2-utils\";\nimport {\n\tThematicLayerConfig,\n\tThematicLayerRawData,\n} from \"../../../Map/components/MapLayer/interfaces/index.js\";\nimport type { PivotTableLayoutProps } from \"../../../DHIS2PivotTable/components/Table/index.js\";\n\nexport interface VisualizationSelectorProps {\n\tconfig: VisualizationConfig;\n}\n\nexport function getDimensionLabel(dimension: Dimension) {\n\tswitch (dimension) {\n\t\tcase \"pe\":\n\t\t\treturn i18n.t(\"Period\");\n\t\tcase \"ou\":\n\t\t\treturn i18n.t(\"Organisation unit\");\n\t\tcase \"dx\":\n\t\t\treturn i18n.t(\"Data\");\n\t\tdefault:\n\t\t\treturn \"\";\n\t}\n}\n\nexport function getOrgUnitSelectionFromIds(ous: string[]) {\n\tconst orgUnitSelection: OrgUnitSelection = {\n\t\torgUnits: [],\n\t};\n\tforEach(ous, (ou) => {\n\t\tif (ou === \"USER_ORGUNIT\") {\n\t\t\tset(orgUnitSelection, [\"userOrgUnit\"], true);\n\t\t} else if (ou === \"USER_ORGUNIT_CHILDREN\") {\n\t\t\tset(orgUnitSelection, [\"userSubUnit\"], true);\n\t\t} else if (ou === \"USER_ORGUNIT_GRANDCHILDREN\") {\n\t\t\tset(orgUnitSelection, [\"userSubX2Unit\"], true);\n\t\t} else {\n\t\t\tconst orgUnits = [...(orgUnitSelection.orgUnits ?? [])];\n\t\t\torgUnits.push({\n\t\t\t\tid: ou,\n\t\t\t\tchildren: [],\n\t\t\t\tpath: \"\",\n\t\t\t});\n\t\t\tset(orgUnitSelection, [\"orgUnits\"], orgUnits);\n\t\t}\n\t});\n\treturn orgUnitSelection;\n}\n\nexport function PivotTableRenderer({\n\toptions,\n}: {\n\toptions: DHIS2PivotTableOptions & PivotTableLayoutProps;\n}) {\n\tconst [layout] = useLayout();\n\tconst { analytics } = useAnalyticsData();\n\n\tconst sanitizedLayout = useMemo(() => {\n\t\treturn mapValues(layout, (dimension) =>\n\t\t\tdimension.map((dimension) => ({\n\t\t\t\tdimension,\n\t\t\t\tlabel: getDimensionLabel(dimension),\n\t\t\t})),\n\t\t);\n\t}, [layout]);\n\n\tif (!analytics) {\n\t\treturn null;\n\t}\n\n\treturn (\n\t\t<DHIS2PivotTable\n\t\t\ttableProps={{\n\t\t\t\tscrollHeight: options.scrollHeight ?? \"100%\",\n\t\t\t\tscrollWidth: options.scrollWidth ?? \"100%\",\n\t\t\t\twidth: options.width ?? \"100%\",\n\t\t\t}}\n\t\t\tanalytics={analytics}\n\t\t\tconfig={{ layout: sanitizedLayout, options }}\n\t\t/>\n\t);\n}\n\nexport function ChartRenderer({ options }: { options: ChartConfig }) {\n\tconst { analytics } = useAnalyticsData();\n\tif (!analytics) {\n\t\treturn null;\n\t}\n\treturn <DHIS2Chart analytics={analytics} config={{ ...options }} />;\n}\n\nexport function MapRenderer({\n\toptions,\n}: {\n\toptions: Omit<MapProps, \"orgUnitSelection\" | \"periodSelection\">;\n}) {\n\tconst [dimensions] = useDimensions();\n\tconst { analytics } = useAnalyticsData();\n\tconst orgUnitSelection: OrgUnitSelection = useMemo(() => {\n\t\treturn getOrgUnitSelectionFromIds(dimensions.ou ?? []);\n\t}, [dimensions.ou]);\n\n\tconst thematicLayers: ThematicLayerConfig[] = useMemo(() => {\n\t\tconst valueIndex =\n\t\t\tfindIndex(analytics.headers, [\"name\", \"value\"]) ?? -1;\n\t\treturn (\n\t\t\tanalytics.metaData?.dimensions[\"dx\"]?.map((dataId) => {\n\t\t\t\tconst config = find(options.thematicLayers, [\"id\", dataId]);\n\t\t\t\tconst data: ThematicLayerRawData[] =\n\t\t\t\t\tanalytics.metaData?.dimensions?.ou?.map((ouId) => {\n\t\t\t\t\t\tconst values = filter(\n\t\t\t\t\t\t\tanalytics.rows,\n\t\t\t\t\t\t\t(row) => row.includes(dataId) && row.includes(ouId),\n\t\t\t\t\t\t) as unknown as string[];\n\t\t\t\t\t\tconst value = values.reduce(\n\t\t\t\t\t\t\t(acc, value) => acc + parseFloat(value[valueIndex]),\n\t\t\t\t\t\t\t0,\n\t\t\t\t\t\t);\n\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\tdata: value,\n\t\t\t\t\t\t\tdataItem: dataId,\n\t\t\t\t\t\t\torgUnit: ouId,\n\t\t\t\t\t\t};\n\t\t\t\t\t}) ?? [];\n\t\t\t\treturn {\n\t\t\t\t\t...config,\n\t\t\t\t\tdata,\n\t\t\t\t} as ThematicLayerConfig;\n\t\t\t}) ?? []\n\t\t);\n\t}, [analytics]);\n\n\treturn (\n\t\t<DHIS2Map\n\t\t\torgUnitSelection={orgUnitSelection}\n\t\t\tthematicLayers={thematicLayers}\n\t\t/>\n\t);\n}\n\nexport function VisualizationSelector({ config }: VisualizationSelectorProps) {\n\tconst [type] = useVisualizationType();\n\tconst { analytics, loading } = useAnalyticsData();\n\n\tif (loading) {\n\t\treturn (\n\t\t\t<div\n\t\t\t\tstyle={{\n\t\t\t\t\twidth: \"100%\",\n\t\t\t\t\theight: \"100%\",\n\t\t\t\t\tdisplay: \"flex\",\n\t\t\t\t\tjustifyContent: \"center\",\n\t\t\t\t\talignItems: \"center\",\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t<CircularLoader small />\n\t\t\t</div>\n\t\t);\n\t}\n\tif (!analytics) {\n\t\treturn null;\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t{type === \"pivotTable\" && (\n\t\t\t\t<PivotTableRenderer\n\t\t\t\t\toptions={config?.pivotTable as DHIS2PivotTableOptions}\n\t\t\t\t/>\n\t\t\t)}\n\t\t\t{type === \"chart\" && (\n\t\t\t\t<ChartRenderer options={config?.chart as ChartConfig} />\n\t\t\t)}\n\t\t\t{type === \"map\" && (\n\t\t\t\t<MapRenderer\n\t\t\t\t\toptions={\n\t\t\t\t\t\tconfig?.map as Omit<\n\t\t\t\t\t\t\tMapProps,\n\t\t\t\t\t\t\t\"orgUnitSelection\" | \"periodSelection\"\n\t\t\t\t\t\t>\n\t\t\t\t\t}\n\t\t\t\t/>\n\t\t\t)}\n\t\t</>\n\t);\n}\n"]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { createContext, useContext, useState } from 'react';
|
|
3
|
+
|
|
4
|
+
const VisualizationTypeContext = createContext("pivotTable");
|
|
5
|
+
const VisualizationConfigContext = createContext(void 0);
|
|
6
|
+
const VisualizationTypeSetter = createContext(void 0);
|
|
7
|
+
function useVisualizationType() {
|
|
8
|
+
return [
|
|
9
|
+
useContext(VisualizationTypeContext),
|
|
10
|
+
useContext(VisualizationTypeSetter)
|
|
11
|
+
];
|
|
12
|
+
}
|
|
13
|
+
function useVisualizationConfig() {
|
|
14
|
+
return useContext(VisualizationConfigContext);
|
|
15
|
+
}
|
|
16
|
+
function VisualizationTypeProvider({
|
|
17
|
+
children,
|
|
18
|
+
defaultType,
|
|
19
|
+
config
|
|
20
|
+
}) {
|
|
21
|
+
const [type, setType] = useState(defaultType);
|
|
22
|
+
return /* @__PURE__ */ jsx(VisualizationTypeContext.Provider, { value: type, children: /* @__PURE__ */ jsx(VisualizationConfigContext.Provider, { value: config, children: /* @__PURE__ */ jsx(VisualizationTypeSetter.Provider, { value: setType, children }) }) });
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export { VisualizationConfigContext, VisualizationTypeContext, VisualizationTypeProvider, VisualizationTypeSetter, useVisualizationConfig, useVisualizationType };
|
|
26
|
+
//# sourceMappingURL=out.js.map
|
|
27
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../src/components/Visualization/components/VisualizationTypeProvider/index.tsx"],"names":[],"mappings":"AA4CI;AA5CJ,SAAgB,eAAe,YAAY,gBAAgB;AAKpD,MAAM,2BACZ,cAAiC,YAAY;AACvC,MAAM,6BAA6B,cAExC,MAAS;AACJ,MAAM,0BAA0B,cAErC,MAAS;AAQJ,SAAS,uBAAuB;AACtC,SAAO;AAAA,IACN,WAAW,wBAAwB;AAAA,IACnC,WAAW,uBAAuB;AAAA,EACnC;AAID;AAEO,SAAS,yBAAyB;AACxC,SAAO,WAAW,0BAA0B;AAC7C;AAEO,SAAS,0BAA0B;AAAA,EACzC;AAAA,EACA;AAAA,EACA;AACD,GAAmC;AAClC,QAAM,CAAC,MAAM,OAAO,IAAI,SAA4B,WAAW;AAE/D,SACC,oBAAC,yBAAyB,UAAzB,EAAkC,OAAO,MACzC,8BAAC,2BAA2B,UAA3B,EAAoC,OAAO,QAC3C,8BAAC,wBAAwB,UAAxB,EAAiC,OAAO,SACvC,UACF,GACD,GACD;AAEF","sourcesContent":["import React, { createContext, useContext, useState } from \"react\";\nimport { VisualizationConfig } from \"../../index.js\";\n\nexport type VisualizationType = \"pivotTable\" | \"chart\" | \"map\";\n\nexport const VisualizationTypeContext =\n\tcreateContext<VisualizationType>(\"pivotTable\");\nexport const VisualizationConfigContext = createContext<\n\tVisualizationConfig | undefined\n>(undefined);\nexport const VisualizationTypeSetter = createContext<\n\tReact.Dispatch<React.SetStateAction<VisualizationType>> | undefined\n>(undefined);\n\nexport interface VisualizationTypeProviderProps {\n\tchildren: React.ReactNode;\n\tdefaultType: VisualizationType;\n\tconfig: VisualizationConfig;\n}\n\nexport function useVisualizationType() {\n\treturn [\n\t\tuseContext(VisualizationTypeContext),\n\t\tuseContext(VisualizationTypeSetter),\n\t] as [\n\t\tVisualizationType,\n\t\tReact.Dispatch<React.SetStateAction<VisualizationType>>,\n\t];\n}\n\nexport function useVisualizationConfig() {\n\treturn useContext(VisualizationConfigContext);\n}\n\nexport function VisualizationTypeProvider({\n\tchildren,\n\tdefaultType,\n\tconfig,\n}: VisualizationTypeProviderProps) {\n\tconst [type, setType] = useState<VisualizationType>(defaultType);\n\n\treturn (\n\t\t<VisualizationTypeContext.Provider value={type}>\n\t\t\t<VisualizationConfigContext.Provider value={config}>\n\t\t\t\t<VisualizationTypeSetter.Provider value={setType}>\n\t\t\t\t\t{children}\n\t\t\t\t</VisualizationTypeSetter.Provider>\n\t\t\t</VisualizationConfigContext.Provider>\n\t\t</VisualizationTypeContext.Provider>\n\t);\n}\n"]}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { useMemo } from 'react';
|
|
3
|
+
import { useVisualizationType, useVisualizationConfig } from '../VisualizationTypeProvider/index.js';
|
|
4
|
+
import { IconTable24, IconVisualizationColumn24, IconWorld24, Tooltip, Button } from '@dhis2/ui';
|
|
5
|
+
import i18n from '@dhis2/d2-i18n';
|
|
6
|
+
|
|
7
|
+
const supportedVisualizationTypes = [
|
|
8
|
+
{
|
|
9
|
+
id: "pivotTable",
|
|
10
|
+
icon: /* @__PURE__ */ jsx(IconTable24, {}),
|
|
11
|
+
label: i18n.t("Pivot table")
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
id: "chart",
|
|
15
|
+
icon: /* @__PURE__ */ jsx(IconVisualizationColumn24, {}),
|
|
16
|
+
label: i18n.t("Chart")
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
id: "map",
|
|
20
|
+
icon: /* @__PURE__ */ jsx(IconWorld24, {}),
|
|
21
|
+
label: i18n.t("Map")
|
|
22
|
+
}
|
|
23
|
+
];
|
|
24
|
+
function VisualizationTypeSelector() {
|
|
25
|
+
const [type, setType] = useVisualizationType();
|
|
26
|
+
const config = useVisualizationConfig();
|
|
27
|
+
const types = useMemo(
|
|
28
|
+
() => supportedVisualizationTypes.filter((supportedType) => {
|
|
29
|
+
return Object.keys(config ?? {}).includes(supportedType.id) && supportedType.id !== type;
|
|
30
|
+
}),
|
|
31
|
+
[type, config]
|
|
32
|
+
);
|
|
33
|
+
return /* @__PURE__ */ jsx("div", { style: { display: "flex", gap: 8 }, children: types.map(({ icon, label, id }) => {
|
|
34
|
+
return /* @__PURE__ */ jsx(
|
|
35
|
+
Tooltip,
|
|
36
|
+
{
|
|
37
|
+
content: i18n.t("View as {{type}}", {
|
|
38
|
+
type: label.toLowerCase()
|
|
39
|
+
}),
|
|
40
|
+
children: /* @__PURE__ */ jsx(
|
|
41
|
+
Button,
|
|
42
|
+
{
|
|
43
|
+
onClick: () => setType(id),
|
|
44
|
+
icon
|
|
45
|
+
}
|
|
46
|
+
)
|
|
47
|
+
},
|
|
48
|
+
`${label}-tooltip`
|
|
49
|
+
);
|
|
50
|
+
}) });
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export { VisualizationTypeSelector };
|
|
54
|
+
//# sourceMappingURL=out.js.map
|
|
55
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../src/components/Visualization/components/VisualizationTypeSelector/index.tsx"],"names":[],"mappings":"AAkBQ;AAlBR,SAAgB,eAAe;AAC/B;AAAA,EACC;AAAA,EACA;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP,OAAO,UAAU;AAEjB,MAAM,8BAA8B;AAAA,EACnC;AAAA,IACC,IAAI;AAAA,IACJ,MAAM,oBAAC,eAAY;AAAA,IACnB,OAAO,KAAK,EAAE,aAAa;AAAA,EAC5B;AAAA,EACA;AAAA,IACC,IAAI;AAAA,IACJ,MAAM,oBAAC,6BAA0B;AAAA,IACjC,OAAO,KAAK,EAAE,OAAO;AAAA,EACtB;AAAA,EACA;AAAA,IACC,IAAI;AAAA,IACJ,MAAM,oBAAC,eAAY;AAAA,IACnB,OAAO,KAAK,EAAE,KAAK;AAAA,EACpB;AACD;AAEO,SAAS,4BAA4B;AAC3C,QAAM,CAAC,MAAM,OAAO,IAAI,qBAAqB;AAC7C,QAAM,SAAS,uBAAuB;AAEtC,QAAM,QAAQ;AAAA,IACb,MACC,4BAA4B,OAAO,CAAC,kBAAkB;AACrD,aACC,OAAO,KAAK,UAAU,CAAC,CAAC,EAAE,SAAS,cAAc,EAAE,KACnD,cAAc,OAAO;AAAA,IAEvB,CAAC;AAAA,IACF,CAAC,MAAM,MAAM;AAAA,EACd;AAEA,SACC,oBAAC,SAAI,OAAO,EAAE,SAAS,QAAQ,KAAK,EAAE,GACpC,gBAAM,IAAI,CAAC,EAAE,MAAM,OAAO,GAAG,MAAM;AACnC,WACC;AAAA,MAAC;AAAA;AAAA,QAEA,SAAS,KAAK,EAAE,oBAAoB;AAAA,UACnC,MAAM,MAAM,YAAY;AAAA,QACzB,CAAC;AAAA,QAED;AAAA,UAAC;AAAA;AAAA,YACA,SAAS,MAAM,QAAQ,EAAuB;AAAA,YAC9C;AAAA;AAAA,QACD;AAAA;AAAA,MARK,GAAG,KAAK;AAAA,IASd;AAAA,EAEF,CAAC,GACF;AAEF","sourcesContent":["import React, { useMemo } from \"react\";\nimport {\n\tuseVisualizationConfig,\n\tuseVisualizationType,\n\tVisualizationType,\n} from \"../VisualizationTypeProvider/index.js\";\nimport {\n\tButton,\n\tIconTable24,\n\tIconVisualizationColumn24,\n\tIconWorld24,\n\tTooltip,\n} from \"@dhis2/ui\";\nimport i18n from \"@dhis2/d2-i18n\";\n\nconst supportedVisualizationTypes = [\n\t{\n\t\tid: \"pivotTable\",\n\t\ticon: <IconTable24 />,\n\t\tlabel: i18n.t(\"Pivot table\"),\n\t},\n\t{\n\t\tid: \"chart\",\n\t\ticon: <IconVisualizationColumn24 />,\n\t\tlabel: i18n.t(\"Chart\"),\n\t},\n\t{\n\t\tid: \"map\",\n\t\ticon: <IconWorld24 />,\n\t\tlabel: i18n.t(\"Map\"),\n\t},\n];\n\nexport function VisualizationTypeSelector() {\n\tconst [type, setType] = useVisualizationType();\n\tconst config = useVisualizationConfig();\n\n\tconst types = useMemo(\n\t\t() =>\n\t\t\tsupportedVisualizationTypes.filter((supportedType) => {\n\t\t\t\treturn (\n\t\t\t\t\tObject.keys(config ?? {}).includes(supportedType.id) &&\n\t\t\t\t\tsupportedType.id !== type\n\t\t\t\t);\n\t\t\t}),\n\t\t[type, config],\n\t);\n\n\treturn (\n\t\t<div style={{ display: \"flex\", gap: 8 }}>\n\t\t\t{types.map(({ icon, label, id }) => {\n\t\t\t\treturn (\n\t\t\t\t\t<Tooltip\n\t\t\t\t\t\tkey={`${label}-tooltip`}\n\t\t\t\t\t\tcontent={i18n.t(\"View as {{type}}\", {\n\t\t\t\t\t\t\ttype: label.toLowerCase(),\n\t\t\t\t\t\t})}\n\t\t\t\t\t>\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\tonClick={() => setType(id as VisualizationType)}\n\t\t\t\t\t\t\ticon={icon}\n\t\t\t\t\t\t/>\n\t\t\t\t\t</Tooltip>\n\t\t\t\t);\n\t\t\t})}\n\t\t</div>\n\t);\n}\n"]}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
2
|
+
import { VisualizationProvider } from './components/VisualizationProvider/index.js';
|
|
3
|
+
import { VisualizationTypeSelector } from './components/VisualizationTypeSelector/index.js';
|
|
4
|
+
import { VisualizationDimensionSelector } from './components/VisualizationDimensionSelector/index.js';
|
|
5
|
+
import { VisualizationSelector } from './components/VisualizationSelector/index.js';
|
|
6
|
+
import { ErrorBoundary } from 'react-error-boundary';
|
|
7
|
+
import i18n from '@dhis2/d2-i18n';
|
|
8
|
+
import { IconError24, colors, Button } from '@dhis2/ui';
|
|
9
|
+
|
|
10
|
+
function ErrorFallback({
|
|
11
|
+
error,
|
|
12
|
+
resetErrorBoundary,
|
|
13
|
+
height
|
|
14
|
+
}) {
|
|
15
|
+
return /* @__PURE__ */ jsxs(
|
|
16
|
+
"div",
|
|
17
|
+
{
|
|
18
|
+
style: {
|
|
19
|
+
width: "100%",
|
|
20
|
+
textAlign: "center",
|
|
21
|
+
height: height ?? 500,
|
|
22
|
+
display: "flex",
|
|
23
|
+
flexDirection: "column",
|
|
24
|
+
alignItems: "center",
|
|
25
|
+
justifyContent: "center",
|
|
26
|
+
gap: 16,
|
|
27
|
+
padding: 16
|
|
28
|
+
},
|
|
29
|
+
children: [
|
|
30
|
+
/* @__PURE__ */ jsx(IconError24, {}),
|
|
31
|
+
/* @__PURE__ */ jsx(
|
|
32
|
+
"h3",
|
|
33
|
+
{
|
|
34
|
+
style: {
|
|
35
|
+
color: colors.grey800,
|
|
36
|
+
margin: 0
|
|
37
|
+
},
|
|
38
|
+
children: i18n.t("Could not load visualization")
|
|
39
|
+
}
|
|
40
|
+
),
|
|
41
|
+
/* @__PURE__ */ jsx("p", { style: { margin: 0 }, children: error.message }),
|
|
42
|
+
resetErrorBoundary && /* @__PURE__ */ jsx(Button, { onClick: resetErrorBoundary, small: true, children: i18n.t("Try again") })
|
|
43
|
+
]
|
|
44
|
+
}
|
|
45
|
+
);
|
|
46
|
+
}
|
|
47
|
+
function Visualization({
|
|
48
|
+
dimensions,
|
|
49
|
+
layout,
|
|
50
|
+
defaultVisualizationType,
|
|
51
|
+
config,
|
|
52
|
+
height,
|
|
53
|
+
showToolbar,
|
|
54
|
+
showOrgUnitSelector,
|
|
55
|
+
showPeriodSelector
|
|
56
|
+
}) {
|
|
57
|
+
return /* @__PURE__ */ jsx(
|
|
58
|
+
ErrorBoundary,
|
|
59
|
+
{
|
|
60
|
+
resetKeys: [dimensions, layout, defaultVisualizationType, config],
|
|
61
|
+
fallbackRender: (props) => /* @__PURE__ */ jsx(ErrorFallback, { height, ...props }),
|
|
62
|
+
children: /* @__PURE__ */ jsx(
|
|
63
|
+
VisualizationProvider,
|
|
64
|
+
{
|
|
65
|
+
config,
|
|
66
|
+
type: defaultVisualizationType,
|
|
67
|
+
layout,
|
|
68
|
+
dimensions,
|
|
69
|
+
children: /* @__PURE__ */ jsxs(
|
|
70
|
+
"div",
|
|
71
|
+
{
|
|
72
|
+
style: {
|
|
73
|
+
display: "flex",
|
|
74
|
+
flexDirection: "column",
|
|
75
|
+
width: "100%",
|
|
76
|
+
height: "100%",
|
|
77
|
+
gap: 16
|
|
78
|
+
},
|
|
79
|
+
children: [
|
|
80
|
+
showToolbar && /* @__PURE__ */ jsxs(
|
|
81
|
+
"div",
|
|
82
|
+
{
|
|
83
|
+
style: {
|
|
84
|
+
display: "flex",
|
|
85
|
+
flexDirection: "row",
|
|
86
|
+
gap: 16,
|
|
87
|
+
justifyContent: "space-between"
|
|
88
|
+
},
|
|
89
|
+
children: [
|
|
90
|
+
/* @__PURE__ */ jsx(VisualizationTypeSelector, {}),
|
|
91
|
+
/* @__PURE__ */ jsx(
|
|
92
|
+
VisualizationDimensionSelector,
|
|
93
|
+
{
|
|
94
|
+
showPeriodSelector,
|
|
95
|
+
showOrgUnitSelector
|
|
96
|
+
}
|
|
97
|
+
)
|
|
98
|
+
]
|
|
99
|
+
}
|
|
100
|
+
),
|
|
101
|
+
/* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsx(VisualizationSelector, { config }) })
|
|
102
|
+
]
|
|
103
|
+
}
|
|
104
|
+
)
|
|
105
|
+
}
|
|
106
|
+
)
|
|
107
|
+
}
|
|
108
|
+
);
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
export { Visualization };
|
|
112
|
+
//# sourceMappingURL=out.js.map
|
|
113
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/components/Visualization/index.tsx"],"names":[],"mappings":"AA2CE,SAgFG,UAnEF,KAbD;AAzCF,SAAS,6BAA6B;AAGtC,SAAS,iCAAiC;AAC1C,SAAS,sCAAsC;AAC/C,SAAS,6BAA6B;AAItC,SAAS,qBAAoC;AAC7C,OAAO,UAAU;AACjB,SAAS,QAAQ,QAAQ,mBAAmB;AAwB5C,SAAS,cAAc;AAAA,EACtB;AAAA,EACA;AAAA,EACA;AACD,GAAwC;AACvC,SACC;AAAA,IAAC;AAAA;AAAA,MACA,OAAO;AAAA,QACN,OAAO;AAAA,QACP,WAAW;AAAA,QACX,QAAQ,UAAU;AAAA,QAClB,SAAS;AAAA,QACT,eAAe;AAAA,QACf,YAAY;AAAA,QACZ,gBAAgB;AAAA,QAChB,KAAK;AAAA,QACL,SAAS;AAAA,MACV;AAAA,MAEA;AAAA,4BAAC,eAAY;AAAA,QACb;AAAA,UAAC;AAAA;AAAA,YACA,OAAO;AAAA,cACN,OAAO,OAAO;AAAA,cACd,QAAQ;AAAA,YACT;AAAA,YAEC,eAAK,EAAE,8BAA8B;AAAA;AAAA,QACvC;AAAA,QACA,oBAAC,OAAE,OAAO,EAAE,QAAQ,EAAE,GAAI,gBAAM,SAAQ;AAAA,QACvC,sBACA,oBAAC,UAAO,SAAS,oBAAoB,OAAK,MACxC,eAAK,EAAE,WAAW,GACpB;AAAA;AAAA;AAAA,EAEF;AAEF;AAEO,SAAS,cAAc;AAAA,EAC7B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD,GAAuB;AACtB,SACC;AAAA,IAAC;AAAA;AAAA,MACA,WAAW,CAAC,YAAY,QAAQ,0BAA0B,MAAM;AAAA,MAChE,gBAAgB,CAAC,UACf,oBAAC,iBAAc,QAAiB,GAAG,OAAO;AAAA,MAG5C;AAAA,QAAC;AAAA;AAAA,UACA;AAAA,UACA,MAAM;AAAA,UACN;AAAA,UACA;AAAA,UAEA;AAAA,YAAC;AAAA;AAAA,cACA,OAAO;AAAA,gBACN,SAAS;AAAA,gBACT,eAAe;AAAA,gBACf,OAAO;AAAA,gBACP,QAAQ;AAAA,gBACR,KAAK;AAAA,cACN;AAAA,cAEC;AAAA,+BACA;AAAA,kBAAC;AAAA;AAAA,oBACA,OAAO;AAAA,sBACN,SAAS;AAAA,sBACT,eAAe;AAAA,sBACf,KAAK;AAAA,sBACL,gBAAgB;AAAA,oBACjB;AAAA,oBAEA;AAAA,0CAAC,6BAA0B;AAAA,sBAC3B;AAAA,wBAAC;AAAA;AAAA,0BACA;AAAA,0BACA;AAAA;AAAA,sBACD;AAAA;AAAA;AAAA,gBACD;AAAA,gBAED,gCACC,8BAAC,yBAAsB,QAAgB,GACxC;AAAA;AAAA;AAAA,UACD;AAAA;AAAA,MACD;AAAA;AAAA,EACD;AAEF","sourcesContent":["import React from \"react\";\nimport { AnalyticsDimension } from \"@hisptz/dhis2-utils\";\nimport { VisualizationProvider } from \"./components/VisualizationProvider/index.js\";\nimport { Layout } from \"./components/LayoutProvider/index.js\";\nimport { VisualizationType } from \"./components/VisualizationTypeProvider/index.js\";\nimport { VisualizationTypeSelector } from \"./components/VisualizationTypeSelector/index.js\";\nimport { VisualizationDimensionSelector } from \"./components/VisualizationDimensionSelector/index.js\";\nimport { VisualizationSelector } from \"./components/VisualizationSelector/index.js\";\nimport { DHIS2PivotTableOptions } from \"../DHIS2PivotTable/index.js\";\nimport { ChartConfig } from \"../ChartAnalytics/index.js\";\nimport { MapProps } from \"../Map/index.js\";\nimport { ErrorBoundary, FallbackProps } from \"react-error-boundary\";\nimport i18n from \"@dhis2/d2-i18n\";\nimport { Button, colors, IconError24 } from \"@dhis2/ui\";\n\nexport interface VisualizationConfig {\n\tpivotTable?: DHIS2PivotTableOptions;\n\tchart?: ChartConfig;\n\tmap?: Omit<MapProps, \"orgUnitSelection\" | \"periodSelection\">;\n}\n\nexport interface VisualizationProps {\n\tlayout: Layout;\n\tdefaultVisualizationType: VisualizationType;\n\tdimensions: AnalyticsDimension;\n\tconfig: VisualizationConfig;\n\theight?: number;\n\tshowToolbar?: boolean;\n\tshowPeriodSelector?: boolean;\n\tshowOrgUnitSelector?: boolean;\n}\n\n/**\n * An analytics component that allows visualization of `chart`, `map`, and `pivot table` by passing analytics object and the default layout and type\n *\n * */\n\nfunction ErrorFallback({\n\terror,\n\tresetErrorBoundary,\n\theight,\n}: FallbackProps & { height?: number }) {\n\treturn (\n\t\t<div\n\t\t\tstyle={{\n\t\t\t\twidth: \"100%\",\n\t\t\t\ttextAlign: \"center\",\n\t\t\t\theight: height ?? 500,\n\t\t\t\tdisplay: \"flex\",\n\t\t\t\tflexDirection: \"column\",\n\t\t\t\talignItems: \"center\",\n\t\t\t\tjustifyContent: \"center\",\n\t\t\t\tgap: 16,\n\t\t\t\tpadding: 16,\n\t\t\t}}\n\t\t>\n\t\t\t<IconError24 />\n\t\t\t<h3\n\t\t\t\tstyle={{\n\t\t\t\t\tcolor: colors.grey800,\n\t\t\t\t\tmargin: 0,\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t{i18n.t(\"Could not load visualization\")}\n\t\t\t</h3>\n\t\t\t<p style={{ margin: 0 }}>{error.message}</p>\n\t\t\t{resetErrorBoundary && (\n\t\t\t\t<Button onClick={resetErrorBoundary} small>\n\t\t\t\t\t{i18n.t(\"Try again\")}\n\t\t\t\t</Button>\n\t\t\t)}\n\t\t</div>\n\t);\n}\n\nexport function Visualization({\n\tdimensions,\n\tlayout,\n\tdefaultVisualizationType,\n\tconfig,\n\theight,\n\tshowToolbar,\n\tshowOrgUnitSelector,\n\tshowPeriodSelector,\n}: VisualizationProps) {\n\treturn (\n\t\t<ErrorBoundary\n\t\t\tresetKeys={[dimensions, layout, defaultVisualizationType, config]}\n\t\t\tfallbackRender={(props) =>\n\t\t\t\t(<ErrorFallback height={height} {...props} />) as any\n\t\t\t}\n\t\t>\n\t\t\t<VisualizationProvider\n\t\t\t\tconfig={config}\n\t\t\t\ttype={defaultVisualizationType}\n\t\t\t\tlayout={layout}\n\t\t\t\tdimensions={dimensions}\n\t\t\t>\n\t\t\t\t<div\n\t\t\t\t\tstyle={{\n\t\t\t\t\t\tdisplay: \"flex\",\n\t\t\t\t\t\tflexDirection: \"column\",\n\t\t\t\t\t\twidth: \"100%\",\n\t\t\t\t\t\theight: \"100%\",\n\t\t\t\t\t\tgap: 16,\n\t\t\t\t\t}}\n\t\t\t\t>\n\t\t\t\t\t{showToolbar && (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tstyle={{\n\t\t\t\t\t\t\t\tdisplay: \"flex\",\n\t\t\t\t\t\t\t\tflexDirection: \"row\",\n\t\t\t\t\t\t\t\tgap: 16,\n\t\t\t\t\t\t\t\tjustifyContent: \"space-between\",\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<VisualizationTypeSelector />\n\t\t\t\t\t\t\t<VisualizationDimensionSelector\n\t\t\t\t\t\t\t\tshowPeriodSelector={showPeriodSelector}\n\t\t\t\t\t\t\t\tshowOrgUnitSelector={showOrgUnitSelector}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t)}\n\t\t\t\t\t<>\n\t\t\t\t\t\t<VisualizationSelector config={config} />\n\t\t\t\t\t</>\n\t\t\t\t</div>\n\t\t\t</VisualizationProvider>\n\t\t</ErrorBoundary>\n\t);\n}\n"]}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * from './components/Map/index.js';
|
|
2
|
+
export * from './components/CircularProgressDashboard/index.js';
|
|
3
|
+
export * from './components/ChartAnalytics/index.js';
|
|
4
|
+
export * from './components/SingleValueContainer/index.js';
|
|
5
|
+
export * from './components/DHIS2PivotTable/index.js';
|
|
6
|
+
export * from './components/Visualization/index.js';
|
|
7
|
+
//# sourceMappingURL=out.js.map
|
|
8
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc","sourcesContent":["export * from \"./components/Map/index.js\";\nexport * from \"./components/CircularProgressDashboard/index.js\";\nexport * from \"./components/ChartAnalytics/index.js\";\nexport * from \"./components/SingleValueContainer/index.js\";\nexport * from \"./components/DHIS2PivotTable/index.js\";\nexport * from \"./components/Visualization/index.js\";\n"]}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import "./styles/custom-highchart.css";
|
|
3
|
+
import { ChartAnalyticsProps } from "./types/props.js";
|
|
4
|
+
export * from "./services/export.js";
|
|
5
|
+
export * from "./types/props.js";
|
|
6
|
+
export * from "./components/DownloadMenu/index.js";
|
|
7
|
+
/**
|
|
8
|
+
* The `DHIS2Chart` component allows you to render a chart visualization from DHIS2 analytics data.
|
|
9
|
+
* It accepts the DHIS2 analytics payload as well as configuration on how to visualize the data.
|
|
10
|
+
*
|
|
11
|
+
* @component
|
|
12
|
+
*
|
|
13
|
+
* @param {ChartAnalyticsProps} props
|
|
14
|
+
* @param {Analytics} [props.analytics] - Analytics data from DHIS2
|
|
15
|
+
* @param {ChartConfig} [props.config] - Visualization configuration. See stories for more information
|
|
16
|
+
* @param {Record<string, any>} [props.containerProps] - Props that will be passed to the chart container
|
|
17
|
+
* @param {forwardRef} forwardRef - A function that creates a higher order component that forwards the ref through the component tree.
|
|
18
|
+
*
|
|
19
|
+
* @returns {React.FC<ChartAnalyticsProps & { ref: React.Ref<unknown> }>} - The DHIS2 chart component with forward ref support.
|
|
20
|
+
*/
|
|
21
|
+
export declare const DHIS2Chart: React.FC<ChartAnalyticsProps>;
|
|
22
|
+
/**
|
|
23
|
+
* @deprecated since `v2`. Use `DHIS2Chart` instead
|
|
24
|
+
* */
|
|
25
|
+
export declare const ChartAnalytics: React.FC<ChartAnalyticsProps>;
|
|
26
|
+
//# sourceMappingURL=DHIS2Chart.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DHIS2Chart.d.ts","sourceRoot":"","sources":["../../../../src/components/ChartAnalytics/DHIS2Chart.tsx"],"names":[],"mappings":"AAGA,OAAO,KAA6B,MAAM,OAAO,CAAC;AAElD,OAAO,+BAA+B,CAAC;AACvC,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAEvD,cAAc,sBAAsB,CAAC;AACrC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oCAAoC,CAAC;AAuBnD;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,mBAAmB,CAEpD,CAAC;AAEF;;KAEK;AACL,eAAO,MAAM,cAAc,+BAAa,CAAC"}
|
package/{build → dist}/types/components/ChartAnalytics/components/DownloadMenu/components/Menu.d.ts
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
import { ChartExportMenuItem } from "../interfaces/menu";
|
|
1
|
+
import { ChartExportMenuItem } from "../interfaces/menu.js";
|
|
3
2
|
export declare function ChartMenu({ menuRef, onClick, onClose, exclude, }: {
|
|
4
3
|
menuRef: HTMLDivElement;
|
|
5
4
|
onClick: (action: string) => void;
|
|
6
5
|
onClose: () => void;
|
|
7
6
|
exclude?: ChartExportMenuItem[];
|
|
8
|
-
}): JSX.Element;
|
|
7
|
+
}): import("react/jsx-runtime.js").JSX.Element;
|
|
8
|
+
//# sourceMappingURL=Menu.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Menu.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/ChartAnalytics/components/DownloadMenu/components/Menu.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAE5D,wBAAgB,SAAS,CAAC,EACzB,OAAO,EACP,OAAO,EACP,OAAO,EACP,OAAY,GACZ,EAAE;IACF,OAAO,EAAE,cAAc,CAAC;IACxB,OAAO,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,OAAO,CAAC,EAAE,mBAAmB,EAAE,CAAC;CAChC,8CA+CA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"menu.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/ChartAnalytics/components/DownloadMenu/constants/menu.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,iBAAiB;;;;;;GAmC7B,CAAC"}
|