@pie-element/drawing-response 12.1.2-next.30 → 12.1.2-next.31

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.
@@ -1,5 +1,5 @@
1
1
  import { a as e, i as t, n, r } from "../browser-kkT1XVKw.js";
2
- import { $ as i, C as a, St as o, _ as s, d as c, gt as l, ht as u, n as d, o as f, pt as p, t as m, u as h, vt as g, wt as _, xt as v, y } from "../MenuItem-CUsuaIHY.js";
2
+ import { $ as i, C as a, Ct as o, St as s, Tt as c, _ as l, _t as u, d, ht as f, n as p, o as m, pt as h, t as g, u as _, y as v, yt as y } from "../MenuItem-C7m-hSiY.js";
3
3
  import * as b from "react";
4
4
  import x, { Component as S } from "react";
5
5
  import { createRoot as C } from "react-dom/client";
@@ -34,7 +34,7 @@ var E = class e extends CustomEvent {
34
34
  }
35
35
  }), this.component = t, this.complete = n;
36
36
  }
37
- }, O = /* @__PURE__ */ e(u(), 1), k = {
37
+ }, O = /* @__PURE__ */ e(f(), 1), k = {
38
38
  translation: {
39
39
  categorize: {
40
40
  limitMaxChoicesPerCategory: "You've reached the limit of {{maxChoicesPerCategory}} responses per area. To add another response, one must first be removed.",
@@ -1592,7 +1592,7 @@ var Ze = {
1592
1592
  label: "Eraser",
1593
1593
  icon: "mdiEraser"
1594
1594
  }
1595
- ] }, $e = i(y)({
1595
+ ] }, $e = i(v)({
1596
1596
  fontSize: "0.9em",
1597
1597
  marginLeft: 8,
1598
1598
  minWidth: 32,
@@ -1628,14 +1628,14 @@ function tt(e) {
1628
1628
  function nt(e, t) {
1629
1629
  return !e || tt(e) ? e : tt(e.default) ? e.default : t && tt(e[t]) ? e[t] : t && tt(e[t]?.default) ? e[t].default : e;
1630
1630
  }
1631
- var rt = nt(c, "InputContainer") || nt(ot.InputContainer, "InputContainer"), it = f, at = it.default, ot = at && typeof at == "object" ? at : it, { translator: st } = Ze, ct = i("div")(({ theme: e }) => ({
1631
+ var rt = nt(d, "InputContainer") || nt(ot.InputContainer, "InputContainer"), it = m, at = it.default, ot = at && typeof at == "object" ? at : it, { translator: st } = Ze, ct = i("div")(({ theme: e }) => ({
1632
1632
  marginTop: e.spacing(2),
1633
1633
  display: "flex"
1634
1634
  })), lt = i(rt)({
1635
1635
  flex: 1,
1636
1636
  fontSize: "inherit",
1637
1637
  width: "90%"
1638
- }), ut = i(m)(({ theme: e, isBlackColor: t }) => ({
1638
+ }), ut = i(g)(({ theme: e, isBlackColor: t }) => ({
1639
1639
  borderRadius: "2px",
1640
1640
  fontSize: "inherit",
1641
1641
  height: "22px",
@@ -1643,7 +1643,7 @@ var rt = nt(c, "InputContainer") || nt(ot.InputContainer, "InputContainer"), it
1643
1643
  marginRight: e.spacing(2),
1644
1644
  marginTop: e.spacing(2),
1645
1645
  ...t && { color: e.palette.background.paper }
1646
- })), dt = i(d)({
1646
+ })), dt = i(p)({
1647
1647
  fontSize: "inherit",
1648
1648
  transform: "translate(0%, 40%)"
1649
1649
  }), ft = class extends x.Component {
@@ -12724,12 +12724,12 @@ var Hs = Vs(ms, "Stage"), Us = Vs(ss, "Layer"), { translator: Ws } = Ze, Gs = i(
12724
12724
  if (e.session) {
12725
12725
  let { TextEntry: t } = e, { drawables: n } = this.state;
12726
12726
  if (e.session.drawables) {
12727
- let r = _(e.session.drawables);
12727
+ let r = c(e.session.drawables);
12728
12728
  if (JSON.stringify(n) !== JSON.stringify((r || []).map((e) => o(e, "type")))) {
12729
12729
  let t = e.session.drawables;
12730
12730
  this.setState({ drawables: t.map((e) => zs(e.type, e)) });
12731
12731
  }
12732
- g(t.all.map((e) => ({
12732
+ y(t.all.map((e) => ({
12733
12733
  ...e,
12734
12734
  ...t[`text_${e.id}`] && t[`text_${e.id}`].attrs,
12735
12735
  value: t[`textarea_${e.id}`] && t[`textarea_${e.id}`].value
@@ -12747,7 +12747,7 @@ var Hs = Vs(ms, "Stage"), Us = Vs(ss, "Layer"), { translator: Ws } = Ze, Gs = i(
12747
12747
  value: n[`textarea_${e.id}`] && n[`textarea_${e.id}`].value
12748
12748
  }))
12749
12749
  };
12750
- g(a, t) || e({
12750
+ y(a, t) || e({
12751
12751
  ...t,
12752
12752
  ...a
12753
12753
  });
@@ -13142,7 +13142,7 @@ var tc = ec($, "Text"), { translator: nc } = Ze, rc = () => Math.random().toStri
13142
13142
  }, n.p = "", n(n.s = 2);
13143
13143
  }([
13144
13144
  function(e, t) {
13145
- e.exports = u();
13145
+ e.exports = f();
13146
13146
  },
13147
13147
  function(e, n) {
13148
13148
  e.exports = t("react");
@@ -13562,12 +13562,12 @@ function Ec(e) {
13562
13562
  function Dc(e, t) {
13563
13563
  return !e || Ec(e) ? e : Ec(e.default) ? e.default : t && Ec(e[t]) ? e[t] : t && Ec(e[t]?.default) ? e[t].default : e;
13564
13564
  }
13565
- var Oc = Dc(s, "UiLayout") || Dc(Nc.UiLayout, "UiLayout"), kc = Dc(h, "PreviewPrompt") || Dc(Nc.PreviewPrompt, "PreviewPrompt"), Ac = Dc(a, "Collapsible") || Dc(Nc.Collapsible, "Collapsible"), jc = f, Mc = jc.default, Nc = Mc && typeof Mc == "object" ? Mc : jc, Pc = i(Oc)({
13566
- color: p.text(),
13567
- backgroundColor: p.background()
13565
+ var Oc = Dc(l, "UiLayout") || Dc(Nc.UiLayout, "UiLayout"), kc = Dc(_, "PreviewPrompt") || Dc(Nc.PreviewPrompt, "PreviewPrompt"), Ac = Dc(a, "Collapsible") || Dc(Nc.Collapsible, "Collapsible"), jc = m, Mc = jc.default, Nc = Mc && typeof Mc == "object" ? Mc : jc, Pc = i(Oc)({
13566
+ color: h.text(),
13567
+ backgroundColor: h.background()
13568
13568
  }), Fc = i(Ac)(({ theme: e }) => ({ marginBottom: e.spacing(2) })), Ic = i("div")({
13569
- color: p.text(),
13570
- backgroundColor: p.background()
13569
+ color: h.text(),
13570
+ backgroundColor: h.background()
13571
13571
  }), Lc = class extends x.Component {
13572
13572
  constructor(e) {
13573
13573
  super(e), this.state = {
@@ -13626,7 +13626,7 @@ var Rc = class extends HTMLElement {
13626
13626
  this._model = e, this.dispatchEvent(new E(this.tagName.toLowerCase(), this.isComplete(), !!this._model)), this._render();
13627
13627
  }
13628
13628
  isComplete() {
13629
- return this._session && (!v(this._session.drawables) || !v(this._session.texts));
13629
+ return this._session && (!s(this._session.drawables) || !s(this._session.texts));
13630
13630
  }
13631
13631
  sessionChanged = (e) => {
13632
13632
  this._session.drawables = e.drawables, this._session.texts = e.texts, this._session.width = e.width, this.dispatchEvent(new D(this.tagName.toLowerCase(), this.isComplete())), this._render();
@@ -13648,7 +13648,7 @@ var Rc = class extends HTMLElement {
13648
13648
  onSessionChange: this.sessionChanged
13649
13649
  });
13650
13650
  this._root ||= C(this), this._root.render(e), queueMicrotask(() => {
13651
- l(this);
13651
+ u(this);
13652
13652
  });
13653
13653
  }
13654
13654
  }