@cling-se/widget 0.13.0 → 0.13.2

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 (136) hide show
  1. package/README.md +27 -22
  2. package/dist/{AddClientCallout-92b43564.js → AddClientCallout-7LpWNu29.js} +11 -16
  3. package/dist/{AnswerModal-b22aab96.js → AnswerModal-DnTU4eo8.js} +1931 -1948
  4. package/dist/{AttachmentItem-39196508.js → AttachmentItem-DcwbrFUh.js} +15 -18
  5. package/dist/{BaseDatePicker-8be0c5ee.js → BaseDatePicker-BpyeJH3N.js} +139 -142
  6. package/dist/{BaseInput-779cb5b2.js → BaseInput-DJreiE5M.js} +77 -56
  7. package/dist/{BaseUpload-941ca869.js → BaseUpload-iosxX2-N.js} +208 -212
  8. package/dist/{BlockMedia-bf89f8a9.js → BlockMedia-DnbdVEZz.js} +6 -8
  9. package/dist/{CCallout-4239825f.js → CCallout-CgviPbdr.js} +26 -16
  10. package/dist/{CDropdownItem-d0cd42d6.js → CDropdownItem-CTJ55d4m.js} +51 -50
  11. package/dist/{CField-9b72b886.js → CField-FGP7ehRq.js} +75 -58
  12. package/dist/{CPhoneFormat-34b4c650.js → CPhoneFormat-8u5dmTPd.js} +5 -7
  13. package/dist/{CSlider.vue_vue_type_style_index_0_lang-c1638d8a.js → CTabs.vue_vue_type_style_index_0_scoped_e02a6440_lang-Dc_pbPEA.js} +6 -8
  14. package/dist/{ClientAutocomplete-0d21002e.js → ClientAutocomplete-hcl0bJxO.js} +11 -13
  15. package/dist/{ClientModal-9b8173e2.js → ClientModal-B8PkUqY2.js} +25 -32
  16. package/dist/{ColorPicker-3d06f308.js → ColorPicker-6AIHrfJ5.js} +5 -7
  17. package/dist/{CompanyModal-2e203a3a.js → CompanyModal-H4hHfy7Y.js} +28 -30
  18. package/dist/{ContentWrapper-71bc374a.js → ContentWrapper-CHZtfhFI.js} +25 -43
  19. package/dist/{CoverBlockSettings-b6c200ee.js → CoverBlockSettings-etwL5N5l.js} +20 -31
  20. package/dist/{DocAnswer-d4ea9b74.js → DocAnswer-Udn1ItYd.js} +5 -12
  21. package/dist/{DocDetails-ea2635ac.js → DocDetails-BQz-is7P.js} +47 -59
  22. package/dist/{DocForm-cff1c78e.js → DocForm-Cvuxr89v.js} +4869 -4944
  23. package/dist/{DocFormSend-d0979323.js → DocFormSend-Bo6YPSMr.js} +15 -33
  24. package/dist/DocLinks-DlWyanFQ.js +38 -0
  25. package/dist/{DocModalBase-77df9b3d.js → DocModalBase-BnuOPozg.js} +8 -10
  26. package/dist/{DocPrint-d39100c7.js → DocPrint-Uw8zz2tr.js} +6 -10
  27. package/dist/{DocReceipt-cf0e772b.js → DocReceipt-DsRzRjD8.js} +11 -15
  28. package/dist/{DocSendReminder-dca2775e.js → DocSendReminder-BEEEh-L9.js} +2 -6
  29. package/dist/{DocTextEditor-5676c56f.js → DocTextEditor-C-qeLSQa.js} +2509 -2529
  30. package/dist/{DocTimeline-5911b608.js → DocTimeline-Bz29bHJu.js} +26 -37
  31. package/dist/{DocumentClient-eca72dd7.js → DocumentClient-1O7wxh-X.js} +15 -22
  32. package/dist/{DocumentLayout-8104d93d.js → DocumentLayout-BrN5peVY.js} +4510 -4527
  33. package/dist/{DocumentLogotype-c43c4bbb.js → DocumentLogotype-Bbas4MsY.js} +20 -22
  34. package/dist/DocumentVoided-Dy-pp_ng.js +25 -0
  35. package/dist/{EmbedInput-02971bf6.js → EmbedInput-bXXwMP4u.js} +9 -12
  36. package/dist/{EmbedSettings-575fae0e.js → EmbedSettings-BA2THNrd.js} +6 -9
  37. package/dist/ErrorCallout-Dvy9895L.js +28 -0
  38. package/dist/{FilePreviewModal-c1d2d5e7.js → FilePreviewModal-r84Ah3lE.js} +8 -14
  39. package/dist/{Flag-1aceeff5.js → Flag-CDN9A_59.js} +18 -20
  40. package/dist/{HeaderSettings-993f8c98.js → HeaderSettings-DoDFhLcR.js} +34 -49
  41. package/dist/{ImageSelectModal-5dfe4a29.js → ImageSelectModal-D6ifkvIw.js} +12 -20
  42. package/dist/{ImageUploadWrapper-1e38bbe2.js → ImageUploadWrapper-K0-MmL-L.js} +356 -384
  43. package/dist/{Index-a7779d2a.js → Index-3p6X7Ln-.js} +24 -26
  44. package/dist/{Index-57800d9c.js → Index-B26J4tXQ.js} +7 -9
  45. package/dist/{Index-7cbe4a17.js → Index-B6gB5CD3.js} +6 -8
  46. package/dist/{Index-ec8820ee.js → Index-B6u3OUGH.js} +20 -23
  47. package/dist/{Index-bc0d3abe.js → Index-BN64idjX.js} +18 -31
  48. package/dist/{Index-50b0a9b8.js → Index-BNGaREiU.js} +14 -21
  49. package/dist/{Index-fa4f462a.js → Index-BNeg0lcx.js} +13 -15
  50. package/dist/{Index-4350bb0f.js → Index-BQVjSt_5.js} +29 -29
  51. package/dist/Index-BVNgUe07.js +21 -0
  52. package/dist/{Index-be8b14a8.js → Index-Be-J2RvQ.js} +8 -11
  53. package/dist/{Index-33635702.js → Index-Btlub0dK.js} +11 -13
  54. package/dist/{Index-46b2296e.js → Index-BtzGGZEN.js} +459 -510
  55. package/dist/{Index-c6a8a298.js → Index-ByCpvqCC.js} +16 -21
  56. package/dist/{Index-8a956c1b.js → Index-CSg7HLqX.js} +8 -10
  57. package/dist/{Index-08737451.js → Index-CUZJomAi.js} +10 -12
  58. package/dist/{Index-9a0233b0.js → Index-Cj_3udAp.js} +12 -21
  59. package/dist/{Index-13e229bb.js → Index-CnOdi4ux.js} +4 -6
  60. package/dist/{Index-c1c7db19.js → Index-DT9AWIQ2.js} +12 -15
  61. package/dist/Index-DWHl_jys.js +24 -0
  62. package/dist/{Index-cfc393ae.js → Index-Di3ibm8r.js} +51 -58
  63. package/dist/Index-Dk-kPbWy.js +52 -0
  64. package/dist/Index-Dl87oWQa.js +49 -0
  65. package/dist/{Index-c4296623.js → Index-DnDY3FUU.js} +9 -11
  66. package/dist/{Index-45c7841a.js → Index-DoKh3I_O.js} +19 -26
  67. package/dist/{Index-2c960d57.js → Index-DvA5sZ1U.js} +7 -9
  68. package/dist/{Index-670097a7.js → Index-DwlzPadK.js} +233 -273
  69. package/dist/{Index-e9f705f3.js → Index-ID37TIgR.js} +2 -4
  70. package/dist/Index-TPRXPN4a.js +26 -0
  71. package/dist/{Index-9b7b4516.js → Index-YdyeCcFX.js} +80 -90
  72. package/dist/{Index-a1097b66.js → Index-b0dDsObZ.js} +5 -9
  73. package/dist/{Index-677b2c85.js → Index-bIYFzizT.js} +4 -6
  74. package/dist/{Index-04f332ec.js → Index-d5iMi4y5.js} +116 -118
  75. package/dist/{Index-2504f599.js → Index-oYQ9EfP9.js} +16 -18
  76. package/dist/{Index-cfa81e3f.js → Index-phsroK51.js} +6 -8
  77. package/dist/{InputToggleRow-a0dc7e03.js → InputToggleRow-ClHkgn7s.js} +3 -5
  78. package/dist/{ManualPopover-6cf3f592.js → ManualPopover-DrhgZvGC.js} +1 -3
  79. package/dist/{MediaWrapper-2c2e3d44.js → MediaWrapper-BxNEJOT7.js} +3 -6
  80. package/dist/{NotBindingText-12f78064.js → NotBindingText-BhKMdYBN.js} +5 -7
  81. package/dist/{PackageGroup-75a1ad26.js → PackageGroup--pDNkIMj.js} +35 -59
  82. package/dist/{PdfTerms-5686a37b.js → PdfTerms-BL34ex7f.js} +11 -18
  83. package/dist/{PdfViewer-d1d05125.js → PdfViewer-CPSINxc8.js} +25 -29
  84. package/dist/{PlainHtml-6cc2bace.js → PlainHtml-Dc76U4EV.js} +5 -7
  85. package/dist/{PriceHeader-e45b65bc.js → PriceHeader-CEGF-DO3.js} +113 -130
  86. package/dist/SearchApi-D4yY2KZj.js +161 -0
  87. package/dist/{Setup-bf823254.js → Setup-BJIY_mWN.js} +9 -11
  88. package/dist/{TermsSettings-7a077b22.js → TermsSettings-DM4pvL-n.js} +6 -12
  89. package/dist/{ThemeColorRow-aad0248e.js → ThemeColorRow-D7TCU3ap.js} +8 -10
  90. package/dist/{ToggleBinding-abd0832e.js → ToggleBinding-CSgFUF6o.js} +7 -9
  91. package/dist/{UploadModal-42302f2b.js → UploadModal-Cz7o7DeT.js} +16 -19
  92. package/dist/{VideoPlayerInput-1c6cbf06.js → VideoPlayerInput-Db0RRtb5.js} +6 -8
  93. package/dist/{VideoPlayerSettings-5ec723e1.js → VideoPlayerSettings-BgbNuWbP.js} +7 -11
  94. package/dist/{VideoSelectModal-16acfd43.js → VideoSelectModal-BIKeCzUZ.js} +20 -28
  95. package/dist/{answerDocumentMixin-97b33f14.js → answerDocumentMixin-Bqg9Of1S.js} +5 -5
  96. package/dist/{debounce-b0ffdee0.js → debounce-DceKdgy2.js} +3 -3
  97. package/dist/{dom-962579a6.js → dom-CPYqHOIw.js} +2 -2
  98. package/dist/{focusDrawerMixin-1d99a268.js → focusDrawerMixin-Cx41U1xU.js} +1 -1
  99. package/dist/{formComponentsInstall-6ccace37.js → formComponentsInstall-CWgaR4yB.js} +1198 -1171
  100. package/dist/{formDrawerState-a7b5832a.js → formDrawerState-DLCSwrgc.js} +1 -1
  101. package/dist/{formValidationMixin-7216cb94.js → formValidationMixin-CsLym0iM.js} +2 -2
  102. package/dist/{index-7690fb79.js → index-0kj8-T7-.js} +39 -44
  103. package/dist/{index-6caf947c.js → index-4MqvoLi4.js} +3 -5
  104. package/dist/{index-93d3e2cb.js → index-By9c7IPL.js} +41 -59
  105. package/dist/{index-d73fd8ca.js → index-C16hoSRM.js} +5 -3
  106. package/dist/{index-ef3da59c.js → index-C6C4uskP.js} +14 -16
  107. package/dist/{IsPremiumPreStep-42eeebac.js → index-Cp7dG8Zm.js} +531 -566
  108. package/dist/index.es.js +3 -3
  109. package/dist/index.umd.js +1019 -1028
  110. package/dist/{main-2c8b76b7.js → main-DBw231uy.js} +21733 -21943
  111. package/dist/{mapFormMixin-c2bc089c.js → mapFormMixin-BrtcYsT9.js} +1 -2
  112. package/dist/{vuedraggable.umd-e89c3d5e.js → omit-DQqb9hkZ.js} +143 -133
  113. package/dist/{publicSenderState-e6458640.js → publicSenderState-BysO0Mzz.js} +1 -1
  114. package/dist/{splitpanes-ba7897bf.js → splitpanes-BHUVsCZF.js} +38 -42
  115. package/dist/style.css +2 -2
  116. package/dist/{throttle-4f3f879a.js → throttle-DKrISvLg.js} +2 -2
  117. package/dist/{tinycolor-f780e5ca.js → tinycolor-Be3bF6zy.js} +6 -6
  118. package/dist/{tippy.esm-a855665a.js → tippy.esm-yjYH8SnL.js} +226 -232
  119. package/dist/{utils-4d39389a.js → utils-DP30AdJH.js} +1 -1
  120. package/package.json +3 -4
  121. package/dist/DocLinks-48aa6dd6.js +0 -41
  122. package/dist/DocumentVoided-2d93ef71.js +0 -27
  123. package/dist/ErrorCallout-05a4796b.js +0 -30
  124. package/dist/Index-1cb59290.js +0 -23
  125. package/dist/Index-2a88c858.js +0 -54
  126. package/dist/Index-5fb421de.js +0 -26
  127. package/dist/Index-6f6fc018.js +0 -28
  128. package/dist/Index-98c7217d.js +0 -61
  129. package/dist/SearchApi-410c081e.js +0 -167
  130. package/dist/index-805c56e4.js +0 -4
  131. package/dist/index-a1d51619.js +0 -14
  132. /package/dist/{CField.vue_vue_type_style_index_0_lang-4ed993c7.js → CField.vue_vue_type_style_index_0_lang-l0sNRNKZ.js} +0 -0
  133. /package/dist/{anime.es-e284c852.js → anime.es-BrPTThYb.js} +0 -0
  134. /package/dist/{color-c1606adc.js → color-TdtKxwVa.js} +0 -0
  135. /package/dist/{i18nMessages-6b279c15.js → i18nMessages-Chz_lxGG.js} +0 -0
  136. /package/dist/{vuex.esm-4a0fff7c.js → vuex.esm-DKGl8mcw.js} +0 -0
