@snowcone-app/canvas 0.41.5 → 0.42.0
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/{CanvasStateV1-C9tFMK5q.js → CanvasStateV1-BQ3cbxt2.js} +3 -2
- package/dist/{CanvasStateV1-C9tFMK5q.js.map → CanvasStateV1-BQ3cbxt2.js.map} +1 -1
- package/dist/{EditorCanvasImpl-CKqnla_y.js → EditorCanvasImpl-VJ7kBhXB.js} +3 -3
- package/dist/{EditorCanvasImpl-CKqnla_y.js.map → EditorCanvasImpl-VJ7kBhXB.js.map} +1 -1
- package/dist/{SnowconeCanvas-BSFMazgl.js → SnowconeCanvas-BzOy46Yw.js} +2 -2
- package/dist/{SnowconeCanvas-BSFMazgl.js.map → SnowconeCanvas-BzOy46Yw.js.map} +1 -1
- package/dist/design/template-fields.d.ts +12 -0
- package/dist/{embed-KG_YnRHA.js → embed-5W-gg9dt.js} +4 -4
- package/dist/{embed-KG_YnRHA.js.map → embed-5W-gg9dt.js.map} +1 -1
- package/dist/embed.mjs +3 -3
- package/dist/index.mjs +3 -3
- package/dist/internals.mjs +1 -1
- package/dist/{template-fields-C0qoE_ZH.js → template-fields-CQURvcab.js} +67 -65
- package/dist/{template-fields-C0qoE_ZH.js.map → template-fields-CQURvcab.js.map} +1 -1
- package/example/package.json +1 -1
- package/package.json +2 -2
|
@@ -14,6 +14,18 @@ export interface TemplateTextField {
|
|
|
14
14
|
* `maxLength`); the canvas itself doesn't truncate.
|
|
15
15
|
*/
|
|
16
16
|
maxLength?: number;
|
|
17
|
+
/**
|
|
18
|
+
* How the buyer's text meets the element's box. `'shrink'`: the text is set at the element's own size and made
|
|
19
|
+
* smaller (never larger) until one line of it fits the element's box width, so a long name never runs past the
|
|
20
|
+
* design's edge. Applied by the personalization binder of `@snowcone-app/ui` (PersonalizationProvider). Absent: the
|
|
21
|
+
* text keeps the element's size and wraps or overflows as the element does.
|
|
22
|
+
*/
|
|
23
|
+
fit?: 'shrink';
|
|
24
|
+
/**
|
|
25
|
+
* The element's own text is a SAMPLE: it shows only until the buyer types into any field of the template; from then on
|
|
26
|
+
* this field draws exactly its box's text (nothing when empty). Applied by `@snowcone-app/ui`'s personalization binder.
|
|
27
|
+
*/
|
|
28
|
+
sample?: boolean;
|
|
17
29
|
/**
|
|
18
30
|
* Artboard (page) this field is scoped to, by artboard NAME — the same
|
|
19
31
|
* convention as the element `artboard` membership tag. In a multi-page
|
|
@@ -5,9 +5,9 @@ import { useContext as ct, createContext as ut, useRef as C, useState as D, useM
|
|
|
5
5
|
import { assertVariantSelected as ft, RenderSession as ht, createCartDetail as gt } from "@snowcone-app/sdk";
|
|
6
6
|
import { s as ee, B as yt, E as bt, v as vt, k as wt } from "./design-builder-BFM94eA9.js";
|
|
7
7
|
import { u as Et, p as kt } from "./usePieceGuideBundle-oBykb3X8.js";
|
|
8
|
-
import { D as xt, C as St, f as Rt, d as It } from "./template-fields-
|
|
8
|
+
import { D as xt, C as St, f as Rt, d as It } from "./template-fields-CQURvcab.js";
|
|
9
9
|
import "./ExportManager-9_RjQEv0.js";
|
|
10
|
-
import "./CanvasStateV1-
|
|
10
|
+
import "./CanvasStateV1-BQ3cbxt2.js";
|
|
11
11
|
const Be = ut(void 0);
|
|
12
12
|
function te() {
|
|
13
13
|
const e = ct(Be);
|
|
@@ -713,7 +713,7 @@ function qe(e) {
|
|
|
713
713
|
// wrapper, which had no DOM at all, stays layout-identical).
|
|
714
714
|
/* @__PURE__ */ g("div", { className: "sc-root", style: { display: "contents" }, "data-sc-part": "root", children: /* @__PURE__ */ g(Ft, { reportedError: l, onRetry: () => d(null), children: /* @__PURE__ */ g(Vt, { ...e, internals: a, recordAudit: x }) }) });
|
|
715
715
|
}
|
|
716
|
-
let Pt = () => import("./EditorCanvasImpl-
|
|
716
|
+
let Pt = () => import("./EditorCanvasImpl-VJ7kBhXB.js").then((e) => e.EditorCanvasImpl);
|
|
717
717
|
function ze() {
|
|
718
718
|
return Pt();
|
|
719
719
|
}
|
|
@@ -1910,4 +1910,4 @@ export {
|
|
|
1910
1910
|
te as u,
|
|
1911
1911
|
At as v
|
|
1912
1912
|
};
|
|
1913
|
-
//# sourceMappingURL=embed-
|
|
1913
|
+
//# sourceMappingURL=embed-5W-gg9dt.js.map
|