@cling-se/widget 0.9.33 → 0.10.4-beta.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.
Files changed (120) hide show
  1. package/dist/{AddClientCallout-5d2a5eaa.js → AddClientCallout-ac04b0e5.js} +5 -5
  2. package/dist/{AnswerModal-39f81c0e.js → AnswerModal-ab94492a.js} +47 -47
  3. package/dist/{AttachmentItem-5d900d83.js → AttachmentItem-3fe7f93e.js} +15 -10
  4. package/dist/{BaseDatePicker-92562106.js → BaseDatePicker-bc7a7a38.js} +2 -2
  5. package/dist/{BaseInput-1c9d9daf.js → BaseInput-0128f8e7.js} +1 -1
  6. package/dist/{BaseUpload-078e4666.js → BaseUpload-72ba3ed6.js} +25 -25
  7. package/dist/{BlockMedia-4155dbd6.js → BlockMedia-34f3880e.js} +1 -1
  8. package/dist/{CCallout-46b3d405.js → CCallout-25f57fce.js} +2 -2
  9. package/dist/{CDropdownItem-9b1ca709.js → CDropdownItem-5b7319d8.js} +1 -1
  10. package/dist/{CField-d7edf10c.js → CField-7d3f84b4.js} +1 -1
  11. package/dist/{CPhoneFormat-40bd6283.js → CPhoneFormat-c733eed8.js} +1 -1
  12. package/dist/{CSlider.vue_vue_type_style_index_0_lang-12f32bb7.js → CSlider.vue_vue_type_style_index_0_lang-2908d3f1.js} +1 -1
  13. package/dist/{ClientAutocomplete-a6bb0940.js → ClientAutocomplete-977b5a9e.js} +2 -2
  14. package/dist/{ClientModal-e5f7b4b8.js → ClientModal-be37f1fc.js} +5 -5
  15. package/dist/{ColorPicker-c1b32ad5.js → ColorPicker-42cda4ee.js} +1 -1
  16. package/dist/{CompanyModal-977515ec.js → CompanyModal-c864241c.js} +3 -3
  17. package/dist/{ContentWrapper-62f4579f.js → ContentWrapper-f36e7350.js} +13 -13
  18. package/dist/{CoverBlockSettings-7226a5b6.js → CoverBlockSettings-362d1abb.js} +9 -9
  19. package/dist/DocAnswer-d7d3e570.js +43 -0
  20. package/dist/{DocDetails-8172e555.js → DocDetails-99c9480f.js} +46 -37
  21. package/dist/{DocForm-3d4d126b.js → DocForm-d42c6859.js} +602 -600
  22. package/dist/{DocFormSend-237ec151.js → DocFormSend-5cfcec8a.js} +51 -38
  23. package/dist/DocLinks-4eb1de5e.js +41 -0
  24. package/dist/{DocModalBase-f3267f66.js → DocModalBase-3199ead0.js} +1 -1
  25. package/dist/{DocPrint-2925c8e3.js → DocPrint-ffd6bd0a.js} +1 -1
  26. package/dist/{DocReceipt-ac09c964.js → DocReceipt-dcb76efe.js} +1 -1
  27. package/dist/{DocSendReminder-e1999f4e.js → DocSendReminder-63f7d042.js} +1 -1
  28. package/dist/{DocTextEditor-25220c68.js → DocTextEditor-f7aa5610.js} +8 -8
  29. package/dist/{DocTimeline-5eb73448.js → DocTimeline-637ce0d3.js} +1 -1
  30. package/dist/{DocumentClient-321f7941.js → DocumentClient-a8c0c1f0.js} +7 -7
  31. package/dist/{DocumentLayout-a798e912.js → DocumentLayout-d0b0264c.js} +5 -5
  32. package/dist/{DocumentLogotype-b87b1b6d.js → DocumentLogotype-cf798645.js} +3 -3
  33. package/dist/{DocumentVoided-f0601bd6.js → DocumentVoided-32256b94.js} +1 -1
  34. package/dist/{EmbedInput-39a03d94.js → EmbedInput-90aa3ad1.js} +2 -2
  35. package/dist/{EmbedSettings-554aac05.js → EmbedSettings-fb61b264.js} +3 -3
  36. package/dist/{ErrorCallout-21273503.js → ErrorCallout-cd3bfacb.js} +1 -1
  37. package/dist/{FilePreviewModal-29a98271.js → FilePreviewModal-7176df5b.js} +5 -5
  38. package/dist/{Flag-6e070aa2.js → Flag-f48640d5.js} +1 -1
  39. package/dist/{HeaderSettings-61efccf5.js → HeaderSettings-d3083244.js} +15 -15
  40. package/dist/{ImageSelectModal-fd5cd1d6.js → ImageSelectModal-44047f1e.js} +8 -8
  41. package/dist/{ImageUploadWrapper-f7f6033b.js → ImageUploadWrapper-9d102509.js} +2 -2
  42. package/dist/{Index-b0cddd8a.js → Index-007fa122.js} +4 -4
  43. package/dist/{Index-74f5784f.js → Index-01311f76.js} +5 -5
  44. package/dist/{Index-952af56e.js → Index-08900b5e.js} +6 -6
  45. package/dist/{Index-9311fb23.js → Index-13103bfa.js} +4 -4
  46. package/dist/{Index-8ce025b4.js → Index-153fb302.js} +7 -7
  47. package/dist/{Index-e876c053.js → Index-15cda543.js} +9 -9
  48. package/dist/{Index-3323e160.js → Index-160a7d88.js} +2 -2
  49. package/dist/{Index-2beebe64.js → Index-2621b655.js} +6 -6
  50. package/dist/{Index-d8d40597.js → Index-268a3680.js} +2 -2
  51. package/dist/{Index-59e57f26.js → Index-2dd0855b.js} +6 -6
  52. package/dist/{Index-30e39d25.js → Index-34f8ec3d.js} +4 -4
  53. package/dist/{Index-7f1f80fa.js → Index-4a077c97.js} +17 -17
  54. package/dist/{Index-d1732510.js → Index-4a69a722.js} +2 -2
  55. package/dist/{Index-46f2a6e0.js → Index-4e013912.js} +4 -4
  56. package/dist/{Index-4d3fa8b8.js → Index-50f1f14e.js} +4 -4
  57. package/dist/{Index-fdbed274.js → Index-6a965ec8.js} +1 -1
  58. package/dist/{Index-c01113d6.js → Index-70e37c05.js} +2 -2
  59. package/dist/{Index-524cea65.js → Index-7adb0086.js} +8 -8
  60. package/dist/{Index-e903660c.js → Index-8a130821.js} +2 -2
  61. package/dist/{Index-c3193bbe.js → Index-8dd0a4a3.js} +6 -6
  62. package/dist/{Index-617c91c3.js → Index-8e42fd14.js} +1 -1
  63. package/dist/{Index-afe7a567.js → Index-8ffa87b4.js} +2 -2
  64. package/dist/{Index-727c0770.js → Index-91923bb3.js} +14 -14
  65. package/dist/{Index-2ecd6c6a.js → Index-a3dd0100.js} +3 -3
  66. package/dist/{Index-8920bf5c.js → Index-a6c2348f.js} +4 -4
  67. package/dist/{Index-808af4fd.js → Index-a8ab221c.js} +4 -4
  68. package/dist/{Index-c1ef9eae.js → Index-a9255882.js} +10 -10
  69. package/dist/{Index-cc59098f.js → Index-b2861f7a.js} +2 -2
  70. package/dist/{Index-e29b7205.js → Index-d5c54afa.js} +4 -4
  71. package/dist/{Index-4835bdde.js → Index-d5ed245c.js} +2 -2
  72. package/dist/{Index-6a5ee34c.js → Index-e9cf6266.js} +14 -14
  73. package/dist/{Index-875247ac.js → Index-f10ed000.js} +5 -5
  74. package/dist/{Index-729cd253.js → Index-f4270151.js} +14 -14
  75. package/dist/{Index-f1c8a1fd.js → Index-ff9efb43.js} +7 -7
  76. package/dist/{InputToggleRow-e9ccb4db.js → InputToggleRow-f7c8fad0.js} +1 -1
  77. package/dist/{IsPremiumPreStep-086fdca0.js → IsPremiumPreStep-c57d25d5.js} +14 -14
  78. package/dist/{ManualPopover-01700f5a.js → ManualPopover-8a1b6a31.js} +1 -1
  79. package/dist/{MediaWrapper-32ca2c1d.js → MediaWrapper-5dcfede8.js} +3 -3
  80. package/dist/{NotBindingText-fb273710.js → NotBindingText-0464a81e.js} +2 -2
  81. package/dist/{PackageGroup-856c8037.js → PackageGroup-339ce6cb.js} +15 -15
  82. package/dist/{PdfTerms-ec7f5bf0.js → PdfTerms-0f433ba4.js} +5 -5
  83. package/dist/{PdfViewer-876f73eb.js → PdfViewer-dfb6816e.js} +9 -9
  84. package/dist/{PlainHtml-eaf23e90.js → PlainHtml-511f00f4.js} +1 -1
  85. package/dist/{PriceHeader-08162c74.js → PriceHeader-81c0f36c.js} +13 -13
  86. package/dist/{SearchApi-4e81ff12.js → SearchApi-0d8acefc.js} +3 -4
  87. package/dist/{Setup-d5c66f4b.js → Setup-bbdf4e98.js} +1 -1
  88. package/dist/{TermsSettings-5c9b40f9.js → TermsSettings-e6827dae.js} +7 -7
  89. package/dist/{ThemeColorRow-37d6548d.js → ThemeColorRow-0a7ade13.js} +3 -3
  90. package/dist/{ToggleBinding-cfa1fef2.js → ToggleBinding-34338d89.js} +3 -3
  91. package/dist/{UploadModal-e1269a45.js → UploadModal-08b3ecb6.js} +3 -3
  92. package/dist/{VideoPlayerInput-675640a9.js → VideoPlayerInput-a1592195.js} +3 -3
  93. package/dist/{VideoPlayerSettings-0d68de0a.js → VideoPlayerSettings-d8ed1e19.js} +4 -4
  94. package/dist/{VideoSelectModal-29619ddc.js → VideoSelectModal-421df4a2.js} +8 -8
  95. package/dist/{answerDocumentMixin-7c88a039.js → answerDocumentMixin-a3a4e70d.js} +3 -3
  96. package/dist/{debounce-a8a2e7ca.js → debounce-7b692c87.js} +8 -8
  97. package/dist/{focusDrawerMixin-903d1bdd.js → focusDrawerMixin-5b5ac90c.js} +1 -1
  98. package/dist/{formComponentsInstall-286a0acd.js → formComponentsInstall-897fd293.js} +12 -12
  99. package/dist/{formDrawerState-e034a6ab.js → formDrawerState-09657030.js} +1 -1
  100. package/dist/{formValidationMixin-76dd5928.js → formValidationMixin-090f1841.js} +1 -1
  101. package/dist/{index-01421a50.js → index-10f9f703.js} +5 -5
  102. package/dist/{index-61ba0ac0.js → index-3f979f04.js} +3 -3
  103. package/dist/{index-5363165d.js → index-71606148.js} +13 -13
  104. package/dist/{index-563cfa1e.js → index-74a344c7.js} +1 -1
  105. package/dist/{index-5827c622.js → index-a3dfaf0e.js} +48 -48
  106. package/dist/{index-4a052f26.js → index-c6a51a6f.js} +1 -1
  107. package/dist/index.es.js +2 -2
  108. package/dist/index.umd.js +158 -159
  109. package/dist/{main-d803b876.js → main-fe7caa96.js} +10357 -12663
  110. package/dist/{mapFormMixin-0583565b.js → mapFormMixin-821b98b6.js} +1 -1
  111. package/dist/{publicSenderState-b62d76e3.js → publicSenderState-7387a06a.js} +1 -1
  112. package/dist/style.css +1 -1
  113. package/dist/{throttle-a8b2f0e5.js → throttle-cc268af2.js} +2 -2
  114. package/dist/{tinycolor-dffe2bfd.js → tinycolor-91424e70.js} +1 -1
  115. package/dist/{tippy.esm-7bfd5b54.js → tippy.esm-95ab3202.js} +5 -5
  116. package/dist/{utils-9a1bdd7a.js → utils-3f18d789.js} +1 -1
  117. package/dist/{vuedraggable.umd-a5100bc8.js → vuedraggable.umd-797c9a23.js} +1 -1
  118. package/package.json +1 -1
  119. package/dist/DocAnswer-245629ec.js +0 -30
  120. package/dist/DocLinks-c807e0dc.js +0 -38
@@ -1,37 +1,37 @@
1
- import { g as m, n as d, w as U, b as u, aF as ae, c as f, C as O, b7 as se, b8 as ne, L as G, M as H, h as D, b9 as oe, ba as le, D as re, bb as ce, bc as de, b6 as pe, bd as ue, T as p, a9 as h, b1 as y, be as me, bf as he, bg as fe, bh as ge, bi as Ce, bj as ve, G as ye, bk as xe, d as we, i as $, S as be, az as _e, l as ke, bl as Le, V as A, b3 as R, b4 as W, I as z, bm as B, b5 as $e, bn as Se, j as Te, bo as I, r as De, m as Ve, a as Be, bp as Me, bq as Ie } from "./main-d803b876.js";
1
+ import { g as m, n as d, v as U, b as u, aE as ae, c as f, C as O, b6 as ne, b7 as se, K as R, L as H, h as D, b8 as oe, b9 as le, B as re, ba as ce, bb as de, b5 as pe, bc as ue, R as p, a8 as h, b0 as y, bd as me, be as he, bf as fe, bg as ge, bh as Ce, bi as ve, F as ye, bj as xe, d as we, i as $, S as be, ay as _e, l as ke, bk as Le, V as A, b2 as G, b3 as W, I as z, bl as B, b4 as $e, bm as Se, j as Te, bn as F, m as De, a as Ve, bo as Be, bp as Me } from "./main-fe7caa96.js";
2
2
  import { m as g, a as x } from "./vuex.esm-4a0fff7c.js";
3
- import "./index-5827c622.js";
4
- import { v as F } from "./index-805c56e4.js";
5
- import { w as b } from "./CDropdownItem-9b1ca709.js";
6
- import { a as _, I as k, b as Fe, c as He } from "./IsPremiumPreStep-086fdca0.js";
7
- import { D as Ae, l as Pe, g as ze, W as Ee, b as Ze, a as Ue } from "./DocumentLayout-a798e912.js";
8
- import { s as L } from "./Flag-6e070aa2.js";
9
- import { B as Oe } from "./BlockMedia-4155dbd6.js";
10
- import { d as P, t as Ge } from "./debounce-a8a2e7ca.js";
11
- import { a as Re } from "./tinycolor-dffe2bfd.js";
12
- import { m as S } from "./mapFormMixin-0583565b.js";
13
- import { S as We, C as q, i as qe } from "./formComponentsInstall-286a0acd.js";
14
- import { f as Ne } from "./formValidationMixin-76dd5928.js";
15
- import { s as v } from "./formDrawerState-e034a6ab.js";
16
- import { F as N, d as je } from "./tippy.esm-7bfd5b54.js";
17
- import { S as Ke } from "./CSlider.vue_vue_type_style_index_0_lang-12f32bb7.js";
18
- import { o as Ye, d as Qe } from "./vuedraggable.umd-a5100bc8.js";
19
- import { s as Je } from "./dom-962579a6.js";
20
- import { o as Xe } from "./index-563cfa1e.js";
21
- import et from "./AnswerModal-39f81c0e.js";
3
+ import "./index-a3dfaf0e.js";
4
+ import { v as I } from "./index-805c56e4.js";
5
+ import { w as b } from "./CDropdownItem-5b7319d8.js";
6
+ import { a as _, I as k, b as Fe, c as Ie } from "./IsPremiumPreStep-c57d25d5.js";
7
+ import { D as He, l as Ae, g as Pe, W as ze, b as Ee, a as Ze } from "./DocumentLayout-d0b0264c.js";
8
+ import { s as L } from "./Flag-f48640d5.js";
9
+ import { B as Ue } from "./BlockMedia-34f3880e.js";
10
+ import { d as P, t as Oe } from "./debounce-7b692c87.js";
11
+ import { a as Re } from "./tinycolor-91424e70.js";
12
+ import { m as S } from "./mapFormMixin-821b98b6.js";
13
+ import { S as Ge, C as q, i as We } from "./formComponentsInstall-897fd293.js";
14
+ import { f as qe } from "./formValidationMixin-090f1841.js";
15
+ import { s as v } from "./formDrawerState-09657030.js";
16
+ import { F as N, d as Ne } from "./tippy.esm-95ab3202.js";
17
+ import { S as je } from "./CSlider.vue_vue_type_style_index_0_lang-2908d3f1.js";
18
+ import { o as Ke, d as Ye } from "./vuedraggable.umd-797c9a23.js";
19
+ import { s as Qe } from "./dom-962579a6.js";
20
+ import { o as Je } from "./index-74a344c7.js";
21
+ import Xe from "./AnswerModal-ab94492a.js";
22
22
  import "./anime.es-e284c852.js";
23
23
  import "./color-71c20583.js";
24
- import "./BaseDatePicker-92562106.js";
25
- import "./ErrorCallout-21273503.js";
26
- import "./AddClientCallout-5d2a5eaa.js";
27
- import "./ClientAutocomplete-a6bb0940.js";
28
- import "./SearchApi-4e81ff12.js";
29
- import "./ClientModal-e5f7b4b8.js";
30
- import "./CCallout-46b3d405.js";
31
- import "./CField-d7edf10c.js";
24
+ import "./BaseDatePicker-bc7a7a38.js";
25
+ import "./ErrorCallout-cd3bfacb.js";
26
+ import "./AddClientCallout-ac04b0e5.js";
27
+ import "./ClientAutocomplete-977b5a9e.js";
28
+ import "./SearchApi-0d8acefc.js";
29
+ import "./ClientModal-be37f1fc.js";
30
+ import "./CCallout-25f57fce.js";
31
+ import "./CField-7d3f84b4.js";
32
32
  import "./CField.vue_vue_type_style_index_0_lang-4ed993c7.js";
33
- import "./ColorPicker-c1b32ad5.js";
34
- const tt = {
33
+ import "./ColorPicker-42cda4ee.js";
34
+ const et = {
35
35
  i18nOptions: {
36
36
  namespaces: "DocumentTemplateFormModal",
37
37
  messages: {
@@ -84,7 +84,7 @@ const tt = {
84
84
  },
85
85
  validations: {
86
86
  name: {
87
- required: F.requiredIf((i) => !i.updateExistingDocTemplate)
87
+ required: I.requiredIf((i) => !i.updateExistingDocTemplate)
88
88
  }
89
89
  },
90
90
  computed: {
@@ -174,7 +174,7 @@ const tt = {
174
174
  }
175
175
  }
176
176
  };
177
- var it = function() {
177
+ var tt = function() {
178
178
  var e = this, t = e._self._c;
179
179
  return t("div", { staticClass: "t-root font-inter" }, [t("div", { staticStyle: { "font-size": "18px", "font-weight": "700", "text-align": "center", "margin-bottom": "1em" } }, [e._v(" " + e._s(e.template ? e.$t("_common:edit", { thing: e.$t("_common:name") }) : e.$t("_common:save", { thing: e.$t("_common:template") })) + " ")]), t("div", [e.template ? e._e() : t("CCallout", [e._v(" " + e._s(e.$t("calloutDescription")) + " ")]), t("CField", { attrs: { vuelidate: e.$v.name, "vuelidate-messages": e.messages.name, label: e.$t("_common:name").capitalize(), "label-position": "inside" } }, [t("CInput", { ref: "input", staticClass: "rounder", staticStyle: { "margin-bottom": "calc(1 * var(--rem))" }, attrs: { value: e.updateExistingDocTemplate ? e.document.template.name : e.name, placeholder: e.$t("namePlaceholder"), disabled: e.updateExistingDocTemplate, autofocus: "", size: "medium" }, on: { input: function(a) {
180
180
  e.name = a;
@@ -183,31 +183,31 @@ var it = function() {
183
183
  }, expression: "updateExistingDocTemplate" } }, [t("div", { staticClass: "text-gray-600" }, [e._v(" " + e._s(e.$t("updateExisting")) + " ")])])], 1)], 1) : e._e(), e.document && e.document.clients.length ? t("div", [t("CField", { staticStyle: { "padding-left": "calc(0.5 * var(--rem))", "margin-bottom": "calc(0.5 * var(--rem))" } }, [t("CCheckbox", { attrs: { type: "secondary", size: "normal" }, model: { value: e.keepClients, callback: function(a) {
184
184
  e.keepClients = a;
185
185
  }, expression: "keepClients" } }, [t("div", { staticClass: "text-gray-600" }, [e._v(" " + e._s(e.$t("keepClients")) + " ")])])], 1)], 1) : e._e()], 1), t("CButton", { staticStyle: { "margin-top": "1.5em" }, attrs: { loading: e.isPosting, type: "secondary", wide: "", taller: "" }, on: { click: e.onSave } }, [e._v(" " + e._s(e.actionButtonText) + " ")])], 1);
186
- }, at = [], st = /* @__PURE__ */ d(
186
+ }, it = [], at = /* @__PURE__ */ d(
187
+ et,
187
188
  tt,
188
189
  it,
189
- at,
190
190
  !1,
191
191
  null,
192
192
  "f544bca9",
193
193
  null,
194
194
  null
195
195
  );
196
- const j = st.exports;
196
+ const j = at.exports;
197
197
  function nt(i, { availableProducts: e }) {
198
198
  if (!i)
199
199
  throw new Error("Missing parameter templateId");
200
- const t = e, a = Object.keys(t).find((s) => {
200
+ const t = e, a = Object.keys(t).find((n) => {
201
201
  var o;
202
- const n = u(
203
- t[s],
202
+ const s = u(
203
+ t[n],
204
204
  "metadata.companyPurchase"
205
205
  );
206
- return (n == null ? void 0 : n.type) === "template" && ((o = n == null ? void 0 : n.data) == null ? void 0 : o.id) === i;
206
+ return (s == null ? void 0 : s.type) === "template" && ((o = s == null ? void 0 : s.data) == null ? void 0 : o.id) === i;
207
207
  });
208
208
  return a ? t[a] : null;
209
209
  }
210
- async function ot(i) {
210
+ async function st(i) {
211
211
  if (!i)
212
212
  throw new Error("Missing argument stripeProduct");
213
213
  const e = i == null ? void 0 : i.prices[0], { data: t } = await ae.createCheckoutSession({
@@ -223,20 +223,20 @@ async function ot(i) {
223
223
  window.open(a, "_blank");
224
224
  }
225
225
  function K(i, { availableProducts: e }) {
226
- var s, n, o;
226
+ var n, s, o;
227
227
  let t = null;
228
228
  const a = nt(i.templateId, { availableProducts: e });
229
229
  return a && (t = {
230
- price: U((s = a == null ? void 0 : a.prices) == null ? void 0 : s[0].amount, { currency: (n = a == null ? void 0 : a.prices) == null ? void 0 : n[0].currency }),
230
+ price: U((n = a == null ? void 0 : a.prices) == null ? void 0 : n[0].amount, { currency: (s = a == null ? void 0 : a.prices) == null ? void 0 : s[0].currency }),
231
231
  isPurchased: ((o = i.purchaseInfo) == null ? void 0 : o.isPurchased) || !1,
232
- onBuy: async () => ot(a)
232
+ onBuy: async () => st(a)
233
233
  }), t;
234
234
  }
235
- const lt = {
235
+ const ot = {
236
236
  name: "GalleryTemplateModal",
237
237
  components: {
238
238
  simplebar: L,
239
- DocumentLayout: Ae,
239
+ DocumentLayout: He,
240
240
  IsPremium: _,
241
241
  IsPremiumPreStep: k
242
242
  },
@@ -322,19 +322,19 @@ const lt = {
322
322
  }
323
323
  },
324
324
  created() {
325
- this.privateProduct = this.product, this.loadTemplateStat(), this.product && (this.socketUnsubscribeFn = se.on(
325
+ this.privateProduct = this.product, this.loadTemplateStat(), this.product && (this.socketUnsubscribeFn = ne.on(
326
326
  "event",
327
327
  async ({ type: i, action: e, data: t }) => {
328
328
  var a;
329
329
  if (i === "companyPurchase" && e === "applied" && (t == null ? void 0 : t.type) === "template") {
330
- const s = (a = t == null ? void 0 : t.data) == null ? void 0 : a.id;
331
- if (s !== this.template.id)
330
+ const n = (a = t == null ? void 0 : t.data) == null ? void 0 : a.id;
331
+ if (n !== this.template.id)
332
332
  return;
333
- const n = {
334
- templateId: s,
333
+ const s = {
334
+ templateId: n,
335
335
  isVisibleApp: !0,
336
336
  includePurchaseInfo: !0
337
- }, o = await this.fetchGallery(n);
337
+ }, o = await this.fetchGallery(s);
338
338
  this.privateProduct = K(
339
339
  o[0],
340
340
  { availableProducts: this.stripeProducts }
@@ -351,7 +351,7 @@ const lt = {
351
351
  const i = this.template.id;
352
352
  i || (this.templateStat = null);
353
353
  try {
354
- const { data: e } = await ne.get(i);
354
+ const { data: e } = await se.get(i);
355
355
  this.templateStat = e;
356
356
  } catch {
357
357
  this.templateStat = null;
@@ -368,44 +368,44 @@ const lt = {
368
368
  },
369
369
  async copyToClipboard(i) {
370
370
  const e = `${f.baseUrl}/template/${i}`;
371
- await G(e) && H("info", this.$t("copyMessage"));
371
+ await R(e) && H("info", this.$t("copyMessage"));
372
372
  }
373
373
  }
374
374
  };
375
- var rt = function() {
375
+ var lt = function() {
376
376
  var a;
377
377
  var e = this, t = e._self._c;
378
378
  return t("div", { staticClass: "bg-gray-200 template-modal font-inter" }, [t("div", { staticStyle: { "background-color": "white", "border-radius": "1em", overflow: "auto", border: "10px solid white", "box-shadow": "rgb(244, 244, 244) 0px 2px 14px 0px inset,", flex: "1 1 auto", "min-height": "0" } }, [t("simplebar", { staticClass: "w-full h-full", attrs: { "data-simplebar-auto-hide": "false" } }, [e.previewDocument ? t("DocumentLayout", { attrs: { document: e.previewDocument } }) : e._e(), e.product && !e.privateProduct.isPurchased ? t("style", { tag: "component" }, [e._v(" .ProseMirror > * + * { filter: blur(8px); user-select: none; pointer-events: none; } ")]) : e._e()], 1)], 1), t("div", { staticStyle: { flex: "0 1 300px", padding: "2em 1em 3em 2em", "font-size": "18px" } }, [t("div", { staticStyle: { "padding-bottom": "2em" } }, [t("div", { staticStyle: { "font-size": "21px", "font-weight": "800", color: "hsl(0, 0%, 0%)" } }, [e._v(" " + e._s(e.meta.name) + " ")]), t("div", { staticStyle: { "font-weight": "400", "font-size": "14px", "min-height": "30px", color: "hsl(0, 0%, 27%)" } }, [(a = e.templateStat) != null && a.usedTimes ? [e._v(" " + e._s(e.$t("_common:used").capitalize()) + " " + e._s(e.templateStat.usedTimes) + " " + e._s(e.$t("_common:times", { count: e.templateStat.usedTimes })) + " ")] : e._e()], 2), t("div", { staticStyle: { hyphens: "auto" } }, [e._v(" " + e._s(e.meta.text) + " ")]), e.meta.author ? t("div", { staticClass: "flex items-center", staticStyle: { "padding-top": "1.5em" } }, [t("div", { staticStyle: { "background-color": "#03f", "border-radius": "50%", width: "2.5em", height: "2.5em", "background-size": "cover", "background-position": "center", "background-repeat": "no-repeat" }, style: {
379
379
  backgroundImage: `url(${e.meta.author.avatar})`
380
380
  } }), t("div", { staticStyle: { "margin-left": "0.5em" } }, [t("div", { staticStyle: { "font-weight": "500" } }, [e._v(e._s(e.meta.author.name))]), t("div", { staticStyle: { "font-weight": "400", "font-size": "14px" } }, [e.meta.author.templatesCount ? [e._v(" " + e._s(e.meta.author.templatesCount) + " " + e._s(e.$t("_common:template", { count: e.meta.author.templatesCount })) + " ")] : [e._v(e._s(e.$t("_common:template").capitalize()))]], 2)])]) : e._e()]), t("div", { staticStyle: { "padding-bottom": "2em" } }, [e.product ? [e.privateProduct.isPurchased ? t("div", { staticClass: "flex items-center gap-2 p-1 mb-5 text-sm border border-gray-300 rounded-full bg-gray-300/60" }, [t("div", { staticClass: "flex items-center justify-center w-5 h-5 rounded-full bg-primary-500" }, [t("BaseIcon", { staticClass: "text-white", attrs: { type: "check", size: "12" } })], 1), t("div", { staticClass: "text-xs font-medium text-gray-700", domProps: { textContent: e._s(
381
381
  e.$t("_common:purchased", { thing: e.$t("_common:template") })
382
- ) } })]) : t("CButton", { staticClass: "text-left !justify-start !px-4", staticStyle: { "margin-bottom": "0.5em" }, attrs: { type: "secondary", wide: "" }, on: { click: e.buyTemplate } }, [t("div", [e._v(" " + e._s(e.$t("_common:buy", { thing: e.$t("_common:template") })) + " ")]), t("div", { staticClass: "absolute py-1.5 px-2 text-sm leading-none text-white -translate-y-1/2 border rounded-md right-2 top-1/2 bg-primary-400/80 border-primary-600/60", domProps: { textContent: e._s(e.privateProduct.price) } })])] : e._e(), t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canUseTemplate: s }) {
383
- return [t("IsPremiumPreStep", { attrs: { feature: "useDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: n }) {
382
+ ) } })]) : t("CButton", { staticClass: "text-left !justify-start !px-4", staticStyle: { "margin-bottom": "0.5em" }, attrs: { type: "secondary", wide: "" }, on: { click: e.buyTemplate } }, [t("div", [e._v(" " + e._s(e.$t("_common:buy", { thing: e.$t("_common:template") })) + " ")]), t("div", { staticClass: "absolute py-1.5 px-2 text-sm leading-none text-white -translate-y-1/2 border rounded-md right-2 top-1/2 bg-primary-400/80 border-primary-600/60", domProps: { textContent: e._s(e.privateProduct.price) } })])] : e._e(), t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canUseTemplate: n }) {
383
+ return [t("IsPremiumPreStep", { attrs: { feature: "useDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: s }) {
384
384
  return [!e.product || e.privateProduct.isPurchased ? t("CButton", { staticStyle: { "margin-bottom": "0.5em" }, attrs: { disabled: e.product ? !e.privateProduct.isPurchased : !1, type: "secondary", wide: "" }, on: { click: function(o) {
385
- e.isPublicForm || s ? e.useSelectedTemplate() : n({ callback: e.useSelectedTemplate });
385
+ e.isPublicForm || n ? e.useSelectedTemplate() : s({ callback: e.useSelectedTemplate });
386
386
  } } }, [e._v(" " + e._s(e.$t("_common:use", { thing: e.$t("_common:template") })) + " ")]) : e._e()];
387
387
  } }], null, !0) })];
388
- } }]) }), t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canCreateTemplate: s }) {
389
- return [t("IsPremiumPreStep", { attrs: { feature: "saveDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: n }) {
388
+ } }]) }), t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canCreateTemplate: n }) {
389
+ return [t("IsPremiumPreStep", { attrs: { feature: "saveDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: s }) {
390
390
  var o;
391
391
  return [(e.product ? (o = e.product) != null && o.isPurchased : e.showSave) ? t("CButton", { staticStyle: { "margin-bottom": "0.5em" }, attrs: { loading: e.isLoading, type: e.didSave ? "success" : "none", "icon-left": e.didSave ? "check" : void 0, wide: "" }, on: { click: function(l) {
392
- e.didSave || (e.isPublicForm || s ? e.saveAsTemplate() : n({ callback: e.saveAsTemplate }));
392
+ e.didSave || (e.isPublicForm || n ? e.saveAsTemplate() : s({ callback: e.saveAsTemplate }));
393
393
  } } }, [e._v(" " + e._s(e.didSave ? e.$t("_common:savedThing", { thing: e.$t("_common:template") }) : e.$t("_common:saveAs", { thing: e.$t("_common:template") })) + " ")]) : e._e()];
394
394
  } }], null, !0) })];
395
- } }]) }), e.allowCopyTemplateLink ? t("CButton", { attrs: { type: "none", "icon-left": "admin", wide: "" }, on: { click: function(s) {
395
+ } }]) }), e.allowCopyTemplateLink ? t("CButton", { attrs: { type: "none", "icon-left": "admin", wide: "" }, on: { click: function(n) {
396
396
  return e.copyToClipboard(e.template.id);
397
397
  } } }, [e._v(" " + e._s(e.$t("_common:copy", { thing: e.$t("_common:link") })) + " ")]) : e._e()], 2)])]);
