@hh.ru/magritte-ui-upload 3.3.25 → 4.0.0
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/FileName.js +1 -1
- package/FileView.js +1 -1
- package/FileViewWithPreview.js +1 -1
- package/MultiUpload.js +1 -1
- package/SingleUpload.js +1 -1
- package/Upload.js +1 -1
- package/index.css +122 -115
- package/index.d.ts +0 -1
- package/index.js +1 -2
- package/index.js.map +1 -1
- package/index.mock.d.ts +0 -2
- package/index.mock.js +1 -3
- package/index.mock.js.map +1 -1
- package/package.json +11 -11
- package/upload-CvvnKTGS.js +5 -0
- package/upload-CvvnKTGS.js.map +1 -0
- package/upload-mR_dU6SQ.js +0 -5
- package/upload-mR_dU6SQ.js.map +0 -1
package/FileName.js
CHANGED
|
@@ -2,7 +2,7 @@ import './index.css';
|
|
|
2
2
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
3
3
|
import classnames from 'classnames';
|
|
4
4
|
|
|
5
|
-
var styles = {"file-name-body":"magritte-file-name-
|
|
5
|
+
var styles = {"file-name-body":"magritte-file-name-body___PTTMc_4-0-0","fileNameBody":"magritte-file-name-body___PTTMc_4-0-0","file-name-body_medium":"magritte-file-name-body_medium___sfmmq_4-0-0","fileNameBodyMedium":"magritte-file-name-body_medium___sfmmq_4-0-0","file-name":"magritte-file-name___ZSL2g_4-0-0","fileName":"magritte-file-name___ZSL2g_4-0-0"};
|
|
6
6
|
|
|
7
7
|
const parse = (file) => {
|
|
8
8
|
const name = file.name;
|
package/FileView.js
CHANGED
|
@@ -9,7 +9,7 @@ import { FileName } from './FileName.js';
|
|
|
9
9
|
import { getUploadIcon, bytes2mb } from './utils.js';
|
|
10
10
|
import 'classnames';
|
|
11
11
|
|
|
12
|
-
var styles = {"file-info-body":"magritte-file-info-
|
|
12
|
+
var styles = {"file-info-body":"magritte-file-info-body___HmfXd_4-0-0","fileInfoBody":"magritte-file-info-body___HmfXd_4-0-0","file-info-and-controls":"magritte-file-info-and-controls___61iyY_4-0-0","fileInfoAndControls":"magritte-file-info-and-controls___61iyY_4-0-0","file-info-container":"magritte-file-info-container___WFab8_4-0-0","fileInfoContainer":"magritte-file-info-container___WFab8_4-0-0","file-info":"magritte-file-info___HrqiB_4-0-0","fileInfo":"magritte-file-info___HrqiB_4-0-0","controls":"magritte-controls___WdH7A_4-0-0"};
|
|
13
13
|
|
|
14
14
|
const FileView = ({ uploadType, loadedFile, preview, renderFileInfo, onFileDelete, 'aria-label': ariaLabel, isLast = false, }) => {
|
|
15
15
|
const isLoading = Boolean(loadedFile?.loading);
|
package/FileViewWithPreview.js
CHANGED
|
@@ -12,7 +12,7 @@ import './FileName.js';
|
|
|
12
12
|
import 'classnames';
|
|
13
13
|
import 'react';
|
|
14
14
|
|
|
15
|
-
var styles = {"item":"magritte-item___vVDG-
|
|
15
|
+
var styles = {"item":"magritte-item___vVDG-_4-0-0"};
|
|
16
16
|
|
|
17
17
|
const FileViewWithPreview = ({ loadedFile, ...otherProps }) => {
|
|
18
18
|
const uploadType = getFileType(loadedFile.data.type);
|
package/MultiUpload.js
CHANGED
|
@@ -8,7 +8,7 @@ import { Placeholder } from './Placeholder.js';
|
|
|
8
8
|
import { useDropActions } from './useDropActions.js';
|
|
9
9
|
import { useDropButtons } from './useDropButtons.js';
|
|
10
10
|
import { getAvaliableFileTypes, getUploadIcon, DEFAULT_ACCEPT, RenderFileInfoDefault } from './utils.js';
|
|
11
|
-
import { s as styles } from './upload-
|
|
11
|
+
import { s as styles } from './upload-CvvnKTGS.js';
|
|
12
12
|
import './FileView.js';
|
|
13
13
|
import '@hh.ru/magritte-ui-avatar';
|
|
14
14
|
import '@hh.ru/magritte-ui-divider';
|
package/SingleUpload.js
CHANGED
|
@@ -14,7 +14,7 @@ import { useDropActions } from './useDropActions.js';
|
|
|
14
14
|
import { useDropButtons } from './useDropButtons.js';
|
|
15
15
|
import { useFilePreview } from './useFilePreview.js';
|
|
16
16
|
import { getAvaliableFileTypes, getUploadIcon, bytes2mb, DEFAULT_ACCEPT, RenderFileInfoDefault } from './utils.js';
|
|
17
|
-
import { s as styles } from './upload-
|
|
17
|
+
import { s as styles } from './upload-CvvnKTGS.js';
|
|
18
18
|
import '@hh.ru/magritte-ui-divider';
|
|
19
19
|
import '@hh.ru/magritte-ui-breakpoint';
|
|
20
20
|
import 'react';
|
package/Upload.js
CHANGED
|
@@ -20,7 +20,7 @@ import '@hh.ru/magritte-ui-breakpoint';
|
|
|
20
20
|
import '@hh.ru/magritte-ui-typography';
|
|
21
21
|
import './useDropActions.js';
|
|
22
22
|
import './useDropButtons.js';
|
|
23
|
-
import './upload-
|
|
23
|
+
import './upload-CvvnKTGS.js';
|
|
24
24
|
|
|
25
25
|
const Upload = ({ multiple, noDragEventsBubbling = true, ...uploadProps }) => {
|
|
26
26
|
if (multiple) {
|
package/index.css
CHANGED
|
@@ -1,178 +1,185 @@
|
|
|
1
1
|
:root{
|
|
2
|
-
--magritte-typography-label-2-regular-font-family-v22-
|
|
3
|
-
--magritte-typography-label-2-regular-font-weight-v22-
|
|
4
|
-
--magritte-typography-label-2-regular-line-height-v22-
|
|
5
|
-
--magritte-typography-label-2-regular-font-size-v22-
|
|
6
|
-
--magritte-typography-label-2-regular-letter-spacing-v22-
|
|
7
|
-
--magritte-typography-label-2-regular-text-indent-v22-
|
|
8
|
-
--magritte-typography-label-2-regular-text-transform-v22-
|
|
9
|
-
--magritte-typography-label-2-regular-text-decoration-v22-
|
|
10
|
-
}
|
|
11
|
-
.magritte-file-name-
|
|
2
|
+
--magritte-typography-label-2-regular-font-family-v22-1-0:"hh sans";
|
|
3
|
+
--magritte-typography-label-2-regular-font-weight-v22-1-0:400;
|
|
4
|
+
--magritte-typography-label-2-regular-line-height-v22-1-0:22px;
|
|
5
|
+
--magritte-typography-label-2-regular-font-size-v22-1-0:16px;
|
|
6
|
+
--magritte-typography-label-2-regular-letter-spacing-v22-1-0:0em;
|
|
7
|
+
--magritte-typography-label-2-regular-text-indent-v22-1-0:0px;
|
|
8
|
+
--magritte-typography-label-2-regular-text-transform-v22-1-0:none;
|
|
9
|
+
--magritte-typography-label-2-regular-text-decoration-v22-1-0:none;
|
|
10
|
+
}
|
|
11
|
+
.magritte-file-name-body___PTTMc_4-0-0{
|
|
12
12
|
display:flex;
|
|
13
13
|
width:100%;
|
|
14
14
|
overflow:hidden;
|
|
15
|
-
font-family:var(--magritte-typography-label-2-regular-font-family-v22-
|
|
16
|
-
font-weight:var(--magritte-typography-label-2-regular-font-weight-v22-
|
|
17
|
-
line-height:var(--magritte-typography-label-2-regular-line-height-v22-
|
|
18
|
-
font-size:var(--magritte-typography-label-2-regular-font-size-v22-
|
|
19
|
-
letter-spacing:var(--magritte-typography-label-2-regular-letter-spacing-v22-
|
|
20
|
-
text-indent:var(--magritte-typography-label-2-regular-text-indent-v22-
|
|
21
|
-
text-transform:var(--magritte-typography-label-2-regular-text-transform-v22-
|
|
22
|
-
text-decoration:var(--magritte-typography-label-2-regular-text-decoration-v22-
|
|
23
|
-
}
|
|
24
|
-
.magritte-file-name-
|
|
15
|
+
font-family:var(--magritte-typography-label-2-regular-font-family-v22-1-0);
|
|
16
|
+
font-weight:var(--magritte-typography-label-2-regular-font-weight-v22-1-0);
|
|
17
|
+
line-height:var(--magritte-typography-label-2-regular-line-height-v22-1-0);
|
|
18
|
+
font-size:var(--magritte-typography-label-2-regular-font-size-v22-1-0);
|
|
19
|
+
letter-spacing:var(--magritte-typography-label-2-regular-letter-spacing-v22-1-0);
|
|
20
|
+
text-indent:var(--magritte-typography-label-2-regular-text-indent-v22-1-0);
|
|
21
|
+
text-transform:var(--magritte-typography-label-2-regular-text-transform-v22-1-0);
|
|
22
|
+
text-decoration:var(--magritte-typography-label-2-regular-text-decoration-v22-1-0);
|
|
23
|
+
}
|
|
24
|
+
.magritte-file-name-body_medium___sfmmq_4-0-0{
|
|
25
25
|
justify-content:center;
|
|
26
26
|
}
|
|
27
|
-
.magritte-file-
|
|
27
|
+
.magritte-file-name___ZSL2g_4-0-0{
|
|
28
28
|
overflow:hidden;
|
|
29
29
|
text-overflow:ellipsis;
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
:root{
|
|
33
|
-
--magritte-typography-label-4-regular-font-family-v22-
|
|
34
|
-
--magritte-typography-label-4-regular-font-weight-v22-
|
|
35
|
-
--magritte-typography-label-4-regular-line-height-v22-
|
|
36
|
-
--magritte-typography-label-4-regular-font-size-v22-
|
|
37
|
-
--magritte-typography-label-4-regular-letter-spacing-v22-
|
|
38
|
-
--magritte-typography-label-4-regular-text-indent-v22-
|
|
39
|
-
--magritte-typography-label-4-regular-text-transform-v22-
|
|
40
|
-
--magritte-typography-label-4-regular-text-decoration-v22-
|
|
41
|
-
--magritte-static-space-100-v22-
|
|
42
|
-
--magritte-static-space-400-v22-
|
|
43
|
-
}
|
|
44
|
-
.magritte-file-info-
|
|
33
|
+
--magritte-typography-label-4-regular-font-family-v22-1-0:"hh sans";
|
|
34
|
+
--magritte-typography-label-4-regular-font-weight-v22-1-0:400;
|
|
35
|
+
--magritte-typography-label-4-regular-line-height-v22-1-0:18px;
|
|
36
|
+
--magritte-typography-label-4-regular-font-size-v22-1-0:12px;
|
|
37
|
+
--magritte-typography-label-4-regular-letter-spacing-v22-1-0:0.01em;
|
|
38
|
+
--magritte-typography-label-4-regular-text-indent-v22-1-0:0px;
|
|
39
|
+
--magritte-typography-label-4-regular-text-transform-v22-1-0:none;
|
|
40
|
+
--magritte-typography-label-4-regular-text-decoration-v22-1-0:none;
|
|
41
|
+
--magritte-static-space-100-v22-1-0:4px;
|
|
42
|
+
--magritte-static-space-400-v22-1-0:16px;
|
|
43
|
+
}
|
|
44
|
+
.magritte-file-info-body___HmfXd_4-0-0{
|
|
45
45
|
flex-grow:1;
|
|
46
46
|
}
|
|
47
|
-
.magritte-file-info-and-
|
|
47
|
+
.magritte-file-info-and-controls___61iyY_4-0-0{
|
|
48
48
|
display:flex;
|
|
49
|
-
gap:var(--magritte-static-space-400-v22-
|
|
49
|
+
gap:var(--magritte-static-space-400-v22-1-0);
|
|
50
50
|
}
|
|
51
|
-
.magritte-file-info-
|
|
51
|
+
.magritte-file-info-container___WFab8_4-0-0{
|
|
52
52
|
flex-grow:1;
|
|
53
53
|
width:50px;
|
|
54
54
|
}
|
|
55
|
-
.magritte-file-
|
|
55
|
+
.magritte-file-info___HrqiB_4-0-0{
|
|
56
56
|
display:flex;
|
|
57
|
-
gap:var(--magritte-static-space-100-v22-
|
|
58
|
-
font-family:var(--magritte-typography-label-4-regular-font-family-v22-
|
|
59
|
-
font-weight:var(--magritte-typography-label-4-regular-font-weight-v22-
|
|
60
|
-
line-height:var(--magritte-typography-label-4-regular-line-height-v22-
|
|
61
|
-
font-size:var(--magritte-typography-label-4-regular-font-size-v22-
|
|
62
|
-
letter-spacing:var(--magritte-typography-label-4-regular-letter-spacing-v22-
|
|
63
|
-
text-indent:var(--magritte-typography-label-4-regular-text-indent-v22-
|
|
64
|
-
text-transform:var(--magritte-typography-label-4-regular-text-transform-v22-
|
|
65
|
-
text-decoration:var(--magritte-typography-label-4-regular-text-decoration-v22-
|
|
66
|
-
}
|
|
67
|
-
.magritte-
|
|
57
|
+
gap:var(--magritte-static-space-100-v22-1-0);
|
|
58
|
+
font-family:var(--magritte-typography-label-4-regular-font-family-v22-1-0);
|
|
59
|
+
font-weight:var(--magritte-typography-label-4-regular-font-weight-v22-1-0);
|
|
60
|
+
line-height:var(--magritte-typography-label-4-regular-line-height-v22-1-0);
|
|
61
|
+
font-size:var(--magritte-typography-label-4-regular-font-size-v22-1-0);
|
|
62
|
+
letter-spacing:var(--magritte-typography-label-4-regular-letter-spacing-v22-1-0);
|
|
63
|
+
text-indent:var(--magritte-typography-label-4-regular-text-indent-v22-1-0);
|
|
64
|
+
text-transform:var(--magritte-typography-label-4-regular-text-transform-v22-1-0);
|
|
65
|
+
text-decoration:var(--magritte-typography-label-4-regular-text-decoration-v22-1-0);
|
|
66
|
+
}
|
|
67
|
+
.magritte-controls___WdH7A_4-0-0{
|
|
68
68
|
display:flex;
|
|
69
69
|
align-items:center;
|
|
70
70
|
margin-left:auto;
|
|
71
|
-
margin-right:var(--magritte-static-space-400-v22-
|
|
71
|
+
margin-right:var(--magritte-static-space-400-v22-1-0);
|
|
72
72
|
}
|
|
73
73
|
|
|
74
74
|
:root{
|
|
75
|
-
--magritte-static-space-400-v22-
|
|
75
|
+
--magritte-static-space-400-v22-1-0:16px;
|
|
76
76
|
}
|
|
77
|
-
.magritte-item___vVDG-
|
|
77
|
+
.magritte-item___vVDG-_4-0-0{
|
|
78
78
|
display:flex;
|
|
79
79
|
width:100%;
|
|
80
|
-
gap:var(--magritte-static-space-400-v22-
|
|
80
|
+
gap:var(--magritte-static-space-400-v22-1-0);
|
|
81
81
|
}
|
|
82
82
|
|
|
83
83
|
:root{
|
|
84
|
-
--magritte-color-background-primary-v22-
|
|
85
|
-
--magritte-color-stroke-neutral-v22-
|
|
86
|
-
--magritte-color-stroke-accent-v22-
|
|
87
|
-
--magritte-color-stroke-state-focused-accessible-v22-
|
|
88
|
-
--magritte-color-component-input-stroke-state-negative-focused-accessible-v22-
|
|
84
|
+
--magritte-color-background-primary-v22-1-0:#ffffff;
|
|
85
|
+
--magritte-color-stroke-neutral-v22-1-0:#DCE3EB;
|
|
86
|
+
--magritte-color-stroke-accent-v22-1-0:#0070ff;
|
|
87
|
+
--magritte-color-stroke-state-focused-accessible-v22-1-0:#0070ff7a;
|
|
88
|
+
--magritte-color-component-input-stroke-state-negative-focused-accessible-v22-1-0:#ff4d3a7a;
|
|
89
89
|
}
|
|
90
90
|
:root{
|
|
91
|
-
--magritte-static-space-300-v22-
|
|
92
|
-
--magritte-static-space-400-v22-
|
|
93
|
-
--magritte-static-space-500-v22-
|
|
94
|
-
--magritte-static-space-600-v22-
|
|
95
|
-
--magritte-static-border-radius-600-v22-
|
|
91
|
+
--magritte-static-space-300-v22-1-0:12px;
|
|
92
|
+
--magritte-static-space-400-v22-1-0:16px;
|
|
93
|
+
--magritte-static-space-500-v22-1-0:20px;
|
|
94
|
+
--magritte-static-space-600-v22-1-0:24px;
|
|
95
|
+
--magritte-static-border-radius-600-v22-1-0:24px;
|
|
96
96
|
}
|
|
97
97
|
.magritte-night-theme{
|
|
98
|
-
--magritte-color-background-primary-v22-
|
|
99
|
-
--magritte-color-stroke-neutral-v22-
|
|
100
|
-
--magritte-color-stroke-accent-v22-
|
|
101
|
-
--magritte-color-stroke-state-focused-accessible-v22-
|
|
102
|
-
--magritte-color-component-input-stroke-state-negative-focused-accessible-v22-
|
|
103
|
-
}
|
|
104
|
-
.magritte-
|
|
98
|
+
--magritte-color-background-primary-v22-1-0:#1B1B1B;
|
|
99
|
+
--magritte-color-stroke-neutral-v22-1-0:#303030;
|
|
100
|
+
--magritte-color-stroke-accent-v22-1-0:#2b7fff;
|
|
101
|
+
--magritte-color-stroke-state-focused-accessible-v22-1-0:#0070ff7a;
|
|
102
|
+
--magritte-color-component-input-stroke-state-negative-focused-accessible-v22-1-0:#ff4d3a7a;
|
|
103
|
+
}
|
|
104
|
+
.magritte-zp-day-theme{
|
|
105
|
+
--magritte-color-background-primary-v22-1-0:#ffffff;
|
|
106
|
+
--magritte-color-stroke-neutral-v22-1-0:#DCE3EB;
|
|
107
|
+
--magritte-color-stroke-accent-v22-1-0:#7195AF;
|
|
108
|
+
--magritte-color-stroke-state-focused-accessible-v22-1-0:#0070ff7a;
|
|
109
|
+
--magritte-color-component-input-stroke-state-negative-focused-accessible-v22-1-0:#ff4d3a7a;
|
|
110
|
+
}
|
|
111
|
+
.magritte-root___FV1tC_4-0-0{
|
|
105
112
|
position:relative;
|
|
106
113
|
display:flex;
|
|
107
114
|
overflow:hidden;
|
|
108
|
-
border-radius:var(--magritte-static-border-radius-600-v22-
|
|
109
|
-
background-color:var(--magritte-color-background-primary-v22-
|
|
115
|
+
border-radius:var(--magritte-static-border-radius-600-v22-1-0);
|
|
116
|
+
background-color:var(--magritte-color-background-primary-v22-1-0);
|
|
110
117
|
}
|
|
111
|
-
.magritte-
|
|
118
|
+
.magritte-root___FV1tC_4-0-0:hover{
|
|
112
119
|
cursor:pointer;
|
|
113
120
|
}
|
|
114
|
-
.magritte-
|
|
115
|
-
border-color:var(--magritte-color-stroke-accent-v22-
|
|
121
|
+
.magritte-root___FV1tC_4-0-0:hover .magritte-background___RfZ0U_4-0-0{
|
|
122
|
+
border-color:var(--magritte-color-stroke-accent-v22-1-0);
|
|
116
123
|
}
|
|
117
|
-
.magritte-
|
|
118
|
-
border-color:var(--magritte-color-stroke-accent-v22-
|
|
124
|
+
.magritte-root___FV1tC_4-0-0.magritte-drag-active___dihBL_4-0-0 .magritte-background___RfZ0U_4-0-0{
|
|
125
|
+
border-color:var(--magritte-color-stroke-accent-v22-1-0);
|
|
119
126
|
}
|
|
120
|
-
.magritte-
|
|
121
|
-
outline:var(--magritte-color-stroke-state-focused-accessible-v22-
|
|
127
|
+
.magritte-root___FV1tC_4-0-0.focus-visible{
|
|
128
|
+
outline:var(--magritte-color-stroke-state-focused-accessible-v22-1-0) solid 4px;
|
|
122
129
|
}
|
|
123
|
-
.magritte-
|
|
124
|
-
border-color:var(--magritte-color-stroke-accent-v22-
|
|
130
|
+
.magritte-root___FV1tC_4-0-0.focus-visible .magritte-background___RfZ0U_4-0-0{
|
|
131
|
+
border-color:var(--magritte-color-stroke-accent-v22-1-0);
|
|
125
132
|
}
|
|
126
|
-
.magritte-
|
|
127
|
-
.magritte-
|
|
133
|
+
.magritte-root___FV1tC_4-0-0.magritte-load___MghDA_4-0-0 .magritte-background___RfZ0U_4-0-0,
|
|
134
|
+
.magritte-root___FV1tC_4-0-0.magritte-loading___9E3p-_4-0-0 .magritte-background___RfZ0U_4-0-0{
|
|
128
135
|
border-style:solid;
|
|
129
136
|
border-width:7px;
|
|
130
137
|
}
|
|
131
|
-
.magritte-
|
|
132
|
-
outline:var(--magritte-color-component-input-stroke-state-negative-focused-accessible-v22-
|
|
138
|
+
.magritte-root___FV1tC_4-0-0.magritte-invalid___Rt10-_4-0-0.focus-visible{
|
|
139
|
+
outline:var(--magritte-color-component-input-stroke-state-negative-focused-accessible-v22-1-0) solid 4px;
|
|
133
140
|
}
|
|
134
|
-
.magritte-
|
|
135
|
-
border-color:var(--magritte-color-stroke-neutral-v22-
|
|
141
|
+
.magritte-root___FV1tC_4-0-0.magritte-invalid___Rt10-_4-0-0 .magritte-background___RfZ0U_4-0-0{
|
|
142
|
+
border-color:var(--magritte-color-stroke-neutral-v22-1-0);
|
|
136
143
|
}
|
|
137
|
-
.magritte-
|
|
144
|
+
.magritte-root_medium___67WJa_4-0-0{
|
|
138
145
|
justify-content:center;
|
|
139
|
-
padding:var(--magritte-static-space-600-v22-
|
|
146
|
+
padding:var(--magritte-static-space-600-v22-1-0);
|
|
140
147
|
}
|
|
141
|
-
.magritte-
|
|
148
|
+
.magritte-root_medium___67WJa_4-0-0 .magritte-body___O7ROl_4-0-0{
|
|
142
149
|
flex-direction:column;
|
|
143
150
|
align-items:center;
|
|
144
151
|
justify-content:center;
|
|
145
152
|
}
|
|
146
|
-
.magritte-
|
|
147
|
-
padding-top:var(--magritte-static-space-400-v22-
|
|
148
|
-
padding-bottom:var(--magritte-static-space-400-v22-
|
|
149
|
-
padding-left:var(--magritte-static-space-400-v22-
|
|
153
|
+
.magritte-root_small___dkUYq_4-0-0{
|
|
154
|
+
padding-top:var(--magritte-static-space-400-v22-1-0);
|
|
155
|
+
padding-bottom:var(--magritte-static-space-400-v22-1-0);
|
|
156
|
+
padding-left:var(--magritte-static-space-400-v22-1-0);
|
|
150
157
|
}
|
|
151
|
-
.magritte-
|
|
152
|
-
gap:var(--magritte-static-space-400-v22-
|
|
158
|
+
.magritte-root_small___dkUYq_4-0-0 .magritte-body___O7ROl_4-0-0{
|
|
159
|
+
gap:var(--magritte-static-space-400-v22-1-0);
|
|
153
160
|
}
|
|
154
|
-
.magritte-
|
|
161
|
+
.magritte-background___RfZ0U_4-0-0{
|
|
155
162
|
position:absolute;
|
|
156
163
|
border-width:8px;
|
|
157
164
|
border-style:dashed;
|
|
158
|
-
border-color:var(--magritte-color-stroke-neutral-v22-
|
|
165
|
+
border-color:var(--magritte-color-stroke-neutral-v22-1-0);
|
|
159
166
|
top:-6px;
|
|
160
167
|
bottom:-6px;
|
|
161
168
|
left:-6px;
|
|
162
169
|
right:-6px;
|
|
163
|
-
border-radius:calc(var(--magritte-static-border-radius-600-v22-
|
|
170
|
+
border-radius:calc(var(--magritte-static-border-radius-600-v22-1-0) + 6px);
|
|
164
171
|
background-position:center;
|
|
165
172
|
background-size:100%;
|
|
166
173
|
}
|
|
167
|
-
.magritte-
|
|
174
|
+
.magritte-body___O7ROl_4-0-0{
|
|
168
175
|
display:flex;
|
|
169
176
|
width:100%;
|
|
170
177
|
}
|
|
171
|
-
.magritte-
|
|
178
|
+
.magritte-loader___XYpWg_4-0-0{
|
|
172
179
|
position:relative;
|
|
173
180
|
display:flex;
|
|
174
181
|
}
|
|
175
|
-
.magritte-cancel___tQ-
|
|
182
|
+
.magritte-cancel___tQ-yX_4-0-0{
|
|
176
183
|
position:absolute;
|
|
177
184
|
top:0;
|
|
178
185
|
left:0;
|
|
@@ -182,37 +189,37 @@
|
|
|
182
189
|
align-items:center;
|
|
183
190
|
justify-content:center;
|
|
184
191
|
}
|
|
185
|
-
.magritte-image-
|
|
192
|
+
.magritte-image-controls___vLf94_4-0-0{
|
|
186
193
|
display:flex;
|
|
187
|
-
gap:var(--magritte-static-space-300-v22-
|
|
194
|
+
gap:var(--magritte-static-space-300-v22-1-0);
|
|
188
195
|
align-items:flex-end;
|
|
189
196
|
justify-content:flex-end;
|
|
190
197
|
width:100%;
|
|
191
198
|
}
|
|
192
|
-
.magritte-small-
|
|
199
|
+
.magritte-small-controls___Qn9TP_4-0-0{
|
|
193
200
|
display:flex;
|
|
194
201
|
align-items:center;
|
|
195
202
|
margin-left:auto;
|
|
196
|
-
margin-right:var(--magritte-static-space-500-v22-
|
|
203
|
+
margin-right:var(--magritte-static-space-500-v22-1-0);
|
|
197
204
|
}
|
|
198
|
-
.magritte-file-
|
|
199
|
-
margin-top:var(--magritte-static-space-300-v22-
|
|
200
|
-
box-shadow:inset 0 0 0 1px var(--magritte-color-stroke-neutral-v22-
|
|
201
|
-
border-radius:var(--magritte-static-border-radius-600-v22-
|
|
202
|
-
padding-top:var(--magritte-static-space-400-v22-
|
|
205
|
+
.magritte-file-list___L9uHt_4-0-0{
|
|
206
|
+
margin-top:var(--magritte-static-space-300-v22-1-0);
|
|
207
|
+
box-shadow:inset 0 0 0 1px var(--magritte-color-stroke-neutral-v22-1-0);
|
|
208
|
+
border-radius:var(--magritte-static-border-radius-600-v22-1-0);
|
|
209
|
+
padding-top:var(--magritte-static-space-400-v22-1-0);
|
|
203
210
|
padding-right:0;
|
|
204
|
-
padding-bottom:var(--magritte-static-space-400-v22-
|
|
205
|
-
padding-left:var(--magritte-static-space-400-v22-
|
|
211
|
+
padding-bottom:var(--magritte-static-space-400-v22-1-0);
|
|
212
|
+
padding-left:var(--magritte-static-space-400-v22-1-0);
|
|
206
213
|
}
|
|
207
|
-
.magritte-file-
|
|
214
|
+
.magritte-file-icon___oetLK_4-0-0{
|
|
208
215
|
display:inline-flex;
|
|
209
216
|
}
|
|
210
|
-
.magritte-file-
|
|
217
|
+
.magritte-file-info___Y3vyi_4-0-0{
|
|
211
218
|
display:inline-flex;
|
|
212
219
|
width:100%;
|
|
213
220
|
flex-direction:column;
|
|
214
221
|
align-items:center;
|
|
215
222
|
}
|
|
216
|
-
.magritte-hidden-file-
|
|
223
|
+
.magritte-hidden-file-info___92c69_4-0-0{
|
|
217
224
|
visibility:hidden;
|
|
218
225
|
}
|
package/index.d.ts
CHANGED
package/index.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import './index.css';
|
|
2
|
-
export * from '@hh.ru/magritte-ui-theme-provider';
|
|
3
2
|
export { Upload } from './Upload.js';
|
|
4
3
|
import 'react/jsx-runtime';
|
|
5
4
|
import './MultiUpload.js';
|
|
@@ -21,6 +20,6 @@ import '@hh.ru/magritte-ui-breakpoint';
|
|
|
21
20
|
import '@hh.ru/magritte-ui-typography';
|
|
22
21
|
import './useDropActions.js';
|
|
23
22
|
import './useDropButtons.js';
|
|
24
|
-
import './upload-
|
|
23
|
+
import './upload-CvvnKTGS.js';
|
|
25
24
|
import './SingleUpload.js';
|
|
26
25
|
//# sourceMappingURL=index.js.map
|
package/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;"}
|
package/index.mock.d.ts
CHANGED
package/index.mock.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import './index.css';
|
|
2
2
|
import { mockComponent } from '@hh.ru/magritte-ui-mock-component';
|
|
3
3
|
|
|
4
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
|
|
5
|
-
const { ThemeProvider } = jest.requireActual('@hh.ru/magritte-ui-theme-provider/index');
|
|
6
4
|
const Upload = mockComponent('Upload', undefined, {
|
|
7
5
|
withChildren: false,
|
|
8
6
|
});
|
|
9
7
|
|
|
10
|
-
export {
|
|
8
|
+
export { Upload };
|
|
11
9
|
//# sourceMappingURL=index.mock.js.map
|
package/index.mock.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mock.js","sources":["../src/index.mock.ts"],"sourcesContent":["import { ForwardRefExoticComponent } from 'react';\n\nimport { mockComponent } from '@hh.ru/magritte-ui-mock-component';\n\nexport type * from '@hh.ru/magritte-ui-upload/types';\n\
|
|
1
|
+
{"version":3,"file":"index.mock.js","sources":["../src/index.mock.ts"],"sourcesContent":["import { ForwardRefExoticComponent } from 'react';\n\nimport { mockComponent } from '@hh.ru/magritte-ui-mock-component';\n\nexport type * from '@hh.ru/magritte-ui-upload/types';\n\nexport const Upload: ForwardRefExoticComponent<Record<string, unknown>> = mockComponent('Upload', undefined, {\n withChildren: false,\n});\n"],"names":[],"mappings":";;MAMa,MAAM,GAAuD,aAAa,CAAC,QAAQ,EAAE,SAAS,EAAE;AACzG,IAAA,YAAY,EAAE,KAAK;AACtB,CAAA;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hh.ru/magritte-ui-upload",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"types": "index.d.ts",
|
|
6
6
|
"sideEffects": [
|
|
@@ -26,18 +26,18 @@
|
|
|
26
26
|
"react": ">=18.2.0"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@hh.ru/magritte-
|
|
29
|
+
"@hh.ru/magritte-design-tokens": "22.1.0",
|
|
30
|
+
"@hh.ru/magritte-ui-avatar": "7.0.0",
|
|
30
31
|
"@hh.ru/magritte-ui-breakpoint": "5.0.3",
|
|
31
|
-
"@hh.ru/magritte-ui-button": "
|
|
32
|
-
"@hh.ru/magritte-ui-button-stack": "2.1.
|
|
33
|
-
"@hh.ru/magritte-ui-divider": "
|
|
34
|
-
"@hh.ru/magritte-ui-icon": "
|
|
35
|
-
"@hh.ru/magritte-ui-loader": "
|
|
32
|
+
"@hh.ru/magritte-ui-button": "6.0.0",
|
|
33
|
+
"@hh.ru/magritte-ui-button-stack": "2.1.70",
|
|
34
|
+
"@hh.ru/magritte-ui-divider": "3.0.0",
|
|
35
|
+
"@hh.ru/magritte-ui-icon": "12.0.0",
|
|
36
|
+
"@hh.ru/magritte-ui-loader": "2.0.0",
|
|
36
37
|
"@hh.ru/magritte-ui-mock-component": "1.1.4",
|
|
37
|
-
"@hh.ru/magritte-ui-spacing": "2.0.
|
|
38
|
-
"@hh.ru/magritte-ui-
|
|
39
|
-
"@hh.ru/magritte-ui-typography": "3.0.47",
|
|
38
|
+
"@hh.ru/magritte-ui-spacing": "2.0.57",
|
|
39
|
+
"@hh.ru/magritte-ui-typography": "4.0.0",
|
|
40
40
|
"react-dropzone": "14.3.5"
|
|
41
41
|
},
|
|
42
|
-
"gitHead": "
|
|
42
|
+
"gitHead": "a823b2d582e812bf99b5fdf32058a93eaa59076b"
|
|
43
43
|
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import './index.css';
|
|
2
|
+
var styles = {"root":"magritte-root___FV1tC_4-0-0","background":"magritte-background___RfZ0U_4-0-0","drag-active":"magritte-drag-active___dihBL_4-0-0","dragActive":"magritte-drag-active___dihBL_4-0-0","load":"magritte-load___MghDA_4-0-0","loading":"magritte-loading___9E3p-_4-0-0","invalid":"magritte-invalid___Rt10-_4-0-0","root_medium":"magritte-root_medium___67WJa_4-0-0","rootMedium":"magritte-root_medium___67WJa_4-0-0","body":"magritte-body___O7ROl_4-0-0","root_small":"magritte-root_small___dkUYq_4-0-0","rootSmall":"magritte-root_small___dkUYq_4-0-0","loader":"magritte-loader___XYpWg_4-0-0","cancel":"magritte-cancel___tQ-yX_4-0-0","image-controls":"magritte-image-controls___vLf94_4-0-0","imageControls":"magritte-image-controls___vLf94_4-0-0","small-controls":"magritte-small-controls___Qn9TP_4-0-0","smallControls":"magritte-small-controls___Qn9TP_4-0-0","file-list":"magritte-file-list___L9uHt_4-0-0","fileList":"magritte-file-list___L9uHt_4-0-0","file-icon":"magritte-file-icon___oetLK_4-0-0","fileIcon":"magritte-file-icon___oetLK_4-0-0","file-info":"magritte-file-info___Y3vyi_4-0-0","fileInfo":"magritte-file-info___Y3vyi_4-0-0","hidden-file-info":"magritte-hidden-file-info___92c69_4-0-0","hiddenFileInfo":"magritte-hidden-file-info___92c69_4-0-0"};
|
|
3
|
+
|
|
4
|
+
export { styles as s };
|
|
5
|
+
//# sourceMappingURL=upload-CvvnKTGS.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"upload-CvvnKTGS.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
package/upload-mR_dU6SQ.js
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import './index.css';
|
|
2
|
-
var styles = {"root":"magritte-root___FV1tC_3-3-25","background":"magritte-background___RfZ0U_3-3-25","drag-active":"magritte-drag-active___dihBL_3-3-25","dragActive":"magritte-drag-active___dihBL_3-3-25","load":"magritte-load___MghDA_3-3-25","loading":"magritte-loading___9E3p-_3-3-25","invalid":"magritte-invalid___Rt10-_3-3-25","root_medium":"magritte-root_medium___67WJa_3-3-25","rootMedium":"magritte-root_medium___67WJa_3-3-25","body":"magritte-body___O7ROl_3-3-25","root_small":"magritte-root_small___dkUYq_3-3-25","rootSmall":"magritte-root_small___dkUYq_3-3-25","loader":"magritte-loader___XYpWg_3-3-25","cancel":"magritte-cancel___tQ-yX_3-3-25","image-controls":"magritte-image-controls___vLf94_3-3-25","imageControls":"magritte-image-controls___vLf94_3-3-25","small-controls":"magritte-small-controls___Qn9TP_3-3-25","smallControls":"magritte-small-controls___Qn9TP_3-3-25","file-list":"magritte-file-list___L9uHt_3-3-25","fileList":"magritte-file-list___L9uHt_3-3-25","file-icon":"magritte-file-icon___oetLK_3-3-25","fileIcon":"magritte-file-icon___oetLK_3-3-25","file-info":"magritte-file-info___Y3vyi_3-3-25","fileInfo":"magritte-file-info___Y3vyi_3-3-25","hidden-file-info":"magritte-hidden-file-info___92c69_3-3-25","hiddenFileInfo":"magritte-hidden-file-info___92c69_3-3-25"};
|
|
3
|
-
|
|
4
|
-
export { styles as s };
|
|
5
|
-
//# sourceMappingURL=upload-mR_dU6SQ.js.map
|
package/upload-mR_dU6SQ.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"upload-mR_dU6SQ.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|