@janbox/storefront-builder 2.0.26 → 2.0.27
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/README.md +44 -0
- package/dist/{composer-DBRKIqu7.js → composer-I1-nDI_3.js} +1 -1
- package/dist/editor.js +94 -93
- package/dist/index-BQy3TapM.js +4 -0
- package/dist/index.js +3 -3
- package/dist/templates.js +1 -1
- package/dist/theme.js +109 -0
- package/dist/{toaster-Bx7Helq-.js → toaster-DzezW7No.js} +546 -589
- package/package.json +5 -1
- package/dist/index-CpLNXUi2.js +0 -4
package/README.md
CHANGED
|
@@ -21,6 +21,7 @@ pnpm add react@^19 react-dom@^19 @janbox/storefront-ui@>=2
|
|
|
21
21
|
| `@janbox/storefront-builder` | Node components (33 nodes) |
|
|
22
22
|
| `@janbox/storefront-builder/editor` | Giao diện editor đầy đủ (`Editor` component + toolbars) |
|
|
23
23
|
| `@janbox/storefront-builder/templates` | Element groups và section templates có sẵn |
|
|
24
|
+
| `@janbox/storefront-builder/theme` | Design tokens (palette, text scale) dùng trong builder |
|
|
24
25
|
| `@janbox/storefront-builder/style.css` | CSS bundle (bắt buộc import) |
|
|
25
26
|
|
|
26
27
|
---
|
|
@@ -403,6 +404,49 @@ type Theme = {
|
|
|
403
404
|
|
|
404
405
|
---
|
|
405
406
|
|
|
407
|
+
## Builder Theme (Design Tokens)
|
|
408
|
+
|
|
409
|
+
Ngoài theme của `@janbox/storefront-ui` (truyền vào `Editor`), builder cũng export bộ design tokens nội bộ dùng cho styling:
|
|
410
|
+
|
|
411
|
+
```ts
|
|
412
|
+
import { palette, text, theme } from '@janbox/storefront-builder/theme';
|
|
413
|
+
```
|
|
414
|
+
|
|
415
|
+
### `palette`
|
|
416
|
+
|
|
417
|
+
Bảng màu nội bộ của builder — dùng cho UI editor và có thể tái sử dụng trong custom toolbar/component:
|
|
418
|
+
|
|
419
|
+
```ts
|
|
420
|
+
palette.primary['5s'] // '#597ef7'
|
|
421
|
+
palette.ink['6s'] // '#333333'
|
|
422
|
+
palette.red['4s'] // '#ff7875'
|
|
423
|
+
```
|
|
424
|
+
|
|
425
|
+
### `text`
|
|
426
|
+
|
|
427
|
+
Text scale (font size + line height) theo các cấp từ `xs` đến `9xl`:
|
|
428
|
+
|
|
429
|
+
```ts
|
|
430
|
+
text.sm // { fontSize: '0.875rem', lineHeight: '1.25rem' }
|
|
431
|
+
text.base // { fontSize: '1rem', lineHeight: '1.5rem' }
|
|
432
|
+
text['2xl'] // { fontSize: '1.5rem', lineHeight: '2rem' }
|
|
433
|
+
```
|
|
434
|
+
|
|
435
|
+
### `theme`
|
|
436
|
+
|
|
437
|
+
Object tổng hợp `{ palette, text }` — tiện khi cần truyền cả hai:
|
|
438
|
+
|
|
439
|
+
```ts
|
|
440
|
+
import { theme } from '@janbox/storefront-builder/theme';
|
|
441
|
+
|
|
442
|
+
theme.palette.blue['6s'] // '#0f62fe'
|
|
443
|
+
theme.text.lg // { fontSize: '1.125rem', lineHeight: '1.75rem' }
|
|
444
|
+
```
|
|
445
|
+
|
|
446
|
+
> **Lưu ý:** Đây là design tokens của builder UI, khác với prop `theme` (kiểu `Theme` của `@janbox/storefront-ui`) truyền vào `Editor` để theming storefront.
|
|
447
|
+
|
|
448
|
+
---
|
|
449
|
+
|
|
406
450
|
## TypeScript
|
|
407
451
|
|
|
408
452
|
Package đi kèm đầy đủ file `.d.ts`. Các type chính:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as i } from "@emotion/react/jsx-runtime";
|
|
2
2
|
import { useMemo as m, useEffect as f } from "react";
|
|
3
|
-
import { u as c, C as v, D as p, a as N, d as h, N as E, g as b, r as D, b as y, B as l } from "./toaster-
|
|
3
|
+
import { u as c, C as v, D as p, a as N, d as h, N as E, g as b, r as D, b as y, B as l } from "./toaster-DzezW7No.js";
|
|
4
4
|
import { isNil as u, isString as d } from "lodash-es";
|
|
5
5
|
import "flat";
|
|
6
6
|
const k = ({ children: t, data: e }) => {
|
package/dist/editor.js
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { jsxs as b, jsx as r, Fragment as ct } from "@emotion/react/jsx-runtime";
|
|
2
|
-
import { aA as zt, aB as
|
|
3
|
-
import {
|
|
2
|
+
import { aA as zt, aB as I, aC as Pe, aD as we, ax as _t, aE as Gt, aF as U, b as Ye, B as Ze, a5 as Ut, aG as ae, aH as dt, aI as Yt, aJ as A, az as ht, ay as Zt, aK as Xt, aL as qt, aM as Jt, aN as Kt, aO as Qt, aP as er, aQ as tr, aR as rr, aS as nr, aT as or, aU as sr, aV as ir, u as G, aW as ar, aX as lr, aY as me, m as cr, i as dr, G as hr, l as Xe, p as ur, F as qe, t as pr, Y as gr, I as fr, aZ as br, s as wr, P as mr, a_ as ut, a$ as Be, b0 as kr, b1 as vr, b2 as Cr, b3 as xr, b4 as yr, b5 as X, b6 as pt, b7 as Tr, b8 as Sr, b9 as Ir, ba as Mr, bb as Er, a4 as gt, a0 as ft, bc as Je, bd as Lr, be as Rr, N as je, bf as Wr, bg as Nr, bh as Ar, a2 as Dr, bi as Ke, bj as Pr } from "./toaster-DzezW7No.js";
|
|
3
|
+
import { bk as Xo, bl as qo, bm as Jo, bn as Ko, bo as Qo, bp as es, bq as ts, br as rs, bs as ns, bt as os, bu as ss, bv as is, bw as as, bx as ls, by as cs, bz as ds, bA as hs, bB as us, bC as ps, bD as gs, bE as fs, bF as bs, bG as ws, bH as ms, bI as ks, bJ as vs, bK as Cs, bL as xs, bM as ys, bN as Ts, bO as Ss, bP as Is, bQ as Ms, bR as Es, bS as Ls, bT as Rs, bU as Ws, bV as Ns, bW as As, bX as Ds, bY as Ps, bZ as Bs, b_ as js, b$ as Vs, c0 as Os, c1 as Fs, c2 as $s, c3 as Hs, c4 as zs, c5 as _s, c6 as Gs, c7 as Us, c8 as Ys, c9 as Zs, ca as Xs, cb as qs, cc as Js, cd as Ks, W as Qs, ce as ei, cf as ti, cg as ri, ch as ni, ci as oi } from "./toaster-DzezW7No.js";
|
|
4
4
|
import { isNil as $, isUndefined as Br, throttle as jr, isFunction as Qe, isNumber as ke, isEqual as Vr } from "lodash-es";
|
|
5
5
|
import { useState as j, useCallback as oe, useMemo as et, Fragment as J, isValidElement as Or, useRef as K, useEffect as z, Suspense as Fr, createElement as bt } from "react";
|
|
6
6
|
import "flat";
|
|
7
|
-
import { FLOATING_Z_INDEX as
|
|
7
|
+
import { FLOATING_Z_INDEX as We, ThemeProvider as $r, breakpoint as Hr, createTheme as tt } from "@janbox/storefront-ui/theme";
|
|
8
8
|
import { useControllableState as rt } from "@janbox/storefront-ui/hooks";
|
|
9
|
+
import { theme as c, palette as Ne, text as le } from "./theme.js";
|
|
9
10
|
import { CacheProvider as zr, Global as _r, createElement as Gr } from "@emotion/react";
|
|
10
11
|
import { useFloating as Ce, autoUpdate as xe, flip as Ve, offset as wt, size as mt, useClick as Ur, useDismiss as kt, useRole as vt, useInteractions as Ct, FloatingPortal as ce, useHover as Yr, safePolygon as Zr, useFocus as Xr } from "@floating-ui/react";
|
|
11
12
|
import "react-colorful";
|
|
@@ -13,7 +14,7 @@ import "overlayscrollbars-react";
|
|
|
13
14
|
import "@tanstack/react-virtual";
|
|
14
15
|
import qr, { useFrame as Oe } from "react-frame-component";
|
|
15
16
|
import "react-dropzone";
|
|
16
|
-
import { a as xt, C as Jr } from "./composer-
|
|
17
|
+
import { a as xt, C as Jr } from "./composer-I1-nDI_3.js";
|
|
17
18
|
import "@janbox/storefront-ui/utils";
|
|
18
19
|
import "@janbox/storefront-ui";
|
|
19
20
|
class Kr {
|
|
@@ -53,7 +54,7 @@ const Qr = () => new Kr();
|
|
|
53
54
|
function en() {
|
|
54
55
|
return zt(Qr);
|
|
55
56
|
}
|
|
56
|
-
const
|
|
57
|
+
const jo = (e) => {
|
|
57
58
|
const {
|
|
58
59
|
innerRef: t,
|
|
59
60
|
placement: o = "bottom-start",
|
|
@@ -131,7 +132,7 @@ const Bo = (e) => {
|
|
|
131
132
|
mt({
|
|
132
133
|
apply({ elements: k }) {
|
|
133
134
|
const { width: S } = k.reference.getBoundingClientRect(), E = n === "fit-parent" ? S : n, H = {
|
|
134
|
-
zIndex:
|
|
135
|
+
zIndex: We
|
|
135
136
|
};
|
|
136
137
|
Br(E) || (H.minWidth = `${E}px`), Object.assign(k.floating.style, H);
|
|
137
138
|
}
|
|
@@ -261,7 +262,7 @@ const Bo = (e) => {
|
|
|
261
262
|
css: { borderRadius: 8, backgroundColor: c.palette.ink["6s"] },
|
|
262
263
|
style: {
|
|
263
264
|
...Pt,
|
|
264
|
-
zIndex:
|
|
265
|
+
zIndex: We
|
|
265
266
|
},
|
|
266
267
|
...Ft(),
|
|
267
268
|
children: /* @__PURE__ */ r(
|
|
@@ -298,10 +299,10 @@ const Bo = (e) => {
|
|
|
298
299
|
}
|
|
299
300
|
) })
|
|
300
301
|
] });
|
|
301
|
-
},
|
|
302
|
+
}, Vo = () => Gt(), Oo = ({ required: e, children: t, ...o }) => /* @__PURE__ */ b("div", { css: { marginBottom: 6, display: "flex", width: "fit-content" }, ...o, children: [
|
|
302
303
|
Or(t) ? t : /* @__PURE__ */ r("label", { children: t }),
|
|
303
304
|
e && /* @__PURE__ */ r("span", { css: { color: c.palette.red["6s"] }, children: " *" })
|
|
304
|
-
] }),
|
|
305
|
+
] }), Fo = () => {
|
|
305
306
|
const [e, t] = j(0), [o, n] = j(!1), i = K(null), s = (f, u) => {
|
|
306
307
|
if (!i.current) return 0;
|
|
307
308
|
const p = i.current.getBoundingClientRect(), a = p.left + p.width / 2, w = p.top + p.height / 2, m = f - a, g = u - w;
|
|
@@ -1004,7 +1005,7 @@ const Rt = ({ children: e, viewport: t, containerProps: o }) => {
|
|
|
1004
1005
|
return n.current && g.observe(n.current), () => g.disconnect();
|
|
1005
1006
|
}, []);
|
|
1006
1007
|
const l = Qe(t?.width) ? t.width(s.width) : t?.width, h = Qe(t?.height) ? t.height(s.height) : t?.height, f = ke(l) ? s.width / l : 1, u = ke(h) ? s.height / h : 1, p = Math.min(f, u, 1), a = (h ?? s.height / p) || 0, w = (l ?? s.width / p) || 0;
|
|
1007
|
-
return /* @__PURE__ */ r("div", { ...o, css: { padding: 8, width: "100%", height: "100%", backgroundColor:
|
|
1008
|
+
return /* @__PURE__ */ r("div", { ...o, css: { padding: 8, width: "100%", height: "100%", backgroundColor: Ne.ink["1s"] }, children: /* @__PURE__ */ r("div", { css: { position: "relative", overflow: "hidden", width: "100%", height: "100%" }, ref: n, children: /* @__PURE__ */ r(
|
|
1008
1009
|
"div",
|
|
1009
1010
|
{
|
|
1010
1011
|
style: {
|
|
@@ -1079,7 +1080,7 @@ const Nn = [
|
|
|
1079
1080
|
value: 1
|
|
1080
1081
|
/* Unitless */
|
|
1081
1082
|
}
|
|
1082
|
-
],
|
|
1083
|
+
], $o = ({ name: e, responsive: t = !0, value: o, onChange: n }) => {
|
|
1083
1084
|
const i = ke(o?.lineHeight) ? _.Unitless : _.Pixels, s = i === _.Unitless ? 0.1 : 1, d = Ut(o?.lineHeight, "float"), l = ({ unit: a, value: w }) => {
|
|
1084
1085
|
if ($(w)) {
|
|
1085
1086
|
n?.({
|
|
@@ -1156,7 +1157,7 @@ const Nn = [
|
|
|
1156
1157
|
label: "Inline Grid",
|
|
1157
1158
|
value: "inline-grid"
|
|
1158
1159
|
}
|
|
1159
|
-
],
|
|
1160
|
+
], Ho = ({
|
|
1160
1161
|
name: e,
|
|
1161
1162
|
responsive: t = !1,
|
|
1162
1163
|
availableDisplays: o,
|
|
@@ -1179,7 +1180,7 @@ const Nn = [
|
|
|
1179
1180
|
onChange: d
|
|
1180
1181
|
}
|
|
1181
1182
|
) });
|
|
1182
|
-
},
|
|
1183
|
+
}, zo = ({ value: e, onChange: t, name: o, responsive: n = !1 }) => {
|
|
1183
1184
|
const i = {
|
|
1184
1185
|
flexBasis: e?.flexBasis ?? "auto",
|
|
1185
1186
|
flexGrow: e?.flexGrow ?? 0,
|
|
@@ -1217,7 +1218,7 @@ const Nn = [
|
|
|
1217
1218
|
},
|
|
1218
1219
|
h.value
|
|
1219
1220
|
)) }) });
|
|
1220
|
-
},
|
|
1221
|
+
}, _o = ({ name: e, value: t, onChange: o, responsive: n = !0 }) => {
|
|
1221
1222
|
const i = K(null), s = (d) => {
|
|
1222
1223
|
o?.({
|
|
1223
1224
|
minWidth: d
|
|
@@ -1236,7 +1237,7 @@ const Nn = [
|
|
|
1236
1237
|
}
|
|
1237
1238
|
}
|
|
1238
1239
|
) }) });
|
|
1239
|
-
},
|
|
1240
|
+
}, Go = ({ value: e, onChange: t }) => {
|
|
1240
1241
|
const [o, n] = j(!1), i = (d) => {
|
|
1241
1242
|
t?.({ ...e, sizeVariant: d });
|
|
1242
1243
|
}, s = (d) => {
|
|
@@ -1676,7 +1677,7 @@ const Nn = [
|
|
|
1676
1677
|
mt({
|
|
1677
1678
|
apply({ elements: w }) {
|
|
1678
1679
|
const m = {
|
|
1679
|
-
zIndex: `${
|
|
1680
|
+
zIndex: `${We}`,
|
|
1680
1681
|
height: `${w.reference.getBoundingClientRect().height}px`
|
|
1681
1682
|
};
|
|
1682
1683
|
Object.assign(w.floating.style, m);
|
|
@@ -2384,7 +2385,7 @@ const Nn = [
|
|
|
2384
2385
|
/* @__PURE__ */ r(Ar, {})
|
|
2385
2386
|
]
|
|
2386
2387
|
}
|
|
2387
|
-
),
|
|
2388
|
+
), Uo = ({
|
|
2388
2389
|
theme: e,
|
|
2389
2390
|
insert: t,
|
|
2390
2391
|
resolver: o,
|
|
@@ -2411,8 +2412,8 @@ const Nn = [
|
|
|
2411
2412
|
flexDirection: "column",
|
|
2412
2413
|
width: "100vw",
|
|
2413
2414
|
height: "100vh",
|
|
2414
|
-
backgroundColor:
|
|
2415
|
-
color:
|
|
2415
|
+
backgroundColor: Ne.ink["6s"],
|
|
2416
|
+
color: Ne.white["6s"],
|
|
2416
2417
|
...le.xs
|
|
2417
2418
|
},
|
|
2418
2419
|
children: [
|
|
@@ -2436,85 +2437,85 @@ const Nn = [
|
|
|
2436
2437
|
] });
|
|
2437
2438
|
};
|
|
2438
2439
|
export {
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2440
|
+
Xo as AspectRatioToolbar,
|
|
2441
|
+
qo as BackgroundToolbar,
|
|
2442
|
+
Jo as BorderRadiusToolbar,
|
|
2443
|
+
Ko as BorderToolbar,
|
|
2444
|
+
Qo as ChildNodesToolbar,
|
|
2445
|
+
es as ColorPickerContent,
|
|
2445
2446
|
Je as ColorPickerPopover,
|
|
2446
|
-
|
|
2447
|
+
ts as ColorPreview,
|
|
2447
2448
|
nr as ColorToolbar,
|
|
2448
|
-
|
|
2449
|
-
|
|
2449
|
+
rs as ColorVariantToolbar,
|
|
2450
|
+
ns as ColumnGapToolbar,
|
|
2450
2451
|
sr as CssFontWeightToolbar,
|
|
2451
2452
|
qt as CssSizeInput,
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2460
|
-
|
|
2453
|
+
os as CssTextAlignToolbar,
|
|
2454
|
+
ss as CssWidthToolbar,
|
|
2455
|
+
Fo as DegreePicker,
|
|
2456
|
+
Ho as DisplayToolbar,
|
|
2457
|
+
Uo as Editor,
|
|
2458
|
+
is as FlexAlignItemsToolbar,
|
|
2459
|
+
zo as FlexToolbar,
|
|
2460
|
+
as as FlexWrapToolbar,
|
|
2461
|
+
ls as FontSizeToolbar,
|
|
2461
2462
|
Rt as FramePreview,
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
|
|
2467
|
-
|
|
2468
|
-
|
|
2469
|
-
|
|
2470
|
-
|
|
2471
|
-
|
|
2472
|
-
|
|
2473
|
-
|
|
2463
|
+
cs as GridAlignItemsToolbar,
|
|
2464
|
+
ds as HeightToolbar,
|
|
2465
|
+
hs as HtmlAnchorTargetToolbar,
|
|
2466
|
+
us as ImageGalleryDialog,
|
|
2467
|
+
ps as ImageSourceSelection,
|
|
2468
|
+
gs as InsertInlineToolbar,
|
|
2469
|
+
fs as InsertLinkToolbar,
|
|
2470
|
+
bs as JustifyContentToolbar,
|
|
2471
|
+
ws as JustifyItemsToolbar,
|
|
2472
|
+
$o as LineHeightToolbar,
|
|
2473
|
+
ms as MarginToolbar,
|
|
2474
|
+
_o as MinWidthToolbar,
|
|
2474
2475
|
Ar as NodeDeleteToolbar,
|
|
2475
2476
|
Wr as NodeDragToolbar,
|
|
2476
2477
|
Nr as NodeNameToolbar,
|
|
2477
|
-
|
|
2478
|
-
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2478
|
+
ks as NumberField,
|
|
2479
|
+
vs as NumberFieldMixOptions,
|
|
2480
|
+
Cs as ObjectFitToolbar,
|
|
2481
|
+
xs as OrderToolbar,
|
|
2482
|
+
ys as PaddingToolbar,
|
|
2483
|
+
Ts as RowGapToolbar,
|
|
2484
|
+
Ss as SvgSourceToolbar,
|
|
2485
|
+
Is as TagNameToolbar,
|
|
2485
2486
|
rr as TextSizeVariantToolbar,
|
|
2486
|
-
|
|
2487
|
+
Go as TextStyleGroupToolbar,
|
|
2487
2488
|
or as TextStyleToolbar,
|
|
2488
2489
|
ir as TextTransformToolbar,
|
|
2489
2490
|
ae as ToolbarField,
|
|
2490
|
-
|
|
2491
|
-
|
|
2491
|
+
Ms as ToolbarGroup,
|
|
2492
|
+
Es as VisibilityToolbar,
|
|
2492
2493
|
me as WbButton,
|
|
2493
2494
|
ar as WbButtonGroup,
|
|
2494
|
-
|
|
2495
|
+
jo as WbCascader,
|
|
2495
2496
|
Tr as WbCollapse,
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
|
|
2508
|
-
|
|
2497
|
+
Ls as WbColorPicker,
|
|
2498
|
+
Rs as WbDatePicker,
|
|
2499
|
+
Ws as WbDialog,
|
|
2500
|
+
Ns as WbDialogBody,
|
|
2501
|
+
As as WbDialogClose,
|
|
2502
|
+
Ds as WbDialogFooter,
|
|
2503
|
+
Ps as WbDialogHeader,
|
|
2504
|
+
Bs as WbDropzone,
|
|
2505
|
+
js as WbFloating,
|
|
2506
|
+
Vs as WbFloatingClose,
|
|
2507
|
+
Os as WbFloatingContent,
|
|
2508
|
+
Fs as WbFloatingContext,
|
|
2509
|
+
Oo as WbFormLabel,
|
|
2509
2510
|
I as WbIcon,
|
|
2510
2511
|
A as WbIconButton,
|
|
2511
2512
|
ut as WbInput,
|
|
2512
2513
|
Yt as WbInputNumber,
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2514
|
+
$s as WbLoadingOverlay,
|
|
2515
|
+
Hs as WbMenu,
|
|
2516
|
+
zs as WbMenuItem,
|
|
2517
|
+
_s as WbMenuList,
|
|
2518
|
+
Gs as WbMenuTrigger,
|
|
2518
2519
|
Jt as WbPopover,
|
|
2519
2520
|
tr as WbPopoverClose,
|
|
2520
2521
|
er as WbPopoverContent,
|
|
@@ -2523,20 +2524,20 @@ export {
|
|
|
2523
2524
|
Be as WbScrollView,
|
|
2524
2525
|
Xt as WbSelect,
|
|
2525
2526
|
Sr as WbSvgLoader,
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2527
|
+
Us as WbSwitch,
|
|
2528
|
+
Ys as WbTab,
|
|
2529
|
+
Zs as WbTabContent,
|
|
2530
|
+
Xs as WbTabList,
|
|
2531
|
+
qs as WbTabPanel,
|
|
2532
|
+
Js as WbTabs,
|
|
2533
|
+
Ks as WbTextarea,
|
|
2534
|
+
Qs as WbTooltip,
|
|
2535
|
+
ei as WbVirtualizedList,
|
|
2536
|
+
ti as pushToast,
|
|
2537
|
+
ri as textSizeVariantOptions,
|
|
2538
|
+
Vo as useDialogContext,
|
|
2538
2539
|
U as useEditor,
|
|
2539
|
-
|
|
2540
|
-
|
|
2540
|
+
ni as useEditorResponsive,
|
|
2541
|
+
oi as useInlineEditable,
|
|
2541
2542
|
Gt as useWbFloatingContext
|
|
2542
2543
|
};
|
package/dist/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { N as n, c as t } from "./toaster-
|
|
2
|
-
import { A as I, e as L, f as T, h as x, i as R, j as S, k as w, l as A, m as E, n as h, o as F, F as U, p as k, q, G as B, H as G, s as H, I as M, t as y, v as V, L as j, w as D, M as z, x as J, y as K, P as O, R as Q, z as X, E as Y, S as Z, J as _, T as $, K as W, O as ee, Q as oe, U as se, V as ae, X as re, Y as de, Z as te, _ as ne, $ as Ne, a0 as ue, a1 as ie, a2 as pe, g as me, a3 as Pe, a4 as ce, a5 as le, a6 as ge, a7 as be, a8 as fe, a9 as ve, aa as Ce, ab as Ie, ac as Le, ad as Te, u as xe, ae as Re, af as Se, ag as we, ah as Ae, ai as Ee, aj as he, ak as Fe, al as Ue, am as ke, an as qe, ao as Be, ap as Ge, aq as He, ar as Me, as as ye, at as Ve, au as je, av as De, aw as ze } from "./toaster-
|
|
1
|
+
import { N as n, c as t } from "./toaster-DzezW7No.js";
|
|
2
|
+
import { A as I, e as L, f as T, h as x, i as R, j as S, k as w, l as A, m as E, n as h, o as F, F as U, p as k, q, G as B, H as G, s as H, I as M, t as y, v as V, L as j, w as D, M as z, x as J, y as K, P as O, R as Q, z as X, E as Y, S as Z, J as _, T as $, K as W, O as ee, Q as oe, U as se, V as ae, X as re, Y as de, Z as te, _ as ne, $ as Ne, a0 as ue, a1 as ie, a2 as pe, g as me, a3 as Pe, a4 as ce, a5 as le, a6 as ge, a7 as be, a8 as fe, a9 as ve, aa as Ce, ab as Ie, ac as Le, ad as Te, u as xe, ae as Re, af as Se, ag as we, ah as Ae, ai as Ee, aj as he, ak as Fe, al as Ue, am as ke, an as qe, ao as Be, ap as Ge, aq as He, ar as Me, as as ye, at as Ve, au as je, av as De, aw as ze } from "./toaster-DzezW7No.js";
|
|
3
3
|
import "lodash-es";
|
|
4
4
|
import { useRef as N, useEffect as u } from "react";
|
|
5
5
|
import { getTabPanelProps as i, getListItemProps as p } from "@janbox/storefront-ui";
|
|
6
|
-
import { C as Ke, a as Oe } from "./composer-
|
|
6
|
+
import { C as Ke, a as Oe } from "./composer-I1-nDI_3.js";
|
|
7
7
|
const g = ({ enabled: a, onChange: r }) => {
|
|
8
8
|
const { dom: e } = n((s) => ({ dom: s.dom })), o = N(void 0);
|
|
9
9
|
u(() => {
|
package/dist/templates.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e, jsxs as o } from "@emotion/react/jsx-runtime";
|
|
2
2
|
import { getColorVar as t } from "@janbox/storefront-ui/theme";
|
|
3
|
-
import { m, G as d, l as n, p as y, F as u, z as B, P as i, s as r, i as g, I as v, ax as k, j as f, t as p, x as V, M as b, e as T, ay as R, az as w, f as s, h as l, A as c, n as A } from "./toaster-
|
|
3
|
+
import { m, G as d, l as n, p as y, F as u, z as B, P as i, s as r, i as g, I as v, ax as k, j as f, t as p, x as V, M as b, e as T, ay as R, az as w, f as s, h as l, A as c, n as A } from "./toaster-DzezW7No.js";
|
|
4
4
|
import "lodash-es";
|
|
5
5
|
import "react";
|
|
6
6
|
import "flat";
|
package/dist/theme.js
ADDED
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
const f = {
|
|
2
|
+
light: "#f9f9f9",
|
|
3
|
+
primary: {
|
|
4
|
+
"1s": "#f0f5ff",
|
|
5
|
+
"2s": "#d6e4ff",
|
|
6
|
+
"3s": "#adc6ff",
|
|
7
|
+
"4s": "#85a5ff",
|
|
8
|
+
"5s": "#597ef7",
|
|
9
|
+
"6s": "#1d39c4",
|
|
10
|
+
"7s": "#10239e"
|
|
11
|
+
},
|
|
12
|
+
red: {
|
|
13
|
+
"1s": "#fff1f0",
|
|
14
|
+
"2s": "#ffccc7",
|
|
15
|
+
"3s": "#ffa39e",
|
|
16
|
+
"4s": "#ff7875",
|
|
17
|
+
"5s": "#ff4d4f",
|
|
18
|
+
"6s": "#f5222d",
|
|
19
|
+
"7s": "#cf1322"
|
|
20
|
+
},
|
|
21
|
+
orange: {
|
|
22
|
+
"1s": "#fff7e6",
|
|
23
|
+
"2s": "#ffe7ba",
|
|
24
|
+
"3s": "#ffd591",
|
|
25
|
+
"4s": "#ffc069",
|
|
26
|
+
"5s": "#ffa940",
|
|
27
|
+
"6s": "#fa8c16",
|
|
28
|
+
"7s": "#d46b08"
|
|
29
|
+
},
|
|
30
|
+
yellow: {
|
|
31
|
+
"1s": "#feffe6",
|
|
32
|
+
"2s": "#ffffb8",
|
|
33
|
+
"3s": "#fffb8f",
|
|
34
|
+
"4s": "#fff566",
|
|
35
|
+
"5s": "#ffec3d",
|
|
36
|
+
"6s": "#fadb14",
|
|
37
|
+
"7s": "#e7c801"
|
|
38
|
+
},
|
|
39
|
+
green: {
|
|
40
|
+
"1s": "#f6ffed",
|
|
41
|
+
"2s": "#d9f7be",
|
|
42
|
+
"3s": "#b7eb8f",
|
|
43
|
+
"4s": "#95de64",
|
|
44
|
+
"5s": "#73d13d",
|
|
45
|
+
"6s": "#389e0d",
|
|
46
|
+
"7s": "#237804"
|
|
47
|
+
},
|
|
48
|
+
blue: {
|
|
49
|
+
"1s": "#e6f3ff",
|
|
50
|
+
"2s": "#b3d7ff",
|
|
51
|
+
"3s": "#8abeff",
|
|
52
|
+
"4s": "#61a3ff",
|
|
53
|
+
"5s": "#3884ff",
|
|
54
|
+
"6s": "#0f62fe",
|
|
55
|
+
"7s": "#0958d9"
|
|
56
|
+
},
|
|
57
|
+
violet: {
|
|
58
|
+
"1s": "#f9f0ff",
|
|
59
|
+
"2s": "#efdbff",
|
|
60
|
+
"3s": "#d3adf7",
|
|
61
|
+
"4s": "#b37feb",
|
|
62
|
+
"5s": "#9254de",
|
|
63
|
+
"6s": "#722ed1",
|
|
64
|
+
"7s": "#531dab"
|
|
65
|
+
},
|
|
66
|
+
ink: {
|
|
67
|
+
"1s": "#f2f2f2",
|
|
68
|
+
"2s": "#dddddd",
|
|
69
|
+
"3s": "#cccccc",
|
|
70
|
+
"4s": "#999999",
|
|
71
|
+
"5s": "#666666",
|
|
72
|
+
"6s": "#333333"
|
|
73
|
+
},
|
|
74
|
+
white: {
|
|
75
|
+
"1s": "rgba(255, 255, 255, 0.1)",
|
|
76
|
+
"2s": "rgba(255, 255, 255, 0.2)",
|
|
77
|
+
"3s": "rgba(255, 255, 255, 0.4)",
|
|
78
|
+
"4s": "rgba(255, 255, 255, 0.6)",
|
|
79
|
+
"5s": "rgba(255, 255, 255, 0.8)",
|
|
80
|
+
"6s": "rgba(255, 255, 255, 1)"
|
|
81
|
+
},
|
|
82
|
+
black: {
|
|
83
|
+
"1s": "rgba(51, 51, 51, 0.08)",
|
|
84
|
+
"2s": "rgba(51, 51, 51, 0.2)",
|
|
85
|
+
"3s": "rgba(51, 51, 51, 0.4)",
|
|
86
|
+
"4s": "rgba(51, 51, 51, 0.6)",
|
|
87
|
+
"5s": "rgba(51, 51, 51, 0.8)",
|
|
88
|
+
"7s": "rgba(0, 0, 0, 0.15)"
|
|
89
|
+
}
|
|
90
|
+
}, e = {
|
|
91
|
+
xs: { fontSize: "0.75rem", lineHeight: "1rem" },
|
|
92
|
+
sm: { fontSize: "0.875rem", lineHeight: "1.25rem" },
|
|
93
|
+
base: { fontSize: "1rem", lineHeight: "1.5rem" },
|
|
94
|
+
lg: { fontSize: "1.125rem", lineHeight: "1.75rem" },
|
|
95
|
+
xl: { fontSize: "1.25rem", lineHeight: "1.75rem" },
|
|
96
|
+
"2xl": { fontSize: "1.5rem", lineHeight: "2rem" },
|
|
97
|
+
"3xl": { fontSize: "1.875rem", lineHeight: "2.25rem" },
|
|
98
|
+
"4xl": { fontSize: "2.25rem", lineHeight: "2.5rem" },
|
|
99
|
+
"5xl": { fontSize: "3rem", lineHeight: "1" },
|
|
100
|
+
"6xl": { fontSize: "3.75rem", lineHeight: "1" },
|
|
101
|
+
"7xl": { fontSize: "4.5rem", lineHeight: "1" },
|
|
102
|
+
"8xl": { fontSize: "6rem", lineHeight: "1" },
|
|
103
|
+
"9xl": { fontSize: "8rem", lineHeight: "1" }
|
|
104
|
+
}, s = { palette: f, text: e };
|
|
105
|
+
export {
|
|
106
|
+
f as palette,
|
|
107
|
+
e as text,
|
|
108
|
+
s as theme
|
|
109
|
+
};
|