398
- }, ct = [], dt = /* @__PURE__ */ d(
398
+ }, rt = [], ct = /* @__PURE__ */ d(
399
+ ot,
399
400
  lt,
400
401
  rt,
401
- ct,
402
402
  !1,
403
403
  null,
404
404
  "74568361",
405
405
  null,
406
406
  null
407
407
  );
408
- const pt = dt.exports, ut = {
408
+ const dt = ct.exports, pt = {
409
409
  name: "GalleryLogic",
410
410
  i18nOptions: {
411
411
  namespaces: "GalleryLogic",
@@ -533,13 +533,13 @@ const pt = dt.exports, ut = {
533
533
  this.$store.hasModule("stripe") || this.$store.registerModuleState("stripe", Fe);
534
534
  },
535
535
  async created() {
536
- var t, a, s, n;
536
+ var t, a, n, s;
537
537
  this.canPurchase && await this.loadPrices();
538
538
  let i = this.galleryCategory;
539
539
  !i && ((a = (t = this.$route) == null ? void 0 : t.query) != null && a.list) && ([i] = this.$route.query.list.split(",")), i && (this.activeCategory = this.allCategories.find(
540
540
  ({ key: o }) => o === i
541
541
  )), await this.loadTemplateGallery();
542
- const e = (n = (s = this.$route) == null ? void 0 : s.query) == null ? void 0 : n.id;
542
+ const e = (s = (n = this.$route) == null ? void 0 : n.query) == null ? void 0 : s.id;
543
543
  if (e)
544
544
  try {
545
545
  const o = this.templateGalleryItems.find(
@@ -582,13 +582,13 @@ const pt = dt.exports, ut = {
582
582
  }
583
583
  },
584
584
  async getGalleryTemplate(i) {
585
- var n;
585
+ var s;
586
586
  const e = {
587
587
  _id: i,
588
588
  populate: "templateId",
589
589
  isVisibleApp: !0,
590
590
  includePurchaseInfo: !0
591
- }, t = await this.fetchGallery(e), a = (n = t == null ? void 0 : t[0]) == null ? void 0 : n.templateId;
591
+ }, t = await this.fetchGallery(e), a = (s = t == null ? void 0 : t[0]) == null ? void 0 : s.templateId;
592
592
  return a ? (oe(a), new le(a)) : null;
593
593
  },
594
594
  onUseTemplate(i) {
@@ -612,7 +612,7 @@ const pt = dt.exports, ut = {
612
612
  fortnoxCom: "/img/fortnox/apple-touch-icon-180x180.png"
613
613
  };
614
614
  this.$modal.show(
615
- pt,
615
+ dt,
616
616
  {
617
617
  template: i,
618
618
  fetchGallery: this.fetchGallery,
@@ -667,30 +667,30 @@ const pt = dt.exports, ut = {
667
667
  selectGalleryItem: this.selectGalleryItem
668
668
  });
669
669
  }
670
- }, mt = null, ht = null;
671
- var ft = /* @__PURE__ */ d(
670
+ }, ut = null, mt = null;
671
+ var ht = /* @__PURE__ */ d(
672
+ pt,
672
673
  ut,
673
674
  mt,
674
- ht,
675
675
  !1,
676
676
  null,
677
677
  null,
678
678
  null,
679
679
  null
680
680
  );
681
- const gt = ft.exports;
682
- const Ct = {
681
+ const ft = ht.exports;
682
+ const gt = {
683
683
  name: "DocumentIcon",
684
684
  truncate: re,
685
685
  inject: {
686
686
  components: {
687
687
  default: {
688
- BlockMedia: Oe
688
+ BlockMedia: Ue
689
689
  }
690
690
  }
691
691
  }
692
692
  };
693
- var vt = function(e, t) {
693
+ var Ct = function(e, t) {
694
694
  return e("div", t._b({ key: t.data.key, staticClass: "item", class: [
695
695
  t.data.staticClass,
696
696
  t.data.class,
@@ -706,18 +706,18 @@ var vt = function(e, t) {
706
706
  } }) : t.props.isPlaceholder || t.props.isAdd ? t._e() : e(t.injections.components.BlockMedia, { tag: "component", staticClass: "item-media", attrs: { media: t.props.media, preview: "" } }), t.scopedSlots.badge ? e("div", { staticClass: "absolute right-2 bottom-2" }, [t._t("badge")], 2) : t._e(), t.props.isAdd ? e("div", { staticClass: "add-button" }, [e("BaseIcon", { attrs: { size: 18, "stroke-width": 3, type: "plus" } })], 1) : t._e()], 1), e("div", { staticClass: "item-footer" }, [t.props.isAdd ? e("div", { staticClass: "item-text", staticStyle: { color: "hsl(0, 0%, 55%)" }, domProps: { textContent: t._s(
707
707
  t.parent.$t("_common:empty", { thing: t.parent.$t("_common:template") })
708
708
  ) } }) : t.props.name ? [e("div", { staticClass: "item-text", domProps: { textContent: t._s(t.$options.truncate(t.props.name, 60)) } }), t._t("default")] : t._e()], 2)]);
709
- }, yt = [], xt = /* @__PURE__ */ d(
709
+ }, vt = [], yt = /* @__PURE__ */ d(
710
+ gt,
710
711
  Ct,
711
712
  vt,
712
- yt,
713
713
  !0,
714
714
  null,
715
715
  "e2f4722e",
716
716
  null,
717
717
  null
718
718
  );
719
- const wt = xt.exports;
720
- const bt = {
719
+ const xt = yt.exports;
720
+ const wt = {
721
721
  name: "HorizontalScroll",
722
722
  components: {
723
723
  Simplebar: L
@@ -747,10 +747,10 @@ const bt = {
747
747
  },
748
748
  methods: {
749
749
  go(i) {
750
- var s, n;
750
+ var n, s;
751
751
  if (!this.$refs.container)
752
752
  return;
753
- const e = (i > 0 ? 1 : -1) * (this.$refs.container.offsetWidth / 2), t = (n = (s = this.$refs) == null ? void 0 : s.list) == null ? void 0 : n.scrollElement;
753
+ const e = (i > 0 ? 1 : -1) * (this.$refs.container.offsetWidth / 2), t = (s = (n = this.$refs) == null ? void 0 : n.list) == null ? void 0 : s.scrollElement;
754
754
  if (!t)
755
755
  return;
756
756
  const { scrollLeft: a } = t;
@@ -762,8 +762,8 @@ const bt = {
762
762
  },
763
763
  scrollHandler() {
764
764
  clearTimeout(this.scrollTimer), this.scrollTimer = setTimeout(() => {
765
- var s, n;
766
- const i = (n = (s = this.$refs) == null ? void 0 : s.list) == null ? void 0 : n.scrollElement;
765
+ var n, s;
766
+ const i = (s = (n = this.$refs) == null ? void 0 : n.list) == null ? void 0 : s.scrollElement;
767
767
  if (!i)
768
768
  return;
769
769
  const { scrollWidth: e, scrollLeft: t, offsetWidth: a } = i;
@@ -772,7 +772,7 @@ const bt = {
772
772
  }
773
773
  }
774
774
  };
775
- var _t = function() {
775
+ var bt = function() {
776
776
  var e = this, t = e._self._c;
777
777
  return t("div", { ref: "container", staticClass: "horizontal-scroll" }, [t("div", { staticClass: "hl-navigation" }, [e.hasPrev ? t("div", { staticClass: "hl-btn-left max-sm:hidden", on: { click: function(a) {
778
778
  return e.go(-1);
@@ -785,18 +785,18 @@ var _t = function() {
785
785
  return e.$emit("expand");
786
786
  } } })];
787
787
  })], 2) : e._e()]), t("div", { staticClass: "hl-container" }, [t("Simplebar", { ref: "list", staticClass: "hl-list", on: { scroll: e.scrollHandler } }, [t("div", { staticClass: "flex w-full" }, [e._t("default")], 2)])], 1)]);
788
- }, kt = [], Lt = /* @__PURE__ */ d(
788
+ }, _t = [], kt = /* @__PURE__ */ d(
789
+ wt,
789
790
  bt,
790
791
  _t,
791
- kt,
792
792
  !1,
793
793
  null,
794
794
  "31e10485",
795
795
  null,
796
796
  null
797
797
  );
798
- const $t = Lt.exports;
799
- const St = {
798
+ const Lt = kt.exports;
799
+ const $t = {
800
800
  name: "DocumentFormRecent",
801
801
  i18nOptions: {
802
802
  namespaces: "DocumentFormRecent",
@@ -851,8 +851,8 @@ const St = {
851
851
  {
852
852
  clients: {
853
853
  $elemMatch: {
854
- $or: ["name", "email", "socialNo", "orgNo"].map((n) => ({
855
- [n]: { $regex: this.query, $options: "i" }
854
+ $or: ["name", "email", "socialNo", "orgNo"].map((s) => ({
855
+ [s]: { $regex: this.query, $options: "i" }
856
856
  }))
857
857
  }
858
858
  }
@@ -866,8 +866,8 @@ const St = {
866
866
  skip: i || 0,
867
867
  sort: "-createdAt",
868
868
  limit: 10
869
- }), { items: s = [] } = a || {};
870
- return s;
869
+ }), { items: n = [] } = a || {};
870
+ return n;
871
871
  },
872
872
  onLoadDocuments: P(async function() {
873
873
  this.isLoading = !0, this.hasItems = !0;
@@ -884,17 +884,17 @@ const St = {
884
884
  }
885
885
  }
886
886
  };
887
- var Tt = function() {
887
+ var St = function() {
888
888
  var e = this, t = e._self._c;
889
889
  return t("div", [t("div", { staticClass: "flex w-full", staticStyle: { "padding-bottom": "1em" } }, [e._t("default"), e.hasItems ? t("CInput", { staticClass: "hidden md:flex", attrs: { loading: e.isLoading, placeholder: e.$t("_common:search"), type: "search", size: "normal", filled: "" }, on: { input: e.onInput }, model: { value: e.query, callback: function(a) {
890
890
  e.query = a;
891
891
  }, expression: "query" } }) : e._e()], 2), t("div", { staticClass: "recent-list" }, [e.isLoading && !e.list.length ? e._l(3, function(a) {
892
892
  return t("div", { key: a, staticClass: "recent-item placeholder" }, [t("CSkeleton", { staticClass: "recent-item-name", attrs: { width: "60%" } }), t("CSkeleton", { attrs: { width: "35%" } })], 1);
893
- }) : !e.isLoading && !e.query && !e.list.length ? t("div", { staticClass: "p-4 text-center text-gray-400 bg-gray-100 border border-gray-200 rounded-md", staticStyle: { "font-size": "15px" } }, [e._v(" " + e._s(e.$t("emptyPlaceholder")) + " ")]) : e.query && !e.isLoading && !e.list.length ? t("div", { staticClass: "text-center text-gray-400", staticStyle: { padding: "1em" } }, [e._v(" " + e._s(e.$t("noResults")) + " ")]) : [t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canCreateTemplate: a, canUseTemplate: s }) {
894
- return [t("IsPremiumPreStep", { attrs: { feature: "useDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: n }) {
893
+ }) : !e.isLoading && !e.query && !e.list.length ? t("div", { staticClass: "p-4 text-center text-gray-400 bg-gray-100 border border-gray-200 rounded-md", staticStyle: { "font-size": "15px" } }, [e._v(" " + e._s(e.$t("emptyPlaceholder")) + " ")]) : e.query && !e.isLoading && !e.list.length ? t("div", { staticClass: "text-center text-gray-400", staticStyle: { padding: "1em" } }, [e._v(" " + e._s(e.$t("noResults")) + " ")]) : [t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canCreateTemplate: a, canUseTemplate: n }) {
894
+ return [t("IsPremiumPreStep", { attrs: { feature: "useDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: s }) {
895
895
  return [t("div", e._l(e.list, function(o, l) {
896
896
  return t("div", { key: o._id, staticClass: "recent-item", on: { click: function(r) {
897
- s ? e.onUseDocTemplate(o._id) : n({
897
+ n ? e.onUseDocTemplate(o._id) : s({
898
898
  callback: () => e.onUseDocTemplate(o._id)
899
899
  });
900
900
  }, "&mouseover": function(r) {
@@ -911,18 +911,18 @@ var Tt = function() {
911
911
  }), 0)];
912
912
  } }], null, !0) })];
913
913
  } }]) })]], 2)]);
914
- }, Dt = [], Vt = /* @__PURE__ */ d(
914
+ }, Tt = [], Dt = /* @__PURE__ */ d(
915
+ $t,
915
916
  St,
916
917
  Tt,
917
- Dt,
918
918
  !1,
919
919
  null,
920
920
  "496e96d5",
921
921
  null,
922
922
  null
923
923
  );
924
- const Bt = Vt.exports;
925
- const Mt = {
924
+ const Vt = Dt.exports;
925
+ const Bt = {
926
926
  i18nOptions: {
927
927
  namespaces: "TemplateSelector",
928
928
  messages: {
@@ -967,10 +967,10 @@ const Mt = {
967
967
  name: "TemplateSelector",
968
968
  mixins: [b],
969
969
  components: {
970
- HorizontalScroll: $t,
971
- DocumentIcon: wt,
972
- DocumentRecent: Bt,
973
- GalleryLogic: gt,
970
+ HorizontalScroll: Lt,
971
+ DocumentIcon: xt,
972
+ DocumentRecent: Vt,
973
+ GalleryLogic: ft,
974
974
  IsPremiumPreStep: k
975
975
  },
976
976
  props: {
@@ -1132,49 +1132,49 @@ const Mt = {
1132
1132
  },
1133
1133
  async copyToClipboard(i) {
1134
1134
  const e = `${f.baseUrl}/template/${i}`;
1135
- await G(e) && H("info", this.$t("copyMessage"));
1135
+ await R(e) && H("info", this.$t("copyMessage"));
1136
1136
  }
1137
1137
  }
1138
1138
  };
1139
- var It = function() {
1139
+ var Mt = function() {
1140
1140
  var e = this, t = e._self._c;
1141
1141
  return t("div", { staticClass: "w-full h-full px-4 pt-10 pb-10 overflow-y-auto bg-white md:pt-16 md:px-10 rounded-2xl" }, [t("div", { staticClass: "max-w-5xl mx-auto font-inter form-start main", class: { small: e.mq === "sm" } }, [e._t("header"), t("div", { staticStyle: { width: "100%", "padding-bottom": "5em" } }, [t("div", { staticClass: "section-title" }, [t("div", [e._v(e._s(e.$t("myTemplates")))]), t("div", { staticClass: "section-subtitle" }, [e._v(" " + e._s(e.$t("myTemplatesSubTitle")) + " ")])]), t("IsPremiumPreStep", { attrs: { feature: "useDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: a }) {
1142
- return [t(e.isExpanded ? "div" : "HorizontalScroll", { tag: "component", staticClass: "template-list", class: { "is-expanded": e.isExpanded }, on: { expand: function(s) {
1142
+ return [t(e.isExpanded ? "div" : "HorizontalScroll", { tag: "component", staticClass: "template-list", class: { "is-expanded": e.isExpanded }, on: { expand: function(n) {
1143
1143
  e.isExpanded = !0;
1144
- } } }, e._l(e.myTemplates, function(s) {
1145
- return t("DocumentIcon", { key: s.id, staticClass: "template-item", attrs: { "is-add": s.id === "empty", "is-placeholder": s.placeholder, media: s.defaultMedia || e.fallbackMedia, thumbnail: s.thumbnailUrl, name: s.name }, on: { click: function(n) {
1146
- s.placeholder || (e.canUseTemplate(s) ? e.select({ templateId: s.id }) : a());
1147
- } } }, [e.canUseTemplate(s) ? !s.doConsumeDocumentQuota && !s.placeholder ? t("div", { staticClass: "text-[11px] h-5 capitalize font-semibold text-white bg-primary-500 rounded leading-none px-1.5 inline-flex items-center border border-primary-600 shadow-sm", attrs: { slot: "badge" }, slot: "badge" }, [e._v(" " + e._s(e.$t("_common:free")) + " ")]) : e._e() : t("div", { staticClass: "inline-flex items-center h-5 gap-1 px-1 leading-none bg-gray-200 border border-gray-300 rounded shadow-sm text-gray-500/90", attrs: { slot: "badge" }, slot: "badge" }, [t("BaseIcon", { attrs: { type: "lock", size: "12", "stroke-width": "2.5" } }), t("div", { staticClass: "text-[11px] font-semibold" }, [e._v("Pro")])], 1), s.onModify === "create" && !s.doConsumeDocumentQuota ? t("CButton", { directives: [{ name: "tooltip", rawName: "v-tooltip", value: {
1144
+ } } }, e._l(e.myTemplates, function(n) {
1145
+ return t("DocumentIcon", { key: n.id, staticClass: "template-item", attrs: { "is-add": n.id === "empty", "is-placeholder": n.placeholder, media: n.defaultMedia || e.fallbackMedia, thumbnail: n.thumbnailUrl, name: n.name }, on: { click: function(s) {
1146
+ n.placeholder || (e.canUseTemplate(n) ? e.select({ templateId: n.id }) : a());
1147
+ } } }, [e.canUseTemplate(n) ? !n.doConsumeDocumentQuota && !n.placeholder ? t("div", { staticClass: "text-[11px] h-5 capitalize font-semibold text-white bg-primary-500 rounded leading-none px-1.5 inline-flex items-center border border-primary-600 shadow-sm", attrs: { slot: "badge" }, slot: "badge" }, [e._v(" " + e._s(e.$t("_common:free")) + " ")]) : e._e() : t("div", { staticClass: "inline-flex items-center h-5 gap-1 px-1 leading-none bg-gray-200 border border-gray-300 rounded shadow-sm text-gray-500/90", attrs: { slot: "badge" }, slot: "badge" }, [t("BaseIcon", { attrs: { type: "lock", size: "12", "stroke-width": "2.5" } }), t("div", { staticClass: "text-[11px] font-semibold" }, [e._v("Pro")])], 1), n.onModify === "create" && !n.doConsumeDocumentQuota ? t("CButton", { directives: [{ name: "tooltip", rawName: "v-tooltip", value: {
1148
1148
  content: e.$t("icon.freeTooltip"),
1149
1149
  placement: "bottom"
1150
1150
  }, expression: `{
1151
1151
  content: $t('icon.freeTooltip'),
1152
1152
  placement: 'bottom'
1153
- }` }], staticStyle: { top: "-8px", right: "-4px" }, attrs: { icon: "info", type: "none", pattern: "tertiary", size: "small" }, nativeOn: { click: function(n) {
1154
- n.stopPropagation();
1155
- } } }) : t("CDropdown", { staticStyle: { top: "-8px", right: "-4px" }, attrs: { "append-to-body": "" }, nativeOn: { click: function(n) {
1156
- n.stopPropagation();
1157
- } } }, [t("CButton", { directives: [{ name: "tooltip", rawName: "v-tooltip", value: e.$t("icon.tooltip"), expression: "$t('icon.tooltip')" }], attrs: { slot: "trigger", icon: "more-vertical", type: "none", pattern: "tertiary", size: "small" }, slot: "trigger" }), e.onEditTemplate ? t("CDropdownItem", { attrs: { "icon-left": "template-color" }, on: { click: function(n) {
1158
- return e.onEditTemplate(s.id);
1159
- } } }, [e._v(" " + e._s(e.$t("_common:edit", { thing: e.$t("_common:template") })) + " ")]) : e._e(), t("CDropdownItem", { attrs: { "icon-props": { size: 16 }, "icon-left": "edit" }, on: { click: function(n) {
1160
- return e.openTemplateFormModal({ template: s });
1161
- } } }, [e._v(" " + e._s(e.$t("_common:change", { thing: e.$t("_common:name") })) + " ")]), t("CDropdownItem", { attrs: { separator: "" } }), e.allowCopyTemplateLink ? [t("CDropdownItem", { attrs: { "icon-props": { size: 16 }, "icon-left": "admin" }, on: { click: function(n) {
1162
- return e.copyToClipboard(s.id);
1163
- } } }, [e._v(" " + e._s(e.$t("_common:copy", { thing: e.$t("_common:link") })) + " ")]), t("CDropdownItem", { attrs: { separator: "" } })] : e._e(), t("CDropdownItem", { attrs: { "icon-props": { size: 16, stroke: "hsl(360, 100%, 60%)" }, "icon-left": "trash" }, on: { click: function(n) {
1164
- return e.removeTemplate({ template: s });
1153
+ }` }], staticStyle: { top: "-8px", right: "-4px" }, attrs: { icon: "info", type: "none", pattern: "tertiary", size: "small" }, nativeOn: { click: function(s) {
1154
+ s.stopPropagation();
1155
+ } } }) : t("CDropdown", { staticStyle: { top: "-8px", right: "-4px" }, attrs: { "append-to-body": "" }, nativeOn: { click: function(s) {
1156
+ s.stopPropagation();
1157
+ } } }, [t("CButton", { directives: [{ name: "tooltip", rawName: "v-tooltip", value: e.$t("icon.tooltip"), expression: "$t('icon.tooltip')" }], attrs: { slot: "trigger", icon: "more-vertical", type: "none", pattern: "tertiary", size: "small" }, slot: "trigger" }), e.onEditTemplate ? t("CDropdownItem", { attrs: { "icon-left": "template-color" }, on: { click: function(s) {
1158
+ return e.onEditTemplate(n.id);
1159
+ } } }, [e._v(" " + e._s(e.$t("_common:edit", { thing: e.$t("_common:template") })) + " ")]) : e._e(), t("CDropdownItem", { attrs: { "icon-props": { size: 16 }, "icon-left": "edit" }, on: { click: function(s) {
1160
+ return e.openTemplateFormModal({ template: n });
1161
+ } } }, [e._v(" " + e._s(e.$t("_common:change", { thing: e.$t("_common:name") })) + " ")]), t("CDropdownItem", { attrs: { separator: "" } }), e.allowCopyTemplateLink ? [t("CDropdownItem", { attrs: { "icon-props": { size: 16 }, "icon-left": "admin" }, on: { click: function(s) {
1162
+ return e.copyToClipboard(n.id);
1163
+ } } }, [e._v(" " + e._s(e.$t("_common:copy", { thing: e.$t("_common:link") })) + " ")]), t("CDropdownItem", { attrs: { separator: "" } })] : e._e(), t("CDropdownItem", { attrs: { "icon-props": { size: 16, stroke: "hsl(360, 100%, 60%)" }, "icon-left": "trash" }, on: { click: function(s) {
1164
+ return e.removeTemplate({ template: n });
1165
1165
  } } }, [e._v(" " + e._s(e.$t("_common:remove")) + " ")])], 2)], 1);
1166
1166
  }), 1)];
1167
1167
  } }]) })], 1), e.showGallery ? [t("GalleryLogic", { attrs: { "fetch-gallery": e.fetchGallery, "use-template": e.select, "show-template-author": e.showGalleryTemplateAuthor, "modal-props": e.galleryModalProps, "gallery-category": e.galleryCategory }, scopedSlots: e._u([{ key: "default", fn: function({
1168
1168
  galleryItems: a,
1169
- categories: s,
1170
- activeCategory: n,
1169
+ categories: n,
1170
+ activeCategory: s,
1171
1171
  selectCategory: o,
1172
1172
  selectGalleryItem: l
1173
1173
  }) {
1174
1174
  return [t("div", { staticStyle: { width: "100%", "padding-bottom": "5em" } }, [t("div", { staticClass: "w-full section-title" }, [t("div", { staticClass: "flex justify-between items-center" }, [t("div", [e._v(e._s(e.$t("gallery")))]), t("CDropdown", { staticStyle: { "margin-left": "calc(0.5 * var(--rem))" }, nativeOn: { click: function(r) {
1175
1175
  r.stopPropagation();
1176
- } } }, [t("CButton", { attrs: { slot: "trigger", size: "small", type: "none", pattern: "secondary", "icon-right": "chevron-down" }, slot: "trigger" }, [e._v(" " + e._s(n ? n.label : "") + " ")]), e._l(s, function(r) {
1177
- return t("CDropdownItem", { key: r.key, attrs: { "icon-right": n && n.key === r.key ? "check" : "" }, on: { click: function(c) {
1176
+ } } }, [t("CButton", { attrs: { slot: "trigger", size: "small", type: "none", pattern: "secondary", "icon-right": "chevron-down" }, slot: "trigger" }, [e._v(" " + e._s(s ? s.label : "") + " ")]), e._l(n, function(r) {
1177
+ return t("CDropdownItem", { key: r.key, attrs: { "icon-right": s && s.key === r.key ? "check" : "" }, on: { click: function(c) {
1178
1178
  return o(r);
1179
1179
  } } }, [e._v(" " + e._s(r.label) + " ")]);
1180
1180
  })], 2)], 1), t("div", { staticClass: "section-subtitle", domProps: { innerHTML: e._s(e.$t("gallerySubTitle")) } })]), t("HorizontalScroll", { staticClass: "template-list" }, e._l(a, function(r) {
@@ -1183,9 +1183,9 @@ var It = function() {
1183
1183
  } } }, [r.product ? t("div", { staticClass: "p-1 text-xs font-semibold leading-none text-white border rounded shadow-lg bg-primary-500 border-primary-700/40", attrs: { slot: "badge" }, slot: "badge" }, [r.product.isPurchased ? t("BaseIcon", { attrs: { type: "check", size: "14", "stroke-width": "3" } }) : t("div", { domProps: { textContent: e._s(r.product.price) } })], 1) : e._e()]);
1184
1184
  }), 1)], 1)];
1185
1185
  } }], null, !1, 4232935324) })] : e._e(), t("DocumentRecent", { staticStyle: { width: "100%", "padding-bottom": "5em" }, on: { "use-doc-template": e.select, "save-template": e.openTemplateFormModal } }, [t("div", { staticClass: "section-title", staticStyle: { flex: "1 1 auto", "padding-bottom": "0.5em" } }, [t("div", [e._v(e._s(e.$t("recent")))]), t("div", { staticClass: "section-subtitle" }, [e._v(" " + e._s(e.$t("recentSubTitle")) + " ")])])])], 2)]);
1186
- }, Ft = [], Ht = /* @__PURE__ */ d(
1186
+ }, Ft = [], It = /* @__PURE__ */ d(
1187
+ Bt,
1187
1188
  Mt,
1188
- It,
1189
1189
  Ft,
1190
1190
  !1,
1191
1191
  null,
@@ -1193,8 +1193,8 @@ var It = function() {
1193
1193
  null,
1194
1194
  null
1195
1195
  );
1196
- const At = Ht.exports;
1197
- const Pt = (i) => {
1196
+ const Ht = It.exports;
1197
+ const At = (i) => {
1198
1198
  const e = Array(2).fill().map(() => p());
1199
1199
  return [
1200
1200
  {
@@ -1216,7 +1216,7 @@ const Pt = (i) => {
1216
1216
  nodeId: e[1]
1217
1217
  }
1218
1218
  ];
1219
- }, zt = (i, e = "en") => [
1219
+ }, Pt = (i, e = "en") => [
1220
1220
  { key: `title-${i}`, anyOf: [{ type: "string" }, { type: "null" }], defaultValue: h.t("attachment_plural", { lng: e }).capitalize() },
1221
1221
  {
1222
1222
  key: `files-${i}`,
@@ -1225,13 +1225,13 @@ const Pt = (i) => {
1225
1225
  $ref: `${f.api.baseUrl}/schemas/file/1.json`
1226
1226
  }
1227
1227
  }
1228
- ], Et = ({ document: i = null }) => {
1228
+ ], zt = ({ document: i = null }) => {
1229
1229
  const e = p(), { language: t } = i || {};
1230
1230
  return {
1231
- readView: Pt(e),
1232
- validation: zt(e, t)
1231
+ readView: At(e),
1232
+ validation: Pt(e, t)
1233
1233
  };
1234
- }, Zt = () => [
1234
+ }, Et = () => [
1235
1235
  {
1236
1236
  itemId: "presentation",
1237
1237
  itemType: "presentation",
@@ -1239,11 +1239,11 @@ const Pt = (i) => {
1239
1239
  parentId: "0",
1240
1240
  nodeId: p()
1241
1241
  }
1242
- ], Ut = () => ({
1243
- readView: Zt(),
1242
+ ], Zt = () => ({
1243
+ readView: Et(),
1244
1244
  validation: []
1245
1245
  // all relevant data is either within base doc or company settings etc
1246
- }), Ot = () => {
1246
+ }), Ut = () => {
1247
1247
  const i = Array(2).fill().map(() => p());
1248
1248
  return [
1249
1249
  {
@@ -1266,7 +1266,7 @@ const Pt = (i) => {
1266
1266
  // uniqid(),
1267
1267
  }
1268
1268
  ];
1269
- }, Gt = (i = "en") => [
1269
+ }, Ot = (i = "en") => [
1270
1270
  {
1271
1271
  key: "multiGroupPricing-title",
1272
1272
  anyOf: [{ type: "string" }, { type: "null" }],
@@ -1275,10 +1275,10 @@ const Pt = (i) => {
1275
1275
  ], Rt = ({ document: i = null }) => {
1276
1276
  const { language: e } = i || {};
1277
1277
  return {
1278
- readView: Ot(),
1279
- validation: Gt(e)
1278
+ readView: Ut(),
1279
+ validation: Ot(e)
1280
1280
  };
1281
- }, Wt = () => [
1281
+ }, Gt = () => [
1282
1282
  {
1283
1283
  itemId: "terms",
1284
1284
  itemType: "termsDisclaimer",
@@ -1296,7 +1296,7 @@ const Pt = (i) => {
1296
1296
  parentId: "0",
1297
1297
  nodeId: p()
1298
1298
  }
1299
- ], qt = () => [
1299
+ ], Wt = () => [
1300
1300
  {
1301
1301
  key: "terms",
1302
1302
  anyOf: [
@@ -1304,10 +1304,10 @@ const Pt = (i) => {
1304
1304
  { type: "null" }
1305
1305
  ]
1306
1306
  }
1307
- ], Nt = () => ({
1308
- readView: Wt(),
1309
- validation: qt()
1310
- }), jt = () => {
1307
+ ], qt = () => ({
1308
+ readView: Gt(),
1309
+ validation: Wt()
1310
+ }), Nt = () => {
1311
1311
  const i = Array(5).fill().map(() => p());
1312
1312
  return [
1313
1313
  {
@@ -1356,7 +1356,7 @@ const Pt = (i) => {
1356
1356
  nodeId: i[4]
1357
1357
  }
1358
1358
  ];
1359
- }, Kt = () => ({
1359
+ }, jt = () => ({
1360
1360
  clients: [{
1361
1361
  name: "Pernilla P.",
1362
1362
  email: "pernilla@mail.se",
@@ -1366,20 +1366,20 @@ const Pt = (i) => {
1366
1366
  deliveryTypes: ["email"],
1367
1367
  answerMethod: { accept: "signature", deny: "button" }
1368
1368
  }]
1369
- }), Yt = (i = "en") => [
1369
+ }), Kt = (i = "en") => [
1370
1370
  { key: "senderString", anyOf: [{ type: "string" }, { type: "null" }] },
1371
1371
  { key: "receiverString", anyOf: [{ type: "string" }, { type: "null" }] },
1372
1372
  { key: "partiesString", anyOf: [{ type: "string" }, { type: "null" }], defaultValue: h.t("components:document.chapters.parties.title", { lng: i }) }
1373
- ], Qt = ({ includeMockData: i = !1, document: e = null, contentData: t = null }) => {
1373
+ ], Yt = ({ includeMockData: i = !1, document: e = null, contentData: t = null }) => {
1374
1374
  const { language: a } = e || {};
1375
- let s = null;
1376
- return typeof t == "function" ? s = t() : i && (s = Kt()), {
1377
- readView: jt(),
1378
- validation: Yt(a),
1375
+ let n = null;
1376
+ return typeof t == "function" ? n = t() : i && (n = jt()), {
1377
+ readView: Nt(),
1378
+ validation: Kt(a),
1379
1379
  // Client / company will for now always exist on doc and in validation
1380
- ...s && { data: s }
1380
+ ...n && { data: n }
1381
1381
  };
1382
- }, Jt = (i) => {
1382
+ }, Qt = (i) => {
1383
1383
  const e = Array(3).fill().map(() => p());
1384
1384
  return [
1385
1385
  {
@@ -1408,7 +1408,7 @@ const Pt = (i) => {
1408
1408
  nodeId: e[2]
1409
1409
  }
1410
1410
  ];
1411
- }, Xt = (i) => [
1411
+ }, Jt = (i) => [
1412
1412
  {
1413
1413
  key: `estimatedTimeComplete-${i}`,
1414
1414
  type: "object",
@@ -1429,20 +1429,20 @@ const Pt = (i) => {
1429
1429
  }
1430
1430
  }
1431
1431
  }
1432
- ], e1 = (i) => ({
1432
+ ], Xt = (i) => ({
1433
1433
  [`estimatedTimeComplete-${i}`]: {
1434
1434
  value: 4,
1435
1435
  unitType: "hour"
1436
1436
  }
1437
- }), t1 = ({ includeMockData: i = !1, contentData: e = null }) => {
1437
+ }), e1 = ({ includeMockData: i = !1, contentData: e = null }) => {
1438
1438
  const t = p();
1439
1439
  let a = null;
1440
- return typeof e == "function" ? a = e(t) : i && (a = e1(t)), {
1441
- readView: Jt(t),
1442
- validation: Xt(t),
1440
+ return typeof e == "function" ? a = e(t) : i && (a = Xt(t)), {
1441
+ readView: Qt(t),
1442
+ validation: Jt(t),
1443
1443
  ...a && { data: a }
1444
1444
  };
1445
- }, i1 = () => {
1445
+ }, t1 = () => {
1446
1446
  const i = Array(3).fill().map(() => p());
1447
1447
  return [
1448
1448
  {
@@ -1476,7 +1476,7 @@ const Pt = (i) => {
1476
1476
  nodeId: i[2]
1477
1477
  }
1478
1478
  ];
1479
- }, a1 = () => [
1479
+ }, i1 = () => [
1480
1480
  {
1481
1481
  key: "estimatedWorkDates",
1482
1482
  type: "object",
@@ -1485,9 +1485,9 @@ const Pt = (i) => {
1485
1485
  endAt: { anyOf: [{ type: "null" }, { type: "string" }] }
1486
1486
  }
1487
1487
  }
1488
- ], s1 = () => ({
1489
- readView: i1(),
1490
- validation: a1()
1488
+ ], a1 = () => ({
1489
+ readView: t1(),
1490
+ validation: i1()
1491
1491
  }), n1 = () => {
1492
1492
  const i = Array(5).fill().map(() => p());
1493
1493
  return [
@@ -1554,7 +1554,7 @@ const Pt = (i) => {
1554
1554
  nodeId: i[4]
1555
1555
  }
1556
1556
  ];
1557
- }, o1 = () => [
1557
+ }, s1 = () => [
1558
1558
  {
1559
1559
  key: "extraWorkConstruction",
1560
1560
  extraWorkConstruction: {
@@ -1578,11 +1578,11 @@ const Pt = (i) => {
1578
1578
  }
1579
1579
  }
1580
1580
  }
1581
- ], l1 = () => ({
1581
+ ], o1 = () => ({
1582
1582
  readView: n1(),
1583
- validation: o1()
1583
+ validation: s1()
1584
1584
  // Client / company will for now always exist on doc and in validation
1585
- }), r1 = () => {
1585
+ }), l1 = () => {
1586
1586
  const i = Array(3).fill().map(() => p());
1587
1587
  return [
1588
1588
  {
@@ -1622,7 +1622,7 @@ const Pt = (i) => {
1622
1622
  nodeId: i[2]
1623
1623
  }
1624
1624
  ];
1625
- }, c1 = () => [
1625
+ }, r1 = () => [
1626
1626
  {
1627
1627
  key: "extraWorkTimeImpact",
1628
1628
  anyOf: [
@@ -1646,10 +1646,10 @@ const Pt = (i) => {
1646
1646
  }
1647
1647
  ]
1648
1648
  }
1649
- ], d1 = () => ({
1650
- readView: r1(),
1651
- validation: c1()
1652
- }), p1 = () => {
1649
+ ], c1 = () => ({
1650
+ readView: l1(),
1651
+ validation: r1()
1652
+ }), d1 = () => {
1653
1653
  const i = Array(5).fill().map(() => p());
1654
1654
  return [
1655
1655
  {
@@ -1702,13 +1702,13 @@ const Pt = (i) => {
1702
1702
  nodeId: i[4]
1703
1703
  }
1704
1704
  ];
1705
- }, u1 = () => [
1705
+ }, p1 = () => [
1706
1706
  { key: "miscAgreements", anyOf: [{ type: "string" }, { type: null }] },
1707
1707
  { key: "notBinding", type: "boolean" }
1708
- ], m1 = () => ({
1709
- readView: p1(),
1710
- validation: u1()
1711
- }), h1 = (i) => {
1708
+ ], u1 = () => ({
1709
+ readView: d1(),
1710
+ validation: p1()
1711
+ }), m1 = (i) => {
1712
1712
  const e = Array(2).fill().map(() => p());
1713
1713
  return [
1714
1714
  {
@@ -1730,22 +1730,22 @@ const Pt = (i) => {
1730
1730
  nodeId: e[1]
1731
1731
  }
1732
1732
  ];
1733
- }, f1 = (i) => [
1733
+ }, h1 = (i) => [
1734
1734
  { key: `title-${i}`, anyOf: [{ type: "string" }, { type: "null" }], defaultValue: "" },
1735
1735
  { key: `content-${i}`, anyOf: [{ type: "string" }, { type: "null" }] }
1736
- ], g1 = (i) => ({
1736
+ ], f1 = (i) => ({
1737
1737
  [`data.title-${i}`]: "My custom text",
1738
1738
  [`data.content-${i}`]: "<p>First impressions matter. Make it count by sending beautiful proposals to your clients. Proposals that look great on any device. Proposals that help you to close with notifications and digital signatures.</p>"
1739
- }), C1 = ({ includeMockData: i = !1, contentData: e = null }) => {
1739
+ }), g1 = ({ includeMockData: i = !1, contentData: e = null }) => {
1740
1740
  const t = p();
1741
1741
  let a = null;
1742
- return typeof e == "function" ? a = e(t) : i && (a = g1(t)), {
1743
- readView: h1(t),
1744
- validation: f1(t),
1742
+ return typeof e == "function" ? a = e(t) : i && (a = f1(t)), {
1743
+ readView: m1(t),
1744
+ validation: h1(t),
1745
1745
  ...a && { data: a },
1746
1746
  onAddFnName: "conditionalOnAdd"
1747
1747
  };
1748
- }, v1 = (i) => [
1748
+ }, C1 = (i) => [
1749
1749
  {
1750
1750
  itemId: "coverBlock",
1751
1751
  itemType: "coverBlock",
@@ -1755,7 +1755,7 @@ const Pt = (i) => {
1755
1755
  parentId: "0",
1756
1756
  nodeId: p()
1757
1757
  }
1758
- ], y1 = (i, e = "en") => [
1758
+ ], v1 = (i, e = "en") => [
1759
1759
  {
1760
1760
  key: `coverBlock-${i}`,
1761
1761
  defaultValue: {
@@ -1772,7 +1772,7 @@ const Pt = (i) => {
1772
1772
  },
1773
1773
  $ref: `${f.api.baseUrl}/schemas/coverBlock/1.json`
1774
1774
  }
1775
- ], x1 = (i) => ({
1775
+ ], y1 = (i) => ({
1776
1776
  [`data.coverBlock-${i}`]: {
1777
1777
  text: "<h1>We know communication</h1>",
1778
1778
  cover: {
@@ -1782,15 +1782,15 @@ const Pt = (i) => {
1782
1782
  blur: 0
1783
1783
  }
1784
1784
  }
1785
- }), w1 = ({ includeMockData: i = !1, document: e = null, contentData: t = null } = {}) => {
1786
- const a = p(), { language: s } = e || {};
1787
- let n = null;
1788
- return typeof t == "function" ? n = t(a) : i && (n = x1(a)), {
1789
- readView: v1(a),
1790
- validation: y1(a, s),
1791
- ...n && { data: n }
1785
+ }), x1 = ({ includeMockData: i = !1, document: e = null, contentData: t = null } = {}) => {
1786
+ const a = p(), { language: n } = e || {};
1787
+ let s = null;
1788
+ return typeof t == "function" ? s = t(a) : i && (s = y1(a)), {
1789
+ readView: C1(a),
1790
+ validation: v1(a, n),
1791
+ ...s && { data: s }
1792
1792
  };
1793
- }, b1 = ({ language: i = "en" } = {}) => {
1793
+ }, w1 = ({ language: i = "en" } = {}) => {
1794
1794
  const e = (t) => h.t(`components:account.documentForm.contentItems.coverBlock.${t}`, {
1795
1795
  lng: i
1796
1796
  });
@@ -1935,7 +1935,7 @@ const Pt = (i) => {
1935
1935
  })
1936
1936
  }
1937
1937
  ];
1938
- }, _1 = (i) => [
1938
+ }, b1 = (i) => [
1939
1939
  {
1940
1940
  itemId: `header-${i}`,
1941
1941
  itemType: "header",
@@ -1945,18 +1945,18 @@ const Pt = (i) => {
1945
1945
  parentId: "0",
1946
1946
  nodeId: p()
1947
1947
  }
1948
- ], k1 = (i, e = null) => {
1948
+ ], _1 = (i, e = null) => {
1949
1949
  const {
1950
1950
  language: t = "en",
1951
1951
  name: a = "",
1952
- theme: s
1953
- } = e || {}, n = a || h.t("_common:proposal", { lng: t }).capitalize();
1954
- e && (e.name = n);
1952
+ theme: n
1953
+ } = e || {}, s = a || h.t("_common:proposal", { lng: t }).capitalize();
1954
+ e && (e.name = s);
1955
1955
  const {
1956
1956
  background: o,
1957
1957
  priceSummaryBackground: l,
1958
1958
  backgroundFilter: r
1959
- } = s || {}, c = l || "hsl(228, 52%, 18%)", C = Re.readability(c, "#fff") < 1.8 ? "#111111" : "#FFFFFF";
1959
+ } = n || {}, c = l || "hsl(228, 52%, 18%)", C = Re.readability(c, "#fff") < 1.8 ? "#111111" : "#FFFFFF";
1960
1960
  return [
1961
1961
  {
1962
1962
  key: `header-${i}`,
@@ -1987,7 +1987,7 @@ const Pt = (i) => {
1987
1987
  },
1988
1988
  value: {
1989
1989
  preText: "",
1990
- documentName: `<p data-typography="title">${n}</p>`,
1990
+ documentName: `<p data-typography="title">${s}</p>`,
1991
1991
  postText: h.t("components:document.chapters.header.postText", { lng: t, interpolation: { prefix: "__", suffix: "__" } }),
1992
1992
  showLogo: !0,
1993
1993
  logotype: ""
@@ -1997,7 +1997,7 @@ const Pt = (i) => {
1997
1997
  }
1998
1998
  }
1999
1999
  ];
2000
- }, L1 = (i) => ({
2000
+ }, k1 = (i) => ({
2001
2001
  [`data.header-${i}`]: {
2002
2002
  layout: "vertical",
2003
2003
  baseStyle: { textAlign: "left", textColor: "#FFFFFF" },
@@ -2027,15 +2027,15 @@ const Pt = (i) => {
2027
2027
  }
2028
2028
  ]
2029
2029
  }
2030
- }), $1 = ({ includeMockData: i = !1, document: e = null, contentData: t = null }) => {
2030
+ }), L1 = ({ includeMockData: i = !1, document: e = null, contentData: t = null }) => {
2031
2031
  const a = p();
2032
- let s = null;
2033
- return typeof t == "function" ? s = t(a) : i && (s = L1(a)), {
2034
- readView: _1(a),
2035
- validation: k1(a, e),
2036
- ...s && { data: s }
2032
+ let n = null;
2033
+ return typeof t == "function" ? n = t(a) : i && (n = k1(a)), {
2034
+ readView: b1(a),
2035
+ validation: _1(a, e),
2036
+ ...n && { data: n }
2037
2037
  };
2038
- }, S1 = ({ language: i = "en" } = {}) => {
2038
+ }, $1 = ({ language: i = "en" } = {}) => {
2039
2039
  const e = (t) => h.t(`components:account.documentForm.contentItems.header.${t}`, {
2040
2040
  lng: i,
2041
2041
  interpolation: { prefix: "__", suffix: "__" }
@@ -2335,7 +2335,7 @@ h.loadOptions({
2335
2335
  }
2336
2336
  }
2337
2337
  });
2338
- const T1 = (i) => {
2338
+ const S1 = (i) => {
2339
2339
  const e = Array(2).fill().map(() => p());
2340
2340
  return [
2341
2341
  {
@@ -2360,7 +2360,7 @@ const T1 = (i) => {
2360
2360
  nodeId: e[1]
2361
2361
  }
2362
2362
  ];
2363
- }, D1 = (i, e = "en") => [
2363
+ }, T1 = (i, e = "en") => [
2364
2364
  {
2365
2365
  key: `packageGroups.${i}`,
2366
2366
  validationKey: "packageGroups",
@@ -2380,15 +2380,15 @@ const T1 = (i) => {
2380
2380
  },
2381
2381
  $ref: `${f.api.baseUrl}/schemas/packageGroups/1.json`
2382
2382
  }
2383
- ], V1 = () => null, B1 = ({ includeMockData: i, document: e = null, contentData: t = null } = {}) => {
2384
- const a = p(), { language: s } = e || {};
2385
- let n = null;
2386
- typeof t == "function" ? n = t(a) : i && (n = V1());
2387
- const o = T1(a), l = D1(a, s);
2383
+ ], D1 = () => null, V1 = ({ includeMockData: i, document: e = null, contentData: t = null } = {}) => {
2384
+ const a = p(), { language: n } = e || {};
2385
+ let s = null;
2386
+ typeof t == "function" ? s = t(a) : i && (s = D1());
2387
+ const o = S1(a), l = T1(a, n);
2388
2388
  return {
2389
2389
  readView: o,
2390
2390
  validation: l,
2391
- ...n && { data: n }
2391
+ ...s && { data: s }
2392
2392
  };
2393
2393
  };
2394
2394
  h.loadOptions({
@@ -2476,13 +2476,13 @@ h.loadOptions({
2476
2476
  }
2477
2477
  }
2478
2478
  });
2479
- const M1 = ({
2479
+ const B1 = ({
2480
2480
  language: i = "en",
2481
2481
  currency: e = "USD",
2482
2482
  _getters: t,
2483
2483
  allArticles: a = []
2484
2484
  } = {}) => {
2485
- const s = u(t, "settings/defaultVatRate") || null, n = !u(t, "settings/hidePriceOnNewlyAddedArticles"), o = (l) => h.t(`packageGroupContentItems:${l}`, { lng: i });
2485
+ const n = u(t, "settings/defaultVatRate") || null, s = !u(t, "settings/hidePriceOnNewlyAddedArticles"), o = (l) => h.t(`packageGroupContentItems:${l}`, { lng: i });
2486
2486
  return [
2487
2487
  {
2488
2488
  previewUrl: `
@@ -2550,8 +2550,8 @@ const M1 = ({
2550
2550
  articles: [
2551
2551
  ...a,
2552
2552
  y({
2553
- vat: s,
2554
- showPrice: n,
2553
+ vat: n,
2554
+ showPrice: s,
2555
2555
  currency: e,
2556
2556
  packageId: r,
2557
2557
  name: o("single.art"),
@@ -2679,16 +2679,16 @@ const M1 = ({
2679
2679
  articles: [
2680
2680
  ...a,
2681
2681
  y({
2682
- vat: s,
2683
- showPrice: n,
2682
+ vat: n,
2683
+ showPrice: s,
2684
2684
  currency: e,
2685
2685
  packageId: r[0],
2686
2686
  name: o("radio.artA"),
2687
2687
  price: 1e5
2688
2688
  }),
2689
2689
  y({
2690
- vat: s,
2691
- showPrice: n,
2690
+ vat: n,
2691
+ showPrice: s,
2692
2692
  currency: e,
2693
2693
  packageId: r[1],
2694
2694
  name: o("radio.artB"),
@@ -2813,16 +2813,16 @@ const M1 = ({
2813
2813
  articles: [
2814
2814
  ...a,
2815
2815
  y({
2816
- vat: s,
2817
- showPrice: n,
2816
+ vat: n,
2817
+ showPrice: s,
2818
2818
  currency: e,
2819
2819
  packageId: r[0],
2820
2820
  name: o("checkbox.artBase"),
2821
2821
  price: 1e5
2822
2822
  }),
2823
2823
  y({
2824
- vat: s,
2825
- showPrice: n,
2824
+ vat: n,
2825
+ showPrice: s,
2826
2826
  currency: e,
2827
2827
  packageId: r[1],
2828
2828
  name: o("checkbox.artOption"),
@@ -2833,7 +2833,7 @@ const M1 = ({
2833
2833
  }
2834
2834
  }
2835
2835
  ];
2836
- }, I1 = (i) => [
2836
+ }, M1 = (i) => [
2837
2837
  {
2838
2838
  itemId: "embed",
2839
2839
  itemType: "embed",
@@ -2856,13 +2856,13 @@ const M1 = ({
2856
2856
  size: "small"
2857
2857
  }
2858
2858
  }
2859
- ], H1 = () => null, A1 = ({ includeMockData: i = !1, document: e = null, contentData: t = null } = {}) => {
2859
+ ], I1 = () => null, H1 = ({ includeMockData: i = !1, document: e = null, contentData: t = null } = {}) => {
2860
2860
  const a = p();
2861
- let s = null;
2862
- return typeof t == "function" ? s = t(a) : i && (s = H1()), {
2863
- readView: I1(a),
2861
+ let n = null;
2862
+ return typeof t == "function" ? n = t(a) : i && (n = I1()), {
2863
+ readView: M1(a),
2864
2864
  validation: F1(a),
2865
- ...s && { data: s }
2865
+ ...n && { data: n }
2866
2866
  };
2867
2867
  };
2868
2868
  h.loadOptions({
@@ -2876,7 +2876,7 @@ h.loadOptions({
2876
2876
  }
2877
2877
  }
2878
2878
  });
2879
- const P1 = ({ language: i = "en" } = {}) => [
2879
+ const A1 = ({ language: i = "en" } = {}) => [
2880
2880
  {
2881
2881
  previewUrl: `
2882
2882
  <div style="position: relative;">
@@ -3168,7 +3168,7 @@ const P1 = ({ language: i = "en" } = {}) => [
3168
3168
  }
3169
3169
  })
3170
3170
  }
3171
- ], z1 = (i) => [
3171
+ ], P1 = (i) => [
3172
3172
  {
3173
3173
  itemId: "videoPlayer",
3174
3174
  itemType: "videoPlayer",
@@ -3181,7 +3181,7 @@ const P1 = ({ language: i = "en" } = {}) => [
3181
3181
  parentId: "0",
3182
3182
  nodeId: p()
3183
3183
  }
3184
- ], E1 = (i) => [
3184
+ ], z1 = (i) => [
3185
3185
  {
3186
3186
  key: `video-${i}`,
3187
3187
  $ref: `${f.api.baseUrl}/schemas/videoPlayer/1.json`,
@@ -3192,7 +3192,7 @@ const P1 = ({ language: i = "en" } = {}) => [
3192
3192
  }
3193
3193
  }
3194
3194
  }
3195
- ], Z1 = (i) => ({
3195
+ ], E1 = (i) => ({
3196
3196
  [`data.video-${i}`]: {
3197
3197
  size: "small",
3198
3198
  video: {
@@ -3201,15 +3201,15 @@ const P1 = ({ language: i = "en" } = {}) => [
3201
3201
  id: "166JEb6qkr4"
3202
3202
  }
3203
3203
  }
3204
- }), U1 = ({ includeMockData: i = !1, contentData: e = null }) => {
3204
+ }), Z1 = ({ includeMockData: i = !1, contentData: e = null }) => {
3205
3205
  const t = p();
3206
3206
  let a = null;
3207
- return typeof e == "function" ? a = e(t) : i && (a = Z1(t)), {
3208
- readView: z1(t),
3209
- validation: E1(t),
3207
+ return typeof e == "function" ? a = e(t) : i && (a = E1(t)), {
3208
+ readView: P1(t),
3209
+ validation: z1(t),
3210
3210
  ...a && { data: a }
3211
3211
  };
3212
- }, O1 = ({ language: i = "en" } = {}) => [
3212
+ }, U1 = ({ language: i = "en" } = {}) => [
3213
3213
  {
3214
3214
  previewUrl: `
3215
3215
  <div style="position: relative;">
@@ -3411,34 +3411,34 @@ const P1 = ({ language: i = "en" } = {}) => [
3411
3411
  })
3412
3412
  }
3413
3413
  ], E = {
3414
- titleAndText2: C1,
3415
- attachments2: Et,
3414
+ titleAndText2: g1,
3415
+ attachments2: zt,
3416
3416
  pdf: he,
3417
- packageGroup: B1,
3417
+ packageGroup: V1,
3418
3418
  multiGroupPricing: Rt,
3419
- coverBlock: w1,
3420
- videoPlayer: U1,
3421
- embed: A1,
3422
- header: $1,
3419
+ coverBlock: x1,
3420
+ videoPlayer: Z1,
3421
+ embed: H1,
3422
+ header: L1,
3423
3423
  answer: fe,
3424
- terms: Nt,
3425
- parties: Qt,
3424
+ terms: qt,
3425
+ parties: Yt,
3426
3426
  custom: ge,
3427
3427
  // legacy
3428
- presentation: Ut,
3429
- estimatedTimeCompleted: t1,
3430
- estimatedWorkStartAndEndAtText: s1,
3431
- extraWorkConstructionPricingList: l1,
3432
- extraWorkTimeImpactText: d1,
3433
- notBinding: m1
3428
+ presentation: Zt,
3429
+ estimatedTimeCompleted: e1,
3430
+ estimatedWorkStartAndEndAtText: a1,
3431
+ extraWorkConstructionPricingList: o1,
3432
+ extraWorkTimeImpactText: c1,
3433
+ notBinding: u1
3434
3434
  }, Z = {
3435
- coverBlock: b1,
3436
- header: S1,
3437
- packageGroup: M1,
3438
- embed: P1,
3439
- videoPlayer: O1,
3435
+ coverBlock: w1,
3436
+ header: $1,
3437
+ packageGroup: B1,
3438
+ embed: A1,
3439
+ videoPlayer: U1,
3440
3440
  custom: me
3441
- }, G1 = {
3441
+ }, O1 = {
3442
3442
  name: "AddBlock",
3443
3443
  props: {
3444
3444
  set: {
@@ -3467,19 +3467,19 @@ const P1 = ({ language: i = "en" } = {}) => [
3467
3467
  )
3468
3468
  });
3469
3469
  }
3470
- }, R1 = null, W1 = null;
3471
- var q1 = /* @__PURE__ */ d(
3472
- G1,
3470
+ }, R1 = null, G1 = null;
3471
+ var W1 = /* @__PURE__ */ d(
3472
+ O1,
3473
3473
  R1,
3474
- W1,
3474
+ G1,
3475
3475
  !1,
3476
3476
  null,
3477
3477
  null,
3478
3478
  null,
3479
3479
  null
3480
3480
  );
3481
- const Y = q1.exports;
3482
- const N1 = {
3481
+ const Y = W1.exports;
3482
+ const q1 = {
3483
3483
  name: "Drawer",
3484
3484
  props: {
3485
3485
  value: {
@@ -3522,7 +3522,7 @@ const N1 = {
3522
3522
  }
3523
3523
  }
3524
3524
  };
3525
- var j1 = function() {
3525
+ var N1 = function() {
3526
3526
  var e = this, t = e._self._c;
3527
3527
  return t("div", [t("transition", { attrs: { name: "fade" } }, [!e.hideOverlay && e.value ? t("div", { staticClass: "d-overlay", style: {
3528
3528
  zIndex: e.zIndex
@@ -3538,18 +3538,18 @@ var j1 = function() {
3538
3538
  boxShadow: e.boxShadow,
3539
3539
  ...e.contentStyle
3540
3540
  } }, [e._t("default")], 2)]) : e._e()])], 1);
3541
- }, K1 = [], Y1 = /* @__PURE__ */ d(
3541
+ }, j1 = [], K1 = /* @__PURE__ */ d(
3542
+ q1,
3542
3543
  N1,
3543
3544
  j1,
3544
- K1,
3545
3545
  !1,
3546
3546
  null,
3547
3547
  "cd4a251a",
3548
3548
  null,
3549
3549
  null
3550
3550
  );
3551
- const Q = Y1.exports;
3552
- const Q1 = {
3551
+ const Q = K1.exports;
3552
+ const Y1 = {
3553
3553
  name: "DocumentSend",
3554
3554
  i18nOptions: {
3555
3555
  namespaces: "documentSend",
@@ -3575,7 +3575,7 @@ const Q1 = {
3575
3575
  components: {
3576
3576
  AddBlock: Y,
3577
3577
  Drawer: Q,
3578
- SendForm: We,
3578
+ SendForm: Ge,
3579
3579
  CCheckbox: ye,
3580
3580
  BaseIcon: xe,
3581
3581
  CButton: we,
@@ -3670,7 +3670,7 @@ const Q1 = {
3670
3670
  }
3671
3671
  }
3672
3672
  };
3673
- var J1 = function() {
3673
+ var Q1 = function() {
3674
3674
  var e = this, t = e._self._c;
3675
3675
  return e.mq !== "sm" || e.isOpen ? t(e.mq === "sm" ? "div" : "Drawer", { tag: "component", attrs: { placement: "right" }, model: { value: e.isOpen, callback: function(a) {
3676
3676
  e.isOpen = a;
@@ -3679,31 +3679,31 @@ var J1 = function() {
3679
3679
  } }, [t("CButton", { staticStyle: { position: "absolute", right: "1em", top: "1em", "z-index": "99" }, attrs: { circle: "", icon: "x", pattern: "secondary" }, on: { click: function(a) {
3680
3680
  e.isOpen = !1;
3681
3681
  } } }), t("SendForm", { attrs: { _document: e._document, _value: e._value, "set-form-value": e.setFormValue, "remove-form-value": e.removeFormValue, "on-save-document": e.onSaveDoc, "use-scroll": "" } }, [e.hasAnswerBlock ? e._e() : t("div", { key: "1", staticClass: "flex p-3 mb-8 border border-red-200 rounded-lg bg-red-50" }, [t("div", [t("BaseIcon", { staticClass: "-mt-1 text-red-600", attrs: { type: "error", size: "18" } })], 1), t("div", [t("div", { staticClass: "pl-2" }, [t("div", { staticClass: "text-sm font-semibold text-red-600", domProps: { textContent: e._s(e.$t("signMissingTitle")) } }), t("div", { staticClass: "mb-4 text-sm text-red-600 text-opacity-80" }, [e._v(" " + e._s(e.$t("signMissingText")) + " ")])]), t("AddBlock", { attrs: { set: e.setFormValue }, scopedSlots: e._u([{ key: "default", fn: function({ addBlock: a }) {
3682
- return [t("CButton", { staticClass: "is-left", attrs: { type: "secondary", size: "small" }, on: { click: function(s) {
3682
+ return [t("CButton", { staticClass: "is-left", attrs: { type: "secondary", size: "small" }, on: { click: function(n) {
3683
3683
  return a({ sectionKey: "answer" });
3684
3684
  } } }, [e._v(" " + e._s(e.$t("signMissingAdd")) + " ")])];
3685
3685
  } }], null, !1, 2898075047) })], 1)]), e.isPublicForm ? t("CButton", { staticStyle: { height: "48px" }, attrs: { slot: "send", type: "secondary", wide: "" }, on: { click: e.onSaveDocument }, slot: "send" }, [e._v(" " + e._s(e.$t("signupToSend")) + " ")]) : e._e(), t("label", { staticClass: "text-gray-600", staticStyle: { display: "inline-flex", "align-items": "center", cursor: "pointer", "user-select": "none", "font-size": "12px", "font-weight": "500", "padding-top": "calc(1 * var(--rem))" }, attrs: { slot: "footer", for: "checkbox-save-as-temp" }, slot: "footer" }, [t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canCreateTemplate: a }) {
3686
- return [t("IsPremiumPreStep", { attrs: { feature: "saveDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: s }) {
3687
- return [t("div", { staticClass: "flex items-center", on: { click: (n) => e.onClickSaveAsTemplate({
3688
- event: n,
3686
+ return [t("IsPremiumPreStep", { attrs: { feature: "saveDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: n }) {
3687
+ return [t("div", { staticClass: "flex items-center", on: { click: (s) => e.onClickSaveAsTemplate({
3688
+ event: s,
3689
3689
  can: a,
3690
- open: s
3691
- }) } }, [t("CCheckbox", { attrs: { id: "checkbox-save-as-temp", size: "small", type: "secondary" }, model: { value: e.saveTemplate, callback: function(n) {
3692
- e.saveTemplate = n;
3690
+ open: n
3691
+ }) } }, [t("CCheckbox", { attrs: { id: "checkbox-save-as-temp", size: "small", type: "secondary" }, model: { value: e.saveTemplate, callback: function(s) {
3692
+ e.saveTemplate = s;
3693
3693
  }, expression: "saveTemplate" } }), t("div", { staticStyle: { "padding-left": "0.5em" } }, [e._v(" " + e._s(e.$t("saveDocAsTemplate")) + " "), t("BaseIcon", { directives: [{ name: "tooltip", rawName: "v-tooltip", value: e.saveTemplateTooltip, expression: "saveTemplateTooltip" }], attrs: { type: "info", size: "15" } })], 1)], 1)];
3694
3694
  } }], null, !0) })];
3695
3695
  } }], null, !1, 2049373406) })], 1)], 1)], 1)]) : e._e();
3696
- }, X1 = [], e2 = /* @__PURE__ */ d(
3696
+ }, J1 = [], X1 = /* @__PURE__ */ d(
3697
+ Y1,
3697
3698
  Q1,
3698
3699
  J1,
3699
- X1,
3700
3700
  !1,
3701
3701
  null,
3702
3702
  "41e74cd7",
3703
3703
  null,
3704
3704
  null
3705
3705
  );
3706
- const t2 = e2.exports, i2 = {
3706
+ const e2 = X1.exports, t2 = {
3707
3707
  name: "Draggable",
3708
3708
  data() {
3709
3709
  return {
@@ -3724,7 +3724,7 @@ const t2 = e2.exports, i2 = {
3724
3724
  this.elementWidth = e.width, this.elementHeight = e.height;
3725
3725
  const t = i.type === "touchstart", a = t ? i.touches[0] : i;
3726
3726
  this.clientX = a.clientX, this.clientY = a.clientY;
3727
- const s = t ? "touchmove" : "mousemove", n = t ? "touchend" : "mouseup", o = (r) => {
3727
+ const n = t ? "touchmove" : "mousemove", s = t ? "touchend" : "mouseup", o = (r) => {
3728
3728
  t || r.preventDefault();
3729
3729
  const c = t ? r.touches[0] : r;
3730
3730
  this.movementX = this.clientX - c.clientX, this.movementY = this.clientY - c.clientY, this.clientX = c.clientX, this.clientY = c.clientY, this.$el.style.top = `${Math.max(
@@ -3735,9 +3735,9 @@ const t2 = e2.exports, i2 = {
3735
3735
  this.windowWidth - this.elementWidth
3736
3736
  )}px`;
3737
3737
  }, l = () => {
3738
- document.removeEventListener(s, o), document.removeEventListener(n, l);
3738
+ document.removeEventListener(n, o), document.removeEventListener(s, l);
3739
3739
  };
3740
- document.addEventListener(s, o), document.addEventListener(n, l);
3740
+ document.addEventListener(n, o), document.addEventListener(s, l);
3741
3741
  }
3742
3742
  },
3743
3743
  render() {
@@ -3745,21 +3745,21 @@ const t2 = e2.exports, i2 = {
3745
3745
  dragMousedown: this.onDragMouseDown
3746
3746
  });
3747
3747
  }
3748
- }, a2 = null, s2 = null;
3748
+ }, i2 = null, a2 = null;
3749
3749
  var n2 = /* @__PURE__ */ d(
3750
+ t2,
3750
3751
  i2,
3751
3752
  a2,
3752
- s2,
3753
3753
  !1,
3754
3754
  null,
3755
3755
  null,
3756
3756
  null,
3757
3757
  null
3758
3758
  );
3759
- const o2 = n2.exports;
3760
- const l2 = {
3759
+ const s2 = n2.exports;
3760
+ const o2 = {
3761
3761
  components: {
3762
- Draggable: o2
3762
+ Draggable: s2
3763
3763
  },
3764
3764
  props: {
3765
3765
  offset: {
@@ -3772,28 +3772,28 @@ const l2 = {
3772
3772
  }
3773
3773
  }
3774
3774
  };
3775
- var r2 = function() {
3775
+ var l2 = function() {
3776
3776
  var e = this, t = e._self._c;
3777
3777
  return t("portal", { attrs: { to: "modal" } }, [t("Draggable", { scopedSlots: e._u([{ key: "default", fn: function({ dragMousedown: a }) {
3778
3778
  return [t("div", { staticClass: "popup", staticStyle: { position: "fixed", width: "280px", "border-radius": "calc(0.5 * var(--rem))", padding: "1em 1em 3em 1em", "font-size": "14px", "background-color": "white", "min-height": "400px", "box-shadow": "0 5px 30px -5px rgb(0, 0, 0, 0.2)", "z-index": "1000" }, style: {
3779
3779
  top: "70px",
3780
3780
  left: `${e.offset + 15}px`
3781
- } }, [t("div", { staticStyle: { position: "relative", height: "100%", width: "100%" } }, [t("CButton", { staticStyle: { position: "absolute", right: "0", top: "0" }, attrs: { icon: "x", size: "small", type: "none", pattern: "tertiary", circle: "" }, on: { click: function(s) {
3781
+ } }, [t("div", { staticStyle: { position: "relative", height: "100%", width: "100%" } }, [t("CButton", { staticStyle: { position: "absolute", right: "0", top: "0" }, attrs: { icon: "x", size: "small", type: "none", pattern: "tertiary", circle: "" }, on: { click: function(n) {
3782
3782
  return e.$emit("close");
3783
3783
  } } }), t("CButton", { staticStyle: { position: "absolute", right: "calc(2.25 * var(--rem))", top: "0", cursor: "grab" }, attrs: { icon: "handle", size: "small", type: "none", pattern: "tertiary", circle: "" }, on: { mousedown: a, touchstart: a } }), t("div", { staticStyle: { "font-weight": "700", "font-size": "1.5em", "margin-bottom": "calc(1 * var(--rem))" } }, [e._v(" " + e._s(e.title) + " ")]), e._t("default")], 2)])];
3784
3784
  } }], null, !0) })], 1);
3785
- }, c2 = [], d2 = /* @__PURE__ */ d(
3785
+ }, r2 = [], c2 = /* @__PURE__ */ d(
3786
+ o2,
3786
3787
  l2,
3787
3788
  r2,
3788
- c2,
3789
3789
  !1,
3790
3790
  null,
3791
3791
  "8029d5ea",
3792
3792
  null,
3793
3793
  null
3794
3794
  );
3795
- const J = d2.exports;
3796
- const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
3795
+ const J = c2.exports;
3796
+ const d2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(d2), p2 = {
3797
3797
  i18nOptions: {
3798
3798
  namespaces: "common",
3799
3799
  keyPrefix: "designLabels"
@@ -3880,8 +3880,8 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
3880
3880
  weight: t
3881
3881
  }
3882
3882
  },
3883
- onInput: ({ family: a, weight: s, options: n = [] }) => {
3884
- this.update(i, a), Pe(a), t != s && this.update("fontWeight", s), this.fontWeightOptions = n;
3883
+ onInput: ({ family: a, weight: n, options: s = [] }) => {
3884
+ this.update(i, a), Ae(a), t != n && this.update("fontWeight", n), this.fontWeightOptions = s;
3885
3885
  }
3886
3886
  }
3887
3887
  ]
@@ -3899,7 +3899,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
3899
3899
  value: t || "",
3900
3900
  type: "number",
3901
3901
  minValue: 0,
3902
- onInput: (s) => this.update(i, `${s}${a}`)
3902
+ onInput: (n) => this.update(i, `${n}${a}`)
3903
3903
  },
3904
3904
  select: {
3905
3905
  value: t || "px",
@@ -3917,7 +3917,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
3917
3917
  { value: 72, label: 72 },
3918
3918
  { value: 96, label: 96 }
3919
3919
  ],
3920
- onInput: (s) => this.update(i, `${s}px`)
3920
+ onInput: (n) => this.update(i, `${n}px`)
3921
3921
  }
3922
3922
  }
3923
3923
  },
@@ -3929,7 +3929,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
3929
3929
  max: 100,
3930
3930
  value: t
3931
3931
  },
3932
- onInput: (s) => this.update(i, `${s}${a}`)
3932
+ onInput: (n) => this.update(i, `${n}${a}`)
3933
3933
  }
3934
3934
  ]
3935
3935
  };
@@ -4099,7 +4099,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4099
4099
  value: t || "",
4100
4100
  type: "number",
4101
4101
  minValue: 0,
4102
- onInput: (s) => this.update(i, `${s}${a}`)
4102
+ onInput: (n) => this.update(i, `${n}${a}`)
4103
4103
  },
4104
4104
  select: {
4105
4105
  value: t || "px",
@@ -4109,7 +4109,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4109
4109
  { value: 900, label: 900 },
4110
4110
  { value: 1080, label: 1080 }
4111
4111
  ],
4112
- onInput: (s) => this.update(i, `${s}px`)
4112
+ onInput: (n) => this.update(i, `${n}px`)
4113
4113
  }
4114
4114
  }
4115
4115
  },
@@ -4122,7 +4122,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4122
4122
  step: 10,
4123
4123
  value: t
4124
4124
  },
4125
- onInput: (s) => this.update(i, `${s}${a}`)
4125
+ onInput: (n) => this.update(i, `${n}${a}`)
4126
4126
  }
4127
4127
  ]
4128
4128
  };
@@ -4168,7 +4168,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4168
4168
  };
4169
4169
  },
4170
4170
  border: ([i, e, t]) => {
4171
- const a = i.value === "solid", [, s] = w(e.value), n = [
4171
+ const a = i.value === "solid", [, n] = w(e.value), s = [
4172
4172
  {
4173
4173
  label: this.$t("border"),
4174
4174
  inputs: [
@@ -4187,7 +4187,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4187
4187
  {
4188
4188
  component: "input",
4189
4189
  props: {
4190
- value: s,
4190
+ value: n,
4191
4191
  type: "number",
4192
4192
  minValue: 0
4193
4193
  }
@@ -4195,15 +4195,15 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4195
4195
  {
4196
4196
  component: "step",
4197
4197
  props: {
4198
- value: s
4198
+ value: n
4199
4199
  },
4200
4200
  onIncrease: () => this.update(
4201
4201
  e.key,
4202
- `${parseFloat(s || 0) + 1}px`
4202
+ `${parseFloat(n || 0) + 1}px`
4203
4203
  ),
4204
4204
  onDecrease: () => this.update(
4205
4205
  e.key,
4206
- `${parseFloat(s || 0) - 1}px`
4206
+ `${parseFloat(n || 0) - 1}px`
4207
4207
  )
4208
4208
  }
4209
4209
  ]
@@ -4228,7 +4228,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4228
4228
  value: a ? `${e.value} ${t.value}` : "none",
4229
4229
  width: "220px",
4230
4230
  popup: {
4231
- inputs: n
4231
+ inputs: s
4232
4232
  }
4233
4233
  }
4234
4234
  }
@@ -4245,8 +4245,8 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4245
4245
  h2: e,
4246
4246
  h3: t,
4247
4247
  blockquote: a,
4248
- p: s,
4249
- '[data-typography="title"]': n
4248
+ p: n,
4249
+ '[data-typography="title"]': s
4250
4250
  } = this.css || {};
4251
4251
  return [
4252
4252
  {
@@ -4260,7 +4260,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4260
4260
  // calc(2.5 * var(--rem))
4261
4261
  fontWeight: 800,
4262
4262
  // 900
4263
- ...n
4263
+ ...s
4264
4264
  }
4265
4265
  },
4266
4266
  {
@@ -4329,7 +4329,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4329
4329
  style: {
4330
4330
  fontFamily: "Inter",
4331
4331
  fontSize: "16px",
4332
- ...s
4332
+ ...n
4333
4333
  }
4334
4334
  }
4335
4335
  ];
@@ -4337,9 +4337,9 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4337
4337
  activeItemOptions() {
4338
4338
  if (!this.activeItem)
4339
4339
  return [];
4340
- const { selector: i, category: e, style: t = {} } = this.activeItem, a = u(this.css, i) || {}, s = (n) => a[n] || t[n];
4341
- return this[e].map(({ option: n, key: o }, l) => {
4342
- const r = this.definitionOptions[n], c = Array.isArray(o) ? o.map((C) => ({ key: C, value: s(C) })) : { key: o, value: s(o) };
4340
+ const { selector: i, category: e, style: t = {} } = this.activeItem, a = u(this.css, i) || {}, n = (s) => a[s] || t[s];
4341
+ return this[e].map(({ option: s, key: o }, l) => {
4342
+ const r = this.definitionOptions[s], c = Array.isArray(o) ? o.map((C) => ({ key: C, value: n(C) })) : { key: o, value: n(o) };
4343
4343
  return r(c, l);
4344
4344
  });
4345
4345
  }
@@ -4347,7 +4347,7 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4347
4347
  watch: {
4348
4348
  async activeItem(i) {
4349
4349
  const e = u(i, "style.fontFamily");
4350
- e && (this.fontWeightOptions = await ze(e));
4350
+ e && (this.fontWeightOptions = await Pe(e));
4351
4351
  }
4352
4352
  },
4353
4353
  methods: {
@@ -4359,10 +4359,10 @@ const p2 = /([\d+.]*)(.*)/, w = (i) => (i || "").match(p2), u2 = {
4359
4359
  }
4360
4360
  }
4361
4361
  };
4362
- var m2 = function() {
4362
+ var u2 = function() {
4363
4363
  var e = this, t = e._self._c;
4364
4364
  return t("div", [t("div", { staticStyle: { padding: "calc(0.5 * var(--rem))", position: "relative" } }, [t("div", { staticStyle: { "padding-left": "calc(0.75 * var(--rem))", "font-size": "14px", color: "hsl(0, 0%, 30%)", "padding-bottom": "3px" } }, [e._v(" " + e._s(e.$t("typography")) + " ")]), e._l(e.typography, function(a) {
4365
- return t("div", { key: a.label, staticClass: "list-option", on: { click: function(s) {
4365
+ return t("div", { key: a.label, staticClass: "list-option", on: { click: function(n) {
4366
4366
  e.activeItem = a;
4367
4367
  } } }, [t("div", { style: {
4368
4368
  fontSize: a.fontSize,
@@ -4372,24 +4372,24 @@ var m2 = function() {
4372
4372
  lineHeight: 1
4373
4373
  } }, [e._v(" " + e._s(a.label) + " ")]), t("div", { staticStyle: { color: "hsl(0, 0%, 45%)", "font-weight": "500", "font-size": "13px", "padding-top": "5px" } }, [e._v(" " + e._s(a.style.fontFamily) + " " + e._s(a.style.fontSize) + " ")])]);
4374
4374
  })], 2), t("div", { staticStyle: { height: "1px", "background-color": "hsl(0, 0%, 88%)", margin: "calc(0.5 * var(--rem)) calc(1 * var(--rem))" } }), t("div", { staticStyle: { padding: "calc(0.75 * var(--rem))" } }, [t("div", { staticStyle: { "padding-left": "calc(0.75 * var(--rem))", "font-size": "14px", color: "hsl(0, 0%, 30%)", "padding-bottom": "3px" } }, [e._v(" " + e._s(e.$t("section_plural")) + " ")]), e._l(e.sections, function(a) {
4375
- return t("div", { key: a.label, staticClass: "list-option", on: { click: function(s) {
4375
+ return t("div", { key: a.label, staticClass: "list-option", on: { click: function(n) {
4376
4376
  e.activeItem = a;
4377
4377
  } } }, [t("div", { staticStyle: { "font-size": "1.075em", "font-weight": "500" } }, [e._v(" " + e._s(a.label) + " ")]), t("div", { staticStyle: { color: "hsl(0, 0%, 45%)", "font-weight": "500", "font-size": "13px", "padding-top": "5px" } }, [e._v(" #000000 ")])]);
4378
- })], 2), e.activeItem ? t("DragWindow", { attrs: { title: e.activeItem.label, offset: e.offset }, on: { close: () => e.activeItem = null } }, e._l(e.activeItemOptions, function(a, s) {
4379
- return t("FormInputRow", { key: s, attrs: { label: a.label, inputs: a.inputs } });
4378
+ })], 2), e.activeItem ? t("DragWindow", { attrs: { title: e.activeItem.label, offset: e.offset }, on: { close: () => e.activeItem = null } }, e._l(e.activeItemOptions, function(a, n) {
4379
+ return t("FormInputRow", { key: n, attrs: { label: a.label, inputs: a.inputs } });
4380
4380
  }), 1) : e._e()], 1);
4381
- }, h2 = [], f2 = /* @__PURE__ */ d(
4381
+ }, m2 = [], h2 = /* @__PURE__ */ d(
4382
+ p2,
4382
4383
  u2,
4383
4384
  m2,
4384
- h2,
4385
4385
  !1,
4386
4386
  null,
4387
4387
  "4404aad6",
4388
4388
  null,
4389
4389
  null
4390
4390
  );
4391
- const g2 = f2.exports;
4392
- const C2 = {
4391
+ const f2 = h2.exports;
4392
+ const g2 = {
4393
4393
  name: "FieldsModal",
4394
4394
  i18nOptions: {
4395
4395
  namespaces: "FieldsModal",
@@ -4454,12 +4454,12 @@ const C2 = {
4454
4454
  validations: {
4455
4455
  form: {
4456
4456
  label: {
4457
- required: F.required,
4457
+ required: I.required,
4458
4458
  isUniqueLabel(i) {
4459
4459
  return this.fields.reduce((t, { label: a }) => a === i ? !1 : t, !0);
4460
4460
  }
4461
4461
  },
4462
- value: { required: F.required }
4462
+ value: { required: I.required }
4463
4463
  }
4464
4464
  },
4465
4465
  computed: {
@@ -4499,12 +4499,12 @@ const C2 = {
4499
4499
  remove() {
4500
4500
  if (!this.existingFieldId)
4501
4501
  return;
4502
- const i = Ye(this.document.fields, [this.existingFieldId]);
4502
+ const i = Ke(this.document.fields, [this.existingFieldId]);
4503
4503
  this.set({ key: "data.fields", value: i }), this.$emit("close");
4504
4504
  }
4505
4505
  }
4506
4506
  };
4507
- var v2 = function() {
4507
+ var C2 = function() {
4508
4508
  var e = this, t = e._self._c;
4509
4509
  return t("div", { staticClass: "flex flex-col items-center w-full text-center bg-white font-inter", staticStyle: { padding: "2em", "border-radius": "10px" } }, [t("div", { staticStyle: { "padding-bottom": "2em" } }, [t("div", { staticStyle: { "font-size": "18px", "font-weight": "600", "margin-bottom": "0.25em" } }, [e._v(" " + e._s(e.existingFieldId ? e.$t("editTitle") : e.$t("newTitle")) + " ")]), t("div", { staticStyle: { "margin-bottom": "0.25em", opacity: "0.65" } }, [e._v(" " + e._s(e.$t("description")) + " ")])]), t("form", { staticStyle: { width: "100%" }, on: { submit: function(a) {
4510
4510
  return a.preventDefault(), e.submit.apply(null, arguments);
@@ -4515,18 +4515,18 @@ var v2 = function() {
4515
4515
  }, expression: "form.label" } })], 1), t("CField", { staticStyle: { width: "100%", "text-align": "left", "margin-bottom": "1em" }, attrs: { label: e.$t("value"), messages: e.messages.form.value, validator: e.$v.form.value, "label-position": "inside" } }, [t("CInput", { attrs: { placeholder: e.$t("valuePlaceholder"), filled: "" }, model: { value: e.form.value, callback: function(a) {
4516
4516
  e.$set(e.form, "value", a);
4517
4517
  }, expression: "form.value" } })], 1), t("CButton", { staticStyle: { "margin-top": "1.5em" }, attrs: { type: "secondary", wide: "" }, domProps: { textContent: e._s(e.$t("_common:save")) }, on: { click: e.submit } }), e.existingFieldId ? t("CButton", { staticStyle: { "margin-top": "5px" }, attrs: { type: "none", pattern: "tertiary", wide: "" }, domProps: { textContent: e._s(e.$t("_common:remove")) }, on: { click: e.remove } }) : e._e()], 1)]);
4518
- }, y2 = [], x2 = /* @__PURE__ */ d(
4518
+ }, v2 = [], y2 = /* @__PURE__ */ d(
4519
+ g2,
4519
4520
  C2,
4520
4521
  v2,
4521
- y2,
4522
4522
  !1,
4523
4523
  null,
4524
4524
  "186f2d19",
4525
4525
  null,
4526
4526
  null
4527
4527
  );
4528
- const w2 = x2.exports;
4529
- const b2 = {
4528
+ const x2 = y2.exports;
4529
+ const w2 = {
4530
4530
  i18nOptions: {
4531
4531
  namespaces: "DocumentFormFields",
4532
4532
  messages: {
@@ -4550,8 +4550,8 @@ const b2 = {
4550
4550
  },
4551
4551
  name: "DocumentFormFields",
4552
4552
  components: {
4553
- SmartList: Ke,
4554
- CAccordion: He,
4553
+ SmartList: je,
4554
+ CAccordion: Ie,
4555
4555
  CField: q
4556
4556
  },
4557
4557
  mixins: [S()],
@@ -4575,7 +4575,7 @@ const b2 = {
4575
4575
  options() {
4576
4576
  const { fields: i, usedFields: e } = this._document;
4577
4577
  return Object.keys(i).map((t) => {
4578
- const a = i[t], { service: s, inputDisabled: n, virtual: o = !1 } = a.meta || {}, l = this.crmService && s === this.crmService ? a.meta.service : null;
4578
+ const a = i[t], { service: n, inputDisabled: s, virtual: o = !1 } = a.meta || {}, l = this.crmService && n === this.crmService ? a.meta.service : null;
4579
4579
  return {
4580
4580
  ...a,
4581
4581
  id: t,
@@ -4583,7 +4583,7 @@ const b2 = {
4583
4583
  onInput: (r) => this.updateValue(a.key, r),
4584
4584
  usedCount: e[a.key] || 0,
4585
4585
  crm: l,
4586
- inputDisabled: n || l,
4586
+ inputDisabled: s || l,
4587
4587
  virtual: o
4588
4588
  };
4589
4589
  });
@@ -4614,7 +4614,7 @@ const b2 = {
4614
4614
  ...a,
4615
4615
  // Filter out previous service fields if switching connected crm
4616
4616
  ...Object.entries(((t = (e = this._document) == null ? void 0 : e.data) == null ? void 0 : t.fields) || {}).reduce(
4617
- (s, [n, o]) => o != null && o.meta.service && o.meta.service !== i ? s : { ...s, [n]: o },
4617
+ (n, [s, o]) => o != null && o.meta.service && o.meta.service !== i ? n : { ...n, [s]: o },
4618
4618
  {}
4619
4619
  )
4620
4620
  });
@@ -4628,7 +4628,7 @@ const b2 = {
4628
4628
  },
4629
4629
  openFieldModal({ existingFieldId: i }) {
4630
4630
  this.$modal.show(
4631
- w2,
4631
+ x2,
4632
4632
  {
4633
4633
  document: this._document,
4634
4634
  set: this.set,
@@ -4660,19 +4660,19 @@ const b2 = {
4660
4660
  }
4661
4661
  }
4662
4662
  };
4663
- var _2 = function() {
4663
+ var b2 = function() {
4664
4664
  var e = this, t = e._self._c;
4665
4665
  return t("div", { staticStyle: { padding: "1em" } }, [t("div", { staticStyle: { margin: "15px 0" } }, [t("div", { staticStyle: { "font-size": "16px", "font-weight": "600" }, domProps: { textContent: e._s(e.$t("title")) } }), t("div", { staticStyle: { color: "hsl(0, 0%, 35%)" }, domProps: { textContent: e._s(e.$t("description")) } })]), t("CInput", { attrs: { placeholder: e.$t("_common:search"), filled: "", size: "small" }, model: { value: e.query, callback: function(a) {
4666
4666
  e.query = a;
4667
4667
  }, expression: "query" } }), e.query ? t("div", { staticStyle: { "margin-top": "15px", "padding-top": "15px", "border-top": "1px solid hsl(0, 0%, 88%)" } }, [t("SmartList", { attrs: { items: e.options, "filter-method": e.filterMethod, query: e.query }, scopedSlots: e._u([{ key: "default", fn: function({ items: a }) {
4668
- return t("div", {}, [a.length ? e._l(a, function(s, n) {
4669
- return t("div", { key: n, staticClass: "flex items-center w-full field-parent" }, [t("div", { staticClass: "field-container", staticStyle: { position: "relative", flex: "1 1 auto" } }, [t("CField", { staticStyle: { width: "100%" }, attrs: { label: " ", "label-position": "inside" } }, [t("span", { staticClass: "drag-label", attrs: { draggable: "" }, domProps: { textContent: e._s(s.label) }, on: { dragstart: (o) => e.onDragStart(o, s) } }), t("CInput", { staticStyle: { width: "100%" }, attrs: { value: s.value, disabled: s.inputDisabled, filled: "", size: "small" }, on: { blur: function(o) {
4668
+ return t("div", {}, [a.length ? e._l(a, function(n, s) {
4669
+ return t("div", { key: s, staticClass: "flex items-center w-full field-parent" }, [t("div", { staticClass: "field-container", staticStyle: { position: "relative", flex: "1 1 auto" } }, [t("CField", { staticStyle: { width: "100%" }, attrs: { label: " ", "label-position": "inside" } }, [t("span", { staticClass: "drag-label", attrs: { draggable: "" }, domProps: { textContent: e._s(n.label) }, on: { dragstart: (o) => e.onDragStart(o, n) } }), t("CInput", { staticStyle: { width: "100%" }, attrs: { value: n.value, disabled: n.inputDisabled, filled: "", size: "small" }, on: { blur: function(o) {
4670
4670
  var l;
4671
- return s.onInput(((l = o == null ? void 0 : o.target) == null ? void 0 : l.value) || "");
4672
- } } })], 1), t("div", { staticClass: "field-actions" }, [!s.inputDisabled && !s.virtual ? t("CButton", { staticStyle: { width: "30px", height: "30px", "border-radius": "3px" }, attrs: { icon: "edit", size: "small", type: "none", pattern: "tertiary" }, on: { click: function(o) {
4673
- return e.openFieldModal({ existingFieldId: s.id });
4671
+ return n.onInput(((l = o == null ? void 0 : o.target) == null ? void 0 : l.value) || "");
4672
+ } } })], 1), t("div", { staticClass: "field-actions" }, [!n.inputDisabled && !n.virtual ? t("CButton", { staticStyle: { width: "30px", height: "30px", "border-radius": "3px" }, attrs: { icon: "edit", size: "small", type: "none", pattern: "tertiary" }, on: { click: function(o) {
4673
+ return e.openFieldModal({ existingFieldId: n.id });
4674
4674
  } } }) : e._e(), t("CButton", { staticStyle: { width: "30px", height: "30px", "border-radius": "3px" }, attrs: { icon: "copy", size: "small", type: "none", pattern: "secondary" }, on: { click: function(o) {
4675
- return e.onCopyField(`{{${s.key}}}`);
4675
+ return e.onCopyField(`{{${n.key}}}`);
4676
4676
  } } })], 1)], 1)]);
4677
4677
  }) : t("div", { staticStyle: { "text-align": "center" } }, [e._v(" " + e._s(e.$t("_common:noResults")) + " ")])], 2);
4678
4678
  } }], null, !1, 653548536) })], 1) : t("div", { staticStyle: { "padding-top": "20px" } }, [t("div", { staticClass: "flex justify-end w-full", staticStyle: { "margin-top": "0.5em", "margin-bottom": "0.5em" } }, [t("CButton", { staticStyle: { "font-size": "13px", "margin-left": "2px" }, attrs: { type: "none", pattern: "secondary", size: "small" }, domProps: { textContent: e._s(e.$t("_common:add", { thing: e.$t("_common:field") })) }, on: { click: e.openFieldModal } })], 1), e._l([
@@ -4693,32 +4693,32 @@ var _2 = function() {
4693
4693
  defaultOpen: !e.usedFields.length,
4694
4694
  items: e.unUsedFields
4695
4695
  }
4696
- ], function(a, s) {
4697
- return t("CAccordion", { key: s, staticStyle: { "border-top": "1px solid hsl(0, 0%, 88%)" }, attrs: { "default-open": a.defaultOpen }, scopedSlots: e._u([{ key: "trigger", fn: function({ expanded: n }) {
4698
- return t("div", { staticClass: "list-button" }, [t("span", [t("span", { domProps: { textContent: e._s(a.label) } }), t("span", { staticStyle: { opacity: "0.45", "padding-left": "0.5em" }, domProps: { textContent: e._s(a.items.length) } })]), t("BaseIcon", { staticStyle: { transition: "200ms" }, style: { transform: `rotate(${n ? "180deg" : "0deg"})` }, attrs: { type: "chevron-down", size: "15" } })], 1);
4699
- } }], null, !0) }, [t("div", { staticStyle: { "padding-bottom": "2em" } }, [a.items.length ? e._l(a.items, function(n, o) {
4700
- return t("div", { key: o, staticClass: "flex items-center w-full field-parent" }, [t("div", { staticClass: "field-container", staticStyle: { position: "relative", flex: "1 1 auto" } }, [t("CField", { staticStyle: { width: "100%" }, attrs: { label: " ", "label-position": "inside" } }, [t("span", { staticClass: "drag-label", attrs: { draggable: "" }, domProps: { textContent: e._s(n.label) }, on: { dragstart: (l) => e.onDragStart(l, n) } }), t("CInput", { staticStyle: { width: "100%" }, attrs: { value: n.value, disabled: n.inputDisabled, filled: "", size: "small" }, on: { blur: function(l) {
4696
+ ], function(a, n) {
4697
+ return t("CAccordion", { key: n, staticStyle: { "border-top": "1px solid hsl(0, 0%, 88%)" }, attrs: { "default-open": a.defaultOpen }, scopedSlots: e._u([{ key: "trigger", fn: function({ expanded: s }) {
4698
+ return t("div", { staticClass: "list-button" }, [t("span", [t("span", { domProps: { textContent: e._s(a.label) } }), t("span", { staticStyle: { opacity: "0.45", "padding-left": "0.5em" }, domProps: { textContent: e._s(a.items.length) } })]), t("BaseIcon", { staticStyle: { transition: "200ms" }, style: { transform: `rotate(${s ? "180deg" : "0deg"})` }, attrs: { type: "chevron-down", size: "15" } })], 1);
4699
+ } }], null, !0) }, [t("div", { staticStyle: { "padding-bottom": "2em" } }, [a.items.length ? e._l(a.items, function(s, o) {
4700
+ return t("div", { key: o, staticClass: "flex items-center w-full field-parent" }, [t("div", { staticClass: "field-container", staticStyle: { position: "relative", flex: "1 1 auto" } }, [t("CField", { staticStyle: { width: "100%" }, attrs: { label: " ", "label-position": "inside" } }, [t("span", { staticClass: "drag-label", attrs: { draggable: "" }, domProps: { textContent: e._s(s.label) }, on: { dragstart: (l) => e.onDragStart(l, s) } }), t("CInput", { staticStyle: { width: "100%" }, attrs: { value: s.value, disabled: s.inputDisabled, filled: "", size: "small" }, on: { blur: function(l) {
4701
4701
  var r;
4702
- return n.onInput(((r = l == null ? void 0 : l.target) == null ? void 0 : r.value) || "");
4703
- } } })], 1), t("div", { staticClass: "field-actions" }, [!n.inputDisabled && !n.virtual ? t("CButton", { staticStyle: { width: "30px", height: "30px", "border-radius": "3px" }, attrs: { icon: "edit", size: "small", type: "none", pattern: "tertiary" }, on: { click: function(l) {
4704
- return e.openFieldModal({ existingFieldId: n.id });
4702
+ return s.onInput(((r = l == null ? void 0 : l.target) == null ? void 0 : r.value) || "");
4703
+ } } })], 1), t("div", { staticClass: "field-actions" }, [!s.inputDisabled && !s.virtual ? t("CButton", { staticStyle: { width: "30px", height: "30px", "border-radius": "3px" }, attrs: { icon: "edit", size: "small", type: "none", pattern: "tertiary" }, on: { click: function(l) {
4704
+ return e.openFieldModal({ existingFieldId: s.id });
4705
4705
  } } }) : e._e(), t("CButton", { staticStyle: { width: "30px", height: "30px", "border-radius": "3px" }, attrs: { icon: "copy", size: "small", type: "none", pattern: "secondary" }, on: { click: function(l) {
4706
- return e.onCopyField(`{{${n.key}}}`);
4706
+ return e.onCopyField(`{{${s.key}}}`);
4707
4707
  } } })], 1)], 1)]);
4708
4708
  }) : t("div", { staticStyle: { "font-size": "13px", "text-align": "center", "user-select": "none", padding: "0.5em", "border-radius": "0.25em", opacity: "0.5" }, domProps: { textContent: e._s(e.$t("noResults")) } })], 2)]);
4709
4709
  })], 2)], 1);
4710
- }, k2 = [], L2 = /* @__PURE__ */ d(
4710
+ }, _2 = [], k2 = /* @__PURE__ */ d(
4711
+ w2,
4711
4712
  b2,
4712
4713
  _2,
4713
- k2,
4714
4714
  !1,
4715
4715
  null,
4716
4716
  "da1996e8",
4717
4717
  null,
4718
4718
  null
4719
4719
  );
4720
- const $2 = L2.exports;
4721
- const S2 = {
4720
+ const L2 = k2.exports;
4721
+ const $2 = {
4722
4722
  i18nOptions: {
4723
4723
  messages: {
4724
4724
  en: {
@@ -4761,7 +4761,7 @@ const S2 = {
4761
4761
  },
4762
4762
  name: "ExtensionTab",
4763
4763
  components: {
4764
- draggable: Qe,
4764
+ draggable: Ye,
4765
4765
  Spinner: be
4766
4766
  },
4767
4767
  mixins: [S(["externalReferences", "clients", "articles"])],
@@ -4865,11 +4865,11 @@ const S2 = {
4865
4865
  );
4866
4866
  if (!e)
4867
4867
  return;
4868
- const { service: t, type: a, typeId: s } = e, { data: n } = await $.getExternalReferenceDetails(
4868
+ const { service: t, type: a, typeId: n } = e, { data: s } = await $.getExternalReferenceDetails(
4869
4869
  t,
4870
- { type: a, typeId: s }
4870
+ { type: a, typeId: n }
4871
4871
  );
4872
- i !== this.dealType ? this.typeDetails = { ...n, type: i } : this.dealDetails = n;
4872
+ i !== this.dealType ? this.typeDetails = { ...s, type: i } : this.dealDetails = s;
4873
4873
  } catch {
4874
4874
  i !== this.dealType ? this.typeDetails = null : this.dealDetails = null;
4875
4875
  } finally {
@@ -4878,25 +4878,25 @@ const S2 = {
4878
4878
  },
4879
4879
  removeReference(i = this.dealType) {
4880
4880
  const e = this.externalReferences.find(
4881
- (n) => n.service === this.activeCrm && n.type === i
4881
+ (s) => s.service === this.activeCrm && s.type === i
4882
4882
  );
4883
4883
  if (!e)
4884
4884
  return;
4885
- const { service: t, type: a, typeId: s } = e;
4886
- !t || !a || !s || (this.externalReferences = this.externalReferences.filter(
4887
- (n) => !(n.service === t && n.type === a && n.typeId === s)
4885
+ const { service: t, type: a, typeId: n } = e;
4886
+ !t || !a || !n || (this.externalReferences = this.externalReferences.filter(
4887
+ (s) => !(s.service === t && s.type === a && s.typeId === n)
4888
4888
  ), i !== this.dealType ? this.typeDetails = null : this.dealDetails = null);
4889
4889
  },
4890
4890
  async suggestClients() {
4891
- var s;
4891
+ var n;
4892
4892
  const { service: i, type: e, typeId: t } = this.currentExternalDeal, { data: a } = await $.suggestClients(i, {
4893
4893
  type: e,
4894
4894
  typeId: t
4895
4895
  });
4896
4896
  if (Array.isArray(a) && a.length) {
4897
- const n = (s = this._document) == null ? void 0 : s.defaultAnswerMethod, o = a.map((l) => ({
4897
+ const s = (n = this._document) == null ? void 0 : n.defaultAnswerMethod, o = a.map((l) => ({
4898
4898
  ..._e(),
4899
- ...n && { answerMethod: n },
4899
+ ...s && { answerMethod: s },
4900
4900
  ...l
4901
4901
  }));
4902
4902
  this.clients = [...this.clients || [], ...o];
@@ -4909,8 +4909,8 @@ const S2 = {
4909
4909
  });
4910
4910
  },
4911
4911
  addArticle(i) {
4912
- var a, s;
4913
- const [e] = ((s = (a = this._document) == null ? void 0 : a.packageGroups) == null ? void 0 : s.packages) || [];
4912
+ var a, n;
4913
+ const [e] = ((n = (a = this._document) == null ? void 0 : a.packageGroups) == null ? void 0 : n.packages) || [];
4914
4914
  if (!(e != null && e.packageId))
4915
4915
  return;
4916
4916
  const t = y({
@@ -4925,10 +4925,10 @@ const S2 = {
4925
4925
  }
4926
4926
  }
4927
4927
  };
4928
- var T2 = function() {
4928
+ var S2 = function() {
4929
4929
  var e = this, t = e._self._c;
4930
4930
  return t("div", { staticStyle: { "font-size": "13px", "padding-left": "calc(0.5 * var(--rem))", "padding-right": "calc(0.5 * var(--rem))", "padding-bottom": "calc(4 * var(--rem))" } }, [e.allAuthenticatedCRMs.length > 1 ? t("CDropdown", { staticStyle: { position: "absolute", right: "calc(0.5 * var(--rem))", top: "calc(0.5 * var(--rem))" }, attrs: { position: "is-bottom-left" } }, [t("CButton", { attrs: { slot: "trigger", size: "small", circle: "", type: "none", pattern: "tertiary", icon: "more-vertical" }, slot: "trigger" }), e._l(e.allAuthenticatedCRMs, function(a) {
4931
- return t("CDropdownItem", { key: a, attrs: { type: e.activeCrm === a ? "primary" : "secondary", size: "small" }, on: { click: function(s) {
4931
+ return t("CDropdownItem", { key: a, attrs: { type: e.activeCrm === a ? "primary" : "secondary", size: "small" }, on: { click: function(n) {
4932
4932
  e.activeCrm = a;
4933
4933
  } } }, [e._v(" " + e._s(a.capitalize()) + " ")]);
4934
4934
  })], 2) : e._e(), e.isLoading && !e.dealDetails ? t("div", { staticClass: "flex items-center justify-center w-full", staticStyle: { "padding-top": "calc(2 * var(--rem))" } }, [t("Spinner", { attrs: { size: "24", color: "grey" } })], 1) : e.activeCrm ? [t("div", { staticStyle: { padding: "0 calc(0.5 * var(--rem)) calc(2 * var(--rem))" } }, [t("div", { staticStyle: { "font-weight": "500", "font-size": "16px" } }, [e._v(" " + e._s(e.activeCrm.capitalize()) + " ")]), e.typeDetails ? t("div", [t("div", { staticClass: "x-hint" }, [t("div", { staticClass: "flex w-full" }, [t("div", { domProps: { textContent: e._s(
@@ -4964,22 +4964,22 @@ var T2 = function() {
4964
4964
  pull: "clone",
4965
4965
  put: !1
4966
4966
  }, clone: e.cloneArticle } }, e._l(e.dealDetails.articles, function(a) {
4967
- return t("div", { key: a._uniqueId, staticStyle: { padding: "calc(0.5 * var(--rem))", "line-height": "1", "margin-bottom": "calc(0.5 * var(--rem))", "box-shadow": "0 1px 3px rgb(0, 0, 0, 0.3)", background: "white", "border-radius": "3px", cursor: "grab", "user-select": "none" }, on: { click: function(s) {
4967
+ return t("div", { key: a._uniqueId, staticStyle: { padding: "calc(0.5 * var(--rem))", "line-height": "1", "margin-bottom": "calc(0.5 * var(--rem))", "box-shadow": "0 1px 3px rgb(0, 0, 0, 0.3)", background: "white", "border-radius": "3px", cursor: "grab", "user-select": "none" }, on: { click: function(n) {
4968
4968
  return e.addArticle(a);
4969
4969
  } } }, [t("div", { staticStyle: { "font-weight": "500", "padding-bottom": "4px", "font-size": "14px" }, domProps: { textContent: e._s(a.name) } }), t("div", { staticClass: "text-gray-600", staticStyle: { "font-size": "12px" } }, [e._v(" " + e._s(e.priceFormat(a.price || 0, { showZero: !1, currency: a.currency || "USD" })) + " · " + e._s(a.quantity || 0) + "x "), a.vat !== null ? [e._v(" · " + e._s(e._document.$t("vat").capitalize()) + " " + e._s(a.vat) + "% ")] : e._e()], 2)]);
4970
4970
  }), 0) : t("div", { staticClass: "flex w-full text-gray-600", staticStyle: { "background-color": "hsl(var(--gray-color-100) / 1)", padding: "5px", "font-size": "12px", "border-radius": "5px", "line-height": "1.35" } }, [t("BaseIcon", { staticStyle: { margin: "1px 4px 0 0", "flex-shrink": "0" }, attrs: { type: "info", size: "13" } }), t("div", { domProps: { textContent: e._s(e.$t("noProducts", { type: e.dealType })) } })], 1)], 1) : e._e()] : t("div", { staticClass: "flex flex-col items-center justify-center w-full text-center", staticStyle: { "padding-top": "calc(1 * var(--rem))" } }, [t("BaseIcon", { staticClass: "text-primary-500", staticStyle: { "padding-bottom": "5px" }, attrs: { type: "info", size: "16" } }), t("div", { staticClass: "text-gray-600" }, [e._v(" " + e._s(e.$t("noCrm")) + " ")]), t("div", { staticClass: "text-center", staticStyle: { "padding-top": "calc(1 * var(--rem))" } }, [t("router-link", { staticClass: "text-primary-500", staticStyle: { "font-weight": "500" }, attrs: { to: { name: "settings" } } }, [e._v(" " + e._s(e.$t("noCrmAction")) + " ")])], 1)], 1)], 2);
4971
- }, D2 = [], V2 = /* @__PURE__ */ d(
4971
+ }, T2 = [], D2 = /* @__PURE__ */ d(
4972
+ $2,
4972
4973
  S2,
4973
4974
  T2,
4974
- D2,
4975
4975
  !1,
4976
4976
  null,
4977
4977
  "341fef10",
4978
4978
  null,
4979
4979
  null
4980
4980
  );
4981
- const B2 = V2.exports;
4982
- const M2 = {
4981
+ const V2 = D2.exports;
4982
+ const B2 = {
4983
4983
  i18nOptions: {
4984
4984
  namespaces: "DocSettings",
4985
4985
  messages: {
@@ -5315,18 +5315,18 @@ const M2 = {
5315
5315
  }
5316
5316
  }
5317
5317
  };
5318
- var I2 = function() {
5318
+ var M2 = function() {
5319
5319
  var e = this, t = e._self._c;
5320
- return t("div", { staticStyle: { height: "100%", padding: "1em" } }, [e._l(e.options, function(a, s) {
5321
- return t("FormInputRow", { key: s, attrs: { label: a.label, "info-tooltip": a.infoTooltip, inputs: a.inputs } });
5320
+ return t("div", { staticStyle: { height: "100%", padding: "1em" } }, [e._l(e.options, function(a, n) {
5321
+ return t("FormInputRow", { key: n, attrs: { label: a.label, "info-tooltip": a.infoTooltip, inputs: a.inputs } });
5322
5322
  }), e.showDragWindow ? t("DragWindow", { attrs: { offset: e.offset, title: e.$t("pricing.title") }, on: { close: function(a) {
5323
5323
  e.showDragWindow = !1;
5324
- } } }, [e._l(e.priceOptions, function(a, s) {
5325
- return [a.type === "divider" ? t("div", { key: s, staticClass: "divider" }) : t("FormInputRow", { key: s, attrs: { label: a.label, "info-tooltip": a.infoTooltip, inputs: a.inputs } })];
5324
+ } } }, [e._l(e.priceOptions, function(a, n) {
5325
+ return [a.type === "divider" ? t("div", { key: n, staticClass: "divider" }) : t("FormInputRow", { key: n, attrs: { label: a.label, "info-tooltip": a.infoTooltip, inputs: a.inputs } })];
5326
5326
  })], 2) : e._e()], 2);
5327
- }, F2 = [], H2 = /* @__PURE__ */ d(
5327
+ }, F2 = [], I2 = /* @__PURE__ */ d(
5328
+ B2,
5328
5329
  M2,
5329
- I2,
5330
5330
  F2,
5331
5331
  !1,
5332
5332
  null,
@@ -5334,7 +5334,7 @@ var I2 = function() {
5334
5334
  null,
5335
5335
  null
5336
5336
  );
5337
- const A2 = H2.exports, P2 = {
5337
+ const H2 = I2.exports, A2 = {
5338
5338
  name: "MenuBlockConvertPopover",
5339
5339
  props: {
5340
5340
  target: {
@@ -5360,32 +5360,32 @@ const A2 = H2.exports, P2 = {
5360
5360
  immediate: !0,
5361
5361
  handler(i) {
5362
5362
  i && this.$nextTick(() => {
5363
- const { top: e, left: t, width: a, height: s } = i.getBoundingClientRect();
5364
- this.$refs.popover.style.top = `${e + s}px`, this.$refs.popover.style.left = `${t + a + 10}px`;
5363
+ const { top: e, left: t, width: a, height: n } = i.getBoundingClientRect();
5364
+ this.$refs.popover.style.top = `${e + n}px`, this.$refs.popover.style.left = `${t + a + 10}px`;
5365
5365
  });
5366
5366
  }
5367
5367
  }
5368
5368
  }
5369
5369
  };
5370
- var z2 = function() {
5370
+ var P2 = function() {
5371
5371
  var e = this, t = e._self._c;
5372
5372
  return t("div", [t("div", { staticClass: "fixed inset-0 z-10", on: { click: function(a) {
5373
5373
  return a.target !== a.currentTarget ? null : e.$emit("close");
5374
5374
  } } }), t("transition", { attrs: { appear: "", mode: "out-in", "enter-active-class": "transition-all duration-100 ease-out", "enter-class": "-translate-x-4 opacity-0", "enter-to-class": "translate-x-0 opacity-100", "leave-active-class": "transition-opacity duration-100 ease-out", "leave-class": "opacity-100", "leave-to-class": "opacity-0" } }, [t("div", { ref: "popover", staticClass: "absolute z-10 p-4 text-sm -translate-y-1/2 bg-white rounded-lg shadow-xl w-52" }, [t("div", { staticClass: "pb-4", domProps: { innerHTML: e._s(e.$t("text")) } }), t("CButton", { attrs: { type: "secondary", size: "small", "icon-right": "arrow-right" }, on: { click: function(a) {
5375
5375
  return e.$emit("convert");
5376
5376
  } } }, [e._v(" " + e._s(e.$t("button")) + " ")])], 1)])], 1);
5377
- }, E2 = [], Z2 = /* @__PURE__ */ d(
5377
+ }, z2 = [], E2 = /* @__PURE__ */ d(
5378
+ A2,
5378
5379
  P2,
5379
5380
  z2,
5380
- E2,
5381
5381
  !1,
5382
5382
  null,
5383
5383
  null,
5384
5384
  null,
5385
5385
  null
5386
5386
  );
5387
- const U2 = Z2.exports;
5388
- const O2 = A.component("ProBadge", {
5387
+ const Z2 = E2.exports;
5388
+ const U2 = A.component("ProBadge", {
5389
5389
  name: "ProBadge",
5390
5390
  render(i) {
5391
5391
  return i(
@@ -5396,7 +5396,7 @@ const O2 = A.component("ProBadge", {
5396
5396
  "Pro"
5397
5397
  );
5398
5398
  }
5399
- }), G2 = {
5399
+ }), O2 = {
5400
5400
  name: "MenuBlocks",
5401
5401
  i18nOptions: {
5402
5402
  namespaces: "menuBlocks",
@@ -5467,12 +5467,12 @@ const O2 = A.component("ProBadge", {
5467
5467
  },
5468
5468
  components: {
5469
5469
  simplebar: L,
5470
- DragList: R,
5470
+ DragList: G,
5471
5471
  DragItem: W,
5472
5472
  AddBlock: Y,
5473
5473
  IsPremiumPreStep: k,
5474
- ProBadge: O2,
5475
- MenuBlockConvertPopover: U2
5474
+ ProBadge: U2,
5475
+ MenuBlockConvertPopover: Z2
5476
5476
  },
5477
5477
  props: {
5478
5478
  _document: {
@@ -5816,7 +5816,7 @@ const O2 = A.component("ProBadge", {
5816
5816
  if (i.locked)
5817
5817
  return t();
5818
5818
  if (!this.canUseBlocks) {
5819
- const a = this.availableBlocks.findIndex((s) => s.key === i.key);
5819
+ const a = this.availableBlocks.findIndex((n) => n.key === i.key);
5820
5820
  return this.showConvertEditableDialogTarget = this.$refs.blockItem[a].$el, this.showConvertEditableDialog = !0, !1;
5821
5821
  }
5822
5822
  return e({
@@ -5829,11 +5829,11 @@ const O2 = A.component("ProBadge", {
5829
5829
  ["_id", "id"].forEach((i) => this.removeValue(`template.${i}`)), this.set({ key: "template.views.read.isEditable", value: !0 }), this.showConvertEditableDialog = !1;
5830
5830
  },
5831
5831
  createTooltips() {
5832
- var s, n;
5832
+ var n, s;
5833
5833
  if (this.mq === "sm")
5834
5834
  return;
5835
- const { tooltips: i } = this, e = (n = (s = this.$el).getRootNode) == null ? void 0 : n.call(s), a = (e == null ? void 0 : e.toString()) === "[object ShadowRoot]" ? e : document.body;
5836
- this.tippyInstances = je(this.$el, {
5835
+ const { tooltips: i } = this, e = (s = (n = this.$el).getRootNode) == null ? void 0 : s.call(n), a = (e == null ? void 0 : e.toString()) === "[object ShadowRoot]" ? e : document.body;
5836
+ this.tippyInstances = Ne(this.$el, {
5837
5837
  target: "[data-tooltip-key]",
5838
5838
  allowHTML: !0,
5839
5839
  duration: [150, 0],
@@ -5905,8 +5905,8 @@ var R2 = function() {
5905
5905
  var e = this, t = e._self._c;
5906
5906
  return t("AddBlock", { attrs: { set: e.set }, on: { "block-added": function(a) {
5907
5907
  return e.$emit("block-added", a);
5908
- } }, scopedSlots: e._u([{ key: "default", fn: function({ addBlock: a, getBlockPayload: s }) {
5909
- return [t("IsPremiumPreStep", { attrs: { feature: "documentBlocks" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: n }) {
5908
+ } }, scopedSlots: e._u([{ key: "default", fn: function({ addBlock: a, getBlockPayload: n }) {
5909
+ return [t("IsPremiumPreStep", { attrs: { feature: "documentBlocks" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: s }) {
5910
5910
  return [t("div", { on: { "&mouseleave": function(o) {
5911
5911
  return e.onMouseleaveDrawer.apply(null, arguments);
5912
5912
  } } }, [!e.canUseBlocks && e.showConvertEditableDialog ? t("MenuBlockConvertPopover", { attrs: { target: e.showConvertEditableDialogTarget }, on: { convert: e.deSyncTemplate, close: function(o) {
@@ -5915,7 +5915,7 @@ var R2 = function() {
5915
5915
  { data: e.primaryBlocks },
5916
5916
  { data: e.secondaryBlocks }
5917
5917
  ], function(o, l) {
5918
- return t("div", { key: l }, [l > 0 ? t("div", { staticStyle: { height: "1px", "background-color": "hsl(0, 0%, 88%)", margin: "calc(1 * var(--rem))" } }) : e._e(), t("DragList", { attrs: { group: { name: "blocks", pull: "clone", put: !1 }, "get-child-payload": (r) => s(
5918
+ return t("div", { key: l }, [l > 0 ? t("div", { staticStyle: { height: "1px", "background-color": "hsl(0, 0%, 88%)", margin: "calc(1 * var(--rem))" } }) : e._e(), t("DragList", { attrs: { group: { name: "blocks", pull: "clone", put: !1 }, "get-child-payload": (r) => n(
5919
5919
  e.getSectionKey({ data: o.data, index: r })
5920
5920
  ), "drop-placeholder": {
5921
5921
  className: "drag-drop-menu-placeholder"
@@ -5933,29 +5933,29 @@ var R2 = function() {
5933
5933
  !1
5934
5934
  ), [t("CButton", { ref: "blockItem", refInFor: !0, staticClass: "option-row is-thinner is-left", class: {
5935
5935
  "sub-menu-active": r.key === e.activeSubMenuKey
5936
- }, staticStyle: { "padding-left": "1.5em", "padding-right": "2em", "border-radius": "0", "font-size": "14px", "border-color": "transparent" }, attrs: { disabled: r.disabled, wide: "", pattern: "secondary" }, on: { click: (c) => e.onUseBlock({ block: r, addBlock: a, openUpgradeModal: n }) } }, [t("div", { staticClass: "flex items-center", staticStyle: { width: "230px" } }, [t("div", { staticClass: "flex items-center", staticStyle: { width: "initial", flex: "1 1 auto" } }, [t("div", { staticClass: "option-image", domProps: { innerHTML: e._s(r.icon) } }), t("div", { staticClass: "option-title" }, [e._v(" " + e._s(e.$t(`blocks.${r.key}`)) + " ")])]), r.locked ? t("ProBadge") : !e.fixed && r.subMenu ? t("BaseIcon", { staticStyle: { color: "hsl(205, 10%, 65%)" }, attrs: { type: "chevron-right", size: "14" } }) : e._e()], 1)])], 1)]);
5936
+ }, staticStyle: { "padding-left": "1.5em", "padding-right": "2em", "border-radius": "0", "font-size": "14px", "border-color": "transparent" }, attrs: { disabled: r.disabled, wide: "", pattern: "secondary" }, on: { click: (c) => e.onUseBlock({ block: r, addBlock: a, openUpgradeModal: s }) } }, [t("div", { staticClass: "flex items-center", staticStyle: { width: "230px" } }, [t("div", { staticClass: "flex items-center", staticStyle: { width: "initial", flex: "1 1 auto" } }, [t("div", { staticClass: "option-image", domProps: { innerHTML: e._s(r.icon) } }), t("div", { staticClass: "option-title" }, [e._v(" " + e._s(e.$t(`blocks.${r.key}`)) + " ")])]), r.locked ? t("ProBadge") : !e.fixed && r.subMenu ? t("BaseIcon", { staticStyle: { color: "hsl(205, 10%, 65%)" }, attrs: { type: "chevron-right", size: "14" } }) : e._e()], 1)])], 1)]);
5937
5937
  }), 1)], 1);
5938
5938
  }), e._t("footer")], 2), t("transition", { attrs: { name: "slide-right" } }, [t("div", { directives: [{ name: "show", rawName: "v-show", value: e.activeSubMenu, expression: "activeSubMenu" }], staticClass: "submenu", on: { "&mouseover": function(o) {
5939
5939
  e.subMenuToShow = e.activeSubMenu;
5940
5940
  }, "&mouseleave": function(o) {
5941
5941
  e.subMenuToShow = null;
5942
- } } }, [t("simplebar", { staticClass: "h-full py-4 pl-3", attrs: { "data-simplebar-auto-hide": "false" } }, [t("DragList", { attrs: { group: { name: "blocks", pull: "clone", put: !1 }, "get-child-payload": (o) => e.getSubMenuPayload({ index: o, getBlockPayload: s }), "drop-placeholder": { className: "drag-drop-menu-placeholder" }, "get-ghost-parent": e.getGhostParent, "non-drag-area-selector": ".no-drag", "drag-handle-selector": ".drag-item", "group-name": "document-blocks", "ghost-class": "drag-drop-ghost", behaviour: "copy" } }, e._l(e.activeSubMenu, function(o, l) {
5943
- return t("DragItem", { key: o.key + l, staticClass: "px-1.5", class: { "drag-item": !o.locked && e.canUseBlocks } }, [t("div", { staticClass: "relative" }, [t("div", { staticClass: "drag-item-preview", domProps: { innerHTML: e._s(o.previewUrl) }, on: { click: (r) => e.onUseBlock({ block: o, addBlock: a, openUpgradeModal: n }) } }), o.locked ? t("ProBadge", { staticClass: "absolute bottom-2 right-4" }) : e._e()], 1)]);
5942
+ } } }, [t("simplebar", { staticClass: "h-full py-4 pl-3", attrs: { "data-simplebar-auto-hide": "false" } }, [t("DragList", { attrs: { group: { name: "blocks", pull: "clone", put: !1 }, "get-child-payload": (o) => e.getSubMenuPayload({ index: o, getBlockPayload: n }), "drop-placeholder": { className: "drag-drop-menu-placeholder" }, "get-ghost-parent": e.getGhostParent, "non-drag-area-selector": ".no-drag", "drag-handle-selector": ".drag-item", "group-name": "document-blocks", "ghost-class": "drag-drop-ghost", behaviour: "copy" } }, e._l(e.activeSubMenu, function(o, l) {
5943
+ return t("DragItem", { key: o.key + l, staticClass: "px-1.5", class: { "drag-item": !o.locked && e.canUseBlocks } }, [t("div", { staticClass: "relative" }, [t("div", { staticClass: "drag-item-preview", domProps: { innerHTML: e._s(o.previewUrl) }, on: { click: (r) => e.onUseBlock({ block: o, addBlock: a, openUpgradeModal: s }) } }), o.locked ? t("ProBadge", { staticClass: "absolute bottom-2 right-4" }) : e._e()], 1)]);
5944
5944
  }), 1)], 1)], 1)])], 1)];
5945
5945
  } }], null, !0) })];
5946
5946
  } }]) });
5947
- }, W2 = [], q2 = /* @__PURE__ */ d(
5948
- G2,
5947
+ }, G2 = [], W2 = /* @__PURE__ */ d(
5948
+ O2,
5949
5949
  R2,
5950
- W2,
5950
+ G2,
5951
5951
  !1,
5952
5952
  null,
5953
5953
  "126e204b",
5954
5954
  null,
5955
5955
  null
5956
5956
  );
5957
- const N2 = q2.exports;
5958
- const j2 = {
5957
+ const q2 = W2.exports;
5958
+ const N2 = {
5959
5959
  name: "DocumentFormMenu",
5960
5960
  i18nOptions: {
5961
5961
  namespaces: "documentFormMenu",
@@ -5971,12 +5971,12 @@ const j2 = {
5971
5971
  }
5972
5972
  },
5973
5973
  components: {
5974
- Design: g2,
5975
- Fields: $2,
5976
- ExtensionTab: B2,
5977
- DocumentGeneralSettings: A2,
5978
- DocumentGuide: () => import("./index-4a052f26.js"),
5979
- MenuBlocks: N2,
5974
+ Design: f2,
5975
+ Fields: L2,
5976
+ ExtensionTab: V2,
5977
+ DocumentGeneralSettings: H2,
5978
+ DocumentGuide: () => import("./index-c6a51a6f.js"),
5979
+ MenuBlocks: q2,
5980
5980
  Simplebar: L
5981
5981
  },
5982
5982
  props: {
@@ -6043,7 +6043,7 @@ const j2 = {
6043
6043
  }
6044
6044
  }
6045
6045
  };
6046
- var K2 = function() {
6046
+ var j2 = function() {
6047
6047
  var e = this, t = e._self._c;
6048
6048
  return t("div", [t("div", { staticClass: "root menu-wrapper", style: [{ width: `${e.width}px` }, e.fixed && { zIndex: 999 }] }, [e.fixed ? t("div", { staticClass: "fixed inset-0", on: { click: function(a) {
6049
6049
  return e.$emit("close");
@@ -6077,7 +6077,7 @@ var K2 = function() {
6077
6077
  externalReferences: "externalReferences",
6078
6078
  clients: "clients",
6079
6079
  articles: "articles"
6080
- } }, on: { input: ({ key: a, value: s }) => e.set({ key: a, value: s }) } }) : e._e(), e.tab === "generalSettings" ? t("DocumentGeneralSettings", { class: { "!top-0 rounded-sm": e.isLegacyTemplate }, attrs: { _document: e.state, _value: {
6080
+ } }, on: { input: ({ key: a, value: n }) => e.set({ key: a, value: n }) } }) : e._e(), e.tab === "generalSettings" ? t("DocumentGeneralSettings", { class: { "!top-0 rounded-sm": e.isLegacyTemplate }, attrs: { _document: e.state, _value: {
6081
6081
  term: "data.terms",
6082
6082
  series: "docNumber.series",
6083
6083
  tags: "tags",
@@ -6087,21 +6087,21 @@ var K2 = function() {
6087
6087
  useVat: "data.formSettings.useVat",
6088
6088
  vatType: "data.formSettings.vatType",
6089
6089
  rounding: "data.formSettings.rounding"
6090
- }, offset: e.fixed ? 0 : e.width }, on: { input: ({ key: a, value: s }) => e.set({ key: a, value: s }) } }) : e._e()], 1)], 1), e.showGuide ? t("DocumentGuide", { on: { close: function(a) {
6090
+ }, offset: e.fixed ? 0 : e.width }, on: { input: ({ key: a, value: n }) => e.set({ key: a, value: n }) } }) : e._e()], 1)], 1), e.showGuide ? t("DocumentGuide", { on: { close: function(a) {
6091
6091
  e.showGuide = !1;
6092
6092
  } } }) : e._e()], 1)])]);
6093
- }, Y2 = [], Q2 = /* @__PURE__ */ d(
6093
+ }, K2 = [], Y2 = /* @__PURE__ */ d(
6094
+ N2,
6094
6095
  j2,
6095
6096
  K2,
6096
- Y2,
6097
6097
  !1,
6098
6098
  null,
6099
6099
  "670ad23f",
6100
6100
  null,
6101
6101
  null
6102
6102
  );
6103
- const J2 = Q2.exports;
6104
- const X2 = {
6103
+ const Q2 = Y2.exports;
6104
+ const J2 = {
6105
6105
  name: "BlockControlButtons",
6106
6106
  i18nOptions: {
6107
6107
  namespace: "blockControlButtons",
@@ -6133,7 +6133,7 @@ const X2 = {
6133
6133
  }
6134
6134
  }
6135
6135
  };
6136
- var ei = function() {
6136
+ var X2 = function() {
6137
6137
  var e = this, t = e._self._c;
6138
6138
  return t("div", { staticClass: "flex gap-2 control-root" }, [e.canToggleVisibility ? t("div", { staticClass: "control-button", on: { click: function(a) {
6139
6139
  return e.$emit("toggle-visible", !e.isVisible);
@@ -6144,21 +6144,21 @@ var ei = function() {
6144
6144
  } } }, [t("BaseIcon", { attrs: { type: "chevron-down", size: "16" } })], 1)]), t("div", { staticClass: "control-button remove", on: { click: function(a) {
6145
6145
  return e.$emit("remove");
6146
6146
  } } }, [t("BaseIcon", { attrs: { type: "x", size: "16" } })], 1)]) : e._e()], 2);
6147
- }, ti = [], ii = /* @__PURE__ */ d(
6147
+ }, ei = [], ti = /* @__PURE__ */ d(
6148
+ J2,
6148
6149
  X2,
6149
6150
  ei,
6150
- ti,
6151
6151
  !1,
6152
6152
  null,
6153
6153
  "9e35bda4",
6154
6154
  null,
6155
6155
  null
6156
6156
  );
6157
- const ai = ii.exports;
6158
- const si = {
6157
+ const ii = ti.exports;
6158
+ const ai = {
6159
6159
  name: "DynamicBlock",
6160
6160
  components: {
6161
- BlockControlButtons: ai
6161
+ BlockControlButtons: ii
6162
6162
  },
6163
6163
  props: {
6164
6164
  isDragging: {
@@ -6242,18 +6242,18 @@ var ni = function() {
6242
6242
  }, remove: function(a) {
6243
6243
  return e.$emit("remove");
6244
6244
  } } }, [e.showEditButton ? t("CButton", { staticClass: "document-block__edit-button", attrs: { round: "", size: "small", thinner: "", "icon-right": "colored-dots" }, on: { click: e.onEdit } }, [e._v(" " + e._s(e.$t("_common:edit").capitalize()) + " ")]) : e._e()], 1) : e._e()], 1)]);
6245
- }, oi = [], li = /* @__PURE__ */ d(
6246
- si,
6245
+ }, si = [], oi = /* @__PURE__ */ d(
6246
+ ai,
6247
6247
  ni,
6248
- oi,
6248
+ si,
6249
6249
  !1,
6250
6250
  null,
6251
6251
  "3d358acc",
6252
6252
  null,
6253
6253
  null
6254
6254
  );
6255
- const ri = li.exports;
6256
- const ci = {
6255
+ const li = oi.exports;
6256
+ const ri = {
6257
6257
  name: "DocumentDrawer",
6258
6258
  components: {
6259
6259
  simplebar: L,
@@ -6279,7 +6279,7 @@ const ci = {
6279
6279
  }
6280
6280
  }
6281
6281
  };
6282
- var di = function() {
6282
+ var ci = function() {
6283
6283
  var e = this, t = e._self._c;
6284
6284
  return t("transition", { attrs: { name: e.fixed ? void 0 : "grow-anim", mode: "out-in" } }, [e.open ? t(e.fixed ? "drawer" : "div", e._b({ ref: "drawer", tag: "component", staticClass: "font-inter document-drawer-root", class: {
6285
6285
  "is-sticky": !e.fixed
@@ -6291,18 +6291,18 @@ var di = function() {
6291
6291
  padding: "calc(2.5 * var(--rem)) calc(1 * var(--rem)) calc(6 * var(--rem)) calc(1 * var(--rem))",
6292
6292
  ...e.fixedStyle
6293
6293
  } }, [e._t("default")], 2)])])]) : e._e()], 1);
6294
- }, pi = [], ui = /* @__PURE__ */ d(
6294
+ }, di = [], pi = /* @__PURE__ */ d(
6295
+ ri,
6295
6296
  ci,
6296
6297
  di,
6297
- pi,
6298
6298
  !1,
6299
6299
  null,
6300
6300
  "28a55097",
6301
6301
  null,
6302
6302
  null
6303
6303
  );
6304
- const mi = ui.exports;
6305
- const hi = {
6304
+ const ui = pi.exports;
6305
+ const mi = {
6306
6306
  name: "DocumentFormViewRadio",
6307
6307
  props: {
6308
6308
  value: {
@@ -6315,24 +6315,24 @@ const hi = {
6315
6315
  }
6316
6316
  }
6317
6317
  };
6318
- var fi = function() {
6318
+ var hi = function() {
6319
6319
  var e = this, t = e._self._c;
6320
6320
  return t("div", { staticClass: "nav-toggle font-inter" }, [t("div", { staticClass: "nav-toggle-button", class: { active: e.value === "edit" }, on: { click: function(a) {
6321
6321
  e.value === "preview" && e.$emit("input", "edit");
6322
6322
  } } }, [e.small ? t("BaseIcon", { attrs: { type: "edit", size: "18" } }) : [e._v(e._s(e.$t("edit")))]], 2), t("div", { staticClass: "nav-toggle-button", class: { active: e.value === "preview" }, attrs: { "data-onboarding": "preview-button" }, on: { click: function(a) {
6323
6323
  e.value === "edit" && e.$emit("input", "preview");
6324
6324
  } } }, [e.small ? t("BaseIcon", { attrs: { type: "eye", size: "18" } }) : [e._v(e._s(e.$t("preview")))]], 2)]);
6325
- }, gi = [], Ci = /* @__PURE__ */ d(
6325
+ }, fi = [], gi = /* @__PURE__ */ d(
6326
+ mi,
6326
6327
  hi,
6327
6328
  fi,
6328
- gi,
6329
6329
  !1,
6330
6330
  null,
6331
6331
  "2d9aa751",
6332
6332
  null,
6333
6333
  null
6334
6334
  );
6335
- const vi = Ci.exports, yi = {
6335
+ const Ci = gi.exports, vi = {
6336
6336
  name: "LogoBanner",
6337
6337
  props: {
6338
6338
  position: {
@@ -6350,46 +6350,46 @@ const vi = Ci.exports, yi = {
6350
6350
  }
6351
6351
  }
6352
6352
  };
6353
- var xi = function() {
6353
+ var yi = function() {
6354
6354
  var e = this, t = e._self._c;
6355
6355
  return t("div", { staticClass: "z-50 flex justify-end bottom-0 left-0 right-0 pb-[10px] px-[10px] pointer-events-none", class: e.position }, [t("a", { staticClass: "pointer-events-auto inline-flex items-center h-8 pl-1.5 pr-2 border rounded-md bg-black/80 border-white/30", attrs: { href: `https://${e.$t(
6356
6356
  "_common:brand.domain"
6357
6357
  )}?utm_source=document&utm_medium=logo-banner`, target: "_blank" } }, [t("div", { staticClass: "w-5 h-5 mr-2 overflow-hidden bg-white rounded" }, [t("img", { staticClass: "w-full h-full", attrs: { src: e.logoUrl, alt: e.$t("brand.name") } })]), t("div", { staticClass: "text-xs font-medium text-white" }, [e._v(" Made in " + e._s(e.$t("brand.name")) + " ")])])]);
6358
- }, wi = [], bi = /* @__PURE__ */ d(
6358
+ }, xi = [], wi = /* @__PURE__ */ d(
6359
+ vi,
6359
6360
  yi,
6360
6361
  xi,
6361
- wi,
6362
6362
  !1,
6363
6363
  null,
6364
6364
  null,
6365
6365
  null,
6366
6366
  null
6367
6367
  );
6368
- const _i = bi.exports;
6369
- const ki = {
6368
+ const bi = wi.exports;
6369
+ const _i = {
6370
6370
  name: "DocumentFormNav"
6371
6371
  };
6372
- var Li = function() {
6372
+ var ki = function() {
6373
6373
  var e = this, t = e._self._c;
6374
6374
  return t("div", { staticClass: "DocumentFormNav py-2 px-2 md:px-6 fixed left-0 top-0 right-0 z-[98]" }, [t("div", { staticClass: "flex" }, [t("div", { staticClass: "inline-flex items-center flex-grow" }, [e._t("left")], 2), t("div", { staticClass: "inline-flex items-center justify-center flex-auto" }, [e._t("center")], 2), t("div", { staticClass: "inline-flex items-center justify-end flex-grow" }, [e._t("right")], 2)])]);
6375
- }, $i = [], Si = /* @__PURE__ */ d(
6375
+ }, Li = [], $i = /* @__PURE__ */ d(
6376
+ _i,
6376
6377
  ki,
6377
6378
  Li,
6378
- $i,
6379
6379
  !1,
6380
6380
  null,
6381
6381
  "39c32da6",
6382
6382
  null,
6383
6383
  null
6384
6384
  );
6385
- const Ti = Si.exports;
6385
+ const Si = $i.exports;
6386
6386
  const X = (i, e, t = "$children") => {
6387
6387
  if (!i)
6388
6388
  return;
6389
6389
  e(i);
6390
6390
  const a = i[t];
6391
- !a && !Array.isArray(a) || a.forEach((s) => X(s, e));
6392
- }, Di = {
6391
+ !a && !Array.isArray(a) || a.forEach((n) => X(n, e));
6392
+ }, Ti = {
6393
6393
  i18nOptions: {
6394
6394
  namespaces: "DocumentFormContainer",
6395
6395
  messages: {
@@ -6405,18 +6405,18 @@ const X = (i, e, t = "$children") => {
6405
6405
  },
6406
6406
  name: "DocumentFormContainer",
6407
6407
  components: {
6408
- WithDimensions: Ee,
6409
- DragList: R,
6408
+ WithDimensions: ze,
6409
+ DragList: G,
6410
6410
  DragItem: W,
6411
- DynamicChapter: Ze,
6412
- DocumentFormMenu: J2,
6413
- DynamicBlock: ri,
6414
- DocumentFormViewRadio: vi,
6415
- DocumentFormNav: Ti,
6416
- DocumentDrawer: mi,
6417
- DocumentStyleContainer: Ue,
6411
+ DynamicChapter: Ee,
6412
+ DocumentFormMenu: Q2,
6413
+ DynamicBlock: li,
6414
+ DocumentFormViewRadio: Ci,
6415
+ DocumentFormNav: Si,
6416
+ DocumentDrawer: ui,
6417
+ DocumentStyleContainer: Ze,
6418
6418
  simplebar: L,
6419
- LogoBanner: _i,
6419
+ LogoBanner: bi,
6420
6420
  IsPremium: _
6421
6421
  },
6422
6422
  props: {
@@ -6521,29 +6521,29 @@ const X = (i, e, t = "$children") => {
6521
6521
  var e, t;
6522
6522
  i && (Object.keys(((t = (e = this._document._doc) == null ? void 0 : e.data) == null ? void 0 : t.packageGroups) || []).forEach(
6523
6523
  (a) => {
6524
- this._document._doc.data.packageGroups[a].packages.forEach((n, o) => {
6524
+ this._document._doc.data.packageGroups[a].packages.forEach((s, o) => {
6525
6525
  this.setFormValue({
6526
6526
  key: `data.packageGroups.${a}.packages[${o}].data.prices.currency`,
6527
6527
  value: i
6528
6528
  });
6529
6529
  });
6530
6530
  }
6531
- ), this._document.allArticles.forEach((a, s) => {
6532
- const n = `articles[${s}].currency`;
6533
- this.setFormValue({ key: n, value: i });
6531
+ ), this._document.allArticles.forEach((a, n) => {
6532
+ const s = `articles[${n}].currency`;
6533
+ this.setFormValue({ key: s, value: i });
6534
6534
  }));
6535
6535
  },
6536
6536
  async externalReferences(i) {
6537
6537
  await Promise.all(
6538
6538
  (i || []).map(async ({ service: e, type: t, typeId: a }) => {
6539
6539
  if (t && a && e && this.$store.getters["settings/isAuthenticatedCRM"](e)) {
6540
- const { data: s } = await $.getFields(
6540
+ const { data: n } = await $.getFields(
6541
6541
  e,
6542
6542
  { type: t, typeId: a, populated: !0 }
6543
6543
  );
6544
6544
  this.setFormValue({
6545
6545
  key: "data.fields",
6546
- value: { ...this._document.fields, ...s }
6546
+ value: { ...this._document.fields, ...n }
6547
6547
  });
6548
6548
  }
6549
6549
  })
@@ -6552,11 +6552,11 @@ const X = (i, e, t = "$children") => {
6552
6552
  },
6553
6553
  methods: {
6554
6554
  onAddBlockMount(i, e) {
6555
- !this.onAddRedis[i] || !e || (e.$el && this.$nextTick(() => Je(e.$el, { offset: 100 })), typeof e[this.onAddRedis[i]] == "function" && e[this.onAddRedis[i]](), delete this.onAddRedis[i]);
6555
+ !this.onAddRedis[i] || !e || (e.$el && this.$nextTick(() => Qe(e.$el, { offset: 100 })), typeof e[this.onAddRedis[i]] == "function" && e[this.onAddRedis[i]](), delete this.onAddRedis[i]);
6556
6556
  },
6557
6557
  onBlockToggleVisible(i, e) {
6558
6558
  const a = [...this.readLayout].findIndex(
6559
- (s) => s.nodeId === i.nodeId
6559
+ (n) => n.nodeId === i.nodeId
6560
6560
  );
6561
6561
  a !== -1 && this.setFormValue({
6562
6562
  key: `template.views.read.nodes[${a}].isVisible`,
@@ -6576,10 +6576,10 @@ const X = (i, e, t = "$children") => {
6576
6576
  const a = i.itemId.split("-")[1];
6577
6577
  this.removePackageGroup(a);
6578
6578
  } else
6579
- X(i, (s) => {
6580
- s.value && Object.values(s.value).forEach((n) => {
6581
- this.removeFormKeyValue(`${n}`);
6582
- let o = n.replace(
6579
+ X(i, (n) => {
6580
+ n.value && Object.values(n.value).forEach((s) => {
6581
+ this.removeFormKeyValue(`${s}`);
6582
+ let o = s.replace(
6583
6583
  /^data.(?!properties)/g,
6584
6584
  "data.properties."
6585
6585
  );
@@ -6590,8 +6590,8 @@ const X = (i, e, t = "$children") => {
6590
6590
  });
6591
6591
  }, "children");
6592
6592
  B([this.nestedReadLayout[e]]).forEach((a) => {
6593
- const s = this.readLayout.findIndex((n) => n.nodeId === a.nodeId);
6594
- this.removeFormValue(`template.views.read.nodes[${s}]`);
6593
+ const n = this.readLayout.findIndex((s) => s.nodeId === a.nodeId);
6594
+ this.removeFormValue(`template.views.read.nodes[${n}]`);
6595
6595
  });
6596
6596
  },
6597
6597
  removePackageGroup(i) {
@@ -6600,7 +6600,7 @@ const X = (i, e, t = "$children") => {
6600
6600
  this.setFormValue({
6601
6601
  key: "articles",
6602
6602
  value: u(this._document, "_doc.articles", []).filter(
6603
- ({ packageId: s }) => s !== a.packageId
6603
+ ({ packageId: n }) => n !== a.packageId
6604
6604
  )
6605
6605
  });
6606
6606
  });
@@ -6616,23 +6616,23 @@ const X = (i, e, t = "$children") => {
6616
6616
  if (e !== null && t !== null) {
6617
6617
  if (e === t)
6618
6618
  return;
6619
- const s = $e(
6619
+ const n = $e(
6620
6620
  this.nestedReadLayout,
6621
6621
  e,
6622
6622
  t
6623
6623
  );
6624
6624
  this.setFormValue({
6625
6625
  key: "template.views.read.nodes",
6626
- value: B(s)
6626
+ value: B(n)
6627
6627
  });
6628
6628
  } else if (!e && t !== null) {
6629
- const { sectionKey: s, createNewSection: n, addValidation: o, contentData: l } = a, {
6629
+ const { sectionKey: n, createNewSection: s, addValidation: o, contentData: l } = a, {
6630
6630
  readView: r,
6631
6631
  validation: c,
6632
6632
  data: C,
6633
6633
  onAddFnName: V = "onAdd"
6634
- } = n({
6635
- sectionKey: s,
6634
+ } = s({
6635
+ sectionKey: n,
6636
6636
  document: this._document,
6637
6637
  contentData: l
6638
6638
  });
@@ -6655,13 +6655,13 @@ const X = (i, e, t = "$children") => {
6655
6655
  }
6656
6656
  }
6657
6657
  };
6658
- var Vi = function() {
6658
+ var Di = function() {
6659
6659
  var e = this, t = e._self._c;
6660
6660
  return t("div", { staticStyle: { overflow: "auto", height: "100vh" } }, [t("div", { staticClass: "flex container-root font-inter", class: {
6661
6661
  "is-edit-view": e.isEditView,
6662
6662
  "is-empty-list": !e.nestedReadLayout.length
6663
- } }, [t("DocumentFormMenu", { directives: [{ name: "show", rawName: "v-show", value: e.drawerState.showLeft, expression: "drawerState.showLeft" }], attrs: { state: e._document, "on-added-block": ({ nodeId: a, onAddFnName: s = "onAdd" }) => {
6664
- e.onAddRedis[a] = s;
6663
+ } }, [t("DocumentFormMenu", { directives: [{ name: "show", rawName: "v-show", value: e.drawerState.showLeft, expression: "drawerState.showLeft" }], attrs: { state: e._document, "on-added-block": ({ nodeId: a, onAddFnName: n = "onAdd" }) => {
6664
+ e.onAddRedis[a] = n;
6665
6665
  }, set: e.setFormValue, "remove-value": e.removeFormValue, template: e.docTemplate, fixed: e.drawerState.isFixed, "can-use-blocks": e.isTemplateEditable, "is-legacy-template": e.isLegacyTemplate, width: e.sidebarWidth }, on: { close: function(a) {
6666
6666
  e.drawerState.showLeft = !1;
6667
6667
  } } }), t("div", { ref: "scroll-body", staticClass: "flex justify-center w-full doc-scroll-container", class: {
@@ -6682,7 +6682,7 @@ var Vi = function() {
6682
6682
  paddingLeft: "6px",
6683
6683
  paddingRight: "6px",
6684
6684
  margin: 0
6685
- }, on: { click: function(s) {
6685
+ }, on: { click: function(n) {
6686
6686
  e.previewDevice = a;
6687
6687
  } } }, [t("BaseIcon", { attrs: { type: a, size: "18" } })], 1);
6688
6688
  }), 0) : e._e()], 1), e._t("nav-right", null, { slot: "right" })], 2), t("div", { staticClass: "list-container", class: [
@@ -6694,12 +6694,12 @@ var Vi = function() {
6694
6694
  e.isEditView && "overflow-hidden min-h-full w-[1200px] mx-auto md:max-w-[90%] max-w-full rounded-md shadow-[0_20px_35px_-8px_hsla(0,0%,0%,0.27)] px-0"
6695
6695
  ] }, [!e.nestedReadLayout.length && !e.isFixedSidebar ? t("div", { staticClass: "text-gray-400 drag-drop-empty-list is-placeholder" }, [t("div", { staticStyle: { position: "relative" } }, [e._m(0), t("svg", { staticClass: "drag-drop-illustration", attrs: { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 50 50" } }, [t("path", { staticClass: "drag-drop-illustration-finger", attrs: { d: "M8 0a4 4 0 00-2.7 1C4.6 1.6 4 2.7 4 4v21.4c-.4.2-.8.2-1.7 1A7.2 7.2 0 000 31.8c0 2 .8 3.8 1 4.5L4 42s-.1 0 0 0c1.4 3.1 4.5 5 8 5h9c5 0 9-4 9-9V22c0-.8-.1-2-.7-3-.5-1-1.7-2-3.3-2-1 0-2 .4-2.6.9 0-.3-.1-.7-.3-1-.6-1-1.7-1.9-3.1-1.9a4 4 0 00-2.7 1c-.6-1.1-1.7-2-3.3-2-.8 0-1.4.2-2 .6V4a4 4 0 00-4-4z", fill: "#000", "fill-rule": "nonzero" } }), t("path", { staticClass: "drag-drop-illustration-grabbing", attrs: { transform: "translate(0 11)", d: "M14 1c-.8 0-1.8.2-2.6.8l-.9 1a4 4 0 00-5.2.2C4.6 3.6 4 4.7 4 5.9V14c-1.7.7-4 3-4 7 0 2.2.9 4.2 1 4.5L3.9 31c1.5 3.1 4.6 5 8 5H21c5 0 9-4 9-9V9c0-4.4-2.5-5-4-5-.7 0-1.5.1-2.3.7C23 2.5 21.4 2 20 2c-1 0-2 .3-2.6.8l-.6-.9A4 4 0 0014 1z", fill: "#000", "fill-rule": "nonzero" } })])]), t("div", { staticClass: "text-center", staticStyle: { "max-width": "22ch" }, domProps: { innerHTML: e._s(e.$t("emptyBlockPlaceholderLarge")) } })]) : e._e(), t(e.isEditView ? "div" : "simplebar", { tag: "component", staticClass: "w-full h-full" }, [t("WithDimensions", { attrs: { "provide-device": !0 }, on: { width: function(a) {
6696
6696
  e.parentSize.width = a;
6697
- } }, scopedSlots: e._u([{ key: "default", fn: function({ width: a, height: s }) {
6698
- var n, o;
6697
+ } }, scopedSlots: e._u([{ key: "default", fn: function({ width: a, height: n }) {
6698
+ var s, o;
6699
6699
  return t("DocumentStyleContainer", { staticClass: "relative w-full h-full", style: {
6700
6700
  "--vw": `${a / 100}px`,
6701
- "--vh": `clamp(7.5px, ${s / 100}px, ${e.isEditView ? 7.5 : 9}px)`
6702
- }, attrs: { "heading-color": e.headingColor, "input-style": ((o = (n = e._document) == null ? void 0 : n.data) == null ? void 0 : o.css) || null } }, [e.nestedReadLayout ? t("DragList", { staticClass: "drag-list", attrs: { handle: ".NO-SELECTOR", "drop-placeholder": { className: "drag-drop-placeholder" }, "should-animate-drop": e.shouldAnimateDrop, group: "blocks", "ghost-class": "drag-drop-ghost", "drag-class": "is-dragged", "group-name": "document-blocks", "non-drag-area-selector": ".no-drag", "drag-handle-selector": ".drag-item" }, on: { "drag-start": function(l) {
6701
+ "--vh": `clamp(7.5px, ${n / 100}px, ${e.isEditView ? 7.5 : 9}px)`
6702
+ }, attrs: { "heading-color": e.headingColor, "input-style": ((o = (s = e._document) == null ? void 0 : s.data) == null ? void 0 : o.css) || null } }, [e.nestedReadLayout ? t("DragList", { staticClass: "drag-list", attrs: { handle: ".NO-SELECTOR", "drop-placeholder": { className: "drag-drop-placeholder" }, "should-animate-drop": e.shouldAnimateDrop, group: "blocks", "ghost-class": "drag-drop-ghost", "drag-class": "is-dragged", "group-name": "document-blocks", "non-drag-area-selector": ".no-drag", "drag-handle-selector": ".drag-item" }, on: { "drag-start": function(l) {
6703
6703
  e.isDragging = !0;
6704
6704
  }, "drag-end": function(l) {
6705
6705
  e.isDragging = !1;
@@ -6733,30 +6733,30 @@ var Vi = function() {
6733
6733
  } } }, [t("CButton", { staticClass: "absolute top-2 right-2", attrs: { "icon-props": { size: 20 }, size: "normal", icon: "x", circle: "", type: "none", pattern: "tertiary" }, on: { click: function(a) {
6734
6734
  e.drawerState.openSection = null;
6735
6735
  } } }), t("portal-target", { attrs: { name: "drawer-content" } })], 1)], 1)]);
6736
- }, Bi = [function() {
6736
+ }, Vi = [function() {
6737
6737
  var i = this, e = i._self._c;
6738
6738
  return e("div", { staticClass: "drag-drop-illustration-block" }, [e("div"), e("div")]);
6739
- }], Mi = /* @__PURE__ */ d(
6739
+ }], Bi = /* @__PURE__ */ d(
6740
+ Ti,
6740
6741
  Di,
6741
6742
  Vi,
6742
- Bi,
6743
6743
  !1,
6744
6744
  null,
6745
6745
  "d761f136",
6746
6746
  null,
6747
6747
  null
6748
6748
  );
6749
- const Ii = Mi.exports;
6749
+ const Mi = Bi.exports;
6750
6750
  function Fi(i, e, t) {
6751
6751
  return i === i && (t !== void 0 && (i = i <= t ? i : t), e !== void 0 && (i = i >= e ? i : e)), i;
6752
6752
  }
6753
- var Hi = Fi, Ai = Hi, M = Ge;
6754
- function Pi(i, e, t) {
6755
- return t === void 0 && (t = e, e = void 0), t !== void 0 && (t = M(t), t = t === t ? t : 0), e !== void 0 && (e = M(e), e = e === e ? e : 0), Ai(M(i), e, t);
6753
+ var Ii = Fi, Hi = Ii, M = Oe;
6754
+ function Ai(i, e, t) {
6755
+ return t === void 0 && (t = e, e = void 0), t !== void 0 && (t = M(t), t = t === t ? t : 0), e !== void 0 && (e = M(e), e = e === e ? e : 0), Hi(M(i), e, t);
6756
6756
  }
6757
- var zi = Pi;
6758
- const Ei = /* @__PURE__ */ Te(zi);
6759
- const Zi = {
6757
+ var Pi = Ai;
6758
+ const zi = /* @__PURE__ */ Te(Pi);
6759
+ const Ei = {
6760
6760
  name: "RemainingTrialButton",
6761
6761
  components: { IsPremium: _ },
6762
6762
  i18nOptions: {
@@ -6788,46 +6788,46 @@ const Zi = {
6788
6788
  },
6789
6789
  mixins: [b],
6790
6790
  methods: {
6791
- clamp: Ei
6791
+ clamp: zi
6792
6792
  }
6793
6793
  };
6794
- var Ui = function() {
6794
+ var Zi = function() {
6795
6795
  var e = this, t = e._self._c;
6796
6796
  return t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({
6797
6797
  accountType: a,
6798
- trialDaysLeft: s,
6799
- openUpgradeModal: n,
6798
+ trialDaysLeft: n,
6799
+ openUpgradeModal: s,
6800
6800
  initialFreePremiumDays: o
6801
6801
  }) {
6802
- return [a === "trial" && e.mq !== "sm" ? t("v-popover", { attrs: { "popover-inner-class": "bg-white rounded-md shadow-xl" } }, [t("div", { staticClass: "relative flex flex-col justify-center px-2 mr-2 text-xs font-semibold rounded-md cursor-pointer select-none bg-gray-200/50 h-9 backdrop-blur-lg backdrop-saturate-150" }, [t("div", { staticClass: "text-gray-600" }, [e._v(" " + e._s(e.$tc("_common:day", { count: s })) + " " + e._s(e.$t("button")) + " ")]), t("div", { staticClass: "h-[3px] bg-gray-300 absolute bottom-1 left-2 right-2 rounded-full ring-1 ring-white/10" }, [t("div", { staticClass: "absolute h-full rounded-full bg-gradient-to-r from-green-500 via-emerald-500 to-primary-600", style: {
6803
- width: e.clamp(s / o * 100, 0, 100) + "%"
6804
- } })])]), t("div", { staticClass: "p-4 text-sm w-56", attrs: { slot: "popover" }, slot: "popover" }, [t("div", { staticClass: "font-semibold" }, [e._v(" " + e._s(e.$t("title.1")) + " "), t("span", { staticClass: "inline-flex py-[3px] px-1.5 leading-none bg-primary-100 border border-primary-200 text-primary-800 rounded-md text-xs" }, [e._v(e._s(e.$t("title.2")))]), e._v(" " + e._s(e.$t("title.3", { trialDaysLeft: s })) + ". ")]), t("div", { staticClass: "text-sm text-gray-600" }, [e._v(" " + e._s(e.$t("title.4")) + " "), t("span", { staticClass: "inline-flex py-[3px] px-1.5 leading-none bg-gray-200 border border-gray-300 text-gray-600 rounded-md text-xs font-semibold" }, [e._v(e._s(e.$t("title.5")))]), e._v(". ")]), t("div", { staticClass: "mt-5" }, [t("CButton", { directives: [{ name: "close-popover", rawName: "v-close-popover" }], attrs: { type: "secondary", size: "small", "icon-right": "arrow-right" }, on: { click: n } }, [e._v(" " + e._s(e.$t("actionButton")) + " ")])], 1)])]) : e._e()];
6802
+ return [a === "trial" && e.mq !== "sm" ? t("v-popover", { attrs: { "popover-inner-class": "bg-white rounded-md shadow-xl" } }, [t("div", { staticClass: "relative flex flex-col justify-center px-2 mr-2 text-xs font-semibold rounded-md cursor-pointer select-none bg-gray-200/50 h-9 backdrop-blur-lg backdrop-saturate-150" }, [t("div", { staticClass: "text-gray-600" }, [e._v(" " + e._s(e.$tc("_common:day", { count: n })) + " " + e._s(e.$t("button")) + " ")]), t("div", { staticClass: "h-[3px] bg-gray-300 absolute bottom-1 left-2 right-2 rounded-full ring-1 ring-white/10" }, [t("div", { staticClass: "absolute h-full rounded-full bg-gradient-to-r from-green-500 via-emerald-500 to-primary-600", style: {
6803
+ width: e.clamp(n / o * 100, 0, 100) + "%"
6804
+ } })])]), t("div", { staticClass: "p-4 text-sm w-56", attrs: { slot: "popover" }, slot: "popover" }, [t("div", { staticClass: "font-semibold" }, [e._v(" " + e._s(e.$t("title.1")) + " "), t("span", { staticClass: "inline-flex py-[3px] px-1.5 leading-none bg-primary-100 border border-primary-200 text-primary-800 rounded-md text-xs" }, [e._v(e._s(e.$t("title.2")))]), e._v(" " + e._s(e.$t("title.3", { trialDaysLeft: n })) + ". ")]), t("div", { staticClass: "text-sm text-gray-600" }, [e._v(" " + e._s(e.$t("title.4")) + " "), t("span", { staticClass: "inline-flex py-[3px] px-1.5 leading-none bg-gray-200 border border-gray-300 text-gray-600 rounded-md text-xs font-semibold" }, [e._v(e._s(e.$t("title.5")))]), e._v(". ")]), t("div", { staticClass: "mt-5" }, [t("CButton", { directives: [{ name: "close-popover", rawName: "v-close-popover" }], attrs: { type: "secondary", size: "small", "icon-right": "arrow-right" }, on: { click: s } }, [e._v(" " + e._s(e.$t("actionButton")) + " ")])], 1)])]) : e._e()];
6805
6805
  } }]) });
6806
- }, Oi = [], Gi = /* @__PURE__ */ d(
6806
+ }, Ui = [], Oi = /* @__PURE__ */ d(
6807
+ Ei,
6807
6808
  Zi,
6808
6809
  Ui,
6809
- Oi,
6810
6810
  !1,
6811
6811
  null,
6812
6812
  "ef060cb6",
6813
6813
  null,
6814
6814
  null
6815
6815
  );
6816
- const Ri = Gi.exports, T = A.observable({
6816
+ const Ri = Oi.exports, T = A.observable({
6817
6817
  canEdit: !1,
6818
6818
  isForm: !0,
6819
6819
  setFormValue: null,
6820
6820
  removeFormValue: null
6821
- }), Wi = {
6821
+ }), Gi = {
6822
6822
  name: "DocumentForm",
6823
6823
  components: {
6824
- DocumentFormContainer: Ii,
6824
+ DocumentFormContainer: Mi,
6825
6825
  IsPremium: _,
6826
6826
  IsPremiumPreStep: k,
6827
- DocumentSend: t2,
6827
+ DocumentSend: e2,
6828
6828
  RemainingTrialButton: Ri
6829
6829
  },
6830
- mixins: [Ne],
6830
+ mixins: [qe],
6831
6831
  props: {
6832
6832
  document: {
6833
6833
  type: Object,
@@ -6931,20 +6931,20 @@ const Ri = Gi.exports, T = A.observable({
6931
6931
  }
6932
6932
  }
6933
6933
  };
6934
- var qi = function() {
6934
+ var Wi = function() {
6935
6935
  var e = this, t = e._self._c;
6936
6936
  return e.document ? t("div", { staticClass: "flex flex-col w-screen bg-white" }, [t("DocumentFormContainer", { attrs: { _document: e.document, view: e.view, "set-form-value": e.setDocValue, "remove-form-value": e.removeDocValue, "remove-form-key-value": e.removeDocKeyValue, close: e.close, "go-back": e.goBack, "can-show-banner": e.canShowBanner }, on: { "update:view": function(a) {
6937
6937
  e.view = a;
6938
- } } }, [t("template", { slot: "nav-right" }, [t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canCreateDocument: a, canCreateTemplate: s }) {
6939
- return [t("IsPremiumPreStep", { attrs: { feature: "documents" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: n }) {
6938
+ } } }, [t("template", { slot: "nav-right" }, [t("IsPremium", { scopedSlots: e._u([{ key: "default", fn: function({ canCreateDocument: a, canCreateTemplate: n }) {
6939
+ return [t("IsPremiumPreStep", { attrs: { feature: "documents" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: s }) {
6940
6940
  return [t("div", { key: e.canDoActions, staticStyle: { flex: "1", display: "inline-flex", "justify-content": "flex-end" } }, [e._t("nav-right-action", function() {
6941
6941
  return [t("RemainingTrialButton"), t("div", { staticClass: "buttons has-addons", staticStyle: { "white-space": "nowrap" } }, [t("CButton", { ref: "sendButton", staticClass: "d-nav-button position right", staticStyle: { "border-radius": "7px 0 0 7px", height: "36px", "padding-left": "11px", "padding-right": "10px", "font-size": "13px", "font-weight": "500" }, attrs: { disabled: !e.canDoActions, loading: e.isLoading, "data-onboarding": "send-button", size: "small", type: "secondary", thinner: "" }, on: { click: function(o) {
6942
- a || !e.doConsumeQuota || e.document.id ? e.openSendModal() : n({ callback: e.openSendModal });
6942
+ a || !e.doConsumeQuota || e.document.id ? e.openSendModal() : s({ callback: e.openSendModal });
6943
6943
  } } }, [e._v(" " + e._s(e.$t("_common:reviewSend")) + " ")]), t("IsPremiumPreStep", { attrs: { feature: "saveDocTemplate" }, scopedSlots: e._u([{ key: "default", fn: function({ onClick: o }) {
6944
6944
  return [t("CDropdown", { attrs: { disabled: !e.canDoActions } }, [t("CButton", { staticClass: "d-nav-button position right", staticStyle: { "border-radius": "0px 7px 7px 0px", height: "36px", "border-left": "1px solid hsla(0, 0%, 100%, 0.35)", "font-size": "13px", "padding-left": "14px", "padding-right": "14px" }, attrs: { slot: "trigger", "icon-props": { size: 13, strokeWidth: 2.5 }, size: "small", type: "secondary", thinner: "", icon: "chevron-down" }, slot: "trigger" }), t("CDropdownItem", { attrs: { "icon-props": { stroke: "hsl(205, 100%, 50%)" }, "icon-left": "save" }, on: { click: function(l) {
6945
- a || e.document.id ? e.submitSave() : n({ callback: e.submitSave });
6945
+ a || e.document.id ? e.submitSave() : s({ callback: e.submitSave });
6946
6946
  } } }, [e._v(" " + e._s(e.$t("_common:save", { thing: e.$t("_common:document").toLowerCase() })) + " ")]), t("CDropdownItem", { attrs: { disabled: e.isLoading, "icon-left": "template-color" }, on: { click: function(l) {
6947
- s ? e.saveAsTemplate() : o({
6947
+ n ? e.saveAsTemplate() : o({
6948
6948
  callback: e.saveAsTemplate
6949
6949
  });
6950
6950
  } } }, [e._v(" " + e._s(e.$t("_common:saveAs", { thing: e.$t("_common:template") })) + " ")])], 1)];
@@ -6959,18 +6959,18 @@ var qi = function() {
6959
6959
  reminders: "data.reminders",
6960
6960
  name: "data.name"
6961
6961
  }, "set-form-value": e.setDocValue, "remove-form-value": e.removeDocValue, "on-save-document": e.onSaveDocument } })], 1) : e._e();
6962
- }, Ni = [], ji = /* @__PURE__ */ d(
6962
+ }, qi = [], Ni = /* @__PURE__ */ d(
6963
+ Gi,
6963
6964
  Wi,
6964
6965
  qi,
6965
- Ni,
6966
6966
  !1,
6967
6967
  null,
6968
6968
  null,
6969
6969
  null,
6970
6970
  null
6971
6971
  );
6972
- const Ki = ji.exports;
6973
- const Yi = {
6972
+ const ji = Ni.exports;
6973
+ const Ki = {
6974
6974
  name: "DocumentPostSendStep",
6975
6975
  mixins: [b],
6976
6976
  i18nOptions: {
@@ -7007,7 +7007,7 @@ const Yi = {
7007
7007
  return this.mq === "sm" ? "100%" : "auto";
7008
7008
  },
7009
7009
  usesManualDelivery() {
7010
- const i = I(this.document);
7010
+ const i = F(this.document);
7011
7011
  return !i.sms && !i.email;
7012
7012
  }
7013
7013
  },
@@ -7022,12 +7022,12 @@ const Yi = {
7022
7022
  sendDocument: m.DO_SEND_DOCUMENT2
7023
7023
  }),
7024
7024
  async handleDocumentLinks() {
7025
- const { id: i } = this.document, e = I(this.document), t = !e.sms && !e.email;
7025
+ const { id: i } = this.document, e = F(this.document), t = !e.sms && !e.email;
7026
7026
  t && (await this.updateDocument({
7027
7027
  id: i,
7028
7028
  body: { status: "sent" },
7029
7029
  showMessage: !1
7030
- }), Xe({ id: i })), t || setTimeout(() => this.close(), 2e3);
7030
+ }), Je({ id: i })), t || setTimeout(() => this.close(), 2e3);
7031
7031
  },
7032
7032
  async onSend() {
7033
7033
  typeof this.onSendFunc == "function" && this.onSendFunc(this.document), await this.handleDocumentLinks();
@@ -7046,7 +7046,7 @@ const Yi = {
7046
7046
  body: { isAccepted: !0 },
7047
7047
  checksum: a
7048
7048
  }), await this.sendDocument({ id: i }), this.onSend()) : (this.$modal.show(
7049
- et,
7049
+ Xe,
7050
7050
  {
7051
7051
  _document: this.document,
7052
7052
  fullScreen: this.modalHeight === "100%",
@@ -7055,12 +7055,12 @@ const Yi = {
7055
7055
  // actions intended mirror public requests made in accept/bankId modals
7056
7056
  // defined here in order to keep it DRY and avoiding account module actions defined in answer modals
7057
7057
  senderActions: {
7058
- answer: async function({ body: n }) {
7058
+ answer: async function({ body: s }) {
7059
7059
  var o;
7060
7060
  return this.answerDocument({
7061
7061
  id: i,
7062
7062
  publicId: e.publicDocumentId,
7063
- body: n,
7063
+ body: s,
7064
7064
  checksum: (o = this.document._doc) == null ? void 0 : o.checksum
7065
7065
  });
7066
7066
  }.bind(this),
@@ -7079,8 +7079,8 @@ const Yi = {
7079
7079
  },
7080
7080
  {
7081
7081
  cancel: () => {
7082
- var s;
7083
- return (s = this.onCancelFunc) == null ? void 0 : s.call(this);
7082
+ var n;
7083
+ return (n = this.onCancelFunc) == null ? void 0 : n.call(this);
7084
7084
  }
7085
7085
  }
7086
7086
  ), !0);
@@ -7090,33 +7090,23 @@ const Yi = {
7090
7090
  }
7091
7091
  }
7092
7092
  };
7093
- var Qi = function() {
7093
+ var Yi = function() {
7094
7094
  var e = this, t = e._self._c;
7095
7095
  return t("div", { staticClass: "font-inter root" }, [t("div", { staticClass: "container" }, [t("div", { staticClass: "icon-wrapper" }, [t("BaseIcon", { attrs: { size: 20, type: "email" } })], 1), t("div", { staticClass: "title", domProps: { textContent: e._s(e.$t("title")) } }), t("div", { staticClass: "divider" }), t("CButton", { staticClass: "close-button", attrs: { type: "secondary" }, on: { click: e.close } }, [e._v(" " + e._s(e.$t("_common:close")) + " ")])], 1)]);
7096
- }, Ji = [], Xi = /* @__PURE__ */ d(
7096
+ }, Qi = [], Ji = /* @__PURE__ */ d(
7097
+ Ki,
7097
7098
  Yi,
7098
7099
  Qi,
7099
- Ji,
7100
7100
  !1,
7101
7101
  null,
7102
7102
  "673cd86f",
7103
7103
  null,
7104
7104
  null
7105
7105
  );
7106
- const ea = Xi.exports;
7107
- A.use(qe);
7108
- const ta = {
7106
+ const Xi = Ji.exports;
7107
+ A.use(We);
7108
+ const ea = {
7109
7109
  name: "DocForm",
7110
- mixins: [
7111
- De([
7112
- "closeFunc",
7113
- "beforeSave",
7114
- "beforeSend",
7115
- "setFormValue",
7116
- "removeFormValue",
7117
- "galleryCategory"
7118
- ])
7119
- ],
7120
7110
  i18nOptions: {
7121
7111
  namespaces: "widgetDocForm",
7122
7112
  messages: {
@@ -7129,20 +7119,39 @@ const ta = {
7129
7119
  }
7130
7120
  },
7131
7121
  components: {
7132
- TemplateSelector: At,
7133
- DocumentForm: Ki,
7134
- PostSend: ea
7122
+ TemplateSelector: Ht,
7123
+ DocumentForm: ji,
7124
+ PostSend: Xi
7135
7125
  },
7136
7126
  props: {
7137
- isNew: {
7127
+ setFormValue: {
7128
+ type: Function,
7129
+ default: null
7130
+ },
7131
+ removeFormValue: {
7132
+ type: Function,
7133
+ default: null
7134
+ },
7135
+ closeFunc: {
7136
+ type: Function,
7137
+ default: null
7138
+ },
7139
+ beforeSave: {
7140
+ type: Function,
7141
+ default: null
7142
+ },
7143
+ beforeSend: {
7144
+ type: Function,
7145
+ default: null
7146
+ },
7147
+ galleryCategory: {
7148
+ type: String,
7149
+ default: null
7150
+ },
7151
+ showBackButton: {
7138
7152
  type: Boolean,
7139
- default: !1
7153
+ default: !0
7140
7154
  }
7141
- // TODO
7142
- // sendProps: {
7143
- // type: Object,
7144
- // default: () => ({})
7145
- // }
7146
7155
  },
7147
7156
  data() {
7148
7157
  return {
@@ -7152,7 +7161,7 @@ const ta = {
7152
7161
  };
7153
7162
  },
7154
7163
  computed: {
7155
- ...Ve({
7164
+ ...De({
7156
7165
  company: "application/company",
7157
7166
  feature: "application/feature",
7158
7167
  can: "application/can",
@@ -7181,7 +7190,7 @@ const ta = {
7181
7190
  (!this.rawDoc || (i = this.rawDoc) != null && i.__isNew) && (this.view = "templateSelect");
7182
7191
  },
7183
7192
  methods: {
7184
- ...Be({
7193
+ ...Ve({
7185
7194
  removeFormKeyValue: m.REMOVE_FORM_KEY_VALUE,
7186
7195
  loadDocumentForm: m.LOAD_DOCUMENT2_FORM,
7187
7196
  duplicateDocumentForm: m.LOAD_DUPLICATE_DOCUMENT2_FORM,
@@ -7199,8 +7208,8 @@ const ta = {
7199
7208
  });
7200
7209
  },
7201
7210
  async onTemplateSelect({ templateId: i, documentId: e, formData: t }) {
7202
- var s;
7203
- const a = Me({ ...this.rawDoc }, [
7211
+ var n;
7212
+ const a = Be({ ...this.rawDoc }, [
7204
7213
  "__tempId",
7205
7214
  "externalReferences",
7206
7215
  "subscriberCompanyUserIds",
@@ -7212,9 +7221,9 @@ const ta = {
7212
7221
  _formData: a
7213
7222
  }) : await this.loadDocumentForm({
7214
7223
  templateId: i,
7215
- formData: t ? Ie(t, a) : null,
7224
+ formData: t ? Me(t, a) : null,
7216
7225
  _formData: a
7217
- }), (s = a == null ? void 0 : a.data) != null && s.name && this.setDocValue({ key: "data.name", value: a.data.name }), await this.initDoc(), this.view = "editor";
7226
+ }), (n = a == null ? void 0 : a.data) != null && n.name && this.setDocValue({ key: "data.name", value: a.data.name }), await this.initDoc(), this.view = "editor";
7218
7227
  },
7219
7228
  setDocValue({ key: i, value: e }) {
7220
7229
  return this.setFormValue({ key: i, value: e });
@@ -7226,6 +7235,7 @@ const ta = {
7226
7235
  return this.removeFormKeyValue(`document2.${i}`);
7227
7236
  },
7228
7237
  async onSaveDocument({ doSend: i = !1 } = {}) {
7238
+ var s;
7229
7239
  let e;
7230
7240
  if (typeof this.beforeSave == "function" && (e = await this.beforeSave(this.document)), i && typeof this.beforeSend == "function" && (e = await this.beforeSend(this.document)), e)
7231
7241
  return;
@@ -7233,40 +7243,32 @@ const ta = {
7233
7243
  if (!t)
7234
7244
  return;
7235
7245
  const a = this.docById(t);
7236
- let s;
7237
- i && (s = !!(a != null && a.senderClient) || this.isManualDelivery(a)), s ? (this.document = a, this.view = "postSend") : this.close();
7238
- },
7239
- close() {
7240
- if (this.closeFunc)
7241
- this.closeFunc();
7242
- else
7243
- throw new Error(
7244
- "[DocForm] closeFunc is missing from route params. Make sure to set it from ui"
7245
- );
7246
+ let n;
7247
+ i && (n = !!(a != null && a.senderClient) || this.isManualDelivery(a)), n ? (this.document = a, this.view = "postSend") : (s = this.closeFunc) == null || s.call(this);
7246
7248
  },
7247
7249
  goBack() {
7248
7250
  this.view = "templateSelect", this.setDocValue({ key: "__isNew", value: !0 });
7249
7251
  },
7250
7252
  isManualDelivery(i) {
7251
- const e = I(i);
7253
+ const e = F(i);
7252
7254
  return !e.sms && !e.email;
7253
7255
  }
7254
7256
  }
7255
7257
  };
7256
- var ia = function() {
7258
+ var ta = function() {
7257
7259
  var e = this, t = e._self._c;
7258
- return t("div", { staticClass: "flex flex-col w-full h-full" }, [e.view === "templateSelect" ? t("div", { staticClass: "flex flex-col w-full h-full" }, [t("div", { staticClass: "relative flex items-center justify-center h-16 border-b border-gray-200" }, [t("CButton", { staticClass: "absolute -translate-y-1/2 top-1/2 left-4", attrs: { icon: "x", circle: "" }, on: { click: e.close } }), t("div", [e._v(e._s(e.$t("selectNavTitle")))])], 1), t("TemplateSelector", { staticClass: "min-h-0 body-scroll", attrs: { "on-use-template": e.onTemplateSelect, "show-gallery": e.feature("templateGallery"), "show-gallery-template-author": !1, "gallery-category": e.galleryCategory, "include-partner-templates": "" } })], 1) : e.view === "editor" ? t("DocumentForm", { attrs: { document: e.document, "set-doc-value": e.setDocValue, "set-form-value": e.setFormValue, "remove-doc-value": e.removeDocValue, "remove-doc-key-value": e.removeDocKeyValue, "on-save-document": e.onSaveDocument, "is-loading": e.isPosting, close: e.close, "go-back": e.document.id ? null : e.goBack, "can-show-banner": !1 } }) : t("PostSend", { attrs: { document: e.document, "on-send-func": e.close, "on-close-func": e.close } })], 1);
7259
- }, aa = [], sa = /* @__PURE__ */ d(
7260
+ return t("div", { staticClass: "flex flex-col w-full h-full" }, [e.view === "templateSelect" ? t("div", { staticClass: "flex flex-col w-full h-full" }, [t("div", { staticClass: "relative flex items-center justify-center h-16 border-b border-gray-200" }, [e.closeFunc ? t("CButton", { staticClass: "absolute -translate-y-1/2 top-1/2 left-4", attrs: { icon: "x", circle: "" }, on: { click: e.closeFunc } }) : e._e(), t("div", [e._v(e._s(e.$t("selectNavTitle")))])], 1), t("TemplateSelector", { staticClass: "min-h-0 body-scroll", attrs: { "on-use-template": e.onTemplateSelect, "show-gallery": e.feature("templateGallery"), "show-gallery-template-author": !1, "gallery-category": e.galleryCategory, "include-partner-templates": "" } })], 1) : e.view === "editor" ? t("DocumentForm", { attrs: { document: e.document, "set-doc-value": e.setDocValue, "set-form-value": e.setFormValue, "remove-doc-value": e.removeDocValue, "remove-doc-key-value": e.removeDocKeyValue, "on-save-document": e.onSaveDocument, "is-loading": e.isPosting, close: e.closeFunc, "go-back": !e.document.id && e.showBackButton ? e.goBack : null, "can-show-banner": !1 } }) : t("PostSend", { attrs: { document: e.document, "on-send-func": e.closeFunc, "on-close-func": e.closeFunc } })], 1);
7261
+ }, ia = [], aa = /* @__PURE__ */ d(
7262
+ ea,
7260
7263
  ta,
7261
7264
  ia,
7262
- aa,
7263
7265
  !1,
7264
7266
  null,
7265
7267
  null,
7266
7268
  null,
7267
7269
  null
7268
7270
  );
7269
- const za = sa.exports;
7271
+ const Pa = aa.exports;
7270
7272
  export {
7271
- za as default
7273
+ Pa as default
7272
7274
  };