@@ -1,4 +1,4 @@
1
- import { o as d, c as m } from "./main-2c8b76b7.js";
1
+ import { o as d, c as m } from "./main-DBw231uy.js";
2
2
  const s = {
3
3
  youtube: {
4
4
  reg: /^(?:https?:\/\/)?(?:(?:www|m)\.)?(?:youtu\.be\/|youtube\.com\/(?:embed\/|v\/|watch\?v=|watch\?.+&v=))((?:\w|-){11})(?:\S+)?$/,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cling-se/widget",
3
- "version": "0.13.0",
3
+ "version": "0.13.2",
4
4
  "type": "module",
5
5
  "main": "./dist/index.umd.js",
6
6
  "module": "./dist/index.es.js",
@@ -41,8 +41,7 @@
41
41
  "vuelidate-error-extractor": "2.4.1",
42
42
  "vuex": "3.4.0",
43
43
  "vuex-map-fields": "1.4.1",
44
- "vuex-router-sync": "5.0.0",
45
- "@cling/core": "0.0.0"
44
+ "vuex-router-sync": "5.0.0"
46
45
  },
47
46
  "devDependencies": {
48
47
  "@rushstack/eslint-patch": "^1.7.2",
@@ -60,7 +59,7 @@
60
59
  "rollup-plugin-visualizer": "^5.8.3",
61
60
  "tailwindcss": "^3.2.1",
62
61
  "terser": "^5.14.2",
63
- "vite": "^4.3.8",
62
+ "vite": "^5.2.6",
64
63
  "vite-tsconfig-paths": "^4.3.2"
65
64
  },
66
65
  "scripts": {
@@ -1,41 +0,0 @@
1
- import { C as o } from "./index-ef3da59c.js";
2
- import { n as t } from "./main-2c8b76b7.js";
3
- import "./vuex.esm-4a0fff7c.js";
4
- const s = {
5
- name: "DocLinks",
6
- components: {
7
- ClientLinks: o
8
- },
9
- props: {
10
- document: {
11
- type: Object,
12
- required: !0
13
- },
14
- closeFunc: {
15
- type: Function,
16
- default: null
17
- }
18
- },
19
- methods: {
20
- close() {
21
- this.closeFunc && this.closeFunc();
22
- }
23
- }
24
- };
25
- var l = function() {
26
- var n = this, e = n._self._c;
27
- return e("div", { staticClass: "h-full w-full overflow-auto" }, [e("ClientLinks", { attrs: { id: n.document.id }, on: { close: n.close } })], 1);
28
- }, c = [], r = /* @__PURE__ */ t(
29
- s,
30
- l,
31
- c,
32
- !1,
33
- null,
34
- null,
35
- null,
36
- null
37
- );
38
- const f = r.exports;
39
- export {
40
- f as default
41
- };
@@ -1,27 +0,0 @@
1
- import { n } from "./main-2c8b76b7.js";
2
- const s = {
3
- name: "DocumentVoided",
4
- props: {
5
- document: {
6
- type: Object,
7
- required: !0
8
- }
9
- }
10
- };
11
- var o = function() {
12
- var t = this, e = t._self._c;
13
- return e("div", { staticClass: "grid h-full place-items-center text-center" }, [e("div", { staticClass: "py-12" }, [e("BaseIcon", { staticClass: "text-primary-500 mb-2", attrs: { type: "info" } }), e("div", { staticClass: "text-lg font-medium", domProps: { textContent: t._s(t.document.$t("documentVoided.title")) } }), e("div", { staticClass: "text-gray-700", domProps: { textContent: t._s(t.document.$t("documentVoided.description")) } })], 1)]);
14
- }, r = [], c = /* @__PURE__ */ n(
15
- s,
16
- o,
17
- r,
18
- !1,
19
- null,
20
- null,
21
- null,
22
- null
23
- );
24
- const d = c.exports;
25
- export {
26
- d as D
27
- };
@@ -1,30 +0,0 @@
1
- import { n as r } from "./main-2c8b76b7.js";
2
- const a = {
3
- name: "ErrorCallout",
4
- props: {
5
- message: {
6
- type: String,
7
- required: !0
8
- },
9
- size: {
10
- type: String,
11
- default: "normal"
12
- }
13
- }
14
- };
15
- var s = function(e, t) {
16
- return e("div", { staticClass: "flex items-center", class: [t.data.staticClass], staticStyle: { "margin-top": "calc(1 * var(--rem))" }, style: [t.data.staticStyle] }, [e("div", { staticClass: "error-wrapper bg-red-50 text-red-500", class: [`is-${t.props.size}`], staticStyle: { margin: "calc(1 * var(--rem)) 0" } }, [e("BaseIcon", { staticStyle: { "margin-right": "0.5em", flex: "0 0 18px" }, attrs: { type: "alert", size: "18" } }), e("div", [t._v(" " + t._s(t.props.message) + " ")])], 1)]);
17
- }, l = [], n = /* @__PURE__ */ r(
18
- a,
19
- s,
20
- l,
21
- !0,
22
- null,
23
- "92251ac9",
24
- null,
25
- null
26
- );
27
- const c = n.exports;
28
- export {
29
- c as E
30
- };
@@ -1,23 +0,0 @@
1
- import { P as s } from "./PlainHtml-6cc2bace.js";
2
- import { n as e } from "./main-2c8b76b7.js";
3
- const l = {
4
- name: "WorkAddressTextRead",
5
- functional: !0,
6
- render(n, r) {
7
- return n(s, [r.props.street ? `${r.props.street}, ` : "", r.props.zip ? `${r.props.zip} ` : " ", r.props.city]);
8
- }
9
- }, o = null, p = null;
10
- var t = /* @__PURE__ */ e(
11
- l,
12
- o,
13
- p,
14
- !1,
15
- null,
16
- null,
17
- null,
18
- null
19
- );
20
- const m = t.exports;
21
- export {
22
- m as default
23
- };
@@ -1,54 +0,0 @@
1
- import { m as l } from "./mapFormMixin-c2bc089c.js";
2
- import { s as r, n as o } from "./main-2c8b76b7.js";
3
- const c = {
4
- name: "DocChapter",
5
- components: {
6
- CInput: r
7
- },
8
- mixins: [l(["title"])],
9
- props: {
10
- enableSpacingX: {
11
- type: Boolean,
12
- default: !0
13
- },
14
- enableSpacingY: {
15
- type: Boolean,
16
- default: !0
17
- }
18
- },
19
- methods: {
20
- // Naming convention used by generateTemplate-functions in order for it to choose whether or not to run on add
21
- conditionalOnAdd() {
22
- const a = () => this.$refs.input.focus();
23
- this.$refs.input ? a() : this.$once("triggerOnAdd", a);
24
- }
25
- }
26
- };
27
- var p = function() {
28
- var i;
29
- var e = this, n = e._self._c;
30
- return n("div", { staticClass: "chapter" }, [n("div", { staticClass: "no-drag", class: {
31
- "chapter-spacing-x": e.enableSpacingX,
32
- "chapter-spacing-y": e.enableSpacingY
33
- } }, [e.canEdit && ((i = e._value) != null && i.title) ? n("CInput", { ref: "input", staticClass: "title preview-title-input", attrs: { value: e.title, spellcheck: !1, placeholder: e.$t("components:account.documentForm.titleAndText.title"), static: "" }, on: { blur: (t) => {
34
- var s;
35
- e.title = ((s = t.target) == null ? void 0 : s.value) || "";
36
- }, "hook:mounted": function(t) {
37
- return e.$emit("triggerOnAdd");
38
- } }, nativeOn: { keydown: function(t) {
39
- return !t.type.indexOf("key") && e._k(t.keyCode, "enter", 13, t.key, "Enter") ? null : t.target.blur();
40
- } } }) : e.title ? n("div", { staticClass: "title" }, [e._v(" " + e._s(e.title) + " ")]) : e._e(), n("div", [e._t("default")], 2)], 1)]);
41
- }, d = [], u = /* @__PURE__ */ o(
42
- c,
43
- p,
44
- d,
45
- !1,
46
- null,
47
- "a4874efe",
48
- null,
49
- null
50
- );
51
- const m = u.exports;
52
- export {
53
- m as default
54
- };
@@ -1,26 +0,0 @@
1
- import { m as n } from "./mapFormMixin-c2bc089c.js";
2
- import { n as r } from "./main-2c8b76b7.js";
3
- const s = {
4
- name: "WorkAddressText",
5
- components: {
6
- Read: () => import("./Index-1cb59290.js")
7
- },
8
- mixins: [n(["street", "city", "zip"])]
9
- };
10
- var _ = function() {
11
- var e = this, t = e._self._c;
12
- return t("Read", { attrs: { street: e.street, city: e.city, zip: e.zip } });
13
- }, o = [], a = /* @__PURE__ */ r(
14
- s,
15
- _,
16
- o,
17
- !1,
18
- null,
19
- "e9a4224e",
20
- null,
21
- null
22
- );
23
- const p = a.exports;
24
- export {
25
- p as default
26
- };
@@ -1,28 +0,0 @@
1
- import { m as _ } from "./mapFormMixin-c2bc089c.js";
2
- import { n as o } from "./main-2c8b76b7.js";
3
- const a = {
4
- name: "NotBinding",
5
- components: {
6
- Edit: () => import("./ToggleBinding-abd0832e.js"),
7
- Read: () => import("./NotBindingText-12f78064.js")
8
- },
9
- mixins: [_()]
10
- };
11
- var i = function() {
12
- var e;
13
- var n = this, t = n._self._c;
14
- return n.canEdit ? t("Edit", n._g({ attrs: { _document: n._document, _value: { notBinding: "data.notBinding" } } }, n.$listeners)) : (e = n._document.data) != null && e.notBinding ? t("Read") : n._e();
15
- }, r = [], d = /* @__PURE__ */ o(
16
- a,
17
- i,
18
- r,
19
- !1,
20
- null,
21
- "a3b56101",
22
- null,
23
- null
24
- );
25
- const l = d.exports;
26
- export {
27
- l as default
28
- };
@@ -1,61 +0,0 @@
1
- import { m as s } from "./mapFormMixin-c2bc089c.js";
2
- import { x as i, y as r, z as m, n as a } from "./main-2c8b76b7.js";
3
- import { T as c } from "./DocTextEditor-5676c56f.js";
4
- import "./tippy.esm-a855665a.js";
5
- import "./ColorPicker-3d06f308.js";
6
- import "./DocumentLayout-8104d93d.js";
7
- import "./debounce-b0ffdee0.js";
8
- import "./CDropdownItem-d0cd42d6.js";
9
- import "./CSlider.vue_vue_type_style_index_0_lang-c1638d8a.js";
10
- import "./dom-962579a6.js";
11
- import "./CField.vue_vue_type_style_index_0_lang-4ed993c7.js";
12
- import "./ManualPopover-6cf3f592.js";
13
- import "./color-c1606adc.js";
14
- const d = {
15
- name: "textContent",
16
- components: {
17
- TextEditor: c
18
- },
19
- mixins: [s(["content"])],
20
- computed: {
21
- value: {
22
- get() {
23
- return this.canEdit ? i(
24
- this.content,
25
- this._document.textTemplateMap,
26
- this._document._doc
27
- ) : r(this.content, this._document._doc);
28
- },
29
- set(e) {
30
- this.content = m(e);
31
- }
32
- }
33
- },
34
- methods: {
35
- onAdd() {
36
- const e = () => this.$refs.textEditor.focus();
37
- this.$refs.textEditor ? e() : this.$once("triggerOnAdd", e);
38
- }
39
- }
40
- };
41
- var l = function() {
42
- var t = this, o = t._self._c;
43
- return o("div", { staticClass: "quill-format", staticStyle: { "font-size": "16px" } }, [o("TextEditor", { ref: "textEditor", staticClass: "text-editor", staticStyle: { "margin-bottom": "1em" }, attrs: { placeholder: t.$t("components:account.documentForm.titleAndText.text"), mentions: () => t._document.textTemplateItems, snippets: !0, "is-absolute": !0 }, on: { "hook:mounted": function(n) {
44
- return t.$emit("triggerOnAdd");
45
- } }, model: { value: t.value, callback: function(n) {
46
- t.value = n;
47
- }, expression: "value" } })], 1);
48
- }, p = [], u = /* @__PURE__ */ a(
49
- d,
50
- l,
51
- p,
52
- !1,
53
- null,
54
- "75de99db",
55
- null,
56
- null
57
- );
58
- const S = u.exports;
59
- export {
60
- S as default
61
- };
@@ -1,167 +0,0 @@
1
- import { g as u, p as h, f, i as d, n as m } from "./main-2c8b76b7.js";
2
- import { d as p } from "./debounce-b0ffdee0.js";
3
- import { m as y, a as g } from "./vuex.esm-4a0fff7c.js";
4
- const A = {
5
- name: "SearchApi",
6
- props: {
7
- customSearch: {
8
- type: Object,
9
- default: () => ({})
10
- }
11
- },
12
- data() {
13
- return {
14
- defaultSearch: {
15
- project: !0,
16
- user: !0,
17
- endCustomer: !1,
18
- article: !1,
19
- extensionArticle: !1,
20
- // Articles in any authenticated CRM
21
- document: !1
22
- },
23
- hasLoadedUsers: !1,
24
- isLoading: !1,
25
- emptyQuery: null,
26
- // String to track last query that was empty, if a new query starts with this string we do not have to search again
27
- hasSearchedAll: !1
28
- // Helper to keep track when some search types have not yet searched due min query length
29
- };
30
- },
31
- computed: {
32
- ...y({
33
- allUsers: "companyUsers/all",
34
- allAuthenticatedCRMs: "settings/allAuthenticatedCRMs",
35
- can: "application/can"
36
- }),
37
- typesToFetch() {
38
- return Object.keys(this.customSearch).length ? Object.keys(this.customSearch).filter(
39
- (e) => this.customSearch[e]
40
- ) : Object.keys(this.defaultSearch).filter(
41
- (e) => this.defaultSearch[e]
42
- );
43
- }
44
- },
45
- methods: {
46
- ...g({
47
- loadUsers: u.LOAD_COMPANY_USERS
48
- }),
49
- canFetchType(e) {
50
- return e === "endCustomer" ? this.can("endCustomers", "read") : e === "user" ? this.can("users", "modify") : !0;
51
- },
52
- async fetch({ query: e, start: a = null, end: r = null }) {
53
- const t = this.typesToFetch.reduce(
54
- (n, c) => ({ ...n, [c]: [] }),
55
- {}
56
- ), s = e.toLowerCase();
57
- if (this.emptyQuery && s && s.startsWith(this.emptyQuery) || (this.emptyQuery = null, this.hasSearchedAll = !0, !s))
58
- return t;
59
- try {
60
- const n = [], c = Object.keys(this.defaultSearch);
61
- (this.typesToFetch || []).forEach((l) => {
62
- c.includes(l) && n.push(
63
- (async () => {
64
- let o = [];
65
- l === "document" ? o = await this.fetchDocuments(s, a, r) : l === "user" ? o = await this.fetchUsers(s, a, r) : l === "extensionArticle" ? o = await this.fetchExtensionArticles(s, a, r) : o = await this.fetchType(l, s, a, r), t[l] = o;
66
- })()
67
- );
68
- }), await Promise.all(n);
69
- } catch (n) {
70
- throw n;
71
- } finally {
72
- this.isLoading = !1;
73
- }
74
- return Object.keys(t).every(
75
- (n) => t[n].length === 0
76
- ) && this.hasSearchedAll && (this.emptyQuery = s), t;
77
- },
78
- async fetchType(e, a, r, t) {
79
- if (!this.canFetchType(e))
80
- return [];
81
- const { data: s } = await h("search", {
82
- type: e,
83
- query: a,
84
- ...r !== null && t !== null && { start: r, end: t }
85
- });
86
- return s;
87
- },
88
- async fetchUsers(e, a, r) {
89
- if (!this.canFetchType("user"))
90
- return [];
91
- this.hasLoadedUsers || (await this.loadUsers(), this.hasLoadedUsers = !0);
92
- const s = Object.values(this.allUsers).filter((i) => !!(i.fullName && i.fullName.toLowerCase().includes(e) || i.email && i.email.toLowerCase().includes(e)));
93
- return a !== null && r !== null ? s.slice(a, r) : s;
94
- },
95
- async fetchDocuments(e, a, r) {
96
- const t = e.replace(/[-[\]{}()*+?.,\\/^$|#]/g, "\\$&"), s = {
97
- $or: [
98
- { "data.name": { $regex: t, $options: "i" } },
99
- { "docNumber.value": { $regex: t, $options: "i" } },
100
- {
101
- clients: {
102
- $elemMatch: {
103
- $or: ["name", "email", "socialNo", "orgNo"].map((c) => ({
104
- [c]: { $regex: t, $options: "i" }
105
- }))
106
- }
107
- }
108
- }
109
- ]
110
- }, { data: i } = await f("/document", {
111
- params: {
112
- lean: !0,
113
- filter: encodeURIComponent(JSON.stringify(s)),
114
- fields: "clients,data.name,projectId,docNumber,createdAt",
115
- ...a !== null && r !== null && { skip: a, limit: r - a }
116
- }
117
- }), { items: n = [] } = i || {};
118
- return n;
119
- },
120
- async fetchExtensionArticles(e, a, r) {
121
- const t = [];
122
- return await Promise.all(
123
- this.allAuthenticatedCRMs.map(async (s) => {
124
- try {
125
- if (s === "pipedrive" && e.length < 2) {
126
- this.hasSearchedAll = !1;
127
- return;
128
- }
129
- const { data: i } = await d.search(s, {
130
- query: e,
131
- type: "article"
132
- });
133
- i && Array.isArray(i) && t.push(...i);
134
- } catch {
135
- }
136
- })
137
- ), t;
138
- },
139
- // eslint-disable-next-line object-curly-newline
140
- triggerSearch: p(async function({ q: a, cb: r, start: t, end: s }) {
141
- this.isLoading = !0;
142
- const i = await this.fetch({ query: a, start: t, end: s });
143
- return this.isLoading = !1, r(i);
144
- }, 500)
145
- },
146
- render() {
147
- return this.$scopedSlots.default({
148
- // eslint-disable-next-line object-curly-newline
149
- fetch: ({ q: e, cb: a, start: r = null, end: t = null }) => (this.isLoading = !0, this.triggerSearch({ q: e, cb: a, start: r, end: t })),
150
- isLoading: this.isLoading
151
- });
152
- }
153
- }, S = null, w = null;
154
- var L = /* @__PURE__ */ m(
155
- A,
156
- S,
157
- w,
158
- !1,
159
- null,
160
- null,
161
- null,
162
- null
163
- );
164
- const $ = L.exports;
165
- export {
166
- $ as S
167
- };
@@ -1,4 +0,0 @@
1
- var a = {};
2
- export {
3
- a as v
4
- };
@@ -1,14 +0,0 @@
1
- import { C as e, P as u, a as P, I as C, s as I } from "./IsPremiumPreStep-42eeebac.js";
2
- import "./main-2c8b76b7.js";
3
- import "./vuex.esm-4a0fff7c.js";
4
- import "./anime.es-e284c852.js";
5
- import "./index-d73fd8ca.js";
6
- import "./index-805c56e4.js";
7
- import "./dom-962579a6.js";
8
- export {
9
- e as CalloutLegacy,
10
- u as Checkout,
11
- P as IsPremium,
12
- C as IsPremiumPreStep,
13
- I as stripeMixin
14
- };
File without changes