New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@wethegit/react-gallery

Package Overview
Dependencies
Maintainers
3
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@wethegit/react-gallery - npm Package Compare versions

Comparing version 4.0.0 to 4.0.1

1766

dist/react-gallery.js

@@ -1,6 +0,3 @@

import dr, { createContext as Yr, useState as Ie, useRef as Fr, useCallback as pe, useEffect as Wr, useContext as qr } from "react";
function Nr(r) {
return r && r.__esModule && Object.prototype.hasOwnProperty.call(r, "default") ? r.default : r;
}
var We = { exports: {} }, Ee = {};
import Ne, { createContext as pr, useState as ce, useRef as mr, useCallback as L, useEffect as hr, useContext as br } from "react";
var fe = { exports: {} }, q = {};
/**

@@ -15,21 +12,21 @@ * @license React

*/
var rr;
function Lr() {
if (rr)
return Ee;
rr = 1;
var r = dr, _ = Symbol.for("react.element"), b = Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, m = r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, v = { key: !0, ref: !0, __self: !0, __source: !0 };
function y(c, u, f) {
var d, p = {}, P = null, F = null;
f !== void 0 && (P = "" + f), u.key !== void 0 && (P = "" + u.key), u.ref !== void 0 && (F = u.ref);
for (d in u)
s.call(u, d) && !v.hasOwnProperty(d) && (p[d] = u[d]);
if (c && c.defaultProps)
for (d in u = c.defaultProps, u)
p[d] === void 0 && (p[d] = u[d]);
return { $$typeof: _, type: c, key: P, ref: F, props: p, _owner: m.current };
var We;
function Er() {
if (We)
return q;
We = 1;
var i = Ne, _ = Symbol.for("react.element"), m = Symbol.for("react.fragment"), y = Object.prototype.hasOwnProperty, R = i.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, d = { key: !0, ref: !0, __self: !0, __source: !0 };
function s(v, n, o) {
var f, E = {}, T = null, A = null;
o !== void 0 && (T = "" + o), n.key !== void 0 && (T = "" + n.key), n.ref !== void 0 && (A = n.ref);
for (f in n)
y.call(n, f) && !d.hasOwnProperty(f) && (E[f] = n[f]);
if (v && v.defaultProps)
for (f in n = v.defaultProps, n)
E[f] === void 0 && (E[f] = n[f]);
return { $$typeof: _, type: v, key: T, ref: A, props: E, _owner: R.current };
}
return Ee.Fragment = b, Ee.jsx = y, Ee.jsxs = y, Ee;
return q.Fragment = m, q.jsx = s, q.jsxs = s, q;
}
var Te = {};
var J = {};
/**

@@ -44,53 +41,53 @@ * @license React

*/
var tr;
function Ur() {
return tr || (tr = 1, process.env.NODE_ENV !== "production" && function() {
var r = dr, _ = Symbol.for("react.element"), b = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), m = Symbol.for("react.strict_mode"), v = Symbol.for("react.profiler"), y = Symbol.for("react.provider"), c = Symbol.for("react.context"), u = Symbol.for("react.forward_ref"), f = Symbol.for("react.suspense"), d = Symbol.for("react.suspense_list"), p = Symbol.for("react.memo"), P = Symbol.for("react.lazy"), F = Symbol.for("react.offscreen"), D = Symbol.iterator, C = "@@iterator";
function U(e) {
var $e;
function Rr() {
return $e || ($e = 1, process.env.NODE_ENV !== "production" && function() {
var i = Ne, _ = Symbol.for("react.element"), m = Symbol.for("react.portal"), y = Symbol.for("react.fragment"), R = Symbol.for("react.strict_mode"), d = Symbol.for("react.profiler"), s = Symbol.for("react.provider"), v = Symbol.for("react.context"), n = Symbol.for("react.forward_ref"), o = Symbol.for("react.suspense"), f = Symbol.for("react.suspense_list"), E = Symbol.for("react.memo"), T = Symbol.for("react.lazy"), A = Symbol.for("react.offscreen"), x = Symbol.iterator, k = "@@iterator";
function N(e) {
if (e === null || typeof e != "object")
return null;
var t = D && e[D] || e[C];
return typeof t == "function" ? t : null;
var r = x && e[x] || e[k];
return typeof r == "function" ? r : null;
}
var q = r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
function L(e) {
var P = i.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
function h(e) {
{
for (var t = arguments.length, o = new Array(t > 1 ? t - 1 : 0), g = 1; g < t; g++)
o[g - 1] = arguments[g];
V("error", e, o);
for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), a = 1; a < r; a++)
t[a - 1] = arguments[a];
Q("error", e, t);
}
}
function V(e, t, o) {
function Q(e, r, t) {
{
var g = q.ReactDebugCurrentFrame, $ = g.getStackAddendum();
$ !== "" && (t += "%s", o = o.concat([$]));
var N = o.map(function(A) {
return String(A);
var a = P.ReactDebugCurrentFrame, c = a.getStackAddendum();
c !== "" && (r += "%s", t = t.concat([c]));
var g = t.map(function(u) {
return String(u);
});
N.unshift("Warning: " + t), Function.prototype.apply.call(console[e], console, N);
g.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, g);
}
}
var I = !1, a = !1, re = !1, _e = !1, me = !1, ue;
ue = Symbol.for("react.module.reference");
function be(e) {
return !!(typeof e == "string" || typeof e == "function" || e === s || e === v || me || e === m || e === f || e === d || _e || e === F || I || a || re || typeof e == "object" && e !== null && (e.$$typeof === P || e.$$typeof === p || e.$$typeof === y || e.$$typeof === c || e.$$typeof === u || // This needs to include all possible module reference object
var S = !1, C = !1, ee = !1, Me = !1, Le = !1, de;
de = Symbol.for("react.module.reference");
function Ue(e) {
return !!(typeof e == "string" || typeof e == "function" || e === y || e === d || Le || e === R || e === o || e === f || Me || e === A || S || C || ee || typeof e == "object" && e !== null && (e.$$typeof === T || e.$$typeof === E || e.$$typeof === s || e.$$typeof === v || e.$$typeof === n || // This needs to include all possible module reference object
// types supported by any Flight configuration anywhere since
// we don't know which Flight build this will end up being used
// with.
e.$$typeof === ue || e.getModuleId !== void 0));
e.$$typeof === de || e.getModuleId !== void 0));
}
function le(e, t, o) {
var g = e.displayName;
if (g)
return g;
var $ = t.displayName || t.name || "";
return $ !== "" ? o + "(" + $ + ")" : o;
function Ge(e, r, t) {
var a = e.displayName;
if (a)
return a;
var c = r.displayName || r.name || "";
return c !== "" ? t + "(" + c + ")" : t;
}
function ce(e) {
function ve(e) {
return e.displayName || "Context";
}
function K(e) {
function D(e) {
if (e == null)
return null;
if (typeof e.tag == "number" && L("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
if (typeof e.tag == "number" && h("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
return e.displayName || e.name || null;

@@ -100,13 +97,13 @@ if (typeof e == "string")

switch (e) {
case s:
case y:
return "Fragment";
case b:
case m:
return "Portal";
case v:
case d:
return "Profiler";
case m:
case R:
return "StrictMode";
case o:
return "Suspense";
case f:
return "Suspense";
case d:
return "SuspenseList";

@@ -116,17 +113,17 @@ }

switch (e.$$typeof) {
case c:
case v:
var r = e;
return ve(r) + ".Consumer";
case s:
var t = e;
return ce(t) + ".Consumer";
case y:
var o = e;
return ce(o._context) + ".Provider";
case u:
return le(e, e.render, "ForwardRef");
case p:
var g = e.displayName || null;
return g !== null ? g : K(e.type) || "Memo";
case P: {
var $ = e, N = $._payload, A = $._init;
return ve(t._context) + ".Provider";
case n:
return Ge(e, e.render, "ForwardRef");
case E:
var a = e.displayName || null;
return a !== null ? a : D(e.type) || "Memo";
case T: {
var c = e, g = c._payload, u = c._init;
try {
return K(A(N));
return D(u(g));
} catch {

@@ -139,14 +136,14 @@ return null;

}
var H = Object.assign, ne = 0, Z, te, ie, fe, n, l, O;
function R() {
var W = Object.assign, G = 0, ge, _e, ye, pe, me, he, be;
function Ee() {
}
R.__reactDisabledLog = !0;
function h() {
Ee.__reactDisabledLog = !0;
function Ve() {
{
if (ne === 0) {
Z = console.log, te = console.info, ie = console.warn, fe = console.error, n = console.group, l = console.groupCollapsed, O = console.groupEnd;
if (G === 0) {
ge = console.log, _e = console.info, ye = console.warn, pe = console.error, me = console.group, he = console.groupCollapsed, be = console.groupEnd;
var e = {
configurable: !0,
enumerable: !0,
value: R,
value: Ee,
writable: !0

@@ -164,8 +161,8 @@ };

}
ne++;
G++;
}
}
function j() {
function Be() {
{
if (ne--, ne === 0) {
if (G--, G === 0) {
var e = {

@@ -177,67 +174,67 @@ configurable: !0,

Object.defineProperties(console, {
log: H({}, e, {
value: Z
log: W({}, e, {
value: ge
}),
info: H({}, e, {
value: te
info: W({}, e, {
value: _e
}),
warn: H({}, e, {
value: ie
warn: W({}, e, {
value: ye
}),
error: H({}, e, {
value: fe
error: W({}, e, {
value: pe
}),
group: H({}, e, {
value: n
group: W({}, e, {
value: me
}),
groupCollapsed: H({}, e, {
value: l
groupCollapsed: W({}, e, {
value: he
}),
groupEnd: H({}, e, {
value: O
groupEnd: W({}, e, {
value: be
})
});
}
ne < 0 && L("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
G < 0 && h("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
}
}
var E = q.ReactCurrentDispatcher, T;
function S(e, t, o) {
var re = P.ReactCurrentDispatcher, te;
function X(e, r, t) {
{
if (T === void 0)
if (te === void 0)
try {
throw Error();
} catch ($) {
var g = $.stack.trim().match(/\n( *(at )?)/);
T = g && g[1] || "";
} catch (c) {
var a = c.stack.trim().match(/\n( *(at )?)/);
te = a && a[1] || "";
}
return `
` + T + e;
` + te + e;
}
}
var k = !1, x;
var ae = !1, z;
{
var B = typeof WeakMap == "function" ? WeakMap : Map;
x = new B();
var qe = typeof WeakMap == "function" ? WeakMap : Map;
z = new qe();
}
function i(e, t) {
if (!e || k)
function Re(e, r) {
if (!e || ae)
return "";
{
var o = x.get(e);
if (o !== void 0)
return o;
var t = z.get(e);
if (t !== void 0)
return t;
}
var a;
ae = !0;
var c = Error.prepareStackTrace;
Error.prepareStackTrace = void 0;
var g;
k = !0;
var $ = Error.prepareStackTrace;
Error.prepareStackTrace = void 0;
var N;
N = E.current, E.current = null, h();
g = re.current, re.current = null, Ve();
try {
if (t) {
var A = function() {
if (r) {
var u = function() {
throw Error();
};
if (Object.defineProperty(A.prototype, "props", {
if (Object.defineProperty(u.prototype, "props", {
set: function() {

@@ -248,14 +245,14 @@ throw Error();

try {
Reflect.construct(A, []);
} catch (ae) {
g = ae;
Reflect.construct(u, []);
} catch (j) {
a = j;
}
Reflect.construct(e, [], A);
Reflect.construct(e, [], u);
} else {
try {
A.call();
} catch (ae) {
g = ae;
u.call();
} catch (j) {
a = j;
}
e.call(A.prototype);
e.call(u.prototype);
}

@@ -265,23 +262,23 @@ } else {

throw Error();
} catch (ae) {
g = ae;
} catch (j) {
a = j;
}
e();
}
} catch (ae) {
if (ae && g && typeof ae.stack == "string") {
for (var w = ae.stack.split(`
`), X = g.stack.split(`
`), G = w.length - 1, z = X.length - 1; G >= 1 && z >= 0 && w[G] !== X[z]; )
z--;
for (; G >= 1 && z >= 0; G--, z--)
if (w[G] !== X[z]) {
if (G !== 1 || z !== 1)
} catch (j) {
if (j && a && typeof j.stack == "string") {
for (var l = j.stack.split(`
`), w = a.stack.split(`
`), p = l.length - 1, b = w.length - 1; p >= 1 && b >= 0 && l[p] !== w[b]; )
b--;
for (; p >= 1 && b >= 0; p--, b--)
if (l[p] !== w[b]) {
if (p !== 1 || b !== 1)
do
if (G--, z--, z < 0 || w[G] !== X[z]) {
var ee = `
` + w[G].replace(" at new ", " at ");
return e.displayName && ee.includes("<anonymous>") && (ee = ee.replace("<anonymous>", e.displayName)), typeof e == "function" && x.set(e, ee), ee;
if (p--, b--, b < 0 || l[p] !== w[b]) {
var I = `
` + l[p].replace(" at new ", " at ");
return e.displayName && I.includes("<anonymous>") && (I = I.replace("<anonymous>", e.displayName)), typeof e == "function" && z.set(e, I), I;
}
while (G >= 1 && z >= 0);
while (p >= 1 && b >= 0);
break;

@@ -291,37 +288,37 @@ }

} finally {
k = !1, E.current = N, j(), Error.prepareStackTrace = $;
ae = !1, re.current = g, Be(), Error.prepareStackTrace = c;
}
var ye = e ? e.displayName || e.name : "", er = ye ? S(ye) : "";
return typeof e == "function" && x.set(e, er), er;
var M = e ? e.displayName || e.name : "", $ = M ? X(M) : "";
return typeof e == "function" && z.set(e, $), $;
}
function Q(e, t, o) {
return i(e, !1);
function Je(e, r, t) {
return Re(e, !1);
}
function de(e) {
var t = e.prototype;
return !!(t && t.isReactComponent);
function Ke(e) {
var r = e.prototype;
return !!(r && r.isReactComponent);
}
function se(e, t, o) {
function H(e, r, t) {
if (e == null)
return "";
if (typeof e == "function")
return i(e, de(e));
return Re(e, Ke(e));
if (typeof e == "string")
return S(e);
return X(e);
switch (e) {
case o:
return X("Suspense");
case f:
return S("Suspense");
case d:
return S("SuspenseList");
return X("SuspenseList");
}
if (typeof e == "object")
switch (e.$$typeof) {
case u:
return Q(e.render);
case p:
return se(e.type, t, o);
case P: {
var g = e, $ = g._payload, N = g._init;
case n:
return Je(e.render);
case E:
return H(e.type, r, t);
case T: {
var a = e, c = a._payload, g = a._init;
try {
return se(N($), t, o);
return H(g(c), r, t);
} catch {

@@ -333,42 +330,42 @@ }

}
var Pe = Object.prototype.hasOwnProperty, Le = {}, Ue = q.ReactDebugCurrentFrame;
function Oe(e) {
var V = Object.prototype.hasOwnProperty, Te = {}, xe = P.ReactDebugCurrentFrame;
function Z(e) {
if (e) {
var t = e._owner, o = se(e.type, e._source, t ? t.type : null);
Ue.setExtraStackFrame(o);
var r = e._owner, t = H(e.type, e._source, r ? r.type : null);
xe.setExtraStackFrame(t);
} else
Ue.setExtraStackFrame(null);
xe.setExtraStackFrame(null);
}
function _r(e, t, o, g, $) {
function Xe(e, r, t, a, c) {
{
var N = Function.call.bind(Pe);
for (var A in e)
if (N(e, A)) {
var w = void 0;
var g = Function.call.bind(V);
for (var u in e)
if (g(e, u)) {
var l = void 0;
try {
if (typeof e[A] != "function") {
var X = Error((g || "React class") + ": " + o + " type `" + A + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[A] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
throw X.name = "Invariant Violation", X;
if (typeof e[u] != "function") {
var w = Error((a || "React class") + ": " + t + " type `" + u + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[u] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
throw w.name = "Invariant Violation", w;
}
w = e[A](t, A, g, o, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
} catch (G) {
w = G;
l = e[u](r, u, a, t, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
} catch (p) {
l = p;
}
w && !(w instanceof Error) && (Oe($), L("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", g || "React class", o, A, typeof w), Oe(null)), w instanceof Error && !(w.message in Le) && (Le[w.message] = !0, Oe($), L("Failed %s type: %s", o, w.message), Oe(null));
l && !(l instanceof Error) && (Z(c), h("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", a || "React class", t, u, typeof l), Z(null)), l instanceof Error && !(l.message in Te) && (Te[l.message] = !0, Z(c), h("Failed %s type: %s", t, l.message), Z(null));
}
}
}
var mr = Array.isArray;
function xe(e) {
return mr(e);
var ze = Array.isArray;
function ne(e) {
return ze(e);
}
function br(e) {
function He(e) {
{
var t = typeof Symbol == "function" && Symbol.toStringTag, o = t && e[Symbol.toStringTag] || e.constructor.name || "Object";
return o;
var r = typeof Symbol == "function" && Symbol.toStringTag, t = r && e[Symbol.toStringTag] || e.constructor.name || "Object";
return t;
}
}
function hr(e) {
function Ze(e) {
try {
return Ve(e), !1;
return Oe(e), !1;
} catch {

@@ -378,10 +375,10 @@ return !0;

}
function Ve(e) {
function Oe(e) {
return "" + e;
}
function Ge(e) {
if (hr(e))
return L("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", br(e)), Ve(e);
function we(e) {
if (Ze(e))
return h("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", He(e)), Oe(e);
}
var he = q.ReactCurrentOwner, Er = {
var B = P.ReactCurrentOwner, Qe = {
key: !0,

@@ -391,8 +388,8 @@ ref: !0,

__source: !0
}, ze, Be, we;
we = {};
function Tr(e) {
if (Pe.call(e, "ref")) {
var t = Object.getOwnPropertyDescriptor(e, "ref").get;
if (t && t.isReactWarning)
}, Pe, Se, ie;
ie = {};
function er(e) {
if (V.call(e, "ref")) {
var r = Object.getOwnPropertyDescriptor(e, "ref").get;
if (r && r.isReactWarning)
return !1;

@@ -402,6 +399,6 @@ }

}
function Rr(e) {
if (Pe.call(e, "key")) {
var t = Object.getOwnPropertyDescriptor(e, "key").get;
if (t && t.isReactWarning)
function rr(e) {
if (V.call(e, "key")) {
var r = Object.getOwnPropertyDescriptor(e, "key").get;
if (r && r.isReactWarning)
return !1;

@@ -411,15 +408,15 @@ }

}
function Pr(e, t) {
if (typeof e.ref == "string" && he.current && t && he.current.stateNode !== t) {
var o = K(he.current.type);
we[o] || (L('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', K(he.current.type), e.ref), we[o] = !0);
function tr(e, r) {
if (typeof e.ref == "string" && B.current && r && B.current.stateNode !== r) {
var t = D(B.current.type);
ie[t] || (h('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', D(B.current.type), e.ref), ie[t] = !0);
}
}
function Or(e, t) {
function ar(e, r) {
{
var o = function() {
ze || (ze = !0, L("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", t));
var t = function() {
Pe || (Pe = !0, h("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
};
o.isReactWarning = !0, Object.defineProperty(e, "key", {
get: o,
t.isReactWarning = !0, Object.defineProperty(e, "key", {
get: t,
configurable: !0

@@ -429,9 +426,9 @@ });

}
function Sr(e, t) {
function nr(e, r) {
{
var o = function() {
Be || (Be = !0, L("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", t));
var t = function() {
Se || (Se = !0, h("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", r));
};
o.isReactWarning = !0, Object.defineProperty(e, "ref", {
get: o,
t.isReactWarning = !0, Object.defineProperty(e, "ref", {
get: t,
configurable: !0

@@ -441,4 +438,4 @@ });

}
var xr = function(e, t, o, g, $, N, A) {
var w = {
var ir = function(e, r, t, a, c, g, u) {
var l = {
// This tag allows us to uniquely identify this as a React Element

@@ -448,9 +445,9 @@ $$typeof: _,

type: e,
key: t,
ref: o,
props: A,
key: r,
ref: t,
props: u,
// Record the component responsible for creating this element.
_owner: N
_owner: g
};
return w._store = {}, Object.defineProperty(w._store, "validated", {
return l._store = {}, Object.defineProperty(l._store, "validated", {
configurable: !1,

@@ -460,49 +457,49 @@ enumerable: !1,

value: !1
}), Object.defineProperty(w, "_self", {
}), Object.defineProperty(l, "_self", {
configurable: !1,
enumerable: !1,
writable: !1,
value: g
}), Object.defineProperty(w, "_source", {
value: a
}), Object.defineProperty(l, "_source", {
configurable: !1,
enumerable: !1,
writable: !1,
value: $
}), Object.freeze && (Object.freeze(w.props), Object.freeze(w)), w;
value: c
}), Object.freeze && (Object.freeze(l.props), Object.freeze(l)), l;
};
function wr(e, t, o, g, $) {
function lr(e, r, t, a, c) {
{
var N, A = {}, w = null, X = null;
o !== void 0 && (Ge(o), w = "" + o), Rr(t) && (Ge(t.key), w = "" + t.key), Tr(t) && (X = t.ref, Pr(t, $));
for (N in t)
Pe.call(t, N) && !Er.hasOwnProperty(N) && (A[N] = t[N]);
var g, u = {}, l = null, w = null;
t !== void 0 && (we(t), l = "" + t), rr(r) && (we(r.key), l = "" + r.key), er(r) && (w = r.ref, tr(r, c));
for (g in r)
V.call(r, g) && !Qe.hasOwnProperty(g) && (u[g] = r[g]);
if (e && e.defaultProps) {
var G = e.defaultProps;
for (N in G)
A[N] === void 0 && (A[N] = G[N]);
var p = e.defaultProps;
for (g in p)
u[g] === void 0 && (u[g] = p[g]);
}
if (w || X) {
var z = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
w && Or(A, z), X && Sr(A, z);
if (l || w) {
var b = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
l && ar(u, b), w && nr(u, b);
}
return xr(e, w, X, $, g, he.current, A);
return ir(e, l, w, c, a, B.current, u);
}
}
var Ce = q.ReactCurrentOwner, Je = q.ReactDebugCurrentFrame;
function ve(e) {
var le = P.ReactCurrentOwner, je = P.ReactDebugCurrentFrame;
function Y(e) {
if (e) {
var t = e._owner, o = se(e.type, e._source, t ? t.type : null);
Je.setExtraStackFrame(o);
var r = e._owner, t = H(e.type, e._source, r ? r.type : null);
je.setExtraStackFrame(t);
} else
Je.setExtraStackFrame(null);
je.setExtraStackFrame(null);
}
var je;
je = !1;
function Ae(e) {
var oe;
oe = !1;
function se(e) {
return typeof e == "object" && e !== null && e.$$typeof === _;
}
function Xe() {
function Ce() {
{
if (Ce.current) {
var e = K(Ce.current.type);
if (le.current) {
var e = D(le.current.type);
if (e)

@@ -516,9 +513,9 @@ return `

}
function Cr(e) {
function or(e) {
{
if (e !== void 0) {
var t = e.fileName.replace(/^.*[\\\/]/, ""), o = e.lineNumber;
var r = e.fileName.replace(/^.*[\\\/]/, ""), t = e.lineNumber;
return `
Check your code at ` + t + ":" + o + ".";
Check your code at ` + r + ":" + t + ".";
}

@@ -528,16 +525,16 @@ return "";

}
var He = {};
function jr(e) {
var ke = {};
function sr(e) {
{
var t = Xe();
if (!t) {
var o = typeof e == "string" ? e : e.displayName || e.name;
o && (t = `
var r = Ce();
if (!r) {
var t = typeof e == "string" ? e : e.displayName || e.name;
t && (r = `
Check the top-level render call using <` + o + ">.");
Check the top-level render call using <` + t + ">.");
}
return t;
return r;
}
}
function Ke(e, t) {
function Ie(e, r) {
{

@@ -547,789 +544,142 @@ if (!e._store || e._store.validated || e.key != null)

e._store.validated = !0;
var o = jr(t);
if (He[o])
var t = sr(r);
if (ke[t])
return;
He[o] = !0;
var g = "";
e && e._owner && e._owner !== Ce.current && (g = " It was passed a child from " + K(e._owner.type) + "."), ve(e), L('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', o, g), ve(null);
ke[t] = !0;
var a = "";
e && e._owner && e._owner !== le.current && (a = " It was passed a child from " + D(e._owner.type) + "."), Y(e), h('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, a), Y(null);
}
}
function Ze(e, t) {
function De(e, r) {
{
if (typeof e != "object")
return;
if (xe(e))
for (var o = 0; o < e.length; o++) {
var g = e[o];
Ae(g) && Ke(g, t);
if (ne(e))
for (var t = 0; t < e.length; t++) {
var a = e[t];
se(a) && Ie(a, r);
}
else if (Ae(e))
else if (se(e))
e._store && (e._store.validated = !0);
else if (e) {
var $ = U(e);
if (typeof $ == "function" && $ !== e.entries)
for (var N = $.call(e), A; !(A = N.next()).done; )
Ae(A.value) && Ke(A.value, t);
var c = N(e);
if (typeof c == "function" && c !== e.entries)
for (var g = c.call(e), u; !(u = g.next()).done; )
se(u.value) && Ie(u.value, r);
}
}
}
function Ar(e) {
function ur(e) {
{
var t = e.type;
if (t == null || typeof t == "string")
var r = e.type;
if (r == null || typeof r == "string")
return;
var o;
if (typeof t == "function")
o = t.propTypes;
else if (typeof t == "object" && (t.$$typeof === u || // Note: Memo only checks outer props here.
var t;
if (typeof r == "function")
t = r.propTypes;
else if (typeof r == "object" && (r.$$typeof === n || // Note: Memo only checks outer props here.
// Inner props are checked in the reconciler.
t.$$typeof === p))
o = t.propTypes;
r.$$typeof === E))
t = r.propTypes;
else
return;
if (o) {
var g = K(t);
_r(o, e.props, "prop", g, e);
} else if (t.PropTypes !== void 0 && !je) {
je = !0;
var $ = K(t);
L("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", $ || "Unknown");
if (t) {
var a = D(r);
Xe(t, e.props, "prop", a, e);
} else if (r.PropTypes !== void 0 && !oe) {
oe = !0;
var c = D(r);
h("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", c || "Unknown");
}
typeof t.getDefaultProps == "function" && !t.getDefaultProps.isReactClassApproved && L("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && h("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
}
}
function Ir(e) {
function cr(e) {
{
for (var t = Object.keys(e.props), o = 0; o < t.length; o++) {
var g = t[o];
if (g !== "children" && g !== "key") {
ve(e), L("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", g), ve(null);
for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {
var a = r[t];
if (a !== "children" && a !== "key") {
Y(e), h("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", a), Y(null);
break;
}
}
e.ref !== null && (ve(e), L("Invalid attribute `ref` supplied to `React.Fragment`."), ve(null));
e.ref !== null && (Y(e), h("Invalid attribute `ref` supplied to `React.Fragment`."), Y(null));
}
}
function Qe(e, t, o, g, $, N) {
var Ae = {};
function Fe(e, r, t, a, c, g) {
{
var A = be(e);
if (!A) {
var w = "";
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (w += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
var X = Cr($);
X ? w += X : w += Xe();
var G;
e === null ? G = "null" : xe(e) ? G = "array" : e !== void 0 && e.$$typeof === _ ? (G = "<" + (K(e.type) || "Unknown") + " />", w = " Did you accidentally export a JSX literal instead of a component?") : G = typeof e, L("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", G, w);
var u = Ue(e);
if (!u) {
var l = "";
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (l += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
var w = or(c);
w ? l += w : l += Ce();
var p;
e === null ? p = "null" : ne(e) ? p = "array" : e !== void 0 && e.$$typeof === _ ? (p = "<" + (D(e.type) || "Unknown") + " />", l = " Did you accidentally export a JSX literal instead of a component?") : p = typeof e, h("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", p, l);
}
var z = wr(e, t, o, $, N);
if (z == null)
return z;
if (A) {
var ee = t.children;
if (ee !== void 0)
if (g)
if (xe(ee)) {
for (var ye = 0; ye < ee.length; ye++)
Ze(ee[ye], e);
Object.freeze && Object.freeze(ee);
var b = lr(e, r, t, c, g);
if (b == null)
return b;
if (u) {
var I = r.children;
if (I !== void 0)
if (a)
if (ne(I)) {
for (var M = 0; M < I.length; M++)
De(I[M], e);
Object.freeze && Object.freeze(I);
} else
L("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
h("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
else
Ze(ee, e);
De(I, e);
}
return e === s ? Ir(z) : Ar(z), z;
}
}
function kr(e, t, o) {
return Qe(e, t, o, !0);
}
function $r(e, t, o) {
return Qe(e, t, o, !1);
}
var Dr = $r, Mr = kr;
Te.Fragment = s, Te.jsx = Dr, Te.jsxs = Mr;
}()), Te;
}
process.env.NODE_ENV === "production" ? We.exports = Lr() : We.exports = Ur();
var oe = We.exports, qe = { exports: {} }, Se = { exports: {} }, M = {};
/** @license React v16.13.1
* react-is.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
var nr;
function Vr() {
if (nr)
return M;
nr = 1;
var r = typeof Symbol == "function" && Symbol.for, _ = r ? Symbol.for("react.element") : 60103, b = r ? Symbol.for("react.portal") : 60106, s = r ? Symbol.for("react.fragment") : 60107, m = r ? Symbol.for("react.strict_mode") : 60108, v = r ? Symbol.for("react.profiler") : 60114, y = r ? Symbol.for("react.provider") : 60109, c = r ? Symbol.for("react.context") : 60110, u = r ? Symbol.for("react.async_mode") : 60111, f = r ? Symbol.for("react.concurrent_mode") : 60111, d = r ? Symbol.for("react.forward_ref") : 60112, p = r ? Symbol.for("react.suspense") : 60113, P = r ? Symbol.for("react.suspense_list") : 60120, F = r ? Symbol.for("react.memo") : 60115, D = r ? Symbol.for("react.lazy") : 60116, C = r ? Symbol.for("react.block") : 60121, U = r ? Symbol.for("react.fundamental") : 60117, q = r ? Symbol.for("react.responder") : 60118, L = r ? Symbol.for("react.scope") : 60119;
function V(a) {
if (typeof a == "object" && a !== null) {
var re = a.$$typeof;
switch (re) {
case _:
switch (a = a.type, a) {
case u:
case f:
case s:
case v:
case m:
case p:
return a;
default:
switch (a = a && a.$$typeof, a) {
case c:
case d:
case D:
case F:
case y:
return a;
default:
return re;
}
if (V.call(r, "key")) {
var $ = D(e), j = Object.keys(r).filter(function(yr) {
return yr !== "key";
}), ue = j.length > 0 ? "{key: someKey, " + j.join(": ..., ") + ": ...}" : "{key: someKey}";
if (!Ae[$ + ue]) {
var _r = j.length > 0 ? "{" + j.join(": ..., ") + ": ...}" : "{}";
h(`A props object containing a "key" prop is being spread into JSX:
let props = %s;
<%s {...props} />
React keys must be passed directly to JSX without using spread:
let props = %s;
<%s key={someKey} {...props} />`, ue, $, _r, $), Ae[$ + ue] = !0;
}
case b:
return re;
}
}
}
function I(a) {
return V(a) === f;
}
return M.AsyncMode = u, M.ConcurrentMode = f, M.ContextConsumer = c, M.ContextProvider = y, M.Element = _, M.ForwardRef = d, M.Fragment = s, M.Lazy = D, M.Memo = F, M.Portal = b, M.Profiler = v, M.StrictMode = m, M.Suspense = p, M.isAsyncMode = function(a) {
return I(a) || V(a) === u;
}, M.isConcurrentMode = I, M.isContextConsumer = function(a) {
return V(a) === c;
}, M.isContextProvider = function(a) {
return V(a) === y;
}, M.isElement = function(a) {
return typeof a == "object" && a !== null && a.$$typeof === _;
}, M.isForwardRef = function(a) {
return V(a) === d;
}, M.isFragment = function(a) {
return V(a) === s;
}, M.isLazy = function(a) {
return V(a) === D;
}, M.isMemo = function(a) {
return V(a) === F;
}, M.isPortal = function(a) {
return V(a) === b;
}, M.isProfiler = function(a) {
return V(a) === v;
}, M.isStrictMode = function(a) {
return V(a) === m;
}, M.isSuspense = function(a) {
return V(a) === p;
}, M.isValidElementType = function(a) {
return typeof a == "string" || typeof a == "function" || a === s || a === f || a === v || a === m || a === p || a === P || typeof a == "object" && a !== null && (a.$$typeof === D || a.$$typeof === F || a.$$typeof === y || a.$$typeof === c || a.$$typeof === d || a.$$typeof === U || a.$$typeof === q || a.$$typeof === L || a.$$typeof === C);
}, M.typeOf = V, M;
}
var Y = {};
/** @license React v16.13.1
* react-is.development.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
var ar;
function Gr() {
return ar || (ar = 1, process.env.NODE_ENV !== "production" && function() {
var r = typeof Symbol == "function" && Symbol.for, _ = r ? Symbol.for("react.element") : 60103, b = r ? Symbol.for("react.portal") : 60106, s = r ? Symbol.for("react.fragment") : 60107, m = r ? Symbol.for("react.strict_mode") : 60108, v = r ? Symbol.for("react.profiler") : 60114, y = r ? Symbol.for("react.provider") : 60109, c = r ? Symbol.for("react.context") : 60110, u = r ? Symbol.for("react.async_mode") : 60111, f = r ? Symbol.for("react.concurrent_mode") : 60111, d = r ? Symbol.for("react.forward_ref") : 60112, p = r ? Symbol.for("react.suspense") : 60113, P = r ? Symbol.for("react.suspense_list") : 60120, F = r ? Symbol.for("react.memo") : 60115, D = r ? Symbol.for("react.lazy") : 60116, C = r ? Symbol.for("react.block") : 60121, U = r ? Symbol.for("react.fundamental") : 60117, q = r ? Symbol.for("react.responder") : 60118, L = r ? Symbol.for("react.scope") : 60119;
function V(i) {
return typeof i == "string" || typeof i == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
i === s || i === f || i === v || i === m || i === p || i === P || typeof i == "object" && i !== null && (i.$$typeof === D || i.$$typeof === F || i.$$typeof === y || i.$$typeof === c || i.$$typeof === d || i.$$typeof === U || i.$$typeof === q || i.$$typeof === L || i.$$typeof === C);
}
function I(i) {
if (typeof i == "object" && i !== null) {
var Q = i.$$typeof;
switch (Q) {
case _:
var de = i.type;
switch (de) {
case u:
case f:
case s:
case v:
case m:
case p:
return de;
default:
var se = de && de.$$typeof;
switch (se) {
case c:
case d:
case D:
case F:
case y:
return se;
default:
return Q;
}
}
case b:
return Q;
}
return e === y ? cr(b) : ur(b), b;
}
}
var a = u, re = f, _e = c, me = y, ue = _, be = d, le = s, ce = D, K = F, H = b, ne = v, Z = m, te = p, ie = !1;
function fe(i) {
return ie || (ie = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), n(i) || I(i) === u;
function fr(e, r, t) {
return Fe(e, r, t, !0);
}
function n(i) {
return I(i) === f;
function dr(e, r, t) {
return Fe(e, r, t, !1);
}
function l(i) {
return I(i) === c;
}
function O(i) {
return I(i) === y;
}
function R(i) {
return typeof i == "object" && i !== null && i.$$typeof === _;
}
function h(i) {
return I(i) === d;
}
function j(i) {
return I(i) === s;
}
function E(i) {
return I(i) === D;
}
function T(i) {
return I(i) === F;
}
function S(i) {
return I(i) === b;
}
function k(i) {
return I(i) === v;
}
function x(i) {
return I(i) === m;
}
function B(i) {
return I(i) === p;
}
Y.AsyncMode = a, Y.ConcurrentMode = re, Y.ContextConsumer = _e, Y.ContextProvider = me, Y.Element = ue, Y.ForwardRef = be, Y.Fragment = le, Y.Lazy = ce, Y.Memo = K, Y.Portal = H, Y.Profiler = ne, Y.StrictMode = Z, Y.Suspense = te, Y.isAsyncMode = fe, Y.isConcurrentMode = n, Y.isContextConsumer = l, Y.isContextProvider = O, Y.isElement = R, Y.isForwardRef = h, Y.isFragment = j, Y.isLazy = E, Y.isMemo = T, Y.isPortal = S, Y.isProfiler = k, Y.isStrictMode = x, Y.isSuspense = B, Y.isValidElementType = V, Y.typeOf = I;
}()), Y;
var vr = dr, gr = fr;
J.Fragment = y, J.jsx = vr, J.jsxs = gr;
}()), J;
}
var or;
function vr() {
return or || (or = 1, process.env.NODE_ENV === "production" ? Se.exports = Vr() : Se.exports = Gr()), Se.exports;
}
/*
object-assign
(c) Sindre Sorhus
@license MIT
*/
var ke, ir;
function zr() {
if (ir)
return ke;
ir = 1;
var r = Object.getOwnPropertySymbols, _ = Object.prototype.hasOwnProperty, b = Object.prototype.propertyIsEnumerable;
function s(v) {
if (v == null)
throw new TypeError("Object.assign cannot be called with null or undefined");
return Object(v);
}
function m() {
try {
if (!Object.assign)
return !1;
var v = new String("abc");
if (v[5] = "de", Object.getOwnPropertyNames(v)[0] === "5")
return !1;
for (var y = {}, c = 0; c < 10; c++)
y["_" + String.fromCharCode(c)] = c;
var u = Object.getOwnPropertyNames(y).map(function(d) {
return y[d];
});
if (u.join("") !== "0123456789")
return !1;
var f = {};
return "abcdefghijklmnopqrst".split("").forEach(function(d) {
f[d] = d;
}), Object.keys(Object.assign({}, f)).join("") === "abcdefghijklmnopqrst";
} catch {
return !1;
}
}
return ke = m() ? Object.assign : function(v, y) {
for (var c, u = s(v), f, d = 1; d < arguments.length; d++) {
c = Object(arguments[d]);
for (var p in c)
_.call(c, p) && (u[p] = c[p]);
if (r) {
f = r(c);
for (var P = 0; P < f.length; P++)
b.call(c, f[P]) && (u[f[P]] = c[f[P]]);
}
}
return u;
}, ke;
}
var $e, sr;
function Ne() {
if (sr)
return $e;
sr = 1;
var r = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
return $e = r, $e;
}
var De, ur;
function yr() {
return ur || (ur = 1, De = Function.call.bind(Object.prototype.hasOwnProperty)), De;
}
var Me, lr;
function Br() {
if (lr)
return Me;
lr = 1;
var r = function() {
};
if (process.env.NODE_ENV !== "production") {
var _ = Ne(), b = {}, s = yr();
r = function(v) {
var y = "Warning: " + v;
typeof console < "u" && console.error(y);
try {
throw new Error(y);
} catch {
}
};
}
function m(v, y, c, u, f) {
if (process.env.NODE_ENV !== "production") {
for (var d in v)
if (s(v, d)) {
var p;
try {
if (typeof v[d] != "function") {
var P = Error(
(u || "React class") + ": " + c + " type `" + d + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof v[d] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
);
throw P.name = "Invariant Violation", P;
}
p = v[d](y, d, u, c, null, _);
} catch (D) {
p = D;
}
if (p && !(p instanceof Error) && r(
(u || "React class") + ": type specification of " + c + " `" + d + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof p + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
), p instanceof Error && !(p.message in b)) {
b[p.message] = !0;
var F = f ? f() : "";
r(
"Failed " + c + " type: " + p.message + (F ?? "")
);
}
}
}
}
return m.resetWarningCache = function() {
process.env.NODE_ENV !== "production" && (b = {});
}, Me = m, Me;
}
var Ye, cr;
function Jr() {
if (cr)
return Ye;
cr = 1;
var r = vr(), _ = zr(), b = Ne(), s = yr(), m = Br(), v = function() {
};
process.env.NODE_ENV !== "production" && (v = function(c) {
var u = "Warning: " + c;
typeof console < "u" && console.error(u);
try {
throw new Error(u);
} catch {
}
});
function y() {
process.env.NODE_ENV === "production" ? fe.exports = Er() : fe.exports = Rr();
var F = fe.exports;
const U = (i = []) => {
if (!i || !Array.isArray(i) || !i.length)
return null;
}
return Ye = function(c, u) {
var f = typeof Symbol == "function" && Symbol.iterator, d = "@@iterator";
function p(n) {
var l = n && (f && n[f] || n[d]);
if (typeof l == "function")
return l;
}
var P = "<<anonymous>>", F = {
array: q("array"),
bigint: q("bigint"),
bool: q("boolean"),
func: q("function"),
number: q("number"),
object: q("object"),
string: q("string"),
symbol: q("symbol"),
any: L(),
arrayOf: V,
element: I(),
elementType: a(),
instanceOf: re,
node: be(),
objectOf: me,
oneOf: _e,
oneOfType: ue,
shape: ce,
exact: K
};
function D(n, l) {
return n === l ? n !== 0 || 1 / n === 1 / l : n !== n && l !== l;
}
function C(n, l) {
this.message = n, this.data = l && typeof l == "object" ? l : {}, this.stack = "";
}
C.prototype = Error.prototype;
function U(n) {
if (process.env.NODE_ENV !== "production")
var l = {}, O = 0;
function R(j, E, T, S, k, x, B) {
if (S = S || P, x = x || T, B !== b) {
if (u) {
var i = new Error(
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
);
throw i.name = "Invariant Violation", i;
} else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
var Q = S + ":" + T;
!l[Q] && // Avoid spamming the console because they are often not actionable except for lib authors
O < 3 && (v(
"You are manually calling a React.PropTypes validation function for the `" + x + "` prop on `" + S + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
), l[Q] = !0, O++);
}
}
return E[T] == null ? j ? E[T] === null ? new C("The " + k + " `" + x + "` is marked as required " + ("in `" + S + "`, but its value is `null`.")) : new C("The " + k + " `" + x + "` is marked as required in " + ("`" + S + "`, but its value is `undefined`.")) : null : n(E, T, S, k, x);
}
var h = R.bind(null, !1);
return h.isRequired = R.bind(null, !0), h;
}
function q(n) {
function l(O, R, h, j, E, T) {
var S = O[R], k = Z(S);
if (k !== n) {
var x = te(S);
return new C(
"Invalid " + j + " `" + E + "` of type " + ("`" + x + "` supplied to `" + h + "`, expected ") + ("`" + n + "`."),
{ expectedType: n }
);
}
return null;
}
return U(l);
}
function L() {
return U(y);
}
function V(n) {
function l(O, R, h, j, E) {
if (typeof n != "function")
return new C("Property `" + E + "` of component `" + h + "` has invalid PropType notation inside arrayOf.");
var T = O[R];
if (!Array.isArray(T)) {
var S = Z(T);
return new C("Invalid " + j + " `" + E + "` of type " + ("`" + S + "` supplied to `" + h + "`, expected an array."));
}
for (var k = 0; k < T.length; k++) {
var x = n(T, k, h, j, E + "[" + k + "]", b);
if (x instanceof Error)
return x;
}
return null;
}
return U(l);
}
function I() {
function n(l, O, R, h, j) {
var E = l[O];
if (!c(E)) {
var T = Z(E);
return new C("Invalid " + h + " `" + j + "` of type " + ("`" + T + "` supplied to `" + R + "`, expected a single ReactElement."));
}
return null;
}
return U(n);
}
function a() {
function n(l, O, R, h, j) {
var E = l[O];
if (!r.isValidElementType(E)) {
var T = Z(E);
return new C("Invalid " + h + " `" + j + "` of type " + ("`" + T + "` supplied to `" + R + "`, expected a single ReactElement type."));
}
return null;
}
return U(n);
}
function re(n) {
function l(O, R, h, j, E) {
if (!(O[R] instanceof n)) {
var T = n.name || P, S = fe(O[R]);
return new C("Invalid " + j + " `" + E + "` of type " + ("`" + S + "` supplied to `" + h + "`, expected ") + ("instance of `" + T + "`."));
}
return null;
}
return U(l);
}
function _e(n) {
if (!Array.isArray(n))
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? v(
"Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."
) : v("Invalid argument supplied to oneOf, expected an array.")), y;
function l(O, R, h, j, E) {
for (var T = O[R], S = 0; S < n.length; S++)
if (D(T, n[S]))
return null;
var k = JSON.stringify(n, function(B, i) {
var Q = te(i);
return Q === "symbol" ? String(i) : i;
});
return new C("Invalid " + j + " `" + E + "` of value `" + String(T) + "` " + ("supplied to `" + h + "`, expected one of " + k + "."));
}
return U(l);
}
function me(n) {
function l(O, R, h, j, E) {
if (typeof n != "function")
return new C("Property `" + E + "` of component `" + h + "` has invalid PropType notation inside objectOf.");
var T = O[R], S = Z(T);
if (S !== "object")
return new C("Invalid " + j + " `" + E + "` of type " + ("`" + S + "` supplied to `" + h + "`, expected an object."));
for (var k in T)
if (s(T, k)) {
var x = n(T, k, h, j, E + "." + k, b);
if (x instanceof Error)
return x;
}
return null;
}
return U(l);
}
function ue(n) {
if (!Array.isArray(n))
return process.env.NODE_ENV !== "production" && v("Invalid argument supplied to oneOfType, expected an instance of array."), y;
for (var l = 0; l < n.length; l++) {
var O = n[l];
if (typeof O != "function")
return v(
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + ie(O) + " at index " + l + "."
), y;
}
function R(h, j, E, T, S) {
for (var k = [], x = 0; x < n.length; x++) {
var B = n[x], i = B(h, j, E, T, S, b);
if (i == null)
return null;
i.data && s(i.data, "expectedType") && k.push(i.data.expectedType);
}
var Q = k.length > 0 ? ", expected one of type [" + k.join(", ") + "]" : "";
return new C("Invalid " + T + " `" + S + "` supplied to " + ("`" + E + "`" + Q + "."));
}
return U(R);
}
function be() {
function n(l, O, R, h, j) {
return H(l[O]) ? null : new C("Invalid " + h + " `" + j + "` supplied to " + ("`" + R + "`, expected a ReactNode."));
}
return U(n);
}
function le(n, l, O, R, h) {
return new C(
(n || "React class") + ": " + l + " type `" + O + "." + R + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + h + "`."
);
}
function ce(n) {
function l(O, R, h, j, E) {
var T = O[R], S = Z(T);
if (S !== "object")
return new C("Invalid " + j + " `" + E + "` of type `" + S + "` " + ("supplied to `" + h + "`, expected `object`."));
for (var k in n) {
var x = n[k];
if (typeof x != "function")
return le(h, j, E, k, te(x));
var B = x(T, k, h, j, E + "." + k, b);
if (B)
return B;
}
return null;
}
return U(l);
}
function K(n) {
function l(O, R, h, j, E) {
var T = O[R], S = Z(T);
if (S !== "object")
return new C("Invalid " + j + " `" + E + "` of type `" + S + "` " + ("supplied to `" + h + "`, expected `object`."));
var k = _({}, O[R], n);
for (var x in k) {
var B = n[x];
if (s(n, x) && typeof B != "function")
return le(h, j, E, x, te(B));
if (!B)
return new C(
"Invalid " + j + " `" + E + "` key `" + x + "` supplied to `" + h + "`.\nBad object: " + JSON.stringify(O[R], null, " ") + `
Valid keys: ` + JSON.stringify(Object.keys(n), null, " ")
);
var i = B(T, x, h, j, E + "." + x, b);
if (i)
return i;
}
return null;
}
return U(l);
}
function H(n) {
switch (typeof n) {
case "number":
case "string":
case "undefined":
return !0;
case "boolean":
return !n;
case "object":
if (Array.isArray(n))
return n.every(H);
if (n === null || c(n))
return !0;
var l = p(n);
if (l) {
var O = l.call(n), R;
if (l !== n.entries) {
for (; !(R = O.next()).done; )
if (!H(R.value))
return !1;
} else
for (; !(R = O.next()).done; ) {
var h = R.value;
if (h && !H(h[1]))
return !1;
}
} else
return !1;
return !0;
default:
return !1;
}
}
function ne(n, l) {
return n === "symbol" ? !0 : l ? l["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && l instanceof Symbol : !1;
}
function Z(n) {
var l = typeof n;
return Array.isArray(n) ? "array" : n instanceof RegExp ? "object" : ne(l, n) ? "symbol" : l;
}
function te(n) {
if (typeof n > "u" || n === null)
return "" + n;
var l = Z(n);
if (l === "object") {
if (n instanceof Date)
return "date";
if (n instanceof RegExp)
return "regexp";
}
return l;
}
function ie(n) {
var l = te(n);
switch (l) {
case "array":
case "object":
return "an " + l;
case "boolean":
case "date":
case "regexp":
return "a " + l;
default:
return l;
}
}
function fe(n) {
return !n.constructor || !n.constructor.name ? P : n.constructor.name;
}
return F.checkPropTypes = m, F.resetWarningCache = m.resetWarningCache, F.PropTypes = F, F;
}, Ye;
}
var Fe, fr;
function Xr() {
if (fr)
return Fe;
fr = 1;
var r = Ne();
function _() {
}
function b() {
}
return b.resetWarningCache = _, Fe = function() {
function s(y, c, u, f, d, p) {
if (p !== r) {
var P = new Error(
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types"
);
throw P.name = "Invariant Violation", P;
}
}
s.isRequired = s;
function m() {
return s;
}
var v = {
array: s,
bigint: s,
bool: s,
func: s,
number: s,
object: s,
string: s,
symbol: s,
any: s,
arrayOf: m,
element: s,
elementType: s,
instanceOf: m,
node: s,
objectOf: m,
oneOf: m,
oneOfType: m,
shape: m,
exact: m,
checkPropTypes: b,
resetWarningCache: _
};
return v.PropTypes = v, v;
}, Fe;
}
if (process.env.NODE_ENV !== "production") {
var Hr = vr(), Kr = !0;
qe.exports = Jr()(Hr.isElement, Kr);
} else
qe.exports = Xr()();
var Zr = qe.exports;
const W = /* @__PURE__ */ Nr(Zr), ge = (r = []) => {
if (!r || !Array.isArray(r) || !r.length)
return null;
let _ = [];
return r.forEach((b) => {
typeof b == "string" && _.push(b);
return i.forEach((m) => {
typeof m == "string" && _.push(m);
}), _.join(" ");
}, Qr = "gallery-module__gallery__nTWS5t", et = "gallery-module__gallery__main__M7tRB-", rt = "gallery-module__gallery__item__putWWs", tt = "gallery-module__gallery__nav__Wv4W0g", nt = "gallery-module__gallery__pagination__LqNRZx", J = {
}, Tr = "gallery-module__gallery__nTWS5t", xr = "gallery-module__gallery__main__M7tRB-", Or = "gallery-module__gallery__item__putWWs", wr = "gallery-module__gallery__nav__Wv4W0g", Pr = "gallery-module__gallery__pagination__LqNRZx", O = {
"visually-hidden": "gallery-module__visually-hidden__vbB7Ij",
gallery: Qr,
gallery: Tr,
"gallery--draggable": "gallery-module__gallery--draggable__F8uLME",
gallery__main: et,
gallery__item: rt,
gallery__main: xr,
gallery__item: Or,
"gallery__item--draggable": "gallery-module__gallery__item--draggable__0t6ZLn",
"gallery__item--dragging": "gallery-module__gallery__item--dragging__ce-1Pn",
gallery__nav: tt,
gallery__pagination: nt,
gallery__nav: wr,
gallery__pagination: Pr,
"gallery__pagination-item": "gallery-module__gallery__pagination-item__-ZXYn7"
}, pr = Yr(), at = {
}, Ye = pr(), Sr = {
isDragging: !1,

@@ -1340,134 +690,115 @@ start: 0,

scrolling: !0
}, ot = 50, gr = ({
items: r,
loop: _,
draggable: b,
}, jr = 50, kr = ({
loop: i = !1,
draggable: _ = !0,
startIndex: m = 0,
visibleRange: y = -1,
ariaLiveText: R = "Item $i of $t.",
items: d,
onChange: s,
startIndex: m,
visibleRange: v,
ariaLiveText: y,
className: c,
children: u
className: v,
children: n
}) => {
const [f, d] = Ie(() => m || 0), [p, P] = Ie(
const [o, f] = ce(() => m || 0), [E, T] = ce(
() => m || 0
), [F, D] = Ie(() => at), C = Fr([]);
if (!Array.isArray(r))
), [A, x] = ce(() => Sr), k = mr([]);
if (!Array.isArray(d))
throw new Error("<Gallery> items prop must be an Array.");
const U = pe(() => {
P(f), d((I) => {
let a = I + 1;
return I === r.length - 1 && (a = _ ? 0 : I), s && s({ oldIndex: I, newIndex: a, direction: 1 }), a;
const N = L(() => {
T(o), f((S) => {
let C = S + 1;
return S === d.length - 1 && (C = i ? 0 : S), s && s({ oldIndex: S, newIndex: C, direction: 1 }), C;
});
}, [f, r.length, _, s]), q = pe(() => {
P(f), d((I) => {
let a = I - 1;
return I === 0 && (a = _ ? r.length - 1 : I), s && s({ oldIndex: I, newIndex: a, direction: 0 }), a;
}, [o, d.length, i, s]), P = L(() => {
T(o), f((S) => {
let C = S - 1;
return S === 0 && (C = i ? d.length - 1 : S), s && s({ oldIndex: S, newIndex: C, direction: 0 }), C;
});
}, [f, r.length, _, s]), L = pe(
(I) => {
const a = r[I] ? I : 0;
P(f), d(a);
const re = a - f > 0 ? 1 : 0;
s && s({ oldIndex: f, newIndex: a, direction: re });
}, [o, d.length, i, s]), h = L(
(S) => {
const C = d[S] ? S : 0;
T(o), f(C);
const ee = C - o > 0 ? 1 : 0;
s && s({ oldIndex: o, newIndex: C, direction: ee });
},
[f, s, r]
[o, s, d]
);
Wr(() => {
r[f] || L();
}, [f, r, L]);
const V = {
galleryItems: r,
itemNodes: C,
hr(() => {
d[o] || h();
}, [o, d, h]);
const Q = {
galleryItems: d,
itemNodes: k,
startIndex: m,
activeIndex: f,
setActiveIndex: d,
previouslyActiveIndex: p,
setPreviouslyActiveIndex: P,
goToIndex: L,
next: U,
previous: q,
loop: _,
draggable: b,
touchState: F,
setTouchState: D,
swipeThreshold: ot,
activeIndex: o,
setActiveIndex: f,
previouslyActiveIndex: E,
setPreviouslyActiveIndex: T,
goToIndex: h,
next: N,
previous: P,
loop: i,
draggable: _,
touchState: A,
setTouchState: x,
swipeThreshold: jr,
onChange: s,
visibleRange: v
visibleRange: y
};
return /* @__PURE__ */ oe.jsx(pr.Provider, { value: V, children: /* @__PURE__ */ oe.jsxs(
return /* @__PURE__ */ F.jsx(Ye.Provider, { value: Q, children: /* @__PURE__ */ F.jsxs(
"div",
{
className: ge([
J.gallery,
b && J["gallery--draggable"],
c
className: U([
O.gallery,
_ && O["gallery--draggable"],
v
]),
style: { "--touch-offset": F.xOffset },
style: { "--touch-offset": A.xOffset },
children: [
u,
y && /* @__PURE__ */ oe.jsx("p", { "aria-live": "polite", className: J["visually-hidden"], children: y.replace("$i", f + 1).replace("$t", r.length) })
n,
R && /* @__PURE__ */ F.jsx("p", { "aria-live": "polite", className: O["visually-hidden"], children: R.replace("$i", o + 1).replace("$t", d.length) })
]
}
) });
};
gr.propTypes = {
items: W.array.isRequired,
loop: W.bool,
draggable: W.bool,
onChange: W.func,
startIndex: W.number,
visibleRange: W.number,
ariaLiveText: W.string,
className: W.string,
children: W.node
};
gr.defaultProps = {
loop: !1,
draggable: !0,
startIndex: 0,
visibleRange: -1,
ariaLiveText: "Item $i of $t."
};
const Re = () => {
const r = qr(pr);
if (!r)
}, K = () => {
const i = br(Ye);
if (!i)
throw new Error("useGallery must be called from within a <Gallery>.");
return r;
}, it = ({ renderGalleryItem: r, className: _, ...b }) => {
return i;
}, Ir = ({ renderGalleryItem: i, className: _, ...m }) => {
const {
activeIndex: s,
galleryItems: m,
next: v,
previous: y,
draggable: c,
touchState: u,
setTouchState: f,
swipeThreshold: d
} = Re(), p = pe(() => {
c && f((D) => ({ ...D, isDragging: !0 }));
}, [c, f]), P = pe(
(D) => {
if (c && !u.scrolling && u.isDragging === !0 && D.clientY)
if (!u.start)
f((C) => ({
...C,
start: { x: D.clientX, y: D.clientY }
activeIndex: y,
galleryItems: R,
next: d,
previous: s,
draggable: v,
touchState: n,
setTouchState: o,
swipeThreshold: f
} = K(), E = L(() => {
v && o((x) => ({ ...x, isDragging: !0 }));
}, [v, o]), T = L(
(x) => {
if (v && !n.scrolling && n.isDragging === !0 && x.clientY)
if (!n.start)
o((k) => ({
...k,
start: { x: x.clientX, y: x.clientY }
}));
else {
const C = D.clientX - u.start.x, U = D.clientY - u.start.y;
u.offsetting ? f((q) => ({ ...q, xOffset: C })) : (Math.abs(U) > 20 && f((q) => ({ ...q, scrolling: !0 })), Math.abs(C) > 10 && f((q) => ({ ...q, offsetting: !0, xOffset: C })));
const k = x.clientX - n.start.x, N = x.clientY - n.start.y;
n.offsetting ? o((P) => ({ ...P, xOffset: k })) : (Math.abs(N) > 20 && o((P) => ({ ...P, scrolling: !0 })), Math.abs(k) > 10 && o((P) => ({ ...P, offsetting: !0, xOffset: k })));
}
},
[
c,
u.scrolling,
u.isDragging,
u.start,
u.offsetting,
f
v,
n.scrolling,
n.isDragging,
n.start,
n.offsetting,
o
]
), F = pe(() => {
c && u.isDragging && (Math.abs(u.xOffset) > d && (u.xOffset < 0 ? v() : y()), f((D) => ({
...D,
), A = L(() => {
v && n.isDragging && (Math.abs(n.xOffset) > f && (n.xOffset < 0 ? d() : s()), o((x) => ({
...x,
isDragging: !1,

@@ -1480,60 +811,50 @@ xOffset: 0,

}, [
c,
u.isDragging,
u.xOffset,
v,
n.isDragging,
n.xOffset,
f,
o,
d,
f,
v,
y
s
]);
return /* @__PURE__ */ oe.jsx(
return /* @__PURE__ */ F.jsx(
"ul",
{
className: ge([J.gallery__main, _]),
onPointerDown: c ? p : null,
onPointerMove: c ? P : null,
onPointerUp: c ? F : null,
style: { "--selected": s, "--total": m.length },
...b,
children: m.map((D, C) => r({ item: D, index: C, activeIndex: s, active: s === C }))
className: U([O.gallery__main, _]),
onPointerDown: v ? E : null,
onPointerMove: v ? T : null,
onPointerUp: v ? A : null,
style: { "--selected": y, "--total": R.length },
...m,
children: R.map((x, k) => i({ item: x, index: k, activeIndex: y, active: y === k }))
}
);
};
it.propTypes = {
renderGalleryItem: W.func.isRequired,
className: W.string
};
const st = ({ renderPaginationItem: r, className: _, ...b }) => {
const { activeIndex: s, galleryItems: m } = Re();
return /* @__PURE__ */ oe.jsx("ul", { className: ge([J.gallery__pagination, _]), ...b, children: m.map((v, y) => r({ index: y, active: s === y, activeIndex: s, item: v })) });
};
st.propTypes = {
renderPaginationItem: W.func.isRequired,
className: W.string
};
const ut = ({
index: r,
}, Dr = ({ renderPaginationItem: i, className: _, ...m }) => {
const { activeIndex: y, galleryItems: R } = K();
return /* @__PURE__ */ F.jsx("ul", { className: U([O.gallery__pagination, _]), ...m, children: R.map((d, s) => i({ index: s, active: y === s, activeIndex: y, item: d })) });
}, Ar = ({
index: i,
active: _,
className: b,
buttonClassName: s,
buttonProps: m,
children: v,
...y
className: m,
buttonClassName: y,
buttonProps: R,
children: d,
...s
}) => {
const { goToIndex: c, itemNodes: u } = Re(), f = (d) => {
c(d), u.current[d].focus({ preventScroll: !0 });
const { goToIndex: v, itemNodes: n } = K(), o = (f) => {
v(f), n.current[f].focus({ preventScroll: !0 });
};
return /* @__PURE__ */ oe.jsx(
return /* @__PURE__ */ F.jsx(
"li",
{
className: ge([J["gallery__pagination-item"], b]),
...y,
children: /* @__PURE__ */ oe.jsx(
className: U([O["gallery__pagination-item"], m]),
...s,
children: /* @__PURE__ */ F.jsx(
"button",
{
className: s,
className: y,
"aria-current": _ ? "true" : null,
onClick: () => f(r),
...m,
children: v
onClick: () => o(i),
...R,
children: d
}

@@ -1543,100 +864,77 @@ )

);
};
ut.propTypes = {
index: W.number.isRequired,
active: W.bool.isRequired,
className: W.string,
buttonClassName: W.string,
buttonProps: W.object,
children: W.node,
onClick: W.func
};
const lt = ({
direction: r,
}, Fr = ({
direction: i,
renderNavItem: _,
className: b,
children: s,
...m
className: m,
children: y,
...R
}) => {
const { next: v, previous: y, loop: c, activeIndex: u, galleryItems: f } = Re(), d = () => {
r ? v() : y();
}, p = r && u === f.length - 1 || !r && u === 0, P = {
disabled: p ? !0 : null,
"aria-disabled": p ? "true" : null
const { next: d, previous: s, loop: v, activeIndex: n, galleryItems: o } = K(), f = () => {
i ? d() : s();
}, E = i && n === o.length - 1 || !i && n === 0, T = {
disabled: E ? !0 : null,
"aria-disabled": E ? "true" : null
};
return !s && !_ ? null : /* @__PURE__ */ oe.jsx(
return !y && !_ ? null : /* @__PURE__ */ F.jsx(
"button",
{
className: ge([
J.gallery__nav,
J[`gallery__nav--${r ? "next" : "previous"}`],
b
className: U([
O.gallery__nav,
O[`gallery__nav--${i ? "next" : "previous"}`],
m
]),
onClick: d,
...!c && P,
...m,
children: s || _({ activeIndex: u, disabled: !c && p })
onClick: f,
...!v && T,
...R,
children: y || _({ activeIndex: n, disabled: !v && E })
}
);
};
lt.propTypes = {
direction: W.oneOf([0, 1]).isRequired,
renderNavItem: W.func,
className: W.string,
children: W.node
};
const ct = ({ index: r, active: _, className: b, children: s, ...m }) => {
}, Wr = ({ index: i, active: _, className: m, children: y, ...R }) => {
const {
itemNodes: v,
activeIndex: y,
previouslyActiveIndex: c,
draggable: u,
touchState: f,
visibleRange: d
} = Re(), p = {
itemNodes: d,
activeIndex: s,
previouslyActiveIndex: v,
draggable: n,
touchState: o,
visibleRange: f
} = K(), E = {
"aria-hidden": _ ? null : "true",
tabIndex: _ ? 0 : -1
};
return /* @__PURE__ */ oe.jsx(
return /* @__PURE__ */ F.jsx(
"li",
{
ref: (P) => v.current[r] = P,
...p,
...m,
className: ge([
J.gallery__item,
u && J["gallery__item--draggable"],
u && f.offsetting && J["gallery__item--dragging"],
_ && J["gallery__item--active"],
r === c && J["gallery__item--was-active"],
r < y && J["gallery__item--left"],
r > y && J["gallery__item--right"],
(d === -1 || Math.abs(r - y) <= d) && J["gallery__item--visible"],
b
ref: (T) => d.current[i] = T,
...E,
...R,
className: U([
O.gallery__item,
n && O["gallery__item--draggable"],
n && o.offsetting && O["gallery__item--dragging"],
_ && O["gallery__item--active"],
i === v && O["gallery__item--was-active"],
i < s && O["gallery__item--left"],
i > s && O["gallery__item--right"],
(f === -1 || Math.abs(i - s) <= f) && O["gallery__item--visible"],
m
]),
style: {
"--i": r,
"--center-offset": Math.abs(r - y),
"--index-offset": r - y,
"--side": r < y ? -1 : r > y ? 1 : 0,
"--i": i,
"--center-offset": Math.abs(i - s),
"--index-offset": i - s,
"--side": i < s ? -1 : i > s ? 1 : 0,
"--active": _ ? 1 : 0
},
children: s
children: y
}
);
};
ct.propTypes = {
index: W.number.isRequired,
active: W.bool.isRequired,
className: W.string,
children: W.node
};
export {
gr as Gallery,
ct as GalleryItem,
it as GalleryMain,
lt as GalleryNav,
st as GalleryPagination,
ut as GalleryPaginationItem,
Re as useGallery
kr as Gallery,
Wr as GalleryItem,
Ir as GalleryMain,
Fr as GalleryNav,
Dr as GalleryPagination,
Ar as GalleryPaginationItem,
K as useGallery
};
{
"name": "@wethegit/react-gallery",
"version": "4.0.0",
"version": "4.0.1",
"description": "A customizable, accessible gallery component for React projects.",

@@ -82,6 +82,3 @@ "files": [

"react-dom": "17 - 18"
},
"dependencies": {
"prop-types": "~15.8.1"
}
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc