@plitzi/sdk-elements 0.39.4 → 0.39.6

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.
Files changed (34) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/dist/components/ElementAdvancedEditor.mjs +4 -4
  3. package/dist/components/SettingsSection/SettingsSection.d.ts +19 -0
  4. package/dist/components/SettingsSection/SettingsSection.mjs +37 -0
  5. package/dist/components/SettingsSection/index.d.ts +2 -0
  6. package/dist/components/SettingsSection/index.mjs +1 -0
  7. package/dist/elements/advanced/BlockJsx/declaration.d.ts +1 -1
  8. package/dist/elements/advanced/BlockJsx/declaration.mjs +1 -1
  9. package/dist/elements/advanced/BlockJsx/index.d.ts +1 -1
  10. package/dist/elements/basic/Link/Settings.mjs +1 -1
  11. package/dist/elements/basic/RichText/Settings.mjs +1 -1
  12. package/dist/elements/declarations/index.d.ts +7 -3
  13. package/dist/elements/internal/LayoutContainer/Settings.mjs +1 -1
  14. package/dist/elements/internal/Page/Settings.mjs +323 -285
  15. package/dist/elements/internal/Page/settingsSummary.d.ts +26 -0
  16. package/dist/elements/internal/Page/settingsSummary.mjs +22 -0
  17. package/dist/elements/media/Image/Settings.mjs +2 -2
  18. package/dist/elements/media/Video/Settings.mjs +2 -2
  19. package/dist/elements/provider/ApiContainer/Settings.mjs +6 -6
  20. package/dist/elements/provider/ApiContainer/components/FiltersInput/FiltersInput.mjs +1 -1
  21. package/dist/elements/structure/Pagination/Settings.mjs +1 -1
  22. package/dist/elements/structure/TabContainer/TabContainer.mjs +15 -11
  23. package/dist/elements/structure/TabContainer/TabContainerItem/Settings.d.ts +6 -1
  24. package/dist/elements/structure/TabContainer/TabContainerItem/Settings.mjs +24 -3
  25. package/dist/elements/structure/TabContainer/TabContainerItem/TabContainerItem.d.ts +7 -1
  26. package/dist/elements/structure/TabContainer/TabContainerItem/TabContainerItem.mjs +66 -38
  27. package/dist/elements/structure/TabContainer/TabContainerItem/declaration.d.ts +6 -2
  28. package/dist/elements/structure/TabContainer/TabContainerItem/declaration.mjs +1 -1
  29. package/dist/elements/structure/TabContainer/TabContainerItem/index.d.ts +6 -2
  30. package/dist/elements/structure/TabContainer/TabContainerItem/openTabFromHash.d.ts +10 -0
  31. package/dist/elements/structure/TabContainer/TabContainerItem/openTabFromHash.mjs +18 -0
  32. package/dist/elements/structure/TabContainer/index.d.ts +6 -2
  33. package/dist/index.d.ts +7 -3
  34. package/package.json +12 -12
@@ -1,324 +1,362 @@
1
1
  import e from "../../useSettingsUpdate.mjs";
2
2
  import t from "../LayoutPicker/index.mjs";
3
- import n from "./SharePreview.mjs";
4
- import { useCallback as r, useEffect as i, useMemo as a, useState as o } from "react";
5
- import { useCommonStore as s } from "@plitzi/sdk-shared/store";
6
- import { OG_TYPES as c, pageAccessOf as l } from "@plitzi/sdk-shared/schema";
7
- import { get as u, pick as d } from "@plitzi/plitzi-ui/helpers";
8
- import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
9
- import { getPageFullPath as h } from "@plitzi/sdk-navigation";
3
+ import n from "../../../components/SettingsSection/SettingsSection.mjs";
4
+ import { accessHelp as ee, accessSummary as te, isRestricted as r, scrollOf as i, seoSummary as ne } from "./settingsSummary.mjs";
5
+ import re from "./SharePreview.mjs";
6
+ import { useCallback as a, useEffect as ie, useMemo as o, useState as s } from "react";
7
+ import { useCommonStore as c } from "@plitzi/sdk-shared/store";
8
+ import { OG_TYPES as l, pageAccessOf as u } from "@plitzi/sdk-shared/schema";
9
+ import { get as d, pick as f } from "@plitzi/plitzi-ui/helpers";
10
+ import { Fragment as p, jsx as m, jsxs as h } from "react/jsx-runtime";
11
+ import { getPageFullPath as ae } from "@plitzi/sdk-navigation";
10
12
  import g from "@plitzi/plitzi-ui/Alert";
