@cling-se/widget 0.9.4 → 0.9.6

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 (131) hide show
  1. package/dist/{AddClientCallout-d472aa84.js → AddClientCallout-d8f5bc53.js} +5 -5
  2. package/dist/{AnswerModal-06487437.js → AnswerModal-5f83562b.js} +248 -248
  3. package/dist/{AttachmentItem-d98488ee.js → AttachmentItem-79eb718b.js} +8 -8
  4. package/dist/{BaseDatePicker-8c098701.js → BaseDatePicker-ae7aebf1.js} +43 -43
  5. package/dist/{BaseInput-2723d613.js → BaseInput-2c476604.js} +1 -1
  6. package/dist/{BaseUpload-996d74b3.js → BaseUpload-9e15729d.js} +3 -3
  7. package/dist/{BlockMedia-00907fb6.js → BlockMedia-a3f00a2f.js} +1 -1
  8. package/dist/{CCallout-ffa95028.js → CCallout-04e2c8c6.js} +6 -6
  9. package/dist/{CDropdownItem-74672842.js → CDropdownItem-5532f8af.js} +76 -75
  10. package/dist/{CField-06dd50f1.js → CField-0bc9de28.js} +1 -1
  11. package/dist/{CSlider.vue_vue_type_style_index_0_lang-f49d85e0.js → CSlider.vue_vue_type_style_index_0_lang-d9c2f582.js} +1 -1
  12. package/dist/{ClientAutocomplete-f65643dd.js → ClientAutocomplete-e13c2753.js} +4 -4
  13. package/dist/{ClientModal-d276aabd.js → ClientModal-da9fddf9.js} +16 -16
  14. package/dist/{ColorPicker-4f6b70af.js → ColorPicker-06b731b7.js} +2 -2
  15. package/dist/{CompanyModal-30c54ce3.js → CompanyModal-b7c42f2a.js} +8 -8
  16. package/dist/{ContentWrapper-d5653fef.js → ContentWrapper-fe4a67bc.js} +19 -19
  17. package/dist/{CoverBlockSettings-2335f3a8.js → CoverBlockSettings-2024e993.js} +19 -19
  18. package/dist/DocForm-af03179d.js +7012 -0
  19. package/dist/{DocFormSend-d0c6fa1d.js → DocFormSend-44161541.js} +14 -14
  20. package/dist/{DocModalBase-f4915a62.js → DocModalBase-9eb0f26f.js} +4 -4
  21. package/dist/DocPrint-92d12950.js +222 -0
  22. package/dist/{DocReceipt-d192000e.js → DocReceipt-4df57e1d.js} +1 -1
  23. package/dist/{DocSendReminder-06d5b34c.js → DocSendReminder-041af744.js} +1 -1
  24. package/dist/{DocTextEditor-c6d1df3c.js → DocTextEditor-b07dd391.js} +19 -19
  25. package/dist/{DocTimeline-b4c20f93.js → DocTimeline-2ae2ca63.js} +7 -7
  26. package/dist/{DocumentClient-c2319f00.js → DocumentClient-3a1aecf2.js} +8 -6
  27. package/dist/{formValidationMixin-4920ab53.js → DocumentLayout-ae49ac7a.js} +1617 -1709
  28. package/dist/{DocumentLogotype-1efd1ce9.js → DocumentLogotype-91436523.js} +3 -3
  29. package/dist/{EmbedInput-654c0477.js → EmbedInput-05e22228.js} +2 -2
  30. package/dist/{EmbedSettings-b81ec734.js → EmbedSettings-9dabb6d4.js} +10 -10
  31. package/dist/ErrorCallout-c7f69cd9.js +30 -0
  32. package/dist/{FilePreviewModal-895bd1bd.js → FilePreviewModal-167a40c8.js} +8 -7
  33. package/dist/{HeaderSettings-c6dac755.js → HeaderSettings-e9b177e0.js} +29 -29
  34. package/dist/{ImageSelectModal-7cece54e.js → ImageSelectModal-8565c461.js} +11 -11
  35. package/dist/{ImageUploadWrapper-53afd31d.js → ImageUploadWrapper-1e61e8da.js} +3 -3
  36. package/dist/{Index-5cc51230.js → Index-0708b238.js} +12 -12
  37. package/dist/{Index-82574a41.js → Index-0799eaba.js} +18 -19
  38. package/dist/{Index-1a7e98d7.js → Index-1f3de208.js} +11 -10
  39. package/dist/{Index-d8879ca9.js → Index-27a05d76.js} +2 -2
  40. package/dist/{Index-b15cfd62.js → Index-43899daf.js} +13 -13
  41. package/dist/{Index-c4de05aa.js → Index-4446581c.js} +10 -9
  42. package/dist/{Index-01c63c88.js → Index-49766088.js} +2 -2
  43. package/dist/{Index-caf5cf44.js → Index-630600c9.js} +94 -94
  44. package/dist/{Index-b14d0f03.js → Index-6b63686e.js} +4 -4
  45. package/dist/{Index-34c84bab.js → Index-716dbe24.js} +10 -10
  46. package/dist/{Index-f935c492.js → Index-72bcad54.js} +10 -10
  47. package/dist/{Index-61f7dc92.js → Index-84820d3d.js} +2 -2
  48. package/dist/{Index-e749f6f1.js → Index-85e8119e.js} +14 -14
  49. package/dist/Index-88e175bf.js +54 -0
  50. package/dist/{Index-e45a0c32.js → Index-89addabd.js} +27 -27
  51. package/dist/{Index-701f0d05.js → Index-8b29bd10.js} +2 -2
  52. package/dist/{Index-d45a1eff.js → Index-8d1c62be.js} +4 -4
  53. package/dist/{Index-63805642.js → Index-96a07794.js} +9 -9
  54. package/dist/{Index-60fc8a6e.js → Index-9bbfa37b.js} +3 -3
  55. package/dist/{Index-7443e91c.js → Index-a7a6f91c.js} +31 -31
  56. package/dist/{Index-8bca2d87.js → Index-a987a099.js} +9 -9
  57. package/dist/{Index-98e8bb86.js → Index-b6b60b81.js} +8 -8
  58. package/dist/{Index-5e35f4a2.js → Index-ba0c8eaa.js} +8 -8
  59. package/dist/{Index-9aaf8b90.js → Index-c038406f.js} +26 -26
  60. package/dist/Index-c53330d6.js +79 -0
  61. package/dist/{Index-9233cc83.js → Index-c58260f8.js} +15 -15
  62. package/dist/{Index-2535f58f.js → Index-c893d091.js} +2 -2
  63. package/dist/{Index-1d361d01.js → Index-ca112d97.js} +4 -4
  64. package/dist/{Index-cd76b120.js → Index-e728d2f7.js} +7 -7
  65. package/dist/{Index-6ef78b7a.js → Index-ecf93915.js} +2 -2
  66. package/dist/{Index-c7e68382.js → Index-eda700f4.js} +4 -4
  67. package/dist/{Index-82b5de12.js → Index-ee75e74a.js} +4 -4
  68. package/dist/{Index-c67218ce.js → Index-f75b1dd5.js} +15 -15
  69. package/dist/{Index-66c8cbfa.js → Index-fc722547.js} +4 -4
  70. package/dist/{InputToggleRow-9d8a7da4.js → InputToggleRow-483acc75.js} +5 -5
  71. package/dist/{IsPremiumPreStep-3a087524.js → IsPremiumPreStep-aa08f8c8.js} +856 -432
  72. package/dist/{MediaWrapper-d4a4b66f.js → MediaWrapper-ed7db800.js} +3 -3
  73. package/dist/{NotBindingText-b199006c.js → NotBindingText-a99b4f85.js} +2 -2
  74. package/dist/{PackageGroup-37ac99b1.js → PackageGroup-8cae78f1.js} +56 -56
  75. package/dist/{PdfTerms-8b52bb6e.js → PdfTerms-9c1c806e.js} +8 -7
  76. package/dist/{PdfViewer-38bd8439.js → PdfViewer-1227dda6.js} +5 -4
  77. package/dist/{PlainHtml-9174cbf6.js → PlainHtml-647219e9.js} +1 -1
  78. package/dist/PriceHeader-cfb22169.js +337 -0
  79. package/dist/{SearchApi-2e286be6.js → SearchApi-c0067742.js} +2 -2
  80. package/dist/{TermsSettings-c74eec79.js → TermsSettings-a0282ad7.js} +11 -11
  81. package/dist/{ThemeColorRow-3558367b.js → ThemeColorRow-71af67bd.js} +3 -3
  82. package/dist/{ToggleBinding-6c9c1ac3.js → ToggleBinding-16c2879e.js} +3 -3
  83. package/dist/{UploadModal-6d0abd77.js → UploadModal-084e3c2e.js} +16 -16
  84. package/dist/{VideoPlayerInput-77cd86aa.js → VideoPlayerInput-fe87698e.js} +3 -3
  85. package/dist/{VideoPlayerSettings-b7eb781c.js → VideoPlayerSettings-06cfaccc.js} +12 -12
  86. package/dist/VideoSelectModal-fa81fb92.js +111 -0
  87. package/dist/{answerDocumentMixin-66023e62.js → answerDocumentMixin-ef48c7eb.js} +3 -3
  88. package/dist/{cssMode-8552fc56.js → cssMode-916ae2c1.js} +7 -7
  89. package/dist/dom-068d1a7b.js +59 -0
  90. package/dist/{focusDrawerMixin-67462262.js → focusDrawerMixin-24942dd1.js} +1 -1
  91. package/dist/{formComponentsInstall-ad9c2a83.js → formComponentsInstall-2dfa2def.js} +25 -25
  92. package/dist/formValidationMixin-82793652.js +49 -0
  93. package/dist/{freemarker2-7e10a65d.js → freemarker2-6fd30e77.js} +7 -7
  94. package/dist/{handlebars-8045bfa8.js → handlebars-ff07e526.js} +7 -7
  95. package/dist/{html-8afcb633.js → html-5ad143f9.js} +7 -7
  96. package/dist/{htmlMode-1a2d1b48.js → htmlMode-adc834ff.js} +7 -7
  97. package/dist/{index-3d6d7a03.js → index-045c9c73.js} +31 -31
  98. package/dist/{index-c48c5eb4.js → index-1f068e8e.js} +3 -3
  99. package/dist/{index-bf93d7c2.js → index-6eda8be0.js} +7 -7
  100. package/dist/{index-f805bfce.js → index-b3fb8f92.js} +45 -45
  101. package/dist/index.es.js +8 -8
  102. package/dist/index.umd.js +565 -561
  103. package/dist/{javascript-dad5561e.js → javascript-9c241e8d.js} +8 -8
  104. package/dist/{jsonMode-ce09245f.js → jsonMode-36a8e1fd.js} +7 -7
  105. package/dist/{liquid-05247459.js → liquid-da99d7af.js} +7 -7
  106. package/dist/{main-04025a56.js → main-2dc98356.js} +15380 -12891
  107. package/dist/{mapFormMixin-8d073f99.js → mapFormMixin-4ac649c2.js} +1 -1
  108. package/dist/{publicSenderState-97108de1.js → publicSenderState-1db8a50c.js} +1 -1
  109. package/dist/{python-3f3513c5.js → python-15d86041.js} +7 -7
  110. package/dist/{razor-1f3e9c4e.js → razor-19e0207f.js} +7 -7
  111. package/dist/simplebar.min-9f5e0b8a.js +71 -0
  112. package/dist/style.css +2 -2
  113. package/dist/{template-42a1d852.js → template-069f0890.js} +1 -1
  114. package/dist/{throttle-a2c1f34d.js → throttle-f8ef830f.js} +2 -2
  115. package/dist/{tinycolor-88fa380f.js → tinycolor-78c3e3d5.js} +1 -1
  116. package/dist/{FormInputRow-9819eb71.js → tippy.esm-d2a6f864.js} +285 -285
  117. package/dist/{tsMode-4c026047.js → tsMode-7fcdffc4.js} +7 -7
  118. package/dist/{typescript-baf56f67.js → typescript-f492bdab.js} +7 -7
  119. package/dist/{utils-6670dea6.js → utils-aab0bc31.js} +1 -1
  120. package/dist/{vuedraggable.umd-d7138234.js → vuedraggable.umd-eb01eee5.js} +41 -41
  121. package/dist/{xml-ffc6146a.js → xml-976a8723.js} +7 -7
  122. package/package.json +3 -2
  123. package/stats.html +1 -1
  124. package/vite-plugin-library-asset-external/index.js +134 -0
  125. package/dist/DocForm-9ca24de4.js +0 -6772
  126. package/dist/ErrorCallout-60d0b3ab.js +0 -30
  127. package/dist/Index-b020a80c.js +0 -47
  128. package/dist/Index-e80f5f9c.js +0 -79
  129. package/dist/PriceHeader-e357afe9.js +0 -336
  130. package/dist/VideoSelectModal-d2299552.js +0 -111
  131. package/dist/simplebar.min-3af55aab.js +0 -2429
