@bagelink/blox 1.15.657 → 1.15.661
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/CmsPageView.vue.d.ts.map +1 -1
- package/dist/{PreviewApp-BTXBGqk_.js → PreviewApp-6imffI4L.js} +1 -1
- package/dist/{PreviewApp-_AiXsd8B.cjs → PreviewApp-_sBftiOk.cjs} +1 -1
- package/dist/{PreviewApp.vue_vue_type_style_index_0_lang-BNAjDevX.cjs → PreviewApp.vue_vue_type_style_index_0_lang-BP6sRzCv.cjs} +1 -1
- package/dist/{PreviewApp.vue_vue_type_style_index_0_lang-C8ZUqyan.js → PreviewApp.vue_vue_type_style_index_0_lang-D3nz9VR7.js} +1 -1
- package/dist/{appRuntime-D2R6KNSO.cjs → appRuntime-KrtrOgvG.cjs} +31 -5
- package/dist/{appRuntime-D6mBmhEl.js → appRuntime-wD8N8dxg.js} +31 -5
- package/dist/composables/useLocaleNav.d.ts.map +1 -1
- package/dist/index.cjs +3 -5
- package/dist/index.mjs +4 -6
- package/dist/ssg/createSSREntry.d.ts.map +1 -1
- package/dist/ssg/index.cjs +4 -5
- package/dist/ssg/index.mjs +4 -5
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CmsPageView.vue.d.ts","sourceRoot":"","sources":["../src/CmsPageView.vue"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"CmsPageView.vue.d.ts","sourceRoot":"","sources":["../src/CmsPageView.vue"],"names":[],"mappings":";AA2pBA,wBAMG"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const PreviewApp_vue_vue_type_style_index_0_lang = require("./PreviewApp.vue_vue_type_style_index_0_lang-
|
|
3
|
+
const PreviewApp_vue_vue_type_style_index_0_lang = require("./PreviewApp.vue_vue_type_style_index_0_lang-BP6sRzCv.cjs");
|
|
4
4
|
exports.default = PreviewApp_vue_vue_type_style_index_0_lang._sfc_main;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent, inject, ref, h, provide, onMounted, onUnmounted, openBlock, createElementBlock, createVNode, unref, nextTick } from "vue";
|
|
2
|
-
import { d as BLOX_REGISTRY_KEY, r as resolveBlockProps, u as useLocale, e as BLOX_RUNTIME_KEY } from "./appRuntime-
|
|
2
|
+
import { d as BLOX_REGISTRY_KEY, r as resolveBlockProps, u as useLocale, e as BLOX_RUNTIME_KEY } from "./appRuntime-wD8N8dxg.js";
|
|
3
3
|
function sendToEditor(msg) {
|
|
4
4
|
window.parent.postMessage(cloneForPostMessage(msg), "*");
|
|
5
5
|
}
|
|
@@ -316,6 +316,29 @@ const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
|
316
316
|
function currentRouteTarget(fallback) {
|
|
317
317
|
return typeof (route == null ? void 0 : route.fullPath) === "string" && route.fullPath ? route.fullPath : currentRoutePath() || fallback;
|
|
318
318
|
}
|
|
319
|
+
function homePath(localeCode) {
|
|
320
|
+
if (strategy) return strategy.toPath("/", localeCode);
|
|
321
|
+
return localeCode === "en" ? "/" : `/${localeCode}`;
|
|
322
|
+
}
|
|
323
|
+
function usableAlternates(alternates) {
|
|
324
|
+
const out = {};
|
|
325
|
+
for (const [localeKey, path] of Object.entries(alternates ?? {})) {
|
|
326
|
+
if (typeof path === "string" && path && !path.includes(":")) out[localeKey] = path;
|
|
327
|
+
}
|
|
328
|
+
return out;
|
|
329
|
+
}
|
|
330
|
+
function hasUnresolvedBinding(resolved) {
|
|
331
|
+
var _a2;
|
|
332
|
+
const bindings = (_a2 = resolved.page) == null ? void 0 : _a2.data_bindings;
|
|
333
|
+
if (!bindings) return false;
|
|
334
|
+
const boundKeys = Object.keys(bindings).filter((key) => key !== "$website");
|
|
335
|
+
if (!boundKeys.length) return false;
|
|
336
|
+
const contexts2 = resolved.contexts ?? {};
|
|
337
|
+
return boundKeys.some((key) => {
|
|
338
|
+
const value = contexts2[key];
|
|
339
|
+
return value === null || value === void 0;
|
|
340
|
+
});
|
|
341
|
+
}
|
|
319
342
|
function tryHydrateFromState(path) {
|
|
320
343
|
var _a2;
|
|
321
344
|
if ((ssrRouteState == null ? void 0 : ssrRouteState.path) === path && ssrRouteState.resolved) {
|
|
@@ -333,7 +356,7 @@ const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
|
333
356
|
blocks.value = ((_b = (_a2 = entry.page) == null ? void 0 : _a2.content) == null ? void 0 : _b.blocks) ?? [];
|
|
334
357
|
contexts.value = entry.contexts ?? {};
|
|
335
358
|
currentPageId.value = ((_c = entry.page) == null ? void 0 : _c.id) ?? null;
|
|
336
|
-
setAlternates(
|
|
359
|
+
setAlternates(usableAlternates(entry.alternates));
|
|
337
360
|
updateDocumentTitle(entry);
|
|
338
361
|
}
|
|
339
362
|
function updateDocumentTitle(resolved) {
|
|
@@ -374,16 +397,19 @@ const _sfc_main$2 = /* @__PURE__ */ vue.defineComponent({
|
|
|
374
397
|
navigating.value = true;
|
|
375
398
|
try {
|
|
376
399
|
const resolved = await ((api == null ? void 0 : api.resolvePath(slug, urlLocale)) ?? index.resolvePath(slug, urlLocale));
|
|
400
|
+
if (hasUnresolvedBinding(resolved)) {
|
|
401
|
+
await router.replace(homePath(urlLocale));
|
|
402
|
+
return;
|
|
403
|
+
}
|
|
377
404
|
blocks.value = ((_a2 = resolved.page.content) == null ? void 0 : _a2.blocks) ?? [];
|
|
378
405
|
contexts.value = resolved.contexts ?? {};
|
|
379
406
|
currentPageId.value = resolved.page.id ?? null;
|
|
380
|
-
setAlternates(resolved.alternates
|
|
407
|
+
setAlternates(usableAlternates(resolved.alternates));
|
|
381
408
|
updateDocumentTitle(resolved);
|
|
382
409
|
} catch (e) {
|
|
383
410
|
const msg = e instanceof Error ? e.message : String(e);
|
|
384
411
|
if (msg.includes("404")) {
|
|
385
|
-
|
|
386
|
-
await router.replace(home);
|
|
412
|
+
await router.replace(homePath(urlLocale));
|
|
387
413
|
} else {
|
|
388
414
|
error.value = msg;
|
|
389
415
|
}
|
|
@@ -873,7 +899,7 @@ class BloxInstance {
|
|
|
873
899
|
router.addRoute({
|
|
874
900
|
path: "/_blox_preview",
|
|
875
901
|
name: BLOX_PREVIEW_ROUTE_NAME,
|
|
876
|
-
component: () => Promise.resolve().then(() => require("./PreviewApp-
|
|
902
|
+
component: () => Promise.resolve().then(() => require("./PreviewApp-_sBftiOk.cjs")),
|
|
877
903
|
beforeEnter: () => typeof window === "undefined" || window.parent !== window ? true : "/"
|
|
878
904
|
});
|
|
879
905
|
}
|
|
@@ -315,6 +315,29 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
315
315
|
function currentRouteTarget(fallback) {
|
|
316
316
|
return typeof (route == null ? void 0 : route.fullPath) === "string" && route.fullPath ? route.fullPath : currentRoutePath() || fallback;
|
|
317
317
|
}
|
|
318
|
+
function homePath(localeCode) {
|
|
319
|
+
if (strategy) return strategy.toPath("/", localeCode);
|
|
320
|
+
return localeCode === "en" ? "/" : `/${localeCode}`;
|
|
321
|
+
}
|
|
322
|
+
function usableAlternates(alternates) {
|
|
323
|
+
const out = {};
|
|
324
|
+
for (const [localeKey, path] of Object.entries(alternates ?? {})) {
|
|
325
|
+
if (typeof path === "string" && path && !path.includes(":")) out[localeKey] = path;
|
|
326
|
+
}
|
|
327
|
+
return out;
|
|
328
|
+
}
|
|
329
|
+
function hasUnresolvedBinding(resolved) {
|
|
330
|
+
var _a2;
|
|
331
|
+
const bindings = (_a2 = resolved.page) == null ? void 0 : _a2.data_bindings;
|
|
332
|
+
if (!bindings) return false;
|
|
333
|
+
const boundKeys = Object.keys(bindings).filter((key) => key !== "$website");
|
|
334
|
+
if (!boundKeys.length) return false;
|
|
335
|
+
const contexts2 = resolved.contexts ?? {};
|
|
336
|
+
return boundKeys.some((key) => {
|
|
337
|
+
const value = contexts2[key];
|
|
338
|
+
return value === null || value === void 0;
|
|
339
|
+
});
|
|
340
|
+
}
|
|
318
341
|
function tryHydrateFromState(path) {
|
|
319
342
|
var _a2;
|
|
320
343
|
if ((ssrRouteState == null ? void 0 : ssrRouteState.path) === path && ssrRouteState.resolved) {
|
|
@@ -332,7 +355,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
332
355
|
blocks.value = ((_b = (_a2 = entry.page) == null ? void 0 : _a2.content) == null ? void 0 : _b.blocks) ?? [];
|
|
333
356
|
contexts.value = entry.contexts ?? {};
|
|
334
357
|
currentPageId.value = ((_c = entry.page) == null ? void 0 : _c.id) ?? null;
|
|
335
|
-
setAlternates(
|
|
358
|
+
setAlternates(usableAlternates(entry.alternates));
|
|
336
359
|
updateDocumentTitle(entry);
|
|
337
360
|
}
|
|
338
361
|
function updateDocumentTitle(resolved) {
|
|
@@ -373,16 +396,19 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
|
373
396
|
navigating.value = true;
|
|
374
397
|
try {
|
|
375
398
|
const resolved = await ((api == null ? void 0 : api.resolvePath(slug, urlLocale)) ?? resolvePath(slug, urlLocale));
|
|
399
|
+
if (hasUnresolvedBinding(resolved)) {
|
|
400
|
+
await router.replace(homePath(urlLocale));
|
|
401
|
+
return;
|
|
402
|
+
}
|
|
376
403
|
blocks.value = ((_a2 = resolved.page.content) == null ? void 0 : _a2.blocks) ?? [];
|
|
377
404
|
contexts.value = resolved.contexts ?? {};
|
|
378
405
|
currentPageId.value = resolved.page.id ?? null;
|
|
379
|
-
setAlternates(resolved.alternates
|
|
406
|
+
setAlternates(usableAlternates(resolved.alternates));
|
|
380
407
|
updateDocumentTitle(resolved);
|
|
381
408
|
} catch (e) {
|
|
382
409
|
const msg = e instanceof Error ? e.message : String(e);
|
|
383
410
|
if (msg.includes("404")) {
|
|
384
|
-
|
|
385
|
-
await router.replace(home);
|
|
411
|
+
await router.replace(homePath(urlLocale));
|
|
386
412
|
} else {
|
|
387
413
|
error.value = msg;
|
|
388
414
|
}
|
|
@@ -872,7 +898,7 @@ class BloxInstance {
|
|
|
872
898
|
router.addRoute({
|
|
873
899
|
path: "/_blox_preview",
|
|
874
900
|
name: BLOX_PREVIEW_ROUTE_NAME,
|
|
875
|
-
component: () => import("./PreviewApp-
|
|
901
|
+
component: () => import("./PreviewApp-6imffI4L.js"),
|
|
876
902
|
beforeEnter: () => typeof window === "undefined" || window.parent !== window ? true : "/"
|
|
877
903
|
});
|
|
878
904
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useLocaleNav.d.ts","sourceRoot":"","sources":["../../src/composables/useLocaleNav.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;GAWG;AACH,wBAAgB,YAAY;iCAYS,MAAM;
|
|
1
|
+
{"version":3,"file":"useLocaleNav.d.ts","sourceRoot":"","sources":["../../src/composables/useLocaleNav.ts"],"names":[],"mappings":"AAMA;;;;;;;;;;;GAWG;AACH,wBAAgB,YAAY;iCAYS,MAAM;mBAiBpB,MAAM,KAAG,MAAM;+BAOH,MAAM,oBAAe,MAAM;mBAYvC,MAAM,KAAG;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE;;;EAa/D"}
|
package/dist/index.cjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const index = require("./index-DUjEj7ts.cjs");
|
|
4
|
-
const PreviewApp_vue_vue_type_style_index_0_lang = require("./PreviewApp.vue_vue_type_style_index_0_lang-
|
|
5
|
-
const appRuntime = require("./appRuntime-
|
|
4
|
+
const PreviewApp_vue_vue_type_style_index_0_lang = require("./PreviewApp.vue_vue_type_style_index_0_lang-BP6sRzCv.cjs");
|
|
5
|
+
const appRuntime = require("./appRuntime-KrtrOgvG.cjs");
|
|
6
6
|
const vue = require("vue");
|
|
7
7
|
const ssg_client = require("./client-AoDTJJXJ.cjs");
|
|
8
8
|
const vueRouter = require("vue-router");
|
|
@@ -139,9 +139,7 @@ function useLocaleNav() {
|
|
|
139
139
|
function switchLocale(targetLocale) {
|
|
140
140
|
if (!strategy) return;
|
|
141
141
|
const alts = currentAlternates.value;
|
|
142
|
-
const
|
|
143
|
-
const { slug: currentSlug } = strategy.detect(hostname, router.currentRoute.value.path);
|
|
144
|
-
const alternateSlug = alts[targetLocale] ?? alts[strategy.defaultLocale] ?? currentSlug ?? "/";
|
|
142
|
+
const alternateSlug = alts[targetLocale] ?? "/";
|
|
145
143
|
strategy.switchTo(targetLocale, alternateSlug, router);
|
|
146
144
|
}
|
|
147
145
|
function toPath(slug) {
|
package/dist/index.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { useBloxApi, getItemBySlug, getItemById, provideBloxApi } from "./index-I81QTzv-.js";
|
|
2
2
|
import { configureApi, createBloxApi, getCollectionResolver, getWebsiteId, getWebsiteIdSync, listItems, resolvePath, setApiOrigin, setCollectionResolver } from "./index-I81QTzv-.js";
|
|
3
|
-
import { _, P, s, a } from "./PreviewApp.vue_vue_type_style_index_0_lang-
|
|
4
|
-
import { f as BLOX_LOCALE_STRATEGY_KEY, u as useLocale, n as normalizeLink, e as BLOX_RUNTIME_KEY, g as useSeo, h as getRegistryData, j as getContentRoute, p as provideBloxData, b as provideBloxLocale, i as installBloxRuntime, s as setActiveLocale, k as installSmartLinks, l as consumePendingLocaleSwitch } from "./appRuntime-
|
|
5
|
-
import { _ as _2, m, o, q, t, v, w, x, y, P as P2, z, A, c, a as a2, C, D, E, F, G, H, I, J, K, L, M, r, N, O, Q, R } from "./appRuntime-
|
|
3
|
+
import { _, P, s, a } from "./PreviewApp.vue_vue_type_style_index_0_lang-D3nz9VR7.js";
|
|
4
|
+
import { f as BLOX_LOCALE_STRATEGY_KEY, u as useLocale, n as normalizeLink, e as BLOX_RUNTIME_KEY, g as useSeo, h as getRegistryData, j as getContentRoute, p as provideBloxData, b as provideBloxLocale, i as installBloxRuntime, s as setActiveLocale, k as installSmartLinks, l as consumePendingLocaleSwitch } from "./appRuntime-wD8N8dxg.js";
|
|
5
|
+
import { _ as _2, m, o, q, t, v, w, x, y, P as P2, z, A, c, a as a2, C, D, E, F, G, H, I, J, K, L, M, r, N, O, Q, R } from "./appRuntime-wD8N8dxg.js";
|
|
6
6
|
import { defineComponent, resolveComponent, openBlock, createBlock, withCtx, Transition, resolveDynamicComponent, inject, ref, watch, onMounted, onUnmounted, computed, onServerPrefetch, toValue, h, Suspense, createSSRApp, createApp } from "vue";
|
|
7
7
|
import { r as readBloxHydration } from "./client-Ce9fRCGH.js";
|
|
8
8
|
import { useRouter, useRoute } from "vue-router";
|
|
@@ -139,9 +139,7 @@ function useLocaleNav() {
|
|
|
139
139
|
function switchLocale(targetLocale) {
|
|
140
140
|
if (!strategy) return;
|
|
141
141
|
const alts = currentAlternates.value;
|
|
142
|
-
const
|
|
143
|
-
const { slug: currentSlug } = strategy.detect(hostname, router.currentRoute.value.path);
|
|
144
|
-
const alternateSlug = alts[targetLocale] ?? alts[strategy.defaultLocale] ?? currentSlug ?? "/";
|
|
142
|
+
const alternateSlug = alts[targetLocale] ?? "/";
|
|
145
143
|
strategy.switchTo(targetLocale, alternateSlug, router);
|
|
146
144
|
}
|
|
147
145
|
function toPath(slug) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createSSREntry.d.ts","sourceRoot":"","sources":["../../src/ssg/createSSREntry.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,MAAM,KAAK,CAAA;AACzC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAA;AACxC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,aAAa,CAAA;AAG9D,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAA;AAK9D,OAA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AAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;CACnC,GAAG,IAAI,CAAC,CAmER;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,yBAAyB,GAAG,YAAY,CAgNnF"}
|
package/dist/ssg/index.cjs
CHANGED
|
@@ -26,7 +26,7 @@ const llmArtifacts = require("../validate-output-BdzD7fIN.cjs");
|
|
|
26
26
|
const ssg_buildGrant = require("./build-grant.cjs");
|
|
27
27
|
const ssg_client = require("../client-AoDTJJXJ.cjs");
|
|
28
28
|
const vue = require("vue");
|
|
29
|
-
const appRuntime = require("../appRuntime-
|
|
29
|
+
const appRuntime = require("../appRuntime-KrtrOgvG.cjs");
|
|
30
30
|
const index = require("../index-DUjEj7ts.cjs");
|
|
31
31
|
async function renderBloxSsgPage(options) {
|
|
32
32
|
var _a, _b, _c, _d;
|
|
@@ -181,10 +181,9 @@ async function resolvePublishedPage(pages, slug, locale, resolver) {
|
|
|
181
181
|
const localizedValue = localizedItem == null ? void 0 : localizedItem[binding.bind_by];
|
|
182
182
|
if (typeof localizedValue !== "string" || !localizedValue) return null;
|
|
183
183
|
const template = ((_a2 = page.alternate_patterns) == null ? void 0 : _a2[targetLocale]) ?? page.slug;
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
];
|
|
184
|
+
const path = template.replace(`:${param.name}`, localizedValue);
|
|
185
|
+
if (path.includes(":")) return null;
|
|
186
|
+
return [targetLocale, path];
|
|
188
187
|
}));
|
|
189
188
|
alternates = Object.fromEntries(localized.filter((value2) => value2 != null));
|
|
190
189
|
}
|
package/dist/ssg/index.mjs
CHANGED
|
@@ -3,7 +3,7 @@ import { k, l, f, m, n, o, q, g, r, s, t, w, x, y, p, a, z, A, u, c, v } from ".
|
|
|
3
3
|
import { parseBloxBuildGrantBody, resolveBloxBuildGrant } from "./build-grant.mjs";
|
|
4
4
|
import { a as BLOX_HYDRATION_WINDOW_KEY } from "../client-Ce9fRCGH.js";
|
|
5
5
|
import { createSSRApp, h, Suspense } from "vue";
|
|
6
|
-
import { c as collectBloxData, a as collectBloxSeo, p as provideBloxData, b as provideBloxLocale, B as BLOX_SSR_ROUTE_STATE_KEY, i as installBloxRuntime, s as setActiveLocale } from "../appRuntime-
|
|
6
|
+
import { c as collectBloxData, a as collectBloxSeo, p as provideBloxData, b as provideBloxLocale, B as BLOX_SSR_ROUTE_STATE_KEY, i as installBloxRuntime, s as setActiveLocale } from "../appRuntime-wD8N8dxg.js";
|
|
7
7
|
import { provideBloxApi, getCollectionResolver } from "../index-I81QTzv-.js";
|
|
8
8
|
async function renderBloxSsgPage(options) {
|
|
9
9
|
var _a, _b, _c, _d;
|
|
@@ -158,10 +158,9 @@ async function resolvePublishedPage(pages, slug, locale, resolver) {
|
|
|
158
158
|
const localizedValue = localizedItem == null ? void 0 : localizedItem[binding.bind_by];
|
|
159
159
|
if (typeof localizedValue !== "string" || !localizedValue) return null;
|
|
160
160
|
const template = ((_a2 = page.alternate_patterns) == null ? void 0 : _a2[targetLocale]) ?? page.slug;
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
];
|
|
161
|
+
const path = template.replace(`:${param.name}`, localizedValue);
|
|
162
|
+
if (path.includes(":")) return null;
|
|
163
|
+
return [targetLocale, path];
|
|
165
164
|
}));
|
|
166
165
|
alternates = Object.fromEntries(localized.filter((value2) => value2 != null));
|
|
167
166
|
}
|
package/package.json
CHANGED