11
13
  import _ from "@plitzi/plitzi-ui/Checkbox";
12
14
  import v from "@plitzi/plitzi-ui/Input";
13
15
  import y from "@plitzi/plitzi-ui/TextArea";
14
16
  import b from "@plitzi/plitzi-ui/Select";
15
17
  import x from "@plitzi/plitzi-ui/Select2";
18
+ import { NOT_FOUND_SLUG as S, notFoundPageIn as C } from "@plitzi/sdk-shared/navigation";
16
19
  // src/elements/internal/Page/Settings.tsx
17
- var S = ({ id: S = "", seoEnabled: C = !1, enabled: w = !0, name: T = "", folder: E = "", seoPageTitle: D = "Title", seoPageDescription: O = "Description", seoRobots: k = "", seoImage: A = "", seoImageAlt: j = "", seoType: ee = "", slug: M = "", layout: N = "", layoutContainer: P = "", accessLevel: F = "", unauthorizedBehaviour: I = "", unauthorizedPageRedirect: L = "", documentScroll: R = "", access: z = "", onUpdate: B }) => {
18
- let V = l({ access: z })?.permissions.join(", ") ?? "", [H, U] = o(V);
19
- i(() => U(V), [V]);
20
- let [[W, G, K]] = s([
20
+ var w = ({ id: w = "", seoEnabled: T = !1, enabled: E = !0, name: D = "", folder: O = "", seoPageTitle: k = "Title", seoPageDescription: A = "Description", seoRobots: oe = "", seoImage: j = "", seoImageAlt: M = "", seoType: se = "", slug: N = "", layout: ce = "", layoutContainer: P = "", accessLevel: F = "", unauthorizedBehaviour: I = "", unauthorizedPageRedirect: L = "", documentScroll: R = "", access: z = "", onUpdate: B }) => {
21
+ let V = u({ access: z })?.permissions.join(", ") ?? "", [H, U] = s(V);
22
+ ie(() => U(V), [V]);
23
+ let [[W, G, K]] = c([
21
24
  "schema.flat",
22
25
  "schema.pages",
23
26
  "schema.pageFolders"
24
- ]), q = a(() => Object.values(d(W, G.filter((e) => e !== S))), [
27
+ ]), le = o(() => Object.values(f(W, G.filter((e) => e !== w))), [
25
28
  W,
26
- S,
29
+ w,
27
30
  G
28
- ]), J = e(B), Y = r((e) => {
31
+ ]), q = e(B), ue = a((e) => {
29
32
  B?.("name", e);
30
- let t = T.replaceAll(" ", "-").toLowerCase().replaceAll(/([^a-z0-9]+)/gi, "");
31
- M && M !== t || B?.("slug", e.replaceAll(" ", "-").toLowerCase().replaceAll(/([^a-z0-9-]+)/gi, ""));
33
+ let t = D.replaceAll(" ", "-").toLowerCase().replaceAll(/([^a-z0-9]+)/gi, "");
34
+ N && N !== t || B?.("slug", e.replaceAll(" ", "-").toLowerCase().replaceAll(/([^a-z0-9-]+)/gi, ""));
32
35
  }, [
33
36
  B,
34
- M,
35
- T
36
- ]), X = r((e) => {
37
+ N,
38
+ D
39
+ ]), [J, Y] = s(""), X = a((e) => {
40
+ let t = C({
41
+ flat: W,
42
+ pages: G
43
+ }, e, w), n = t !== void 0 && Object.hasOwn(W, t) ? W[t].attributes.name : void 0;
44
+ return t === void 0 ? void 0 : typeof n == "string" && n !== "" ? n : t;
45
+ }, [
46
+ W,
47
+ G,
48
+ w
49
+ ]), de = a((e) => {
37
50
  if (/^[a-zA-Z0-9:*/_-]+$/gim.test(e) || !e) {
38
- let t = e.replaceAll("//", "/");
39
- B?.("slug", t);
51
+ let t = e.replaceAll("//", "/"), n = t === S ? X(O) : void 0;
52
+ if (n !== void 0) {
53
+ Y(`"${n}" is already the 404 page ${O ? "of this folder" : "of the space"}: one per place. Use "Use as 404 page" in the Pages panel to make this one it instead.`);
54
+ return;
55
+ }
56
+ Y(""), B?.("slug", t);
40
57
  }
41
- }, [B]), Z = r((e) => {
58
+ }, [
59
+ B,
60
+ X,
61
+ O
62
+ ]), fe = a((e) => {
42
63
  B?.("accessLevel", e), B?.("unauthorizedBehaviour", ""), B?.("unauthorizedPageRedirect", "");
43
- }, [B]), Q = r(() => {
64
+ }, [B]), pe = a(() => {
44
65
  let e = H.split(",").map((e) => e.trim()).filter(Boolean);
45
66
  B?.("access", e.length > 0 ? { permissions: e } : "");
46
- }, [B, H]), te = r((e) => B?.("seoEnabled", e.target.checked), [B]), ne = r((e) => B?.("enabled", e.target.checked), [B]), re = r((e) => B?.("folder", e?.value ?? ""), [B]), ie = a(() => [{
67
+ }, [B, H]), me = a((e) => B?.("seoEnabled", e.target.checked), [B]), he = a((e) => B?.("enabled", e.target.checked), [B]), ge = a((e) => {
68
+ let t = e?.value ?? "", n = N === S ? X(t) : void 0;
69
+ n === void 0 ? (Y(""), B?.("folder", t)) : Y(`"${n}" is already the 404 page ${t ? "of that folder" : "of the space"}: one per place. Give one of them another slug first.`);
70
+ }, [
71
+ B,
72
+ X,
73
+ N
74
+ ]), _e = o(() => [{
47
75
  value: "",
48
76
  label: "None"
49
77
  }, ...K.map(({ id: e, name: t }) => ({
50
78
  value: e,
51
79
  label: t
52
- }))], [K]), $ = a(() => h(W, K, S, !0), [
80
+ }))], [K]), Z = o(() => ae(W, K, w, !0), [
53
81
  W,
54
82
  K,
55
- S
56
- ]);
57
- return /* @__PURE__ */ m("div", {
58
- className: "flex flex-col gap-4 py-2",
83
+ w
84
+ ]), Q = o(() => {
85
+ let e = Object.hasOwn(W, L) ? W[L].attributes.name : void 0;
86
+ return {
87
+ accessLevel: F,
88
+ permissions: u({ access: z })?.permissions ?? [],
89
+ unauthorizedBehaviour: I,
90
+ redirectName: typeof e == "string" ? e : ""
91
+ };
92
+ }, [
93
+ F,
94
+ z,
95
+ I,
96
+ W,
97
+ L
98
+ ]), $ = i(R);
99
+ return /* @__PURE__ */ h("div", {
100
+ className: "flex flex-col py-2",
59
101
  children: [
60
- !w && /* @__PURE__ */ p(g, {
61
- intent: "info",
62
- size: "xs",
63
- solid: !1,
64
- children: /* @__PURE__ */ p("span", {
65
- className: "text-xs",
66
- children: "When this option is disable, this page wont be accesible"
67
- })
68
- }),
69
- /* @__PURE__ */ p(_, {
70
- label: " Page Enabled",
71
- checked: w,
72
- onChange: ne,
73
- size: "xs"
74
- }),
75
- /* @__PURE__ */ p(v, {
76
- value: T,
77
- label: "Page Name",
78
- onChange: Y,
79
- size: "xs"
102
+ /* @__PURE__ */ h(n, {
103
+ id: "page-page",
104
+ title: "Page",
105
+ summary: [N === S ? "404 page" : Z, E ? "" : "disabled"].filter(Boolean).join(" · "),
106
+ defaultOpen: !0,
107
+ children: [
108
+ /* @__PURE__ */ m(_, {
109
+ label: " Page Enabled",
110
+ checked: E,
111
+ onChange: he,
112
+ size: "xs"
113
+ }),
114
+ !E && /* @__PURE__ */ m(g, {
115
+ intent: "info",
116
+ size: "xs",
117
+ solid: !1,
118
+ children: /* @__PURE__ */ m("span", {
119
+ className: "text-xs",
120
+ children: "While disabled, this page is not served to anybody"
121
+ })
122
+ }),
123
+ /* @__PURE__ */ m(v, {
124
+ value: D,
125
+ label: "Page Name",
126
+ onChange: ue,
127
+ size: "xs"
128
+ }),
129
+ /* @__PURE__ */ h("div", {
130
+ className: "flex flex-col gap-1",
131
+ children: [
132
+ /* @__PURE__ */ m(v, {
133
+ value: N,
134
+ onChange: de,
135
+ label: "Slug / Path",
136
+ size: "xs"
137
+ }),
138
+ /* @__PURE__ */ h("span", {
139
+ className: "text-ui-fg-subtle truncate text-xs",
140
+ title: Z,
141
+ children: ["Full path: ", /* @__PURE__ */ m("span", {
142
+ className: "text-ui-fg font-semibold",
143
+ children: Z
144
+ })]
145
+ }),
146
+ /* @__PURE__ */ m("span", {
147
+ className: "text-ui-fg-subtle text-xs",
148
+ children: "Letters, numbers and _ - : / *"
149
+ }),
150
+ N === S && /* @__PURE__ */ h("span", {
151
+ className: "text-ui-fg-subtle text-xs",
152
+ children: [
153
+ "The 404 page ",
154
+ O ? "of its folder" : "of the space",
155
+ ": every address",
156
+ O ? " in it" : "",
157
+ " no other page answers lands here, sent with status 404."
158
+ ]
159
+ }),
160
+ J && /* @__PURE__ */ m(g, {
161
+ intent: "warning",
162
+ size: "xs",
163
+ solid: !1,
164
+ children: /* @__PURE__ */ m("span", {
165
+ className: "text-xs",
166
+ children: J
167
+ })
168
+ })
169
+ ]
170
+ }),
171
+ /* @__PURE__ */ m(x, {
172
+ label: "Folder",
173
+ value: O,
174
+ options: _e,
175
+ placeholder: "None",
176
+ onChange: ge,
177
+ size: "xs"
178
+ }),
179
+ /* @__PURE__ */ m(t, {
180
+ layout: ce,
181
+ layoutContainer: P,
182
+ onUpdate: B
183
+ })
184
+ ]
80
185
  }),
81
- /* @__PURE__ */ p(g, {
82
- intent: "info",
83
- size: "xs",
84
- solid: !1,
85
- children: /* @__PURE__ */ p("span", {
86
- className: "text-xs",
87
- children: "Slug is a combination of letters, numbers and _ - : / *"
88
- })
186
+ /* @__PURE__ */ h(n, {
187
+ id: "page-access",
188
+ title: "Access",
189
+ summary: te(Q),
190
+ highlight: r(Q),
191
+ children: [
192
+ /* @__PURE__ */ h(b, {
193
+ value: F,
194
+ label: "Restrict Access",
195
+ onChange: fe,
196
+ placeholder: "None",
197
+ size: "xs",
198
+ children: [/* @__PURE__ */ m("option", {
199
+ value: "public",
200
+ children: "Public"
201
+ }), /* @__PURE__ */ m("option", {
202
+ value: "authenticated",
203
+ children: "Authenticated"
204
+ })]
205
+ }),
206
+ /* @__PURE__ */ m(v, {
207
+ label: "Required permissions",
208
+ value: H,
209
+ onChange: U,
210
+ onBlur: pe,
211
+ placeholder: "None — anybody this page is for",
212
+ size: "xs"
213
+ }),
214
+ (F !== "" || V !== "") && /* @__PURE__ */ h(b, {
215
+ label: "Unauthorized Behaviour",
216
+ value: I,
217
+ onChange: q.text("unauthorizedBehaviour"),
218
+ placeholder: "None",
219
+ size: "xs",
220
+ children: [/* @__PURE__ */ m("option", {
221
+ value: "redirect",
222
+ children: "Redirect"
223
+ }), /* @__PURE__ */ m("option", {
224
+ value: "notFound",
225
+ children: "Not found (404)"
226
+ })]
227
+ }),
228
+ I === "redirect" && /* @__PURE__ */ m(b, {
229
+ value: L,
230
+ label: "Redirect Page",
231
+ onChange: q.text("unauthorizedPageRedirect"),
232
+ placeholder: "None",
233
+ size: "xs",
234
+ children: le.map((e) => /* @__PURE__ */ m("option", {
235
+ value: e.id,
236
+ children: d(e, "attributes.name")
237
+ }, e.id))
238
+ }),
239
+ /* @__PURE__ */ m("span", {
240
+ className: "text-ui-fg-subtle text-xs",
241
+ children: ee(Q)
242
+ })
243
+ ]
89
244
  }),
90
- /* @__PURE__ */ m("div", {
91
- className: "flex flex-col",
92
- children: [/* @__PURE__ */ p(v, {
93
- value: M,
94
- onChange: X,
95
- label: "Slug / Path",
96
- className: { inputContainer: "rounded-none rounded-tl rounded-tr" },
97
- size: "xs"
98
- }), /* @__PURE__ */ m("div", {
99
- className: "truncate rounded-b border-x border-b border-gray-200 px-1 py-0.5 text-xs",
100
- title: $,
101
- children: ["Full Path: ", /* @__PURE__ */ p("span", {
102
- className: "font-bold",
103
- children: $
245
+ /* @__PURE__ */ h(n, {
246
+ id: "page-scroll",
247
+ title: "Scroll",
248
+ summary: $.label,
249
+ children: [/* @__PURE__ */ h(b, {
250
+ value: R,
251
+ label: "Document Scroll",
252
+ onChange: q.text("documentScroll"),
253
+ placeholder: "Scrolls",
254
+ size: "xs",
255
+ children: [/* @__PURE__ */ m("option", {
256
+ value: "noBounce",
257
+ children: "No bounce"
258
+ }), /* @__PURE__ */ m("option", {
259
+ value: "locked",
260
+ children: "Locked"
104
261
  })]
262
+ }), /* @__PURE__ */ m("span", {
263
+ className: "text-ui-fg-subtle text-xs",
264
+ children: $.help
105
265
  })]
106
266
  }),
107
- /* @__PURE__ */ p(x, {
108
- label: "Folder",
109
- value: E,
110
- options: ie,
111
- placeholder: "None",
112
- onChange: re,
113
- size: "xs"
114
- }),
115
- /* @__PURE__ */ p(t, {
116
- layout: N,
117
- layoutContainer: P,
118
- onUpdate: B
119
- }),
120
- /* @__PURE__ */ m(b, {
121
- value: F,
122
- label: "Restrict Access",
123
- onChange: Z,
124
- placeholder: "None",
125
- size: "xs",
126
- children: [/* @__PURE__ */ p("option", {
127
- value: "public",
128
- children: "Public"
129
- }), /* @__PURE__ */ p("option", {
130
- value: "authenticated",
131
- children: "Authenticated"
132
- })]
133
- }),
134
- F === "" && /* @__PURE__ */ p(g, {
135
- intent: "info",
136
- solid: !1,
137
- size: "xs",
138
- children: /* @__PURE__ */ p("span", {
139
- className: "text-xs",
140
- children: "Anyone on the internet can access this page"
141
- })
142
- }),
143
- F === "public" && /* @__PURE__ */ p(g, {
144
- intent: "info",
145
- solid: !1,
146
- size: "xs",
147
- children: /* @__PURE__ */ p("span", {
148
- className: "text-xs",
149
- children: "Only Guest can access this page"
150
- })
151
- }),
152
- /* @__PURE__ */ p(v, {
153
- label: "Required permissions",
154
- value: H,
155
- onChange: U,
156
- onBlur: Q,
157
- placeholder: "None — anybody this page is for",
158
- size: "xs"
159
- }),
160
- V !== "" && /* @__PURE__ */ p(g, {
161
- intent: "info",
162
- solid: !1,
163
- size: "xs",
164
- children: /* @__PURE__ */ p("span", {
165
- className: "text-xs",
166
- children: "Only visitors holding every one of these see this page. Anybody else is answered 401 or 403 — or 404, if Unauthorized Behaviour says Not found — and the server never sends them its content"
167
- })
168
- }),
169
- (F !== "" || V !== "") && /* @__PURE__ */ m(b, {
170
- label: "Unauthorized Behaviour",
171
- value: I,
172
- onChange: J.text("unauthorizedBehaviour"),
173
- placeholder: "None",
174
- size: "xs",
175
- children: [/* @__PURE__ */ p("option", {
176
- value: "redirect",
177
- children: "Redirect"
178
- }), /* @__PURE__ */ p("option", {
179
- value: "notFound",
180
- children: "Not found (404)"
181
- })]
182
- }),
183
- I === "notFound" && /* @__PURE__ */ p(g, {
184
- intent: "info",
185
- solid: !1,
186
- size: "xs",
187
- children: /* @__PURE__ */ p("span", {
188
- className: "text-xs",
189
- children: "Anybody this page is not for is answered as if it did not exist — the space's 404 — and is sent nothing of it, not its name nor its path. For a back-office, whose refusal would tell whoever probes the path that something is there"
190
- })
191
- }),
192
- I === "redirect" && /* @__PURE__ */ p(b, {
193
- value: L,
194
- label: "Redirect Page",
195
- onChange: J.text("unauthorizedPageRedirect"),
196
- placeholder: "None",
197
- size: "xs",
198
- children: q.map((e) => /* @__PURE__ */ p("option", {
199
- value: e.id,
200
- children: u(e, "attributes.name")
201
- }, e.id))
202
- }),
203
- /* @__PURE__ */ m(b, {
204
- value: R,
205
- label: "Document Scroll",
206
- onChange: J.text("documentScroll"),
207
- placeholder: "Scrolls",
208
- size: "xs",
209
- children: [/* @__PURE__ */ p("option", {
210
- value: "noBounce",
211
- children: "No bounce"
212
- }), /* @__PURE__ */ p("option", {
213
- value: "locked",
214
- children: "Locked"
215
- })]
216
- }),
217
- R === "noBounce" && /* @__PURE__ */ p(g, {
218
- intent: "info",
219
- solid: !1,
220
- size: "xs",
221
- children: /* @__PURE__ */ p("span", {
222
- className: "text-xs",
223
- children: "The page scrolls, but a finger pulled past either end no longer bounces it or reloads it"
224
- })
225
- }),
226
- R === "locked" && /* @__PURE__ */ p(g, {
227
- intent: "info",
228
- solid: !1,
229
- size: "xs",
230
- children: /* @__PURE__ */ p("span", {
231
- className: "text-xs",
232
- children: "The page holds still: only the parts set to scroll on their own (overflow auto) move. For a screen that fills the window — a dashboard, a board"
233
- })
234
- }),
235
- /* @__PURE__ */ p(_, {
236
- label: " SEO Enabled",
237
- checked: C,
238
- onChange: te,
239
- size: "xs"
240
- }),
241
- C && /* @__PURE__ */ m(f, { children: [
242
- /* @__PURE__ */ p(v, {
243
- value: D,
244
- label: "SEO Title",
245
- onChange: J.text("seoPageTitle"),
246
- size: "xs"
247
- }),
248
- /* @__PURE__ */ p(y, {
249
- label: "SEO Description",
250
- value: O,
251
- onChange: J.text("seoPageDescription"),
252
- rows: 3,
267
+ /* @__PURE__ */ h(n, {
268
+ id: "page-seo",
269
+ title: "Search & sharing",
270
+ summary: ne(T, k),
271
+ highlight: T,
272
+ children: [/* @__PURE__ */ m(_, {
273
+ label: " SEO Enabled",
274
+ checked: T,
275
+ onChange: me,
253
276
  size: "xs"
254
- }),
255
- /* @__PURE__ */ m("div", {
256
- className: "flex flex-col",
257
- children: [
258
- /* @__PURE__ */ p("p", {
259
- className: "mb-4 text-xs",
260
- children: "Specify this page's title and description. You can see how they'll look in search engine results pages (SERPs) in the preview below."
261
- }),
262
- /* @__PURE__ */ p("label", { children: "Search Result Preview" }),
263
- /* @__PURE__ */ m("div", {
264
- className: "rounded border border-gray-300 px-2 py-1",
265
- children: [
266
- /* @__PURE__ */ p("div", {
267
- className: "mb-1 pt-1 text-xl text-[#1a0dab]",
268
- children: /* @__PURE__ */ p("label", { children: D })
269
- }),
270
- /* @__PURE__ */ p("div", {
271
- className: "text-sm text-[#006621]",
272
- children: /* @__PURE__ */ p("span", { children: "www.url.com" })
273
- }),
274
- /* @__PURE__ */ p("div", {
275
- className: "settings-seo__description mb-1 pt-1 text-sm",
276
- children: `${O.slice(0, 160)}...`
277
- })
278
- ]
279
- })
280
- ]
281
- }),
282
- /* @__PURE__ */ p(v, {
283
- value: k,
284
- label: "Robots",
285
- placeholder: "index, follow",
286
- onChange: J.text("seoRobots"),
287
- size: "xs"
288
- }),
289
- /* @__PURE__ */ p(v, {
290
- value: A,
291
- label: "Share image",
292
- placeholder: "/og.png, https://…, or {{ apiContainer_room.cover }}",
293
- onChange: J.text("seoImage"),
294
- size: "xs"
295
- }),
296
- /* @__PURE__ */ p(v, {
297
- value: j,
298
- label: "Share image description",
299
- placeholder: "What the picture shows",
300
- onChange: J.text("seoImageAlt"),
301
- size: "xs"
302
- }),
303
- /* @__PURE__ */ p(b, {
304
- value: ee,
305
- label: "Kind of page",
306
- onChange: J.text("seoType"),
307
- size: "xs",
308
- placeholder: "website",
309
- children: c.map((e) => /* @__PURE__ */ p("option", {
310
- value: e,
311
- children: e
312
- }, e))
313
- }),
314
- /* @__PURE__ */ p(n, {
315
- title: D,
316
- description: O,
317
- ...A ? { image: A } : {},
318
- ...j ? { imageAlt: j } : {}
319
- })
320
- ] })
277
+ }), T && /* @__PURE__ */ h(p, { children: [
278
+ /* @__PURE__ */ m(v, {
279
+ value: k,
280
+ label: "SEO Title",
281
+ onChange: q.text("seoPageTitle"),
282
+ size: "xs"
283
+ }),
284
+ /* @__PURE__ */ m(y, {
285
+ label: "SEO Description",
286
+ value: A,
287
+ onChange: q.text("seoPageDescription"),
288
+ rows: 3,
289
+ size: "xs"
290
+ }),
291
+ /* @__PURE__ */ m(v, {
292
+ value: oe,
293
+ label: "Robots",
294
+ placeholder: "index, follow",
295
+ onChange: q.text("seoRobots"),
296
+ size: "xs"
297
+ }),
298
+ /* @__PURE__ */ m(b, {
299
+ value: se,
300
+ label: "Kind of page",
301
+ onChange: q.text("seoType"),
302
+ size: "xs",
303
+ placeholder: "website",
304
+ children: l.map((e) => /* @__PURE__ */ m("option", {
305
+ value: e,
306
+ children: e
307
+ }, e))
308
+ }),
309
+ /* @__PURE__ */ m(v, {
310
+ value: j,
311
+ label: "Share image",
312
+ placeholder: "/og.png, https://…, or {{ apiContainer_room.cover }}",
313
+ onChange: q.text("seoImage"),
314
+ size: "xs"
315
+ }),
316
+ /* @__PURE__ */ m(v, {
317
+ value: M,
318
+ label: "Share image description",
319
+ placeholder: "What the picture shows",
320
+ onChange: q.text("seoImageAlt"),
321
+ size: "xs"
322
+ }),
323
+ /* @__PURE__ */ h(n, {
324
+ id: "page-seo-previews",
325
+ title: "Previews",
326
+ summary: "Search result and share card",
327
+ children: [
328
+ /* @__PURE__ */ m("span", {
329
+ className: "text-ui-fg-subtle text-xs",
330
+ children: "How this page's title and description show in search results (SERPs):"
331
+ }),
332
+ /* @__PURE__ */ h("div", {
333
+ className: "rounded border border-gray-300 bg-white px-2 py-1",
334
+ children: [
335
+ /* @__PURE__ */ m("div", {
336
+ className: "mb-1 pt-1 text-xl text-[#1a0dab]",
337
+ children: /* @__PURE__ */ m("label", { children: k })
338
+ }),
339
+ /* @__PURE__ */ m("div", {
340
+ className: "text-sm text-[#006621]",
341
+ children: /* @__PURE__ */ m("span", { children: "www.url.com" })
342
+ }),
343
+ /* @__PURE__ */ m("div", {
344
+ className: "settings-seo__description text-ui-fg mb-1 pt-1 text-sm",
345
+ children: `${A.slice(0, 160)}...`
346
+ })
347
+ ]
348
+ }),
349
+ /* @__PURE__ */ m(re, {
350
+ title: k,
351
+ description: A,
352
+ ...j ? { image: j } : {},
353
+ ...M ? { imageAlt: M } : {}
354
+ })
355
+ ]
356
+ })
357
+ ] })]
358
+ })
321
359
  ]
322
360
  });
323
361
  };
324
- export { S as default };
362
+ export { w as default };