react-input-material 0.0.349 → 0.0.354
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/components/Dummy.tsx +3 -3
- package/components/FileInput.js +1 -1
- package/components/FileInput.module.css +12 -24
- package/components/FileInput.styles.css +4 -4
- package/components/FileInput.tsx +16 -18
- package/components/GenericAnimate.module.css +3 -4
- package/components/GenericAnimate.styles.css +1 -1
- package/components/GenericInput.module.css +32 -45
- package/components/GenericInput.styles.css +2 -2
- package/components/GenericInput.tsx +1 -1
- package/components/Inputs.js +1 -1
- package/components/Inputs.module.css +10 -9
- package/components/Inputs.styles.css +3 -3
- package/components/Interval.js +1 -1
- package/components/Interval.module.css +16 -15
- package/components/Interval.styles.css +3 -3
- package/components/RequireableCheckbox.module.css +4 -4
- package/components/RequireableCheckbox.styles.css +1 -1
- package/index.js +1 -1
- package/index.styles.css +12 -12
- package/package.json +32 -16
- package/readme.md +38 -2
package/components/FileInput.tsx
CHANGED
|
@@ -19,7 +19,6 @@
|
|
|
19
19
|
// region imports
|
|
20
20
|
import {blobToBase64String, dataURLToBlob} from 'blob-util'
|
|
21
21
|
import Tools from 'clientnode'
|
|
22
|
-
import {FirstParameter} from 'clientnode/type'
|
|
23
22
|
import {
|
|
24
23
|
FocusEvent as ReactFocusEvent,
|
|
25
24
|
ForwardedRef,
|
|
@@ -28,7 +27,6 @@ import {
|
|
|
28
27
|
MouseEvent as ReactMouseEvent,
|
|
29
28
|
MutableRefObject,
|
|
30
29
|
ReactElement,
|
|
31
|
-
RefCallback,
|
|
32
30
|
SyntheticEvent,
|
|
33
31
|
useEffect,
|
|
34
32
|
useImperativeHandle,
|
|
@@ -46,7 +44,6 @@ import {
|
|
|
46
44
|
import {CircularProgress} from '@rmwc/circular-progress'
|
|
47
45
|
import {Theme} from '@rmwc/theme'
|
|
48
46
|
import {Typography} from '@rmwc/typography'
|
|
49
|
-
import {ComponentAdapter} from 'web-component-wrapper/type'
|
|
50
47
|
|
|
51
48
|
/*
|
|
52
49
|
"namedExport" version of css-loader:
|
|
@@ -78,11 +75,9 @@ import {
|
|
|
78
75
|
defaultFileInputProperties as defaultProperties,
|
|
79
76
|
defaultFileNameInputProperties,
|
|
80
77
|
FileInputAdapter as Adapter,
|
|
81
|
-
FileInputModel as Model,
|
|
82
78
|
FileInputModelState as ModelState,
|
|
83
79
|
FileInputProperties as Properties,
|
|
84
80
|
FileInputProps as Props,
|
|
85
|
-
FileInputState as State,
|
|
86
81
|
FileValue,
|
|
87
82
|
FileInputValueState as ValueState,
|
|
88
83
|
fileInputPropertyTypes as propertyTypes,
|
|
@@ -94,23 +89,26 @@ import {
|
|
|
94
89
|
} from '../type'
|
|
95
90
|
// endregion
|
|
96
91
|
// region constants
|
|
97
|
-
const imageContentTypeRegularExpression
|
|
98
|
-
'^image/(?:p?jpe?g|png|svg(?:\\+xml)?|vnd\\.microsoft\\.icon|gif|' +
|
|
99
|
-
'
|
|
92
|
+
const imageContentTypeRegularExpression = new RegExp(
|
|
93
|
+
'^image/(?:p?jpe?g|png|svg(?:\\+xml)?|vnd\\.microsoft\\.icon|gif|tiff|webp' +
|
|
94
|
+
'|vnd\\.wap\\.wbmp|x-(?:icon|jng|ms-bmp))$',
|
|
95
|
+
'i'
|
|
100
96
|
)
|
|
101
|
-
const textContentTypeRegularExpression
|
|
102
|
-
'^(?:application/xml)|' +
|
|
103
|
-
'
|
|
97
|
+
const textContentTypeRegularExpression = new RegExp(
|
|
98
|
+
'^(?:application/xml)|(?:text/(?:plain|x-ndpb[wy]html|(?:x-)?csv' +
|
|
99
|
+
'|x?html?|xml))$',
|
|
100
|
+
'i'
|
|
104
101
|
)
|
|
105
|
-
const representableTextContentTypeRegularExpression
|
|
102
|
+
const representableTextContentTypeRegularExpression =
|
|
106
103
|
// Plain version:
|
|
107
|
-
/^text\/plain$/
|
|
104
|
+
/^text\/plain$/i
|
|
108
105
|
// Rendered version:
|
|
109
|
-
//
|
|
110
|
-
const videoContentTypeRegularExpression
|
|
111
|
-
'^video/(?:(?:x-)?(?:x-)?webm|3gpp|mp2t|mp4|mpeg|quicktime|' +
|
|
112
|
-
'
|
|
113
|
-
'(?:application/(?:x-)?shockwave-flash)$'
|
|
106
|
+
// /^(application\/xml)|(text\/(plain|x?html?|xml))$/i
|
|
107
|
+
const videoContentTypeRegularExpression = new RegExp(
|
|
108
|
+
'^video/(?:(?:x-)?(?:x-)?webm|3gpp|mp2t|mp4|mpeg|quicktime|(?:x-)?flv' +
|
|
109
|
+
'|(?:x-)?m4v|(?:x-)mng|x-ms-as|x-ms-wmv|x-msvideo)' +
|
|
110
|
+
'|(?:application/(?:x-)?shockwave-flash)$',
|
|
111
|
+
'i'
|
|
114
112
|
)
|
|
115
113
|
// endregion
|
|
116
114
|
// region helper
|
|
@@ -22,13 +22,13 @@ endregion */
|
|
|
22
22
|
.generic-animate-appear,
|
|
23
23
|
.generic-animate-enter,
|
|
24
24
|
.generic-animate-exit-active {
|
|
25
|
-
opacity: 0
|
|
25
|
+
opacity: 0%;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
.generic-animate-appear-active,
|
|
29
29
|
.generic-animate-enter-active,
|
|
30
30
|
.generic-animate-exit {
|
|
31
|
-
opacity:
|
|
31
|
+
opacity: 100%;
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
.generic-animate-appear-active,
|
|
@@ -36,13 +36,12 @@ endregion */
|
|
|
36
36
|
.generic-animate-exit-active {
|
|
37
37
|
transition: opacity 200ms ease-in;
|
|
38
38
|
}
|
|
39
|
-
|
|
40
39
|
/*
|
|
41
40
|
NOTE: If this class is not defined dedicated due to some pre-processing
|
|
42
41
|
animations gets broken.
|
|
43
42
|
*/
|
|
44
43
|
.generic-animate-exit-active {
|
|
45
|
-
opacity: 0
|
|
44
|
+
opacity: 0%;
|
|
46
45
|
}
|
|
47
46
|
|
|
48
47
|
.generic-animate-exit-done {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* !/usr/bin/env css
|
|
2
|
-
-*- coding: utf-8 -*- */.generic-animate,.generic-animate__list-wrapper,.generic-animate__wrapper{visibility:visible}.generic-animate-appear,.generic-animate-enter,.generic-animate-exit-active{opacity:0}.generic-animate-appear-active,.generic-animate-enter-active,.generic-animate-exit{opacity:1}.generic-animate-appear-active,.generic-animate-enter-active,.generic-animate-exit-active{-webkit-transition:opacity .2s ease-in;transition:opacity .2s ease-in}.generic-animate-exit-active{opacity:0}.generic-animate-exit-done{display:none}
|
|
2
|
+
-*- coding: utf-8 -*- */.generic-animate,.generic-animate__list-wrapper,.generic-animate__wrapper{visibility:visible}.generic-animate-appear,.generic-animate-enter,.generic-animate-exit-active{opacity:0}.generic-animate-appear-active,.generic-animate-enter-active,.generic-animate-exit{opacity:1%}.generic-animate-appear-active,.generic-animate-enter-active,.generic-animate-exit-active{-webkit-transition:opacity .2s ease-in;transition:opacity .2s ease-in}.generic-animate-exit-active{opacity:0}.generic-animate-exit-done{display:none}
|
|
@@ -10,77 +10,64 @@ This library written by Torben Sickert stand under a creative commons naming
|
|
|
10
10
|
3.0 unported license. See https://creativecommons.org/licenses/by/3.0/deed.de
|
|
11
11
|
endregion */
|
|
12
12
|
/* region imports */
|
|
13
|
-
|
|
14
13
|
/*
|
|
15
|
-
|
|
16
14
|
CSS-Modules:
|
|
17
15
|
|
|
18
|
-
import
|
|
16
|
+
import "@rmwc/circular-progress/styles";
|
|
19
17
|
|
|
20
|
-
import
|
|
18
|
+
import "@rmwc/formfield/styles";
|
|
21
19
|
|
|
22
|
-
import
|
|
20
|
+
import "@rmwc/icon-button/styles";
|
|
23
21
|
|
|
24
|
-
import
|
|
22
|
+
import "@rmwc/select/styles";
|
|
25
23
|
|
|
26
|
-
import
|
|
24
|
+
import "@rmwc/textfield/styles";
|
|
27
25
|
|
|
28
|
-
import
|
|
26
|
+
import "@rmwc/theme/styles";
|
|
29
27
|
|
|
30
|
-
import
|
|
28
|
+
import "@rmwc/tooltip/styles";
|
|
31
29
|
|
|
32
|
-
import
|
|
33
|
-
|
|
34
|
-
*/
|
|
35
|
-
|
|
36
|
-
/*
|
|
30
|
+
import "@rmwc/typography/styles";
|
|
37
31
|
|
|
38
32
|
Redundant:
|
|
39
33
|
|
|
40
|
-
@import
|
|
34
|
+
@import "@material/ripple/dist/mdc.ripple.css";
|
|
41
35
|
|
|
42
|
-
@import
|
|
43
|
-
@import
|
|
44
|
-
@import
|
|
45
|
-
@import
|
|
36
|
+
@import "@material/floating-label/dist/mdc.floating-label.css";
|
|
37
|
+
@import "@material/line-ripple/dist/mdc.line-ripple.css";
|
|
38
|
+
@import "@material/notched-outline/dist/mdc.notched-outline.css";
|
|
39
|
+
@import "@material/ripple/dist/mdc.ripple.css";
|
|
46
40
|
|
|
47
|
-
@import
|
|
48
|
-
|
|
49
|
-
*/
|
|
50
|
-
|
|
51
|
-
/*
|
|
41
|
+
@import "@rmwc/icon/icon.css";
|
|
52
42
|
|
|
53
43
|
Plain CSS:
|
|
54
|
-
|
|
55
44
|
*/
|
|
56
|
-
@import
|
|
57
|
-
|
|
58
|
-
@import '@material/form-field/dist/mdc.form-field.css';
|
|
59
|
-
|
|
60
|
-
@import '@material/icon-button/dist/mdc.icon-button.css';
|
|
61
|
-
@import '@material/ripple/dist/mdc.ripple.css';
|
|
62
|
-
@import '@rmwc/icon/icon.css';
|
|
45
|
+
@import "@rmwc/circular-progress/circular-progress.css";
|
|
63
46
|
|
|
64
|
-
@import
|
|
65
|
-
@import '@material/line-ripple/dist/mdc.line-ripple.css';
|
|
66
|
-
@import '@material/list/dist/mdc.list.css';
|
|
67
|
-
@import '@material/menu/dist/mdc.menu.css';
|
|
68
|
-
@import '@material/menu-surface/dist/mdc.menu-surface.css';
|
|
69
|
-
@import '@material/notched-outline/dist/mdc.notched-outline.css';
|
|
47
|
+
@import "@material/form-field/dist/mdc.form-field.css";
|
|
70
48
|
|
|
71
|
-
@import
|
|
72
|
-
@import
|
|
49
|
+
@import "@material/icon-button/dist/mdc.icon-button.css";
|
|
50
|
+
@import "@material/ripple/dist/mdc.ripple.css";
|
|
51
|
+
@import "@rmwc/icon/icon.css";
|
|
73
52
|
|
|
74
|
-
@import
|
|
53
|
+
@import "@material/floating-label/dist/mdc.floating-label.css";
|
|
54
|
+
@import "@material/line-ripple/dist/mdc.line-ripple.css";
|
|
55
|
+
@import "@material/list/dist/mdc.list.css";
|
|
56
|
+
@import "@material/menu/dist/mdc.menu.css";
|
|
57
|
+
@import "@material/menu-surface/dist/mdc.menu-surface.css";
|
|
58
|
+
@import "@material/notched-outline/dist/mdc.notched-outline.css";
|
|
75
59
|
|
|
76
|
-
@import
|
|
77
|
-
@import
|
|
60
|
+
@import "@material/select/dist/mdc.select.css";
|
|
61
|
+
@import "@rmwc/select/select.css";
|
|
78
62
|
|
|
79
|
-
@import
|
|
63
|
+
@import "@material/textfield/dist/mdc.textfield.css";
|
|
80
64
|
|
|
81
|
-
@import
|
|
65
|
+
@import "@material/theme/dist/mdc.theme.css";
|
|
66
|
+
@import "@rmwc/theme/theme.css";
|
|
82
67
|
|
|
68
|
+
@import "@rmwc/tooltip/tooltip.css";
|
|
83
69
|
|
|
70
|
+
@import "@material/typography/dist/mdc.typography.css";
|
|
84
71
|
/* endregion */
|
|
85
72
|
.generic-input {
|
|
86
73
|
display: block;
|