@carto/meridian-ds 2.8.0 → 2.9.1-alpha-lists.2
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 +13 -2
- package/dist/{Alert-C4W0H_uN.cjs → Alert-BDpjbOOk.cjs} +1 -1
- package/dist/{Alert-BZPM5zpX.js → Alert-BWe4a9zW.js} +1 -1
- package/dist/{MenuItem-CgF4QdGi.cjs → MenuItem-DrvPgr-r.cjs} +15 -1
- package/dist/{MenuItem-DRUK149i.js → MenuItem-zaH11xyj.js} +16 -2
- package/dist/components/index.cjs +223 -21
- package/dist/components/index.js +226 -24
- package/dist/{css-utils-CjUBRJVK.js → css-utils-BzztxQJk.js} +8 -4
- package/dist/{css-utils-CH7es90t.cjs → css-utils-Do3X_yIr.cjs} +4 -0
- package/dist/custom-icons/index.cjs +666 -538
- package/dist/custom-icons/index.js +666 -538
- package/dist/theme/index.cjs +267 -47
- package/dist/theme/index.js +253 -33
- package/dist/types/components/Avatar/Avatar.stories.d.ts.map +1 -1
- package/dist/types/components/EmptyState/EmptyState.d.ts +4 -0
- package/dist/types/components/EmptyState/EmptyState.d.ts.map +1 -0
- package/dist/types/components/EmptyState/EmptyState.stories.d.ts +188 -0
- package/dist/types/components/EmptyState/EmptyState.stories.d.ts.map +1 -0
- package/dist/types/components/EmptyState/EmptyState.styled.d.ts +38 -0
- package/dist/types/components/EmptyState/EmptyState.styled.d.ts.map +1 -0
- package/dist/types/components/EmptyState/EmptyState.test.d.ts +2 -0
- package/dist/types/components/EmptyState/EmptyState.test.d.ts.map +1 -0
- package/dist/types/components/EmptyState/index.d.ts +3 -0
- package/dist/types/components/EmptyState/index.d.ts.map +1 -0
- package/dist/types/components/EmptyState/types.d.ts +82 -0
- package/dist/types/components/EmptyState/types.d.ts.map +1 -0
- package/dist/types/components/List/List.d.ts +18 -0
- package/dist/types/components/List/List.d.ts.map +1 -0
- package/dist/types/components/List/List.stories.d.ts +80 -0
- package/dist/types/components/List/List.stories.d.ts.map +1 -0
- package/dist/types/components/List/List.test.d.ts +2 -0
- package/dist/types/components/List/List.test.d.ts.map +1 -0
- package/dist/types/components/List/ListSubheader/ListSubheader.d.ts +14 -0
- package/dist/types/components/List/ListSubheader/ListSubheader.d.ts.map +1 -0
- package/dist/types/components/List/ListSubheader/ListSubheader.test.d.ts +2 -0
- package/dist/types/components/List/ListSubheader/ListSubheader.test.d.ts.map +1 -0
- package/dist/types/components/List/index.d.ts +5 -0
- package/dist/types/components/List/index.d.ts.map +1 -0
- package/dist/types/components/ListItem/ListItem.d.ts +33 -0
- package/dist/types/components/ListItem/ListItem.d.ts.map +1 -0
- package/dist/types/components/ListItem/ListItem.stories.d.ts +235 -0
- package/dist/types/components/ListItem/ListItem.stories.d.ts.map +1 -0
- package/dist/types/components/ListItem/ListItem.test.d.ts +2 -0
- package/dist/types/components/ListItem/ListItem.test.d.ts.map +1 -0
- package/dist/types/components/ListItem/ListItemRightContent/ListItemRightContent.d.ts +14 -0
- package/dist/types/components/ListItem/ListItemRightContent/ListItemRightContent.d.ts.map +1 -0
- package/dist/types/components/ListItem/ListItemRightContent/ListItemRightContent.test.d.ts +2 -0
- package/dist/types/components/ListItem/ListItemRightContent/ListItemRightContent.test.d.ts.map +1 -0
- package/dist/types/components/ListItem/index.d.ts +5 -0
- package/dist/types/components/ListItem/index.d.ts.map +1 -0
- package/dist/types/components/Loader/Loader.stories.d.ts +3 -3
- package/dist/types/components/Loader/Loader.stories.d.ts.map +1 -1
- package/dist/types/components/Menu/Menu/Menu.stories.d.ts.map +1 -1
- package/dist/types/components/index.d.ts +6 -0
- package/dist/types/components/index.d.ts.map +1 -1
- package/dist/types/custom-icons/GroupOff.d.ts +4 -0
- package/dist/types/custom-icons/GroupOff.d.ts.map +1 -0
- package/dist/types/custom-icons/RunReuse.d.ts +4 -0
- package/dist/types/custom-icons/RunReuse.d.ts.map +1 -0
- package/dist/types/custom-icons/SearchMap.d.ts +4 -0
- package/dist/types/custom-icons/SearchMap.d.ts.map +1 -0
- package/dist/types/custom-icons/SwitchAccessShortcut.d.ts +4 -0
- package/dist/types/custom-icons/SwitchAccessShortcut.d.ts.map +1 -0
- package/dist/types/custom-icons/__docs__/CustomIcons.stories.d.ts +8 -0
- package/dist/types/custom-icons/__docs__/CustomIcons.stories.d.ts.map +1 -1
- package/dist/types/custom-icons/index.d.ts +4 -0
- package/dist/types/custom-icons/index.d.ts.map +1 -1
- package/dist/types/theme/components/data-display.d.ts.map +1 -1
- package/dist/types/theme/components/navigation.d.ts.map +1 -1
- package/dist/types/theme/types.d.ts +86 -0
- package/dist/types/theme/types.d.ts.map +1 -1
- package/dist/types/utils/theme-constants.d.ts +2 -0
- package/dist/types/utils/theme-constants.d.ts.map +1 -1
- package/dist/types/utils/theme-utils.d.ts +16 -0
- package/dist/types/utils/theme-utils.d.ts.map +1 -1
- package/dist/types/widgets/FeatureSelectionWidgetUI/FeatureSelectionWidgetUI.test.d.ts +0 -1
- package/dist/types/widgets/FeatureSelectionWidgetUI/FeatureSelectionWidgetUI.test.d.ts.map +1 -1
- package/dist/widgets/index.cjs +2 -2
- package/dist/widgets/index.js +2 -2
- package/package.json +1 -1
- package/dist/types/theme/components/stories/List.stories.d.ts +0 -62
- package/dist/types/theme/components/stories/List.stories.d.ts.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,14 +2,25 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
- CI: Auto-run Chromatic on release PRs [#334](https://github.com/CartoDB/meridian-ds/pull/334)
|
|
6
|
+
|
|
5
7
|
## 2.0
|
|
6
8
|
|
|
9
|
+
### 2.9.1
|
|
10
|
+
|
|
11
|
+
- Custom Icons: GroupOff, RunReuse, SearchMap, SwitchAccessShortcut [#335](https://github.com/CartoDB/meridian-ds/pull/335)
|
|
12
|
+
|
|
13
|
+
### 2.9.0
|
|
14
|
+
|
|
15
|
+
- New EmptyState component [#330](https://github.com/CartoDB/meridian-ds/pull/330)
|
|
16
|
+
- Tests: Add console mock utility and enhance test setup [#315](https://github.com/CartoDB/meridian-ds/pull/315)
|
|
17
|
+
|
|
7
18
|
### 2.8.0
|
|
8
19
|
|
|
9
20
|
- New Loader and CircularProgress components [#329](https://github.com/CartoDB/meridian-ds/pull/329)
|
|
10
21
|
- Dialog: improve customization [#313](https://github.com/CartoDB/meridian-ds/pull/313)
|
|
11
22
|
- ToggleButtonGroup: move styles to the theme [#319](https://github.com/CartoDB/meridian-ds/pull/319)
|
|
12
|
-
- Custom Icons: CreateFolder,FolderEmpty [#331](https://github.com/CartoDB/meridian-ds/pull/331)
|
|
23
|
+
- Custom Icons: CreateFolder, FolderEmpty [#331](https://github.com/CartoDB/meridian-ds/pull/331)
|
|
13
24
|
|
|
14
25
|
### 2.7.0
|
|
15
26
|
|
|
@@ -30,7 +41,7 @@
|
|
|
30
41
|
### 2.6.1
|
|
31
42
|
|
|
32
43
|
- Custom Icons: FoldersStackedOutlined,RedoAlt,UndoAlt [#317](https://github.com/CartoDB/meridian-ds/pull/317)
|
|
33
|
-
- Tabs: remove box-shadow in vertical mode[#302](https://github.com/CartoDB/meridian-ds/pull/302)
|
|
44
|
+
- Tabs: remove box-shadow in vertical mode [#302](https://github.com/CartoDB/meridian-ds/pull/302)
|
|
34
45
|
|
|
35
46
|
### 2.6.0
|
|
36
47
|
|
|
@@ -4,7 +4,7 @@ const React = require("react");
|
|
|
4
4
|
const material = require("@mui/material");
|
|
5
5
|
const iconsMaterial = require("@mui/icons-material");
|
|
6
6
|
require("cartocolor");
|
|
7
|
-
const cssUtils = require("./css-utils-
|
|
7
|
+
const cssUtils = require("./css-utils-Do3X_yIr.cjs");
|
|
8
8
|
const ScreenReaderOnly = material.styled("span")(() => ({
|
|
9
9
|
position: "absolute",
|
|
10
10
|
width: 1,
|
|
@@ -3,7 +3,7 @@ import { forwardRef, useState } from "react";
|
|
|
3
3
|
import { styled, Link as Link$1, Alert as Alert$1, Fade, AlertTitle } from "@mui/material";
|
|
4
4
|
import { OpenInNewOutlined } from "@mui/icons-material";
|
|
5
5
|
import "cartocolor";
|
|
6
|
-
import { c as ICON_SIZE_SMALL, b as ICON_SIZE_MEDIUM, u as useTranslationWithFallback, T as Typography } from "./css-utils-
|
|
6
|
+
import { c as ICON_SIZE_SMALL, b as ICON_SIZE_MEDIUM, u as useTranslationWithFallback, T as Typography } from "./css-utils-BzztxQJk.js";
|
|
7
7
|
const ScreenReaderOnly = styled("span")(() => ({
|
|
8
8
|
position: "absolute",
|
|
9
9
|
width: 1,
|
|
@@ -2,7 +2,19 @@
|
|
|
2
2
|
const jsxRuntime = require("react/jsx-runtime");
|
|
3
3
|
const React = require("react");
|
|
4
4
|
const material = require("@mui/material");
|
|
5
|
-
const cssUtils = require("./css-utils-
|
|
5
|
+
const cssUtils = require("./css-utils-Do3X_yIr.cjs");
|
|
6
|
+
function getPixelToRem(px) {
|
|
7
|
+
const fontBase = 16;
|
|
8
|
+
const rem = 1 / fontBase * px + "rem";
|
|
9
|
+
return rem;
|
|
10
|
+
}
|
|
11
|
+
function getThemeColor(colorPath, theme) {
|
|
12
|
+
const colorValue = colorPath.split(".").reduce(
|
|
13
|
+
(acc, part) => acc && typeof acc === "object" && part in acc ? acc[part] : void 0,
|
|
14
|
+
theme.palette
|
|
15
|
+
);
|
|
16
|
+
return typeof colorValue === "string" ? colorValue : void 0;
|
|
17
|
+
}
|
|
6
18
|
const StyledMenuItem = material.styled(material.MenuItem, {
|
|
7
19
|
shouldForwardProp: (prop) => !["subtitle", "destructive", "extended", "fixed", "iconColor"].includes(
|
|
8
20
|
prop
|
|
@@ -176,3 +188,5 @@ function _MenuItem({
|
|
|
176
188
|
}
|
|
177
189
|
const MenuItem = React.forwardRef(_MenuItem);
|
|
178
190
|
exports.MenuItem = MenuItem;
|
|
191
|
+
exports.getPixelToRem = getPixelToRem;
|
|
192
|
+
exports.getThemeColor = getThemeColor;
|
|
@@ -1,7 +1,19 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef } from "react";
|
|
3
3
|
import { styled, MenuItem as MenuItem$1 } from "@mui/material";
|
|
4
|
-
import { f as MENU_ITEM_SIZE_DENSE,
|
|
4
|
+
import { f as MENU_ITEM_SIZE_DENSE, i as MENU_ITEM_SIZE_EXTENDED } from "./css-utils-BzztxQJk.js";
|
|
5
|
+
function getPixelToRem(px) {
|
|
6
|
+
const fontBase = 16;
|
|
7
|
+
const rem = 1 / fontBase * px + "rem";
|
|
8
|
+
return rem;
|
|
9
|
+
}
|
|
10
|
+
function getThemeColor(colorPath, theme) {
|
|
11
|
+
const colorValue = colorPath.split(".").reduce(
|
|
12
|
+
(acc, part) => acc && typeof acc === "object" && part in acc ? acc[part] : void 0,
|
|
13
|
+
theme.palette
|
|
14
|
+
);
|
|
15
|
+
return typeof colorValue === "string" ? colorValue : void 0;
|
|
16
|
+
}
|
|
5
17
|
const StyledMenuItem = styled(MenuItem$1, {
|
|
6
18
|
shouldForwardProp: (prop) => !["subtitle", "destructive", "extended", "fixed", "iconColor"].includes(
|
|
7
19
|
prop
|
|
@@ -175,5 +187,7 @@ function _MenuItem({
|
|
|
175
187
|
}
|
|
176
188
|
const MenuItem = forwardRef(_MenuItem);
|
|
177
189
|
export {
|
|
178
|
-
MenuItem as M
|
|
190
|
+
MenuItem as M,
|
|
191
|
+
getThemeColor as a,
|
|
192
|
+
getPixelToRem as g
|
|
179
193
|
};
|
|
@@ -4,11 +4,11 @@ const jsxRuntime = require("react/jsx-runtime");
|
|
|
4
4
|
const React = require("react");
|
|
5
5
|
const material = require("@mui/material");
|
|
6
6
|
const iconsMaterial = require("@mui/icons-material");
|
|
7
|
-
const cssUtils = require("../css-utils-
|
|
8
|
-
const Alert$1 = require("../Alert-
|
|
7
|
+
const cssUtils = require("../css-utils-Do3X_yIr.cjs");
|
|
8
|
+
const Alert$1 = require("../Alert-BDpjbOOk.cjs");
|
|
9
9
|
const ArrowDown = require("../ArrowDown-DJ0vhbsw.cjs");
|
|
10
10
|
const OpenDiagonallyRight = require("../OpenDiagonallyRight-CpL4ROwg.cjs");
|
|
11
|
-
const MenuItem = require("../MenuItem-
|
|
11
|
+
const MenuItem = require("../MenuItem-DrvPgr-r.cjs");
|
|
12
12
|
require("cartocolor");
|
|
13
13
|
const reactWindow = require("react-window");
|
|
14
14
|
const reactCodemirror2 = require("react-codemirror2");
|
|
@@ -223,7 +223,7 @@ function SplitButton({
|
|
|
223
223
|
)
|
|
224
224
|
] });
|
|
225
225
|
}
|
|
226
|
-
const Root$
|
|
226
|
+
const Root$6 = material.styled(material.Box)(({ theme }) => ({
|
|
227
227
|
display: "flex",
|
|
228
228
|
alignItems: "center",
|
|
229
229
|
gap: theme.spacing(0.5)
|
|
@@ -257,7 +257,7 @@ function _LabelWithIndicator({
|
|
|
257
257
|
typographyProps
|
|
258
258
|
}, ref) {
|
|
259
259
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
260
|
-
Root$
|
|
260
|
+
Root$6,
|
|
261
261
|
{
|
|
262
262
|
ref,
|
|
263
263
|
"data-testid": dataTestId,
|
|
@@ -776,7 +776,7 @@ function _MultipleSelectField({
|
|
|
776
776
|
const MultipleSelectField = React.forwardRef(_MultipleSelectField);
|
|
777
777
|
const StyledToggleButtonGroup = material.styled(material.ToggleButtonGroup, {
|
|
778
778
|
shouldForwardProp: (prop) => prop !== "backgroundColor"
|
|
779
|
-
})();
|
|
779
|
+
})(() => ({}));
|
|
780
780
|
function _ToggleButtonGroup({
|
|
781
781
|
children,
|
|
782
782
|
variant = "floating",
|
|
@@ -890,7 +890,7 @@ function _Loader({
|
|
|
890
890
|
secondLabel && /* @__PURE__ */ jsxRuntime.jsx(
|
|
891
891
|
cssUtils.Typography,
|
|
892
892
|
{
|
|
893
|
-
variant: "
|
|
893
|
+
variant: "caption",
|
|
894
894
|
color: "textSecondary",
|
|
895
895
|
...secondLabelProps,
|
|
896
896
|
id: labelText ? void 0 : "loader-label",
|
|
@@ -1479,7 +1479,7 @@ function useMultipleAutocomplete({
|
|
|
1479
1479
|
getCounterRenderTags
|
|
1480
1480
|
};
|
|
1481
1481
|
}
|
|
1482
|
-
const List = material.styled("ul")(
|
|
1482
|
+
const List$1 = material.styled("ul")(
|
|
1483
1483
|
({ theme, hasFilters }) => ({
|
|
1484
1484
|
...!hasFilters && {
|
|
1485
1485
|
paddingTop: `${theme.spacing(1)} !important`
|
|
@@ -1606,7 +1606,7 @@ function _AutocompleteList({
|
|
|
1606
1606
|
);
|
|
1607
1607
|
};
|
|
1608
1608
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1609
|
-
List,
|
|
1609
|
+
List$1,
|
|
1610
1610
|
{
|
|
1611
1611
|
ref,
|
|
1612
1612
|
...otherProps,
|
|
@@ -1929,7 +1929,7 @@ function SecondaryText({ text }) {
|
|
|
1929
1929
|
}
|
|
1930
1930
|
);
|
|
1931
1931
|
}
|
|
1932
|
-
const Root$
|
|
1932
|
+
const Root$5 = material.styled(material.AppBar)(({ theme }) => ({
|
|
1933
1933
|
backgroundColor: theme.palette.brand.appBarMain,
|
|
1934
1934
|
userSelect: "none",
|
|
1935
1935
|
"& .MuiTypography-root": {
|
|
@@ -1964,7 +1964,7 @@ function _AppBar({
|
|
|
1964
1964
|
onClickMenu,
|
|
1965
1965
|
...otherProps
|
|
1966
1966
|
}, ref) {
|
|
1967
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Root$
|
|
1967
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Root$5, { ...otherProps, ref, "data-name": "app-bar", children: /* @__PURE__ */ jsxRuntime.jsxs(material.Toolbar, { children: [
|
|
1968
1968
|
/* @__PURE__ */ jsxRuntime.jsxs(BrandElements, { children: [
|
|
1969
1969
|
showBurgerMenu && /* @__PURE__ */ jsxRuntime.jsx(BurgerMenu, { onClickMenu }),
|
|
1970
1970
|
brandLogo && /* @__PURE__ */ jsxRuntime.jsx(BrandLogo, { logo: brandLogo }),
|
|
@@ -2644,7 +2644,7 @@ function CodeAreaInput({
|
|
|
2644
2644
|
}
|
|
2645
2645
|
);
|
|
2646
2646
|
}
|
|
2647
|
-
const Root$
|
|
2647
|
+
const Root$4 = material.styled(material.FormControl)(() => ({
|
|
2648
2648
|
display: "flex",
|
|
2649
2649
|
flexDirection: "column",
|
|
2650
2650
|
flex: 1
|
|
@@ -2836,7 +2836,7 @@ function CodeAreaField({
|
|
|
2836
2836
|
const readOnly = (options == null ? void 0 : options.readOnly) ?? false;
|
|
2837
2837
|
const lineNumbers = (options == null ? void 0 : options.lineNumbers) ?? true;
|
|
2838
2838
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2839
|
-
Root$
|
|
2839
|
+
Root$4,
|
|
2840
2840
|
{
|
|
2841
2841
|
size,
|
|
2842
2842
|
error,
|
|
@@ -3411,7 +3411,7 @@ function DialogAlert({
|
|
|
3411
3411
|
}) {
|
|
3412
3412
|
return /* @__PURE__ */ jsxRuntime.jsx(StyledAlert, { severity, ...otherProps, "data-name": "dialog-alert", children });
|
|
3413
3413
|
}
|
|
3414
|
-
const Root$
|
|
3414
|
+
const Root$3 = material.styled(material.Box, {
|
|
3415
3415
|
shouldForwardProp: (prop) => !["dark", "hasChildren"].includes(prop)
|
|
3416
3416
|
})(({ dark, hasChildren, theme }) => ({
|
|
3417
3417
|
flex: "0 0 auto",
|
|
@@ -3479,7 +3479,7 @@ function DialogFooter({
|
|
|
3479
3479
|
topContent,
|
|
3480
3480
|
!!alertContent && /* @__PURE__ */ jsxRuntime.jsx(DividerTop, {}),
|
|
3481
3481
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
3482
|
-
Root$
|
|
3482
|
+
Root$3,
|
|
3483
3483
|
{
|
|
3484
3484
|
...otherProps,
|
|
3485
3485
|
dark,
|
|
@@ -3575,7 +3575,7 @@ function DialogConfirmation({
|
|
|
3575
3575
|
}
|
|
3576
3576
|
);
|
|
3577
3577
|
}
|
|
3578
|
-
const Root$
|
|
3578
|
+
const Root$2 = material.styled(material.Box)(({ theme }) => ({
|
|
3579
3579
|
display: "flex",
|
|
3580
3580
|
alignItems: "center",
|
|
3581
3581
|
justifyContent: "center",
|
|
@@ -3656,7 +3656,7 @@ function DialogStepper({
|
|
|
3656
3656
|
stepsLabels,
|
|
3657
3657
|
...props
|
|
3658
3658
|
}) {
|
|
3659
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Root$
|
|
3659
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Root$2, { ...props, "data-name": "dialog-stepper", children: /* @__PURE__ */ jsxRuntime.jsx(material.Box, { sx: { display: "flex" }, children: stepsLabels.map((stepLabel, idx) => {
|
|
3660
3660
|
const step = idx + 1;
|
|
3661
3661
|
const isCurrent = step === currentStep;
|
|
3662
3662
|
const isCompleted = step < currentStep;
|
|
@@ -3942,7 +3942,7 @@ function ClearButton({
|
|
|
3942
3942
|
}
|
|
3943
3943
|
) });
|
|
3944
3944
|
}
|
|
3945
|
-
const Root = material.styled(material.Box, {
|
|
3945
|
+
const Root$1 = material.styled(material.Box, {
|
|
3946
3946
|
shouldForwardProp: (prop) => !["size", "variant", "readOnly"].includes(prop)
|
|
3947
3947
|
})(({ size, variant, readOnly, theme }) => ({
|
|
3948
3948
|
// There is no specific slot to change TextField styles at DatePicker level, so we need to wrap our component to isolate this override. https://mui.com/x/react-date-pickers/date-picker/#customization
|
|
@@ -3982,7 +3982,7 @@ function DateFieldContainer({
|
|
|
3982
3982
|
readOnly,
|
|
3983
3983
|
...props
|
|
3984
3984
|
}) {
|
|
3985
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Root, { ...props, size, variant, readOnly, children });
|
|
3985
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Root$1, { ...props, size, variant, readOnly, children });
|
|
3986
3986
|
}
|
|
3987
3987
|
function DatePicker({
|
|
3988
3988
|
handleClear,
|
|
@@ -4666,6 +4666,122 @@ function DateTimePicker({
|
|
|
4666
4666
|
}
|
|
4667
4667
|
);
|
|
4668
4668
|
}
|
|
4669
|
+
const EMPTY_STATE_WIDTH = 592;
|
|
4670
|
+
const Root = material.styled(material.Stack, {
|
|
4671
|
+
shouldForwardProp: (prop) => prop !== "size" && prop !== "spacing" && prop !== "contentHeight"
|
|
4672
|
+
})(({ size = "medium", spacing, contentHeight, theme }) => ({
|
|
4673
|
+
display: "flex",
|
|
4674
|
+
justifyContent: "center",
|
|
4675
|
+
alignItems: "center",
|
|
4676
|
+
gap: theme.spacing(spacing ?? (size === "small" ? 1 : 2)),
|
|
4677
|
+
height: contentHeight,
|
|
4678
|
+
minHeight: contentHeight
|
|
4679
|
+
}));
|
|
4680
|
+
const IconWrapper = material.styled(material.Box, {
|
|
4681
|
+
shouldForwardProp: (prop) => prop !== "size" && prop !== "iconSize" && prop !== "iconColor"
|
|
4682
|
+
})(({ size, iconSize, iconColor, theme }) => {
|
|
4683
|
+
const finalIconSize = iconSize ?? (size === "small" ? theme.spacing(5) : theme.spacing(6));
|
|
4684
|
+
const colorValue = iconColor === null || iconColor === void 0 ? void 0 : MenuItem.getThemeColor(iconColor, theme);
|
|
4685
|
+
return {
|
|
4686
|
+
display: "flex",
|
|
4687
|
+
".MuiSvgIcon-root": {
|
|
4688
|
+
width: finalIconSize,
|
|
4689
|
+
height: finalIconSize,
|
|
4690
|
+
fontSize: finalIconSize,
|
|
4691
|
+
...colorValue && { color: colorValue }
|
|
4692
|
+
}
|
|
4693
|
+
};
|
|
4694
|
+
});
|
|
4695
|
+
const TextContent = material.styled(material.Stack, {
|
|
4696
|
+
shouldForwardProp: (prop) => prop !== "contentWidth"
|
|
4697
|
+
})(({ contentWidth, theme }) => ({
|
|
4698
|
+
display: "flex",
|
|
4699
|
+
flexDirection: "column",
|
|
4700
|
+
alignItems: "center",
|
|
4701
|
+
gap: theme.spacing(0.5),
|
|
4702
|
+
textAlign: "center",
|
|
4703
|
+
maxWidth: contentWidth ?? EMPTY_STATE_WIDTH,
|
|
4704
|
+
margin: "0 auto"
|
|
4705
|
+
}));
|
|
4706
|
+
const Actions = material.styled(material.Stack, {
|
|
4707
|
+
shouldForwardProp: (prop) => prop !== "size" && prop !== "spacing"
|
|
4708
|
+
})(({ size = "medium", spacing, theme }) => ({
|
|
4709
|
+
display: "flex",
|
|
4710
|
+
alignItems: "center",
|
|
4711
|
+
gap: theme.spacing(spacing ?? (size === "small" ? 1 : 2)),
|
|
4712
|
+
marginTop: theme.spacing(size === "small" ? 1 : 2),
|
|
4713
|
+
".MuiButton-root + .MuiButton-root": {
|
|
4714
|
+
marginLeft: 0
|
|
4715
|
+
}
|
|
4716
|
+
}));
|
|
4717
|
+
function _EmptyState({
|
|
4718
|
+
icon,
|
|
4719
|
+
title,
|
|
4720
|
+
description,
|
|
4721
|
+
actions,
|
|
4722
|
+
children,
|
|
4723
|
+
size = "medium",
|
|
4724
|
+
spacing,
|
|
4725
|
+
iconProps,
|
|
4726
|
+
contentWidth = EMPTY_STATE_WIDTH,
|
|
4727
|
+
contentHeight,
|
|
4728
|
+
sx,
|
|
4729
|
+
titleProps,
|
|
4730
|
+
descriptionProps,
|
|
4731
|
+
...otherProps
|
|
4732
|
+
}, ref) {
|
|
4733
|
+
const hasAnyTextContent = title || description;
|
|
4734
|
+
const isSmall = size === "small";
|
|
4735
|
+
const iconSize = (iconProps == null ? void 0 : iconProps.size) ?? (isSmall ? 32 : 48);
|
|
4736
|
+
const iconColor = (iconProps == null ? void 0 : iconProps.color) === null ? null : (iconProps == null ? void 0 : iconProps.color) ?? "text.disabled";
|
|
4737
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
4738
|
+
Root,
|
|
4739
|
+
{
|
|
4740
|
+
ref,
|
|
4741
|
+
alignItems: "center",
|
|
4742
|
+
size,
|
|
4743
|
+
spacing,
|
|
4744
|
+
contentHeight,
|
|
4745
|
+
sx,
|
|
4746
|
+
...otherProps,
|
|
4747
|
+
"data-name": "empty-state",
|
|
4748
|
+
"data-size": size,
|
|
4749
|
+
"data-spacing": spacing,
|
|
4750
|
+
"data-content-height": contentHeight,
|
|
4751
|
+
"data-content-width": contentWidth,
|
|
4752
|
+
"data-icon-size": iconSize,
|
|
4753
|
+
"data-icon-color": iconColor ?? "null",
|
|
4754
|
+
children: [
|
|
4755
|
+
icon && /* @__PURE__ */ jsxRuntime.jsx(IconWrapper, { size, iconSize, iconColor, children: icon }),
|
|
4756
|
+
hasAnyTextContent && /* @__PURE__ */ jsxRuntime.jsxs(TextContent, { contentWidth, children: [
|
|
4757
|
+
title && /* @__PURE__ */ jsxRuntime.jsx(
|
|
4758
|
+
cssUtils.Typography,
|
|
4759
|
+
{
|
|
4760
|
+
variant: isSmall ? "body2" : "body1",
|
|
4761
|
+
color: "textSecondary",
|
|
4762
|
+
component: "div",
|
|
4763
|
+
...titleProps,
|
|
4764
|
+
children: title
|
|
4765
|
+
}
|
|
4766
|
+
),
|
|
4767
|
+
description && /* @__PURE__ */ jsxRuntime.jsx(
|
|
4768
|
+
cssUtils.Typography,
|
|
4769
|
+
{
|
|
4770
|
+
variant: isSmall ? "caption" : "body2",
|
|
4771
|
+
color: "textSecondary",
|
|
4772
|
+
component: "div",
|
|
4773
|
+
...descriptionProps,
|
|
4774
|
+
children: description
|
|
4775
|
+
}
|
|
4776
|
+
)
|
|
4777
|
+
] }),
|
|
4778
|
+
actions && /* @__PURE__ */ jsxRuntime.jsx(Actions, { size, spacing, children: actions }),
|
|
4779
|
+
children
|
|
4780
|
+
]
|
|
4781
|
+
}
|
|
4782
|
+
);
|
|
4783
|
+
}
|
|
4784
|
+
const EmptyState = React.forwardRef(_EmptyState);
|
|
4669
4785
|
const DEFAULT_ITEMS = [{ outlinedBullet: false, value: "" }];
|
|
4670
4786
|
const Content$2 = material.styled("ul")(({ theme }) => ({
|
|
4671
4787
|
listStyle: "none",
|
|
@@ -4812,7 +4928,7 @@ const StyledMenu = material.styled(material.Menu, {
|
|
|
4812
4928
|
}
|
|
4813
4929
|
}
|
|
4814
4930
|
}));
|
|
4815
|
-
function _Menu({ extended, width, height, MenuListProps, ...otherProps }, ref) {
|
|
4931
|
+
function _Menu({ extended, width, height, MenuListProps: MenuListProps2, ...otherProps }, ref) {
|
|
4816
4932
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
4817
4933
|
StyledMenu,
|
|
4818
4934
|
{
|
|
@@ -4823,7 +4939,7 @@ function _Menu({ extended, width, height, MenuListProps, ...otherProps }, ref) {
|
|
|
4823
4939
|
height,
|
|
4824
4940
|
extended,
|
|
4825
4941
|
MenuListProps: {
|
|
4826
|
-
...
|
|
4942
|
+
...MenuListProps2,
|
|
4827
4943
|
"data-width": width,
|
|
4828
4944
|
"data-height": height,
|
|
4829
4945
|
"data-extended": extended
|
|
@@ -6147,6 +6263,87 @@ function _EllipsisWithTooltip({
|
|
|
6147
6263
|
);
|
|
6148
6264
|
}
|
|
6149
6265
|
const EllipsisWithTooltip = React.forwardRef(_EllipsisWithTooltip);
|
|
6266
|
+
function _List({ variant = "standard", spacing, ...otherProps }, ref) {
|
|
6267
|
+
const isOutlinedItems = variant === "outlined-items";
|
|
6268
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6269
|
+
material.List,
|
|
6270
|
+
{
|
|
6271
|
+
...otherProps,
|
|
6272
|
+
variant,
|
|
6273
|
+
spacing: spacing || (isOutlinedItems ? 1 : 0),
|
|
6274
|
+
ref,
|
|
6275
|
+
"data-name": "list",
|
|
6276
|
+
"data-variant": variant,
|
|
6277
|
+
"data-spacing": spacing
|
|
6278
|
+
}
|
|
6279
|
+
);
|
|
6280
|
+
}
|
|
6281
|
+
const List = React.forwardRef(_List);
|
|
6282
|
+
function _ListSubheader({ backgroundColor = "default", ...otherProps }, ref) {
|
|
6283
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6284
|
+
material.ListSubheader,
|
|
6285
|
+
{
|
|
6286
|
+
...otherProps,
|
|
6287
|
+
ref,
|
|
6288
|
+
"data-name": "list-subheader",
|
|
6289
|
+
"data-background-color": backgroundColor
|
|
6290
|
+
}
|
|
6291
|
+
);
|
|
6292
|
+
}
|
|
6293
|
+
const ListSubheader = React.forwardRef(_ListSubheader);
|
|
6294
|
+
function _ListItem({
|
|
6295
|
+
variant = "standard",
|
|
6296
|
+
disabled,
|
|
6297
|
+
fixedHeight = true,
|
|
6298
|
+
onClick,
|
|
6299
|
+
...otherProps
|
|
6300
|
+
}, ref) {
|
|
6301
|
+
if (onClick) {
|
|
6302
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6303
|
+
material.ListItemButton,
|
|
6304
|
+
{
|
|
6305
|
+
...otherProps,
|
|
6306
|
+
variant,
|
|
6307
|
+
disabled,
|
|
6308
|
+
onClick,
|
|
6309
|
+
ref,
|
|
6310
|
+
"data-name": "list-item-button",
|
|
6311
|
+
"data-variant": variant,
|
|
6312
|
+
"data-fixed-height": fixedHeight
|
|
6313
|
+
}
|
|
6314
|
+
);
|
|
6315
|
+
}
|
|
6316
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6317
|
+
material.ListItem,
|
|
6318
|
+
{
|
|
6319
|
+
...otherProps,
|
|
6320
|
+
variant,
|
|
6321
|
+
disabled,
|
|
6322
|
+
...disabled && { "aria-disabled": true },
|
|
6323
|
+
ref,
|
|
6324
|
+
"data-name": "list-item",
|
|
6325
|
+
"data-variant": variant,
|
|
6326
|
+
"data-fixed-height": fixedHeight
|
|
6327
|
+
}
|
|
6328
|
+
);
|
|
6329
|
+
}
|
|
6330
|
+
const ListItem = React.forwardRef(_ListItem);
|
|
6331
|
+
function ListItemRightContent({
|
|
6332
|
+
children,
|
|
6333
|
+
...props
|
|
6334
|
+
}) {
|
|
6335
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
6336
|
+
material.Stack,
|
|
6337
|
+
{
|
|
6338
|
+
direction: "row",
|
|
6339
|
+
alignItems: "center",
|
|
6340
|
+
gap: 1.5,
|
|
6341
|
+
...props,
|
|
6342
|
+
"data-name": "list-item-right-content",
|
|
6343
|
+
children
|
|
6344
|
+
}
|
|
6345
|
+
);
|
|
6346
|
+
}
|
|
6150
6347
|
exports.IconButton = cssUtils.IconButton;
|
|
6151
6348
|
exports.TablePaginationActions = cssUtils.TablePaginationActions;
|
|
6152
6349
|
exports.Typography = cssUtils.Typography;
|
|
@@ -6188,9 +6385,14 @@ exports.DialogHeader = DialogHeader;
|
|
|
6188
6385
|
exports.DialogPaper = DialogPaper;
|
|
6189
6386
|
exports.DialogStepper = DialogStepper;
|
|
6190
6387
|
exports.EllipsisWithTooltip = EllipsisWithTooltip;
|
|
6388
|
+
exports.EmptyState = EmptyState;
|
|
6191
6389
|
exports.FilterDropdown = FilterDropdown;
|
|
6192
6390
|
exports.FilterDropdownMenuItem = FilterDropdownMenuItem;
|
|
6193
6391
|
exports.LabelWithIndicator = LabelWithIndicator;
|
|
6392
|
+
exports.List = List;
|
|
6393
|
+
exports.ListItem = ListItem;
|
|
6394
|
+
exports.ListItemRightContent = ListItemRightContent;
|
|
6395
|
+
exports.ListSubheader = ListSubheader;
|
|
6194
6396
|
exports.Loader = Loader;
|
|
6195
6397
|
exports.Menu = Menu;
|
|
6196
6398
|
exports.MenuItemFilter = MenuItemFilter;
|