@redis-ui/components 51.13.0 → 51.14.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Stepper/components/Step/components/Icon/Icon.cjs +1 -2
- package/dist/Stepper/components/Step/components/Icon/Icon.js +2 -3
- package/dist/Stepper/components/Step/components/Icon/Icon.style.cjs +18 -4
- package/dist/Stepper/components/Step/components/Icon/Icon.style.d.ts +1 -0
- package/dist/Stepper/components/Step/components/Icon/Icon.style.js +18 -5
- package/package.json +2 -2
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
const require_Typography = require("../../../../../Typography/Typography.cjs");
|
|
2
1
|
const require_Step_context = require("../../Step.context.cjs");
|
|
3
2
|
const require_Stepper_context = require("../../../../Stepper.context.cjs");
|
|
4
3
|
const require_Step_types = require("../../Step.types.cjs");
|
|
@@ -12,7 +11,7 @@ var Icon = ({ children, ...restProps }) => {
|
|
|
12
11
|
...restProps,
|
|
13
12
|
"data-state": state,
|
|
14
13
|
"aria-hidden": true,
|
|
15
|
-
children: state === require_Step_types.StepperStepState.COMPLETED && !isCompact ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Icon_style.IconCheck, {}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
14
|
+
children: state === require_Step_types.StepperStepState.COMPLETED && !isCompact ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Icon_style.IconCheck, {}) : /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_Icon_style.Number, {
|
|
16
15
|
size: "S",
|
|
17
16
|
component: "div",
|
|
18
17
|
children: !isCompact && children || index + 1
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import Typography from "../../../../../Typography/Typography.js";
|
|
2
1
|
import { useStepContext } from "../../Step.context.js";
|
|
3
2
|
import { useStepperContext } from "../../../../Stepper.context.js";
|
|
4
3
|
import { StepperStepState } from "../../Step.types.js";
|
|
5
|
-
import { Container, IconCheck } from "./Icon.style.js";
|
|
4
|
+
import { Container, IconCheck, Number } from "./Icon.style.js";
|
|
6
5
|
import { jsx } from "react/jsx-runtime";
|
|
7
6
|
//#region src/Stepper/components/Step/components/Icon/Icon.tsx
|
|
8
7
|
var Icon = ({ children, ...restProps }) => {
|
|
@@ -12,7 +11,7 @@ var Icon = ({ children, ...restProps }) => {
|
|
|
12
11
|
...restProps,
|
|
13
12
|
"data-state": state,
|
|
14
13
|
"aria-hidden": true,
|
|
15
|
-
children: state === StepperStepState.COMPLETED && !isCompact ? /* @__PURE__ */ jsx(IconCheck, {}) : /* @__PURE__ */ jsx(
|
|
14
|
+
children: state === StepperStepState.COMPLETED && !isCompact ? /* @__PURE__ */ jsx(IconCheck, {}) : /* @__PURE__ */ jsx(Number, {
|
|
16
15
|
size: "S",
|
|
17
16
|
component: "div",
|
|
18
17
|
children: !isCompact && children || index + 1
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
const require_runtime = require("../../../../../_virtual/_rolldown/runtime.cjs");
|
|
2
|
+
const require_Typography = require("../../../../../Typography/Typography.cjs");
|
|
2
3
|
const require_Step_types = require("../../Step.types.cjs");
|
|
3
4
|
const require_Compose_style = require("../../../Compose/Compose.style.cjs");
|
|
4
5
|
let styled_components = require("styled-components");
|
|
@@ -10,11 +11,11 @@ var Container = styled_components.default.div.withConfig({
|
|
|
10
11
|
displayName: "Iconstyle__Container",
|
|
11
12
|
componentId: "RedisUI__sc-1ojkwgp-0"
|
|
12
13
|
})([
|
|
13
|
-
"display:flex;align-items:center;justify-content:center;flex:none;line-height:0;transition:all 0.3s ease;@media (prefers-reduced-motion:reduce){transition:none;}width:",
|
|
14
|
+
"display:flex;align-items:center;justify-content:center;flex:none;box-sizing:border-box;line-height:0;transition:all 0.3s ease;@media (prefers-reduced-motion:reduce){transition:none;}width:",
|
|
14
15
|
";height:",
|
|
15
16
|
";",
|
|
16
17
|
" ",
|
|
17
|
-
"[data-variant='compact'] &&{width:auto;height:auto;padding:0;border-radius:0;background-color:transparent;line-height:inherit;> *{font-family:inherit;font-size:inherit;}}",
|
|
18
|
+
"[data-variant='compact'] &&{width:auto;height:auto;padding:0;border:none;border-radius:0;background-color:transparent;line-height:inherit;> *{font-family:inherit;font-size:inherit;font-weight:inherit;}}",
|
|
18
19
|
""
|
|
19
20
|
], () => (0, _redislabsdev_redis_ui_styles.useTheme)().components.stepper.step.indicator.size, () => (0, _redislabsdev_redis_ui_styles.useTheme)().components.stepper.step.indicator.size, () => {
|
|
20
21
|
const { states } = (0, _redislabsdev_redis_ui_styles.useTheme)().components.stepper.step;
|
|
@@ -24,16 +25,29 @@ var Container = styled_components.default.div.withConfig({
|
|
|
24
25
|
&[data-state='${state}'] {
|
|
25
26
|
background-color: ${theme.bgColor};
|
|
26
27
|
color: ${theme.iconColor};
|
|
28
|
+
border: ${theme.border};
|
|
27
29
|
border-radius: ${theme.borderRadius};
|
|
28
30
|
padding: ${theme.padding};
|
|
29
31
|
}
|
|
30
32
|
`;
|
|
31
33
|
});
|
|
32
34
|
}, require_Compose_style.StepperCompose, require_Compose_style.useCompactStateStyle);
|
|
35
|
+
var Number = (0, styled_components.default)(require_Typography.default.Body).withConfig({
|
|
36
|
+
displayName: "Iconstyle__Number",
|
|
37
|
+
componentId: "RedisUI__sc-1ojkwgp-1"
|
|
38
|
+
})(["", ""], () => {
|
|
39
|
+
const { fontFamily, fontSize, fontWeight } = (0, _redislabsdev_redis_ui_styles.useTheme)().components.stepper.step.indicator;
|
|
40
|
+
return styled_components.css`
|
|
41
|
+
font-family: ${fontFamily};
|
|
42
|
+
font-size: ${fontSize};
|
|
43
|
+
font-weight: ${fontWeight};
|
|
44
|
+
`;
|
|
45
|
+
});
|
|
33
46
|
var IconCheck = (0, styled_components.default)(_redislabsdev_redis_ui_icons.CheckBoldIcon).withConfig({
|
|
34
47
|
displayName: "Iconstyle__IconCheck",
|
|
35
|
-
componentId: "RedisUI__sc-1ojkwgp-
|
|
36
|
-
})(["
|
|
48
|
+
componentId: "RedisUI__sc-1ojkwgp-2"
|
|
49
|
+
})(["width:100%;height:100%;&,> *{fill:currentColor;}"]);
|
|
37
50
|
//#endregion
|
|
38
51
|
exports.Container = Container;
|
|
39
52
|
exports.IconCheck = IconCheck;
|
|
53
|
+
exports.Number = Number;
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
export declare const Container: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
2
|
+
export declare const Number: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("../../../../..").TypographyBodyProps & import("react").RefAttributes<HTMLElement>>, any, {}, never>;
|
|
2
3
|
export declare const IconCheck: import("styled-components").StyledComponent<({ size, customSize, variant, title: titleProp, ...rest }: import("@redis-ui/icons").MonochromeIconProps) => import("react/jsx-runtime").JSX.Element, any, {}, never>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import Typography from "../../../../../Typography/Typography.js";
|
|
1
2
|
import { StepperStepState } from "../../Step.types.js";
|
|
2
3
|
import { StepperCompose, useCompactStateStyle } from "../../../Compose/Compose.style.js";
|
|
3
4
|
import _styled, { css } from "styled-components";
|
|
@@ -8,11 +9,11 @@ var Container = _styled.div.withConfig({
|
|
|
8
9
|
displayName: "Iconstyle__Container",
|
|
9
10
|
componentId: "RedisUI__sc-1ojkwgp-0"
|
|
10
11
|
})([
|
|
11
|
-
"display:flex;align-items:center;justify-content:center;flex:none;line-height:0;transition:all 0.3s ease;@media (prefers-reduced-motion:reduce){transition:none;}width:",
|
|
12
|
+
"display:flex;align-items:center;justify-content:center;flex:none;box-sizing:border-box;line-height:0;transition:all 0.3s ease;@media (prefers-reduced-motion:reduce){transition:none;}width:",
|
|
12
13
|
";height:",
|
|
13
14
|
";",
|
|
14
15
|
" ",
|
|
15
|
-
"[data-variant='compact'] &&{width:auto;height:auto;padding:0;border-radius:0;background-color:transparent;line-height:inherit;> *{font-family:inherit;font-size:inherit;}}",
|
|
16
|
+
"[data-variant='compact'] &&{width:auto;height:auto;padding:0;border:none;border-radius:0;background-color:transparent;line-height:inherit;> *{font-family:inherit;font-size:inherit;font-weight:inherit;}}",
|
|
16
17
|
""
|
|
17
18
|
], () => useTheme().components.stepper.step.indicator.size, () => useTheme().components.stepper.step.indicator.size, () => {
|
|
18
19
|
const { states } = useTheme().components.stepper.step;
|
|
@@ -22,15 +23,27 @@ var Container = _styled.div.withConfig({
|
|
|
22
23
|
&[data-state='${state}'] {
|
|
23
24
|
background-color: ${theme.bgColor};
|
|
24
25
|
color: ${theme.iconColor};
|
|
26
|
+
border: ${theme.border};
|
|
25
27
|
border-radius: ${theme.borderRadius};
|
|
26
28
|
padding: ${theme.padding};
|
|
27
29
|
}
|
|
28
30
|
`;
|
|
29
31
|
});
|
|
30
32
|
}, StepperCompose, useCompactStateStyle);
|
|
33
|
+
var Number = _styled(Typography.Body).withConfig({
|
|
34
|
+
displayName: "Iconstyle__Number",
|
|
35
|
+
componentId: "RedisUI__sc-1ojkwgp-1"
|
|
36
|
+
})(["", ""], () => {
|
|
37
|
+
const { fontFamily, fontSize, fontWeight } = useTheme().components.stepper.step.indicator;
|
|
38
|
+
return css`
|
|
39
|
+
font-family: ${fontFamily};
|
|
40
|
+
font-size: ${fontSize};
|
|
41
|
+
font-weight: ${fontWeight};
|
|
42
|
+
`;
|
|
43
|
+
});
|
|
31
44
|
var IconCheck = _styled(CheckBoldIcon).withConfig({
|
|
32
45
|
displayName: "Iconstyle__IconCheck",
|
|
33
|
-
componentId: "RedisUI__sc-1ojkwgp-
|
|
34
|
-
})(["
|
|
46
|
+
componentId: "RedisUI__sc-1ojkwgp-2"
|
|
47
|
+
})(["width:100%;height:100%;&,> *{fill:currentColor;}"]);
|
|
35
48
|
//#endregion
|
|
36
|
-
export { Container, IconCheck };
|
|
49
|
+
export { Container, IconCheck, Number };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@redis-ui/components",
|
|
3
3
|
"license": "UNLICENSED",
|
|
4
|
-
"version": "51.
|
|
4
|
+
"version": "51.14.1",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": false,
|
|
7
7
|
"repository": "git@github.com:redislabsdev/redis-ui.git",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|
|
32
32
|
"@redis-ui/icons": "^8.0.0 || ^9.0.0 || ^10.0.0",
|
|
33
|
-
"@redis-ui/styles": "^21.
|
|
33
|
+
"@redis-ui/styles": "^21.20.0",
|
|
34
34
|
"react": "^18.0.0 || ^19.0.0",
|
|
35
35
|
"react-dom": "^18.0.0 || ^19.0.0",
|
|
36
36
|
"styled-components": "^5.0.0"
|