@bagelink/blox 1.15.29 → 1.15.34
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/{PreviewApp-BDMfuAiu.cjs → PreviewApp-C5hzLdHt.cjs} +1 -1
- package/dist/{PreviewApp-MdZQEVkN.js → PreviewApp-CCxTa86_.js} +1 -1
- package/dist/{PreviewApp.vue_vue_type_style_index_0_lang-Bc4Ac4WN.js → PreviewApp.vue_vue_type_style_index_0_lang-Bv4eRrVz.js} +1 -1
- package/dist/{PreviewApp.vue_vue_type_style_index_0_lang-BG9Fvfdw.cjs → PreviewApp.vue_vue_type_style_index_0_lang-Da4Pi_Lc.cjs} +1 -1
- package/dist/{core-DhrL5TMI.cjs → core-CR2evIjK.cjs} +2 -2
- package/dist/{core-CgtYpQbn.js → core-Do0ELzJT.js} +2 -2
- package/dist/index.cjs +2 -2
- package/dist/index.mjs +3 -3
- package/dist/{prerender-LqPEzho3.cjs → prerender-D_Hd055h.cjs} +16 -5
- package/dist/{prerender-CJ22vZ1T.js → prerender-QNw4gq9W.js} +16 -5
- package/dist/ssg/cli.cjs +1 -1
- package/dist/ssg/cli.mjs +1 -1
- package/dist/ssg/index.cjs +2 -2
- package/dist/ssg/index.mjs +3 -3
- package/dist/ssg/seo.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -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-Da4Pi_Lc.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 { e as BLOX_REGISTRY_KEY, u as useLocale } from "./core-
|
|
2
|
+
import { e as BLOX_REGISTRY_KEY, u as useLocale } from "./core-Do0ELzJT.js";
|
|
3
3
|
function sendToEditor(msg) {
|
|
4
4
|
window.parent.postMessage(msg, "*");
|
|
5
5
|
}
|
|
@@ -100,7 +100,7 @@ const PageRenderer = vue.defineComponent({
|
|
|
100
100
|
});
|
|
101
101
|
const _hoisted_1 = {
|
|
102
102
|
key: 0,
|
|
103
|
-
class: "blox-loading"
|
|
103
|
+
class: "blox-loading flex column h-100vh justify-content-center"
|
|
104
104
|
};
|
|
105
105
|
const _hoisted_2 = {
|
|
106
106
|
key: 1,
|
|
@@ -404,7 +404,7 @@ class BloxInstance {
|
|
|
404
404
|
}
|
|
405
405
|
router.addRoute({
|
|
406
406
|
path: "/_blox_preview",
|
|
407
|
-
component: () => Promise.resolve().then(() => require("./PreviewApp-
|
|
407
|
+
component: () => Promise.resolve().then(() => require("./PreviewApp-C5hzLdHt.cjs")),
|
|
408
408
|
beforeEnter: () => window.parent !== window ? true : "/"
|
|
409
409
|
});
|
|
410
410
|
router.addRoute({ path: "/:pathMatch(.*)*", component: _sfc_main$1 });
|
|
@@ -99,7 +99,7 @@ const PageRenderer = defineComponent({
|
|
|
99
99
|
});
|
|
100
100
|
const _hoisted_1 = {
|
|
101
101
|
key: 0,
|
|
102
|
-
class: "blox-loading"
|
|
102
|
+
class: "blox-loading flex column h-100vh justify-content-center"
|
|
103
103
|
};
|
|
104
104
|
const _hoisted_2 = {
|
|
105
105
|
key: 1,
|
|
@@ -403,7 +403,7 @@ class BloxInstance {
|
|
|
403
403
|
}
|
|
404
404
|
router.addRoute({
|
|
405
405
|
path: "/_blox_preview",
|
|
406
|
-
component: () => import("./PreviewApp-
|
|
406
|
+
component: () => import("./PreviewApp-CCxTa86_.js"),
|
|
407
407
|
beforeEnter: () => window.parent !== window ? true : "/"
|
|
408
408
|
});
|
|
409
409
|
router.addRoute({ path: "/:pathMatch(.*)*", component: _sfc_main$1 });
|
package/dist/index.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const core = require("./core-
|
|
4
|
-
const PreviewApp_vue_vue_type_style_index_0_lang = require("./PreviewApp.vue_vue_type_style_index_0_lang-
|
|
3
|
+
const core = require("./core-CR2evIjK.cjs");
|
|
4
|
+
const PreviewApp_vue_vue_type_style_index_0_lang = require("./PreviewApp.vue_vue_type_style_index_0_lang-Da4Pi_Lc.cjs");
|
|
5
5
|
const vue = require("vue");
|
|
6
6
|
const vueRouter = require("vue-router");
|
|
7
7
|
const pinia = require("pinia");
|
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { B as BLOX_LOCALE_STRATEGY_KEY, u as useLocale, c as createBlox } from "./core-
|
|
2
|
-
import { a, b, _, P, d, l, r } from "./core-
|
|
3
|
-
import { _ as _2, P as P2, s, a as a2 } from "./PreviewApp.vue_vue_type_style_index_0_lang-
|
|
1
|
+
import { B as BLOX_LOCALE_STRATEGY_KEY, u as useLocale, c as createBlox } from "./core-Do0ELzJT.js";
|
|
2
|
+
import { a, b, _, P, d, l, r } from "./core-Do0ELzJT.js";
|
|
3
|
+
import { _ as _2, P as P2, s, a as a2 } from "./PreviewApp.vue_vue_type_style_index_0_lang-Bv4eRrVz.js";
|
|
4
4
|
import { inject, computed, createApp, markRaw } from "vue";
|
|
5
5
|
import { useRouter } from "vue-router";
|
|
6
6
|
import { createPinia } from "pinia";
|
|
@@ -177,7 +177,7 @@ function buildPageHead(options) {
|
|
|
177
177
|
}
|
|
178
178
|
const ogTitle = (page == null ? void 0 : page.meta_title) || ctx.title || (page == null ? void 0 : page.title) || meta.og_site_name || meta.default_meta_title;
|
|
179
179
|
const ogDesc = (page == null ? void 0 : page.meta_description) || ctx.description || meta.og_description || meta.default_meta_description;
|
|
180
|
-
const ogImage = (page == null ? void 0 : page.og_image) || ctx.image || meta.default_og_image;
|
|
180
|
+
const ogImage = absUrl((page == null ? void 0 : page.og_image) || ctx.image || meta.default_og_image, canonicalBase);
|
|
181
181
|
const ogType = meta.og_type || "website";
|
|
182
182
|
if (ogTitle) parts.push(`<meta property="og:title" content="${esc(ogTitle)}">`);
|
|
183
183
|
if (ogDesc) parts.push(`<meta property="og:description" content="${esc(ogDesc)}">`);
|
|
@@ -211,11 +211,14 @@ function buildSiteHead(website) {
|
|
|
211
211
|
if (!website) return "";
|
|
212
212
|
const parts = [];
|
|
213
213
|
const meta = website.meta ?? {};
|
|
214
|
-
|
|
215
|
-
|
|
214
|
+
const base = (meta.canonical_base_url || website.domain || "").replace(/\/$/, "");
|
|
215
|
+
const favicon = absUrl(website.favicon_url, base);
|
|
216
|
+
if (favicon) {
|
|
217
|
+
parts.push(`<link rel="icon" href="${esc(favicon)}">`);
|
|
216
218
|
}
|
|
217
|
-
|
|
218
|
-
|
|
219
|
+
const webclip = absUrl(meta.webclip, base);
|
|
220
|
+
if (webclip) {
|
|
221
|
+
parts.push(`<link rel="apple-touch-icon" sizes="180x180" href="${esc(webclip)}">`);
|
|
219
222
|
}
|
|
220
223
|
if (meta.verification_google) {
|
|
221
224
|
parts.push(`<meta name="google-site-verification" content="${esc(meta.verification_google)}">`);
|
|
@@ -302,6 +305,14 @@ function extractPrimaryContext(contexts) {
|
|
|
302
305
|
function esc(s) {
|
|
303
306
|
return s.replace(/&/g, "&").replace(/"/g, """).replace(/</g, "<").replace(/>/g, ">");
|
|
304
307
|
}
|
|
308
|
+
function absUrl(value, base) {
|
|
309
|
+
if (!value) return null;
|
|
310
|
+
const v = value.trim();
|
|
311
|
+
if (!v) return null;
|
|
312
|
+
if (/^(https?:)?\/\//i.test(v) || v.startsWith("/")) return v;
|
|
313
|
+
const cleanBase = (base ?? "").replace(/\/$/, "");
|
|
314
|
+
return cleanBase ? `${cleanBase}/${v}` : `/${v}`;
|
|
315
|
+
}
|
|
305
316
|
async function prerender({
|
|
306
317
|
root = process.cwd(),
|
|
307
318
|
clientOutDir = "dist/client",
|
|
@@ -154,7 +154,7 @@ function buildPageHead(options) {
|
|
|
154
154
|
}
|
|
155
155
|
const ogTitle = (page == null ? void 0 : page.meta_title) || ctx.title || (page == null ? void 0 : page.title) || meta.og_site_name || meta.default_meta_title;
|
|
156
156
|
const ogDesc = (page == null ? void 0 : page.meta_description) || ctx.description || meta.og_description || meta.default_meta_description;
|
|
157
|
-
const ogImage = (page == null ? void 0 : page.og_image) || ctx.image || meta.default_og_image;
|
|
157
|
+
const ogImage = absUrl((page == null ? void 0 : page.og_image) || ctx.image || meta.default_og_image, canonicalBase);
|
|
158
158
|
const ogType = meta.og_type || "website";
|
|
159
159
|
if (ogTitle) parts.push(`<meta property="og:title" content="${esc(ogTitle)}">`);
|
|
160
160
|
if (ogDesc) parts.push(`<meta property="og:description" content="${esc(ogDesc)}">`);
|
|
@@ -188,11 +188,14 @@ function buildSiteHead(website) {
|
|
|
188
188
|
if (!website) return "";
|
|
189
189
|
const parts = [];
|
|
190
190
|
const meta = website.meta ?? {};
|
|
191
|
-
|
|
192
|
-
|
|
191
|
+
const base = (meta.canonical_base_url || website.domain || "").replace(/\/$/, "");
|
|
192
|
+
const favicon = absUrl(website.favicon_url, base);
|
|
193
|
+
if (favicon) {
|
|
194
|
+
parts.push(`<link rel="icon" href="${esc(favicon)}">`);
|
|
193
195
|
}
|
|
194
|
-
|
|
195
|
-
|
|
196
|
+
const webclip = absUrl(meta.webclip, base);
|
|
197
|
+
if (webclip) {
|
|
198
|
+
parts.push(`<link rel="apple-touch-icon" sizes="180x180" href="${esc(webclip)}">`);
|
|
196
199
|
}
|
|
197
200
|
if (meta.verification_google) {
|
|
198
201
|
parts.push(`<meta name="google-site-verification" content="${esc(meta.verification_google)}">`);
|
|
@@ -279,6 +282,14 @@ function extractPrimaryContext(contexts) {
|
|
|
279
282
|
function esc(s) {
|
|
280
283
|
return s.replace(/&/g, "&").replace(/"/g, """).replace(/</g, "<").replace(/>/g, ">");
|
|
281
284
|
}
|
|
285
|
+
function absUrl(value, base) {
|
|
286
|
+
if (!value) return null;
|
|
287
|
+
const v = value.trim();
|
|
288
|
+
if (!v) return null;
|
|
289
|
+
if (/^(https?:)?\/\//i.test(v) || v.startsWith("/")) return v;
|
|
290
|
+
const cleanBase = (base ?? "").replace(/\/$/, "");
|
|
291
|
+
return cleanBase ? `${cleanBase}/${v}` : `/${v}`;
|
|
292
|
+
}
|
|
282
293
|
async function prerender({
|
|
283
294
|
root = process.cwd(),
|
|
284
295
|
clientOutDir = "dist/client",
|
package/dist/ssg/cli.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env bun
|
|
2
2
|
"use strict";
|
|
3
3
|
const process = require("node:process");
|
|
4
|
-
const prerender = require("../prerender-
|
|
4
|
+
const prerender = require("../prerender-D_Hd055h.cjs");
|
|
5
5
|
async function resolveApiBase(mode) {
|
|
6
6
|
if (process.env.BAGELINK_API_URL != null && process.env.BAGELINK_API_URL !== "") {
|
|
7
7
|
return { apiBase: process.env.BAGELINK_API_URL };
|
package/dist/ssg/cli.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env bun
|
|
2
2
|
import process from "node:process";
|
|
3
|
-
import { p as polyfillBloxSsgGlobals, f as fetchCmsSiteData, a as prerender } from "../prerender-
|
|
3
|
+
import { p as polyfillBloxSsgGlobals, f as fetchCmsSiteData, a as prerender } from "../prerender-QNw4gq9W.js";
|
|
4
4
|
async function resolveApiBase(mode) {
|
|
5
5
|
if (process.env.BAGELINK_API_URL != null && process.env.BAGELINK_API_URL !== "") {
|
|
6
6
|
return { apiBase: process.env.BAGELINK_API_URL };
|
package/dist/ssg/index.cjs
CHANGED
|
@@ -22,11 +22,11 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
22
22
|
mod
|
|
23
23
|
));
|
|
24
24
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
25
|
-
const prerender = require("../prerender-
|
|
25
|
+
const prerender = require("../prerender-D_Hd055h.cjs");
|
|
26
26
|
const ssg_client = require("./client.cjs");
|
|
27
27
|
const pinia = require("pinia");
|
|
28
28
|
const vue = require("vue");
|
|
29
|
-
const core = require("../core-
|
|
29
|
+
const core = require("../core-CR2evIjK.cjs");
|
|
30
30
|
async function renderBloxSsgPage(options) {
|
|
31
31
|
const {
|
|
32
32
|
url,
|
package/dist/ssg/index.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { b as buildPageHead } from "../prerender-
|
|
2
|
-
import { c, d, f, g, e, h, p, a } from "../prerender-
|
|
1
|
+
import { b as buildPageHead } from "../prerender-QNw4gq9W.js";
|
|
2
|
+
import { c, d, f, g, e, h, p, a } from "../prerender-QNw4gq9W.js";
|
|
3
3
|
import { BLOX_STATE_WINDOW_KEY, BLOX_COLLECTIONS_WINDOW_KEY, BLOX_WEBSITE_ID_WINDOW_KEY } from "./client.mjs";
|
|
4
4
|
import { getCollectionCache, getEmbeddedWebsiteId, installBloxStateCache, installCollectionCache } from "./client.mjs";
|
|
5
5
|
import { createPinia } from "pinia";
|
|
6
6
|
import { createSSRApp, markRaw } from "vue";
|
|
7
|
-
import { c as createBlox } from "../core-
|
|
7
|
+
import { c as createBlox } from "../core-Do0ELzJT.js";
|
|
8
8
|
async function renderBloxSsgPage(options) {
|
|
9
9
|
const {
|
|
10
10
|
url,
|
package/dist/ssg/seo.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"seo.d.ts","sourceRoot":"","sources":["../../src/ssg/seo.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,cAAc,CAAA;AAMzD,4DAA4D;AAC5D,MAAM,WAAW,WAAW;IAC3B,IAAI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