webim-adapter 2.10.6 → 2.10.7
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/build/webim-adapter.js +1454 -1438
- package/build/webim-bundle.js +20 -16
- package/build/webim-embed.js +18 -18
- package/build/webim-ssr.js +1461 -1445
- package/package.json +1 -1
package/build/webim-bundle.js
CHANGED
|
@@ -200,36 +200,40 @@ var n = "-apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Ari
|
|
|
200
200
|
};
|
|
201
201
|
r.light, r.dark, `${n}`, `${n}`;
|
|
202
202
|
function i(e, t) {
|
|
203
|
+
let n = e?.scheme;
|
|
204
|
+
return n === "light" || n === "dark" ? n : n === "auto" ? "" : t?.scheme === "light" || t?.scheme === "dark" ? t.scheme : "";
|
|
205
|
+
}
|
|
206
|
+
function a(e, t) {
|
|
203
207
|
return e?.themeRef && t?.[e.themeRef] || e?.theme;
|
|
204
208
|
}
|
|
205
209
|
//#endregion
|
|
206
210
|
//#region src/bundle.js
|
|
207
|
-
function
|
|
208
|
-
let
|
|
211
|
+
function o({ page: e, settings: t, tenant: n, apiUrl: r, locale: o }) {
|
|
212
|
+
let s = {
|
|
209
213
|
...t?.global ?? {},
|
|
210
214
|
...t?.tenant ?? {}
|
|
211
|
-
},
|
|
215
|
+
}, c = e.meta ?? {}, l = a(c, s.builder_themes?.themes);
|
|
212
216
|
return {
|
|
213
217
|
schema: 1,
|
|
214
218
|
title: e.title,
|
|
215
219
|
slug: e.slug,
|
|
216
220
|
param: e.param ?? "",
|
|
217
|
-
blocks:
|
|
218
|
-
theme:
|
|
219
|
-
components:
|
|
220
|
-
custom:
|
|
221
|
-
animations:
|
|
222
|
-
seo:
|
|
223
|
-
direction:
|
|
224
|
-
scheme:
|
|
225
|
-
locale:
|
|
226
|
-
locales:
|
|
221
|
+
blocks: o && c.i18n?.[o]?.blocks || e.blocks,
|
|
222
|
+
theme: l,
|
|
223
|
+
components: s.builder_components?.components ?? {},
|
|
224
|
+
custom: c.custom,
|
|
225
|
+
animations: c.animations,
|
|
226
|
+
seo: c.seo,
|
|
227
|
+
direction: c.direction,
|
|
228
|
+
scheme: i(l, c),
|
|
229
|
+
locale: o || s.locales?.default,
|
|
230
|
+
locales: s.locales,
|
|
227
231
|
tenant: n ?? "",
|
|
228
232
|
apiUrl: r ?? "",
|
|
229
|
-
settings:
|
|
233
|
+
settings: s
|
|
230
234
|
};
|
|
231
235
|
}
|
|
232
|
-
function
|
|
236
|
+
function s(e) {
|
|
233
237
|
let t = e?.seo ?? {}, n = String(t.title || e?.title || e?.slug || "").trim(), r = e?.settings ?? {}, i = r["site.titleFormat"], a = typeof r["site.name"] == "string" ? r["site.name"].trim() : "";
|
|
234
238
|
if (!a || i !== "suffix" && i !== "prefix") return n;
|
|
235
239
|
if (!n || n.toLowerCase().includes(a.toLowerCase())) return n || a;
|
|
@@ -237,4 +241,4 @@ function o(e) {
|
|
|
237
241
|
return i === "prefix" ? `${a}${s}${n}` : `${n}${s}${a}`;
|
|
238
242
|
}
|
|
239
243
|
//#endregion
|
|
240
|
-
export {
|
|
244
|
+
export { o as assembleBundle, s as documentTitle };
|