@bagelink/vue 1.4.5 → 1.4.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/AddressSearch.vue.d.ts.map +1 -1
- package/dist/components/calendar/CalendarPopover.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/CheckInput.vue.d.ts +1 -0
- package/dist/components/form/inputs/CheckInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/SelectInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/SignaturePad.vue.d.ts +3 -1
- package/dist/components/form/inputs/SignaturePad.vue.d.ts.map +1 -1
- package/dist/index.cjs +109 -71
- package/dist/index.mjs +109 -71
- package/dist/style.css +8 -8
- package/package.json +2 -2
- package/src/components/form/inputs/CheckInput.vue +2 -0
- package/src/components/form/inputs/RichText/utils/commands.ts +2 -2
- package/src/components/form/inputs/SignaturePad.vue +83 -38
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AddressSearch.vue.d.ts","sourceRoot":"","sources":["../../src/components/AddressSearch.vue"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;yBAsJoB,GAAG;yBACL,GAAG;4BACnB,GAAG;6BAAoC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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over.vue.d.ts","sourceRoot":"","sources":["../../../src/components/calendar/CalendarPopover.vue"],"names":[],"mappings":"AAwGA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAIpD,KAAK,WAAW,GAAG;IAClB,KAAK,CAAC,EAAE,aAAa,CAAA;IACrB,aAAa,CAAC,EAAE,WAAW,CAAA;IAC3B,QAAQ,CAAC,EAAE;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAA;IACxC,IAAI,EAAE,OAAO,CAAA;IACb,mBAAmB,EAAE,OAAO,CAAA;CAC5B,CAAC;AAqDF,iBAAS,cAAc;WAyDT,OAAO,IAA6B;;;;YAXhB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"CalendarPopover.vue.d.ts","sourceRoot":"","sources":["../../../src/components/calendar/CalendarPopover.vue"],"names":[],"mappings":"AAwGA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAIpD,KAAK,WAAW,GAAG;IAClB,KAAK,CAAC,EAAE,aAAa,CAAA;IACrB,aAAa,CAAC,EAAE,WAAW,CAAA;IAC3B,QAAQ,CAAC,EAAE;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,CAAA;IACxC,IAAI,EAAE,OAAO,CAAA;IACb,mBAAmB,EAAE,OAAO,CAAA;CAC5B,CAAC;AAqDF,iBAAS,cAAc;WAyDT,OAAO,IAA6B;;;;YAXhB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCAqDsmjB,GAAG,8CAA8C,GAAG,yBAAyB,GAAG,6DAAmC,GAAG;;;;;;;;;;;;;;;;;EArChwjB;AAaD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oCAuBsnjB,GAAG,8CAA8C,GAAG,yBAAyB,GAAG,6DAAmC,GAAG;;;;;;;;;;;;;;;OAf/vjB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAQpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CheckInput.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/inputs/CheckInput.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CheckInput.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/inputs/CheckInput.vue"],"names":[],"mappings":"yBAgGiB,CAAC,SAAS,OAAO,GAAG,SAAS,GAAG,GAAG,EAAE,EACrD,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,EAC3G,eAAe,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,EACjE;WAoGO,mBAAmB,CAAC;;;qBApEb,CAAC;;gBA9BP,MAAM;aACT,MAAM;gBACH,MAAM;gBACN,OAAO;mBACJ,OAAO;mBACP,OAAO;uBACH,CAAC;gBACR,GAAG;oBA2FkF,CAAC,4BAA2B;oBACzG,OAAO,KAAK,EAAE,gBAAgB,CAAC,EAAE,CAAC,GAAG,IAAI;WAClD,GAAG;;uBA9B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B,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAapG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -26,6 +26,7 @@ type __VLS_Props = {
|
|
|
26
26
|
};
|
|
27
27
|
declare function clear(): void;
|
|
28
28
|
declare function save(format?: FormatType): string | undefined;
|
|
29
|
+
declare function fromDataURL(url: string): Promise<void> | undefined;
|
|
29
30
|
declare function undo(): void;
|
|
30
31
|
declare function addWaterMark(data: WaterMark): void;
|
|
31
32
|
type __VLS_PublicProps = {
|
|
@@ -38,7 +39,7 @@ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {
|
|
|
38
39
|
isEmpty: () => boolean | undefined;
|
|
39
40
|
undo: typeof undo;
|
|
40
41
|
addWaterMark: typeof addWaterMark;
|
|
41
|
-
fromDataURL:
|
|
42
|
+
fromDataURL: typeof fromDataURL;
|
|
42
43
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
43
44
|
"update:modelValue": (value: any) => any;
|
|
44
45
|
"update:file": (value: File) => any;
|
|
@@ -49,6 +50,7 @@ declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {
|
|
|
49
50
|
clearable: boolean;
|
|
50
51
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
51
52
|
vCanvas: HTMLCanvasElement;
|
|
53
|
+
requiredInput: HTMLInputElement;
|
|
52
54
|
}, HTMLDivElement>;
|
|
53
55
|
export default _default;
|
|
54
56
|
//# sourceMappingURL=SignaturePad.vue.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SignaturePad.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/form/inputs/SignaturePad.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file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CAAC;IACjB,MAAM,CAAC,EAAE,IAAI,CAAC;CACb,GAAG,WAAW,CAAC;;;;;;;;;;;;;;;eA7MH,OAAO;;;;;AA+SpB,wBAWG"}
|
package/dist/index.cjs
CHANGED
|
@@ -764,8 +764,8 @@ function onClickOutside(target, handler, options = {}) {
|
|
|
764
764
|
if (isIOS && !_iOSWorkaround) {
|
|
765
765
|
_iOSWorkaround = true;
|
|
766
766
|
const listenerOptions = { passive: true };
|
|
767
|
-
Array.from(window2.document.body.children).forEach((el) =>
|
|
768
|
-
|
|
767
|
+
Array.from(window2.document.body.children).forEach((el) => el.addEventListener("click", noop$1, listenerOptions));
|
|
768
|
+
window2.document.documentElement.addEventListener("click", noop$1, listenerOptions);
|
|
769
769
|
}
|
|
770
770
|
let shouldListen = true;
|
|
771
771
|
const shouldIgnore = (event) => {
|
|
@@ -10922,15 +10922,20 @@ const flip = function(options) {
|
|
|
10922
10922
|
const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
|
|
10923
10923
|
const nextPlacement = placements2[nextIndex];
|
|
10924
10924
|
if (nextPlacement) {
|
|
10925
|
-
|
|
10926
|
-
|
|
10927
|
-
|
|
10928
|
-
|
|
10929
|
-
|
|
10930
|
-
|
|
10931
|
-
|
|
10932
|
-
|
|
10933
|
-
|
|
10925
|
+
var _overflowsData$;
|
|
10926
|
+
const ignoreCrossAxisOverflow = checkCrossAxis === "alignment" ? initialSideAxis !== getSideAxis(nextPlacement) : false;
|
|
10927
|
+
const hasInitialMainAxisOverflow = ((_overflowsData$ = overflowsData[0]) == null ? void 0 : _overflowsData$.overflows[0]) > 0;
|
|
10928
|
+
if (!ignoreCrossAxisOverflow || hasInitialMainAxisOverflow) {
|
|
10929
|
+
return {
|
|
10930
|
+
data: {
|
|
10931
|
+
index: nextIndex,
|
|
10932
|
+
overflows: overflowsData
|
|
10933
|
+
},
|
|
10934
|
+
reset: {
|
|
10935
|
+
placement: nextPlacement
|
|
10936
|
+
}
|
|
10937
|
+
};
|
|
10938
|
+
}
|
|
10934
10939
|
}
|
|
10935
10940
|
let resetPlacement = (_overflowsData$filter = overflowsData.filter((d2) => d2.overflows[0] <= 0).sort((a2, b2) => a2.overflows[1] - b2.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
|
|
10936
10941
|
if (!resetPlacement) {
|
|
@@ -14186,7 +14191,7 @@ const _sfc_main$T = /* @__PURE__ */ vue.defineComponent({
|
|
|
14186
14191
|
});
|
|
14187
14192
|
const Checkbox = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["__scopeId", "data-v-73f1d9ad"]]);
|
|
14188
14193
|
const _hoisted_1$L = ["title"];
|
|
14189
|
-
const _hoisted_2$A = ["id", "value", "required"];
|
|
14194
|
+
const _hoisted_2$A = ["id", "disabled", "value", "required"];
|
|
14190
14195
|
const _hoisted_3$v = ["for"];
|
|
14191
14196
|
const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
|
|
14192
14197
|
__name: "CheckInput",
|
|
@@ -14196,6 +14201,7 @@ const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
|
|
|
14196
14201
|
title: {},
|
|
14197
14202
|
small: { type: Boolean },
|
|
14198
14203
|
required: { type: Boolean },
|
|
14204
|
+
disabled: { type: Boolean },
|
|
14199
14205
|
defaultValue: { default: false },
|
|
14200
14206
|
value: {}
|
|
14201
14207
|
}, {
|
|
@@ -14217,6 +14223,7 @@ const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
|
|
|
14217
14223
|
vue.withDirectives(vue.createElementVNode("input", {
|
|
14218
14224
|
id: inputId.value + _ctx.value,
|
|
14219
14225
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => checked.value = $event),
|
|
14226
|
+
disabled: _ctx.disabled,
|
|
14220
14227
|
value: _ctx.value,
|
|
14221
14228
|
required: _ctx.required,
|
|
14222
14229
|
type: "checkbox",
|
|
@@ -14235,7 +14242,7 @@ const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
|
|
|
14235
14242
|
};
|
|
14236
14243
|
}
|
|
14237
14244
|
});
|
|
14238
|
-
const CheckInput = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["__scopeId", "data-v-
|
|
14245
|
+
const CheckInput = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["__scopeId", "data-v-1c41dd4f"]]);
|
|
14239
14246
|
function useHighlight() {
|
|
14240
14247
|
const hljs = vue.ref(null);
|
|
14241
14248
|
const loaded = vue.ref(false);
|
|
@@ -17697,9 +17704,13 @@ function createCommandRegistry(state2) {
|
|
|
17697
17704
|
}, (state22) => state22.isCodeView)
|
|
17698
17705
|
};
|
|
17699
17706
|
const mediaCommands = {
|
|
17700
|
-
image: createCommand("Insert Image", (state22) =>
|
|
17707
|
+
image: createCommand("Insert Image", (state22) => {
|
|
17708
|
+
state22.modal && insertImage(state22.modal, state22);
|
|
17709
|
+
}),
|
|
17701
17710
|
link: createCommand("Insert Link", (state22) => state22.modal && state22.range && insertLink(state22.modal, state22)),
|
|
17702
|
-
embed: createCommand("Insert Embed", (state22) =>
|
|
17711
|
+
embed: createCommand("Insert Embed", (state22) => {
|
|
17712
|
+
state22.modal && insertEmbed(state22.modal, state22);
|
|
17713
|
+
})
|
|
17703
17714
|
};
|
|
17704
17715
|
const otherCommands = {
|
|
17705
17716
|
clear: createCommand("Clear Formatting", (state22) => {
|
|
@@ -18586,7 +18597,8 @@ const _sfc_main$D = /* @__PURE__ */ vue.defineComponent({
|
|
|
18586
18597
|
default: vue.withCtx(() => _cache[3] || (_cache[3] = [
|
|
18587
18598
|
vue.createTextVNode(" Clear Session ")
|
|
18588
18599
|
])),
|
|
18589
|
-
_: 1
|
|
18600
|
+
_: 1,
|
|
18601
|
+
__: [3]
|
|
18590
18602
|
}, 8, ["onClick"]),
|
|
18591
18603
|
vue.createVNode(vue.unref(Btn), {
|
|
18592
18604
|
thin: "",
|
|
@@ -18597,7 +18609,8 @@ const _sfc_main$D = /* @__PURE__ */ vue.defineComponent({
|
|
|
18597
18609
|
default: vue.withCtx(() => _cache[4] || (_cache[4] = [
|
|
18598
18610
|
vue.createTextVNode(" Download Log ")
|
|
18599
18611
|
])),
|
|
18600
|
-
_: 1
|
|
18612
|
+
_: 1,
|
|
18613
|
+
__: [4]
|
|
18601
18614
|
}, 8, ["onClick"]),
|
|
18602
18615
|
vue.createVNode(vue.unref(Btn), {
|
|
18603
18616
|
thin: "",
|
|
@@ -18611,7 +18624,8 @@ const _sfc_main$D = /* @__PURE__ */ vue.defineComponent({
|
|
|
18611
18624
|
default: vue.withCtx(() => _cache[5] || (_cache[5] = [
|
|
18612
18625
|
vue.createTextVNode(" Copy Log ")
|
|
18613
18626
|
])),
|
|
18614
|
-
_: 1
|
|
18627
|
+
_: 1,
|
|
18628
|
+
__: [5]
|
|
18615
18629
|
})
|
|
18616
18630
|
])) : vue.createCommentVNode("", true)
|
|
18617
18631
|
], 2)
|
|
@@ -19523,13 +19537,7 @@ class SignaturePad extends SignatureEventTarget {
|
|
|
19523
19537
|
}
|
|
19524
19538
|
}
|
|
19525
19539
|
const _hoisted_1$u = ["disabled"];
|
|
19526
|
-
const _hoisted_2$l =
|
|
19527
|
-
key: 1,
|
|
19528
|
-
placeholder: "required",
|
|
19529
|
-
type: "text",
|
|
19530
|
-
required: "",
|
|
19531
|
-
class: "pixel opacity-0"
|
|
19532
|
-
};
|
|
19540
|
+
const _hoisted_2$l = ["required"];
|
|
19533
19541
|
const _sfc_main$B = /* @__PURE__ */ vue.defineComponent({
|
|
19534
19542
|
__name: "SignaturePad",
|
|
19535
19543
|
props: /* @__PURE__ */ vue.mergeModels({
|
|
@@ -19556,6 +19564,7 @@ const _sfc_main$B = /* @__PURE__ */ vue.defineComponent({
|
|
|
19556
19564
|
const sigData = vue.useModel(__props, "modelValue");
|
|
19557
19565
|
const fileData = vue.useModel(__props, "file");
|
|
19558
19566
|
const vCanvas = vue.ref();
|
|
19567
|
+
const requiredInput = vue.ref();
|
|
19559
19568
|
let sig = vue.ref();
|
|
19560
19569
|
let _isEmpty = vue.ref(true);
|
|
19561
19570
|
function clear() {
|
|
@@ -19575,22 +19584,32 @@ const _sfc_main$B = /* @__PURE__ */ vue.defineComponent({
|
|
|
19575
19584
|
if (props2.format === "image/svg+xml") {
|
|
19576
19585
|
fileData.value = new File([data2], "signature.svg", { type: "image/svg+xml" });
|
|
19577
19586
|
} else {
|
|
19578
|
-
|
|
19579
|
-
|
|
19580
|
-
|
|
19581
|
-
|
|
19582
|
-
|
|
19587
|
+
try {
|
|
19588
|
+
const base64Data = data2.split(",")[1];
|
|
19589
|
+
if (!base64Data) throw new Error("Invalid data URL format");
|
|
19590
|
+
const byteCharacters = atob(base64Data);
|
|
19591
|
+
const byteArray = new Uint8Array(
|
|
19592
|
+
Array.from(byteCharacters, (char) => char.charCodeAt(0))
|
|
19593
|
+
);
|
|
19594
|
+
const mimeType = props2.format || "image/png";
|
|
19595
|
+
const blob = new Blob([byteArray], { type: mimeType });
|
|
19596
|
+
const extension = mimeType.split("/")[1];
|
|
19597
|
+
fileData.value = new File([blob], `signature.${extension}`, { type: mimeType });
|
|
19598
|
+
} catch (error) {
|
|
19599
|
+
console.error("Error saving signature file:", error);
|
|
19583
19600
|
}
|
|
19584
|
-
const byteArray = new Uint8Array(byteNumbers);
|
|
19585
|
-
const blob = new Blob([byteArray], { type: props2.format || "image/png" });
|
|
19586
|
-
const extension = (props2.format || "image/png").split("/")[1];
|
|
19587
|
-
fileData.value = new File([blob], `signature.${extension}`, { type: props2.format || "image/png" });
|
|
19588
19601
|
}
|
|
19589
19602
|
}
|
|
19590
|
-
|
|
19591
|
-
var _a;
|
|
19592
|
-
return (
|
|
19593
|
-
|
|
19603
|
+
function fromDataURL(url) {
|
|
19604
|
+
var _a, _b, _c;
|
|
19605
|
+
return (_c = sig.value) == null ? void 0 : _c.fromDataURL(url, {
|
|
19606
|
+
height: (_a = vCanvas.value) == null ? void 0 : _a.height,
|
|
19607
|
+
width: (_b = vCanvas.value) == null ? void 0 : _b.width,
|
|
19608
|
+
ratio: props2.ratio,
|
|
19609
|
+
xOffset: 0,
|
|
19610
|
+
yOffset: 0
|
|
19611
|
+
});
|
|
19612
|
+
}
|
|
19594
19613
|
const isEmpty = () => {
|
|
19595
19614
|
var _a;
|
|
19596
19615
|
return (_a = sig.value) == null ? void 0 : _a.isEmpty();
|
|
@@ -19650,14 +19669,14 @@ const _sfc_main$B = /* @__PURE__ */ vue.defineComponent({
|
|
|
19650
19669
|
sigData.value = data2;
|
|
19651
19670
|
saveFile();
|
|
19652
19671
|
}
|
|
19653
|
-
|
|
19672
|
+
function loadFile(file) {
|
|
19654
19673
|
if (!file) return;
|
|
19655
19674
|
const reader = new FileReader();
|
|
19656
19675
|
return new Promise((resolve) => {
|
|
19657
19676
|
reader.onload = (e) => {
|
|
19658
19677
|
var _a;
|
|
19659
|
-
const dataUrl = (_a = e.target) == null ? void 0 : _a.result;
|
|
19660
|
-
fromDataURL(dataUrl);
|
|
19678
|
+
const dataUrl = String((_a = e.target) == null ? void 0 : _a.result);
|
|
19679
|
+
void fromDataURL(dataUrl);
|
|
19661
19680
|
_isEmpty.value = false;
|
|
19662
19681
|
sigData.value = dataUrl;
|
|
19663
19682
|
resolve(true);
|
|
@@ -19666,38 +19685,36 @@ const _sfc_main$B = /* @__PURE__ */ vue.defineComponent({
|
|
|
19666
19685
|
});
|
|
19667
19686
|
}
|
|
19668
19687
|
vue.watch(fileData, (newFile) => {
|
|
19669
|
-
loadFile(newFile);
|
|
19670
|
-
});
|
|
19688
|
+
void loadFile(newFile);
|
|
19689
|
+
});
|
|
19690
|
+
function resizeCanvas() {
|
|
19691
|
+
let url;
|
|
19692
|
+
if (!isEmpty()) url = save2();
|
|
19693
|
+
const ratio = props2.ratio ?? 1 / 2;
|
|
19694
|
+
const { width } = vCanvas.value.getBoundingClientRect();
|
|
19695
|
+
vCanvas.value.width = props2.width ? Number(props2.width.replaceAll("px", "")) : width;
|
|
19696
|
+
vCanvas.value.height = props2.height ? Number(props2.height.replaceAll("px", "")) : width * ratio;
|
|
19697
|
+
clear();
|
|
19698
|
+
if (!props2.clearOnResize && url !== void 0) void fromDataURL(url);
|
|
19699
|
+
if (props2.waterMark) addWaterMark(props2.waterMark);
|
|
19700
|
+
}
|
|
19671
19701
|
function draw() {
|
|
19672
|
-
|
|
19673
|
-
|
|
19674
|
-
|
|
19675
|
-
let url;
|
|
19676
|
-
if (!isEmpty()) url = save2();
|
|
19677
|
-
const ratio = props2.ratio ?? 1 / 2;
|
|
19678
|
-
const { width } = c2.getBoundingClientRect();
|
|
19679
|
-
c2.width = props2.width ? Number(props2.width.replaceAll("px", "")) : width;
|
|
19680
|
-
c2.height = props2.height ? Number(props2.height.replaceAll("px", "")) : width * ratio;
|
|
19681
|
-
clear();
|
|
19682
|
-
if (!props2.clearOnResize && url !== void 0) fromDataURL(url);
|
|
19683
|
-
if (props2.waterMark) addWaterMark(props2.waterMark);
|
|
19684
|
-
}
|
|
19685
|
-
window.addEventListener("resize", () => {
|
|
19686
|
-
resizeCanvas(canvas);
|
|
19687
|
-
});
|
|
19688
|
-
resizeCanvas(canvas);
|
|
19702
|
+
sig.value = new SignaturePad(vCanvas.value, signatureOptions.value);
|
|
19703
|
+
window.addEventListener("resize", resizeCanvas);
|
|
19704
|
+
resizeCanvas();
|
|
19689
19705
|
if (props2.disabled) sig.value.off();
|
|
19690
19706
|
else sig.value.on();
|
|
19691
19707
|
_isEmpty.value = sig.value.isEmpty();
|
|
19692
19708
|
sig.value.addEventListener("endStroke", onEndStroke);
|
|
19693
19709
|
if (fileData.value) {
|
|
19694
|
-
loadFile(fileData.value);
|
|
19710
|
+
void loadFile(fileData.value);
|
|
19695
19711
|
}
|
|
19696
19712
|
}
|
|
19697
19713
|
vue.onMounted(draw);
|
|
19698
19714
|
vue.onUnmounted(() => {
|
|
19699
19715
|
var _a;
|
|
19700
19716
|
(_a = sig.value) == null ? void 0 : _a.removeEventListener("endStroke", onEndStroke);
|
|
19717
|
+
window.removeEventListener("resize", resizeCanvas);
|
|
19701
19718
|
});
|
|
19702
19719
|
__expose({
|
|
19703
19720
|
save: save2,
|
|
@@ -19710,7 +19727,7 @@ const _sfc_main$B = /* @__PURE__ */ vue.defineComponent({
|
|
|
19710
19727
|
return (_ctx, _cache) => {
|
|
19711
19728
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
19712
19729
|
class: vue.normalizeClass(["bgl_input signature-pad relative", { "bg-transparent": _ctx.disabled }]),
|
|
19713
|
-
onTouchmove: _cache[
|
|
19730
|
+
onTouchmove: _cache[1] || (_cache[1] = vue.withModifiers(() => {
|
|
19714
19731
|
}, ["prevent"]))
|
|
19715
19732
|
}, [
|
|
19716
19733
|
_ctx.clearable && !_ctx.disabled ? (vue.openBlock(), vue.createBlock(vue.unref(Btn), {
|
|
@@ -19727,7 +19744,20 @@ const _sfc_main$B = /* @__PURE__ */ vue.defineComponent({
|
|
|
19727
19744
|
class: "canvas",
|
|
19728
19745
|
disabled: _ctx.disabled
|
|
19729
19746
|
}, null, 8, _hoisted_1$u),
|
|
19730
|
-
|
|
19747
|
+
vue.createElementVNode("input", {
|
|
19748
|
+
ref_key: "requiredInput",
|
|
19749
|
+
ref: requiredInput,
|
|
19750
|
+
placeholder: "required",
|
|
19751
|
+
type: "text",
|
|
19752
|
+
required: _ctx.required && vue.unref(_isEmpty),
|
|
19753
|
+
class: "pixel opacity-0",
|
|
19754
|
+
tabindex: "-1",
|
|
19755
|
+
"aria-hidden": "true",
|
|
19756
|
+
onFocus: _cache[0] || (_cache[0] = (event) => {
|
|
19757
|
+
var _a, _b;
|
|
19758
|
+
return (_b = (_a = event.target) == null ? void 0 : _a.blur) == null ? void 0 : _b.call(_a);
|
|
19759
|
+
})
|
|
19760
|
+
}, null, 40, _hoisted_2$l)
|
|
19731
19761
|
], 34);
|
|
19732
19762
|
};
|
|
19733
19763
|
}
|
|
@@ -22355,7 +22385,8 @@ const _sfc_main$A = /* @__PURE__ */ vue.defineComponent({
|
|
|
22355
22385
|
default: vue.withCtx(() => _cache[1] || (_cache[1] = [
|
|
22356
22386
|
vue.createTextVNode(" New ")
|
|
22357
22387
|
])),
|
|
22358
|
-
_: 1
|
|
22388
|
+
_: 1,
|
|
22389
|
+
__: [1]
|
|
22359
22390
|
})
|
|
22360
22391
|
], 8, _hoisted_1$t);
|
|
22361
22392
|
};
|
|
@@ -33590,7 +33621,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
33590
33621
|
_cache[30] || (_cache[30] = vue.createElementVNode("u", null, "or click to select a file", -1)),
|
|
33591
33622
|
_cache[31] || (_cache[31] = vue.createElementVNode("p", { class: "txt-12 color-gray" }, " Accepts .xlsx, .xls, and .csv files ", -1))
|
|
33592
33623
|
]),
|
|
33593
|
-
_: 1
|
|
33624
|
+
_: 1,
|
|
33625
|
+
__: [29, 30, 31]
|
|
33594
33626
|
})
|
|
33595
33627
|
]),
|
|
33596
33628
|
_: 1
|
|
@@ -33721,7 +33753,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
33721
33753
|
default: vue.withCtx(() => _cache[34] || (_cache[34] = [
|
|
33722
33754
|
vue.createTextVNode(" Preview Data ")
|
|
33723
33755
|
])),
|
|
33724
|
-
_: 1
|
|
33756
|
+
_: 1,
|
|
33757
|
+
__: [34]
|
|
33725
33758
|
})
|
|
33726
33759
|
])) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_19, _cache[35] || (_cache[35] = [
|
|
33727
33760
|
vue.createElementVNode("div", { class: "mapping-incomplete-message" }, " Please map the required fields to continue ", -1)
|
|
@@ -33857,7 +33890,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
33857
33890
|
_cache[40] || (_cache[40] = vue.createElementVNode("p", null, "or click to select a file", -1)),
|
|
33858
33891
|
_cache[41] || (_cache[41] = vue.createElementVNode("p", { class: "txt-12 color-gray" }, " Accepts .xlsx, .xls, and .csv files ", -1))
|
|
33859
33892
|
]),
|
|
33860
|
-
_: 1
|
|
33893
|
+
_: 1,
|
|
33894
|
+
__: [39, 40, 41]
|
|
33861
33895
|
})
|
|
33862
33896
|
]),
|
|
33863
33897
|
_: 1
|
|
@@ -33943,7 +33977,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
33943
33977
|
default: vue.withCtx(() => _cache[42] || (_cache[42] = [
|
|
33944
33978
|
vue.createTextVNode(" Transform ")
|
|
33945
33979
|
])),
|
|
33946
|
-
_: 2
|
|
33980
|
+
_: 2,
|
|
33981
|
+
__: [42]
|
|
33947
33982
|
}, 1032, ["onClick"])
|
|
33948
33983
|
])
|
|
33949
33984
|
])
|
|
@@ -34117,7 +34152,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
34117
34152
|
default: vue.withCtx(() => _cache[48] || (_cache[48] = [
|
|
34118
34153
|
vue.createTextVNode(" Close ")
|
|
34119
34154
|
])),
|
|
34120
|
-
_: 1
|
|
34155
|
+
_: 1,
|
|
34156
|
+
__: [48]
|
|
34121
34157
|
})
|
|
34122
34158
|
])
|
|
34123
34159
|
])) : vue.createCommentVNode("", true)
|
|
@@ -34285,7 +34321,8 @@ const _sfc_main$p = /* @__PURE__ */ vue.defineComponent({
|
|
|
34285
34321
|
_cache[0] || (_cache[0] = vue.createElementVNode("div", { style: { "flex-grow": "1" } }, null, -1)),
|
|
34286
34322
|
vue.renderSlot(_ctx.$slots, "footer", {}, void 0, true)
|
|
34287
34323
|
]),
|
|
34288
|
-
_: 3
|
|
34324
|
+
_: 3,
|
|
34325
|
+
__: [0]
|
|
34289
34326
|
})
|
|
34290
34327
|
], 2);
|
|
34291
34328
|
};
|
|
@@ -34672,7 +34709,8 @@ const _sfc_main$j = /* @__PURE__ */ vue.defineComponent({
|
|
|
34672
34709
|
}, null, 8, _hoisted_5$5)) : vue.createCommentVNode("", true)
|
|
34673
34710
|
])
|
|
34674
34711
|
]),
|
|
34675
|
-
_: 3
|
|
34712
|
+
_: 3,
|
|
34713
|
+
__: [0]
|
|
34676
34714
|
}, 16, ["class", "onClick"])), [
|
|
34677
34715
|
[_directive_ripple, isClickable.value]
|
|
34678
34716
|
]);
|
package/dist/index.mjs
CHANGED
|
@@ -762,8 +762,8 @@ function onClickOutside(target, handler, options = {}) {
|
|
|
762
762
|
if (isIOS && !_iOSWorkaround) {
|
|
763
763
|
_iOSWorkaround = true;
|
|
764
764
|
const listenerOptions = { passive: true };
|
|
765
|
-
Array.from(window2.document.body.children).forEach((el) =>
|
|
766
|
-
|
|
765
|
+
Array.from(window2.document.body.children).forEach((el) => el.addEventListener("click", noop$1, listenerOptions));
|
|
766
|
+
window2.document.documentElement.addEventListener("click", noop$1, listenerOptions);
|
|
767
767
|
}
|
|
768
768
|
let shouldListen = true;
|
|
769
769
|
const shouldIgnore = (event) => {
|
|
@@ -10920,15 +10920,20 @@ const flip = function(options) {
|
|
|
10920
10920
|
const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
|
|
10921
10921
|
const nextPlacement = placements2[nextIndex];
|
|
10922
10922
|
if (nextPlacement) {
|
|
10923
|
-
|
|
10924
|
-
|
|
10925
|
-
|
|
10926
|
-
|
|
10927
|
-
|
|
10928
|
-
|
|
10929
|
-
|
|
10930
|
-
|
|
10931
|
-
|
|
10923
|
+
var _overflowsData$;
|
|
10924
|
+
const ignoreCrossAxisOverflow = checkCrossAxis === "alignment" ? initialSideAxis !== getSideAxis(nextPlacement) : false;
|
|
10925
|
+
const hasInitialMainAxisOverflow = ((_overflowsData$ = overflowsData[0]) == null ? void 0 : _overflowsData$.overflows[0]) > 0;
|
|
10926
|
+
if (!ignoreCrossAxisOverflow || hasInitialMainAxisOverflow) {
|
|
10927
|
+
return {
|
|
10928
|
+
data: {
|
|
10929
|
+
index: nextIndex,
|
|
10930
|
+
overflows: overflowsData
|
|
10931
|
+
},
|
|
10932
|
+
reset: {
|
|
10933
|
+
placement: nextPlacement
|
|
10934
|
+
}
|
|
10935
|
+
};
|
|
10936
|
+
}
|
|
10932
10937
|
}
|
|
10933
10938
|
let resetPlacement = (_overflowsData$filter = overflowsData.filter((d2) => d2.overflows[0] <= 0).sort((a2, b2) => a2.overflows[1] - b2.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
|
|
10934
10939
|
if (!resetPlacement) {
|
|
@@ -14184,7 +14189,7 @@ const _sfc_main$T = /* @__PURE__ */ defineComponent({
|
|
|
14184
14189
|
});
|
|
14185
14190
|
const Checkbox = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["__scopeId", "data-v-73f1d9ad"]]);
|
|
14186
14191
|
const _hoisted_1$L = ["title"];
|
|
14187
|
-
const _hoisted_2$A = ["id", "value", "required"];
|
|
14192
|
+
const _hoisted_2$A = ["id", "disabled", "value", "required"];
|
|
14188
14193
|
const _hoisted_3$v = ["for"];
|
|
14189
14194
|
const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
14190
14195
|
__name: "CheckInput",
|
|
@@ -14194,6 +14199,7 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
|
14194
14199
|
title: {},
|
|
14195
14200
|
small: { type: Boolean },
|
|
14196
14201
|
required: { type: Boolean },
|
|
14202
|
+
disabled: { type: Boolean },
|
|
14197
14203
|
defaultValue: { default: false },
|
|
14198
14204
|
value: {}
|
|
14199
14205
|
}, {
|
|
@@ -14215,6 +14221,7 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
|
14215
14221
|
withDirectives(createElementVNode("input", {
|
|
14216
14222
|
id: inputId.value + _ctx.value,
|
|
14217
14223
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => checked.value = $event),
|
|
14224
|
+
disabled: _ctx.disabled,
|
|
14218
14225
|
value: _ctx.value,
|
|
14219
14226
|
required: _ctx.required,
|
|
14220
14227
|
type: "checkbox",
|
|
@@ -14233,7 +14240,7 @@ const _sfc_main$S = /* @__PURE__ */ defineComponent({
|
|
|
14233
14240
|
};
|
|
14234
14241
|
}
|
|
14235
14242
|
});
|
|
14236
|
-
const CheckInput = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["__scopeId", "data-v-
|
|
14243
|
+
const CheckInput = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["__scopeId", "data-v-1c41dd4f"]]);
|
|
14237
14244
|
function useHighlight() {
|
|
14238
14245
|
const hljs = ref(null);
|
|
14239
14246
|
const loaded = ref(false);
|
|
@@ -17695,9 +17702,13 @@ function createCommandRegistry(state2) {
|
|
|
17695
17702
|
}, (state22) => state22.isCodeView)
|
|
17696
17703
|
};
|
|
17697
17704
|
const mediaCommands = {
|
|
17698
|
-
image: createCommand("Insert Image", (state22) =>
|
|
17705
|
+
image: createCommand("Insert Image", (state22) => {
|
|
17706
|
+
state22.modal && insertImage(state22.modal, state22);
|
|
17707
|
+
}),
|
|
17699
17708
|
link: createCommand("Insert Link", (state22) => state22.modal && state22.range && insertLink(state22.modal, state22)),
|
|
17700
|
-
embed: createCommand("Insert Embed", (state22) =>
|
|
17709
|
+
embed: createCommand("Insert Embed", (state22) => {
|
|
17710
|
+
state22.modal && insertEmbed(state22.modal, state22);
|
|
17711
|
+
})
|
|
17701
17712
|
};
|
|
17702
17713
|
const otherCommands = {
|
|
17703
17714
|
clear: createCommand("Clear Formatting", (state22) => {
|
|
@@ -18584,7 +18595,8 @@ const _sfc_main$D = /* @__PURE__ */ defineComponent({
|
|
|
18584
18595
|
default: withCtx(() => _cache[3] || (_cache[3] = [
|
|
18585
18596
|
createTextVNode(" Clear Session ")
|
|
18586
18597
|
])),
|
|
18587
|
-
_: 1
|
|
18598
|
+
_: 1,
|
|
18599
|
+
__: [3]
|
|
18588
18600
|
}, 8, ["onClick"]),
|
|
18589
18601
|
createVNode(unref(Btn), {
|
|
18590
18602
|
thin: "",
|
|
@@ -18595,7 +18607,8 @@ const _sfc_main$D = /* @__PURE__ */ defineComponent({
|
|
|
18595
18607
|
default: withCtx(() => _cache[4] || (_cache[4] = [
|
|
18596
18608
|
createTextVNode(" Download Log ")
|
|
18597
18609
|
])),
|
|
18598
|
-
_: 1
|
|
18610
|
+
_: 1,
|
|
18611
|
+
__: [4]
|
|
18599
18612
|
}, 8, ["onClick"]),
|
|
18600
18613
|
createVNode(unref(Btn), {
|
|
18601
18614
|
thin: "",
|
|
@@ -18609,7 +18622,8 @@ const _sfc_main$D = /* @__PURE__ */ defineComponent({
|
|
|
18609
18622
|
default: withCtx(() => _cache[5] || (_cache[5] = [
|
|
18610
18623
|
createTextVNode(" Copy Log ")
|
|
18611
18624
|
])),
|
|
18612
|
-
_: 1
|
|
18625
|
+
_: 1,
|
|
18626
|
+
__: [5]
|
|
18613
18627
|
})
|
|
18614
18628
|
])) : createCommentVNode("", true)
|
|
18615
18629
|
], 2)
|
|
@@ -19521,13 +19535,7 @@ class SignaturePad extends SignatureEventTarget {
|
|
|
19521
19535
|
}
|
|
19522
19536
|
}
|
|
19523
19537
|
const _hoisted_1$u = ["disabled"];
|
|
19524
|
-
const _hoisted_2$l =
|
|
19525
|
-
key: 1,
|
|
19526
|
-
placeholder: "required",
|
|
19527
|
-
type: "text",
|
|
19528
|
-
required: "",
|
|
19529
|
-
class: "pixel opacity-0"
|
|
19530
|
-
};
|
|
19538
|
+
const _hoisted_2$l = ["required"];
|
|
19531
19539
|
const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
19532
19540
|
__name: "SignaturePad",
|
|
19533
19541
|
props: /* @__PURE__ */ mergeModels({
|
|
@@ -19554,6 +19562,7 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
19554
19562
|
const sigData = useModel(__props, "modelValue");
|
|
19555
19563
|
const fileData = useModel(__props, "file");
|
|
19556
19564
|
const vCanvas = ref();
|
|
19565
|
+
const requiredInput = ref();
|
|
19557
19566
|
let sig = ref();
|
|
19558
19567
|
let _isEmpty = ref(true);
|
|
19559
19568
|
function clear() {
|
|
@@ -19573,22 +19582,32 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
19573
19582
|
if (props2.format === "image/svg+xml") {
|
|
19574
19583
|
fileData.value = new File([data2], "signature.svg", { type: "image/svg+xml" });
|
|
19575
19584
|
} else {
|
|
19576
|
-
|
|
19577
|
-
|
|
19578
|
-
|
|
19579
|
-
|
|
19580
|
-
|
|
19585
|
+
try {
|
|
19586
|
+
const base64Data = data2.split(",")[1];
|
|
19587
|
+
if (!base64Data) throw new Error("Invalid data URL format");
|
|
19588
|
+
const byteCharacters = atob(base64Data);
|
|
19589
|
+
const byteArray = new Uint8Array(
|
|
19590
|
+
Array.from(byteCharacters, (char) => char.charCodeAt(0))
|
|
19591
|
+
);
|
|
19592
|
+
const mimeType = props2.format || "image/png";
|
|
19593
|
+
const blob = new Blob([byteArray], { type: mimeType });
|
|
19594
|
+
const extension = mimeType.split("/")[1];
|
|
19595
|
+
fileData.value = new File([blob], `signature.${extension}`, { type: mimeType });
|
|
19596
|
+
} catch (error) {
|
|
19597
|
+
console.error("Error saving signature file:", error);
|
|
19581
19598
|
}
|
|
19582
|
-
const byteArray = new Uint8Array(byteNumbers);
|
|
19583
|
-
const blob = new Blob([byteArray], { type: props2.format || "image/png" });
|
|
19584
|
-
const extension = (props2.format || "image/png").split("/")[1];
|
|
19585
|
-
fileData.value = new File([blob], `signature.${extension}`, { type: props2.format || "image/png" });
|
|
19586
19599
|
}
|
|
19587
19600
|
}
|
|
19588
|
-
|
|
19589
|
-
var _a;
|
|
19590
|
-
return (
|
|
19591
|
-
|
|
19601
|
+
function fromDataURL(url) {
|
|
19602
|
+
var _a, _b, _c;
|
|
19603
|
+
return (_c = sig.value) == null ? void 0 : _c.fromDataURL(url, {
|
|
19604
|
+
height: (_a = vCanvas.value) == null ? void 0 : _a.height,
|
|
19605
|
+
width: (_b = vCanvas.value) == null ? void 0 : _b.width,
|
|
19606
|
+
ratio: props2.ratio,
|
|
19607
|
+
xOffset: 0,
|
|
19608
|
+
yOffset: 0
|
|
19609
|
+
});
|
|
19610
|
+
}
|
|
19592
19611
|
const isEmpty = () => {
|
|
19593
19612
|
var _a;
|
|
19594
19613
|
return (_a = sig.value) == null ? void 0 : _a.isEmpty();
|
|
@@ -19648,14 +19667,14 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
19648
19667
|
sigData.value = data2;
|
|
19649
19668
|
saveFile();
|
|
19650
19669
|
}
|
|
19651
|
-
|
|
19670
|
+
function loadFile(file) {
|
|
19652
19671
|
if (!file) return;
|
|
19653
19672
|
const reader = new FileReader();
|
|
19654
19673
|
return new Promise((resolve) => {
|
|
19655
19674
|
reader.onload = (e) => {
|
|
19656
19675
|
var _a;
|
|
19657
|
-
const dataUrl = (_a = e.target) == null ? void 0 : _a.result;
|
|
19658
|
-
fromDataURL(dataUrl);
|
|
19676
|
+
const dataUrl = String((_a = e.target) == null ? void 0 : _a.result);
|
|
19677
|
+
void fromDataURL(dataUrl);
|
|
19659
19678
|
_isEmpty.value = false;
|
|
19660
19679
|
sigData.value = dataUrl;
|
|
19661
19680
|
resolve(true);
|
|
@@ -19664,38 +19683,36 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
19664
19683
|
});
|
|
19665
19684
|
}
|
|
19666
19685
|
watch(fileData, (newFile) => {
|
|
19667
|
-
loadFile(newFile);
|
|
19668
|
-
});
|
|
19686
|
+
void loadFile(newFile);
|
|
19687
|
+
});
|
|
19688
|
+
function resizeCanvas() {
|
|
19689
|
+
let url;
|
|
19690
|
+
if (!isEmpty()) url = save2();
|
|
19691
|
+
const ratio = props2.ratio ?? 1 / 2;
|
|
19692
|
+
const { width } = vCanvas.value.getBoundingClientRect();
|
|
19693
|
+
vCanvas.value.width = props2.width ? Number(props2.width.replaceAll("px", "")) : width;
|
|
19694
|
+
vCanvas.value.height = props2.height ? Number(props2.height.replaceAll("px", "")) : width * ratio;
|
|
19695
|
+
clear();
|
|
19696
|
+
if (!props2.clearOnResize && url !== void 0) void fromDataURL(url);
|
|
19697
|
+
if (props2.waterMark) addWaterMark(props2.waterMark);
|
|
19698
|
+
}
|
|
19669
19699
|
function draw() {
|
|
19670
|
-
|
|
19671
|
-
|
|
19672
|
-
|
|
19673
|
-
let url;
|
|
19674
|
-
if (!isEmpty()) url = save2();
|
|
19675
|
-
const ratio = props2.ratio ?? 1 / 2;
|
|
19676
|
-
const { width } = c2.getBoundingClientRect();
|
|
19677
|
-
c2.width = props2.width ? Number(props2.width.replaceAll("px", "")) : width;
|
|
19678
|
-
c2.height = props2.height ? Number(props2.height.replaceAll("px", "")) : width * ratio;
|
|
19679
|
-
clear();
|
|
19680
|
-
if (!props2.clearOnResize && url !== void 0) fromDataURL(url);
|
|
19681
|
-
if (props2.waterMark) addWaterMark(props2.waterMark);
|
|
19682
|
-
}
|
|
19683
|
-
window.addEventListener("resize", () => {
|
|
19684
|
-
resizeCanvas(canvas);
|
|
19685
|
-
});
|
|
19686
|
-
resizeCanvas(canvas);
|
|
19700
|
+
sig.value = new SignaturePad(vCanvas.value, signatureOptions.value);
|
|
19701
|
+
window.addEventListener("resize", resizeCanvas);
|
|
19702
|
+
resizeCanvas();
|
|
19687
19703
|
if (props2.disabled) sig.value.off();
|
|
19688
19704
|
else sig.value.on();
|
|
19689
19705
|
_isEmpty.value = sig.value.isEmpty();
|
|
19690
19706
|
sig.value.addEventListener("endStroke", onEndStroke);
|
|
19691
19707
|
if (fileData.value) {
|
|
19692
|
-
loadFile(fileData.value);
|
|
19708
|
+
void loadFile(fileData.value);
|
|
19693
19709
|
}
|
|
19694
19710
|
}
|
|
19695
19711
|
onMounted(draw);
|
|
19696
19712
|
onUnmounted(() => {
|
|
19697
19713
|
var _a;
|
|
19698
19714
|
(_a = sig.value) == null ? void 0 : _a.removeEventListener("endStroke", onEndStroke);
|
|
19715
|
+
window.removeEventListener("resize", resizeCanvas);
|
|
19699
19716
|
});
|
|
19700
19717
|
__expose({
|
|
19701
19718
|
save: save2,
|
|
@@ -19708,7 +19725,7 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
19708
19725
|
return (_ctx, _cache) => {
|
|
19709
19726
|
return openBlock(), createElementBlock("div", {
|
|
19710
19727
|
class: normalizeClass(["bgl_input signature-pad relative", { "bg-transparent": _ctx.disabled }]),
|
|
19711
|
-
onTouchmove: _cache[
|
|
19728
|
+
onTouchmove: _cache[1] || (_cache[1] = withModifiers(() => {
|
|
19712
19729
|
}, ["prevent"]))
|
|
19713
19730
|
}, [
|
|
19714
19731
|
_ctx.clearable && !_ctx.disabled ? (openBlock(), createBlock(unref(Btn), {
|
|
@@ -19725,7 +19742,20 @@ const _sfc_main$B = /* @__PURE__ */ defineComponent({
|
|
|
19725
19742
|
class: "canvas",
|
|
19726
19743
|
disabled: _ctx.disabled
|
|
19727
19744
|
}, null, 8, _hoisted_1$u),
|
|
19728
|
-
|
|
19745
|
+
createElementVNode("input", {
|
|
19746
|
+
ref_key: "requiredInput",
|
|
19747
|
+
ref: requiredInput,
|
|
19748
|
+
placeholder: "required",
|
|
19749
|
+
type: "text",
|
|
19750
|
+
required: _ctx.required && unref(_isEmpty),
|
|
19751
|
+
class: "pixel opacity-0",
|
|
19752
|
+
tabindex: "-1",
|
|
19753
|
+
"aria-hidden": "true",
|
|
19754
|
+
onFocus: _cache[0] || (_cache[0] = (event) => {
|
|
19755
|
+
var _a, _b;
|
|
19756
|
+
return (_b = (_a = event.target) == null ? void 0 : _a.blur) == null ? void 0 : _b.call(_a);
|
|
19757
|
+
})
|
|
19758
|
+
}, null, 40, _hoisted_2$l)
|
|
19729
19759
|
], 34);
|
|
19730
19760
|
};
|
|
19731
19761
|
}
|
|
@@ -22353,7 +22383,8 @@ const _sfc_main$A = /* @__PURE__ */ defineComponent({
|
|
|
22353
22383
|
default: withCtx(() => _cache[1] || (_cache[1] = [
|
|
22354
22384
|
createTextVNode(" New ")
|
|
22355
22385
|
])),
|
|
22356
|
-
_: 1
|
|
22386
|
+
_: 1,
|
|
22387
|
+
__: [1]
|
|
22357
22388
|
})
|
|
22358
22389
|
], 8, _hoisted_1$t);
|
|
22359
22390
|
};
|
|
@@ -33588,7 +33619,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
33588
33619
|
_cache[30] || (_cache[30] = createElementVNode("u", null, "or click to select a file", -1)),
|
|
33589
33620
|
_cache[31] || (_cache[31] = createElementVNode("p", { class: "txt-12 color-gray" }, " Accepts .xlsx, .xls, and .csv files ", -1))
|
|
33590
33621
|
]),
|
|
33591
|
-
_: 1
|
|
33622
|
+
_: 1,
|
|
33623
|
+
__: [29, 30, 31]
|
|
33592
33624
|
})
|
|
33593
33625
|
]),
|
|
33594
33626
|
_: 1
|
|
@@ -33719,7 +33751,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
33719
33751
|
default: withCtx(() => _cache[34] || (_cache[34] = [
|
|
33720
33752
|
createTextVNode(" Preview Data ")
|
|
33721
33753
|
])),
|
|
33722
|
-
_: 1
|
|
33754
|
+
_: 1,
|
|
33755
|
+
__: [34]
|
|
33723
33756
|
})
|
|
33724
33757
|
])) : (openBlock(), createElementBlock("div", _hoisted_19, _cache[35] || (_cache[35] = [
|
|
33725
33758
|
createElementVNode("div", { class: "mapping-incomplete-message" }, " Please map the required fields to continue ", -1)
|
|
@@ -33855,7 +33888,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
33855
33888
|
_cache[40] || (_cache[40] = createElementVNode("p", null, "or click to select a file", -1)),
|
|
33856
33889
|
_cache[41] || (_cache[41] = createElementVNode("p", { class: "txt-12 color-gray" }, " Accepts .xlsx, .xls, and .csv files ", -1))
|
|
33857
33890
|
]),
|
|
33858
|
-
_: 1
|
|
33891
|
+
_: 1,
|
|
33892
|
+
__: [39, 40, 41]
|
|
33859
33893
|
})
|
|
33860
33894
|
]),
|
|
33861
33895
|
_: 1
|
|
@@ -33941,7 +33975,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
33941
33975
|
default: withCtx(() => _cache[42] || (_cache[42] = [
|
|
33942
33976
|
createTextVNode(" Transform ")
|
|
33943
33977
|
])),
|
|
33944
|
-
_: 2
|
|
33978
|
+
_: 2,
|
|
33979
|
+
__: [42]
|
|
33945
33980
|
}, 1032, ["onClick"])
|
|
33946
33981
|
])
|
|
33947
33982
|
])
|
|
@@ -34115,7 +34150,8 @@ ${unmatchedValues.length} values could not be automatically matched.`);
|
|
|
34115
34150
|
default: withCtx(() => _cache[48] || (_cache[48] = [
|
|
34116
34151
|
createTextVNode(" Close ")
|
|
34117
34152
|
])),
|
|
34118
|
-
_: 1
|
|
34153
|
+
_: 1,
|
|
34154
|
+
__: [48]
|
|
34119
34155
|
})
|
|
34120
34156
|
])
|
|
34121
34157
|
])) : createCommentVNode("", true)
|
|
@@ -34283,7 +34319,8 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
|
34283
34319
|
_cache[0] || (_cache[0] = createElementVNode("div", { style: { "flex-grow": "1" } }, null, -1)),
|
|
34284
34320
|
renderSlot(_ctx.$slots, "footer", {}, void 0, true)
|
|
34285
34321
|
]),
|
|
34286
|
-
_: 3
|
|
34322
|
+
_: 3,
|
|
34323
|
+
__: [0]
|
|
34287
34324
|
})
|
|
34288
34325
|
], 2);
|
|
34289
34326
|
};
|
|
@@ -34670,7 +34707,8 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
34670
34707
|
}, null, 8, _hoisted_5$5)) : createCommentVNode("", true)
|
|
34671
34708
|
])
|
|
34672
34709
|
]),
|
|
34673
|
-
_: 3
|
|
34710
|
+
_: 3,
|
|
34711
|
+
__: [0]
|
|
34674
34712
|
}, 16, ["class", "onClick"])), [
|
|
34675
34713
|
[_directive_ripple, isClickable.value]
|
|
34676
34714
|
]);
|
package/dist/style.css
CHANGED
|
@@ -1362,12 +1362,12 @@ fieldset[data-v-f7e758e5] {
|
|
|
1362
1362
|
box-shadow: inset 0 0 0px 2px white;
|
|
1363
1363
|
}
|
|
1364
1364
|
|
|
1365
|
-
.bgl-checkbox[data-v-
|
|
1365
|
+
.bgl-checkbox[data-v-1c41dd4f] {
|
|
1366
1366
|
flex-direction: row;
|
|
1367
1367
|
cursor: pointer;
|
|
1368
1368
|
align-items: flex-start;
|
|
1369
1369
|
}
|
|
1370
|
-
.bgl-checkbox input[type='checkbox'][data-v-
|
|
1370
|
+
.bgl-checkbox input[type='checkbox'][data-v-1c41dd4f] {
|
|
1371
1371
|
accent-color: var(--bgl-accent-color);
|
|
1372
1372
|
height: calc(var(--input-height) / 2.75);
|
|
1373
1373
|
width: calc(var(--input-height) / 2.75);
|
|
@@ -1377,7 +1377,7 @@ fieldset[data-v-f7e758e5] {
|
|
|
1377
1377
|
align-items: center;
|
|
1378
1378
|
flex-shrink: 0;
|
|
1379
1379
|
}
|
|
1380
|
-
.bgl-checkbox input[type='checkbox'][data-v-
|
|
1380
|
+
.bgl-checkbox input[type='checkbox'][data-v-1c41dd4f]::before {
|
|
1381
1381
|
content: '';
|
|
1382
1382
|
height: calc(var(--input-height) / 2.75);
|
|
1383
1383
|
width: calc(var(--input-height) / 2.75);
|
|
@@ -1387,23 +1387,23 @@ fieldset[data-v-f7e758e5] {
|
|
|
1387
1387
|
transition: all 200ms ease;
|
|
1388
1388
|
position: absolute;
|
|
1389
1389
|
}
|
|
1390
|
-
.bgl-checkbox input[type='checkbox'][data-v-
|
|
1390
|
+
.bgl-checkbox input[type='checkbox'][data-v-1c41dd4f]:hover::before {
|
|
1391
1391
|
opacity: 0.2;
|
|
1392
1392
|
transform: scale(2);
|
|
1393
1393
|
}
|
|
1394
|
-
.bgl-checkbox label[data-v-
|
|
1394
|
+
.bgl-checkbox label[data-v-1c41dd4f] {
|
|
1395
1395
|
cursor: pointer;
|
|
1396
1396
|
user-select: none;
|
|
1397
1397
|
font-size: var(--input-font-size);
|
|
1398
1398
|
transition: var(--bgl-transition-400);
|
|
1399
1399
|
}
|
|
1400
|
-
.bgl-checkbox:hover label[data-v-
|
|
1400
|
+
.bgl-checkbox:hover label[data-v-1c41dd4f] {
|
|
1401
1401
|
color: var(--bgl-primary) !important;
|
|
1402
1402
|
}
|
|
1403
|
-
.bgl-checkbox input:checked + label[data-v-
|
|
1403
|
+
.bgl-checkbox input:checked + label[data-v-1c41dd4f]{
|
|
1404
1404
|
color: var(--bgl-primary) !important;
|
|
1405
1405
|
}
|
|
1406
|
-
.bagel-input:focus-within.bgl-checkbox:not(:checked) label[data-v-
|
|
1406
|
+
.bagel-input:focus-within.bgl-checkbox:not(:checked) label[data-v-1c41dd4f] {
|
|
1407
1407
|
color: var(--label-color) !important;
|
|
1408
1408
|
}
|
|
1409
1409
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bagelink/vue",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.4.
|
|
4
|
+
"version": "1.4.10",
|
|
5
5
|
"description": "Bagel core sdk packages",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Neveh Allon",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"@types/leaflet": "^1.9.17",
|
|
60
60
|
"@types/signature_pad": "^4.0.0",
|
|
61
61
|
"@vue-macros/reactivity-transform": "^1.1.6",
|
|
62
|
-
"vue": "^3.5.
|
|
62
|
+
"vue": "^3.5.14",
|
|
63
63
|
"vue-component-type-helpers": "^2.2.10"
|
|
64
64
|
},
|
|
65
65
|
"peerDependencies": {
|
|
@@ -7,6 +7,7 @@ const { defaultValue = false, id } = defineProps<{
|
|
|
7
7
|
title?: string
|
|
8
8
|
small?: boolean
|
|
9
9
|
required?: boolean
|
|
10
|
+
disabled?: boolean
|
|
10
11
|
defaultValue?: T
|
|
11
12
|
value?: any
|
|
12
13
|
}>()
|
|
@@ -29,6 +30,7 @@ onMounted(() => {
|
|
|
29
30
|
<input
|
|
30
31
|
:id="inputId + value"
|
|
31
32
|
v-model="checked"
|
|
33
|
+
:disabled="disabled"
|
|
32
34
|
:value
|
|
33
35
|
:required
|
|
34
36
|
type="checkbox"
|
|
@@ -367,9 +367,9 @@ export function createCommandRegistry(state: EditorState): CommandRegistry {
|
|
|
367
367
|
|
|
368
368
|
// Media commands
|
|
369
369
|
const mediaCommands = {
|
|
370
|
-
image: createCommand('Insert Image', state => state.modal && insertImage(state.modal, state)),
|
|
370
|
+
image: createCommand('Insert Image', (state) => { state.modal && insertImage(state.modal, state) }),
|
|
371
371
|
link: createCommand('Insert Link', state => state.modal && state.range && insertLink(state.modal, state)),
|
|
372
|
-
embed: createCommand('Insert Embed', state => state.modal && insertEmbed(state.modal, state))
|
|
372
|
+
embed: createCommand('Insert Embed', (state) => { state.modal && insertEmbed(state.modal, state) })
|
|
373
373
|
}
|
|
374
374
|
|
|
375
375
|
// Other formatting commands
|
|
@@ -38,6 +38,7 @@ const sigData = defineModel()
|
|
|
38
38
|
const fileData = defineModel<File>('file')
|
|
39
39
|
|
|
40
40
|
const vCanvas = $ref<HTMLCanvasElement>()
|
|
41
|
+
const requiredInput = $ref<HTMLInputElement>()
|
|
41
42
|
|
|
42
43
|
let sig = $ref<SignaturePad>()
|
|
43
44
|
|
|
@@ -62,24 +63,37 @@ function saveFile() {
|
|
|
62
63
|
// For SVG, create file directly from the SVG string
|
|
63
64
|
fileData.value = new File([data], 'signature.svg', { type: 'image/svg+xml' })
|
|
64
65
|
} else {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
66
|
+
try {
|
|
67
|
+
// For PNG/JPG, convert base64 to blob first
|
|
68
|
+
const base64Data = data.split(',')[1]
|
|
69
|
+
if (!base64Data) throw new Error('Invalid data URL format')
|
|
70
|
+
|
|
71
|
+
const byteCharacters = atob(base64Data)
|
|
72
|
+
// Create byte array directly with mapping function
|
|
73
|
+
const byteArray = new Uint8Array(
|
|
74
|
+
Array.from(byteCharacters, char => char.charCodeAt(0))
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
const mimeType = props.format || 'image/png'
|
|
78
|
+
const blob = new Blob([byteArray], { type: mimeType })
|
|
79
|
+
const extension = mimeType.split('/')[1]
|
|
80
|
+
|
|
81
|
+
fileData.value = new File([blob], `signature.${extension}`, { type: mimeType })
|
|
82
|
+
} catch (error) {
|
|
83
|
+
console.error('Error saving signature file:', error)
|
|
72
84
|
}
|
|
73
|
-
|
|
74
|
-
const byteArray = new Uint8Array(byteNumbers)
|
|
75
|
-
const blob = new Blob([byteArray], { type: props.format || 'image/png' })
|
|
76
|
-
|
|
77
|
-
const extension = (props.format || 'image/png').split('/')[1]
|
|
78
|
-
fileData.value = new File([blob], `signature.${extension}`, { type: props.format || 'image/png' })
|
|
79
85
|
}
|
|
80
86
|
}
|
|
81
87
|
|
|
82
|
-
|
|
88
|
+
function fromDataURL(url: string) {
|
|
89
|
+
return sig?.fromDataURL(url, {
|
|
90
|
+
height: vCanvas?.height,
|
|
91
|
+
width: vCanvas?.width,
|
|
92
|
+
ratio: props.ratio,
|
|
93
|
+
xOffset: 0,
|
|
94
|
+
yOffset: 0,
|
|
95
|
+
})
|
|
96
|
+
}
|
|
83
97
|
|
|
84
98
|
const isEmpty = () => sig?.isEmpty()
|
|
85
99
|
function undo() {
|
|
@@ -140,13 +154,13 @@ function onEndStroke() {
|
|
|
140
154
|
saveFile()
|
|
141
155
|
}
|
|
142
156
|
|
|
143
|
-
|
|
157
|
+
function loadFile(file: File | undefined) {
|
|
144
158
|
if (!file) return
|
|
145
159
|
const reader = new FileReader()
|
|
146
160
|
return new Promise((resolve) => {
|
|
147
161
|
reader.onload = (e) => {
|
|
148
|
-
const dataUrl = e.target?.result
|
|
149
|
-
fromDataURL(dataUrl)
|
|
162
|
+
const dataUrl = String(e.target?.result)
|
|
163
|
+
void fromDataURL(dataUrl)
|
|
150
164
|
_isEmpty = false
|
|
151
165
|
sigData.value = dataUrl
|
|
152
166
|
resolve(true)
|
|
@@ -156,25 +170,25 @@ async function loadFile(file: File | undefined) {
|
|
|
156
170
|
}
|
|
157
171
|
|
|
158
172
|
watch(fileData, (newFile) => {
|
|
159
|
-
loadFile(newFile)
|
|
173
|
+
void loadFile(newFile)
|
|
160
174
|
})
|
|
161
175
|
|
|
176
|
+
function resizeCanvas() {
|
|
177
|
+
let url
|
|
178
|
+
if (!isEmpty()) url = save()
|
|
179
|
+
const ratio = props.ratio ?? 1 / 2
|
|
180
|
+
const { width } = vCanvas!.getBoundingClientRect()
|
|
181
|
+
vCanvas!.width = props.width ? Number(props.width.replaceAll('px', '')) : width
|
|
182
|
+
vCanvas!.height = props.height ? Number(props.height.replaceAll('px', '')) : width * ratio
|
|
183
|
+
clear()
|
|
184
|
+
if (!props.clearOnResize && url !== undefined) void fromDataURL(url)
|
|
185
|
+
if (props.waterMark) addWaterMark(props.waterMark)
|
|
186
|
+
}
|
|
187
|
+
|
|
162
188
|
function draw() {
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
let url
|
|
167
|
-
if (!isEmpty()) url = save()
|
|
168
|
-
const ratio = props.ratio ?? 1 / 2
|
|
169
|
-
const { width } = c.getBoundingClientRect()
|
|
170
|
-
c.width = props.width ? Number(props.width.replaceAll('px', '')) : width
|
|
171
|
-
c.height = props.height ? Number(props.height.replaceAll('px', '')) : width * ratio
|
|
172
|
-
clear()
|
|
173
|
-
if (!props.clearOnResize && url !== undefined) fromDataURL(url)
|
|
174
|
-
if (props.waterMark) addWaterMark(props.waterMark)
|
|
175
|
-
}
|
|
176
|
-
window.addEventListener('resize', () => { resizeCanvas(canvas) })
|
|
177
|
-
resizeCanvas(canvas)
|
|
189
|
+
sig = new SignaturePad(vCanvas!, signatureOptions)
|
|
190
|
+
window.addEventListener('resize', resizeCanvas)
|
|
191
|
+
resizeCanvas()
|
|
178
192
|
if (props.disabled) sig.off()
|
|
179
193
|
else sig.on()
|
|
180
194
|
_isEmpty = sig.isEmpty()
|
|
@@ -182,13 +196,14 @@ function draw() {
|
|
|
182
196
|
|
|
183
197
|
// Load initial file if provided
|
|
184
198
|
if (fileData.value) {
|
|
185
|
-
loadFile(fileData.value)
|
|
199
|
+
void loadFile(fileData.value)
|
|
186
200
|
}
|
|
187
201
|
}
|
|
188
202
|
|
|
189
203
|
onMounted(draw)
|
|
190
204
|
onUnmounted(() => {
|
|
191
205
|
sig?.removeEventListener('endStroke', onEndStroke)
|
|
206
|
+
window.removeEventListener('resize', resizeCanvas)
|
|
192
207
|
})
|
|
193
208
|
|
|
194
209
|
defineExpose({
|
|
@@ -202,10 +217,40 @@ defineExpose({
|
|
|
202
217
|
</script>
|
|
203
218
|
|
|
204
219
|
<template>
|
|
205
|
-
<div
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
220
|
+
<div
|
|
221
|
+
class="bgl_input signature-pad relative"
|
|
222
|
+
:class="{ 'bg-transparent': disabled }"
|
|
223
|
+
@touchmove.prevent
|
|
224
|
+
>
|
|
225
|
+
<Btn
|
|
226
|
+
v-if="clearable && !disabled"
|
|
227
|
+
flat
|
|
228
|
+
thin
|
|
229
|
+
icon="refresh"
|
|
230
|
+
class="position-bottom-end"
|
|
231
|
+
@click="clear"
|
|
232
|
+
/>
|
|
233
|
+
<canvas
|
|
234
|
+
ref="vCanvas"
|
|
235
|
+
class="canvas"
|
|
236
|
+
:disabled
|
|
237
|
+
/>
|
|
238
|
+
<input
|
|
239
|
+
ref="requiredInput"
|
|
240
|
+
placeholder="required"
|
|
241
|
+
type="text"
|
|
242
|
+
:required="required && _isEmpty"
|
|
243
|
+
class="pixel opacity-0"
|
|
244
|
+
tabindex="-1"
|
|
245
|
+
aria-hidden="true"
|
|
246
|
+
@focus="event => (event.target as any)?.blur?.()"
|
|
247
|
+
>
|
|
248
|
+
<!--
|
|
249
|
+
we add a hidden input to make the signature pad required
|
|
250
|
+
we need to set the tabindex to -1 and aria-hidden to true
|
|
251
|
+
to make it not focusable and not visible to screen readers
|
|
252
|
+
! most importantally this prevents the keyboard from opening on mobile
|
|
253
|
+
-->
|
|
209
254
|
</div>
|
|
210
255
|
</template>
|
|
211
256
|
|