zuii 1.4.24 → 1.4.26
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/dist/components/Button/style/index.css +1 -1
- package/dist/components/Form/js/uppy.d.ts +74 -0
- package/dist/components/Form/js/uppy.js +106 -0
- package/dist/components/Form/react/FileInput.d.ts +9 -1
- package/dist/components/Form/react/FileInput.js +37 -53
- package/dist/components/Form/react/NumberInput.d.ts +14 -2
- package/dist/components/Form/react/NumberInput.js +53 -40
- package/dist/components/Form/react/index.js +1 -1
- package/dist/components/Form/style/index.css +1 -1
- package/dist/templates/Forms/Forms-elements.tsx +21 -2
- package/package.json +2 -1
|
@@ -16,7 +16,7 @@ export const FormsElements = () => {
|
|
|
16
16
|
const formData = new FormData(e.currentTarget);
|
|
17
17
|
console.log(Object.fromEntries(formData.entries()));
|
|
18
18
|
console.log(formData.getAll('selectMultiple[]'));
|
|
19
|
-
const tousLesFichiers = formData.getAll('file-
|
|
19
|
+
const tousLesFichiers = formData.getAll('file-upload[]');
|
|
20
20
|
console.log(tousLesFichiers); // Affiche [File, File]
|
|
21
21
|
|
|
22
22
|
const fileTest = formData.get('file-test');
|
|
@@ -33,6 +33,7 @@ export const FormsElements = () => {
|
|
|
33
33
|
<Form.Control id="search" type="search" placeholder="Enter search" name="search" icon="icon-search" />
|
|
34
34
|
<Form.Control id="email" type="email" placeholder="Enter email" name="email" icon="icon-at-sign" />
|
|
35
35
|
<Form.Control id="number" type="number" placeholder="Enter number" name="number" icon="icon-number" />
|
|
36
|
+
<Form.Number id="number-button" placeholder="Enter number" name="number-button" onChange={(val) => console.log(val)} step={1} min={0} max={10} required={true} className='fees-field__input' />
|
|
36
37
|
{/* <Form.File id="file-simple" label="Upload simple" name="file_simple" />
|
|
37
38
|
<Form.File
|
|
38
39
|
id="simple-upload"
|
|
@@ -53,6 +54,25 @@ export const FormsElements = () => {
|
|
|
53
54
|
lang='fr'
|
|
54
55
|
name="file-dashboard"
|
|
55
56
|
/>
|
|
57
|
+
<Form.File
|
|
58
|
+
restrictions={{ maxNumberOfFiles: 5 }}
|
|
59
|
+
webcam={{
|
|
60
|
+
allowVideo: false
|
|
61
|
+
}}
|
|
62
|
+
lang='fr'
|
|
63
|
+
name="file-upload"
|
|
64
|
+
files={[
|
|
65
|
+
{
|
|
66
|
+
route: 'https://placehold.co/286x180.png',
|
|
67
|
+
options: {
|
|
68
|
+
method: 'GET',
|
|
69
|
+
headers: {
|
|
70
|
+
'Content-Type': 'multipart/form-data'
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
]}
|
|
75
|
+
/>
|
|
56
76
|
<Form.Check id="checkbox1" type="checkbox" label="Enter checkbox" name="checkbox" />
|
|
57
77
|
<Form.Check id="checkbox2" type="checkbox" label="Enter checkbox checked" name="checkbox" defaultChecked />
|
|
58
78
|
<Form.Check id="radio1" type="radio" label="Enter radio option 1" name="radio" defaultChecked />
|
|
@@ -109,7 +129,6 @@ export const FormsElements = () => {
|
|
|
109
129
|
<Form.Tel name='tel-test' nameFormat='tel-test-format' />
|
|
110
130
|
<Form.Control type="submit" value="Submit" />
|
|
111
131
|
|
|
112
|
-
<input type="file" name="file-test" id="file-test" />
|
|
113
132
|
</form>
|
|
114
133
|
|
|
115
134
|
</div>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "zuii",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.26",
|
|
4
4
|
"description": "Bibliothèque de composants UI légère, intuitive et modulaire pour les interfaces web modernes.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": {
|
|
@@ -65,6 +65,7 @@
|
|
|
65
65
|
"@uppy/image-editor": "^4.2.0",
|
|
66
66
|
"@uppy/locales": "^5.1.1",
|
|
67
67
|
"@uppy/react": "^5.2.0",
|
|
68
|
+
"@uppy/webcam": "^5.1.0",
|
|
68
69
|
"ag-grid-community": "^35.0.1",
|
|
69
70
|
"ag-grid-react": "^35.0.1",
|
|
70
71
|
"apca-w3": "^0.1.9",
|