@designcrowd/library.brand-page 6.0.0 → 6.0.1-jj-1
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/lib/src/{CreatedOnBrandCrowd-de-de-BhimVEpD.js → CreatedOnBrandCrowd-de-de-9euOrehV.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-en-us-CcBSmedR.js → CreatedOnBrandCrowd-en-us-YGQYmluT.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-es-es-Bywf3OqP.js → CreatedOnBrandCrowd-es-es-BNdoYm-V.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-fr-CWpYmK2m.js → CreatedOnBrandCrowd-fr-ca-u6g0gN7C.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-fr-ca-CWpYmK2m.js → CreatedOnBrandCrowd-fr-fr-u6g0gN7C.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-pt-DHM9G51s.js → CreatedOnBrandCrowd-pt-br-Cb_wlAM-.js} +1 -1
- package/lib/src/{CreatedOnBrandCrowd-pt-br-DHM9G51s.js → CreatedOnBrandCrowd-pt-pt-Cb_wlAM-.js} +1 -1
- package/lib/src/{CreatedOnDcom-de-de-BnUSIarY.js → CreatedOnDcom-de-de-Cv-dlRCv.js} +1 -1
- package/lib/src/{CreatedOnDcom-en-us-DzU8X52o.js → CreatedOnDcom-en-us-t029ffHN.js} +1 -1
- package/lib/src/{CreatedOnDcom-es-es-rpp-c_OZ.js → CreatedOnDcom-es-es-Zf4nkMz4.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-ca-MJ7nCJTH.js → CreatedOnDcom-fr-ca-CX-t8NIu.js} +1 -1
- package/lib/src/{CreatedOnDcom-fr-fr-B3USPvBZ.js → CreatedOnDcom-fr-fr-CW39zzHY.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-br-DJv7sfEZ.js → CreatedOnDcom-pt-br-psDhvZVE.js} +1 -1
- package/lib/src/{CreatedOnDcom-pt-pt-DAPP7A-E.js → CreatedOnDcom-pt-pt-BYiOQUu2.js} +1 -1
- package/lib/src/composables/useSnapshot.js +18 -18
- package/lib/src/index.mjs +1 -1
- package/lib/src/{lib-Cfx4mNMR.js → lib-R0RAe3pD.js} +10987 -10968
- package/lib/src/metadata-builder/ai-metadata-executor.js +1 -0
- package/lib/src/metadata-builder/builders/footer-builder.js +103 -70
- package/lib/src/metadata-builder/builders/section-builders/move-section-builder.d.ts +16 -1
- package/lib/src/metadata-builder/builders/section-builders/move-section-builder.js +48 -26
- package/lib/src/metadata-builder/builders/section-field-utils.d.ts +7 -0
- package/lib/src/metadata-builder/builders/section-field-utils.js +1 -1
- package/lib/src/metadata-builder/parsers/ai-toolcall-parser.d.ts +10 -4
- package/package.json +1 -1
- package/src/composables/useSnapshot.ts +19 -22
- package/src/metadata-builder/ai-metadata-executor.ts +1 -0
- package/src/metadata-builder/builders/footer-builder.test.ts +200 -1
- package/src/metadata-builder/builders/footer-builder.ts +151 -95
- package/src/metadata-builder/builders/section-builders/move-section-builder.ts +76 -30
- package/src/metadata-builder/builders/section-field-utils.ts +1 -1
- package/src/metadata-builder/parsers/ai-toolcall-parser.ts +10 -4
|
@@ -131,13 +131,17 @@ export function useSnapshot() {
|
|
|
131
131
|
// the width crisp and let MAX_SNAPSHOT_HEIGHT bound the cost.
|
|
132
132
|
const captureWidth = target.clientWidth || target.offsetWidth || 1;
|
|
133
133
|
const scale = Math.min(1, SNAPSHOT_TARGET_WIDTH / captureWidth);
|
|
134
|
-
//
|
|
135
|
-
//
|
|
136
|
-
//
|
|
137
|
-
//
|
|
138
|
-
//
|
|
134
|
+
// Inline every shape's blob-backed SVG as a data: URI up front. Shapes
|
|
135
|
+
// (content + background) render their coloured SVG via an <img> whose src
|
|
136
|
+
// is a `blob:` URL from URL.createObjectURL. The owning component revokes
|
|
137
|
+
// that blob on re-render (colour/size/imageUrl change) and on unmount —
|
|
138
|
+
// exactly what an AI "change all my contents" run triggers right before we
|
|
139
|
+
// capture. html2canvas fetches each <img> src ASYNCHRONOUSLY while
|
|
140
|
+
// rendering, so a concurrent revoke leaves it fetching a dead blob URL →
|
|
141
|
+
// the shape 404s and snapshots blank. A data: URI can't be revoked, so
|
|
142
|
+
// swapping the blob for one in the clone removes the race.
|
|
139
143
|
const blobSvgUris = new Map();
|
|
140
|
-
const blobSources = Array.from(element.querySelectorAll('.c-shape-object
|
|
144
|
+
const blobSources = Array.from(element.querySelectorAll('.c-shape-object img')).map((img) => img.getAttribute('src'));
|
|
141
145
|
for (const src of blobSources) {
|
|
142
146
|
if (src && src.startsWith('blob:') && !blobSvgUris.has(src)) {
|
|
143
147
|
try {
|
|
@@ -245,19 +249,15 @@ export function useSnapshot() {
|
|
|
245
249
|
height: 'auto',
|
|
246
250
|
overflow: 'visible',
|
|
247
251
|
});
|
|
248
|
-
//
|
|
249
|
-
//
|
|
252
|
+
// Repoint each shape <img> from its (revocable) blob: src to the
|
|
253
|
+
// pre-fetched data: URI so html2canvas never fetches a blob that may
|
|
254
|
+
// have been revoked mid-capture.
|
|
250
255
|
_doc
|
|
251
|
-
.querySelectorAll('.c-shape-object
|
|
252
|
-
.forEach((
|
|
253
|
-
const
|
|
254
|
-
if (
|
|
255
|
-
|
|
256
|
-
img.src = blobSvgUris.get(dataUrl);
|
|
257
|
-
const style = obj.getAttribute('style');
|
|
258
|
-
if (style)
|
|
259
|
-
img.setAttribute('style', style);
|
|
260
|
-
obj.parentNode?.replaceChild(img, obj);
|
|
256
|
+
.querySelectorAll('.c-shape-object img')
|
|
257
|
+
.forEach((img) => {
|
|
258
|
+
const src = img.getAttribute('src');
|
|
259
|
+
if (src && blobSvgUris.has(src)) {
|
|
260
|
+
img.src = blobSvgUris.get(src);
|
|
261
261
|
}
|
|
262
262
|
});
|
|
263
263
|
// Replace object-fit images with a background-size div so they
|
package/lib/src/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as E, a as T, b as s, c as I, d as S, e as N, f as e, B as A, g as O, h as C, i as G, j as t, k as D, l as P, m as R, n as L, o as M, p as o, q as r, r as n, s as b, t as F, u as l, v as i, w as g, x as B, y as c, z as Y, C as U, D as d, E as u, F as H, G as p, H as y, I as K, J as k, K as m, L as V, M as X, N as v, O as h, P as W, Q as f, R as x, S as z, T as w, U as Z, V as j, W as q, X as Q, Y as J, Z as $, $ as aa, a0 as _a, a1 as Ea, a2 as Ta, a3 as sa, a4 as Ia, a5 as Sa, a6 as Na, a7 as ea, a8 as Aa, a9 as Oa, aa as Ca, ab as Ga, ac as ta, ad as Da, ae as Pa, af as Ra, ag as La, ah as Ma, ai as oa, aj as ra, ak as na, al as ba, am as Fa, an as la, ao as ia, ap as ga, aq as Ba, ar as ca, as as Ya, at as Ua, au as da, av as ua, aw as Ha, ax as pa, ay as ya, az as Ka, aA as ka, aB as ma, aC as Va, aD as Xa, aE as va, aF as ha, aG as Wa, aH as fa, aI as xa, aJ as za, aK as wa, aL as Za, aM as ja, aN as qa, aO as Qa, aP as Ja, aQ as $a, aR as a_, aS as __, aT as E_, aU as T_, aV as s_, aW as I_, aX as S_, aY as N_, aZ as e_, a_ as A_, a$ as O_, b0 as C_, b1 as G_, b2 as t_, b3 as D_, b4 as P_, b5 as R_, b6 as L_, b7 as M_, b8 as o_, b9 as r_, ba as n_, bb as b_, bc as F_, bd as l_, be as i_, bf as g_, bg as B_, bh as c_, bi as Y_, bj as U_, bk as d_, bl as u_, bm as H_, bn as p_, bo as y_, bp as K_, bq as k_, br as m_, bs as V_, bt as X_, bu as v_, bv as h_, bw as W_, bx as f_, by as x_, bz as z_, bA as w_, bB as Z_, bC as j_, bD as q_, bE as Q_, bF as J_, bG as $_, bH as aE, bI as _E, bJ as EE, bK as TE, bL as sE, bM as IE, bN as SE, bO as NE, bP as eE, bQ as AE, bR as OE, bS as CE, bT as GE, bU as tE, bV as DE, bW as PE, bX as RE, bY as LE, bZ as ME, b_ as oE, b$ as rE, c0 as nE, c1 as bE, c2 as FE, c3 as lE, c4 as iE, c5 as gE, c6 as BE, c7 as cE, c8 as YE, c9 as UE, ca as dE, cb as uE, cc as HE, cd as pE, ce as yE, cf as KE, cg as kE, ch as mE, ci as VE, cj as XE, ck as vE, cl as hE, cm as WE, cn as fE, co as xE, cp as zE, cq as wE, cr as ZE } from "./lib-
|
|
1
|
+
import { A as E, a as T, b as s, c as I, d as S, e as N, f as e, B as A, g as O, h as C, i as G, j as t, k as D, l as P, m as R, n as L, o as M, p as o, q as r, r as n, s as b, t as F, u as l, v as i, w as g, x as B, y as c, z as Y, C as U, D as d, E as u, F as H, G as p, H as y, I as K, J as k, K as m, L as V, M as X, N as v, O as h, P as W, Q as f, R as x, S as z, T as w, U as Z, V as j, W as q, X as Q, Y as J, Z as $, $ as aa, a0 as _a, a1 as Ea, a2 as Ta, a3 as sa, a4 as Ia, a5 as Sa, a6 as Na, a7 as ea, a8 as Aa, a9 as Oa, aa as Ca, ab as Ga, ac as ta, ad as Da, ae as Pa, af as Ra, ag as La, ah as Ma, ai as oa, aj as ra, ak as na, al as ba, am as Fa, an as la, ao as ia, ap as ga, aq as Ba, ar as ca, as as Ya, at as Ua, au as da, av as ua, aw as Ha, ax as pa, ay as ya, az as Ka, aA as ka, aB as ma, aC as Va, aD as Xa, aE as va, aF as ha, aG as Wa, aH as fa, aI as xa, aJ as za, aK as wa, aL as Za, aM as ja, aN as qa, aO as Qa, aP as Ja, aQ as $a, aR as a_, aS as __, aT as E_, aU as T_, aV as s_, aW as I_, aX as S_, aY as N_, aZ as e_, a_ as A_, a$ as O_, b0 as C_, b1 as G_, b2 as t_, b3 as D_, b4 as P_, b5 as R_, b6 as L_, b7 as M_, b8 as o_, b9 as r_, ba as n_, bb as b_, bc as F_, bd as l_, be as i_, bf as g_, bg as B_, bh as c_, bi as Y_, bj as U_, bk as d_, bl as u_, bm as H_, bn as p_, bo as y_, bp as K_, bq as k_, br as m_, bs as V_, bt as X_, bu as v_, bv as h_, bw as W_, bx as f_, by as x_, bz as z_, bA as w_, bB as Z_, bC as j_, bD as q_, bE as Q_, bF as J_, bG as $_, bH as aE, bI as _E, bJ as EE, bK as TE, bL as sE, bM as IE, bN as SE, bO as NE, bP as eE, bQ as AE, bR as OE, bS as CE, bT as GE, bU as tE, bV as DE, bW as PE, bX as RE, bY as LE, bZ as ME, b_ as oE, b$ as rE, c0 as nE, c1 as bE, c2 as FE, c3 as lE, c4 as iE, c5 as gE, c6 as BE, c7 as cE, c8 as YE, c9 as UE, ca as dE, cb as uE, cc as HE, cd as pE, ce as yE, cf as KE, cg as kE, ch as mE, ci as VE, cj as XE, ck as vE, cl as hE, cm as WE, cn as fE, co as xE, cp as zE, cq as wE, cr as ZE } from "./lib-R0RAe3pD.js";
|
|
2
2
|
import { createPinia as qE, setActivePinia as QE } from "pinia";
|
|
3
3
|
export {
|
|
4
4
|
E as ABOUT_SECTION_SETTINGS_CONFIG,
|