@m4l/components 9.65.2-beta-m4lcom-783-rediseno-de-steps-del-componente-stepper.0 → 9.65.2-beta-update-switch-component-variable.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/DevicesPicker/slots/DevicesPickerSlots.d.ts +1 -1
- package/components/Stepper/Stepper.styles.d.ts.map +1 -1
- package/components/Stepper/Stepper.styles.js +113 -176
- package/components/Stepper/subcomponents/StepArea/index.d.ts.map +1 -1
- package/components/Stepper/subcomponents/StepArea/index.js +37 -39
- package/components/Stepper/subcomponents/StepArea/subcomponents/Inidicator/index.d.ts.map +1 -1
- package/components/Stepper/subcomponents/StepArea/subcomponents/Inidicator/index.js +48 -64
- package/components/extended/mui/Switch/Switch.d.ts +1 -1
- package/components/extended/mui/Switch/Switch.d.ts.map +1 -1
- package/components/extended/mui/Switch/Switch.js +144 -61
- package/components/extended/mui/Switch/Switch.styles.d.ts.map +1 -1
- package/components/extended/mui/Switch/Switch.styles.js +124 -52
- package/components/extended/mui/Switch/constants.d.ts +1 -1
- package/components/extended/mui/Switch/constants.d.ts.map +1 -1
- package/components/extended/mui/Switch/slots/SwitchEnum.d.ts +5 -0
- package/components/extended/mui/Switch/slots/SwitchEnum.d.ts.map +1 -1
- package/components/extended/mui/Switch/slots/SwitchEnum.js +2 -2
- package/components/extended/mui/Switch/slots/SwitchSlots.d.ts +15 -0
- package/components/extended/mui/Switch/slots/SwitchSlots.d.ts.map +1 -1
- package/components/extended/mui/Switch/slots/SwitchSlots.js +32 -11
- package/components/extended/mui/Switch/types.d.ts +33 -0
- package/components/extended/mui/Switch/types.d.ts.map +1 -1
- package/package.json +5 -5
|
@@ -58,7 +58,7 @@ export declare const PanelStyled: import('@emotion/styled').StyledComponent<impo
|
|
|
58
58
|
export declare const PanelHeaderStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
59
59
|
ownerState?: (Partial<import('..').DevicesPickerOwnerState> & Record<string, unknown>) | undefined;
|
|
60
60
|
}, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').ClassAttributes<HTMLDivElement> | keyof import('react').HTMLAttributes<HTMLDivElement>>, {}>;
|
|
61
|
-
export declare const PanelSwitchStyled: import('@emotion/styled').StyledComponent<Pick<Omit<import('../../extended/mui/Switch/types').SwitchProps, "ref"> & import('react').RefAttributes<HTMLButtonElement>, "color" | "content" | "translate" | "error" | "action" | "classes" | "className" | "sx" | "form" | "label" | "slot" | "style" | "title" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "hidden" | "id" | "lang" | "nonce" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "popover" | "popoverTargetAction" | "popoverTarget" | "inert" | "inputMode" | "is" | "exportparts" | "part" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-braillelabel" | "aria-brailleroledescription" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colindextext" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-description" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowindextext" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerLeave" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onScrollEnd" | "onScrollEndCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onToggle" | "onBeforeToggle" | "onTransitionCancel" | "onTransitionCancelCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "onTransitionRun" | "onTransitionRunCapture" | "onTransitionStart" | "onTransitionStartCapture" | "component" | "name" | "size" | "type" | "value" | "icon" | "disabled" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "edge" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "checked" | keyof import('react').RefAttributes<HTMLButtonElement> | "readOnly" | "required" | "inputProps" | "inputRef" | "checkedIcon" | "labelPlacement"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
61
|
+
export declare const PanelSwitchStyled: import('@emotion/styled').StyledComponent<Pick<Omit<import('../../extended/mui/Switch/types').SwitchProps, "ref"> & import('react').RefAttributes<HTMLButtonElement>, "color" | "content" | "translate" | "error" | "action" | "classes" | "className" | "sx" | "form" | "label" | "slot" | "style" | "title" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "hidden" | "id" | "lang" | "nonce" | "spellCheck" | "tabIndex" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "rel" | "resource" | "rev" | "typeof" | "vocab" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "popover" | "popoverTargetAction" | "popoverTarget" | "inert" | "inputMode" | "is" | "exportparts" | "part" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-braillelabel" | "aria-brailleroledescription" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colindextext" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-description" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowindextext" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerLeave" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onScrollEnd" | "onScrollEndCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onToggle" | "onBeforeToggle" | "onTransitionCancel" | "onTransitionCancelCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "onTransitionRun" | "onTransitionRunCapture" | "onTransitionStart" | "onTransitionStartCapture" | "component" | "name" | "size" | "type" | "variant" | "value" | "icon" | "disabled" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "edge" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "checked" | keyof import('react').RefAttributes<HTMLButtonElement> | "readOnly" | "showIcon" | "required" | "inputProps" | "inputRef" | "checkedIcon" | "labelPlacement" | "showStartText" | "startText" | "showDescription" | "descriptionText" | "showEndText" | "endText"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
62
62
|
ownerState?: (Partial<import('..').DevicesPickerOwnerState> & Record<string, unknown>) | undefined;
|
|
63
63
|
}, {}, {}>;
|
|
64
64
|
export declare const PanelListStyled: import('@emotion/styled').StyledComponent<Pick<import('../..').CheckableListProps, keyof import('../..').CheckableListProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Stepper.styles.d.ts","sourceRoot":"","sources":["../../../../../../packages/components/src/components/Stepper/Stepper.styles.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAGxC,eAAO,MAAM,aAAa,EAAE,
|
|
1
|
+
{"version":3,"file":"Stepper.styles.d.ts","sourceRoot":"","sources":["../../../../../../packages/components/src/components/Stepper/Stepper.styles.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAGxC,eAAO,MAAM,aAAa,EAAE,aAmb3B,CAAC"}
|
|
@@ -1,62 +1,52 @@
|
|
|
1
|
-
import { getSizeStyles as
|
|
2
|
-
const
|
|
1
|
+
import { getSizeStyles as o } from "../../utils/getSizeStyles/getSizeStyles.js";
|
|
2
|
+
const c = {
|
|
3
3
|
/**
|
|
4
4
|
*
|
|
5
5
|
* Estilos para el contenedor principal del Stepper.
|
|
6
6
|
*/
|
|
7
|
-
stepperRoot: ({ theme:
|
|
7
|
+
stepperRoot: ({ theme: i }) => ({
|
|
8
8
|
display: "flex",
|
|
9
9
|
flexDirection: "column",
|
|
10
10
|
justifyContent: "flex-start",
|
|
11
|
-
background:
|
|
11
|
+
background: i.vars.palette.background.default,
|
|
12
12
|
width: "100%",
|
|
13
13
|
height: "100%",
|
|
14
|
-
borderRadius:
|
|
14
|
+
borderRadius: i.vars.size.borderRadius.r1
|
|
15
15
|
}),
|
|
16
16
|
/**
|
|
17
17
|
* Estilos para la sección que contiene los pasos del Stepper.
|
|
18
18
|
*/
|
|
19
|
-
contentSection: ({ theme:
|
|
19
|
+
contentSection: ({ theme: i, ownerState: e }) => ({
|
|
20
20
|
display: "flex",
|
|
21
21
|
flex: 1,
|
|
22
22
|
height: "100%",
|
|
23
23
|
overflow: "hidden",
|
|
24
|
-
|
|
25
|
-
|
|
24
|
+
gap: i.vars.size.baseSpacings.sp6,
|
|
25
|
+
...e?.orientation === "vertical" || i.generalSettings.isMobile ? {
|
|
26
26
|
flexDirection: "column"
|
|
27
27
|
} : {
|
|
28
|
-
gap: e.vars.size.baseSpacings.sp5,
|
|
29
28
|
flexDirection: "row"
|
|
30
29
|
}
|
|
31
30
|
}),
|
|
32
31
|
/**
|
|
33
32
|
* Estilos para el contenido del paso dentro del Stepper.
|
|
34
33
|
*/
|
|
35
|
-
stepContent: ({ ownerState:
|
|
34
|
+
stepContent: ({ ownerState: i }) => ({
|
|
36
35
|
height: "100%",
|
|
37
|
-
display:
|
|
36
|
+
display: i?.isStepVisible ? "flex" : "none",
|
|
38
37
|
flexDirection: "column"
|
|
39
38
|
}),
|
|
40
39
|
/**
|
|
41
40
|
* Estilos para la sección que contiene los botones de acción del Stepper.
|
|
42
41
|
*/
|
|
43
|
-
stepArea: ({ theme:
|
|
44
|
-
...
|
|
42
|
+
stepArea: ({ theme: i, ownerState: e }) => ({
|
|
43
|
+
...e?.orientation === "vertical" || i.generalSettings.isMobile ? {
|
|
45
44
|
display: "flex",
|
|
46
45
|
alignItems: "start",
|
|
47
46
|
width: "100%",
|
|
48
47
|
overflowX: "auto",
|
|
49
48
|
overflowY: "hidden"
|
|
50
49
|
} : {
|
|
51
|
-
display: "flex",
|
|
52
|
-
flexDirection: "column",
|
|
53
|
-
gap: e.vars.size.baseSpacings["sp0-5"],
|
|
54
|
-
padding: e.vars.size.baseSpacings.sp3,
|
|
55
|
-
boxSizing: "border-box",
|
|
56
|
-
borderRadius: e.vars.size.borderRadius.r2,
|
|
57
|
-
background: e.vars.palette.background.base,
|
|
58
|
-
alignSelf: "flex-start",
|
|
59
|
-
maxHeight: "100%",
|
|
60
50
|
maxWidth: "116px",
|
|
61
51
|
overflowY: "auto"
|
|
62
52
|
}
|
|
@@ -64,79 +54,48 @@ const S = {
|
|
|
64
54
|
/**
|
|
65
55
|
* Estilos para el área de contenido del Stepper.
|
|
66
56
|
*/
|
|
67
|
-
contentArea: ({ theme:
|
|
57
|
+
contentArea: ({ theme: i, ownerState: e }) => ({
|
|
68
58
|
flex: 1,
|
|
69
59
|
display: "flex",
|
|
70
60
|
flexDirection: "column",
|
|
71
61
|
overflowY: "auto",
|
|
72
|
-
...
|
|
62
|
+
...e?.orientation === "vertical" || i.generalSettings.isMobile ? {
|
|
73
63
|
// borderTop: '1px solid',
|
|
74
|
-
gap:
|
|
64
|
+
gap: i.vars.size.baseSpacings.sp4
|
|
75
65
|
// paddingTop: theme.vars.size.baseSpacings.sp8,
|
|
76
66
|
} : {
|
|
77
|
-
gap:
|
|
78
|
-
|
|
67
|
+
gap: i.vars.size.baseSpacings.sp6,
|
|
68
|
+
borderLeft: "1px solid",
|
|
69
|
+
paddingLeft: i.vars.size.baseSpacings.sp8
|
|
70
|
+
},
|
|
71
|
+
borderColor: i.vars.palette?.border.disabled
|
|
79
72
|
}),
|
|
80
73
|
/**
|
|
81
74
|
* Estilos para cada paso del Stepper.
|
|
82
75
|
*/
|
|
83
|
-
step: ({ theme:
|
|
84
|
-
const
|
|
76
|
+
step: ({ theme: i, ownerState: e }) => {
|
|
77
|
+
const t = e?.currentStep ?? 0, r = e?.step ?? 0, s = e?.totalSteps ?? 0, a = t > r, n = r === s - 1;
|
|
85
78
|
return {
|
|
86
79
|
cursor: "pointer",
|
|
87
|
-
display:
|
|
88
|
-
flexDirection:
|
|
89
|
-
alignItems: "center",
|
|
90
|
-
justifyContent:
|
|
91
|
-
gap:
|
|
80
|
+
display: e?.isStepVisible ? "flex" : "none",
|
|
81
|
+
flexDirection: e?.orientation === "vertical" || i.generalSettings.isMobile ? "column" : "row",
|
|
82
|
+
alignItems: e?.orientation === "vertical" || i.generalSettings.isMobile ? "center" : "start",
|
|
83
|
+
justifyContent: e?.visibleTitle ? "space-between" : "center",
|
|
84
|
+
gap: e?.orientation === "vertical" || i.generalSettings.isMobile ? i.vars.size.baseSpacings.sp1 : i.vars.size.baseSpacings.sp4,
|
|
92
85
|
width: "100%",
|
|
93
|
-
...(
|
|
94
|
-
minWidth:
|
|
95
|
-
},
|
|
96
|
-
height: "auto",
|
|
97
|
-
...n && {
|
|
98
|
-
paddingBlock: e.vars.size.baseSpacings["sp0-5"]
|
|
99
|
-
},
|
|
100
|
-
...!(i?.orientation === "vertical" || e.generalSettings.isMobile) && {
|
|
101
|
-
paddingBottom: `calc(${e.vars.size.baseSpacings["sp0-5"]} + ${e.vars.size.baseSpacings.sp3})`
|
|
86
|
+
...(e?.orientation === "vertical" || i.generalSettings.isMobile) && {
|
|
87
|
+
minWidth: i.vars.size.baseSpacings.sp10
|
|
102
88
|
},
|
|
89
|
+
height: e?.orientation === "vertical" || i.generalSettings.isMobile ? "auto" : i.vars.size.baseSpacings.sp13,
|
|
103
90
|
position: "relative",
|
|
104
|
-
|
|
105
|
-
...t > 0 && {
|
|
106
|
-
"&::before": {
|
|
107
|
-
content: '""',
|
|
108
|
-
position: "absolute",
|
|
109
|
-
top: p,
|
|
110
|
-
left: 0,
|
|
111
|
-
right: `calc(50% + ${l})`,
|
|
112
|
-
// Width from the stroke token; only the style and the color change.
|
|
113
|
-
borderTop: e.vars.size.borderStroke.container,
|
|
114
|
-
borderTopStyle: s >= d ? "solid" : "dashed",
|
|
115
|
-
borderTopColor: s >= d ? e.vars.palette.primary.enabled : e.vars.palette.border.secondary
|
|
116
|
-
}
|
|
117
|
-
},
|
|
118
|
-
...!o && {
|
|
119
|
-
"&::after": {
|
|
120
|
-
content: '""',
|
|
121
|
-
position: "absolute",
|
|
122
|
-
top: p,
|
|
123
|
-
right: 0,
|
|
124
|
-
left: `calc(50% + ${l})`,
|
|
125
|
-
// Right half: solid once the current step is past this one.
|
|
126
|
-
borderTop: e.vars.size.borderStroke.container,
|
|
127
|
-
borderTopStyle: s > d ? "solid" : "dashed",
|
|
128
|
-
borderTopColor: s > d ? e.vars.palette.primary.enabled : e.vars.palette.border.secondary
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
},
|
|
132
|
-
...!o && e.generalSettings.isMobile && {
|
|
91
|
+
...!n && (e?.orientation === "vertical" || i.generalSettings.isMobile) && {
|
|
133
92
|
"&::after": {
|
|
134
93
|
content: '""',
|
|
135
94
|
position: "absolute",
|
|
136
|
-
top:
|
|
95
|
+
top: e?.orientation === "horizontal" && i.generalSettings.isMobile ? "16px" : "10px",
|
|
137
96
|
// Ajustado para coincidir con el centro del indicador cuando alignItems es start
|
|
138
97
|
height: "1px",
|
|
139
|
-
borderTop: `1px ${
|
|
98
|
+
borderTop: `1px ${a ? "solid" : "dashed"} ${a ? i.vars.palette.primary.enabled : i.vars.palette.border.default}`,
|
|
140
99
|
left: "50%",
|
|
141
100
|
width: "100%"
|
|
142
101
|
}
|
|
@@ -146,44 +105,36 @@ const S = {
|
|
|
146
105
|
/**
|
|
147
106
|
* Estilos para el nombre del paso dentro del Stepper.
|
|
148
107
|
*/
|
|
149
|
-
stepName: ({ theme:
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
minWidth: 0,
|
|
176
|
-
order: 1,
|
|
177
|
-
"&.M4LTypography-root": {
|
|
178
|
-
color: r || o ? e.vars.palette.text.primary : e.vars.palette.text.secondary,
|
|
179
|
-
textAlign: i?.orientation === "vertical" || e.generalSettings.isMobile ? "center" : "left"
|
|
180
|
-
}
|
|
181
|
-
};
|
|
182
|
-
},
|
|
108
|
+
stepName: ({ theme: i, ownerState: e }) => ({
|
|
109
|
+
...e?.orientation === "horizontal" && !i.generalSettings.isMobile && {
|
|
110
|
+
minHeight: i.vars.size.desktop.medium.action,
|
|
111
|
+
maxWidth: "120px",
|
|
112
|
+
width: "100%"
|
|
113
|
+
},
|
|
114
|
+
...(e?.orientation === "vertical" || i.generalSettings.isMobile) && {
|
|
115
|
+
maxWidth: "120px",
|
|
116
|
+
width: "100%",
|
|
117
|
+
marginTop: i.vars.size.baseSpacings.sp1
|
|
118
|
+
},
|
|
119
|
+
alignContent: "center",
|
|
120
|
+
cursor: "pointer",
|
|
121
|
+
...i.generalSettings.isMobile ? {
|
|
122
|
+
display: "none"
|
|
123
|
+
} : {
|
|
124
|
+
display: e?.visibleTitle ? "block" : "none"
|
|
125
|
+
},
|
|
126
|
+
flex: 1,
|
|
127
|
+
minWidth: 0,
|
|
128
|
+
order: e?.orientation === "vertical" || i.generalSettings.isMobile ? 1 : 0,
|
|
129
|
+
"&.M4LTypography-root": {
|
|
130
|
+
color: e?.originalStepIndex !== void 0 && typeof e.originalStepIndex == "number" ? (e.currentStep ?? 0) > e.originalStepIndex ? i.vars.palette.primary.semanticText : (e.currentStep ?? 0) === e.originalStepIndex ? i.vars.palette.text.primary : i.vars.palette.text.secondary : i.vars.palette.text.secondary,
|
|
131
|
+
textAlign: e?.orientation === "vertical" || i.generalSettings.isMobile ? "center" : "right"
|
|
132
|
+
}
|
|
133
|
+
}),
|
|
183
134
|
/**
|
|
184
135
|
* Styles for the step name text with line clamp truncation.
|
|
185
136
|
*/
|
|
186
|
-
stepNameText: ({ theme:
|
|
137
|
+
stepNameText: ({ theme: i, ownerState: e }) => ({
|
|
187
138
|
display: "-webkit-box",
|
|
188
139
|
WebkitBoxOrient: "vertical",
|
|
189
140
|
WebkitLineClamp: 2,
|
|
@@ -194,118 +145,104 @@ const S = {
|
|
|
194
145
|
width: "100%",
|
|
195
146
|
direction: "ltr",
|
|
196
147
|
lineHeight: 1.2,
|
|
197
|
-
textAlign:
|
|
148
|
+
textAlign: e?.orientation === "vertical" || i.generalSettings.isMobile ? "center" : "left"
|
|
198
149
|
}),
|
|
199
150
|
/**
|
|
200
151
|
* Estilos para el indicador numérico de cada paso del Stepper.
|
|
201
152
|
*/
|
|
202
|
-
indicator: ({ theme:
|
|
203
|
-
const
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
marginTop: e.generalSettings.isMobile ? "6px" : e.vars.size.baseSpacings.sp1
|
|
153
|
+
indicator: ({ theme: i, ownerState: e }) => {
|
|
154
|
+
const t = e?.step ?? 0, r = e?.totalSteps ?? 0, s = e?.isCompleted ?? !1, a = e?.isCurrent ?? !1, n = e?.isValidStep ?? !0, p = t === r - 1;
|
|
155
|
+
return {
|
|
156
|
+
...e?.orientation === "horizontal" ? {
|
|
157
|
+
marginTop: i.generalSettings.isMobile ? "6px" : i.vars.size.baseSpacings.sp1
|
|
208
158
|
} : {},
|
|
209
159
|
display: "flex",
|
|
210
160
|
alignItems: "center",
|
|
211
161
|
justifyContent: "center",
|
|
212
162
|
flexShrink: 0,
|
|
213
163
|
zIndex: 1,
|
|
214
|
-
order: 0,
|
|
215
|
-
background:
|
|
216
|
-
borderRadius:
|
|
217
|
-
...
|
|
218
|
-
|
|
219
|
-
border: e.vars.size.borderStroke.container,
|
|
220
|
-
// Figma's default opacity (0.08) equals the theme's default.hoverOpacity;
|
|
221
|
-
// default.opacity is 0.12.
|
|
222
|
-
borderColor: g || r ? e.vars.palette.primary.selectedOpacity : e.vars.palette.default.hoverOpacity
|
|
223
|
-
},
|
|
224
|
-
...p && {
|
|
225
|
-
// Figma's 0.16 opacity maps to selectedOpacity because hoverOpacity is 0.12.
|
|
226
|
-
boxShadow: b && r ? `0 2px 8px 0 ${e.vars.palette.primary.selectedOpacity}` : "none"
|
|
164
|
+
order: e?.orientation === "vertical" || i.generalSettings.isMobile ? 0 : 1,
|
|
165
|
+
background: !n && e?.hasBeenValidated ? i.vars.palette.error.enabled : s && n ? e?.indicatorType === "dot" || i.generalSettings.isMobile ? i.vars.palette.background.default : i.vars.palette.primary.toneOpacity : a ? e?.indicatorType === "dot" || i.generalSettings.isMobile ? i.vars.palette.background.default : i.vars.palette.primary.enabled : e?.indicatorType === "dot" || i.generalSettings.isMobile ? i.vars.palette.background.default : i.vars.palette.default.enabled,
|
|
166
|
+
borderRadius: i.vars.size.borderRadius.r2,
|
|
167
|
+
...e?.indicatorType === "number" && !i.generalSettings.isMobile && {
|
|
168
|
+
boxShadow: a ? "0 2px 8px 0 rgb(0, 100, 255, 0.16)" : "none"
|
|
227
169
|
},
|
|
228
170
|
position: "relative",
|
|
229
|
-
...!
|
|
171
|
+
...!p && e?.orientation === "horizontal" && !i.generalSettings.isMobile && {
|
|
230
172
|
"&::after": {
|
|
231
173
|
content: '""',
|
|
232
174
|
position: "absolute",
|
|
233
|
-
top:
|
|
175
|
+
top: "100%",
|
|
234
176
|
left: "50%",
|
|
235
177
|
transform: "translateX(-50%)",
|
|
236
178
|
width: "1px",
|
|
237
|
-
height:
|
|
238
|
-
borderLeft: `1px ${
|
|
179
|
+
height: i.vars.size.baseSpacings.sp12,
|
|
180
|
+
borderLeft: `1px ${s ? "solid" : "dashed"} ${s ? i.vars.palette.primary.enabled : i.vars.palette.border.default}`
|
|
239
181
|
}
|
|
240
182
|
},
|
|
241
|
-
...
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
(x) => ({
|
|
246
|
-
width: x,
|
|
247
|
-
height: x
|
|
248
|
-
})
|
|
249
|
-
)
|
|
183
|
+
...o(i, e?.size || "medium", "case", (l) => ({
|
|
184
|
+
width: l,
|
|
185
|
+
height: l
|
|
186
|
+
}))
|
|
250
187
|
};
|
|
251
188
|
},
|
|
252
189
|
/**
|
|
253
190
|
* Estilos para el número de texto dentro del indicador numérico del Stepper.
|
|
254
191
|
*/
|
|
255
|
-
textNumber: ({ theme:
|
|
256
|
-
const
|
|
192
|
+
textNumber: ({ theme: i, ownerState: e }) => {
|
|
193
|
+
const t = e?.isCompleted ?? !1, r = e?.isCurrent ?? !1, s = e?.isValidStep ?? !0, a = e?.hasBeenValidated ?? !1;
|
|
257
194
|
return {
|
|
258
195
|
"&.M4LTypography-root": {
|
|
259
|
-
color: !
|
|
196
|
+
color: !s && a ? i.vars.palette.error.contrastText : t || r ? i.vars.palette.primary.contrastText : i.vars.palette.text.primary
|
|
260
197
|
}
|
|
261
198
|
};
|
|
262
199
|
},
|
|
263
200
|
/**
|
|
264
201
|
* Estilos para el área de contenido del Stepper.
|
|
265
202
|
*/
|
|
266
|
-
contentAreaHeader: ({ theme:
|
|
203
|
+
contentAreaHeader: ({ theme: i }) => ({
|
|
267
204
|
display: "flex",
|
|
268
205
|
alignItems: "center",
|
|
269
|
-
gap:
|
|
206
|
+
gap: i.size.baseSpacings.sp3,
|
|
270
207
|
position: "sticky",
|
|
271
208
|
top: 0,
|
|
272
|
-
backgroundColor:
|
|
209
|
+
backgroundColor: i.vars.palette.background.default,
|
|
273
210
|
zIndex: 10
|
|
274
211
|
// paddingBottom: theme.vars.size.baseSpacings.sp2,
|
|
275
212
|
}),
|
|
276
213
|
/**
|
|
277
214
|
* Estilos para el cuerpo del área de contenido del Stepper
|
|
278
215
|
*/
|
|
279
|
-
contentAreaBody: ({ theme:
|
|
216
|
+
contentAreaBody: ({ theme: i }) => ({
|
|
280
217
|
flex: 1,
|
|
281
218
|
overflowY: "auto",
|
|
282
219
|
display: "flex",
|
|
283
220
|
flexDirection: "column",
|
|
284
|
-
gap:
|
|
221
|
+
gap: i.vars.size.baseSpacings.sp6
|
|
285
222
|
}),
|
|
286
223
|
/**
|
|
287
224
|
* Estilos para el contenedor del icono del titulo del Stepper.
|
|
288
225
|
*/
|
|
289
|
-
wrapperIcon: ({ theme:
|
|
226
|
+
wrapperIcon: ({ theme: i, ownerState: e }) => ({
|
|
290
227
|
display: "flex",
|
|
291
228
|
alignItems: "center",
|
|
292
229
|
justifyContent: "center",
|
|
293
230
|
flexShrink: 0,
|
|
294
|
-
background:
|
|
295
|
-
borderRadius:
|
|
296
|
-
...
|
|
297
|
-
width:
|
|
298
|
-
height:
|
|
231
|
+
background: i.vars.palette.primary.enabledOpacity,
|
|
232
|
+
borderRadius: i.vars.size.borderRadius["r1-5"],
|
|
233
|
+
...o(i, e?.size || "medium", "box", (t) => ({
|
|
234
|
+
width: t,
|
|
235
|
+
height: t
|
|
299
236
|
}))
|
|
300
237
|
}),
|
|
301
238
|
/**
|
|
302
239
|
* Estilos para el título del Stepper.
|
|
303
240
|
*/
|
|
304
|
-
wrapperTitle: ({ theme:
|
|
305
|
-
color:
|
|
241
|
+
wrapperTitle: ({ theme: i }) => ({
|
|
242
|
+
color: i.vars.palette.text.primary,
|
|
306
243
|
display: "flex",
|
|
307
244
|
flexDirection: "column",
|
|
308
|
-
gap:
|
|
245
|
+
gap: i.vars.size.baseSpacings["sp0-5"],
|
|
309
246
|
flex: 1,
|
|
310
247
|
minWidth: 0,
|
|
311
248
|
overflow: "hidden"
|
|
@@ -313,10 +250,10 @@ const S = {
|
|
|
313
250
|
/**
|
|
314
251
|
* Estilos para el icono del Stepper.
|
|
315
252
|
*/
|
|
316
|
-
icon: ({ theme:
|
|
317
|
-
...
|
|
318
|
-
width:
|
|
319
|
-
height:
|
|
253
|
+
icon: ({ theme: i, ownerState: e }) => ({
|
|
254
|
+
...o(i, e?.size || "medium", "case", (t) => ({
|
|
255
|
+
width: t,
|
|
256
|
+
height: t
|
|
320
257
|
}))
|
|
321
258
|
}),
|
|
322
259
|
/**
|
|
@@ -345,13 +282,13 @@ const S = {
|
|
|
345
282
|
/**
|
|
346
283
|
* Estilos para la descripción del Stepper.
|
|
347
284
|
*/
|
|
348
|
-
description: ({ theme:
|
|
285
|
+
description: ({ theme: i }) => ({
|
|
349
286
|
minWidth: 0,
|
|
350
287
|
overflow: "hidden",
|
|
351
288
|
width: "100%",
|
|
352
289
|
maxWidth: "100%",
|
|
353
290
|
"&.M4LTypography-root": {
|
|
354
|
-
color:
|
|
291
|
+
color: i.vars.palette.text.secondary,
|
|
355
292
|
overflow: "hidden",
|
|
356
293
|
minWidth: 0,
|
|
357
294
|
textOverflow: "ellipsis",
|
|
@@ -361,43 +298,43 @@ const S = {
|
|
|
361
298
|
/**
|
|
362
299
|
* Estilos para la sección de botones de acción del Stepper.
|
|
363
300
|
*/
|
|
364
|
-
stepperFooterSection: ({ theme:
|
|
301
|
+
stepperFooterSection: ({ theme: i }) => ({
|
|
365
302
|
display: "flex",
|
|
366
303
|
alignItems: "center",
|
|
367
304
|
justifyContent: "space-between",
|
|
368
305
|
flexWrap: "wrap",
|
|
369
|
-
gap:
|
|
370
|
-
paddingTop:
|
|
306
|
+
gap: i.vars.size.baseSpacings.sp2,
|
|
307
|
+
paddingTop: i.vars.size.baseSpacings.sp4,
|
|
371
308
|
position: "sticky",
|
|
372
309
|
bottom: 0,
|
|
373
|
-
backgroundColor:
|
|
310
|
+
backgroundColor: i.vars.palette.background.default,
|
|
374
311
|
marginTop: "auto",
|
|
375
312
|
zIndex: 10
|
|
376
313
|
}),
|
|
377
314
|
/**
|
|
378
315
|
* Estilos para las acciones del lado izquierdo del StepperFooter.
|
|
379
316
|
*/
|
|
380
|
-
stepperFooterLeftActions: ({ theme:
|
|
317
|
+
stepperFooterLeftActions: ({ theme: i }) => ({
|
|
381
318
|
display: "flex",
|
|
382
319
|
alignItems: "center",
|
|
383
|
-
gap:
|
|
320
|
+
gap: i.vars.size.baseSpacings.sp3
|
|
384
321
|
}),
|
|
385
322
|
/**
|
|
386
323
|
* Estilos para las acciones del lado derecho del StepperFooter.
|
|
387
324
|
*/
|
|
388
|
-
stepperFooterRightActions: ({ theme:
|
|
325
|
+
stepperFooterRightActions: ({ theme: i }) => ({
|
|
389
326
|
display: "flex",
|
|
390
327
|
alignItems: "center",
|
|
391
|
-
gap:
|
|
328
|
+
gap: i.vars.size.baseSpacings.sp3
|
|
392
329
|
}),
|
|
393
330
|
/**
|
|
394
331
|
* Estilos para el contenedor de los botones del Stepper.
|
|
395
332
|
*/
|
|
396
|
-
wrapperButtons: ({ theme:
|
|
333
|
+
wrapperButtons: ({ theme: i }) => ({
|
|
397
334
|
display: "flex",
|
|
398
|
-
gap:
|
|
335
|
+
gap: i.size.baseSpacings.sp3
|
|
399
336
|
})
|
|
400
337
|
};
|
|
401
338
|
export {
|
|
402
|
-
|
|
339
|
+
c as stepperStyles
|
|
403
340
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/components/src/components/Stepper/subcomponents/StepArea/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../packages/components/src/components/Stepper/subcomponents/StepArea/index.tsx"],"names":[],"mappings":"AAYA;;;;GAIG;AACH,wBAAgB,QAAQ,qDA8DvB"}
|