@m4l/components 9.3.34-BE20251126-beta.1 → 9.3.34-BE20251127-beta.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/@types/types.d.ts +17 -9
- package/components/CommonActions/components/ActionCancel/slots/ActionsCancelSlots.d.ts +1 -1
- package/components/CommonActions/components/ActionFormCancel/slots/ActionFormCancelSlots.d.ts +1 -1
- package/components/CommonActions/components/ActionIntro/slots/ActionsIntroSlots.d.ts +1 -1
- package/components/EditLabel/slots/EditLabelSlots.d.ts +1 -1
- package/components/Label/index.d.ts +1 -1
- package/components/Label/types.d.ts +0 -6
- package/components/LoadingError/LoadingError.js +1 -1
- package/components/ModalDialog/slots/ModalDialogSlots.d.ts +1 -1
- package/components/PropertyValue/PropertyValue.js +1 -1
- package/components/SettingsLayout/slots/SettingsLayoutSlots.d.ts +1 -1
- package/components/Stepper/subcomponents/StepperButtons/StepperSubmitButton/index.js +1 -1
- package/components/TabsNavigator/slots/TabsNavigatorSlots.d.ts +10 -10
- package/components/WindowBase/WindowBase.styles.js +0 -8
- package/components/WindowBase/subcomponents/Header/useButtonActions.js +13 -23
- package/components/areas/components/AreasAdmin/slots/AreasAdminSlots.d.ts +1 -1
- package/components/hook-form/RHFCheckbox/slots/RHFCheckBoxSlots.d.ts +1 -1
- package/components/hook-form/RHFColorPicker/slots/RHFColorPickerSlots.js +1 -1
- package/components/hook-form/RHFDatePicker/RHFDatePicker.d.ts +7 -0
- package/components/hook-form/RHFDatePicker/RHFDatePicker.js +85 -0
- package/components/hook-form/RHFDatePicker/RHFDatePicker.styles.d.ts +5 -0
- package/components/hook-form/RHFDatePicker/RHFDatePicker.styles.js +200 -0
- package/components/hook-form/RHFDatePicker/constants.d.ts +4 -0
- package/components/hook-form/RHFDatePicker/constants.js +4 -0
- package/components/hook-form/RHFDatePicker/icons.d.ts +6 -0
- package/components/hook-form/RHFDatePicker/index.d.ts +1 -0
- package/components/hook-form/RHFDatePicker/slots/RHFDatePickerEnum.d.ts +11 -0
- package/components/hook-form/RHFDatePicker/slots/RHFDatePickerEnum.js +15 -0
- package/components/hook-form/RHFDatePicker/slots/RHFDatePickerSlots.d.ts +50 -0
- package/components/hook-form/RHFDatePicker/slots/RHFDatePickerSlots.js +44 -0
- package/components/hook-form/RHFDatePicker/slots/index.d.ts +2 -0
- package/components/hook-form/RHFDatePicker/types.d.ts +61 -0
- package/components/hook-form/RHFDateTime/RHFDateTime.d.ts +24 -1
- package/components/hook-form/RHFDateTimePicker/RHFDateTimePicker.d.ts +11 -0
- package/components/hook-form/RHFDateTimePicker/RHFDateTimePicker.js +8 -0
- package/components/hook-form/RHFDateTimePicker/index.d.ts +1 -0
- package/components/hook-form/RHFPeriod/slots/RHFPeriodSlots.d.ts +1 -1
- package/components/hook-form/RHFSelect/slots/RHFSlots.d.ts +1 -1
- package/components/hook-form/RHFTextField/slots/RHFTextFieldSlots.d.ts +1 -1
- package/components/hook-form/RHFTextFieldPassword/slots/RHFTextFieldPasswordSlots.d.ts +1 -1
- package/components/hook-form/RHFUpload/RHFUploadImage/slots/RHFUploadImageSlots.d.ts +1 -1
- package/components/hook-form/RHFUpload/RHFUploadSingleFile/slots/RHFUploadSingleFileSlots.d.ts +1 -1
- package/components/hook-form/index.d.ts +2 -1
- package/components/index.d.ts +0 -1
- package/components/mui_extended/Autocomplete/slots/AutocompleteSlots.d.ts +1 -1
- package/components/mui_extended/Autocomplete/slots/AutocompleteSlots.js +1 -1
- package/components/mui_extended/Button/slots/ButtonSlots.d.ts +1 -1
- package/components/mui_extended/DatePicker/DatePicker.d.ts +7 -0
- package/components/mui_extended/DatePicker/DatePicker.js +39 -0
- package/components/mui_extended/DatePicker/DatePicker.styles.d.ts +5 -0
- package/components/mui_extended/DatePicker/DatePicker.styles.js +193 -0
- package/components/mui_extended/DatePicker/constants.d.ts +2 -0
- package/components/mui_extended/DatePicker/constants.js +8 -0
- package/components/mui_extended/DatePicker/hooks/useDatePicker/types.d.ts +11 -0
- package/components/mui_extended/DatePicker/hooks/useDatePicker/useDatePicker.d.ts +9 -0
- package/components/mui_extended/DatePicker/hooks/useDatePicker/useDatePicker.js +200 -0
- package/components/mui_extended/DatePicker/icons.d.ts +4 -0
- package/components/mui_extended/DatePicker/icons.js +10 -0
- package/components/mui_extended/DatePicker/index.d.ts +2 -0
- package/components/mui_extended/DatePicker/index.js +1 -0
- package/components/mui_extended/DatePicker/slots/DatePickerEnum.d.ts +10 -0
- package/components/mui_extended/DatePicker/slots/DatePickerEnum.js +14 -0
- package/components/mui_extended/DatePicker/slots/DatePickerSlots.d.ts +44 -0
- package/components/mui_extended/DatePicker/slots/DatePickerSlots.js +46 -0
- package/components/mui_extended/DatePicker/types.d.ts +32 -0
- package/components/mui_extended/LoadingButton/index.js +1 -0
- package/components/mui_extended/LoadingButton/slots/LoadingButtonSlots.d.ts +1 -1
- package/components/mui_extended/NavLink/constants.d.ts +1 -1
- package/components/mui_extended/Select/slots/SelectSlots.d.ts +1 -1
- package/components/mui_extended/Select/slots/SelectSlots.js +1 -1
- package/components/mui_extended/TextField/TextField.js +2 -2
- package/components/mui_extended/TextField/TextField.styles.js +1 -1
- package/components/mui_extended/TextField/slots/TextFieldSlots.d.ts +1 -1
- package/components/mui_extended/ToggleButton/slots/ToggleButtonSlots.d.ts +1 -1
- package/components/mui_extended/Tooltip/Tooltip.styles.js +4 -22
- package/components/mui_extended/index.d.ts +1 -0
- package/index.js +74 -72
- package/package.json +1 -1
- package/components/ActionsGroup/ActionsGroup.d.ts +0 -5
- package/components/ActionsGroup/ActionsGroup.js +0 -40
- package/components/ActionsGroup/ActionsGroup.styles.d.ts +0 -2
- package/components/ActionsGroup/ActionsGroup.styles.js +0 -95
- package/components/ActionsGroup/constants.d.ts +0 -2
- package/components/ActionsGroup/constants.js +0 -8
- package/components/ActionsGroup/icons.d.ts +0 -3
- package/components/ActionsGroup/icons.js +0 -6
- package/components/ActionsGroup/index.d.ts +0 -1
- package/components/ActionsGroup/slots/ActionsGroupEnum.d.ts +0 -8
- package/components/ActionsGroup/slots/ActionsGroupEnum.js +0 -12
- package/components/ActionsGroup/slots/ActionsGroupSlots.d.ts +0 -15
- package/components/ActionsGroup/slots/ActionsGroupSlots.js +0 -35
- package/components/ActionsGroup/subcomponents/ActionIconButton/ActionIconButton.d.ts +0 -6
- package/components/ActionsGroup/subcomponents/ActionIconButton/ActionIconButton.js +0 -76
- package/components/ActionsGroup/subcomponents/ActionIconButton/types.d.ts +0 -7
- package/components/ActionsGroup/types.d.ts +0 -60
- package/components/hook-form/RHFActionsGroup/RHFActionsGroup.d.ts +0 -7
- package/components/hook-form/RHFActionsGroup/RHFActionsGroup.js +0 -87
- package/components/hook-form/RHFActionsGroup/RHFActionsGroupStyles.d.ts +0 -2
- package/components/hook-form/RHFActionsGroup/RHFActionsGroupStyles.js +0 -14
- package/components/hook-form/RHFActionsGroup/constants.d.ts +0 -9
- package/components/hook-form/RHFActionsGroup/constants.js +0 -8
- package/components/hook-form/RHFActionsGroup/index.d.ts +0 -2
- package/components/hook-form/RHFActionsGroup/slots/RHFActionsGroupEnum.d.ts +0 -3
- package/components/hook-form/RHFActionsGroup/slots/RHFActionsGroupEnum.js +0 -7
- package/components/hook-form/RHFActionsGroup/slots/RHFActionsGroupSlots.d.ts +0 -1
- package/components/hook-form/RHFActionsGroup/slots/RHFActionsGroupSlots.js +0 -11
- package/components/hook-form/RHFActionsGroup/slots/index.d.ts +0 -2
- package/components/hook-form/RHFActionsGroup/tests/common.d.ts +0 -28
- package/components/hook-form/RHFActionsGroup/types.d.ts +0 -54
- /package/components/{ActionsGroup/__tests__/ActionsGroup.test.d.ts → hook-form/RHFDatePicker/__tests__/RHFDatePicker.test.d.ts} +0 -0
- /package/components/{ActionsGroup → hook-form/RHFDatePicker}/index.js +0 -0
- /package/components/hook-form/{RHFActionsGroup → RHFDatePicker/slots}/index.js +0 -0
- /package/components/hook-form/{RHFActionsGroup/slots → RHFDateTimePicker}/index.js +0 -0
- /package/components/{hook-form/RHFActionsGroup/tests/RHFActionsGroup.test.d.ts → mui_extended/DatePicker/__tests__/DatePicker.test.d.ts} +0 -0
|
@@ -18,7 +18,7 @@ export declare const MenuListStyled: import('@emotion/styled').StyledComponent<P
|
|
|
18
18
|
export declare const CircularProgressStyled: import('@emotion/styled').StyledComponent<Pick<import('../../CircularProgress/types').CircularProgressProps, keyof import('../../CircularProgress/types').CircularProgressProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
19
19
|
ownerState?: (Partial<import('../types').AutocompleteOwnerState> & Record<string, unknown>) | undefined;
|
|
20
20
|
}, {}, {}>;
|
|
21
|
-
export declare const RenderInputStyled: import('@emotion/styled').StyledComponent<Pick<Omit<import('../../TextField/types').TextFieldProps, "ref"> & import('react').RefAttributes<HTMLDivElement>, "value" | "size" | "children" | "title" | "component" | "name" | "error" | "select" | "rows" | "id" | "type" | "disabled" | "hidden" | "content" | "style" | "variant" | "margin" | "translate" | "className" | "classes" | "sx" | "label" | "slot" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "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" | "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" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "dataTestId" | "autoComplete" | "maxLength" | "placeholder" | "required" | keyof import('react').RefAttributes<HTMLDivElement> | "maxRows" | "fullWidth" | "
|
|
21
|
+
export declare const RenderInputStyled: import('@emotion/styled').StyledComponent<Pick<Omit<import('../../TextField/types').TextFieldProps, "ref"> & import('react').RefAttributes<HTMLDivElement>, "value" | "size" | "children" | "title" | "component" | "name" | "error" | "select" | "rows" | "id" | "type" | "disabled" | "hidden" | "content" | "style" | "variant" | "margin" | "translate" | "className" | "classes" | "sx" | "label" | "slot" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "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" | "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" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "dataTestId" | "autoComplete" | "maxLength" | "placeholder" | "required" | keyof import('react').RefAttributes<HTMLDivElement> | "maxRows" | "fullWidth" | "focused" | "hiddenLabel" | "InputProps" | "FormHelperTextProps" | "helperText" | "InputLabelProps" | "inputProps" | "inputRef" | "multiline" | "minRows" | "SelectProps"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
22
22
|
ownerState?: (Partial<import('../types').AutocompleteOwnerState> & Record<string, unknown>) | undefined;
|
|
23
23
|
}, {}, {}>;
|
|
24
24
|
export declare const TypographyStyled: import('@emotion/styled').StyledComponent<Pick<Omit<import('../../Typography/types').TypographyProps, "ref"> & import('react').RefAttributes<HTMLSpanElement>, "size" | "children" | "title" | "component" | "zIndex" | "id" | "disabled" | "paragraph" | "border" | "fontWeight" | "lineHeight" | "letterSpacing" | "fontSize" | "textTransform" | "fontFamily" | "typography" | "flex" | "hidden" | "color" | "left" | "right" | "bottom" | "top" | "content" | "style" | "position" | "ellipsis" | "padding" | "variant" | "borderRadius" | "width" | "display" | "borderColor" | "height" | "gap" | "minHeight" | "margin" | "overflow" | "boxShadow" | "minWidth" | "justifyContent" | "alignItems" | "paddingLeft" | "borderLeft" | "borderTop" | "maxWidth" | "flexDirection" | "paddingRight" | "borderRight" | "flexGrow" | "marginLeft" | "textOverflow" | "borderBottom" | "gridTemplateColumns" | "marginBottom" | "dataTestid" | "alignContent" | "alignSelf" | "boxSizing" | "columnGap" | "flexBasis" | "flexShrink" | "flexWrap" | "fontStyle" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateRows" | "justifyItems" | "justifySelf" | "marginBlockEnd" | "marginBlockStart" | "marginInlineEnd" | "marginInlineStart" | "marginRight" | "marginTop" | "maxHeight" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingTop" | "rowGap" | "textAlign" | "translate" | "visibility" | "whiteSpace" | "gridArea" | "gridColumn" | "gridRow" | "marginBlock" | "marginInline" | "paddingBlock" | "paddingInline" | "className" | "classes" | "sx" | "p" | "slot" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "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" | "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" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "displayPrint" | "align" | "htmlFor" | "gutterBottom" | "noWrap" | "variantMapping" | "skeletonWidth" | "skeletonRows" | keyof import('react').RefAttributes<HTMLSpanElement>> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Record<string, unknown> & {
|
|
@@ -9,9 +9,9 @@ import { S as Skeleton } from "../../Skeleton/Skeleton.js";
|
|
|
9
9
|
import { T as TextField } from "../../TextField/TextField.js";
|
|
10
10
|
import { P as Popper } from "../../Popper/Popper.js";
|
|
11
11
|
import { I as IconButton } from "../../IconButton/IconButton.js";
|
|
12
|
+
import { M as MenuItem } from "../../MenuItem/MenuItem.js";
|
|
12
13
|
import { T as Typography } from "../../Typography/Typography.js";
|
|
13
14
|
import { C as CircularProgress } from "../../CircularProgress/CircularProgress.js";
|
|
14
|
-
import { M as MenuItem } from "../../MenuItem/MenuItem.js";
|
|
15
15
|
const AutocompleteRootStyled = styled(Autocomplete, {
|
|
16
16
|
name: AUTOCOMPLETE_KEY_COMPONENT,
|
|
17
17
|
slot: AutocompleteSlots.root
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
declare const ButtonRootStyled: import('@emotion/styled').StyledComponent<Pick<import('@mui/material').ButtonOwnProps & Omit<import('@mui/material').ButtonBaseOwnProps, "classes"> & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
|
|
2
2
|
ref?: ((instance: HTMLButtonElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLButtonElement> | null | undefined;
|
|
3
|
-
}, "size" | "children" | "disabled" | "action" | "color" | "style" | "variant" | "className" | "classes" | "sx" | "tabIndex" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "href" | "startIcon" | "endIcon" | "
|
|
3
|
+
}, "size" | "children" | "disabled" | "action" | "color" | "style" | "variant" | "className" | "classes" | "sx" | "tabIndex" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "href" | "startIcon" | "endIcon" | "fullWidth" | "disableElevation">, "value" | "size" | "children" | "ref" | "title" | "name" | "id" | "type" | "disabled" | "action" | "hidden" | "color" | "content" | "style" | "variant" | "translate" | "className" | "classes" | "sx" | "form" | "slot" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "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" | "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" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "href" | "startIcon" | "endIcon" | "fullWidth" | "disableElevation"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('..').ButtonOwnerState> & Record<string, unknown> & {
|
|
4
4
|
ownerState: Partial<import('..').ButtonOwnerState> & Record<string, unknown>;
|
|
5
5
|
}, {}, {}>;
|
|
6
6
|
declare const SkeletonButtonStyled: import('@emotion/styled').StyledComponent<Pick<import('../../Skeleton/types').SkeletonProps, keyof import('../../Skeleton/types').SkeletonProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('..').ButtonOwnerState> & Record<string, unknown> & {
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { DatePickerProps } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Componente de selección de fecha con UI completa
|
|
4
|
+
*
|
|
5
|
+
* Este componente proporciona la interfaz de usuario para seleccionar fechas.
|
|
6
|
+
*/
|
|
7
|
+
export declare const DatePicker: (props: DatePickerProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { D as DatePickerStyled } from "./slots/DatePickerSlots.js";
|
|
3
|
+
import { u as useDatePicker } from "./hooks/useDatePicker/useDatePicker.js";
|
|
4
|
+
import { D as DATE_PICKER_CLASSES } from "./constants.js";
|
|
5
|
+
import { clsx } from "clsx";
|
|
6
|
+
const DatePicker = (props) => {
|
|
7
|
+
const {
|
|
8
|
+
value,
|
|
9
|
+
onChange,
|
|
10
|
+
disabled,
|
|
11
|
+
className,
|
|
12
|
+
readOnly,
|
|
13
|
+
...datePickerProps
|
|
14
|
+
} = props;
|
|
15
|
+
const {
|
|
16
|
+
ownerState,
|
|
17
|
+
defaultSlots,
|
|
18
|
+
defaultSlotProps,
|
|
19
|
+
dateFormat
|
|
20
|
+
} = useDatePicker(props);
|
|
21
|
+
return /* @__PURE__ */ jsx(
|
|
22
|
+
DatePickerStyled,
|
|
23
|
+
{
|
|
24
|
+
...datePickerProps,
|
|
25
|
+
className: clsx(className, DATE_PICKER_CLASSES.root),
|
|
26
|
+
value,
|
|
27
|
+
onChange: (newValue, reason) => onChange?.(newValue, reason),
|
|
28
|
+
disabled,
|
|
29
|
+
readOnly,
|
|
30
|
+
ownerState,
|
|
31
|
+
format: dateFormat,
|
|
32
|
+
slots: defaultSlots,
|
|
33
|
+
slotProps: defaultSlotProps
|
|
34
|
+
}
|
|
35
|
+
);
|
|
36
|
+
};
|
|
37
|
+
export {
|
|
38
|
+
DatePicker as D
|
|
39
|
+
};
|
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
import { g as getSizeStyles } from "../../../utils/getSizeStyles/getSizeStyles.js";
|
|
2
|
+
import { g as getTypographyStyles } from "../../../utils/getTypographyStyles.js";
|
|
3
|
+
const datePickerStyles = {
|
|
4
|
+
/**
|
|
5
|
+
* Estilos para el DatePicker de MUI.
|
|
6
|
+
* Permite personalizar los estilos del componente DatePicker.
|
|
7
|
+
*/
|
|
8
|
+
root: {},
|
|
9
|
+
/**
|
|
10
|
+
* Estilos para el TextField de MUI.
|
|
11
|
+
*/
|
|
12
|
+
textField: ({ theme, ownerState }) => ({
|
|
13
|
+
"& .MuiInputAdornment-root": {
|
|
14
|
+
...getSizeStyles(theme, ownerState?.size || "medium", "action", (size) => ({
|
|
15
|
+
width: size,
|
|
16
|
+
height: size
|
|
17
|
+
}))
|
|
18
|
+
},
|
|
19
|
+
"& .MuiFormLabel-root": {
|
|
20
|
+
display: "none"
|
|
21
|
+
}
|
|
22
|
+
}),
|
|
23
|
+
/**
|
|
24
|
+
* Estilos para el layout de MUI.
|
|
25
|
+
*/
|
|
26
|
+
layout: ({ theme, ownerState }) => ({
|
|
27
|
+
"& .MuiDateCalendar-root": {
|
|
28
|
+
maxWidth: "244px",
|
|
29
|
+
height: "fit-content",
|
|
30
|
+
gap: theme.vars.size.baseSpacings.sp3,
|
|
31
|
+
"& .MuiPickersFadeTransitionGroup-root": {
|
|
32
|
+
"& .MuiYearCalendar-root": {
|
|
33
|
+
display: "grid",
|
|
34
|
+
gridTemplateColumns: "repeat(auto-fill, minmax(50px, 1fr));",
|
|
35
|
+
justifyContent: "space-between",
|
|
36
|
+
width: "100%",
|
|
37
|
+
rowGap: theme.vars.size.baseSpacings.sp2,
|
|
38
|
+
"& .MuiPickersYear-root": {
|
|
39
|
+
width: theme.vars.size.baseSpacings.sp10,
|
|
40
|
+
"& .MuiPickersYear-yearButton": {
|
|
41
|
+
borderRadius: theme.vars.size.borderRadius["r1-5"],
|
|
42
|
+
...getSizeStyles(theme, ownerState?.size || "medium", "action", (size) => ({
|
|
43
|
+
height: size
|
|
44
|
+
})),
|
|
45
|
+
...getTypographyStyles(theme.generalSettings.isMobile, ownerState?.size || "medium", "body"),
|
|
46
|
+
margin: 0,
|
|
47
|
+
padding: 0,
|
|
48
|
+
"&:hover": {
|
|
49
|
+
backgroundColor: theme.vars.palette.default.hoverOpacity
|
|
50
|
+
},
|
|
51
|
+
"&:active": {
|
|
52
|
+
backgroundColor: theme.vars.palette.default.active
|
|
53
|
+
},
|
|
54
|
+
"&.Mui-selected": {
|
|
55
|
+
backgroundColor: theme.vars.palette.primary.enabled,
|
|
56
|
+
color: theme.vars.palette.primary.contrastText,
|
|
57
|
+
"&:hover": {
|
|
58
|
+
backgroundColor: theme.vars.palette.primary.hover
|
|
59
|
+
},
|
|
60
|
+
"&:active": {
|
|
61
|
+
backgroundColor: theme.vars.palette.primary.active
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
"& .MuiDayCalendar-root": {
|
|
69
|
+
minHeight: "fit-content",
|
|
70
|
+
"& .MuiDayCalendar-header": {
|
|
71
|
+
height: theme.vars.size.baseSpacings.sp7,
|
|
72
|
+
width: "100%",
|
|
73
|
+
gap: theme.vars.size.baseSpacings.sp1,
|
|
74
|
+
justifyContent: "flex-start",
|
|
75
|
+
margin: 0,
|
|
76
|
+
padding: 0,
|
|
77
|
+
"& .MuiDayCalendar-weekDayLabel": {
|
|
78
|
+
height: theme.vars.size.baseSpacings.sp7,
|
|
79
|
+
width: theme.vars.size.baseSpacings.sp7,
|
|
80
|
+
...getTypographyStyles(theme.generalSettings.isMobile, ownerState?.size || "medium", "body"),
|
|
81
|
+
color: theme.vars.palette.text.secondary,
|
|
82
|
+
display: "flex",
|
|
83
|
+
alignItems: "center",
|
|
84
|
+
justifyContent: "center"
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
"& .MuiPickersSlideTransition-root": {
|
|
88
|
+
minHeight: "168px",
|
|
89
|
+
"& .MuiDayCalendar-weekContainer": {
|
|
90
|
+
height: "fit-content",
|
|
91
|
+
gap: theme.vars.size.baseSpacings.sp1,
|
|
92
|
+
justifyContent: "flex-start",
|
|
93
|
+
margin: 0,
|
|
94
|
+
padding: 0,
|
|
95
|
+
"& .MuiPickersDay-root": {
|
|
96
|
+
borderRadius: theme.vars.size.borderRadius["r1-5"],
|
|
97
|
+
height: theme.vars.size.baseSpacings.sp7,
|
|
98
|
+
width: theme.vars.size.baseSpacings.sp7,
|
|
99
|
+
color: theme.vars.palette.text.primary,
|
|
100
|
+
display: "flex",
|
|
101
|
+
alignItems: "center",
|
|
102
|
+
justifyContent: "center",
|
|
103
|
+
...getTypographyStyles(theme.generalSettings.isMobile, ownerState?.size || "medium", "body"),
|
|
104
|
+
"&.Mui-selected": {
|
|
105
|
+
backgroundColor: theme.vars.palette.primary.enabled,
|
|
106
|
+
color: theme.vars.palette.primary.contrastText,
|
|
107
|
+
"&:hover": {
|
|
108
|
+
backgroundColor: theme.vars.palette.primary.hover
|
|
109
|
+
},
|
|
110
|
+
"&:active": {
|
|
111
|
+
backgroundColor: theme.vars.palette.primary.active
|
|
112
|
+
}
|
|
113
|
+
},
|
|
114
|
+
"&:hover": {
|
|
115
|
+
backgroundColor: theme.vars.palette.default.hoverOpacity
|
|
116
|
+
},
|
|
117
|
+
"&:active": {
|
|
118
|
+
backgroundColor: theme.vars.palette.default.active
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}),
|
|
126
|
+
/**
|
|
127
|
+
* Estilos para el desktopPaper de MUI.
|
|
128
|
+
*/
|
|
129
|
+
desktopPaper: ({ theme }) => ({
|
|
130
|
+
// Overrides
|
|
131
|
+
backgroundColor: theme.vars.palette.background.default,
|
|
132
|
+
borderRadius: theme.vars.size.borderRadius.r2,
|
|
133
|
+
boxShadow: theme.vars.customShadows.z4,
|
|
134
|
+
padding: theme.vars.size.baseSpacings.sp3,
|
|
135
|
+
gap: theme.vars.size.baseSpacings.sp1
|
|
136
|
+
}),
|
|
137
|
+
/**
|
|
138
|
+
* Estilos para el calendarHeader de MUI.
|
|
139
|
+
*/
|
|
140
|
+
calendarHeader: ({ theme, ownerState }) => ({
|
|
141
|
+
"&&&.MuiPickersCalendarHeader-root": {
|
|
142
|
+
margin: 0,
|
|
143
|
+
padding: 0,
|
|
144
|
+
minHeight: "fit-content",
|
|
145
|
+
maxHeight: "fit-content",
|
|
146
|
+
"& .MuiPickersCalendarHeader-labelContainer": {
|
|
147
|
+
...getSizeStyles(theme, ownerState?.size || "medium", "action", (height) => ({
|
|
148
|
+
height,
|
|
149
|
+
minHeight: height,
|
|
150
|
+
maxHeight: height
|
|
151
|
+
})),
|
|
152
|
+
paddingLeft: theme.vars.size.baseSpacings.sp3,
|
|
153
|
+
paddingRight: 0,
|
|
154
|
+
paddingTop: 0,
|
|
155
|
+
paddingBottom: 0,
|
|
156
|
+
border: `1px solid ${theme.vars.palette.border.secondary}`,
|
|
157
|
+
borderRadius: theme.vars.size.borderRadius["r1-5"],
|
|
158
|
+
"& .MuiPickersCalendarHeader-label": {
|
|
159
|
+
...getTypographyStyles(theme.generalSettings.isMobile, ownerState?.size || "medium", "body")
|
|
160
|
+
}
|
|
161
|
+
},
|
|
162
|
+
"& .MuiPickersArrowSwitcher-root": {
|
|
163
|
+
minWidth: "52px",
|
|
164
|
+
gap: theme.vars.size.baseSpacings["sp0-5"],
|
|
165
|
+
justifyContent: "space-between"
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}),
|
|
169
|
+
/**
|
|
170
|
+
* Estilos para el iconButton de M4L.
|
|
171
|
+
* Requerido para corrección de fix en tamaños ↴ Overrides ❌
|
|
172
|
+
*/
|
|
173
|
+
iconButton: () => ({}),
|
|
174
|
+
/**
|
|
175
|
+
* Estilos para el actionsContainer de M4L.
|
|
176
|
+
*/
|
|
177
|
+
actionsContainer: ({ theme }) => ({
|
|
178
|
+
paddingLeft: theme.vars.size.baseSpacings.sp6,
|
|
179
|
+
paddingRight: theme.vars.size.baseSpacings.sp6,
|
|
180
|
+
paddingBottom: theme.vars.size.baseSpacings.sp4
|
|
181
|
+
}),
|
|
182
|
+
/**
|
|
183
|
+
* Estilos para el dialog de MUI.
|
|
184
|
+
*/
|
|
185
|
+
dialog: ({ theme }) => ({
|
|
186
|
+
"& .MuiPaper-root": {
|
|
187
|
+
borderRadius: theme.vars.size.borderRadius.r2
|
|
188
|
+
}
|
|
189
|
+
})
|
|
190
|
+
};
|
|
191
|
+
export {
|
|
192
|
+
datePickerStyles as d
|
|
193
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { g as getComponentClasses } from "../../../utils/getComponentSlotRoot.js";
|
|
2
|
+
import { D as DatePickerEnum } from "./slots/DatePickerEnum.js";
|
|
3
|
+
const DATE_PICKER_KEY_COMPONENT = "M4LDatePicker";
|
|
4
|
+
const DATE_PICKER_CLASSES = getComponentClasses(DATE_PICKER_KEY_COMPONENT, DatePickerEnum);
|
|
5
|
+
export {
|
|
6
|
+
DATE_PICKER_CLASSES as D,
|
|
7
|
+
DATE_PICKER_KEY_COMPONENT as a
|
|
8
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DatePickerSlotsComponents, DatePickerSlotsComponentsProps } from '@mui/x-date-pickers';
|
|
2
|
+
import { DatePickerOwnerState } from '../../types';
|
|
3
|
+
/**
|
|
4
|
+
* Tipo de retorno del hook useDatePicker
|
|
5
|
+
*/
|
|
6
|
+
export interface UseDatePickerReturn {
|
|
7
|
+
ownerState: DatePickerOwnerState;
|
|
8
|
+
defaultSlots: DatePickerSlotsComponents<unknown>;
|
|
9
|
+
defaultSlotProps: DatePickerSlotsComponentsProps<unknown>;
|
|
10
|
+
dateFormat: string;
|
|
11
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DatePickerProps } from '../../types';
|
|
2
|
+
import { UseDatePickerReturn } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* Hook personalizado que encapsula toda la lógica de memos, callbacks y objetos
|
|
5
|
+
* necesarios para el componente DatePicker
|
|
6
|
+
* @param props - Props del componente DatePicker
|
|
7
|
+
* @returns Objeto con ownerState, defaultSlots, defaultSlotProps, dateFormat y dateMask
|
|
8
|
+
*/
|
|
9
|
+
export declare const useDatePicker: (props: DatePickerProps) => UseDatePickerReturn;
|
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { I as IconButtonStyled, C as CalendarHeaderStyled, A as ActionsContainerStyled, P as PickersLayoutStyled, a as DesktopPaperStyled, T as TextFieldStyled } from "../../slots/DatePickerSlots.js";
|
|
3
|
+
import { useFormatter, useIsMobile } from "@m4l/graphics";
|
|
4
|
+
import React, { useMemo, useCallback } from "react";
|
|
5
|
+
import { useEnvironment, useModuleDictionary } from "@m4l/core";
|
|
6
|
+
import { c as chevron_left, a as chevron_right, b as chevron_down, d as calendar } from "../../icons.js";
|
|
7
|
+
import { d as datePickerStyles } from "../../DatePicker.styles.js";
|
|
8
|
+
import { u as useComponentSize } from "../../../../../hooks/useComponentSize/useComponentSize.js";
|
|
9
|
+
import { I as IconButton } from "../../../IconButton/IconButton.js";
|
|
10
|
+
import { B as Button } from "../../../Button/Button.js";
|
|
11
|
+
const useDatePicker = (props) => {
|
|
12
|
+
const {
|
|
13
|
+
error,
|
|
14
|
+
size = "medium",
|
|
15
|
+
disabled,
|
|
16
|
+
slots,
|
|
17
|
+
variant = "outlined",
|
|
18
|
+
readOnly,
|
|
19
|
+
id
|
|
20
|
+
} = props;
|
|
21
|
+
const { dateFormatter } = useFormatter();
|
|
22
|
+
const { host_static_assets, environment_assets } = useEnvironment();
|
|
23
|
+
const { getLabel } = useModuleDictionary();
|
|
24
|
+
const isMobile = useIsMobile();
|
|
25
|
+
const { currentSize } = useComponentSize(size);
|
|
26
|
+
const { dateFormat } = dateFormatter;
|
|
27
|
+
const ownerState = useMemo(() => ({
|
|
28
|
+
size: currentSize,
|
|
29
|
+
error: !!error,
|
|
30
|
+
disabled: !!disabled
|
|
31
|
+
}), [currentSize, error, disabled]);
|
|
32
|
+
const CustomPreviousIconButton = useMemo(() => {
|
|
33
|
+
return React.forwardRef((iconButtonProps, ref) => {
|
|
34
|
+
return /* @__PURE__ */ jsx(
|
|
35
|
+
IconButtonStyled,
|
|
36
|
+
{
|
|
37
|
+
ref,
|
|
38
|
+
...iconButtonProps,
|
|
39
|
+
ownerState,
|
|
40
|
+
size: currentSize,
|
|
41
|
+
disabled,
|
|
42
|
+
icon: `${host_static_assets}/${environment_assets}/${chevron_left}`
|
|
43
|
+
}
|
|
44
|
+
);
|
|
45
|
+
});
|
|
46
|
+
}, [currentSize, disabled, environment_assets, host_static_assets, ownerState]);
|
|
47
|
+
const CustomNextIconButton = useMemo(() => {
|
|
48
|
+
return React.forwardRef((iconButtonProps, ref) => {
|
|
49
|
+
return /* @__PURE__ */ jsx(
|
|
50
|
+
IconButtonStyled,
|
|
51
|
+
{
|
|
52
|
+
ref,
|
|
53
|
+
...iconButtonProps,
|
|
54
|
+
ownerState,
|
|
55
|
+
size: currentSize,
|
|
56
|
+
disabled,
|
|
57
|
+
icon: `${host_static_assets}/${environment_assets}/${chevron_right}`
|
|
58
|
+
}
|
|
59
|
+
);
|
|
60
|
+
});
|
|
61
|
+
}, [currentSize, disabled, environment_assets, host_static_assets, ownerState]);
|
|
62
|
+
const CustomSwitchViewButton = useMemo(() => {
|
|
63
|
+
return React.forwardRef((iconButtonProps, ref) => {
|
|
64
|
+
const currentView = iconButtonProps?.ownerState?.view;
|
|
65
|
+
const isYearView = currentView === "year";
|
|
66
|
+
const rotationAngle = isYearView ? 180 : 0;
|
|
67
|
+
return /* @__PURE__ */ jsx(
|
|
68
|
+
IconButtonStyled,
|
|
69
|
+
{
|
|
70
|
+
ref,
|
|
71
|
+
...iconButtonProps,
|
|
72
|
+
ownerState,
|
|
73
|
+
size: currentSize,
|
|
74
|
+
disabled,
|
|
75
|
+
rotationAngle,
|
|
76
|
+
icon: `${host_static_assets}/${environment_assets}/${chevron_down}`
|
|
77
|
+
}
|
|
78
|
+
);
|
|
79
|
+
});
|
|
80
|
+
}, [currentSize, disabled, environment_assets, host_static_assets, ownerState]);
|
|
81
|
+
const calendarHeaderCallback = useCallback((args) => {
|
|
82
|
+
return /* @__PURE__ */ jsx(CalendarHeaderStyled, { ...args, ownerState });
|
|
83
|
+
}, [ownerState]);
|
|
84
|
+
const CustomCancelButton = useMemo(() => {
|
|
85
|
+
return React.forwardRef((buttonProps, ref) => {
|
|
86
|
+
return /* @__PURE__ */ jsx(
|
|
87
|
+
Button,
|
|
88
|
+
{
|
|
89
|
+
ref,
|
|
90
|
+
...buttonProps,
|
|
91
|
+
variant: "text",
|
|
92
|
+
color: "default",
|
|
93
|
+
size: currentSize,
|
|
94
|
+
label: getLabel("common_actions.cancel"),
|
|
95
|
+
disabled
|
|
96
|
+
}
|
|
97
|
+
);
|
|
98
|
+
});
|
|
99
|
+
}, [currentSize, disabled, getLabel]);
|
|
100
|
+
const CustomOkButton = useMemo(() => {
|
|
101
|
+
return React.forwardRef((buttonProps, ref) => {
|
|
102
|
+
return /* @__PURE__ */ jsx(
|
|
103
|
+
Button,
|
|
104
|
+
{
|
|
105
|
+
ref,
|
|
106
|
+
...buttonProps,
|
|
107
|
+
variant: "contained",
|
|
108
|
+
color: "primary",
|
|
109
|
+
size: currentSize,
|
|
110
|
+
label: getLabel("common_actions.intro"),
|
|
111
|
+
disabled
|
|
112
|
+
}
|
|
113
|
+
);
|
|
114
|
+
});
|
|
115
|
+
}, [currentSize, disabled, getLabel]);
|
|
116
|
+
const CustomActionBar = useMemo(() => {
|
|
117
|
+
return React.forwardRef((actionBarProps, ref) => {
|
|
118
|
+
const { onAccept, onCancel, className: actionBarClassName } = actionBarProps;
|
|
119
|
+
return /* @__PURE__ */ jsxs(
|
|
120
|
+
ActionsContainerStyled,
|
|
121
|
+
{
|
|
122
|
+
ref,
|
|
123
|
+
className: actionBarClassName,
|
|
124
|
+
children: [
|
|
125
|
+
/* @__PURE__ */ jsx(CustomCancelButton, { onClick: onCancel }),
|
|
126
|
+
/* @__PURE__ */ jsx(CustomOkButton, { onClick: onAccept })
|
|
127
|
+
]
|
|
128
|
+
}
|
|
129
|
+
);
|
|
130
|
+
});
|
|
131
|
+
}, [CustomCancelButton, CustomOkButton]);
|
|
132
|
+
const mobileActionBarSlot = useMemo(() => {
|
|
133
|
+
if (isMobile && slots?.actionBar === void 0) {
|
|
134
|
+
return { actionBar: CustomActionBar };
|
|
135
|
+
}
|
|
136
|
+
return {};
|
|
137
|
+
}, [isMobile, slots?.actionBar, CustomActionBar]);
|
|
138
|
+
const openPickerButton = useCallback((args) => {
|
|
139
|
+
return /* @__PURE__ */ jsx(
|
|
140
|
+
IconButton,
|
|
141
|
+
{
|
|
142
|
+
...args,
|
|
143
|
+
icon: `${host_static_assets}/${environment_assets}/${calendar}`,
|
|
144
|
+
size: currentSize,
|
|
145
|
+
disabled: readOnly || disabled
|
|
146
|
+
}
|
|
147
|
+
);
|
|
148
|
+
}, [currentSize, disabled, environment_assets, host_static_assets, readOnly]);
|
|
149
|
+
const defaultSlots = useMemo(() => ({
|
|
150
|
+
textField: TextFieldStyled,
|
|
151
|
+
openPickerButton,
|
|
152
|
+
// Popper component
|
|
153
|
+
desktopPaper: DesktopPaperStyled,
|
|
154
|
+
calendarHeader: calendarHeaderCallback,
|
|
155
|
+
previousIconButton: CustomPreviousIconButton,
|
|
156
|
+
nextIconButton: CustomNextIconButton,
|
|
157
|
+
switchViewButton: CustomSwitchViewButton,
|
|
158
|
+
layout: PickersLayoutStyled,
|
|
159
|
+
...mobileActionBarSlot
|
|
160
|
+
}), [
|
|
161
|
+
calendarHeaderCallback,
|
|
162
|
+
CustomNextIconButton,
|
|
163
|
+
CustomPreviousIconButton,
|
|
164
|
+
CustomSwitchViewButton,
|
|
165
|
+
mobileActionBarSlot,
|
|
166
|
+
openPickerButton
|
|
167
|
+
]);
|
|
168
|
+
const hasError = !!error;
|
|
169
|
+
const dialogSxStyles = useMemo(() => {
|
|
170
|
+
const dialogStyleFn = datePickerStyles?.dialog;
|
|
171
|
+
if (!dialogStyleFn || typeof dialogStyleFn !== "function") {
|
|
172
|
+
return void 0;
|
|
173
|
+
}
|
|
174
|
+
return (theme) => {
|
|
175
|
+
return dialogStyleFn({ theme });
|
|
176
|
+
};
|
|
177
|
+
}, []);
|
|
178
|
+
const defaultSlotProps = useMemo(() => ({
|
|
179
|
+
textField: {
|
|
180
|
+
id,
|
|
181
|
+
error: hasError,
|
|
182
|
+
size: currentSize,
|
|
183
|
+
variant,
|
|
184
|
+
label: null,
|
|
185
|
+
readOnly
|
|
186
|
+
},
|
|
187
|
+
dialog: {
|
|
188
|
+
sx: dialogSxStyles
|
|
189
|
+
}
|
|
190
|
+
}), [id, hasError, currentSize, variant, readOnly, dialogSxStyles]);
|
|
191
|
+
return {
|
|
192
|
+
ownerState,
|
|
193
|
+
defaultSlots,
|
|
194
|
+
defaultSlotProps,
|
|
195
|
+
dateFormat
|
|
196
|
+
};
|
|
197
|
+
};
|
|
198
|
+
export {
|
|
199
|
+
useDatePicker as u
|
|
200
|
+
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare const chevron_down = "frontend/components/rhfdatepicker/assets/icons/chevron_down.svg";
|
|
2
|
+
export declare const calendar = "frontend/components/rhfdatepicker/assets/icons/created_at.svg";
|
|
3
|
+
export declare const chevron_left = "frontend/components/rhfdatepicker/assets/icons/chevron_left_sm.svg";
|
|
4
|
+
export declare const chevron_right = "frontend/components/rhfdatepicker/assets/icons/chevron_right_sm.svg";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
const chevron_down = "frontend/components/rhfdatepicker/assets/icons/chevron_down.svg";
|
|
2
|
+
const calendar = "frontend/components/rhfdatepicker/assets/icons/created_at.svg";
|
|
3
|
+
const chevron_left = "frontend/components/rhfdatepicker/assets/icons/chevron_left_sm.svg";
|
|
4
|
+
const chevron_right = "frontend/components/rhfdatepicker/assets/icons/chevron_right_sm.svg";
|
|
5
|
+
export {
|
|
6
|
+
chevron_right as a,
|
|
7
|
+
chevron_down as b,
|
|
8
|
+
chevron_left as c,
|
|
9
|
+
calendar as d
|
|
10
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare enum DatePickerEnum {
|
|
2
|
+
root = "root",
|
|
3
|
+
textField = "textField",
|
|
4
|
+
desktopPaper = "desktopPaper",
|
|
5
|
+
calendarHeader = "calendarHeader",
|
|
6
|
+
iconButton = "iconButton",
|
|
7
|
+
layout = "layout",
|
|
8
|
+
actionsContainer = "actionsContainer",
|
|
9
|
+
dialog = "dialog"
|
|
10
|
+
}
|