@arquimedes.co/eureka-forms 3.0.4-refactor → 3.0.6-refactor
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.
|
@@ -77,6 +77,10 @@ const StyledDialog = styled(MuiDialog)(({ theme }) => ({
|
|
|
77
77
|
borderRadius: '5px',
|
|
78
78
|
backgroundColor: 'transparent',
|
|
79
79
|
},
|
|
80
|
+
'& .Erk-MuiPickersLayout-root': {
|
|
81
|
+
display: 'flex',
|
|
82
|
+
flexDirection: 'column',
|
|
83
|
+
},
|
|
80
84
|
'& .Erk-MuiDialogActions-root': {
|
|
81
85
|
'& .Erk-MuiButtonBase-root': { fontWeight: 700 },
|
|
82
86
|
},
|
|
@@ -98,7 +102,7 @@ const StyledDay = styled(MuiPickerDay)(({ theme }) => ({
|
|
|
98
102
|
}));
|
|
99
103
|
function CustomDatePicker({ error, required, disabled, readOnly, helperText, size = 'small', pickTime = false, ...others }) {
|
|
100
104
|
if (pickTime) {
|
|
101
|
-
return (_jsx(StyledDateTimePicker, { ampm: true, ...others, disabled: disabled ?? readOnly, defaultValue: required ? new Date() : undefined, showDaysOutsideCurrentMonth: true, slotProps: {
|
|
105
|
+
return (_jsx(StyledDateTimePicker, { ampm: true, reduceAnimations: true, ...others, disabled: disabled ?? readOnly, defaultValue: required ? new Date() : undefined, showDaysOutsideCurrentMonth: true, slotProps: {
|
|
102
106
|
actionBar: {
|
|
103
107
|
actions: ['clear', 'accept'],
|
|
104
108
|
},
|
|
@@ -159,7 +163,7 @@ function CustomDatePicker({ error, required, disabled, readOnly, helperText, siz
|
|
|
159
163
|
} }));
|
|
160
164
|
}
|
|
161
165
|
else {
|
|
162
|
-
return (_jsx(StyledDatePicker, { ...others, readOnly: readOnly, disabled: disabled ?? readOnly, defaultValue: required ? new Date() : undefined, showDaysOutsideCurrentMonth: true, views: ['year', 'month', 'day'], slotProps: {
|
|
166
|
+
return (_jsx(StyledDatePicker, { ...others, reduceAnimations: true, readOnly: readOnly, disabled: disabled ?? readOnly, defaultValue: required ? new Date() : undefined, showDaysOutsideCurrentMonth: true, views: ['year', 'month', 'day'], slotProps: {
|
|
163
167
|
actionBar: {
|
|
164
168
|
actions: ['clear', 'accept'],
|
|
165
169
|
},
|
|
@@ -7,6 +7,7 @@ import es from 'i18n-iso-countries/langs/es.json';
|
|
|
7
7
|
import { InputAdornment, Select, styled } from '@mui/material';
|
|
8
8
|
import { MenuItem } from '@mui/material';
|
|
9
9
|
import { StyledTextField } from '../ErkTextField/ErkTextField';
|
|
10
|
+
import { useAppSelector } from '../../hooks';
|
|
10
11
|
isoCountries.registerLocale(es);
|
|
11
12
|
const StyledSelect = styled(Select)(({ theme }) => ({
|
|
12
13
|
padding: 0,
|
|
@@ -29,7 +30,8 @@ const StyledSelect = styled(Select)(({ theme }) => ({
|
|
|
29
30
|
borderBottom: 'none',
|
|
30
31
|
},
|
|
31
32
|
}));
|
|
32
|
-
function CustomPhoneInput({ value, onChange, inputRef, readOnly = false, disabled = false,
|
|
33
|
+
function CustomPhoneInput({ value, onChange, inputRef, readOnly = false, disabled = false, ...others }) {
|
|
34
|
+
const defaultCountry = useAppSelector((state) => state.global.countryCode);
|
|
33
35
|
const { inputValue, handlePhoneValueChange, inputRef: phoneRef, country, setCountry, } = usePhoneInput({
|
|
34
36
|
value: '+' + value,
|
|
35
37
|
inputRef,
|
package/dist/index.lib.d.ts
CHANGED
package/dist/index.lib.js
CHANGED
package/package.json
CHANGED