@blocklet/pages-kit-inner-components 0.4.157 → 0.4.159
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/lib/cjs/add-component.js +13 -13
- package/lib/cjs/chunks/{array-6wh7d5gC.js → array-5NwrYcJ5.js} +2 -2
- package/lib/cjs/chunks/{config-string-DnwpUGUo.js → config-string-DV4-1k4s.js} +1 -1
- package/lib/cjs/chunks/{draft-data-DPZIakr4.js → draft-data-QlwpWm4f.js} +1 -1
- package/lib/cjs/chunks/home-WKpO7IF-.js +38 -0
- package/lib/cjs/chunks/{publish-button-Cr534T09.js → publish-button-ImPoBEP5.js} +1 -1
- package/lib/cjs/chunks/state-DytLDIZR.js +1 -0
- package/lib/cjs/home.js +1 -1
- package/lib/cjs/locales.js +1 -1
- package/lib/cjs/setting.js +1 -1
- package/lib/cjs/theme.js +1 -239
- package/lib/es/add-component.js +299 -299
- package/lib/es/chunks/{array-DudMqbtU.js → array-BAy40Bak.js} +1 -4
- package/lib/es/chunks/{config-string-CNgatAMw.js → config-string-SEFT7xVe.js} +1 -1
- package/lib/es/chunks/{draft-data-DB1pDB18.js → draft-data-B7-JQvuO.js} +1 -1
- package/lib/es/chunks/home-DOrhBil-.js +527 -0
- package/lib/es/chunks/{publish-button-BauXdoix.js → publish-button-CxEaqAku.js} +3 -3
- package/lib/es/chunks/{state-BcZbsEn6.js → state-C_CbKF7g.js} +105 -98
- package/lib/es/home.js +3 -3
- package/lib/es/locales.js +8 -0
- package/lib/es/setting.js +37 -37
- package/lib/es/theme.js +416 -703
- package/package.json +18 -18
- package/lib/cjs/chunks/home-B5XHNRCN.js +0 -38
- package/lib/cjs/chunks/state-D4MG-uJB.js +0 -1
- package/lib/es/chunks/home-Bqe3w7ou.js +0 -533
|
@@ -8,11 +8,11 @@ import { useLocaleContext as Z } from "@arcblock/ux/lib/Locale/context";
|
|
|
8
8
|
import H, { getYjsDoc as ee } from "@syncedstore/core";
|
|
9
9
|
import { useSyncedStore as te } from "@syncedstore/react";
|
|
10
10
|
import { useLocalStorageState as ne } from "ahooks";
|
|
11
|
-
import { produce as
|
|
11
|
+
import { produce as v } from "immer";
|
|
12
12
|
import oe from "js-cookie";
|
|
13
13
|
import N from "lodash/debounce";
|
|
14
14
|
import { customAlphabet as re } from "nanoid";
|
|
15
|
-
import { createContext as se, useState as E, useRef as ce, useMemo as
|
|
15
|
+
import { createContext as se, useState as E, useRef as ce, useMemo as C, useCallback as k, useEffect as O, useContext as ie } from "react";
|
|
16
16
|
import { useParams as ae, useNavigate as de } from "react-router-dom";
|
|
17
17
|
import { IndexeddbPersistence as le } from "y-indexeddb";
|
|
18
18
|
import { WebsocketProvider as ue } from "y-websocket";
|
|
@@ -68,12 +68,12 @@ function Ye({
|
|
|
68
68
|
children: a,
|
|
69
69
|
waitingSynced: f
|
|
70
70
|
}) {
|
|
71
|
-
const [I, w] = E(!1), { locale: h } = Z(), S = V(), e = `${S}:MakerLocalState`, o = `${S}:${t}`, [
|
|
71
|
+
const [I, w] = E(!1), { locale: h } = Z(), S = V(), e = `${S}:MakerLocalState`, o = `${S}:${t}`, [r, s] = ne(e, {
|
|
72
72
|
defaultValue: {},
|
|
73
73
|
listenStorageChange: !0
|
|
74
|
-
}), c = ce(
|
|
75
|
-
c.current =
|
|
76
|
-
const i =
|
|
74
|
+
}), c = ce(r);
|
|
75
|
+
c.current = r;
|
|
76
|
+
const i = C(
|
|
77
77
|
() => H({
|
|
78
78
|
dataSourceIds: [],
|
|
79
79
|
dataSources: {},
|
|
@@ -87,9 +87,9 @@ function Ye({
|
|
|
87
87
|
resources: {}
|
|
88
88
|
}),
|
|
89
89
|
[]
|
|
90
|
-
), d =
|
|
91
|
-
|
|
92
|
-
const p =
|
|
90
|
+
), d = C(() => ee(i), [i]);
|
|
91
|
+
C(() => new le(o, d), [o, d]);
|
|
92
|
+
const p = C(
|
|
93
93
|
() => new ue(n, o, d, {
|
|
94
94
|
params: { token: oe.get("login_token") },
|
|
95
95
|
resyncInterval: 5 * 60 * 1e3
|
|
@@ -97,25 +97,25 @@ function Ye({
|
|
|
97
97
|
[n, o, d]
|
|
98
98
|
), g = k(() => {
|
|
99
99
|
p && (p.disconnect(), p.connect());
|
|
100
|
-
}, [p]), y =
|
|
100
|
+
}, [p]), y = C(
|
|
101
101
|
() => new me(
|
|
102
102
|
[d.getArray("pageIds"), d.getMap("pages"), d.getArray("supportedLocales"), d.getMap("config")],
|
|
103
103
|
{ doc: d }
|
|
104
104
|
),
|
|
105
105
|
[d]
|
|
106
|
-
), [j, x] = E(null), [R,
|
|
106
|
+
), [j, x] = E(null), [R, T] = E(!1), [$, _] = E(void 0), M = k(async () => {
|
|
107
107
|
if (S) {
|
|
108
|
-
|
|
108
|
+
T(!0);
|
|
109
109
|
try {
|
|
110
110
|
const l = await Ie(S);
|
|
111
111
|
x(l);
|
|
112
112
|
} catch (l) {
|
|
113
113
|
console.error("Failed to fetch project:", l);
|
|
114
114
|
} finally {
|
|
115
|
-
|
|
115
|
+
T(!1);
|
|
116
116
|
}
|
|
117
117
|
}
|
|
118
|
-
}, [S]),
|
|
118
|
+
}, [S]), G = k(
|
|
119
119
|
async (l, u) => {
|
|
120
120
|
var P;
|
|
121
121
|
if (_(void 0), !!S) {
|
|
@@ -136,39 +136,39 @@ function Ye({
|
|
|
136
136
|
[S, j]
|
|
137
137
|
);
|
|
138
138
|
O(() => {
|
|
139
|
-
S &&
|
|
140
|
-
}, [S,
|
|
141
|
-
const W =
|
|
139
|
+
S && M();
|
|
140
|
+
}, [S, M]);
|
|
141
|
+
const W = C(
|
|
142
142
|
() => ({
|
|
143
143
|
doc: d,
|
|
144
144
|
state: i,
|
|
145
145
|
localState: {
|
|
146
|
-
...
|
|
146
|
+
...r,
|
|
147
147
|
// always use the locale from the context
|
|
148
148
|
currentLocale: h
|
|
149
149
|
},
|
|
150
|
-
setLocalState: (l) =>
|
|
150
|
+
setLocalState: (l) => s(typeof l == "function" ? (u) => l(u ?? {}) : l),
|
|
151
151
|
undoManager: y,
|
|
152
152
|
projectState: {
|
|
153
153
|
project: j,
|
|
154
154
|
isLoadingProject: R,
|
|
155
|
-
error:
|
|
155
|
+
error: $
|
|
156
156
|
},
|
|
157
|
-
updateProject:
|
|
157
|
+
updateProject: G,
|
|
158
158
|
forceSync: g
|
|
159
159
|
}),
|
|
160
160
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
161
161
|
[
|
|
162
162
|
d,
|
|
163
163
|
i,
|
|
164
|
-
JSON.stringify(
|
|
164
|
+
JSON.stringify(r),
|
|
165
165
|
// resolve the problem of react warning
|
|
166
|
-
|
|
166
|
+
s,
|
|
167
167
|
y,
|
|
168
168
|
j,
|
|
169
169
|
R,
|
|
170
|
-
|
|
171
|
-
|
|
170
|
+
G,
|
|
171
|
+
$,
|
|
172
172
|
h,
|
|
173
173
|
g
|
|
174
174
|
]
|
|
@@ -179,19 +179,19 @@ function Ye({
|
|
|
179
179
|
l.meta.set("localState", { currentPageId: u, currentLocale: P, pages: m });
|
|
180
180
|
}), y.on("stack-item-popped", ({ stackItem: l }) => {
|
|
181
181
|
const u = l.meta.get("localState");
|
|
182
|
-
u &&
|
|
182
|
+
u && s((P) => ({ ...P, ...u }));
|
|
183
183
|
});
|
|
184
|
-
}, [y,
|
|
185
|
-
p.awareness.setLocalState(
|
|
186
|
-
}, [p,
|
|
184
|
+
}, [y, s]), O(() => {
|
|
185
|
+
p.awareness.setLocalState(r);
|
|
186
|
+
}, [p, r]), O(() => {
|
|
187
187
|
p.once("synced", () => w(!0));
|
|
188
188
|
const l = () => {
|
|
189
|
-
|
|
189
|
+
s((m) => ({
|
|
190
190
|
...m,
|
|
191
191
|
networkStatus: void 0
|
|
192
192
|
}));
|
|
193
193
|
}, u = () => {
|
|
194
|
-
|
|
194
|
+
s((m) => ({
|
|
195
195
|
...m,
|
|
196
196
|
networkStatus: "offline"
|
|
197
197
|
}));
|
|
@@ -201,18 +201,18 @@ function Ye({
|
|
|
201
201
|
return p.on("status", P), window.addEventListener("online", l), window.addEventListener("offline", u), () => {
|
|
202
202
|
p.off("status", P), window.removeEventListener("online", l), window.removeEventListener("offline", u);
|
|
203
203
|
};
|
|
204
|
-
}, [p,
|
|
204
|
+
}, [p, s]), f && !I ? null : /* @__PURE__ */ L(B.Provider, { value: W, children: a });
|
|
205
205
|
}
|
|
206
|
-
const
|
|
206
|
+
const Ce = () => {
|
|
207
207
|
const n = ie(B);
|
|
208
208
|
if (!n)
|
|
209
209
|
throw new Error("Context is null");
|
|
210
|
-
const t = te(n.state), { setLocalState: a, localState: f } = n, I = de(), w = V(), h =
|
|
210
|
+
const t = te(n.state), { setLocalState: a, localState: f } = n, I = de(), w = V(), h = C(
|
|
211
211
|
() => ({
|
|
212
212
|
setCurrentSectionId: (e, o) => {
|
|
213
|
-
var
|
|
214
|
-
e === f.currentPageId && o === ((
|
|
215
|
-
(c) =>
|
|
213
|
+
var r, s;
|
|
214
|
+
e === f.currentPageId && o === ((s = (r = f.pages) == null ? void 0 : r[e]) == null ? void 0 : s.currentSectionId) || (I(b("/admin/maker", w ?? "", "pages", e)), a(
|
|
215
|
+
(c) => v(c, (i) => {
|
|
216
216
|
var d;
|
|
217
217
|
i.currentPageId = e, i.currentComponentId = void 0, i.customComponentPreviewerProperties = {}, o !== void 0 && (i.pages ?? (i.pages = {}), (d = i.pages)[e] ?? (d[e] = {}), i.pages[e].currentSectionId = o ?? void 0), o ? window.sessionStorage.setItem("iframe_show_id", `"${o}"`) : window.sessionStorage.removeItem("iframe_show_id");
|
|
218
218
|
})
|
|
@@ -220,65 +220,72 @@ const ve = () => {
|
|
|
220
220
|
},
|
|
221
221
|
setCurrentComponentId: (e) => {
|
|
222
222
|
e !== f.currentComponentId && (I(b("/admin/maker", w ?? "", "components", e)), a(
|
|
223
|
-
(o) =>
|
|
224
|
-
|
|
223
|
+
(o) => v(o, (r) => {
|
|
224
|
+
r.currentComponentId = e, r.customComponentPreviewerProperties = {};
|
|
225
225
|
})
|
|
226
226
|
));
|
|
227
227
|
},
|
|
228
228
|
setCurrentRouteId: ({ routeId: e, dynamicParams: o }) => {
|
|
229
229
|
a(
|
|
230
|
-
(
|
|
231
|
-
|
|
230
|
+
(r) => v(r, (s) => {
|
|
231
|
+
s.currentRouteId = e, s.currentDynamicParams = o;
|
|
232
232
|
})
|
|
233
233
|
);
|
|
234
234
|
},
|
|
235
235
|
setCustomComponentPreviewerProperties: (() => {
|
|
236
236
|
const e = {}, o = N(() => {
|
|
237
237
|
a(
|
|
238
|
-
(
|
|
239
|
-
|
|
240
|
-
...
|
|
238
|
+
(r) => v(r, (s) => {
|
|
239
|
+
s.customComponentPreviewerProperties = {
|
|
240
|
+
...s == null ? void 0 : s.customComponentPreviewerProperties,
|
|
241
241
|
...e
|
|
242
242
|
}, Object.keys(e).forEach((c) => delete e[c]);
|
|
243
243
|
})
|
|
244
244
|
);
|
|
245
245
|
}, 5);
|
|
246
|
-
return (
|
|
247
|
-
Object.assign(e,
|
|
246
|
+
return (r) => {
|
|
247
|
+
Object.assign(e, r), o();
|
|
248
248
|
};
|
|
249
249
|
})(),
|
|
250
250
|
setRouteGenerateProcess: (e) => {
|
|
251
251
|
a(
|
|
252
|
-
(o) =>
|
|
253
|
-
e ?
|
|
254
|
-
...
|
|
252
|
+
(o) => v(o, (r) => {
|
|
253
|
+
e ? r.routeGenerateProcess = {
|
|
254
|
+
...r.routeGenerateProcess,
|
|
255
255
|
...e
|
|
256
|
-
} :
|
|
256
|
+
} : r.routeGenerateProcess = {};
|
|
257
257
|
})
|
|
258
258
|
);
|
|
259
259
|
},
|
|
260
260
|
resetRouteGenerateProcess: () => {
|
|
261
261
|
a(
|
|
262
|
-
(e) =>
|
|
262
|
+
(e) => v(e, (o) => {
|
|
263
263
|
o.routeGenerateProcess = {
|
|
264
264
|
progress: "complete"
|
|
265
265
|
};
|
|
266
266
|
})
|
|
267
267
|
);
|
|
268
|
+
},
|
|
269
|
+
setCurrentThemeMode: (e) => {
|
|
270
|
+
a(
|
|
271
|
+
(o) => v(o, (r) => {
|
|
272
|
+
r.currentThemeMode = e;
|
|
273
|
+
})
|
|
274
|
+
);
|
|
268
275
|
}
|
|
269
276
|
}),
|
|
270
277
|
[a, I, w]
|
|
271
|
-
), S =
|
|
278
|
+
), S = C(
|
|
272
279
|
() => ({
|
|
273
280
|
addPage: (e, o) => {
|
|
274
281
|
var c, i, d, p, g, y;
|
|
275
|
-
const
|
|
282
|
+
const r = (e == null ? void 0 : e.id) ?? A(), s = {
|
|
276
283
|
...e,
|
|
277
|
-
id:
|
|
284
|
+
id: r,
|
|
278
285
|
createdAt: (e == null ? void 0 : e.createdAt) ?? (/* @__PURE__ */ new Date()).toISOString(),
|
|
279
286
|
updatedAt: (e == null ? void 0 : e.updatedAt) ?? (/* @__PURE__ */ new Date()).toISOString(),
|
|
280
287
|
publishedAt: (/* @__PURE__ */ new Date(0)).toISOString(),
|
|
281
|
-
slug: (e == null ? void 0 : e.slug) ?? `/${
|
|
288
|
+
slug: (e == null ? void 0 : e.slug) ?? `/${r}`,
|
|
282
289
|
sections: (e == null ? void 0 : e.sections) ?? {},
|
|
283
290
|
sectionIds: (e == null ? void 0 : e.sectionIds) ?? [],
|
|
284
291
|
isPublic: (e == null ? void 0 : e.isPublic) ?? !0,
|
|
@@ -292,17 +299,17 @@ const ve = () => {
|
|
|
292
299
|
}
|
|
293
300
|
};
|
|
294
301
|
return n.doc.transact(() => {
|
|
295
|
-
t.pages[
|
|
296
|
-
}),
|
|
302
|
+
t.pages[s.id] = s, t.pageIds.splice(o ?? t.pageIds.length, 0, s.id);
|
|
303
|
+
}), s;
|
|
297
304
|
},
|
|
298
305
|
addRoute: (e, o) => {
|
|
299
|
-
const
|
|
306
|
+
const r = (e == null ? void 0 : e.id) ?? A(), s = {
|
|
300
307
|
...e,
|
|
301
|
-
id:
|
|
308
|
+
id: r,
|
|
302
309
|
createdAt: (e == null ? void 0 : e.createdAt) ?? (/* @__PURE__ */ new Date()).toISOString(),
|
|
303
310
|
updatedAt: (e == null ? void 0 : e.updatedAt) ?? (/* @__PURE__ */ new Date()).toISOString(),
|
|
304
311
|
publishedAt: (/* @__PURE__ */ new Date(0)).toISOString(),
|
|
305
|
-
path: (e == null ? void 0 : e.path) ?? `/${
|
|
312
|
+
path: (e == null ? void 0 : e.path) ?? `/${r}`,
|
|
306
313
|
handler: (e == null ? void 0 : e.handler) ?? "Pages Kit",
|
|
307
314
|
isPublic: (e == null ? void 0 : e.isPublic) ?? !0,
|
|
308
315
|
params: (e == null ? void 0 : e.params) ?? [],
|
|
@@ -311,17 +318,17 @@ const ve = () => {
|
|
|
311
318
|
dataSource: (e == null ? void 0 : e.dataSource) ?? {}
|
|
312
319
|
};
|
|
313
320
|
return n.doc.transact(() => {
|
|
314
|
-
t.routes ?? (t.routes = {}), t.routeIds ?? (t.routeIds = []), t.routes[
|
|
315
|
-
}),
|
|
321
|
+
t.routes ?? (t.routes = {}), t.routeIds ?? (t.routeIds = []), t.routes[s.id] = s, t.routeIds.splice(o ?? t.routeIds.length, 0, s.id);
|
|
322
|
+
}), s;
|
|
316
323
|
},
|
|
317
324
|
deleteRoute: (e) => {
|
|
318
|
-
var
|
|
325
|
+
var r;
|
|
319
326
|
if (!e)
|
|
320
327
|
return;
|
|
321
|
-
const o = (
|
|
328
|
+
const o = (r = t.routeIds) == null ? void 0 : r.indexOf(e);
|
|
322
329
|
o !== void 0 && o !== -1 && n.doc.transact(() => {
|
|
323
|
-
var
|
|
324
|
-
(
|
|
330
|
+
var s, c;
|
|
331
|
+
(s = t.routeIds) == null || s.splice(o, 1), (c = t.routes) == null || delete c[e];
|
|
325
332
|
});
|
|
326
333
|
},
|
|
327
334
|
deletePage: (e) => {
|
|
@@ -331,12 +338,12 @@ const ve = () => {
|
|
|
331
338
|
});
|
|
332
339
|
},
|
|
333
340
|
movePage: (e, o) => {
|
|
334
|
-
const { pageIds:
|
|
335
|
-
|
|
341
|
+
const { pageIds: r } = t, s = r.indexOf(e);
|
|
342
|
+
s >= 0 && r.splice(o, 0, ...r.splice(s, 1));
|
|
336
343
|
},
|
|
337
|
-
addSection: (e, o,
|
|
338
|
-
const
|
|
339
|
-
if (!
|
|
344
|
+
addSection: (e, o, r) => {
|
|
345
|
+
const s = t.pages[e];
|
|
346
|
+
if (!s)
|
|
340
347
|
throw new Error(`Page ${e} is not exists`);
|
|
341
348
|
const c = {
|
|
342
349
|
...o,
|
|
@@ -345,40 +352,40 @@ const ve = () => {
|
|
|
345
352
|
llmConfig: o.llmConfig ?? {}
|
|
346
353
|
};
|
|
347
354
|
return n.doc.transact(() => {
|
|
348
|
-
|
|
355
|
+
s.sections[c.id] = c, s.sectionIds.splice(r ?? s.sectionIds.length, 0, c.id);
|
|
349
356
|
}), c;
|
|
350
357
|
},
|
|
351
358
|
deleteSection: (e, o) => {
|
|
352
|
-
const
|
|
353
|
-
if (!
|
|
359
|
+
const r = t.pages[e];
|
|
360
|
+
if (!r)
|
|
354
361
|
throw new Error(`Page ${e} is not exists`);
|
|
355
|
-
const
|
|
356
|
-
|
|
357
|
-
|
|
362
|
+
const s = r.sectionIds.indexOf(o);
|
|
363
|
+
s !== -1 && n.doc.transact(() => {
|
|
364
|
+
r.sectionIds.splice(s, 1), delete r.sections[o];
|
|
358
365
|
});
|
|
359
366
|
},
|
|
360
|
-
toggleSectionVisibility: (e, o,
|
|
361
|
-
const
|
|
362
|
-
if (!
|
|
367
|
+
toggleSectionVisibility: (e, o, r) => {
|
|
368
|
+
const s = t.pages[e];
|
|
369
|
+
if (!s)
|
|
363
370
|
throw new Error(`Page ${e} is not exists`);
|
|
364
|
-
const c =
|
|
365
|
-
c && (c.visibility =
|
|
371
|
+
const c = s.sections[o];
|
|
372
|
+
c && (c.visibility = r);
|
|
366
373
|
},
|
|
367
|
-
moveSection: (e, o,
|
|
368
|
-
const
|
|
369
|
-
if (!
|
|
374
|
+
moveSection: (e, o, r) => {
|
|
375
|
+
const s = t.pages[e];
|
|
376
|
+
if (!s)
|
|
370
377
|
throw new Error(`Page ${e} is not exists`);
|
|
371
|
-
const { sectionIds: c } =
|
|
372
|
-
i >= 0 && c.splice(
|
|
378
|
+
const { sectionIds: c } = s, i = c.indexOf(o);
|
|
379
|
+
i >= 0 && c.splice(r, 0, ...c.splice(i, 1));
|
|
373
380
|
},
|
|
374
381
|
addDataSource: (e) => {
|
|
375
|
-
const o = e.id ?? A(),
|
|
382
|
+
const o = e.id ?? A(), r = {
|
|
376
383
|
...e ?? {},
|
|
377
384
|
id: o,
|
|
378
385
|
createdAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
379
386
|
};
|
|
380
387
|
return n.doc.transact(() => {
|
|
381
|
-
t.dataSourceIds ?? (t.dataSourceIds = []), t.dataSources ?? (t.dataSources = {}), t.dataSourceIds.push(o), t.dataSources[o] =
|
|
388
|
+
t.dataSourceIds ?? (t.dataSourceIds = []), t.dataSources ?? (t.dataSources = {}), t.dataSourceIds.push(o), t.dataSources[o] = r;
|
|
382
389
|
}), t.dataSources[o];
|
|
383
390
|
},
|
|
384
391
|
deleteDataSource: (e) => {
|
|
@@ -402,15 +409,15 @@ const ve = () => {
|
|
|
402
409
|
return e ? t.pages[e] : void 0;
|
|
403
410
|
},
|
|
404
411
|
get currentSection() {
|
|
405
|
-
var
|
|
412
|
+
var s, c, i;
|
|
406
413
|
const {
|
|
407
414
|
localState: { currentPageId: e, ...o }
|
|
408
415
|
} = n;
|
|
409
416
|
if (!e)
|
|
410
417
|
return;
|
|
411
|
-
const
|
|
412
|
-
if (
|
|
413
|
-
return (i = t.pages[e]) == null ? void 0 : i.sections[
|
|
418
|
+
const r = (c = (s = o.pages) == null ? void 0 : s[e]) == null ? void 0 : c.currentSectionId;
|
|
419
|
+
if (r)
|
|
420
|
+
return (i = t.pages[e]) == null ? void 0 : i.sections[r];
|
|
414
421
|
},
|
|
415
422
|
get currentRoute() {
|
|
416
423
|
var o;
|
|
@@ -424,7 +431,7 @@ const ve = () => {
|
|
|
424
431
|
const { projectId: n } = ae();
|
|
425
432
|
return n ?? fe() ?? "";
|
|
426
433
|
};
|
|
427
|
-
function
|
|
434
|
+
function ve(n) {
|
|
428
435
|
var f, I;
|
|
429
436
|
const { resources: t } = n;
|
|
430
437
|
if (!t.components)
|
|
@@ -448,16 +455,16 @@ function ge(n) {
|
|
|
448
455
|
}
|
|
449
456
|
function je(n) {
|
|
450
457
|
return {
|
|
451
|
-
...
|
|
458
|
+
...ve(n),
|
|
452
459
|
...ge(n)
|
|
453
460
|
};
|
|
454
461
|
}
|
|
455
|
-
const Ze = () => je(
|
|
462
|
+
const Ze = () => je(Ce().state);
|
|
456
463
|
export {
|
|
457
464
|
Ke as E,
|
|
458
465
|
Ye as S,
|
|
459
466
|
qe as a,
|
|
460
|
-
|
|
467
|
+
Ce as b,
|
|
461
468
|
We as c,
|
|
462
469
|
je as d,
|
|
463
470
|
Xe as e,
|
|
@@ -466,7 +473,7 @@ export {
|
|
|
466
473
|
J as h,
|
|
467
474
|
Ve as i,
|
|
468
475
|
ge as j,
|
|
469
|
-
|
|
476
|
+
ve as k,
|
|
470
477
|
fe as l,
|
|
471
478
|
A as n,
|
|
472
479
|
ze as t,
|
package/lib/es/home.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
|
-
import "./chunks/state-
|
|
2
|
+
import "./chunks/state-C_CbKF7g.js";
|
|
3
3
|
import "@arcblock/ux/lib/Locale/context";
|
|
4
4
|
import "@arcblock/ux/lib/Result";
|
|
5
5
|
import "@blocklet/pages-kit/builtin/page/header";
|
|
@@ -21,8 +21,8 @@ import "react-helmet";
|
|
|
21
21
|
import "react-router-dom";
|
|
22
22
|
import "react-use";
|
|
23
23
|
import "ufo";
|
|
24
|
-
import "./chunks/array-
|
|
25
|
-
import { a as D, P as R, d as S, c as W, b as j, T as k, H as q } from "./chunks/home-
|
|
24
|
+
import "./chunks/array-BAy40Bak.js";
|
|
25
|
+
import { a as D, P as R, d as S, c as W, b as j, T as k, H as q } from "./chunks/home-DOrhBil-.js";
|
|
26
26
|
export {
|
|
27
27
|
D as HomeView,
|
|
28
28
|
R as PageRoutes,
|
package/lib/es/locales.js
CHANGED
|
@@ -103,6 +103,10 @@ const t = e({
|
|
|
103
103
|
configColor: "Config color",
|
|
104
104
|
configColorMuiTheme: "Theme Color",
|
|
105
105
|
configColorCustomColor: "Custom Color",
|
|
106
|
+
configColorMuiThemeInfo: "Use theme color, it will automatically adapt to the theme color and dark mode",
|
|
107
|
+
configColorMuiThemeWithAlternateColor: " (includes light and dark modes)",
|
|
108
|
+
configColorLightMode: "Light Mode",
|
|
109
|
+
configColorDarkMode: "Dark Mode",
|
|
106
110
|
import: "Import",
|
|
107
111
|
importDialog: {
|
|
108
112
|
upload: {
|
|
@@ -584,6 +588,10 @@ const t = e({
|
|
|
584
588
|
configColor: "设置颜色",
|
|
585
589
|
configColorMuiTheme: "主题色",
|
|
586
590
|
configColorCustomColor: "自定义颜色",
|
|
591
|
+
configColorMuiThemeInfo: "使用主题色会自动适应主题配色及亮暗模式",
|
|
592
|
+
configColorMuiThemeWithAlternateColor: " (包含亮/暗两种模式)",
|
|
593
|
+
configColorLightMode: "亮色模式",
|
|
594
|
+
configColorDarkMode: "暗黑模式",
|
|
587
595
|
import: "导入",
|
|
588
596
|
importDialog: {
|
|
589
597
|
upload: {
|