@m4l/components 8.1.0-beta.devDaniel.Icon → 8.1.0-beta.devDaniel.inputNumberSpinner
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 +15 -10
- package/components/ControlIncrement/ControlIncrement.d.ts +5 -0
- package/components/ControlIncrement/ControlIncrement.styles.d.ts +8 -0
- package/components/ControlIncrement/constants.d.ts +25 -0
- package/components/ControlIncrement/slots/ControlIncrementEnum.d.ts +6 -0
- package/components/ControlIncrement/slots/ControltrolIncrementSlots.d.ts +14 -0
- package/components/ControlIncrement/slots/index.d.ts +2 -0
- package/components/ControlIncrement/stories/ControlClick/ControlIncrement.controlclick.stories.d.ts +13 -0
- package/components/ControlIncrement/stories/DefaultAndDisabled/ControlIncrement.defaultanddisabled.stories.d.ts +17 -0
- package/components/ControlIncrement/stories/Sizes/ControlIncrement.sizes.stories.d.ts +21 -0
- package/components/ControlIncrement/types.d.ts +56 -0
- package/components/DataGrid/classes/index.d.ts +1 -1
- package/components/DynamicFilter/slots/dynamicFilterSlots.d.ts +1 -1
- package/components/DynamicSort/slots/DynamicSortSlots.d.ts +1 -1
- package/components/GridLayout/classes/index.d.ts +1 -1
- package/components/HelperError/HelperError.js +2 -1
- package/components/HelperError/types.d.ts +4 -0
- package/components/Icon/Icon.d.ts +3 -0
- package/components/Icon/Icon.js +71 -54
- package/components/Icon/Icon.stories.d.ts +166 -0
- package/components/Icon/Icon.styles.js +31 -73
- package/components/Icon/slots/IconEnum.d.ts +1 -2
- package/components/Icon/slots/IconEnum.js +0 -1
- package/components/Icon/slots/IconSlots.d.ts +0 -3
- package/components/Icon/slots/IconSlots.js +1 -7
- package/components/Icon/types.d.ts +12 -16
- package/components/InputNumberSpinner/InputNumberSpinner.d.ts +5 -0
- package/components/InputNumberSpinner/InputNumberSpinner.styles.d.ts +8 -0
- package/components/InputNumberSpinner/constants.d.ts +9 -0
- package/components/InputNumberSpinner/hooks/types.d.ts +13 -0
- package/components/InputNumberSpinner/hooks/useInputNumberSpinner.d.ts +19 -0
- package/components/InputNumberSpinner/index.d.ts +2 -0
- package/components/InputNumberSpinner/slots/InputNumberSpinnerEnum.d.ts +7 -0
- package/components/InputNumberSpinner/slots/InputNumberSpinnerSlots.d.ts +15 -0
- package/components/InputNumberSpinner/slots/index.d.ts +2 -0
- package/components/InputNumberSpinner/stories/Default/InputNumberSpinner.default.stories.d.ts +25 -0
- package/components/InputNumberSpinner/stories/Error/InputNumberSpinner.error.stories.d.ts +25 -0
- package/components/InputNumberSpinner/stories/Sizes/InputNumberSpinner.sizes.stories.d.ts +41 -0
- package/components/InputNumberSpinner/stories/Variants/InputNumberSpinner.variants.stories.d.ts +25 -0
- package/components/InputNumberSpinner/types.d.ts +64 -0
- package/components/Label/Label.js +9 -1
- package/components/Label/slots/LabelSlots.d.ts +1 -1
- package/components/Label/types.d.ts +4 -0
- package/components/PropertyValue/classes/index.d.ts +1 -1
- package/components/SideBar/classes/index.d.ts +1 -1
- package/components/SideBar/subcomponents/ContentGroups/subcomponents/ItemListRoot/subcomponents/NavListSub/subcomponents/NavItemSub/styles.d.ts +1 -1
- package/components/SideBar/subcomponents/ContentGroups/subcomponents/ItemListRoot/subcomponents/NavListSub/subcomponents/NavItemSub/subcomponents/NavItemSubContent/styles.d.ts +1 -1
- package/components/ToastContainer/subcomponents/ToastMessage/useToastMessage.d.ts +1 -1
- package/components/ToastContainer/subcomponents/ToastMessage/useToastMessage.js +1 -2
- package/components/extended/react-resizable/Resizable/slots/ResizableSlots.d.ts +1 -1
- package/components/extended/react-resizable/ResizableBox/slots/ResizableBoxSlots.d.ts +1 -1
- package/components/hook-form/RHFAutocomplete/classes/index.d.ts +1 -1
- package/components/hook-form/RHFCheckbox/styles.d.ts +1 -1
- package/components/hook-form/RHFTextField/slots/RHFTextFieldSlots.d.ts +1 -1
- package/components/hook-form/RHFormContext/classes/index.d.ts +1 -1
- package/components/mui_extended/Badge/slots/BadgeSlots.d.ts +1 -1
- package/components/mui_extended/Button/styles.d.ts +1 -1
- package/components/mui_extended/IconButton/IconButton.js +3 -4
- package/components/mui_extended/IconButton/slots/IconButtonSlots.d.ts +2 -2
- package/components/mui_extended/IconButton/types.d.ts +1 -1
- package/components/mui_extended/MenuActions/slots/MenuActionsSlots.d.ts +1 -1
- package/components/mui_extended/Skeleton/Slots/skeletonSlots.d.ts +1 -1
- package/components/mui_extended/Tabs/styles.d.ts +1 -1
- package/components/mui_extended/Typography/slots/typographySlots.d.ts +1 -1
- package/package.json +1 -1
- package/components/Icon/stories/DefaultWithProps/Icon.defaultWithProps.stories.d.ts +0 -35
- package/components/Icon/stories/Preset/Icon.preset.stories.d.ts +0 -16
- package/components/Icon/stories/Semantic/Icon.semantic.stories.d.ts +0 -30
- package/components/Icon/stories/Sizes/icon.sizes.stories.d.ts +0 -40
- package/components/hook-form/RHFInputNumberSpinner/RHFInputNumberSpinner.d.ts +0 -5
- package/components/hook-form/RHFInputNumberSpinner/RHFInputNumberSpinner.stories.d.ts +0 -21
- package/components/hook-form/RHFInputNumberSpinner/RHFInputNumberSpinner.styles.d.ts +0 -2
- package/components/hook-form/RHFInputNumberSpinner/constants.d.ts +0 -1
- package/components/hook-form/RHFInputNumberSpinner/index.d.ts +0 -1
- package/components/hook-form/RHFInputNumberSpinner/slots/RHFInputNumberSpinnerSlots.d.ts +0 -23
- package/components/hook-form/RHFInputNumberSpinner/slots/RHFInputNumberSpinnnerEnum.d.ts +0 -9
- package/components/hook-form/RHFInputNumberSpinner/slots/index.d.ts +0 -2
- package/components/hook-form/RHFInputNumberSpinner/subcomponents/SkeletonSpinner/index.d.ts +0 -4
- package/components/hook-form/RHFInputNumberSpinner/types.d.ts +0 -21
- package/components/hook-form/RHFInputNumberSpinner/useRHFInputNumberSpinner.d.ts +0 -13
package/@types/types.d.ts
CHANGED
|
@@ -9,10 +9,6 @@ import {
|
|
|
9
9
|
MenuActionsOwnerState,
|
|
10
10
|
MenuActionsSlotsType,
|
|
11
11
|
} from '../components/mui_extended/MenuActions/types';
|
|
12
|
-
import {
|
|
13
|
-
RHFInputNumberSpinnerOwnerState,
|
|
14
|
-
RHFInputNumberSpinnerSlotsType,
|
|
15
|
-
} from '../components/hook-form/RHFInputNumberSpinner/types';
|
|
16
12
|
|
|
17
13
|
import {
|
|
18
14
|
PopupViewerSlotsType,
|
|
@@ -40,7 +36,9 @@ import type {
|
|
|
40
36
|
} from '../components/mui_extended/IconButton/types';
|
|
41
37
|
|
|
42
38
|
import type { BadgeSlotsType, BadgeOwnerState } from '../components/mui_extended/Badge/types';
|
|
39
|
+
import { ControlIncrementOwnerState, ControlIncrementSlotsType } from '../components/ControlIncrement/types';
|
|
43
40
|
import { SkeletonOwnerState, SkeletonSlotsType } from '../components/mui_extended/Skeleton/types';
|
|
41
|
+
import { InputNumberSpinnerOwnerState, InputNumberSpinnerSlotsType } from '../components/InputNumberSpinner/types';
|
|
44
42
|
import { TypographyOwnerState, TypographySlotsType } from '../components/mui_extended/Typography/types';
|
|
45
43
|
|
|
46
44
|
declare module '@mui/material/styles' {
|
|
@@ -50,7 +48,7 @@ declare module '@mui/material/styles' {
|
|
|
50
48
|
RHFTextField: RHFTextFieldSlotsType;
|
|
51
49
|
M4LDynamicSort: DynamicSortSlotsType;
|
|
52
50
|
M4LMenuActions: MenuActionsSlotsType;
|
|
53
|
-
|
|
51
|
+
M4LInputNumberSpinner: InputNumberSpinnerSlotsType;
|
|
54
52
|
M4LPopupsViewer: PopupViewerSlotsType;
|
|
55
53
|
M4LIcon: IconSlotsType;
|
|
56
54
|
M4LDragResizeWindow: DragResizeWindowSlotsType;
|
|
@@ -60,6 +58,7 @@ declare module '@mui/material/styles' {
|
|
|
60
58
|
M4LTooltip: TooltipSlotsType;
|
|
61
59
|
M4LIconButton: IconButtonSlotsType;
|
|
62
60
|
M4LBadge: BadgeSlotsType;
|
|
61
|
+
M4LControlIncrement: ControlIncrementSlotsType;
|
|
63
62
|
M4LSkeleton: SkeletonSlotsType;
|
|
64
63
|
M4LTypography: TypographySlotsType;
|
|
65
64
|
}
|
|
@@ -70,7 +69,7 @@ declare module '@mui/material/styles' {
|
|
|
70
69
|
RHFTextField: Partial<RHFTextFieldOwnerState>;
|
|
71
70
|
M4LDynamicSort: Partial<DynamicSortOwnerState>;
|
|
72
71
|
M4LMenuActions: Partial<MenuActionsOwnerState>;
|
|
73
|
-
|
|
72
|
+
M4LInputNumberSpinner: Partial<InputNumberSpinnerOwnerState>;
|
|
74
73
|
M4LPopupsViewer: Partial<PopupsViewerOwnerState>;
|
|
75
74
|
M4LIcon: Partial<IconOwnerState>;
|
|
76
75
|
M4LDragResizeWindow: Partial<DragResizeWindowOwnerState>;
|
|
@@ -80,6 +79,7 @@ declare module '@mui/material/styles' {
|
|
|
80
79
|
M4LTooltip: Partial<TooltipOwnerState>;
|
|
81
80
|
M4LIconButton: Partial<IconButtonOwnerState>;
|
|
82
81
|
M4LBadge: Partial<BadgeOwnerState>;
|
|
82
|
+
M4LControlIncrement: Partial<ControlIncrementOwnerState>
|
|
83
83
|
M4LSkeleton: Partial<SkeletonOwnerState>;
|
|
84
84
|
M4LTypography: Partial<TypographyOwnerState>;
|
|
85
85
|
}
|
|
@@ -105,10 +105,10 @@ declare module '@mui/material/styles' {
|
|
|
105
105
|
styleOverrides?: ComponentsOverrides<Theme>['M4LMenuActions'];
|
|
106
106
|
variants?: ComponentsVariants['M4LMenuActions'];
|
|
107
107
|
};
|
|
108
|
-
|
|
109
|
-
defaultProps?: ComponentsPropsList['
|
|
110
|
-
styleOverrides?: ComponentsOverrides<Theme>['
|
|
111
|
-
variants?: ComponentsVariants['
|
|
108
|
+
M4LInputNumberSpinner?: {
|
|
109
|
+
defaultProps?: ComponentsPropsList['M4LInputNumberSpinner'];
|
|
110
|
+
styleOverrides?: ComponentsOverrides<Theme>['M4LInputNumberSpinner'];
|
|
111
|
+
variants?: ComponentsVariants['M4LInputNumberSpinner'];
|
|
112
112
|
};
|
|
113
113
|
M4LPopupsViewer?: {
|
|
114
114
|
defaultProps?: ComponentsPropsList['M4LPopupsViewer'];
|
|
@@ -155,6 +155,11 @@ declare module '@mui/material/styles' {
|
|
|
155
155
|
styleOverrides?: ComponentsOverrides<Theme>['M4LBadge'];
|
|
156
156
|
variants?: ComponentsVariants['M4LBadge'];
|
|
157
157
|
};
|
|
158
|
+
M4LControlIncrement?: {
|
|
159
|
+
defaultProps?: ComponentsPropsList['M4LControlIncrement'];
|
|
160
|
+
styleOverrides?: ComponentsOverrides<Theme>['M4LControlIncrement'];
|
|
161
|
+
variants?: ComponentsVariants['M4LControlIncrement'];
|
|
162
|
+
};
|
|
158
163
|
M4LSkeleton?: {
|
|
159
164
|
defaultProps?: ComponentsPropsList['M4LSkeleton'];
|
|
160
165
|
styleOverrides?: ComponentsOverrides<Theme>['M4LSkeleton'];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ControlIncrementStyles } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* Estilos utilizados para el componente `ControlIncrement`.
|
|
4
|
+
* Este objeto define los estilos para los diferentes "slots" (partes) del componente,
|
|
5
|
+
* como el contenedor principal (`root`), los botones de incremento (`iconButtonUp`) y decremento (`iconButtonDown`),
|
|
6
|
+
* y el esqueleto (`controlIncrementSkeleton`).
|
|
7
|
+
*/
|
|
8
|
+
export declare const controlIncrementStyles: ControlIncrementStyles;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Nombre de clase que se usa para dar identidad a los slots del componente.
|
|
3
|
+
*/
|
|
4
|
+
export declare const CONTROL_INCREMENT_KEY_COMPONENT = "M4LControlIncrement";
|
|
5
|
+
/**
|
|
6
|
+
* Constante para la url del icono arrow up
|
|
7
|
+
*/
|
|
8
|
+
export declare const ICON_INCREMENT = "https://s3.amazonaws.com/static.made4labs/environments/d1/frontend/components/ControlIncrement/assets/icons/chevron_up_sm.svg";
|
|
9
|
+
/**
|
|
10
|
+
* Constante para la url del icono arrow down
|
|
11
|
+
*/
|
|
12
|
+
export declare const ICON_DECREMENT = "https://s3.amazonaws.com/static.made4labs/environments/d1/frontend/components/ControlIncrement/assets/icons/chevron_down_sm.svg";
|
|
13
|
+
/**
|
|
14
|
+
* Nombre de clase creado para aportar especificidad a los estilos del componente. Es usado para sobreescribir los estilos de MUI sin
|
|
15
|
+
* tener la necesidad de agregar valores en !important.
|
|
16
|
+
*/
|
|
17
|
+
export declare const CONTROL_INCREMENT_SPECIFY = "M4lclassCssSpecificity";
|
|
18
|
+
/**
|
|
19
|
+
* Cosntante para su uso en una clase para mas especificidad y evitar el uso de important
|
|
20
|
+
*/
|
|
21
|
+
export declare const BUTTON_UP = "button-up";
|
|
22
|
+
/**
|
|
23
|
+
* Cosntante para su uso en una clase para mas especificidad y evitar el uso de important
|
|
24
|
+
*/
|
|
25
|
+
export declare const BUTTON_DOWN = "button-down";
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export declare const RootStyled: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('../types').ControlIncrementOwnerState> & Record<string, unknown> & {
|
|
2
|
+
ownerState: Partial<import('../types').ControlIncrementOwnerState> & Record<string, unknown>;
|
|
3
|
+
}, Pick<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('react').HTMLAttributes<HTMLDivElement> | keyof import('react').ClassAttributes<HTMLDivElement>>, {}>;
|
|
4
|
+
export declare const IconButtonUpStyles: import('@emotion/styled').StyledComponent<Pick<import('../../mui_extended/IconButton/types').IconButtonProps, keyof import('../../mui_extended/IconButton/types').IconButtonProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('../types').ControlIncrementOwnerState> & Record<string, unknown> & {
|
|
5
|
+
ownerState: Partial<import('../types').ControlIncrementOwnerState> & Record<string, unknown>;
|
|
6
|
+
}, {}, {}>;
|
|
7
|
+
export declare const IconButtonDownStyles: import('@emotion/styled').StyledComponent<Pick<import('../../mui_extended/IconButton/types').IconButtonProps, keyof import('../../mui_extended/IconButton/types').IconButtonProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('../types').ControlIncrementOwnerState> & Record<string, unknown> & {
|
|
8
|
+
ownerState: Partial<import('../types').ControlIncrementOwnerState> & Record<string, unknown>;
|
|
9
|
+
}, {}, {}>;
|
|
10
|
+
export declare const ControlIncrementSkeletonStyled: import('@emotion/styled').StyledComponent<Pick<import('@mui/material').SkeletonOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
|
|
11
|
+
ref?: ((instance: HTMLSpanElement | 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<HTMLSpanElement> | null | undefined;
|
|
12
|
+
}, "height" | "width" | "animation" | "sx" | "classes" | "className" | "style" | "children" | "variant">, "color" | "content" | "height" | "translate" | "width" | "animation" | "sx" | "classes" | "title" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "hidden" | "id" | "lang" | "nonce" | "slot" | "spellCheck" | "style" | "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" | "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" | "children" | "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" | "onResize" | "onResizeCapture" | "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" | "ref" | "key" | "variant"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('../types').ControlIncrementOwnerState> & Record<string, unknown> & {
|
|
13
|
+
ownerState: Partial<import('../types').ControlIncrementOwnerState> & Record<string, unknown>;
|
|
14
|
+
}, {}, {}>;
|
package/components/ControlIncrement/stories/ControlClick/ControlIncrement.controlclick.stories.d.ts
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react/*';
|
|
2
|
+
import { ControlIncrement } from '../../ControlIncrement';
|
|
3
|
+
declare const meta: Meta<typeof ControlIncrement>;
|
|
4
|
+
type Story = StoryObj<typeof ControlIncrement>;
|
|
5
|
+
/**
|
|
6
|
+
* ControlIncrement en modo Base
|
|
7
|
+
*/
|
|
8
|
+
export declare const Base: Story;
|
|
9
|
+
/**
|
|
10
|
+
* ControlIncrement Tiene la particularidad de que cuando le des click a up o down este ejecute una funcion
|
|
11
|
+
*/
|
|
12
|
+
export declare const Click: Story;
|
|
13
|
+
export default meta;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react/*';
|
|
2
|
+
import { ControlIncrement } from '../../ControlIncrement';
|
|
3
|
+
declare const meta: Meta<typeof ControlIncrement>;
|
|
4
|
+
type Story = StoryObj<typeof ControlIncrement>;
|
|
5
|
+
/**
|
|
6
|
+
* ControlIncrement en modo Base
|
|
7
|
+
*/
|
|
8
|
+
export declare const Base: Story;
|
|
9
|
+
/**
|
|
10
|
+
* ControlIncrement cuando esta en modo default
|
|
11
|
+
*/
|
|
12
|
+
export declare const Default: Story;
|
|
13
|
+
/**
|
|
14
|
+
* ControlIncrement cuando esta en modo disabled
|
|
15
|
+
*/
|
|
16
|
+
export declare const Disabled: Story;
|
|
17
|
+
export default meta;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react/*';
|
|
2
|
+
import { ControlIncrement } from '../../ControlIncrement';
|
|
3
|
+
declare const meta: Meta<typeof ControlIncrement>;
|
|
4
|
+
type Story = StoryObj<typeof ControlIncrement>;
|
|
5
|
+
/**
|
|
6
|
+
* ControlIncrement en modo Base
|
|
7
|
+
*/
|
|
8
|
+
export declare const Base: Story;
|
|
9
|
+
/**
|
|
10
|
+
* CrontrolIncrement cuando esta en el sizes de small
|
|
11
|
+
*/
|
|
12
|
+
export declare const SizesSmall: Story;
|
|
13
|
+
/**
|
|
14
|
+
* CrontrolIncrement cuando esta en el sizes de medium
|
|
15
|
+
*/
|
|
16
|
+
export declare const SizesMedium: Story;
|
|
17
|
+
/**
|
|
18
|
+
* ControlIncrement cuando esta en modo Skeleton
|
|
19
|
+
*/
|
|
20
|
+
export declare const skeletonMode: Story;
|
|
21
|
+
export default meta;
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { PaletteColor, Theme } from '@mui/material/styles';
|
|
2
|
+
import { OverridesStyleRules } from '@mui/material/styles/overrides';
|
|
3
|
+
import { ComponentPalletColor, Sizes } from '@m4l/styles';
|
|
4
|
+
import { ControlIncrementSlots } from './slots/ControlIncrementEnum';
|
|
5
|
+
import { CONTROL_INCREMENT_KEY_COMPONENT } from './constants';
|
|
6
|
+
/**
|
|
7
|
+
* Interfaz que define las propiedades del componente `ControlIncrement`.
|
|
8
|
+
*/
|
|
9
|
+
export interface ControlIncrementProps {
|
|
10
|
+
/**
|
|
11
|
+
* Tamaño del componente. Acepta valores: 'small', 'medium' o 'large'.
|
|
12
|
+
*/
|
|
13
|
+
sizes?: Sizes;
|
|
14
|
+
/**
|
|
15
|
+
* Color del componente. Solo se acepta el valor 'default'.
|
|
16
|
+
*/
|
|
17
|
+
color?: Extract<ComponentPalletColor, 'default'>;
|
|
18
|
+
/**
|
|
19
|
+
* Indica si el componente está deshabilitado.
|
|
20
|
+
*/
|
|
21
|
+
disabled?: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* Función que se ejecuta cuando se acciona el IconButton superior.
|
|
24
|
+
*/
|
|
25
|
+
onChangeUp: () => void;
|
|
26
|
+
/**
|
|
27
|
+
* Función que se ejecuta cuando se acciona el IconButton inferior.
|
|
28
|
+
*/
|
|
29
|
+
onChangeDown: () => void;
|
|
30
|
+
/**
|
|
31
|
+
* Clase CSS adicional para aplicar estilos personalizados al componente.
|
|
32
|
+
*/
|
|
33
|
+
className?: string;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Interfaz que define el estado propietario de `ControlIncrement`, excluyendo algunas propiedades
|
|
37
|
+
* del componente base y añadiendo una propiedad de paletteColor.
|
|
38
|
+
*/
|
|
39
|
+
export interface ControlIncrementOwnerState extends Omit<ControlIncrementProps, 'handleButtonChange' | 'setMouseDownDirection' | 'onChangeUp' | 'onChangeDown'> {
|
|
40
|
+
/**
|
|
41
|
+
* Color de la paleta utilizado para el componente.
|
|
42
|
+
*/
|
|
43
|
+
paletteColor: PaletteColor;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Tipo que representa las claves de los slots del componente `ControlIncrement`.
|
|
47
|
+
* Este tipo se genera a partir de las claves del objeto `ControlIncrementSlots`.
|
|
48
|
+
*/
|
|
49
|
+
export type ControlIncrementSlotsType = keyof typeof ControlIncrementSlots;
|
|
50
|
+
/**
|
|
51
|
+
* Define los estilos personalizados para el componente `ControlIncrement`.
|
|
52
|
+
*
|
|
53
|
+
* Este tipo se utiliza para sobrescribir las reglas de estilo (OverridesStyleRules) aplicables a los slots del componente.
|
|
54
|
+
* @see OverridesStyleRules
|
|
55
|
+
*/
|
|
56
|
+
export type ControlIncrementStyles = Partial<OverridesStyleRules<ControlIncrementSlots, typeof CONTROL_INCREMENT_KEY_COMPONENT, Theme> | undefined> | undefined;
|
|
@@ -6,8 +6,8 @@ export declare function getDataGridUtilityClass(slot: string): string;
|
|
|
6
6
|
* TODO: Documentar
|
|
7
7
|
*/
|
|
8
8
|
export declare const dataGridUtilityClasses: (ownerState: OwnerState) => {
|
|
9
|
-
actions: string;
|
|
10
9
|
root: string;
|
|
10
|
+
actions: string;
|
|
11
11
|
rowsCount: string;
|
|
12
12
|
rowsCountLabel: string;
|
|
13
13
|
rowsCountValue: string;
|
|
@@ -57,7 +57,7 @@ export declare const PopoverMenuStyled: import('@emotion/styled').StyledComponen
|
|
|
57
57
|
}, {}, {}>;
|
|
58
58
|
export declare const PopoverMenuItemStyled: import('@emotion/styled').StyledComponent<Pick<import('@mui/material').MenuItemOwnProps & Omit<import('@mui/material').ButtonBaseOwnProps, "classes"> & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & {
|
|
59
59
|
ref?: ((instance: HTMLLIElement | 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<HTMLLIElement> | null | undefined;
|
|
60
|
-
}, "
|
|
60
|
+
}, "disabled" | "sx" | "classes" | "autoFocus" | "className" | "style" | "tabIndex" | "children" | "divider" | "action" | "dense" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "selected" | "disableGutters">, "color" | "content" | "translate" | "disabled" | "sx" | "classes" | "title" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "hidden" | "id" | "lang" | "nonce" | "slot" | "spellCheck" | "style" | "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" | "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" | "children" | "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" | "onResize" | "onResizeCapture" | "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" | "ref" | "divider" | "action" | "dense" | "key" | "value" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "selected" | "disableGutters"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('../types').DynamicFilterOwnerState> & Record<string, unknown> & {
|
|
61
61
|
ownerState: Partial<import('../types').DynamicFilterOwnerState> & Record<string, unknown>;
|
|
62
62
|
}, {}, {}>;
|
|
63
63
|
export declare const PopoverMenuItemIconStyled: import('@emotion/styled').StyledComponent<Pick<import('../../Icon').IconProps, keyof import('../../Icon').IconProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('../types').DynamicFilterOwnerState> & Record<string, unknown> & {
|
|
@@ -54,7 +54,7 @@ export declare const PopoverMenuStyled: import('@emotion/styled').StyledComponen
|
|
|
54
54
|
}, {}, {}>;
|
|
55
55
|
export declare const PopoverMenuItemStyled: import('@emotion/styled').StyledComponent<Pick<import('@mui/material').MenuItemOwnProps & Omit<import('@mui/material').ButtonBaseOwnProps, "classes"> & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & {
|
|
56
56
|
ref?: ((instance: HTMLLIElement | 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<HTMLLIElement> | null | undefined;
|
|
57
|
-
}, "
|
|
57
|
+
}, "disabled" | "sx" | "classes" | "autoFocus" | "className" | "style" | "tabIndex" | "children" | "divider" | "action" | "dense" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "selected" | "disableGutters">, "color" | "content" | "translate" | "disabled" | "sx" | "classes" | "title" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "autoCapitalize" | "autoFocus" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "enterKeyHint" | "hidden" | "id" | "lang" | "nonce" | "slot" | "spellCheck" | "style" | "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" | "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" | "children" | "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" | "onResize" | "onResizeCapture" | "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" | "ref" | "divider" | "action" | "dense" | "key" | "value" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "selected" | "disableGutters"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('../types').DynamicSortOwnerState> & Record<string, unknown> & {
|
|
58
58
|
ownerState: Partial<import('../types').DynamicSortOwnerState> & Record<string, unknown>;
|
|
59
59
|
}, {}, {}>;
|
|
60
60
|
export declare const PopoverMenuItemIconStyled: import('@emotion/styled').StyledComponent<Pick<import('../../Icon').IconProps, keyof import('../../Icon').IconProps> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme> & Partial<import('../types').DynamicSortOwnerState> & Record<string, unknown> & {
|
|
@@ -3,5 +3,5 @@ export declare const gridLayoutClasses: GridLayoutClasses;
|
|
|
3
3
|
/**
|
|
4
4
|
* TODO: Documentar
|
|
5
5
|
*/
|
|
6
|
-
export declare const useUtilityClasses: () => Record<"root" | "
|
|
6
|
+
export declare const useUtilityClasses: () => Record<"root" | "static" | "invisible" | "colapsed" | "resizing" | "dragging" | "gridItemRoot" | "gridItemPlaceholder" | "gridItemFreeMove" | "maximizeMe" | "maximizeOther" | "resizeHide" | "cssTransforms", string>;
|
|
7
7
|
export type Classes = ReturnType<typeof useUtilityClasses>;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
2
|
import { T as TypographyStyled } from "./slots/HelperErrorSlots.js";
|
|
3
3
|
const HelperError = (props) => {
|
|
4
|
-
const { message = "", skeletonWidth } = props;
|
|
4
|
+
const { message = "", skeletonWidth, className } = props;
|
|
5
5
|
return /* @__PURE__ */ jsx(
|
|
6
6
|
TypographyStyled,
|
|
7
7
|
{
|
|
8
|
+
className,
|
|
8
9
|
ownerState: {},
|
|
9
10
|
variant: "body",
|
|
10
11
|
skeletonWidth,
|
|
@@ -12,6 +12,10 @@ export interface HelperErrorProps extends Pick<TypographyProps, 'skeletonWidth'>
|
|
|
12
12
|
* Mensaje que se visualiza en el componente HelperError.
|
|
13
13
|
*/
|
|
14
14
|
message: string | undefined;
|
|
15
|
+
/**
|
|
16
|
+
* Propiedad que permite administrar estilos para su uso en los slots
|
|
17
|
+
*/
|
|
18
|
+
className?: string;
|
|
15
19
|
}
|
|
16
20
|
/**
|
|
17
21
|
* Representa el estado del componente HelperError, incluyendo todas las propiedades de HelperErrorProps.
|
|
@@ -2,4 +2,7 @@ import { IconProps } from './types';
|
|
|
2
2
|
/**
|
|
3
3
|
* Provee de un medio por el cual se carga un icono svg en la plataforma web, aporta su versión provisional de carga en red.
|
|
4
4
|
*/
|
|
5
|
+
/**
|
|
6
|
+
* TODO: Documentar
|
|
7
|
+
*/
|
|
5
8
|
export declare const Icon: (props: IconProps) => import("react/jsx-runtime").JSX.Element;
|
package/components/Icon/Icon.js
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { T as TEST_PROP_ID } from "../../test/constants_no_mock.js";
|
|
3
|
+
import { g as getNameDataTestId } from "../../test/getNameDataTestId.js";
|
|
4
4
|
import { I as ICON_PREFIX } from "./constants.js";
|
|
5
5
|
import { u as useComponentSize } from "../../hooks/useComponentSize/useComponentSize.js";
|
|
6
|
-
import { T as TooltipStyled, R as RootStyled, I as IconStyled
|
|
6
|
+
import { T as TooltipStyled, R as RootStyled, I as IconStyled } from "./slots/IconSlots.js";
|
|
7
7
|
import { I as IconSlots } from "./slots/IconEnum.js";
|
|
8
8
|
const Icon = (props) => {
|
|
9
9
|
const {
|
|
10
10
|
src,
|
|
11
|
-
size = "
|
|
11
|
+
size = "small",
|
|
12
12
|
rotationAngle,
|
|
13
13
|
tooltipContent,
|
|
14
|
+
securityArea,
|
|
14
15
|
color = "text.primary",
|
|
15
16
|
className,
|
|
16
17
|
placement = "bottom",
|
|
@@ -18,56 +19,72 @@ const Icon = (props) => {
|
|
|
18
19
|
disabled
|
|
19
20
|
} = props;
|
|
20
21
|
const { currentSize } = useComponentSize(size);
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
TooltipStyled,
|
|
33
|
-
{
|
|
34
|
-
title: tooltipContent,
|
|
35
|
-
ownerState: { ...ownerState },
|
|
36
|
-
placement,
|
|
37
|
-
...getPropDataTestId(ICON_PREFIX, IconSlots.tooltip, instaceDataTestId),
|
|
38
|
-
children: /* @__PURE__ */ jsx(
|
|
39
|
-
RootStyled,
|
|
40
|
-
{
|
|
41
|
-
className,
|
|
42
|
-
ownerState: { ...ownerState },
|
|
43
|
-
...getPropDataTestId(ICON_PREFIX, IconSlots.root, instaceDataTestId),
|
|
44
|
-
children: /* @__PURE__ */ jsx(
|
|
45
|
-
IconStyled,
|
|
46
|
-
{
|
|
47
|
-
ownerState: { ...ownerState },
|
|
48
|
-
...getPropDataTestId(ICON_PREFIX, IconSlots.icon, instaceDataTestId)
|
|
49
|
-
}
|
|
50
|
-
)
|
|
51
|
-
}
|
|
22
|
+
return /* @__PURE__ */ jsx(Fragment, { children: tooltipContent ? /* @__PURE__ */ jsx(
|
|
23
|
+
TooltipStyled,
|
|
24
|
+
{
|
|
25
|
+
title: tooltipContent,
|
|
26
|
+
ownerState: {},
|
|
27
|
+
placement,
|
|
28
|
+
...process.env.NODE_ENV !== "production" ? {
|
|
29
|
+
[TEST_PROP_ID]: getNameDataTestId(
|
|
30
|
+
ICON_PREFIX,
|
|
31
|
+
IconSlots.tooltip,
|
|
32
|
+
instaceDataTestId
|
|
52
33
|
)
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
34
|
+
} : {},
|
|
35
|
+
children: /* @__PURE__ */ jsx(
|
|
36
|
+
RootStyled,
|
|
37
|
+
{
|
|
38
|
+
className,
|
|
39
|
+
ownerState: { securityArea, size: currentSize },
|
|
40
|
+
...process.env.NODE_ENV !== "production" ? {
|
|
41
|
+
[TEST_PROP_ID]: getNameDataTestId(ICON_PREFIX, IconSlots.root, instaceDataTestId)
|
|
42
|
+
} : {},
|
|
43
|
+
children: /* @__PURE__ */ jsx(
|
|
44
|
+
IconStyled,
|
|
45
|
+
{
|
|
46
|
+
ownerState: {
|
|
47
|
+
src,
|
|
48
|
+
rotationAngle,
|
|
49
|
+
size: currentSize,
|
|
50
|
+
disabled,
|
|
51
|
+
color
|
|
52
|
+
},
|
|
53
|
+
...process.env.NODE_ENV !== "production" ? {
|
|
54
|
+
[TEST_PROP_ID]: getNameDataTestId(
|
|
55
|
+
ICON_PREFIX,
|
|
56
|
+
IconSlots.icon,
|
|
57
|
+
instaceDataTestId
|
|
58
|
+
)
|
|
59
|
+
} : {}
|
|
60
|
+
}
|
|
61
|
+
)
|
|
62
|
+
}
|
|
63
|
+
)
|
|
64
|
+
}
|
|
65
|
+
) : /* @__PURE__ */ jsx(
|
|
66
|
+
RootStyled,
|
|
67
|
+
{
|
|
68
|
+
className,
|
|
69
|
+
ownerState: { securityArea, size: currentSize },
|
|
70
|
+
...process.env.NODE_ENV !== "production" ? { [TEST_PROP_ID]: getNameDataTestId(ICON_PREFIX, IconSlots.root, instaceDataTestId) } : {},
|
|
71
|
+
children: /* @__PURE__ */ jsx(
|
|
72
|
+
IconStyled,
|
|
73
|
+
{
|
|
74
|
+
ownerState: {
|
|
75
|
+
src,
|
|
76
|
+
rotationAngle,
|
|
77
|
+
size: currentSize,
|
|
78
|
+
color,
|
|
79
|
+
disabled
|
|
80
|
+
},
|
|
81
|
+
...process.env.NODE_ENV !== "production" ? {
|
|
82
|
+
[TEST_PROP_ID]: getNameDataTestId(ICON_PREFIX, IconSlots.icon, instaceDataTestId)
|
|
83
|
+
} : {}
|
|
84
|
+
}
|
|
85
|
+
)
|
|
86
|
+
}
|
|
87
|
+
) });
|
|
71
88
|
};
|
|
72
89
|
export {
|
|
73
90
|
Icon as I
|