@carto/meridian-ds 2.4.0 → 2.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/dist/{Link-_lzRY1Ay.cjs → Link-CrGCrul0.cjs} +1 -1
- package/dist/{Link-D5fKicEY.js → Link-RfbgGzdR.js} +1 -1
- package/dist/{MenuItem-badiQq9A.js → MenuItem-ZNdBUBvt.js} +1 -1
- package/dist/{MenuItem-YpFpuljU.cjs → MenuItem-nokUtiks.cjs} +1 -1
- package/dist/components/index.cjs +98 -3
- package/dist/components/index.js +100 -5
- package/dist/theme/index.cjs +305 -305
- package/dist/theme/index.js +306 -306
- package/dist/types/components/molecules/Tag.d.ts +1 -1
- package/dist/types/components/organisms/CodeArea/CodeAreaInput.d.ts.map +1 -1
- package/dist/types/components/organisms/CodeArea/index.d.ts +3 -1
- package/dist/types/components/organisms/CodeArea/index.d.ts.map +1 -1
- package/dist/types/components/organisms/CodeArea/useAutocompletion.d.ts +62 -0
- package/dist/types/components/organisms/CodeArea/useAutocompletion.d.ts.map +1 -0
- package/dist/types/components/organisms/CodeArea/utils.d.ts +7 -0
- package/dist/types/components/organisms/CodeArea/utils.d.ts.map +1 -1
- package/dist/types/components/organisms/Dialog/DialogPaper.d.ts +1 -1
- package/dist/types/theme/carto-theme.d.ts +5 -5
- package/dist/types/theme/carto-theme.d.ts.map +1 -1
- package/dist/types/theme/components/buttons.d.ts.map +1 -0
- package/dist/types/theme/components/data-display.d.ts.map +1 -0
- package/dist/types/theme/components/date-pickers.d.ts.map +1 -0
- package/dist/types/theme/components/feedback.d.ts.map +1 -0
- package/dist/types/theme/components/forms.d.ts.map +1 -0
- package/dist/types/theme/components/navigation.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Accordion.stories.d.ts +56 -0
- package/dist/types/theme/components/stories/Accordion.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Breadcrumb.stories.d.ts +58 -0
- package/dist/types/theme/components/stories/Breadcrumb.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/ButtonGroup.stories.d.ts +118 -0
- package/dist/types/theme/components/stories/ButtonGroup.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Checkbox.stories.d.ts +93 -0
- package/dist/types/theme/components/stories/Checkbox.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Chip.stories.d.ts +311 -0
- package/dist/types/theme/components/stories/Chip.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Divider.stories.d.ts +43 -0
- package/dist/types/theme/components/stories/Divider.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/FAB.stories.d.ts +82 -0
- package/dist/types/theme/components/stories/FAB.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/HelperText.stories.d.ts +48 -0
- package/dist/types/theme/components/stories/HelperText.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/InputLabel.stories.d.ts +56 -0
- package/dist/types/theme/components/stories/InputLabel.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/List.stories.d.ts +62 -0
- package/dist/types/theme/components/stories/List.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Paper.stories.d.ts +48 -0
- package/dist/types/theme/components/stories/Paper.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Progress.stories.d.ts +78 -0
- package/dist/types/theme/components/stories/Progress.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Radio.stories.d.ts +75 -0
- package/dist/types/theme/components/stories/Radio.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Slider.stories.d.ts +217 -0
- package/dist/types/theme/components/stories/Slider.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Switch.stories.d.ts +58 -0
- package/dist/types/theme/components/stories/Switch.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Table.stories.d.ts +44 -0
- package/dist/types/theme/components/stories/Table.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/TablePagination.stories.d.ts +27 -0
- package/dist/types/theme/components/stories/TablePagination.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Tabs.stories.d.ts +133 -0
- package/dist/types/theme/components/stories/Tabs.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/TextArea.stories.d.ts +180 -0
- package/dist/types/theme/components/stories/TextArea.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/TextField.stories.d.ts +198 -0
- package/dist/types/theme/components/stories/TextField.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/ToggleButton.stories.d.ts +57 -0
- package/dist/types/theme/components/stories/ToggleButton.stories.d.ts.map +1 -0
- package/dist/types/theme/components/stories/Tooltip.stories.d.ts +73 -0
- package/dist/types/theme/components/stories/Tooltip.stories.d.ts.map +1 -0
- package/dist/types/theme/components/surfaces.d.ts.map +1 -0
- package/dist/types/theme/{sections → helpers}/css-baseline.d.ts.map +1 -1
- package/dist/types/theme/helpers/theme-constants.d.ts.map +1 -0
- package/dist/types/theme/helpers/theme-utils.d.ts.map +1 -0
- package/dist/types/theme/index.d.ts +1 -1
- package/dist/types/theme/index.d.ts.map +1 -1
- package/dist/types/theme/tokens/ColorTokens.stories.d.ts +17 -0
- package/dist/types/theme/tokens/ColorTokens.stories.d.ts.map +1 -0
- package/dist/types/theme/tokens/LayoutTokens.stories.d.ts +30 -0
- package/dist/types/theme/tokens/LayoutTokens.stories.d.ts.map +1 -0
- package/dist/types/theme/tokens/TypographyTokens.stories.d.ts +17 -0
- package/dist/types/theme/tokens/TypographyTokens.stories.d.ts.map +1 -0
- package/dist/types/theme/{sections/palette.d.ts → tokens/colors.d.ts} +1 -1
- package/dist/types/theme/tokens/colors.d.ts.map +1 -0
- package/dist/types/theme/tokens/shadows.d.ts.map +1 -0
- package/dist/types/theme/{sections → tokens}/typography.d.ts +5 -5
- package/dist/types/theme/{sections → tokens}/typography.d.ts.map +1 -1
- package/dist/types/utils/formatterUtils.d.ts +9 -0
- package/dist/types/utils/formatterUtils.d.ts.map +1 -1
- package/dist/types/widgets/BarWidgetUI/BarWidgetUI.stories.d.ts +126 -0
- package/dist/types/widgets/BarWidgetUI/BarWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/BarWidgetUI/BarWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/BarWidgetUI/BarWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/BarWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/BarWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/CategoryWidgetUI/CategoryWidgetUI.stories.d.ts +128 -0
- package/dist/types/widgets/CategoryWidgetUI/CategoryWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/CategoryWidgetUI/CategoryWidgetUI.styled.d.ts +8 -8
- package/dist/types/widgets/CategoryWidgetUI/CategoryWidgetUI.styled.d.ts.map +1 -1
- package/dist/types/widgets/CategoryWidgetUI/CategoryWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/CategoryWidgetUI/CategoryWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/CategoryWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/CategoryWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/ChartLegend.d.ts.map +1 -1
- package/dist/types/widgets/FeatureSelectionWidgetUI/FeatureSelectionWidgetUI.stories.d.ts +74 -0
- package/dist/types/widgets/FeatureSelectionWidgetUI/FeatureSelectionWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/FeatureSelectionWidgetUI/FeatureSelectionWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/FeatureSelectionWidgetUI/FeatureSelectionWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/FormulaWidgetUI/FormulaWidgetUI.stories.d.ts +68 -0
- package/dist/types/widgets/FormulaWidgetUI/FormulaWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/FormulaWidgetUI/FormulaWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/FormulaWidgetUI/FormulaWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/FormulaWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/FormulaWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/HistogramWidgetUI/HistogramWidgetUI.stories.d.ts +114 -0
- package/dist/types/widgets/HistogramWidgetUI/HistogramWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/HistogramWidgetUI/HistogramWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/HistogramWidgetUI/HistogramWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/HistogramWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/HistogramWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/{NoDataAlert.d.ts → NoDataAlert/NoDataAlert.d.ts} +1 -1
- package/dist/types/widgets/NoDataAlert/NoDataAlert.d.ts.map +1 -0
- package/dist/types/widgets/NoDataAlert/NoDataAlert.stories.d.ts +34 -0
- package/dist/types/widgets/NoDataAlert/NoDataAlert.stories.d.ts.map +1 -0
- package/dist/types/widgets/NoDataAlert/index.d.ts +3 -0
- package/dist/types/widgets/NoDataAlert/index.d.ts.map +1 -0
- package/dist/types/widgets/PieWidgetUI/PieWidgetUI.stories.d.ts +107 -0
- package/dist/types/widgets/PieWidgetUI/PieWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/PieWidgetUI/PieWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/PieWidgetUI/PieWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/PieWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/PieWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/PieWidgetUI/usePieCategories.d.ts.map +1 -1
- package/dist/types/widgets/RangeWidgetUI/RangeWidgetUI.stories.d.ts +33 -0
- package/dist/types/widgets/RangeWidgetUI/RangeWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/RangeWidgetUI/RangeWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/RangeWidgetUI/RangeWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/RangeWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/RangeWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/ScatterPlotWidgetUI/ScatterPlotWidgetUI.stories.d.ts +66 -0
- package/dist/types/widgets/ScatterPlotWidgetUI/ScatterPlotWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/ScatterPlotWidgetUI/ScatterPlotWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/ScatterPlotWidgetUI/ScatterPlotWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/ScatterPlotWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/ScatterPlotWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/SkeletonWidgets.d.ts +4 -4
- package/dist/types/widgets/TableWidgetUI/TableWidgetUI.stories.d.ts +223 -0
- package/dist/types/widgets/TableWidgetUI/TableWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/TableWidgetUI/TableWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/TableWidgetUI/TableWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/TableWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/TableWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/TimeSeriesWidgetUI/TimeSeriesWidgetUI.d.ts.map +1 -1
- package/dist/types/widgets/TimeSeriesWidgetUI/TimeSeriesWidgetUI.stories.d.ts +129 -0
- package/dist/types/widgets/TimeSeriesWidgetUI/TimeSeriesWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/TimeSeriesWidgetUI/TimeSeriesWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/TimeSeriesWidgetUI/TimeSeriesWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/TimeSeriesWidgetUI/timeSeriesUtils.test.d.ts +2 -0
- package/dist/types/widgets/TimeSeriesWidgetUI/timeSeriesUtils.test.d.ts.map +1 -0
- package/dist/types/widgets/WrapperWidgetUI/WrapperWidgetUI.d.ts.map +1 -0
- package/dist/types/widgets/WrapperWidgetUI/WrapperWidgetUI.stories.d.ts +195 -0
- package/dist/types/widgets/WrapperWidgetUI/WrapperWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/WrapperWidgetUI/WrapperWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/WrapperWidgetUI/WrapperWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/WrapperWidgetUI/index.d.ts +3 -0
- package/dist/types/widgets/WrapperWidgetUI/index.d.ts.map +1 -0
- package/dist/types/widgets/comparative/ComparativeCategoryWidgetUI/ComparativeCategoryWidgetUI.d.ts +1 -1
- package/dist/types/widgets/comparative/ComparativeCategoryWidgetUI/ComparativeCategoryWidgetUI.d.ts.map +1 -1
- package/dist/types/widgets/comparative/ComparativeCategoryWidgetUI/ComparativeCategoryWidgetUI.stories.d.ts +35 -0
- package/dist/types/widgets/comparative/ComparativeCategoryWidgetUI/ComparativeCategoryWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/comparative/ComparativeCategoryWidgetUI/ComparativeCategoryWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/comparative/ComparativeCategoryWidgetUI/ComparativeCategoryWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/comparative/ComparativeCategoryWidgetUI/transposeCategoryData.d.ts +1 -1
- package/dist/types/widgets/comparative/ComparativeCategoryWidgetUI/transposeCategoryData.d.ts.map +1 -1
- package/dist/types/widgets/comparative/ComparativeFormulaWidgetUI/ComparativeFormulaWidgetUI.stories.d.ts +31 -0
- package/dist/types/widgets/comparative/ComparativeFormulaWidgetUI/ComparativeFormulaWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/comparative/ComparativeFormulaWidgetUI/ComparativeFormulaWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/comparative/ComparativeFormulaWidgetUI/ComparativeFormulaWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/comparative/{ComparativePieWidgetUI.d.ts → ComparativePieWidgetUI/ComparativePieWidgetUI.d.ts} +1 -1
- package/dist/types/widgets/comparative/ComparativePieWidgetUI/ComparativePieWidgetUI.d.ts.map +1 -0
- package/dist/types/widgets/comparative/ComparativePieWidgetUI/ComparativePieWidgetUI.stories.d.ts +45 -0
- package/dist/types/widgets/comparative/ComparativePieWidgetUI/ComparativePieWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/comparative/ComparativePieWidgetUI/ComparativePieWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/comparative/ComparativePieWidgetUI/ComparativePieWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/comparative/index.d.ts +7 -0
- package/dist/types/widgets/comparative/index.d.ts.map +1 -0
- package/dist/types/widgets/index.d.ts +11 -29
- package/dist/types/widgets/index.d.ts.map +1 -1
- package/dist/types/widgets/legend/LegendCategories.stories.d.ts +46 -0
- package/dist/types/widgets/legend/LegendCategories.stories.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendCategories.test.d.ts +2 -0
- package/dist/types/widgets/legend/LegendCategories.test.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendIcon.stories.d.ts +27 -0
- package/dist/types/widgets/legend/LegendIcon.stories.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendIcon.test.d.ts +2 -0
- package/dist/types/widgets/legend/LegendIcon.test.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendProportion.stories.d.ts +26 -0
- package/dist/types/widgets/legend/LegendProportion.stories.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendProportion.test.d.ts +2 -0
- package/dist/types/widgets/legend/LegendProportion.test.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendRamp.stories.d.ts +62 -0
- package/dist/types/widgets/legend/LegendRamp.stories.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendRamp.test.d.ts +2 -0
- package/dist/types/widgets/legend/LegendRamp.test.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendWidgetUI.stories.d.ts +228 -0
- package/dist/types/widgets/legend/LegendWidgetUI.stories.d.ts.map +1 -0
- package/dist/types/widgets/legend/LegendWidgetUI.styles.d.ts +1 -1
- package/dist/types/widgets/legend/LegendWidgetUI.test.d.ts +2 -0
- package/dist/types/widgets/legend/LegendWidgetUI.test.d.ts.map +1 -0
- package/dist/types/widgets/legend/legendFixtures.d.ts +168 -0
- package/dist/types/widgets/legend/legendFixtures.d.ts.map +1 -0
- package/dist/widgets/index.cjs +250 -249
- package/dist/widgets/index.js +252 -251
- package/package.json +4 -1
- package/dist/types/theme/sections/components/buttons.d.ts.map +0 -1
- package/dist/types/theme/sections/components/data-display.d.ts.map +0 -1
- package/dist/types/theme/sections/components/date-pickers.d.ts.map +0 -1
- package/dist/types/theme/sections/components/feedback.d.ts.map +0 -1
- package/dist/types/theme/sections/components/forms.d.ts.map +0 -1
- package/dist/types/theme/sections/components/navigation.d.ts.map +0 -1
- package/dist/types/theme/sections/components/surfaces.d.ts.map +0 -1
- package/dist/types/theme/sections/palette.d.ts.map +0 -1
- package/dist/types/theme/sections/shadows.d.ts.map +0 -1
- package/dist/types/theme/theme-constants.d.ts.map +0 -1
- package/dist/types/theme/theme-utils.d.ts.map +0 -1
- package/dist/types/widgets/NoDataAlert.d.ts.map +0 -1
- package/dist/types/widgets/WrapperWidgetUI.d.ts.map +0 -1
- package/dist/types/widgets/comparative/ComparativePieWidgetUI.d.ts.map +0 -1
- package/dist/{TablePaginationActions-CCDi-BO-.js → TablePaginationActions-C6TVGJM-.js} +25 -25
- package/dist/{TablePaginationActions-D2K26kdR.cjs → TablePaginationActions-DAMGtIub.cjs} +25 -25
- /package/dist/types/theme/{sections/components → components}/buttons.d.ts +0 -0
- /package/dist/types/theme/{sections/components → components}/data-display.d.ts +0 -0
- /package/dist/types/theme/{sections/components → components}/date-pickers.d.ts +0 -0
- /package/dist/types/theme/{sections/components → components}/feedback.d.ts +0 -0
- /package/dist/types/theme/{sections/components → components}/forms.d.ts +0 -0
- /package/dist/types/theme/{sections/components → components}/navigation.d.ts +0 -0
- /package/dist/types/theme/{sections/components → components}/surfaces.d.ts +0 -0
- /package/dist/types/theme/{sections → helpers}/css-baseline.d.ts +0 -0
- /package/dist/types/theme/{theme-constants.d.ts → helpers/theme-constants.d.ts} +0 -0
- /package/dist/types/theme/{theme-utils.d.ts → helpers/theme-utils.d.ts} +0 -0
- /package/dist/types/theme/{sections → tokens}/shadows.d.ts +0 -0
- /package/dist/types/widgets/{WrapperWidgetUI.d.ts → WrapperWidgetUI/WrapperWidgetUI.d.ts} +0 -0
package/dist/widgets/index.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
2
2
|
import React, { useMemo, useState, useEffect, useCallback, useRef, createContext, useContext, useLayoutEffect, createRef } from "react";
|
|
3
|
-
import { useTheme, styled, Box, Skeleton, Grid, Link, darken, Button, Divider, TextField, InputAdornment, Checkbox, Tooltip, debounce, Slider, TableCell, Table, TableHead, TableRow, TableBody, TableContainer, TableSortLabel, TablePagination, IconButton as IconButton$1, Menu, MenuItem, SvgIcon,
|
|
3
|
+
import { useTheme, styled, Box, Skeleton, Grid, Link, darken, Button, Divider, TextField, InputAdornment, Checkbox, Tooltip, debounce, Slider, TableCell, Table, TableHead, TableRow, TableBody, TableContainer, TableSortLabel, TablePagination, IconButton as IconButton$1, Menu, MenuItem, SvgIcon, Icon, Collapse, LinearProgress, Typography as Typography$1, lighten, ClickAwayListener, ToggleButton, capitalize, ListItem, Chip, List, Paper, Popover, Select, ListItemText, Drawer } from "@mui/material";
|
|
4
4
|
import { useIntl } from "react-intl";
|
|
5
|
-
import { h as getDefaultExportFromCjs, u as useImperativeIntl, T as Typography, S as SPACING, B as BREAKPOINTS, a as TablePaginationActions, b as ICON_SIZE_MEDIUM } from "../TablePaginationActions-
|
|
5
|
+
import { h as getDefaultExportFromCjs, u as useImperativeIntl, T as Typography, S as SPACING, B as BREAKPOINTS, a as TablePaginationActions, b as ICON_SIZE_MEDIUM } from "../TablePaginationActions-C6TVGJM-.js";
|
|
6
6
|
import _ReactEcharts from "echarts-for-react";
|
|
7
7
|
import { FixedSizeList } from "react-window";
|
|
8
8
|
import { S as Search, a as SwatchSquare } from "../SwatchSquare-CaaLsjAC.js";
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
9
|
+
import { A as Alert, I as IconButton, L as Link$1 } from "../Link-RfbgGzdR.js";
|
|
10
|
+
import { ChevronLeft, ChevronRight, ExpandLess, ExpandMore, MoreVert, KeyboardArrowDown, ErrorOutline, Cancel, VisibilityOutlined, VisibilityOffOutlined, Close, LayersOutlined } from "@mui/icons-material";
|
|
11
11
|
import { a as getColorByCategory, c as commonPalette, b as getPalette } from "../paletteUtils-BHqJlHm9.js";
|
|
12
12
|
function detectTouchscreen() {
|
|
13
13
|
let result = false;
|
|
@@ -1804,6 +1804,32 @@ function formatData(data, ticks, min, max) {
|
|
|
1804
1804
|
]
|
|
1805
1805
|
);
|
|
1806
1806
|
}
|
|
1807
|
+
function AlertBody({
|
|
1808
|
+
color = void 0,
|
|
1809
|
+
children
|
|
1810
|
+
}) {
|
|
1811
|
+
return children ? /* @__PURE__ */ jsx(Box, { mt: 0.5, children: /* @__PURE__ */ jsx(
|
|
1812
|
+
Typography,
|
|
1813
|
+
{
|
|
1814
|
+
component: "div",
|
|
1815
|
+
variant: "caption",
|
|
1816
|
+
color: color ?? "inherit",
|
|
1817
|
+
style: { fontWeight: "normal" },
|
|
1818
|
+
children
|
|
1819
|
+
}
|
|
1820
|
+
) }) : /* @__PURE__ */ jsx(Box, { mt: -1 });
|
|
1821
|
+
}
|
|
1822
|
+
function NoDataAlert({
|
|
1823
|
+
title = "No data available",
|
|
1824
|
+
body = "There are no results for the combination of filters applied to your data. Try tweaking your filters, or zoom and pan the map to adjust the Map View.",
|
|
1825
|
+
severity = void 0,
|
|
1826
|
+
...otherProps
|
|
1827
|
+
}) {
|
|
1828
|
+
return severity ? /* @__PURE__ */ jsx(Alert, { title, severity, ...otherProps, children: /* @__PURE__ */ jsx(AlertBody, { children: body }) }) : /* @__PURE__ */ jsxs(Box, { ...otherProps, children: [
|
|
1829
|
+
title && /* @__PURE__ */ jsx(Typography, { variant: "body2", children: title }),
|
|
1830
|
+
/* @__PURE__ */ jsx(AlertBody, { color: "textSecondary", children: body })
|
|
1831
|
+
] });
|
|
1832
|
+
}
|
|
1807
1833
|
function usePieCategories(data, order, maxItems, colors, othersValue) {
|
|
1808
1834
|
const theme = useTheme();
|
|
1809
1835
|
const orderedData = useMemo(() => {
|
|
@@ -4824,6 +4850,223 @@ function TimeSeriesWidgetUIContent({
|
|
|
4824
4850
|
}
|
|
4825
4851
|
);
|
|
4826
4852
|
}
|
|
4853
|
+
const Root = styled(Box, {
|
|
4854
|
+
shouldForwardProp: (prop) => prop !== "margin"
|
|
4855
|
+
})(({ theme, margin }) => {
|
|
4856
|
+
return {
|
|
4857
|
+
margin: 0,
|
|
4858
|
+
position: "relative",
|
|
4859
|
+
maxWidth: "100%",
|
|
4860
|
+
padding: margin ?? theme.spacing(2, 2.5)
|
|
4861
|
+
};
|
|
4862
|
+
});
|
|
4863
|
+
const LoadingBar = styled(LinearProgress)(({ theme }) => ({
|
|
4864
|
+
position: "absolute",
|
|
4865
|
+
top: 0,
|
|
4866
|
+
left: 0,
|
|
4867
|
+
width: "100%",
|
|
4868
|
+
height: theme.spacing(0.25)
|
|
4869
|
+
}));
|
|
4870
|
+
const Header = styled(Grid, {
|
|
4871
|
+
shouldForwardProp: (prop) => prop !== "expanded"
|
|
4872
|
+
})(({ theme, expanded = true }) => ({
|
|
4873
|
+
display: "flex",
|
|
4874
|
+
flexDirection: "row",
|
|
4875
|
+
alignItems: "flex-start",
|
|
4876
|
+
justifyContent: "space-between",
|
|
4877
|
+
width: "100%",
|
|
4878
|
+
...expanded ? { minHeight: theme.spacing(3) } : { height: theme.spacing(3) },
|
|
4879
|
+
padding: 0
|
|
4880
|
+
}));
|
|
4881
|
+
const HeaderButton = styled(Button, {
|
|
4882
|
+
shouldForwardProp: (prop) => prop !== "expandable"
|
|
4883
|
+
})(({ theme, expandable = true }) => ({
|
|
4884
|
+
flex: 1,
|
|
4885
|
+
padding: 0,
|
|
4886
|
+
alignItems: "flex-start",
|
|
4887
|
+
justifyContent: "flex-start",
|
|
4888
|
+
height: "auto",
|
|
4889
|
+
minHeight: "auto",
|
|
4890
|
+
marginBottom: theme.spacing(1),
|
|
4891
|
+
cursor: expandable ? "pointer" : "default",
|
|
4892
|
+
"& .MuiButton-startIcon": {
|
|
4893
|
+
marginTop: "3px",
|
|
4894
|
+
marginRight: theme.spacing(1)
|
|
4895
|
+
},
|
|
4896
|
+
"&:hover": {
|
|
4897
|
+
background: "none"
|
|
4898
|
+
}
|
|
4899
|
+
}));
|
|
4900
|
+
const ParentIcon = ({ theme }) => ({
|
|
4901
|
+
display: "flex",
|
|
4902
|
+
alignItems: "center",
|
|
4903
|
+
justifyContent: "center",
|
|
4904
|
+
width: theme.spacing(3),
|
|
4905
|
+
height: theme.spacing(3),
|
|
4906
|
+
color: theme.palette.text.secondary
|
|
4907
|
+
});
|
|
4908
|
+
const HideButton = styled(ExpandLess)(({ theme }) => ParentIcon({ theme }));
|
|
4909
|
+
const ShowButton = styled(ExpandMore)(({ theme }) => ParentIcon({ theme }));
|
|
4910
|
+
const Text = styled(Typography$1, {
|
|
4911
|
+
shouldForwardProp: (prop) => prop !== "expanded"
|
|
4912
|
+
})(({ expanded = true }) => ({
|
|
4913
|
+
wordBreak: "break-word",
|
|
4914
|
+
overflow: "hidden",
|
|
4915
|
+
...expanded && {
|
|
4916
|
+
display: "-webkit-box",
|
|
4917
|
+
WebkitLineClamp: 2,
|
|
4918
|
+
WebkitBoxOrient: "vertical"
|
|
4919
|
+
},
|
|
4920
|
+
...!expanded && {
|
|
4921
|
+
whiteSpace: "nowrap",
|
|
4922
|
+
textOverflow: "ellipsis"
|
|
4923
|
+
}
|
|
4924
|
+
}));
|
|
4925
|
+
const HeaderItems = styled(Grid)(({ theme }) => ({
|
|
4926
|
+
display: "flex",
|
|
4927
|
+
alignItems: "center",
|
|
4928
|
+
gap: theme.spacing(1),
|
|
4929
|
+
marginRight: theme.spacing(-0.5),
|
|
4930
|
+
marginLeft: theme.spacing(1)
|
|
4931
|
+
}));
|
|
4932
|
+
const IconActionButton = styled(IconButton$1)(({ theme }) => ({
|
|
4933
|
+
color: theme.palette.text.secondary
|
|
4934
|
+
}));
|
|
4935
|
+
const PaperMenu = styled(Menu)(({ theme }) => ({
|
|
4936
|
+
".MuiPaper-root": {
|
|
4937
|
+
marginTop: theme.spacing(5),
|
|
4938
|
+
maxHeight: theme.spacing(21),
|
|
4939
|
+
minWidth: theme.spacing(16)
|
|
4940
|
+
}
|
|
4941
|
+
}));
|
|
4942
|
+
const EMPTY_ARR$2 = [];
|
|
4943
|
+
const defaultOptionsIcon = /* @__PURE__ */ jsx(MoreVert, {});
|
|
4944
|
+
function WrapperWidgetUI({
|
|
4945
|
+
title,
|
|
4946
|
+
actions = EMPTY_ARR$2,
|
|
4947
|
+
options = EMPTY_ARR$2,
|
|
4948
|
+
optionsIcon = defaultOptionsIcon,
|
|
4949
|
+
children,
|
|
4950
|
+
contentProps,
|
|
4951
|
+
disabled = false,
|
|
4952
|
+
expandable = true,
|
|
4953
|
+
expanded: _expanded = true,
|
|
4954
|
+
onExpandedChange,
|
|
4955
|
+
footer,
|
|
4956
|
+
headerItems,
|
|
4957
|
+
isLoading = false,
|
|
4958
|
+
margin
|
|
4959
|
+
}) {
|
|
4960
|
+
const wrapper = createRef();
|
|
4961
|
+
const [expandedInt, setExpandedInt] = useState(true);
|
|
4962
|
+
const externalExpanded = _expanded !== void 0 && onExpandedChange !== void 0;
|
|
4963
|
+
const expanded = expandable !== false ? externalExpanded ? _expanded : expandedInt : true;
|
|
4964
|
+
const setExpanded = externalExpanded ? onExpandedChange : setExpandedInt;
|
|
4965
|
+
const [anchorEl, setAnchorEl] = useState(null);
|
|
4966
|
+
const open = Boolean(anchorEl);
|
|
4967
|
+
const handleExpandClick = () => {
|
|
4968
|
+
if (expandable) {
|
|
4969
|
+
setExpanded(!expanded);
|
|
4970
|
+
}
|
|
4971
|
+
};
|
|
4972
|
+
const handleClick = (ev) => setAnchorEl(ev.currentTarget);
|
|
4973
|
+
const handleClose = () => setAnchorEl(null);
|
|
4974
|
+
function handleOptionAction(action) {
|
|
4975
|
+
if (action) {
|
|
4976
|
+
action();
|
|
4977
|
+
}
|
|
4978
|
+
handleClose();
|
|
4979
|
+
}
|
|
4980
|
+
const iconButtonTooltip = (action) => {
|
|
4981
|
+
return /* @__PURE__ */ jsx(
|
|
4982
|
+
IconActionButton,
|
|
4983
|
+
{
|
|
4984
|
+
"aria-label": action.label,
|
|
4985
|
+
onClick: action.action,
|
|
4986
|
+
size: "small",
|
|
4987
|
+
children: action.icon
|
|
4988
|
+
},
|
|
4989
|
+
action.id
|
|
4990
|
+
);
|
|
4991
|
+
};
|
|
4992
|
+
if (disabled) {
|
|
4993
|
+
return children ? /* @__PURE__ */ jsx(Fragment, { children }) : null;
|
|
4994
|
+
}
|
|
4995
|
+
return /* @__PURE__ */ jsxs(Root, { margin, component: "section", "aria-label": title, children: [
|
|
4996
|
+
isLoading ? /* @__PURE__ */ jsx(LoadingBar, {}) : null,
|
|
4997
|
+
/* @__PURE__ */ jsxs(Header, { container: true, expanded: _expanded, children: [
|
|
4998
|
+
/* @__PURE__ */ jsx(
|
|
4999
|
+
HeaderButton,
|
|
5000
|
+
{
|
|
5001
|
+
expandable,
|
|
5002
|
+
startIcon: expandable && /* @__PURE__ */ jsx(Icon, { children: expanded ? /* @__PURE__ */ jsx(HideButton, {}) : /* @__PURE__ */ jsx(ShowButton, {}) }),
|
|
5003
|
+
onClick: handleExpandClick,
|
|
5004
|
+
tabIndex: expandable ? 0 : -1,
|
|
5005
|
+
children: /* @__PURE__ */ jsx(Tooltip, { title, children: /* @__PURE__ */ jsx(Text, { expanded: _expanded, align: "left", variant: "subtitle1", children: title }) })
|
|
5006
|
+
}
|
|
5007
|
+
),
|
|
5008
|
+
/* @__PURE__ */ jsxs(HeaderItems, { item: true, children: [
|
|
5009
|
+
headerItems,
|
|
5010
|
+
actions.length > 0 && actions.map((action) => {
|
|
5011
|
+
return action.tooltip ? /* @__PURE__ */ jsx(
|
|
5012
|
+
Tooltip,
|
|
5013
|
+
{
|
|
5014
|
+
title: action.tooltip.text,
|
|
5015
|
+
placement: action.tooltip.placement ?? "top",
|
|
5016
|
+
children: iconButtonTooltip(action)
|
|
5017
|
+
},
|
|
5018
|
+
action.id
|
|
5019
|
+
) : iconButtonTooltip(action);
|
|
5020
|
+
}),
|
|
5021
|
+
options.length > 0 && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
5022
|
+
/* @__PURE__ */ jsx(
|
|
5023
|
+
IconActionButton,
|
|
5024
|
+
{
|
|
5025
|
+
"aria-label": "Options",
|
|
5026
|
+
"aria-controls": "options-menu",
|
|
5027
|
+
"aria-haspopup": "true",
|
|
5028
|
+
onClick: handleClick,
|
|
5029
|
+
size: "small",
|
|
5030
|
+
children: optionsIcon
|
|
5031
|
+
}
|
|
5032
|
+
),
|
|
5033
|
+
/* @__PURE__ */ jsx(
|
|
5034
|
+
PaperMenu,
|
|
5035
|
+
{
|
|
5036
|
+
id: "options-menu",
|
|
5037
|
+
elevation: 8,
|
|
5038
|
+
anchorOrigin: {
|
|
5039
|
+
vertical: "top",
|
|
5040
|
+
horizontal: "right"
|
|
5041
|
+
},
|
|
5042
|
+
transformOrigin: {
|
|
5043
|
+
vertical: "top",
|
|
5044
|
+
horizontal: "right"
|
|
5045
|
+
},
|
|
5046
|
+
anchorEl,
|
|
5047
|
+
keepMounted: true,
|
|
5048
|
+
open,
|
|
5049
|
+
onClose: handleClose,
|
|
5050
|
+
children: options.map((option) => /* @__PURE__ */ jsx(
|
|
5051
|
+
MenuItem,
|
|
5052
|
+
{
|
|
5053
|
+
selected: option.selected,
|
|
5054
|
+
onClick: () => handleOptionAction(option.action),
|
|
5055
|
+
children: option.name
|
|
5056
|
+
},
|
|
5057
|
+
option.id
|
|
5058
|
+
))
|
|
5059
|
+
}
|
|
5060
|
+
)
|
|
5061
|
+
] })
|
|
5062
|
+
] })
|
|
5063
|
+
] }),
|
|
5064
|
+
/* @__PURE__ */ jsx(Collapse, { ref: wrapper, in: expanded, timeout: "auto", unmountOnExit: true, children: /* @__PURE__ */ jsxs(Box, { ...contentProps, children: [
|
|
5065
|
+
/* @__PURE__ */ jsx(Box, { pt: 1, children }),
|
|
5066
|
+
footer ?? /* @__PURE__ */ jsx(Box, { children: footer })
|
|
5067
|
+
] }) })
|
|
5068
|
+
] });
|
|
5069
|
+
}
|
|
4827
5070
|
const Wrapper = styled("div")(({ theme }) => ({
|
|
4828
5071
|
padding: theme.spacing(2, 0),
|
|
4829
5072
|
...theme.typography.body2
|
|
@@ -5929,10 +6172,10 @@ const StylesWrapper = styled(Paper)(({ theme }) => ({
|
|
|
5929
6172
|
maxHeight: theme.spacing(5),
|
|
5930
6173
|
padding: theme.spacing(0.5)
|
|
5931
6174
|
}));
|
|
5932
|
-
const EMPTY_ARR$
|
|
6175
|
+
const EMPTY_ARR$1 = [];
|
|
5933
6176
|
function FeatureSelectionWidgetUI({
|
|
5934
6177
|
selectionModes,
|
|
5935
|
-
editModes = EMPTY_ARR$
|
|
6178
|
+
editModes = EMPTY_ARR$1,
|
|
5936
6179
|
selectedMode,
|
|
5937
6180
|
onSelectMode,
|
|
5938
6181
|
enabled = false,
|
|
@@ -6859,10 +7102,10 @@ function getZoomHelperText({
|
|
|
6859
7102
|
}
|
|
6860
7103
|
const EMPTY_OBJ = {};
|
|
6861
7104
|
const EMPTY_FN = () => void 0;
|
|
6862
|
-
const EMPTY_ARR
|
|
7105
|
+
const EMPTY_ARR = [];
|
|
6863
7106
|
function LegendWidgetUI({
|
|
6864
7107
|
customLegendTypes = EMPTY_OBJ,
|
|
6865
|
-
layers = EMPTY_ARR
|
|
7108
|
+
layers = EMPTY_ARR,
|
|
6866
7109
|
collapsed = false,
|
|
6867
7110
|
onChangeCollapsed = EMPTY_FN,
|
|
6868
7111
|
onChangeVisibility = EMPTY_FN,
|
|
@@ -6942,249 +7185,6 @@ function LegendWidgetUI({
|
|
|
6942
7185
|
)) }) })
|
|
6943
7186
|
] }) });
|
|
6944
7187
|
}
|
|
6945
|
-
function AlertBody({
|
|
6946
|
-
color = void 0,
|
|
6947
|
-
children
|
|
6948
|
-
}) {
|
|
6949
|
-
return children ? /* @__PURE__ */ jsx(Box, { mt: 0.5, children: /* @__PURE__ */ jsx(
|
|
6950
|
-
Typography,
|
|
6951
|
-
{
|
|
6952
|
-
component: "div",
|
|
6953
|
-
variant: "caption",
|
|
6954
|
-
color: color ?? "inherit",
|
|
6955
|
-
style: { fontWeight: "normal" },
|
|
6956
|
-
children
|
|
6957
|
-
}
|
|
6958
|
-
) }) : /* @__PURE__ */ jsx(Box, { mt: -1 });
|
|
6959
|
-
}
|
|
6960
|
-
function NoDataAlert({
|
|
6961
|
-
title = "No data available",
|
|
6962
|
-
body = "There are no results for the combination of filters applied to your data. Try tweaking your filters, or zoom and pan the map to adjust the Map View.",
|
|
6963
|
-
severity = void 0,
|
|
6964
|
-
...otherProps
|
|
6965
|
-
}) {
|
|
6966
|
-
return severity ? /* @__PURE__ */ jsx(Alert, { title, severity, ...otherProps, children: /* @__PURE__ */ jsx(AlertBody, { children: body }) }) : /* @__PURE__ */ jsxs(Box, { ...otherProps, children: [
|
|
6967
|
-
title && /* @__PURE__ */ jsx(Typography, { variant: "body2", children: title }),
|
|
6968
|
-
/* @__PURE__ */ jsx(AlertBody, { color: "textSecondary", children: body })
|
|
6969
|
-
] });
|
|
6970
|
-
}
|
|
6971
|
-
const Root = styled(Box, {
|
|
6972
|
-
shouldForwardProp: (prop) => prop !== "margin"
|
|
6973
|
-
})(({ theme, margin }) => {
|
|
6974
|
-
return {
|
|
6975
|
-
margin: 0,
|
|
6976
|
-
position: "relative",
|
|
6977
|
-
maxWidth: "100%",
|
|
6978
|
-
padding: margin ?? theme.spacing(2, 2.5)
|
|
6979
|
-
};
|
|
6980
|
-
});
|
|
6981
|
-
const LoadingBar = styled(LinearProgress)(({ theme }) => ({
|
|
6982
|
-
position: "absolute",
|
|
6983
|
-
top: 0,
|
|
6984
|
-
left: 0,
|
|
6985
|
-
width: "100%",
|
|
6986
|
-
height: theme.spacing(0.25)
|
|
6987
|
-
}));
|
|
6988
|
-
const Header = styled(Grid, {
|
|
6989
|
-
shouldForwardProp: (prop) => prop !== "expanded"
|
|
6990
|
-
})(({ theme, expanded = true }) => ({
|
|
6991
|
-
display: "flex",
|
|
6992
|
-
flexDirection: "row",
|
|
6993
|
-
alignItems: "flex-start",
|
|
6994
|
-
justifyContent: "space-between",
|
|
6995
|
-
width: "100%",
|
|
6996
|
-
...expanded ? { minHeight: theme.spacing(3) } : { height: theme.spacing(3) },
|
|
6997
|
-
padding: 0
|
|
6998
|
-
}));
|
|
6999
|
-
const HeaderButton = styled(Button, {
|
|
7000
|
-
shouldForwardProp: (prop) => prop !== "expandable"
|
|
7001
|
-
})(({ theme, expandable = true }) => ({
|
|
7002
|
-
flex: 1,
|
|
7003
|
-
padding: 0,
|
|
7004
|
-
alignItems: "flex-start",
|
|
7005
|
-
justifyContent: "flex-start",
|
|
7006
|
-
height: "auto",
|
|
7007
|
-
minHeight: "auto",
|
|
7008
|
-
marginBottom: theme.spacing(1),
|
|
7009
|
-
cursor: expandable ? "pointer" : "default",
|
|
7010
|
-
"& .MuiButton-startIcon": {
|
|
7011
|
-
marginTop: "3px",
|
|
7012
|
-
marginRight: theme.spacing(1)
|
|
7013
|
-
},
|
|
7014
|
-
"&:hover": {
|
|
7015
|
-
background: "none"
|
|
7016
|
-
}
|
|
7017
|
-
}));
|
|
7018
|
-
const ParentIcon = ({ theme }) => ({
|
|
7019
|
-
display: "flex",
|
|
7020
|
-
alignItems: "center",
|
|
7021
|
-
justifyContent: "center",
|
|
7022
|
-
width: theme.spacing(3),
|
|
7023
|
-
height: theme.spacing(3),
|
|
7024
|
-
color: theme.palette.text.secondary
|
|
7025
|
-
});
|
|
7026
|
-
const HideButton = styled(ExpandLess)(({ theme }) => ParentIcon({ theme }));
|
|
7027
|
-
const ShowButton = styled(ExpandMore)(({ theme }) => ParentIcon({ theme }));
|
|
7028
|
-
const Text = styled(Typography$1, {
|
|
7029
|
-
shouldForwardProp: (prop) => prop !== "expanded"
|
|
7030
|
-
})(({ expanded = true }) => ({
|
|
7031
|
-
wordBreak: "break-word",
|
|
7032
|
-
overflow: "hidden",
|
|
7033
|
-
...expanded && {
|
|
7034
|
-
display: "-webkit-box",
|
|
7035
|
-
WebkitLineClamp: 2,
|
|
7036
|
-
WebkitBoxOrient: "vertical"
|
|
7037
|
-
},
|
|
7038
|
-
...!expanded && {
|
|
7039
|
-
whiteSpace: "nowrap",
|
|
7040
|
-
textOverflow: "ellipsis"
|
|
7041
|
-
}
|
|
7042
|
-
}));
|
|
7043
|
-
const HeaderItems = styled(Grid)(({ theme }) => ({
|
|
7044
|
-
display: "flex",
|
|
7045
|
-
alignItems: "center",
|
|
7046
|
-
gap: theme.spacing(1),
|
|
7047
|
-
marginRight: theme.spacing(-0.5),
|
|
7048
|
-
marginLeft: theme.spacing(1)
|
|
7049
|
-
}));
|
|
7050
|
-
const IconActionButton = styled(IconButton$1)(({ theme }) => ({
|
|
7051
|
-
color: theme.palette.text.secondary
|
|
7052
|
-
}));
|
|
7053
|
-
const PaperMenu = styled(Menu)(({ theme }) => ({
|
|
7054
|
-
".MuiPaper-root": {
|
|
7055
|
-
marginTop: theme.spacing(5),
|
|
7056
|
-
maxHeight: theme.spacing(21),
|
|
7057
|
-
minWidth: theme.spacing(16)
|
|
7058
|
-
}
|
|
7059
|
-
}));
|
|
7060
|
-
const EMPTY_ARR = [];
|
|
7061
|
-
const defaultOptionsIcon = /* @__PURE__ */ jsx(MoreVert, {});
|
|
7062
|
-
function WrapperWidgetUI({
|
|
7063
|
-
title,
|
|
7064
|
-
actions = EMPTY_ARR,
|
|
7065
|
-
options = EMPTY_ARR,
|
|
7066
|
-
optionsIcon = defaultOptionsIcon,
|
|
7067
|
-
children,
|
|
7068
|
-
contentProps,
|
|
7069
|
-
disabled = false,
|
|
7070
|
-
expandable = true,
|
|
7071
|
-
expanded: _expanded = true,
|
|
7072
|
-
onExpandedChange,
|
|
7073
|
-
footer,
|
|
7074
|
-
headerItems,
|
|
7075
|
-
isLoading = false,
|
|
7076
|
-
margin
|
|
7077
|
-
}) {
|
|
7078
|
-
const wrapper = createRef();
|
|
7079
|
-
const [expandedInt, setExpandedInt] = useState(true);
|
|
7080
|
-
const externalExpanded = _expanded !== void 0 && onExpandedChange !== void 0;
|
|
7081
|
-
const expanded = expandable !== false ? externalExpanded ? _expanded : expandedInt : true;
|
|
7082
|
-
const setExpanded = externalExpanded ? onExpandedChange : setExpandedInt;
|
|
7083
|
-
const [anchorEl, setAnchorEl] = useState(null);
|
|
7084
|
-
const open = Boolean(anchorEl);
|
|
7085
|
-
const handleExpandClick = () => {
|
|
7086
|
-
if (expandable) {
|
|
7087
|
-
setExpanded(!expanded);
|
|
7088
|
-
}
|
|
7089
|
-
};
|
|
7090
|
-
const handleClick = (ev) => setAnchorEl(ev.currentTarget);
|
|
7091
|
-
const handleClose = () => setAnchorEl(null);
|
|
7092
|
-
function handleOptionAction(action) {
|
|
7093
|
-
if (action) {
|
|
7094
|
-
action();
|
|
7095
|
-
}
|
|
7096
|
-
handleClose();
|
|
7097
|
-
}
|
|
7098
|
-
const iconButtonTooltip = (action) => {
|
|
7099
|
-
return /* @__PURE__ */ jsx(
|
|
7100
|
-
IconActionButton,
|
|
7101
|
-
{
|
|
7102
|
-
"aria-label": action.label,
|
|
7103
|
-
onClick: action.action,
|
|
7104
|
-
size: "small",
|
|
7105
|
-
children: action.icon
|
|
7106
|
-
},
|
|
7107
|
-
action.id
|
|
7108
|
-
);
|
|
7109
|
-
};
|
|
7110
|
-
if (disabled) {
|
|
7111
|
-
return children ? /* @__PURE__ */ jsx(Fragment, { children }) : null;
|
|
7112
|
-
}
|
|
7113
|
-
return /* @__PURE__ */ jsxs(Root, { margin, component: "section", "aria-label": title, children: [
|
|
7114
|
-
isLoading ? /* @__PURE__ */ jsx(LoadingBar, {}) : null,
|
|
7115
|
-
/* @__PURE__ */ jsxs(Header, { container: true, expanded: _expanded, children: [
|
|
7116
|
-
/* @__PURE__ */ jsx(
|
|
7117
|
-
HeaderButton,
|
|
7118
|
-
{
|
|
7119
|
-
expandable,
|
|
7120
|
-
startIcon: expandable && /* @__PURE__ */ jsx(Icon, { children: expanded ? /* @__PURE__ */ jsx(HideButton, {}) : /* @__PURE__ */ jsx(ShowButton, {}) }),
|
|
7121
|
-
onClick: handleExpandClick,
|
|
7122
|
-
tabIndex: expandable ? 0 : -1,
|
|
7123
|
-
children: /* @__PURE__ */ jsx(Tooltip, { title, children: /* @__PURE__ */ jsx(Text, { expanded: _expanded, align: "left", variant: "subtitle1", children: title }) })
|
|
7124
|
-
}
|
|
7125
|
-
),
|
|
7126
|
-
/* @__PURE__ */ jsxs(HeaderItems, { item: true, children: [
|
|
7127
|
-
headerItems,
|
|
7128
|
-
actions.length > 0 && actions.map((action) => {
|
|
7129
|
-
return action.tooltip ? /* @__PURE__ */ jsx(
|
|
7130
|
-
Tooltip,
|
|
7131
|
-
{
|
|
7132
|
-
title: action.tooltip.text,
|
|
7133
|
-
placement: action.tooltip.placement ?? "top",
|
|
7134
|
-
children: iconButtonTooltip(action)
|
|
7135
|
-
},
|
|
7136
|
-
action.id
|
|
7137
|
-
) : iconButtonTooltip(action);
|
|
7138
|
-
}),
|
|
7139
|
-
options.length > 0 && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
7140
|
-
/* @__PURE__ */ jsx(
|
|
7141
|
-
IconActionButton,
|
|
7142
|
-
{
|
|
7143
|
-
"aria-label": "Options",
|
|
7144
|
-
"aria-controls": "options-menu",
|
|
7145
|
-
"aria-haspopup": "true",
|
|
7146
|
-
onClick: handleClick,
|
|
7147
|
-
size: "small",
|
|
7148
|
-
children: optionsIcon
|
|
7149
|
-
}
|
|
7150
|
-
),
|
|
7151
|
-
/* @__PURE__ */ jsx(
|
|
7152
|
-
PaperMenu,
|
|
7153
|
-
{
|
|
7154
|
-
id: "options-menu",
|
|
7155
|
-
elevation: 8,
|
|
7156
|
-
anchorOrigin: {
|
|
7157
|
-
vertical: "top",
|
|
7158
|
-
horizontal: "right"
|
|
7159
|
-
},
|
|
7160
|
-
transformOrigin: {
|
|
7161
|
-
vertical: "top",
|
|
7162
|
-
horizontal: "right"
|
|
7163
|
-
},
|
|
7164
|
-
anchorEl,
|
|
7165
|
-
keepMounted: true,
|
|
7166
|
-
open,
|
|
7167
|
-
onClose: handleClose,
|
|
7168
|
-
children: options.map((option) => /* @__PURE__ */ jsx(
|
|
7169
|
-
MenuItem,
|
|
7170
|
-
{
|
|
7171
|
-
selected: option.selected,
|
|
7172
|
-
onClick: () => handleOptionAction(option.action),
|
|
7173
|
-
children: option.name
|
|
7174
|
-
},
|
|
7175
|
-
option.id
|
|
7176
|
-
))
|
|
7177
|
-
}
|
|
7178
|
-
)
|
|
7179
|
-
] })
|
|
7180
|
-
] })
|
|
7181
|
-
] }),
|
|
7182
|
-
/* @__PURE__ */ jsx(Collapse, { ref: wrapper, in: expanded, timeout: "auto", unmountOnExit: true, children: /* @__PURE__ */ jsxs(Box, { ...contentProps, children: [
|
|
7183
|
-
/* @__PURE__ */ jsx(Box, { pt: 1, children }),
|
|
7184
|
-
footer ?? /* @__PURE__ */ jsx(Box, { children: footer })
|
|
7185
|
-
] }) })
|
|
7186
|
-
] });
|
|
7187
|
-
}
|
|
7188
7188
|
export {
|
|
7189
7189
|
BarWidgetUI,
|
|
7190
7190
|
CategoryWidgetUI,
|
|
@@ -7214,6 +7214,7 @@ export {
|
|
|
7214
7214
|
TimeSeriesProvider,
|
|
7215
7215
|
TimeSeriesWidgetUI,
|
|
7216
7216
|
WrapperWidgetUI,
|
|
7217
|
+
areChartPropsEqual,
|
|
7217
7218
|
useTimeSeriesContext,
|
|
7218
7219
|
useTimeSeriesInteractivity
|
|
7219
7220
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@carto/meridian-ds",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.5.0",
|
|
4
4
|
"description": "CARTO Meridian Design System",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
@@ -65,8 +65,10 @@
|
|
|
65
65
|
"@vitejs/plugin-react-swc": "3.7.0",
|
|
66
66
|
"@vitest/coverage-istanbul": "^2.1.3",
|
|
67
67
|
"cartocolor": "5.0.2",
|
|
68
|
+
"chromatic": "^13.1.3",
|
|
68
69
|
"codemirror": "^5.65.19",
|
|
69
70
|
"date-fns": "^2.29.1",
|
|
71
|
+
"dompurify": "^3.2.6",
|
|
70
72
|
"echarts": "5.6.0",
|
|
71
73
|
"echarts-for-react": "3.0.2",
|
|
72
74
|
"eslint": "8.57.0",
|
|
@@ -102,6 +104,7 @@
|
|
|
102
104
|
"@mui/x-date-pickers": "^7.11.0",
|
|
103
105
|
"cartocolor": "5.0.2",
|
|
104
106
|
"codemirror": ">=5.65.19",
|
|
107
|
+
"dompurify": "^3.2.6",
|
|
105
108
|
"echarts": ">=5.5.1",
|
|
106
109
|
"echarts-for-react": ">=3.0.2",
|
|
107
110
|
"react": ">=18.3.1",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"buttons.d.ts","sourceRoot":"","sources":["../../../../../src/theme/sections/components/buttons.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAQtD,eAAO,MAAM,gBAAgB,EAAE,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CA+pBvD,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"data-display.d.ts","sourceRoot":"","sources":["../../../../../src/theme/sections/components/data-display.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAS,UAAU,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAkBxD,eAAO,MAAM,oBAAoB,EAAE,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CA0iB3D,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"date-pickers.d.ts","sourceRoot":"","sources":["../../../../../src/theme/sections/components/date-pickers.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAgBtD,eAAO,MAAM,oBAAoB,EAAE,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CAgR3D,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"feedback.d.ts","sourceRoot":"","sources":["../../../../../src/theme/sections/components/feedback.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAEjD,eAAO,MAAM,iBAAiB,EAAE,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CAuFxD,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"forms.d.ts","sourceRoot":"","sources":["../../../../../src/theme/sections/components/forms.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAuB,KAAK,EAAW,MAAM,eAAe,CAAA;AA6F/E,eAAO,MAAM,cAAc,EAAE,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CAg6BrD,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"navigation.d.ts","sourceRoot":"","sources":["../../../../../src/theme/sections/components/navigation.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAEjD,eAAO,MAAM,mBAAmB,EAAE,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CAwU1D,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"surfaces.d.ts","sourceRoot":"","sources":["../../../../../src/theme/sections/components/surfaces.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAEjD,eAAO,MAAM,iBAAiB,EAAE,OAAO,CAAC,UAAU,CAAC,KAAK,CAAC,CAwFxD,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"palette.d.ts","sourceRoot":"","sources":["../../../../src/theme/sections/palette.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,KAAK,EAAS,MAAM,eAAe,CAAA;AAKjD,eAAO,MAAM,YAAY,YAAY,CAAA;AA+FrC,eAAO,MAAM,aAAa,EAAE,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC,CAmHnD,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"shadows.d.ts","sourceRoot":"","sources":["../../../../src/theme/sections/shadows.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAG1C,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,SAAS,CA0BzC,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"theme-constants.d.ts","sourceRoot":"","sources":["../../../src/theme/theme-constants.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,OAAO,IAAI,CAAA;AAGxB,eAAO,MAAM,WAAW;;;;;;CAMvB,CAAA;AAGD,eAAO,MAAM,UAAU,+BAAyB,CAAA;AAGhD,eAAO,MAAM,eAAe,QAAkB,CAAA;AAC9C,eAAO,MAAM,gBAAgB,QAAmB,CAAA;AAChD,eAAO,MAAM,eAAe,QAAgB,CAAA;AAG5C,eAAO,MAAM,WAAW,QAAgB,CAAA;AAGxC,eAAO,MAAM,2BAA2B,OAAO,CAAA;AAG/C,eAAO,MAAM,kBAAkB,MAAM,CAAA;AACrC,eAAO,MAAM,oBAAoB,KAAK,CAAA;AACtC,eAAO,MAAM,sBAAsB,KAAK,CAAA;AACxC,eAAO,MAAM,uBAAuB,KAAK,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"theme-utils.d.ts","sourceRoot":"","sources":["../../../src/theme/theme-utils.ts"],"names":[],"mappings":"AACA,wBAAgB,aAAa,CAAC,EAAE,EAAE,MAAM,UAKvC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NoDataAlert.d.ts","sourceRoot":"","sources":["../../../src/widgets/NoDataAlert.tsx"],"names":[],"mappings":"AACA,OAAc,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAA;AA0BhE,MAAM,MAAM,gBAAgB,GAAG,UAAU,GAAG;IAAE,IAAI,EAAE,KAAK,CAAC,SAAS,CAAA;CAAE,CAAA;AAErE,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAClC,KAA2B,EAC3B,IAA6J,EAC7J,QAAoB,EACpB,GAAG,UAAU,EACd,EAAE,gBAAgB,2CAWlB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"WrapperWidgetUI.d.ts","sourceRoot":"","sources":["../../../src/widgets/WrapperWidgetUI.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAuB,KAAK,aAAa,EAAE,MAAM,OAAO,CAAA;AAC/D,OAAO,EAEL,QAAQ,EAaT,MAAM,eAAe,CAAA;AA0GtB,MAAM,MAAM,qBAAqB,GAAG;IAClC,EAAE,EAAE,MAAM,CAAA;IACV,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,KAAK,CAAC,SAAS,CAAA;IACrB,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,OAAO,CAAC,EAAE;QACR,IAAI,EAAE,MAAM,CAAA;QACZ,SAAS,CAAC,EAAE,KAAK,GAAG,QAAQ,GAAG,MAAM,GAAG,OAAO,CAAA;KAChD,CAAA;CACF,CAAA;AACD,MAAM,MAAM,qBAAqB,GAAG;IAClC,EAAE,EAAE,MAAM,CAAA;IACV,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAA;AACD,MAAM,MAAM,oBAAoB,GAAG;IACjC,KAAK,EAAE,MAAM,CAAA;IACb,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,gBAAgB,CAAC,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,IAAI,CAAA;IAC9C,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IAC7B,OAAO,CAAC,EAAE,qBAAqB,EAAE,CAAA;IACjC,OAAO,CAAC,EAAE,qBAAqB,EAAE,CAAA;IACjC,WAAW,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IAC7B,QAAQ,CAAC,EAAE,GAAG,CAAC,OAAO,GAAG,GAAG,CAAC,OAAO,EAAE,CAAA;IACtC,MAAM,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACxB,MAAM,CAAC,EAAE,aAAa,CAAC,QAAQ,CAAC,CAAA;IAChC,YAAY,CAAC,EAAE,QAAQ,CAAA;CACxB,GAAG,CACA;IAAE,QAAQ,EAAE,IAAI,CAAC;IAAC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;CAAE,GAC7C;IAAE,QAAQ,CAAC,EAAE,KAAK,CAAC;IAAC,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;CAAE,CACnD,CAAA;AAKD,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EACtC,KAAK,EACL,OAA8C,EAC9C,OAA8C,EAC9C,WAAgC,EAChC,QAAQ,EACR,YAAY,EACZ,QAAgB,EAChB,UAAiB,EACjB,QAAQ,EAAE,SAAgB,EAC1B,gBAAgB,EAChB,MAAM,EACN,WAAW,EACX,SAAiB,EACjB,MAAM,GACP,EAAE,oBAAoB,kDAyItB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ComparativePieWidgetUI.d.ts","sourceRoot":"","sources":["../../../../src/widgets/comparative/ComparativePieWidgetUI.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAA;AA6BtD,iBAAS,uBAAuB,CAC9B,MAAM,EAAE,aAAa,EACrB,SAAS,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,MAAM,EAChC,UAAU,EAAE,OAAO,iBAiCpB;AAMD,MAAM,MAAM,0BAA0B,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAA;AACxE,MAAM,MAAM,2BAA2B,GAAG;IACxC,KAAK,EAAE,MAAM,EAAE,CAAA;IACf,IAAI,EAAE,0BAA0B,EAAE,EAAE,CAAA;IACpC,MAAM,CAAC,EAAE,MAAM,EAAE,EAAE,CAAA;IACnB,MAAM,CAAC,EAAE,MAAM,EAAE,EAAE,CAAA;IACnB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,SAAS,CAAC,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,MAAM,CAAA;IACjC,gBAAgB,CAAC,EAAE,OAAO,uBAAuB,CAAA;IACjD,kBAAkB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC7B,kBAAkB,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,EAAE,KAAK,IAAI,CAAA;IACnD,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB,CAAA;AAID,MAAM,CAAC,OAAO,UAAU,sBAAsB,CAAC,EAC7C,KAA+B,EAC/B,IAAoD,EACpD,MAAkC,EAClC,MAAkC,EAClC,MAAuB,EACvB,SAAgB,EAChB,SAAgD,EAChD,gBAA0C,EAC1C,kBAAuB,EACvB,kBAA6B,EAC7B,SAAiB,GAClB,EAAE,2BAA2B,kDAmM7B"}
|