@factoringplus/pl-components-pack-v3 0.3.76 → 0.3.78
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/pl-components-pack-v3.es.js +75 -32
- package/dist/pl-components-pack-v3.umd.js +21 -21
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -24504,18 +24504,6 @@ const _sfc_main$u = {
|
|
|
24504
24504
|
minLength: {
|
|
24505
24505
|
type: Number
|
|
24506
24506
|
},
|
|
24507
|
-
formater: {
|
|
24508
|
-
type: Function,
|
|
24509
|
-
default: function(value) {
|
|
24510
|
-
return value;
|
|
24511
|
-
}
|
|
24512
|
-
},
|
|
24513
|
-
parcer: {
|
|
24514
|
-
type: Function,
|
|
24515
|
-
default: (value) => {
|
|
24516
|
-
return value;
|
|
24517
|
-
}
|
|
24518
|
-
},
|
|
24519
24507
|
isError: {
|
|
24520
24508
|
type: Boolean,
|
|
24521
24509
|
default: false
|
|
@@ -24534,7 +24522,7 @@ const _sfc_main$u = {
|
|
|
24534
24522
|
},
|
|
24535
24523
|
type: {
|
|
24536
24524
|
type: String,
|
|
24537
|
-
default: "
|
|
24525
|
+
default: "number"
|
|
24538
24526
|
},
|
|
24539
24527
|
label: {
|
|
24540
24528
|
type: String,
|
|
@@ -24567,8 +24555,23 @@ const _sfc_main$u = {
|
|
|
24567
24555
|
ruleForm[props2.prop] = newValue;
|
|
24568
24556
|
});
|
|
24569
24557
|
const updateValue = (value) => {
|
|
24558
|
+
if (props2.type === "number") {
|
|
24559
|
+
if (!isNaN(value) && !value.includes("."))
|
|
24560
|
+
emit2("update:modelValue", value);
|
|
24561
|
+
return;
|
|
24562
|
+
}
|
|
24570
24563
|
emit2("update:modelValue", value);
|
|
24571
24564
|
};
|
|
24565
|
+
const getTypeInput = () => {
|
|
24566
|
+
switch (props2.type) {
|
|
24567
|
+
case "text":
|
|
24568
|
+
return "text";
|
|
24569
|
+
case "textarea":
|
|
24570
|
+
return "textarea";
|
|
24571
|
+
case "number":
|
|
24572
|
+
return "text";
|
|
24573
|
+
}
|
|
24574
|
+
};
|
|
24572
24575
|
const clearValue = () => {
|
|
24573
24576
|
emit2("update:modelValue", "");
|
|
24574
24577
|
};
|
|
@@ -24602,7 +24605,7 @@ const _sfc_main$u = {
|
|
|
24602
24605
|
alt: "user",
|
|
24603
24606
|
src: _imports_1$3
|
|
24604
24607
|
}, null, 2)) : createCommentVNode("", true),
|
|
24605
|
-
props2.clearable
|
|
24608
|
+
props2.clearable ? (openBlock(), createElementBlock("img", {
|
|
24606
24609
|
key: 2,
|
|
24607
24610
|
onClick: clearValue,
|
|
24608
24611
|
class: normalizeClass(["clearBtn", [!__props.label && !__props.icon ? "clearNoLabel" : ""]]),
|
|
@@ -24624,20 +24627,18 @@ const _sfc_main$u = {
|
|
|
24624
24627
|
default: withCtx(() => [
|
|
24625
24628
|
createVNode(_component_el_input, {
|
|
24626
24629
|
class: normalizeClass({ padding: props2.prefix }),
|
|
24627
|
-
formatter: (value) => __props.formater(value),
|
|
24628
|
-
parser: (value) => __props.parcer(value),
|
|
24629
24630
|
minlength: __props.minLength,
|
|
24630
24631
|
maxlength: __props.maxLength,
|
|
24631
24632
|
disabled: props2.disabled,
|
|
24632
24633
|
placeholder: props2.placeholder,
|
|
24633
24634
|
modelValue: unref(modelValue),
|
|
24634
24635
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(modelValue) ? modelValue.value = $event : modelValue = $event),
|
|
24635
|
-
type:
|
|
24636
|
+
type: getTypeInput(),
|
|
24636
24637
|
resize: "none",
|
|
24637
24638
|
autosize: { minRows: 3, maxRows: 6 },
|
|
24638
24639
|
clearable: props2.clearable && _ctx.area,
|
|
24639
24640
|
onInput: updateValue
|
|
24640
|
-
}, null, 8, ["class", "
|
|
24641
|
+
}, null, 8, ["class", "minlength", "maxlength", "disabled", "placeholder", "modelValue", "type", "clearable"])
|
|
24641
24642
|
]),
|
|
24642
24643
|
_: 1
|
|
24643
24644
|
}, 8, ["class", "label", "prop"])
|
|
@@ -40264,14 +40265,14 @@ const _sfc_main$h = {
|
|
|
40264
40265
|
(openBlock(), createElementBlock(Fragment, null, renderList(tabs2, (item) => {
|
|
40265
40266
|
return createElementVNode("div", {
|
|
40266
40267
|
key: item.label,
|
|
40267
|
-
class: normalizeClass(["p-12 ps-3 pe-3 rounded-8 disable-color fw-500", [selected.value === item.label ? "active-tab" : ""]])
|
|
40268
|
+
class: normalizeClass(["p-12 ps-3 pe-3 rounded-8 disable-color pointer fw-500", [selected.value === item.label ? "active-tab" : ""]])
|
|
40268
40269
|
}, [
|
|
40269
40270
|
createElementVNode("div", {
|
|
40270
40271
|
onClick: ($event) => {
|
|
40271
40272
|
selected.value = item.label;
|
|
40272
40273
|
item.checked = !item.checked;
|
|
40273
40274
|
},
|
|
40274
|
-
class: "d-flex justify-content-between align-items-center
|
|
40275
|
+
class: "d-flex justify-content-between align-items-center"
|
|
40275
40276
|
}, [
|
|
40276
40277
|
createElementVNode("span", null, toDisplayString(item.value), 1),
|
|
40277
40278
|
createVNode(_sfc_main$i, {
|
|
@@ -40318,12 +40319,12 @@ const _hoisted_1$f = {
|
|
|
40318
40319
|
id: "dialogForm",
|
|
40319
40320
|
class: "container d-flex flex-column p-3 justify-content-center"
|
|
40320
40321
|
};
|
|
40321
|
-
const _hoisted_2$d = /* @__PURE__ */ createElementVNode("div", { class: "d-flex align-items-start" }, [
|
|
40322
|
+
const _hoisted_2$d = /* @__PURE__ */ createElementVNode("div", { class: "d-flex align-items-start gap-12" }, [
|
|
40322
40323
|
/* @__PURE__ */ createElementVNode("img", {
|
|
40323
40324
|
src: _imports_0$4,
|
|
40324
40325
|
alt: "notification"
|
|
40325
40326
|
}),
|
|
40326
|
-
/* @__PURE__ */ createElementVNode("div", { class: "text default-text
|
|
40327
|
+
/* @__PURE__ */ createElementVNode("div", { class: "text default-text" }, [
|
|
40327
40328
|
/* @__PURE__ */ createTextVNode(" \u041C\u044B "),
|
|
40328
40329
|
/* @__PURE__ */ createElementVNode("span", { class: "fw-bold" }, "\u0437\u0430\u043F\u043E\u043B\u043D\u0438\u043B\u0438"),
|
|
40329
40330
|
/* @__PURE__ */ createTextVNode(" \u0437\u0430 \u0432\u0430\u0441 \u0447\u0430\u0441\u0442\u044C \u0434\u0430\u043D\u043D\u044B\u0445, \u0432\u0437\u044F\u0442\u044B\u0445 \u0438\u0437 \u043E\u0442\u043A\u0440\u044B\u0442\u044B\u0445 \u0438\u0441\u0442\u043E\u0447\u043D\u0438\u043A\u043E\u0432. ")
|
|
@@ -40560,9 +40561,10 @@ const _sfc_main$c = {
|
|
|
40560
40561
|
_: 1
|
|
40561
40562
|
}, 8, ["label"])
|
|
40562
40563
|
]),
|
|
40563
|
-
|
|
40564
|
+
props2.helper ? (openBlock(), createElementBlock("p", {
|
|
40565
|
+
key: 4,
|
|
40564
40566
|
class: normalizeClass({ isError: !props2.isError })
|
|
40565
|
-
}, toDisplayString(props2.helper), 3)
|
|
40567
|
+
}, toDisplayString(props2.helper), 3)) : createCommentVNode("", true)
|
|
40566
40568
|
]);
|
|
40567
40569
|
};
|
|
40568
40570
|
}
|
|
@@ -40613,7 +40615,7 @@ const _hoisted_1$a = {
|
|
|
40613
40615
|
class: "container general-form"
|
|
40614
40616
|
};
|
|
40615
40617
|
const _hoisted_2$9 = /* @__PURE__ */ createElementVNode("h3", { class: "title-text mb-32" }, "\u041E\u0431\u0449\u0438\u0435 \u0441\u0432\u0435\u0434\u0435\u043D\u0438\u044F", -1);
|
|
40616
|
-
const _hoisted_3$9 = { class: "d-flex justify-content-between mt-32 mb-
|
|
40618
|
+
const _hoisted_3$9 = { class: "d-flex justify-content-between mt-32 mb-32" };
|
|
40617
40619
|
const _sfc_main$a = {
|
|
40618
40620
|
__name: "pl-form-general",
|
|
40619
40621
|
props: {
|
|
@@ -40665,7 +40667,7 @@ const _sfc_main$a = {
|
|
|
40665
40667
|
disabled: true,
|
|
40666
40668
|
modelValue: unref(formClient).inn,
|
|
40667
40669
|
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => unref(formClient).inn = $event),
|
|
40668
|
-
label: "\
|
|
40670
|
+
label: "\u0418\u041D\u041D"
|
|
40669
40671
|
}, null, 8, ["modelValue"])
|
|
40670
40672
|
]),
|
|
40671
40673
|
createVNode(_sfc_main$c, {
|
|
@@ -42332,6 +42334,20 @@ const _sfc_main$2 = {
|
|
|
42332
42334
|
type: String,
|
|
42333
42335
|
default: ""
|
|
42334
42336
|
},
|
|
42337
|
+
rules: {
|
|
42338
|
+
type: Object,
|
|
42339
|
+
default: function() {
|
|
42340
|
+
return {};
|
|
42341
|
+
}
|
|
42342
|
+
},
|
|
42343
|
+
prop: {
|
|
42344
|
+
type: String,
|
|
42345
|
+
default: "name"
|
|
42346
|
+
},
|
|
42347
|
+
isError: {
|
|
42348
|
+
type: Boolean,
|
|
42349
|
+
default: false
|
|
42350
|
+
},
|
|
42335
42351
|
label: {
|
|
42336
42352
|
type: String,
|
|
42337
42353
|
default: ""
|
|
@@ -42349,12 +42365,33 @@ const _sfc_main$2 = {
|
|
|
42349
42365
|
default: true
|
|
42350
42366
|
}
|
|
42351
42367
|
},
|
|
42352
|
-
emits: ["update:modelValue"],
|
|
42368
|
+
emits: ["update:modelValue", "validate"],
|
|
42353
42369
|
setup(__props, { emit: emit2 }) {
|
|
42354
42370
|
const props2 = __props;
|
|
42355
42371
|
const selected = ref(false);
|
|
42372
|
+
const formSelect = ref();
|
|
42356
42373
|
let select2 = ref("");
|
|
42357
42374
|
select2.value = props2.modelValue;
|
|
42375
|
+
let { modelValue: validateValue } = toRefs(props2);
|
|
42376
|
+
const ruleForm = ref({
|
|
42377
|
+
[props2.prop]: validateValue
|
|
42378
|
+
});
|
|
42379
|
+
const validateInp = (prop, isValid2, message2) => {
|
|
42380
|
+
emit2("validate", prop, isValid2, message2);
|
|
42381
|
+
};
|
|
42382
|
+
const blurSelect = async () => {
|
|
42383
|
+
selected.value = false;
|
|
42384
|
+
setTimeout(() => {
|
|
42385
|
+
formSelect.value.validate((valid, fields) => {
|
|
42386
|
+
console.log(valid, fields);
|
|
42387
|
+
if (valid) {
|
|
42388
|
+
console.log("submit!");
|
|
42389
|
+
} else {
|
|
42390
|
+
console.log("error submit!", fields);
|
|
42391
|
+
}
|
|
42392
|
+
});
|
|
42393
|
+
}, 200);
|
|
42394
|
+
};
|
|
42358
42395
|
watch(select2, (value) => {
|
|
42359
42396
|
selected.value = false;
|
|
42360
42397
|
emit2("update:modelValue", value);
|
|
@@ -42366,13 +42403,19 @@ const _sfc_main$2 = {
|
|
|
42366
42403
|
const _component_el_form = ElForm;
|
|
42367
42404
|
return openBlock(), createElementBlock("div", _hoisted_1$2, [
|
|
42368
42405
|
createVNode(_component_el_form, {
|
|
42406
|
+
onValidate: validateInp,
|
|
42369
42407
|
"label-position": "top",
|
|
42370
|
-
|
|
42408
|
+
model: ruleForm.value,
|
|
42409
|
+
ref_key: "formSelect",
|
|
42410
|
+
ref: formSelect,
|
|
42411
|
+
rules: __props.rules
|
|
42371
42412
|
}, {
|
|
42372
42413
|
default: withCtx(() => [
|
|
42373
42414
|
createVNode(_component_el_form_item, {
|
|
42374
42415
|
label: __props.label,
|
|
42375
|
-
prop:
|
|
42416
|
+
prop: __props.prop,
|
|
42417
|
+
class: normalizeClass({ "is-error": __props.isError }),
|
|
42418
|
+
"show-message": true
|
|
42376
42419
|
}, {
|
|
42377
42420
|
default: withCtx(() => [
|
|
42378
42421
|
createElementVNode("img", {
|
|
@@ -42386,7 +42429,7 @@ const _sfc_main$2 = {
|
|
|
42386
42429
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(select2) ? select2.value = $event : select2 = $event),
|
|
42387
42430
|
placeholder: __props.placeholder,
|
|
42388
42431
|
onFocus: _cache[1] || (_cache[1] = ($event) => selected.value = true),
|
|
42389
|
-
onBlur:
|
|
42432
|
+
onBlur: blurSelect
|
|
42390
42433
|
}, {
|
|
42391
42434
|
default: withCtx(() => [
|
|
42392
42435
|
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.options, (item) => {
|
|
@@ -42410,10 +42453,10 @@ const _sfc_main$2 = {
|
|
|
42410
42453
|
}, 8, ["popper-class", "modelValue", "placeholder"])
|
|
42411
42454
|
]),
|
|
42412
42455
|
_: 1
|
|
42413
|
-
}, 8, ["label"])
|
|
42456
|
+
}, 8, ["label", "prop", "class"])
|
|
42414
42457
|
]),
|
|
42415
42458
|
_: 1
|
|
42416
|
-
},
|
|
42459
|
+
}, 8, ["model", "rules"])
|
|
42417
42460
|
]);
|
|
42418
42461
|
};
|
|
42419
42462
|
}
|