@salutejs/plasma-new-hope 0.194.1-canary.1569.11908076676.0 → 0.195.0-canary.1534.11911237435.0
Sign up to get free protection for your applications and to get access to all the features.
- package/cjs/_virtual/_rollupPluginBabelHelpers.js +333 -0
- package/cjs/_virtual/_rollupPluginBabelHelpers.js.map +1 -1
- package/cjs/components/Dropzone/Dropzone.css +15 -0
- package/cjs/components/Dropzone/Dropzone.js +252 -0
- package/cjs/components/Dropzone/Dropzone.js.map +1 -0
- package/cjs/components/Dropzone/Dropzone.styles.js +47 -0
- package/cjs/components/Dropzone/Dropzone.styles.js.map +1 -0
- package/cjs/components/Dropzone/Dropzone.styles_1fo7dbq.css +7 -0
- package/cjs/components/Dropzone/Dropzone.tokens.js +47 -0
- package/cjs/components/Dropzone/Dropzone.tokens.js.map +1 -0
- package/cjs/components/Dropzone/variations/_disabled/base.js +9 -0
- package/cjs/components/Dropzone/variations/_disabled/base.js.map +1 -0
- package/cjs/components/Dropzone/variations/_disabled/base_3qwygi.css +1 -0
- package/cjs/components/Dropzone/variations/_size/base.js +9 -0
- package/cjs/components/Dropzone/variations/_size/base.js.map +1 -0
- package/cjs/components/Dropzone/variations/_size/base_1bt22g1.css +1 -0
- package/cjs/components/Dropzone/variations/_view/base.js +9 -0
- package/cjs/components/Dropzone/variations/_view/base.js.map +1 -0
- package/cjs/components/Dropzone/variations/_view/base_1pdzq6t.css +1 -0
- package/cjs/components/Switch/Switch.css +1 -1
- package/cjs/components/Switch/Switch.tokens.js +1 -2
- package/cjs/components/Switch/Switch.tokens.js.map +1 -1
- package/cjs/components/Switch/_toggleSize/base.js +1 -1
- package/cjs/components/Switch/_toggleSize/base.js.map +1 -1
- package/cjs/components/Switch/_toggleSize/base_1d0b3t4.css +1 -0
- package/cjs/components/_Icon/Icon.assets/ArrowBarDown.js +24 -0
- package/cjs/components/_Icon/Icon.assets/ArrowBarDown.js.map +1 -0
- package/cjs/components/_Icon/Icons/IconArrowBarDown.js +23 -0
- package/cjs/components/_Icon/Icons/IconArrowBarDown.js.map +1 -0
- package/cjs/index.css +15 -1
- package/cjs/index.js +6 -0
- package/cjs/index.js.map +1 -1
- package/emotion/cjs/components/Dropzone/Dropzone.js +271 -0
- package/emotion/cjs/components/Dropzone/Dropzone.styles.js +67 -0
- package/emotion/cjs/components/Dropzone/Dropzone.template-docs.mdx +136 -0
- package/emotion/cjs/components/Dropzone/Dropzone.tokens.js +44 -0
- package/emotion/cjs/components/Dropzone/Dropzone.types.js +5 -0
- package/emotion/cjs/components/Dropzone/index.js +31 -0
- package/emotion/cjs/components/Dropzone/variations/_disabled/base.js +9 -0
- package/emotion/cjs/components/Dropzone/variations/_disabled/tokens.json +4 -0
- package/emotion/cjs/components/Dropzone/variations/_size/base.js +10 -0
- package/emotion/cjs/components/Dropzone/variations/_size/tokens.json +19 -0
- package/emotion/cjs/components/Dropzone/variations/_view/base.js +10 -0
- package/emotion/cjs/components/Dropzone/variations/_view/tokens.json +9 -0
- package/emotion/cjs/components/Switch/Switch.tokens.js +1 -2
- package/emotion/cjs/components/Switch/_toggleSize/base.js +1 -1
- package/emotion/cjs/components/_Icon/Icon.assets/ArrowBarDown.js +23 -0
- package/emotion/cjs/components/_Icon/Icons/IconArrowBarDown.js +22 -0
- package/emotion/cjs/components/_Icon/index.js +8 -1
- package/emotion/cjs/examples/plasma_b2c/components/Dropzone/Dropzone.config.js +25 -0
- package/emotion/cjs/examples/plasma_b2c/components/Dropzone/Dropzone.js +11 -0
- package/emotion/cjs/examples/plasma_b2c/components/Dropzone/Dropzone.stories.tsx +57 -0
- package/emotion/cjs/examples/plasma_b2c/components/Switch/Switch.config.js +8 -8
- package/emotion/cjs/examples/plasma_b2c/components/Switch/Switch.outline.config.js +8 -8
- package/emotion/cjs/examples/plasma_web/components/Dropzone/Dropzone.config.js +25 -0
- package/emotion/cjs/examples/plasma_web/components/Dropzone/Dropzone.js +11 -0
- package/emotion/cjs/examples/plasma_web/components/Dropzone/Dropzone.stories.tsx +57 -0
- package/emotion/cjs/examples/plasma_web/components/Switch/Switch.config.js +8 -8
- package/emotion/cjs/examples/plasma_web/components/Switch/Switch.outline.config.js +8 -8
- package/emotion/cjs/index.js +11 -0
- package/emotion/es/components/Dropzone/Dropzone.js +263 -0
- package/emotion/es/components/Dropzone/Dropzone.styles.js +60 -0
- package/emotion/es/components/Dropzone/Dropzone.template-docs.mdx +136 -0
- package/emotion/es/components/Dropzone/Dropzone.tokens.js +38 -0
- package/emotion/es/components/Dropzone/Dropzone.types.js +1 -0
- package/emotion/es/components/Dropzone/index.js +2 -0
- package/emotion/es/components/Dropzone/variations/_disabled/base.js +3 -0
- package/emotion/es/components/Dropzone/variations/_disabled/tokens.json +4 -0
- package/emotion/es/components/Dropzone/variations/_size/base.js +4 -0
- package/emotion/es/components/Dropzone/variations/_size/tokens.json +19 -0
- package/emotion/es/components/Dropzone/variations/_view/base.js +4 -0
- package/emotion/es/components/Dropzone/variations/_view/tokens.json +9 -0
- package/emotion/es/components/Switch/Switch.tokens.js +1 -2
- package/emotion/es/components/Switch/_toggleSize/base.js +2 -2
- package/emotion/es/components/_Icon/Icon.assets/ArrowBarDown.js +16 -0
- package/emotion/es/components/_Icon/Icons/IconArrowBarDown.js +15 -0
- package/emotion/es/components/_Icon/index.js +2 -1
- package/emotion/es/examples/plasma_b2c/components/Dropzone/Dropzone.config.js +19 -0
- package/emotion/es/examples/plasma_b2c/components/Dropzone/Dropzone.js +5 -0
- package/emotion/es/examples/plasma_b2c/components/Dropzone/Dropzone.stories.tsx +57 -0
- package/emotion/es/examples/plasma_b2c/components/Switch/Switch.config.js +8 -8
- package/emotion/es/examples/plasma_b2c/components/Switch/Switch.outline.config.js +8 -8
- package/emotion/es/examples/plasma_web/components/Dropzone/Dropzone.config.js +19 -0
- package/emotion/es/examples/plasma_web/components/Dropzone/Dropzone.js +5 -0
- package/emotion/es/examples/plasma_web/components/Dropzone/Dropzone.stories.tsx +57 -0
- package/emotion/es/examples/plasma_web/components/Switch/Switch.config.js +8 -8
- package/emotion/es/examples/plasma_web/components/Switch/Switch.outline.config.js +8 -8
- package/emotion/es/index.js +2 -1
- package/es/_virtual/_rollupPluginBabelHelpers.js +332 -1
- package/es/_virtual/_rollupPluginBabelHelpers.js.map +1 -1
- package/es/components/Dropzone/Dropzone.css +15 -0
- package/es/components/Dropzone/Dropzone.js +247 -0
- package/es/components/Dropzone/Dropzone.js.map +1 -0
- package/es/components/Dropzone/Dropzone.styles.js +37 -0
- package/es/components/Dropzone/Dropzone.styles.js.map +1 -0
- package/es/components/Dropzone/Dropzone.styles_1fo7dbq.css +7 -0
- package/es/components/Dropzone/Dropzone.tokens.js +41 -0
- package/es/components/Dropzone/Dropzone.tokens.js.map +1 -0
- package/es/components/Dropzone/variations/_disabled/base.js +5 -0
- package/es/components/Dropzone/variations/_disabled/base.js.map +1 -0
- package/es/components/Dropzone/variations/_disabled/base_3qwygi.css +1 -0
- package/es/components/Dropzone/variations/_size/base.js +5 -0
- package/es/components/Dropzone/variations/_size/base.js.map +1 -0
- package/es/components/Dropzone/variations/_size/base_1bt22g1.css +1 -0
- package/es/components/Dropzone/variations/_view/base.js +5 -0
- package/es/components/Dropzone/variations/_view/base.js.map +1 -0
- package/es/components/Dropzone/variations/_view/base_1pdzq6t.css +1 -0
- package/es/components/Switch/Switch.css +1 -1
- package/es/components/Switch/Switch.tokens.js +1 -2
- package/es/components/Switch/Switch.tokens.js.map +1 -1
- package/es/components/Switch/_toggleSize/base.js +1 -1
- package/es/components/Switch/_toggleSize/base.js.map +1 -1
- package/es/components/Switch/_toggleSize/base_1d0b3t4.css +1 -0
- package/es/components/_Icon/Icon.assets/ArrowBarDown.js +20 -0
- package/es/components/_Icon/Icon.assets/ArrowBarDown.js.map +1 -0
- package/es/components/_Icon/Icons/IconArrowBarDown.js +19 -0
- package/es/components/_Icon/Icons/IconArrowBarDown.js.map +1 -0
- package/es/index.css +15 -1
- package/es/index.js +2 -0
- package/es/index.js.map +1 -1
- package/package.json +2 -2
- package/styled-components/cjs/components/Dropzone/Dropzone.js +271 -0
- package/styled-components/cjs/components/Dropzone/Dropzone.styles.js +29 -0
- package/styled-components/cjs/components/Dropzone/Dropzone.template-docs.mdx +136 -0
- package/styled-components/cjs/components/Dropzone/Dropzone.tokens.js +44 -0
- package/styled-components/cjs/components/Dropzone/Dropzone.types.js +5 -0
- package/styled-components/cjs/components/Dropzone/index.js +31 -0
- package/styled-components/cjs/components/Dropzone/variations/_disabled/base.js +9 -0
- package/styled-components/cjs/components/Dropzone/variations/_disabled/tokens.json +4 -0
- package/styled-components/cjs/components/Dropzone/variations/_size/base.js +10 -0
- package/styled-components/cjs/components/Dropzone/variations/_size/tokens.json +19 -0
- package/styled-components/cjs/components/Dropzone/variations/_view/base.js +10 -0
- package/styled-components/cjs/components/Dropzone/variations/_view/tokens.json +9 -0
- package/styled-components/cjs/components/Switch/Switch.tokens.js +1 -2
- package/styled-components/cjs/components/Switch/_toggleSize/base.js +1 -1
- package/styled-components/cjs/components/_Icon/Icon.assets/ArrowBarDown.js +23 -0
- package/styled-components/cjs/components/_Icon/Icons/IconArrowBarDown.js +22 -0
- package/styled-components/cjs/components/_Icon/index.js +8 -1
- package/styled-components/cjs/examples/plasma_b2c/components/Dropzone/Dropzone.config.js +25 -0
- package/styled-components/cjs/examples/plasma_b2c/components/Dropzone/Dropzone.js +11 -0
- package/styled-components/cjs/examples/plasma_b2c/components/Dropzone/Dropzone.stories.tsx +57 -0
- package/styled-components/cjs/examples/plasma_b2c/components/Switch/Switch.config.js +1 -1
- package/styled-components/cjs/examples/plasma_b2c/components/Switch/Switch.outline.config.js +1 -1
- package/styled-components/cjs/examples/plasma_web/components/Dropzone/Dropzone.config.js +25 -0
- package/styled-components/cjs/examples/plasma_web/components/Dropzone/Dropzone.js +11 -0
- package/styled-components/cjs/examples/plasma_web/components/Dropzone/Dropzone.stories.tsx +57 -0
- package/styled-components/cjs/examples/plasma_web/components/Switch/Switch.config.js +1 -1
- package/styled-components/cjs/examples/plasma_web/components/Switch/Switch.outline.config.js +1 -1
- package/styled-components/cjs/index.js +11 -0
- package/styled-components/es/components/Dropzone/Dropzone.js +263 -0
- package/styled-components/es/components/Dropzone/Dropzone.styles.js +21 -0
- package/styled-components/es/components/Dropzone/Dropzone.template-docs.mdx +136 -0
- package/styled-components/es/components/Dropzone/Dropzone.tokens.js +38 -0
- package/styled-components/es/components/Dropzone/Dropzone.types.js +1 -0
- package/styled-components/es/components/Dropzone/index.js +2 -0
- package/styled-components/es/components/Dropzone/variations/_disabled/base.js +3 -0
- package/styled-components/es/components/Dropzone/variations/_disabled/tokens.json +4 -0
- package/styled-components/es/components/Dropzone/variations/_size/base.js +4 -0
- package/styled-components/es/components/Dropzone/variations/_size/tokens.json +19 -0
- package/styled-components/es/components/Dropzone/variations/_view/base.js +4 -0
- package/styled-components/es/components/Dropzone/variations/_view/tokens.json +9 -0
- package/styled-components/es/components/Switch/Switch.tokens.js +1 -2
- package/styled-components/es/components/Switch/_toggleSize/base.js +2 -2
- package/styled-components/es/components/_Icon/Icon.assets/ArrowBarDown.js +16 -0
- package/styled-components/es/components/_Icon/Icons/IconArrowBarDown.js +15 -0
- package/styled-components/es/components/_Icon/index.js +2 -1
- package/styled-components/es/examples/plasma_b2c/components/Dropzone/Dropzone.config.js +19 -0
- package/styled-components/es/examples/plasma_b2c/components/Dropzone/Dropzone.js +5 -0
- package/styled-components/es/examples/plasma_b2c/components/Dropzone/Dropzone.stories.tsx +57 -0
- package/styled-components/es/examples/plasma_b2c/components/Switch/Switch.config.js +1 -1
- package/styled-components/es/examples/plasma_b2c/components/Switch/Switch.outline.config.js +1 -1
- package/styled-components/es/examples/plasma_web/components/Dropzone/Dropzone.config.js +19 -0
- package/styled-components/es/examples/plasma_web/components/Dropzone/Dropzone.js +5 -0
- package/styled-components/es/examples/plasma_web/components/Dropzone/Dropzone.stories.tsx +57 -0
- package/styled-components/es/examples/plasma_web/components/Switch/Switch.config.js +1 -1
- package/styled-components/es/examples/plasma_web/components/Switch/Switch.outline.config.js +1 -1
- package/styled-components/es/index.js +2 -1
- package/types/components/Dropzone/Dropzone.d.ts +59 -0
- package/types/components/Dropzone/Dropzone.d.ts.map +1 -0
- package/types/components/Dropzone/Dropzone.styles.d.ts +9 -0
- package/types/components/Dropzone/Dropzone.styles.d.ts.map +1 -0
- package/types/components/Dropzone/Dropzone.tokens.d.ts +39 -0
- package/types/components/Dropzone/Dropzone.tokens.d.ts.map +1 -0
- package/types/components/Dropzone/Dropzone.types.d.ts +77 -0
- package/types/components/Dropzone/Dropzone.types.d.ts.map +1 -0
- package/types/components/Dropzone/index.d.ts +3 -0
- package/types/components/Dropzone/index.d.ts.map +1 -0
- package/types/components/Dropzone/variations/_disabled/base.d.ts +2 -0
- package/types/components/Dropzone/variations/_disabled/base.d.ts.map +1 -0
- package/types/components/Dropzone/variations/_size/base.d.ts +2 -0
- package/types/components/Dropzone/variations/_size/base.d.ts.map +1 -0
- package/types/components/Dropzone/variations/_view/base.d.ts +2 -0
- package/types/components/Dropzone/variations/_view/base.d.ts.map +1 -0
- package/types/components/Switch/Switch.tokens.d.ts +1 -2
- package/types/components/Switch/Switch.tokens.d.ts.map +1 -1
- package/types/components/Switch/_toggleSize/base.d.ts.map +1 -1
- package/types/components/_Icon/Icon.assets/ArrowBarDown.d.ts +4 -0
- package/types/components/_Icon/Icon.assets/ArrowBarDown.d.ts.map +1 -0
- package/types/components/_Icon/Icons/IconArrowBarDown.d.ts +4 -0
- package/types/components/_Icon/Icons/IconArrowBarDown.d.ts.map +1 -0
- package/types/components/_Icon/index.d.ts +1 -0
- package/types/components/_Icon/index.d.ts.map +1 -1
- package/types/examples/plasma_b2c/components/Dropzone/Dropzone.config.d.ts +18 -0
- package/types/examples/plasma_b2c/components/Dropzone/Dropzone.config.d.ts.map +1 -0
- package/types/examples/plasma_b2c/components/Dropzone/Dropzone.d.ts +29 -0
- package/types/examples/plasma_b2c/components/Dropzone/Dropzone.d.ts.map +1 -0
- package/types/examples/plasma_b2c/components/Switch/Switch.config.d.ts.map +1 -1
- package/types/examples/plasma_b2c/components/Switch/Switch.outline.config.d.ts.map +1 -1
- package/types/examples/plasma_web/components/Dropzone/Dropzone.config.d.ts +18 -0
- package/types/examples/plasma_web/components/Dropzone/Dropzone.config.d.ts.map +1 -0
- package/types/examples/plasma_web/components/Dropzone/Dropzone.d.ts +29 -0
- package/types/examples/plasma_web/components/Dropzone/Dropzone.d.ts.map +1 -0
- package/types/examples/plasma_web/components/Switch/Switch.config.d.ts.map +1 -1
- package/types/examples/plasma_web/components/Switch/Switch.outline.config.d.ts.map +1 -1
- package/types/index.d.ts +1 -0
- package/types/index.d.ts.map +1 -1
- package/cjs/components/Switch/_toggleSize/base_o6rjc1.css +0 -1
- package/es/components/Switch/_toggleSize/base_o6rjc1.css +0 -1
@@ -46,6 +46,307 @@ function _objectSpread2(e) {
|
|
46
46
|
}
|
47
47
|
return e;
|
48
48
|
}
|
49
|
+
function _regeneratorRuntime() {
|
50
|
+
_regeneratorRuntime = function () {
|
51
|
+
return e;
|
52
|
+
};
|
53
|
+
var t,
|
54
|
+
e = {},
|
55
|
+
r = Object.prototype,
|
56
|
+
n = r.hasOwnProperty,
|
57
|
+
o = Object.defineProperty || function (t, e, r) {
|
58
|
+
t[e] = r.value;
|
59
|
+
},
|
60
|
+
i = "function" == typeof Symbol ? Symbol : {},
|
61
|
+
a = i.iterator || "@@iterator",
|
62
|
+
c = i.asyncIterator || "@@asyncIterator",
|
63
|
+
u = i.toStringTag || "@@toStringTag";
|
64
|
+
function define(t, e, r) {
|
65
|
+
return Object.defineProperty(t, e, {
|
66
|
+
value: r,
|
67
|
+
enumerable: !0,
|
68
|
+
configurable: !0,
|
69
|
+
writable: !0
|
70
|
+
}), t[e];
|
71
|
+
}
|
72
|
+
try {
|
73
|
+
define({}, "");
|
74
|
+
} catch (t) {
|
75
|
+
define = function (t, e, r) {
|
76
|
+
return t[e] = r;
|
77
|
+
};
|
78
|
+
}
|
79
|
+
function wrap(t, e, r, n) {
|
80
|
+
var i = e && e.prototype instanceof Generator ? e : Generator,
|
81
|
+
a = Object.create(i.prototype),
|
82
|
+
c = new Context(n || []);
|
83
|
+
return o(a, "_invoke", {
|
84
|
+
value: makeInvokeMethod(t, r, c)
|
85
|
+
}), a;
|
86
|
+
}
|
87
|
+
function tryCatch(t, e, r) {
|
88
|
+
try {
|
89
|
+
return {
|
90
|
+
type: "normal",
|
91
|
+
arg: t.call(e, r)
|
92
|
+
};
|
93
|
+
} catch (t) {
|
94
|
+
return {
|
95
|
+
type: "throw",
|
96
|
+
arg: t
|
97
|
+
};
|
98
|
+
}
|
99
|
+
}
|
100
|
+
e.wrap = wrap;
|
101
|
+
var h = "suspendedStart",
|
102
|
+
l = "suspendedYield",
|
103
|
+
f = "executing",
|
104
|
+
s = "completed",
|
105
|
+
y = {};
|
106
|
+
function Generator() {}
|
107
|
+
function GeneratorFunction() {}
|
108
|
+
function GeneratorFunctionPrototype() {}
|
109
|
+
var p = {};
|
110
|
+
define(p, a, function () {
|
111
|
+
return this;
|
112
|
+
});
|
113
|
+
var d = Object.getPrototypeOf,
|
114
|
+
v = d && d(d(values([])));
|
115
|
+
v && v !== r && n.call(v, a) && (p = v);
|
116
|
+
var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p);
|
117
|
+
function defineIteratorMethods(t) {
|
118
|
+
["next", "throw", "return"].forEach(function (e) {
|
119
|
+
define(t, e, function (t) {
|
120
|
+
return this._invoke(e, t);
|
121
|
+
});
|
122
|
+
});
|
123
|
+
}
|
124
|
+
function AsyncIterator(t, e) {
|
125
|
+
function invoke(r, o, i, a) {
|
126
|
+
var c = tryCatch(t[r], t, o);
|
127
|
+
if ("throw" !== c.type) {
|
128
|
+
var u = c.arg,
|
129
|
+
h = u.value;
|
130
|
+
return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) {
|
131
|
+
invoke("next", t, i, a);
|
132
|
+
}, function (t) {
|
133
|
+
invoke("throw", t, i, a);
|
134
|
+
}) : e.resolve(h).then(function (t) {
|
135
|
+
u.value = t, i(u);
|
136
|
+
}, function (t) {
|
137
|
+
return invoke("throw", t, i, a);
|
138
|
+
});
|
139
|
+
}
|
140
|
+
a(c.arg);
|
141
|
+
}
|
142
|
+
var r;
|
143
|
+
o(this, "_invoke", {
|
144
|
+
value: function (t, n) {
|
145
|
+
function callInvokeWithMethodAndArg() {
|
146
|
+
return new e(function (e, r) {
|
147
|
+
invoke(t, n, e, r);
|
148
|
+
});
|
149
|
+
}
|
150
|
+
return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
|
151
|
+
}
|
152
|
+
});
|
153
|
+
}
|
154
|
+
function makeInvokeMethod(e, r, n) {
|
155
|
+
var o = h;
|
156
|
+
return function (i, a) {
|
157
|
+
if (o === f) throw Error("Generator is already running");
|
158
|
+
if (o === s) {
|
159
|
+
if ("throw" === i) throw a;
|
160
|
+
return {
|
161
|
+
value: t,
|
162
|
+
done: !0
|
163
|
+
};
|
164
|
+
}
|
165
|
+
for (n.method = i, n.arg = a;;) {
|
166
|
+
var c = n.delegate;
|
167
|
+
if (c) {
|
168
|
+
var u = maybeInvokeDelegate(c, n);
|
169
|
+
if (u) {
|
170
|
+
if (u === y) continue;
|
171
|
+
return u;
|
172
|
+
}
|
173
|
+
}
|
174
|
+
if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
|
175
|
+
if (o === h) throw o = s, n.arg;
|
176
|
+
n.dispatchException(n.arg);
|
177
|
+
} else "return" === n.method && n.abrupt("return", n.arg);
|
178
|
+
o = f;
|
179
|
+
var p = tryCatch(e, r, n);
|
180
|
+
if ("normal" === p.type) {
|
181
|
+
if (o = n.done ? s : l, p.arg === y) continue;
|
182
|
+
return {
|
183
|
+
value: p.arg,
|
184
|
+
done: n.done
|
185
|
+
};
|
186
|
+
}
|
187
|
+
"throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
|
188
|
+
}
|
189
|
+
};
|
190
|
+
}
|
191
|
+
function maybeInvokeDelegate(e, r) {
|
192
|
+
var n = r.method,
|
193
|
+
o = e.iterator[n];
|
194
|
+
if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
|
195
|
+
var i = tryCatch(o, e.iterator, r.arg);
|
196
|
+
if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
|
197
|
+
var a = i.arg;
|
198
|
+
return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
|
199
|
+
}
|
200
|
+
function pushTryEntry(t) {
|
201
|
+
var e = {
|
202
|
+
tryLoc: t[0]
|
203
|
+
};
|
204
|
+
1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
|
205
|
+
}
|
206
|
+
function resetTryEntry(t) {
|
207
|
+
var e = t.completion || {};
|
208
|
+
e.type = "normal", delete e.arg, t.completion = e;
|
209
|
+
}
|
210
|
+
function Context(t) {
|
211
|
+
this.tryEntries = [{
|
212
|
+
tryLoc: "root"
|
213
|
+
}], t.forEach(pushTryEntry, this), this.reset(!0);
|
214
|
+
}
|
215
|
+
function values(e) {
|
216
|
+
if (e || "" === e) {
|
217
|
+
var r = e[a];
|
218
|
+
if (r) return r.call(e);
|
219
|
+
if ("function" == typeof e.next) return e;
|
220
|
+
if (!isNaN(e.length)) {
|
221
|
+
var o = -1,
|
222
|
+
i = function next() {
|
223
|
+
for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
|
224
|
+
return next.value = t, next.done = !0, next;
|
225
|
+
};
|
226
|
+
return i.next = i;
|
227
|
+
}
|
228
|
+
}
|
229
|
+
throw new TypeError(typeof e + " is not iterable");
|
230
|
+
}
|
231
|
+
return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
|
232
|
+
value: GeneratorFunctionPrototype,
|
233
|
+
configurable: !0
|
234
|
+
}), o(GeneratorFunctionPrototype, "constructor", {
|
235
|
+
value: GeneratorFunction,
|
236
|
+
configurable: !0
|
237
|
+
}), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
|
238
|
+
var e = "function" == typeof t && t.constructor;
|
239
|
+
return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
|
240
|
+
}, e.mark = function (t) {
|
241
|
+
return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
|
242
|
+
}, e.awrap = function (t) {
|
243
|
+
return {
|
244
|
+
__await: t
|
245
|
+
};
|
246
|
+
}, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
|
247
|
+
return this;
|
248
|
+
}), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
|
249
|
+
void 0 === i && (i = Promise);
|
250
|
+
var a = new AsyncIterator(wrap(t, r, n, o), i);
|
251
|
+
return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
|
252
|
+
return t.done ? t.value : a.next();
|
253
|
+
});
|
254
|
+
}, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () {
|
255
|
+
return this;
|
256
|
+
}), define(g, "toString", function () {
|
257
|
+
return "[object Generator]";
|
258
|
+
}), e.keys = function (t) {
|
259
|
+
var e = Object(t),
|
260
|
+
r = [];
|
261
|
+
for (var n in e) r.push(n);
|
262
|
+
return r.reverse(), function next() {
|
263
|
+
for (; r.length;) {
|
264
|
+
var t = r.pop();
|
265
|
+
if (t in e) return next.value = t, next.done = !1, next;
|
266
|
+
}
|
267
|
+
return next.done = !0, next;
|
268
|
+
};
|
269
|
+
}, e.values = values, Context.prototype = {
|
270
|
+
constructor: Context,
|
271
|
+
reset: function (e) {
|
272
|
+
if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
|
273
|
+
},
|
274
|
+
stop: function () {
|
275
|
+
this.done = !0;
|
276
|
+
var t = this.tryEntries[0].completion;
|
277
|
+
if ("throw" === t.type) throw t.arg;
|
278
|
+
return this.rval;
|
279
|
+
},
|
280
|
+
dispatchException: function (e) {
|
281
|
+
if (this.done) throw e;
|
282
|
+
var r = this;
|
283
|
+
function handle(n, o) {
|
284
|
+
return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
|
285
|
+
}
|
286
|
+
for (var o = this.tryEntries.length - 1; o >= 0; --o) {
|
287
|
+
var i = this.tryEntries[o],
|
288
|
+
a = i.completion;
|
289
|
+
if ("root" === i.tryLoc) return handle("end");
|
290
|
+
if (i.tryLoc <= this.prev) {
|
291
|
+
var c = n.call(i, "catchLoc"),
|
292
|
+
u = n.call(i, "finallyLoc");
|
293
|
+
if (c && u) {
|
294
|
+
if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
|
295
|
+
if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
|
296
|
+
} else if (c) {
|
297
|
+
if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
|
298
|
+
} else {
|
299
|
+
if (!u) throw Error("try statement without catch or finally");
|
300
|
+
if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
|
301
|
+
}
|
302
|
+
}
|
303
|
+
}
|
304
|
+
},
|
305
|
+
abrupt: function (t, e) {
|
306
|
+
for (var r = this.tryEntries.length - 1; r >= 0; --r) {
|
307
|
+
var o = this.tryEntries[r];
|
308
|
+
if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
|
309
|
+
var i = o;
|
310
|
+
break;
|
311
|
+
}
|
312
|
+
}
|
313
|
+
i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
|
314
|
+
var a = i ? i.completion : {};
|
315
|
+
return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
|
316
|
+
},
|
317
|
+
complete: function (t, e) {
|
318
|
+
if ("throw" === t.type) throw t.arg;
|
319
|
+
return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
|
320
|
+
},
|
321
|
+
finish: function (t) {
|
322
|
+
for (var e = this.tryEntries.length - 1; e >= 0; --e) {
|
323
|
+
var r = this.tryEntries[e];
|
324
|
+
if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
|
325
|
+
}
|
326
|
+
},
|
327
|
+
catch: function (t) {
|
328
|
+
for (var e = this.tryEntries.length - 1; e >= 0; --e) {
|
329
|
+
var r = this.tryEntries[e];
|
330
|
+
if (r.tryLoc === t) {
|
331
|
+
var n = r.completion;
|
332
|
+
if ("throw" === n.type) {
|
333
|
+
var o = n.arg;
|
334
|
+
resetTryEntry(r);
|
335
|
+
}
|
336
|
+
return o;
|
337
|
+
}
|
338
|
+
}
|
339
|
+
throw Error("illegal catch attempt");
|
340
|
+
},
|
341
|
+
delegateYield: function (e, r, n) {
|
342
|
+
return this.delegate = {
|
343
|
+
iterator: values(e),
|
344
|
+
resultName: r,
|
345
|
+
nextLoc: n
|
346
|
+
}, "next" === this.method && (this.arg = t), y;
|
347
|
+
}
|
348
|
+
}, e;
|
349
|
+
}
|
49
350
|
function _toPrimitive(t, r) {
|
50
351
|
if ("object" != typeof t || !t) return t;
|
51
352
|
var e = t[Symbol.toPrimitive];
|
@@ -69,6 +370,36 @@ function _typeof(o) {
|
|
69
370
|
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
70
371
|
}, _typeof(o);
|
71
372
|
}
|
373
|
+
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
374
|
+
try {
|
375
|
+
var info = gen[key](arg);
|
376
|
+
var value = info.value;
|
377
|
+
} catch (error) {
|
378
|
+
reject(error);
|
379
|
+
return;
|
380
|
+
}
|
381
|
+
if (info.done) {
|
382
|
+
resolve(value);
|
383
|
+
} else {
|
384
|
+
Promise.resolve(value).then(_next, _throw);
|
385
|
+
}
|
386
|
+
}
|
387
|
+
function _asyncToGenerator(fn) {
|
388
|
+
return function () {
|
389
|
+
var self = this,
|
390
|
+
args = arguments;
|
391
|
+
return new Promise(function (resolve, reject) {
|
392
|
+
var gen = fn.apply(self, args);
|
393
|
+
function _next(value) {
|
394
|
+
asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);
|
395
|
+
}
|
396
|
+
function _throw(err) {
|
397
|
+
asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);
|
398
|
+
}
|
399
|
+
_next(undefined);
|
400
|
+
});
|
401
|
+
};
|
402
|
+
}
|
72
403
|
function _classCallCheck(instance, Constructor) {
|
73
404
|
if (!(instance instanceof Constructor)) {
|
74
405
|
throw new TypeError("Cannot call a class as a function");
|
@@ -184,5 +515,5 @@ function _nonIterableRest() {
|
|
184
515
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
185
516
|
}
|
186
517
|
|
187
|
-
export { _arrayLikeToArray as arrayLikeToArray, _arrayWithHoles as arrayWithHoles, _arrayWithoutHoles as arrayWithoutHoles, _classCallCheck as classCallCheck, _createClass as createClass, _defineProperty as defineProperty, _extends as extends, _iterableToArray as iterableToArray, _iterableToArrayLimit as iterableToArrayLimit, _nonIterableRest as nonIterableRest, _nonIterableSpread as nonIterableSpread, _objectSpread2 as objectSpread2, _objectWithoutProperties as objectWithoutProperties, _objectWithoutPropertiesLoose as objectWithoutPropertiesLoose, _slicedToArray as slicedToArray, _toArray as toArray, _toConsumableArray as toConsumableArray, _toPrimitive as toPrimitive, _toPropertyKey as toPropertyKey, _typeof as typeof, _unsupportedIterableToArray as unsupportedIterableToArray };
|
518
|
+
export { _arrayLikeToArray as arrayLikeToArray, _arrayWithHoles as arrayWithHoles, _arrayWithoutHoles as arrayWithoutHoles, _asyncToGenerator as asyncToGenerator, _classCallCheck as classCallCheck, _createClass as createClass, _defineProperty as defineProperty, _extends as extends, _iterableToArray as iterableToArray, _iterableToArrayLimit as iterableToArrayLimit, _nonIterableRest as nonIterableRest, _nonIterableSpread as nonIterableSpread, _objectSpread2 as objectSpread2, _objectWithoutProperties as objectWithoutProperties, _objectWithoutPropertiesLoose as objectWithoutPropertiesLoose, _regeneratorRuntime as regeneratorRuntime, _slicedToArray as slicedToArray, _toArray as toArray, _toConsumableArray as toConsumableArray, _toPrimitive as toPrimitive, _toPropertyKey as toPropertyKey, _typeof as typeof, _unsupportedIterableToArray as unsupportedIterableToArray };
|
188
519
|
//# sourceMappingURL=_rollupPluginBabelHelpers.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"_rollupPluginBabelHelpers.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"_rollupPluginBabelHelpers.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
@@ -0,0 +1,15 @@
|
|
1
|
+
.IconRoot_7pl7ig_svvlqhf__32c458a1{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;width:var(--svvlqhf-0);height:var(--svvlqhf-0);-webkit-flex:0 0 var(--svvlqhf-0);-ms-flex:0 0 var(--svvlqhf-0);flex:0 0 var(--svvlqhf-0);}
|
2
|
+
|
3
|
+
.base_1pdzq6t_byh8zio__d97f375f{background:var(--plasma-dropzone-background);border:var(--plasma-dropzone-border-color);}.base_1pdzq6t_byh8zio__d97f375f:not(.base_1pdzq6t_dropzoneActive__d97f375f):hover,.base_1pdzq6t_byh8zio__d97f375f:not(.base_1pdzq6t_dropzoneActive__d97f375f):focus-within{background:var(--plasma-dropzone-background-hover);border-color:var(--plasma-dropzone-border-color-hover);outline:none;}.base_1pdzq6t_byh8zio__d97f375f.base_1pdzq6t_dropzoneActive__d97f375f{border-color:var(--plasma-dropzone-border-color-active);}.base_1pdzq6t_byh8zio__d97f375f.base_1pdzq6t_dropzoneActive__d97f375f .base_1pdzq6t_dqiwesh__d97f375f{background:var(--plasma-dropzone-overlay-color-active);}.base_1pdzq6t_byh8zio__d97f375f .base_1pdzq6t_twnyozc__d97f375f{color:var(--plasma-dropzone-title-color);}.base_1pdzq6t_byh8zio__d97f375f .base_1pdzq6t_d1nsxook__d97f375f{color:var(--plasma-dropzone-description-color);}
|
4
|
+
|
5
|
+
.base_1bt22g1_b1q81cck__c0e52b1e{padding:var(--plasma-dropzone-padding);border-radius:var(--plasma-dropzone-border-radius);height:var(--plasma_private-dropzone-height);width:var(--plasma_private-dropzone-width);}.base_1bt22g1_b1q81cck__c0e52b1e.base_1bt22g1_dropzoneStretch__c0e52b1e{width:100%;}.base_1bt22g1_b1q81cck__c0e52b1e .base_1bt22g1_dqiwesh__c0e52b1e{border-radius:var(--plasma-dropzone-border-radius);}.base_1bt22g1_b1q81cck__c0e52b1e .base_1bt22g1_c1afz1o5__c0e52b1e{gap:var(--plasma-dropzone-content-gap);}.base_1bt22g1_b1q81cck__c0e52b1e .base_1bt22g1_twnyozc__c0e52b1e{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;gap:var(--plasma-dropzone-title-wrapper-gap);}.base_1bt22g1_b1q81cck__c0e52b1e .base_1bt22g1_twnyozc__c0e52b1e.base_1bt22g1_dropzoneVerticalContentPlacing__c0e52b1e{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;gap:var(--plasma-dropzone-title-wrapper-column-gap);}.base_1bt22g1_b1q81cck__c0e52b1e .base_1bt22g1_tahwclk__c0e52b1e{font-family:var(--plasma-dropzone-title-font-family);font-size:var(--plasma-dropzone-title-font-size);font-style:var(--plasma-dropzone-title-font-style);font-weight:var(--plasma-dropzone-title-font-weight);-webkit-letter-spacing:var(--plasma-dropzone-title-letter-spacing);-moz-letter-spacing:var(--plasma-dropzone-title-letter-spacing);-ms-letter-spacing:var(--plasma-dropzone-title-letter-spacing);letter-spacing:var(--plasma-dropzone-title-letter-spacing);line-height:var(--plasma-dropzone-title-line-height);}.base_1bt22g1_b1q81cck__c0e52b1e .base_1bt22g1_d1nsxook__c0e52b1e{font-family:var(--plasma-dropzone-description-font-family);font-size:var(--plasma-dropzone-description-font-size);font-style:var(--plasma-dropzone-description-font-style);font-weight:var(--plasma-dropzone-description-font-weight);-webkit-letter-spacing:var(--plasma-dropzone-description-letter-spacing);-moz-letter-spacing:var(--plasma-dropzone-description-letter-spacing);-ms-letter-spacing:var(--plasma-dropzone-description-letter-spacing);letter-spacing:var(--plasma-dropzone-description-letter-spacing);line-height:var(--plasma-dropzone-description-line-height);}
|
6
|
+
|
7
|
+
.base_3qwygi_b1t0rfqa__f5b3e7aa.base_3qwygi_dropzoneDisabled__f5b3e7aa{opacity:var(--plasma-dropzone-disabled-opacity);cursor:not-allowed;}
|
8
|
+
|
9
|
+
.Dropzone_styles_1fo7dbq_bfglrd7__65c68d0a{position:relative;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;cursor:pointer;}
|
10
|
+
.Dropzone_styles_1fo7dbq_dqiwesh__65c68d0a{position:absolute;top:0;left:0;width:100%;height:100%;z-index:2;}
|
11
|
+
.Dropzone_styles_1fo7dbq_c1afz1o5__65c68d0a{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;}
|
12
|
+
|
13
|
+
|
14
|
+
|
15
|
+
.Dropzone_styles_1fo7dbq_hzipmyu__65c68d0a{display:none;}
|
@@ -0,0 +1,247 @@
|
|
1
|
+
import { objectWithoutProperties as _objectWithoutProperties, slicedToArray as _slicedToArray, objectSpread2 as _objectSpread2, defineProperty as _defineProperty, extends as _extends, asyncToGenerator as _asyncToGenerator, regeneratorRuntime as _regeneratorRuntime, toConsumableArray as _toConsumableArray } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
2
|
+
import React, { forwardRef, useState, useRef } from 'react';
|
3
|
+
import { useForkRef } from '@salutejs/plasma-core';
|
4
|
+
import { cx } from '../../utils/index.js';
|
5
|
+
import { base as base$1 } from './variations/_view/base.js';
|
6
|
+
import { base as base$2 } from './variations/_size/base.js';
|
7
|
+
import { base as base$3 } from './variations/_disabled/base.js';
|
8
|
+
import { DropzoneHandlerOverlay, Content, TitleWrapper, Title, Description, HiddenInput, base } from './Dropzone.styles.js';
|
9
|
+
import { classes, privateTokens } from './Dropzone.tokens.js';
|
10
|
+
import { IconArrowBarDown } from '../_Icon/Icons/IconArrowBarDown.js';
|
11
|
+
import { getSizeValueFromProp } from '../../utils/getSizeValueFromProp.js';
|
12
|
+
|
13
|
+
var _IconArrowBarDown;
|
14
|
+
var _excluded = ["className", "style", "accept", "multiple", "title", "description", "icon", "iconPlacement", "size", "view", "disabled", "stretch", "width", "height", "onDragEnter", "onDragLeave", "onDragOver", "onDrop", "validator", "onClick", "onChange", "onChoseFiles"];
|
15
|
+
var dropzoneRoot = function dropzoneRoot(Root) {
|
16
|
+
return /*#__PURE__*/forwardRef(function (_ref, outerRef) {
|
17
|
+
var className = _ref.className,
|
18
|
+
style = _ref.style,
|
19
|
+
accept = _ref.accept,
|
20
|
+
multiple = _ref.multiple,
|
21
|
+
title = _ref.title,
|
22
|
+
description = _ref.description,
|
23
|
+
icon = _ref.icon,
|
24
|
+
iconPlacement = _ref.iconPlacement,
|
25
|
+
size = _ref.size,
|
26
|
+
view = _ref.view,
|
27
|
+
disabled = _ref.disabled,
|
28
|
+
stretch = _ref.stretch,
|
29
|
+
width = _ref.width,
|
30
|
+
height = _ref.height,
|
31
|
+
onDragEnter = _ref.onDragEnter,
|
32
|
+
onDragLeave = _ref.onDragLeave,
|
33
|
+
onDragOver = _ref.onDragOver,
|
34
|
+
onDrop = _ref.onDrop,
|
35
|
+
validator = _ref.validator,
|
36
|
+
onClick = _ref.onClick,
|
37
|
+
onChange = _ref.onChange,
|
38
|
+
onChoseFiles = _ref.onChoseFiles,
|
39
|
+
rest = _objectWithoutProperties(_ref, _excluded);
|
40
|
+
var _useState = useState(false),
|
41
|
+
_useState2 = _slicedToArray(_useState, 2),
|
42
|
+
isDropzoneActive = _useState2[0],
|
43
|
+
setIsDropzoneActive = _useState2[1];
|
44
|
+
var inputRef = useRef(null);
|
45
|
+
var forkInputRef = useForkRef(outerRef, inputRef);
|
46
|
+
var innerWidth = width ? getSizeValueFromProp(width) : 'fit-content';
|
47
|
+
var innerHeight = height ? getSizeValueFromProp(height) : 'fit-content';
|
48
|
+
var processFiles = /*#__PURE__*/function () {
|
49
|
+
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(rawFiles, callback, afterAction) {
|
50
|
+
var files, res;
|
51
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
52
|
+
while (1) switch (_context.prev = _context.next) {
|
53
|
+
case 0:
|
54
|
+
if (rawFiles !== null && rawFiles !== void 0 && rawFiles.length) {
|
55
|
+
_context.next = 2;
|
56
|
+
break;
|
57
|
+
}
|
58
|
+
return _context.abrupt("return");
|
59
|
+
case 2:
|
60
|
+
files = _toConsumableArray(rawFiles);
|
61
|
+
res = {
|
62
|
+
acceptedFiles: files
|
63
|
+
};
|
64
|
+
if (!validator) {
|
65
|
+
_context.next = 8;
|
66
|
+
break;
|
67
|
+
}
|
68
|
+
_context.next = 7;
|
69
|
+
return validator === null || validator === void 0 ? void 0 : validator(files);
|
70
|
+
case 7:
|
71
|
+
res = _context.sent;
|
72
|
+
case 8:
|
73
|
+
if (!callback) {
|
74
|
+
_context.next = 11;
|
75
|
+
break;
|
76
|
+
}
|
77
|
+
_context.next = 11;
|
78
|
+
return callback(res);
|
79
|
+
case 11:
|
80
|
+
if (afterAction) {
|
81
|
+
afterAction();
|
82
|
+
}
|
83
|
+
case 12:
|
84
|
+
case "end":
|
85
|
+
return _context.stop();
|
86
|
+
}
|
87
|
+
}, _callee);
|
88
|
+
}));
|
89
|
+
return function processFiles(_x, _x2, _x3) {
|
90
|
+
return _ref2.apply(this, arguments);
|
91
|
+
};
|
92
|
+
}();
|
93
|
+
var handleDragEnter = function handleDragEnter(event) {
|
94
|
+
if (disabled) {
|
95
|
+
return;
|
96
|
+
}
|
97
|
+
event.preventDefault();
|
98
|
+
event.stopPropagation();
|
99
|
+
if (onDragEnter) {
|
100
|
+
onDragEnter(event);
|
101
|
+
}
|
102
|
+
setIsDropzoneActive(true);
|
103
|
+
};
|
104
|
+
var handleDragLeave = function handleDragLeave(event) {
|
105
|
+
if (disabled) {
|
106
|
+
return;
|
107
|
+
}
|
108
|
+
event.preventDefault();
|
109
|
+
if (onDragLeave) {
|
110
|
+
onDragLeave(event);
|
111
|
+
}
|
112
|
+
setIsDropzoneActive(false);
|
113
|
+
};
|
114
|
+
var handleDragOver = function handleDragOver(event) {
|
115
|
+
if (disabled) {
|
116
|
+
return;
|
117
|
+
}
|
118
|
+
event.preventDefault();
|
119
|
+
if (onDragOver) {
|
120
|
+
onDragOver(event);
|
121
|
+
}
|
122
|
+
var rawFiles = event.dataTransfer.files;
|
123
|
+
if (!isDropzoneActive && rawFiles && rawFiles.length > 0) {
|
124
|
+
setIsDropzoneActive(true);
|
125
|
+
}
|
126
|
+
};
|
127
|
+
var handleDrop = /*#__PURE__*/function () {
|
128
|
+
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(event) {
|
129
|
+
var rawFiles, afterAction;
|
130
|
+
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
131
|
+
while (1) switch (_context2.prev = _context2.next) {
|
132
|
+
case 0:
|
133
|
+
if (!disabled) {
|
134
|
+
_context2.next = 2;
|
135
|
+
break;
|
136
|
+
}
|
137
|
+
return _context2.abrupt("return");
|
138
|
+
case 2:
|
139
|
+
event.preventDefault();
|
140
|
+
event.persist();
|
141
|
+
rawFiles = event.dataTransfer.files;
|
142
|
+
afterAction = function afterAction() {
|
143
|
+
event.dataTransfer.clearData();
|
144
|
+
setIsDropzoneActive(false);
|
145
|
+
};
|
146
|
+
_context2.next = 8;
|
147
|
+
return processFiles(rawFiles, onDrop, afterAction);
|
148
|
+
case 8:
|
149
|
+
case "end":
|
150
|
+
return _context2.stop();
|
151
|
+
}
|
152
|
+
}, _callee2);
|
153
|
+
}));
|
154
|
+
return function handleDrop(_x4) {
|
155
|
+
return _ref3.apply(this, arguments);
|
156
|
+
};
|
157
|
+
}();
|
158
|
+
var handleClick = function handleClick(event) {
|
159
|
+
if (!inputRef.current || disabled) {
|
160
|
+
return;
|
161
|
+
}
|
162
|
+
inputRef.current.click();
|
163
|
+
if (onClick) {
|
164
|
+
onClick(event);
|
165
|
+
}
|
166
|
+
};
|
167
|
+
var handleChange = /*#__PURE__*/function () {
|
168
|
+
var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3(event) {
|
169
|
+
var rawFiles;
|
170
|
+
return _regeneratorRuntime().wrap(function _callee3$(_context3) {
|
171
|
+
while (1) switch (_context3.prev = _context3.next) {
|
172
|
+
case 0:
|
173
|
+
if (!disabled) {
|
174
|
+
_context3.next = 2;
|
175
|
+
break;
|
176
|
+
}
|
177
|
+
return _context3.abrupt("return");
|
178
|
+
case 2:
|
179
|
+
if (onChange) {
|
180
|
+
onChange(event);
|
181
|
+
}
|
182
|
+
rawFiles = event.target.files;
|
183
|
+
_context3.next = 6;
|
184
|
+
return processFiles(rawFiles, onChoseFiles);
|
185
|
+
case 6:
|
186
|
+
case "end":
|
187
|
+
return _context3.stop();
|
188
|
+
}
|
189
|
+
}, _callee3);
|
190
|
+
}));
|
191
|
+
return function handleChange(_x5) {
|
192
|
+
return _ref4.apply(this, arguments);
|
193
|
+
};
|
194
|
+
}();
|
195
|
+
return /*#__PURE__*/React.createElement(Root, {
|
196
|
+
className: cx(className, isDropzoneActive && classes.active, stretch && classes.stretch, disabled && classes.disabled),
|
197
|
+
view: view,
|
198
|
+
size: size,
|
199
|
+
disabled: disabled,
|
200
|
+
tabIndex: 0,
|
201
|
+
style: _objectSpread2(_objectSpread2({}, style), {}, _defineProperty(_defineProperty({}, privateTokens.width, innerWidth), privateTokens.height, innerHeight))
|
202
|
+
}, /*#__PURE__*/React.createElement(DropzoneHandlerOverlay, {
|
203
|
+
onDragEnter: handleDragEnter,
|
204
|
+
onDragLeave: handleDragLeave,
|
205
|
+
onDragOver: handleDragOver,
|
206
|
+
onDrop: handleDrop,
|
207
|
+
onClick: handleClick
|
208
|
+
}), /*#__PURE__*/React.createElement(Content, null, /*#__PURE__*/React.createElement(TitleWrapper, {
|
209
|
+
className: cx(iconPlacement === 'top' && classes.verticalContentPlacing)
|
210
|
+
}, icon || _IconArrowBarDown || (_IconArrowBarDown = /*#__PURE__*/React.createElement(IconArrowBarDown, {
|
211
|
+
color: "inherit",
|
212
|
+
size: "s"
|
213
|
+
})), title && /*#__PURE__*/React.createElement(Title, null, title)), description && /*#__PURE__*/React.createElement(Description, null, description)), /*#__PURE__*/React.createElement(HiddenInput, _extends({
|
214
|
+
ref: forkInputRef,
|
215
|
+
type: "file",
|
216
|
+
accept: accept,
|
217
|
+
multiple: multiple,
|
218
|
+
tabIndex: -1,
|
219
|
+
onChange: handleChange
|
220
|
+
}, rest)));
|
221
|
+
});
|
222
|
+
};
|
223
|
+
var dropzoneConfig = {
|
224
|
+
name: 'Dropzone',
|
225
|
+
tag: 'div',
|
226
|
+
layout: dropzoneRoot,
|
227
|
+
base: base,
|
228
|
+
variations: {
|
229
|
+
view: {
|
230
|
+
css: base$1
|
231
|
+
},
|
232
|
+
size: {
|
233
|
+
css: base$2
|
234
|
+
},
|
235
|
+
disabled: {
|
236
|
+
css: base$3,
|
237
|
+
attrs: true
|
238
|
+
}
|
239
|
+
},
|
240
|
+
defaults: {
|
241
|
+
view: 'default',
|
242
|
+
size: 'm'
|
243
|
+
}
|
244
|
+
};
|
245
|
+
|
246
|
+
export { dropzoneConfig, dropzoneRoot };
|
247
|
+
//# sourceMappingURL=Dropzone.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"Dropzone.js","sources":["../../../src/components/Dropzone/Dropzone.tsx"],"sourcesContent":["import React, { forwardRef, useRef, useState } from 'react';\nimport type { ChangeEvent, CSSProperties, DragEvent, MouseEvent } from 'react';\nimport { useForkRef } from '@salutejs/plasma-core';\n\nimport { cx, getSizeValueFromProp } from '../../utils';\nimport { IconArrowBarDown } from '../../components/_Icon';\nimport type { RootProps } from '../../engines';\n\nimport type { DropzoneProps, DropzoneRootProps, FileArgs, FileProcessHandler } from './Dropzone.types';\nimport { base as viewCSS } from './variations/_view/base';\nimport { base as sizeCSS } from './variations/_size/base';\nimport { base as disabledCSS } from './variations/_disabled/base';\nimport {\n base,\n Content,\n Description,\n DropzoneHandlerOverlay,\n HiddenInput,\n Title,\n TitleWrapper,\n} from './Dropzone.styles';\nimport { classes, privateTokens } from './Dropzone.tokens';\n\nexport const dropzoneRoot = (Root: RootProps<HTMLDivElement, DropzoneRootProps>) =>\n forwardRef<HTMLInputElement, DropzoneProps>(\n (\n {\n className,\n style,\n accept,\n multiple,\n title,\n description,\n icon,\n iconPlacement,\n size,\n view,\n disabled,\n stretch,\n width,\n height,\n onDragEnter,\n onDragLeave,\n onDragOver,\n onDrop,\n validator,\n onClick,\n onChange,\n onChoseFiles,\n ...rest\n },\n outerRef,\n ) => {\n const [isDropzoneActive, setIsDropzoneActive] = useState(false);\n\n const inputRef = useRef<HTMLInputElement>(null);\n const forkInputRef = useForkRef(outerRef, inputRef);\n\n const innerWidth = width ? getSizeValueFromProp(width) : 'fit-content';\n const innerHeight = height ? getSizeValueFromProp(height) : 'fit-content';\n\n const processFiles = async (\n rawFiles: FileList | null,\n callback?: FileProcessHandler,\n afterAction?: () => void,\n ) => {\n if (!rawFiles?.length) {\n return;\n }\n\n const files = [...rawFiles];\n let res: FileArgs = {\n acceptedFiles: files,\n };\n\n if (validator) {\n res = await validator?.(files);\n }\n\n if (callback) {\n await callback(res);\n }\n\n if (afterAction) {\n afterAction();\n }\n };\n\n const handleDragEnter = (event: DragEvent<HTMLDivElement>) => {\n if (disabled) {\n return;\n }\n\n event.preventDefault();\n event.stopPropagation();\n\n if (onDragEnter) {\n onDragEnter(event);\n }\n\n setIsDropzoneActive(true);\n };\n\n const handleDragLeave = (event: DragEvent<HTMLDivElement>) => {\n if (disabled) {\n return;\n }\n\n event.preventDefault();\n\n if (onDragLeave) {\n onDragLeave(event);\n }\n\n setIsDropzoneActive(false);\n };\n\n const handleDragOver = (event: DragEvent<HTMLDivElement>) => {\n if (disabled) {\n return;\n }\n\n event.preventDefault();\n\n if (onDragOver) {\n onDragOver(event);\n }\n\n const { files: rawFiles } = event.dataTransfer;\n\n if (!isDropzoneActive && rawFiles && rawFiles.length > 0) {\n setIsDropzoneActive(true);\n }\n };\n\n const handleDrop = async (event: DragEvent<HTMLDivElement>) => {\n if (disabled) {\n return;\n }\n\n event.preventDefault();\n event.persist();\n\n const { files: rawFiles } = event.dataTransfer;\n const afterAction = () => {\n event.dataTransfer.clearData();\n setIsDropzoneActive(false);\n };\n\n await processFiles(rawFiles, onDrop, afterAction);\n };\n\n const handleClick = (event: MouseEvent<HTMLInputElement>) => {\n if (!inputRef.current || disabled) {\n return;\n }\n\n inputRef.current.click();\n\n if (onClick) {\n onClick(event);\n }\n };\n\n const handleChange = async (event: ChangeEvent<HTMLInputElement>) => {\n if (disabled) {\n return;\n }\n\n if (onChange) {\n onChange(event);\n }\n\n const { files: rawFiles } = event.target;\n\n await processFiles(rawFiles, onChoseFiles);\n };\n\n return (\n <Root\n className={cx(\n className,\n isDropzoneActive && classes.active,\n stretch && classes.stretch,\n disabled && classes.disabled,\n )}\n view={view}\n size={size}\n disabled={disabled}\n tabIndex={0}\n style={\n {\n ...style,\n [privateTokens.width]: innerWidth,\n [privateTokens.height]: innerHeight,\n } as CSSProperties\n }\n >\n <DropzoneHandlerOverlay\n onDragEnter={handleDragEnter}\n onDragLeave={handleDragLeave}\n onDragOver={handleDragOver}\n onDrop={handleDrop}\n onClick={handleClick}\n />\n <Content>\n <TitleWrapper className={cx(iconPlacement === 'top' && classes.verticalContentPlacing)}>\n {icon || <IconArrowBarDown color=\"inherit\" size=\"s\" />}\n {title && <Title>{title}</Title>}\n </TitleWrapper>\n {description && <Description>{description}</Description>}\n </Content>\n <HiddenInput\n ref={forkInputRef}\n type=\"file\"\n accept={accept}\n multiple={multiple}\n tabIndex={-1}\n onChange={handleChange}\n {...rest}\n />\n </Root>\n );\n },\n );\n\nexport const dropzoneConfig = {\n name: 'Dropzone',\n tag: 'div',\n layout: dropzoneRoot,\n base,\n variations: {\n view: {\n css: viewCSS,\n },\n size: {\n css: sizeCSS,\n },\n disabled: {\n css: disabledCSS,\n attrs: true,\n },\n },\n defaults: {\n view: 'default',\n size: 'm',\n },\n};\n"],"names":["dropzoneRoot","Root","forwardRef","_ref","outerRef","className","style","accept","multiple","title","description","icon","iconPlacement","size","view","disabled","stretch","width","height","onDragEnter","onDragLeave","onDragOver","onDrop","validator","onClick","onChange","onChoseFiles","rest","_objectWithoutProperties","_excluded","_useState","useState","_useState2","_slicedToArray","isDropzoneActive","setIsDropzoneActive","inputRef","useRef","forkInputRef","useForkRef","innerWidth","getSizeValueFromProp","innerHeight","processFiles","_ref2","_asyncToGenerator","_regeneratorRuntime","mark","_callee","rawFiles","callback","afterAction","files","res","wrap","_callee$","_context","prev","next","length","abrupt","_toConsumableArray","acceptedFiles","sent","stop","_x","_x2","_x3","apply","arguments","handleDragEnter","event","preventDefault","stopPropagation","handleDragLeave","handleDragOver","dataTransfer","handleDrop","_ref3","_callee2","_callee2$","_context2","persist","clearData","_x4","handleClick","current","click","handleChange","_ref4","_callee3","_callee3$","_context3","target","_x5","React","createElement","cx","classes","active","tabIndex","_objectSpread","_defineProperty","privateTokens","DropzoneHandlerOverlay","Content","TitleWrapper","verticalContentPlacing","_IconArrowBarDown","IconArrowBarDown","color","Title","Description","HiddenInput","_extends","ref","type","dropzoneConfig","name","tag","layout","base","variations","css","viewCSS","sizeCSS","disabledCSS","attrs","defaults"],"mappings":";;;;;;;;;;;;;;IAuBaA,YAAY,GAA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