diff --git a/package.json b/package.json index c7e450d..ecb11de 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@netservice/astrea-react-ds", - "version": "2.1.0", + "version": "2.2.0", "main": "dist/umd/index.min.js", "module": "dist/esm/index.js", "license": "Apache-2.0", @@ -49,7 +49,8 @@ }, "dependencies": { "@fontsource/titillium-web": "^4.5.9", - "@storybook/test": "^8.1.6" + "@storybook/test": "^8.1.6", + "date-fns": "2.29.3" }, "peerDependencies": { "@emotion/react": "^11.11.1", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 5fa94ef..b033854 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -11,6 +11,9 @@ dependencies: '@storybook/test': specifier: ^8.1.6 version: 8.1.6(@types/jest@29.5.12)(jest@29.7.0) + date-fns: + specifier: 2.29.3 + version: 2.29.3 devDependencies: '@babel/cli': @@ -48,7 +51,7 @@ devDependencies: version: 5.15.15(@emotion/react@11.11.4)(@emotion/styled@11.11.5)(@types/react@18.3.3)(react@18.3.1) '@mui/x-date-pickers': specifier: ^6.12.1 - version: 6.20.1(@emotion/react@11.11.4)(@emotion/styled@11.11.5)(@mui/material@5.15.19)(@mui/system@5.15.15)(@types/react@18.3.3)(moment@2.30.1)(react-dom@18.3.1)(react@18.3.1) + version: 6.20.1(@emotion/react@11.11.4)(@emotion/styled@11.11.5)(@mui/material@5.15.19)(@mui/system@5.15.15)(@types/react@18.3.3)(date-fns@2.29.3)(moment@2.30.1)(react-dom@18.3.1)(react@18.3.1) '@rollup/plugin-alias': specifier: ^5.1.0 version: 5.1.0(rollup@3.29.4) @@ -2579,7 +2582,7 @@ packages: react-is: 18.3.1 dev: true - /@mui/x-date-pickers@6.20.1(@emotion/react@11.11.4)(@emotion/styled@11.11.5)(@mui/material@5.15.19)(@mui/system@5.15.15)(@types/react@18.3.3)(moment@2.30.1)(react-dom@18.3.1)(react@18.3.1): + /@mui/x-date-pickers@6.20.1(@emotion/react@11.11.4)(@emotion/styled@11.11.5)(@mui/material@5.15.19)(@mui/system@5.15.15)(@types/react@18.3.3)(date-fns@2.29.3)(moment@2.30.1)(react-dom@18.3.1)(react@18.3.1): resolution: {integrity: sha512-DKUzDpHTrP5f6BPclWAs46zrOgDZ+4ewizCO0qbVXMC6rYrZh+ElNeF396GqdZBfrt3ATEyAEa1CW2mceK4wng==} engines: {node: '>=14.0.0'} peerDependencies: @@ -2625,6 +2628,7 @@ packages: '@mui/utils': 5.15.14(@types/react@18.3.3)(react@18.3.1) '@types/react-transition-group': 4.4.10 clsx: 2.1.1 + date-fns: 2.29.3 moment: 2.30.1 prop-types: 15.8.1 react: 18.3.1 @@ -5893,6 +5897,10 @@ packages: is-data-view: 1.0.1 dev: true + /date-fns@2.29.3: + resolution: {integrity: sha512-dDCnyH2WnnKusqvZZ6+jA1O51Ibt8ZMRNkDZdyAyK4YfbDwa/cEmuztzG5pk6hqlp9aSBPYcjOlktquahGwGeA==} + engines: {node: '>=0.11'} + /debug@2.6.9: resolution: {integrity: sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==} peerDependencies: diff --git a/src/components/components/NsInputFile.tsx b/src/components/components/NsInputFile.tsx index 2b12b86..eb4f2db 100644 --- a/src/components/components/NsInputFile.tsx +++ b/src/components/components/NsInputFile.tsx @@ -8,7 +8,7 @@ export interface NsInputFileProps { onChange?: (e: any) => void; } -export function NsInputFile({ onChange, value }: NsInputFileProps) { +export function NsInputFile({ onChange, value, ...rest }: NsInputFileProps) { const inputRef = useRef(null); const [selectedFile, setSelectedFile] = useState(value); const { t } = useTranslation(); @@ -50,6 +50,7 @@ export function NsInputFile({ onChange, value }: NsInputFileProps) { id={inputId} style={{ display: 'none' }} ref={inputRef} + {...rest} />