@chaibuilder/sdk 1.2.77 → 1.2.78
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{CodeEditor-J-XqPeSx.js → CodeEditor-GsTOzMVg.js} +2 -2
- package/dist/{CodeEditor-qSebvlcW.cjs → CodeEditor-jefVJM0J.cjs} +1 -1
- package/dist/STRINGS-TDN5UhWi.js +7 -0
- package/dist/STRINGS-Yl7cSWDc.cjs +1 -0
- package/dist/{Topbar-uwCF26N5.js → Topbar-Nc6eEWWP.js} +2 -2
- package/dist/{Topbar-tfoXdBnv.cjs → Topbar-XyIs0-bw.cjs} +1 -1
- package/dist/{UnsplashImages-wKvqSePy.cjs → UnsplashImages-CXv1GzLl.cjs} +1 -1
- package/dist/{UnsplashImages-ycaFnevC.js → UnsplashImages-SUnc-2ZG.js} +2 -2
- package/dist/{UploadImages-_y_ACWKk.cjs → UploadImages-h-IZsdZq.cjs} +1 -1
- package/dist/{UploadImages-SBOaVL2H.js → UploadImages-iewW_N13.js} +2 -2
- package/dist/core.cjs +1 -1
- package/dist/core.d.ts +25 -3
- package/dist/core.js +56 -53
- package/dist/{index-wgzGsKsU.js → index-5TMff_bN.js} +1107 -1070
- package/dist/{index-AnW6pixe.cjs → index-QtgjVIUR.cjs} +14 -14
- package/dist/render.cjs +1 -1
- package/dist/render.js +1 -1
- package/dist/web-blocks.cjs +1 -1
- package/dist/web-blocks.js +38 -37
- package/package.json +1 -1
- package/dist/STRINGS-hZpwIZMT.cjs +0 -1
- package/dist/STRINGS-rPGH65PW.js +0 -8
|
@@ -14,7 +14,7 @@ import { g as getDefaultExportFromCjs, p as plugin, c as commonjsGlobal } from "
|
|
|
14
14
|
import { useThrottledCallback, useResizeObserver, useDebouncedCallback, useIntervalEffect } from "@react-hookz/web";
|
|
15
15
|
import TreeModel from "tree-model";
|
|
16
16
|
import ReactQuill, { Quill } from "react-quill";
|
|
17
|
-
import { S as SLOT_KEY, I as I18N_KEY, a as STYLES_KEY, R as ROOT_TEMP_KEY
|
|
17
|
+
import { S as SLOT_KEY, I as I18N_KEY, a as STYLES_KEY, R as ROOT_TEMP_KEY } from "./STRINGS-TDN5UhWi.js";
|
|
18
18
|
import { useHotkeys } from "react-hotkeys-hook";
|
|
19
19
|
import { flip as flip$2 } from "@floating-ui/dom";
|
|
20
20
|
import { useFloating as useFloating$1, shift, getOverflowAncestors, autoUpdate, size, offset, limitShift, flip as flip$3, inline, arrow } from "@floating-ui/react-dom";
|
|
@@ -94,35 +94,35 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
94
94
|
(define_import_meta_env_default$2 ? "production" : void 0) !== "production" && Object.freeze(O);
|
|
95
95
|
const T = r.get(k);
|
|
96
96
|
if (r.set(k, O), o.has(k) || o.set(k, T), T && hasPromiseAtomValue(T)) {
|
|
97
|
-
const
|
|
98
|
-
cancelPromise(T.v,
|
|
97
|
+
const B = "v" in O ? O.v instanceof Promise ? O.v : Promise.resolve(O.v) : Promise.reject(O.e);
|
|
98
|
+
cancelPromise(T.v, B);
|
|
99
99
|
}
|
|
100
100
|
}, d = (k, O, T) => {
|
|
101
|
-
const
|
|
102
|
-
let
|
|
101
|
+
const B = /* @__PURE__ */ new Map();
|
|
102
|
+
let L = !1;
|
|
103
103
|
T.forEach((D, W) => {
|
|
104
|
-
!D && W === k && (D = O), D ? (
|
|
105
|
-
}), (
|
|
104
|
+
!D && W === k && (D = O), D ? (B.set(W, D), O.d.get(W) !== D && (L = !0)) : (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && console.warn("[Bug] atom state not found");
|
|
105
|
+
}), (L || O.d.size !== B.size) && (O.d = B);
|
|
106
106
|
}, m = (k, O, T) => {
|
|
107
|
-
const
|
|
108
|
-
d: (
|
|
107
|
+
const B = c(k), L = {
|
|
108
|
+
d: (B == null ? void 0 : B.d) || /* @__PURE__ */ new Map(),
|
|
109
109
|
v: O
|
|
110
110
|
};
|
|
111
|
-
if (T && d(k,
|
|
112
|
-
return
|
|
113
|
-
if (
|
|
114
|
-
if (
|
|
115
|
-
return
|
|
116
|
-
|
|
111
|
+
if (T && d(k, L, T), B && isEqualAtomValue(B, L) && B.d === L.d)
|
|
112
|
+
return B;
|
|
113
|
+
if (B && hasPromiseAtomValue(B) && hasPromiseAtomValue(L) && isEqualPromiseAtomValue(B, L)) {
|
|
114
|
+
if (B.d === L.d)
|
|
115
|
+
return B;
|
|
116
|
+
L.v = B.v;
|
|
117
117
|
}
|
|
118
|
-
return u(k,
|
|
119
|
-
}, p = (k, O, T,
|
|
118
|
+
return u(k, L), L;
|
|
119
|
+
}, p = (k, O, T, B) => {
|
|
120
120
|
if (isPromiseLike$2(O)) {
|
|
121
|
-
let
|
|
121
|
+
let L;
|
|
122
122
|
const D = new Promise((W, J) => {
|
|
123
123
|
let F = !1;
|
|
124
124
|
O.then(
|
|
125
|
-
(
|
|
125
|
+
(V) => {
|
|
126
126
|
if (!F) {
|
|
127
127
|
F = !0;
|
|
128
128
|
const q = c(k), G = m(
|
|
@@ -130,10 +130,10 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
130
130
|
D,
|
|
131
131
|
T
|
|
132
132
|
);
|
|
133
|
-
resolvePromise(D,
|
|
133
|
+
resolvePromise(D, V), W(V), (q == null ? void 0 : q.d) !== G.d && R(k, G, q == null ? void 0 : q.d);
|
|
134
134
|
}
|
|
135
135
|
},
|
|
136
|
-
(
|
|
136
|
+
(V) => {
|
|
137
137
|
if (!F) {
|
|
138
138
|
F = !0;
|
|
139
139
|
const q = c(k), G = m(
|
|
@@ -141,40 +141,40 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
141
141
|
D,
|
|
142
142
|
T
|
|
143
143
|
);
|
|
144
|
-
rejectPromise(D,
|
|
144
|
+
rejectPromise(D, V), J(V), (q == null ? void 0 : q.d) !== G.d && R(k, G, q == null ? void 0 : q.d);
|
|
145
145
|
}
|
|
146
146
|
}
|
|
147
|
-
),
|
|
148
|
-
F || (F = !0,
|
|
147
|
+
), L = (V) => {
|
|
148
|
+
F || (F = !0, V.then(
|
|
149
149
|
(q) => resolvePromise(D, q),
|
|
150
150
|
(q) => rejectPromise(D, q)
|
|
151
|
-
), W(
|
|
151
|
+
), W(V));
|
|
152
152
|
};
|
|
153
153
|
});
|
|
154
154
|
return D.orig = O, D.status = "pending", registerCancelPromise(D, (W) => {
|
|
155
|
-
W &&
|
|
155
|
+
W && L(W), B == null || B();
|
|
156
156
|
}), m(k, D, T);
|
|
157
157
|
}
|
|
158
158
|
return m(k, O, T);
|
|
159
159
|
}, g = (k, O, T) => {
|
|
160
|
-
const
|
|
161
|
-
d: (
|
|
160
|
+
const B = c(k), L = {
|
|
161
|
+
d: (B == null ? void 0 : B.d) || /* @__PURE__ */ new Map(),
|
|
162
162
|
e: O
|
|
163
163
|
};
|
|
164
|
-
return T && d(k,
|
|
164
|
+
return T && d(k, L, T), B && isEqualAtomError(B, L) && B.d === L.d ? B : (u(k, L), L);
|
|
165
165
|
}, h = (k) => {
|
|
166
166
|
const O = c(k);
|
|
167
|
-
if (O && (O.d.forEach((F,
|
|
168
|
-
|
|
169
|
-
}), Array.from(O.d).every(([F,
|
|
167
|
+
if (O && (O.d.forEach((F, V) => {
|
|
168
|
+
V !== k && !n.has(V) && h(V);
|
|
169
|
+
}), Array.from(O.d).every(([F, V]) => {
|
|
170
170
|
const q = c(F);
|
|
171
|
-
return F === k || q ===
|
|
172
|
-
q && !hasPromiseAtomValue(q) && isEqualAtomValue(q,
|
|
171
|
+
return F === k || q === V || // TODO This is a hack, we should find a better solution.
|
|
172
|
+
q && !hasPromiseAtomValue(q) && isEqualAtomValue(q, V);
|
|
173
173
|
})))
|
|
174
174
|
return O;
|
|
175
175
|
const T = /* @__PURE__ */ new Map();
|
|
176
|
-
let
|
|
177
|
-
const
|
|
176
|
+
let B = !0;
|
|
177
|
+
const L = (F) => {
|
|
178
178
|
if (F === k) {
|
|
179
179
|
const q = c(F);
|
|
180
180
|
if (q)
|
|
@@ -183,8 +183,8 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
183
183
|
return T.set(F, void 0), F.init;
|
|
184
184
|
throw new Error("no atom init");
|
|
185
185
|
}
|
|
186
|
-
const
|
|
187
|
-
return T.set(F,
|
|
186
|
+
const V = h(F);
|
|
187
|
+
return T.set(F, V), returnAtomValue(V);
|
|
188
188
|
};
|
|
189
189
|
let D, W;
|
|
190
190
|
const J = {
|
|
@@ -193,13 +193,13 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
193
193
|
},
|
|
194
194
|
get setSelf() {
|
|
195
195
|
return (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && !isActuallyWritableAtom(k) && console.warn("setSelf function cannot be used with read-only atom"), !W && isActuallyWritableAtom(k) && (W = (...F) => {
|
|
196
|
-
if ((define_import_meta_env_default$2 ? "production" : void 0) !== "production" &&
|
|
196
|
+
if ((define_import_meta_env_default$2 ? "production" : void 0) !== "production" && B && console.warn("setSelf function cannot be called in sync"), !B)
|
|
197
197
|
return A(k, ...F);
|
|
198
198
|
}), W;
|
|
199
199
|
}
|
|
200
200
|
};
|
|
201
201
|
try {
|
|
202
|
-
const F = k.read(
|
|
202
|
+
const F = k.read(L, J);
|
|
203
203
|
return p(
|
|
204
204
|
k,
|
|
205
205
|
F,
|
|
@@ -209,32 +209,32 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
209
209
|
} catch (F) {
|
|
210
210
|
return g(k, F, T);
|
|
211
211
|
} finally {
|
|
212
|
-
|
|
212
|
+
B = !1;
|
|
213
213
|
}
|
|
214
214
|
}, b = (k) => returnAtomValue(h(k)), x = (k) => {
|
|
215
215
|
let O = n.get(k);
|
|
216
216
|
return O || (O = P(k)), O;
|
|
217
217
|
}, v = (k, O) => !O.l.size && (!O.t.size || O.t.size === 1 && O.t.has(k)), S = (k) => {
|
|
218
218
|
const O = n.get(k);
|
|
219
|
-
O && v(k, O) &&
|
|
219
|
+
O && v(k, O) && C(k);
|
|
220
220
|
}, E = (k) => {
|
|
221
|
-
const O = /* @__PURE__ */ new Map(), T = /* @__PURE__ */ new WeakMap(),
|
|
221
|
+
const O = /* @__PURE__ */ new Map(), T = /* @__PURE__ */ new WeakMap(), B = (D) => {
|
|
222
222
|
const W = n.get(D);
|
|
223
223
|
W == null || W.t.forEach((J) => {
|
|
224
224
|
J !== D && (O.set(
|
|
225
225
|
J,
|
|
226
226
|
(O.get(J) || /* @__PURE__ */ new Set()).add(D)
|
|
227
|
-
), T.set(J, (T.get(J) || 0) + 1),
|
|
227
|
+
), T.set(J, (T.get(J) || 0) + 1), B(J));
|
|
228
228
|
});
|
|
229
229
|
};
|
|
230
|
-
|
|
231
|
-
const
|
|
230
|
+
B(k);
|
|
231
|
+
const L = (D) => {
|
|
232
232
|
const W = n.get(D);
|
|
233
233
|
W == null || W.t.forEach((J) => {
|
|
234
234
|
var F;
|
|
235
235
|
if (J !== D) {
|
|
236
|
-
let
|
|
237
|
-
if (
|
|
236
|
+
let V = T.get(J);
|
|
237
|
+
if (V && T.set(J, --V), !V) {
|
|
238
238
|
let q = !!((F = O.get(J)) != null && F.size);
|
|
239
239
|
if (q) {
|
|
240
240
|
const G = c(J), ee = h(J);
|
|
@@ -242,85 +242,85 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
242
242
|
}
|
|
243
243
|
q || O.forEach((G) => G.delete(J));
|
|
244
244
|
}
|
|
245
|
-
|
|
245
|
+
L(J);
|
|
246
246
|
}
|
|
247
247
|
});
|
|
248
248
|
};
|
|
249
|
-
|
|
249
|
+
L(k);
|
|
250
250
|
}, w = (k, ...O) => {
|
|
251
251
|
let T = !0;
|
|
252
|
-
const
|
|
252
|
+
const B = (W) => returnAtomValue(h(W)), L = (W, ...J) => {
|
|
253
253
|
let F;
|
|
254
254
|
if (W === k) {
|
|
255
255
|
if (!hasInitialValue(W))
|
|
256
256
|
throw new Error("atom not writable");
|
|
257
|
-
const
|
|
258
|
-
(!
|
|
257
|
+
const V = c(W), q = p(W, J[0]);
|
|
258
|
+
(!V || !isEqualAtomValue(V, q)) && E(W);
|
|
259
259
|
} else
|
|
260
260
|
F = w(W, ...J);
|
|
261
261
|
if (!T) {
|
|
262
|
-
const
|
|
262
|
+
const V = I();
|
|
263
263
|
(define_import_meta_env_default$2 ? "production" : void 0) !== "production" && i.forEach(
|
|
264
|
-
(q) => q({ type: "async-write", flushed:
|
|
264
|
+
(q) => q({ type: "async-write", flushed: V })
|
|
265
265
|
);
|
|
266
266
|
}
|
|
267
267
|
return F;
|
|
268
|
-
}, D = k.write(
|
|
268
|
+
}, D = k.write(B, L, ...O);
|
|
269
269
|
return T = !1, D;
|
|
270
270
|
}, A = (k, ...O) => {
|
|
271
|
-
const T = w(k, ...O),
|
|
271
|
+
const T = w(k, ...O), B = I();
|
|
272
272
|
return (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && i.forEach(
|
|
273
|
-
(
|
|
273
|
+
(L) => L({ type: "write", flushed: B })
|
|
274
274
|
), T;
|
|
275
275
|
}, P = (k, O) => {
|
|
276
276
|
const T = {
|
|
277
277
|
t: new Set(O && [O]),
|
|
278
278
|
l: /* @__PURE__ */ new Set()
|
|
279
279
|
};
|
|
280
|
-
if (n.set(k, T), (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && l.add(k), h(k).d.forEach((
|
|
281
|
-
const D = n.get(
|
|
282
|
-
D ? D.t.add(k) :
|
|
280
|
+
if (n.set(k, T), (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && l.add(k), h(k).d.forEach((B, L) => {
|
|
281
|
+
const D = n.get(L);
|
|
282
|
+
D ? D.t.add(k) : L !== k && P(L, k);
|
|
283
283
|
}), h(k), isActuallyWritableAtom(k) && k.onMount) {
|
|
284
|
-
const
|
|
285
|
-
|
|
284
|
+
const B = k.onMount((...L) => A(k, ...L));
|
|
285
|
+
B && (T.u = B);
|
|
286
286
|
}
|
|
287
287
|
return T;
|
|
288
|
-
},
|
|
288
|
+
}, C = (k) => {
|
|
289
289
|
var O;
|
|
290
290
|
const T = (O = n.get(k)) == null ? void 0 : O.u;
|
|
291
291
|
T && T(), n.delete(k), (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && l.delete(k);
|
|
292
|
-
const
|
|
293
|
-
|
|
292
|
+
const B = c(k);
|
|
293
|
+
B ? (hasPromiseAtomValue(B) && cancelPromise(B.v), B.d.forEach((L, D) => {
|
|
294
294
|
if (D !== k) {
|
|
295
295
|
const W = n.get(D);
|
|
296
|
-
W && (W.t.delete(k), v(D, W) &&
|
|
296
|
+
W && (W.t.delete(k), v(D, W) && C(D));
|
|
297
297
|
}
|
|
298
298
|
})) : (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && console.warn("[Bug] could not find atom state to unmount", k);
|
|
299
|
-
},
|
|
300
|
-
const
|
|
301
|
-
T == null || T.forEach((
|
|
302
|
-
if (
|
|
303
|
-
|
|
299
|
+
}, R = (k, O, T) => {
|
|
300
|
+
const B = new Set(O.d.keys());
|
|
301
|
+
T == null || T.forEach((L, D) => {
|
|
302
|
+
if (B.has(D)) {
|
|
303
|
+
B.delete(D);
|
|
304
304
|
return;
|
|
305
305
|
}
|
|
306
306
|
const W = n.get(D);
|
|
307
|
-
W && (W.t.delete(k), v(D, W) &&
|
|
308
|
-
}),
|
|
309
|
-
const D = n.get(
|
|
310
|
-
D ? D.t.add(k) : n.has(k) && P(
|
|
307
|
+
W && (W.t.delete(k), v(D, W) && C(D));
|
|
308
|
+
}), B.forEach((L) => {
|
|
309
|
+
const D = n.get(L);
|
|
310
|
+
D ? D.t.add(k) : n.has(k) && P(L, k);
|
|
311
311
|
});
|
|
312
312
|
}, I = () => {
|
|
313
313
|
let k;
|
|
314
314
|
for ((define_import_meta_env_default$2 ? "production" : void 0) !== "production" && (k = /* @__PURE__ */ new Set()); o.size; ) {
|
|
315
315
|
const O = Array.from(o);
|
|
316
|
-
o.clear(), O.forEach(([T,
|
|
317
|
-
const
|
|
318
|
-
if (
|
|
319
|
-
|
|
316
|
+
o.clear(), O.forEach(([T, B]) => {
|
|
317
|
+
const L = c(T);
|
|
318
|
+
if (L) {
|
|
319
|
+
L.d !== (B == null ? void 0 : B.d) && R(T, L, B == null ? void 0 : B.d);
|
|
320
320
|
const D = n.get(T);
|
|
321
321
|
D && !// TODO This seems pretty hacky. Hope to fix it.
|
|
322
322
|
// Maybe we could `mountDependencies` in `setAtomState`?
|
|
323
|
-
(
|
|
323
|
+
(B && !hasPromiseAtomValue(B) && (isEqualAtomValue(B, L) || isEqualAtomError(B, L))) && (D.l.forEach((W) => W()), (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && k.add(T));
|
|
324
324
|
} else
|
|
325
325
|
(define_import_meta_env_default$2 ? "production" : void 0) !== "production" && console.warn("[Bug] no atom state to flush");
|
|
326
326
|
});
|
|
@@ -328,11 +328,11 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
328
328
|
if ((define_import_meta_env_default$2 ? "production" : void 0) !== "production")
|
|
329
329
|
return a.forEach((O) => O("state")), k;
|
|
330
330
|
}, j = (k, O) => {
|
|
331
|
-
const T = x(k),
|
|
332
|
-
return
|
|
333
|
-
(D) => D({ type: "sub", flushed:
|
|
331
|
+
const T = x(k), B = I(), L = T.l;
|
|
332
|
+
return L.add(O), (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && (a.forEach((D) => D("sub")), i.forEach(
|
|
333
|
+
(D) => D({ type: "sub", flushed: B })
|
|
334
334
|
)), () => {
|
|
335
|
-
|
|
335
|
+
L.delete(O), S(k), (define_import_meta_env_default$2 ? "production" : void 0) !== "production" && (a.forEach((D) => D("unsub")), i.forEach((D) => D({ type: "unsub" })));
|
|
336
336
|
};
|
|
337
337
|
};
|
|
338
338
|
return (define_import_meta_env_default$2 ? "production" : void 0) !== "production" ? {
|
|
@@ -351,8 +351,8 @@ const hasInitialValue = (r) => "init" in r, isActuallyWritableAtom = (r) => !!r.
|
|
|
351
351
|
dev_get_atom_state: (k) => r.get(k),
|
|
352
352
|
dev_get_mounted: (k) => n.get(k),
|
|
353
353
|
dev_restore_atoms: (k) => {
|
|
354
|
-
for (const [T,
|
|
355
|
-
hasInitialValue(T) && (p(T,
|
|
354
|
+
for (const [T, B] of k)
|
|
355
|
+
hasInitialValue(T) && (p(T, B), E(T));
|
|
356
356
|
const O = I();
|
|
357
357
|
i.forEach(
|
|
358
358
|
(T) => T({ type: "restore", flushed: O })
|
|
@@ -388,23 +388,23 @@ function splitAtom(r, n) {
|
|
|
388
388
|
return;
|
|
389
389
|
}
|
|
390
390
|
const S = (w) => {
|
|
391
|
-
const A = w(i), P = w(r),
|
|
392
|
-
if (
|
|
391
|
+
const A = w(i), P = w(r), R = a(P, A == null ? void 0 : A.arr).keyList.indexOf(x);
|
|
392
|
+
if (R < 0 || R >= P.length) {
|
|
393
393
|
const I = c[a(c).keyList.indexOf(x)];
|
|
394
394
|
if (I)
|
|
395
395
|
return I;
|
|
396
396
|
throw new Error("splitAtom: index out of bounds for read");
|
|
397
397
|
}
|
|
398
|
-
return P[
|
|
398
|
+
return P[R];
|
|
399
399
|
}, E = (w, A, P) => {
|
|
400
|
-
const
|
|
401
|
-
if (j < 0 || j >=
|
|
400
|
+
const C = w(i), R = w(r), j = a(R, C == null ? void 0 : C.arr).keyList.indexOf(x);
|
|
401
|
+
if (j < 0 || j >= R.length)
|
|
402
402
|
throw new Error("splitAtom: index out of bounds for write");
|
|
403
|
-
const k = isFunction$1(P) ? P(
|
|
403
|
+
const k = isFunction$1(P) ? P(R[j]) : P;
|
|
404
404
|
A(r, [
|
|
405
|
-
...
|
|
405
|
+
...R.slice(0, j),
|
|
406
406
|
k,
|
|
407
|
-
...
|
|
407
|
+
...R.slice(j + 1)
|
|
408
408
|
]);
|
|
409
409
|
};
|
|
410
410
|
p[b] = isWritable(r) ? atom(S, E) : atom(S);
|
|
@@ -1217,12 +1217,12 @@ const useBlocksStoreManager = () => {
|
|
|
1217
1217
|
return {
|
|
1218
1218
|
moveBlocks: (x, v, S) => {
|
|
1219
1219
|
const E = map(x, (A) => {
|
|
1220
|
-
const
|
|
1221
|
-
return { _id: A, oldParent:
|
|
1220
|
+
const C = n.find((j) => j._id === A)._parent || null, I = n.filter((j) => C ? j._parent === C : !j._parent).map((j) => j._id).indexOf(A);
|
|
1221
|
+
return { _id: A, oldParent: C, oldPosition: I };
|
|
1222
1222
|
}), w = E.find(({ _id: A }) => A === x[0]);
|
|
1223
1223
|
w && w.oldParent === v && w.oldPosition === S || (l(x, v, S), r({
|
|
1224
|
-
undo: () => each(E, ({ _id: A, oldParent: P, oldPosition:
|
|
1225
|
-
l([A], P,
|
|
1224
|
+
undo: () => each(E, ({ _id: A, oldParent: P, oldPosition: C }) => {
|
|
1225
|
+
l([A], P, C);
|
|
1226
1226
|
}),
|
|
1227
1227
|
redo: () => l(x, v, S)
|
|
1228
1228
|
}));
|
|
@@ -1248,8 +1248,8 @@ const useBlocksStoreManager = () => {
|
|
|
1248
1248
|
else {
|
|
1249
1249
|
const w = keys(v);
|
|
1250
1250
|
E = map(x, (A) => {
|
|
1251
|
-
const P = n.find((
|
|
1252
|
-
return each(w, (
|
|
1251
|
+
const P = n.find((R) => R._id === A), C = { _id: A };
|
|
1252
|
+
return each(w, (R) => C[R] = P[R]), C;
|
|
1253
1253
|
});
|
|
1254
1254
|
}
|
|
1255
1255
|
c(map(x, (w) => ({ _id: w, ...v }))), r({
|
|
@@ -3171,8 +3171,10 @@ const useHandleCanvasDblClick = () => {
|
|
|
3171
3171
|
}, KeyboardHandler = () => {
|
|
3172
3172
|
const { document: r } = useFrame();
|
|
3173
3173
|
return useKeyEventWatcher(r), null;
|
|
3174
|
-
},
|
|
3175
|
-
|
|
3174
|
+
}, { useChaiBuilderMsgListener, emitChaiBuilderMsg } = createEvent("chaiBuilderMsg")(), CHAI_BUILDER_EVENTS = {
|
|
3175
|
+
OPEN_ADD_BLOCK: "OPEN_ADD_BLOCK",
|
|
3176
|
+
CLOSE_ADD_BLOCK: "CLOSE_ADD_BLOCK",
|
|
3177
|
+
SHOW_BLOCK_SETTINGS: "SHOW_BLOCK_SETTINGS"
|
|
3176
3178
|
}, BlockActionLabel = ({ block: r, label: n }) => {
|
|
3177
3179
|
const [, o] = useSelectedBlockIds(), [, a] = useHighlightBlockId(), [, i] = useAtom$1(draggedBlockAtom), l = useFeature("dnd");
|
|
3178
3180
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
@@ -3192,49 +3194,55 @@ const useHandleCanvasDblClick = () => {
|
|
|
3192
3194
|
}
|
|
3193
3195
|
);
|
|
3194
3196
|
}, BlockActionsStatic = ({ selectedBlockElement: r, block: n }) => {
|
|
3195
|
-
const o = useRemoveBlocks(), a = useDuplicateBlocks(), [, i] = useSelectedBlockIds(), [, l] = useHighlightBlockId(), [, c] =
|
|
3197
|
+
const o = useRemoveBlocks(), a = useDuplicateBlocks(), [, i] = useSelectedBlockIds(), [, l] = useHighlightBlockId(), [, c] = useSelectedStylingBlocks(), [u] = useAtom$1(inlineEditingActiveAtom), { floatingStyles: d, refs: m, update: p } = useFloating$1({
|
|
3196
3198
|
placement: "top-start",
|
|
3197
3199
|
middleware: [shift(), flip$2()],
|
|
3198
3200
|
elements: {
|
|
3199
3201
|
reference: r
|
|
3200
3202
|
}
|
|
3201
3203
|
});
|
|
3202
|
-
useResizeObserver(r, () =>
|
|
3203
|
-
const
|
|
3204
|
-
return !r || !n ||
|
|
3204
|
+
useResizeObserver(r, () => p(), r !== null);
|
|
3205
|
+
const g = get$1(n, "_parent", null), h = isEmpty(get$1(n, "_name", "")) ? get$1(n, "_type", "") : get$1(n, "_name", "");
|
|
3206
|
+
return !r || !n || u ? null : /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
3205
3207
|
"div",
|
|
3206
3208
|
{
|
|
3207
3209
|
role: "button",
|
|
3208
3210
|
tabIndex: 0,
|
|
3209
|
-
ref:
|
|
3210
|
-
style:
|
|
3211
|
-
onClick: (
|
|
3212
|
-
|
|
3211
|
+
ref: m.setFloating,
|
|
3212
|
+
style: d,
|
|
3213
|
+
onClick: (b) => {
|
|
3214
|
+
b.stopPropagation(), b.preventDefault();
|
|
3213
3215
|
},
|
|
3214
|
-
onMouseEnter: (
|
|
3215
|
-
|
|
3216
|
+
onMouseEnter: (b) => {
|
|
3217
|
+
b.stopPropagation(), l(null);
|
|
3216
3218
|
},
|
|
3217
|
-
onKeyDown: (
|
|
3219
|
+
onKeyDown: (b) => b.stopPropagation(),
|
|
3218
3220
|
className: "isolate z-10 flex h-6 items-center bg-blue-500 py-2 text-xs text-white",
|
|
3219
3221
|
children: [
|
|
3220
|
-
|
|
3222
|
+
g && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
3221
3223
|
ArrowUpIcon,
|
|
3222
3224
|
{
|
|
3223
3225
|
className: "hover:scale-105",
|
|
3224
3226
|
onClick: () => {
|
|
3225
|
-
|
|
3227
|
+
c([]), i([g]);
|
|
3226
3228
|
}
|
|
3227
3229
|
}
|
|
3228
3230
|
),
|
|
3229
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(BlockActionLabel, { label:
|
|
3231
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(BlockActionLabel, { label: h, block: n }),
|
|
3230
3232
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex gap-2 px-1", children: [
|
|
3231
|
-
canAddChildBlock(get$1(n, "_type", "")) && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
3233
|
+
canAddChildBlock(get$1(n, "_type", "")) && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
3234
|
+
PlusIcon,
|
|
3235
|
+
{
|
|
3236
|
+
className: "hover:scale-105",
|
|
3237
|
+
onClick: () => emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK, data: n })
|
|
3238
|
+
}
|
|
3239
|
+
),
|
|
3232
3240
|
canDuplicateBlock(get$1(n, "_type", "")) ? /* @__PURE__ */ jsxRuntimeExports.jsx(CopyIcon$1, { className: "hover:scale-105", onClick: () => a([n == null ? void 0 : n._id]) }) : null,
|
|
3233
3241
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
3234
3242
|
GearIcon,
|
|
3235
3243
|
{
|
|
3236
3244
|
className: "text-white hover:scale-105",
|
|
3237
|
-
onClick: () => emitChaiBuilderMsg({ name:
|
|
3245
|
+
onClick: () => emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.SHOW_BLOCK_SETTINGS, data: n })
|
|
3238
3246
|
}
|
|
3239
3247
|
),
|
|
3240
3248
|
canDeleteBlock(get$1(n, "_type", "")) ? /* @__PURE__ */ jsxRuntimeExports.jsx(TrashIcon, { className: "hover:scale-105", onClick: () => o([n == null ? void 0 : n._id]) }) : null
|
|
@@ -3255,14 +3263,14 @@ const useHandleCanvasDblClick = () => {
|
|
|
3255
3263
|
}, [a, d]);
|
|
3256
3264
|
const x = get$1(n, "headingFont", "DM Sans"), v = get$1(n, "bodyFont", "DM Sans");
|
|
3257
3265
|
return useEffect$1(() => {
|
|
3258
|
-
const S = get$1(n, "primaryColor", "#000"), E = get$1(n, "secondaryColor", "#FFF"), w = get$1(n, "bodyBgLightColor", "#fff"), A = get$1(n, "bodyBgDarkColor", "#000"), P = get$1(n, "bodyTextDarkColor", "#000"),
|
|
3266
|
+
const S = get$1(n, "primaryColor", "#000"), E = get$1(n, "secondaryColor", "#FFF"), w = get$1(n, "bodyBgLightColor", "#fff"), A = get$1(n, "bodyBgDarkColor", "#000"), P = get$1(n, "bodyTextDarkColor", "#000"), C = get$1(n, "bodyTextLightColor", "#fff"), R = getPalette([
|
|
3259
3267
|
{ color: S, name: "primary" },
|
|
3260
3268
|
{ color: E, name: "secondary" }
|
|
3261
3269
|
]), I = {
|
|
3262
3270
|
"bg-light": w,
|
|
3263
3271
|
"bg-dark": A,
|
|
3264
3272
|
"text-dark": P,
|
|
3265
|
-
"text-light":
|
|
3273
|
+
"text-light": C
|
|
3266
3274
|
}, j = get$1(n, "roundedCorners", "0");
|
|
3267
3275
|
!m || !m.tailwind || (m.tailwind.config = {
|
|
3268
3276
|
darkMode: "class",
|
|
@@ -3282,7 +3290,7 @@ const useHandleCanvasDblClick = () => {
|
|
|
3282
3290
|
borderRadius: {
|
|
3283
3291
|
DEFAULT: `${j || "0"}px`
|
|
3284
3292
|
},
|
|
3285
|
-
colors: { ...I, ...
|
|
3293
|
+
colors: { ...I, ...R }
|
|
3286
3294
|
}
|
|
3287
3295
|
},
|
|
3288
3296
|
plugins: [
|
|
@@ -3410,10 +3418,10 @@ function BlocksRendererStatic({ blocks: r }) {
|
|
|
3410
3418
|
const E = getBlockComponent(h._type), w = get$1(E, "builderComponent", get$1(E, "component", null));
|
|
3411
3419
|
if (isNull(w))
|
|
3412
3420
|
return /* @__PURE__ */ jsxRuntimeExports.jsx("noscript", { children: `<!-- ${h == null ? void 0 : h._type} not registered -->` });
|
|
3413
|
-
const A = has(E, "getBlockStateFrom") ? E == null ? void 0 : E.getBlockStateFrom(h, n) : [], P = g(A),
|
|
3414
|
-
if (get$1(
|
|
3421
|
+
const A = has(E, "getBlockStateFrom") ? E == null ? void 0 : E.getBlockStateFrom(h, n) : [], P = g(A), C = d(h);
|
|
3422
|
+
if (get$1(C, "__isHidden", !1) && !includes(o, h._id))
|
|
3415
3423
|
return null;
|
|
3416
|
-
const
|
|
3424
|
+
const R = i && isDescendant(i._id, h._id, n);
|
|
3417
3425
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(Suspense, { children: React__default.createElement(w, {
|
|
3418
3426
|
blockProps: {
|
|
3419
3427
|
...includes(o, h._id) ? { "force-show": "" } : {},
|
|
@@ -3423,15 +3431,15 @@ function BlocksRendererStatic({ blocks: r }) {
|
|
|
3423
3431
|
// @ts-ignore
|
|
3424
3432
|
{
|
|
3425
3433
|
"data-dnd": canAcceptChildBlock(h._type, i == null ? void 0 : i._type) ? "yes" : "no",
|
|
3426
|
-
"data-dnd-dragged": i._id === h._id ||
|
|
3434
|
+
"data-dnd-dragged": i._id === h._id || R ? "yes" : "no"
|
|
3427
3435
|
}
|
|
3428
3436
|
) : {},
|
|
3429
|
-
...l === h._id && !
|
|
3437
|
+
...l === h._id && !R ? { "data-drop": "yes" } : {},
|
|
3430
3438
|
...includes(a, h._id) ? { "data-cut-block": "yes" } : {}
|
|
3431
3439
|
},
|
|
3432
3440
|
index: b,
|
|
3433
3441
|
...applyBindings(h, m),
|
|
3434
|
-
...omit(
|
|
3442
|
+
...omit(C, ["__isHidden"]),
|
|
3435
3443
|
...v,
|
|
3436
3444
|
inBuilder: !0,
|
|
3437
3445
|
blockState: P
|
|
@@ -3458,15 +3466,15 @@ const useAllDataProviders = () => useMemo$1(() => getChaiDataProviders(), []), B
|
|
|
3458
3466
|
const [r] = useBlocksStore(), n = isEmpty(r) ? null : /* @__PURE__ */ jsxRuntimeExports.jsx(BlocksExternalDataProvider, { children: /* @__PURE__ */ jsxRuntimeExports.jsx(BlocksRendererStatic, { blocks: filter(r, (o) => isEmpty(o._parent)) }) });
|
|
3459
3467
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: n });
|
|
3460
3468
|
}, AddBlockAtBottom = () => {
|
|
3461
|
-
const
|
|
3469
|
+
const { t: r } = useTranslation();
|
|
3462
3470
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
3463
3471
|
"button",
|
|
3464
3472
|
{
|
|
3465
|
-
onClick: () =>
|
|
3473
|
+
onClick: () => emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK }),
|
|
3466
3474
|
className: "mt-1 block w-full rounded-md bg-gray-100 p-2 text-black hover:bg-gray-200 dark:bg-gray-700 dark:text-white dark:hover:bg-gray-700",
|
|
3467
3475
|
children: [
|
|
3468
3476
|
"+ ",
|
|
3469
|
-
|
|
3477
|
+
r("add_block")
|
|
3470
3478
|
]
|
|
3471
3479
|
}
|
|
3472
3480
|
);
|
|
@@ -3484,41 +3492,41 @@ const useAllDataProviders = () => useMemo$1(() => getChaiDataProviders(), []), B
|
|
|
3484
3492
|
n(l);
|
|
3485
3493
|
}, []), /* @__PURE__ */ jsxRuntimeExports.jsx("div", { id: "main-content", className: "h-full w-full", ref: a, children: r });
|
|
3486
3494
|
}, getElementByStyleId = (r, n) => r.querySelector(`[data-style-id="${n}"]`), StaticCanvas = () => {
|
|
3487
|
-
const [r] = useAtom$1(networkModeAtom), [n] = useCanvasWidth(), [, o] = useSelectedBlockIds(), a = useSelectedBlock(), [, i] = useHighlightBlockId(), l = useRef$1(null), c = useRef$1(null), [u, d] = useState$1({ width: 0, height: 0 }), m = useCanvasScale(u), [p, g] = useState$1([]), [, h] = useState$1([]), [, b] = useAtom$1(canvasIframeAtom), [x, v] = useSelectedStylingBlocks(), S = useBuilderProp("loading", !1), E = useBuilderProp("htmlDir", "ltr"), w = (
|
|
3488
|
-
d((
|
|
3495
|
+
const [r] = useAtom$1(networkModeAtom), [n] = useCanvasWidth(), [, o] = useSelectedBlockIds(), a = useSelectedBlock(), [, i] = useHighlightBlockId(), l = useRef$1(null), c = useRef$1(null), [u, d] = useState$1({ width: 0, height: 0 }), m = useCanvasScale(u), [p, g] = useState$1([]), [, h] = useState$1([]), [, b] = useAtom$1(canvasIframeAtom), [x, v] = useSelectedStylingBlocks(), S = useBuilderProp("loading", !1), E = useBuilderProp("htmlDir", "ltr"), w = (C) => {
|
|
3496
|
+
d((R) => ({ ...R, width: C }));
|
|
3489
3497
|
};
|
|
3490
3498
|
useEffect$1(() => {
|
|
3491
3499
|
if (!c.current)
|
|
3492
3500
|
return;
|
|
3493
|
-
const { clientWidth:
|
|
3494
|
-
d({ width:
|
|
3501
|
+
const { clientWidth: C, clientHeight: R } = c.current;
|
|
3502
|
+
d({ width: C, height: R });
|
|
3495
3503
|
}, [c, n]);
|
|
3496
|
-
const A = (
|
|
3497
|
-
const { top: I } =
|
|
3498
|
-
return I +
|
|
3504
|
+
const A = (C, R = 0) => {
|
|
3505
|
+
const { top: I } = C.getBoundingClientRect();
|
|
3506
|
+
return I + R >= 0 && I - R <= window.innerHeight;
|
|
3499
3507
|
};
|
|
3500
3508
|
useEffect$1(() => {
|
|
3501
|
-
var
|
|
3509
|
+
var C, R;
|
|
3502
3510
|
if (a && a.type !== "Multiple" && l.current) {
|
|
3503
3511
|
const I = getElementByDataBlockId(l.current.contentDocument, a._id);
|
|
3504
|
-
I && (A(I) || (
|
|
3512
|
+
I && (A(I) || (R = (C = l.current) == null ? void 0 : C.contentWindow) == null || R.scrollTo({ top: I.offsetTop, behavior: "smooth" }), g([I]));
|
|
3505
3513
|
}
|
|
3506
3514
|
}, [a]), useEffect$1(() => {
|
|
3507
3515
|
if (!isEmpty(x) && l.current) {
|
|
3508
|
-
const
|
|
3516
|
+
const C = getElementByStyleId(
|
|
3509
3517
|
l.current.contentDocument,
|
|
3510
3518
|
first(x).id
|
|
3511
3519
|
);
|
|
3512
|
-
h(
|
|
3520
|
+
h(C ? [C] : [null]);
|
|
3513
3521
|
} else
|
|
3514
3522
|
h([null]);
|
|
3515
3523
|
}, [x]);
|
|
3516
3524
|
const P = useMemo$1(() => {
|
|
3517
|
-
let
|
|
3518
|
-
return
|
|
3525
|
+
let C = IframeInitialContent;
|
|
3526
|
+
return C = C.replace("__HTML_DIR__", E), r === "offline" && (C = C.replace(
|
|
3519
3527
|
"https://old.chaibuilder.com/offline/tailwind.cdn.js",
|
|
3520
3528
|
"/offline/tailwind.cdn.js"
|
|
3521
|
-
),
|
|
3529
|
+
), C = C.replace("https://unpkg.com/aos@next/dist/aos.css", "/offline/aos.css"), C = C.replace("https://unpkg.com/aos@next/dist/aos.js", "/offline/aos.js")), C;
|
|
3522
3530
|
}, [r]);
|
|
3523
3531
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(ResizableCanvasWrapper, { onMount: w, onResize: w, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
3524
3532
|
"div",
|
|
@@ -3570,7 +3578,7 @@ const useAllDataProviders = () => useMemo$1(() => getChaiDataProviders(), []), B
|
|
|
3570
3578
|
}, StaticCanvas$1 = StaticCanvas, FallbackError = () => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "h-full w-full rounded-md bg-red-200 p-4 text-red-500", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex h-full w-full flex-col items-center justify-center", children: [
|
|
3571
3579
|
/* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "font-semibold", children: "Oops! Something went wrong." }),
|
|
3572
3580
|
/* @__PURE__ */ jsxRuntimeExports.jsx("p", { children: "Please try again." })
|
|
3573
|
-
] }) }), CodeEditor$1 = React__default.lazy(() => import("./CodeEditor-
|
|
3581
|
+
] }) }), CodeEditor$1 = React__default.lazy(() => import("./CodeEditor-GsTOzMVg.js")), CanvasArea = () => {
|
|
3574
3582
|
const [r] = useCodeEditor(), n = useBuilderProp("onError", noop$1);
|
|
3575
3583
|
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex h-full w-full flex-col", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "relative flex h-full flex-col overflow-hidden bg-gray-100/40 px-2", children: [
|
|
3576
3584
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Suspense, { fallback: /* @__PURE__ */ jsxRuntimeExports.jsx(Skeleton, { className: "h-full" }), children: /* @__PURE__ */ jsxRuntimeExports.jsx(ErrorBoundary$1, { fallback: /* @__PURE__ */ jsxRuntimeExports.jsx(FallbackError, {}), onError: n, children: /* @__PURE__ */ jsxRuntimeExports.jsx(StaticCanvas$1, {}) }) }),
|
|
@@ -3648,8 +3656,8 @@ const useAllDataProviders = () => useMemo$1(() => getChaiDataProviders(), []), B
|
|
|
3648
3656
|
React.useEffect(() => () => {
|
|
3649
3657
|
isEqual(a, c.current) || o(c.current);
|
|
3650
3658
|
}, []);
|
|
3651
|
-
const d = ({ formData:
|
|
3652
|
-
|
|
3659
|
+
const d = ({ formData: C }, R) => {
|
|
3660
|
+
R && (i(C), c.current = C);
|
|
3653
3661
|
}, {
|
|
3654
3662
|
bodyFont: m,
|
|
3655
3663
|
headingFont: p,
|
|
@@ -3702,9 +3710,9 @@ const useAllDataProviders = () => useMemo$1(() => getChaiDataProviders(), []), B
|
|
|
3702
3710
|
type: "object",
|
|
3703
3711
|
properties: {}
|
|
3704
3712
|
}, P = {};
|
|
3705
|
-
return Object.keys(w).forEach((
|
|
3706
|
-
const
|
|
3707
|
-
return A.properties || (A.properties = {}), A.properties[
|
|
3713
|
+
return Object.keys(w).forEach((C) => {
|
|
3714
|
+
const R = w[C];
|
|
3715
|
+
return A.properties || (A.properties = {}), A.properties[C] = R.schema, P[C] = R.uiSchema, !0;
|
|
3708
3716
|
}), /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("flex h-full w-full select-none flex-col", n), children: [
|
|
3709
3717
|
r ? /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "rounded-md bg-background/30 p-1", children: /* @__PURE__ */ jsxRuntimeExports.jsx("h1", { className: "px-1 font-semibold", children: u("Theme Configuration") }) }) : null,
|
|
3710
3718
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -3872,7 +3880,7 @@ const useAllDataProviders = () => useMemo$1(() => getChaiDataProviders(), []), B
|
|
|
3872
3880
|
}
|
|
3873
3881
|
);
|
|
3874
3882
|
}, BlockContextMenuContent = () => {
|
|
3875
|
-
const { t: r } = useTranslation(), [n] = useSelectedBlockIds(), o = useDuplicateBlocks(), a = useSelectedBlock(),
|
|
3883
|
+
const { t: r } = useTranslation(), [n] = useSelectedBlockIds(), o = useDuplicateBlocks(), a = useSelectedBlock(), i = useCallback$1(() => {
|
|
3876
3884
|
o(n);
|
|
3877
3885
|
}, [n, o]);
|
|
3878
3886
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(ContextMenuContent, { className: "text-xs", children: [
|
|
@@ -3881,7 +3889,7 @@ const useAllDataProviders = () => useMemo$1(() => getChaiDataProviders(), []), B
|
|
|
3881
3889
|
{
|
|
3882
3890
|
disabled: !canAddChildBlock(a == null ? void 0 : a._type),
|
|
3883
3891
|
className: "flex items-center gap-x-4 text-xs",
|
|
3884
|
-
onClick: () =>
|
|
3892
|
+
onClick: () => emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK, data: a }),
|
|
3885
3893
|
children: [
|
|
3886
3894
|
/* @__PURE__ */ jsxRuntimeExports.jsx(PlusIcon$1, { size: "14" }),
|
|
3887
3895
|
" ",
|
|
@@ -3894,7 +3902,7 @@ const useAllDataProviders = () => useMemo$1(() => getChaiDataProviders(), []), B
|
|
|
3894
3902
|
{
|
|
3895
3903
|
disabled: !canDuplicateBlock(a == null ? void 0 : a._type),
|
|
3896
3904
|
className: "flex items-center gap-x-4 text-xs",
|
|
3897
|
-
onClick:
|
|
3905
|
+
onClick: i,
|
|
3898
3906
|
children: [
|
|
3899
3907
|
/* @__PURE__ */ jsxRuntimeExports.jsx(CardStackPlusIcon, {}),
|
|
3900
3908
|
" ",
|
|
@@ -3953,34 +3961,34 @@ function BsLightningFill(r) {
|
|
|
3953
3961
|
function TbEyeDown(r) {
|
|
3954
3962
|
return GenIcon({ tag: "svg", attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { d: "M10 12a2 2 0 1 0 4 0a2 2 0 0 0 -4 0" }, child: [] }, { tag: "path", attr: { d: "M12 18c-3.6 0 -6.6 -2 -9 -6c2.4 -4 5.4 -6 9 -6c3.6 0 6.6 2 9 6" }, child: [] }, { tag: "path", attr: { d: "M19 16v6" }, child: [] }, { tag: "path", attr: { d: "M22 19l-3 3l-3 -3" }, child: [] }] })(r);
|
|
3955
3963
|
}
|
|
3956
|
-
const Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
3964
|
+
const useAddBlocksModal = () => useAtom(addBlockModalOpenAtom), Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
3957
3965
|
const a = useBuilderProp("outlineMenuItems", []), [, i] = useAddBlocksModal(), { t: l } = useTranslation(), [c] = useAtom$1(canvasIframeAtom);
|
|
3958
3966
|
let u = null;
|
|
3959
|
-
const d = r.children.length > 0, { id: m, data: p, isSelected: g, willReceiveDrop: h, isDragging: b, isEditing: x, handleClick: v } = r, S = (
|
|
3960
|
-
|
|
3961
|
-
}, E = (
|
|
3962
|
-
|
|
3963
|
-
}, w = (
|
|
3964
|
-
|
|
3965
|
-
}, A = (
|
|
3966
|
-
|
|
3967
|
+
const d = r.children.length > 0, { id: m, data: p, isSelected: g, willReceiveDrop: h, isDragging: b, isEditing: x, handleClick: v } = r, S = (R) => {
|
|
3968
|
+
R.stopPropagation(), r.toggle();
|
|
3969
|
+
}, E = (R) => {
|
|
3970
|
+
R.isInternal && (u = R.isOpen, R.isOpen && R.close());
|
|
3971
|
+
}, w = (R) => {
|
|
3972
|
+
R.isInternal && u !== null && (u ? R.open() : R.close(), u = null);
|
|
3973
|
+
}, A = (R) => {
|
|
3974
|
+
R.stopPropagation(), r.isOpen || r.toggle(), v(R);
|
|
3967
3975
|
};
|
|
3968
3976
|
useEffect$1(() => {
|
|
3969
|
-
const
|
|
3977
|
+
const R = setTimeout(() => {
|
|
3970
3978
|
h && !r.isOpen && !b && r.toggle();
|
|
3971
3979
|
}, 500);
|
|
3972
|
-
return () => clearTimeout(
|
|
3980
|
+
return () => clearTimeout(R);
|
|
3973
3981
|
}, [h, r, b]);
|
|
3974
3982
|
const P = useMemo$1(() => {
|
|
3975
|
-
const
|
|
3976
|
-
for (let j = 0; j <
|
|
3977
|
-
if (
|
|
3978
|
-
const k = p[
|
|
3983
|
+
const R = Object.keys(p), I = [];
|
|
3984
|
+
for (let j = 0; j < R.length; j++)
|
|
3985
|
+
if (R[j].endsWith("_attrs")) {
|
|
3986
|
+
const k = p[R[j]], O = Object.keys(k).join("|");
|
|
3979
3987
|
O.match(/x-data/) && I.push("data"), O.match(/x-on/) && I.push("event"), O.match(/x-show|x-if/) && I.push("show");
|
|
3980
3988
|
}
|
|
3981
3989
|
return I;
|
|
3982
|
-
}, [p]),
|
|
3983
|
-
const j = c.contentDocument || c.contentWindow.document, k = j.querySelector(`[data-block-id=${
|
|
3990
|
+
}, [p]), C = (R, I) => {
|
|
3991
|
+
const j = c.contentDocument || c.contentWindow.document, k = j.querySelector(`[data-block-id=${R}]`);
|
|
3984
3992
|
k && k.setAttribute("data-drop", I);
|
|
3985
3993
|
const O = k.getBoundingClientRect(), T = c.getBoundingClientRect();
|
|
3986
3994
|
O.top >= T.top && O.left >= T.left && O.bottom <= T.bottom && O.right <= T.right || (j.documentElement.scrollTop = k.offsetTop - T.top);
|
|
@@ -3988,7 +3996,7 @@ const Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
|
3988
3996
|
return m === ROOT_TEMP_KEY ? /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
3989
3997
|
"button",
|
|
3990
3998
|
{
|
|
3991
|
-
onClick: () =>
|
|
3999
|
+
onClick: () => emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK }),
|
|
3992
4000
|
className: "mb-10 mt-5 w-full rounded bg-gray-100 p-1 hover:bg-gray-200",
|
|
3993
4001
|
children: [
|
|
3994
4002
|
"+ ",
|
|
@@ -4004,14 +4012,14 @@ const Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
|
4004
4012
|
ref: o,
|
|
4005
4013
|
onDragStart: () => E(r),
|
|
4006
4014
|
onDragEnd: () => w(r),
|
|
4007
|
-
onDragOver: (
|
|
4008
|
-
|
|
4015
|
+
onDragOver: (R) => {
|
|
4016
|
+
R.preventDefault(), C(m, "yes");
|
|
4009
4017
|
},
|
|
4010
|
-
onDragLeave: (
|
|
4011
|
-
|
|
4018
|
+
onDragLeave: (R) => {
|
|
4019
|
+
R.preventDefault(), C(m, "no");
|
|
4012
4020
|
},
|
|
4013
|
-
onDrop: (
|
|
4014
|
-
|
|
4021
|
+
onDrop: (R) => {
|
|
4022
|
+
R.preventDefault(), C(m, "no");
|
|
4015
4023
|
},
|
|
4016
4024
|
className: cn(
|
|
4017
4025
|
"group flex !h-full w-full items-center justify-between space-x-px !rounded py-px outline-none",
|
|
@@ -4034,8 +4042,8 @@ const Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
|
4034
4042
|
"div",
|
|
4035
4043
|
{
|
|
4036
4044
|
className: "ml-2 flex items-center gap-x-1 truncate text-[11px]",
|
|
4037
|
-
onDoubleClick: (
|
|
4038
|
-
|
|
4045
|
+
onDoubleClick: (R) => {
|
|
4046
|
+
R.stopPropagation(), r.edit(), r.deselect();
|
|
4039
4047
|
},
|
|
4040
4048
|
children: [
|
|
4041
4049
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: (p == null ? void 0 : p._name) || (p == null ? void 0 : p._type.split("/").pop()) }),
|
|
@@ -4060,16 +4068,16 @@ const Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
|
4060
4068
|
),
|
|
4061
4069
|
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContent, { className: "isolate z-[9999]", children: l("Add block") })
|
|
4062
4070
|
] }) : null,
|
|
4063
|
-
a.map((
|
|
4071
|
+
a.map((R) => /* @__PURE__ */ jsxRuntimeExports.jsxs(Tooltip$1, { children: [
|
|
4064
4072
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
4065
4073
|
TooltipTrigger,
|
|
4066
4074
|
{
|
|
4067
4075
|
className: "cursor-pointer rounded bg-transparent hover:bg-white hover:text-blue-500",
|
|
4068
4076
|
asChild: !0,
|
|
4069
|
-
children: React__default.createElement(
|
|
4077
|
+
children: React__default.createElement(R.item, { blockId: m })
|
|
4070
4078
|
}
|
|
4071
4079
|
),
|
|
4072
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContent, { className: "isolate z-10", children:
|
|
4080
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContent, { className: "isolate z-10", children: R.tooltip })
|
|
4073
4081
|
] }))
|
|
4074
4082
|
] })
|
|
4075
4083
|
]
|
|
@@ -4102,7 +4110,7 @@ const Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
|
4102
4110
|
return canAcceptChildBlock(a, i);
|
|
4103
4111
|
};
|
|
4104
4112
|
}, ListTree = () => {
|
|
4105
|
-
const [treeData] = useAtom$1(treeDSBlocks), [ids, setIds] = useSelectedBlockIds(), [cutBlocksIds] = useCutBlockIds(), updateBlockProps = useUpdateBlocksProps(), [, setStyleBlocks] = useSelectedStylingBlocks(), { moveBlocks } = useBlocksStoreUndoableActions(), canMove = useCanMove(), treeRef = useRef$1(null), [, setTreeRef] = useAtom$1(treeRefAtom), { t } = useTranslation(),
|
|
4113
|
+
const [treeData] = useAtom$1(treeDSBlocks), [ids, setIds] = useSelectedBlockIds(), [cutBlocksIds] = useCutBlockIds(), updateBlockProps = useUpdateBlocksProps(), [, setStyleBlocks] = useSelectedStylingBlocks(), { moveBlocks } = useBlocksStoreUndoableActions(), canMove = useCanMove(), treeRef = useRef$1(null), [, setTreeRef] = useAtom$1(treeRefAtom), { t } = useTranslation(), clearSelection = () => {
|
|
4106
4114
|
setIds([]), setStyleBlocks([]);
|
|
4107
4115
|
}, filteredTreeData = useMemo$1(() => {
|
|
4108
4116
|
const r = (o, a) => o.filter((i) => !a.includes(i._id)).map((i) => ({
|
|
@@ -4172,7 +4180,18 @@ const Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
|
4172
4180
|
t("page_is_empty"),
|
|
4173
4181
|
/* @__PURE__ */ jsxRuntimeExports.jsx("br", {}),
|
|
4174
4182
|
/* @__PURE__ */ jsxRuntimeExports.jsx("br", {}),
|
|
4175
|
-
/* @__PURE__ */ jsxRuntimeExports.
|
|
4183
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
4184
|
+
Button$1,
|
|
4185
|
+
{
|
|
4186
|
+
onClick: () => emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK }),
|
|
4187
|
+
variant: "default",
|
|
4188
|
+
size: "sm",
|
|
4189
|
+
children: [
|
|
4190
|
+
"+ ",
|
|
4191
|
+
t("add_block")
|
|
4192
|
+
]
|
|
4193
|
+
}
|
|
4194
|
+
)
|
|
4176
4195
|
] }) }) }) : /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: cn("flex h-full select-none flex-col space-y-1"), onClick: () => clearSelection(), children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
4177
4196
|
"div",
|
|
4178
4197
|
{
|
|
@@ -4390,30 +4409,30 @@ const Node = memo(({ node: r, style: n, dragHandle: o }) => {
|
|
|
4390
4409
|
}, getBlocksFromHTML = (r) => {
|
|
4391
4410
|
const n = parse$1(getSanitizedHTML(r));
|
|
4392
4411
|
return isEmpty(r) ? [] : flatten(traverseNodes(n));
|
|
4393
|
-
}, ImportHTML = () => {
|
|
4394
|
-
const { t:
|
|
4395
|
-
const
|
|
4396
|
-
|
|
4412
|
+
}, ImportHTML = ({ parentId: r }) => {
|
|
4413
|
+
const { t: n } = useTranslation(), [o, a] = useState$1(""), { addPredefinedBlock: i } = useAddBlock(), l = () => {
|
|
4414
|
+
const c = getBlocksFromHTML(o);
|
|
4415
|
+
i([...c], r), a(""), emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK });
|
|
4397
4416
|
};
|
|
4398
4417
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(Card, { className: "border-border/0 p-0 shadow-none", children: [
|
|
4399
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(CardHeader, { className: "p-3", children: /* @__PURE__ */ jsxRuntimeExports.jsx(CardDescription, { children:
|
|
4418
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(CardHeader, { className: "p-3", children: /* @__PURE__ */ jsxRuntimeExports.jsx(CardDescription, { children: n("html_snippet_description") }) }),
|
|
4400
4419
|
/* @__PURE__ */ jsxRuntimeExports.jsx(CardContent, { className: "space-y-2 px-3 py-0", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "space-y-1", children: [
|
|
4401
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(Label, { htmlFor: "current", className: "text-sm", children:
|
|
4420
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Label, { htmlFor: "current", className: "text-sm", children: n("tailwind_html_snippet") }),
|
|
4402
4421
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
4403
4422
|
Textarea,
|
|
4404
4423
|
{
|
|
4405
4424
|
autoFocus: !0,
|
|
4406
4425
|
tabIndex: 1,
|
|
4407
|
-
ref: (
|
|
4408
|
-
onChange: (
|
|
4426
|
+
ref: (c) => c && c.focus(),
|
|
4427
|
+
onChange: (c) => a(c.target.value),
|
|
4409
4428
|
rows: 12,
|
|
4410
|
-
value:
|
|
4411
|
-
placeholder:
|
|
4429
|
+
value: o,
|
|
4430
|
+
placeholder: n("enter_code_snippet"),
|
|
4412
4431
|
className: "resize-none overflow-x-auto whitespace-pre bg-gray-100 font-mono text-xs font-normal"
|
|
4413
4432
|
}
|
|
4414
4433
|
)
|
|
4415
4434
|
] }) }),
|
|
4416
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(CardFooter, { className: "flex flex-col justify-end p-3", children: /* @__PURE__ */ jsxRuntimeExports.jsx(Button$1, { disabled:
|
|
4435
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(CardFooter, { className: "flex flex-col justify-end p-3", children: /* @__PURE__ */ jsxRuntimeExports.jsx(Button$1, { disabled: o.trim() === "", onClick: () => l(), size: "sm", className: "w-full", children: n("import_html") }) })
|
|
4417
4436
|
] });
|
|
4418
4437
|
}, ImportHTML$1 = ImportHTML, isBoolean = (r) => typeof r == "boolean" || r instanceof Boolean, isNumber = (r) => typeof r == "number" || r instanceof Number, isBigInt = (r) => typeof r == "bigint" || r instanceof BigInt, isDate = (r) => !!r && r instanceof Date, isString = (r) => typeof r == "string" || r instanceof String, isArray$4 = (r) => Array.isArray(r), isObject$1 = (r) => r instanceof Object && r !== null;
|
|
4419
4438
|
function useBool(r) {
|
|
@@ -4443,8 +4462,8 @@ function ExpandableObject(r) {
|
|
|
4443
4462
|
useEffect$1(() => {
|
|
4444
4463
|
g.current ? x(m(u, o, n)) : g.current = !0;
|
|
4445
4464
|
}, [m]);
|
|
4446
|
-
const v = h ? d.collapseIcon : d.expandIcon, S = h ? "collapse JSON" : "expand JSON", E = useComponentId(), w = u + 1, A = a.length - 1, P = (
|
|
4447
|
-
|
|
4465
|
+
const v = h ? d.collapseIcon : d.expandIcon, S = h ? "collapse JSON" : "expand JSON", E = useComponentId(), w = u + 1, A = a.length - 1, P = (C) => {
|
|
4466
|
+
C.key === " " && (C.preventDefault(), b());
|
|
4448
4467
|
};
|
|
4449
4468
|
return /* @__PURE__ */ createElement$1("div", {
|
|
4450
4469
|
className: d.basicChildStyle,
|
|
@@ -4470,12 +4489,12 @@ function ExpandableObject(r) {
|
|
|
4470
4489
|
className: d.punctuation
|
|
4471
4490
|
}, l), h ? /* @__PURE__ */ createElement$1("div", {
|
|
4472
4491
|
id: E
|
|
4473
|
-
}, a.map((
|
|
4474
|
-
key:
|
|
4475
|
-
field:
|
|
4476
|
-
value:
|
|
4492
|
+
}, a.map((C, R) => /* @__PURE__ */ createElement$1(DataRender, {
|
|
4493
|
+
key: C[0] || R,
|
|
4494
|
+
field: C[0],
|
|
4495
|
+
value: C[1],
|
|
4477
4496
|
style: d,
|
|
4478
|
-
lastElement:
|
|
4497
|
+
lastElement: R === A,
|
|
4479
4498
|
level: w,
|
|
4480
4499
|
shouldExpandNode: m,
|
|
4481
4500
|
clickToExpandNode: p
|
|
@@ -4956,7 +4975,7 @@ const ViewData = ({ data: r, fullView: n }) => {
|
|
|
4956
4975
|
}
|
|
4957
4976
|
)
|
|
4958
4977
|
] });
|
|
4959
|
-
}, UnsplashImages = React__default.lazy(() => import("./UnsplashImages-
|
|
4978
|
+
}, UnsplashImages = React__default.lazy(() => import("./UnsplashImages-SUnc-2ZG.js")), UploadImages = React__default.lazy(() => import("./UploadImages-iewW_N13.js")), ImagesPanel = ({
|
|
4960
4979
|
isModalView: r = !1,
|
|
4961
4980
|
onSelect: n = () => {
|
|
4962
4981
|
}
|
|
@@ -5431,35 +5450,35 @@ const AskAIStyles = ({ blockId: r }) => {
|
|
|
5431
5450
|
keys: ["name"]
|
|
5432
5451
|
});
|
|
5433
5452
|
function ManualClasses() {
|
|
5434
|
-
var
|
|
5435
|
-
const { t: r } = useTranslation(), [n] = useSelectedStylingBlocks(), o = useSelectedBlock(), a = useAddClassesToBlocks(), i = useRemoveClassesFromBlocks(), [l] = useSelectedBlockIds(), c = useBuilderProp("askAiCallBack", null), [u, d] = useState$1(""), { toast: m } = useToast(), p = (
|
|
5436
|
-
const
|
|
5437
|
-
a(l,
|
|
5438
|
-
}, [b, x] = useState$1([]), v = ({ value:
|
|
5439
|
-
const I =
|
|
5453
|
+
var C;
|
|
5454
|
+
const { t: r } = useTranslation(), [n] = useSelectedStylingBlocks(), o = useSelectedBlock(), a = useAddClassesToBlocks(), i = useRemoveClassesFromBlocks(), [l] = useSelectedBlockIds(), c = useBuilderProp("askAiCallBack", null), [u, d] = useState$1(""), { toast: m } = useToast(), p = (C = first(n)) == null ? void 0 : C.prop, g = reject((get$1(o, p, "").replace(STYLES_KEY, "").split(",").pop() || "").split(" "), isEmpty), h = () => {
|
|
5455
|
+
const R = u.trim().toLowerCase().replace(/ +(?= )/g, "").split(" ");
|
|
5456
|
+
a(l, R, !0), d("");
|
|
5457
|
+
}, [b, x] = useState$1([]), v = ({ value: R }) => {
|
|
5458
|
+
const I = R.trim().toLowerCase(), j = I.match(/.+:/g);
|
|
5440
5459
|
let k = [];
|
|
5441
5460
|
if (j && j.length > 0) {
|
|
5442
5461
|
const [O] = j, T = I.replace(O, "");
|
|
5443
|
-
k = fuse.search(T).map((
|
|
5444
|
-
...
|
|
5445
|
-
item: { ...
|
|
5462
|
+
k = fuse.search(T).map((L) => ({
|
|
5463
|
+
...L,
|
|
5464
|
+
item: { ...L.item, name: O + L.item.name }
|
|
5446
5465
|
}));
|
|
5447
5466
|
} else
|
|
5448
5467
|
k = fuse.search(I);
|
|
5449
5468
|
return x(map(k, "item"));
|
|
5450
5469
|
}, S = () => {
|
|
5451
5470
|
x([]);
|
|
5452
|
-
}, E = (
|
|
5471
|
+
}, E = (R) => R.name, w = (R) => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "rounded-md p-1", children: R.name }), A = {
|
|
5453
5472
|
autoComplete: "off",
|
|
5454
5473
|
autoCorrect: "off",
|
|
5455
5474
|
autoCapitalize: "off",
|
|
5456
5475
|
spellCheck: !1,
|
|
5457
5476
|
placeholder: r("enter_classes_separated_by_space"),
|
|
5458
5477
|
value: u,
|
|
5459
|
-
onKeyDown: (
|
|
5460
|
-
|
|
5478
|
+
onKeyDown: (R) => {
|
|
5479
|
+
R.key === "Enter" && u.trim() !== "" && h();
|
|
5461
5480
|
},
|
|
5462
|
-
onChange: (
|
|
5481
|
+
onChange: (R, { newValue: I }) => d(I),
|
|
5463
5482
|
className: "w-full rounded-md text-xs px-2 hover:outline-0 bg-background border-border py-1"
|
|
5464
5483
|
}, P = () => {
|
|
5465
5484
|
if (navigator.clipboard === void 0) {
|
|
@@ -5529,22 +5548,22 @@ function ManualClasses() {
|
|
|
5529
5548
|
)
|
|
5530
5549
|
] }),
|
|
5531
5550
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex w-full flex-wrap gap-2 overflow-x-hidden", children: React.Children.toArray(
|
|
5532
|
-
g.map((
|
|
5551
|
+
g.map((R) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
5533
5552
|
"div",
|
|
5534
5553
|
{
|
|
5535
5554
|
className: "group relative flex max-w-[260px] cursor-default items-center gap-x-1 truncate rounded border border-gray-300 bg-gray-200 p-px px-1.5 text-[11px] text-gray-600 hover:border-gray-300",
|
|
5536
5555
|
children: [
|
|
5537
|
-
|
|
5556
|
+
R,
|
|
5538
5557
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
5539
5558
|
Cross2Icon,
|
|
5540
5559
|
{
|
|
5541
|
-
onClick: () => i(l, [
|
|
5560
|
+
onClick: () => i(l, [R]),
|
|
5542
5561
|
className: "invisible absolute right-1 rounded-full bg-red-400 hover:text-white group-hover:visible group-hover:cursor-pointer"
|
|
5543
5562
|
}
|
|
5544
5563
|
)
|
|
5545
5564
|
]
|
|
5546
5565
|
},
|
|
5547
|
-
|
|
5566
|
+
R
|
|
5548
5567
|
))
|
|
5549
5568
|
) })
|
|
5550
5569
|
]
|
|
@@ -6203,7 +6222,7 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6203
6222
|
}
|
|
6204
6223
|
h(O), i(O === "class" || isEmpty(k) ? "" : k);
|
|
6205
6224
|
}, [l, d, m]);
|
|
6206
|
-
const
|
|
6225
|
+
const C = useThrottledCallback((k) => c(k), [c], THROTTLE_TIME), R = useThrottledCallback((k) => c(k, !1), [c], THROTTLE_TIME), I = useCallback$1(
|
|
6207
6226
|
(k = !1) => {
|
|
6208
6227
|
const O = getUserInputValues(`${a}`, m);
|
|
6209
6228
|
if (get$1(O, "error", !1)) {
|
|
@@ -6212,15 +6231,15 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6212
6231
|
}
|
|
6213
6232
|
const T = get$1(O, "unit") !== "" ? get$1(O, "unit") : g;
|
|
6214
6233
|
if (T === "auto" || T === "none") {
|
|
6215
|
-
|
|
6234
|
+
C(`${u}${T}`);
|
|
6216
6235
|
return;
|
|
6217
6236
|
}
|
|
6218
6237
|
if (get$1(O, "value") === "")
|
|
6219
6238
|
return;
|
|
6220
|
-
const
|
|
6221
|
-
k ?
|
|
6239
|
+
const L = `${get$1(O, "value", "").startsWith("-") ? "-" : ""}${u}[${get$1(O, "value", "").replace("-", "")}${T === "-" ? "" : T}]`;
|
|
6240
|
+
k ? R(L) : C(L);
|
|
6222
6241
|
},
|
|
6223
|
-
[
|
|
6242
|
+
[C, R, a, g, u, m]
|
|
6224
6243
|
), j = useCallback$1(
|
|
6225
6244
|
(k) => {
|
|
6226
6245
|
const O = getUserInputValues(`${a}`, m);
|
|
@@ -6229,15 +6248,15 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6229
6248
|
return;
|
|
6230
6249
|
}
|
|
6231
6250
|
if (k === "auto" || k === "none") {
|
|
6232
|
-
|
|
6251
|
+
C(`${u}${k}`);
|
|
6233
6252
|
return;
|
|
6234
6253
|
}
|
|
6235
6254
|
if (get$1(O, "value") === "")
|
|
6236
6255
|
return;
|
|
6237
|
-
const T = get$1(O, "unit") !== "" ? get$1(O, "unit") : k,
|
|
6238
|
-
|
|
6256
|
+
const T = get$1(O, "unit") !== "" ? get$1(O, "unit") : k, L = `${get$1(O, "value", "").startsWith("-") ? "-" : ""}${u}[${get$1(O, "value", "").replace("-", "")}${T === "-" ? "" : T}]`;
|
|
6257
|
+
C(L);
|
|
6239
6258
|
},
|
|
6240
|
-
[
|
|
6259
|
+
[C, a, u, m]
|
|
6241
6260
|
);
|
|
6242
6261
|
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex w-full flex-col", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex items-center justify-start", children: g === "class" ? /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
6243
6262
|
/* @__PURE__ */ jsxRuntimeExports.jsx("input", { className: "w-20 rounded py-1", readOnly: !0, value: l }),
|
|
@@ -6261,8 +6280,8 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6261
6280
|
const O = parseInt$1(k.target.value);
|
|
6262
6281
|
let T = isNaN$1(O) ? 0 : O;
|
|
6263
6282
|
k.keyCode === 38 && (T += 1), k.keyCode === 40 && (T -= 1);
|
|
6264
|
-
const
|
|
6265
|
-
|
|
6283
|
+
const B = `${T}`, D = `${B.startsWith("-") ? "-" : ""}${u}[${B.replace("-", "")}${g === "-" ? "" : g}]`;
|
|
6284
|
+
R(D);
|
|
6266
6285
|
},
|
|
6267
6286
|
onKeyUp: (k) => {
|
|
6268
6287
|
A && (k.preventDefault(), P(!1));
|
|
@@ -6314,15 +6333,15 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6314
6333
|
onDragEnd: (k) => {
|
|
6315
6334
|
if (S(() => ""), w(!1), isEmpty(k))
|
|
6316
6335
|
return;
|
|
6317
|
-
const O = `${k}`,
|
|
6318
|
-
|
|
6336
|
+
const O = `${k}`, B = `${O.startsWith("-") ? "-" : ""}${u}[${O.replace("-", "")}${g === "-" ? "" : g}]`;
|
|
6337
|
+
C(B);
|
|
6319
6338
|
},
|
|
6320
6339
|
onDrag: (k) => {
|
|
6321
6340
|
if (isEmpty(k))
|
|
6322
6341
|
return;
|
|
6323
6342
|
S(k);
|
|
6324
|
-
const O = `${k}`,
|
|
6325
|
-
|
|
6343
|
+
const O = `${k}`, B = `${O.startsWith("-") ? "-" : ""}${u}[${O.replace("-", "")}${g === "-" ? "" : g}]`;
|
|
6344
|
+
R(B);
|
|
6326
6345
|
},
|
|
6327
6346
|
currentValue: a,
|
|
6328
6347
|
unit: g,
|
|
@@ -6420,8 +6439,8 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6420
6439
|
}, getBreakpoint = (r) => `${r.toUpperCase()} ${BREAKPOINTS[r] ? `(${BREAKPOINTS[r]} & up)` : ""}`, BlockStyle = (r) => {
|
|
6421
6440
|
const { t: n } = useTranslation(), { type: o = "icons", label: a, property: i, onEmitChange: l = () => {
|
|
6422
6441
|
}, units: c, negative: u = !1 } = r, [d] = useDarkMode(), [m] = useStylingState(), [, p] = useCanvasWidth(), g = useCurrentClassByProperty(i), h = useAddClassesToBlocks(), b = useRemoveClassesFromBlocks(), [x] = useSelectedBlockIds(), v = useMemo$1(() => get$1(g, "fullCls", ""), [g]), S = useCallback$1(
|
|
6423
|
-
(
|
|
6424
|
-
const j = { dark: d, mq: p, mod: m, cls:
|
|
6442
|
+
(R, I = !0) => {
|
|
6443
|
+
const j = { dark: d, mq: p, mod: m, cls: R, property: i, fullCls: "" };
|
|
6425
6444
|
(d || m !== "") && (j.mq = "xs");
|
|
6426
6445
|
const k = generateFullClsName(j);
|
|
6427
6446
|
h(x, [k], I);
|
|
@@ -6434,7 +6453,7 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6434
6453
|
l(w, g);
|
|
6435
6454
|
}, [w, l, g]);
|
|
6436
6455
|
const [, , A] = useCanvasWidth(), P = useCallback$1(
|
|
6437
|
-
(
|
|
6456
|
+
(R) => {
|
|
6438
6457
|
A({
|
|
6439
6458
|
xs: 400,
|
|
6440
6459
|
sm: 640,
|
|
@@ -6442,12 +6461,12 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6442
6461
|
lg: 1024,
|
|
6443
6462
|
xl: 1420,
|
|
6444
6463
|
"2xl": 1920
|
|
6445
|
-
}[
|
|
6464
|
+
}[R]);
|
|
6446
6465
|
},
|
|
6447
6466
|
[A]
|
|
6448
|
-
),
|
|
6449
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(BlockStyleProvider, { canChange: w, canReset: g &&
|
|
6450
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "relative w-[70px] truncate text-xs text-foreground", children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `text-[11px] ${g && !
|
|
6467
|
+
), C = get$1(g, "dark", null) === d && get$1(g, "mod", null) === m && get$1(g, "mq", null) === p;
|
|
6468
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(BlockStyleProvider, { canChange: w, canReset: g && C, children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "group flex flex-row items-center py-2 first:pt-0 last:pb-0", children: [
|
|
6469
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "relative w-[70px] truncate text-xs text-foreground", children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: `text-[11px] ${g && !C ? "text-foreground" : ""}`, children: n(a) }) }),
|
|
6451
6470
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex flex-row items-center", children: [
|
|
6452
6471
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "w-[150px]", children: [
|
|
6453
6472
|
o === "arbitrary" ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -6466,7 +6485,7 @@ const RangeChoices = ({ property: r, onChange: n }) => {
|
|
|
6466
6485
|
o === "color" && /* @__PURE__ */ jsxRuntimeExports.jsx(ColorChoice, { property: i, onChange: S }),
|
|
6467
6486
|
o === "dropdown" && /* @__PURE__ */ jsxRuntimeExports.jsx(DropDownChoices, { label: a, property: i, onChange: S })
|
|
6468
6487
|
] }),
|
|
6469
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `w-[30px] cursor-pointer ${v ? "visible" : "invisible"}`, children:
|
|
6488
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: `w-[30px] cursor-pointer ${v ? "visible" : "invisible"}`, children: C ? /* @__PURE__ */ jsxRuntimeExports.jsx("button", { type: "button", onClick: () => E(), title: "Reset", className: "flex px-1.5 text-xs", children: /* @__PURE__ */ jsxRuntimeExports.jsx(CrossCircledIcon, { className: "h-5 w-5 text-blue-500 hover:opacity-80" }) }) : w && g ? /* @__PURE__ */ jsxRuntimeExports.jsxs(Tooltip$1, { delayDuration: 100, children: [
|
|
6470
6489
|
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipTrigger, { asChild: !0, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
6471
6490
|
"button",
|
|
6472
6491
|
{
|
|
@@ -6740,38 +6759,37 @@ function UILibrariesSelect({
|
|
|
6740
6759
|
}
|
|
6741
6760
|
const BlockCard = ({
|
|
6742
6761
|
block: r,
|
|
6743
|
-
|
|
6744
|
-
|
|
6762
|
+
library: n,
|
|
6763
|
+
parentId: o = void 0
|
|
6745
6764
|
}) => {
|
|
6746
|
-
const [a, i] = useState$1(!1), l = useBuilderProp("getUILibraryBlock", noop$1), { addCoreBlock: c, addPredefinedBlock: u } = useAddBlock(), [
|
|
6747
|
-
const
|
|
6748
|
-
return
|
|
6749
|
-
},
|
|
6750
|
-
async (
|
|
6751
|
-
if (
|
|
6752
|
-
c(r,
|
|
6765
|
+
const [a, i] = useState$1(!1), l = useBuilderProp("getUILibraryBlock", noop$1), { addCoreBlock: c, addPredefinedBlock: u } = useAddBlock(), [, d] = useSelectedBlockIds(), [, m] = useHighlightBlockId(), p = get$1(r, "name", get$1(r, "label")), g = useFeature("dnd"), [, h] = useAtom$1(draggedBlockAtom), b = (S) => {
|
|
6766
|
+
const E = has(S, "styles_attrs.data-page-section");
|
|
6767
|
+
return S._type === "Box" && E;
|
|
6768
|
+
}, x = useCallback$1(
|
|
6769
|
+
async (S) => {
|
|
6770
|
+
if (S.stopPropagation(), has(r, "component")) {
|
|
6771
|
+
c(r, o), emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK });
|
|
6753
6772
|
return;
|
|
6754
6773
|
}
|
|
6755
6774
|
i(!0);
|
|
6756
|
-
const
|
|
6757
|
-
|
|
6758
|
-
isEmpty(w) || u(syncBlocksWithDefaults(w), A), n();
|
|
6775
|
+
const E = await l(n, r);
|
|
6776
|
+
isEmpty(E) || u(syncBlocksWithDefaults(E), o), emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK });
|
|
6759
6777
|
},
|
|
6760
6778
|
[r]
|
|
6761
|
-
),
|
|
6762
|
-
const
|
|
6763
|
-
let
|
|
6764
|
-
if (
|
|
6765
|
-
const
|
|
6766
|
-
if (
|
|
6767
|
-
const
|
|
6768
|
-
|
|
6769
|
-
|
|
6779
|
+
), v = async (S) => {
|
|
6780
|
+
const E = await l(n, r);
|
|
6781
|
+
let w = o;
|
|
6782
|
+
if (b(first(E)) && (w = null), !isEmpty(E)) {
|
|
6783
|
+
const A = { blocks: E, uiLibrary: !0, parent: w };
|
|
6784
|
+
if (S.dataTransfer.setData("text/plain", JSON.stringify(A)), r.preview) {
|
|
6785
|
+
const P = new Image();
|
|
6786
|
+
P.src = r.preview, P.onload = () => {
|
|
6787
|
+
S.dataTransfer.setDragImage(P, 0, 0);
|
|
6770
6788
|
};
|
|
6771
6789
|
} else
|
|
6772
|
-
|
|
6773
|
-
|
|
6774
|
-
|
|
6790
|
+
S.dataTransfer.setDragImage(new Image(), 0, 0);
|
|
6791
|
+
h(A), setTimeout(() => {
|
|
6792
|
+
d([]), m(null), emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK });
|
|
6775
6793
|
}, 200);
|
|
6776
6794
|
}
|
|
6777
6795
|
};
|
|
@@ -6780,9 +6798,9 @@ const BlockCard = ({
|
|
|
6780
6798
|
"div",
|
|
6781
6799
|
{
|
|
6782
6800
|
onClick: a ? () => {
|
|
6783
|
-
} :
|
|
6784
|
-
draggable:
|
|
6785
|
-
onDragStart:
|
|
6801
|
+
} : x,
|
|
6802
|
+
draggable: g ? "true" : "false",
|
|
6803
|
+
onDragStart: v,
|
|
6786
6804
|
className: clsx(
|
|
6787
6805
|
"relative mt-2 cursor-pointer overflow-hidden rounded-md border border-gray-300 bg-white duration-200 hover:border-blue-500 hover:shadow-xl"
|
|
6788
6806
|
),
|
|
@@ -6791,11 +6809,11 @@ const BlockCard = ({
|
|
|
6791
6809
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Loader$1, { className: "animate-spin", size: 15, color: "white" }),
|
|
6792
6810
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "pl-2 text-sm text-white", children: "Adding..." })
|
|
6793
6811
|
] }),
|
|
6794
|
-
r.preview ? /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: r.preview, className: "min-h-[45px] w-full rounded-md", alt:
|
|
6812
|
+
r.preview ? /* @__PURE__ */ jsxRuntimeExports.jsx("img", { src: r.preview, className: "min-h-[45px] w-full rounded-md", alt: p }) : /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex h-20 items-center justify-center rounded-md border border-border border-gray-300 bg-gray-200", children: /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "max-w-xs text-center text-sm text-gray-700", children: p }) })
|
|
6795
6813
|
]
|
|
6796
6814
|
}
|
|
6797
6815
|
) }),
|
|
6798
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContent, { children: /* @__PURE__ */ jsxRuntimeExports.jsx("p", { children:
|
|
6816
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContent, { children: /* @__PURE__ */ jsxRuntimeExports.jsx("p", { children: p }) })
|
|
6799
6817
|
] });
|
|
6800
6818
|
}, libraryBlocksAtom = atom$1(
|
|
6801
6819
|
{}
|
|
@@ -6810,34 +6828,34 @@ const BlockCard = ({
|
|
|
6810
6828
|
c.current = "idle", o((d) => ({ ...d, [r == null ? void 0 : r.uuid]: { loading: "complete", blocks: u || [] } }));
|
|
6811
6829
|
})();
|
|
6812
6830
|
}, [r, i, l, c]), { data: i || [], isLoading: l === "loading" };
|
|
6813
|
-
}, UILibrarySection = () => {
|
|
6814
|
-
const [
|
|
6815
|
-
|
|
6816
|
-
|
|
6831
|
+
}, UILibrarySection = ({ parentId: r }) => {
|
|
6832
|
+
const [n, o] = useAtom$1(selectedLibraryAtom), a = useBuilderProp("uiLibraries", []), i = useChaiBlocks(), l = values(i).filter((w) => w.category === "custom"), c = a.find((w) => w.uuid === n) || first(a), { data: u, isLoading: d } = useLibraryBlocks(c), m = groupBy([...u, ...l], "group"), [p, g] = useState$1("Hero"), h = get$1(m, p, []), b = useRef$1(null), { t: x } = useTranslation(), v = (w) => {
|
|
6833
|
+
b.current && (clearTimeout(b.current), b.current = null), b.current = setTimeout(() => {
|
|
6834
|
+
b.current && g(w);
|
|
6817
6835
|
}, 300);
|
|
6818
6836
|
};
|
|
6819
|
-
if (
|
|
6837
|
+
if (d)
|
|
6820
6838
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "mt-4 grid h-full w-full grid-cols-12 gap-2", children: [
|
|
6821
6839
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Skeleton, { className: "col-span-3 h-full" }),
|
|
6822
6840
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Skeleton, { className: "col-span-9 h-full" })
|
|
6823
6841
|
] });
|
|
6824
|
-
const S = filter(
|
|
6825
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "relative flex h-full max-h-full flex-col overflow-hidden bg-background", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex h-full pt-2", children: [
|
|
6826
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex h-full w-
|
|
6827
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(UILibrariesSelect, { library:
|
|
6828
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "mt-2 flex flex-col", children: [
|
|
6842
|
+
const S = filter(h, (w, A) => A % 2 === 0), E = filter(h, (w, A) => A % 2 === 1);
|
|
6843
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "relative mt-2 flex h-full max-h-full flex-col overflow-hidden bg-background", children: /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex h-full pt-2", children: [
|
|
6844
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex h-full w-60 flex-col gap-1 px-1 pr-2", children: [
|
|
6845
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(UILibrariesSelect, { library: c == null ? void 0 : c.uuid, setLibrary: o, uiLibraries: a }),
|
|
6846
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "mt-2 flex h-full max-h-full flex-col", children: [
|
|
6829
6847
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-xs font-bold text-gray-500", children: x("groups") }),
|
|
6830
6848
|
/* @__PURE__ */ jsxRuntimeExports.jsx("hr", { className: "mt-1" }),
|
|
6831
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(ScrollArea$1, { className: "mt-2 h-full
|
|
6832
|
-
map(
|
|
6849
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(ScrollArea$1, { className: "no-scrollbar mt-2 h-full max-h-full overflow-y-auto", children: React__default.Children.toArray(
|
|
6850
|
+
map(m, (w, A) => /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
6833
6851
|
"div",
|
|
6834
6852
|
{
|
|
6835
6853
|
onMouseEnter: () => v(A),
|
|
6836
|
-
onMouseLeave: () => clearTimeout(
|
|
6837
|
-
onClick: () =>
|
|
6854
|
+
onMouseLeave: () => clearTimeout(b.current),
|
|
6855
|
+
onClick: () => g(A),
|
|
6838
6856
|
className: cn(
|
|
6839
6857
|
"flex w-full cursor-pointer items-center justify-between rounded-md p-2 text-sm transition-all ease-in-out hover:bg-gray-200",
|
|
6840
|
-
A ===
|
|
6858
|
+
A === p ? "bg-blue-500 text-white hover:bg-blue-600" : ""
|
|
6841
6859
|
),
|
|
6842
6860
|
children: [
|
|
6843
6861
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: capitalize(x(A.toLowerCase())) }),
|
|
@@ -6852,15 +6870,15 @@ const BlockCard = ({
|
|
|
6852
6870
|
/* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
6853
6871
|
ScrollArea$1,
|
|
6854
6872
|
{
|
|
6855
|
-
onMouseEnter: () =>
|
|
6873
|
+
onMouseEnter: () => b.current ? clearTimeout(b.current) : null,
|
|
6856
6874
|
className: "z-10 -mt-2 flex h-full max-h-full w-full flex-col gap-2 border-l border-gray-300 transition-all ease-linear",
|
|
6857
6875
|
children: [
|
|
6858
6876
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "grid grid-cols-2 gap-2 px-2", children: [
|
|
6859
6877
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col gap-1", children: React__default.Children.toArray(
|
|
6860
|
-
S.map((w) => /* @__PURE__ */ jsxRuntimeExports.jsx(BlockCard, {
|
|
6878
|
+
S.map((w) => /* @__PURE__ */ jsxRuntimeExports.jsx(BlockCard, { parentId: r, block: w, library: c }))
|
|
6861
6879
|
) }),
|
|
6862
6880
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex flex-col gap-1", children: React__default.Children.toArray(
|
|
6863
|
-
E.map((w) => /* @__PURE__ */ jsxRuntimeExports.jsx(BlockCard, {
|
|
6881
|
+
E.map((w) => /* @__PURE__ */ jsxRuntimeExports.jsx(BlockCard, { parentId: r, block: w, library: c }))
|
|
6864
6882
|
) })
|
|
6865
6883
|
] }),
|
|
6866
6884
|
/* @__PURE__ */ jsxRuntimeExports.jsx("br", {}),
|
|
@@ -6870,7 +6888,7 @@ const BlockCard = ({
|
|
|
6870
6888
|
}
|
|
6871
6889
|
)
|
|
6872
6890
|
] }) }) });
|
|
6873
|
-
}, UILibrariesPanel = () => /* @__PURE__ */ jsxRuntimeExports.jsx(UILibrarySection, {}), UILibraries = UILibrariesPanel, add_block = "Add block", enter_paste_tailwind_html = "(Enter or paste TailwindCSS HTML snippet)", click_to_add_block = "(Click to add block to page)", core = "Core", custom_blocks = "Custom Blocks", ui_library = "UI Library", html_snippet_description = "Use HTML snippets from Tailwind CSS component libraries etc. or just copy paste your own HTML code.", tailwind_html_snippet = "Tailwind HTML snippet:", enter_code_snippet = "Enter your code snippet here...", import_html = "Import HTML", note_imported_html = "NOTE: Imported html will be added to the currently selected block. If no block is selected, the html will be added to the page.", dark_mode = "Dark mode", tree_view_no_blocks = "This page has no blocks. Add a block by clicking the + button", canvas_empty = "This page is empty", no_block_selected_for_styling = "Please select a block to edit settings or styles", no_block_selected_for_ask_ai = "Please select a block to ask AI", no_styling_block_selected = "Please select a styling block", drop_here_message = "Drop your block here", use_setting = "Use setting", mobile_xs_title = "Mobile (XS)", mobile_xs_content = "Styles set here are applied to all screen unless edited at higher breakpoint", mobile_sm_title = "Mobile landscape (SM)", mobile_sm_content = "Styles set here are applied at 640px and up unless edited at higher breakpoint", tablet_md_title = "Tablet (MD)", tablet_md_content = "Styles set here are applied at 768px and up", tablet_lg_title = "Tablet Landscape (LG)", tablet_lg_content = "Styles set here are applied at 1024px and up unless edited at higher breakpoint", desktop_xl_title = "Desktop (XL)", desktop_xl_content = "Styles set here are applied at 1280px and up unless edited at higher breakpoint", large_desktop_2xl_title = "Large Desktop (2XL)", large_desktop_2xl_content = "Styles set here are applied at 1536px and up", Breakpoints$1 = "Breakpoints", clear = "Clear", clear_canvas_title = "Clear whole canvas?", clear_canvas_description = "Are you sure you want to clear the whole canvas?", cancel = "Cancel", yes = "Yes", preview = "Preview", settings = "Settings", styling = "Styling", data_provider = "Data Provider", remove_provider_confirmation = "Are you sure you want to remove <span class='text-blue-500'>{name}</span> provider?", remove_provider_warning = "Your data provider will be removed from this page and all added data binding will be not visible on blocks.", remove = "Remove", no_data_providers = "You have no data providers registered. Please add a data provider to your project.", learn_more = "Learn more", add_data_providers = "Add data providers:", select_provider = "Select a provider", choose = "Choose", page_data_providers = "Page data providers:", view_data = "View Data", mark_as_global = "Mark as Global", global_block_note = "Note: Global blocks are single instances. Editing global blocks will be reflected on all pages using these blocks.", global_block_indicator = "Global blocks are indicated with", global_block_category = "Global blocks are available under 'Global' category", enter_global_block_name = "Enter global block name", eg_header_footer = "Eg: Header, Footer", blocks_selected = "{{length}} blocks selected.", cut = "Cut", copy$1 = "Copy", clear_selection = "Clear Selection", dev_mode_message = "This is dev mode. Visit", to_see_page_preview = "to see page preview", theme_config = {
|
|
6891
|
+
}, UILibrariesPanel = ({ parentId: r }) => /* @__PURE__ */ jsxRuntimeExports.jsx(UILibrarySection, { parentId: r }), UILibraries = UILibrariesPanel, add_block = "Add block", enter_paste_tailwind_html = "(Enter or paste TailwindCSS HTML snippet)", click_to_add_block = "(Click to add block to page)", core = "Core", custom_blocks = "Custom Blocks", ui_library = "UI Library", html_snippet_description = "Use HTML snippets from Tailwind CSS component libraries etc. or just copy paste your own HTML code.", tailwind_html_snippet = "Tailwind HTML snippet:", enter_code_snippet = "Enter your code snippet here...", import_html = "Import HTML", note_imported_html = "NOTE: Imported html will be added to the currently selected block. If no block is selected, the html will be added to the page.", dark_mode = "Dark mode", tree_view_no_blocks = "This page has no blocks. Add a block by clicking the + button", canvas_empty = "This page is empty", no_block_selected_for_styling = "Please select a block to edit settings or styles", no_block_selected_for_ask_ai = "Please select a block to ask AI", no_styling_block_selected = "Please select a styling block", drop_here_message = "Drop your block here", use_setting = "Use setting", mobile_xs_title = "Mobile (XS)", mobile_xs_content = "Styles set here are applied to all screen unless edited at higher breakpoint", mobile_sm_title = "Mobile landscape (SM)", mobile_sm_content = "Styles set here are applied at 640px and up unless edited at higher breakpoint", tablet_md_title = "Tablet (MD)", tablet_md_content = "Styles set here are applied at 768px and up", tablet_lg_title = "Tablet Landscape (LG)", tablet_lg_content = "Styles set here are applied at 1024px and up unless edited at higher breakpoint", desktop_xl_title = "Desktop (XL)", desktop_xl_content = "Styles set here are applied at 1280px and up unless edited at higher breakpoint", large_desktop_2xl_title = "Large Desktop (2XL)", large_desktop_2xl_content = "Styles set here are applied at 1536px and up", Breakpoints$1 = "Breakpoints", clear = "Clear", clear_canvas_title = "Clear whole canvas?", clear_canvas_description = "Are you sure you want to clear the whole canvas?", cancel = "Cancel", yes = "Yes", preview = "Preview", settings = "Settings", styling = "Styling", data_provider = "Data Provider", remove_provider_confirmation = "Are you sure you want to remove <span class='text-blue-500'>{name}</span> provider?", remove_provider_warning = "Your data provider will be removed from this page and all added data binding will be not visible on blocks.", remove = "Remove", no_data_providers = "You have no data providers registered. Please add a data provider to your project.", learn_more = "Learn more", add_data_providers = "Add data providers:", select_provider = "Select a provider", choose = "Choose", page_data_providers = "Page data providers:", view_data = "View Data", mark_as_global = "Mark as Global", global_block_note = "Note: Global blocks are single instances. Editing global blocks will be reflected on all pages using these blocks.", global_block_indicator = "Global blocks are indicated with", global_block_category = "Global blocks are available under 'Global' category", enter_global_block_name = "Enter global block name", eg_header_footer = "Eg: Header, Footer", blocks_selected = "{{length}} blocks selected.", cut = "Cut", copy$1 = "Copy", clear_selection = "Clear Selection", dev_mode_message = "This is dev mode. Visit", to_see_page_preview = "to see page preview", theme_config = {
|
|
6874
6892
|
heading_font: "Heading Font",
|
|
6875
6893
|
body_font: "Body Font",
|
|
6876
6894
|
rounded_corner: "Rounded Corners",
|
|
@@ -7304,49 +7322,50 @@ i18n.use(initReactI18next).init({
|
|
|
7304
7322
|
// react already safes from xss => https://www.i18next.com/translation-function/interpolation#unescape
|
|
7305
7323
|
}
|
|
7306
7324
|
});
|
|
7307
|
-
const CoreBlock = ({ block: r, disabled: n }) => {
|
|
7308
|
-
const [,
|
|
7309
|
-
if (has(r, "blocks")) {
|
|
7310
|
-
const
|
|
7311
|
-
|
|
7325
|
+
const CoreBlock = ({ block: r, disabled: n, parentId: o }) => {
|
|
7326
|
+
const [, a] = useAtom$1(draggedBlockAtom), { type: i, icon: l, label: c } = r, { addCoreBlock: u, addPredefinedBlock: d } = useAddBlock(), [, m] = useSelectedBlockIds(), [, p] = useHighlightBlockId(), g = () => {
|
|
7327
|
+
if (console.log("addBlockToPage", r, o), has(r, "blocks")) {
|
|
7328
|
+
const x = isFunction$2(r.blocks) ? r.blocks() : r.blocks;
|
|
7329
|
+
d(syncBlocksWithDefaults(x), o || null);
|
|
7312
7330
|
} else
|
|
7313
|
-
|
|
7314
|
-
|
|
7315
|
-
},
|
|
7331
|
+
u(r, o || null);
|
|
7332
|
+
emitChaiBuilderMsg({ name: CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK });
|
|
7333
|
+
}, h = useFeature("dnd"), { t: b } = useTranslation();
|
|
7316
7334
|
return /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: /* @__PURE__ */ jsxRuntimeExports.jsxs(Tooltip$1, { children: [
|
|
7317
7335
|
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipTrigger, { asChild: !0, children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
7318
7336
|
"button",
|
|
7319
7337
|
{
|
|
7320
7338
|
disabled: n,
|
|
7321
|
-
onClick:
|
|
7339
|
+
onClick: g,
|
|
7322
7340
|
type: "button",
|
|
7323
|
-
onDragStart: (
|
|
7324
|
-
|
|
7325
|
-
|
|
7341
|
+
onDragStart: (x) => {
|
|
7342
|
+
x.dataTransfer.setData("text/plain", JSON.stringify(omit(r, ["component", "icon"]))), x.dataTransfer.setDragImage(new Image(), 0, 0), a(omit(r, ["component", "icon"])), setTimeout(() => {
|
|
7343
|
+
m([]), p(null);
|
|
7326
7344
|
}, 200);
|
|
7327
7345
|
},
|
|
7328
|
-
draggable:
|
|
7346
|
+
draggable: h ? "true" : "false",
|
|
7329
7347
|
className: "cursor-pointer space-y-2 rounded-lg border border-border p-3 text-center hover:bg-slate-300/50 disabled:cursor-not-allowed disabled:bg-gray-100 disabled:text-gray-400",
|
|
7330
7348
|
children: [
|
|
7331
|
-
createElement$1(
|
|
7332
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "truncate text-xs", children: capitalize(
|
|
7349
|
+
createElement$1(l || BoxIcon, { className: "w-4 h-4 mx-auto" }),
|
|
7350
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "truncate text-xs", children: capitalize(b(c || i)) })
|
|
7333
7351
|
]
|
|
7334
7352
|
}
|
|
7335
7353
|
) }),
|
|
7336
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContent, { children: /* @__PURE__ */ jsxRuntimeExports.jsx("p", { children:
|
|
7354
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContent, { children: /* @__PURE__ */ jsxRuntimeExports.jsx("p", { children: b(c || i) }) })
|
|
7337
7355
|
] }) });
|
|
7338
|
-
}, CORE_GROUPS = ["basic", "typography", "media", "layout", "form", "advanced", "other"], ChaiBuilderBlocks = ({ groups: r, blocks: n }) => {
|
|
7356
|
+
}, CORE_GROUPS = ["basic", "typography", "media", "layout", "form", "advanced", "other"], ChaiBuilderBlocks = ({ groups: r, blocks: n, parentId: o }) => {
|
|
7339
7357
|
var c;
|
|
7340
|
-
const { t:
|
|
7358
|
+
const { t: a } = useTranslation(), [i] = useBlocksStore(), l = (c = find(i, (u) => u._id === o)) == null ? void 0 : c._type;
|
|
7341
7359
|
return React__default.Children.toArray(
|
|
7342
7360
|
map(
|
|
7343
7361
|
sortBy(r, (u) => CORE_GROUPS.indexOf(u) === -1 ? 99 : CORE_GROUPS.indexOf(u)),
|
|
7344
7362
|
(u) => reject(filter(values(n), { group: u }), { hidden: !0 }).length ? /* @__PURE__ */ jsxRuntimeExports.jsx(Accordion, { type: "single", value: u, collapsible: !0, className: "w-full", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(AccordionItem, { value: u, children: [
|
|
7345
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(AccordionTrigger, { className: "rounded-md bg-gray-100 px-4 py-2 capitalize hover:no-underline", children: capitalize(
|
|
7363
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(AccordionTrigger, { className: "rounded-md bg-gray-100 px-4 py-2 capitalize hover:no-underline", children: capitalize(a(u.toLowerCase())) }),
|
|
7346
7364
|
/* @__PURE__ */ jsxRuntimeExports.jsx(AccordionContent, { className: "mx-auto max-w-xl p-3", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "grid grid-cols-4 gap-2", children: React__default.Children.toArray(
|
|
7347
7365
|
reject(filter(values(n), { group: u }), { hidden: !0 }).map((d) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
7348
7366
|
CoreBlock,
|
|
7349
7367
|
{
|
|
7368
|
+
parentId: o,
|
|
7350
7369
|
block: d,
|
|
7351
7370
|
disabled: !canAcceptChildBlock(l, d.type) || !canBeNestedInside(l, d.type)
|
|
7352
7371
|
}
|
|
@@ -7355,33 +7374,37 @@ const CoreBlock = ({ block: r, disabled: n }) => {
|
|
|
7355
7374
|
] }) }) : null
|
|
7356
7375
|
)
|
|
7357
7376
|
);
|
|
7358
|
-
}, AddBlocksPanel = ({
|
|
7359
|
-
|
|
7377
|
+
}, AddBlocksPanel = ({
|
|
7378
|
+
className: r,
|
|
7379
|
+
showHeading: n = !0,
|
|
7380
|
+
parentId: o = void 0
|
|
7381
|
+
}) => {
|
|
7382
|
+
const { t: a } = useTranslation(), [i, l] = useState$1("library"), [c, u] = useState$1("basic"), d = useChaiBlocks(), [, m] = useAtom$1(showPredefinedBlockCategoryAtom), p = useBuilderProp("importHTMLSupport", !0), g = useBuilderProp("filterChaiBlock", () => !0), h = filter(d, g), b = groupBy(h, "category"), x = uniq(map(b.core, "group"));
|
|
7360
7383
|
return useEffect$1(() => {
|
|
7361
|
-
!includes(
|
|
7362
|
-
}, [
|
|
7384
|
+
!includes(x, c) && !isEmpty(x) && !isEmpty(c) && u(first(x));
|
|
7385
|
+
}, [x, c]), /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: cn("flex h-full w-full flex-col overflow-hidden", r), children: [
|
|
7363
7386
|
n ? /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "mb-2 flex flex-col justify-between rounded-md bg-background/30 p-1", children: [
|
|
7364
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("h1", { className: "flex flex-col items-baseline px-1 text-xl font-semibold xl:flex-col", children:
|
|
7365
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "p-0 text-xs font-light leading-3 opacity-80 xl:pl-1", children:
|
|
7387
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("h1", { className: "flex flex-col items-baseline px-1 text-xl font-semibold xl:flex-col", children: a("add_block") }),
|
|
7388
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "p-0 text-xs font-light leading-3 opacity-80 xl:pl-1", children: a(i === "html" ? "enter_paste_tailwind_html" : "click_to_add_block") })
|
|
7366
7389
|
] }) : null,
|
|
7367
7390
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
7368
7391
|
Tabs$1,
|
|
7369
7392
|
{
|
|
7370
|
-
onValueChange: (
|
|
7371
|
-
|
|
7393
|
+
onValueChange: (v) => {
|
|
7394
|
+
m(""), l(v);
|
|
7372
7395
|
},
|
|
7373
|
-
value:
|
|
7374
|
-
className: cn("h-max",
|
|
7375
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsxs(TabsList$1, { className: "grid w-full " + (
|
|
7376
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(TabsTrigger, { value: "library", children:
|
|
7377
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(TabsTrigger, { value: "core", children:
|
|
7378
|
-
|
|
7396
|
+
value: i,
|
|
7397
|
+
className: cn("h-max", p ? "" : "hidden"),
|
|
7398
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs(TabsList$1, { className: "grid w-full " + (p ? "grid-cols-3" : "grid-cols-1"), children: [
|
|
7399
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TabsTrigger, { value: "library", children: a("library") }),
|
|
7400
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(TabsTrigger, { value: "core", children: a("blocks") }),
|
|
7401
|
+
p ? /* @__PURE__ */ jsxRuntimeExports.jsx(TabsTrigger, { value: "html", children: a("import") }) : null
|
|
7379
7402
|
] })
|
|
7380
7403
|
}
|
|
7381
7404
|
),
|
|
7382
|
-
|
|
7383
|
-
|
|
7384
|
-
|
|
7405
|
+
i === "core" && /* @__PURE__ */ jsxRuntimeExports.jsx(ScrollArea$1, { className: "-mx-1.5 h-[calc(100vh-156px)] overflow-y-auto", children: /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-2 w-full", children: /* @__PURE__ */ jsxRuntimeExports.jsx(ChaiBuilderBlocks, { parentId: o, groups: x, blocks: b.core }) }) }),
|
|
7406
|
+
i === "library" && /* @__PURE__ */ jsxRuntimeExports.jsx(UILibraries, { parentId: o }),
|
|
7407
|
+
i === "html" && p ? /* @__PURE__ */ jsxRuntimeExports.jsx(ImportHTML$1, { parentId: o }) : null
|
|
7385
7408
|
] });
|
|
7386
7409
|
}, AddBlocksPanel$1 = AddBlocksPanel;
|
|
7387
7410
|
function FaCheck(r) {
|
|
@@ -7668,8 +7691,8 @@ const AIUserPrompt = ({ blockId: r }) => {
|
|
|
7668
7691
|
o(P), i(a), c(""), d(""), h("");
|
|
7669
7692
|
}
|
|
7670
7693
|
}, S = (P) => {
|
|
7671
|
-
const
|
|
7672
|
-
o(
|
|
7694
|
+
const C = a.filter((R, I) => I !== P);
|
|
7695
|
+
o(C), i(C);
|
|
7673
7696
|
}, E = (P) => {
|
|
7674
7697
|
p(P), c(a[P].key), d(a[P].value);
|
|
7675
7698
|
}, w = () => {
|
|
@@ -7736,22 +7759,22 @@ const AIUserPrompt = ({ blockId: r }) => {
|
|
|
7736
7759
|
]
|
|
7737
7760
|
}
|
|
7738
7761
|
),
|
|
7739
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-4 space-y-1 overflow-y-auto", children: a.map((P,
|
|
7762
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "mt-4 space-y-1 overflow-y-auto", children: a.map((P, C) => /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center justify-between rounded bg-muted p-1.5 text-sm", children: [
|
|
7740
7763
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "mr-2 flex flex-col", children: [
|
|
7741
7764
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "truncate font-semibold", children: P.key }),
|
|
7742
7765
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-wrap max-w-[200px] text-muted-foreground", children: P.value.toString() })
|
|
7743
7766
|
] }),
|
|
7744
7767
|
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex-shrink-0", children: [
|
|
7745
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs(Button$1, { variant: "ghost", size: "icon", className: "h-6 w-6", onClick: () => E(
|
|
7768
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(Button$1, { variant: "ghost", size: "icon", className: "h-6 w-6", onClick: () => E(C), children: [
|
|
7746
7769
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Edit2, { className: "h-3 w-3" }),
|
|
7747
7770
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "sr-only", children: "Edit attribute" })
|
|
7748
7771
|
] }),
|
|
7749
|
-
/* @__PURE__ */ jsxRuntimeExports.jsxs(Button$1, { variant: "ghost", size: "icon", className: "h-6 w-6", onClick: () => S(
|
|
7772
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(Button$1, { variant: "ghost", size: "icon", className: "h-6 w-6", onClick: () => S(C), children: [
|
|
7750
7773
|
/* @__PURE__ */ jsxRuntimeExports.jsx(X, { className: "h-3 w-3" }),
|
|
7751
7774
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "sr-only", children: "Remove attribute" })
|
|
7752
7775
|
] })
|
|
7753
7776
|
] })
|
|
7754
|
-
] },
|
|
7777
|
+
] }, C)) })
|
|
7755
7778
|
] });
|
|
7756
7779
|
}), BlockAttributesEditor = React.memo(() => {
|
|
7757
7780
|
const r = useSelectedBlock(), [n, o] = useState$1([]), [a] = useSelectedStylingBlocks(), i = useUpdateBlocksPropsRealtime(), l = useUpdateBlocksProps(), c = `${get$1(a, "0.prop")}_attrs`;
|
|
@@ -7830,15 +7853,15 @@ function useAtomsSnapshot({
|
|
|
7830
7853
|
A && "v" in A && h.set(w, A.v);
|
|
7831
7854
|
const P = (E = o.dev_get_mounted) == null ? void 0 : E.call(o, w);
|
|
7832
7855
|
if (P) {
|
|
7833
|
-
let
|
|
7834
|
-
r || (
|
|
7835
|
-
Array.from(
|
|
7856
|
+
let C = P.t;
|
|
7857
|
+
r || (C = new Set(
|
|
7858
|
+
Array.from(C.values()).filter(
|
|
7836
7859
|
/* NOTE: This just removes private atoms from the dependents list,
|
|
7837
7860
|
instead of hiding them from the dependency chain and showing
|
|
7838
7861
|
the nested dependents of the private atoms. */
|
|
7839
|
-
(
|
|
7862
|
+
(R) => !R.debugPrivate
|
|
7840
7863
|
)
|
|
7841
|
-
)), b.set(w,
|
|
7864
|
+
)), b.set(w, C);
|
|
7842
7865
|
}
|
|
7843
7866
|
}
|
|
7844
7867
|
if (isEqualAtomsValues(u, h) && isEqualAtomsDependents(d, b))
|
|
@@ -8053,7 +8076,7 @@ function compile(r) {
|
|
|
8053
8076
|
return dealloc(parse("", null, null, null, [""], r = alloc(r), 0, [0], r));
|
|
8054
8077
|
}
|
|
8055
8078
|
function parse(r, n, o, a, i, l, c, u, d) {
|
|
8056
|
-
for (var m = 0, p = 0, g = c, h = 0, b = 0, x = 0, v = 1, S = 1, E = 1, w = 0, A = "", P = i,
|
|
8079
|
+
for (var m = 0, p = 0, g = c, h = 0, b = 0, x = 0, v = 1, S = 1, E = 1, w = 0, A = "", P = i, C = l, R = a, I = A; S; )
|
|
8057
8080
|
switch (x = w, w = next()) {
|
|
8058
8081
|
case 40:
|
|
8059
8082
|
if (x != 108 && charat(I, g - 1) == 58) {
|
|
@@ -8099,19 +8122,19 @@ function parse(r, n, o, a, i, l, c, u, d) {
|
|
|
8099
8122
|
case 59:
|
|
8100
8123
|
I += ";";
|
|
8101
8124
|
default:
|
|
8102
|
-
if (append(
|
|
8125
|
+
if (append(R = ruleset(I, n, o, m, p, i, u, A, P = [], C = [], g), l), w === 123)
|
|
8103
8126
|
if (p === 0)
|
|
8104
|
-
parse(I, n,
|
|
8127
|
+
parse(I, n, R, R, P, l, g, u, C);
|
|
8105
8128
|
else
|
|
8106
8129
|
switch (h === 99 && charat(I, 3) === 110 ? 100 : h) {
|
|
8107
8130
|
case 100:
|
|
8108
8131
|
case 108:
|
|
8109
8132
|
case 109:
|
|
8110
8133
|
case 115:
|
|
8111
|
-
parse(r,
|
|
8134
|
+
parse(r, R, R, a && append(ruleset(r, R, R, 0, 0, i, u, A, i, P = [], g), C), i, C, g, u, a ? P : C);
|
|
8112
8135
|
break;
|
|
8113
8136
|
default:
|
|
8114
|
-
parse(I,
|
|
8137
|
+
parse(I, R, R, R, [""], C, 0, u, C);
|
|
8115
8138
|
}
|
|
8116
8139
|
}
|
|
8117
8140
|
m = p = b = 0, v = E = 1, A = I = "", g = c;
|
|
@@ -8475,8 +8498,8 @@ If multiple caches share the same key they might "fight" for each other's style
|
|
|
8475
8498
|
};
|
|
8476
8499
|
d = function(S, E, w, A) {
|
|
8477
8500
|
p = w, process.env.NODE_ENV !== "production" && E.map !== void 0 && (p = {
|
|
8478
|
-
insert: function(
|
|
8479
|
-
w.insert(
|
|
8501
|
+
insert: function(C) {
|
|
8502
|
+
w.insert(C + E.map);
|
|
8480
8503
|
}
|
|
8481
8504
|
}), b(S ? S + "{" + E.styles + "}" : E.styles), A && (x.inserted[E.name] = !0);
|
|
8482
8505
|
};
|
|
@@ -8523,65 +8546,65 @@ function requireReactIs_production_min() {
|
|
|
8523
8546
|
return reactIs_production_min;
|
|
8524
8547
|
hasRequiredReactIs_production_min = 1;
|
|
8525
8548
|
var r = typeof Symbol == "function" && Symbol.for, n = r ? Symbol.for("react.element") : 60103, o = r ? Symbol.for("react.portal") : 60106, a = r ? Symbol.for("react.fragment") : 60107, i = r ? Symbol.for("react.strict_mode") : 60108, l = r ? Symbol.for("react.profiler") : 60114, c = r ? Symbol.for("react.provider") : 60109, u = r ? Symbol.for("react.context") : 60110, d = r ? Symbol.for("react.async_mode") : 60111, m = r ? Symbol.for("react.concurrent_mode") : 60111, p = r ? Symbol.for("react.forward_ref") : 60112, g = r ? Symbol.for("react.suspense") : 60113, h = r ? Symbol.for("react.suspense_list") : 60120, b = r ? Symbol.for("react.memo") : 60115, x = r ? Symbol.for("react.lazy") : 60116, v = r ? Symbol.for("react.block") : 60121, S = r ? Symbol.for("react.fundamental") : 60117, E = r ? Symbol.for("react.responder") : 60118, w = r ? Symbol.for("react.scope") : 60119;
|
|
8526
|
-
function A(
|
|
8527
|
-
if (typeof
|
|
8528
|
-
var
|
|
8529
|
-
switch (
|
|
8549
|
+
function A(C) {
|
|
8550
|
+
if (typeof C == "object" && C !== null) {
|
|
8551
|
+
var R = C.$$typeof;
|
|
8552
|
+
switch (R) {
|
|
8530
8553
|
case n:
|
|
8531
|
-
switch (
|
|
8554
|
+
switch (C = C.type, C) {
|
|
8532
8555
|
case d:
|
|
8533
8556
|
case m:
|
|
8534
8557
|
case a:
|
|
8535
8558
|
case l:
|
|
8536
8559
|
case i:
|
|
8537
8560
|
case g:
|
|
8538
|
-
return
|
|
8561
|
+
return C;
|
|
8539
8562
|
default:
|
|
8540
|
-
switch (
|
|
8563
|
+
switch (C = C && C.$$typeof, C) {
|
|
8541
8564
|
case u:
|
|
8542
8565
|
case p:
|
|
8543
8566
|
case x:
|
|
8544
8567
|
case b:
|
|
8545
8568
|
case c:
|
|
8546
|
-
return R;
|
|
8547
|
-
default:
|
|
8548
8569
|
return C;
|
|
8570
|
+
default:
|
|
8571
|
+
return R;
|
|
8549
8572
|
}
|
|
8550
8573
|
}
|
|
8551
8574
|
case o:
|
|
8552
|
-
return
|
|
8553
|
-
}
|
|
8554
|
-
}
|
|
8555
|
-
}
|
|
8556
|
-
function P(
|
|
8557
|
-
return A(
|
|
8558
|
-
}
|
|
8559
|
-
return reactIs_production_min.AsyncMode = d, reactIs_production_min.ConcurrentMode = m, reactIs_production_min.ContextConsumer = u, reactIs_production_min.ContextProvider = c, reactIs_production_min.Element = n, reactIs_production_min.ForwardRef = p, reactIs_production_min.Fragment = a, reactIs_production_min.Lazy = x, reactIs_production_min.Memo = b, reactIs_production_min.Portal = o, reactIs_production_min.Profiler = l, reactIs_production_min.StrictMode = i, reactIs_production_min.Suspense = g, reactIs_production_min.isAsyncMode = function(
|
|
8560
|
-
return P(
|
|
8561
|
-
}, reactIs_production_min.isConcurrentMode = P, reactIs_production_min.isContextConsumer = function(
|
|
8562
|
-
return A(
|
|
8563
|
-
}, reactIs_production_min.isContextProvider = function(
|
|
8564
|
-
return A(
|
|
8565
|
-
}, reactIs_production_min.isElement = function(
|
|
8566
|
-
return typeof
|
|
8567
|
-
}, reactIs_production_min.isForwardRef = function(
|
|
8568
|
-
return A(
|
|
8569
|
-
}, reactIs_production_min.isFragment = function(
|
|
8570
|
-
return A(
|
|
8571
|
-
}, reactIs_production_min.isLazy = function(
|
|
8572
|
-
return A(
|
|
8573
|
-
}, reactIs_production_min.isMemo = function(
|
|
8574
|
-
return A(
|
|
8575
|
-
}, reactIs_production_min.isPortal = function(
|
|
8576
|
-
return A(
|
|
8577
|
-
}, reactIs_production_min.isProfiler = function(
|
|
8578
|
-
return A(
|
|
8579
|
-
}, reactIs_production_min.isStrictMode = function(
|
|
8580
|
-
return A(
|
|
8581
|
-
}, reactIs_production_min.isSuspense = function(
|
|
8582
|
-
return A(
|
|
8583
|
-
}, reactIs_production_min.isValidElementType = function(
|
|
8584
|
-
return typeof
|
|
8575
|
+
return R;
|
|
8576
|
+
}
|
|
8577
|
+
}
|
|
8578
|
+
}
|
|
8579
|
+
function P(C) {
|
|
8580
|
+
return A(C) === m;
|
|
8581
|
+
}
|
|
8582
|
+
return reactIs_production_min.AsyncMode = d, reactIs_production_min.ConcurrentMode = m, reactIs_production_min.ContextConsumer = u, reactIs_production_min.ContextProvider = c, reactIs_production_min.Element = n, reactIs_production_min.ForwardRef = p, reactIs_production_min.Fragment = a, reactIs_production_min.Lazy = x, reactIs_production_min.Memo = b, reactIs_production_min.Portal = o, reactIs_production_min.Profiler = l, reactIs_production_min.StrictMode = i, reactIs_production_min.Suspense = g, reactIs_production_min.isAsyncMode = function(C) {
|
|
8583
|
+
return P(C) || A(C) === d;
|
|
8584
|
+
}, reactIs_production_min.isConcurrentMode = P, reactIs_production_min.isContextConsumer = function(C) {
|
|
8585
|
+
return A(C) === u;
|
|
8586
|
+
}, reactIs_production_min.isContextProvider = function(C) {
|
|
8587
|
+
return A(C) === c;
|
|
8588
|
+
}, reactIs_production_min.isElement = function(C) {
|
|
8589
|
+
return typeof C == "object" && C !== null && C.$$typeof === n;
|
|
8590
|
+
}, reactIs_production_min.isForwardRef = function(C) {
|
|
8591
|
+
return A(C) === p;
|
|
8592
|
+
}, reactIs_production_min.isFragment = function(C) {
|
|
8593
|
+
return A(C) === a;
|
|
8594
|
+
}, reactIs_production_min.isLazy = function(C) {
|
|
8595
|
+
return A(C) === x;
|
|
8596
|
+
}, reactIs_production_min.isMemo = function(C) {
|
|
8597
|
+
return A(C) === b;
|
|
8598
|
+
}, reactIs_production_min.isPortal = function(C) {
|
|
8599
|
+
return A(C) === o;
|
|
8600
|
+
}, reactIs_production_min.isProfiler = function(C) {
|
|
8601
|
+
return A(C) === l;
|
|
8602
|
+
}, reactIs_production_min.isStrictMode = function(C) {
|
|
8603
|
+
return A(C) === i;
|
|
8604
|
+
}, reactIs_production_min.isSuspense = function(C) {
|
|
8605
|
+
return A(C) === g;
|
|
8606
|
+
}, reactIs_production_min.isValidElementType = function(C) {
|
|
8607
|
+
return typeof C == "string" || typeof C == "function" || C === a || C === m || C === l || C === i || C === g || C === h || typeof C == "object" && C !== null && (C.$$typeof === x || C.$$typeof === b || C.$$typeof === c || C.$$typeof === u || C.$$typeof === p || C.$$typeof === S || C.$$typeof === E || C.$$typeof === w || C.$$typeof === v);
|
|
8585
8608
|
}, reactIs_production_min.typeOf = A, reactIs_production_min;
|
|
8586
8609
|
}
|
|
8587
8610
|
var reactIs_development = {};
|
|
@@ -8633,9 +8656,9 @@ function requireReactIs_development() {
|
|
|
8633
8656
|
}
|
|
8634
8657
|
}
|
|
8635
8658
|
}
|
|
8636
|
-
var
|
|
8659
|
+
var C = d, R = m, I = u, j = c, k = n, O = p, T = a, B = x, L = b, D = o, W = l, J = i, F = g, V = !1;
|
|
8637
8660
|
function q(K) {
|
|
8638
|
-
return
|
|
8661
|
+
return V || (V = !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.")), G(K) || P(K) === d;
|
|
8639
8662
|
}
|
|
8640
8663
|
function G(K) {
|
|
8641
8664
|
return P(K) === m;
|
|
@@ -8673,7 +8696,7 @@ function requireReactIs_development() {
|
|
|
8673
8696
|
function se(K) {
|
|
8674
8697
|
return P(K) === g;
|
|
8675
8698
|
}
|
|
8676
|
-
reactIs_development.AsyncMode =
|
|
8699
|
+
reactIs_development.AsyncMode = C, reactIs_development.ConcurrentMode = R, reactIs_development.ContextConsumer = I, reactIs_development.ContextProvider = j, reactIs_development.Element = k, reactIs_development.ForwardRef = O, reactIs_development.Fragment = T, reactIs_development.Lazy = B, reactIs_development.Memo = L, reactIs_development.Portal = D, reactIs_development.Profiler = W, reactIs_development.StrictMode = J, reactIs_development.Suspense = F, reactIs_development.isAsyncMode = q, reactIs_development.isConcurrentMode = G, reactIs_development.isContextConsumer = ee, reactIs_development.isContextProvider = z, reactIs_development.isElement = U, reactIs_development.isForwardRef = te, reactIs_development.isFragment = _, reactIs_development.isLazy = Q, reactIs_development.isMemo = ne, reactIs_development.isPortal = re, reactIs_development.isProfiler = $, reactIs_development.isStrictMode = ae, reactIs_development.isSuspense = se, reactIs_development.isValidElementType = A, reactIs_development.typeOf = P;
|
|
8677
8700
|
}()), reactIs_development;
|
|
8678
8701
|
}
|
|
8679
8702
|
process.env.NODE_ENV === "production" ? reactIs$1.exports = requireReactIs_production_min() : reactIs$1.exports = requireReactIs_development();
|
|
@@ -10715,9 +10738,9 @@ function useMove(r, n, o = "ltr") {
|
|
|
10715
10738
|
a.current.style.userSelect = "none";
|
|
10716
10739
|
const P = a.current.getBoundingClientRect();
|
|
10717
10740
|
if (P.width && P.height) {
|
|
10718
|
-
const
|
|
10741
|
+
const C = clamp$1((w - P.left) / P.width, 0, 1);
|
|
10719
10742
|
r({
|
|
10720
|
-
x: o === "ltr" ?
|
|
10743
|
+
x: o === "ltr" ? C : 1 - C,
|
|
10721
10744
|
y: clamp$1((A - P.top) / P.height, 0, 1)
|
|
10722
10745
|
});
|
|
10723
10746
|
}
|
|
@@ -10845,7 +10868,7 @@ function useScrollIntoView({
|
|
|
10845
10868
|
}) - (p.current ? 0 : w);
|
|
10846
10869
|
function P() {
|
|
10847
10870
|
d.current === 0 && (d.current = performance.now());
|
|
10848
|
-
const
|
|
10871
|
+
const R = performance.now() - d.current, I = h || r === 0 ? 1 : R / r, j = w + A * a(I);
|
|
10849
10872
|
setScrollParam({
|
|
10850
10873
|
parent: p.current,
|
|
10851
10874
|
axis: n,
|
|
@@ -10909,20 +10932,20 @@ function extractSystemStyles(r) {
|
|
|
10909
10932
|
opacity: w,
|
|
10910
10933
|
ff: A,
|
|
10911
10934
|
fz: P,
|
|
10912
|
-
fw:
|
|
10913
|
-
lts:
|
|
10935
|
+
fw: C,
|
|
10936
|
+
lts: R,
|
|
10914
10937
|
ta: I,
|
|
10915
10938
|
lh: j,
|
|
10916
10939
|
fs: k,
|
|
10917
10940
|
tt: O,
|
|
10918
10941
|
td: T,
|
|
10919
|
-
w:
|
|
10920
|
-
miw:
|
|
10942
|
+
w: B,
|
|
10943
|
+
miw: L,
|
|
10921
10944
|
maw: D,
|
|
10922
10945
|
h: W,
|
|
10923
10946
|
mih: J,
|
|
10924
10947
|
mah: F,
|
|
10925
|
-
bgsz:
|
|
10948
|
+
bgsz: V,
|
|
10926
10949
|
bgp: q,
|
|
10927
10950
|
bgr: G,
|
|
10928
10951
|
bga: ee,
|
|
@@ -10998,20 +11021,20 @@ function extractSystemStyles(r) {
|
|
|
10998
11021
|
opacity: w,
|
|
10999
11022
|
ff: A,
|
|
11000
11023
|
fz: P,
|
|
11001
|
-
fw:
|
|
11002
|
-
lts:
|
|
11024
|
+
fw: C,
|
|
11025
|
+
lts: R,
|
|
11003
11026
|
ta: I,
|
|
11004
11027
|
lh: j,
|
|
11005
11028
|
fs: k,
|
|
11006
11029
|
tt: O,
|
|
11007
11030
|
td: T,
|
|
11008
|
-
w:
|
|
11009
|
-
miw:
|
|
11031
|
+
w: B,
|
|
11032
|
+
miw: L,
|
|
11010
11033
|
maw: D,
|
|
11011
11034
|
h: W,
|
|
11012
11035
|
mih: J,
|
|
11013
11036
|
mah: F,
|
|
11014
|
-
bgsz:
|
|
11037
|
+
bgsz: V,
|
|
11015
11038
|
bgp: q,
|
|
11016
11039
|
bgr: G,
|
|
11017
11040
|
bga: ee,
|
|
@@ -12066,8 +12089,8 @@ const defaultProps$A = {
|
|
|
12066
12089
|
classNames: w,
|
|
12067
12090
|
styles: A,
|
|
12068
12091
|
unstyled: P,
|
|
12069
|
-
span:
|
|
12070
|
-
__staticSelector:
|
|
12092
|
+
span: C,
|
|
12093
|
+
__staticSelector: R
|
|
12071
12094
|
} = o, I = __objRest$L(o, [
|
|
12072
12095
|
"className",
|
|
12073
12096
|
"size",
|
|
@@ -12102,11 +12125,11 @@ const defaultProps$A = {
|
|
|
12102
12125
|
transform: c,
|
|
12103
12126
|
align: d,
|
|
12104
12127
|
gradient: h
|
|
12105
|
-
}, { unstyled: P, name:
|
|
12128
|
+
}, { unstyled: P, name: R || "Text", variant: m, size: i });
|
|
12106
12129
|
return /* @__PURE__ */ React__default.createElement(Box, __spreadValues$14({
|
|
12107
12130
|
ref: n,
|
|
12108
12131
|
className: k(j.root, { [j.gradient]: m === "gradient" }, a),
|
|
12109
|
-
component:
|
|
12132
|
+
component: C ? "span" : "div"
|
|
12110
12133
|
}, I));
|
|
12111
12134
|
});
|
|
12112
12135
|
_Text.displayName = "@mantine/core/Text";
|
|
@@ -12371,7 +12394,7 @@ function SelectItems({
|
|
|
12371
12394
|
size: g
|
|
12372
12395
|
}), w = [], A = [];
|
|
12373
12396
|
let P = null;
|
|
12374
|
-
const
|
|
12397
|
+
const C = (I, j) => {
|
|
12375
12398
|
const k = typeof i == "function" ? i(I.value) : !1;
|
|
12376
12399
|
return /* @__PURE__ */ React__default.createElement(p, __spreadValues$$({
|
|
12377
12400
|
key: I.value,
|
|
@@ -12395,15 +12418,15 @@ function SelectItems({
|
|
|
12395
12418
|
variant: S
|
|
12396
12419
|
}, I));
|
|
12397
12420
|
};
|
|
12398
|
-
let
|
|
12421
|
+
let R = null;
|
|
12399
12422
|
if (r.forEach((I, j) => {
|
|
12400
|
-
I.creatable ? P = j : I.group ? (
|
|
12423
|
+
I.creatable ? P = j : I.group ? (R !== I.group && (R = I.group, A.push(/* @__PURE__ */ React__default.createElement("div", {
|
|
12401
12424
|
className: E.separator,
|
|
12402
12425
|
key: `__mantine-divider-${j}`
|
|
12403
12426
|
}, /* @__PURE__ */ React__default.createElement(Divider, {
|
|
12404
12427
|
classNames: { label: E.separatorLabel },
|
|
12405
12428
|
label: I.group
|
|
12406
|
-
})))), A.push(
|
|
12429
|
+
})))), A.push(C(I, j))) : w.push(C(I, j));
|
|
12407
12430
|
}), b) {
|
|
12408
12431
|
const I = r[P];
|
|
12409
12432
|
w.push(/* @__PURE__ */ React__default.createElement("div", {
|
|
@@ -12567,7 +12590,7 @@ const defaultProps$x = {
|
|
|
12567
12590
|
"unstyled",
|
|
12568
12591
|
"variant",
|
|
12569
12592
|
"viewportProps"
|
|
12570
|
-
]), [w, A] = useState$1(!1), P = useMantineTheme(), { classes:
|
|
12593
|
+
]), [w, A] = useState$1(!1), P = useMantineTheme(), { classes: C, cx: R } = useStyles$D({ scrollbarSize: u, offsetScrollbars: g, scrollbarHovered: w, hidden: m === "never" }, { name: "ScrollArea", classNames: l, styles: c, unstyled: x, variant: v });
|
|
12571
12594
|
return /* @__PURE__ */ React__default.createElement(ScrollAreaPrimitive.Root, {
|
|
12572
12595
|
type: m === "never" ? "always" : m,
|
|
12573
12596
|
scrollHideDelay: d,
|
|
@@ -12575,9 +12598,9 @@ const defaultProps$x = {
|
|
|
12575
12598
|
ref: n,
|
|
12576
12599
|
asChild: !0
|
|
12577
12600
|
}, /* @__PURE__ */ React__default.createElement(Box, __spreadValues$Z({
|
|
12578
|
-
className: C
|
|
12601
|
+
className: R(C.root, i)
|
|
12579
12602
|
}, E), /* @__PURE__ */ React__default.createElement(ScrollAreaPrimitive.Viewport, __spreadProps$F(__spreadValues$Z({}, S), {
|
|
12580
|
-
className:
|
|
12603
|
+
className: C.viewport,
|
|
12581
12604
|
ref: h,
|
|
12582
12605
|
onScroll: typeof b == "function" ? ({ currentTarget: I }) => b({
|
|
12583
12606
|
x: I.scrollLeft,
|
|
@@ -12585,22 +12608,22 @@ const defaultProps$x = {
|
|
|
12585
12608
|
}) : void 0
|
|
12586
12609
|
}), a), /* @__PURE__ */ React__default.createElement(ScrollAreaPrimitive.Scrollbar, {
|
|
12587
12610
|
orientation: "horizontal",
|
|
12588
|
-
className:
|
|
12611
|
+
className: C.scrollbar,
|
|
12589
12612
|
forceMount: !0,
|
|
12590
12613
|
onMouseEnter: () => A(!0),
|
|
12591
12614
|
onMouseLeave: () => A(!1)
|
|
12592
12615
|
}, /* @__PURE__ */ React__default.createElement(ScrollAreaPrimitive.Thumb, {
|
|
12593
|
-
className:
|
|
12616
|
+
className: C.thumb
|
|
12594
12617
|
})), /* @__PURE__ */ React__default.createElement(ScrollAreaPrimitive.Scrollbar, {
|
|
12595
12618
|
orientation: "vertical",
|
|
12596
|
-
className:
|
|
12619
|
+
className: C.scrollbar,
|
|
12597
12620
|
forceMount: !0,
|
|
12598
12621
|
onMouseEnter: () => A(!0),
|
|
12599
12622
|
onMouseLeave: () => A(!1)
|
|
12600
12623
|
}, /* @__PURE__ */ React__default.createElement(ScrollAreaPrimitive.Thumb, {
|
|
12601
|
-
className:
|
|
12624
|
+
className: C.thumb
|
|
12602
12625
|
})), /* @__PURE__ */ React__default.createElement(ScrollAreaPrimitive.Corner, {
|
|
12603
|
-
className:
|
|
12626
|
+
className: C.corner
|
|
12604
12627
|
})));
|
|
12605
12628
|
}), ScrollAreaAutosize = forwardRef$1((r, n) => {
|
|
12606
12629
|
const o = useComponentDefaultProps("ScrollAreaAutosize", defaultProps$x, r), {
|
|
@@ -12797,7 +12820,7 @@ const useHover = function(r, n) {
|
|
|
12797
12820
|
floating: b
|
|
12798
12821
|
},
|
|
12799
12822
|
refs: x
|
|
12800
|
-
} = r, v = useFloatingTree(), S = useFloatingParentNodeId(), E = useLatestRef(i), w = useLatestRef(a), A = React.useRef(), P = React.useRef(),
|
|
12823
|
+
} = r, v = useFloatingTree(), S = useFloatingParentNodeId(), E = useLatestRef(i), w = useLatestRef(a), A = React.useRef(), P = React.useRef(), C = React.useRef(), R = React.useRef(), I = React.useRef(!0), j = React.useRef(!1), k = React.useRef(() => {
|
|
12801
12824
|
}), O = React.useCallback(() => {
|
|
12802
12825
|
var D;
|
|
12803
12826
|
const W = (D = p.current.openEvent) == null ? void 0 : D.type;
|
|
@@ -12807,7 +12830,7 @@ const useHover = function(r, n) {
|
|
|
12807
12830
|
if (!o)
|
|
12808
12831
|
return;
|
|
12809
12832
|
function D() {
|
|
12810
|
-
clearTimeout(P.current), clearTimeout(
|
|
12833
|
+
clearTimeout(P.current), clearTimeout(R.current), I.current = !0;
|
|
12811
12834
|
}
|
|
12812
12835
|
return g.on("dismiss", D), () => {
|
|
12813
12836
|
g.off("dismiss", D);
|
|
@@ -12826,10 +12849,10 @@ const useHover = function(r, n) {
|
|
|
12826
12849
|
const T = React.useCallback(function(D) {
|
|
12827
12850
|
D === void 0 && (D = !0);
|
|
12828
12851
|
const W = getDelay(w.current, "close", A.current);
|
|
12829
|
-
W && !
|
|
12830
|
-
}, [w, m]),
|
|
12831
|
-
k.current(),
|
|
12832
|
-
}, []),
|
|
12852
|
+
W && !C.current ? (clearTimeout(P.current), P.current = setTimeout(() => m(!1), W)) : D && (clearTimeout(P.current), m(!1));
|
|
12853
|
+
}, [w, m]), B = React.useCallback(() => {
|
|
12854
|
+
k.current(), C.current = void 0;
|
|
12855
|
+
}, []), L = React.useCallback(() => {
|
|
12833
12856
|
if (j.current) {
|
|
12834
12857
|
const D = getDocument(x.floating.current).body;
|
|
12835
12858
|
D.style.pointerEvents = "", D.removeAttribute(safePolygonIdentifier), j.current = !1;
|
|
@@ -12841,31 +12864,31 @@ const useHover = function(r, n) {
|
|
|
12841
12864
|
function D() {
|
|
12842
12865
|
return p.current.openEvent ? ["click", "mousedown"].includes(p.current.openEvent.type) : !1;
|
|
12843
12866
|
}
|
|
12844
|
-
function W(
|
|
12867
|
+
function W(V) {
|
|
12845
12868
|
if (clearTimeout(P.current), I.current = !1, l && !isMouseLikePointerType(A.current) || c > 0 && getDelay(w.current, "open") === 0)
|
|
12846
12869
|
return;
|
|
12847
|
-
p.current.openEvent =
|
|
12870
|
+
p.current.openEvent = V;
|
|
12848
12871
|
const q = getDelay(w.current, "open", A.current);
|
|
12849
12872
|
q ? P.current = setTimeout(() => {
|
|
12850
12873
|
m(!0);
|
|
12851
12874
|
}, q) : m(!0);
|
|
12852
12875
|
}
|
|
12853
|
-
function J(
|
|
12876
|
+
function J(V) {
|
|
12854
12877
|
if (D())
|
|
12855
12878
|
return;
|
|
12856
12879
|
k.current();
|
|
12857
12880
|
const q = getDocument(b);
|
|
12858
|
-
if (clearTimeout(
|
|
12859
|
-
d || clearTimeout(P.current),
|
|
12881
|
+
if (clearTimeout(R.current), E.current) {
|
|
12882
|
+
d || clearTimeout(P.current), C.current = E.current({
|
|
12860
12883
|
...r,
|
|
12861
12884
|
tree: v,
|
|
12862
|
-
x:
|
|
12863
|
-
y:
|
|
12885
|
+
x: V.clientX,
|
|
12886
|
+
y: V.clientY,
|
|
12864
12887
|
onClose() {
|
|
12865
|
-
|
|
12888
|
+
L(), B(), T();
|
|
12866
12889
|
}
|
|
12867
12890
|
});
|
|
12868
|
-
const G =
|
|
12891
|
+
const G = C.current;
|
|
12869
12892
|
q.addEventListener("mousemove", G), k.current = () => {
|
|
12870
12893
|
q.removeEventListener("mousemove", G);
|
|
12871
12894
|
};
|
|
@@ -12873,42 +12896,42 @@ const useHover = function(r, n) {
|
|
|
12873
12896
|
}
|
|
12874
12897
|
T();
|
|
12875
12898
|
}
|
|
12876
|
-
function F(
|
|
12899
|
+
function F(V) {
|
|
12877
12900
|
D() || E.current == null || E.current({
|
|
12878
12901
|
...r,
|
|
12879
12902
|
tree: v,
|
|
12880
|
-
x:
|
|
12881
|
-
y:
|
|
12903
|
+
x: V.clientX,
|
|
12904
|
+
y: V.clientY,
|
|
12882
12905
|
onClose() {
|
|
12883
|
-
|
|
12906
|
+
L(), B(), T();
|
|
12884
12907
|
}
|
|
12885
|
-
})(
|
|
12908
|
+
})(V);
|
|
12886
12909
|
}
|
|
12887
12910
|
if (isElement(h)) {
|
|
12888
|
-
const
|
|
12889
|
-
return d &&
|
|
12911
|
+
const V = h;
|
|
12912
|
+
return d && V.addEventListener("mouseleave", F), b == null || b.addEventListener("mouseleave", F), u && V.addEventListener("mousemove", W, {
|
|
12890
12913
|
once: !0
|
|
12891
|
-
}),
|
|
12892
|
-
d &&
|
|
12914
|
+
}), V.addEventListener("mouseenter", W), V.addEventListener("mouseleave", J), () => {
|
|
12915
|
+
d && V.removeEventListener("mouseleave", F), b == null || b.removeEventListener("mouseleave", F), u && V.removeEventListener("mousemove", W), V.removeEventListener("mouseenter", W), V.removeEventListener("mouseleave", J);
|
|
12893
12916
|
};
|
|
12894
12917
|
}
|
|
12895
|
-
}, [h, b, o, r, l, c, u, T,
|
|
12918
|
+
}, [h, b, o, r, l, c, u, T, B, L, m, d, v, w, E, p]), index(() => {
|
|
12896
12919
|
var D;
|
|
12897
12920
|
if (o && d && (D = E.current) != null && D.__options.blockPointerEvents && O()) {
|
|
12898
12921
|
const F = getDocument(b).body;
|
|
12899
12922
|
if (F.setAttribute(safePolygonIdentifier, ""), F.style.pointerEvents = "none", j.current = !0, isElement(h) && b) {
|
|
12900
12923
|
var W, J;
|
|
12901
|
-
const
|
|
12902
|
-
return q && (q.style.pointerEvents = ""),
|
|
12903
|
-
|
|
12924
|
+
const V = h, q = v == null || (W = v.nodesRef.current.find((G) => G.id === S)) == null || (J = W.context) == null ? void 0 : J.elements.floating;
|
|
12925
|
+
return q && (q.style.pointerEvents = ""), V.style.pointerEvents = "auto", b.style.pointerEvents = "auto", () => {
|
|
12926
|
+
V.style.pointerEvents = "", b.style.pointerEvents = "";
|
|
12904
12927
|
};
|
|
12905
12928
|
}
|
|
12906
12929
|
}
|
|
12907
12930
|
}, [o, d, S, b, h, v, E, p, O]), index(() => {
|
|
12908
|
-
d || (A.current = void 0,
|
|
12909
|
-
}, [d,
|
|
12910
|
-
|
|
12911
|
-
}, [o,
|
|
12931
|
+
d || (A.current = void 0, B(), L());
|
|
12932
|
+
}, [d, B, L]), React.useEffect(() => () => {
|
|
12933
|
+
B(), clearTimeout(P.current), clearTimeout(R.current), L();
|
|
12934
|
+
}, [o, B, L]), React.useMemo(() => {
|
|
12912
12935
|
if (!o)
|
|
12913
12936
|
return {};
|
|
12914
12937
|
function D(W) {
|
|
@@ -12919,7 +12942,7 @@ const useHover = function(r, n) {
|
|
|
12919
12942
|
onPointerDown: D,
|
|
12920
12943
|
onPointerEnter: D,
|
|
12921
12944
|
onMouseMove() {
|
|
12922
|
-
d || c === 0 || (clearTimeout(
|
|
12945
|
+
d || c === 0 || (clearTimeout(R.current), R.current = setTimeout(() => {
|
|
12923
12946
|
I.current || m(!0);
|
|
12924
12947
|
}, c));
|
|
12925
12948
|
}
|
|
@@ -13122,7 +13145,7 @@ const bubbleHandlerKeys = {
|
|
|
13122
13145
|
ancestorScroll: S = !1,
|
|
13123
13146
|
bubbles: E = !0
|
|
13124
13147
|
} = n === void 0 ? {} : n;
|
|
13125
|
-
const w = useFloatingTree(), A = useFloatingParentNodeId() != null, P = useEvent(typeof h == "function" ? h : () => !1),
|
|
13148
|
+
const w = useFloatingTree(), A = useFloatingParentNodeId() != null, P = useEvent(typeof h == "function" ? h : () => !1), C = typeof h == "function" ? P : h, R = React.useRef(!1), {
|
|
13126
13149
|
escapeKeyBubbles: I,
|
|
13127
13150
|
outsidePressBubbles: j
|
|
13128
13151
|
} = normalizeBubblesProp(E);
|
|
@@ -13136,8 +13159,8 @@ const bubbleHandlerKeys = {
|
|
|
13136
13159
|
if (W.length > 0) {
|
|
13137
13160
|
let J = !0;
|
|
13138
13161
|
if (W.forEach((F) => {
|
|
13139
|
-
var
|
|
13140
|
-
if ((
|
|
13162
|
+
var V;
|
|
13163
|
+
if ((V = F.context) != null && V.open && !F.context.dataRef.current.__escapeKeyBubbles) {
|
|
13141
13164
|
J = !1;
|
|
13142
13165
|
return;
|
|
13143
13166
|
}
|
|
@@ -13155,8 +13178,8 @@ const bubbleHandlerKeys = {
|
|
|
13155
13178
|
}
|
|
13156
13179
|
}
|
|
13157
13180
|
function O(D) {
|
|
13158
|
-
const W =
|
|
13159
|
-
if (
|
|
13181
|
+
const W = R.current;
|
|
13182
|
+
if (R.current = !1, W || typeof C == "function" && !C(D))
|
|
13160
13183
|
return;
|
|
13161
13184
|
const J = getTarget(D);
|
|
13162
13185
|
if (isHTMLElement(J) && d) {
|
|
@@ -13171,10 +13194,10 @@ const bubbleHandlerKeys = {
|
|
|
13171
13194
|
});
|
|
13172
13195
|
if (isEventTargetWithin(D, d) || isEventTargetWithin(D, u) || F)
|
|
13173
13196
|
return;
|
|
13174
|
-
const
|
|
13175
|
-
if (
|
|
13197
|
+
const V = w ? getChildren(w.nodesRef.current, l) : [];
|
|
13198
|
+
if (V.length > 0) {
|
|
13176
13199
|
let q = !0;
|
|
13177
|
-
if (
|
|
13200
|
+
if (V.forEach((G) => {
|
|
13178
13201
|
var ee;
|
|
13179
13202
|
if ((ee = G.context) != null && ee.open && !G.context.dataRef.current.__outsidePressBubbles) {
|
|
13180
13203
|
q = !1;
|
|
@@ -13195,24 +13218,24 @@ const bubbleHandlerKeys = {
|
|
|
13195
13218
|
function T() {
|
|
13196
13219
|
a(!1);
|
|
13197
13220
|
}
|
|
13198
|
-
const
|
|
13199
|
-
g &&
|
|
13200
|
-
let
|
|
13201
|
-
return S && (isElement(u) && (
|
|
13221
|
+
const B = getDocument(d);
|
|
13222
|
+
g && B.addEventListener("keydown", k), C && B.addEventListener(b, O);
|
|
13223
|
+
let L = [];
|
|
13224
|
+
return S && (isElement(u) && (L = getOverflowAncestors(u)), isElement(d) && (L = L.concat(getOverflowAncestors(d))), !isElement(c) && c && c.contextElement && (L = L.concat(getOverflowAncestors(c.contextElement)))), L = L.filter((D) => {
|
|
13202
13225
|
var W;
|
|
13203
|
-
return D !== ((W =
|
|
13204
|
-
}),
|
|
13226
|
+
return D !== ((W = B.defaultView) == null ? void 0 : W.visualViewport);
|
|
13227
|
+
}), L.forEach((D) => {
|
|
13205
13228
|
D.addEventListener("scroll", T, {
|
|
13206
13229
|
passive: !0
|
|
13207
13230
|
});
|
|
13208
13231
|
}), () => {
|
|
13209
|
-
g &&
|
|
13232
|
+
g && B.removeEventListener("keydown", k), C && B.removeEventListener(b, O), L.forEach((D) => {
|
|
13210
13233
|
D.removeEventListener("scroll", T);
|
|
13211
13234
|
});
|
|
13212
13235
|
};
|
|
13213
|
-
}, [m, d, u, c, g,
|
|
13214
|
-
|
|
13215
|
-
}, [
|
|
13236
|
+
}, [m, d, u, c, g, C, b, i, w, l, o, a, S, p, I, j, A]), React.useEffect(() => {
|
|
13237
|
+
R.current = !1;
|
|
13238
|
+
}, [C, b]), React.useMemo(() => p ? {
|
|
13216
13239
|
reference: {
|
|
13217
13240
|
[bubbleHandlerKeys[v]]: () => {
|
|
13218
13241
|
x && (i.emit("dismiss", {
|
|
@@ -13225,7 +13248,7 @@ const bubbleHandlerKeys = {
|
|
|
13225
13248
|
},
|
|
13226
13249
|
floating: {
|
|
13227
13250
|
[captureHandlerKeys[b]]: () => {
|
|
13228
|
-
|
|
13251
|
+
R.current = !0;
|
|
13229
13252
|
}
|
|
13230
13253
|
}
|
|
13231
13254
|
} : {}, [p, i, x, b, v, a]);
|
|
@@ -13605,11 +13628,11 @@ function useTransition({
|
|
|
13605
13628
|
if (h(P), P === 0)
|
|
13606
13629
|
typeof w == "function" && w(), typeof A == "function" && A(), x(E ? "entered" : "exited");
|
|
13607
13630
|
else {
|
|
13608
|
-
const
|
|
13631
|
+
const C = window.setTimeout(() => {
|
|
13609
13632
|
typeof w == "function" && w(), x(E ? "entering" : "exiting");
|
|
13610
13633
|
}, 10);
|
|
13611
13634
|
v.current = window.setTimeout(() => {
|
|
13612
|
-
window.clearTimeout(
|
|
13635
|
+
window.clearTimeout(C), typeof A == "function" && A(), x(E ? "entered" : "exited");
|
|
13613
13636
|
}, P);
|
|
13614
13637
|
}
|
|
13615
13638
|
};
|
|
@@ -13897,20 +13920,20 @@ function Popover(r) {
|
|
|
13897
13920
|
withArrow: w,
|
|
13898
13921
|
arrowSize: A,
|
|
13899
13922
|
arrowOffset: P,
|
|
13900
|
-
arrowRadius:
|
|
13901
|
-
arrowPosition:
|
|
13923
|
+
arrowRadius: C,
|
|
13924
|
+
arrowPosition: R,
|
|
13902
13925
|
unstyled: I,
|
|
13903
13926
|
classNames: j,
|
|
13904
13927
|
styles: k,
|
|
13905
13928
|
closeOnClickOutside: O,
|
|
13906
13929
|
withinPortal: T,
|
|
13907
|
-
portalProps:
|
|
13908
|
-
closeOnEscape:
|
|
13930
|
+
portalProps: B,
|
|
13931
|
+
closeOnEscape: L,
|
|
13909
13932
|
clickOutsideEvents: D,
|
|
13910
13933
|
trapFocus: W,
|
|
13911
13934
|
onClose: J,
|
|
13912
13935
|
onOpen: F,
|
|
13913
|
-
onChange:
|
|
13936
|
+
onChange: V,
|
|
13914
13937
|
zIndex: q,
|
|
13915
13938
|
radius: G,
|
|
13916
13939
|
shadow: ee,
|
|
@@ -13971,7 +13994,7 @@ function Popover(r) {
|
|
|
13971
13994
|
positionDependencies: b,
|
|
13972
13995
|
opened: x,
|
|
13973
13996
|
defaultOpened: U,
|
|
13974
|
-
onChange:
|
|
13997
|
+
onChange: V,
|
|
13975
13998
|
onOpen: F,
|
|
13976
13999
|
onClose: J
|
|
13977
14000
|
});
|
|
@@ -13999,16 +14022,16 @@ function Popover(r) {
|
|
|
13999
14022
|
withArrow: w,
|
|
14000
14023
|
arrowSize: A,
|
|
14001
14024
|
arrowOffset: P,
|
|
14002
|
-
arrowRadius:
|
|
14003
|
-
arrowPosition:
|
|
14025
|
+
arrowRadius: C,
|
|
14026
|
+
arrowPosition: R,
|
|
14004
14027
|
placement: be.floating.placement,
|
|
14005
14028
|
trapFocus: W,
|
|
14006
14029
|
withinPortal: T,
|
|
14007
|
-
portalProps:
|
|
14030
|
+
portalProps: B,
|
|
14008
14031
|
zIndex: q,
|
|
14009
14032
|
radius: G,
|
|
14010
14033
|
shadow: ee,
|
|
14011
|
-
closeOnEscape:
|
|
14034
|
+
closeOnEscape: L,
|
|
14012
14035
|
onClose: be.onClose,
|
|
14013
14036
|
onToggle: be.onToggle,
|
|
14014
14037
|
getTargetId: () => `${fe}-target`,
|
|
@@ -14165,8 +14188,8 @@ function useInputProps(r, n, o) {
|
|
|
14165
14188
|
id: w,
|
|
14166
14189
|
size: A,
|
|
14167
14190
|
style: P,
|
|
14168
|
-
inputContainer:
|
|
14169
|
-
inputWrapperOrder:
|
|
14191
|
+
inputContainer: C,
|
|
14192
|
+
inputWrapperOrder: R,
|
|
14170
14193
|
withAsterisk: I,
|
|
14171
14194
|
variant: j
|
|
14172
14195
|
} = a, k = __objRest$A(a, [
|
|
@@ -14191,7 +14214,7 @@ function useInputProps(r, n, o) {
|
|
|
14191
14214
|
"inputWrapperOrder",
|
|
14192
14215
|
"withAsterisk",
|
|
14193
14216
|
"variant"
|
|
14194
|
-
]), O = useId$2(w), { systemStyles: T, rest:
|
|
14217
|
+
]), O = useId$2(w), { systemStyles: T, rest: B } = extractSystemStyles(k), L = __spreadValues$R({
|
|
14195
14218
|
label: i,
|
|
14196
14219
|
description: l,
|
|
14197
14220
|
error: c,
|
|
@@ -14208,16 +14231,16 @@ function useInputProps(r, n, o) {
|
|
|
14208
14231
|
id: O,
|
|
14209
14232
|
size: A,
|
|
14210
14233
|
style: P,
|
|
14211
|
-
inputContainer:
|
|
14212
|
-
inputWrapperOrder:
|
|
14234
|
+
inputContainer: C,
|
|
14235
|
+
inputWrapperOrder: R,
|
|
14213
14236
|
withAsterisk: I,
|
|
14214
14237
|
variant: j
|
|
14215
14238
|
}, E);
|
|
14216
|
-
return __spreadProps$z(__spreadValues$R({},
|
|
14239
|
+
return __spreadProps$z(__spreadValues$R({}, B), {
|
|
14217
14240
|
classNames: d,
|
|
14218
14241
|
styles: m,
|
|
14219
14242
|
unstyled: g,
|
|
14220
|
-
wrapperProps: __spreadValues$R(__spreadValues$R({},
|
|
14243
|
+
wrapperProps: __spreadValues$R(__spreadValues$R({}, L), T),
|
|
14221
14244
|
inputProps: {
|
|
14222
14245
|
required: u,
|
|
14223
14246
|
classNames: d,
|
|
@@ -14493,8 +14516,8 @@ const defaultProps$q = {
|
|
|
14493
14516
|
__staticSelector: w,
|
|
14494
14517
|
unstyled: A,
|
|
14495
14518
|
inputWrapperOrder: P,
|
|
14496
|
-
withAsterisk:
|
|
14497
|
-
variant:
|
|
14519
|
+
withAsterisk: C,
|
|
14520
|
+
variant: R
|
|
14498
14521
|
} = o, I = __objRest$w(o, [
|
|
14499
14522
|
"className",
|
|
14500
14523
|
"label",
|
|
@@ -14521,32 +14544,32 @@ const defaultProps$q = {
|
|
|
14521
14544
|
styles: v,
|
|
14522
14545
|
name: ["InputWrapper", w],
|
|
14523
14546
|
unstyled: A,
|
|
14524
|
-
variant:
|
|
14547
|
+
variant: R,
|
|
14525
14548
|
size: S
|
|
14526
14549
|
}), O = {
|
|
14527
14550
|
classNames: x,
|
|
14528
14551
|
styles: v,
|
|
14529
14552
|
unstyled: A,
|
|
14530
14553
|
size: S,
|
|
14531
|
-
variant:
|
|
14554
|
+
variant: R,
|
|
14532
14555
|
__staticSelector: w
|
|
14533
|
-
}, T = typeof
|
|
14556
|
+
}, T = typeof C == "boolean" ? C : c, B = u ? `${u}-error` : b == null ? void 0 : b.id, L = u ? `${u}-description` : h == null ? void 0 : h.id, W = `${!!d && typeof d != "boolean" ? B : ""} ${m ? L : ""}`, J = W.trim().length > 0 ? W.trim() : void 0, F = i && /* @__PURE__ */ React__default.createElement(InputLabel, __spreadValues$M(__spreadValues$M({
|
|
14534
14557
|
key: "label",
|
|
14535
14558
|
labelElement: p,
|
|
14536
14559
|
id: u ? `${u}-label` : void 0,
|
|
14537
14560
|
htmlFor: u,
|
|
14538
14561
|
required: T
|
|
14539
|
-
}, O), g), i),
|
|
14562
|
+
}, O), g), i), V = m && /* @__PURE__ */ React__default.createElement(InputDescription, __spreadProps$x(__spreadValues$M(__spreadValues$M({
|
|
14540
14563
|
key: "description"
|
|
14541
14564
|
}, h), O), {
|
|
14542
14565
|
size: (h == null ? void 0 : h.size) || O.size,
|
|
14543
|
-
id: (h == null ? void 0 : h.id) ||
|
|
14566
|
+
id: (h == null ? void 0 : h.id) || L
|
|
14544
14567
|
}), m), q = /* @__PURE__ */ React__default.createElement(Fragment, {
|
|
14545
14568
|
key: "input"
|
|
14546
14569
|
}, E(l)), G = typeof d != "boolean" && d && /* @__PURE__ */ React__default.createElement(InputError, __spreadProps$x(__spreadValues$M(__spreadValues$M({}, b), O), {
|
|
14547
14570
|
size: (b == null ? void 0 : b.size) || O.size,
|
|
14548
14571
|
key: "error",
|
|
14549
|
-
id: (b == null ? void 0 : b.id) ||
|
|
14572
|
+
id: (b == null ? void 0 : b.id) || B
|
|
14550
14573
|
}), d), ee = P.map((z) => {
|
|
14551
14574
|
switch (z) {
|
|
14552
14575
|
case "label":
|
|
@@ -14554,7 +14577,7 @@ const defaultProps$q = {
|
|
|
14554
14577
|
case "input":
|
|
14555
14578
|
return q;
|
|
14556
14579
|
case "description":
|
|
14557
|
-
return
|
|
14580
|
+
return V;
|
|
14558
14581
|
case "error":
|
|
14559
14582
|
return G;
|
|
14560
14583
|
default:
|
|
@@ -14565,7 +14588,7 @@ const defaultProps$q = {
|
|
|
14565
14588
|
value: __spreadValues$M({
|
|
14566
14589
|
describedBy: J
|
|
14567
14590
|
}, getInputOffsets(P, {
|
|
14568
|
-
hasDescription: !!
|
|
14591
|
+
hasDescription: !!V,
|
|
14569
14592
|
hasError: !!G
|
|
14570
14593
|
}))
|
|
14571
14594
|
}, /* @__PURE__ */ React__default.createElement(Box, __spreadValues$M({
|
|
@@ -14786,8 +14809,8 @@ const defaultProps$o = {
|
|
|
14786
14809
|
styles: w,
|
|
14787
14810
|
__staticSelector: A,
|
|
14788
14811
|
multiline: P,
|
|
14789
|
-
sx:
|
|
14790
|
-
unstyled:
|
|
14812
|
+
sx: C,
|
|
14813
|
+
unstyled: R,
|
|
14791
14814
|
pointer: I
|
|
14792
14815
|
} = o, j = __objRest$u(o, [
|
|
14793
14816
|
"className",
|
|
@@ -14811,7 +14834,7 @@ const defaultProps$o = {
|
|
|
14811
14834
|
"sx",
|
|
14812
14835
|
"unstyled",
|
|
14813
14836
|
"pointer"
|
|
14814
|
-
]), { offsetBottom: k, offsetTop: O, describedBy: T } = useInputWrapperContext(), { classes:
|
|
14837
|
+
]), { offsetBottom: k, offsetTop: O, describedBy: T } = useInputWrapperContext(), { classes: B, cx: L } = useStyles$v({
|
|
14815
14838
|
radius: x,
|
|
14816
14839
|
multiline: P,
|
|
14817
14840
|
invalid: !!i,
|
|
@@ -14821,13 +14844,13 @@ const defaultProps$o = {
|
|
|
14821
14844
|
offsetBottom: k,
|
|
14822
14845
|
offsetTop: O,
|
|
14823
14846
|
pointer: I
|
|
14824
|
-
}, { classNames: E, styles: w, name: ["Input", A], unstyled:
|
|
14847
|
+
}, { classNames: E, styles: w, name: ["Input", A], unstyled: R, variant: u, size: v }), { systemStyles: D, rest: W } = extractSystemStyles(j);
|
|
14825
14848
|
return /* @__PURE__ */ React__default.createElement(Box, __spreadValues$J(__spreadValues$J({
|
|
14826
|
-
className:
|
|
14827
|
-
sx:
|
|
14849
|
+
className: L(B.wrapper, a),
|
|
14850
|
+
sx: C,
|
|
14828
14851
|
style: m
|
|
14829
14852
|
}, D), S), d && /* @__PURE__ */ React__default.createElement("div", {
|
|
14830
|
-
className:
|
|
14853
|
+
className: B.icon
|
|
14831
14854
|
}, d), /* @__PURE__ */ React__default.createElement(Box, __spreadProps$v(__spreadValues$J({
|
|
14832
14855
|
component: "input"
|
|
14833
14856
|
}, W), {
|
|
@@ -14839,9 +14862,9 @@ const defaultProps$o = {
|
|
|
14839
14862
|
"data-disabled": c || void 0,
|
|
14840
14863
|
"data-with-icon": !!d || void 0,
|
|
14841
14864
|
"data-invalid": !!i || void 0,
|
|
14842
|
-
className:
|
|
14865
|
+
className: B.input
|
|
14843
14866
|
})), h && /* @__PURE__ */ React__default.createElement("div", __spreadProps$v(__spreadValues$J({}, b), {
|
|
14844
|
-
className:
|
|
14867
|
+
className: B.rightSection
|
|
14845
14868
|
}), h));
|
|
14846
14869
|
});
|
|
14847
14870
|
_Input.displayName = "@mantine/core/Input";
|
|
@@ -15220,8 +15243,8 @@ const defaultProps$l = {
|
|
|
15220
15243
|
loaderProps: w,
|
|
15221
15244
|
gradient: A,
|
|
15222
15245
|
classNames: P,
|
|
15223
|
-
styles:
|
|
15224
|
-
unstyled:
|
|
15246
|
+
styles: C,
|
|
15247
|
+
unstyled: R
|
|
15225
15248
|
} = o, I = __objRest$r(o, [
|
|
15226
15249
|
"className",
|
|
15227
15250
|
"size",
|
|
@@ -15251,7 +15274,7 @@ const defaultProps$l = {
|
|
|
15251
15274
|
gradient: A,
|
|
15252
15275
|
withLeftIcon: !!m,
|
|
15253
15276
|
withRightIcon: !!p
|
|
15254
|
-
}, { name: "Button", unstyled:
|
|
15277
|
+
}, { name: "Button", unstyled: R, classNames: P, styles: C, variant: h, size: i }), T = O.fn.variant({ color: l, variant: h }), B = /* @__PURE__ */ React__default.createElement(Loader, __spreadValues$E({
|
|
15255
15278
|
color: T.color,
|
|
15256
15279
|
size: `calc(${getSize({ size: i, sizes: sizes$1 }).height} / 2)`
|
|
15257
15280
|
}, w));
|
|
@@ -15263,19 +15286,19 @@ const defaultProps$l = {
|
|
|
15263
15286
|
"data-disabled": u || void 0,
|
|
15264
15287
|
"data-loading": S || void 0,
|
|
15265
15288
|
ref: n,
|
|
15266
|
-
unstyled:
|
|
15289
|
+
unstyled: R
|
|
15267
15290
|
}, I), /* @__PURE__ */ React__default.createElement("div", {
|
|
15268
15291
|
className: j.inner
|
|
15269
15292
|
}, (m || S && E === "left") && /* @__PURE__ */ React__default.createElement("span", {
|
|
15270
15293
|
className: k(j.icon, j.leftIcon)
|
|
15271
|
-
}, S && E === "left" ?
|
|
15294
|
+
}, S && E === "left" ? B : m), S && E === "center" && /* @__PURE__ */ React__default.createElement("span", {
|
|
15272
15295
|
className: j.centerLoader
|
|
15273
|
-
},
|
|
15296
|
+
}, B), /* @__PURE__ */ React__default.createElement("span", {
|
|
15274
15297
|
className: j.label,
|
|
15275
15298
|
style: { textTransform: x ? "uppercase" : void 0 }
|
|
15276
15299
|
}, d), (p || S && E === "right") && /* @__PURE__ */ React__default.createElement("span", {
|
|
15277
15300
|
className: k(j.icon, j.rightIcon)
|
|
15278
|
-
}, S && E === "right" ?
|
|
15301
|
+
}, S && E === "right" ? B : p)));
|
|
15279
15302
|
});
|
|
15280
15303
|
_Button.displayName = "@mantine/core/Button";
|
|
15281
15304
|
_Button.Group = ButtonGroup;
|
|
@@ -15671,14 +15694,14 @@ const defaultProps$g = {
|
|
|
15671
15694
|
"unstyled",
|
|
15672
15695
|
"processing",
|
|
15673
15696
|
"variant"
|
|
15674
|
-
]), { classes:
|
|
15697
|
+
]), { classes: C, cx: R } = useStyles$m({ position: i, offset: l, radius: u, inline: d, color: g, withBorder: m, zIndex: S, withLabel: !!b }, { name: "Indicator", classNames: x, styles: h, unstyled: E, variant: A, size: c });
|
|
15675
15698
|
return /* @__PURE__ */ React__default.createElement(Box, __spreadValues$w({
|
|
15676
15699
|
ref: n,
|
|
15677
|
-
className: C
|
|
15700
|
+
className: R(C.root, p)
|
|
15678
15701
|
}, P), !v && /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement("div", {
|
|
15679
|
-
className: C
|
|
15702
|
+
className: R(C.indicator, C.common)
|
|
15680
15703
|
}, b), w && /* @__PURE__ */ React__default.createElement("div", {
|
|
15681
|
-
className: C
|
|
15704
|
+
className: R(C.processing, C.common)
|
|
15682
15705
|
})), a);
|
|
15683
15706
|
});
|
|
15684
15707
|
Indicator.displayName = "@mantine/core/Indicator";
|
|
@@ -15917,7 +15940,7 @@ const defaultProps$d = {
|
|
|
15917
15940
|
"unstyled",
|
|
15918
15941
|
"variant",
|
|
15919
15942
|
"keepMounted"
|
|
15920
|
-
]), { classes: A, cx: P, theme:
|
|
15943
|
+
]), { classes: A, cx: P, theme: C } = useStyles$j(null, { name: "LoadingOverlay", unstyled: v, variant: S }), R = `calc(${p} + 1)`;
|
|
15921
15944
|
return /* @__PURE__ */ React__default.createElement(Transition, {
|
|
15922
15945
|
keepMounted: E,
|
|
15923
15946
|
duration: d,
|
|
@@ -15929,16 +15952,16 @@ const defaultProps$d = {
|
|
|
15929
15952
|
style: __spreadProps$m(__spreadValues$r(__spreadValues$r({}, I), g), { zIndex: p }),
|
|
15930
15953
|
ref: n
|
|
15931
15954
|
}, w), h ? /* @__PURE__ */ React__default.createElement("div", {
|
|
15932
|
-
style: { zIndex:
|
|
15955
|
+
style: { zIndex: R }
|
|
15933
15956
|
}, h) : /* @__PURE__ */ React__default.createElement(Loader, __spreadValues$r({
|
|
15934
|
-
style: { zIndex:
|
|
15957
|
+
style: { zIndex: R }
|
|
15935
15958
|
}, l)), /* @__PURE__ */ React__default.createElement(Overlay, {
|
|
15936
15959
|
opacity: c,
|
|
15937
15960
|
zIndex: p,
|
|
15938
15961
|
radius: b,
|
|
15939
15962
|
blur: x,
|
|
15940
15963
|
unstyled: v,
|
|
15941
|
-
color: u || (
|
|
15964
|
+
color: u || (C.colorScheme === "dark" ? C.colors.dark[5] : C.white)
|
|
15942
15965
|
})));
|
|
15943
15966
|
});
|
|
15944
15967
|
LoadingOverlay.displayName = "@mantine/core/LoadingOverlay";
|
|
@@ -16159,8 +16182,8 @@ const defaultProps$c = {
|
|
|
16159
16182
|
onChange: w,
|
|
16160
16183
|
disableRightSectionRotation: A,
|
|
16161
16184
|
childrenOffset: P,
|
|
16162
|
-
disabled:
|
|
16163
|
-
onClick:
|
|
16185
|
+
disabled: C,
|
|
16186
|
+
onClick: R
|
|
16164
16187
|
} = o, I = __objRest$g(o, [
|
|
16165
16188
|
"label",
|
|
16166
16189
|
"description",
|
|
@@ -16187,18 +16210,18 @@ const defaultProps$c = {
|
|
|
16187
16210
|
defaultValue: E,
|
|
16188
16211
|
finalValue: !1,
|
|
16189
16212
|
onChange: w
|
|
16190
|
-
}),
|
|
16191
|
-
|
|
16213
|
+
}), B = !!v, L = (D) => {
|
|
16214
|
+
B ? (D.preventDefault(), R == null || R(D), T(!O)) : R == null || R(D);
|
|
16192
16215
|
};
|
|
16193
16216
|
return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(UnstyledButton, __spreadValues$m({
|
|
16194
16217
|
ref: n,
|
|
16195
16218
|
className: k(j.root, u),
|
|
16196
16219
|
"data-active": g || void 0,
|
|
16197
|
-
onClick:
|
|
16220
|
+
onClick: L,
|
|
16198
16221
|
unstyled: p,
|
|
16199
16222
|
"data-expanded": O || void 0,
|
|
16200
|
-
"data-disabled":
|
|
16201
|
-
disabled:
|
|
16223
|
+
"data-disabled": C || void 0,
|
|
16224
|
+
disabled: C
|
|
16202
16225
|
}, I), l && /* @__PURE__ */ React__default.createElement("span", {
|
|
16203
16226
|
className: j.icon
|
|
16204
16227
|
}, l), /* @__PURE__ */ React__default.createElement("span", {
|
|
@@ -16213,10 +16236,10 @@ const defaultProps$c = {
|
|
|
16213
16236
|
size: "xs",
|
|
16214
16237
|
"data-active": g || void 0,
|
|
16215
16238
|
className: j.description
|
|
16216
|
-
}, i)), (
|
|
16239
|
+
}, i)), (B || c) && /* @__PURE__ */ React__default.createElement("span", {
|
|
16217
16240
|
className: j.rightSection,
|
|
16218
16241
|
"data-rotate": O && !A || void 0
|
|
16219
|
-
},
|
|
16242
|
+
}, B ? c || /* @__PURE__ */ React__default.createElement(ChevronIcon$1, {
|
|
16220
16243
|
width: rem(14),
|
|
16221
16244
|
height: rem(14),
|
|
16222
16245
|
style: { transform: "rotate(-90deg)" }
|
|
@@ -16392,8 +16415,8 @@ function TooltipFloating(r) {
|
|
|
16392
16415
|
width: w,
|
|
16393
16416
|
zIndex: A,
|
|
16394
16417
|
disabled: P,
|
|
16395
|
-
variant:
|
|
16396
|
-
} = o,
|
|
16418
|
+
variant: C
|
|
16419
|
+
} = o, R = __objRest$e(o, [
|
|
16397
16420
|
"children",
|
|
16398
16421
|
"refProp",
|
|
16399
16422
|
"withinPortal",
|
|
@@ -16413,23 +16436,23 @@ function TooltipFloating(r) {
|
|
|
16413
16436
|
"zIndex",
|
|
16414
16437
|
"disabled",
|
|
16415
16438
|
"variant"
|
|
16416
|
-
]), { handleMouseMove: I, x: j, y: k, opened: O, boundaryRef: T, floating:
|
|
16439
|
+
]), { handleMouseMove: I, x: j, y: k, opened: O, boundaryRef: T, floating: B, setOpened: L } = useFloatingTooltip({
|
|
16417
16440
|
offset: v,
|
|
16418
16441
|
position: S
|
|
16419
|
-
}), { classes: D, cx: W } = useStyles$h({ radius: h, color: b, multiline: E, width: w }, { name: "TooltipFloating", classNames: m, styles: p, unstyled: g, variant:
|
|
16442
|
+
}), { classes: D, cx: W } = useStyles$h({ radius: h, color: b, multiline: E, width: w }, { name: "TooltipFloating", classNames: m, styles: p, unstyled: g, variant: C });
|
|
16420
16443
|
if (!isElement$1(a))
|
|
16421
16444
|
throw new Error(TOOLTIP_ERRORS.children);
|
|
16422
16445
|
const J = useMergedRef(T, a.ref), F = (q) => {
|
|
16423
16446
|
var G, ee;
|
|
16424
|
-
(ee = (G = a.props).onMouseEnter) == null || ee.call(G, q), I(q),
|
|
16425
|
-
},
|
|
16447
|
+
(ee = (G = a.props).onMouseEnter) == null || ee.call(G, q), I(q), L(!0);
|
|
16448
|
+
}, V = (q) => {
|
|
16426
16449
|
var G, ee;
|
|
16427
|
-
(ee = (G = a.props).onMouseLeave) == null || ee.call(G, q),
|
|
16450
|
+
(ee = (G = a.props).onMouseLeave) == null || ee.call(G, q), L(!1);
|
|
16428
16451
|
};
|
|
16429
16452
|
return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(OptionalPortal, __spreadProps$g(__spreadValues$j({}, c), {
|
|
16430
16453
|
withinPortal: l
|
|
16431
|
-
}), /* @__PURE__ */ React__default.createElement(Box, __spreadProps$g(__spreadValues$j({},
|
|
16432
|
-
ref:
|
|
16454
|
+
}), /* @__PURE__ */ React__default.createElement(Box, __spreadProps$g(__spreadValues$j({}, R), {
|
|
16455
|
+
ref: B,
|
|
16433
16456
|
className: W(D.tooltip, d),
|
|
16434
16457
|
style: __spreadProps$g(__spreadValues$j({}, u), {
|
|
16435
16458
|
zIndex: A,
|
|
@@ -16440,7 +16463,7 @@ function TooltipFloating(r) {
|
|
|
16440
16463
|
}), x)), cloneElement(a, __spreadProps$g(__spreadValues$j({}, a.props), {
|
|
16441
16464
|
[i]: J,
|
|
16442
16465
|
onMouseEnter: F,
|
|
16443
|
-
onMouseLeave:
|
|
16466
|
+
onMouseLeave: V
|
|
16444
16467
|
})));
|
|
16445
16468
|
}
|
|
16446
16469
|
TooltipFloating.displayName = "@mantine/core/TooltipFloating";
|
|
@@ -16468,7 +16491,7 @@ function useTooltip(r) {
|
|
|
16468
16491
|
arrow({ element: r.arrowRef, padding: r.arrowOffset }),
|
|
16469
16492
|
...r.inline ? [inline()] : []
|
|
16470
16493
|
]
|
|
16471
|
-
}), { getReferenceProps:
|
|
16494
|
+
}), { getReferenceProps: C, getFloatingProps: R } = useInteractions([
|
|
16472
16495
|
useHover(v, {
|
|
16473
16496
|
enabled: r.events.hover,
|
|
16474
16497
|
delay: l ? u : { open: r.openDelay, close: r.closeDelay },
|
|
@@ -16494,8 +16517,8 @@ function useTooltip(r) {
|
|
|
16494
16517
|
arrowY: P,
|
|
16495
16518
|
reference: b,
|
|
16496
16519
|
floating: x,
|
|
16497
|
-
getFloatingProps:
|
|
16498
|
-
getReferenceProps:
|
|
16520
|
+
getFloatingProps: R,
|
|
16521
|
+
getReferenceProps: C,
|
|
16499
16522
|
isGroupPhase: i && d && d !== c,
|
|
16500
16523
|
opened: i,
|
|
16501
16524
|
placement: w
|
|
@@ -16551,20 +16574,20 @@ const defaultProps$9 = {
|
|
|
16551
16574
|
styles: w,
|
|
16552
16575
|
unstyled: A,
|
|
16553
16576
|
style: P,
|
|
16554
|
-
className:
|
|
16555
|
-
withArrow:
|
|
16577
|
+
className: C,
|
|
16578
|
+
withArrow: R,
|
|
16556
16579
|
arrowSize: I,
|
|
16557
16580
|
arrowOffset: j,
|
|
16558
16581
|
arrowRadius: k,
|
|
16559
16582
|
arrowPosition: O,
|
|
16560
16583
|
offset: T,
|
|
16561
|
-
transitionProps:
|
|
16562
|
-
multiline:
|
|
16584
|
+
transitionProps: B,
|
|
16585
|
+
multiline: L,
|
|
16563
16586
|
width: D,
|
|
16564
16587
|
events: W,
|
|
16565
16588
|
zIndex: J,
|
|
16566
16589
|
disabled: F,
|
|
16567
|
-
positionDependencies:
|
|
16590
|
+
positionDependencies: V,
|
|
16568
16591
|
onClick: q,
|
|
16569
16592
|
onMouseEnter: G,
|
|
16570
16593
|
onMouseLeave: ee,
|
|
@@ -16608,7 +16631,7 @@ const defaultProps$9 = {
|
|
|
16608
16631
|
"inline",
|
|
16609
16632
|
"variant",
|
|
16610
16633
|
"keepMounted"
|
|
16611
|
-
]), { classes: Q, cx: ne, theme: re } = useStyles$h({ radius: v, color: S, width: D, multiline:
|
|
16634
|
+
]), { classes: Q, cx: ne, theme: re } = useStyles$h({ radius: v, color: S, width: D, multiline: L }, { name: "Tooltip", classNames: E, styles: w, unstyled: A, variant: U }), $ = useTooltip({
|
|
16612
16635
|
position: getFloatingPosition(re.dir, c),
|
|
16613
16636
|
closeDelay: p,
|
|
16614
16637
|
openDelay: m,
|
|
@@ -16617,8 +16640,8 @@ const defaultProps$9 = {
|
|
|
16617
16640
|
events: W,
|
|
16618
16641
|
arrowRef: a,
|
|
16619
16642
|
arrowOffset: j,
|
|
16620
|
-
offset: T + (
|
|
16621
|
-
positionDependencies: [...
|
|
16643
|
+
offset: T + (R ? I / 2 : 0),
|
|
16644
|
+
positionDependencies: [...V, l],
|
|
16622
16645
|
inline: z
|
|
16623
16646
|
});
|
|
16624
16647
|
if (!isElement$1(l))
|
|
@@ -16629,9 +16652,9 @@ const defaultProps$9 = {
|
|
|
16629
16652
|
}), /* @__PURE__ */ React__default.createElement(Transition, __spreadProps$f(__spreadValues$i({
|
|
16630
16653
|
keepMounted: te,
|
|
16631
16654
|
mounted: !F && $.opened
|
|
16632
|
-
},
|
|
16633
|
-
transition:
|
|
16634
|
-
duration: $.isGroupPhase ? 10 : (o =
|
|
16655
|
+
}, B), {
|
|
16656
|
+
transition: B.transition || "fade",
|
|
16657
|
+
duration: $.isGroupPhase ? 10 : (o = B.duration) != null ? o : 100
|
|
16635
16658
|
}), (se) => {
|
|
16636
16659
|
var K, Z;
|
|
16637
16660
|
return /* @__PURE__ */ React__default.createElement(Box, __spreadValues$i(__spreadValues$i({}, _), $.getFloatingProps({
|
|
@@ -16646,7 +16669,7 @@ const defaultProps$9 = {
|
|
|
16646
16669
|
ref: a,
|
|
16647
16670
|
arrowX: $.arrowX,
|
|
16648
16671
|
arrowY: $.arrowY,
|
|
16649
|
-
visible:
|
|
16672
|
+
visible: R,
|
|
16650
16673
|
position: $.placement,
|
|
16651
16674
|
arrowSize: I,
|
|
16652
16675
|
arrowOffset: j,
|
|
@@ -16662,7 +16685,7 @@ const defaultProps$9 = {
|
|
|
16662
16685
|
onPointerDown: r.onPointerDown,
|
|
16663
16686
|
onPointerEnter: r.onPointerEnter,
|
|
16664
16687
|
[u]: ae,
|
|
16665
|
-
className: ne(
|
|
16688
|
+
className: ne(C, l.props.className)
|
|
16666
16689
|
}, l.props))));
|
|
16667
16690
|
});
|
|
16668
16691
|
_Tooltip.Group = TooltipGroup;
|
|
@@ -16767,20 +16790,20 @@ const defaultProps$8 = {
|
|
|
16767
16790
|
styles: w,
|
|
16768
16791
|
filter: A,
|
|
16769
16792
|
maxDropdownHeight: P,
|
|
16770
|
-
searchable:
|
|
16771
|
-
clearable:
|
|
16793
|
+
searchable: C,
|
|
16794
|
+
clearable: R,
|
|
16772
16795
|
nothingFound: I,
|
|
16773
16796
|
limit: j,
|
|
16774
16797
|
disabled: k,
|
|
16775
16798
|
onSearchChange: O,
|
|
16776
16799
|
searchValue: T,
|
|
16777
|
-
rightSection:
|
|
16778
|
-
rightSectionWidth:
|
|
16800
|
+
rightSection: B,
|
|
16801
|
+
rightSectionWidth: L,
|
|
16779
16802
|
creatable: D,
|
|
16780
16803
|
getCreateLabel: W,
|
|
16781
16804
|
shouldCreate: J,
|
|
16782
16805
|
selectOnBlur: F,
|
|
16783
|
-
onCreate:
|
|
16806
|
+
onCreate: V,
|
|
16784
16807
|
dropdownComponent: q,
|
|
16785
16808
|
onDropdownClose: G,
|
|
16786
16809
|
onDropdownOpen: ee,
|
|
@@ -16848,12 +16871,12 @@ const defaultProps$8 = {
|
|
|
16848
16871
|
"readOnly",
|
|
16849
16872
|
"clearButtonProps",
|
|
16850
16873
|
"hoverOnSearchChange"
|
|
16851
|
-
]), { classes: be, cx: Ze, theme: Ne } = useStyles$g(), [ge, Ge] = useState$1(v), [ke, ve] = useState$1(-1), He = useRef$1(), Fe = useRef$1({}), [Je, rt] = useState$1("column"),
|
|
16874
|
+
]), { classes: be, cx: Ze, theme: Ne } = useStyles$g(), [ge, Ge] = useState$1(v), [ke, ve] = useState$1(-1), He = useRef$1(), Fe = useRef$1({}), [Je, rt] = useState$1("column"), Ce = Je === "column", { scrollIntoView: De, targetRef: Le, scrollableRef: nt } = useScrollIntoView({
|
|
16852
16875
|
duration: 0,
|
|
16853
16876
|
offset: 5,
|
|
16854
16877
|
cancelable: !1,
|
|
16855
16878
|
isList: !0
|
|
16856
|
-
}), Ye = re === void 0 ?
|
|
16879
|
+
}), Ye = re === void 0 ? R : re, Se = (H) => {
|
|
16857
16880
|
if (ge !== H) {
|
|
16858
16881
|
Ge(H);
|
|
16859
16882
|
const ie = H ? ee : G;
|
|
@@ -16861,48 +16884,48 @@ const defaultProps$8 = {
|
|
|
16861
16884
|
}
|
|
16862
16885
|
}, qe = D && typeof W == "function";
|
|
16863
16886
|
let We = null;
|
|
16864
|
-
const ot = c.map((H) => typeof H == "string" ? { label: H, value: H } : H), Ue = groupOptions({ data: ot }), [
|
|
16887
|
+
const ot = c.map((H) => typeof H == "string" ? { label: H, value: H } : H), Ue = groupOptions({ data: ot }), [Re, Be, Xe] = useUncontrolled({
|
|
16865
16888
|
value: u,
|
|
16866
16889
|
defaultValue: d,
|
|
16867
16890
|
finalValue: null,
|
|
16868
16891
|
onChange: m
|
|
16869
|
-
}), Pe = Ue.find((H) => H.value ===
|
|
16892
|
+
}), Pe = Ue.find((H) => H.value === Re), [Ie, at] = useUncontrolled({
|
|
16870
16893
|
value: T,
|
|
16871
16894
|
defaultValue: (Pe == null ? void 0 : Pe.label) || "",
|
|
16872
16895
|
finalValue: void 0,
|
|
16873
16896
|
onChange: O
|
|
16874
16897
|
}), Oe = (H) => {
|
|
16875
|
-
at(H),
|
|
16898
|
+
at(H), C && typeof O == "function" && O(H);
|
|
16876
16899
|
}, st = () => {
|
|
16877
16900
|
var H;
|
|
16878
|
-
Z || (
|
|
16901
|
+
Z || (Be(null), Xe || Oe(""), (H = He.current) == null || H.focus());
|
|
16879
16902
|
};
|
|
16880
16903
|
useEffect$1(() => {
|
|
16881
|
-
const H = Ue.find((ie) => ie.value ===
|
|
16882
|
-
H ? Oe(H.label) : (!qe || !
|
|
16883
|
-
}, [
|
|
16884
|
-
Pe && (!
|
|
16904
|
+
const H = Ue.find((ie) => ie.value === Re);
|
|
16905
|
+
H ? Oe(H.label) : (!qe || !Re) && Oe("");
|
|
16906
|
+
}, [Re]), useEffect$1(() => {
|
|
16907
|
+
Pe && (!C || !ge) && Oe(Pe.label);
|
|
16885
16908
|
}, [Pe == null ? void 0 : Pe.label]);
|
|
16886
16909
|
const je = (H) => {
|
|
16887
16910
|
if (!Z)
|
|
16888
16911
|
if (Ye && (Pe == null ? void 0 : Pe.value) === H.value)
|
|
16889
|
-
|
|
16912
|
+
Be(null), Se(!1);
|
|
16890
16913
|
else {
|
|
16891
|
-
if (H.creatable && typeof
|
|
16892
|
-
const ie =
|
|
16893
|
-
typeof ie < "u" && ie !== null &&
|
|
16914
|
+
if (H.creatable && typeof V == "function") {
|
|
16915
|
+
const ie = V(H.value);
|
|
16916
|
+
typeof ie < "u" && ie !== null && Be(typeof ie == "string" ? ie : ie.value);
|
|
16894
16917
|
} else
|
|
16895
|
-
|
|
16918
|
+
Be(H.value);
|
|
16896
16919
|
Xe || Oe(H.label), ve(-1), Se(!1), He.current.focus();
|
|
16897
16920
|
}
|
|
16898
16921
|
}, he = filterData({
|
|
16899
16922
|
data: Ue,
|
|
16900
|
-
searchable:
|
|
16923
|
+
searchable: C,
|
|
16901
16924
|
limit: j,
|
|
16902
16925
|
searchValue: Ie,
|
|
16903
16926
|
filter: A,
|
|
16904
16927
|
filterDataOnExactSearchMatch: ae,
|
|
16905
|
-
value:
|
|
16928
|
+
value: Re
|
|
16906
16929
|
});
|
|
16907
16930
|
qe && J(Ie, he) && (We = W(Ie), he.push({ label: Ie, value: Ie, creatable: !0 }));
|
|
16908
16931
|
const Qe = (H, ie, ue) => {
|
|
@@ -16915,21 +16938,21 @@ const defaultProps$8 = {
|
|
|
16915
16938
|
useDidUpdate(() => {
|
|
16916
16939
|
ve(fe && Ie ? 0 : -1);
|
|
16917
16940
|
}, [Ie, fe]);
|
|
16918
|
-
const
|
|
16941
|
+
const Ve = Re ? he.findIndex((H) => H.value === Re) : 0, Ee = !Z && (he.length > 0 ? ge : ge && !!I), _e = () => {
|
|
16919
16942
|
ve((H) => {
|
|
16920
16943
|
var ie;
|
|
16921
16944
|
const ue = Qe(H, (de) => de - 1, (de) => de > 0);
|
|
16922
|
-
return
|
|
16945
|
+
return Le.current = Fe.current[(ie = he[ue]) == null ? void 0 : ie.value], Ee && De({ alignment: Ce ? "start" : "end" }), ue;
|
|
16923
16946
|
});
|
|
16924
16947
|
}, $e = () => {
|
|
16925
16948
|
ve((H) => {
|
|
16926
16949
|
var ie;
|
|
16927
16950
|
const ue = Qe(H, (de) => de + 1, (de) => de < he.length - 1);
|
|
16928
|
-
return
|
|
16951
|
+
return Le.current = Fe.current[(ie = he[ue]) == null ? void 0 : ie.value], Ee && De({ alignment: Ce ? "end" : "start" }), ue;
|
|
16929
16952
|
});
|
|
16930
16953
|
}, Ke = () => window.setTimeout(() => {
|
|
16931
16954
|
var H;
|
|
16932
|
-
|
|
16955
|
+
Le.current = Fe.current[(H = he[Ve]) == null ? void 0 : H.value], De({ alignment: Ce ? "end" : "start" });
|
|
16933
16956
|
}, 50);
|
|
16934
16957
|
useDidUpdate(() => {
|
|
16935
16958
|
Ee && Ke();
|
|
@@ -16937,26 +16960,26 @@ const defaultProps$8 = {
|
|
|
16937
16960
|
const N = (H) => {
|
|
16938
16961
|
switch (typeof g == "function" && g(H), H.key) {
|
|
16939
16962
|
case "ArrowUp": {
|
|
16940
|
-
H.preventDefault(), ge ?
|
|
16963
|
+
H.preventDefault(), ge ? Ce ? _e() : $e() : (ve(Ve), Se(!0), Ke());
|
|
16941
16964
|
break;
|
|
16942
16965
|
}
|
|
16943
16966
|
case "ArrowDown": {
|
|
16944
|
-
H.preventDefault(), ge ?
|
|
16967
|
+
H.preventDefault(), ge ? Ce ? $e() : _e() : (ve(Ve), Se(!0), Ke());
|
|
16945
16968
|
break;
|
|
16946
16969
|
}
|
|
16947
16970
|
case "Home": {
|
|
16948
|
-
if (!
|
|
16971
|
+
if (!C) {
|
|
16949
16972
|
H.preventDefault(), ge || Se(!0);
|
|
16950
16973
|
const ie = he.findIndex((ue) => !ue.disabled);
|
|
16951
|
-
ve(ie), Ee && De({ alignment:
|
|
16974
|
+
ve(ie), Ee && De({ alignment: Ce ? "end" : "start" });
|
|
16952
16975
|
}
|
|
16953
16976
|
break;
|
|
16954
16977
|
}
|
|
16955
16978
|
case "End": {
|
|
16956
|
-
if (!
|
|
16979
|
+
if (!C) {
|
|
16957
16980
|
H.preventDefault(), ge || Se(!0);
|
|
16958
16981
|
const ie = he.map((ue) => !!ue.disabled).lastIndexOf(!1);
|
|
16959
|
-
ve(ie), Ee && De({ alignment:
|
|
16982
|
+
ve(ie), Ee && De({ alignment: Ce ? "end" : "start" });
|
|
16960
16983
|
}
|
|
16961
16984
|
break;
|
|
16962
16985
|
}
|
|
@@ -16965,22 +16988,22 @@ const defaultProps$8 = {
|
|
|
16965
16988
|
break;
|
|
16966
16989
|
}
|
|
16967
16990
|
case " ": {
|
|
16968
|
-
|
|
16991
|
+
C || (H.preventDefault(), he[ke] && ge ? je(he[ke]) : (Se(!0), ve(Ve), Ke()));
|
|
16969
16992
|
break;
|
|
16970
16993
|
}
|
|
16971
16994
|
case "Enter":
|
|
16972
|
-
|
|
16995
|
+
C || H.preventDefault(), he[ke] && ge && (H.preventDefault(), je(he[ke]));
|
|
16973
16996
|
}
|
|
16974
|
-
},
|
|
16997
|
+
}, M = (H) => {
|
|
16975
16998
|
typeof h == "function" && h(H);
|
|
16976
|
-
const ie = Ue.find((ue) => ue.value ===
|
|
16999
|
+
const ie = Ue.find((ue) => ue.value === Re);
|
|
16977
17000
|
F && he[ke] && ge && je(he[ke]), Oe((ie == null ? void 0 : ie.label) || ""), Se(!1);
|
|
16978
17001
|
}, Y = (H) => {
|
|
16979
|
-
typeof b == "function" && b(H),
|
|
17002
|
+
typeof b == "function" && b(H), C && Se(!0);
|
|
16980
17003
|
}, oe = (H) => {
|
|
16981
|
-
Z || (Oe(H.currentTarget.value),
|
|
17004
|
+
Z || (Oe(H.currentTarget.value), R && H.currentTarget.value === "" && Be(null), ve(-1), Se(!0));
|
|
16982
17005
|
}, ce = () => {
|
|
16983
|
-
Z || (Se(!ge),
|
|
17006
|
+
Z || (Se(!ge), Re && !ge && ve(Ve));
|
|
16984
17007
|
};
|
|
16985
17008
|
return /* @__PURE__ */ React__default.createElement(Input.Wrapper, __spreadProps$e(__spreadValues$h({}, i), {
|
|
16986
17009
|
__staticSelector: "Select"
|
|
@@ -17011,7 +17034,7 @@ const defaultProps$8 = {
|
|
|
17011
17034
|
}, /* @__PURE__ */ React__default.createElement("input", {
|
|
17012
17035
|
type: "hidden",
|
|
17013
17036
|
name: Q,
|
|
17014
|
-
value:
|
|
17037
|
+
value: Re || "",
|
|
17015
17038
|
form: se,
|
|
17016
17039
|
disabled: k
|
|
17017
17040
|
}), /* @__PURE__ */ React__default.createElement(Input, __spreadValues$h(__spreadProps$e(__spreadValues$h(__spreadValues$h({
|
|
@@ -17028,22 +17051,22 @@ const defaultProps$8 = {
|
|
|
17028
17051
|
"aria-controls": Ee ? `${a.id}-items` : null,
|
|
17029
17052
|
"aria-activedescendant": ke >= 0 ? `${a.id}-${ke}` : null,
|
|
17030
17053
|
onMouseDown: ce,
|
|
17031
|
-
onBlur:
|
|
17054
|
+
onBlur: M,
|
|
17032
17055
|
onFocus: Y,
|
|
17033
|
-
readOnly: !
|
|
17056
|
+
readOnly: !C || Z,
|
|
17034
17057
|
disabled: k,
|
|
17035
17058
|
"data-mantine-stop-propagation": Ee,
|
|
17036
17059
|
name: null,
|
|
17037
17060
|
classNames: __spreadProps$e(__spreadValues$h({}, E), {
|
|
17038
|
-
input: Ze({ [be.input]: !
|
|
17061
|
+
input: Ze({ [be.input]: !C }, E == null ? void 0 : E.input)
|
|
17039
17062
|
})
|
|
17040
17063
|
}), getSelectRightSectionProps({
|
|
17041
17064
|
theme: Ne,
|
|
17042
|
-
rightSection:
|
|
17043
|
-
rightSectionWidth:
|
|
17065
|
+
rightSection: B,
|
|
17066
|
+
rightSectionWidth: L,
|
|
17044
17067
|
styles: w,
|
|
17045
17068
|
size: a.size,
|
|
17046
|
-
shouldClear:
|
|
17069
|
+
shouldClear: R && !!Pe,
|
|
17047
17070
|
onClear: st,
|
|
17048
17071
|
error: i.error,
|
|
17049
17072
|
clearButtonProps: le,
|
|
@@ -17063,7 +17086,7 @@ const defaultProps$8 = {
|
|
|
17063
17086
|
hovered: ke,
|
|
17064
17087
|
classNames: E,
|
|
17065
17088
|
styles: w,
|
|
17066
|
-
isItemSelected: (H) => H ===
|
|
17089
|
+
isItemSelected: (H) => H === Re,
|
|
17067
17090
|
uuid: a.id,
|
|
17068
17091
|
__staticSelector: "Select",
|
|
17069
17092
|
onItemHover: ve,
|
|
@@ -17192,13 +17215,13 @@ const Thumb = forwardRef$1(({
|
|
|
17192
17215
|
onBlur: w,
|
|
17193
17216
|
showLabelOnHover: A,
|
|
17194
17217
|
isHovered: P,
|
|
17195
|
-
children:
|
|
17196
|
-
disabled:
|
|
17218
|
+
children: C = null,
|
|
17219
|
+
disabled: R,
|
|
17197
17220
|
unstyled: I,
|
|
17198
17221
|
thumbSize: j,
|
|
17199
17222
|
variant: k
|
|
17200
17223
|
}, O) => {
|
|
17201
|
-
const { classes: T, cx:
|
|
17224
|
+
const { classes: T, cx: B, theme: L } = useStyles$d({ color: d, disabled: R, thumbSize: j }, { name: "Slider", classNames: m, styles: p, unstyled: I, variant: k, size: g }), [D, W] = useState$1(!1), J = v || l || D || A && P;
|
|
17202
17225
|
return /* @__PURE__ */ React__default.createElement(Box, {
|
|
17203
17226
|
tabIndex: 0,
|
|
17204
17227
|
role: "slider",
|
|
@@ -17207,7 +17230,7 @@ const Thumb = forwardRef$1(({
|
|
|
17207
17230
|
"aria-valuemin": n,
|
|
17208
17231
|
"aria-valuenow": o,
|
|
17209
17232
|
ref: O,
|
|
17210
|
-
className:
|
|
17233
|
+
className: B(T.thumb, { [T.dragging]: l }),
|
|
17211
17234
|
onFocus: () => {
|
|
17212
17235
|
W(!0), typeof E == "function" && E();
|
|
17213
17236
|
},
|
|
@@ -17218,12 +17241,12 @@ const Thumb = forwardRef$1(({
|
|
|
17218
17241
|
onMouseDown: c,
|
|
17219
17242
|
onKeyDownCapture: u,
|
|
17220
17243
|
onClick: (F) => F.stopPropagation(),
|
|
17221
|
-
style: { [
|
|
17222
|
-
},
|
|
17244
|
+
style: { [L.dir === "rtl" ? "right" : "left"]: `${a}%` }
|
|
17245
|
+
}, C, /* @__PURE__ */ React__default.createElement(Transition, {
|
|
17223
17246
|
mounted: i != null && J,
|
|
17224
17247
|
duration: b,
|
|
17225
17248
|
transition: h,
|
|
17226
|
-
timingFunction: x ||
|
|
17249
|
+
timingFunction: x || L.transitionTimingFunction
|
|
17227
17250
|
}, (F) => /* @__PURE__ */ React__default.createElement("div", {
|
|
17228
17251
|
style: F,
|
|
17229
17252
|
className: T.label
|
|
@@ -17545,15 +17568,15 @@ const defaultProps$7 = {
|
|
|
17545
17568
|
label: w,
|
|
17546
17569
|
labelTransition: A,
|
|
17547
17570
|
labelTransitionDuration: P,
|
|
17548
|
-
labelTransitionTimingFunction:
|
|
17549
|
-
labelAlwaysOn:
|
|
17571
|
+
labelTransitionTimingFunction: C,
|
|
17572
|
+
labelAlwaysOn: R,
|
|
17550
17573
|
thumbLabel: I,
|
|
17551
17574
|
showLabelOnHover: j,
|
|
17552
17575
|
thumbChildren: k,
|
|
17553
17576
|
disabled: O,
|
|
17554
17577
|
unstyled: T,
|
|
17555
|
-
thumbSize:
|
|
17556
|
-
scale:
|
|
17578
|
+
thumbSize: B,
|
|
17579
|
+
scale: L,
|
|
17557
17580
|
inverted: D,
|
|
17558
17581
|
variant: W
|
|
17559
17582
|
} = o, J = __objRest$9(o, [
|
|
@@ -17586,17 +17609,17 @@ const defaultProps$7 = {
|
|
|
17586
17609
|
"scale",
|
|
17587
17610
|
"inverted",
|
|
17588
17611
|
"variant"
|
|
17589
|
-
]), F = x ?? getPrecision(b),
|
|
17612
|
+
]), F = x ?? getPrecision(b), V = useMantineTheme(), [q, G] = useState$1(!1), [ee, z] = useUncontrolled({
|
|
17590
17613
|
value: typeof c == "number" ? clamp$1(c, g, h) : c,
|
|
17591
17614
|
defaultValue: typeof v == "number" ? clamp$1(v, g, h) : v,
|
|
17592
17615
|
finalValue: clamp$1(0, g, h),
|
|
17593
17616
|
onChange: u
|
|
17594
|
-
}), U = useRef$1(ee), te = useRef$1(), _ = useRef$1(), Q = getPosition({ value: ee, min: g, max: h }), ne =
|
|
17617
|
+
}), U = useRef$1(ee), te = useRef$1(), _ = useRef$1(), Q = getPosition({ value: ee, min: g, max: h }), ne = L(ee), re = typeof w == "function" ? w(ne) : w, $ = useCallback$1(({ x: Z }) => {
|
|
17595
17618
|
if (!O) {
|
|
17596
17619
|
const le = getChangeValue({ value: Z, min: g, max: h, step: b, precision: F });
|
|
17597
17620
|
z(le), U.current = le;
|
|
17598
17621
|
}
|
|
17599
|
-
}, [O, g, h, b, F, z]), { ref: ae, active: se } = useMove($, { onScrubEnd: () => d == null ? void 0 : d(U.current) },
|
|
17622
|
+
}, [O, g, h, b, F, z]), { ref: ae, active: se } = useMove($, { onScrubEnd: () => d == null ? void 0 : d(U.current) }, V.dir), K = (Z) => {
|
|
17600
17623
|
if (!O)
|
|
17601
17624
|
switch (Z.key) {
|
|
17602
17625
|
case "ArrowUp": {
|
|
@@ -17607,7 +17630,7 @@ const defaultProps$7 = {
|
|
|
17607
17630
|
}
|
|
17608
17631
|
case "ArrowRight": {
|
|
17609
17632
|
Z.preventDefault(), _.current.focus();
|
|
17610
|
-
const le = getFloatingValue(Math.min(Math.max(
|
|
17633
|
+
const le = getFloatingValue(Math.min(Math.max(V.dir === "rtl" ? ee - b : ee + b, g), h), F);
|
|
17611
17634
|
d == null || d(le), z(le);
|
|
17612
17635
|
break;
|
|
17613
17636
|
}
|
|
@@ -17619,7 +17642,7 @@ const defaultProps$7 = {
|
|
|
17619
17642
|
}
|
|
17620
17643
|
case "ArrowLeft": {
|
|
17621
17644
|
Z.preventDefault(), _.current.focus();
|
|
17622
|
-
const le = getFloatingValue(Math.min(Math.max(
|
|
17645
|
+
const le = getFloatingValue(Math.min(Math.max(V.dir === "rtl" ? ee + b : ee - b, g), h), F);
|
|
17623
17646
|
d == null || d(le), z(le);
|
|
17624
17647
|
break;
|
|
17625
17648
|
}
|
|
@@ -17652,7 +17675,7 @@ const defaultProps$7 = {
|
|
|
17652
17675
|
filled: Q,
|
|
17653
17676
|
marks: E,
|
|
17654
17677
|
size: m,
|
|
17655
|
-
thumbSize:
|
|
17678
|
+
thumbSize: B,
|
|
17656
17679
|
radius: p,
|
|
17657
17680
|
color: l,
|
|
17658
17681
|
min: g,
|
|
@@ -17681,8 +17704,8 @@ const defaultProps$7 = {
|
|
|
17681
17704
|
ref: _,
|
|
17682
17705
|
labelTransition: A,
|
|
17683
17706
|
labelTransitionDuration: P,
|
|
17684
|
-
labelTransitionTimingFunction:
|
|
17685
|
-
labelAlwaysOn:
|
|
17707
|
+
labelTransitionTimingFunction: C,
|
|
17708
|
+
labelAlwaysOn: R,
|
|
17686
17709
|
classNames: a,
|
|
17687
17710
|
styles: i,
|
|
17688
17711
|
thumbLabel: I,
|
|
@@ -17690,7 +17713,7 @@ const defaultProps$7 = {
|
|
|
17690
17713
|
isHovered: q,
|
|
17691
17714
|
disabled: O,
|
|
17692
17715
|
unstyled: T,
|
|
17693
|
-
thumbSize:
|
|
17716
|
+
thumbSize: B,
|
|
17694
17717
|
variant: W
|
|
17695
17718
|
}, k)), /* @__PURE__ */ React__default.createElement("input", {
|
|
17696
17719
|
type: "hidden",
|
|
@@ -17966,8 +17989,8 @@ const defaultProps$3 = {}, Tab = forwardRef$1((r, n) => {
|
|
|
17966
17989
|
classNames: h.classNames,
|
|
17967
17990
|
styles: h.styles,
|
|
17968
17991
|
variant: h.variant
|
|
17969
|
-
}), w = a === h.value, A = h.getPanelId(a), P = h.mountedPanelIds.includes(a) ? A : void 0,
|
|
17970
|
-
h.onTabChange(h.allowTabDeactivation && a === h.value ? null : a), c == null || c(
|
|
17992
|
+
}), w = a === h.value, A = h.getPanelId(a), P = h.mountedPanelIds.includes(a) ? A : void 0, C = (R) => {
|
|
17993
|
+
h.onTabChange(h.allowTabDeactivation && a === h.value ? null : a), c == null || c(R);
|
|
17971
17994
|
};
|
|
17972
17995
|
return /* @__PURE__ */ React__default.createElement(UnstyledButton, __spreadProps$5(__spreadValues$6({}, g), {
|
|
17973
17996
|
unstyled: h.unstyled,
|
|
@@ -17980,7 +18003,7 @@ const defaultProps$3 = {}, Tab = forwardRef$1((r, n) => {
|
|
|
17980
18003
|
"aria-selected": w,
|
|
17981
18004
|
tabIndex: w || h.value === null ? 0 : -1,
|
|
17982
18005
|
"aria-controls": P,
|
|
17983
|
-
onClick:
|
|
18006
|
+
onClick: C,
|
|
17984
18007
|
onKeyDown: createScopedKeydownHandler({
|
|
17985
18008
|
siblingSelector: '[role="tab"]',
|
|
17986
18009
|
parentSelector: '[role="tablist"]',
|
|
@@ -18019,7 +18042,7 @@ function TabsProvider({
|
|
|
18019
18042
|
styles: S,
|
|
18020
18043
|
unstyled: E
|
|
18021
18044
|
}) {
|
|
18022
|
-
const w = useId$2(c), [A, P] = useState$1([]), [
|
|
18045
|
+
const w = useId$2(c), [A, P] = useState$1([]), [C, R] = useUncontrolled({
|
|
18023
18046
|
value: n,
|
|
18024
18047
|
defaultValue: r,
|
|
18025
18048
|
finalValue: null,
|
|
@@ -18028,14 +18051,14 @@ function TabsProvider({
|
|
|
18028
18051
|
return /* @__PURE__ */ React__default.createElement(TabsContextProvider, {
|
|
18029
18052
|
value: {
|
|
18030
18053
|
placement: b,
|
|
18031
|
-
value:
|
|
18054
|
+
value: C,
|
|
18032
18055
|
orientation: a,
|
|
18033
18056
|
id: w,
|
|
18034
18057
|
loop: l,
|
|
18035
18058
|
activateTabWithKeyboard: u,
|
|
18036
18059
|
getTabId: getSafeId(`${w}-tab`, TABS_ERRORS.value),
|
|
18037
18060
|
getPanelId: getSafeId(`${w}-panel`, TABS_ERRORS.value),
|
|
18038
|
-
onTabChange:
|
|
18061
|
+
onTabChange: R,
|
|
18039
18062
|
setMountedPanelIds: P,
|
|
18040
18063
|
mountedPanelIds: A,
|
|
18041
18064
|
allowTabDeactivation: d,
|
|
@@ -18101,8 +18124,8 @@ const defaultProps$2 = {
|
|
|
18101
18124
|
radius: w,
|
|
18102
18125
|
inverted: A,
|
|
18103
18126
|
keepMounted: P,
|
|
18104
|
-
placement:
|
|
18105
|
-
} = o,
|
|
18127
|
+
placement: C
|
|
18128
|
+
} = o, R = __objRest$4(o, [
|
|
18106
18129
|
"defaultValue",
|
|
18107
18130
|
"value",
|
|
18108
18131
|
"orientation",
|
|
@@ -18122,7 +18145,7 @@ const defaultProps$2 = {
|
|
|
18122
18145
|
"inverted",
|
|
18123
18146
|
"keepMounted",
|
|
18124
18147
|
"placement"
|
|
18125
|
-
]), { classes: I, cx: j } = useStyles$4({ orientation: l, color: b, radius: w, inverted: A, placement:
|
|
18148
|
+
]), { classes: I, cx: j } = useStyles$4({ orientation: l, color: b, radius: w, inverted: A, placement: C }, { unstyled: v, name: "Tabs", classNames: S, styles: E, variant: h });
|
|
18126
18149
|
return /* @__PURE__ */ React__default.createElement(TabsProvider, {
|
|
18127
18150
|
activateTabWithKeyboard: u,
|
|
18128
18151
|
defaultValue: a,
|
|
@@ -18137,11 +18160,11 @@ const defaultProps$2 = {
|
|
|
18137
18160
|
radius: w,
|
|
18138
18161
|
inverted: A,
|
|
18139
18162
|
keepMounted: P,
|
|
18140
|
-
placement:
|
|
18163
|
+
placement: C,
|
|
18141
18164
|
classNames: S,
|
|
18142
18165
|
styles: E,
|
|
18143
18166
|
unstyled: v
|
|
18144
|
-
}, /* @__PURE__ */ React__default.createElement(Box, __spreadProps$4(__spreadValues$5({},
|
|
18167
|
+
}, /* @__PURE__ */ React__default.createElement(Box, __spreadProps$4(__spreadValues$5({}, R), {
|
|
18145
18168
|
className: j(I.root, x),
|
|
18146
18169
|
id: p,
|
|
18147
18170
|
ref: n
|
|
@@ -18537,8 +18560,8 @@ function stringify(r, n, o, a = {}) {
|
|
|
18537
18560
|
const w = i ? " " : "", A = i ? `
|
|
18538
18561
|
` : "";
|
|
18539
18562
|
let P = `var x${w}=${w}${E};${A}`;
|
|
18540
|
-
for (const [
|
|
18541
|
-
const I = quote_1.stringifyPath(
|
|
18563
|
+
for (const [C, R] of d.entries()) {
|
|
18564
|
+
const I = quote_1.stringifyPath(C, v), j = quote_1.stringifyPath(R, v);
|
|
18542
18565
|
P += `x${I}${w}=${w}x${j};${A}`;
|
|
18543
18566
|
}
|
|
18544
18567
|
return `(function${w}()${w}{${A}${P}return x;${A}}())`;
|
|
@@ -18594,13 +18617,13 @@ function PanelWithForwardedRef({
|
|
|
18594
18617
|
getPanelStyle: w,
|
|
18595
18618
|
registerPanel: A,
|
|
18596
18619
|
resizePanel: P,
|
|
18597
|
-
unregisterPanel:
|
|
18598
|
-
} = x,
|
|
18620
|
+
unregisterPanel: C
|
|
18621
|
+
} = x, R = useRef({
|
|
18599
18622
|
onCollapse: m,
|
|
18600
18623
|
onResize: p
|
|
18601
18624
|
});
|
|
18602
18625
|
if (useEffect(() => {
|
|
18603
|
-
|
|
18626
|
+
R.current.onCollapse = m, R.current.onResize = p;
|
|
18604
18627
|
}), d < 0 || d > 100)
|
|
18605
18628
|
throw Error(`Panel minSize must be between 0 and 100, but was ${d}`);
|
|
18606
18629
|
if (u < 0 || u > 100)
|
|
@@ -18613,7 +18636,7 @@ function PanelWithForwardedRef({
|
|
|
18613
18636
|
const I = w(v, i), j = useRef({
|
|
18614
18637
|
size: parseSizeFromStyle(I)
|
|
18615
18638
|
}), k = useRef({
|
|
18616
|
-
callbacksRef:
|
|
18639
|
+
callbacksRef: R,
|
|
18617
18640
|
collapsedSize: o,
|
|
18618
18641
|
collapsible: a,
|
|
18619
18642
|
defaultSize: i,
|
|
@@ -18624,10 +18647,10 @@ function PanelWithForwardedRef({
|
|
|
18624
18647
|
order: g
|
|
18625
18648
|
});
|
|
18626
18649
|
return useIsomorphicLayoutEffect(() => {
|
|
18627
|
-
j.current.size = parseSizeFromStyle(I), k.current.callbacksRef =
|
|
18650
|
+
j.current.size = parseSizeFromStyle(I), k.current.callbacksRef = R, k.current.collapsedSize = o, k.current.collapsible = a, k.current.defaultSize = i, k.current.id = v, k.current.idWasAutoGenerated = c == null, k.current.maxSize = u, k.current.minSize = d, k.current.order = g;
|
|
18628
18651
|
}), useIsomorphicLayoutEffect(() => (A(v, k), () => {
|
|
18629
|
-
|
|
18630
|
-
}), [g, v, A,
|
|
18652
|
+
C(v);
|
|
18653
|
+
}), [g, v, A, C]), useImperativeHandle(l, () => ({
|
|
18631
18654
|
collapse: () => S(v),
|
|
18632
18655
|
expand: () => E(v),
|
|
18633
18656
|
getCollapsed() {
|
|
@@ -18802,23 +18825,23 @@ function useWindowSplitterPanelGroupBehavior({
|
|
|
18802
18825
|
if (S == null || E == null)
|
|
18803
18826
|
return () => {
|
|
18804
18827
|
};
|
|
18805
|
-
let w = 0, A = 100, P = 0,
|
|
18828
|
+
let w = 0, A = 100, P = 0, C = 0;
|
|
18806
18829
|
v.forEach((T) => {
|
|
18807
|
-
T.current.id === S ? (A = T.current.maxSize, w = T.current.minSize) : (P += T.current.minSize,
|
|
18830
|
+
T.current.id === S ? (A = T.current.maxSize, w = T.current.minSize) : (P += T.current.minSize, C += T.current.maxSize);
|
|
18808
18831
|
});
|
|
18809
|
-
const
|
|
18810
|
-
b.setAttribute("aria-valuemax", "" + Math.round(
|
|
18832
|
+
const R = Math.min(A, 100 - P), I = Math.max(w, (v.length - 1) * 100 - C), j = getFlexGrow(u, S, i);
|
|
18833
|
+
b.setAttribute("aria-valuemax", "" + Math.round(R)), b.setAttribute("aria-valuemin", "" + Math.round(I)), b.setAttribute("aria-valuenow", "" + Math.round(parseInt(j)));
|
|
18811
18834
|
const k = (T) => {
|
|
18812
18835
|
if (!T.defaultPrevented)
|
|
18813
18836
|
switch (T.key) {
|
|
18814
18837
|
case "Enter": {
|
|
18815
18838
|
T.preventDefault();
|
|
18816
|
-
const
|
|
18817
|
-
if (
|
|
18818
|
-
const
|
|
18839
|
+
const B = v.findIndex((L) => L.current.id === S);
|
|
18840
|
+
if (B >= 0) {
|
|
18841
|
+
const L = v[B], D = i[B];
|
|
18819
18842
|
if (D != null) {
|
|
18820
18843
|
let W = 0;
|
|
18821
|
-
D.toPrecision(PRECISION) <=
|
|
18844
|
+
D.toPrecision(PRECISION) <= L.current.minSize.toPrecision(PRECISION) ? W = c === "horizontal" ? p : m : W = -(c === "horizontal" ? p : m);
|
|
18822
18845
|
const J = adjustByDelta(T, u, S, E, W, i, l.current, null);
|
|
18823
18846
|
i !== J && a(J);
|
|
18824
18847
|
}
|
|
@@ -18926,10 +18949,10 @@ function getMovement(r, n, o, a, i, l, c) {
|
|
|
18926
18949
|
E = -x;
|
|
18927
18950
|
break;
|
|
18928
18951
|
}
|
|
18929
|
-
const [w, A] = getResizeHandlePanelIds(n, o, a), P = E < 0 ? w : A,
|
|
18930
|
-
if (
|
|
18931
|
-
const I = p[
|
|
18932
|
-
(I === 0 || I.toPrecision(PRECISION) ===
|
|
18952
|
+
const [w, A] = getResizeHandlePanelIds(n, o, a), P = E < 0 ? w : A, C = a.findIndex((I) => I.current.id === P), R = a[C];
|
|
18953
|
+
if (R.current.collapsible) {
|
|
18954
|
+
const I = p[C];
|
|
18955
|
+
(I === 0 || I.toPrecision(PRECISION) === R.current.minSize.toPrecision(PRECISION)) && (E = E < 0 ? -R.current.minSize * x : R.current.minSize * x);
|
|
18933
18956
|
}
|
|
18934
18957
|
return E;
|
|
18935
18958
|
} else
|
|
@@ -19062,7 +19085,7 @@ function PanelGroupWithForwardedRef({
|
|
|
19062
19085
|
useEffect(() => {
|
|
19063
19086
|
E.current.onLayout = u;
|
|
19064
19087
|
});
|
|
19065
|
-
const w = useRef({}), [A, P] = useState([]),
|
|
19088
|
+
const w = useRef({}), [A, P] = useState([]), C = useRef(/* @__PURE__ */ new Map()), R = useRef(0), I = useRef({
|
|
19066
19089
|
direction: a,
|
|
19067
19090
|
panels: x,
|
|
19068
19091
|
sizes: A
|
|
@@ -19075,8 +19098,8 @@ function PanelGroupWithForwardedRef({
|
|
|
19075
19098
|
return F;
|
|
19076
19099
|
},
|
|
19077
19100
|
setLayout: (F) => {
|
|
19078
|
-
const
|
|
19079
|
-
assert(
|
|
19101
|
+
const V = F.reduce((z, U) => z + U, 0);
|
|
19102
|
+
assert(V === 100, "Panel sizes must add up to 100%");
|
|
19080
19103
|
const {
|
|
19081
19104
|
panels: q
|
|
19082
19105
|
} = I.current, G = w.current, ee = panelsMapToSortedArray(q);
|
|
@@ -19090,29 +19113,29 @@ function PanelGroupWithForwardedRef({
|
|
|
19090
19113
|
panels: x,
|
|
19091
19114
|
setSizes: P,
|
|
19092
19115
|
sizes: A,
|
|
19093
|
-
panelSizeBeforeCollapse:
|
|
19116
|
+
panelSizeBeforeCollapse: C
|
|
19094
19117
|
}), useEffect(() => {
|
|
19095
19118
|
const {
|
|
19096
19119
|
onLayout: F
|
|
19097
19120
|
} = E.current, {
|
|
19098
|
-
panels:
|
|
19121
|
+
panels: V,
|
|
19099
19122
|
sizes: q
|
|
19100
19123
|
} = I.current;
|
|
19101
19124
|
if (q.length > 0) {
|
|
19102
19125
|
F && F(q);
|
|
19103
|
-
const G = w.current, ee = panelsMapToSortedArray(
|
|
19126
|
+
const G = w.current, ee = panelsMapToSortedArray(V);
|
|
19104
19127
|
callPanelCallbacks(ee, q, G);
|
|
19105
19128
|
}
|
|
19106
19129
|
}, [A]), useIsomorphicLayoutEffect(() => {
|
|
19107
19130
|
if (I.current.sizes.length === x.size)
|
|
19108
19131
|
return;
|
|
19109
|
-
let
|
|
19132
|
+
let V = null;
|
|
19110
19133
|
if (r) {
|
|
19111
19134
|
const q = panelsMapToSortedArray(x);
|
|
19112
|
-
|
|
19135
|
+
V = loadPanelLayout(r, q, d);
|
|
19113
19136
|
}
|
|
19114
|
-
if (
|
|
19115
|
-
P(
|
|
19137
|
+
if (V != null)
|
|
19138
|
+
P(V);
|
|
19116
19139
|
else {
|
|
19117
19140
|
const q = panelsMapToSortedArray(x);
|
|
19118
19141
|
let G = 0, ee = 0, z = 0;
|
|
@@ -19134,13 +19157,13 @@ function PanelGroupWithForwardedRef({
|
|
|
19134
19157
|
debounceMap[r] || (debounceMap[r] = debounce(savePanelGroupLayout, 100)), debounceMap[r](r, F, A, d);
|
|
19135
19158
|
}
|
|
19136
19159
|
}, [r, x, A, d]);
|
|
19137
|
-
const j = useCallback((F,
|
|
19160
|
+
const j = useCallback((F, V) => {
|
|
19138
19161
|
const {
|
|
19139
19162
|
panels: q
|
|
19140
19163
|
} = I.current;
|
|
19141
19164
|
return q.size === 0 ? {
|
|
19142
19165
|
flexBasis: 0,
|
|
19143
|
-
flexGrow:
|
|
19166
|
+
flexGrow: V ?? void 0,
|
|
19144
19167
|
flexShrink: 1,
|
|
19145
19168
|
// Without this, Panel sizes may be unintentionally overridden by their content.
|
|
19146
19169
|
overflow: "hidden"
|
|
@@ -19154,12 +19177,12 @@ function PanelGroupWithForwardedRef({
|
|
|
19154
19177
|
// This avoid edge cases like nested iframes.
|
|
19155
19178
|
pointerEvents: i && h !== null ? "none" : void 0
|
|
19156
19179
|
};
|
|
19157
|
-
}, [h, i, A]), k = useCallback((F,
|
|
19180
|
+
}, [h, i, A]), k = useCallback((F, V) => {
|
|
19158
19181
|
v((q) => {
|
|
19159
19182
|
if (q.has(F))
|
|
19160
19183
|
return q;
|
|
19161
19184
|
const G = new Map(q);
|
|
19162
|
-
return G.set(F,
|
|
19185
|
+
return G.set(F, V), G;
|
|
19163
19186
|
});
|
|
19164
19187
|
}, []), O = useCallback((F) => (q) => {
|
|
19165
19188
|
q.preventDefault();
|
|
@@ -19175,24 +19198,24 @@ function PanelGroupWithForwardedRef({
|
|
|
19175
19198
|
return;
|
|
19176
19199
|
const re = getPanelGroup(g).getBoundingClientRect(), $ = G === "horizontal";
|
|
19177
19200
|
document.dir === "rtl" && $ && (Q = -Q);
|
|
19178
|
-
const ae = $ ? re.width : re.height, se = Q / ae * 100, K = adjustByDelta(q, ee, te, _, se, z,
|
|
19179
|
-
if ((isMouseEvent(q) || isTouchEvent(q)) &&
|
|
19201
|
+
const ae = $ ? re.width : re.height, se = Q / ae * 100, K = adjustByDelta(q, ee, te, _, se, z, C.current, S.current), Z = !areEqual(z, K);
|
|
19202
|
+
if ((isMouseEvent(q) || isTouchEvent(q)) && R.current != se && setGlobalCursorStyle(Z ? $ ? "horizontal" : "vertical" : $ ? Q < 0 ? "horizontal-min" : "horizontal-max" : Q < 0 ? "vertical-min" : "vertical-max"), Z) {
|
|
19180
19203
|
const le = w.current;
|
|
19181
19204
|
P(K), callPanelCallbacks(U, K, le);
|
|
19182
19205
|
}
|
|
19183
|
-
|
|
19206
|
+
R.current = se;
|
|
19184
19207
|
}, [g]), T = useCallback((F) => {
|
|
19185
|
-
v((
|
|
19186
|
-
if (!
|
|
19187
|
-
return
|
|
19188
|
-
const q = new Map(
|
|
19208
|
+
v((V) => {
|
|
19209
|
+
if (!V.has(F))
|
|
19210
|
+
return V;
|
|
19211
|
+
const q = new Map(V);
|
|
19189
19212
|
return q.delete(F), q;
|
|
19190
19213
|
});
|
|
19191
|
-
}, []),
|
|
19214
|
+
}, []), B = useCallback((F) => {
|
|
19192
19215
|
const {
|
|
19193
|
-
panels:
|
|
19216
|
+
panels: V,
|
|
19194
19217
|
sizes: q
|
|
19195
|
-
} = I.current, G =
|
|
19218
|
+
} = I.current, G = V.get(F);
|
|
19196
19219
|
if (G == null)
|
|
19197
19220
|
return;
|
|
19198
19221
|
const {
|
|
@@ -19201,46 +19224,46 @@ function PanelGroupWithForwardedRef({
|
|
|
19201
19224
|
} = G.current;
|
|
19202
19225
|
if (!z)
|
|
19203
19226
|
return;
|
|
19204
|
-
const U = panelsMapToSortedArray(
|
|
19227
|
+
const U = panelsMapToSortedArray(V), te = U.indexOf(G);
|
|
19205
19228
|
if (te < 0)
|
|
19206
19229
|
return;
|
|
19207
19230
|
const _ = q[te];
|
|
19208
19231
|
if (_ === ee)
|
|
19209
19232
|
return;
|
|
19210
|
-
|
|
19233
|
+
C.current.set(F, _);
|
|
19211
19234
|
const [Q, ne] = getBeforeAndAfterIds(F, U);
|
|
19212
19235
|
if (Q == null || ne == null)
|
|
19213
19236
|
return;
|
|
19214
|
-
const $ = te === U.length - 1 ? _ : ee - _, ae = adjustByDelta(null,
|
|
19237
|
+
const $ = te === U.length - 1 ? _ : ee - _, ae = adjustByDelta(null, V, Q, ne, $, q, C.current, null);
|
|
19215
19238
|
if (q !== ae) {
|
|
19216
19239
|
const se = w.current;
|
|
19217
19240
|
P(ae), callPanelCallbacks(U, ae, se);
|
|
19218
19241
|
}
|
|
19219
|
-
}, []),
|
|
19242
|
+
}, []), L = useCallback((F) => {
|
|
19220
19243
|
const {
|
|
19221
|
-
panels:
|
|
19244
|
+
panels: V,
|
|
19222
19245
|
sizes: q
|
|
19223
|
-
} = I.current, G =
|
|
19246
|
+
} = I.current, G = V.get(F);
|
|
19224
19247
|
if (G == null)
|
|
19225
19248
|
return;
|
|
19226
19249
|
const {
|
|
19227
19250
|
collapsedSize: ee,
|
|
19228
19251
|
minSize: z
|
|
19229
|
-
} = G.current, U =
|
|
19252
|
+
} = G.current, U = C.current.get(F) || z;
|
|
19230
19253
|
if (!U)
|
|
19231
19254
|
return;
|
|
19232
|
-
const te = panelsMapToSortedArray(
|
|
19255
|
+
const te = panelsMapToSortedArray(V), _ = te.indexOf(G);
|
|
19233
19256
|
if (_ < 0 || q[_] !== ee)
|
|
19234
19257
|
return;
|
|
19235
19258
|
const [ne, re] = getBeforeAndAfterIds(F, te);
|
|
19236
19259
|
if (ne == null || re == null)
|
|
19237
19260
|
return;
|
|
19238
|
-
const ae = _ === te.length - 1 ? ee - U : U, se = adjustByDelta(null,
|
|
19261
|
+
const ae = _ === te.length - 1 ? ee - U : U, se = adjustByDelta(null, V, ne, re, ae, q, C.current, null);
|
|
19239
19262
|
if (q !== se) {
|
|
19240
19263
|
const K = w.current;
|
|
19241
19264
|
P(se), callPanelCallbacks(te, se, K);
|
|
19242
19265
|
}
|
|
19243
|
-
}, []), D = useCallback((F,
|
|
19266
|
+
}, []), D = useCallback((F, V) => {
|
|
19244
19267
|
const {
|
|
19245
19268
|
panels: q,
|
|
19246
19269
|
sizes: G
|
|
@@ -19256,33 +19279,33 @@ function PanelGroupWithForwardedRef({
|
|
|
19256
19279
|
if (ne < 0)
|
|
19257
19280
|
return;
|
|
19258
19281
|
const re = G[ne];
|
|
19259
|
-
if (re ===
|
|
19282
|
+
if (re === V)
|
|
19260
19283
|
return;
|
|
19261
|
-
U &&
|
|
19284
|
+
U && V === z || (V = Math.min(te, Math.max(_, V)));
|
|
19262
19285
|
const [$, ae] = getBeforeAndAfterIds(F, Q);
|
|
19263
19286
|
if ($ == null || ae == null)
|
|
19264
19287
|
return;
|
|
19265
|
-
const K = ne === Q.length - 1 ? re -
|
|
19288
|
+
const K = ne === Q.length - 1 ? re - V : V - re, Z = adjustByDelta(null, q, $, ae, K, G, C.current, null);
|
|
19266
19289
|
if (G !== Z) {
|
|
19267
19290
|
const le = w.current;
|
|
19268
19291
|
P(Z), callPanelCallbacks(Q, Z, le);
|
|
19269
19292
|
}
|
|
19270
19293
|
}, []), W = useMemo(() => ({
|
|
19271
19294
|
activeHandleId: h,
|
|
19272
|
-
collapsePanel:
|
|
19295
|
+
collapsePanel: B,
|
|
19273
19296
|
direction: a,
|
|
19274
|
-
expandPanel:
|
|
19297
|
+
expandPanel: L,
|
|
19275
19298
|
getPanelStyle: j,
|
|
19276
19299
|
groupId: g,
|
|
19277
19300
|
registerPanel: k,
|
|
19278
19301
|
registerResizeHandle: O,
|
|
19279
19302
|
resizePanel: D,
|
|
19280
|
-
startDragging: (F,
|
|
19281
|
-
if (b(F), isMouseEvent(
|
|
19303
|
+
startDragging: (F, V) => {
|
|
19304
|
+
if (b(F), isMouseEvent(V) || isTouchEvent(V)) {
|
|
19282
19305
|
const q = getResizeHandle(F);
|
|
19283
19306
|
S.current = {
|
|
19284
19307
|
dragHandleRect: q.getBoundingClientRect(),
|
|
19285
|
-
dragOffset: getDragOffset(
|
|
19308
|
+
dragOffset: getDragOffset(V, F, a),
|
|
19286
19309
|
sizes: I.current.sizes
|
|
19287
19310
|
};
|
|
19288
19311
|
}
|
|
@@ -19291,7 +19314,7 @@ function PanelGroupWithForwardedRef({
|
|
|
19291
19314
|
resetGlobalCursorStyle(), b(null), S.current = null;
|
|
19292
19315
|
},
|
|
19293
19316
|
unregisterPanel: T
|
|
19294
|
-
}), [h,
|
|
19317
|
+
}), [h, B, a, L, j, g, k, O, D, T]), J = {
|
|
19295
19318
|
display: "flex",
|
|
19296
19319
|
flexDirection: a === "horizontal" ? "row" : "column",
|
|
19297
19320
|
height: "100%",
|
|
@@ -19344,7 +19367,7 @@ function PanelResizeHandle$1({
|
|
|
19344
19367
|
registerResizeHandle: b,
|
|
19345
19368
|
startDragging: x,
|
|
19346
19369
|
stopDragging: v
|
|
19347
|
-
} = m, S = useUniqueId(a), E = p === S, [w, A] = useState(!1), [P,
|
|
19370
|
+
} = m, S = useUniqueId(a), E = p === S, [w, A] = useState(!1), [P, C] = useState(null), R = useCallback(() => {
|
|
19348
19371
|
u.current.blur(), v();
|
|
19349
19372
|
const {
|
|
19350
19373
|
onDragging: k
|
|
@@ -19353,23 +19376,23 @@ function PanelResizeHandle$1({
|
|
|
19353
19376
|
}, [v]);
|
|
19354
19377
|
useEffect(() => {
|
|
19355
19378
|
if (o)
|
|
19356
|
-
|
|
19379
|
+
C(null);
|
|
19357
19380
|
else {
|
|
19358
19381
|
const j = b(S);
|
|
19359
|
-
|
|
19382
|
+
C(() => j);
|
|
19360
19383
|
}
|
|
19361
19384
|
}, [o, S, b]), useEffect(() => {
|
|
19362
19385
|
if (o || P == null || !E)
|
|
19363
19386
|
return;
|
|
19364
|
-
const j = (
|
|
19365
|
-
P(
|
|
19366
|
-
}, k = (
|
|
19367
|
-
P(
|
|
19387
|
+
const j = (B) => {
|
|
19388
|
+
P(B);
|
|
19389
|
+
}, k = (B) => {
|
|
19390
|
+
P(B);
|
|
19368
19391
|
}, T = u.current.ownerDocument;
|
|
19369
|
-
return T.body.addEventListener("contextmenu",
|
|
19370
|
-
T.body.removeEventListener("contextmenu",
|
|
19392
|
+
return T.body.addEventListener("contextmenu", R), T.body.addEventListener("mousemove", j), T.body.addEventListener("touchmove", j), T.body.addEventListener("mouseleave", k), window.addEventListener("mouseup", R), window.addEventListener("touchend", R), () => {
|
|
19393
|
+
T.body.removeEventListener("contextmenu", R), T.body.removeEventListener("mousemove", j), T.body.removeEventListener("touchmove", j), T.body.removeEventListener("mouseleave", k), window.removeEventListener("mouseup", R), window.removeEventListener("touchend", R);
|
|
19371
19394
|
};
|
|
19372
|
-
}, [g, o, E, P,
|
|
19395
|
+
}, [g, o, E, P, R]), useWindowSplitterResizeHandlerBehavior({
|
|
19373
19396
|
disabled: o,
|
|
19374
19397
|
handleId: S,
|
|
19375
19398
|
resizeHandler: P
|
|
@@ -19396,9 +19419,9 @@ function PanelResizeHandle$1({
|
|
|
19396
19419
|
} = d.current;
|
|
19397
19420
|
k && k(!0);
|
|
19398
19421
|
},
|
|
19399
|
-
onMouseUp:
|
|
19400
|
-
onTouchCancel:
|
|
19401
|
-
onTouchEnd:
|
|
19422
|
+
onMouseUp: R,
|
|
19423
|
+
onTouchCancel: R,
|
|
19424
|
+
onTouchEnd: R,
|
|
19402
19425
|
onTouchStart: (j) => {
|
|
19403
19426
|
x(S, j.nativeEvent);
|
|
19404
19427
|
const {
|
|
@@ -19604,17 +19627,17 @@ function JSONNestedNode(r) {
|
|
|
19604
19627
|
...r,
|
|
19605
19628
|
circularCache: n,
|
|
19606
19629
|
level: g + 1
|
|
19607
|
-
}) : null, P = /* @__PURE__ */ React__default.createElement("span", v("nestedNodeItemType", S), b),
|
|
19608
|
-
return u ? /* @__PURE__ */ React__default.createElement("li", v("rootNode", ...
|
|
19630
|
+
}) : null, P = /* @__PURE__ */ React__default.createElement("span", v("nestedNodeItemType", S), b), C = c(h, i, P, a(i, o), m), R = [m, h, S, l];
|
|
19631
|
+
return u ? /* @__PURE__ */ React__default.createElement("li", v("rootNode", ...R), /* @__PURE__ */ React__default.createElement("ul", v("rootNodeChildren", ...R), A)) : /* @__PURE__ */ React__default.createElement("li", v("nestedNode", ...R), l && /* @__PURE__ */ React__default.createElement(JSONArrow, {
|
|
19609
19632
|
styling: v,
|
|
19610
19633
|
nodeType: h,
|
|
19611
19634
|
expanded: S,
|
|
19612
19635
|
onClick: w
|
|
19613
|
-
}), /* @__PURE__ */ React__default.createElement("label", _extends$1({}, v(["label", "nestedNodeLabel"], ...
|
|
19636
|
+
}), /* @__PURE__ */ React__default.createElement("label", _extends$1({}, v(["label", "nestedNodeLabel"], ...R), {
|
|
19614
19637
|
onClick: w
|
|
19615
|
-
}), p(...
|
|
19638
|
+
}), p(...R)), /* @__PURE__ */ React__default.createElement("span", _extends$1({}, v("nestedNodeItemString", ...R), {
|
|
19616
19639
|
onClick: w
|
|
19617
|
-
}),
|
|
19640
|
+
}), C), /* @__PURE__ */ React__default.createElement("ul", v("nestedNodeChildren", ...R), A));
|
|
19618
19641
|
}
|
|
19619
19642
|
function createItemString$2(r) {
|
|
19620
19643
|
const n = Object.getOwnPropertyNames(r).length;
|
|
@@ -21796,9 +21819,9 @@ function createHybrid(r, n, o, a, i, l, c, u, d, m) {
|
|
|
21796
21819
|
for (var E = arguments.length, w = Array(E), A = E; A--; )
|
|
21797
21820
|
w[A] = arguments[A];
|
|
21798
21821
|
if (b)
|
|
21799
|
-
var P = getHolder(S),
|
|
21800
|
-
if (a && (w = composeArgs(w, a, i, b)), l && (w = composeArgsRight(w, l, c, b)), E -=
|
|
21801
|
-
var
|
|
21822
|
+
var P = getHolder(S), C = countHolders(w, P);
|
|
21823
|
+
if (a && (w = composeArgs(w, a, i, b)), l && (w = composeArgsRight(w, l, c, b)), E -= C, b && E < m) {
|
|
21824
|
+
var R = replaceHolders(w, P);
|
|
21802
21825
|
return createRecurry(
|
|
21803
21826
|
r,
|
|
21804
21827
|
n,
|
|
@@ -21806,7 +21829,7 @@ function createHybrid(r, n, o, a, i, l, c, u, d, m) {
|
|
|
21806
21829
|
S.placeholder,
|
|
21807
21830
|
o,
|
|
21808
21831
|
w,
|
|
21809
|
-
|
|
21832
|
+
R,
|
|
21810
21833
|
u,
|
|
21811
21834
|
d,
|
|
21812
21835
|
m - E
|
|
@@ -22676,8 +22699,8 @@ var Prism$1 = function() {
|
|
|
22676
22699
|
b.hasOwnProperty(E) || (S[E] = v[E]);
|
|
22677
22700
|
}
|
|
22678
22701
|
var A = x[g];
|
|
22679
|
-
return x[g] = S, a.languages.DFS(a.languages, function(P,
|
|
22680
|
-
|
|
22702
|
+
return x[g] = S, a.languages.DFS(a.languages, function(P, C) {
|
|
22703
|
+
C === A && P != g && (this[P] = S);
|
|
22681
22704
|
}), S;
|
|
22682
22705
|
},
|
|
22683
22706
|
// Traverse a language definition with Depth First Search
|
|
@@ -22839,41 +22862,41 @@ var Prism$1 = function() {
|
|
|
22839
22862
|
for (var A = 0; A < w.length; ++A) {
|
|
22840
22863
|
if (S && S.cause == E + "," + A)
|
|
22841
22864
|
return;
|
|
22842
|
-
var P = w[A],
|
|
22865
|
+
var P = w[A], C = P.inside, R = !!P.lookbehind, I = !!P.greedy, j = P.alias;
|
|
22843
22866
|
if (I && !P.pattern.global) {
|
|
22844
22867
|
var k = P.pattern.toString().match(/[imsuy]*$/)[0];
|
|
22845
22868
|
P.pattern = RegExp(P.pattern.source, k + "g");
|
|
22846
22869
|
}
|
|
22847
|
-
for (var O = P.pattern || P, T = x.next,
|
|
22848
|
-
var
|
|
22870
|
+
for (var O = P.pattern || P, T = x.next, B = v; T !== h.tail && !(S && B >= S.reach); B += T.value.length, T = T.next) {
|
|
22871
|
+
var L = T.value;
|
|
22849
22872
|
if (h.length > g.length)
|
|
22850
22873
|
return;
|
|
22851
|
-
if (!(
|
|
22874
|
+
if (!(L instanceof i)) {
|
|
22852
22875
|
var D = 1, W;
|
|
22853
22876
|
if (I) {
|
|
22854
|
-
if (W = l(O,
|
|
22877
|
+
if (W = l(O, B, g, R), !W || W.index >= g.length)
|
|
22855
22878
|
break;
|
|
22856
|
-
var q = W.index, J = W.index + W[0].length, F =
|
|
22879
|
+
var q = W.index, J = W.index + W[0].length, F = B;
|
|
22857
22880
|
for (F += T.value.length; q >= F; )
|
|
22858
22881
|
T = T.next, F += T.value.length;
|
|
22859
|
-
if (F -= T.value.length,
|
|
22882
|
+
if (F -= T.value.length, B = F, T.value instanceof i)
|
|
22860
22883
|
continue;
|
|
22861
|
-
for (var
|
|
22862
|
-
D++, F +=
|
|
22863
|
-
D--,
|
|
22864
|
-
} else if (W = l(O, 0,
|
|
22884
|
+
for (var V = T; V !== h.tail && (F < J || typeof V.value == "string"); V = V.next)
|
|
22885
|
+
D++, F += V.value.length;
|
|
22886
|
+
D--, L = g.slice(B, F), W.index -= B;
|
|
22887
|
+
} else if (W = l(O, 0, L, R), !W)
|
|
22865
22888
|
continue;
|
|
22866
|
-
var q = W.index, G = W[0], ee =
|
|
22889
|
+
var q = W.index, G = W[0], ee = L.slice(0, q), z = L.slice(q + G.length), U = B + L.length;
|
|
22867
22890
|
S && U > S.reach && (S.reach = U);
|
|
22868
22891
|
var te = T.prev;
|
|
22869
|
-
ee && (te = d(h, te, ee),
|
|
22870
|
-
var _ = new i(E,
|
|
22892
|
+
ee && (te = d(h, te, ee), B += ee.length), m(h, te, D);
|
|
22893
|
+
var _ = new i(E, C ? a.tokenize(G, C) : G, j, G);
|
|
22871
22894
|
if (T = d(h, te, _), z && d(h, T, z), D > 1) {
|
|
22872
22895
|
var Q = {
|
|
22873
22896
|
cause: E + "," + A,
|
|
22874
22897
|
reach: U
|
|
22875
22898
|
};
|
|
22876
|
-
c(g, h, b, T.prev,
|
|
22899
|
+
c(g, h, b, T.prev, B, Q), S && Q.reach > S.reach && (S.reach = Q.reach);
|
|
22877
22900
|
}
|
|
22878
22901
|
}
|
|
22879
22902
|
}
|
|
@@ -24357,34 +24380,34 @@ prism.languages.sql = {
|
|
|
24357
24380
|
for (var j = I.content, k; b.indexOf(k = u(E++, v)) !== -1; )
|
|
24358
24381
|
;
|
|
24359
24382
|
return w[k] = j, k;
|
|
24360
|
-
}).join(""), P = d(A, x, v),
|
|
24383
|
+
}).join(""), P = d(A, x, v), C = Object.keys(w);
|
|
24361
24384
|
E = 0;
|
|
24362
|
-
function
|
|
24385
|
+
function R(I) {
|
|
24363
24386
|
for (var j = 0; j < I.length; j++) {
|
|
24364
|
-
if (E >=
|
|
24387
|
+
if (E >= C.length)
|
|
24365
24388
|
return;
|
|
24366
24389
|
var k = I[j];
|
|
24367
24390
|
if (typeof k == "string" || typeof k.content == "string") {
|
|
24368
|
-
var O =
|
|
24391
|
+
var O = C[E], T = typeof k == "string" ? k : (
|
|
24369
24392
|
/** @type {string} */
|
|
24370
24393
|
k.content
|
|
24371
|
-
),
|
|
24372
|
-
if (
|
|
24394
|
+
), B = T.indexOf(O);
|
|
24395
|
+
if (B !== -1) {
|
|
24373
24396
|
++E;
|
|
24374
|
-
var
|
|
24375
|
-
if (
|
|
24397
|
+
var L = T.substring(0, B), D = m(w[O]), W = T.substring(B + O.length), J = [];
|
|
24398
|
+
if (L && J.push(L), J.push(D), W) {
|
|
24376
24399
|
var F = [W];
|
|
24377
|
-
|
|
24400
|
+
R(F), J.push.apply(J, F);
|
|
24378
24401
|
}
|
|
24379
24402
|
typeof k == "string" ? (I.splice.apply(I, [j, 1].concat(J)), j += J.length - 1) : k.content = J;
|
|
24380
24403
|
}
|
|
24381
24404
|
} else {
|
|
24382
|
-
var
|
|
24383
|
-
Array.isArray(
|
|
24405
|
+
var V = k.content;
|
|
24406
|
+
Array.isArray(V) ? R(V) : R([V]);
|
|
24384
24407
|
}
|
|
24385
24408
|
}
|
|
24386
24409
|
}
|
|
24387
|
-
return
|
|
24410
|
+
return R(P), new r.Token(v, P, "language-" + v, b);
|
|
24388
24411
|
}
|
|
24389
24412
|
var g = {
|
|
24390
24413
|
javascript: !0,
|
|
@@ -24409,10 +24432,10 @@ prism.languages.sql = {
|
|
|
24409
24432
|
if (w.type === "template-string") {
|
|
24410
24433
|
var P = A[1];
|
|
24411
24434
|
if (A.length === 3 && typeof P != "string" && P.type === "embedded-code") {
|
|
24412
|
-
var
|
|
24435
|
+
var C = h(P), R = P.alias, I = Array.isArray(R) ? R[0] : R, j = r.languages[I];
|
|
24413
24436
|
if (!j)
|
|
24414
24437
|
continue;
|
|
24415
|
-
A[1] = p(
|
|
24438
|
+
A[1] = p(C, j, I);
|
|
24416
24439
|
}
|
|
24417
24440
|
} else
|
|
24418
24441
|
x(A);
|
|
@@ -25880,11 +25903,11 @@ const prismDefaultProps = {
|
|
|
25880
25903
|
"radius",
|
|
25881
25904
|
"getPrismTheme",
|
|
25882
25905
|
"variant"
|
|
25883
|
-
]),
|
|
25906
|
+
]), C = v && typeof i == "string" ? i.trim() : i, R = C.split(`
|
|
25884
25907
|
`).length.toString().length, I = useMantineTheme(), j = useClipboard(), k = x || I.colorScheme, { classes: O, cx: T } = useStyles$2({
|
|
25885
25908
|
colorScheme: k,
|
|
25886
25909
|
native: b !== ScrollArea,
|
|
25887
|
-
maxLineSize:
|
|
25910
|
+
maxLineSize: R,
|
|
25888
25911
|
radius: E
|
|
25889
25912
|
}, { name: "Prism", classNames: u, styles: d, unstyled: S, variant: A });
|
|
25890
25913
|
return /* @__PURE__ */ React__default.createElement(Box, __spreadProps$2(__spreadValues$2({
|
|
@@ -25903,17 +25926,17 @@ const prismDefaultProps = {
|
|
|
25903
25926
|
}, /* @__PURE__ */ React__default.createElement(ActionIcon, {
|
|
25904
25927
|
className: O.copy,
|
|
25905
25928
|
"aria-label": j.copied ? p : m,
|
|
25906
|
-
onClick: () => j.copy(
|
|
25929
|
+
onClick: () => j.copy(C),
|
|
25907
25930
|
unstyled: S
|
|
25908
25931
|
}, /* @__PURE__ */ React__default.createElement(CopyIcon, {
|
|
25909
25932
|
copied: j.copied
|
|
25910
25933
|
}))), /* @__PURE__ */ React__default.createElement(Highlight$1, __spreadProps$2(__spreadValues$2({}, defaultProps), {
|
|
25911
25934
|
theme: w(I, k),
|
|
25912
|
-
code:
|
|
25935
|
+
code: C,
|
|
25913
25936
|
language: l
|
|
25914
25937
|
}), ({
|
|
25915
|
-
className:
|
|
25916
|
-
style:
|
|
25938
|
+
className: B,
|
|
25939
|
+
style: L,
|
|
25917
25940
|
tokens: D,
|
|
25918
25941
|
getLineProps: W,
|
|
25919
25942
|
getTokenProps: J
|
|
@@ -25921,15 +25944,15 @@ const prismDefaultProps = {
|
|
|
25921
25944
|
className: O.scrollArea,
|
|
25922
25945
|
dir: "ltr"
|
|
25923
25946
|
}, /* @__PURE__ */ React__default.createElement("pre", {
|
|
25924
|
-
className: T(O.code,
|
|
25925
|
-
style:
|
|
25947
|
+
className: T(O.code, B),
|
|
25948
|
+
style: L,
|
|
25926
25949
|
dir: "ltr"
|
|
25927
|
-
}, D.map((F,
|
|
25950
|
+
}, D.map((F, V) => {
|
|
25928
25951
|
var q, G, ee, z;
|
|
25929
|
-
if (
|
|
25952
|
+
if (V === D.length - 1 && F.length === 1 && F[0].content === `
|
|
25930
25953
|
`)
|
|
25931
25954
|
return null;
|
|
25932
|
-
const U =
|
|
25955
|
+
const U = V + 1, te = W({ line: F, key: V }), _ = U in h, Q = k === "dark" ? I.fn.rgba(I.fn.themeColor((q = h[U]) == null ? void 0 : q.color, 9), 0.25) : I.fn.themeColor((G = h[U]) == null ? void 0 : G.color, 0);
|
|
25933
25956
|
return /* @__PURE__ */ React__default.createElement("div", __spreadProps$2(__spreadValues$2({}, te), {
|
|
25934
25957
|
className: T(O.line, te.className),
|
|
25935
25958
|
style: __spreadValues$2({}, _ ? { backgroundColor: Q } : null)
|
|
@@ -26158,10 +26181,10 @@ var diffMatchPatch = { exports: {} };
|
|
|
26158
26181
|
for (var d = l.length, m = c.length, p = Math.ceil((d + m) / 2), g = p, h = 2 * p, b = new Array(h), x = new Array(h), v = 0; v < h; v++)
|
|
26159
26182
|
b[v] = -1, x[v] = -1;
|
|
26160
26183
|
b[g + 1] = 0, x[g + 1] = 0;
|
|
26161
|
-
for (var S = d - m, E = S % 2 != 0, w = 0, A = 0, P = 0,
|
|
26162
|
-
for (var I = -
|
|
26184
|
+
for (var S = d - m, E = S % 2 != 0, w = 0, A = 0, P = 0, C = 0, R = 0; R < p && !((/* @__PURE__ */ new Date()).getTime() > u); R++) {
|
|
26185
|
+
for (var I = -R + w; I <= R - A; I += 2) {
|
|
26163
26186
|
var j = g + I, k;
|
|
26164
|
-
I == -
|
|
26187
|
+
I == -R || I != R && b[j - 1] < b[j + 1] ? k = b[j + 1] : k = b[j - 1] + 1;
|
|
26165
26188
|
for (var O = k - I; k < d && O < m && l.charAt(k) == c.charAt(O); )
|
|
26166
26189
|
k++, O++;
|
|
26167
26190
|
if (b[j] = k, k > d)
|
|
@@ -26171,26 +26194,26 @@ var diffMatchPatch = { exports: {} };
|
|
|
26171
26194
|
else if (E) {
|
|
26172
26195
|
var T = g + S - I;
|
|
26173
26196
|
if (T >= 0 && T < h && x[T] != -1) {
|
|
26174
|
-
var
|
|
26175
|
-
if (k >=
|
|
26197
|
+
var B = d - x[T];
|
|
26198
|
+
if (k >= B)
|
|
26176
26199
|
return this.diff_bisectSplit_(l, c, k, O, u);
|
|
26177
26200
|
}
|
|
26178
26201
|
}
|
|
26179
26202
|
}
|
|
26180
|
-
for (var
|
|
26181
|
-
var T = g +
|
|
26182
|
-
|
|
26183
|
-
for (var D =
|
|
26184
|
-
|
|
26185
|
-
if (x[T] =
|
|
26186
|
-
|
|
26203
|
+
for (var L = -R + P; L <= R - C; L += 2) {
|
|
26204
|
+
var T = g + L, B;
|
|
26205
|
+
L == -R || L != R && x[T - 1] < x[T + 1] ? B = x[T + 1] : B = x[T - 1] + 1;
|
|
26206
|
+
for (var D = B - L; B < d && D < m && l.charAt(d - B - 1) == c.charAt(m - D - 1); )
|
|
26207
|
+
B++, D++;
|
|
26208
|
+
if (x[T] = B, B > d)
|
|
26209
|
+
C += 2;
|
|
26187
26210
|
else if (D > m)
|
|
26188
26211
|
P += 2;
|
|
26189
26212
|
else if (!E) {
|
|
26190
|
-
var j = g + S -
|
|
26213
|
+
var j = g + S - L;
|
|
26191
26214
|
if (j >= 0 && j < h && b[j] != -1) {
|
|
26192
26215
|
var k = b[j], O = g + k - j;
|
|
26193
|
-
if (
|
|
26216
|
+
if (B = d - B, k >= B)
|
|
26194
26217
|
return this.diff_bisectSplit_(l, c, k, O, u);
|
|
26195
26218
|
}
|
|
26196
26219
|
}
|
|
@@ -26258,22 +26281,22 @@ var diffMatchPatch = { exports: {} };
|
|
|
26258
26281
|
if (u.length < 4 || d.length * 2 < u.length)
|
|
26259
26282
|
return null;
|
|
26260
26283
|
var m = this;
|
|
26261
|
-
function p(A, P,
|
|
26262
|
-
for (var
|
|
26263
|
-
var
|
|
26264
|
-
A.substring(
|
|
26284
|
+
function p(A, P, C) {
|
|
26285
|
+
for (var R = A.substring(C, C + Math.floor(A.length / 4)), I = -1, j = "", k, O, T, B; (I = P.indexOf(R, I + 1)) != -1; ) {
|
|
26286
|
+
var L = m.diff_commonPrefix(
|
|
26287
|
+
A.substring(C),
|
|
26265
26288
|
P.substring(I)
|
|
26266
26289
|
), D = m.diff_commonSuffix(
|
|
26267
|
-
A.substring(0,
|
|
26290
|
+
A.substring(0, C),
|
|
26268
26291
|
P.substring(0, I)
|
|
26269
26292
|
);
|
|
26270
|
-
j.length < D +
|
|
26293
|
+
j.length < D + L && (j = P.substring(I - D, I) + P.substring(I, I + L), k = A.substring(0, C - D), O = A.substring(C + L), T = P.substring(0, I - D), B = P.substring(I + L));
|
|
26271
26294
|
}
|
|
26272
26295
|
return j.length * 2 >= A.length ? [
|
|
26273
26296
|
k,
|
|
26274
26297
|
O,
|
|
26275
26298
|
T,
|
|
26276
|
-
|
|
26299
|
+
B,
|
|
26277
26300
|
j
|
|
26278
26301
|
] : null;
|
|
26279
26302
|
}
|
|
@@ -26320,8 +26343,8 @@ var diffMatchPatch = { exports: {} };
|
|
|
26320
26343
|
function c(w, A) {
|
|
26321
26344
|
if (!w || !A)
|
|
26322
26345
|
return 6;
|
|
26323
|
-
var P = w.charAt(w.length - 1),
|
|
26324
|
-
return
|
|
26346
|
+
var P = w.charAt(w.length - 1), C = A.charAt(0), R = P.match(n.nonAlphaNumericRegex_), I = C.match(n.nonAlphaNumericRegex_), j = R && P.match(n.whitespaceRegex_), k = I && C.match(n.whitespaceRegex_), O = j && P.match(n.linebreakRegex_), T = k && C.match(n.linebreakRegex_), B = O && w.match(n.blanklineEndRegex_), L = T && A.match(n.blanklineStartRegex_);
|
|
26347
|
+
return B || L ? 5 : O || T ? 4 : R && !j && k ? 3 : j || k ? 2 : R || I ? 1 : 0;
|
|
26325
26348
|
}
|
|
26326
26349
|
for (var u = 1; u < l.length - 1; ) {
|
|
26327
26350
|
if (l[u - 1][0] == i && l[u + 1][0] == i) {
|
|
@@ -26472,8 +26495,8 @@ var diffMatchPatch = { exports: {} };
|
|
|
26472
26495
|
throw new Error("Pattern too long for this browser.");
|
|
26473
26496
|
var d = this.match_alphabet_(c), m = this;
|
|
26474
26497
|
function p(k, O) {
|
|
26475
|
-
var T = k / c.length,
|
|
26476
|
-
return m.Match_Distance ? T +
|
|
26498
|
+
var T = k / c.length, B = Math.abs(u - O);
|
|
26499
|
+
return m.Match_Distance ? T + B / m.Match_Distance : B ? 1 : T;
|
|
26477
26500
|
}
|
|
26478
26501
|
var g = this.Match_Threshold, h = l.indexOf(c, u);
|
|
26479
26502
|
h != -1 && (g = Math.min(p(0, h), g), h = l.lastIndexOf(c, u + c.length), h != -1 && (g = Math.min(p(0, h), g)));
|
|
@@ -26483,14 +26506,14 @@ var diffMatchPatch = { exports: {} };
|
|
|
26483
26506
|
for (x = 0, v = S; x < v; )
|
|
26484
26507
|
p(w, u + v) <= g ? x = v : S = v, v = Math.floor((S - x) / 2 + x);
|
|
26485
26508
|
S = v;
|
|
26486
|
-
var A = Math.max(1, u - v + 1), P = Math.min(u + v, l.length) + c.length,
|
|
26487
|
-
|
|
26488
|
-
for (var
|
|
26489
|
-
var I = d[l.charAt(
|
|
26490
|
-
if (w === 0 ? R
|
|
26491
|
-
var j = p(w,
|
|
26509
|
+
var A = Math.max(1, u - v + 1), P = Math.min(u + v, l.length) + c.length, C = Array(P + 2);
|
|
26510
|
+
C[P + 1] = (1 << w) - 1;
|
|
26511
|
+
for (var R = P; R >= A; R--) {
|
|
26512
|
+
var I = d[l.charAt(R - 1)];
|
|
26513
|
+
if (w === 0 ? C[R] = (C[R + 1] << 1 | 1) & I : C[R] = (C[R + 1] << 1 | 1) & I | ((E[R + 1] | E[R]) << 1 | 1) | E[R + 1], C[R] & b) {
|
|
26514
|
+
var j = p(w, R - 1);
|
|
26492
26515
|
if (j <= g)
|
|
26493
|
-
if (g = j, h =
|
|
26516
|
+
if (g = j, h = R - 1, h > u)
|
|
26494
26517
|
A = Math.max(1, 2 * u - h);
|
|
26495
26518
|
else
|
|
26496
26519
|
break;
|
|
@@ -26498,7 +26521,7 @@ var diffMatchPatch = { exports: {} };
|
|
|
26498
26521
|
}
|
|
26499
26522
|
if (p(w + 1, u) > g)
|
|
26500
26523
|
break;
|
|
26501
|
-
E =
|
|
26524
|
+
E = C;
|
|
26502
26525
|
}
|
|
26503
26526
|
return h;
|
|
26504
26527
|
}, n.prototype.match_alphabet_ = function(l) {
|
|
@@ -27877,19 +27900,19 @@ const diffFilter$2 = function r(n) {
|
|
|
27877
27900
|
n.options && n.options.arrays && n.options.arrays.includeValueOnMove && (A = !0);
|
|
27878
27901
|
const P = E.length;
|
|
27879
27902
|
for (l = a; l < g - i; l++) {
|
|
27880
|
-
const
|
|
27881
|
-
if (
|
|
27882
|
-
let
|
|
27903
|
+
const C = arrayIndexOf(S.indices2, l - a);
|
|
27904
|
+
if (C < 0) {
|
|
27905
|
+
let R = !1;
|
|
27883
27906
|
if (w && P > 0) {
|
|
27884
27907
|
for (let I = 0; I < P; I++)
|
|
27885
27908
|
if (c = E[I], matchItems(x, v, c - a, l - a, o)) {
|
|
27886
|
-
b[`_${c}`].splice(1, 2, l, ARRAY_MOVE), A || (b[`_${c}`][0] = ""), u = l, h = new DiffContext(n.left[c], n.right[u]), n.push(h, u), E.splice(I, 1),
|
|
27909
|
+
b[`_${c}`].splice(1, 2, l, ARRAY_MOVE), A || (b[`_${c}`][0] = ""), u = l, h = new DiffContext(n.left[c], n.right[u]), n.push(h, u), E.splice(I, 1), R = !0;
|
|
27887
27910
|
break;
|
|
27888
27911
|
}
|
|
27889
27912
|
}
|
|
27890
|
-
|
|
27913
|
+
R || (b[l] = [m[l]]);
|
|
27891
27914
|
} else
|
|
27892
|
-
c = S.indices1[
|
|
27915
|
+
c = S.indices1[C] + a, u = S.indices2[C] + a, h = new DiffContext(n.left[c], n.right[u]), n.push(h, u);
|
|
27893
27916
|
}
|
|
27894
27917
|
n.setResult(b).exit();
|
|
27895
27918
|
};
|
|
@@ -28322,27 +28345,27 @@ var require_react_is_production_min = __commonJS({
|
|
|
28322
28345
|
"node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.production.min.js"(r) {
|
|
28323
28346
|
init_react_shim();
|
|
28324
28347
|
var n = typeof Symbol == "function" && Symbol.for, o = n ? Symbol.for("react.element") : 60103, a = n ? Symbol.for("react.portal") : 60106, i = n ? Symbol.for("react.fragment") : 60107, l = n ? Symbol.for("react.strict_mode") : 60108, c = n ? Symbol.for("react.profiler") : 60114, u = n ? Symbol.for("react.provider") : 60109, d = n ? Symbol.for("react.context") : 60110, m = n ? Symbol.for("react.async_mode") : 60111, p = n ? Symbol.for("react.concurrent_mode") : 60111, g = n ? Symbol.for("react.forward_ref") : 60112, h = n ? Symbol.for("react.suspense") : 60113, b = n ? Symbol.for("react.suspense_list") : 60120, x = n ? Symbol.for("react.memo") : 60115, v = n ? Symbol.for("react.lazy") : 60116, S = n ? Symbol.for("react.block") : 60121, E = n ? Symbol.for("react.fundamental") : 60117, w = n ? Symbol.for("react.responder") : 60118, A = n ? Symbol.for("react.scope") : 60119;
|
|
28325
|
-
function P(
|
|
28326
|
-
if (typeof
|
|
28327
|
-
var I =
|
|
28348
|
+
function P(R) {
|
|
28349
|
+
if (typeof R == "object" && R !== null) {
|
|
28350
|
+
var I = R.$$typeof;
|
|
28328
28351
|
switch (I) {
|
|
28329
28352
|
case o:
|
|
28330
|
-
switch (
|
|
28353
|
+
switch (R = R.type, R) {
|
|
28331
28354
|
case m:
|
|
28332
28355
|
case p:
|
|
28333
28356
|
case i:
|
|
28334
28357
|
case c:
|
|
28335
28358
|
case l:
|
|
28336
28359
|
case h:
|
|
28337
|
-
return
|
|
28360
|
+
return R;
|
|
28338
28361
|
default:
|
|
28339
|
-
switch (
|
|
28362
|
+
switch (R = R && R.$$typeof, R) {
|
|
28340
28363
|
case d:
|
|
28341
28364
|
case g:
|
|
28342
28365
|
case v:
|
|
28343
28366
|
case x:
|
|
28344
28367
|
case u:
|
|
28345
|
-
return
|
|
28368
|
+
return R;
|
|
28346
28369
|
default:
|
|
28347
28370
|
return I;
|
|
28348
28371
|
}
|
|
@@ -28352,35 +28375,35 @@ var require_react_is_production_min = __commonJS({
|
|
|
28352
28375
|
}
|
|
28353
28376
|
}
|
|
28354
28377
|
}
|
|
28355
|
-
function R
|
|
28356
|
-
return P(
|
|
28357
|
-
}
|
|
28358
|
-
r.AsyncMode = m, r.ConcurrentMode = p, r.ContextConsumer = d, r.ContextProvider = u, r.Element = o, r.ForwardRef = g, r.Fragment = i, r.Lazy = v, r.Memo = x, r.Portal = a, r.Profiler = c, r.StrictMode = l, r.Suspense = h, r.isAsyncMode = function(
|
|
28359
|
-
return R
|
|
28360
|
-
}, r.isConcurrentMode =
|
|
28361
|
-
return P(
|
|
28362
|
-
}, r.isContextProvider = function(
|
|
28363
|
-
return P(
|
|
28364
|
-
}, r.isElement = function(
|
|
28365
|
-
return typeof
|
|
28366
|
-
}, r.isForwardRef = function(
|
|
28367
|
-
return P(
|
|
28368
|
-
}, r.isFragment = function(
|
|
28369
|
-
return P(
|
|
28370
|
-
}, r.isLazy = function(
|
|
28371
|
-
return P(
|
|
28372
|
-
}, r.isMemo = function(
|
|
28373
|
-
return P(
|
|
28374
|
-
}, r.isPortal = function(
|
|
28375
|
-
return P(
|
|
28376
|
-
}, r.isProfiler = function(
|
|
28377
|
-
return P(
|
|
28378
|
-
}, r.isStrictMode = function(
|
|
28379
|
-
return P(
|
|
28380
|
-
}, r.isSuspense = function(
|
|
28381
|
-
return P(
|
|
28382
|
-
}, r.isValidElementType = function(
|
|
28383
|
-
return typeof
|
|
28378
|
+
function C(R) {
|
|
28379
|
+
return P(R) === p;
|
|
28380
|
+
}
|
|
28381
|
+
r.AsyncMode = m, r.ConcurrentMode = p, r.ContextConsumer = d, r.ContextProvider = u, r.Element = o, r.ForwardRef = g, r.Fragment = i, r.Lazy = v, r.Memo = x, r.Portal = a, r.Profiler = c, r.StrictMode = l, r.Suspense = h, r.isAsyncMode = function(R) {
|
|
28382
|
+
return C(R) || P(R) === m;
|
|
28383
|
+
}, r.isConcurrentMode = C, r.isContextConsumer = function(R) {
|
|
28384
|
+
return P(R) === d;
|
|
28385
|
+
}, r.isContextProvider = function(R) {
|
|
28386
|
+
return P(R) === u;
|
|
28387
|
+
}, r.isElement = function(R) {
|
|
28388
|
+
return typeof R == "object" && R !== null && R.$$typeof === o;
|
|
28389
|
+
}, r.isForwardRef = function(R) {
|
|
28390
|
+
return P(R) === g;
|
|
28391
|
+
}, r.isFragment = function(R) {
|
|
28392
|
+
return P(R) === i;
|
|
28393
|
+
}, r.isLazy = function(R) {
|
|
28394
|
+
return P(R) === v;
|
|
28395
|
+
}, r.isMemo = function(R) {
|
|
28396
|
+
return P(R) === x;
|
|
28397
|
+
}, r.isPortal = function(R) {
|
|
28398
|
+
return P(R) === a;
|
|
28399
|
+
}, r.isProfiler = function(R) {
|
|
28400
|
+
return P(R) === c;
|
|
28401
|
+
}, r.isStrictMode = function(R) {
|
|
28402
|
+
return P(R) === l;
|
|
28403
|
+
}, r.isSuspense = function(R) {
|
|
28404
|
+
return P(R) === h;
|
|
28405
|
+
}, r.isValidElementType = function(R) {
|
|
28406
|
+
return typeof R == "string" || typeof R == "function" || R === i || R === p || R === c || R === l || R === h || R === b || typeof R == "object" && R !== null && (R.$$typeof === v || R.$$typeof === x || R.$$typeof === u || R.$$typeof === d || R.$$typeof === g || R.$$typeof === E || R.$$typeof === w || R.$$typeof === A || R.$$typeof === S);
|
|
28384
28407
|
}, r.typeOf = P;
|
|
28385
28408
|
}
|
|
28386
28409
|
}), require_react_is_development = __commonJS({
|
|
@@ -28391,7 +28414,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
28391
28414
|
return typeof Z == "string" || typeof Z == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
28392
28415
|
Z === i || Z === p || Z === c || Z === l || Z === h || Z === b || typeof Z == "object" && Z !== null && (Z.$$typeof === v || Z.$$typeof === x || Z.$$typeof === u || Z.$$typeof === d || Z.$$typeof === g || Z.$$typeof === E || Z.$$typeof === w || Z.$$typeof === A || Z.$$typeof === S);
|
|
28393
28416
|
}
|
|
28394
|
-
function
|
|
28417
|
+
function C(Z) {
|
|
28395
28418
|
if (typeof Z == "object" && Z !== null) {
|
|
28396
28419
|
var le = Z.$$typeof;
|
|
28397
28420
|
switch (le) {
|
|
@@ -28423,47 +28446,47 @@ var require_react_is_production_min = __commonJS({
|
|
|
28423
28446
|
}
|
|
28424
28447
|
}
|
|
28425
28448
|
}
|
|
28426
|
-
var
|
|
28449
|
+
var R = m, I = p, j = d, k = u, O = o, T = g, B = i, L = v, D = x, W = a, J = c, F = l, V = h, q = !1;
|
|
28427
28450
|
function G(Z) {
|
|
28428
|
-
return q || (q = !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.")), ee(Z) ||
|
|
28451
|
+
return q || (q = !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.")), ee(Z) || C(Z) === m;
|
|
28429
28452
|
}
|
|
28430
28453
|
function ee(Z) {
|
|
28431
|
-
return
|
|
28454
|
+
return C(Z) === p;
|
|
28432
28455
|
}
|
|
28433
28456
|
function z(Z) {
|
|
28434
|
-
return
|
|
28457
|
+
return C(Z) === d;
|
|
28435
28458
|
}
|
|
28436
28459
|
function U(Z) {
|
|
28437
|
-
return
|
|
28460
|
+
return C(Z) === u;
|
|
28438
28461
|
}
|
|
28439
28462
|
function te(Z) {
|
|
28440
28463
|
return typeof Z == "object" && Z !== null && Z.$$typeof === o;
|
|
28441
28464
|
}
|
|
28442
28465
|
function _(Z) {
|
|
28443
|
-
return
|
|
28466
|
+
return C(Z) === g;
|
|
28444
28467
|
}
|
|
28445
28468
|
function Q(Z) {
|
|
28446
|
-
return
|
|
28469
|
+
return C(Z) === i;
|
|
28447
28470
|
}
|
|
28448
28471
|
function ne(Z) {
|
|
28449
|
-
return
|
|
28472
|
+
return C(Z) === v;
|
|
28450
28473
|
}
|
|
28451
28474
|
function re(Z) {
|
|
28452
|
-
return
|
|
28475
|
+
return C(Z) === x;
|
|
28453
28476
|
}
|
|
28454
28477
|
function $(Z) {
|
|
28455
|
-
return
|
|
28478
|
+
return C(Z) === a;
|
|
28456
28479
|
}
|
|
28457
28480
|
function ae(Z) {
|
|
28458
|
-
return
|
|
28481
|
+
return C(Z) === c;
|
|
28459
28482
|
}
|
|
28460
28483
|
function se(Z) {
|
|
28461
|
-
return
|
|
28484
|
+
return C(Z) === l;
|
|
28462
28485
|
}
|
|
28463
28486
|
function K(Z) {
|
|
28464
|
-
return
|
|
28487
|
+
return C(Z) === h;
|
|
28465
28488
|
}
|
|
28466
|
-
r.AsyncMode =
|
|
28489
|
+
r.AsyncMode = R, r.ConcurrentMode = I, r.ContextConsumer = j, r.ContextProvider = k, r.Element = O, r.ForwardRef = T, r.Fragment = B, r.Lazy = L, r.Memo = D, r.Portal = W, r.Profiler = J, r.StrictMode = F, r.Suspense = V, r.isAsyncMode = G, r.isConcurrentMode = ee, r.isContextConsumer = z, r.isContextProvider = U, r.isElement = te, r.isForwardRef = _, r.isFragment = Q, r.isLazy = ne, r.isMemo = re, r.isPortal = $, r.isProfiler = ae, r.isStrictMode = se, r.isSuspense = K, r.isValidElementType = P, r.typeOf = C;
|
|
28467
28490
|
}();
|
|
28468
28491
|
}
|
|
28469
28492
|
}), require_react_is = __commonJS({
|
|
@@ -28604,11 +28627,11 @@ var require_react_is_production_min = __commonJS({
|
|
|
28604
28627
|
string: A("string"),
|
|
28605
28628
|
symbol: A("symbol"),
|
|
28606
28629
|
any: P(),
|
|
28607
|
-
arrayOf:
|
|
28608
|
-
element:
|
|
28630
|
+
arrayOf: C,
|
|
28631
|
+
element: R(),
|
|
28609
28632
|
elementType: I(),
|
|
28610
28633
|
instanceOf: j,
|
|
28611
|
-
node:
|
|
28634
|
+
node: B(),
|
|
28612
28635
|
objectOf: O,
|
|
28613
28636
|
oneOf: k,
|
|
28614
28637
|
oneOfType: T,
|
|
@@ -28647,7 +28670,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
28647
28670
|
}
|
|
28648
28671
|
function A(z) {
|
|
28649
28672
|
function U(te, _, Q, ne, re, $) {
|
|
28650
|
-
var ae = te[_], se =
|
|
28673
|
+
var ae = te[_], se = V(ae);
|
|
28651
28674
|
if (se !== z) {
|
|
28652
28675
|
var K = q(ae);
|
|
28653
28676
|
return new E(
|
|
@@ -28662,13 +28685,13 @@ var require_react_is_production_min = __commonJS({
|
|
|
28662
28685
|
function P() {
|
|
28663
28686
|
return w(d);
|
|
28664
28687
|
}
|
|
28665
|
-
function
|
|
28688
|
+
function C(z) {
|
|
28666
28689
|
function U(te, _, Q, ne, re) {
|
|
28667
28690
|
if (typeof z != "function")
|
|
28668
28691
|
return new E("Property `" + re + "` of component `" + Q + "` has invalid PropType notation inside arrayOf.");
|
|
28669
28692
|
var $ = te[_];
|
|
28670
28693
|
if (!Array.isArray($)) {
|
|
28671
|
-
var ae =
|
|
28694
|
+
var ae = V($);
|
|
28672
28695
|
return new E("Invalid " + ne + " `" + re + "` of type " + ("`" + ae + "` supplied to `" + Q + "`, expected an array."));
|
|
28673
28696
|
}
|
|
28674
28697
|
for (var se = 0; se < $.length; se++) {
|
|
@@ -28680,11 +28703,11 @@ var require_react_is_production_min = __commonJS({
|
|
|
28680
28703
|
}
|
|
28681
28704
|
return w(U);
|
|
28682
28705
|
}
|
|
28683
|
-
function
|
|
28706
|
+
function R() {
|
|
28684
28707
|
function z(U, te, _, Q, ne) {
|
|
28685
28708
|
var re = U[te];
|
|
28686
28709
|
if (!m(re)) {
|
|
28687
|
-
var $ =
|
|
28710
|
+
var $ = V(re);
|
|
28688
28711
|
return new E("Invalid " + Q + " `" + ne + "` of type " + ("`" + $ + "` supplied to `" + _ + "`, expected a single ReactElement."));
|
|
28689
28712
|
}
|
|
28690
28713
|
return null;
|
|
@@ -28695,7 +28718,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
28695
28718
|
function z(U, te, _, Q, ne) {
|
|
28696
28719
|
var re = U[te];
|
|
28697
28720
|
if (!o.isValidElementType(re)) {
|
|
28698
|
-
var $ =
|
|
28721
|
+
var $ = V(re);
|
|
28699
28722
|
return new E("Invalid " + Q + " `" + ne + "` of type " + ("`" + $ + "` supplied to `" + _ + "`, expected a single ReactElement type."));
|
|
28700
28723
|
}
|
|
28701
28724
|
return null;
|
|
@@ -28733,7 +28756,7 @@ var require_react_is_production_min = __commonJS({
|
|
|
28733
28756
|
function U(te, _, Q, ne, re) {
|
|
28734
28757
|
if (typeof z != "function")
|
|
28735
28758
|
return new E("Property `" + re + "` of component `" + Q + "` has invalid PropType notation inside objectOf.");
|
|
28736
|
-
var $ = te[_], ae =
|
|
28759
|
+
var $ = te[_], ae = V($);
|
|
28737
28760
|
if (ae !== "object")
|
|
28738
28761
|
return new E("Invalid " + ne + " `" + re + "` of type " + ("`" + ae + "` supplied to `" + Q + "`, expected an object."));
|
|
28739
28762
|
for (var se in $)
|
|
@@ -28768,26 +28791,26 @@ var require_react_is_production_min = __commonJS({
|
|
|
28768
28791
|
}
|
|
28769
28792
|
return w(_);
|
|
28770
28793
|
}
|
|
28771
|
-
function
|
|
28794
|
+
function B() {
|
|
28772
28795
|
function z(U, te, _, Q, ne) {
|
|
28773
28796
|
return J(U[te]) ? null : new E("Invalid " + Q + " `" + ne + "` supplied to " + ("`" + _ + "`, expected a ReactNode."));
|
|
28774
28797
|
}
|
|
28775
28798
|
return w(z);
|
|
28776
28799
|
}
|
|
28777
|
-
function
|
|
28800
|
+
function L(z, U, te, _, Q) {
|
|
28778
28801
|
return new E(
|
|
28779
28802
|
(z || "React class") + ": " + U + " type `" + te + "." + _ + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + Q + "`."
|
|
28780
28803
|
);
|
|
28781
28804
|
}
|
|
28782
28805
|
function D(z) {
|
|
28783
28806
|
function U(te, _, Q, ne, re) {
|
|
28784
|
-
var $ = te[_], ae =
|
|
28807
|
+
var $ = te[_], ae = V($);
|
|
28785
28808
|
if (ae !== "object")
|
|
28786
28809
|
return new E("Invalid " + ne + " `" + re + "` of type `" + ae + "` " + ("supplied to `" + Q + "`, expected `object`."));
|
|
28787
28810
|
for (var se in z) {
|
|
28788
28811
|
var K = z[se];
|
|
28789
28812
|
if (typeof K != "function")
|
|
28790
|
-
return
|
|
28813
|
+
return L(Q, ne, re, se, q(K));
|
|
28791
28814
|
var Z = K($, se, Q, ne, re + "." + se, i);
|
|
28792
28815
|
if (Z)
|
|
28793
28816
|
return Z;
|
|
@@ -28798,14 +28821,14 @@ var require_react_is_production_min = __commonJS({
|
|
|
28798
28821
|
}
|
|
28799
28822
|
function W(z) {
|
|
28800
28823
|
function U(te, _, Q, ne, re) {
|
|
28801
|
-
var $ = te[_], ae =
|
|
28824
|
+
var $ = te[_], ae = V($);
|
|
28802
28825
|
if (ae !== "object")
|
|
28803
28826
|
return new E("Invalid " + ne + " `" + re + "` of type `" + ae + "` " + ("supplied to `" + Q + "`, expected `object`."));
|
|
28804
28827
|
var se = a({}, te[_], z);
|
|
28805
28828
|
for (var K in se) {
|
|
28806
28829
|
var Z = z[K];
|
|
28807
28830
|
if (l(z, K) && typeof Z != "function")
|
|
28808
|
-
return
|
|
28831
|
+
return L(Q, ne, re, K, q(Z));
|
|
28809
28832
|
if (!Z)
|
|
28810
28833
|
return new E(
|
|
28811
28834
|
"Invalid " + ne + " `" + re + "` key `" + K + "` supplied to `" + Q + "`.\nBad object: " + JSON.stringify(te[_], null, " ") + `
|
|
@@ -28855,14 +28878,14 @@ Valid keys: ` + JSON.stringify(Object.keys(z), null, " ")
|
|
|
28855
28878
|
function F(z, U) {
|
|
28856
28879
|
return z === "symbol" ? !0 : U ? U["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && U instanceof Symbol : !1;
|
|
28857
28880
|
}
|
|
28858
|
-
function
|
|
28881
|
+
function V(z) {
|
|
28859
28882
|
var U = typeof z;
|
|
28860
28883
|
return Array.isArray(z) ? "array" : z instanceof RegExp ? "object" : F(U, z) ? "symbol" : U;
|
|
28861
28884
|
}
|
|
28862
28885
|
function q(z) {
|
|
28863
28886
|
if (typeof z > "u" || z === null)
|
|
28864
28887
|
return "" + z;
|
|
28865
|
-
var U =
|
|
28888
|
+
var U = V(z);
|
|
28866
28889
|
if (U === "object") {
|
|
28867
28890
|
if (z instanceof Date)
|
|
28868
28891
|
return "date";
|
|
@@ -29979,10 +30002,10 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
29979
30002
|
r.flat = n(A);
|
|
29980
30003
|
var P = require_google();
|
|
29981
30004
|
r.google = n(P);
|
|
29982
|
-
var
|
|
29983
|
-
r.grayscale = n(
|
|
29984
|
-
var
|
|
29985
|
-
r.greenscreen = n(
|
|
30005
|
+
var C = require_grayscale();
|
|
30006
|
+
r.grayscale = n(C);
|
|
30007
|
+
var R = require_greenscreen();
|
|
30008
|
+
r.greenscreen = n(R);
|
|
29986
30009
|
var I = require_harmonic();
|
|
29987
30010
|
r.harmonic = n(I);
|
|
29988
30011
|
var j = require_hopscotch();
|
|
@@ -29993,10 +30016,10 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
29993
30016
|
r.marrakesh = n(O);
|
|
29994
30017
|
var T = require_mocha();
|
|
29995
30018
|
r.mocha = n(T);
|
|
29996
|
-
var
|
|
29997
|
-
r.monokai = n(
|
|
29998
|
-
var
|
|
29999
|
-
r.ocean = n(
|
|
30019
|
+
var B = require_monokai();
|
|
30020
|
+
r.monokai = n(B);
|
|
30021
|
+
var L = require_ocean();
|
|
30022
|
+
r.ocean = n(L);
|
|
30000
30023
|
var D = require_paraiso();
|
|
30001
30024
|
r.paraiso = n(D);
|
|
30002
30025
|
var W = require_pop();
|
|
@@ -30005,8 +30028,8 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
30005
30028
|
r.railscasts = n(J);
|
|
30006
30029
|
var F = require_shapeshifter();
|
|
30007
30030
|
r.shapeshifter = n(F);
|
|
30008
|
-
var
|
|
30009
|
-
r.solarized = n(
|
|
30031
|
+
var V = require_solarized();
|
|
30032
|
+
r.solarized = n(V);
|
|
30010
30033
|
var q = require_summerfruit();
|
|
30011
30034
|
r.summerfruit = n(q);
|
|
30012
30035
|
var G = require_tomorrow();
|
|
@@ -30477,10 +30500,10 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
30477
30500
|
var g = p[0] / 255, h = p[1] / 255, b = p[2] / 255, x = Math.min(g, h, b), v = Math.max(g, h, b), S = v - x, E, w, A;
|
|
30478
30501
|
return v === x ? E = 0 : g === v ? E = (h - b) / S : h === v ? E = 2 + (b - g) / S : b === v && (E = 4 + (g - h) / S), E = Math.min(E * 60, 360), E < 0 && (E += 360), A = (x + v) / 2, v === x ? w = 0 : A <= 0.5 ? w = S / (v + x) : w = S / (2 - v - x), [E, w * 100, A * 100];
|
|
30479
30502
|
}, l.rgb.hsv = function(p) {
|
|
30480
|
-
var g, h, b, x, v, S = p[0] / 255, E = p[1] / 255, w = p[2] / 255, A = Math.max(S, E, w), P = A - Math.min(S, E, w),
|
|
30481
|
-
return (A -
|
|
30503
|
+
var g, h, b, x, v, S = p[0] / 255, E = p[1] / 255, w = p[2] / 255, A = Math.max(S, E, w), P = A - Math.min(S, E, w), C = function(R) {
|
|
30504
|
+
return (A - R) / 6 / P + 1 / 2;
|
|
30482
30505
|
};
|
|
30483
|
-
return P === 0 ? x = v = 0 : (v = P / A, g =
|
|
30506
|
+
return P === 0 ? x = v = 0 : (v = P / A, g = C(S), h = C(E), b = C(w), S === A ? x = b - h : E === A ? x = 1 / 3 + g - b : w === A && (x = 2 / 3 + h - g), x < 0 ? x += 1 : x > 1 && (x -= 1)), [
|
|
30484
30507
|
x * 360,
|
|
30485
30508
|
v * 100,
|
|
30486
30509
|
A * 100
|
|
@@ -30549,30 +30572,30 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
30549
30572
|
}, l.hwb.rgb = function(p) {
|
|
30550
30573
|
var g = p[0] / 360, h = p[1] / 100, b = p[2] / 100, x = h + b, v, S, E, w;
|
|
30551
30574
|
x > 1 && (h /= x, b /= x), v = Math.floor(6 * g), S = 1 - b, E = 6 * g - v, v & 1 && (E = 1 - E), w = h + E * (S - h);
|
|
30552
|
-
var A, P,
|
|
30575
|
+
var A, P, C;
|
|
30553
30576
|
switch (v) {
|
|
30554
30577
|
default:
|
|
30555
30578
|
case 6:
|
|
30556
30579
|
case 0:
|
|
30557
|
-
A = S, P = w,
|
|
30580
|
+
A = S, P = w, C = h;
|
|
30558
30581
|
break;
|
|
30559
30582
|
case 1:
|
|
30560
|
-
A = w, P = S,
|
|
30583
|
+
A = w, P = S, C = h;
|
|
30561
30584
|
break;
|
|
30562
30585
|
case 2:
|
|
30563
|
-
A = h, P = S,
|
|
30586
|
+
A = h, P = S, C = w;
|
|
30564
30587
|
break;
|
|
30565
30588
|
case 3:
|
|
30566
|
-
A = h, P = w,
|
|
30589
|
+
A = h, P = w, C = S;
|
|
30567
30590
|
break;
|
|
30568
30591
|
case 4:
|
|
30569
|
-
A = w, P = h,
|
|
30592
|
+
A = w, P = h, C = S;
|
|
30570
30593
|
break;
|
|
30571
30594
|
case 5:
|
|
30572
|
-
A = S, P = h,
|
|
30595
|
+
A = S, P = h, C = w;
|
|
30573
30596
|
break;
|
|
30574
30597
|
}
|
|
30575
|
-
return [A * 255, P * 255,
|
|
30598
|
+
return [A * 255, P * 255, C * 255];
|
|
30576
30599
|
}, l.cmyk.rgb = function(p) {
|
|
30577
30600
|
var g = p[0] / 100, h = p[1] / 100, b = p[2] / 100, x = p[3] / 100, v, S, E;
|
|
30578
30601
|
return v = 1 - Math.min(1, g * (1 - x) + x), S = 1 - Math.min(1, h * (1 - x) + x), E = 1 - Math.min(1, b * (1 - x) + x), [v * 255, S * 255, E * 255];
|
|
@@ -30821,12 +30844,12 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
30821
30844
|
], this.valpha = 1;
|
|
30822
30845
|
else {
|
|
30823
30846
|
this.valpha = 1;
|
|
30824
|
-
var
|
|
30825
|
-
"alpha" in v && (
|
|
30826
|
-
var
|
|
30827
|
-
if (!(
|
|
30847
|
+
var C = Object.keys(v);
|
|
30848
|
+
"alpha" in v && (C.splice(C.indexOf("alpha"), 1), this.valpha = typeof v.alpha == "number" ? v.alpha : 0);
|
|
30849
|
+
var R = C.sort().join("");
|
|
30850
|
+
if (!(R in c))
|
|
30828
30851
|
throw new Error("Unable to parse color from object: " + JSON.stringify(v));
|
|
30829
|
-
this.model = c[
|
|
30852
|
+
this.model = c[R];
|
|
30830
30853
|
var I = a[this.model].labels, j = [];
|
|
30831
30854
|
for (E = 0; E < I.length; E++)
|
|
30832
30855
|
j.push(v[I[E]]);
|
|
@@ -30982,11 +31005,11 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
30982
31005
|
mix: function(v, S) {
|
|
30983
31006
|
if (!v || !v.rgb)
|
|
30984
31007
|
throw new Error('Argument to "mix" was not a Color instance, but rather an instance of ' + typeof v);
|
|
30985
|
-
var E = v.rgb(), w = this.rgb(), A = S === void 0 ? 0.5 : S, P = 2 * A - 1,
|
|
31008
|
+
var E = v.rgb(), w = this.rgb(), A = S === void 0 ? 0.5 : S, P = 2 * A - 1, C = E.alpha() - w.alpha(), R = ((P * C === -1 ? P : (P + C) / (1 + P * C)) + 1) / 2, I = 1 - R;
|
|
30986
31009
|
return d.rgb(
|
|
30987
|
-
|
|
30988
|
-
|
|
30989
|
-
|
|
31010
|
+
R * E.red() + I * w.red(),
|
|
31011
|
+
R * E.green() + I * w.green(),
|
|
31012
|
+
R * E.blue() + I * w.blue(),
|
|
30990
31013
|
E.alpha() * A + w.alpha() * (1 - A)
|
|
30991
31014
|
);
|
|
30992
31015
|
}
|
|
@@ -31049,67 +31072,67 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
31049
31072
|
["partial", m],
|
|
31050
31073
|
["partialRight", p],
|
|
31051
31074
|
["rearg", h]
|
|
31052
|
-
], A = "[object Function]", P = "[object GeneratorFunction]",
|
|
31053
|
-
function G(N,
|
|
31075
|
+
], A = "[object Function]", P = "[object GeneratorFunction]", C = "[object Symbol]", R = /[\\^$.*+?()[\]{}|]/g, I = /^\s+|\s+$/g, j = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/, k = /\{\n\/\* \[wrapped with (.+)\] \*/, O = /,? & /, T = /^[-+]0x[0-9a-f]+$/i, B = /^0b[01]+$/i, L = /^\[object .+?Constructor\]$/, D = /^0o[0-7]+$/i, W = /^(?:0|[1-9]\d*)$/, J = parseInt, F = typeof global == "object" && global && global.Object === Object && global, V = typeof self == "object" && self && self.Object === Object && self, q = F || V || Function("return this")();
|
|
31076
|
+
function G(N, M, Y) {
|
|
31054
31077
|
switch (Y.length) {
|
|
31055
31078
|
case 0:
|
|
31056
|
-
return N.call(
|
|
31079
|
+
return N.call(M);
|
|
31057
31080
|
case 1:
|
|
31058
|
-
return N.call(
|
|
31081
|
+
return N.call(M, Y[0]);
|
|
31059
31082
|
case 2:
|
|
31060
|
-
return N.call(
|
|
31083
|
+
return N.call(M, Y[0], Y[1]);
|
|
31061
31084
|
case 3:
|
|
31062
|
-
return N.call(
|
|
31085
|
+
return N.call(M, Y[0], Y[1], Y[2]);
|
|
31063
31086
|
}
|
|
31064
|
-
return N.apply(
|
|
31087
|
+
return N.apply(M, Y);
|
|
31065
31088
|
}
|
|
31066
|
-
function ee(N,
|
|
31067
|
-
for (var Y = -1, oe = N ? N.length : 0; ++Y < oe &&
|
|
31089
|
+
function ee(N, M) {
|
|
31090
|
+
for (var Y = -1, oe = N ? N.length : 0; ++Y < oe && M(N[Y], Y, N) !== !1; )
|
|
31068
31091
|
;
|
|
31069
31092
|
return N;
|
|
31070
31093
|
}
|
|
31071
|
-
function z(N,
|
|
31094
|
+
function z(N, M) {
|
|
31072
31095
|
var Y = N ? N.length : 0;
|
|
31073
|
-
return !!Y && te(N,
|
|
31096
|
+
return !!Y && te(N, M, 0) > -1;
|
|
31074
31097
|
}
|
|
31075
|
-
function U(N,
|
|
31098
|
+
function U(N, M, Y, oe) {
|
|
31076
31099
|
for (var ce = N.length, H = Y + (oe ? 1 : -1); oe ? H-- : ++H < ce; )
|
|
31077
|
-
if (
|
|
31100
|
+
if (M(N[H], H, N))
|
|
31078
31101
|
return H;
|
|
31079
31102
|
return -1;
|
|
31080
31103
|
}
|
|
31081
|
-
function te(N,
|
|
31082
|
-
if (
|
|
31104
|
+
function te(N, M, Y) {
|
|
31105
|
+
if (M !== M)
|
|
31083
31106
|
return U(N, _, Y);
|
|
31084
31107
|
for (var oe = Y - 1, ce = N.length; ++oe < ce; )
|
|
31085
|
-
if (N[oe] ===
|
|
31108
|
+
if (N[oe] === M)
|
|
31086
31109
|
return oe;
|
|
31087
31110
|
return -1;
|
|
31088
31111
|
}
|
|
31089
31112
|
function _(N) {
|
|
31090
31113
|
return N !== N;
|
|
31091
31114
|
}
|
|
31092
|
-
function Q(N,
|
|
31115
|
+
function Q(N, M) {
|
|
31093
31116
|
for (var Y = N.length, oe = 0; Y--; )
|
|
31094
|
-
N[Y] ===
|
|
31117
|
+
N[Y] === M && oe++;
|
|
31095
31118
|
return oe;
|
|
31096
31119
|
}
|
|
31097
|
-
function ne(N,
|
|
31098
|
-
return N == null ? void 0 : N[
|
|
31120
|
+
function ne(N, M) {
|
|
31121
|
+
return N == null ? void 0 : N[M];
|
|
31099
31122
|
}
|
|
31100
31123
|
function re(N) {
|
|
31101
|
-
var
|
|
31124
|
+
var M = !1;
|
|
31102
31125
|
if (N != null && typeof N.toString != "function")
|
|
31103
31126
|
try {
|
|
31104
|
-
|
|
31127
|
+
M = !!(N + "");
|
|
31105
31128
|
} catch {
|
|
31106
31129
|
}
|
|
31107
|
-
return
|
|
31130
|
+
return M;
|
|
31108
31131
|
}
|
|
31109
|
-
function $(N,
|
|
31132
|
+
function $(N, M) {
|
|
31110
31133
|
for (var Y = -1, oe = N.length, ce = 0, H = []; ++Y < oe; ) {
|
|
31111
31134
|
var ie = N[Y];
|
|
31112
|
-
(ie ===
|
|
31135
|
+
(ie === M || ie === a) && (N[Y] = a, H[ce++] = Y);
|
|
31113
31136
|
}
|
|
31114
31137
|
return H;
|
|
31115
31138
|
}
|
|
@@ -31117,79 +31140,79 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
31117
31140
|
var N = /[^.]+$/.exec(K && K.keys && K.keys.IE_PROTO || "");
|
|
31118
31141
|
return N ? "Symbol(src)_1." + N : "";
|
|
31119
31142
|
}(), le = ae.toString, fe = se.hasOwnProperty, Te = se.toString, be = RegExp(
|
|
31120
|
-
"^" + le.call(fe).replace(
|
|
31143
|
+
"^" + le.call(fe).replace(R, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
|
31121
31144
|
), Ze = Object.create, Ne = Math.max, ge = Math.min, Ge = function() {
|
|
31122
|
-
var N = We(Object, "defineProperty"),
|
|
31123
|
-
return
|
|
31145
|
+
var N = We(Object, "defineProperty"), M = We.name;
|
|
31146
|
+
return M && M.length > 2 ? N : void 0;
|
|
31124
31147
|
}();
|
|
31125
31148
|
function ke(N) {
|
|
31126
31149
|
return je(N) ? Ze(N) : {};
|
|
31127
31150
|
}
|
|
31128
31151
|
function ve(N) {
|
|
31129
|
-
if (!je(N) ||
|
|
31152
|
+
if (!je(N) || Be(N))
|
|
31130
31153
|
return !1;
|
|
31131
|
-
var
|
|
31132
|
-
return
|
|
31154
|
+
var M = st(N) || re(N) ? be : L;
|
|
31155
|
+
return M.test(Ie(N));
|
|
31133
31156
|
}
|
|
31134
|
-
function He(N,
|
|
31135
|
-
for (var ce = -1, H = N.length, ie = Y.length, ue = -1, de =
|
|
31136
|
-
pe[ue] =
|
|
31157
|
+
function He(N, M, Y, oe) {
|
|
31158
|
+
for (var ce = -1, H = N.length, ie = Y.length, ue = -1, de = M.length, me = Ne(H - ie, 0), pe = Array(de + me), xe = !oe; ++ue < de; )
|
|
31159
|
+
pe[ue] = M[ue];
|
|
31137
31160
|
for (; ++ce < ie; )
|
|
31138
31161
|
(xe || ce < H) && (pe[Y[ce]] = N[ce]);
|
|
31139
31162
|
for (; me--; )
|
|
31140
31163
|
pe[ue++] = N[ce++];
|
|
31141
31164
|
return pe;
|
|
31142
31165
|
}
|
|
31143
|
-
function Fe(N,
|
|
31144
|
-
for (var ce = -1, H = N.length, ie = -1, ue = Y.length, de = -1, me =
|
|
31166
|
+
function Fe(N, M, Y, oe) {
|
|
31167
|
+
for (var ce = -1, H = N.length, ie = -1, ue = Y.length, de = -1, me = M.length, pe = Ne(H - ue, 0), xe = Array(pe + me), ye = !oe; ++ce < pe; )
|
|
31145
31168
|
xe[ce] = N[ce];
|
|
31146
31169
|
for (var we = ce; ++de < me; )
|
|
31147
|
-
xe[we + de] =
|
|
31170
|
+
xe[we + de] = M[de];
|
|
31148
31171
|
for (; ++ie < ue; )
|
|
31149
31172
|
(ye || ce < H) && (xe[we + Y[ie]] = N[ce++]);
|
|
31150
31173
|
return xe;
|
|
31151
31174
|
}
|
|
31152
|
-
function Je(N,
|
|
31175
|
+
function Je(N, M) {
|
|
31153
31176
|
var Y = -1, oe = N.length;
|
|
31154
|
-
for (
|
|
31155
|
-
|
|
31156
|
-
return
|
|
31177
|
+
for (M || (M = Array(oe)); ++Y < oe; )
|
|
31178
|
+
M[Y] = N[Y];
|
|
31179
|
+
return M;
|
|
31157
31180
|
}
|
|
31158
|
-
function rt(N,
|
|
31159
|
-
var oe =
|
|
31181
|
+
function rt(N, M, Y) {
|
|
31182
|
+
var oe = M & i, ce = Ce(N);
|
|
31160
31183
|
function H() {
|
|
31161
31184
|
var ie = this && this !== q && this instanceof H ? ce : N;
|
|
31162
31185
|
return ie.apply(oe ? Y : this, arguments);
|
|
31163
31186
|
}
|
|
31164
31187
|
return H;
|
|
31165
31188
|
}
|
|
31166
|
-
function
|
|
31189
|
+
function Ce(N) {
|
|
31167
31190
|
return function() {
|
|
31168
|
-
var
|
|
31169
|
-
switch (
|
|
31191
|
+
var M = arguments;
|
|
31192
|
+
switch (M.length) {
|
|
31170
31193
|
case 0:
|
|
31171
31194
|
return new N();
|
|
31172
31195
|
case 1:
|
|
31173
|
-
return new N(
|
|
31196
|
+
return new N(M[0]);
|
|
31174
31197
|
case 2:
|
|
31175
|
-
return new N(
|
|
31198
|
+
return new N(M[0], M[1]);
|
|
31176
31199
|
case 3:
|
|
31177
|
-
return new N(
|
|
31200
|
+
return new N(M[0], M[1], M[2]);
|
|
31178
31201
|
case 4:
|
|
31179
|
-
return new N(
|
|
31202
|
+
return new N(M[0], M[1], M[2], M[3]);
|
|
31180
31203
|
case 5:
|
|
31181
|
-
return new N(
|
|
31204
|
+
return new N(M[0], M[1], M[2], M[3], M[4]);
|
|
31182
31205
|
case 6:
|
|
31183
|
-
return new N(
|
|
31206
|
+
return new N(M[0], M[1], M[2], M[3], M[4], M[5]);
|
|
31184
31207
|
case 7:
|
|
31185
|
-
return new N(
|
|
31208
|
+
return new N(M[0], M[1], M[2], M[3], M[4], M[5], M[6]);
|
|
31186
31209
|
}
|
|
31187
|
-
var Y = ke(N.prototype), oe = N.apply(Y,
|
|
31210
|
+
var Y = ke(N.prototype), oe = N.apply(Y, M);
|
|
31188
31211
|
return je(oe) ? oe : Y;
|
|
31189
31212
|
};
|
|
31190
31213
|
}
|
|
31191
|
-
function De(N,
|
|
31192
|
-
var oe =
|
|
31214
|
+
function De(N, M, Y) {
|
|
31215
|
+
var oe = Ce(N);
|
|
31193
31216
|
function ce() {
|
|
31194
31217
|
for (var H = arguments.length, ie = Array(H), ue = H, de = qe(ce); ue--; )
|
|
31195
31218
|
ie[ue] = arguments[ue];
|
|
@@ -31197,8 +31220,8 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
31197
31220
|
if (H -= me.length, H < Y)
|
|
31198
31221
|
return Ye(
|
|
31199
31222
|
N,
|
|
31200
|
-
|
|
31201
|
-
|
|
31223
|
+
M,
|
|
31224
|
+
Le,
|
|
31202
31225
|
ce.placeholder,
|
|
31203
31226
|
void 0,
|
|
31204
31227
|
ie,
|
|
@@ -31212,35 +31235,35 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
31212
31235
|
}
|
|
31213
31236
|
return ce;
|
|
31214
31237
|
}
|
|
31215
|
-
function
|
|
31216
|
-
var pe =
|
|
31238
|
+
function Le(N, M, Y, oe, ce, H, ie, ue, de, me) {
|
|
31239
|
+
var pe = M & g, xe = M & i, ye = M & l, we = M & (u | d), it = M & b, et = ye ? void 0 : Ce(N);
|
|
31217
31240
|
function tt() {
|
|
31218
|
-
for (var
|
|
31241
|
+
for (var Me = arguments.length, Ae = Array(Me), lt = Me; lt--; )
|
|
31219
31242
|
Ae[lt] = arguments[lt];
|
|
31220
31243
|
if (we)
|
|
31221
31244
|
var ut = qe(tt), pt = Q(Ae, ut);
|
|
31222
|
-
if (oe && (Ae = He(Ae, oe, ce, we)), H && (Ae = Fe(Ae, H, ie, we)),
|
|
31245
|
+
if (oe && (Ae = He(Ae, oe, ce, we)), H && (Ae = Fe(Ae, H, ie, we)), Me -= pt, we && Me < me) {
|
|
31223
31246
|
var ft = $(Ae, ut);
|
|
31224
31247
|
return Ye(
|
|
31225
31248
|
N,
|
|
31226
|
-
|
|
31227
|
-
|
|
31249
|
+
M,
|
|
31250
|
+
Le,
|
|
31228
31251
|
tt.placeholder,
|
|
31229
31252
|
Y,
|
|
31230
31253
|
Ae,
|
|
31231
31254
|
ft,
|
|
31232
31255
|
ue,
|
|
31233
31256
|
de,
|
|
31234
|
-
me -
|
|
31257
|
+
me - Me
|
|
31235
31258
|
);
|
|
31236
31259
|
}
|
|
31237
31260
|
var dt = xe ? Y : this, ct = ye ? dt[N] : N;
|
|
31238
|
-
return
|
|
31261
|
+
return Me = Ae.length, ue ? Ae = Xe(Ae, ue) : it && Me > 1 && Ae.reverse(), pe && de < Me && (Ae.length = de), this && this !== q && this instanceof tt && (ct = et || Ce(ct)), ct.apply(dt, Ae);
|
|
31239
31262
|
}
|
|
31240
31263
|
return tt;
|
|
31241
31264
|
}
|
|
31242
|
-
function nt(N,
|
|
31243
|
-
var ce =
|
|
31265
|
+
function nt(N, M, Y, oe) {
|
|
31266
|
+
var ce = M & i, H = Ce(N);
|
|
31244
31267
|
function ie() {
|
|
31245
31268
|
for (var ue = -1, de = arguments.length, me = -1, pe = oe.length, xe = Array(pe + de), ye = this && this !== q && this instanceof ie ? H : N; ++me < pe; )
|
|
31246
31269
|
xe[me] = oe[me];
|
|
@@ -31250,24 +31273,24 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
31250
31273
|
}
|
|
31251
31274
|
return ie;
|
|
31252
31275
|
}
|
|
31253
|
-
function Ye(N,
|
|
31254
|
-
var pe =
|
|
31255
|
-
|
|
31256
|
-
var et = Y(N,
|
|
31257
|
-
return et.placeholder = oe, Pe(et, N,
|
|
31276
|
+
function Ye(N, M, Y, oe, ce, H, ie, ue, de, me) {
|
|
31277
|
+
var pe = M & u, xe = pe ? ie : void 0, ye = pe ? void 0 : ie, we = pe ? H : void 0, it = pe ? void 0 : H;
|
|
31278
|
+
M |= pe ? m : p, M &= ~(pe ? p : m), M & c || (M &= ~(i | l));
|
|
31279
|
+
var et = Y(N, M, ce, we, xe, it, ye, ue, de, me);
|
|
31280
|
+
return et.placeholder = oe, Pe(et, N, M);
|
|
31258
31281
|
}
|
|
31259
|
-
function Se(N,
|
|
31260
|
-
var de =
|
|
31282
|
+
function Se(N, M, Y, oe, ce, H, ie, ue) {
|
|
31283
|
+
var de = M & l;
|
|
31261
31284
|
if (!de && typeof N != "function")
|
|
31262
31285
|
throw new TypeError(o);
|
|
31263
31286
|
var me = oe ? oe.length : 0;
|
|
31264
|
-
if (me || (
|
|
31287
|
+
if (me || (M &= ~(m | p), oe = ce = void 0), ie = ie === void 0 ? ie : Ne(Ee(ie), 0), ue = ue === void 0 ? ue : Ee(ue), me -= ce ? ce.length : 0, M & p) {
|
|
31265
31288
|
var pe = oe, xe = ce;
|
|
31266
31289
|
oe = ce = void 0;
|
|
31267
31290
|
}
|
|
31268
31291
|
var ye = [
|
|
31269
31292
|
N,
|
|
31270
|
-
|
|
31293
|
+
M,
|
|
31271
31294
|
Y,
|
|
31272
31295
|
oe,
|
|
31273
31296
|
ce,
|
|
@@ -31277,45 +31300,45 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
31277
31300
|
ie,
|
|
31278
31301
|
ue
|
|
31279
31302
|
];
|
|
31280
|
-
if (N = ye[0],
|
|
31281
|
-
var we = rt(N,
|
|
31303
|
+
if (N = ye[0], M = ye[1], Y = ye[2], oe = ye[3], ce = ye[4], ue = ye[9] = ye[9] == null ? de ? 0 : N.length : Ne(ye[9] - me, 0), !ue && M & (u | d) && (M &= ~(u | d)), !M || M == i)
|
|
31304
|
+
var we = rt(N, M, Y);
|
|
31282
31305
|
else
|
|
31283
|
-
|
|
31284
|
-
return Pe(we, N,
|
|
31306
|
+
M == u || M == d ? we = De(N, M, ue) : (M == m || M == (i | m)) && !ce.length ? we = nt(N, M, Y, oe) : we = Le.apply(void 0, ye);
|
|
31307
|
+
return Pe(we, N, M);
|
|
31285
31308
|
}
|
|
31286
31309
|
function qe(N) {
|
|
31287
|
-
var
|
|
31288
|
-
return
|
|
31310
|
+
var M = N;
|
|
31311
|
+
return M.placeholder;
|
|
31289
31312
|
}
|
|
31290
|
-
function We(N,
|
|
31291
|
-
var Y = ne(N,
|
|
31313
|
+
function We(N, M) {
|
|
31314
|
+
var Y = ne(N, M);
|
|
31292
31315
|
return ve(Y) ? Y : void 0;
|
|
31293
31316
|
}
|
|
31294
31317
|
function ot(N) {
|
|
31295
|
-
var
|
|
31296
|
-
return
|
|
31318
|
+
var M = N.match(k);
|
|
31319
|
+
return M ? M[1].split(O) : [];
|
|
31297
31320
|
}
|
|
31298
|
-
function Ue(N,
|
|
31299
|
-
var Y =
|
|
31300
|
-
return
|
|
31301
|
-
/* [wrapped with ` +
|
|
31321
|
+
function Ue(N, M) {
|
|
31322
|
+
var Y = M.length, oe = Y - 1;
|
|
31323
|
+
return M[oe] = (Y > 1 ? "& " : "") + M[oe], M = M.join(Y > 2 ? ", " : " "), N.replace(j, `{
|
|
31324
|
+
/* [wrapped with ` + M + `] */
|
|
31302
31325
|
`);
|
|
31303
31326
|
}
|
|
31304
|
-
function
|
|
31305
|
-
return
|
|
31327
|
+
function Re(N, M) {
|
|
31328
|
+
return M = M ?? v, !!M && (typeof N == "number" || W.test(N)) && N > -1 && N % 1 == 0 && N < M;
|
|
31306
31329
|
}
|
|
31307
|
-
function
|
|
31330
|
+
function Be(N) {
|
|
31308
31331
|
return !!Z && Z in N;
|
|
31309
31332
|
}
|
|
31310
|
-
function Xe(N,
|
|
31311
|
-
for (var Y = N.length, oe = ge(
|
|
31312
|
-
var H =
|
|
31313
|
-
N[oe] =
|
|
31333
|
+
function Xe(N, M) {
|
|
31334
|
+
for (var Y = N.length, oe = ge(M.length, Y), ce = Je(N); oe--; ) {
|
|
31335
|
+
var H = M[oe];
|
|
31336
|
+
N[oe] = Re(H, Y) ? ce[H] : void 0;
|
|
31314
31337
|
}
|
|
31315
31338
|
return N;
|
|
31316
31339
|
}
|
|
31317
|
-
var Pe = Ge ? function(N,
|
|
31318
|
-
var oe =
|
|
31340
|
+
var Pe = Ge ? function(N, M, Y) {
|
|
31341
|
+
var oe = M + "";
|
|
31319
31342
|
return Ge(N, "toString", {
|
|
31320
31343
|
configurable: !0,
|
|
31321
31344
|
enumerable: !1,
|
|
@@ -31335,43 +31358,43 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
31335
31358
|
}
|
|
31336
31359
|
return "";
|
|
31337
31360
|
}
|
|
31338
|
-
function at(N,
|
|
31361
|
+
function at(N, M) {
|
|
31339
31362
|
return ee(w, function(Y) {
|
|
31340
31363
|
var oe = "_." + Y[0];
|
|
31341
|
-
|
|
31364
|
+
M & Y[1] && !z(N, oe) && N.push(oe);
|
|
31342
31365
|
}), N.sort();
|
|
31343
31366
|
}
|
|
31344
|
-
function Oe(N,
|
|
31345
|
-
|
|
31346
|
-
var oe = Se(N, u, void 0, void 0, void 0, void 0, void 0,
|
|
31367
|
+
function Oe(N, M, Y) {
|
|
31368
|
+
M = Y ? void 0 : M;
|
|
31369
|
+
var oe = Se(N, u, void 0, void 0, void 0, void 0, void 0, M);
|
|
31347
31370
|
return oe.placeholder = Oe.placeholder, oe;
|
|
31348
31371
|
}
|
|
31349
31372
|
function st(N) {
|
|
31350
|
-
var
|
|
31351
|
-
return
|
|
31373
|
+
var M = je(N) ? Te.call(N) : "";
|
|
31374
|
+
return M == A || M == P;
|
|
31352
31375
|
}
|
|
31353
31376
|
function je(N) {
|
|
31354
|
-
var
|
|
31355
|
-
return !!N && (
|
|
31377
|
+
var M = typeof N;
|
|
31378
|
+
return !!N && (M == "object" || M == "function");
|
|
31356
31379
|
}
|
|
31357
31380
|
function he(N) {
|
|
31358
31381
|
return !!N && typeof N == "object";
|
|
31359
31382
|
}
|
|
31360
31383
|
function Qe(N) {
|
|
31361
|
-
return typeof N == "symbol" || he(N) && Te.call(N) ==
|
|
31384
|
+
return typeof N == "symbol" || he(N) && Te.call(N) == C;
|
|
31362
31385
|
}
|
|
31363
|
-
function
|
|
31386
|
+
function Ve(N) {
|
|
31364
31387
|
if (!N)
|
|
31365
31388
|
return N === 0 ? N : 0;
|
|
31366
31389
|
if (N = _e(N), N === x || N === -x) {
|
|
31367
|
-
var
|
|
31368
|
-
return
|
|
31390
|
+
var M = N < 0 ? -1 : 1;
|
|
31391
|
+
return M * S;
|
|
31369
31392
|
}
|
|
31370
31393
|
return N === N ? N : 0;
|
|
31371
31394
|
}
|
|
31372
31395
|
function Ee(N) {
|
|
31373
|
-
var
|
|
31374
|
-
return
|
|
31396
|
+
var M = Ve(N), Y = M % 1;
|
|
31397
|
+
return M === M ? Y ? M - Y : M : 0;
|
|
31375
31398
|
}
|
|
31376
31399
|
function _e(N) {
|
|
31377
31400
|
if (typeof N == "number")
|
|
@@ -31379,13 +31402,13 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
31379
31402
|
if (Qe(N))
|
|
31380
31403
|
return E;
|
|
31381
31404
|
if (je(N)) {
|
|
31382
|
-
var
|
|
31383
|
-
N = je(
|
|
31405
|
+
var M = typeof N.valueOf == "function" ? N.valueOf() : N;
|
|
31406
|
+
N = je(M) ? M + "" : M;
|
|
31384
31407
|
}
|
|
31385
31408
|
if (typeof N != "string")
|
|
31386
31409
|
return N === 0 ? N : +N;
|
|
31387
31410
|
N = N.replace(I, "");
|
|
31388
|
-
var Y =
|
|
31411
|
+
var Y = B.test(N);
|
|
31389
31412
|
return Y || D.test(N) ? J(N.slice(2), Y ? 2 : 8) : T.test(N) ? E : +N;
|
|
31390
31413
|
}
|
|
31391
31414
|
function $e(N) {
|
|
@@ -33849,11 +33872,22 @@ const TabletIcon = ({ landscape: r = !1 }) => /* @__PURE__ */ jsxRuntimeExports.
|
|
|
33849
33872
|
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "flex h-full items-center space-x-2", children: /* @__PURE__ */ jsxRuntimeExports.jsx(ClearCanvas, {}) })
|
|
33850
33873
|
] });
|
|
33851
33874
|
}, AddBlocksDialog = () => {
|
|
33852
|
-
const { t: r } = useTranslation(), [n, o] =
|
|
33853
|
-
return
|
|
33854
|
-
|
|
33855
|
-
|
|
33856
|
-
/* @__PURE__ */ jsxRuntimeExports.
|
|
33875
|
+
const { t: r } = useTranslation(), [n, o] = useState$1(""), [a, i] = useState$1(!1);
|
|
33876
|
+
return useChaiBuilderMsgListener(({ name: l, data: c = void 0 }) => {
|
|
33877
|
+
l === CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK && (o(c == null ? void 0 : c._id), i(!0)), l === CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK && (o(""), i(!1));
|
|
33878
|
+
}), /* @__PURE__ */ jsxRuntimeExports.jsx(AlertDialog, { open: a, onOpenChange: () => a ? i(!1) : "", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(AlertDialogContent, { className: "max-h-[80vh] max-w-5xl overflow-hidden", children: [
|
|
33879
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(AlertDialogHeader, { className: "flex flex-row items-center justify-between", children: [
|
|
33880
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(AlertDialogTitle, { children: r("add_block") }),
|
|
33881
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
33882
|
+
"button",
|
|
33883
|
+
{
|
|
33884
|
+
onClick: () => i(!1),
|
|
33885
|
+
className: "text-gray-500 hover:text-gray-600 dark:text-gray-400 dark:hover:text-gray-300",
|
|
33886
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Cross2Icon, { className: "h-6 w-6" })
|
|
33887
|
+
}
|
|
33888
|
+
)
|
|
33889
|
+
] }),
|
|
33890
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "no-scrollbar h-[500px] max-h-full overflow-hidden", children: /* @__PURE__ */ jsxRuntimeExports.jsx(AddBlocksPanel$1, { parentId: n, showHeading: !1 }) })
|
|
33857
33891
|
] }) });
|
|
33858
33892
|
}, SettingsPanel = () => {
|
|
33859
33893
|
const r = useSelectedBlock(), { t: n } = useTranslation(), [o, a] = useState$1(!0), i = useBuilderProp("onError", noop$1);
|
|
@@ -33880,7 +33914,7 @@ const TabletIcon = ({ landscape: r = !1 }) => /* @__PURE__ */ jsxRuntimeExports.
|
|
|
33880
33914
|
/* @__PURE__ */ jsxRuntimeExports.jsx("br", {}),
|
|
33881
33915
|
/* @__PURE__ */ jsxRuntimeExports.jsx("br", {})
|
|
33882
33916
|
] }) });
|
|
33883
|
-
}, SettingsPanel$1 = SettingsPanel, TopBar = lazy(() => import("./Topbar-
|
|
33917
|
+
}, SettingsPanel$1 = SettingsPanel, TopBar = lazy(() => import("./Topbar-Nc6eEWWP.js")), menuItems = [
|
|
33884
33918
|
{ icon: /* @__PURE__ */ jsxRuntimeExports.jsx(Layers, { size: 20 }), label: "sidebar.outline", component: Outline$1 },
|
|
33885
33919
|
{ icon: /* @__PURE__ */ jsxRuntimeExports.jsx(EditIcon, { size: 16 }), label: "sidebar.edit_block", component: SettingsPanel$1 },
|
|
33886
33920
|
{ icon: /* @__PURE__ */ jsxRuntimeExports.jsx(LightningBoltIcon, { className: "size-5" }), label: "sidebar.ai_assistant", component: AskAI },
|
|
@@ -33897,7 +33931,7 @@ const TabletIcon = ({ landscape: r = !1 }) => /* @__PURE__ */ jsxRuntimeExports.
|
|
|
33897
33931
|
}, RootLayout = () => {
|
|
33898
33932
|
const [r, n] = useState$1(0);
|
|
33899
33933
|
useChaiBuilderMsgListener(({ name: u }) => {
|
|
33900
|
-
u ===
|
|
33934
|
+
u === CHAI_BUILDER_EVENTS.SHOW_BLOCK_SETTINGS && n(1);
|
|
33901
33935
|
});
|
|
33902
33936
|
const o = useBuilderProp("sideBarComponents.top", []), a = (u) => {
|
|
33903
33937
|
u.preventDefault();
|
|
@@ -34008,40 +34042,43 @@ const TabletIcon = ({ landscape: r = !1 }) => /* @__PURE__ */ jsxRuntimeExports.
|
|
|
34008
34042
|
] }) }) });
|
|
34009
34043
|
};
|
|
34010
34044
|
export {
|
|
34011
|
-
|
|
34045
|
+
useStylingBreakpoint as $,
|
|
34012
34046
|
AddBlocksPanel$1 as A,
|
|
34013
34047
|
BlockSettings as B,
|
|
34014
34048
|
ChaiSelect$1 as C,
|
|
34015
34049
|
DarkMode as D,
|
|
34016
|
-
|
|
34050
|
+
useCanvasWidth as E,
|
|
34017
34051
|
FaCheck as F,
|
|
34018
|
-
|
|
34019
|
-
|
|
34052
|
+
useCanvasZoom as G,
|
|
34053
|
+
useCopyBlockIds as H,
|
|
34020
34054
|
ImportHTML$1 as I,
|
|
34021
|
-
|
|
34022
|
-
|
|
34023
|
-
|
|
34024
|
-
|
|
34025
|
-
|
|
34055
|
+
useCopyToClipboard as J,
|
|
34056
|
+
useCurrentPage as K,
|
|
34057
|
+
useCutBlockIds as L,
|
|
34058
|
+
useDarkMode as M,
|
|
34059
|
+
useDuplicateBlocks as N,
|
|
34026
34060
|
Outline$1 as O,
|
|
34027
|
-
|
|
34028
|
-
|
|
34029
|
-
|
|
34030
|
-
|
|
34061
|
+
useGetPageData as P,
|
|
34062
|
+
useHiddenBlockIds as Q,
|
|
34063
|
+
useHighlightBlockId as R,
|
|
34064
|
+
usePasteBlocks as S,
|
|
34031
34065
|
ThemeOptions as T,
|
|
34032
34066
|
UILibraries as U,
|
|
34033
|
-
|
|
34034
|
-
|
|
34035
|
-
|
|
34036
|
-
|
|
34037
|
-
|
|
34038
|
-
|
|
34067
|
+
useBrandingOptions as V,
|
|
34068
|
+
useRemoveBlocks as W,
|
|
34069
|
+
useRemoveClassesFromBlocks as X,
|
|
34070
|
+
useSelectedBlockCurrentClasses as Y,
|
|
34071
|
+
useSelectedBlockAllClasses as Z,
|
|
34072
|
+
useSelectedBlock as _,
|
|
34039
34073
|
useSelectedBlockIds as a,
|
|
34040
|
-
|
|
34041
|
-
|
|
34042
|
-
|
|
34043
|
-
|
|
34044
|
-
|
|
34074
|
+
useUILibraryBlocks as a0,
|
|
34075
|
+
useStylingState as a1,
|
|
34076
|
+
useSelectedBlocksDisplayChild as a2,
|
|
34077
|
+
useAllBlocks as a3,
|
|
34078
|
+
useActivePanel as a4,
|
|
34079
|
+
useAddBlockParent as a5,
|
|
34080
|
+
useSelectedBreakpoints as a6,
|
|
34081
|
+
useSelectedStylingBlocks as a7,
|
|
34045
34082
|
useUpdateBlocksProps as b,
|
|
34046
34083
|
useUpdateBlocksPropsRealtime as c,
|
|
34047
34084
|
useBuilderProp as d,
|
|
@@ -34049,22 +34086,22 @@ export {
|
|
|
34049
34086
|
usePreviewMode as f,
|
|
34050
34087
|
CanvasArea$1 as g,
|
|
34051
34088
|
BlockStyling as h,
|
|
34052
|
-
|
|
34053
|
-
|
|
34054
|
-
|
|
34055
|
-
|
|
34056
|
-
|
|
34057
|
-
|
|
34058
|
-
|
|
34059
|
-
|
|
34060
|
-
|
|
34061
|
-
|
|
34062
|
-
|
|
34063
|
-
|
|
34089
|
+
emitChaiBuilderMsg as i,
|
|
34090
|
+
useChaiBuilderMsgListener as j,
|
|
34091
|
+
CHAI_BUILDER_EVENTS as k,
|
|
34092
|
+
AISetContext as l,
|
|
34093
|
+
AIUserPrompt as m,
|
|
34094
|
+
BlockAttributesEditor as n,
|
|
34095
|
+
ChaiBuilderEditor as o,
|
|
34096
|
+
Breakpoints as p,
|
|
34097
|
+
UndoRedo as q,
|
|
34098
|
+
getBlocksFromHTML as r,
|
|
34099
|
+
useBlocksStore as s,
|
|
34100
|
+
useUndoManager as t,
|
|
34064
34101
|
useCodeEditor as u,
|
|
34065
|
-
|
|
34066
|
-
|
|
34067
|
-
|
|
34068
|
-
|
|
34069
|
-
|
|
34102
|
+
useBuilderReset as v,
|
|
34103
|
+
useReadOnlyMode as w,
|
|
34104
|
+
useActiveModal as x,
|
|
34105
|
+
useAddBlock as y,
|
|
34106
|
+
useAddClassesToBlocks as z
|
|
34070
34107
|
};
|