jky-component-lib 0.0.133 → 0.0.138
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/es/amap/style.css +5 -12
- package/dist/es/amap/style3.css +12 -5
- package/dist/es/form/FormItem.vue.js +60 -54
- package/dist/es/form/items/AutocompleteItem.vue.d.ts +1 -1
- package/dist/es/form/items/AutocompleteItem.vue.js +10 -3
- package/dist/es/form/items/CascaderItem.vue.d.ts +1 -1
- package/dist/es/form/items/CascaderItem.vue.js +10 -3
- package/dist/es/form/items/CheckboxGroupItem.vue.d.ts +3 -1
- package/dist/es/form/items/CheckboxGroupItem.vue.js +10 -3
- package/dist/es/form/items/ColorPickerItem.vue.d.ts +1 -1
- package/dist/es/form/items/ColorPickerItem.vue.js +10 -3
- package/dist/es/form/items/ColorPickerPanelItem.vue.d.ts +1 -1
- package/dist/es/form/items/ColorPickerPanelItem.vue.js +10 -3
- package/dist/es/form/items/DatePickerItem.vue.d.ts +1 -1
- package/dist/es/form/items/DatePickerItem.vue.js +10 -3
- package/dist/es/form/items/DividerItem.vue.d.ts +3 -1
- package/dist/es/form/items/DividerItem.vue.js +10 -3
- package/dist/es/form/items/FileUploadItem.vue.d.ts +1 -1
- package/dist/es/form/items/FileUploadItem.vue.js +10 -3
- package/dist/es/form/items/ImageUploadItem.vue.d.ts +1 -1
- package/dist/es/form/items/ImageUploadItem.vue.js +10 -3
- package/dist/es/form/items/InputItem.vue.d.ts +1 -1
- package/dist/es/form/items/InputItem.vue.js +11 -4
- package/dist/es/form/items/InputNumberItem.vue.d.ts +1 -1
- package/dist/es/form/items/InputNumberItem.vue.js +10 -3
- package/dist/es/form/items/InputTagItem.vue.d.ts +1 -1
- package/dist/es/form/items/InputTagItem.vue.js +10 -3
- package/dist/es/form/items/LinkedSelectItem.vue.d.ts +4 -1
- package/dist/es/form/items/LinkedSelectItem.vue.js +10 -3
- package/dist/es/form/items/MentionItem.vue.d.ts +1 -1
- package/dist/es/form/items/MentionItem.vue.js +10 -3
- package/dist/es/form/items/RadioGroupItem.vue.d.ts +3 -1
- package/dist/es/form/items/RadioGroupItem.vue.js +10 -3
- package/dist/es/form/items/RangeInputNumberItem.vue.d.ts +13 -0
- package/dist/es/form/items/RangeInputNumberItem.vue.js +116 -0
- package/dist/es/form/items/RangeInputNumberItem.vue2.js +4 -0
- package/dist/es/form/items/RateItem.vue.d.ts +1 -1
- package/dist/es/form/items/RateItem.vue.js +10 -3
- package/dist/es/form/items/SelectItem.vue.d.ts +1 -1
- package/dist/es/form/items/SelectItem.vue.js +10 -3
- package/dist/es/form/items/SelectTableItem.vue.d.ts +1 -1
- package/dist/es/form/items/SelectTableItem.vue.js +10 -3
- package/dist/es/form/items/SelectV2Item.vue.d.ts +1 -1
- package/dist/es/form/items/SelectV2Item.vue.js +10 -3
- package/dist/es/form/items/SliderItem.vue.d.ts +1 -1
- package/dist/es/form/items/SliderItem.vue.js +10 -3
- package/dist/es/form/items/SwitchItem.vue.d.ts +1 -1
- package/dist/es/form/items/SwitchItem.vue.js +10 -3
- package/dist/es/form/items/TextareaItem.vue.d.ts +1 -1
- package/dist/es/form/items/TextareaItem.vue.js +10 -3
- package/dist/es/form/items/TimePickerItem.vue.d.ts +1 -1
- package/dist/es/form/items/TimePickerItem.vue.js +10 -3
- package/dist/es/form/items/TimeSelectItem.vue.d.ts +1 -1
- package/dist/es/form/items/TimeSelectItem.vue.js +10 -3
- package/dist/es/form/items/TransferItem.vue.d.ts +1 -1
- package/dist/es/form/items/TransferItem.vue.js +10 -3
- package/dist/es/form/items/TreeSelectItem.vue.d.ts +1 -1
- package/dist/es/form/items/TreeSelectItem.vue.js +10 -3
- package/dist/es/modal/Footer.vue.d.ts +1 -1
- package/dist/es/modal/Footer.vue.js +4 -2
- package/dist/es/modal/Modal.vue.js +6 -3
- package/dist/es/package.json.js +1 -1
- package/dist/es/page-table/PageTable.vue.js +1 -1
- package/dist/es/page-table/PageTableColumn.vue.d.ts +1 -0
- package/dist/lib/amap/style.css +5 -12
- package/dist/lib/amap/style3.css +12 -5
- package/dist/lib/form/FormItem.vue.js +9 -3
- package/dist/lib/form/items/AutocompleteItem.vue.d.ts +1 -1
- package/dist/lib/form/items/AutocompleteItem.vue.js +9 -2
- package/dist/lib/form/items/CascaderItem.vue.d.ts +1 -1
- package/dist/lib/form/items/CascaderItem.vue.js +9 -2
- package/dist/lib/form/items/CheckboxGroupItem.vue.d.ts +3 -1
- package/dist/lib/form/items/CheckboxGroupItem.vue.js +9 -2
- package/dist/lib/form/items/ColorPickerItem.vue.d.ts +1 -1
- package/dist/lib/form/items/ColorPickerItem.vue.js +9 -2
- package/dist/lib/form/items/ColorPickerPanelItem.vue.d.ts +1 -1
- package/dist/lib/form/items/ColorPickerPanelItem.vue.js +9 -2
- package/dist/lib/form/items/DatePickerItem.vue.d.ts +1 -1
- package/dist/lib/form/items/DatePickerItem.vue.js +9 -2
- package/dist/lib/form/items/DividerItem.vue.d.ts +3 -1
- package/dist/lib/form/items/DividerItem.vue.js +9 -2
- package/dist/lib/form/items/FileUploadItem.vue.d.ts +1 -1
- package/dist/lib/form/items/FileUploadItem.vue.js +9 -2
- package/dist/lib/form/items/ImageUploadItem.vue.d.ts +1 -1
- package/dist/lib/form/items/ImageUploadItem.vue.js +9 -2
- package/dist/lib/form/items/InputItem.vue.d.ts +1 -1
- package/dist/lib/form/items/InputItem.vue.js +10 -3
- package/dist/lib/form/items/InputNumberItem.vue.d.ts +1 -1
- package/dist/lib/form/items/InputNumberItem.vue.js +9 -2
- package/dist/lib/form/items/InputTagItem.vue.d.ts +1 -1
- package/dist/lib/form/items/InputTagItem.vue.js +9 -2
- package/dist/lib/form/items/LinkedSelectItem.vue.d.ts +4 -1
- package/dist/lib/form/items/LinkedSelectItem.vue.js +9 -2
- package/dist/lib/form/items/MentionItem.vue.d.ts +1 -1
- package/dist/lib/form/items/MentionItem.vue.js +9 -2
- package/dist/lib/form/items/RadioGroupItem.vue.d.ts +3 -1
- package/dist/lib/form/items/RadioGroupItem.vue.js +9 -2
- package/dist/lib/form/items/RangeInputNumberItem.vue.d.ts +13 -0
- package/dist/lib/form/items/RangeInputNumberItem.vue.js +116 -0
- package/dist/lib/form/items/RangeInputNumberItem.vue2.js +4 -0
- package/dist/lib/form/items/RateItem.vue.d.ts +1 -1
- package/dist/lib/form/items/RateItem.vue.js +9 -2
- package/dist/lib/form/items/SelectItem.vue.d.ts +1 -1
- package/dist/lib/form/items/SelectItem.vue.js +9 -2
- package/dist/lib/form/items/SelectTableItem.vue.d.ts +1 -1
- package/dist/lib/form/items/SelectTableItem.vue.js +9 -2
- package/dist/lib/form/items/SelectV2Item.vue.d.ts +1 -1
- package/dist/lib/form/items/SelectV2Item.vue.js +9 -2
- package/dist/lib/form/items/SliderItem.vue.d.ts +1 -1
- package/dist/lib/form/items/SliderItem.vue.js +9 -2
- package/dist/lib/form/items/SwitchItem.vue.d.ts +1 -1
- package/dist/lib/form/items/SwitchItem.vue.js +9 -2
- package/dist/lib/form/items/TextareaItem.vue.d.ts +1 -1
- package/dist/lib/form/items/TextareaItem.vue.js +9 -2
- package/dist/lib/form/items/TimePickerItem.vue.d.ts +1 -1
- package/dist/lib/form/items/TimePickerItem.vue.js +9 -2
- package/dist/lib/form/items/TimeSelectItem.vue.d.ts +1 -1
- package/dist/lib/form/items/TimeSelectItem.vue.js +9 -2
- package/dist/lib/form/items/TransferItem.vue.d.ts +1 -1
- package/dist/lib/form/items/TransferItem.vue.js +9 -2
- package/dist/lib/form/items/TreeSelectItem.vue.d.ts +1 -1
- package/dist/lib/form/items/TreeSelectItem.vue.js +9 -2
- package/dist/lib/modal/Footer.vue.d.ts +1 -1
- package/dist/lib/modal/Footer.vue.js +4 -2
- package/dist/lib/modal/Modal.vue.js +6 -3
- package/dist/lib/package.json.js +1 -1
- package/dist/lib/page-table/PageTable.vue.js +1 -1
- package/dist/lib/page-table/PageTableColumn.vue.d.ts +1 -0
- package/package.json +3 -6
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, createSlots, withCtx, createVNode, createTextVNode, renderList, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
20
|
+
import { defineComponent, useSlots, computed, openBlock, createBlock, unref, mergeProps, createSlots, withCtx, createVNode, createTextVNode, renderList, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
21
21
|
import { ElUpload, ElButton } from "element-plus";
|
|
22
22
|
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
23
23
|
name: "JkyFormItemFileUpload"
|
|
@@ -34,6 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
34
34
|
setup(__props, { emit: __emit }) {
|
|
35
35
|
const props = __props;
|
|
36
36
|
const emit = __emit;
|
|
37
|
+
const slots = useSlots();
|
|
37
38
|
const uploadProps = computed(() => {
|
|
38
39
|
var _a, _b;
|
|
39
40
|
return __spreadProps(__spreadValues({}, props.componentProps), {
|
|
@@ -44,6 +45,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
44
45
|
});
|
|
45
46
|
});
|
|
46
47
|
const listType = computed(() => props.componentProps.listType || "text");
|
|
48
|
+
function getSlotNames() {
|
|
49
|
+
return Object.keys(slots);
|
|
50
|
+
}
|
|
51
|
+
function getComponentSlotNames() {
|
|
52
|
+
return Object.keys(props.componentSlots || {});
|
|
53
|
+
}
|
|
47
54
|
return (_ctx, _cache) => {
|
|
48
55
|
return openBlock(), createBlock(unref(ElUpload), mergeProps(uploadProps.value, {
|
|
49
56
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:modelValue", $event))
|
|
@@ -60,7 +67,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
60
67
|
]),
|
|
61
68
|
key: "0"
|
|
62
69
|
} : void 0,
|
|
63
|
-
renderList(
|
|
70
|
+
renderList(getSlotNames(), (name) => {
|
|
64
71
|
return {
|
|
65
72
|
name,
|
|
66
73
|
fn: withCtx((slotData) => [
|
|
@@ -68,7 +75,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
68
75
|
])
|
|
69
76
|
};
|
|
70
77
|
}),
|
|
71
|
-
renderList(
|
|
78
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
72
79
|
return {
|
|
73
80
|
name,
|
|
74
81
|
fn: withCtx((slotData) => [
|
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, createSlots, withCtx, createElementVNode, createVNode, createTextVNode, renderList, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
20
|
+
import { defineComponent, useSlots, computed, openBlock, createBlock, unref, mergeProps, createSlots, withCtx, createElementVNode, createVNode, createTextVNode, renderList, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
21
21
|
import { Plus } from "@element-plus/icons-vue";
|
|
22
22
|
import { ElUpload, ElIcon, ElButton } from "element-plus";
|
|
23
23
|
const _hoisted_1 = { class: "el-upload__picture-card-wrapper" };
|
|
@@ -36,6 +36,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
36
36
|
setup(__props, { emit: __emit }) {
|
|
37
37
|
const props = __props;
|
|
38
38
|
const emit = __emit;
|
|
39
|
+
const slots = useSlots();
|
|
39
40
|
const uploadProps = computed(() => {
|
|
40
41
|
var _a, _b;
|
|
41
42
|
return __spreadProps(__spreadValues({}, props.componentProps), {
|
|
@@ -46,6 +47,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
46
47
|
});
|
|
47
48
|
});
|
|
48
49
|
const listType = computed(() => props.componentProps.listType || "picture-card");
|
|
50
|
+
function getSlotNames() {
|
|
51
|
+
return Object.keys(slots);
|
|
52
|
+
}
|
|
53
|
+
function getComponentSlotNames() {
|
|
54
|
+
return Object.keys(props.componentSlots || {});
|
|
55
|
+
}
|
|
49
56
|
return (_ctx, _cache) => {
|
|
50
57
|
return openBlock(), createBlock(unref(ElUpload), mergeProps(uploadProps.value, {
|
|
51
58
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:modelValue", $event))
|
|
@@ -75,7 +82,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
75
82
|
]),
|
|
76
83
|
key: "1"
|
|
77
84
|
} : void 0,
|
|
78
|
-
renderList(
|
|
85
|
+
renderList(getSlotNames(), (name) => {
|
|
79
86
|
return {
|
|
80
87
|
name,
|
|
81
88
|
fn: withCtx((slotData) => [
|
|
@@ -83,7 +90,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
83
90
|
])
|
|
84
91
|
};
|
|
85
92
|
}),
|
|
86
|
-
renderList(
|
|
93
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
87
94
|
return {
|
|
88
95
|
name,
|
|
89
96
|
fn: withCtx((slotData) => [
|
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot,
|
|
20
|
+
import { defineComponent, useSlots, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
21
21
|
import { ElInput } from "element-plus";
|
|
22
22
|
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
23
23
|
name: "JkyFormItemInput"
|
|
@@ -34,6 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
34
34
|
setup(__props, { emit: __emit }) {
|
|
35
35
|
const props = __props;
|
|
36
36
|
const emit = __emit;
|
|
37
|
+
const slots = useSlots();
|
|
37
38
|
const inputProps = computed(() => {
|
|
38
39
|
var _a, _b, _c;
|
|
39
40
|
return __spreadProps(__spreadValues({}, props.componentProps), {
|
|
@@ -45,19 +46,25 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
45
46
|
class: ["w-full min-w-25", (_c = props.componentProps) == null ? void 0 : _c.class]
|
|
46
47
|
});
|
|
47
48
|
});
|
|
49
|
+
function getSlotNames() {
|
|
50
|
+
return Object.keys(slots);
|
|
51
|
+
}
|
|
52
|
+
function getComponentSlotNames() {
|
|
53
|
+
return Object.keys(props.componentSlots || {});
|
|
54
|
+
}
|
|
48
55
|
return (_ctx, _cache) => {
|
|
49
56
|
return openBlock(), createBlock(unref(ElInput), mergeProps(inputProps.value, {
|
|
50
57
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:modelValue", $event))
|
|
51
58
|
}), createSlots({ _: 2 }, [
|
|
52
|
-
renderList(
|
|
59
|
+
renderList(getSlotNames(), (name) => {
|
|
53
60
|
return {
|
|
54
61
|
name,
|
|
55
62
|
fn: withCtx((slotData) => [
|
|
56
|
-
renderSlot(_ctx.$slots, name,
|
|
63
|
+
renderSlot(_ctx.$slots, name, normalizeProps(guardReactiveProps(slotData || {})))
|
|
57
64
|
])
|
|
58
65
|
};
|
|
59
66
|
}),
|
|
60
|
-
renderList(
|
|
67
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
61
68
|
return {
|
|
62
69
|
name,
|
|
63
70
|
fn: withCtx((slotData) => [
|
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
20
|
+
import { defineComponent, useSlots, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
21
21
|
import { ElInputNumber } from "element-plus";
|
|
22
22
|
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
23
23
|
name: "JkyFormItemInputNumber"
|
|
@@ -34,6 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
34
34
|
setup(__props, { emit: __emit }) {
|
|
35
35
|
const props = __props;
|
|
36
36
|
const emit = __emit;
|
|
37
|
+
const slots = useSlots();
|
|
37
38
|
const numberModelValue = computed(() => {
|
|
38
39
|
const val = props.modelValue;
|
|
39
40
|
return val === "" || val === null || val === void 0 ? null : Number(val);
|
|
@@ -46,11 +47,17 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
46
47
|
disabled: (_b = (_a = props.componentProps) == null ? void 0 : _a.disabled) != null ? _b : props.disabled
|
|
47
48
|
});
|
|
48
49
|
});
|
|
50
|
+
function getSlotNames() {
|
|
51
|
+
return Object.keys(slots);
|
|
52
|
+
}
|
|
53
|
+
function getComponentSlotNames() {
|
|
54
|
+
return Object.keys(props.componentSlots || {});
|
|
55
|
+
}
|
|
49
56
|
return (_ctx, _cache) => {
|
|
50
57
|
return openBlock(), createBlock(unref(ElInputNumber), mergeProps(inputNumberProps.value, {
|
|
51
58
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:modelValue", $event))
|
|
52
59
|
}), createSlots({ _: 2 }, [
|
|
53
|
-
renderList(
|
|
60
|
+
renderList(getSlotNames(), (name) => {
|
|
54
61
|
return {
|
|
55
62
|
name,
|
|
56
63
|
fn: withCtx((slotData) => [
|
|
@@ -58,7 +65,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
58
65
|
])
|
|
59
66
|
};
|
|
60
67
|
}),
|
|
61
|
-
renderList(
|
|
68
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
62
69
|
return {
|
|
63
70
|
name,
|
|
64
71
|
fn: withCtx((slotData) => [
|
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
20
|
+
import { defineComponent, useSlots, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
21
21
|
import { ElInputTag } from "element-plus";
|
|
22
22
|
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
23
23
|
name: "JkyFormItemInputTag"
|
|
@@ -34,6 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
34
34
|
setup(__props, { emit: __emit }) {
|
|
35
35
|
const props = __props;
|
|
36
36
|
const emit = __emit;
|
|
37
|
+
const slots = useSlots();
|
|
37
38
|
const inputTagProps = computed(() => {
|
|
38
39
|
var _a, _b;
|
|
39
40
|
return __spreadProps(__spreadValues({}, props.componentProps), {
|
|
@@ -41,11 +42,17 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
41
42
|
disabled: (_b = (_a = props.componentProps) == null ? void 0 : _a.disabled) != null ? _b : props.disabled
|
|
42
43
|
});
|
|
43
44
|
});
|
|
45
|
+
function getSlotNames() {
|
|
46
|
+
return Object.keys(slots);
|
|
47
|
+
}
|
|
48
|
+
function getComponentSlotNames() {
|
|
49
|
+
return Object.keys(props.componentSlots || {});
|
|
50
|
+
}
|
|
44
51
|
return (_ctx, _cache) => {
|
|
45
52
|
return openBlock(), createBlock(unref(ElInputTag), mergeProps(inputTagProps.value, {
|
|
46
53
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:modelValue", $event))
|
|
47
54
|
}), createSlots({ _: 2 }, [
|
|
48
|
-
renderList(
|
|
55
|
+
renderList(getSlotNames(), (name) => {
|
|
49
56
|
return {
|
|
50
57
|
name,
|
|
51
58
|
fn: withCtx((slotData) => [
|
|
@@ -53,7 +60,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
53
60
|
])
|
|
54
61
|
};
|
|
55
62
|
}),
|
|
56
|
-
renderList(
|
|
63
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
57
64
|
return {
|
|
58
65
|
name,
|
|
59
66
|
fn: withCtx((slotData) => [
|
|
@@ -8,7 +8,10 @@ type __VLS_Props = {
|
|
|
8
8
|
};
|
|
9
9
|
declare function __VLS_template(): {
|
|
10
10
|
attrs: Partial<{}>;
|
|
11
|
-
slots: any
|
|
11
|
+
slots: Partial<Record<string, (_: any) => any>> & {
|
|
12
|
+
prefix?(_: {}): any;
|
|
13
|
+
suffix?(_: {}): any;
|
|
14
|
+
};
|
|
12
15
|
refs: {};
|
|
13
16
|
rootEl: HTMLDivElement;
|
|
14
17
|
};
|
|
@@ -37,7 +37,7 @@ var __async = (__this, __arguments, generator) => {
|
|
|
37
37
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
38
38
|
});
|
|
39
39
|
};
|
|
40
|
-
import { defineComponent, computed, ref, onMounted, openBlock, createElementBlock, renderSlot, Fragment, renderList, createBlock, unref, mergeProps, createSlots, withCtx, resolveDynamicComponent, watch } from "vue";
|
|
40
|
+
import { defineComponent, useSlots, computed, ref, onMounted, openBlock, createElementBlock, renderSlot, Fragment, renderList, createBlock, unref, mergeProps, createSlots, withCtx, resolveDynamicComponent, watch } from "vue";
|
|
41
41
|
import { ElSelect, ElOption } from "element-plus";
|
|
42
42
|
const _hoisted_1 = { class: "flex gap-2" };
|
|
43
43
|
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
@@ -55,6 +55,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
55
55
|
setup(__props, { emit: __emit }) {
|
|
56
56
|
const props = __props;
|
|
57
57
|
const emit = __emit;
|
|
58
|
+
const slots = useSlots();
|
|
58
59
|
const config = computed(() => {
|
|
59
60
|
var _a;
|
|
60
61
|
return ((_a = props.config) == null ? void 0 : _a.config) || {};
|
|
@@ -127,6 +128,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
127
128
|
loadOptions(0, void 0);
|
|
128
129
|
}
|
|
129
130
|
});
|
|
131
|
+
function getSlotNames() {
|
|
132
|
+
return Object.keys(slots);
|
|
133
|
+
}
|
|
134
|
+
function getComponentSlotNames() {
|
|
135
|
+
return Object.keys(props.componentSlots || {});
|
|
136
|
+
}
|
|
130
137
|
return (_ctx, _cache) => {
|
|
131
138
|
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
132
139
|
renderSlot(_ctx.$slots, "prefix"),
|
|
@@ -157,7 +164,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
157
164
|
]),
|
|
158
165
|
_: 2
|
|
159
166
|
}, [
|
|
160
|
-
renderList(
|
|
167
|
+
renderList(getSlotNames(), (name) => {
|
|
161
168
|
return {
|
|
162
169
|
name,
|
|
163
170
|
fn: withCtx((slotData) => [
|
|
@@ -165,7 +172,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
165
172
|
])
|
|
166
173
|
};
|
|
167
174
|
}),
|
|
168
|
-
renderList(
|
|
175
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
169
176
|
return {
|
|
170
177
|
name,
|
|
171
178
|
fn: withCtx((slotData) => [
|
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
20
|
+
import { defineComponent, useSlots, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
21
21
|
import { ElMention } from "element-plus";
|
|
22
22
|
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
23
23
|
name: "JkyFormItemMention"
|
|
@@ -34,6 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
34
34
|
setup(__props, { emit: __emit }) {
|
|
35
35
|
const props = __props;
|
|
36
36
|
const emit = __emit;
|
|
37
|
+
const slots = useSlots();
|
|
37
38
|
const mentionProps = computed(() => {
|
|
38
39
|
var _a, _b;
|
|
39
40
|
return __spreadProps(__spreadValues({}, props.componentProps), {
|
|
@@ -41,11 +42,17 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
41
42
|
disabled: (_b = (_a = props.componentProps) == null ? void 0 : _a.disabled) != null ? _b : props.disabled
|
|
42
43
|
});
|
|
43
44
|
});
|
|
45
|
+
function getSlotNames() {
|
|
46
|
+
return Object.keys(slots);
|
|
47
|
+
}
|
|
48
|
+
function getComponentSlotNames() {
|
|
49
|
+
return Object.keys(props.componentSlots || {});
|
|
50
|
+
}
|
|
44
51
|
return (_ctx, _cache) => {
|
|
45
52
|
return openBlock(), createBlock(unref(ElMention), mergeProps(mentionProps.value, {
|
|
46
53
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:modelValue", $event))
|
|
47
54
|
}), createSlots({ _: 2 }, [
|
|
48
|
-
renderList(
|
|
55
|
+
renderList(getSlotNames(), (name) => {
|
|
49
56
|
return {
|
|
50
57
|
name,
|
|
51
58
|
fn: withCtx((slotData) => [
|
|
@@ -53,7 +60,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
53
60
|
])
|
|
54
61
|
};
|
|
55
62
|
}),
|
|
56
|
-
renderList(
|
|
63
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
57
64
|
return {
|
|
58
65
|
name,
|
|
59
66
|
fn: withCtx((slotData) => [
|
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, createSlots, withCtx, createElementBlock, Fragment, renderList, createTextVNode, toDisplayString, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
20
|
+
import { defineComponent, useSlots, computed, openBlock, createBlock, unref, mergeProps, createSlots, withCtx, createElementBlock, Fragment, renderList, createTextVNode, toDisplayString, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
21
21
|
import { ElRadioGroup, ElRadioButton, ElRadio } from "element-plus";
|
|
22
22
|
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
23
23
|
name: "JkyFormItemRadioGroup"
|
|
@@ -34,6 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
34
34
|
setup(__props, { emit: __emit }) {
|
|
35
35
|
const props = __props;
|
|
36
36
|
const emit = __emit;
|
|
37
|
+
const slots = useSlots();
|
|
37
38
|
const radioGroupProps = computed(() => {
|
|
38
39
|
var _a, _b;
|
|
39
40
|
return __spreadProps(__spreadValues({}, props.componentProps), {
|
|
@@ -43,6 +44,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
43
44
|
});
|
|
44
45
|
const options = computed(() => props.componentProps.options || props.config.options || []);
|
|
45
46
|
const isButton = computed(() => props.componentProps.button || false);
|
|
47
|
+
function getSlotNames() {
|
|
48
|
+
return Object.keys(slots);
|
|
49
|
+
}
|
|
50
|
+
function getComponentSlotNames() {
|
|
51
|
+
return Object.keys(props.componentSlots || {});
|
|
52
|
+
}
|
|
46
53
|
return (_ctx, _cache) => {
|
|
47
54
|
return openBlock(), createBlock(unref(ElRadioGroup), mergeProps(radioGroupProps.value, {
|
|
48
55
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:modelValue", $event))
|
|
@@ -76,7 +83,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
76
83
|
]),
|
|
77
84
|
_: 2
|
|
78
85
|
}, [
|
|
79
|
-
renderList(
|
|
86
|
+
renderList(getSlotNames(), (name) => {
|
|
80
87
|
return {
|
|
81
88
|
name,
|
|
82
89
|
fn: withCtx((slotData) => [
|
|
@@ -84,7 +91,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
84
91
|
])
|
|
85
92
|
};
|
|
86
93
|
}),
|
|
87
|
-
renderList(
|
|
94
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
88
95
|
return {
|
|
89
96
|
name,
|
|
90
97
|
fn: withCtx((slotData) => [
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
type __VLS_Props = {
|
|
2
|
+
modelValue?: any;
|
|
3
|
+
config: any;
|
|
4
|
+
componentProps: any;
|
|
5
|
+
componentSlots?: any;
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
};
|
|
8
|
+
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
9
|
+
"update:modelValue": (value: any) => any;
|
|
10
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
11
|
+
"onUpdate:modelValue"?: ((value: any) => any) | undefined;
|
|
12
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
13
|
+
export default _default;
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
+
var __spreadValues = (a, b) => {
|
|
9
|
+
for (var prop in b || (b = {}))
|
|
10
|
+
if (__hasOwnProp.call(b, prop))
|
|
11
|
+
__defNormalProp(a, prop, b[prop]);
|
|
12
|
+
if (__getOwnPropSymbols)
|
|
13
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
+
if (__propIsEnum.call(b, prop))
|
|
15
|
+
__defNormalProp(a, prop, b[prop]);
|
|
16
|
+
}
|
|
17
|
+
return a;
|
|
18
|
+
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
+
import { defineComponent, computed, h, openBlock, createElementBlock, createVNode, unref, mergeProps, createBlock, resolveDynamicComponent } from "vue";
|
|
21
|
+
import { ElInputNumber } from "element-plus";
|
|
22
|
+
const _hoisted_1 = { class: "flex items-center gap-2" };
|
|
23
|
+
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
24
|
+
name: "JkyFormItemRangeInputNumber"
|
|
25
|
+
}), {
|
|
26
|
+
__name: "RangeInputNumberItem",
|
|
27
|
+
props: {
|
|
28
|
+
modelValue: {},
|
|
29
|
+
config: {},
|
|
30
|
+
componentProps: {},
|
|
31
|
+
componentSlots: {},
|
|
32
|
+
disabled: { type: Boolean }
|
|
33
|
+
},
|
|
34
|
+
emits: ["update:modelValue"],
|
|
35
|
+
setup(__props, { emit: __emit }) {
|
|
36
|
+
const props = __props;
|
|
37
|
+
const emit = __emit;
|
|
38
|
+
function parseModelValue() {
|
|
39
|
+
var _a, _b;
|
|
40
|
+
const val = props.modelValue;
|
|
41
|
+
if (val && typeof val === "object") {
|
|
42
|
+
return {
|
|
43
|
+
min: (_a = val.min) != null ? _a : null,
|
|
44
|
+
max: (_b = val.max) != null ? _b : null
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
return { min: null, max: null };
|
|
48
|
+
}
|
|
49
|
+
const rangeProps = computed(() => {
|
|
50
|
+
var _a, _b;
|
|
51
|
+
return __spreadProps(__spreadValues({}, props.componentProps), {
|
|
52
|
+
disabled: (_b = (_a = props.componentProps) == null ? void 0 : _a.disabled) != null ? _b : props.disabled
|
|
53
|
+
});
|
|
54
|
+
});
|
|
55
|
+
const separator = computed(() => {
|
|
56
|
+
var _a;
|
|
57
|
+
const separatorProp = (_a = rangeProps.value.separator) != null ? _a : "~";
|
|
58
|
+
if (typeof separatorProp === "function") {
|
|
59
|
+
return separatorProp();
|
|
60
|
+
} else if (typeof separatorProp === "string") {
|
|
61
|
+
return h("span", {}, separatorProp);
|
|
62
|
+
}
|
|
63
|
+
return separatorProp;
|
|
64
|
+
});
|
|
65
|
+
const minInputProps = computed(() => {
|
|
66
|
+
var _a;
|
|
67
|
+
return __spreadProps(__spreadValues({}, rangeProps.value), {
|
|
68
|
+
modelValue: parseModelValue().min,
|
|
69
|
+
placeholder: rangeProps.value.minPlaceholder || "最小值",
|
|
70
|
+
class: ["flex-1", (_a = rangeProps.value) == null ? void 0 : _a.minClass]
|
|
71
|
+
});
|
|
72
|
+
});
|
|
73
|
+
const maxInputProps = computed(() => {
|
|
74
|
+
var _a;
|
|
75
|
+
return __spreadProps(__spreadValues({}, rangeProps.value), {
|
|
76
|
+
modelValue: parseModelValue().max,
|
|
77
|
+
placeholder: rangeProps.value.maxPlaceholder || "最大值",
|
|
78
|
+
class: ["flex-1", (_a = rangeProps.value) == null ? void 0 : _a.maxClass]
|
|
79
|
+
});
|
|
80
|
+
});
|
|
81
|
+
function handleMinChange(value) {
|
|
82
|
+
const current = parseModelValue();
|
|
83
|
+
const minVal = value != null ? value : null;
|
|
84
|
+
const maxVal = current.max;
|
|
85
|
+
if (minVal !== null && maxVal !== null && minVal > maxVal) {
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
emit("update:modelValue", {
|
|
89
|
+
min: minVal,
|
|
90
|
+
max: maxVal
|
|
91
|
+
});
|
|
92
|
+
}
|
|
93
|
+
function handleMaxChange(value) {
|
|
94
|
+
const current = parseModelValue();
|
|
95
|
+
const minVal = current.min;
|
|
96
|
+
const maxVal = value != null ? value : null;
|
|
97
|
+
if (minVal !== null && maxVal !== null && maxVal < minVal) {
|
|
98
|
+
return;
|
|
99
|
+
}
|
|
100
|
+
emit("update:modelValue", {
|
|
101
|
+
min: minVal,
|
|
102
|
+
max: maxVal
|
|
103
|
+
});
|
|
104
|
+
}
|
|
105
|
+
return (_ctx, _cache) => {
|
|
106
|
+
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
107
|
+
createVNode(unref(ElInputNumber), mergeProps(minInputProps.value, { "onUpdate:modelValue": handleMinChange }), null, 16),
|
|
108
|
+
(openBlock(), createBlock(resolveDynamicComponent(separator.value))),
|
|
109
|
+
createVNode(unref(ElInputNumber), mergeProps(maxInputProps.value, { "onUpdate:modelValue": handleMaxChange }), null, 16)
|
|
110
|
+
]);
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
}));
|
|
114
|
+
export {
|
|
115
|
+
_sfc_main as default
|
|
116
|
+
};
|
|
@@ -17,7 +17,7 @@ var __spreadValues = (a, b) => {
|
|
|
17
17
|
return a;
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
import { defineComponent, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
20
|
+
import { defineComponent, useSlots, computed, openBlock, createBlock, unref, mergeProps, createSlots, renderList, withCtx, renderSlot, normalizeProps, guardReactiveProps, resolveDynamicComponent } from "vue";
|
|
21
21
|
import { ElRate } from "element-plus";
|
|
22
22
|
const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
|
|
23
23
|
name: "JkyFormItemRate"
|
|
@@ -34,6 +34,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
34
34
|
setup(__props, { emit: __emit }) {
|
|
35
35
|
const props = __props;
|
|
36
36
|
const emit = __emit;
|
|
37
|
+
const slots = useSlots();
|
|
37
38
|
const rateProps = computed(() => {
|
|
38
39
|
var _a, _b;
|
|
39
40
|
return __spreadProps(__spreadValues({}, props.componentProps), {
|
|
@@ -41,11 +42,17 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
41
42
|
disabled: (_b = (_a = props.componentProps) == null ? void 0 : _a.disabled) != null ? _b : props.disabled
|
|
42
43
|
});
|
|
43
44
|
});
|
|
45
|
+
function getSlotNames() {
|
|
46
|
+
return Object.keys(slots);
|
|
47
|
+
}
|
|
48
|
+
function getComponentSlotNames() {
|
|
49
|
+
return Object.keys(props.componentSlots || {});
|
|
50
|
+
}
|
|
44
51
|
return (_ctx, _cache) => {
|
|
45
52
|
return openBlock(), createBlock(unref(ElRate), mergeProps(rateProps.value, {
|
|
46
53
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => emit("update:modelValue", $event))
|
|
47
54
|
}), createSlots({ _: 2 }, [
|
|
48
|
-
renderList(
|
|
55
|
+
renderList(getSlotNames(), (name) => {
|
|
49
56
|
return {
|
|
50
57
|
name,
|
|
51
58
|
fn: withCtx((slotData) => [
|
|
@@ -53,7 +60,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({
|
|
|
53
60
|
])
|
|
54
61
|
};
|
|
55
62
|
}),
|
|
56
|
-
renderList(
|
|
63
|
+
renderList(getComponentSlotNames(), (name) => {
|
|
57
64
|
return {
|
|
58
65
|
name,
|
|
59
66
|
fn: withCtx((slotData) => [
|