@oktis-works/admin 0.4.19 → 0.4.20
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/client/_astro/{ActivityWidget.DGLCPDgH.js → ActivityWidget.BbEtaaM-.js} +2 -2
- package/dist/client/_astro/{AdminBar.Cj9iKizr.js → AdminBar.CU2eba2D.js} +2 -2
- package/dist/client/_astro/{AtGlanceWidget.B1bDhxvN.js → AtGlanceWidget.C1hpeDlx.js} +1 -1
- package/dist/client/_astro/ContentEditor.Bc5Jq8Dv.js +1 -0
- package/dist/client/_astro/{ContentEditor.SP4PO6Pb.js → ContentEditor.DvpaqJBD.js} +2 -2
- package/dist/client/_astro/ContentTypeWorkspace.DakVi21h.js +1 -0
- package/dist/client/_astro/{CustomFieldsManager.CvWD3R1q.js → CustomFieldsManager.B7WOTvb7.js} +1 -1
- package/dist/client/_astro/DashboardHome.CUfuLLDH.js +1 -0
- package/dist/client/_astro/DashboardLayout.CGou4voc.css +1 -0
- package/dist/client/_astro/DashboardLayout.astro_astro_type_script_index_0_lang.Dpnx6U2l.js +4 -0
- package/dist/client/_astro/{Footer.BqzSGnHm.js → Footer.rUGgtlfI.js} +1 -1
- package/dist/client/_astro/{GeneralSettings.Ditcyy4b.js → GeneralSettings.C4mnJ7P2.js} +1 -1
- package/dist/client/_astro/{MediaLibrary.qzwN-LI5.js → MediaLibrary.2geQYfXB.js} +1 -1
- package/dist/client/_astro/{PluginManager.DEkeX_0Z.js → PluginManager.D3pm88iu.js} +1 -1
- package/dist/client/_astro/PostTypesManager.Cyhr3VEJ.js +1 -0
- package/dist/client/_astro/{QuickDraftWidget.xoJjOM58.js → QuickDraftWidget.CPljoS31.js} +2 -2
- package/dist/client/_astro/{ResourceHubs.BHlRlPvI.js → ResourceHubs.DpCJERsJ.js} +1 -1
- package/dist/client/_astro/{TaxonomiesManager.DKQAGS8n.js → TaxonomiesManager.P3bc-fnu.js} +1 -1
- package/dist/client/_astro/{TaxonomyTermsManager.CyB7XH-D.js → TaxonomyTermsManager.BxP9gwm7.js} +1 -1
- package/dist/client/_astro/{ThemeManager.BBKCx5pa.js → ThemeManager.3MUOwqex.js} +1 -1
- package/dist/client/_astro/{UserCreateForm.BDsHkQYW.js → UserCreateForm.C3RiEJEa.js} +1 -1
- package/dist/client/_astro/{UsersManager.DeQ4uL3a.js → UsersManager.DR9XR3FX.js} +1 -1
- package/dist/client/_astro/api.25OAsWO0.js +1 -0
- package/dist/client/_astro/{extensions.DLE6XtMB.js → extensions.Bj86CHnv.js} +1 -1
- package/dist/client/_astro/i18n.C24_pkIi.js +1 -0
- package/dist/client/_astro/{login.astro_astro_type_script_index_0_lang.BPE3sVZJ.js → login.astro_astro_type_script_index_0_lang.O-AlzgHd.js} +1 -1
- package/dist/client/_astro/pt-BR.BPvwNpKR.js +1 -0
- package/dist/client/_astro/{src.lFTwiz1W.js → src.Cq47pnsg.js} +1 -1
- package/dist/client/_astro/{version.Cwfv80ER.js → version.BQq07lEn.js} +1 -1
- package/dist/server/chunks/{ContentEditor_CxZJjeXR.mjs → ContentEditor_DS7flRjR.mjs} +12 -5
- package/dist/server/chunks/{DashboardLayout_DCIiRkcO.mjs → DashboardLayout_09DepSVn.mjs} +7 -7
- package/dist/server/chunks/{MediaLibrary_azhfNs4N.mjs → MediaLibrary_Xs09kLza.mjs} +2 -2
- package/dist/server/chunks/{ResourceHubs_BJMX1AJR.mjs → ResourceHubs_Dwb0xyPZ.mjs} +1 -1
- package/dist/server/chunks/{_slug__BEfbBGa_.mjs → _slug__l8CTaLpP.mjs} +1 -1
- package/dist/server/chunks/{access_DNxcWCO1.mjs → access_D93W5BWD.mjs} +2 -2
- package/dist/server/chunks/{custom-fields_DI9f2Pqi.mjs → custom-fields_Dp7DHJ0M.mjs} +2 -2
- package/dist/server/chunks/{edit_3GtD2cva.mjs → edit_hSCrM2Gq.mjs} +12 -12
- package/dist/server/chunks/{general_CbiPNS7I.mjs → general_Ct9MU7b-.mjs} +2 -2
- package/dist/server/chunks/{i18n_DIBvEjfq.mjs → i18n_BqFK0MIW.mjs} +20 -2
- package/dist/server/chunks/{index_C3amWOJX.mjs → index_B77wdzK2.mjs} +1 -1
- package/dist/server/chunks/{index_BZJqnzEO.mjs → index_CBfRX_VO.mjs} +89 -44
- package/dist/server/chunks/{index_kTsjYnf7.mjs → index_Cv2j9xC_.mjs} +5 -5
- package/dist/server/chunks/{index_BcV8TVEC.mjs → index_DQ5pFuPN.mjs} +2 -2
- package/dist/server/chunks/{index_CTJw_OsD.mjs → index_uv0IHg8r.mjs} +2 -2
- package/dist/server/chunks/{new_uLMmBd95.mjs → new_DpJfTahF.mjs} +2 -2
- package/dist/server/chunks/{new_Dg9ykZGm.mjs → new_XOnqlHm3.mjs} +12 -12
- package/dist/server/chunks/{operations_vnv5cnws.mjs → operations_0sYvzzNC.mjs} +2 -2
- package/dist/server/chunks/{plugins_pNXwbZGI.mjs → plugins_Clk92l6Q.mjs} +2 -2
- package/dist/server/chunks/{post-types_g7oMw8xZ.mjs → post-types_DziideHh.mjs} +40 -14
- package/dist/server/chunks/{pt-BR_BM0FS26r.mjs → pt-BR_CBnqy3xP.mjs} +15 -1
- package/dist/server/chunks/{resources_DhbyXd_o.mjs → resources_dPTDnpAf.mjs} +2 -2
- package/dist/server/chunks/{taxonomies_CX8h73Lt.mjs → taxonomies_Bc6xPaKp.mjs} +2 -2
- package/dist/server/chunks/{taxonomy_D8om_RNg.mjs → taxonomy_Cv4_KTTL.mjs} +11 -11
- package/dist/server/chunks/{themes_JX5WVf2J.mjs → themes_BRtDtEK7.mjs} +2 -2
- package/dist/server/chunks/{upload_r2qJskLo.mjs → upload_CB_L9tkU.mjs} +2 -2
- package/dist/server/entry.mjs +96 -72
- package/dist/server/virtual_astro_middleware.mjs +1 -1
- package/package.json +6 -5
- package/dist/client/_astro/ContentList.o2zVu57t.js +0 -1
- package/dist/client/_astro/DashboardHome.DnCbpnkg.js +0 -1
- package/dist/client/_astro/DashboardLayout.BOoRKX4v.css +0 -1
- package/dist/client/_astro/DashboardLayout.astro_astro_type_script_index_0_lang.7Kcbf7KO.js +0 -1
- package/dist/client/_astro/PostTypesManager.CGYbeXgb.js +0 -1
- package/dist/client/_astro/api.DD5u5p4h.js +0 -1
- package/dist/client/_astro/i18n.JWFhLjfn.js +0 -1
- package/dist/client/_astro/pt-BR.CGjPpous.js +0 -1
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent$1 } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { n as useTranslation, r as apiClient } from "./
|
|
5
|
-
import { c as Select, i as Card, n as Badge, o as Input, r as Button, s as Pagination, t as $$DashboardLayout, u as Table } from "./
|
|
6
|
-
import {
|
|
4
|
+
import { n as useTranslation, r as apiClient } from "./i18n_BqFK0MIW.mjs";
|
|
5
|
+
import { c as Select, i as Card, n as Badge, o as Input, r as Button, s as Pagination, t as $$DashboardLayout, u as Table } from "./DashboardLayout_09DepSVn.mjs";
|
|
6
|
+
import { t as ContentEditor } from "./ContentEditor_DS7flRjR.mjs";
|
|
7
|
+
import { createComponent, escape, memo, ssr, ssrAttribute, ssrHydrationKey } from "solid-js/web";
|
|
7
8
|
import { Show, createMemo, createSignal, onMount } from "solid-js";
|
|
8
9
|
//#region src/components/content/ContentList.tsx
|
|
9
|
-
var _tmpl
|
|
10
|
+
var _tmpl$$1 = [
|
|
10
11
|
"<span",
|
|
11
12
|
" class=\"muted\">",
|
|
12
13
|
"</span>"
|
|
13
14
|
];
|
|
14
|
-
var _tmpl$2 = [
|
|
15
|
+
var _tmpl$2$1 = [
|
|
15
16
|
"<div",
|
|
16
17
|
" class=\"users-table__actions\"><a class=\"btn btn-secondary btn-sm\" href=\"",
|
|
17
18
|
"\">",
|
|
@@ -20,27 +21,22 @@ var _tmpl$2 = [
|
|
|
20
21
|
"<!--/--></div>"
|
|
21
22
|
];
|
|
22
23
|
var _tmpl$3 = [
|
|
23
|
-
"<a",
|
|
24
|
-
" class=\"btn btn-primary\"",
|
|
25
|
-
">",
|
|
26
|
-
"</a>"
|
|
27
|
-
];
|
|
28
|
-
var _tmpl$4 = [
|
|
29
24
|
"<div",
|
|
30
25
|
" class=\"notice notice--error\">",
|
|
31
26
|
"</div>"
|
|
32
27
|
];
|
|
33
|
-
var _tmpl$
|
|
28
|
+
var _tmpl$4 = [
|
|
34
29
|
"<div",
|
|
35
30
|
" class=\"notice\">",
|
|
36
31
|
"</div>"
|
|
37
32
|
];
|
|
38
|
-
var _tmpl$
|
|
33
|
+
var _tmpl$5 = [
|
|
39
34
|
"<div",
|
|
40
35
|
" class=\"content-list\"><div class=\"content-list__heading\"><div><h2>",
|
|
41
36
|
"</h2><p class=\"muted\">",
|
|
42
|
-
"</p></div
|
|
43
|
-
"
|
|
37
|
+
"</p></div><a class=\"btn btn-primary\"",
|
|
38
|
+
">",
|
|
39
|
+
"</a></div><!--$-->",
|
|
44
40
|
"<!--/--><!--$-->",
|
|
45
41
|
"<!--/--><div class=\"toolbar\"><!--$-->",
|
|
46
42
|
"<!--/--><!--$-->",
|
|
@@ -57,14 +53,14 @@ function formatDate(row) {
|
|
|
57
53
|
const date = new Date(value);
|
|
58
54
|
return Number.isNaN(date.getTime()) ? "—" : date.toLocaleString("pt-BR");
|
|
59
55
|
}
|
|
60
|
-
function ContentList() {
|
|
56
|
+
function ContentList(props) {
|
|
61
57
|
const { t } = useTranslation();
|
|
62
58
|
const [items, setItems] = createSignal([]);
|
|
63
59
|
const [types, setTypes] = createSignal([]);
|
|
64
60
|
const [total, setTotal] = createSignal(0);
|
|
65
61
|
const [page, setPage] = createSignal(1);
|
|
66
62
|
const [search, setSearch] = createSignal("");
|
|
67
|
-
const [type
|
|
63
|
+
const [type] = createSignal(props.contentType);
|
|
68
64
|
const [status, setStatus] = createSignal("");
|
|
69
65
|
const [error, setError] = createSignal("");
|
|
70
66
|
const [info, setInfo] = createSignal("");
|
|
@@ -87,7 +83,6 @@ function ContentList() {
|
|
|
87
83
|
};
|
|
88
84
|
onMount(async () => {
|
|
89
85
|
const query = new URLSearchParams(window.location.search);
|
|
90
|
-
setType(query.get("type") ?? "");
|
|
91
86
|
setStatus(query.get("status") ?? "");
|
|
92
87
|
setSearch(query.get("search") ?? "");
|
|
93
88
|
await load();
|
|
@@ -97,7 +92,7 @@ function ContentList() {
|
|
|
97
92
|
});
|
|
98
93
|
const activeType = createMemo(() => types().find((entry) => entry.slug === type()));
|
|
99
94
|
const pageTitle = createMemo(() => activeType()?.pluralLabel || t("content.list.title"));
|
|
100
|
-
const newContentHref = createMemo(() => `/content
|
|
95
|
+
const newContentHref = createMemo(() => `/content/${encodeURIComponent(type())}/new`);
|
|
101
96
|
const searchNow = async () => {
|
|
102
97
|
setPage(1);
|
|
103
98
|
await load();
|
|
@@ -150,7 +145,7 @@ function ContentList() {
|
|
|
150
145
|
{
|
|
151
146
|
key: "updated_at",
|
|
152
147
|
label: t("content.list.columns.updated"),
|
|
153
|
-
render: (_value, row) => ssr(_tmpl
|
|
148
|
+
render: (_value, row) => ssr(_tmpl$$1, ssrHydrationKey(), escape(formatDate(row)))
|
|
154
149
|
},
|
|
155
150
|
{
|
|
156
151
|
key: "actions",
|
|
@@ -158,7 +153,7 @@ function ContentList() {
|
|
|
158
153
|
render: (_value, row) => {
|
|
159
154
|
const content = row;
|
|
160
155
|
const isPublished = raw(content)["status"] === "PUBLISHED";
|
|
161
|
-
return ssr(_tmpl$2, ssrHydrationKey(), `/content/edit?id=${escape(encodeURIComponent(content.id), true)}`, escape(t("content.list.actions.edit")), escape(createComponent(Button, {
|
|
156
|
+
return ssr(_tmpl$2$1, ssrHydrationKey(), `/content/${escape(encodeURIComponent(content.type || type()), true)}/edit?id=${escape(encodeURIComponent(content.id), true)}`, escape(t("content.list.actions.edit")), escape(createComponent(Button, {
|
|
162
157
|
variant: isPublished ? "secondary" : "primary",
|
|
163
158
|
size: "sm",
|
|
164
159
|
get loading() {
|
|
@@ -179,26 +174,19 @@ function ContentList() {
|
|
|
179
174
|
}
|
|
180
175
|
}
|
|
181
176
|
]);
|
|
182
|
-
return ssr(_tmpl$
|
|
183
|
-
get when() {
|
|
184
|
-
return type();
|
|
185
|
-
},
|
|
186
|
-
get children() {
|
|
187
|
-
return ssr(_tmpl$3, ssrHydrationKey(), ssrAttribute("href", escape(newContentHref(), true), false), escape(t("content.list.buttons.addNew")));
|
|
188
|
-
}
|
|
189
|
-
})), escape(createComponent(Show, {
|
|
177
|
+
return ssr(_tmpl$5, ssrHydrationKey(), escape(pageTitle()), escape(t("content.list.description")), ssrAttribute("href", escape(newContentHref(), true), false), escape(t("content.list.buttons.addNew")), escape(createComponent(Show, {
|
|
190
178
|
get when() {
|
|
191
179
|
return error();
|
|
192
180
|
},
|
|
193
181
|
get children() {
|
|
194
|
-
return ssr(_tmpl$
|
|
182
|
+
return ssr(_tmpl$3, ssrHydrationKey(), escape(error()));
|
|
195
183
|
}
|
|
196
184
|
})), escape(createComponent(Show, {
|
|
197
185
|
get when() {
|
|
198
186
|
return info();
|
|
199
187
|
},
|
|
200
188
|
get children() {
|
|
201
|
-
return ssr(_tmpl$
|
|
189
|
+
return ssr(_tmpl$4, ssrHydrationKey(), escape(info()));
|
|
202
190
|
}
|
|
203
191
|
})), escape(createComponent(Input, {
|
|
204
192
|
name: "search",
|
|
@@ -273,8 +261,63 @@ function ContentList() {
|
|
|
273
261
|
} })));
|
|
274
262
|
}
|
|
275
263
|
//#endregion
|
|
276
|
-
//#region src/
|
|
277
|
-
var
|
|
264
|
+
//#region src/components/content/ContentTypeWorkspace.tsx
|
|
265
|
+
var _tmpl$ = [
|
|
266
|
+
"<div",
|
|
267
|
+
" class=\"notice notice--error\">",
|
|
268
|
+
"</div>"
|
|
269
|
+
];
|
|
270
|
+
var _tmpl$2 = [
|
|
271
|
+
"<div",
|
|
272
|
+
" class=\"card\">",
|
|
273
|
+
"</div>"
|
|
274
|
+
];
|
|
275
|
+
function ContentTypeWorkspace(props) {
|
|
276
|
+
const { t } = useTranslation();
|
|
277
|
+
const [type, setType] = createSignal(null);
|
|
278
|
+
const [error, setError] = createSignal("");
|
|
279
|
+
onMount(async () => {
|
|
280
|
+
try {
|
|
281
|
+
const match = (await apiClient.getContentTypes()).find((entry) => entry.slug === props.contentType);
|
|
282
|
+
if (!match) {
|
|
283
|
+
setError(t("content.list.typeNotFound"));
|
|
284
|
+
return;
|
|
285
|
+
}
|
|
286
|
+
setType(match);
|
|
287
|
+
} catch (err) {
|
|
288
|
+
setError(err instanceof Error ? err.message : String(err));
|
|
289
|
+
}
|
|
290
|
+
});
|
|
291
|
+
return createComponent(Show, {
|
|
292
|
+
get when() {
|
|
293
|
+
return type();
|
|
294
|
+
},
|
|
295
|
+
get fallback() {
|
|
296
|
+
return memo(() => !!error())() ? ssr(_tmpl$, ssrHydrationKey(), escape(error())) : ssr(_tmpl$2, ssrHydrationKey(), escape(t("common.loading")));
|
|
297
|
+
},
|
|
298
|
+
children: (current) => createComponent(Show, {
|
|
299
|
+
get when() {
|
|
300
|
+
return current().singleton;
|
|
301
|
+
},
|
|
302
|
+
get fallback() {
|
|
303
|
+
return createComponent(ContentList, { get contentType() {
|
|
304
|
+
return current().slug;
|
|
305
|
+
} });
|
|
306
|
+
},
|
|
307
|
+
get children() {
|
|
308
|
+
return createComponent(ContentEditor, {
|
|
309
|
+
get initialType() {
|
|
310
|
+
return current().slug;
|
|
311
|
+
},
|
|
312
|
+
singleton: true
|
|
313
|
+
});
|
|
314
|
+
}
|
|
315
|
+
})
|
|
316
|
+
});
|
|
317
|
+
}
|
|
318
|
+
//#endregion
|
|
319
|
+
//#region src/pages/content/[type]/index.astro
|
|
320
|
+
var _type__exports = /* @__PURE__ */ __exportAll({
|
|
278
321
|
default: () => $$Index,
|
|
279
322
|
file: () => $$file,
|
|
280
323
|
url: () => $$url
|
|
@@ -284,21 +327,23 @@ var $$Index = createComponent$1(($$result, $$props, $$slots) => {
|
|
|
284
327
|
const Astro = $$result.createAstro($$props, $$slots);
|
|
285
328
|
Astro.self = $$Index;
|
|
286
329
|
const { t } = Astro.locals;
|
|
330
|
+
const contentType = Astro.params.type ?? "post";
|
|
287
331
|
return renderTemplate`${renderComponent($$result, "DashboardLayout", $$DashboardLayout, {
|
|
288
|
-
"title":
|
|
289
|
-
"data-astro-cid-
|
|
290
|
-
}, { "default": ($$result) => renderTemplate`${maybeRenderHead($$result)}<div class="content-page" data-astro-cid-
|
|
332
|
+
"title": contentType,
|
|
333
|
+
"data-astro-cid-znq2nu33": true
|
|
334
|
+
}, { "default": ($$result) => renderTemplate`${maybeRenderHead($$result)}<div class="content-type-page" data-astro-cid-znq2nu33>${renderComponent($$result, "ContentTypeWorkspace", ContentTypeWorkspace, {
|
|
291
335
|
"client:load": true,
|
|
292
|
-
"
|
|
336
|
+
"contentType": contentType,
|
|
337
|
+
"data-astro-cid-znq2nu33": true,
|
|
293
338
|
"client:component-hydration": "load",
|
|
294
|
-
"client:component-path": "/home/runner/work/cms/cms/apps/admin/src/components/content/
|
|
295
|
-
"client:component-export": "
|
|
339
|
+
"client:component-path": "/home/runner/work/cms/cms/apps/admin/src/components/content/ContentTypeWorkspace.tsx",
|
|
340
|
+
"client:component-export": "ContentTypeWorkspace"
|
|
296
341
|
})}</div>` })}`;
|
|
297
|
-
}, "/home/runner/work/cms/cms/apps/admin/src/pages/content/index.astro", void 0);
|
|
298
|
-
var $$file = "/home/runner/work/cms/cms/apps/admin/src/pages/content/index.astro";
|
|
299
|
-
var $$url = "/content";
|
|
342
|
+
}, "/home/runner/work/cms/cms/apps/admin/src/pages/content/[type]/index.astro", void 0);
|
|
343
|
+
var $$file = "/home/runner/work/cms/cms/apps/admin/src/pages/content/[type]/index.astro";
|
|
344
|
+
var $$url = "/content/[type]";
|
|
300
345
|
//#endregion
|
|
301
|
-
//#region \0virtual:astro:page:src/pages/content/index@_@astro
|
|
302
|
-
var page = () =>
|
|
346
|
+
//#region \0virtual:astro:page:src/pages/content/[type]/index@_@astro
|
|
347
|
+
var page = () => _type__exports;
|
|
303
348
|
//#endregion
|
|
304
349
|
export { page };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent$1 } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { n as useTranslation, r as apiClient } from "./
|
|
5
|
-
import { t as $$DashboardLayout } from "./
|
|
4
|
+
import { n as useTranslation, r as apiClient } from "./i18n_BqFK0MIW.mjs";
|
|
5
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
6
6
|
import { createComponent, escape, ssr, ssrHydrationKey } from "solid-js/web";
|
|
7
7
|
import { For, Show, createSignal, onMount } from "solid-js";
|
|
8
8
|
//#region src/components/apps/dashboard/DashboardHome.tsx
|
|
@@ -34,7 +34,7 @@ var _tmpl$3 = [
|
|
|
34
34
|
"</p></div><div class=\"card stat-card\"><h3 class=\"stat-label\">",
|
|
35
35
|
"</h3><p class=\"stat-value\">",
|
|
36
36
|
"</p></div></div><div class=\"card\"><div class=\"card-header\"><h3>",
|
|
37
|
-
"</h3><a href=\"/content\" class=\"btn btn-secondary btn-sm\">",
|
|
37
|
+
"</h3><a href=\"/content/post\" class=\"btn btn-secondary btn-sm\">",
|
|
38
38
|
"</a></div><!--$-->",
|
|
39
39
|
"<!--/--></div></div>"
|
|
40
40
|
];
|
|
@@ -117,7 +117,7 @@ function DashboardHome() {
|
|
|
117
117
|
get each() {
|
|
118
118
|
return recent();
|
|
119
119
|
},
|
|
120
|
-
children: (row) => ssr(_tmpl$5, ssrHydrationKey(), `/content/edit?id=${escape(encodeURIComponent(String(raw(row)["id"] ?? "")), true)}`, escape(String(raw(row)["title"] ?? "—")), escape(String(raw(row)["type"] ?? "—")), escape(String(raw(row)["status"] ?? "—")), escape(formatDate(row)))
|
|
120
|
+
children: (row) => ssr(_tmpl$5, ssrHydrationKey(), `/content/${escape(encodeURIComponent(String(raw(row)["type"] ?? "post")), true)}/edit?id=${escape(encodeURIComponent(String(raw(row)["id"] ?? "")), true)}`, escape(String(raw(row)["title"] ?? "—")), escape(String(raw(row)["type"] ?? "—")), escape(String(raw(row)["status"] ?? "—")), escape(formatDate(row)))
|
|
121
121
|
})));
|
|
122
122
|
}
|
|
123
123
|
})));
|
|
@@ -143,7 +143,7 @@ var $$Index = createComponent$1(($$result, $$props, $$slots) => {
|
|
|
143
143
|
"client:component-hydration": "load",
|
|
144
144
|
"client:component-path": "/home/runner/work/cms/cms/apps/admin/src/components/apps/dashboard/DashboardHome.tsx",
|
|
145
145
|
"client:component-export": "DashboardHome"
|
|
146
|
-
})}<div class="quick-actions" data-astro-cid-lcdefpme><div class="card" data-astro-cid-lcdefpme><h3 class="card-header" data-astro-cid-lcdefpme>${t("layout.actions.newPost")}</h3><div class="actions-grid" data-astro-cid-lcdefpme><a href="/content/new" class="action-card" data-astro-cid-lcdefpme><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><line x1="12" y1="5" x2="12" y2="19" data-astro-cid-lcdefpme></line><line x1="5" y1="12" x2="19" y2="12" data-astro-cid-lcdefpme></line></svg><span data-astro-cid-lcdefpme>${t("layout.actions.newPost")}</span></a><a href="/media/upload" class="action-card" data-astro-cid-lcdefpme><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" data-astro-cid-lcdefpme></path><polyline points="17 8 12 3 7 8" data-astro-cid-lcdefpme></polyline><line x1="12" y1="3" x2="12" y2="15" data-astro-cid-lcdefpme></line></svg><span data-astro-cid-lcdefpme>${t("layout.actions.uploadMedia")}</span></a><a href="/users/new" class="action-card" data-astro-cid-lcdefpme><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><path d="M16 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2" data-astro-cid-lcdefpme></path><circle cx="8.5" cy="7" r="4" data-astro-cid-lcdefpme></circle><line x1="20" y1="8" x2="20" y2="14" data-astro-cid-lcdefpme></line><line x1="23" y1="11" x2="17" y2="11" data-astro-cid-lcdefpme></line></svg><span data-astro-cid-lcdefpme>${t("layout.actions.addUser")}</span></a><a href="/settings" class="action-card" data-astro-cid-lcdefpme><span class="settings-action-icon" aria-hidden="true" data-astro-cid-lcdefpme><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><path d="M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.38a2 2 0 0 0-.73-2.73l-.15-.09a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z" data-astro-cid-lcdefpme></path><circle cx="12" cy="12" r="3" data-astro-cid-lcdefpme></circle></svg></span><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><circle cx="12" cy="12" r="3" data-astro-cid-lcdefpme></circle><path d="M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z" data-astro-cid-lcdefpme></path></svg><span data-astro-cid-lcdefpme>${t("layout.actions.openSettings")}</span></a></div></div></div></div>` })}`;
|
|
146
|
+
})}<div class="quick-actions" data-astro-cid-lcdefpme><div class="card" data-astro-cid-lcdefpme><h3 class="card-header" data-astro-cid-lcdefpme>${t("layout.actions.newPost")}</h3><div class="actions-grid" data-astro-cid-lcdefpme><a href="/content/post/new" class="action-card" data-astro-cid-lcdefpme><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><line x1="12" y1="5" x2="12" y2="19" data-astro-cid-lcdefpme></line><line x1="5" y1="12" x2="19" y2="12" data-astro-cid-lcdefpme></line></svg><span data-astro-cid-lcdefpme>${t("layout.actions.newPost")}</span></a><a href="/media/upload" class="action-card" data-astro-cid-lcdefpme><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" data-astro-cid-lcdefpme></path><polyline points="17 8 12 3 7 8" data-astro-cid-lcdefpme></polyline><line x1="12" y1="3" x2="12" y2="15" data-astro-cid-lcdefpme></line></svg><span data-astro-cid-lcdefpme>${t("layout.actions.uploadMedia")}</span></a><a href="/users/new" class="action-card" data-astro-cid-lcdefpme><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><path d="M16 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2" data-astro-cid-lcdefpme></path><circle cx="8.5" cy="7" r="4" data-astro-cid-lcdefpme></circle><line x1="20" y1="8" x2="20" y2="14" data-astro-cid-lcdefpme></line><line x1="23" y1="11" x2="17" y2="11" data-astro-cid-lcdefpme></line></svg><span data-astro-cid-lcdefpme>${t("layout.actions.addUser")}</span></a><a href="/settings" class="action-card" data-astro-cid-lcdefpme><span class="settings-action-icon" aria-hidden="true" data-astro-cid-lcdefpme><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><path d="M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.38a2 2 0 0 0-.73-2.73l-.15-.09a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z" data-astro-cid-lcdefpme></path><circle cx="12" cy="12" r="3" data-astro-cid-lcdefpme></circle></svg></span><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-astro-cid-lcdefpme><circle cx="12" cy="12" r="3" data-astro-cid-lcdefpme></circle><path d="M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z" data-astro-cid-lcdefpme></path></svg><span data-astro-cid-lcdefpme>${t("layout.actions.openSettings")}</span></a></div></div></div></div>` })}`;
|
|
147
147
|
}, "/home/runner/work/cms/cms/apps/admin/src/pages/index.astro", void 0);
|
|
148
148
|
var $$file = "/home/runner/work/cms/cms/apps/admin/src/pages/index.astro";
|
|
149
149
|
//#endregion
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent$1 } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { n as useTranslation, r as apiClient } from "./
|
|
5
|
-
import { a as For2, c as Select, f as createSignal, l as Show2, n as Badge, o as Input, p as onMount, r as Button, s as Pagination, t as $$DashboardLayout } from "./
|
|
4
|
+
import { n as useTranslation, r as apiClient } from "./i18n_BqFK0MIW.mjs";
|
|
5
|
+
import { a as For2, c as Select, f as createSignal, l as Show2, n as Badge, o as Input, p as onMount, r as Button, s as Pagination, t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
6
6
|
import { createComponent, escape, ssr, ssrAttribute, ssrHydrationKey } from "solid-js/web";
|
|
7
7
|
//#region src/components/apps/users/UsersManager.tsx
|
|
8
8
|
var _tmpl$ = [
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { t as $$DashboardLayout } from "./
|
|
5
|
-
import { t as MediaLibrary } from "./
|
|
4
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
5
|
+
import { t as MediaLibrary } from "./MediaLibrary_Xs09kLza.mjs";
|
|
6
6
|
//#region src/pages/media/index.astro
|
|
7
7
|
var media_exports = /* @__PURE__ */ __exportAll({
|
|
8
8
|
default: () => $$Index,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent$1 } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { n as useTranslation, r as apiClient } from "./
|
|
5
|
-
import { t as $$DashboardLayout } from "./
|
|
4
|
+
import { n as useTranslation, r as apiClient } from "./i18n_BqFK0MIW.mjs";
|
|
5
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
6
6
|
import { createComponent, escape, ssr, ssrAttribute, ssrHydrationKey } from "solid-js/web";
|
|
7
7
|
import { For, Show, createSignal, onMount } from "solid-js";
|
|
8
8
|
//#region src/components/apps/users/UserCreateForm.tsx
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { t as $$DashboardLayout } from "./
|
|
5
|
-
import { t as ContentEditor } from "./
|
|
6
|
-
//#region src/pages/content/new.astro
|
|
4
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
5
|
+
import { t as ContentEditor } from "./ContentEditor_DS7flRjR.mjs";
|
|
6
|
+
//#region src/pages/content/[type]/new.astro
|
|
7
7
|
var new_exports = /* @__PURE__ */ __exportAll({
|
|
8
8
|
default: () => $$New,
|
|
9
9
|
file: () => $$file,
|
|
@@ -14,23 +14,23 @@ var $$New = createComponent(($$result, $$props, $$slots) => {
|
|
|
14
14
|
const Astro = $$result.createAstro($$props, $$slots);
|
|
15
15
|
Astro.self = $$New;
|
|
16
16
|
const { t } = Astro.locals;
|
|
17
|
-
const
|
|
17
|
+
const contentType = Astro.params.type ?? "post";
|
|
18
18
|
return renderTemplate`${renderComponent($$result, "DashboardLayout", $$DashboardLayout, {
|
|
19
19
|
"title": t("content.editor.save"),
|
|
20
|
-
"data-astro-cid-
|
|
21
|
-
}, { "default": ($$result) => renderTemplate`${maybeRenderHead($$result)}<div class="editor-page" data-astro-cid-
|
|
20
|
+
"data-astro-cid-5s5mludg": true
|
|
21
|
+
}, { "default": ($$result) => renderTemplate`${maybeRenderHead($$result)}<div class="editor-page" data-astro-cid-5s5mludg>${renderComponent($$result, "ContentEditor", ContentEditor, {
|
|
22
22
|
"client:load": true,
|
|
23
|
-
"initialType":
|
|
24
|
-
"data-astro-cid-
|
|
23
|
+
"initialType": contentType,
|
|
24
|
+
"data-astro-cid-5s5mludg": true,
|
|
25
25
|
"client:component-hydration": "load",
|
|
26
26
|
"client:component-path": "/home/runner/work/cms/cms/apps/admin/src/components/content/ContentEditor.tsx",
|
|
27
27
|
"client:component-export": "ContentEditor"
|
|
28
28
|
})}</div>` })}`;
|
|
29
|
-
}, "/home/runner/work/cms/cms/apps/admin/src/pages/content/new.astro", void 0);
|
|
30
|
-
var $$file = "/home/runner/work/cms/cms/apps/admin/src/pages/content/new.astro";
|
|
31
|
-
var $$url = "/content/new";
|
|
29
|
+
}, "/home/runner/work/cms/cms/apps/admin/src/pages/content/[type]/new.astro", void 0);
|
|
30
|
+
var $$file = "/home/runner/work/cms/cms/apps/admin/src/pages/content/[type]/new.astro";
|
|
31
|
+
var $$url = "/content/[type]/new";
|
|
32
32
|
//#endregion
|
|
33
|
-
//#region \0virtual:astro:page:src/pages/content/new@_@astro
|
|
33
|
+
//#region \0virtual:astro:page:src/pages/content/[type]/new@_@astro
|
|
34
34
|
var page = () => new_exports;
|
|
35
35
|
//#endregion
|
|
36
36
|
export { page };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { t as $$DashboardLayout } from "./
|
|
5
|
-
import { r as OperationsManager } from "./
|
|
4
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
5
|
+
import { r as OperationsManager } from "./ResourceHubs_Dwb0xyPZ.mjs";
|
|
6
6
|
//#region src/pages/settings/operations.astro
|
|
7
7
|
var operations_exports = /* @__PURE__ */ __exportAll({
|
|
8
8
|
default: () => $$Operations,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent$1 } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { n as useTranslation, r as apiClient } from "./
|
|
5
|
-
import { t as $$DashboardLayout } from "./
|
|
4
|
+
import { n as useTranslation, r as apiClient } from "./i18n_BqFK0MIW.mjs";
|
|
5
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
6
6
|
import { createComponent, escape, ssr, ssrAttribute, ssrHydrationKey } from "solid-js/web";
|
|
7
7
|
import { For, Show, createSignal, onMount } from "solid-js";
|
|
8
8
|
//#region src/components/apps/plugins/PluginManager.tsx
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent$1 } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { n as useTranslation, r as apiClient } from "./
|
|
5
|
-
import { t as $$DashboardLayout } from "./
|
|
4
|
+
import { n as useTranslation, r as apiClient } from "./i18n_BqFK0MIW.mjs";
|
|
5
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
6
6
|
import { createComponent, escape, ssr, ssrAttribute, ssrHydrationKey } from "solid-js/web";
|
|
7
7
|
import { For, Show, createMemo, createSignal, onMount } from "solid-js";
|
|
8
8
|
//#region src/components/apps/settings/PostTypesManager.tsx
|
|
@@ -12,6 +12,11 @@ var _tmpl$ = [
|
|
|
12
12
|
"</div>"
|
|
13
13
|
];
|
|
14
14
|
var _tmpl$2 = [
|
|
15
|
+
"<button",
|
|
16
|
+
" type=\"button\" class=\"btn btn-secondary\">",
|
|
17
|
+
"</button>"
|
|
18
|
+
];
|
|
19
|
+
var _tmpl$3 = [
|
|
15
20
|
"<div",
|
|
16
21
|
" class=\"post-types-manager\"><!--$-->",
|
|
17
22
|
"<!--/--><form class=\"card\"><h3>",
|
|
@@ -21,13 +26,21 @@ var _tmpl$2 = [
|
|
|
21
26
|
"<!--/--><input class=\"input\" required",
|
|
22
27
|
"></label><label><!--$-->",
|
|
23
28
|
"<!--/--><input class=\"input\" required",
|
|
24
|
-
"></label
|
|
29
|
+
"></label><label><!--$-->",
|
|
30
|
+
"<!--/--><input class=\"input\"",
|
|
31
|
+
" placeholder=\"box\"><small class=\"muted\">",
|
|
32
|
+
"</small></label></div><fieldset class=\"supports\"><legend>",
|
|
25
33
|
"</legend><!--$-->",
|
|
26
34
|
"<!--/--><label><input type=\"checkbox\"",
|
|
27
35
|
"> <!--$-->",
|
|
36
|
+
"<!--/--></label><label><input type=\"checkbox\"",
|
|
37
|
+
"> <!--$-->",
|
|
28
38
|
"<!--/--></label></fieldset><button type=\"submit\" class=\"btn btn-primary\"",
|
|
29
39
|
">",
|
|
30
|
-
"</button
|
|
40
|
+
"</button><!--$-->",
|
|
41
|
+
"<!--/--></form><table class=\"table\"><thead><tr><th>",
|
|
42
|
+
"</th><th>",
|
|
43
|
+
"</th><th>",
|
|
31
44
|
"</th><th>",
|
|
32
45
|
"</th><th>",
|
|
33
46
|
"</th><th>",
|
|
@@ -36,18 +49,18 @@ var _tmpl$2 = [
|
|
|
36
49
|
"</th><th></th></tr></thead><tbody>",
|
|
37
50
|
"</tbody></table></div>"
|
|
38
51
|
];
|
|
39
|
-
var _tmpl$
|
|
52
|
+
var _tmpl$4 = [
|
|
40
53
|
"<label",
|
|
41
54
|
"><input type=\"checkbox\"",
|
|
42
55
|
"> <!--$-->",
|
|
43
56
|
"<!--/--></label>"
|
|
44
57
|
];
|
|
45
|
-
var _tmpl$
|
|
58
|
+
var _tmpl$5 = [
|
|
46
59
|
"<button",
|
|
47
60
|
" type=\"button\" class=\"btn btn-danger\">",
|
|
48
61
|
"</button>"
|
|
49
62
|
];
|
|
50
|
-
var _tmpl$
|
|
63
|
+
var _tmpl$6 = [
|
|
51
64
|
"<tr",
|
|
52
65
|
"><td>",
|
|
53
66
|
"</td><td>",
|
|
@@ -56,13 +69,17 @@ var _tmpl$5 = [
|
|
|
56
69
|
"</td><td>",
|
|
57
70
|
"</td><td>",
|
|
58
71
|
"</td><td>",
|
|
59
|
-
"</td
|
|
72
|
+
"</td><td>",
|
|
73
|
+
"</td><td><button type=\"button\" class=\"btn btn-secondary\">",
|
|
74
|
+
"</button> <!--$-->",
|
|
75
|
+
"<!--/--></td></tr>"
|
|
60
76
|
];
|
|
61
77
|
function PostTypesManager() {
|
|
62
78
|
const { t } = useTranslation();
|
|
63
79
|
const [types, setTypes] = createSignal([]);
|
|
64
80
|
const [error, setError] = createSignal("");
|
|
65
81
|
const [saving, setSaving] = createSignal(false);
|
|
82
|
+
const [editingSlug, setEditingSlug] = createSignal(null);
|
|
66
83
|
const supportsOptions = createMemo(() => [
|
|
67
84
|
{
|
|
68
85
|
value: "title",
|
|
@@ -91,6 +108,8 @@ function PostTypesManager() {
|
|
|
91
108
|
singularLabel: "",
|
|
92
109
|
pluralLabel: "",
|
|
93
110
|
hasArchive: false,
|
|
111
|
+
singleton: false,
|
|
112
|
+
menuIcon: "box",
|
|
94
113
|
supports: ["title", "editor"]
|
|
95
114
|
});
|
|
96
115
|
const load = async () => {
|
|
@@ -101,28 +120,35 @@ function PostTypesManager() {
|
|
|
101
120
|
}
|
|
102
121
|
};
|
|
103
122
|
onMount(load);
|
|
104
|
-
return ssr(_tmpl$
|
|
123
|
+
return ssr(_tmpl$3, ssrHydrationKey(), escape(createComponent(Show, {
|
|
105
124
|
get when() {
|
|
106
125
|
return error();
|
|
107
126
|
},
|
|
108
127
|
get children() {
|
|
109
128
|
return ssr(_tmpl$, ssrHydrationKey(), escape(error()));
|
|
110
129
|
}
|
|
111
|
-
})), escape(t("settings.postTypes.form.title")), escape(t("settings.postTypes.form.slug")), ssrAttribute("title", escape(t("settings.postTypes.form.slugHint"), true), false) + ssrAttribute("value", escape(form().slug, true), false), escape(t("settings.postTypes.form.singular")), ssrAttribute("value", escape(form().singularLabel, true), false), escape(t("settings.postTypes.form.plural")), ssrAttribute("value", escape(form().pluralLabel, true), false), escape(t("settings.postTypes.form.supports")), escape(createComponent(For, {
|
|
130
|
+
})), editingSlug() ? escape(t("settings.postTypes.form.editTitle")) : escape(t("settings.postTypes.form.title")), escape(t("settings.postTypes.form.slug")), ssrAttribute("title", escape(t("settings.postTypes.form.slugHint"), true), false) + ssrAttribute("value", escape(form().slug, true), false), escape(t("settings.postTypes.form.singular")), ssrAttribute("value", escape(form().singularLabel, true), false), escape(t("settings.postTypes.form.plural")), ssrAttribute("value", escape(form().pluralLabel, true), false), escape(t("settings.postTypes.form.icon")), ssrAttribute("value", escape(form().menuIcon, true), false), escape(t("settings.postTypes.form.iconHint")), escape(t("settings.postTypes.form.supports")), escape(createComponent(For, {
|
|
112
131
|
get each() {
|
|
113
132
|
return supportsOptions();
|
|
114
133
|
},
|
|
115
|
-
children: (option) => ssr(_tmpl$
|
|
116
|
-
})), ssrAttribute("checked", form().hasArchive, true), escape(t("settings.postTypes.form.hasArchive")), ssrAttribute("
|
|
134
|
+
children: (option) => ssr(_tmpl$4, ssrHydrationKey(), ssrAttribute("checked", form().supports.includes(option.value), true), escape(option.label))
|
|
135
|
+
})), ssrAttribute("checked", form().hasArchive, true), escape(t("settings.postTypes.form.hasArchive")), ssrAttribute("checked", form().singleton, true), escape(t("settings.postTypes.form.singleton")), ssrAttribute("disabled", saving(), true), editingSlug() ? escape(t("settings.postTypes.form.update")) : escape(t("settings.postTypes.form.create")), escape(createComponent(Show, {
|
|
136
|
+
get when() {
|
|
137
|
+
return editingSlug();
|
|
138
|
+
},
|
|
139
|
+
get children() {
|
|
140
|
+
return ssr(_tmpl$2, ssrHydrationKey(), escape(t("settings.postTypes.form.cancel")));
|
|
141
|
+
}
|
|
142
|
+
})), escape(t("settings.postTypes.table.slug")), escape(t("settings.postTypes.table.singular")), escape(t("settings.postTypes.table.plural")), escape(t("settings.postTypes.table.source")), escape(t("settings.postTypes.table.supports")), escape(t("settings.postTypes.table.archive")), escape(t("settings.postTypes.table.mode")), escape(t("settings.postTypes.table.icon")), escape(createComponent(For, {
|
|
117
143
|
get each() {
|
|
118
144
|
return types();
|
|
119
145
|
},
|
|
120
|
-
children: (type) => ssr(_tmpl$
|
|
146
|
+
children: (type) => ssr(_tmpl$6, ssrHydrationKey(), escape(type.slug), escape(type.singularLabel), escape(type.pluralLabel), escape(type.source ?? t("settings.postTypes.sources.admin")), escape((type.supports ?? []).join(", ")), type.hasArchive ? escape(t("common.yes")) : escape(t("common.no")), type.singleton ? escape(t("settings.postTypes.table.singleton")) : escape(t("settings.postTypes.table.collection")), escape(type.menuIcon ?? "box"), escape(t("settings.postTypes.table.actions.edit")), escape(createComponent(Show, {
|
|
121
147
|
get when() {
|
|
122
148
|
return type.source !== "CORE";
|
|
123
149
|
},
|
|
124
150
|
get children() {
|
|
125
|
-
return ssr(_tmpl$
|
|
151
|
+
return ssr(_tmpl$5, ssrHydrationKey(), escape(t("settings.postTypes.table.actions.remove")));
|
|
126
152
|
}
|
|
127
153
|
})))
|
|
128
154
|
})));
|
|
@@ -71,6 +71,7 @@ var content = {
|
|
|
71
71
|
"list": {
|
|
72
72
|
"title": "Conteúdo",
|
|
73
73
|
"description": "Busque, filtre, edite e publique seu conteúdo.",
|
|
74
|
+
"typeNotFound": "Este tipo de conteúdo não foi encontrado.",
|
|
74
75
|
"columns": {
|
|
75
76
|
"title": "Título",
|
|
76
77
|
"type": "Tipo",
|
|
@@ -291,6 +292,12 @@ var settings = {
|
|
|
291
292
|
"revisions": "Revisões"
|
|
292
293
|
},
|
|
293
294
|
"hasArchive": "Possui arquivo público (/slug)",
|
|
295
|
+
"singleton": "Singleton (apenas um conteúdo)",
|
|
296
|
+
"icon": "Ícone do sidebar (nome Lucide)",
|
|
297
|
+
"iconHint": "Exemplos: box, package, shopping-bag, file-text",
|
|
298
|
+
"editTitle": "Editar Tipo de Conteúdo",
|
|
299
|
+
"update": "Atualizar",
|
|
300
|
+
"cancel": "Cancelar",
|
|
294
301
|
"create": "Criar"
|
|
295
302
|
},
|
|
296
303
|
"table": {
|
|
@@ -300,7 +307,14 @@ var settings = {
|
|
|
300
307
|
"source": "Origem",
|
|
301
308
|
"supports": "Suporta",
|
|
302
309
|
"archive": "Arquivo",
|
|
303
|
-
"
|
|
310
|
+
"mode": "Modo",
|
|
311
|
+
"singleton": "Singleton",
|
|
312
|
+
"collection": "Coleção",
|
|
313
|
+
"icon": "Ícone",
|
|
314
|
+
"actions": {
|
|
315
|
+
"edit": "Editar",
|
|
316
|
+
"remove": "Remover"
|
|
317
|
+
}
|
|
304
318
|
},
|
|
305
319
|
"sources": {
|
|
306
320
|
"admin": "Admin",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { t as $$DashboardLayout } from "./
|
|
5
|
-
import { n as ContentResourcesManager } from "./
|
|
4
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
5
|
+
import { n as ContentResourcesManager } from "./ResourceHubs_Dwb0xyPZ.mjs";
|
|
6
6
|
//#region src/pages/settings/resources.astro
|
|
7
7
|
var resources_exports = /* @__PURE__ */ __exportAll({
|
|
8
8
|
default: () => $$Resources,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as __exportAll } from "./rolldown-runtime_BMI-E3GI.mjs";
|
|
2
2
|
import { S as createAstro, d as maybeRenderHead, i as renderComponent, u as renderTemplate } from "./server_B5N27szj.mjs";
|
|
3
3
|
import { t as createComponent$1 } from "./compiler_O7J1rlsi.mjs";
|
|
4
|
-
import { n as useTranslation, r as apiClient } from "./
|
|
5
|
-
import { t as $$DashboardLayout } from "./
|
|
4
|
+
import { n as useTranslation, r as apiClient } from "./i18n_BqFK0MIW.mjs";
|
|
5
|
+
import { t as $$DashboardLayout } from "./DashboardLayout_09DepSVn.mjs";
|
|
6
6
|
import { createComponent, escape, ssr, ssrAttribute, ssrHydrationKey, ssrStyleProperty } from "solid-js/web";
|
|
7
7
|
import { For, Show, createSignal, onMount } from "solid-js";
|
|
8
8
|
//#region src/components/apps/settings/TaxonomiesManager.tsx
|