@m4l/base 1.7.0 → 1.7.2-beta-m4lcom-785-data-grids-implementar-la-funcionalidad-de-scroll-infinito.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/components/Icon/Icon.d.ts.map +1 -1
- package/components/Icon/Icon.js +26 -24
- package/components/Icon/Icon.styles.d.ts.map +1 -1
- package/components/Icon/Icon.styles.js +31 -30
- package/components/Icon/types.d.ts +3 -1
- package/components/Icon/types.d.ts.map +1 -1
- package/index.js +32 -28
- package/package.json +2 -2
- package/utils/getIconPaintStyles/getIconPaintStyles.d.ts +23 -0
- package/utils/getIconPaintStyles/getIconPaintStyles.d.ts.map +1 -1
- package/utils/getIconPaintStyles/getIconPaintStyles.js +26 -8
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Icon.d.ts","sourceRoot":"","sources":["../../../../../../packages/base/src/components/Icon/Icon.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAkB,SAAS,EAA0C,MAAM,SAAS,CAAC;AAgC5F;;GAEG;AACH,QAAA,MAAM,IAAI;YAAW,SAAS;;
|
|
1
|
+
{"version":3,"file":"Icon.d.ts","sourceRoot":"","sources":["../../../../../../packages/base/src/components/Icon/Icon.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAkB,SAAS,EAA0C,MAAM,SAAS,CAAC;AAgC5F;;GAEG;AACH,QAAA,MAAM,IAAI;YAAW,SAAS;;CAuH7B,CAAC;AAIF,OAAO,EAAE,IAAI,EAAE,CAAC"}
|
package/components/Icon/Icon.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as j, Fragment as A, jsx as n } from "@emotion/react/jsx-runtime";
|
|
2
2
|
import u from "clsx";
|
|
3
|
-
import { isValidElement as S, cloneElement as
|
|
4
|
-
import { useModuleSkeleton as
|
|
3
|
+
import { isValidElement as S, cloneElement as L } from "react";
|
|
4
|
+
import { useModuleSkeleton as M } from "@m4l/core";
|
|
5
5
|
import { getPropDataTestId as s } from "../../utils/getNameDataTestId.js";
|
|
6
|
-
import { ICON_CLASSES as o, normalizeIconSize as
|
|
7
|
-
import { TooltipStyled as
|
|
8
|
-
function
|
|
6
|
+
import { ICON_CLASSES as o, normalizeIconSize as F, ICON_PREFIX as a } from "./constants.js";
|
|
7
|
+
import { TooltipStyled as O, RootStyled as b, IconSkeletonStyled as _, IconStyled as B } from "./slots/IconSlots.js";
|
|
8
|
+
function V(t) {
|
|
9
9
|
return "src" in t && typeof t.src == "string" || "icon" in t && typeof t.icon == "string";
|
|
10
10
|
}
|
|
11
|
-
function
|
|
11
|
+
function X(t) {
|
|
12
12
|
return "src" in t && t.src !== void 0 && S(t.src) || "icon" in t && t.icon !== void 0 && S(t.icon);
|
|
13
13
|
}
|
|
14
|
-
function
|
|
15
|
-
if (
|
|
14
|
+
function $(t) {
|
|
15
|
+
if (V(t) || X(t))
|
|
16
16
|
return "src" in t ? t.src : t.icon;
|
|
17
17
|
}
|
|
18
|
-
const
|
|
18
|
+
const q = (t) => {
|
|
19
19
|
const {
|
|
20
|
-
size:
|
|
20
|
+
size: k = "medium",
|
|
21
21
|
rotationAngle: l,
|
|
22
22
|
tooltipContent: f,
|
|
23
23
|
color: x = "text.primary",
|
|
@@ -29,8 +29,9 @@ const $ = (t) => {
|
|
|
29
29
|
selected: T,
|
|
30
30
|
enabledSelected: D,
|
|
31
31
|
onClick: g,
|
|
32
|
-
ariaLabel: i
|
|
33
|
-
|
|
32
|
+
ariaLabel: i,
|
|
33
|
+
originalColor: E
|
|
34
|
+
} = t, y = M(), c = R ?? w, e = $(t), m = F(k), P = e !== void 0 ? typeof e == "string" : void 0, h = i ? {
|
|
34
35
|
role: "img",
|
|
35
36
|
"aria-label": i
|
|
36
37
|
} : {
|
|
@@ -43,8 +44,9 @@ const $ = (t) => {
|
|
|
43
44
|
rotationAngle: l,
|
|
44
45
|
selected: T,
|
|
45
46
|
enabledSelected: D,
|
|
47
|
+
originalColor: E,
|
|
46
48
|
isSkeleton: y,
|
|
47
|
-
isMaskStrategy:
|
|
49
|
+
isMaskStrategy: P
|
|
48
50
|
}, v = typeof g == "function" && !d, z = {
|
|
49
51
|
className: u(I, o.root),
|
|
50
52
|
ownerState: { ...r },
|
|
@@ -52,15 +54,15 @@ const $ = (t) => {
|
|
|
52
54
|
tabIndex: v ? 0 : -1,
|
|
53
55
|
"aria-disabled": d,
|
|
54
56
|
...s(a, "root", c)
|
|
55
|
-
},
|
|
56
|
-
|
|
57
|
+
}, C = () => e && typeof e == "string" ? /* @__PURE__ */ n(
|
|
58
|
+
B,
|
|
57
59
|
{
|
|
58
60
|
className: u(o.icon, o.root),
|
|
59
61
|
ownerState: { ...r },
|
|
60
62
|
...s(a, "icon", c),
|
|
61
63
|
...h
|
|
62
64
|
}
|
|
63
|
-
) : e && S(e) ?
|
|
65
|
+
) : e && S(e) ? L(e, {
|
|
64
66
|
sx: {
|
|
65
67
|
fontSize: m === "small" ? "small" : "medium",
|
|
66
68
|
...l && {
|
|
@@ -72,9 +74,9 @@ const $ = (t) => {
|
|
|
72
74
|
...h,
|
|
73
75
|
...i ? { titleAccess: i } : {}
|
|
74
76
|
}) : null;
|
|
75
|
-
return /* @__PURE__ */
|
|
77
|
+
return /* @__PURE__ */ j(A, { children: [
|
|
76
78
|
f ? /* @__PURE__ */ n(
|
|
77
|
-
|
|
79
|
+
O,
|
|
78
80
|
{
|
|
79
81
|
className: I || o.tooltip,
|
|
80
82
|
title: f,
|
|
@@ -82,11 +84,11 @@ const $ = (t) => {
|
|
|
82
84
|
placement: N,
|
|
83
85
|
size: m,
|
|
84
86
|
...s(a, "tooltip", c),
|
|
85
|
-
children: /* @__PURE__ */ n(
|
|
87
|
+
children: /* @__PURE__ */ n(b, { ...z, children: C() })
|
|
86
88
|
}
|
|
87
|
-
) : /* @__PURE__ */ n(
|
|
89
|
+
) : /* @__PURE__ */ n(b, { ...z, children: C() }),
|
|
88
90
|
y && /* @__PURE__ */ n(
|
|
89
|
-
|
|
91
|
+
_,
|
|
90
92
|
{
|
|
91
93
|
className: u(o.iconSkeleton, o.root),
|
|
92
94
|
variant: "rectangular",
|
|
@@ -97,7 +99,7 @@ const $ = (t) => {
|
|
|
97
99
|
)
|
|
98
100
|
] });
|
|
99
101
|
};
|
|
100
|
-
|
|
102
|
+
q.isM4LIconComponent = !0;
|
|
101
103
|
export {
|
|
102
|
-
|
|
104
|
+
q as Icon
|
|
103
105
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Icon.styles.d.ts","sourceRoot":"","sources":["../../../../../../packages/base/src/components/Icon/Icon.styles.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Icon.styles.d.ts","sourceRoot":"","sources":["../../../../../../packages/base/src/components/Icon/Icon.styles.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAkB,UAAU,EAAE,MAAM,SAAS,CAAC;AAkD1D,eAAO,MAAM,UAAU,EAAE,UAiExB,CAAC"}
|
|
@@ -1,69 +1,70 @@
|
|
|
1
|
-
import { getSizeStyles as
|
|
1
|
+
import { getSizeStyles as a } from "../../utils/getSizeStyles/getSizeStyles.js";
|
|
2
2
|
import { ICON_CLASSES as l } from "./constants.js";
|
|
3
|
-
import {
|
|
4
|
-
const
|
|
3
|
+
import { getOriginalSvgIconRootPaintStyles as d, ICON_SVG_SHAPE_SELECTOR as c } from "../../utils/getIconPaintStyles/getIconPaintStyles.js";
|
|
4
|
+
const p = {
|
|
5
5
|
small: 16,
|
|
6
6
|
medium: 24
|
|
7
7
|
};
|
|
8
|
-
function
|
|
9
|
-
const
|
|
10
|
-
return
|
|
8
|
+
function u(t, i) {
|
|
9
|
+
const e = t.vars?.palette ?? t.palette;
|
|
10
|
+
return i.split(".").reduce((s, n) => {
|
|
11
11
|
if (s && typeof s == "object" && n in s)
|
|
12
12
|
return s[n];
|
|
13
|
-
},
|
|
13
|
+
}, e) ?? (i.includes(".") ? e.text.primary : i);
|
|
14
14
|
}
|
|
15
|
-
function
|
|
15
|
+
function o(t, i = "medium") {
|
|
16
16
|
if (t.vars?.size && t.generalSettings)
|
|
17
|
-
return
|
|
17
|
+
return a(t, i, "base", (r) => ({
|
|
18
18
|
width: r,
|
|
19
19
|
height: r
|
|
20
20
|
}));
|
|
21
|
-
const
|
|
21
|
+
const e = p[i];
|
|
22
22
|
return {
|
|
23
|
-
width:
|
|
24
|
-
height:
|
|
23
|
+
width: e,
|
|
24
|
+
height: e
|
|
25
25
|
};
|
|
26
26
|
}
|
|
27
|
-
const
|
|
27
|
+
const k = {
|
|
28
28
|
/**
|
|
29
29
|
* Root styles for the Icon component, handling both mask and non-mask strategies, as well as disabled and selected states.
|
|
30
30
|
*/
|
|
31
|
-
root: ({ theme: t, ownerState:
|
|
32
|
-
const
|
|
31
|
+
root: ({ theme: t, ownerState: i }) => {
|
|
32
|
+
const e = i?.disabled ? (t.vars?.palette ?? t.palette).text.disabled : i?.selected && i?.enabledSelected ? (t.vars?.palette ?? t.palette).primary.enabled : u(t, String(i?.color));
|
|
33
33
|
return {
|
|
34
|
-
display:
|
|
34
|
+
display: i?.isSkeleton ? "none" : "flex",
|
|
35
35
|
justifyContent: "center",
|
|
36
36
|
alignItems: "center",
|
|
37
37
|
width: "fit-content",
|
|
38
38
|
transition: "transform 0.5s ease-in-out",
|
|
39
|
-
...
|
|
40
|
-
...
|
|
39
|
+
...o(t, i?.size ?? "medium"),
|
|
40
|
+
...i?.isMaskStrategy === !1 && {
|
|
41
41
|
"& .MuiSvgIcon-root": {
|
|
42
42
|
width: "inherit",
|
|
43
43
|
height: "inherit",
|
|
44
44
|
display: "flex",
|
|
45
45
|
alignItems: "center",
|
|
46
46
|
justifyContent: "center",
|
|
47
|
-
[
|
|
48
|
-
fill:
|
|
47
|
+
[c]: {
|
|
48
|
+
fill: e
|
|
49
49
|
}
|
|
50
50
|
}
|
|
51
51
|
},
|
|
52
|
-
...
|
|
52
|
+
...i?.isMaskStrategy === !0 && {
|
|
53
53
|
[`& .${l.icon}`]: {
|
|
54
54
|
maskPosition: "center",
|
|
55
55
|
maskRepeat: "no-repeat",
|
|
56
56
|
maskSize: "cover",
|
|
57
57
|
WebkitMaskRepeat: "no-repeat",
|
|
58
|
-
mask: `url(${
|
|
59
|
-
WebkitMask: `url(${
|
|
58
|
+
mask: `url(${i?.src})`,
|
|
59
|
+
WebkitMask: `url(${i?.src})`,
|
|
60
60
|
WebkitMaskSize: "cover",
|
|
61
|
-
...
|
|
62
|
-
transform: `rotate(${
|
|
61
|
+
...i?.rotationAngle && {
|
|
62
|
+
transform: `rotate(${i.rotationAngle}deg)`
|
|
63
63
|
},
|
|
64
|
-
backgroundColor:
|
|
64
|
+
backgroundColor: e
|
|
65
65
|
}
|
|
66
|
-
}
|
|
66
|
+
},
|
|
67
|
+
...i?.originalColor && d()
|
|
67
68
|
};
|
|
68
69
|
},
|
|
69
70
|
/**
|
|
@@ -76,14 +77,14 @@ const m = {
|
|
|
76
77
|
/**
|
|
77
78
|
* Skeleton styles for the icon element when in loading state.
|
|
78
79
|
*/
|
|
79
|
-
iconSkeleton: ({ theme: t, ownerState:
|
|
80
|
+
iconSkeleton: ({ theme: t, ownerState: i }) => ({
|
|
80
81
|
"&": {
|
|
81
82
|
borderRadius: t.size?.borderRadius?.r1 ?? t.shape.borderRadius,
|
|
82
|
-
...
|
|
83
|
+
...o(t, i?.size ?? "medium")
|
|
83
84
|
}
|
|
84
85
|
}),
|
|
85
86
|
tooltip: {}
|
|
86
87
|
};
|
|
87
88
|
export {
|
|
88
|
-
|
|
89
|
+
k as iconStyles
|
|
89
90
|
};
|
|
@@ -38,6 +38,8 @@ export interface IconBaseProps extends Pick<TooltipProps, 'placement'> {
|
|
|
38
38
|
onClick?: (event: React.MouseEvent<any, MouseEvent>) => void;
|
|
39
39
|
/** Optional aria-label override. */
|
|
40
40
|
ariaLabel?: string;
|
|
41
|
+
/** Restores authored fills for multicolor SVG component sources. */
|
|
42
|
+
originalColor?: boolean;
|
|
41
43
|
}
|
|
42
44
|
export type IconResourceSrc = IconBaseProps & ({
|
|
43
45
|
/** SVG source URL rendered with CSS mask. */
|
|
@@ -61,7 +63,7 @@ export type IconProps = IconResourceSrc | IconResourceComponent;
|
|
|
61
63
|
/**
|
|
62
64
|
* Owner state consumed by the styled Icon slots.
|
|
63
65
|
*/
|
|
64
|
-
export interface IconOwnerState extends Pick<IconBaseProps, 'selected' | 'enabledSelected' | 'size' | 'rotationAngle' | 'color' | 'disabled'> {
|
|
66
|
+
export interface IconOwnerState extends Pick<IconBaseProps, 'selected' | 'enabledSelected' | 'size' | 'rotationAngle' | 'color' | 'disabled' | 'originalColor'> {
|
|
65
67
|
src?: string | ReactNode;
|
|
66
68
|
isSkeleton?: boolean;
|
|
67
69
|
isMaskStrategy?: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../packages/base/src/components/Icon/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAChD,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACpC,OAAO,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AACpE,OAAO,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAChE,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAE7C;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,SAAS,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,SAAS,CAAC,CAAC,GAAG,MAAM,CAAC;AAEzE,MAAM,WAAW,aAAc,SAAQ,IAAI,CAAC,YAAY,EAAE,WAAW,CAAC;IACpE,iCAAiC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,MAAM,qBAAqB,GAAG,aAAa,GAAG,CAChD;IACE,uCAAuC;IACvC,GAAG,EAAE,YAAY,CAAC;IAClB,IAAI,CAAC,EAAE,KAAK,CAAC;CACd,GACD;IACE,GAAG,CAAC,EAAE,KAAK,CAAC;IACZ,2DAA2D;IAC3D,IAAI,EAAE,YAAY,CAAC;CACpB,CACJ,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG,eAAe,GAAG,qBAAqB,CAAC;AAEhE;;GAEG;AACH,MAAM,WAAW,cAAe,SAAQ,IAAI,CAC1C,aAAa,EACb,UAAU,GAAG,iBAAiB,GAAG,MAAM,GAAG,eAAe,GAAG,OAAO,GAAG,UAAU,GAAG,eAAe,CACnG;IACC,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,cAAc,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED,MAAM,MAAM,aAAa,GAAG,MAAM,OAAO,SAAS,CAAC;AAEnD,MAAM,MAAM,UAAU,GAAG,sBAAsB,CAC7C,aAAa,EACb,OAAO,kBAAkB,EACzB,KAAK,CACN,CAAC"}
|
package/index.js
CHANGED
|
@@ -1,35 +1,39 @@
|
|
|
1
|
-
import { Icon as
|
|
2
|
-
import { ICON_CLASSES as
|
|
1
|
+
import { Icon as t } from "./components/Icon/Icon.js";
|
|
2
|
+
import { ICON_CLASSES as _, ICON_KEY_COMPONENT as r, ICON_PREFIX as T } from "./components/Icon/constants.js";
|
|
3
3
|
import { ButtonBase as E } from "./extended/mui/ButtonBase/ButtonBase.js";
|
|
4
|
-
import { buttonBaseStyles as
|
|
4
|
+
import { buttonBaseStyles as I } from "./extended/mui/ButtonBase/ButtonBase.styles.js";
|
|
5
5
|
import { BUTTON_BASE_KEY_COMPONENT as C } from "./extended/mui/ButtonBase/constants.js";
|
|
6
|
-
import { ButtonBaseSlots as
|
|
7
|
-
import { RootStyled as
|
|
8
|
-
import { Tooltip as
|
|
9
|
-
import { DEFAULT_TOOLTIP_OFFSET as
|
|
10
|
-
import { Typography as
|
|
11
|
-
import { TYPOGRAPHY_CLASSES as
|
|
12
|
-
import { ICON_SVG_SHAPE_SELECTOR as
|
|
6
|
+
import { ButtonBaseSlots as p } from "./extended/mui/ButtonBase/slots/ButtonBaseEnum.js";
|
|
7
|
+
import { RootStyled as L, SkeletonStyled as R } from "./extended/mui/ButtonBase/slots/ButtonBaseSlots.js";
|
|
8
|
+
import { Tooltip as f } from "./extended/mui/Tooltip/Tooltip.js";
|
|
9
|
+
import { DEFAULT_TOOLTIP_OFFSET as x, TOOLTIP_CLASSES as l, TOOLTIP_KEY_COMPONENT as a } from "./extended/mui/Tooltip/constants.js";
|
|
10
|
+
import { Typography as g } from "./extended/mui/Typography/Typography.js";
|
|
11
|
+
import { TYPOGRAPHY_CLASSES as s, TYPOGRAPHY_CLASS_NAME_SPECIFY as y, TYPOGRAPHY_FONTS as B, TYPOGRAPHY_KEY_COMPONENT as F } from "./extended/mui/Typography/constants.js";
|
|
12
|
+
import { ICON_SVG_SHAPE_SELECTOR as M, ORIGINAL_SVG_ICON_PAINT_SELECTOR as c, ORIGINAL_SVG_ICON_ROOT_PAINT_SELECTOR as K, getIconPaintStyles as u, getOriginalSvgIconPaintStyles as V, getOriginalSvgIconRootPaintStyles as d } from "./utils/getIconPaintStyles/getIconPaintStyles.js";
|
|
13
13
|
export {
|
|
14
14
|
C as BUTTON_BASE_KEY_COMPONENT,
|
|
15
15
|
E as ButtonBase,
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
16
|
+
p as ButtonBaseSlots,
|
|
17
|
+
x as DEFAULT_TOOLTIP_OFFSET,
|
|
18
|
+
_ as ICON_CLASSES,
|
|
19
|
+
r as ICON_KEY_COMPONENT,
|
|
20
20
|
T as ICON_PREFIX,
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
R as
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
21
|
+
M as ICON_SVG_SHAPE_SELECTOR,
|
|
22
|
+
t as Icon,
|
|
23
|
+
c as ORIGINAL_SVG_ICON_PAINT_SELECTOR,
|
|
24
|
+
K as ORIGINAL_SVG_ICON_ROOT_PAINT_SELECTOR,
|
|
25
|
+
L as RootStyled,
|
|
26
|
+
R as SkeletonStyled,
|
|
27
|
+
l as TOOLTIP_CLASSES,
|
|
28
|
+
a as TOOLTIP_KEY_COMPONENT,
|
|
29
|
+
s as TYPOGRAPHY_CLASSES,
|
|
30
|
+
y as TYPOGRAPHY_CLASS_NAME_SPECIFY,
|
|
31
|
+
B as TYPOGRAPHY_FONTS,
|
|
32
|
+
F as TYPOGRAPHY_KEY_COMPONENT,
|
|
33
|
+
f as Tooltip,
|
|
34
|
+
g as Typography,
|
|
35
|
+
I as buttonBaseStyles,
|
|
36
|
+
u as getIconPaintStyles,
|
|
37
|
+
V as getOriginalSvgIconPaintStyles,
|
|
38
|
+
d as getOriginalSvgIconRootPaintStyles
|
|
35
39
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@m4l/base",
|
|
3
|
-
"version": "1.7.0",
|
|
3
|
+
"version": "1.7.2-beta-m4lcom-785-data-grids-implementar-la-funcionalidad-de-scroll-infinito.0",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@m4l/core": "^2.0.33",
|
|
33
33
|
"@m4l/icons": "^1.0.0",
|
|
34
|
-
"@m4l/styles": "^7.
|
|
34
|
+
"@m4l/styles": "^7.2.0",
|
|
35
35
|
"@emotion/react": "11.14.0",
|
|
36
36
|
"clsx": "2.1.1",
|
|
37
37
|
"react": "19.1.0",
|
|
@@ -8,6 +8,13 @@
|
|
|
8
8
|
* silently misses every SVG icon, so both branches must always be declared.
|
|
9
9
|
*/
|
|
10
10
|
export declare const ICON_SVG_SHAPE_SELECTOR = "& svg, & path, & rect, & circle, & ellipse, & polygon, & polyline, & line, & g, & text, & tspan, & use";
|
|
11
|
+
/**
|
|
12
|
+
* Nodes whose fill multicolor sources restore. Besides shapes with an authored `fill`,
|
|
13
|
+
* stroke-only shapes (e.g. an illustration card border) and the `g` groups they inherit
|
|
14
|
+
* from must be reverted too, or they keep the icon color and cover the artwork.
|
|
15
|
+
*/
|
|
16
|
+
export declare const ORIGINAL_SVG_ICON_PAINT_SELECTOR = "&&&:not(.Mui-disabled) .M4LIcon-root .MuiSvgIcon-root :is([fill], [stroke], g)";
|
|
17
|
+
export declare const ORIGINAL_SVG_ICON_ROOT_PAINT_SELECTOR = "&&&:not([aria-disabled=\"true\"]) .MuiSvgIcon-root :is([fill], [stroke], g)";
|
|
11
18
|
export interface IconPaintOptions {
|
|
12
19
|
/**
|
|
13
20
|
* Selector inserted between the rule root and the icon nodes, for call sites
|
|
@@ -40,4 +47,20 @@ export declare function getIconPaintStyles(color: string, options?: IconPaintOpt
|
|
|
40
47
|
backgroundColor?: undefined;
|
|
41
48
|
};
|
|
42
49
|
};
|
|
50
|
+
/**
|
|
51
|
+
* Restore presentation fills for enabled multicolor SVG actions.
|
|
52
|
+
*/
|
|
53
|
+
export declare function getOriginalSvgIconPaintStyles(): {
|
|
54
|
+
"&&&:not(.Mui-disabled) .M4LIcon-root .MuiSvgIcon-root :is([fill], [stroke], g)": {
|
|
55
|
+
fill: string;
|
|
56
|
+
};
|
|
57
|
+
};
|
|
58
|
+
/**
|
|
59
|
+
* Restore presentation fills for enabled multicolor SVG resources rendered directly by Icon.
|
|
60
|
+
*/
|
|
61
|
+
export declare function getOriginalSvgIconRootPaintStyles(): {
|
|
62
|
+
"&&&:not([aria-disabled=\"true\"]) .MuiSvgIcon-root :is([fill], [stroke], g)": {
|
|
63
|
+
fill: string;
|
|
64
|
+
};
|
|
65
|
+
};
|
|
43
66
|
//# sourceMappingURL=getIconPaintStyles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getIconPaintStyles.d.ts","sourceRoot":"","sources":["../../../../../../packages/base/src/utils/getIconPaintStyles/getIconPaintStyles.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,eAAO,MAAM,uBAAuB,2GACsE,CAAC;
|
|
1
|
+
{"version":3,"file":"getIconPaintStyles.d.ts","sourceRoot":"","sources":["../../../../../../packages/base/src/utils/getIconPaintStyles/getIconPaintStyles.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,eAAO,MAAM,uBAAuB,2GACsE,CAAC;AAC3G;;;;GAIG;AACH,eAAO,MAAM,gCAAgC,mFACqC,CAAC;AACnF,eAAO,MAAM,qCAAqC,gFAC2B,CAAC;AAE9E,MAAM,WAAW,gBAAgB;IAC/B;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;OAIG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,gBAAgB;;;;;;;;;;;EAgB3E;AAED;;GAEG;AACH,wBAAgB,6BAA6B;;;;EAM5C;AAED;;GAEG;AACH,wBAAgB,iCAAiC;;;;EAMhD"}
|
|
@@ -1,19 +1,37 @@
|
|
|
1
|
-
const
|
|
2
|
-
function
|
|
3
|
-
const { scope:
|
|
1
|
+
const l = "& svg, & path, & rect, & circle, & ellipse, & polygon, & polyline, & line, & g, & text, & tspan, & use", c = "&&&:not(.Mui-disabled) .M4LIcon-root .MuiSvgIcon-root :is([fill], [stroke], g)", s = '&&&:not([aria-disabled="true"]) .MuiSvgIcon-root :is([fill], [stroke], g)';
|
|
2
|
+
function a(t, i) {
|
|
3
|
+
const { scope: o, important: r = !0 } = i ?? {}, n = o ? `& ${o} ` : "& ", e = r ? `${t} !important` : t;
|
|
4
4
|
return {
|
|
5
|
-
[`${
|
|
5
|
+
[`${n}.M4LIcon-icon`]: {
|
|
6
6
|
backgroundColor: e
|
|
7
7
|
},
|
|
8
|
-
[`${
|
|
9
|
-
[
|
|
8
|
+
[`${n}.MuiSvgIcon-root`]: {
|
|
9
|
+
[l]: {
|
|
10
10
|
fill: e,
|
|
11
11
|
stroke: "none"
|
|
12
12
|
}
|
|
13
13
|
}
|
|
14
14
|
};
|
|
15
15
|
}
|
|
16
|
+
function I() {
|
|
17
|
+
return {
|
|
18
|
+
[c]: {
|
|
19
|
+
fill: "revert-layer"
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
function g() {
|
|
24
|
+
return {
|
|
25
|
+
[s]: {
|
|
26
|
+
fill: "revert-layer"
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
}
|
|
16
30
|
export {
|
|
17
|
-
|
|
18
|
-
|
|
31
|
+
l as ICON_SVG_SHAPE_SELECTOR,
|
|
32
|
+
c as ORIGINAL_SVG_ICON_PAINT_SELECTOR,
|
|
33
|
+
s as ORIGINAL_SVG_ICON_ROOT_PAINT_SELECTOR,
|
|
34
|
+
a as getIconPaintStyles,
|
|
35
|
+
I as getOriginalSvgIconPaintStyles,
|
|
36
|
+
g as getOriginalSvgIconRootPaintStyles
|
|
19
37
|
};
|