@astral/ui 4.49.0 → 4.50.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/NewStepper/NewStepper.d.ts +2 -0
- package/components/NewStepper/NewStepper.js +30 -0
- package/components/NewStepper/Step/Description/Description.d.ts +7 -0
- package/components/NewStepper/Step/Description/Description.js +8 -0
- package/components/NewStepper/Step/Description/index.d.ts +1 -0
- package/components/NewStepper/Step/Description/index.js +1 -0
- package/components/NewStepper/Step/Description/styles.d.ts +11 -0
- package/components/NewStepper/Step/Description/styles.js +18 -0
- package/components/NewStepper/Step/Label/Label.d.ts +8 -0
- package/components/NewStepper/Step/Label/Label.js +9 -0
- package/components/NewStepper/Step/Label/index.d.ts +1 -0
- package/components/NewStepper/Step/Label/index.js +1 -0
- package/components/NewStepper/Step/Label/styles.d.ts +25 -0
- package/components/NewStepper/Step/Label/styles.js +18 -0
- package/components/NewStepper/Step/Label/useLogic/index.d.ts +1 -0
- package/components/NewStepper/Step/Label/useLogic/index.js +1 -0
- package/components/NewStepper/Step/Label/useLogic/useLogic.d.ts +7 -0
- package/components/NewStepper/Step/Label/useLogic/useLogic.js +7 -0
- package/components/NewStepper/Step/Step.d.ts +2 -0
- package/components/NewStepper/Step/Step.js +80 -0
- package/components/NewStepper/Step/constants.d.ts +28 -0
- package/components/NewStepper/Step/constants.js +25 -0
- package/components/NewStepper/Step/index.d.ts +3 -0
- package/components/NewStepper/Step/index.js +2 -0
- package/components/NewStepper/Step/styles.d.ts +38 -0
- package/components/NewStepper/Step/styles.js +303 -0
- package/components/NewStepper/Step/types.d.ts +44 -0
- package/components/NewStepper/Step/types.js +1 -0
- package/components/NewStepper/Step/useLogic/index.d.ts +1 -0
- package/components/NewStepper/Step/useLogic/index.js +1 -0
- package/components/NewStepper/Step/useLogic/useLogic.d.ts +23 -0
- package/components/NewStepper/Step/useLogic/useLogic.js +55 -0
- package/components/NewStepper/StepIcon/StepIcon.d.ts +28 -0
- package/components/NewStepper/StepIcon/StepIcon.js +34 -0
- package/components/NewStepper/StepIcon/constants.d.ts +7 -0
- package/components/NewStepper/StepIcon/constants.js +8 -0
- package/components/NewStepper/StepIcon/index.d.ts +2 -0
- package/components/NewStepper/StepIcon/index.js +2 -0
- package/components/NewStepper/StepperContext/StepperContext.d.ts +11 -0
- package/components/NewStepper/StepperContext/StepperContext.js +10 -0
- package/components/NewStepper/StepperContext/StepperContextProvider/StepperContextProvider.d.ts +7 -0
- package/components/NewStepper/StepperContext/StepperContextProvider/StepperContextProvider.js +23 -0
- package/components/NewStepper/StepperContext/StepperContextProvider/index.d.ts +1 -0
- package/components/NewStepper/StepperContext/StepperContextProvider/index.js +1 -0
- package/components/NewStepper/StepperContext/index.d.ts +2 -0
- package/components/NewStepper/StepperContext/index.js +2 -0
- package/components/NewStepper/constants.d.ts +12 -0
- package/components/NewStepper/constants.js +13 -0
- package/components/NewStepper/index.d.ts +4 -0
- package/components/NewStepper/index.js +3 -0
- package/components/NewStepper/public.d.ts +4 -0
- package/components/NewStepper/public.js +3 -0
- package/components/NewStepper/styles.d.ts +5 -0
- package/components/NewStepper/styles.js +34 -0
- package/components/NewStepper/types.d.ts +33 -0
- package/components/NewStepper/types.js +1 -0
- package/components/NewStepper/useLogic/index.d.ts +1 -0
- package/components/NewStepper/useLogic/index.js +1 -0
- package/components/NewStepper/useLogic/useLogic.d.ts +15 -0
- package/components/NewStepper/useLogic/useLogic.js +47 -0
- package/components/NewStepper/useLogic/utils/index.d.ts +1 -0
- package/components/NewStepper/useLogic/utils/index.js +1 -0
- package/components/NewStepper/useLogic/utils/validateStepperProps/index.d.ts +1 -0
- package/components/NewStepper/useLogic/utils/validateStepperProps/index.js +1 -0
- package/components/NewStepper/useLogic/utils/validateStepperProps/validateStepperProps.d.ts +5 -0
- package/components/NewStepper/useLogic/utils/validateStepperProps/validateStepperProps.js +16 -0
- package/components/Stepper/Stepper.d.ts +3 -0
- package/components/Stepper/Stepper.js +3 -0
- package/components/StepperWizard/StepperWizard.d.ts +3 -0
- package/components/StepperWizard/StepperWizard.js +3 -0
- package/components/Typography/Typography.js +1 -1
- package/components/Typography/constants.d.ts +1 -0
- package/components/Typography/constants.js +2 -0
- package/node/components/NewStepper/NewStepper.d.ts +2 -0
- package/node/components/NewStepper/NewStepper.js +34 -0
- package/node/components/NewStepper/Step/Description/Description.d.ts +7 -0
- package/node/components/NewStepper/Step/Description/Description.js +12 -0
- package/node/components/NewStepper/Step/Description/index.d.ts +1 -0
- package/node/components/NewStepper/Step/Description/index.js +17 -0
- package/node/components/NewStepper/Step/Description/styles.d.ts +11 -0
- package/node/components/NewStepper/Step/Description/styles.js +21 -0
- package/node/components/NewStepper/Step/Label/Label.d.ts +8 -0
- package/node/components/NewStepper/Step/Label/Label.js +13 -0
- package/node/components/NewStepper/Step/Label/index.d.ts +1 -0
- package/node/components/NewStepper/Step/Label/index.js +5 -0
- package/node/components/NewStepper/Step/Label/styles.d.ts +25 -0
- package/node/components/NewStepper/Step/Label/styles.js +21 -0
- package/node/components/NewStepper/Step/Label/useLogic/index.d.ts +1 -0
- package/node/components/NewStepper/Step/Label/useLogic/index.js +17 -0
- package/node/components/NewStepper/Step/Label/useLogic/useLogic.d.ts +7 -0
- package/node/components/NewStepper/Step/Label/useLogic/useLogic.js +11 -0
- package/node/components/NewStepper/Step/Step.d.ts +2 -0
- package/node/components/NewStepper/Step/Step.js +84 -0
- package/node/components/NewStepper/Step/constants.d.ts +28 -0
- package/node/components/NewStepper/Step/constants.js +28 -0
- package/node/components/NewStepper/Step/index.d.ts +3 -0
- package/node/components/NewStepper/Step/index.js +7 -0
- package/node/components/NewStepper/Step/styles.d.ts +38 -0
- package/node/components/NewStepper/Step/styles.js +306 -0
- package/node/components/NewStepper/Step/types.d.ts +44 -0
- package/node/components/NewStepper/Step/types.js +2 -0
- package/node/components/NewStepper/Step/useLogic/index.d.ts +1 -0
- package/node/components/NewStepper/Step/useLogic/index.js +17 -0
- package/node/components/NewStepper/Step/useLogic/useLogic.d.ts +23 -0
- package/node/components/NewStepper/Step/useLogic/useLogic.js +59 -0
- package/node/components/NewStepper/StepIcon/StepIcon.d.ts +28 -0
- package/node/components/NewStepper/StepIcon/StepIcon.js +38 -0
- package/node/components/NewStepper/StepIcon/constants.d.ts +7 -0
- package/node/components/NewStepper/StepIcon/constants.js +11 -0
- package/node/components/NewStepper/StepIcon/index.d.ts +2 -0
- package/node/components/NewStepper/StepIcon/index.js +7 -0
- package/node/components/NewStepper/StepperContext/StepperContext.d.ts +11 -0
- package/node/components/NewStepper/StepperContext/StepperContext.js +13 -0
- package/node/components/NewStepper/StepperContext/StepperContextProvider/StepperContextProvider.d.ts +7 -0
- package/node/components/NewStepper/StepperContext/StepperContextProvider/StepperContextProvider.js +27 -0
- package/node/components/NewStepper/StepperContext/StepperContextProvider/index.d.ts +1 -0
- package/node/components/NewStepper/StepperContext/StepperContextProvider/index.js +17 -0
- package/node/components/NewStepper/StepperContext/index.d.ts +2 -0
- package/node/components/NewStepper/StepperContext/index.js +18 -0
- package/node/components/NewStepper/constants.d.ts +12 -0
- package/node/components/NewStepper/constants.js +16 -0
- package/node/components/NewStepper/index.d.ts +4 -0
- package/node/components/NewStepper/index.js +10 -0
- package/node/components/NewStepper/public.d.ts +4 -0
- package/node/components/NewStepper/public.js +10 -0
- package/node/components/NewStepper/styles.d.ts +5 -0
- package/node/components/NewStepper/styles.js +37 -0
- package/node/components/NewStepper/types.d.ts +33 -0
- package/node/components/NewStepper/types.js +2 -0
- package/node/components/NewStepper/useLogic/index.d.ts +1 -0
- package/node/components/NewStepper/useLogic/index.js +17 -0
- package/node/components/NewStepper/useLogic/useLogic.d.ts +15 -0
- package/node/components/NewStepper/useLogic/useLogic.js +51 -0
- package/node/components/NewStepper/useLogic/utils/index.d.ts +1 -0
- package/node/components/NewStepper/useLogic/utils/index.js +17 -0
- package/node/components/NewStepper/useLogic/utils/validateStepperProps/index.d.ts +1 -0
- package/node/components/NewStepper/useLogic/utils/validateStepperProps/index.js +17 -0
- package/node/components/NewStepper/useLogic/utils/validateStepperProps/validateStepperProps.d.ts +5 -0
- package/node/components/NewStepper/useLogic/utils/validateStepperProps/validateStepperProps.js +20 -0
- package/node/components/Stepper/Stepper.d.ts +3 -0
- package/node/components/Stepper/Stepper.js +3 -0
- package/node/components/StepperWizard/StepperWizard.d.ts +3 -0
- package/node/components/StepperWizard/StepperWizard.js +3 -0
- package/node/components/Typography/Typography.js +1 -1
- package/node/components/Typography/constants.d.ts +1 -0
- package/node/components/Typography/constants.js +2 -0
- package/package.json +1 -1
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { classNames } from '../utils/classNames';
|
|
3
|
+
import { cva } from '../utils/cva';
|
|
4
|
+
import { stepperClassnames } from './constants';
|
|
5
|
+
import { StepperContextProvider } from './StepperContext';
|
|
6
|
+
import { Wrapper } from './styles';
|
|
7
|
+
import { useLogic } from './useLogic';
|
|
8
|
+
const stepper = cva(stepperClassnames.root, {
|
|
9
|
+
variants: {
|
|
10
|
+
orientation: {
|
|
11
|
+
horizontal: stepperClassnames.orientationHorizontal,
|
|
12
|
+
vertical: stepperClassnames.orientationVertical,
|
|
13
|
+
},
|
|
14
|
+
alternativeLabel: {
|
|
15
|
+
true: stepperClassnames.alternativeLabel,
|
|
16
|
+
},
|
|
17
|
+
connector: {
|
|
18
|
+
arrow: stepperClassnames.arrowConnector,
|
|
19
|
+
line: stepperClassnames.lineConnector,
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
});
|
|
23
|
+
export const NewStepper = (props) => {
|
|
24
|
+
const { containerRef, stepperConnector, stepperAlternativeLabel, activeStep, onClickPrevStep, onClickStep, orientation, className, children, } = useLogic(props);
|
|
25
|
+
return (_jsx(StepperContextProvider, { orientation: orientation, activeStep: activeStep, setActiveStep: () => undefined, connector: stepperConnector, alternativeLabel: stepperAlternativeLabel, onClickPrevStep: onClickPrevStep, onClickStep: onClickStep, children: _jsx(Wrapper, { ref: containerRef, role: "group", className: classNames(stepper({
|
|
26
|
+
alternativeLabel: stepperAlternativeLabel,
|
|
27
|
+
connector: stepperConnector,
|
|
28
|
+
orientation,
|
|
29
|
+
}), className), children: children }) }));
|
|
30
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { StyledTypography } from './styles';
|
|
3
|
+
export const Description = ({ children, className }) => {
|
|
4
|
+
if (typeof children === 'string') {
|
|
5
|
+
return (_jsx(StyledTypography, { variant: "caption", className: className, children: children }));
|
|
6
|
+
}
|
|
7
|
+
return (_jsx(StyledTypography, { component: "div", className: className, children: children }));
|
|
8
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Description';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Description';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const StyledTypography: import("../../../styled").StyledComponent<import("../../../Typography/types").TypographyPropsBase & {
|
|
3
|
+
color?: import("../../../Typography").TypographyColor | undefined;
|
|
4
|
+
variant?: import("../../../Typography").TypographyVariant | undefined;
|
|
5
|
+
colorIntensity?: import("../../../Typography").Intensity | undefined;
|
|
6
|
+
component?: import("../../../Typography/types").ComponentProp | undefined;
|
|
7
|
+
isUpperCase?: boolean | undefined;
|
|
8
|
+
withoutCalt?: boolean | undefined;
|
|
9
|
+
} & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
|
|
10
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
11
|
+
}, {}, {}>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { styled } from '../../../styled';
|
|
2
|
+
import { Typography } from '../../../Typography';
|
|
3
|
+
export const StyledTypography = styled(Typography) `
|
|
4
|
+
min-height: 22px;
|
|
5
|
+
margin-bottom: ${({ theme }) => theme.microSpacing(1)};
|
|
6
|
+
margin-left: 9px;
|
|
7
|
+
padding-left: 13px;
|
|
8
|
+
|
|
9
|
+
text-align: start;
|
|
10
|
+
|
|
11
|
+
border-left: 2px solid ${({ theme }) => theme.palette.grey[300]};
|
|
12
|
+
|
|
13
|
+
${({ theme }) => theme.breakpoints.down('sm')} {
|
|
14
|
+
margin-bottom: 0;
|
|
15
|
+
margin-left: 11px;
|
|
16
|
+
padding-left: 15px;
|
|
17
|
+
}
|
|
18
|
+
`;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { Collapse } from '../../../Collapse';
|
|
3
|
+
import { Typography } from '../../../Typography';
|
|
4
|
+
import { Fade } from '../../../transitions/Fade';
|
|
5
|
+
import { stepClassnames } from '../constants';
|
|
6
|
+
import { DesktopLabel, MobileCompactLabel, MobileLabelGroup } from './styles';
|
|
7
|
+
export const Label = ({ label, stepId, isActiveStep }) => {
|
|
8
|
+
return (_jsxs(_Fragment, { children: [_jsx(DesktopLabel, { className: stepClassnames.label, children: label }), _jsxs(MobileLabelGroup, { className: stepClassnames.labelMobile, children: [_jsx(Collapse, { in: !isActiveStep, orientation: "horizontal", children: _jsx(Fade, { in: !isActiveStep, children: _jsx(MobileCompactLabel, { className: stepClassnames.label, children: stepId }) }) }), _jsx(Collapse, { in: isActiveStep, orientation: "horizontal", children: _jsx(Fade, { in: isActiveStep, children: _jsx(Typography, { className: stepClassnames.label, children: label }) }) })] })] }));
|
|
9
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Label } from './Label';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Label } from './Label';
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const MobileLabelGroup: import("../../../styled").StyledComponent<{
|
|
3
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
4
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
5
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
6
|
+
export declare const MobileCompactLabel: import("../../../styled").StyledComponent<import("../../../Typography/types").TypographyPropsBase & {
|
|
7
|
+
color?: import("../../../Typography").TypographyColor | undefined;
|
|
8
|
+
variant?: import("../../../Typography").TypographyVariant | undefined;
|
|
9
|
+
colorIntensity?: import("../../../Typography").Intensity | undefined;
|
|
10
|
+
component?: import("../../../Typography/types").ComponentProp | undefined;
|
|
11
|
+
isUpperCase?: boolean | undefined;
|
|
12
|
+
withoutCalt?: boolean | undefined;
|
|
13
|
+
} & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
|
|
14
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
15
|
+
}, {}, {}>;
|
|
16
|
+
export declare const DesktopLabel: import("../../../styled").StyledComponent<import("../../../Typography/types").TypographyPropsBase & {
|
|
17
|
+
color?: import("../../../Typography").TypographyColor | undefined;
|
|
18
|
+
variant?: import("../../../Typography").TypographyVariant | undefined;
|
|
19
|
+
colorIntensity?: import("../../../Typography").Intensity | undefined;
|
|
20
|
+
component?: import("../../../Typography/types").ComponentProp | undefined;
|
|
21
|
+
isUpperCase?: boolean | undefined;
|
|
22
|
+
withoutCalt?: boolean | undefined;
|
|
23
|
+
} & import("react").HTMLAttributes<HTMLParagraphElement> & import("react").RefAttributes<HTMLSpanElement> & {
|
|
24
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
25
|
+
}, {}, {}>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { styled } from '../../../styled';
|
|
2
|
+
import { Typography } from '../../../Typography';
|
|
3
|
+
export const MobileLabelGroup = styled.div `
|
|
4
|
+
display: none;
|
|
5
|
+
|
|
6
|
+
${({ theme }) => theme.breakpoints.down('sm')} {
|
|
7
|
+
display: flex;
|
|
8
|
+
align-items: center;
|
|
9
|
+
}
|
|
10
|
+
`;
|
|
11
|
+
export const MobileCompactLabel = styled(Typography) `
|
|
12
|
+
display: inline-block;
|
|
13
|
+
`;
|
|
14
|
+
export const DesktopLabel = styled(Typography) `
|
|
15
|
+
${({ theme }) => theme.breakpoints.down('sm')} {
|
|
16
|
+
display: none;
|
|
17
|
+
}
|
|
18
|
+
`;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './useLogic';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './useLogic';
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { useContext } from 'react';
|
|
2
|
+
import { StepperContext } from '../../../StepperContext';
|
|
3
|
+
export const useLogic = ({ stepId }) => {
|
|
4
|
+
const { activeStep } = useContext(StepperContext);
|
|
5
|
+
const isStepActive = activeStep === stepId;
|
|
6
|
+
return { isStepActive };
|
|
7
|
+
};
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { classNames } from '../../utils/classNames';
|
|
3
|
+
import { cva } from '../../utils/cva';
|
|
4
|
+
import { StepIcon } from '../StepIcon';
|
|
5
|
+
import { stepClassnames } from './constants';
|
|
6
|
+
import { Description } from './Description';
|
|
7
|
+
import { Label } from './Label';
|
|
8
|
+
import { ArrowConnector, IconWrapper, LabelWrapper, LineConnector, StepContentWrapper, StyledButton, Wrapper, } from './styles';
|
|
9
|
+
import { useLogic } from './useLogic';
|
|
10
|
+
const step = cva(stepClassnames.root, {
|
|
11
|
+
variants: {
|
|
12
|
+
isError: {
|
|
13
|
+
true: stepClassnames.error,
|
|
14
|
+
},
|
|
15
|
+
isCompleted: {
|
|
16
|
+
true: stepClassnames.completed,
|
|
17
|
+
},
|
|
18
|
+
connector: {
|
|
19
|
+
arrow: stepClassnames.connectorArrow,
|
|
20
|
+
line: stepClassnames.connectorLine,
|
|
21
|
+
},
|
|
22
|
+
activeStep: {
|
|
23
|
+
true: stepClassnames.active,
|
|
24
|
+
},
|
|
25
|
+
alternativeLabel: {
|
|
26
|
+
true: stepClassnames.alternativeLabel,
|
|
27
|
+
},
|
|
28
|
+
orientation: {
|
|
29
|
+
horizontal: stepClassnames.orientationHorizontal,
|
|
30
|
+
vertical: stepClassnames.orientationVertical,
|
|
31
|
+
},
|
|
32
|
+
isDisabled: {
|
|
33
|
+
true: stepClassnames.disabled,
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
});
|
|
37
|
+
const connector = cva(stepClassnames.connector, {
|
|
38
|
+
variants: {
|
|
39
|
+
connector: {
|
|
40
|
+
arrow: stepClassnames.connectorArrow,
|
|
41
|
+
line: stepClassnames.connectorLine,
|
|
42
|
+
},
|
|
43
|
+
alternativeLabel: {
|
|
44
|
+
true: stepClassnames.alternativeLabel,
|
|
45
|
+
},
|
|
46
|
+
orientation: {
|
|
47
|
+
horizontal: stepClassnames.orientationHorizontal,
|
|
48
|
+
vertical: stepClassnames.orientationVertical,
|
|
49
|
+
},
|
|
50
|
+
hasDescription: {
|
|
51
|
+
true: stepClassnames.hasDescription,
|
|
52
|
+
},
|
|
53
|
+
},
|
|
54
|
+
});
|
|
55
|
+
export const Step = (props) => {
|
|
56
|
+
const { isCompletedStep, isRenderButton, handleClick, connectorVariant, alternativeLabel, orientation, stepId, children, isError, isWarning, icon, className, label, isRenderVerticalLineConnector, isRenderHorizontalLineConnector, isDisabled, isActiveStep, } = useLogic(props);
|
|
57
|
+
const StepContent = isRenderButton ? StyledButton : StepContentWrapper;
|
|
58
|
+
return (_jsxs(Wrapper, { "data-active-step": isActiveStep, className: classNames(step({
|
|
59
|
+
isError,
|
|
60
|
+
isCompleted: isCompletedStep,
|
|
61
|
+
connector: connectorVariant,
|
|
62
|
+
activeStep: isActiveStep,
|
|
63
|
+
alternativeLabel,
|
|
64
|
+
orientation,
|
|
65
|
+
isDisabled,
|
|
66
|
+
}), className), children: [_jsxs(StepContent, { variant: "text", onClick: handleClick, disabled: isDisabled, className: classNames(stepClassnames.content, {
|
|
67
|
+
[stepClassnames.active]: isActiveStep,
|
|
68
|
+
}), children: [_jsxs(LabelWrapper, { className: stepClassnames.labelContainer, children: [_jsx(IconWrapper, { className: stepClassnames.iconContainer, children: _jsx(StepIcon, { icon: icon, isActive: isActiveStep, isCompleted: isCompletedStep, isError: isError, isWarning: isWarning }) }), _jsx(Label, { label: label, stepId: stepId, isActiveStep: isActiveStep }), connectorVariant === 'arrow' && (_jsx(ArrowConnector, { className: connector({
|
|
69
|
+
connector: connectorVariant,
|
|
70
|
+
alternativeLabel,
|
|
71
|
+
orientation,
|
|
72
|
+
}) }))] }), children && (_jsx(Description, { className: stepClassnames.description, children: children })), isRenderVerticalLineConnector && (_jsx(LineConnector, { className: connector({
|
|
73
|
+
connector: connectorVariant,
|
|
74
|
+
orientation,
|
|
75
|
+
}) }))] }), isRenderHorizontalLineConnector && (_jsx(LineConnector, { className: connector({
|
|
76
|
+
connector: connectorVariant,
|
|
77
|
+
alternativeLabel,
|
|
78
|
+
orientation,
|
|
79
|
+
}) }))] }));
|
|
80
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export declare const stepStateClassnames: {
|
|
2
|
+
active: string;
|
|
3
|
+
completed: string;
|
|
4
|
+
error: string;
|
|
5
|
+
warning: string;
|
|
6
|
+
disabled: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const stepClassnames: {
|
|
9
|
+
active: string;
|
|
10
|
+
completed: string;
|
|
11
|
+
error: string;
|
|
12
|
+
warning: string;
|
|
13
|
+
disabled: string;
|
|
14
|
+
root: string;
|
|
15
|
+
label: string;
|
|
16
|
+
description: string;
|
|
17
|
+
iconContainer: string;
|
|
18
|
+
connector: string;
|
|
19
|
+
connectorLine: string;
|
|
20
|
+
connectorArrow: string;
|
|
21
|
+
alternativeLabel: string;
|
|
22
|
+
orientationHorizontal: string;
|
|
23
|
+
orientationVertical: string;
|
|
24
|
+
labelContainer: string;
|
|
25
|
+
labelMobile: string;
|
|
26
|
+
content: string;
|
|
27
|
+
hasDescription: string;
|
|
28
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { createUIKitClassname } from '../../utils/createUIKitClassname';
|
|
2
|
+
export const stepStateClassnames = {
|
|
3
|
+
active: createUIKitClassname('step_active'),
|
|
4
|
+
completed: createUIKitClassname('step_completed'),
|
|
5
|
+
error: createUIKitClassname('step_error'),
|
|
6
|
+
warning: createUIKitClassname('step_warning'),
|
|
7
|
+
disabled: createUIKitClassname('step_disabled'),
|
|
8
|
+
};
|
|
9
|
+
export const stepClassnames = {
|
|
10
|
+
root: createUIKitClassname('step'),
|
|
11
|
+
label: createUIKitClassname('step__label'),
|
|
12
|
+
description: createUIKitClassname('step__description'),
|
|
13
|
+
iconContainer: createUIKitClassname('step__icon-container'),
|
|
14
|
+
connector: createUIKitClassname('step__connector'),
|
|
15
|
+
connectorLine: createUIKitClassname('step_connector-line'),
|
|
16
|
+
connectorArrow: createUIKitClassname('step_connector-arrow'),
|
|
17
|
+
alternativeLabel: createUIKitClassname('step_alternative-label'),
|
|
18
|
+
orientationHorizontal: createUIKitClassname('step_orientation-horizontal'),
|
|
19
|
+
orientationVertical: createUIKitClassname('step_orientation-vertical'),
|
|
20
|
+
labelContainer: createUIKitClassname('step__label-container'),
|
|
21
|
+
labelMobile: createUIKitClassname('step__label-mobile'),
|
|
22
|
+
content: createUIKitClassname('step__content'),
|
|
23
|
+
hasDescription: createUIKitClassname('step_has-description'),
|
|
24
|
+
...stepStateClassnames,
|
|
25
|
+
};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export declare const Wrapper: import("../../styled").StyledComponent<{
|
|
3
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
4
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
5
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
6
|
+
export declare const IconWrapper: import("../../styled").StyledComponent<{
|
|
7
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
8
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
9
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
10
|
+
export declare const ArrowConnector: import("../../styled").StyledComponent<{
|
|
11
|
+
children?: import("react").ReactNode;
|
|
12
|
+
color?: string | undefined;
|
|
13
|
+
titleAccess?: string | undefined;
|
|
14
|
+
size?: "sm" | "md" | undefined;
|
|
15
|
+
} & import("react").SVGProps<SVGSVGElement> & {
|
|
16
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
17
|
+
}, {}, {}>;
|
|
18
|
+
export declare const LineConnector: import("../../styled").StyledComponent<{
|
|
19
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
20
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
21
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
22
|
+
export declare const LabelWrapper: import("../../styled").StyledComponent<{
|
|
23
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
24
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
25
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
26
|
+
export declare const StepContentWrapper: import("../../styled").StyledComponent<{
|
|
27
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
28
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
29
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
30
|
+
export declare const StyledButton: import("../../styled").StyledComponent<Omit<import("../..").WithoutEmotionSpecific<import("@mui/material").ButtonProps>, "color" | "component" | "variant" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple"> & {
|
|
31
|
+
variant?: "light" | "link" | "text" | "contained" | "outlined" | undefined;
|
|
32
|
+
loading?: boolean | undefined;
|
|
33
|
+
color?: "primary" | "success" | "warning" | "error" | "grey" | undefined;
|
|
34
|
+
component?: import("react").ElementType | undefined;
|
|
35
|
+
selected?: boolean | undefined;
|
|
36
|
+
} & Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, ""> & import("react").RefAttributes<HTMLButtonElement> & {
|
|
37
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
38
|
+
}, {}, {}>;
|