nectiasw 0.0.102 → 0.0.103
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/Dragarea/types.d.ts +1 -0
- package/dist/index.es.js +29 -27
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
|
@@ -22,6 +22,7 @@ export type DragareaProps = {
|
|
|
22
22
|
statusColors?: Partial<Record<DropStatus, string>>;
|
|
23
23
|
statusBorder?: Partial<Record<DropStatus, string>>;
|
|
24
24
|
renderContent?: JSX.Element;
|
|
25
|
+
renderBelowFilename?: JSX.Element;
|
|
25
26
|
statusIcons?: Partial<Record<DropStatus, React.ComponentType<any>>>;
|
|
26
27
|
};
|
|
27
28
|
export declare enum DropStatus {
|
package/dist/index.es.js
CHANGED
|
@@ -56829,41 +56829,42 @@ const Hde = ye.div`
|
|
|
56829
56829
|
renderContent: a,
|
|
56830
56830
|
onStatusChange: s,
|
|
56831
56831
|
acceptedFileType: l,
|
|
56832
|
-
|
|
56833
|
-
|
|
56834
|
-
|
|
56835
|
-
|
|
56832
|
+
renderBelowFilename: c,
|
|
56833
|
+
statusMessages: d,
|
|
56834
|
+
statusColors: h,
|
|
56835
|
+
statusBorder: m,
|
|
56836
|
+
statusIcons: g = {
|
|
56836
56837
|
[Ei.DragActive]: ek,
|
|
56837
56838
|
[Ei.InvalidType]: tk,
|
|
56838
56839
|
[Ei.WithError]: tk,
|
|
56839
56840
|
[Ei.Reload]: jde
|
|
56840
56841
|
},
|
|
56841
|
-
...
|
|
56842
|
+
...x
|
|
56842
56843
|
}) => {
|
|
56843
|
-
const
|
|
56844
|
+
const v = {
|
|
56844
56845
|
[Ei.DragActive]: [
|
|
56845
56846
|
"Mensaje personalizado 1",
|
|
56846
56847
|
"Mensaje personalizado 2"
|
|
56847
56848
|
]
|
|
56848
|
-
}, v = {
|
|
56849
|
-
[Ei.WithError]: "red"
|
|
56850
56849
|
}, f = {
|
|
56850
|
+
[Ei.WithError]: "red"
|
|
56851
|
+
}, b = {
|
|
56851
56852
|
[Ei.DragActive]: "green"
|
|
56852
|
-
},
|
|
56853
|
-
(
|
|
56854
|
-
const
|
|
56855
|
-
o == null || o(
|
|
56853
|
+
}, w = Ft(
|
|
56854
|
+
(L) => {
|
|
56855
|
+
const Y = L[0];
|
|
56856
|
+
o == null || o(Y);
|
|
56856
56857
|
},
|
|
56857
56858
|
[o]
|
|
56858
|
-
), { getRootProps:
|
|
56859
|
+
), { getRootProps: y, getInputProps: S, isDragActive: _, fileRejections: k } = b7({
|
|
56859
56860
|
accept: l,
|
|
56860
56861
|
maxSize: r,
|
|
56861
56862
|
maxFiles: 1,
|
|
56862
|
-
onDrop:
|
|
56863
|
+
onDrop: w,
|
|
56863
56864
|
onDropRejected: () => {
|
|
56864
|
-
if (
|
|
56865
|
-
const { code:
|
|
56866
|
-
switch (
|
|
56865
|
+
if (k.length > 0) {
|
|
56866
|
+
const { code: L } = k[0].errors[0];
|
|
56867
|
+
switch (L) {
|
|
56867
56868
|
case "file-too-large":
|
|
56868
56869
|
s == null || s(Ei.FileTooBig);
|
|
56869
56870
|
break;
|
|
@@ -56873,21 +56874,21 @@ const Hde = ye.div`
|
|
|
56873
56874
|
}
|
|
56874
56875
|
}
|
|
56875
56876
|
}
|
|
56876
|
-
}),
|
|
56877
|
+
}), D = e || Ei.DragActive, O = (g == null ? void 0 : g[D]) || ek;
|
|
56877
56878
|
e = e || Ei.DragActive;
|
|
56878
|
-
const
|
|
56879
|
+
const M = (h == null ? void 0 : h[e]) ?? f[e] ?? [], F = (m == null ? void 0 : m[e]) ?? b[e] ?? [], N = (d == null ? void 0 : d[e]) ?? v[e] ?? [];
|
|
56879
56880
|
return /* @__PURE__ */ he(
|
|
56880
56881
|
Hde,
|
|
56881
56882
|
{
|
|
56882
|
-
...
|
|
56883
|
-
isDragActive:
|
|
56884
|
-
borderColor:
|
|
56883
|
+
...y(),
|
|
56884
|
+
isDragActive: _,
|
|
56885
|
+
borderColor: F,
|
|
56885
56886
|
wrongColor: t,
|
|
56886
56887
|
successColor: i,
|
|
56887
|
-
...
|
|
56888
|
+
...x,
|
|
56888
56889
|
children: [
|
|
56889
|
-
|
|
56890
|
-
e && [Ei.WithError, Ei.Reload].includes(e) && n && /* @__PURE__ */ he(Ude, { backgroundColor:
|
|
56890
|
+
O && /* @__PURE__ */ B(O, {}),
|
|
56891
|
+
e && [Ei.WithError, Ei.Reload].includes(e) && n && /* @__PURE__ */ he(Ude, { backgroundColor: M, children: [
|
|
56891
56892
|
/* @__PURE__ */ B(Yde, {}),
|
|
56892
56893
|
" ",
|
|
56893
56894
|
/* @__PURE__ */ he("p", { children: [
|
|
@@ -56896,11 +56897,12 @@ const Hde = ye.div`
|
|
|
56896
56897
|
" "
|
|
56897
56898
|
] })
|
|
56898
56899
|
] }),
|
|
56900
|
+
c && c,
|
|
56899
56901
|
/* @__PURE__ */ he(Wde, { children: [
|
|
56900
|
-
|
|
56902
|
+
N.filter(Boolean).map((L) => /* @__PURE__ */ B("p", { children: L }, L)),
|
|
56901
56903
|
a && a
|
|
56902
56904
|
] }),
|
|
56903
|
-
/* @__PURE__ */ B($de, { ...
|
|
56905
|
+
/* @__PURE__ */ B($de, { ...S() })
|
|
56904
56906
|
]
|
|
56905
56907
|
}
|
|
56906
56908
|
);
|