@kolkrabbi/design-editor 0.32.0 → 0.34.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/{Timeline-BKYyRqYg.js → Timeline-Cz-W72D0.js} +1 -1
- package/dist/{core-Cs-PEiuU.js → core-BeMuE9nC.js} +2376 -2355
- package/dist/core.js +3 -3
- package/dist/design-editor.css +1 -1
- package/dist/design-editor.js +52 -38
- package/dist/{effectCategories-BGIW_dEc.js → effectCategories-DV7i_AgK.js} +1 -1
- package/dist/{effects-RqPdJrRb.js → effects-Dn4_OzYx.js} +19 -17
- package/dist/effects.js +1 -1
- package/dist/{generators-BnuRmK-x.js → generators-XBzHN_kX.js} +34 -33
- package/dist/generators.js +1 -1
- package/dist/{host-DJ8bDKO7.js → host-B4QQewPr.js} +2 -2
- package/dist/{motion-DKZGyk14.js → motion-Cuwxm2ic.js} +25 -21
- package/dist/motion.js +1 -1
- package/dist/{store-D6Si8cRD.js → store-CF9s1Pb2.js} +417 -416
- package/dist/{useLayerEdit-BF9wI5pX.js → useLayerEdit-Cmtx3V3O.js} +20 -18
- package/package.json +11 -11
package/dist/design-editor.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { An as e, B as t, Bn as n, D as r, F as i, I as a, J as o, L as s, Lt as c, Mn as l, P as u, Vn as d, _n as f, a as p, d as m, f as h, ft as g, gt as _, ht as v, i as y, j as b, jn as x, kn as S, mn as C, n as w, nn as T, o as E, p as D, pn as O, r as ee, vn as k } from "./rolls-CEQmdcp3.js";
|
|
2
|
-
import { n as A, r as j, t as te } from "./useLayerEdit-
|
|
3
|
-
import { C as M, D as ne, E as N, _ as P, a as F, c as I, d as re, f as L, g as R, i as ie, l as ae, m as z, n as B, r as oe, t as se, u as ce, v as V, w as H, x as U, y as le } from "./effectCategories-
|
|
2
|
+
import { n as A, r as j, t as te } from "./useLayerEdit-Cmtx3V3O.js";
|
|
3
|
+
import { C as M, D as ne, E as N, _ as P, a as F, c as I, d as re, f as L, g as R, i as ie, l as ae, m as z, n as B, r as oe, t as se, u as ce, v as V, w as H, x as U, y as le } from "./effectCategories-DV7i_AgK.js";
|
|
4
4
|
import { r as ue } from "./TreePicker-1_NZG8GB.js";
|
|
5
|
-
import { _ as de, a as W, b as fe, f as pe, g as me, h as he, i as ge, m as _e, n as ve, o as ye, p as be, r as xe, s as Se, v as Ce, y as we } from "./generators-
|
|
6
|
-
import { A as Te, C as Ee, D as De, E as Oe, M as ke, O as Ae, S as je, T as Me, _ as Ne, b as Pe, c as Fe, h as Ie, j as Le, k as Re, l as ze, m as Be, u as Ve, v as He, w as Ue, y as We } from "./store-
|
|
5
|
+
import { _ as de, a as W, b as fe, f as pe, g as me, h as he, i as ge, m as _e, n as ve, o as ye, p as be, r as xe, s as Se, v as Ce, y as we } from "./generators-XBzHN_kX.js";
|
|
6
|
+
import { A as Te, C as Ee, D as De, E as Oe, M as ke, O as Ae, S as je, T as Me, _ as Ne, b as Pe, c as Fe, h as Ie, j as Le, k as Re, l as ze, m as Be, u as Ve, v as He, w as Ue, y as We } from "./store-CF9s1Pb2.js";
|
|
7
7
|
import { a as Ge, c as Ke, d as qe, f as Je, i as Ye, l as Xe, n as Ze, o as Qe, p as $e, r as et, s as G, t as tt, u as nt } from "./morphStore-B5081ohW.js";
|
|
8
8
|
import { n as rt, r as it, t as at } from "./BindDot-Don6fG00.js";
|
|
9
|
-
import { n as ot, r as st } from "./effects-
|
|
10
|
-
import { a as ct, i as lt, n as ut, o as dt, r as ft } from "./motion-
|
|
11
|
-
import { n as pt, r as mt, t as ht } from "./Timeline-
|
|
12
|
-
import { $ as gt, A as _t, B as vt, C as yt, D as bt, E as xt, F as St, G as Ct, H as wt, I as Tt, J as Et, K as Dt, L as Ot, M as kt, N as At, O as jt, P as Mt, Q as Nt, R as Pt, S as Ft, T as It, U as Lt, V as Rt, W as zt, X as Bt, Y as Vt, Z as Ht, _ as Ut, _t as Wt, a as Gt, at as Kt, b as qt, c as Jt, ct as Yt, d as Xt, dt as Zt, et as Qt, f as $t, ft as en, g as tn, gt as nn, h as rn, ht as an, i as on, it as sn, j as cn, k as ln, l as un, lt as dn, m as fn, mt as pn, n as mn, nt as hn, o as gn, ot as _n, p as vn, pt as yn, q as bn, r as xn, rt as Sn, s as Cn, st as wn, t as Tn, tt as En, u as Dn, ut as On, v as kn, vt as An, w as jn, x as Mn, y as Nn, z as Pn } from "./core-
|
|
13
|
-
import { Button as K, Divider as Fn, Dropdown as In, LabeledControlSection as
|
|
9
|
+
import { n as ot, r as st } from "./effects-Dn4_OzYx.js";
|
|
10
|
+
import { a as ct, i as lt, n as ut, o as dt, r as ft } from "./motion-Cuwxm2ic.js";
|
|
11
|
+
import { n as pt, r as mt, t as ht } from "./Timeline-Cz-W72D0.js";
|
|
12
|
+
import { $ as gt, A as _t, B as vt, C as yt, D as bt, E as xt, F as St, G as Ct, H as wt, I as Tt, J as Et, K as Dt, L as Ot, M as kt, N as At, O as jt, P as Mt, Q as Nt, R as Pt, S as Ft, T as It, U as Lt, V as Rt, W as zt, X as Bt, Y as Vt, Z as Ht, _ as Ut, _t as Wt, a as Gt, at as Kt, b as qt, c as Jt, ct as Yt, d as Xt, dt as Zt, et as Qt, f as $t, ft as en, g as tn, gt as nn, h as rn, ht as an, i as on, it as sn, j as cn, k as ln, l as un, lt as dn, m as fn, mt as pn, n as mn, nt as hn, o as gn, ot as _n, p as vn, pt as yn, q as bn, r as xn, rt as Sn, s as Cn, st as wn, t as Tn, tt as En, u as Dn, ut as On, v as kn, vt as An, w as jn, x as Mn, y as Nn, z as Pn } from "./core-BeMuE9nC.js";
|
|
13
|
+
import { Button as K, ButtonGroup as q, Divider as Fn, Dropdown as In, LabeledControlSection as J, MultiSelect as Ln, SettingsRow as Rn, StepList as zn, Tag as Bn, ToggleSwitch as Vn, Tooltip as Hn, useGrabEdge as Un, useMediaQuery as Wn, useModal as Gn } from "@kolkrabbi/kol-component";
|
|
14
14
|
import { createContext as Kn, useContext as qn, useEffect as Y, useRef as X, useState as Z, useSyncExternalStore as Jn } from "react";
|
|
15
15
|
import { Fragment as Yn, jsx as Q, jsxs as $ } from "react/jsx-runtime";
|
|
16
|
-
import {
|
|
16
|
+
import { IconLoader as Xn } from "@kolkrabbi/kol-icons";
|
|
17
17
|
import { AppFloatNav as Zn, DocumentCapsule as Qn, FloatLayout as $n, GlobalActions as er, PropertyRail as tr } from "@kolkrabbi/kol-shell";
|
|
18
18
|
import { useDragResize as nr, useTheme as rr } from "@kolkrabbi/kol-framework";
|
|
19
19
|
import { createPortal as ir } from "react-dom";
|
|
@@ -626,7 +626,8 @@ function Ar({ layer: e, readOnly: t = !1, editTabs: n = null }) {
|
|
|
626
626
|
}, [g]), /* @__PURE__ */ $("div", {
|
|
627
627
|
className: "flex flex-col gap-5",
|
|
628
628
|
children: [
|
|
629
|
-
/* @__PURE__ */ Q(
|
|
629
|
+
/* @__PURE__ */ Q(q, {
|
|
630
|
+
layout: "joined",
|
|
630
631
|
tone: "sunken",
|
|
631
632
|
value: d,
|
|
632
633
|
onChange: (e) => !t && G({ mode: e }),
|
|
@@ -634,7 +635,7 @@ function Ar({ layer: e, readOnly: t = !1, editTabs: n = null }) {
|
|
|
634
635
|
size: r,
|
|
635
636
|
className: a(r)
|
|
636
637
|
}),
|
|
637
|
-
!t && /* @__PURE__ */ Q(
|
|
638
|
+
!t && /* @__PURE__ */ Q(J, {
|
|
638
639
|
divided: !0,
|
|
639
640
|
children: /* @__PURE__ */ Q(ue, {
|
|
640
641
|
tree: _r(),
|
|
@@ -644,7 +645,7 @@ function Ar({ layer: e, readOnly: t = !1, editTabs: n = null }) {
|
|
|
644
645
|
onPick: br
|
|
645
646
|
})
|
|
646
647
|
}),
|
|
647
|
-
/* @__PURE__ */ $(
|
|
648
|
+
/* @__PURE__ */ $(J, {
|
|
648
649
|
divided: !0,
|
|
649
650
|
children: [
|
|
650
651
|
/* @__PURE__ */ Q(zn, {
|
|
@@ -675,11 +676,12 @@ function Ar({ layer: e, readOnly: t = !1, editTabs: n = null }) {
|
|
|
675
676
|
})
|
|
676
677
|
]
|
|
677
678
|
}),
|
|
678
|
-
m != null && !t && e && n && /* @__PURE__ */ $(
|
|
679
|
+
m != null && !t && e && n && /* @__PURE__ */ $(J, {
|
|
679
680
|
label: `Step ${m + 1}`,
|
|
680
681
|
divided: !0,
|
|
681
682
|
children: [
|
|
682
|
-
/* @__PURE__ */ Q(
|
|
683
|
+
/* @__PURE__ */ Q(q, {
|
|
684
|
+
layout: "joined",
|
|
683
685
|
tone: "sunken",
|
|
684
686
|
value: k,
|
|
685
687
|
onChange: j,
|
|
@@ -716,7 +718,7 @@ function Ar({ layer: e, readOnly: t = !1, editTabs: n = null }) {
|
|
|
716
718
|
},
|
|
717
719
|
inline: !0
|
|
718
720
|
}),
|
|
719
|
-
!t && c.length >= 2 && /* @__PURE__ */ Q(
|
|
721
|
+
!t && c.length >= 2 && /* @__PURE__ */ Q(J, {
|
|
720
722
|
divided: !0,
|
|
721
723
|
children: /* @__PURE__ */ Q(K, {
|
|
722
724
|
tone: "primary",
|
|
@@ -807,7 +809,7 @@ function Pr({ schema: e, layer: t, setProp: n, label: r = "Modulate" }) {
|
|
|
807
809
|
}
|
|
808
810
|
});
|
|
809
811
|
};
|
|
810
|
-
return /* @__PURE__ */ Q(
|
|
812
|
+
return /* @__PURE__ */ Q(J, {
|
|
811
813
|
label: r,
|
|
812
814
|
divided: !0,
|
|
813
815
|
children: o.map((e) => {
|
|
@@ -890,7 +892,7 @@ function Lr({ schema: e, layer: t, setProp: n, inputs: i = null }) {
|
|
|
890
892
|
}
|
|
891
893
|
});
|
|
892
894
|
}, g = (e) => n(e, r(t[e]) ? t[e].transform?.base ?? m(e) : m(e)), v = d.find((e) => !f(e)) ?? u.find((e) => !f(e));
|
|
893
|
-
return /* @__PURE__ */ $(
|
|
895
|
+
return /* @__PURE__ */ $(J, {
|
|
894
896
|
label: "Inputs",
|
|
895
897
|
divided: !0,
|
|
896
898
|
children: [p.map((e) => /* @__PURE__ */ Q(Ln, {
|
|
@@ -938,7 +940,7 @@ function Hr({ layer: e, setProp: t }) {
|
|
|
938
940
|
let n = s(), [r, i] = Z(!1), a = X(null), o = (e, n) => {
|
|
939
941
|
t("meshSrc", e), t("meshType", n);
|
|
940
942
|
};
|
|
941
|
-
return /* @__PURE__ */ $(
|
|
943
|
+
return /* @__PURE__ */ $(J, {
|
|
942
944
|
label: "Model",
|
|
943
945
|
divided: !0,
|
|
944
946
|
children: [
|
|
@@ -1039,7 +1041,8 @@ function qr({ options: e, active: t, onPick: n, spread: r = !1, pills: i = !1 })
|
|
|
1039
1041
|
onClick: () => n(e.value),
|
|
1040
1042
|
children: e.label
|
|
1041
1043
|
}, e.value))
|
|
1042
|
-
}) : /* @__PURE__ */ Q(
|
|
1044
|
+
}) : /* @__PURE__ */ Q(q, {
|
|
1045
|
+
layout: "joined",
|
|
1043
1046
|
tone: "sunken",
|
|
1044
1047
|
value: t ?? null,
|
|
1045
1048
|
onChange: n,
|
|
@@ -1183,7 +1186,8 @@ function Xr({ layer: t, showMod: n }) {
|
|
|
1183
1186
|
return /* @__PURE__ */ $(Yr, {
|
|
1184
1187
|
title: "Effects",
|
|
1185
1188
|
fx: !0,
|
|
1186
|
-
tabStrip: /* @__PURE__ */ Q(
|
|
1189
|
+
tabStrip: /* @__PURE__ */ Q(q, {
|
|
1190
|
+
layout: "joined",
|
|
1187
1191
|
tone: "sunken",
|
|
1188
1192
|
value: u,
|
|
1189
1193
|
onChange: d,
|
|
@@ -1192,7 +1196,7 @@ function Xr({ layer: t, showMod: n }) {
|
|
|
1192
1196
|
className: a(c)
|
|
1193
1197
|
}),
|
|
1194
1198
|
children: [u === "effect" && /* @__PURE__ */ $(Yn, { children: [
|
|
1195
|
-
/* @__PURE__ */ $(
|
|
1199
|
+
/* @__PURE__ */ $(J, {
|
|
1196
1200
|
label: "Effect stack",
|
|
1197
1201
|
divided: !0,
|
|
1198
1202
|
children: [C.length === 0 && /* @__PURE__ */ Q(j, {
|
|
@@ -1204,7 +1208,7 @@ function Xr({ layer: t, showMod: n }) {
|
|
|
1204
1208
|
})]
|
|
1205
1209
|
}),
|
|
1206
1210
|
/* @__PURE__ */ Q(Fn, {}),
|
|
1207
|
-
C.length < 8 && /* @__PURE__ */ Q(
|
|
1211
|
+
C.length < 8 && /* @__PURE__ */ Q(J, {
|
|
1208
1212
|
label: V.label,
|
|
1209
1213
|
divided: !0,
|
|
1210
1214
|
children: /* @__PURE__ */ Q(In, {
|
|
@@ -1231,7 +1235,8 @@ function Xr({ layer: t, showMod: n }) {
|
|
|
1231
1235
|
onPick: N,
|
|
1232
1236
|
spread: k,
|
|
1233
1237
|
fx: !0,
|
|
1234
|
-
tabStrip: /* @__PURE__ */ Q(
|
|
1238
|
+
tabStrip: /* @__PURE__ */ Q(q, {
|
|
1239
|
+
layout: "joined",
|
|
1235
1240
|
tone: "sunken",
|
|
1236
1241
|
value: u,
|
|
1237
1242
|
onChange: d,
|
|
@@ -1278,7 +1283,8 @@ function Xr({ layer: t, showMod: n }) {
|
|
|
1278
1283
|
fx: !0,
|
|
1279
1284
|
scope: O.id,
|
|
1280
1285
|
ghostLabels: O.def.params.map((e) => e.label).filter(Boolean),
|
|
1281
|
-
tabStrip: /* @__PURE__ */ Q(
|
|
1286
|
+
tabStrip: /* @__PURE__ */ Q(q, {
|
|
1287
|
+
layout: "joined",
|
|
1282
1288
|
tone: "sunken",
|
|
1283
1289
|
value: u,
|
|
1284
1290
|
onChange: d,
|
|
@@ -1291,7 +1297,7 @@ function Xr({ layer: t, showMod: n }) {
|
|
|
1291
1297
|
schema: W,
|
|
1292
1298
|
...pe
|
|
1293
1299
|
}),
|
|
1294
|
-
/* @__PURE__ */ $(
|
|
1300
|
+
/* @__PURE__ */ $(J, {
|
|
1295
1301
|
divided: !0,
|
|
1296
1302
|
children: [/* @__PURE__ */ Q(A, {
|
|
1297
1303
|
schema: fe,
|
|
@@ -1370,14 +1376,15 @@ function Xr({ layer: t, showMod: n }) {
|
|
|
1370
1376
|
...pe,
|
|
1371
1377
|
tab: "anim"
|
|
1372
1378
|
}),
|
|
1373
|
-
O.def.orbit && /* @__PURE__ */ Q(
|
|
1379
|
+
O.def.orbit && /* @__PURE__ */ Q(J, {
|
|
1374
1380
|
label: "Interaction",
|
|
1375
1381
|
divided: !0,
|
|
1376
1382
|
children: /* @__PURE__ */ Q(Rn, {
|
|
1377
1383
|
label: "ORBIT (C)",
|
|
1378
1384
|
align: "fill",
|
|
1379
1385
|
labelWidth: i,
|
|
1380
|
-
children: /* @__PURE__ */ Q(
|
|
1386
|
+
children: /* @__PURE__ */ Q(q, {
|
|
1387
|
+
layout: "joined",
|
|
1381
1388
|
tone: "sunken",
|
|
1382
1389
|
size: c,
|
|
1383
1390
|
className: "w-full",
|
|
@@ -1395,7 +1402,7 @@ function Xr({ layer: t, showMod: n }) {
|
|
|
1395
1402
|
})
|
|
1396
1403
|
})
|
|
1397
1404
|
}),
|
|
1398
|
-
/* @__PURE__ */ Q(
|
|
1405
|
+
/* @__PURE__ */ Q(J, {
|
|
1399
1406
|
divided: !0,
|
|
1400
1407
|
children: /* @__PURE__ */ Q(ot, {
|
|
1401
1408
|
inline: !0,
|
|
@@ -1457,7 +1464,7 @@ function $r({ chain: e, layer: t, hostView: n, addFilter: r, removeFilter: i, se
|
|
|
1457
1464
|
...d.params,
|
|
1458
1465
|
id: t.id
|
|
1459
1466
|
} : null, p = d ? a(u) : null;
|
|
1460
|
-
return /* @__PURE__ */ Q(
|
|
1467
|
+
return /* @__PURE__ */ Q(J, {
|
|
1461
1468
|
label: "Media",
|
|
1462
1469
|
divided: !0,
|
|
1463
1470
|
children: d?.def ? /* @__PURE__ */ $(Yn, { children: [/* @__PURE__ */ Q(A, {
|
|
@@ -1543,7 +1550,7 @@ function ti({ chain: e, from: t = 1, filters: n = null, layer: r, hostView: i, a
|
|
|
1543
1550
|
value: e.id,
|
|
1544
1551
|
label: e.label ?? e.id
|
|
1545
1552
|
}))];
|
|
1546
|
-
return /* @__PURE__ */ $(
|
|
1553
|
+
return /* @__PURE__ */ $(J, {
|
|
1547
1554
|
label: "Post-Processing",
|
|
1548
1555
|
divided: !0,
|
|
1549
1556
|
children: [/* @__PURE__ */ Q(ei, {
|
|
@@ -1589,7 +1596,8 @@ function ni({ layer: e, showMod: t, tree: n }) {
|
|
|
1589
1596
|
pills: !0,
|
|
1590
1597
|
scope: e.loopId,
|
|
1591
1598
|
ghostLabels: (U(e.loopId)?.params ?? []).filter((e) => e.type !== "color" && e.label).map((e) => e.label),
|
|
1592
|
-
tabStrip: /* @__PURE__ */ Q(
|
|
1599
|
+
tabStrip: /* @__PURE__ */ Q(q, {
|
|
1600
|
+
layout: "joined",
|
|
1593
1601
|
tone: "sunken",
|
|
1594
1602
|
value: i,
|
|
1595
1603
|
onChange: c,
|
|
@@ -1657,7 +1665,8 @@ function ri({ layer: e, showMod: t }) {
|
|
|
1657
1665
|
});
|
|
1658
1666
|
}), /* @__PURE__ */ Q(Yr, {
|
|
1659
1667
|
title: p,
|
|
1660
|
-
tabStrip: /* @__PURE__ */ Q(
|
|
1668
|
+
tabStrip: /* @__PURE__ */ Q(q, {
|
|
1669
|
+
layout: "joined",
|
|
1661
1670
|
tone: "sunken",
|
|
1662
1671
|
value: r,
|
|
1663
1672
|
onChange: i,
|
|
@@ -2717,7 +2726,8 @@ function Wi(e, t) {
|
|
|
2717
2726
|
return i.length && r.push(i), r;
|
|
2718
2727
|
}
|
|
2719
2728
|
function Gi({ cells: e, size: t }) {
|
|
2720
|
-
return Wi(e, t).map((e, n) => /* @__PURE__ */ Q(
|
|
2729
|
+
return Wi(e, t).map((e, n) => /* @__PURE__ */ Q(q, {
|
|
2730
|
+
layout: "joined",
|
|
2721
2731
|
value: null,
|
|
2722
2732
|
onChange: (t) => e.find((e) => e.value === t)?.run(),
|
|
2723
2733
|
options: e,
|
|
@@ -2737,7 +2747,8 @@ var Ki = [
|
|
|
2737
2747
|
}));
|
|
2738
2748
|
function qi({ size: e }) {
|
|
2739
2749
|
let { loopSeconds: t, setLoopSeconds: n } = C();
|
|
2740
|
-
return /* @__PURE__ */ Q(
|
|
2750
|
+
return /* @__PURE__ */ Q(q, {
|
|
2751
|
+
layout: "joined",
|
|
2741
2752
|
value: String(t),
|
|
2742
2753
|
onChange: (e) => n(Number(e)),
|
|
2743
2754
|
options: Ki,
|
|
@@ -2924,7 +2935,8 @@ function Xi({ layer: e, onSwitchCategory: t, onInsert: r, onRestart: i, aspectVa
|
|
|
2924
2935
|
/* @__PURE__ */ $("div", {
|
|
2925
2936
|
className: l ? "px-4 pb-5" : "min-h-0 flex-1 overflow-y-auto px-3 pb-3",
|
|
2926
2937
|
children: [
|
|
2927
|
-
/* @__PURE__ */ Q(
|
|
2938
|
+
/* @__PURE__ */ Q(q, {
|
|
2939
|
+
layout: "joined",
|
|
2928
2940
|
value: ye,
|
|
2929
2941
|
onChange: M,
|
|
2930
2942
|
options: ve,
|
|
@@ -3067,14 +3079,16 @@ function Xi({ layer: e, onSwitchCategory: t, onInsert: r, onRestart: i, aspectVa
|
|
|
3067
3079
|
ye === "output" && /* @__PURE__ */ $("div", {
|
|
3068
3080
|
className: "flex flex-col gap-2 pt-3",
|
|
3069
3081
|
children: [
|
|
3070
|
-
/* @__PURE__ */ Q(
|
|
3082
|
+
/* @__PURE__ */ Q(q, {
|
|
3083
|
+
layout: "joined",
|
|
3071
3084
|
value: a,
|
|
3072
3085
|
onChange: s,
|
|
3073
3086
|
options: Ji,
|
|
3074
3087
|
size: B,
|
|
3075
3088
|
ariaLabel: "Aspect"
|
|
3076
3089
|
}),
|
|
3077
|
-
/* @__PURE__ */ Q(
|
|
3090
|
+
/* @__PURE__ */ Q(q, {
|
|
3091
|
+
layout: "joined",
|
|
3078
3092
|
value: a,
|
|
3079
3093
|
onChange: s,
|
|
3080
3094
|
options: Yi,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { In as e, Ln as t, Nn as n, Pn as r, Rn as i, cn as a, fn as o, ln as s, pn as c, xn as l, zn as u } from "./rolls-CEQmdcp3.js";
|
|
2
|
-
import { a as d, i as f, o as p, s as m } from "./useLayerEdit-
|
|
2
|
+
import { a as d, i as f, o as p, s as m } from "./useLayerEdit-Cmtx3V3O.js";
|
|
3
3
|
import { a as h, u as g } from "./TreePicker-1_NZG8GB.js";
|
|
4
4
|
import { useSyncExternalStore as _ } from "react";
|
|
5
5
|
//#region src/loops/lib/fill.js
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { F as e, J as t, L as n, Rt as r, Vn as i, a, d as o, ft as s, ht as c, n as l, o as u, t as d, u as f } from "./rolls-CEQmdcp3.js";
|
|
2
|
-
import { n as p, r as m, t as h } from "./useLayerEdit-
|
|
3
|
-
import { $ as g, J as _, K as v, Q as y, X as b, Y as x, Z as S, a as ee, et as C, f as w, i as T, l as E, o as D, p as O, q as k, r as A, s as j, u as M } from "./effectCategories-
|
|
2
|
+
import { n as p, r as m, t as h } from "./useLayerEdit-Cmtx3V3O.js";
|
|
3
|
+
import { $ as g, J as _, K as v, Q as y, X as b, Y as x, Z as S, a as ee, et as C, f as w, i as T, l as E, o as D, p as O, q as k, r as A, s as j, u as M } from "./effectCategories-DV7i_AgK.js";
|
|
4
4
|
import { n as N, t as P } from "./TreePicker-1_NZG8GB.js";
|
|
5
5
|
import { t as F } from "./BindDot-Don6fG00.js";
|
|
6
|
-
import { Button as I,
|
|
6
|
+
import { Button as I, ButtonGroup as L, Dropdown as R, LabeledControl as z, LabeledControlSection as B, SettingsRow as V, ToggleSwitch as H, Tooltip as U, XYPad as W } from "@kolkrabbi/kol-component";
|
|
7
7
|
import { useEffect as G, useRef as te, useState as K } from "react";
|
|
8
8
|
import { Fragment as q, jsx as J, jsxs as Y } from "react/jsx-runtime";
|
|
9
9
|
//#region src/editor/compose/inspectors/EffectsPanel.jsx
|
|
@@ -65,16 +65,16 @@ function re({ layer: r }) {
|
|
|
65
65
|
}
|
|
66
66
|
} : t);
|
|
67
67
|
m.patch({ filters: t });
|
|
68
|
-
},
|
|
68
|
+
}, z = (e, t) => {
|
|
69
69
|
if (e === "cameraDrag") {
|
|
70
70
|
m.setProp(e, t);
|
|
71
71
|
return;
|
|
72
72
|
}
|
|
73
73
|
I({ [e]: t });
|
|
74
|
-
},
|
|
74
|
+
}, B = (e) => z("sweeps", e), H = (e) => /* @__PURE__ */ J(F, {
|
|
75
75
|
layer: P,
|
|
76
76
|
param: e,
|
|
77
|
-
setProp:
|
|
77
|
+
setProp: z
|
|
78
78
|
}), U = C?.def ? E(C.def.id) : null, W = U ? C.def.params.find((e) => e.key === U) : null, X = C?.def ? C.def.params.filter((e) => c(e) !== "anim" && e !== W) : [];
|
|
79
79
|
return /* @__PURE__ */ Y("div", {
|
|
80
80
|
className: "flex flex-col gap-4",
|
|
@@ -112,7 +112,8 @@ function re({ layer: r }) {
|
|
|
112
112
|
label: "Camera drag",
|
|
113
113
|
align: "fill",
|
|
114
114
|
labelWidth: e,
|
|
115
|
-
children: /* @__PURE__ */ J(
|
|
115
|
+
children: /* @__PURE__ */ J(L, {
|
|
116
|
+
layout: "joined",
|
|
116
117
|
size: i,
|
|
117
118
|
className: "w-full",
|
|
118
119
|
options: [{
|
|
@@ -123,10 +124,11 @@ function re({ layer: r }) {
|
|
|
123
124
|
label: "On"
|
|
124
125
|
}],
|
|
125
126
|
value: r.cameraDrag ? "on" : "off",
|
|
126
|
-
onChange: (e) =>
|
|
127
|
+
onChange: (e) => z("cameraDrag", e === "on")
|
|
127
128
|
})
|
|
128
129
|
}),
|
|
129
|
-
/* @__PURE__ */ J(
|
|
130
|
+
/* @__PURE__ */ J(L, {
|
|
131
|
+
layout: "joined",
|
|
130
132
|
size: i,
|
|
131
133
|
className: "w-full",
|
|
132
134
|
value: D,
|
|
@@ -136,7 +138,7 @@ function re({ layer: r }) {
|
|
|
136
138
|
D === "effect" && /* @__PURE__ */ Y(q, { children: [/* @__PURE__ */ J(p, {
|
|
137
139
|
schema: X,
|
|
138
140
|
layer: P,
|
|
139
|
-
setProp:
|
|
141
|
+
setProp: z,
|
|
140
142
|
palette: a,
|
|
141
143
|
renderAnimate: H
|
|
142
144
|
}), /* @__PURE__ */ J(Z, {
|
|
@@ -149,7 +151,7 @@ function re({ layer: r }) {
|
|
|
149
151
|
/* @__PURE__ */ J(p, {
|
|
150
152
|
schema: C.def.params,
|
|
151
153
|
layer: P,
|
|
152
|
-
setProp:
|
|
154
|
+
setProp: z,
|
|
153
155
|
palette: a,
|
|
154
156
|
renderAnimate: H,
|
|
155
157
|
tab: "anim"
|
|
@@ -162,12 +164,12 @@ function re({ layer: r }) {
|
|
|
162
164
|
}),
|
|
163
165
|
C.def.sweeps && /* @__PURE__ */ J(Q, {
|
|
164
166
|
sweeps: Array.isArray(C.params.sweeps) ? C.params.sweeps : [],
|
|
165
|
-
onChange:
|
|
167
|
+
onChange: B
|
|
166
168
|
})
|
|
167
169
|
] })
|
|
168
170
|
]
|
|
169
171
|
})]
|
|
170
|
-
}, t.key)), g.length < 8 ? /* @__PURE__ */ J(
|
|
172
|
+
}, t.key)), g.length < 8 ? /* @__PURE__ */ J(R, {
|
|
171
173
|
variant: "subtle",
|
|
172
174
|
size: i,
|
|
173
175
|
className: "w-full",
|
|
@@ -263,7 +265,7 @@ function ie({ stage: e, selected: t, options: r, onSelect: i, onPick: a, onToggl
|
|
|
263
265
|
m(p ? "Disable effect" : "Enable effect", o, !1, p ? "eye-on" : "eye-off"),
|
|
264
266
|
/* @__PURE__ */ J("div", {
|
|
265
267
|
className: `flex-1 min-w-0 ${p ? "" : "opacity-60"}`,
|
|
266
|
-
children: /* @__PURE__ */ J(
|
|
268
|
+
children: /* @__PURE__ */ J(R, {
|
|
267
269
|
variant: "subtle",
|
|
268
270
|
size: f,
|
|
269
271
|
className: "w-full",
|
|
@@ -342,7 +344,7 @@ function Q({ sweeps: t, onChange: r, inline: i = !1 }) {
|
|
|
342
344
|
...t,
|
|
343
345
|
...n
|
|
344
346
|
} : t));
|
|
345
|
-
return /* @__PURE__ */ Y(q, { children: [/* @__PURE__ */ Y(
|
|
347
|
+
return /* @__PURE__ */ Y(q, { children: [/* @__PURE__ */ Y(B, {
|
|
346
348
|
label: "Motion",
|
|
347
349
|
divided: !0,
|
|
348
350
|
children: [/* @__PURE__ */ J(P, {
|
|
@@ -369,7 +371,7 @@ function Q({ sweeps: t, onChange: r, inline: i = !1 }) {
|
|
|
369
371
|
})]
|
|
370
372
|
}), t.map((t, n) => {
|
|
371
373
|
let r = t.enabled !== !1;
|
|
372
|
-
return /* @__PURE__ */ Y(
|
|
374
|
+
return /* @__PURE__ */ Y(B, {
|
|
373
375
|
divided: !0,
|
|
374
376
|
children: [/* @__PURE__ */ Y("div", {
|
|
375
377
|
className: "flex items-center gap-2",
|
|
@@ -401,7 +403,7 @@ function Q({ sweeps: t, onChange: r, inline: i = !1 }) {
|
|
|
401
403
|
layer: t,
|
|
402
404
|
setProp: (e, t) => l(n, { [e]: t }),
|
|
403
405
|
inline: i
|
|
404
|
-
}), (t.shape ?? "linear") !== "noise" && /* @__PURE__ */ J(
|
|
406
|
+
}), (t.shape ?? "linear") !== "noise" && /* @__PURE__ */ J(z, {
|
|
405
407
|
inline: !0,
|
|
406
408
|
label: "ORIGIN",
|
|
407
409
|
labelWidth: e,
|
package/dist/effects.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as e } from "./effects-
|
|
1
|
+
import { t as e } from "./effects-Dn4_OzYx.js";
|
|
2
2
|
export { e as effects };
|