@process.co/ui 0.0.21 → 0.0.23
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/css/ui.css +48 -0
- package/dist/components/dev/index.cjs +213 -7
- package/dist/components/dev/index.cjs.map +1 -1
- package/dist/components/dev/index.d.cts +64 -3
- package/dist/components/dev/index.d.ts +64 -3
- package/dist/components/dev/index.js +214 -9
- package/dist/components/dev/index.js.map +1 -1
- package/dist/components/fields/index.cjs.map +1 -1
- package/dist/components/fields/index.js.map +1 -1
- package/dist/components/slots/index.cjs +1088 -92
- package/dist/components/slots/index.cjs.map +1 -1
- package/dist/components/slots/index.d.cts +1 -1
- package/dist/components/slots/index.d.ts +1 -1
- package/dist/components/slots/index.js +1088 -90
- package/dist/components/slots/index.js.map +1 -1
- package/dist/{index-NpNmoYuX.d.cts → index-D4Fc9AJv.d.cts} +15 -2
- package/dist/{index-NpNmoYuX.d.ts → index-D4Fc9AJv.d.ts} +15 -2
- package/dist/index.cjs +1028 -34
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1029 -32
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,13 +1,968 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import
|
|
1
|
+
import * as React4 from 'react';
|
|
2
|
+
import React4__default, { createContext, useContext, useState, useEffect } from 'react';
|
|
3
3
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
4
4
|
import 'react-dom';
|
|
5
|
-
import PropTypes from 'prop-types';
|
|
6
5
|
|
|
6
|
+
var __create = Object.create;
|
|
7
|
+
var __defProp = Object.defineProperty;
|
|
8
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
9
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
10
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
11
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
12
|
var __commonJS = (cb, mod) => function __require() {
|
|
9
13
|
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
10
14
|
};
|
|
15
|
+
var __copyProps = (to, from, except, desc) => {
|
|
16
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
17
|
+
for (let key of __getOwnPropNames(from))
|
|
18
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
19
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
20
|
+
}
|
|
21
|
+
return to;
|
|
22
|
+
};
|
|
23
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
24
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
25
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
26
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
27
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
28
|
+
!mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
29
|
+
mod
|
|
30
|
+
));
|
|
31
|
+
|
|
32
|
+
// ../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.production.min.js
|
|
33
|
+
var require_react_is_production_min = __commonJS({
|
|
34
|
+
"../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.production.min.js"(exports$1) {
|
|
35
|
+
var b = "function" === typeof Symbol && Symbol.for;
|
|
36
|
+
var c = b ? Symbol.for("react.element") : 60103;
|
|
37
|
+
var d = b ? Symbol.for("react.portal") : 60106;
|
|
38
|
+
var e = b ? Symbol.for("react.fragment") : 60107;
|
|
39
|
+
var f = b ? Symbol.for("react.strict_mode") : 60108;
|
|
40
|
+
var g2 = b ? Symbol.for("react.profiler") : 60114;
|
|
41
|
+
var h = b ? Symbol.for("react.provider") : 60109;
|
|
42
|
+
var k = b ? Symbol.for("react.context") : 60110;
|
|
43
|
+
var l = b ? Symbol.for("react.async_mode") : 60111;
|
|
44
|
+
var m = b ? Symbol.for("react.concurrent_mode") : 60111;
|
|
45
|
+
var n = b ? Symbol.for("react.forward_ref") : 60112;
|
|
46
|
+
var p2 = b ? Symbol.for("react.suspense") : 60113;
|
|
47
|
+
var q = b ? Symbol.for("react.suspense_list") : 60120;
|
|
48
|
+
var r3 = b ? Symbol.for("react.memo") : 60115;
|
|
49
|
+
var t2 = b ? Symbol.for("react.lazy") : 60116;
|
|
50
|
+
var v = b ? Symbol.for("react.block") : 60121;
|
|
51
|
+
var w2 = b ? Symbol.for("react.fundamental") : 60117;
|
|
52
|
+
var x2 = b ? Symbol.for("react.responder") : 60118;
|
|
53
|
+
var y = b ? Symbol.for("react.scope") : 60119;
|
|
54
|
+
function z(a) {
|
|
55
|
+
if ("object" === typeof a && null !== a) {
|
|
56
|
+
var u = a.$$typeof;
|
|
57
|
+
switch (u) {
|
|
58
|
+
case c:
|
|
59
|
+
switch (a = a.type, a) {
|
|
60
|
+
case l:
|
|
61
|
+
case m:
|
|
62
|
+
case e:
|
|
63
|
+
case g2:
|
|
64
|
+
case f:
|
|
65
|
+
case p2:
|
|
66
|
+
return a;
|
|
67
|
+
default:
|
|
68
|
+
switch (a = a && a.$$typeof, a) {
|
|
69
|
+
case k:
|
|
70
|
+
case n:
|
|
71
|
+
case t2:
|
|
72
|
+
case r3:
|
|
73
|
+
case h:
|
|
74
|
+
return a;
|
|
75
|
+
default:
|
|
76
|
+
return u;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
case d:
|
|
80
|
+
return u;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
function A2(a) {
|
|
85
|
+
return z(a) === m;
|
|
86
|
+
}
|
|
87
|
+
exports$1.AsyncMode = l;
|
|
88
|
+
exports$1.ConcurrentMode = m;
|
|
89
|
+
exports$1.ContextConsumer = k;
|
|
90
|
+
exports$1.ContextProvider = h;
|
|
91
|
+
exports$1.Element = c;
|
|
92
|
+
exports$1.ForwardRef = n;
|
|
93
|
+
exports$1.Fragment = e;
|
|
94
|
+
exports$1.Lazy = t2;
|
|
95
|
+
exports$1.Memo = r3;
|
|
96
|
+
exports$1.Portal = d;
|
|
97
|
+
exports$1.Profiler = g2;
|
|
98
|
+
exports$1.StrictMode = f;
|
|
99
|
+
exports$1.Suspense = p2;
|
|
100
|
+
exports$1.isAsyncMode = function(a) {
|
|
101
|
+
return A2(a) || z(a) === l;
|
|
102
|
+
};
|
|
103
|
+
exports$1.isConcurrentMode = A2;
|
|
104
|
+
exports$1.isContextConsumer = function(a) {
|
|
105
|
+
return z(a) === k;
|
|
106
|
+
};
|
|
107
|
+
exports$1.isContextProvider = function(a) {
|
|
108
|
+
return z(a) === h;
|
|
109
|
+
};
|
|
110
|
+
exports$1.isElement = function(a) {
|
|
111
|
+
return "object" === typeof a && null !== a && a.$$typeof === c;
|
|
112
|
+
};
|
|
113
|
+
exports$1.isForwardRef = function(a) {
|
|
114
|
+
return z(a) === n;
|
|
115
|
+
};
|
|
116
|
+
exports$1.isFragment = function(a) {
|
|
117
|
+
return z(a) === e;
|
|
118
|
+
};
|
|
119
|
+
exports$1.isLazy = function(a) {
|
|
120
|
+
return z(a) === t2;
|
|
121
|
+
};
|
|
122
|
+
exports$1.isMemo = function(a) {
|
|
123
|
+
return z(a) === r3;
|
|
124
|
+
};
|
|
125
|
+
exports$1.isPortal = function(a) {
|
|
126
|
+
return z(a) === d;
|
|
127
|
+
};
|
|
128
|
+
exports$1.isProfiler = function(a) {
|
|
129
|
+
return z(a) === g2;
|
|
130
|
+
};
|
|
131
|
+
exports$1.isStrictMode = function(a) {
|
|
132
|
+
return z(a) === f;
|
|
133
|
+
};
|
|
134
|
+
exports$1.isSuspense = function(a) {
|
|
135
|
+
return z(a) === p2;
|
|
136
|
+
};
|
|
137
|
+
exports$1.isValidElementType = function(a) {
|
|
138
|
+
return "string" === typeof a || "function" === typeof a || a === e || a === m || a === g2 || a === f || a === p2 || a === q || "object" === typeof a && null !== a && (a.$$typeof === t2 || a.$$typeof === r3 || a.$$typeof === h || a.$$typeof === k || a.$$typeof === n || a.$$typeof === w2 || a.$$typeof === x2 || a.$$typeof === y || a.$$typeof === v);
|
|
139
|
+
};
|
|
140
|
+
exports$1.typeOf = z;
|
|
141
|
+
}
|
|
142
|
+
});
|
|
143
|
+
|
|
144
|
+
// ../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.development.js
|
|
145
|
+
var require_react_is_development = __commonJS({
|
|
146
|
+
"../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.development.js"(exports$1) {
|
|
147
|
+
if (process.env.NODE_ENV !== "production") {
|
|
148
|
+
(function() {
|
|
149
|
+
var hasSymbol = typeof Symbol === "function" && Symbol.for;
|
|
150
|
+
var REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for("react.element") : 60103;
|
|
151
|
+
var REACT_PORTAL_TYPE = hasSymbol ? Symbol.for("react.portal") : 60106;
|
|
152
|
+
var REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for("react.fragment") : 60107;
|
|
153
|
+
var REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for("react.strict_mode") : 60108;
|
|
154
|
+
var REACT_PROFILER_TYPE = hasSymbol ? Symbol.for("react.profiler") : 60114;
|
|
155
|
+
var REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for("react.provider") : 60109;
|
|
156
|
+
var REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for("react.context") : 60110;
|
|
157
|
+
var REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for("react.async_mode") : 60111;
|
|
158
|
+
var REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for("react.concurrent_mode") : 60111;
|
|
159
|
+
var REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for("react.forward_ref") : 60112;
|
|
160
|
+
var REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for("react.suspense") : 60113;
|
|
161
|
+
var REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for("react.suspense_list") : 60120;
|
|
162
|
+
var REACT_MEMO_TYPE = hasSymbol ? Symbol.for("react.memo") : 60115;
|
|
163
|
+
var REACT_LAZY_TYPE2 = hasSymbol ? Symbol.for("react.lazy") : 60116;
|
|
164
|
+
var REACT_BLOCK_TYPE = hasSymbol ? Symbol.for("react.block") : 60121;
|
|
165
|
+
var REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for("react.fundamental") : 60117;
|
|
166
|
+
var REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for("react.responder") : 60118;
|
|
167
|
+
var REACT_SCOPE_TYPE = hasSymbol ? Symbol.for("react.scope") : 60119;
|
|
168
|
+
function isValidElementType(type) {
|
|
169
|
+
return typeof type === "string" || typeof type === "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
170
|
+
type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === "object" && type !== null && (type.$$typeof === REACT_LAZY_TYPE2 || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);
|
|
171
|
+
}
|
|
172
|
+
function typeOf(object) {
|
|
173
|
+
if (typeof object === "object" && object !== null) {
|
|
174
|
+
var $$typeof = object.$$typeof;
|
|
175
|
+
switch ($$typeof) {
|
|
176
|
+
case REACT_ELEMENT_TYPE:
|
|
177
|
+
var type = object.type;
|
|
178
|
+
switch (type) {
|
|
179
|
+
case REACT_ASYNC_MODE_TYPE:
|
|
180
|
+
case REACT_CONCURRENT_MODE_TYPE:
|
|
181
|
+
case REACT_FRAGMENT_TYPE:
|
|
182
|
+
case REACT_PROFILER_TYPE:
|
|
183
|
+
case REACT_STRICT_MODE_TYPE:
|
|
184
|
+
case REACT_SUSPENSE_TYPE:
|
|
185
|
+
return type;
|
|
186
|
+
default:
|
|
187
|
+
var $$typeofType = type && type.$$typeof;
|
|
188
|
+
switch ($$typeofType) {
|
|
189
|
+
case REACT_CONTEXT_TYPE:
|
|
190
|
+
case REACT_FORWARD_REF_TYPE:
|
|
191
|
+
case REACT_LAZY_TYPE2:
|
|
192
|
+
case REACT_MEMO_TYPE:
|
|
193
|
+
case REACT_PROVIDER_TYPE:
|
|
194
|
+
return $$typeofType;
|
|
195
|
+
default:
|
|
196
|
+
return $$typeof;
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
case REACT_PORTAL_TYPE:
|
|
200
|
+
return $$typeof;
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
return void 0;
|
|
204
|
+
}
|
|
205
|
+
var AsyncMode = REACT_ASYNC_MODE_TYPE;
|
|
206
|
+
var ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;
|
|
207
|
+
var ContextConsumer = REACT_CONTEXT_TYPE;
|
|
208
|
+
var ContextProvider = REACT_PROVIDER_TYPE;
|
|
209
|
+
var Element = REACT_ELEMENT_TYPE;
|
|
210
|
+
var ForwardRef = REACT_FORWARD_REF_TYPE;
|
|
211
|
+
var Fragment4 = REACT_FRAGMENT_TYPE;
|
|
212
|
+
var Lazy = REACT_LAZY_TYPE2;
|
|
213
|
+
var Memo = REACT_MEMO_TYPE;
|
|
214
|
+
var Portal = REACT_PORTAL_TYPE;
|
|
215
|
+
var Profiler = REACT_PROFILER_TYPE;
|
|
216
|
+
var StrictMode = REACT_STRICT_MODE_TYPE;
|
|
217
|
+
var Suspense = REACT_SUSPENSE_TYPE;
|
|
218
|
+
var hasWarnedAboutDeprecatedIsAsyncMode = false;
|
|
219
|
+
function isAsyncMode(object) {
|
|
220
|
+
{
|
|
221
|
+
if (!hasWarnedAboutDeprecatedIsAsyncMode) {
|
|
222
|
+
hasWarnedAboutDeprecatedIsAsyncMode = true;
|
|
223
|
+
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.");
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;
|
|
227
|
+
}
|
|
228
|
+
function isConcurrentMode(object) {
|
|
229
|
+
return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;
|
|
230
|
+
}
|
|
231
|
+
function isContextConsumer(object) {
|
|
232
|
+
return typeOf(object) === REACT_CONTEXT_TYPE;
|
|
233
|
+
}
|
|
234
|
+
function isContextProvider(object) {
|
|
235
|
+
return typeOf(object) === REACT_PROVIDER_TYPE;
|
|
236
|
+
}
|
|
237
|
+
function isElement(object) {
|
|
238
|
+
return typeof object === "object" && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;
|
|
239
|
+
}
|
|
240
|
+
function isForwardRef(object) {
|
|
241
|
+
return typeOf(object) === REACT_FORWARD_REF_TYPE;
|
|
242
|
+
}
|
|
243
|
+
function isFragment(object) {
|
|
244
|
+
return typeOf(object) === REACT_FRAGMENT_TYPE;
|
|
245
|
+
}
|
|
246
|
+
function isLazy(object) {
|
|
247
|
+
return typeOf(object) === REACT_LAZY_TYPE2;
|
|
248
|
+
}
|
|
249
|
+
function isMemo(object) {
|
|
250
|
+
return typeOf(object) === REACT_MEMO_TYPE;
|
|
251
|
+
}
|
|
252
|
+
function isPortal(object) {
|
|
253
|
+
return typeOf(object) === REACT_PORTAL_TYPE;
|
|
254
|
+
}
|
|
255
|
+
function isProfiler(object) {
|
|
256
|
+
return typeOf(object) === REACT_PROFILER_TYPE;
|
|
257
|
+
}
|
|
258
|
+
function isStrictMode(object) {
|
|
259
|
+
return typeOf(object) === REACT_STRICT_MODE_TYPE;
|
|
260
|
+
}
|
|
261
|
+
function isSuspense(object) {
|
|
262
|
+
return typeOf(object) === REACT_SUSPENSE_TYPE;
|
|
263
|
+
}
|
|
264
|
+
exports$1.AsyncMode = AsyncMode;
|
|
265
|
+
exports$1.ConcurrentMode = ConcurrentMode;
|
|
266
|
+
exports$1.ContextConsumer = ContextConsumer;
|
|
267
|
+
exports$1.ContextProvider = ContextProvider;
|
|
268
|
+
exports$1.Element = Element;
|
|
269
|
+
exports$1.ForwardRef = ForwardRef;
|
|
270
|
+
exports$1.Fragment = Fragment4;
|
|
271
|
+
exports$1.Lazy = Lazy;
|
|
272
|
+
exports$1.Memo = Memo;
|
|
273
|
+
exports$1.Portal = Portal;
|
|
274
|
+
exports$1.Profiler = Profiler;
|
|
275
|
+
exports$1.StrictMode = StrictMode;
|
|
276
|
+
exports$1.Suspense = Suspense;
|
|
277
|
+
exports$1.isAsyncMode = isAsyncMode;
|
|
278
|
+
exports$1.isConcurrentMode = isConcurrentMode;
|
|
279
|
+
exports$1.isContextConsumer = isContextConsumer;
|
|
280
|
+
exports$1.isContextProvider = isContextProvider;
|
|
281
|
+
exports$1.isElement = isElement;
|
|
282
|
+
exports$1.isForwardRef = isForwardRef;
|
|
283
|
+
exports$1.isFragment = isFragment;
|
|
284
|
+
exports$1.isLazy = isLazy;
|
|
285
|
+
exports$1.isMemo = isMemo;
|
|
286
|
+
exports$1.isPortal = isPortal;
|
|
287
|
+
exports$1.isProfiler = isProfiler;
|
|
288
|
+
exports$1.isStrictMode = isStrictMode;
|
|
289
|
+
exports$1.isSuspense = isSuspense;
|
|
290
|
+
exports$1.isValidElementType = isValidElementType;
|
|
291
|
+
exports$1.typeOf = typeOf;
|
|
292
|
+
})();
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
});
|
|
296
|
+
|
|
297
|
+
// ../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.js
|
|
298
|
+
var require_react_is = __commonJS({
|
|
299
|
+
"../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.js"(exports$1, module) {
|
|
300
|
+
if (process.env.NODE_ENV === "production") {
|
|
301
|
+
module.exports = require_react_is_production_min();
|
|
302
|
+
} else {
|
|
303
|
+
module.exports = require_react_is_development();
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
});
|
|
307
|
+
|
|
308
|
+
// ../../node_modules/.pnpm/object-assign@4.1.1/node_modules/object-assign/index.js
|
|
309
|
+
var require_object_assign = __commonJS({
|
|
310
|
+
"../../node_modules/.pnpm/object-assign@4.1.1/node_modules/object-assign/index.js"(exports$1, module) {
|
|
311
|
+
var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
|
312
|
+
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
313
|
+
var propIsEnumerable = Object.prototype.propertyIsEnumerable;
|
|
314
|
+
function toObject(val) {
|
|
315
|
+
if (val === null || val === void 0) {
|
|
316
|
+
throw new TypeError("Object.assign cannot be called with null or undefined");
|
|
317
|
+
}
|
|
318
|
+
return Object(val);
|
|
319
|
+
}
|
|
320
|
+
function shouldUseNative() {
|
|
321
|
+
try {
|
|
322
|
+
if (!Object.assign) {
|
|
323
|
+
return false;
|
|
324
|
+
}
|
|
325
|
+
var test1 = new String("abc");
|
|
326
|
+
test1[5] = "de";
|
|
327
|
+
if (Object.getOwnPropertyNames(test1)[0] === "5") {
|
|
328
|
+
return false;
|
|
329
|
+
}
|
|
330
|
+
var test2 = {};
|
|
331
|
+
for (var i = 0; i < 10; i++) {
|
|
332
|
+
test2["_" + String.fromCharCode(i)] = i;
|
|
333
|
+
}
|
|
334
|
+
var order2 = Object.getOwnPropertyNames(test2).map(function(n) {
|
|
335
|
+
return test2[n];
|
|
336
|
+
});
|
|
337
|
+
if (order2.join("") !== "0123456789") {
|
|
338
|
+
return false;
|
|
339
|
+
}
|
|
340
|
+
var test3 = {};
|
|
341
|
+
"abcdefghijklmnopqrst".split("").forEach(function(letter) {
|
|
342
|
+
test3[letter] = letter;
|
|
343
|
+
});
|
|
344
|
+
if (Object.keys(Object.assign({}, test3)).join("") !== "abcdefghijklmnopqrst") {
|
|
345
|
+
return false;
|
|
346
|
+
}
|
|
347
|
+
return true;
|
|
348
|
+
} catch (err) {
|
|
349
|
+
return false;
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
module.exports = shouldUseNative() ? Object.assign : function(target, source) {
|
|
353
|
+
var from;
|
|
354
|
+
var to = toObject(target);
|
|
355
|
+
var symbols;
|
|
356
|
+
for (var s2 = 1; s2 < arguments.length; s2++) {
|
|
357
|
+
from = Object(arguments[s2]);
|
|
358
|
+
for (var key in from) {
|
|
359
|
+
if (hasOwnProperty.call(from, key)) {
|
|
360
|
+
to[key] = from[key];
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
if (getOwnPropertySymbols) {
|
|
364
|
+
symbols = getOwnPropertySymbols(from);
|
|
365
|
+
for (var i = 0; i < symbols.length; i++) {
|
|
366
|
+
if (propIsEnumerable.call(from, symbols[i])) {
|
|
367
|
+
to[symbols[i]] = from[symbols[i]];
|
|
368
|
+
}
|
|
369
|
+
}
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
return to;
|
|
373
|
+
};
|
|
374
|
+
}
|
|
375
|
+
});
|
|
376
|
+
|
|
377
|
+
// ../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/lib/ReactPropTypesSecret.js
|
|
378
|
+
var require_ReactPropTypesSecret = __commonJS({
|
|
379
|
+
"../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/lib/ReactPropTypesSecret.js"(exports$1, module) {
|
|
380
|
+
var ReactPropTypesSecret = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
|
|
381
|
+
module.exports = ReactPropTypesSecret;
|
|
382
|
+
}
|
|
383
|
+
});
|
|
384
|
+
|
|
385
|
+
// ../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/lib/has.js
|
|
386
|
+
var require_has = __commonJS({
|
|
387
|
+
"../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/lib/has.js"(exports$1, module) {
|
|
388
|
+
module.exports = Function.call.bind(Object.prototype.hasOwnProperty);
|
|
389
|
+
}
|
|
390
|
+
});
|
|
391
|
+
|
|
392
|
+
// ../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/checkPropTypes.js
|
|
393
|
+
var require_checkPropTypes = __commonJS({
|
|
394
|
+
"../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/checkPropTypes.js"(exports$1, module) {
|
|
395
|
+
var printWarning = function() {
|
|
396
|
+
};
|
|
397
|
+
if (process.env.NODE_ENV !== "production") {
|
|
398
|
+
ReactPropTypesSecret = require_ReactPropTypesSecret();
|
|
399
|
+
loggedTypeFailures = {};
|
|
400
|
+
has = require_has();
|
|
401
|
+
printWarning = function(text2) {
|
|
402
|
+
var message = "Warning: " + text2;
|
|
403
|
+
if (typeof console !== "undefined") {
|
|
404
|
+
console.error(message);
|
|
405
|
+
}
|
|
406
|
+
try {
|
|
407
|
+
throw new Error(message);
|
|
408
|
+
} catch (x2) {
|
|
409
|
+
}
|
|
410
|
+
};
|
|
411
|
+
}
|
|
412
|
+
var ReactPropTypesSecret;
|
|
413
|
+
var loggedTypeFailures;
|
|
414
|
+
var has;
|
|
415
|
+
function checkPropTypes(typeSpecs, values, location, componentName, getStack) {
|
|
416
|
+
if (process.env.NODE_ENV !== "production") {
|
|
417
|
+
for (var typeSpecName in typeSpecs) {
|
|
418
|
+
if (has(typeSpecs, typeSpecName)) {
|
|
419
|
+
var error;
|
|
420
|
+
try {
|
|
421
|
+
if (typeof typeSpecs[typeSpecName] !== "function") {
|
|
422
|
+
var err = Error(
|
|
423
|
+
(componentName || "React class") + ": " + location + " type `" + typeSpecName + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof typeSpecs[typeSpecName] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
|
|
424
|
+
);
|
|
425
|
+
err.name = "Invariant Violation";
|
|
426
|
+
throw err;
|
|
427
|
+
}
|
|
428
|
+
error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);
|
|
429
|
+
} catch (ex) {
|
|
430
|
+
error = ex;
|
|
431
|
+
}
|
|
432
|
+
if (error && !(error instanceof Error)) {
|
|
433
|
+
printWarning(
|
|
434
|
+
(componentName || "React class") + ": type specification of " + location + " `" + typeSpecName + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof error + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
|
|
435
|
+
);
|
|
436
|
+
}
|
|
437
|
+
if (error instanceof Error && !(error.message in loggedTypeFailures)) {
|
|
438
|
+
loggedTypeFailures[error.message] = true;
|
|
439
|
+
var stack = getStack ? getStack() : "";
|
|
440
|
+
printWarning(
|
|
441
|
+
"Failed " + location + " type: " + error.message + (stack != null ? stack : "")
|
|
442
|
+
);
|
|
443
|
+
}
|
|
444
|
+
}
|
|
445
|
+
}
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
checkPropTypes.resetWarningCache = function() {
|
|
449
|
+
if (process.env.NODE_ENV !== "production") {
|
|
450
|
+
loggedTypeFailures = {};
|
|
451
|
+
}
|
|
452
|
+
};
|
|
453
|
+
module.exports = checkPropTypes;
|
|
454
|
+
}
|
|
455
|
+
});
|
|
456
|
+
|
|
457
|
+
// ../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/factoryWithTypeCheckers.js
|
|
458
|
+
var require_factoryWithTypeCheckers = __commonJS({
|
|
459
|
+
"../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/factoryWithTypeCheckers.js"(exports$1, module) {
|
|
460
|
+
var ReactIs = require_react_is();
|
|
461
|
+
var assign = require_object_assign();
|
|
462
|
+
var ReactPropTypesSecret = require_ReactPropTypesSecret();
|
|
463
|
+
var has = require_has();
|
|
464
|
+
var checkPropTypes = require_checkPropTypes();
|
|
465
|
+
var printWarning = function() {
|
|
466
|
+
};
|
|
467
|
+
if (process.env.NODE_ENV !== "production") {
|
|
468
|
+
printWarning = function(text2) {
|
|
469
|
+
var message = "Warning: " + text2;
|
|
470
|
+
if (typeof console !== "undefined") {
|
|
471
|
+
console.error(message);
|
|
472
|
+
}
|
|
473
|
+
try {
|
|
474
|
+
throw new Error(message);
|
|
475
|
+
} catch (x2) {
|
|
476
|
+
}
|
|
477
|
+
};
|
|
478
|
+
}
|
|
479
|
+
function emptyFunctionThatReturnsNull() {
|
|
480
|
+
return null;
|
|
481
|
+
}
|
|
482
|
+
module.exports = function(isValidElement3, throwOnDirectAccess) {
|
|
483
|
+
var ITERATOR_SYMBOL = typeof Symbol === "function" && Symbol.iterator;
|
|
484
|
+
var FAUX_ITERATOR_SYMBOL = "@@iterator";
|
|
485
|
+
function getIteratorFn(maybeIterable) {
|
|
486
|
+
var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);
|
|
487
|
+
if (typeof iteratorFn === "function") {
|
|
488
|
+
return iteratorFn;
|
|
489
|
+
}
|
|
490
|
+
}
|
|
491
|
+
var ANONYMOUS = "<<anonymous>>";
|
|
492
|
+
var ReactPropTypes = {
|
|
493
|
+
array: createPrimitiveTypeChecker("array"),
|
|
494
|
+
bigint: createPrimitiveTypeChecker("bigint"),
|
|
495
|
+
bool: createPrimitiveTypeChecker("boolean"),
|
|
496
|
+
func: createPrimitiveTypeChecker("function"),
|
|
497
|
+
number: createPrimitiveTypeChecker("number"),
|
|
498
|
+
object: createPrimitiveTypeChecker("object"),
|
|
499
|
+
string: createPrimitiveTypeChecker("string"),
|
|
500
|
+
symbol: createPrimitiveTypeChecker("symbol"),
|
|
501
|
+
any: createAnyTypeChecker(),
|
|
502
|
+
arrayOf: createArrayOfTypeChecker,
|
|
503
|
+
element: createElementTypeChecker(),
|
|
504
|
+
elementType: createElementTypeTypeChecker(),
|
|
505
|
+
instanceOf: createInstanceTypeChecker,
|
|
506
|
+
node: createNodeChecker(),
|
|
507
|
+
objectOf: createObjectOfTypeChecker,
|
|
508
|
+
oneOf: createEnumTypeChecker,
|
|
509
|
+
oneOfType: createUnionTypeChecker,
|
|
510
|
+
shape: createShapeTypeChecker,
|
|
511
|
+
exact: createStrictShapeTypeChecker
|
|
512
|
+
};
|
|
513
|
+
function is(x2, y) {
|
|
514
|
+
if (x2 === y) {
|
|
515
|
+
return x2 !== 0 || 1 / x2 === 1 / y;
|
|
516
|
+
} else {
|
|
517
|
+
return x2 !== x2 && y !== y;
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
function PropTypeError(message, data) {
|
|
521
|
+
this.message = message;
|
|
522
|
+
this.data = data && typeof data === "object" ? data : {};
|
|
523
|
+
this.stack = "";
|
|
524
|
+
}
|
|
525
|
+
PropTypeError.prototype = Error.prototype;
|
|
526
|
+
function createChainableTypeChecker(validate) {
|
|
527
|
+
if (process.env.NODE_ENV !== "production") {
|
|
528
|
+
var manualPropTypeCallCache = {};
|
|
529
|
+
var manualPropTypeWarningCount = 0;
|
|
530
|
+
}
|
|
531
|
+
function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {
|
|
532
|
+
componentName = componentName || ANONYMOUS;
|
|
533
|
+
propFullName = propFullName || propName;
|
|
534
|
+
if (secret !== ReactPropTypesSecret) {
|
|
535
|
+
if (throwOnDirectAccess) {
|
|
536
|
+
var err = new Error(
|
|
537
|
+
"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"
|
|
538
|
+
);
|
|
539
|
+
err.name = "Invariant Violation";
|
|
540
|
+
throw err;
|
|
541
|
+
} else if (process.env.NODE_ENV !== "production" && typeof console !== "undefined") {
|
|
542
|
+
var cacheKey = componentName + ":" + propName;
|
|
543
|
+
if (!manualPropTypeCallCache[cacheKey] && // Avoid spamming the console because they are often not actionable except for lib authors
|
|
544
|
+
manualPropTypeWarningCount < 3) {
|
|
545
|
+
printWarning(
|
|
546
|
+
"You are manually calling a React.PropTypes validation function for the `" + propFullName + "` prop on `" + componentName + "`. 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."
|
|
547
|
+
);
|
|
548
|
+
manualPropTypeCallCache[cacheKey] = true;
|
|
549
|
+
manualPropTypeWarningCount++;
|
|
550
|
+
}
|
|
551
|
+
}
|
|
552
|
+
}
|
|
553
|
+
if (props[propName] == null) {
|
|
554
|
+
if (isRequired) {
|
|
555
|
+
if (props[propName] === null) {
|
|
556
|
+
return new PropTypeError("The " + location + " `" + propFullName + "` is marked as required " + ("in `" + componentName + "`, but its value is `null`."));
|
|
557
|
+
}
|
|
558
|
+
return new PropTypeError("The " + location + " `" + propFullName + "` is marked as required in " + ("`" + componentName + "`, but its value is `undefined`."));
|
|
559
|
+
}
|
|
560
|
+
return null;
|
|
561
|
+
} else {
|
|
562
|
+
return validate(props, propName, componentName, location, propFullName);
|
|
563
|
+
}
|
|
564
|
+
}
|
|
565
|
+
var chainedCheckType = checkType.bind(null, false);
|
|
566
|
+
chainedCheckType.isRequired = checkType.bind(null, true);
|
|
567
|
+
return chainedCheckType;
|
|
568
|
+
}
|
|
569
|
+
function createPrimitiveTypeChecker(expectedType) {
|
|
570
|
+
function validate(props, propName, componentName, location, propFullName, secret) {
|
|
571
|
+
var propValue = props[propName];
|
|
572
|
+
var propType = getPropType(propValue);
|
|
573
|
+
if (propType !== expectedType) {
|
|
574
|
+
var preciseType = getPreciseType(propValue);
|
|
575
|
+
return new PropTypeError(
|
|
576
|
+
"Invalid " + location + " `" + propFullName + "` of type " + ("`" + preciseType + "` supplied to `" + componentName + "`, expected ") + ("`" + expectedType + "`."),
|
|
577
|
+
{ expectedType }
|
|
578
|
+
);
|
|
579
|
+
}
|
|
580
|
+
return null;
|
|
581
|
+
}
|
|
582
|
+
return createChainableTypeChecker(validate);
|
|
583
|
+
}
|
|
584
|
+
function createAnyTypeChecker() {
|
|
585
|
+
return createChainableTypeChecker(emptyFunctionThatReturnsNull);
|
|
586
|
+
}
|
|
587
|
+
function createArrayOfTypeChecker(typeChecker) {
|
|
588
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
589
|
+
if (typeof typeChecker !== "function") {
|
|
590
|
+
return new PropTypeError("Property `" + propFullName + "` of component `" + componentName + "` has invalid PropType notation inside arrayOf.");
|
|
591
|
+
}
|
|
592
|
+
var propValue = props[propName];
|
|
593
|
+
if (!Array.isArray(propValue)) {
|
|
594
|
+
var propType = getPropType(propValue);
|
|
595
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected an array."));
|
|
596
|
+
}
|
|
597
|
+
for (var i = 0; i < propValue.length; i++) {
|
|
598
|
+
var error = typeChecker(propValue, i, componentName, location, propFullName + "[" + i + "]", ReactPropTypesSecret);
|
|
599
|
+
if (error instanceof Error) {
|
|
600
|
+
return error;
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
return null;
|
|
604
|
+
}
|
|
605
|
+
return createChainableTypeChecker(validate);
|
|
606
|
+
}
|
|
607
|
+
function createElementTypeChecker() {
|
|
608
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
609
|
+
var propValue = props[propName];
|
|
610
|
+
if (!isValidElement3(propValue)) {
|
|
611
|
+
var propType = getPropType(propValue);
|
|
612
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected a single ReactElement."));
|
|
613
|
+
}
|
|
614
|
+
return null;
|
|
615
|
+
}
|
|
616
|
+
return createChainableTypeChecker(validate);
|
|
617
|
+
}
|
|
618
|
+
function createElementTypeTypeChecker() {
|
|
619
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
620
|
+
var propValue = props[propName];
|
|
621
|
+
if (!ReactIs.isValidElementType(propValue)) {
|
|
622
|
+
var propType = getPropType(propValue);
|
|
623
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected a single ReactElement type."));
|
|
624
|
+
}
|
|
625
|
+
return null;
|
|
626
|
+
}
|
|
627
|
+
return createChainableTypeChecker(validate);
|
|
628
|
+
}
|
|
629
|
+
function createInstanceTypeChecker(expectedClass) {
|
|
630
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
631
|
+
if (!(props[propName] instanceof expectedClass)) {
|
|
632
|
+
var expectedClassName = expectedClass.name || ANONYMOUS;
|
|
633
|
+
var actualClassName = getClassName(props[propName]);
|
|
634
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + actualClassName + "` supplied to `" + componentName + "`, expected ") + ("instance of `" + expectedClassName + "`."));
|
|
635
|
+
}
|
|
636
|
+
return null;
|
|
637
|
+
}
|
|
638
|
+
return createChainableTypeChecker(validate);
|
|
639
|
+
}
|
|
640
|
+
function createEnumTypeChecker(expectedValues) {
|
|
641
|
+
if (!Array.isArray(expectedValues)) {
|
|
642
|
+
if (process.env.NODE_ENV !== "production") {
|
|
643
|
+
if (arguments.length > 1) {
|
|
644
|
+
printWarning(
|
|
645
|
+
"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])."
|
|
646
|
+
);
|
|
647
|
+
} else {
|
|
648
|
+
printWarning("Invalid argument supplied to oneOf, expected an array.");
|
|
649
|
+
}
|
|
650
|
+
}
|
|
651
|
+
return emptyFunctionThatReturnsNull;
|
|
652
|
+
}
|
|
653
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
654
|
+
var propValue = props[propName];
|
|
655
|
+
for (var i = 0; i < expectedValues.length; i++) {
|
|
656
|
+
if (is(propValue, expectedValues[i])) {
|
|
657
|
+
return null;
|
|
658
|
+
}
|
|
659
|
+
}
|
|
660
|
+
var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {
|
|
661
|
+
var type = getPreciseType(value);
|
|
662
|
+
if (type === "symbol") {
|
|
663
|
+
return String(value);
|
|
664
|
+
}
|
|
665
|
+
return value;
|
|
666
|
+
});
|
|
667
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` of value `" + String(propValue) + "` " + ("supplied to `" + componentName + "`, expected one of " + valuesString + "."));
|
|
668
|
+
}
|
|
669
|
+
return createChainableTypeChecker(validate);
|
|
670
|
+
}
|
|
671
|
+
function createObjectOfTypeChecker(typeChecker) {
|
|
672
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
673
|
+
if (typeof typeChecker !== "function") {
|
|
674
|
+
return new PropTypeError("Property `" + propFullName + "` of component `" + componentName + "` has invalid PropType notation inside objectOf.");
|
|
675
|
+
}
|
|
676
|
+
var propValue = props[propName];
|
|
677
|
+
var propType = getPropType(propValue);
|
|
678
|
+
if (propType !== "object") {
|
|
679
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type " + ("`" + propType + "` supplied to `" + componentName + "`, expected an object."));
|
|
680
|
+
}
|
|
681
|
+
for (var key in propValue) {
|
|
682
|
+
if (has(propValue, key)) {
|
|
683
|
+
var error = typeChecker(propValue, key, componentName, location, propFullName + "." + key, ReactPropTypesSecret);
|
|
684
|
+
if (error instanceof Error) {
|
|
685
|
+
return error;
|
|
686
|
+
}
|
|
687
|
+
}
|
|
688
|
+
}
|
|
689
|
+
return null;
|
|
690
|
+
}
|
|
691
|
+
return createChainableTypeChecker(validate);
|
|
692
|
+
}
|
|
693
|
+
function createUnionTypeChecker(arrayOfTypeCheckers) {
|
|
694
|
+
if (!Array.isArray(arrayOfTypeCheckers)) {
|
|
695
|
+
process.env.NODE_ENV !== "production" ? printWarning("Invalid argument supplied to oneOfType, expected an instance of array.") : void 0;
|
|
696
|
+
return emptyFunctionThatReturnsNull;
|
|
697
|
+
}
|
|
698
|
+
for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
|
|
699
|
+
var checker = arrayOfTypeCheckers[i];
|
|
700
|
+
if (typeof checker !== "function") {
|
|
701
|
+
printWarning(
|
|
702
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + getPostfixForTypeWarning(checker) + " at index " + i + "."
|
|
703
|
+
);
|
|
704
|
+
return emptyFunctionThatReturnsNull;
|
|
705
|
+
}
|
|
706
|
+
}
|
|
707
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
708
|
+
var expectedTypes = [];
|
|
709
|
+
for (var i2 = 0; i2 < arrayOfTypeCheckers.length; i2++) {
|
|
710
|
+
var checker2 = arrayOfTypeCheckers[i2];
|
|
711
|
+
var checkerResult = checker2(props, propName, componentName, location, propFullName, ReactPropTypesSecret);
|
|
712
|
+
if (checkerResult == null) {
|
|
713
|
+
return null;
|
|
714
|
+
}
|
|
715
|
+
if (checkerResult.data && has(checkerResult.data, "expectedType")) {
|
|
716
|
+
expectedTypes.push(checkerResult.data.expectedType);
|
|
717
|
+
}
|
|
718
|
+
}
|
|
719
|
+
var expectedTypesMessage = expectedTypes.length > 0 ? ", expected one of type [" + expectedTypes.join(", ") + "]" : "";
|
|
720
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` supplied to " + ("`" + componentName + "`" + expectedTypesMessage + "."));
|
|
721
|
+
}
|
|
722
|
+
return createChainableTypeChecker(validate);
|
|
723
|
+
}
|
|
724
|
+
function createNodeChecker() {
|
|
725
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
726
|
+
if (!isNode(props[propName])) {
|
|
727
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` supplied to " + ("`" + componentName + "`, expected a ReactNode."));
|
|
728
|
+
}
|
|
729
|
+
return null;
|
|
730
|
+
}
|
|
731
|
+
return createChainableTypeChecker(validate);
|
|
732
|
+
}
|
|
733
|
+
function invalidValidatorError(componentName, location, propFullName, key, type) {
|
|
734
|
+
return new PropTypeError(
|
|
735
|
+
(componentName || "React class") + ": " + location + " type `" + propFullName + "." + key + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + type + "`."
|
|
736
|
+
);
|
|
737
|
+
}
|
|
738
|
+
function createShapeTypeChecker(shapeTypes) {
|
|
739
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
740
|
+
var propValue = props[propName];
|
|
741
|
+
var propType = getPropType(propValue);
|
|
742
|
+
if (propType !== "object") {
|
|
743
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type `" + propType + "` " + ("supplied to `" + componentName + "`, expected `object`."));
|
|
744
|
+
}
|
|
745
|
+
for (var key in shapeTypes) {
|
|
746
|
+
var checker = shapeTypes[key];
|
|
747
|
+
if (typeof checker !== "function") {
|
|
748
|
+
return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));
|
|
749
|
+
}
|
|
750
|
+
var error = checker(propValue, key, componentName, location, propFullName + "." + key, ReactPropTypesSecret);
|
|
751
|
+
if (error) {
|
|
752
|
+
return error;
|
|
753
|
+
}
|
|
754
|
+
}
|
|
755
|
+
return null;
|
|
756
|
+
}
|
|
757
|
+
return createChainableTypeChecker(validate);
|
|
758
|
+
}
|
|
759
|
+
function createStrictShapeTypeChecker(shapeTypes) {
|
|
760
|
+
function validate(props, propName, componentName, location, propFullName) {
|
|
761
|
+
var propValue = props[propName];
|
|
762
|
+
var propType = getPropType(propValue);
|
|
763
|
+
if (propType !== "object") {
|
|
764
|
+
return new PropTypeError("Invalid " + location + " `" + propFullName + "` of type `" + propType + "` " + ("supplied to `" + componentName + "`, expected `object`."));
|
|
765
|
+
}
|
|
766
|
+
var allKeys = assign({}, props[propName], shapeTypes);
|
|
767
|
+
for (var key in allKeys) {
|
|
768
|
+
var checker = shapeTypes[key];
|
|
769
|
+
if (has(shapeTypes, key) && typeof checker !== "function") {
|
|
770
|
+
return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));
|
|
771
|
+
}
|
|
772
|
+
if (!checker) {
|
|
773
|
+
return new PropTypeError(
|
|
774
|
+
"Invalid " + location + " `" + propFullName + "` key `" + key + "` supplied to `" + componentName + "`.\nBad object: " + JSON.stringify(props[propName], null, " ") + "\nValid keys: " + JSON.stringify(Object.keys(shapeTypes), null, " ")
|
|
775
|
+
);
|
|
776
|
+
}
|
|
777
|
+
var error = checker(propValue, key, componentName, location, propFullName + "." + key, ReactPropTypesSecret);
|
|
778
|
+
if (error) {
|
|
779
|
+
return error;
|
|
780
|
+
}
|
|
781
|
+
}
|
|
782
|
+
return null;
|
|
783
|
+
}
|
|
784
|
+
return createChainableTypeChecker(validate);
|
|
785
|
+
}
|
|
786
|
+
function isNode(propValue) {
|
|
787
|
+
switch (typeof propValue) {
|
|
788
|
+
case "number":
|
|
789
|
+
case "string":
|
|
790
|
+
case "undefined":
|
|
791
|
+
return true;
|
|
792
|
+
case "boolean":
|
|
793
|
+
return !propValue;
|
|
794
|
+
case "object":
|
|
795
|
+
if (Array.isArray(propValue)) {
|
|
796
|
+
return propValue.every(isNode);
|
|
797
|
+
}
|
|
798
|
+
if (propValue === null || isValidElement3(propValue)) {
|
|
799
|
+
return true;
|
|
800
|
+
}
|
|
801
|
+
var iteratorFn = getIteratorFn(propValue);
|
|
802
|
+
if (iteratorFn) {
|
|
803
|
+
var iterator = iteratorFn.call(propValue);
|
|
804
|
+
var step;
|
|
805
|
+
if (iteratorFn !== propValue.entries) {
|
|
806
|
+
while (!(step = iterator.next()).done) {
|
|
807
|
+
if (!isNode(step.value)) {
|
|
808
|
+
return false;
|
|
809
|
+
}
|
|
810
|
+
}
|
|
811
|
+
} else {
|
|
812
|
+
while (!(step = iterator.next()).done) {
|
|
813
|
+
var entry = step.value;
|
|
814
|
+
if (entry) {
|
|
815
|
+
if (!isNode(entry[1])) {
|
|
816
|
+
return false;
|
|
817
|
+
}
|
|
818
|
+
}
|
|
819
|
+
}
|
|
820
|
+
}
|
|
821
|
+
} else {
|
|
822
|
+
return false;
|
|
823
|
+
}
|
|
824
|
+
return true;
|
|
825
|
+
default:
|
|
826
|
+
return false;
|
|
827
|
+
}
|
|
828
|
+
}
|
|
829
|
+
function isSymbol(propType, propValue) {
|
|
830
|
+
if (propType === "symbol") {
|
|
831
|
+
return true;
|
|
832
|
+
}
|
|
833
|
+
if (!propValue) {
|
|
834
|
+
return false;
|
|
835
|
+
}
|
|
836
|
+
if (propValue["@@toStringTag"] === "Symbol") {
|
|
837
|
+
return true;
|
|
838
|
+
}
|
|
839
|
+
if (typeof Symbol === "function" && propValue instanceof Symbol) {
|
|
840
|
+
return true;
|
|
841
|
+
}
|
|
842
|
+
return false;
|
|
843
|
+
}
|
|
844
|
+
function getPropType(propValue) {
|
|
845
|
+
var propType = typeof propValue;
|
|
846
|
+
if (Array.isArray(propValue)) {
|
|
847
|
+
return "array";
|
|
848
|
+
}
|
|
849
|
+
if (propValue instanceof RegExp) {
|
|
850
|
+
return "object";
|
|
851
|
+
}
|
|
852
|
+
if (isSymbol(propType, propValue)) {
|
|
853
|
+
return "symbol";
|
|
854
|
+
}
|
|
855
|
+
return propType;
|
|
856
|
+
}
|
|
857
|
+
function getPreciseType(propValue) {
|
|
858
|
+
if (typeof propValue === "undefined" || propValue === null) {
|
|
859
|
+
return "" + propValue;
|
|
860
|
+
}
|
|
861
|
+
var propType = getPropType(propValue);
|
|
862
|
+
if (propType === "object") {
|
|
863
|
+
if (propValue instanceof Date) {
|
|
864
|
+
return "date";
|
|
865
|
+
} else if (propValue instanceof RegExp) {
|
|
866
|
+
return "regexp";
|
|
867
|
+
}
|
|
868
|
+
}
|
|
869
|
+
return propType;
|
|
870
|
+
}
|
|
871
|
+
function getPostfixForTypeWarning(value) {
|
|
872
|
+
var type = getPreciseType(value);
|
|
873
|
+
switch (type) {
|
|
874
|
+
case "array":
|
|
875
|
+
case "object":
|
|
876
|
+
return "an " + type;
|
|
877
|
+
case "boolean":
|
|
878
|
+
case "date":
|
|
879
|
+
case "regexp":
|
|
880
|
+
return "a " + type;
|
|
881
|
+
default:
|
|
882
|
+
return type;
|
|
883
|
+
}
|
|
884
|
+
}
|
|
885
|
+
function getClassName(propValue) {
|
|
886
|
+
if (!propValue.constructor || !propValue.constructor.name) {
|
|
887
|
+
return ANONYMOUS;
|
|
888
|
+
}
|
|
889
|
+
return propValue.constructor.name;
|
|
890
|
+
}
|
|
891
|
+
ReactPropTypes.checkPropTypes = checkPropTypes;
|
|
892
|
+
ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;
|
|
893
|
+
ReactPropTypes.PropTypes = ReactPropTypes;
|
|
894
|
+
return ReactPropTypes;
|
|
895
|
+
};
|
|
896
|
+
}
|
|
897
|
+
});
|
|
898
|
+
|
|
899
|
+
// ../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/factoryWithThrowingShims.js
|
|
900
|
+
var require_factoryWithThrowingShims = __commonJS({
|
|
901
|
+
"../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/factoryWithThrowingShims.js"(exports$1, module) {
|
|
902
|
+
var ReactPropTypesSecret = require_ReactPropTypesSecret();
|
|
903
|
+
function emptyFunction() {
|
|
904
|
+
}
|
|
905
|
+
function emptyFunctionWithReset() {
|
|
906
|
+
}
|
|
907
|
+
emptyFunctionWithReset.resetWarningCache = emptyFunction;
|
|
908
|
+
module.exports = function() {
|
|
909
|
+
function shim(props, propName, componentName, location, propFullName, secret) {
|
|
910
|
+
if (secret === ReactPropTypesSecret) {
|
|
911
|
+
return;
|
|
912
|
+
}
|
|
913
|
+
var err = new Error(
|
|
914
|
+
"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"
|
|
915
|
+
);
|
|
916
|
+
err.name = "Invariant Violation";
|
|
917
|
+
throw err;
|
|
918
|
+
}
|
|
919
|
+
shim.isRequired = shim;
|
|
920
|
+
function getShim() {
|
|
921
|
+
return shim;
|
|
922
|
+
}
|
|
923
|
+
var ReactPropTypes = {
|
|
924
|
+
array: shim,
|
|
925
|
+
bigint: shim,
|
|
926
|
+
bool: shim,
|
|
927
|
+
func: shim,
|
|
928
|
+
number: shim,
|
|
929
|
+
object: shim,
|
|
930
|
+
string: shim,
|
|
931
|
+
symbol: shim,
|
|
932
|
+
any: shim,
|
|
933
|
+
arrayOf: getShim,
|
|
934
|
+
element: shim,
|
|
935
|
+
elementType: shim,
|
|
936
|
+
instanceOf: getShim,
|
|
937
|
+
node: shim,
|
|
938
|
+
objectOf: getShim,
|
|
939
|
+
oneOf: getShim,
|
|
940
|
+
oneOfType: getShim,
|
|
941
|
+
shape: getShim,
|
|
942
|
+
exact: getShim,
|
|
943
|
+
checkPropTypes: emptyFunctionWithReset,
|
|
944
|
+
resetWarningCache: emptyFunction
|
|
945
|
+
};
|
|
946
|
+
ReactPropTypes.PropTypes = ReactPropTypes;
|
|
947
|
+
return ReactPropTypes;
|
|
948
|
+
};
|
|
949
|
+
}
|
|
950
|
+
});
|
|
951
|
+
|
|
952
|
+
// ../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/index.js
|
|
953
|
+
var require_prop_types = __commonJS({
|
|
954
|
+
"../../node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/index.js"(exports$1, module) {
|
|
955
|
+
if (process.env.NODE_ENV !== "production") {
|
|
956
|
+
ReactIs = require_react_is();
|
|
957
|
+
throwOnDirectAccess = true;
|
|
958
|
+
module.exports = require_factoryWithTypeCheckers()(ReactIs.isElement, throwOnDirectAccess);
|
|
959
|
+
} else {
|
|
960
|
+
module.exports = require_factoryWithThrowingShims()();
|
|
961
|
+
}
|
|
962
|
+
var ReactIs;
|
|
963
|
+
var throwOnDirectAccess;
|
|
964
|
+
}
|
|
965
|
+
});
|
|
11
966
|
|
|
12
967
|
// ../../node_modules/.pnpm/@fortawesome+fontawesome-svg-core@6.7.2/node_modules/@fortawesome/fontawesome-svg-core/package.json
|
|
13
968
|
var require_package = __commonJS({
|
|
@@ -88,6 +1043,7 @@ var require_package = __commonJS({
|
|
|
88
1043
|
};
|
|
89
1044
|
}
|
|
90
1045
|
});
|
|
1046
|
+
var DevContext = createContext(null);
|
|
91
1047
|
|
|
92
1048
|
// src/components/slots/SlotElements.tsx
|
|
93
1049
|
var SlotElements = (props) => {
|
|
@@ -126,10 +1082,10 @@ function composeRefs(...refs) {
|
|
|
126
1082
|
};
|
|
127
1083
|
}
|
|
128
1084
|
function useComposedRefs(...refs) {
|
|
129
|
-
return
|
|
1085
|
+
return React4.useCallback(composeRefs(...refs), refs);
|
|
130
1086
|
}
|
|
131
1087
|
var REACT_LAZY_TYPE = Symbol.for("react.lazy");
|
|
132
|
-
var use =
|
|
1088
|
+
var use = React4[" use ".trim().toString()];
|
|
133
1089
|
function isPromiseLike(value) {
|
|
134
1090
|
return typeof value === "object" && value !== null && "then" in value;
|
|
135
1091
|
}
|
|
@@ -139,24 +1095,24 @@ function isLazyComponent(element) {
|
|
|
139
1095
|
// @__NO_SIDE_EFFECTS__
|
|
140
1096
|
function createSlot(ownerName) {
|
|
141
1097
|
const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);
|
|
142
|
-
const Slot2 =
|
|
1098
|
+
const Slot2 = React4.forwardRef((props, forwardedRef) => {
|
|
143
1099
|
let { children, ...slotProps } = props;
|
|
144
1100
|
if (isLazyComponent(children) && typeof use === "function") {
|
|
145
1101
|
children = use(children._payload);
|
|
146
1102
|
}
|
|
147
|
-
const childrenArray =
|
|
1103
|
+
const childrenArray = React4.Children.toArray(children);
|
|
148
1104
|
const slottable = childrenArray.find(isSlottable);
|
|
149
1105
|
if (slottable) {
|
|
150
1106
|
const newElement = slottable.props.children;
|
|
151
1107
|
const newChildren = childrenArray.map((child) => {
|
|
152
1108
|
if (child === slottable) {
|
|
153
|
-
if (
|
|
154
|
-
return
|
|
1109
|
+
if (React4.Children.count(newElement) > 1) return React4.Children.only(null);
|
|
1110
|
+
return React4.isValidElement(newElement) ? newElement.props.children : null;
|
|
155
1111
|
} else {
|
|
156
1112
|
return child;
|
|
157
1113
|
}
|
|
158
1114
|
});
|
|
159
|
-
return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children:
|
|
1115
|
+
return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React4.isValidElement(newElement) ? React4.cloneElement(newElement, void 0, newChildren) : null });
|
|
160
1116
|
}
|
|
161
1117
|
return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
|
|
162
1118
|
});
|
|
@@ -166,27 +1122,27 @@ function createSlot(ownerName) {
|
|
|
166
1122
|
var Slot = /* @__PURE__ */ createSlot("Slot");
|
|
167
1123
|
// @__NO_SIDE_EFFECTS__
|
|
168
1124
|
function createSlotClone(ownerName) {
|
|
169
|
-
const SlotClone =
|
|
1125
|
+
const SlotClone = React4.forwardRef((props, forwardedRef) => {
|
|
170
1126
|
let { children, ...slotProps } = props;
|
|
171
1127
|
if (isLazyComponent(children) && typeof use === "function") {
|
|
172
1128
|
children = use(children._payload);
|
|
173
1129
|
}
|
|
174
|
-
if (
|
|
1130
|
+
if (React4.isValidElement(children)) {
|
|
175
1131
|
const childrenRef = getElementRef(children);
|
|
176
1132
|
const props2 = mergeProps(slotProps, children.props);
|
|
177
|
-
if (children.type !==
|
|
1133
|
+
if (children.type !== React4.Fragment) {
|
|
178
1134
|
props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
|
|
179
1135
|
}
|
|
180
|
-
return
|
|
1136
|
+
return React4.cloneElement(children, props2);
|
|
181
1137
|
}
|
|
182
|
-
return
|
|
1138
|
+
return React4.Children.count(children) > 1 ? React4.Children.only(null) : null;
|
|
183
1139
|
});
|
|
184
1140
|
SlotClone.displayName = `${ownerName}.SlotClone`;
|
|
185
1141
|
return SlotClone;
|
|
186
1142
|
}
|
|
187
1143
|
var SLOTTABLE_IDENTIFIER = Symbol("radix.slottable");
|
|
188
1144
|
function isSlottable(child) {
|
|
189
|
-
return
|
|
1145
|
+
return React4.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;
|
|
190
1146
|
}
|
|
191
1147
|
function mergeProps(slotProps, childProps) {
|
|
192
1148
|
const overrideProps = { ...childProps };
|
|
@@ -3333,7 +4289,7 @@ function Button({
|
|
|
3333
4289
|
...props
|
|
3334
4290
|
}) {
|
|
3335
4291
|
const Comp = asChild ? Slot : "button";
|
|
3336
|
-
return /* @__PURE__ */
|
|
4292
|
+
return /* @__PURE__ */ React4.createElement(
|
|
3337
4293
|
Comp,
|
|
3338
4294
|
{
|
|
3339
4295
|
"data-slot": "button",
|
|
@@ -3359,32 +4315,32 @@ function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForD
|
|
|
3359
4315
|
function createContextScope(scopeName, createContextScopeDeps = []) {
|
|
3360
4316
|
let defaultContexts = [];
|
|
3361
4317
|
function createContext3(rootComponentName, defaultContext) {
|
|
3362
|
-
const BaseContext =
|
|
4318
|
+
const BaseContext = React4.createContext(defaultContext);
|
|
3363
4319
|
const index = defaultContexts.length;
|
|
3364
4320
|
defaultContexts = [...defaultContexts, defaultContext];
|
|
3365
4321
|
const Provider = (props) => {
|
|
3366
4322
|
const { scope, children, ...context } = props;
|
|
3367
4323
|
const Context = scope?.[scopeName]?.[index] || BaseContext;
|
|
3368
|
-
const value =
|
|
4324
|
+
const value = React4.useMemo(() => context, Object.values(context));
|
|
3369
4325
|
return /* @__PURE__ */ jsx(Context.Provider, { value, children });
|
|
3370
4326
|
};
|
|
3371
4327
|
Provider.displayName = rootComponentName + "Provider";
|
|
3372
|
-
function
|
|
4328
|
+
function useContext22(consumerName, scope) {
|
|
3373
4329
|
const Context = scope?.[scopeName]?.[index] || BaseContext;
|
|
3374
|
-
const context =
|
|
4330
|
+
const context = React4.useContext(Context);
|
|
3375
4331
|
if (context) return context;
|
|
3376
4332
|
if (defaultContext !== void 0) return defaultContext;
|
|
3377
4333
|
throw new Error(`\`${consumerName}\` must be used within \`${rootComponentName}\``);
|
|
3378
4334
|
}
|
|
3379
|
-
return [Provider,
|
|
4335
|
+
return [Provider, useContext22];
|
|
3380
4336
|
}
|
|
3381
4337
|
const createScope = () => {
|
|
3382
4338
|
const scopeContexts = defaultContexts.map((defaultContext) => {
|
|
3383
|
-
return
|
|
4339
|
+
return React4.createContext(defaultContext);
|
|
3384
4340
|
});
|
|
3385
4341
|
return function useScope(scope) {
|
|
3386
4342
|
const contexts = scope?.[scopeName] || scopeContexts;
|
|
3387
|
-
return
|
|
4343
|
+
return React4.useMemo(
|
|
3388
4344
|
() => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),
|
|
3389
4345
|
[scope, contexts]
|
|
3390
4346
|
);
|
|
@@ -3407,15 +4363,15 @@ function composeContextScopes(...scopes) {
|
|
|
3407
4363
|
const currentScope = scopeProps[`__scope${scopeName}`];
|
|
3408
4364
|
return { ...nextScopes2, ...currentScope };
|
|
3409
4365
|
}, {});
|
|
3410
|
-
return
|
|
4366
|
+
return React4.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);
|
|
3411
4367
|
};
|
|
3412
4368
|
};
|
|
3413
4369
|
createScope.scopeName = baseScope.scopeName;
|
|
3414
4370
|
return createScope;
|
|
3415
4371
|
}
|
|
3416
|
-
var useLayoutEffect2 = globalThis?.document ?
|
|
4372
|
+
var useLayoutEffect2 = globalThis?.document ? React4.useLayoutEffect : () => {
|
|
3417
4373
|
};
|
|
3418
|
-
var useInsertionEffect =
|
|
4374
|
+
var useInsertionEffect = React4[" useInsertionEffect ".trim().toString()] || useLayoutEffect2;
|
|
3419
4375
|
function useControllableState({
|
|
3420
4376
|
prop,
|
|
3421
4377
|
defaultProp,
|
|
@@ -3430,8 +4386,8 @@ function useControllableState({
|
|
|
3430
4386
|
const isControlled = prop !== void 0;
|
|
3431
4387
|
const value = isControlled ? prop : uncontrolledProp;
|
|
3432
4388
|
{
|
|
3433
|
-
const isControlledRef =
|
|
3434
|
-
|
|
4389
|
+
const isControlledRef = React4.useRef(prop !== void 0);
|
|
4390
|
+
React4.useEffect(() => {
|
|
3435
4391
|
const wasControlled = isControlledRef.current;
|
|
3436
4392
|
if (wasControlled !== isControlled) {
|
|
3437
4393
|
const from = wasControlled ? "controlled" : "uncontrolled";
|
|
@@ -3443,7 +4399,7 @@ function useControllableState({
|
|
|
3443
4399
|
isControlledRef.current = isControlled;
|
|
3444
4400
|
}, [isControlled, caller]);
|
|
3445
4401
|
}
|
|
3446
|
-
const setValue =
|
|
4402
|
+
const setValue = React4.useCallback(
|
|
3447
4403
|
(nextValue) => {
|
|
3448
4404
|
if (isControlled) {
|
|
3449
4405
|
const value2 = isFunction(nextValue) ? nextValue(prop) : nextValue;
|
|
@@ -3462,13 +4418,13 @@ function useUncontrolledState({
|
|
|
3462
4418
|
defaultProp,
|
|
3463
4419
|
onChange: onChange2
|
|
3464
4420
|
}) {
|
|
3465
|
-
const [value, setValue] =
|
|
3466
|
-
const prevValueRef =
|
|
3467
|
-
const onChangeRef =
|
|
4421
|
+
const [value, setValue] = React4.useState(defaultProp);
|
|
4422
|
+
const prevValueRef = React4.useRef(value);
|
|
4423
|
+
const onChangeRef = React4.useRef(onChange2);
|
|
3468
4424
|
useInsertionEffect(() => {
|
|
3469
4425
|
onChangeRef.current = onChange2;
|
|
3470
4426
|
}, [onChange2]);
|
|
3471
|
-
|
|
4427
|
+
React4.useEffect(() => {
|
|
3472
4428
|
if (prevValueRef.current !== value) {
|
|
3473
4429
|
onChangeRef.current?.(value);
|
|
3474
4430
|
prevValueRef.current = value;
|
|
@@ -3480,8 +4436,8 @@ function isFunction(value) {
|
|
|
3480
4436
|
return typeof value === "function";
|
|
3481
4437
|
}
|
|
3482
4438
|
function usePrevious(value) {
|
|
3483
|
-
const ref =
|
|
3484
|
-
return
|
|
4439
|
+
const ref = React4.useRef({ value, previous: value });
|
|
4440
|
+
return React4.useMemo(() => {
|
|
3485
4441
|
if (ref.current.value !== value) {
|
|
3486
4442
|
ref.current.previous = ref.current.value;
|
|
3487
4443
|
ref.current.value = value;
|
|
@@ -3490,7 +4446,7 @@ function usePrevious(value) {
|
|
|
3490
4446
|
}, [value]);
|
|
3491
4447
|
}
|
|
3492
4448
|
function useSize(element) {
|
|
3493
|
-
const [size, setSize] =
|
|
4449
|
+
const [size, setSize] = React4.useState(void 0);
|
|
3494
4450
|
useLayoutEffect2(() => {
|
|
3495
4451
|
if (element) {
|
|
3496
4452
|
setSize({ width: element.offsetWidth, height: element.offsetHeight });
|
|
@@ -3526,21 +4482,21 @@ function useSize(element) {
|
|
|
3526
4482
|
// @__NO_SIDE_EFFECTS__
|
|
3527
4483
|
function createSlot2(ownerName) {
|
|
3528
4484
|
const SlotClone = /* @__PURE__ */ createSlotClone2(ownerName);
|
|
3529
|
-
const Slot2 =
|
|
4485
|
+
const Slot2 = React4.forwardRef((props, forwardedRef) => {
|
|
3530
4486
|
const { children, ...slotProps } = props;
|
|
3531
|
-
const childrenArray =
|
|
4487
|
+
const childrenArray = React4.Children.toArray(children);
|
|
3532
4488
|
const slottable = childrenArray.find(isSlottable2);
|
|
3533
4489
|
if (slottable) {
|
|
3534
4490
|
const newElement = slottable.props.children;
|
|
3535
4491
|
const newChildren = childrenArray.map((child) => {
|
|
3536
4492
|
if (child === slottable) {
|
|
3537
|
-
if (
|
|
3538
|
-
return
|
|
4493
|
+
if (React4.Children.count(newElement) > 1) return React4.Children.only(null);
|
|
4494
|
+
return React4.isValidElement(newElement) ? newElement.props.children : null;
|
|
3539
4495
|
} else {
|
|
3540
4496
|
return child;
|
|
3541
4497
|
}
|
|
3542
4498
|
});
|
|
3543
|
-
return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children:
|
|
4499
|
+
return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React4.isValidElement(newElement) ? React4.cloneElement(newElement, void 0, newChildren) : null });
|
|
3544
4500
|
}
|
|
3545
4501
|
return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });
|
|
3546
4502
|
});
|
|
@@ -3549,24 +4505,24 @@ function createSlot2(ownerName) {
|
|
|
3549
4505
|
}
|
|
3550
4506
|
// @__NO_SIDE_EFFECTS__
|
|
3551
4507
|
function createSlotClone2(ownerName) {
|
|
3552
|
-
const SlotClone =
|
|
4508
|
+
const SlotClone = React4.forwardRef((props, forwardedRef) => {
|
|
3553
4509
|
const { children, ...slotProps } = props;
|
|
3554
|
-
if (
|
|
4510
|
+
if (React4.isValidElement(children)) {
|
|
3555
4511
|
const childrenRef = getElementRef2(children);
|
|
3556
4512
|
const props2 = mergeProps2(slotProps, children.props);
|
|
3557
|
-
if (children.type !==
|
|
4513
|
+
if (children.type !== React4.Fragment) {
|
|
3558
4514
|
props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;
|
|
3559
4515
|
}
|
|
3560
|
-
return
|
|
4516
|
+
return React4.cloneElement(children, props2);
|
|
3561
4517
|
}
|
|
3562
|
-
return
|
|
4518
|
+
return React4.Children.count(children) > 1 ? React4.Children.only(null) : null;
|
|
3563
4519
|
});
|
|
3564
4520
|
SlotClone.displayName = `${ownerName}.SlotClone`;
|
|
3565
4521
|
return SlotClone;
|
|
3566
4522
|
}
|
|
3567
4523
|
var SLOTTABLE_IDENTIFIER2 = Symbol("radix.slottable");
|
|
3568
4524
|
function isSlottable2(child) {
|
|
3569
|
-
return
|
|
4525
|
+
return React4.isValidElement(child) && typeof child.type === "function" && "__radixId" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER2;
|
|
3570
4526
|
}
|
|
3571
4527
|
function mergeProps2(slotProps, childProps) {
|
|
3572
4528
|
const overrideProps = { ...childProps };
|
|
@@ -3626,7 +4582,7 @@ var NODES = [
|
|
|
3626
4582
|
];
|
|
3627
4583
|
var Primitive = NODES.reduce((primitive, node) => {
|
|
3628
4584
|
const Slot2 = createSlot2(`Primitive.${node}`);
|
|
3629
|
-
const Node2 =
|
|
4585
|
+
const Node2 = React4.forwardRef((props, forwardedRef) => {
|
|
3630
4586
|
const { asChild, ...primitiveProps } = props;
|
|
3631
4587
|
const Comp = asChild ? Slot2 : node;
|
|
3632
4588
|
if (typeof window !== "undefined") {
|
|
@@ -3640,7 +4596,7 @@ var Primitive = NODES.reduce((primitive, node) => {
|
|
|
3640
4596
|
var SWITCH_NAME = "Switch";
|
|
3641
4597
|
var [createSwitchContext] = createContextScope(SWITCH_NAME);
|
|
3642
4598
|
var [SwitchProvider, useSwitchContext] = createSwitchContext(SWITCH_NAME);
|
|
3643
|
-
var Switch =
|
|
4599
|
+
var Switch = React4.forwardRef(
|
|
3644
4600
|
(props, forwardedRef) => {
|
|
3645
4601
|
const {
|
|
3646
4602
|
__scopeSwitch,
|
|
@@ -3654,9 +4610,9 @@ var Switch = React3.forwardRef(
|
|
|
3654
4610
|
form,
|
|
3655
4611
|
...switchProps
|
|
3656
4612
|
} = props;
|
|
3657
|
-
const [button, setButton] =
|
|
4613
|
+
const [button, setButton] = React4.useState(null);
|
|
3658
4614
|
const composedRefs = useComposedRefs(forwardedRef, (node) => setButton(node));
|
|
3659
|
-
const hasConsumerStoppedPropagationRef =
|
|
4615
|
+
const hasConsumerStoppedPropagationRef = React4.useRef(false);
|
|
3660
4616
|
const isFormControl = button ? form || !!button.closest("form") : true;
|
|
3661
4617
|
const [checked, setChecked] = useControllableState({
|
|
3662
4618
|
prop: checkedProp,
|
|
@@ -3706,7 +4662,7 @@ var Switch = React3.forwardRef(
|
|
|
3706
4662
|
);
|
|
3707
4663
|
Switch.displayName = SWITCH_NAME;
|
|
3708
4664
|
var THUMB_NAME = "SwitchThumb";
|
|
3709
|
-
var SwitchThumb =
|
|
4665
|
+
var SwitchThumb = React4.forwardRef(
|
|
3710
4666
|
(props, forwardedRef) => {
|
|
3711
4667
|
const { __scopeSwitch, ...thumbProps } = props;
|
|
3712
4668
|
const context = useSwitchContext(THUMB_NAME, __scopeSwitch);
|
|
@@ -3723,7 +4679,7 @@ var SwitchThumb = React3.forwardRef(
|
|
|
3723
4679
|
);
|
|
3724
4680
|
SwitchThumb.displayName = THUMB_NAME;
|
|
3725
4681
|
var BUBBLE_INPUT_NAME = "SwitchBubbleInput";
|
|
3726
|
-
var SwitchBubbleInput =
|
|
4682
|
+
var SwitchBubbleInput = React4.forwardRef(
|
|
3727
4683
|
({
|
|
3728
4684
|
__scopeSwitch,
|
|
3729
4685
|
control,
|
|
@@ -3731,11 +4687,11 @@ var SwitchBubbleInput = React3.forwardRef(
|
|
|
3731
4687
|
bubbles = true,
|
|
3732
4688
|
...props
|
|
3733
4689
|
}, forwardedRef) => {
|
|
3734
|
-
const ref =
|
|
4690
|
+
const ref = React4.useRef(null);
|
|
3735
4691
|
const composedRefs = useComposedRefs(ref, forwardedRef);
|
|
3736
4692
|
const prevChecked = usePrevious(checked);
|
|
3737
4693
|
const controlSize = useSize(control);
|
|
3738
|
-
|
|
4694
|
+
React4.useEffect(() => {
|
|
3739
4695
|
const input = ref.current;
|
|
3740
4696
|
if (!input) return;
|
|
3741
4697
|
const inputProto = window.HTMLInputElement.prototype;
|
|
@@ -3816,14 +4772,14 @@ var switchThumbVariants = cva(
|
|
|
3816
4772
|
}
|
|
3817
4773
|
);
|
|
3818
4774
|
function Switch2({ className, size, ...props }) {
|
|
3819
|
-
return /* @__PURE__ */
|
|
4775
|
+
return /* @__PURE__ */ React4.createElement(
|
|
3820
4776
|
Root,
|
|
3821
4777
|
{
|
|
3822
4778
|
"data-slot": "switch",
|
|
3823
4779
|
className: cn(switchRootVariants({ size }), className),
|
|
3824
4780
|
...props
|
|
3825
4781
|
},
|
|
3826
|
-
/* @__PURE__ */
|
|
4782
|
+
/* @__PURE__ */ React4.createElement(
|
|
3827
4783
|
Thumb,
|
|
3828
4784
|
{
|
|
3829
4785
|
"data-slot": "switch-thumb",
|
|
@@ -6627,6 +7583,9 @@ var icon = api.icon;
|
|
|
6627
7583
|
api.layer;
|
|
6628
7584
|
api.text;
|
|
6629
7585
|
api.counter;
|
|
7586
|
+
|
|
7587
|
+
// ../../node_modules/.pnpm/@fortawesome+react-fontawesome@0.2.6_@fortawesome+fontawesome-svg-core@6.7.2_react@19.2.2/node_modules/@fortawesome/react-fontawesome/index.es.js
|
|
7588
|
+
var import_prop_types = __toESM(require_prop_types());
|
|
6630
7589
|
function _arrayLikeToArray(r3, a) {
|
|
6631
7590
|
(null == a || a > r3.length) && (a = r3.length);
|
|
6632
7591
|
for (var e = 0, n = Array(a); e < a; e++) n[e] = r3[e];
|
|
@@ -6945,7 +7904,7 @@ var defaultProps = {
|
|
|
6945
7904
|
swapOpacity: false,
|
|
6946
7905
|
widthAuto: false
|
|
6947
7906
|
};
|
|
6948
|
-
var FontAwesomeIcon = /* @__PURE__ */
|
|
7907
|
+
var FontAwesomeIcon = /* @__PURE__ */ React4__default.forwardRef(function(props, ref) {
|
|
6949
7908
|
var allProps = _objectSpread22(_objectSpread22({}, defaultProps), props);
|
|
6950
7909
|
var iconArgs = allProps.icon, maskArgs = allProps.mask, symbol = allProps.symbol, className = allProps.className, title = allProps.title, titleId = allProps.titleId, maskId = allProps.maskId;
|
|
6951
7910
|
var iconLookup = normalizeIconArgs(iconArgs);
|
|
@@ -6975,38 +7934,38 @@ var FontAwesomeIcon = /* @__PURE__ */ React3__default.forwardRef(function(props,
|
|
|
6975
7934
|
});
|
|
6976
7935
|
FontAwesomeIcon.displayName = "FontAwesomeIcon";
|
|
6977
7936
|
FontAwesomeIcon.propTypes = {
|
|
6978
|
-
beat:
|
|
6979
|
-
border:
|
|
6980
|
-
beatFade:
|
|
6981
|
-
bounce:
|
|
6982
|
-
className:
|
|
6983
|
-
fade:
|
|
6984
|
-
flash:
|
|
6985
|
-
mask:
|
|
6986
|
-
maskId:
|
|
7937
|
+
beat: import_prop_types.default.bool,
|
|
7938
|
+
border: import_prop_types.default.bool,
|
|
7939
|
+
beatFade: import_prop_types.default.bool,
|
|
7940
|
+
bounce: import_prop_types.default.bool,
|
|
7941
|
+
className: import_prop_types.default.string,
|
|
7942
|
+
fade: import_prop_types.default.bool,
|
|
7943
|
+
flash: import_prop_types.default.bool,
|
|
7944
|
+
mask: import_prop_types.default.oneOfType([import_prop_types.default.object, import_prop_types.default.array, import_prop_types.default.string]),
|
|
7945
|
+
maskId: import_prop_types.default.string,
|
|
6987
7946
|
// the fixedWidth property has been deprecated as of version 7
|
|
6988
|
-
fixedWidth:
|
|
6989
|
-
inverse:
|
|
6990
|
-
flip:
|
|
6991
|
-
icon:
|
|
6992
|
-
listItem:
|
|
6993
|
-
pull:
|
|
6994
|
-
pulse:
|
|
6995
|
-
rotation:
|
|
6996
|
-
rotateBy:
|
|
6997
|
-
shake:
|
|
6998
|
-
size:
|
|
6999
|
-
spin:
|
|
7000
|
-
spinPulse:
|
|
7001
|
-
spinReverse:
|
|
7002
|
-
symbol:
|
|
7003
|
-
title:
|
|
7004
|
-
titleId:
|
|
7005
|
-
transform:
|
|
7006
|
-
swapOpacity:
|
|
7007
|
-
widthAuto:
|
|
7947
|
+
fixedWidth: import_prop_types.default.bool,
|
|
7948
|
+
inverse: import_prop_types.default.bool,
|
|
7949
|
+
flip: import_prop_types.default.oneOf([true, false, "horizontal", "vertical", "both"]),
|
|
7950
|
+
icon: import_prop_types.default.oneOfType([import_prop_types.default.object, import_prop_types.default.array, import_prop_types.default.string]),
|
|
7951
|
+
listItem: import_prop_types.default.bool,
|
|
7952
|
+
pull: import_prop_types.default.oneOf(["right", "left"]),
|
|
7953
|
+
pulse: import_prop_types.default.bool,
|
|
7954
|
+
rotation: import_prop_types.default.oneOf([0, 90, 180, 270]),
|
|
7955
|
+
rotateBy: import_prop_types.default.bool,
|
|
7956
|
+
shake: import_prop_types.default.bool,
|
|
7957
|
+
size: import_prop_types.default.oneOf(["2xs", "xs", "sm", "lg", "xl", "2xl", "1x", "2x", "3x", "4x", "5x", "6x", "7x", "8x", "9x", "10x"]),
|
|
7958
|
+
spin: import_prop_types.default.bool,
|
|
7959
|
+
spinPulse: import_prop_types.default.bool,
|
|
7960
|
+
spinReverse: import_prop_types.default.bool,
|
|
7961
|
+
symbol: import_prop_types.default.oneOfType([import_prop_types.default.bool, import_prop_types.default.string]),
|
|
7962
|
+
title: import_prop_types.default.string,
|
|
7963
|
+
titleId: import_prop_types.default.string,
|
|
7964
|
+
transform: import_prop_types.default.oneOfType([import_prop_types.default.string, import_prop_types.default.object]),
|
|
7965
|
+
swapOpacity: import_prop_types.default.bool,
|
|
7966
|
+
widthAuto: import_prop_types.default.bool
|
|
7008
7967
|
};
|
|
7009
|
-
var convertCurry = convert.bind(null,
|
|
7968
|
+
var convertCurry = convert.bind(null, React4__default.createElement);
|
|
7010
7969
|
|
|
7011
7970
|
// ../../node_modules/.pnpm/@fortawesome+pro-solid-svg-icons@6.7.2/node_modules/@fortawesome/pro-solid-svg-icons/index.mjs
|
|
7012
7971
|
var faGripVertical = {
|
|
@@ -7031,8 +7990,47 @@ var SlotDragHandle = (props) => {
|
|
|
7031
7990
|
const { slotId } = props;
|
|
7032
7991
|
return /* @__PURE__ */ React.createElement("div", { className: "uii:cursor-grab" }, /* @__PURE__ */ React.createElement(FontAwesomeIcon, { icon: faGripVertical }));
|
|
7033
7992
|
};
|
|
7993
|
+
|
|
7994
|
+
// src/components/slots/index.tsx
|
|
7995
|
+
function useSlotContext(slotId) {
|
|
7996
|
+
const devContext = useContext(DevContext);
|
|
7997
|
+
const [activeSlotId, setActiveSlotId] = useState(void 0);
|
|
7998
|
+
useEffect(() => {
|
|
7999
|
+
if (devContext) {
|
|
8000
|
+
setActiveSlotId(devContext.activeSlotId ?? void 0);
|
|
8001
|
+
}
|
|
8002
|
+
}, [devContext, slotId]);
|
|
8003
|
+
return { active: (activeSlotId ?? "") === slotId, enabled: true };
|
|
8004
|
+
}
|
|
7034
8005
|
/*! Bundled license information:
|
|
7035
8006
|
|
|
8007
|
+
react-is/cjs/react-is.production.min.js:
|
|
8008
|
+
(** @license React v16.13.1
|
|
8009
|
+
* react-is.production.min.js
|
|
8010
|
+
*
|
|
8011
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
8012
|
+
*
|
|
8013
|
+
* This source code is licensed under the MIT license found in the
|
|
8014
|
+
* LICENSE file in the root directory of this source tree.
|
|
8015
|
+
*)
|
|
8016
|
+
|
|
8017
|
+
react-is/cjs/react-is.development.js:
|
|
8018
|
+
(** @license React v16.13.1
|
|
8019
|
+
* react-is.development.js
|
|
8020
|
+
*
|
|
8021
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
8022
|
+
*
|
|
8023
|
+
* This source code is licensed under the MIT license found in the
|
|
8024
|
+
* LICENSE file in the root directory of this source tree.
|
|
8025
|
+
*)
|
|
8026
|
+
|
|
8027
|
+
object-assign/index.js:
|
|
8028
|
+
(*
|
|
8029
|
+
object-assign
|
|
8030
|
+
(c) Sindre Sorhus
|
|
8031
|
+
@license MIT
|
|
8032
|
+
*)
|
|
8033
|
+
|
|
7036
8034
|
@fortawesome/fontawesome-svg-core/index.mjs:
|
|
7037
8035
|
(*!
|
|
7038
8036
|
* Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com
|
|
@@ -7048,6 +8046,6 @@ var SlotDragHandle = (props) => {
|
|
|
7048
8046
|
*)
|
|
7049
8047
|
*/
|
|
7050
8048
|
|
|
7051
|
-
export { ExportManager, SlotDelete, SlotDragHandle, SlotElements, SlotEnable };
|
|
8049
|
+
export { ExportManager, SlotDelete, SlotDragHandle, SlotElements, SlotEnable, useSlotContext };
|
|
7052
8050
|
//# sourceMappingURL=index.js.map
|
|
7053
8051
|
//# sourceMappingURL=index.js.map
|