@@ -1,30 +0,0 @@
1
- import { n as r } from "./main-04025a56.js";
2
- const s = {
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 a = function(e, t) {
16
- return e("div", { staticClass: "flex items-center", class: [t.data.staticClass], staticStyle: { "margin-top": "1rem" }, style: [t.data.staticStyle] }, [e("div", { staticClass: "error-wrapper bg-red-50 text-red-500", class: [`is-${t.props.size}`], staticStyle: { margin: "1rem 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
- }, n = [], l = /* @__PURE__ */ r(
18
- s,
19
- a,
20
- n,
21
- !0,
22
- null,
23
- "300a015f",
24
- null,
25
- null
26
- );
27
- const p = l.exports;
28
- export {
29
- p as E
30
- };
@@ -1,47 +0,0 @@
1
- import { m as l } from "./mapFormMixin-8d073f99.js";
2
- import { l as r, n as o } from "./main-04025a56.js";
3
- const c = {
4
- name: "DocChapter",
5
- components: {
6
- CInput: r
7
- },
8
- mixins: [l(["title"])],
9
- props: {
10
- enableSpacing: {
11
- type: Boolean,
12
- default: !0
13
- }
14
- },
15
- methods: {
16
- // Naming convention used by generateTemplate-functions in order for it to choose whether or not to run on add
17
- conditionalOnAdd() {
18
- const i = () => this.$refs.input.focus();
19
- this.$refs.input ? i() : this.$once("triggerOnAdd", i);
20
- }
21
- }
22
- };
23
- var d = function() {
24
- var s;
25
- var t = this, n = t._self._c;
26
- return n("div", { staticClass: "chapter" }, [n("div", { staticClass: "no-drag", class: { "chapter-spacing": t.enableSpacing } }, [t.canEdit && ((s = t._value) != null && s.title) ? n("CInput", { ref: "input", staticClass: "title preview-title-input", attrs: { value: t.title, spellcheck: !1, placeholder: t.$t("components:account.documentForm.titleAndText.title"), static: "" }, on: { blur: (e) => {
27
- var a;
28
- t.title = ((a = e.target) == null ? void 0 : a.value) || "";
29
- }, "hook:mounted": function(e) {
30
- return t.$emit("triggerOnAdd");
31
- } }, nativeOn: { keydown: function(e) {
32
- return !e.type.indexOf("key") && t._k(e.keyCode, "enter", 13, e.key, "Enter") ? null : e.target.blur();
33
- } } }) : t.title ? n("div", { staticClass: "title" }, [t._v(" " + t._s(t.title) + " ")]) : t._e(), t._t("default")], 2)]);
34
- }, u = [], p = /* @__PURE__ */ o(
35
- c,
36
- d,
37
- u,
38
- !1,
39
- null,
40
- "586591d4",
41
- null,
42
- null
43
- );
44
- const m = p.exports;
45
- export {
46
- m as default
47
- };
@@ -1,79 +0,0 @@
1
- import { n as c, o as l } from "./main-04025a56.js";
2
- const d = {
3
- name: "MultiGroupPricing",
4
- props: {
5
- _document: {
6
- type: Object,
7
- default: () => ({})
8
- }
9
- },
10
- computed: {
11
- docPriceItems() {
12
- const { total: o, subTotal: t } = this._document.prices || {};
13
- return [
14
- {
15
- label: this._document.$t("price.net"),
16
- value: this.priceFormat(t)
17
- },
18
- {
19
- label: this._document.$t("price.total"),
20
- value: this.priceFormat(o)
21
- }
22
- ];
23
- },
24
- pkgGroups() {
25
- var t;
26
- return (((t = this._document.packageGroups) == null ? void 0 : t.groups) || []).map(({ title: e, prices: r, selectedPackages: i }) => {
27
- const { total: s, subTotal: n } = r || {};
28
- return {
29
- title: e,
30
- noOfSelectedPackages: i.length,
31
- priceItems: [
32
- {
33
- label: this._document.$t("price.net"),
34
- value: this.priceFormat(n)
35
- },
36
- {
37
- label: this._document.$t("price.total"),
38
- value: this.priceFormat(s)
39
- }
40
- ]
41
- };
42
- });
43
- }
44
- },
45
- methods: {
46
- priceFormat(o, t) {
47
- return l(o, {
48
- currency: this._document.currency,
49
- showZero: !0,
50
- decimals: 2,
51
- hideZeroDecimals: !0,
52
- ...t
53
- });
54
- }
55
- }
56
- };
57
- var p = function() {
58
- var t = this, e = t._self._c;
59
- return e("div", [t._l(t.pkgGroups, function(r, i) {
60
- return e("div", { key: i, staticStyle: { padding: "0.5rem 0" } }, [e("div", { staticStyle: { display: "flex", "font-size": "1.1rem", "font-weight": "600", "padding-bottom": "3px", "border-bottom": "1px solid rgba(0, 0, 0, 0.2)" } }, [t._v(" " + t._s(r.title) + " "), e("span", { staticClass: "has-text-grey", staticStyle: { "margin-left": "auto", "font-size": "1rem" } }, [t._v(" " + t._s(r.noOfSelectedPackages) + " paket ")])]), t._l(r.priceItems, function({ label: s, value: n }, a) {
61
- return e("div", { key: s + a, staticStyle: { display: "flex", "justify-content": "space-between", "font-size": "1rem" } }, [e("div", [t._v(t._s(s))]), e("div", [t._v(t._s(n))])]);
62
- })], 2);
63
- }), e("div", { staticStyle: { "margin-top": "1rem" } }, [e("div", { staticStyle: { "font-size": "1.1rem", "font-weight": "600", "padding-bottom": "3px", "border-bottom": "1px solid rgba(0, 0, 0, 0.2)" } }, [t._v("Doc summary")]), t._l(t.docPriceItems, function({ label: r, value: i }, s) {
64
- return e("div", { key: s + r, staticStyle: { display: "flex", "justify-content": "space-between", "font-size": "1rem" } }, [e("div", [t._v(t._s(r))]), e("div", [t._v(t._s(i))])]);
65
- })], 2)], 2);
66
- }, u = [], _ = /* @__PURE__ */ c(
67
- d,
68
- p,
69
- u,
70
- !1,
71
- null,
72
- "d926efba",
73
- null,
74
- null
75
- );
76
- const f = _.exports;
77
- export {
78
- f as default
79
- };
@@ -1,336 +0,0 @@
1
- import { m as n } from "./mapFormMixin-8d073f99.js";
2
- import { B as l } from "./BlockMedia-00907fb6.js";
3
- import { n as c, b as a, o as d, W as u } from "./main-04025a56.js";
4
- import { T as m } from "./DocTextEditor-c6d1df3c.js";
5
- import { i as p } from "./i18nMessages-45c6bfd6.js";
6
- import { t as _ } from "./tinycolor-88fa380f.js";
7
- import { s as y } from "./formValidationMixin-4920ab53.js";
8
- import "./color-71c20583.js";
9
- import "./FormInputRow-9819eb71.js";
10
- import "./ColorPicker-4f6b70af.js";
11
- import "./CDropdownItem-74672842.js";
12
- import "./CSlider.vue_vue_type_style_index_0_lang-f49d85e0.js";
13
- import "./CField.vue_vue_type_style_index_0_lang-4ed993c7.js";
14
- const h = {
15
- name: "SummaryTop",
16
- i18nOptions: {
17
- namespaces: "summaryTop",
18
- messages: p
19
- },
20
- components: {
21
- TextEditor: m,
22
- DocumentLogotype: () => import("./DocumentLogotype-1efd1ce9.js")
23
- },
24
- inject: ["parentSize"],
25
- mixins: [n([])],
26
- props: {
27
- showLogo: {
28
- type: Boolean,
29
- default: !0
30
- },
31
- logotype: {
32
- type: String,
33
- default: null
34
- },
35
- companyLogotype: {
36
- type: String,
37
- default: null
38
- },
39
- senderName: {
40
- type: String,
41
- default: null
42
- },
43
- docName: {
44
- type: String,
45
- default: null
46
- },
47
- docType: {
48
- type: String,
49
- required: !0
50
- },
51
- docNumber: {
52
- type: [Number, String],
53
- default: null
54
- },
55
- sentAt: {
56
- type: [String, Number],
57
- default: null
58
- // required: true,
59
- },
60
- expiresAt: {
61
- type: String,
62
- default: null
63
- },
64
- estimatedTime: {
65
- type: String,
66
- default: null
67
- },
68
- validator: {
69
- type: Object,
70
- default: () => ({})
71
- },
72
- hasHover: {
73
- type: Boolean,
74
- default: !1
75
- }
76
- },
77
- computed: {
78
- logotypeListeners() {
79
- return {
80
- ...this.$listeners,
81
- input: (i) => this.$emit("update:logotype", i)
82
- };
83
- }
84
- }
85
- };
86
- var g = function() {
87
- var t = this, e = t._self._c;
88
- return e("section", { staticClass: "flex justify-center w-full summary-top" }, [e("div", { staticClass: "doc-summary-top-wrapper" }, [e("div", { staticClass: "doc-summary-top-wrapper__background" }), e("div", { staticClass: "flex justify-between w-full", staticStyle: { "margin-bottom": "2.5rem" } }, [t.showLogo && (t.logotype || t.companyLogotype) || t.canEdit ? e("DocumentLogotype", t._g({ attrs: { value: t.logotype, "show-logo": t.showLogo, "company-logotype": t.companyLogotype, "has-hover": t.hasHover } }, t.logotypeListeners)) : e("div", { staticClass: "company-name" }, [t._v(" " + t._s(t.senderName) + " ")]), e("div", { staticClass: "top-right-text-wrapper" }, [t.sentAt ? e("div", [t._v(t._s(t.$formatDate(t.sentAt)))]) : t._e(), t.docNumber ? e("div", [t._v(" #" + t._s(t.docNumber))]) : t._e()])], 1), e("div", { staticClass: "title-text" }, [t.canEdit ? e("TextEditor", { ref: "editor", staticClass: "no-drag", staticStyle: { "will-change": "opacity" }, attrs: { value: t.docName, placeholder: t.$t("name.placeholder"), extensions: {
89
- bulletList: !1,
90
- heading: [1, 2, 3],
91
- bold: !1,
92
- link: !1,
93
- underline: !1,
94
- blockquote: !0,
95
- table: !1
96
- }, unstyled: "", static: "" }, on: { input: function(s) {
97
- return t.$emit("update:doc-name", s);
98
- } } }) : e("div", { staticClass: "quill-custom", domProps: { innerHTML: t._s(t.docName) } })], 1), e("div", { staticClass: "flex justify-between w-full" }, [t.expiresAt ? e("div", { staticClass: "data-group" }, [e("div", { staticClass: "label-text caps" }, [t._v(t._s(t._document.$t("replyBy")))]), e("div", { staticClass: "data-text" }, [t._v(t._s(t.$formatDate(t.expiresAt)))])]) : t._e(), t.docType !== "document" ? e("div", { staticClass: "data-group" }, [e("div", { staticClass: "label-text caps" }, [t._v(t._s(t._document.$t("document").capitalize()))]), e("div", { staticClass: "data-text" }, [t._v(t._s(t._document.$t(`series.${t.docType}`).capitalize()))])]) : t._e(), t.parentSize.width >= 576 ? [t.estimatedTime ? e("div", { staticClass: "data-group" }, [e("div", { staticClass: "label-text caps" }, [t._v(t._s(t.$t("time.estimatedTime")))]), e("div", { staticClass: "data-text" }, [t._v(t._s(t._document.$t("approx")) + " " + t._s(t.estimatedTime))])]) : t._e()] : t._e()], 2)])]);
99
- }, f = [], v = /* @__PURE__ */ c(
100
- h,
101
- g,
102
- f,
103
- !1,
104
- null,
105
- "68d8a9dc",
106
- null,
107
- null
108
- );
109
- const S = v.exports;
110
- const x = {
111
- name: "SummaryBottom",
112
- mixins: [n([])],
113
- props: {
114
- base: {
115
- type: Object,
116
- default: null
117
- },
118
- options: {
119
- type: Array,
120
- default: () => []
121
- },
122
- backgroundColor: {
123
- type: String,
124
- default: "#4c576d"
125
- },
126
- documentCurrency: {
127
- type: String,
128
- required: !0
129
- },
130
- vatType: {
131
- type: String,
132
- required: !0
133
- }
134
- },
135
- inject: ["parentSize"],
136
- data() {
137
- return {
138
- get: a,
139
- tinycolor: _
140
- };
141
- },
142
- computed: {
143
- prices() {
144
- return a(this, "base.prices") || {};
145
- },
146
- isIndivid() {
147
- return a(this.prices, "helpers.isIndivid", !0);
148
- },
149
- showIncVat() {
150
- return this.isIndivid;
151
- },
152
- priceTotal() {
153
- return this.isIndivid ? a(this.prices, "total", null) : a(this.prices, "subTotal", null);
154
- },
155
- priceType() {
156
- return this.prices.type || ["fixed"];
157
- },
158
- currency() {
159
- return this.prices.currency || this.documentCurrency;
160
- },
161
- openAccMaxPrice() {
162
- return this.prices.maxTotal || null;
163
- },
164
- houseWorkType() {
165
- return a(this.prices, "region.houseWorkType", null);
166
- },
167
- isReverseVat() {
168
- return a(this.prices, "region.reverseVat", !1);
169
- },
170
- priceTypeString() {
171
- return this.priceType.includes("openAccMaxPrice") ? this._document.$t("price.openAccMaxPrice") : this.priceType.includes("openAcc") ? this._document.$t("price.openAcc") : this._document.$t("price.price").capitalize();
172
- },
173
- priceDeductionVatString() {
174
- let i = "";
175
- if (this.isReverseVat && !this.showIncVat) {
176
- const t = this.priceFormat(0, { currency: this.currency, showZero: !0 });
177
- return i = this._document.$t("summaryBottom.reverseVat", { amount: t }), i;
178
- }
179
- return this.houseWorkType && (i = this._document.$t("deduction.afterType", { type: `${this.houseWorkType}_percentage` })), this.showIncVat && (i += ` ${this._document.$t("vat.incVat", { thing: this._document.$t(`vat.${this.vatType}`) })}`), this.showIncVat || (i += ` ${this._document.$t("vat.exVat", { thing: this._document.$t(`vat.${this.vatType}`) })}`), i.capitalize();
180
- },
181
- backgroundSecondary() {
182
- if (!this.isSmallScreen)
183
- return { backgroundColor: "transparent" };
184
- const i = this.backgroundColor.match(/(\d*\.)?\d+/g)[0], t = this.backgroundColor.match(/(\d*\.)?\d+/g)[1], e = this.backgroundColor.match(/(\d*\.)?\d+/g)[2], s = this.backgroundColor.match(/(\d*\.)?\d+/g)[3];
185
- return {
186
- backgroundColor: `hsla(${i}, ${t ** 0.9}%, ${e ** 0.9}%, ${s})`
187
- };
188
- },
189
- isSmallScreen() {
190
- return this.parentSize.width <= 576;
191
- }
192
- },
193
- methods: {
194
- priceFormat: d,
195
- scrollToPricing() {
196
- const i = document.querySelector("#price");
197
- i && y(i);
198
- }
199
- }
200
- };
201
- var b = function() {
202
- var t = this, e = t._self._c;
203
- return e("section", { staticClass: "summary-bottom-root" }, [e("div", { staticClass: "summary-bottom", style: [
204
- {
205
- backgroundColor: t.backgroundColor,
206
- color: t.tinycolor.readability(t.backgroundColor, "#FFF") > 2.2 ? "#FFF" : "#000"
207
- },
208
- t.options.length && {
209
- overflow: "hidden",
210
- padding: 0
211
- }
212
- ] }, [t.options.length ? e("div", { staticClass: "flex items-center justify-end w-full", staticStyle: { height: "108px" } }, [e("div", { staticStyle: { "text-align": "right", padding: "2rem" } }, [e("div", { staticStyle: { "font-size": "1.5rem", "font-weight": "900" } }, [t._v(t._s(t._document.$t("price.proposal")))]), e("div", [t._v(t._s(t._document.$t("summaryBottom.chooseFrom")))])]), e("div", { staticStyle: { "background-color": "hsla(0, 0%, 0%, 0.15)", paadding: "1rem 2rem", height: "100%", display: "inline-flex" } }, [t.base ? e("div", { staticStyle: { display: "flex", "flex-direction": "column", "align-items": "flex-start", "justify-content": "center", padding: "1rem 1rem", "text-align": "left" } }, [e("div", { staticStyle: { "font-weight": "900", "font-size": "1.5rem" } }, [t._v(t._s(t.priceFormat(t.base.prices.total, { currency: t.currency, decimals: 2, hideZeroDecimals: !0 })))]), e("div", [t._v("+ " + t._s(t._document.$tc("summaryBottom.option", { count: t.options.length })))])]) : e("div", { staticStyle: { padding: "2rem", display: "inline-flex", "align-items": "center", "justify-content": "center", "font-weight": "900", "font-size": "2.5rem" } }, [t._v(" " + t._s(t._document.$t("summaryBottom.noOfOptions", { count: t.options.length })) + " ")])]), e("div", { staticStyle: { "background-color": "hsla(0, 0%, 0%, 0.4)", overflow: "hidden", width: "1.5rem", display: "flex", "flex-direction": "column", "justify-content": "center", "align-items": "center", height: "100%", color: "hsla(0, 0%, 100%, 0.2)" } })]) : e("div", { staticClass: "flex justify-between w-full", class: [
213
- {
214
- column: t.isSmallScreen,
215
- sm: t.isSmallScreen
216
- }
217
- ], staticStyle: { position: "relative" } }, [e("div", { staticClass: "flex flex-col w-full", class: [{ "fixed-price-type-string": t.isSmallScreen }], staticStyle: { "background-color": "hsl(224, 57%, 39%)" }, style: [t.backgroundSecondary] }, [e("div", { staticClass: "price-type-string data-text" }, [t._v(" " + t._s(t.priceTypeString) + " ")]), t.isSmallScreen ? t._e() : e("div", { staticClass: "price-deduction-text" }, [t._v(" " + t._s(t.priceDeductionVatString) + " ")])]), t.priceType.some((s) => ["openAcc", "openAccMaxPrice"].includes(s)) ? e("div", { staticClass: "open-acc-wrapper" }, [t.openAccMaxPrice ? e("div", { staticClass: "open-acc-item" }, [e("div", [t._v(t._s(t._document.$t("price.maxPrice").capitalize()) + " " + t._s(t._document.$t("vat.exVat", { thing: t._document.$t(`vat.${t.vatType}`) })) + ":")]), e("div", [t._v(t._s(t.priceFormat(t.openAccMaxPrice, { currency: t.currency })))])]) : t._e(), e("div", { staticClass: "open-acc-link" }, [t._v(" " + t._s(t._document.$t("see").capitalize()) + " "), e("span", { staticStyle: { color: "inherit", cursor: "pointer" }, on: { click: t.scrollToPricing } }, [e("u", [t._v(t._s(t._document.$t("price.price_plural")))])]), t._v(" " + t._s(t._document.$t("summaryBottom.forDetails")) + " ")])]) : e("div", { staticClass: "flex items-center w-full", class: [{ "justify-end": !t.isSmallScreen }] }, [e("div", { staticClass: "data-text", staticStyle: { "font-size": "2rem", "font-weight": "900", "letter-spacing": "1px", "line-height": "1", "padding-bottom": "0.3rem" } }, [t._v(" " + t._s(t.priceType.includes("approx") ? t._document.$t("approx").capitalize() : "") + " " + t._s(t.priceFormat(t.priceTotal, { currency: t.currency, decimals: 2, hideZeroDecimals: !0 })) + " ")])]), t.isSmallScreen ? e("div", { staticClass: "label-text caps price-deduction-text", staticStyle: { "margin-top": "4px" } }, [t._v(" " + t._s(t.priceDeductionVatString) + " ")]) : t._e()])])]);
218
- }, C = [], $ = /* @__PURE__ */ c(
219
- x,
220
- b,
221
- C,
222
- !1,
223
- null,
224
- "dd3b66e4",
225
- null,
226
- null
227
- );
228
- const w = $.exports;
229
- const T = {
230
- name: "PriceHeader",
231
- components: {
232
- SummaryTop: S,
233
- SummaryBottom: w,
234
- BlockMedia: l
235
- },
236
- mixins: [n([
237
- "media",
238
- "backgroundColor",
239
- "documentName",
240
- "showPriceSummary",
241
- "showLogo",
242
- "logotype"
243
- ])],
244
- props: {
245
- _document: {
246
- type: Object,
247
- default: () => ({})
248
- },
249
- _value: {
250
- type: Object,
251
- default: () => ({})
252
- },
253
- hasHover: {
254
- type: Boolean,
255
- default: !1
256
- }
257
- },
258
- computed: {
259
- internalName: {
260
- get() {
261
- return this.documentName;
262
- },
263
- set(i) {
264
- this.documentName = i, this.$emit("input", { key: "data.name", value: u(i).trim().slice(0, 255) });
265
- }
266
- },
267
- company() {
268
- return this._document.sender.company;
269
- },
270
- prices() {
271
- return this._document.prices;
272
- },
273
- estimatedTimeString() {
274
- var e, s;
275
- const { value: i, unitType: t } = ((s = (e = this._document) == null ? void 0 : e.data) == null ? void 0 : s.estimatedTime) || {};
276
- return !i || !t ? null : this.$tc(`${t}`, { count: i });
277
- },
278
- sendAtShowDate() {
279
- const { sentAt: i, scheduledFirstDelivery: t } = this._document;
280
- return i || (t ? t.sendAt : null);
281
- },
282
- summaryBottom() {
283
- var s;
284
- let i = {
285
- show: !1,
286
- backgroundColor: this.backgroundColor || this._document.theme.priceSummaryBackground,
287
- documentCurrency: this._document.currency,
288
- vatType: this._document.vatType
289
- }, { showPriceSummary: t } = this;
290
- typeof t != "boolean" && ({ showPriceSummary: t } = this._document.theme);
291
- const e = ((s = this._document.packageGroups) == null ? void 0 : s.packages) || [];
292
- return e.length > 1 ? i = {
293
- ...i,
294
- show: t,
295
- base: { prices: this.prices },
296
- options: e.filter(({ toggable: r }) => r).map(({ prices: r }) => ({ prices: r }))
297
- } : i = {
298
- ...i,
299
- show: t && this._document.readPrices && (this.prices.total || this.prices.type.some((r) => ["openAccMaxPrice", "openAcc"].includes(r))),
300
- base: { prices: this.prices }
301
- }, this.canEdit && t && (i.show = !0), i.documentCurrency || (i.show = !1), i;
302
- }
303
- }
304
- };
305
- var k = function() {
306
- var s, r;
307
- var t = this, e = t._self._c;
308
- return e("div", [e("div", { staticClass: "doc-jumbotron-wrapper" }, [e("BlockMedia", { staticClass: "price-media-wrapper", attrs: { media: {
309
- ...t.media,
310
- resourceUrl: ((s = t.media) == null ? void 0 : s.resourceUrl) || t._document.theme.background,
311
- overlayColor: ((r = t.media) == null ? void 0 : r.overlayColor) || t._document.theme.backgroundFilter
312
- } } }), e("SummaryTop", { attrs: { _document: t._document, "show-logo": t.showLogo, logotype: t.logotype, "company-logotype": t.company.logotype, "sender-name": t.company.name, "doc-type": t._document.docNumber.series, "doc-name": t.internalName, "doc-number": t._document.docNumber.value, "sent-at": t.sendAtShowDate, "expires-at": t._document.expiresAt, "estimated-time": t.estimatedTimeString, "has-hover": t.hasHover }, on: { "update:showLogo": function(o) {
313
- t.showLogo = o;
314
- }, "update:show-logo": function(o) {
315
- t.showLogo = o;
316
- }, "update:logotype": function(o) {
317
- t.logotype = o;
318
- }, "update:docName": function(o) {
319
- t.internalName = o;
320
- }, "update:doc-name": function(o) {
321
- t.internalName = o;
322
- } } })], 1), t.summaryBottom.show ? e("SummaryBottom", t._b({ attrs: { _document: t._document } }, "SummaryBottom", t.summaryBottom, !1)) : t._e()], 1);
323
- }, A = [], B = /* @__PURE__ */ c(
324
- T,
325
- k,
326
- A,
327
- !1,
328
- null,
329
- "d570ff60",
330
- null,
331
- null
332
- );
333
- const E = B.exports;
334
- export {
335
- E as default
336
- };
@@ -1,111 +0,0 @@
1
- import { j as h, n as v, h as g } from "./main-04025a56.js";
2
- import { B as _, a as x } from "./index-bf93d7c2.js";
3
- import y from "./VideoPlayerInput-77cd86aa.js";
4
- import "./CDropdownItem-74672842.js";
5
- import "./throttle-a2c1f34d.js";
6
- import "./formValidationMixin-4920ab53.js";
7
- import "./simplebar.min-3af55aab.js";
8
- import "./utils-6670dea6.js";
9
- const V = h.pexels.id, w = {
10
- name: "VideoSelectModal",
11
- i18nOptions: {
12
- namespaces: "videoSelectModal",
13
- messages: {
14
- en: {
15
- creditVideos: "Videos from {{thing}}",
16
- tabLink: "Use link"
17
- },
18
- sv: {
19
- creditVideos: "Videor från {{thing}}",
20
- tabLink: "Egen länk"
21
- }
22
- }
23
- },
24
- components: {
25
- BackgroundModal: _,
26
- BackgroundList: x,
27
- VideoPlayerInput: y
28
- },
29
- data() {
30
- return {
31
- activeTab: "pexels",
32
- selectedVideo: null,
33
- customVideo: null
34
- };
35
- },
36
- methods: {
37
- async fetch({ query: s, page: t }) {
38
- const { data: e } = await g.get("https://api.pexels.com/videos/search", {
39
- headers: {
40
- Authorization: V
41
- },
42
- params: {
43
- page: t,
44
- per_page: 12,
45
- query: s
46
- }
47
- }), o = (a, i) => a.height < i.height || a.width < i.width ? -1 : 1, u = (a) => (a.find(({ height: i }) => i > 1e3 && i < 1200) || {}).link;
48
- return {
49
- items: (e.videos || []).map(({
50
- id: a,
51
- image: i,
52
- video_files: c = [],
53
- user: d
54
- }) => {
55
- const { sd: m, hd: p } = (c || []).sort(o).reduce((r, n) => (r[n.quality] && n.link && r[n.quality].push(n.link), r), { sd: [], hd: [] }), [f] = m;
56
- let l = u(c);
57
- return l || ([l] = p.length ? p : m.slice(-1)), {
58
- id: `${a}`,
59
- image: i,
60
- minImage: i,
61
- video: l,
62
- minVideo: f,
63
- userName: d.name,
64
- userLink: d.link
65
- };
66
- }),
67
- total: e.total_results
68
- };
69
- },
70
- selectVideo(s) {
71
- const {
72
- id: t,
73
- image: e,
74
- video: o
75
- } = s || {};
76
- this.selectedVideo = {
77
- id: t,
78
- url: o,
79
- thumbnail: e,
80
- provider: "pexels"
81
- };
82
- },
83
- onSave() {
84
- const s = this.activeTab === "pexels" ? this.selectedVideo : this.customVideo;
85
- this.$emit("input", s), this.$parent && this.$parent.$emit("input", s), this.$emit("close");
86
- }
87
- }
88
- };
89
- var b = function() {
90
- var t = this, e = t._self._c;
91
- return e("BackgroundModal", [e("div", { staticClass: "flex items-center justify-center w-full", staticStyle: { padding: "0.25rem 1rem", "border-bottom": "1px solid hsl(0, 0%, 88%)" }, attrs: { slot: "header" }, slot: "header" }, [e("CButton", { staticStyle: { "font-size": "15px", "font-weight": "700", opacity: "0.5", "box-shadow": "none" }, style: t.activeTab === "pexels" && { opacity: 1 }, on: { click: function(o) {
92
- t.activeTab = "pexels";
93
- } } }, [e("span", { staticStyle: { display: "inline-flex", "align-items": "center" } }, [e("svg", { staticStyle: { "margin-right": "0.5rem" }, attrs: { xmlns: "http://www.w3.org/2000/svg", width: "28", height: "28", viewBox: "0 0 32 32" } }, [e("path", { attrs: { d: "M2 0h28a2 2 0 0 1 2 2v28a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V2a2 2 0 0 1 2-2z", fill: "#05A081" } }), e("path", { attrs: { d: "M13 21h3.863v-3.752h1.167a3.124 3.124 0 1 0 0-6.248H13v10zm5.863 2H11V9h7.03a5.124 5.124 0 0 1 .833 10.18V23z", fill: "#fff" } })]), t._v(" " + t._s(t.$t("_common:video").capitalize()) + " ")])]), e("CButton", { staticStyle: { "font-size": "15px", "font-weight": "700", opacity: "0.5", "box-shadow": "none" }, style: t.activeTab === "customUrl" && { opacity: 1 }, on: { click: function(o) {
94
- t.activeTab = "customUrl";
95
- } } }, [e("span", { staticStyle: { display: "inline-flex", "align-items": "center" } }, [e("svg", { staticStyle: { "margin-right": "0.5rem" }, attrs: { width: "28", height: "28", xmlns: "http://www.w3.org/2000/svg", version: "1.1", x: "0", y: "0", "xml:space": "preserve", viewBox: "0 0 71.412 50" } }, [e("g", { attrs: { transform: "scale(.58824)" } }, [e("path", { attrs: { d: "M118.9 13.3c-1.4-5.2-5.5-9.3-10.7-10.7C98.7 0 60.7 0 60.7 0s-38 0-47.5 2.5C8.1 3.9 3.9 8.1 2.5 13.3 0 22.8 0 42.5 0 42.5s0 19.8 2.5 29.2C3.9 76.9 8 81 13.2 82.4 22.8 85 60.7 85 60.7 85s38 0 47.5-2.5c5.2-1.4 9.3-5.5 10.7-10.7 2.5-9.5 2.5-29.2 2.5-29.2s.1-19.8-2.5-29.3z", fill: "red", "fill-opacity": "1" } }), e("path", { attrs: { fill: "#fff", d: "M80.2 42.5L48.6 24.3v36.4z" } })])]), t._v(" " + t._s(t.$t("tabLink").capitalize()) + " ")])])], 1), t.activeTab === "pexels" ? e("BackgroundList", { attrs: { fetch: t.fetch, "credit-text": t.$t("creditVideos", { thing: "Pexels" }), "default-query": "nature" }, on: { select: t.selectVideo } }, [e("CButton", { staticStyle: { "margin-left": "0.5em" }, attrs: { slot: "footer", disable: !t.selectedVideo, type: "secondary" }, on: { click: t.onSave }, slot: "footer" }, [t._v(" " + t._s(t.$t("_common:save")) + " ")])], 1) : e("div", { staticClass: "flex flex-col items-center justify-center w-full" }, [e("div", { staticStyle: { "max-width": "500px", width: "100%", margin: "0 auto", "padding-top": "3rem" } }, [e("div", { staticStyle: { position: "relative", width: "100%", "padding-top": "56.25%", "background-color": "hsl(0, 0%, 95%)", "border-radius": "0.5em", "margin-bottom": "1.5rem" } }, [t.customVideo ? e("iframe", { staticClass: "custom-video-preview", attrs: { src: t.customVideo.url } }) : t._e()]), e("VideoPlayerInput", { attrs: { filled: !0, "video-options": { background: !0 } }, model: { value: t.customVideo, callback: function(o) {
96
- t.customVideo = o;
97
- }, expression: "customVideo" } }, [e("CButton", { attrs: { disable: !t.customVideo, type: "secondary" }, on: { click: t.onSave } }, [t._v(" " + t._s(t.$t("_common:save")) + " ")])], 1)], 1)])], 1);
98
- }, k = [], S = /* @__PURE__ */ v(
99
- w,
100
- b,
101
- k,
102
- !1,
103
- null,
104
- "184fafdd",
105
- null,
106
- null
107
- );
108
- const j = S.exports;
109
- export {
110
- j as default
111
- };