@fangzhongya/fang-ui 0.1.27 → 0.1.28
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/array/index.css +4 -0
- package/dist/components/array/src/index2.cjs +5 -5
- package/dist/components/array/src/index2.js +2 -2
- package/dist/components/audios/index.css +4 -0
- package/dist/components/box/index.css +4 -0
- package/dist/components/box-adjust/index.css +4 -0
- package/dist/components/box-local/index.css +4 -0
- package/dist/components/box-mask/index.css +4 -0
- package/dist/components/box-title/index.css +4 -0
- package/dist/components/buttons/index.css +4 -0
- package/dist/components/cascaders/index.css +4 -0
- package/dist/components/checks/index.css +4 -0
- package/dist/components/common/compons/components.cjs +52 -0
- package/dist/components/common/compons/components.d.ts +27 -0
- package/dist/components/common/compons/components.js +52 -0
- package/dist/components/common/compons/index.scss +23 -0
- package/dist/components/common/compons/index2.scss +23 -0
- package/dist/components/common/use.cjs +29 -3
- package/dist/components/common/use.d.ts +2 -2
- package/dist/components/common/use.js +29 -3
- package/dist/components/dates/index.css +4 -0
- package/dist/components/dates-divide/index.css +4 -0
- package/dist/components/dates-picker/index.css +4 -0
- package/dist/components/dates2/index.css +4 -0
- package/dist/components/dialogs/index.css +4 -0
- package/dist/components/edit/index.css +4 -0
- package/dist/components/edit-float/index.css +4 -0
- package/dist/components/forms/common/config.cjs +11 -1
- package/dist/components/forms/common/config.d.ts +1 -0
- package/dist/components/forms/common/config.js +11 -1
- package/dist/components/forms/index.css +10 -6
- package/dist/components/forms/index.scss +2 -1
- package/dist/components/forms/src/data.cjs +7 -0
- package/dist/components/forms/src/data.d.ts +7 -0
- package/dist/components/forms/src/data.js +7 -0
- package/dist/components/forms/src/setup.cjs +3 -12
- package/dist/components/forms/src/setup.d.ts +1 -1
- package/dist/components/forms/src/setup.js +4 -13
- package/dist/components/forms/style/index2.scss +3 -1
- package/dist/components/forms-div/index.css +4 -0
- package/dist/components/forms-div/src/index2.cjs +4 -4
- package/dist/components/forms-div/src/index2.js +2 -2
- package/dist/components/forms-item/index.css +4 -0
- package/dist/components/forms-item/src/indexts.d.ts +1 -1
- package/dist/components/forms-item/src/label.cjs +15 -28
- package/dist/components/forms-item/src/label.js +16 -29
- package/dist/components/full-screen/index.css +4 -0
- package/dist/components/history/index.css +4 -0
- package/dist/components/icon/index.css +4 -0
- package/dist/components/icon-picker/index.css +4 -0
- package/dist/components/iframe/index.css +4 -0
- package/dist/components/images/index.css +4 -0
- package/dist/components/index.cjs +2 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +2 -0
- package/dist/components/index.scss +2 -1
- package/dist/components/index2.scss +2 -1
- package/dist/components/input-array/index.css +4 -0
- package/dist/components/input-history/index.css +4 -0
- package/dist/components/input-num/index.css +4 -0
- package/dist/components/input-select/index.css +4 -0
- package/dist/components/inputs/index.css +4 -0
- package/dist/components/{global-config → keep-com}/index.css +4 -0
- package/dist/components/labels/index.css +4 -0
- package/dist/components/list/index.css +4 -0
- package/dist/components/list/src/data.cjs +6 -0
- package/dist/components/list/src/data.d.ts +6 -0
- package/dist/components/list/src/data.js +6 -0
- package/dist/components/list/src/index2.cjs +6 -6
- package/dist/components/list/src/index2.js +2 -2
- package/dist/components/lists/index.css +4 -0
- package/dist/components/listsp/index.css +4 -0
- package/dist/components/listspd/index.css +4 -0
- package/dist/components/menus/index.css +4 -0
- package/dist/components/no-data/index.css +4 -0
- package/dist/components/page/index.css +10 -6
- package/dist/components/paging/index.css +4 -0
- package/dist/components/popup/index.css +4 -0
- package/dist/components/retract/index.css +4 -0
- package/dist/components/right-key/index.css +4 -0
- package/dist/components/scss/common.scss +4 -0
- package/dist/components/seamless-scroll/index.css +4 -0
- package/dist/components/select-scroll/index.css +4 -0
- package/dist/components/selector/index.css +4 -0
- package/dist/components/selects/index.css +4 -0
- package/dist/components/sliders/index.css +4 -0
- package/dist/components/switchs/index.css +4 -0
- package/dist/components/tables/common/config.cjs +1 -1
- package/dist/components/tables/common/config.js +1 -1
- package/dist/components/tables/common/pagin.cjs +74 -32
- package/dist/components/tables/common/pagin.d.ts +8 -1
- package/dist/components/tables/common/pagin.js +74 -32
- package/dist/components/tables/index.css +4 -0
- package/dist/components/tables/src/column.cjs +22 -20
- package/dist/components/tables/src/column.d.ts +3 -0
- package/dist/components/tables/src/column.js +14 -12
- package/dist/components/tables/src/data.cjs +15 -0
- package/dist/components/tables/src/data.d.ts +13 -0
- package/dist/components/tables/src/data.js +15 -0
- package/dist/components/tables/src/index2.cjs +17 -9
- package/dist/components/tables/src/index2.js +11 -3
- package/dist/components/tablesp/index.css +4 -0
- package/dist/components/tablespd/index.css +4 -0
- package/dist/components/tabless/index.css +4 -0
- package/dist/components/tablesv/index.css +4 -0
- package/dist/components/tablesv/src/column.cjs +116 -112
- package/dist/components/tablesv/src/column.d.ts +3 -1
- package/dist/components/tablesv/src/column.js +110 -106
- package/dist/components/tablesv/src/data.cjs +44 -0
- package/dist/components/tablesv/src/data.d.ts +43 -1
- package/dist/components/tablesv/src/data.js +44 -0
- package/dist/components/tablesv/src/index2.cjs +37 -14
- package/dist/components/tablesv/src/index2.js +36 -13
- package/dist/components/tablesv/style/index2.scss +3 -1
- package/dist/components/tablesvp/index.css +10 -0
- package/dist/components/tablesvp/index.scss +8 -0
- package/dist/components/tablesvp/src/index2.cjs +15 -5
- package/dist/components/tablesvp/src/index2.js +15 -5
- package/dist/components/tablesvpd/index.cjs +9 -0
- package/dist/components/tablesvpd/index.css +157 -0
- package/dist/components/tablesvpd/index.d.ts +4 -0
- package/dist/components/tablesvpd/index.js +9 -0
- package/dist/components/tablesvpd/index.scss +41 -0
- package/dist/components/tablesvpd/src/data.cjs +13 -0
- package/dist/components/tablesvpd/src/data.d.ts +18 -0
- package/dist/components/tablesvpd/src/data.js +13 -0
- package/dist/components/tablesvpd/src/index.cjs +4 -0
- package/dist/components/tablesvpd/src/index.js +4 -0
- package/dist/components/tablesvpd/src/index2.cjs +107 -0
- package/dist/components/tablesvpd/src/index2.js +107 -0
- package/dist/components/tablesvpd/style/index2.scss +4 -0
- package/dist/components/uploads/index.css +4 -0
- package/dist/components/videos/index.css +4 -0
- package/dist/components/window/index.css +4 -0
- package/dist/css/array.css +4 -0
- package/dist/css/audios.css +4 -0
- package/dist/css/box-adjust.css +4 -0
- package/dist/css/box-local.css +4 -0
- package/dist/css/box-mask.css +4 -0
- package/dist/css/box-title.css +4 -0
- package/dist/css/box.css +4 -0
- package/dist/css/buttons.css +4 -0
- package/dist/css/cascaders.css +4 -0
- package/dist/css/checks.css +4 -0
- package/dist/css/dates-divide.css +4 -0
- package/dist/css/dates-picker.css +4 -0
- package/dist/css/dates.css +4 -0
- package/dist/css/dates2.css +4 -0
- package/dist/css/dialogs.css +4 -0
- package/dist/css/edit-float.css +4 -0
- package/dist/css/edit.css +4 -0
- package/dist/css/forms-div.css +4 -0
- package/dist/css/forms-item.css +4 -0
- package/dist/css/forms.css +10 -6
- package/dist/css/full-screen.css +4 -0
- package/dist/css/history.css +4 -0
- package/dist/css/icon-picker.css +4 -0
- package/dist/css/icon.css +4 -0
- package/dist/css/iframe.css +4 -0
- package/dist/css/images.css +4 -0
- package/dist/css/index.css +44 -6
- package/dist/css/input-array.css +4 -0
- package/dist/css/input-history.css +4 -0
- package/dist/css/input-num.css +4 -0
- package/dist/css/input-select.css +4 -0
- package/dist/css/inputs.css +4 -0
- package/dist/css/{global-config.css → keep-com.css} +4 -0
- package/dist/css/labels.css +4 -0
- package/dist/css/list.css +4 -0
- package/dist/css/lists.css +4 -0
- package/dist/css/listsp.css +4 -0
- package/dist/css/listspd.css +4 -0
- package/dist/css/menus.css +4 -0
- package/dist/css/no-data.css +4 -0
- package/dist/css/page.css +10 -6
- package/dist/css/paging.css +4 -0
- package/dist/css/popup.css +4 -0
- package/dist/css/retract.css +4 -0
- package/dist/css/right-key.css +4 -0
- package/dist/css/seamless-scroll.css +4 -0
- package/dist/css/select-scroll.css +4 -0
- package/dist/css/selector.css +4 -0
- package/dist/css/selects.css +4 -0
- package/dist/css/sliders.css +4 -0
- package/dist/css/switchs.css +4 -0
- package/dist/css/tables.css +4 -0
- package/dist/css/tablesp.css +4 -0
- package/dist/css/tablespd.css +4 -0
- package/dist/css/tabless.css +4 -0
- package/dist/css/tablesv.css +4 -0
- package/dist/css/tablesvp.css +10 -0
- package/dist/css/tablesvpd.css +157 -0
- package/dist/css/uploads.css +4 -0
- package/dist/css/videos.css +4 -0
- package/dist/css/window.css +4 -0
- package/dist/expand/{chunk-MC76Q3TQ.cjs → chunk-3HP2ZDNG.cjs} +3 -1
- package/dist/expand/{chunk-CV4O5V2F.js → chunk-7C25SBCF.js} +3 -1
- package/dist/expand/components.cjs +5 -5
- package/dist/expand/components.js +1 -1
- package/dist/expand/config.cjs +2 -2
- package/dist/expand/config.js +1 -1
- package/dist/hooks/compons/index.cjs +44 -0
- package/dist/hooks/compons/index.d.ts +7 -0
- package/dist/hooks/compons/index.js +44 -0
- package/dist/icons/index.json +1 -1
- package/dist/index.cjs +24 -22
- package/dist/index.css +44 -6
- package/dist/index.js +2 -0
- package/package.json +12 -12
- package/dist/components/common/compons.cjs +0 -76
- package/dist/components/common/compons.d.ts +0 -9
- package/dist/components/common/compons.js +0 -76
- package/dist/components/common/compons.scss +0 -26
- package/dist/components/common/compons2.scss +0 -26
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const vue = require("vue");
|
|
4
|
-
const util = require("../common/util.cjs");
|
|
5
|
-
const index = require("../../table-column/index.cjs");
|
|
6
4
|
const use = require("../../common/use.cjs");
|
|
7
5
|
const getAttrValue = require("../../../utils/vues/getAttrValue.cjs");
|
|
8
|
-
const
|
|
6
|
+
const index = require("../../../hooks/compons/index.cjs");
|
|
9
7
|
const config = require("../common/config.cjs");
|
|
8
|
+
const util = require("../common/util.cjs");
|
|
9
|
+
const index$1 = require("../../table-column/index.cjs");
|
|
10
10
|
const noProps = ["children", "class", "minWidth", "label"];
|
|
11
11
|
function setProps(obj, props) {
|
|
12
12
|
const table = props.table;
|
|
@@ -17,19 +17,20 @@ function setProps(obj, props) {
|
|
|
17
17
|
Object.keys(obj).forEach((key) => {
|
|
18
18
|
if (!noProps.includes(key)) {
|
|
19
19
|
if (obj[key] !== "") {
|
|
20
|
-
robj[key] = obj[key];
|
|
21
20
|
if (key == "sortable") {
|
|
22
21
|
if (obj[key]) {
|
|
23
22
|
robj[key] = "custom";
|
|
24
23
|
}
|
|
24
|
+
} else {
|
|
25
|
+
robj[key] = obj[key];
|
|
25
26
|
}
|
|
26
27
|
}
|
|
27
28
|
}
|
|
28
29
|
});
|
|
29
30
|
return robj;
|
|
30
31
|
}
|
|
31
|
-
function setSslot(obj, scope, emit, slots, props,
|
|
32
|
-
const slot = use.useSetSlot(obj, scope.row, slots,
|
|
32
|
+
function setSslot(obj, scope, emit, slots, props, index$12) {
|
|
33
|
+
const slot = use.useSetSlot(obj, scope.row, slots, index$12, scope);
|
|
33
34
|
if (slot) {
|
|
34
35
|
return slot;
|
|
35
36
|
}
|
|
@@ -41,9 +42,9 @@ function setSslot(obj, scope, emit, slots, props, index2) {
|
|
|
41
42
|
obj,
|
|
42
43
|
scope.row,
|
|
43
44
|
optionss,
|
|
44
|
-
|
|
45
|
+
index.useComponsGet(config.provides.compons),
|
|
45
46
|
emit,
|
|
46
|
-
|
|
47
|
+
index$12,
|
|
47
48
|
scope
|
|
48
49
|
);
|
|
49
50
|
if (column) {
|
|
@@ -51,7 +52,7 @@ function setSslot(obj, scope, emit, slots, props, index2) {
|
|
|
51
52
|
}
|
|
52
53
|
}
|
|
53
54
|
}
|
|
54
|
-
return defaultDom(obj, scope, props,
|
|
55
|
+
return defaultDom(obj, scope, props, index$12);
|
|
55
56
|
}
|
|
56
57
|
function defaultDom(obj, scope, props, index2) {
|
|
57
58
|
var _a;
|
|
@@ -85,7 +86,7 @@ function defaultDom(obj, scope, props, index2) {
|
|
|
85
86
|
domValue ?? table.emptyDisplay ?? ""
|
|
86
87
|
);
|
|
87
88
|
}
|
|
88
|
-
function setHeader(obj, scope, slots, emit, props,
|
|
89
|
+
function setHeader(obj, scope, slots, emit, props, index$12) {
|
|
89
90
|
const optionss = props.options || {};
|
|
90
91
|
return use.useGetDomLabel(
|
|
91
92
|
obj.label,
|
|
@@ -93,17 +94,22 @@ function setHeader(obj, scope, slots, emit, props, index2) {
|
|
|
93
94
|
scope.row,
|
|
94
95
|
slots,
|
|
95
96
|
optionss,
|
|
96
|
-
|
|
97
|
+
index.useComponsGet(config.provides.compons),
|
|
97
98
|
emit,
|
|
98
|
-
|
|
99
|
+
index$12
|
|
99
100
|
);
|
|
100
101
|
}
|
|
101
|
-
function
|
|
102
|
+
function getDom(obj, emit, propss, slots, index2) {
|
|
103
|
+
return getTableColumn(obj, emit, propss, slots, index2, (scope) => {
|
|
104
|
+
return setSslot(obj, scope, emit, slots, propss, index2);
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
function getTableColumn(obj, emit, props, slots, index2, def) {
|
|
102
108
|
if (obj.type == "selection") {
|
|
103
109
|
def = void 0;
|
|
104
110
|
}
|
|
105
111
|
return vue.h(
|
|
106
|
-
index.TableColumn,
|
|
112
|
+
index$1.TableColumn,
|
|
107
113
|
{
|
|
108
114
|
...setProps(obj, props),
|
|
109
115
|
className: obj.class,
|
|
@@ -112,18 +118,14 @@ function getTableColumn(obj, emit, props, slots, index$1, def) {
|
|
|
112
118
|
{
|
|
113
119
|
default: def,
|
|
114
120
|
header: (scope) => {
|
|
115
|
-
return setHeader(obj, scope, slots, emit, props,
|
|
121
|
+
return setHeader(obj, scope, slots, emit, props, index2);
|
|
116
122
|
}
|
|
117
123
|
}
|
|
118
124
|
);
|
|
119
125
|
}
|
|
120
|
-
function getDom(obj, emit, props, slots, index2) {
|
|
121
|
-
return getTableColumn(obj, emit, props, slots, index2, (scope) => {
|
|
122
|
-
return setSslot(obj, scope, emit, slots, props, index2);
|
|
123
|
-
});
|
|
124
|
-
}
|
|
125
126
|
function columnRender(obj, emit, props, slots, index2) {
|
|
126
127
|
return getDom(obj, emit, props, slots, index2);
|
|
127
128
|
}
|
|
128
129
|
exports.columnRender = columnRender;
|
|
129
130
|
exports.getTableColumn = getTableColumn;
|
|
131
|
+
exports.setHeader = setHeader;
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { VNode, RendererNode, RendererElement } from 'vue';
|
|
2
|
+
export declare function setHeader(obj: ListObj, scope: ObjAny, slots: ObjAny, emit: Function, props: ObjAny, index: number): string | VNode<RendererNode, RendererElement, {
|
|
3
|
+
[key: string]: any;
|
|
4
|
+
}>;
|
|
2
5
|
export declare function getTableColumn(obj: ListObj, emit: Function, props: ObjAny, slots: ObjAny, index: number, def?: Function): VNode<RendererNode, RendererElement, {
|
|
3
6
|
[key: string]: any;
|
|
4
7
|
}>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { h } from "vue";
|
|
2
|
-
import { setMinWidth } from "../common/util.js";
|
|
3
|
-
import { TableColumn } from "../../table-column/index.js";
|
|
4
2
|
import { useSetSlot, useSetCompon, useGetDomValue, useGetDomLabel } from "../../common/use.js";
|
|
5
3
|
import { getAttrValue } from "../../../utils/vues/getAttrValue.js";
|
|
6
|
-
import {
|
|
4
|
+
import { useComponsGet } from "../../../hooks/compons/index.js";
|
|
7
5
|
import { provides } from "../common/config.js";
|
|
6
|
+
import { setMinWidth } from "../common/util.js";
|
|
7
|
+
import { TableColumn } from "../../table-column/index.js";
|
|
8
8
|
const noProps = ["children", "class", "minWidth", "label"];
|
|
9
9
|
function setProps(obj, props) {
|
|
10
10
|
const table = props.table;
|
|
@@ -15,11 +15,12 @@ function setProps(obj, props) {
|
|
|
15
15
|
Object.keys(obj).forEach((key) => {
|
|
16
16
|
if (!noProps.includes(key)) {
|
|
17
17
|
if (obj[key] !== "") {
|
|
18
|
-
robj[key] = obj[key];
|
|
19
18
|
if (key == "sortable") {
|
|
20
19
|
if (obj[key]) {
|
|
21
20
|
robj[key] = "custom";
|
|
22
21
|
}
|
|
22
|
+
} else {
|
|
23
|
+
robj[key] = obj[key];
|
|
23
24
|
}
|
|
24
25
|
}
|
|
25
26
|
}
|
|
@@ -39,7 +40,7 @@ function setSslot(obj, scope, emit, slots, props, index) {
|
|
|
39
40
|
obj,
|
|
40
41
|
scope.row,
|
|
41
42
|
optionss,
|
|
42
|
-
|
|
43
|
+
useComponsGet(provides.compons),
|
|
43
44
|
emit,
|
|
44
45
|
index,
|
|
45
46
|
scope
|
|
@@ -91,11 +92,16 @@ function setHeader(obj, scope, slots, emit, props, index) {
|
|
|
91
92
|
scope.row,
|
|
92
93
|
slots,
|
|
93
94
|
optionss,
|
|
94
|
-
|
|
95
|
+
useComponsGet(provides.compons),
|
|
95
96
|
emit,
|
|
96
97
|
index
|
|
97
98
|
);
|
|
98
99
|
}
|
|
100
|
+
function getDom(obj, emit, propss, slots, index) {
|
|
101
|
+
return getTableColumn(obj, emit, propss, slots, index, (scope) => {
|
|
102
|
+
return setSslot(obj, scope, emit, slots, propss, index);
|
|
103
|
+
});
|
|
104
|
+
}
|
|
99
105
|
function getTableColumn(obj, emit, props, slots, index, def) {
|
|
100
106
|
if (obj.type == "selection") {
|
|
101
107
|
def = void 0;
|
|
@@ -115,15 +121,11 @@ function getTableColumn(obj, emit, props, slots, index, def) {
|
|
|
115
121
|
}
|
|
116
122
|
);
|
|
117
123
|
}
|
|
118
|
-
function getDom(obj, emit, props, slots, index) {
|
|
119
|
-
return getTableColumn(obj, emit, props, slots, index, (scope) => {
|
|
120
|
-
return setSslot(obj, scope, emit, slots, props, index);
|
|
121
|
-
});
|
|
122
|
-
}
|
|
123
124
|
function columnRender(obj, emit, props, slots, index) {
|
|
124
125
|
return getDom(obj, emit, props, slots, index);
|
|
125
126
|
}
|
|
126
127
|
export {
|
|
127
128
|
columnRender,
|
|
128
|
-
getTableColumn
|
|
129
|
+
getTableColumn,
|
|
130
|
+
setHeader
|
|
129
131
|
};
|
|
@@ -73,12 +73,21 @@ const dataProps = {
|
|
|
73
73
|
return [];
|
|
74
74
|
}
|
|
75
75
|
},
|
|
76
|
+
rowKey: {
|
|
77
|
+
type: String
|
|
78
|
+
},
|
|
76
79
|
/**
|
|
77
80
|
* 行高度
|
|
78
81
|
*/
|
|
79
82
|
lineHeight: {
|
|
80
83
|
type: [String, Number]
|
|
81
84
|
},
|
|
85
|
+
size: {
|
|
86
|
+
type: String,
|
|
87
|
+
default() {
|
|
88
|
+
return "default";
|
|
89
|
+
}
|
|
90
|
+
},
|
|
82
91
|
/**
|
|
83
92
|
* @props { Object } options 选择数据集合
|
|
84
93
|
*/
|
|
@@ -88,6 +97,12 @@ const dataProps = {
|
|
|
88
97
|
return {};
|
|
89
98
|
}
|
|
90
99
|
},
|
|
100
|
+
/**
|
|
101
|
+
* @props { Boolean } isCompons 是否使用默认的配置
|
|
102
|
+
*/
|
|
103
|
+
isCompons: {
|
|
104
|
+
type: Boolean
|
|
105
|
+
},
|
|
91
106
|
/**
|
|
92
107
|
* @props { Object } compons 外部组件集合
|
|
93
108
|
*/
|
|
@@ -106,12 +106,19 @@ export declare const dataProps: {
|
|
|
106
106
|
};
|
|
107
107
|
default(): never[];
|
|
108
108
|
};
|
|
109
|
+
rowKey: {
|
|
110
|
+
type: StringConstructor;
|
|
111
|
+
};
|
|
109
112
|
/**
|
|
110
113
|
* 行高度
|
|
111
114
|
*/
|
|
112
115
|
lineHeight: {
|
|
113
116
|
type: (StringConstructor | NumberConstructor)[];
|
|
114
117
|
};
|
|
118
|
+
size: {
|
|
119
|
+
type: StringConstructor;
|
|
120
|
+
default(): string;
|
|
121
|
+
};
|
|
115
122
|
/**
|
|
116
123
|
* @props { Object } options 选择数据集合
|
|
117
124
|
*/
|
|
@@ -119,6 +126,12 @@ export declare const dataProps: {
|
|
|
119
126
|
type: ObjectConstructor;
|
|
120
127
|
default(): {};
|
|
121
128
|
};
|
|
129
|
+
/**
|
|
130
|
+
* @props { Boolean } isCompons 是否使用默认的配置
|
|
131
|
+
*/
|
|
132
|
+
isCompons: {
|
|
133
|
+
type: BooleanConstructor;
|
|
134
|
+
};
|
|
122
135
|
/**
|
|
123
136
|
* @props { Object } compons 外部组件集合
|
|
124
137
|
*/
|
|
@@ -71,12 +71,21 @@ const dataProps = {
|
|
|
71
71
|
return [];
|
|
72
72
|
}
|
|
73
73
|
},
|
|
74
|
+
rowKey: {
|
|
75
|
+
type: String
|
|
76
|
+
},
|
|
74
77
|
/**
|
|
75
78
|
* 行高度
|
|
76
79
|
*/
|
|
77
80
|
lineHeight: {
|
|
78
81
|
type: [String, Number]
|
|
79
82
|
},
|
|
83
|
+
size: {
|
|
84
|
+
type: String,
|
|
85
|
+
default() {
|
|
86
|
+
return "default";
|
|
87
|
+
}
|
|
88
|
+
},
|
|
80
89
|
/**
|
|
81
90
|
* @props { Object } options 选择数据集合
|
|
82
91
|
*/
|
|
@@ -86,6 +95,12 @@ const dataProps = {
|
|
|
86
95
|
return {};
|
|
87
96
|
}
|
|
88
97
|
},
|
|
98
|
+
/**
|
|
99
|
+
* @props { Boolean } isCompons 是否使用默认的配置
|
|
100
|
+
*/
|
|
101
|
+
isCompons: {
|
|
102
|
+
type: Boolean
|
|
103
|
+
},
|
|
89
104
|
/**
|
|
90
105
|
* @props { Object } compons 外部组件集合
|
|
91
106
|
*/
|
|
@@ -3,17 +3,17 @@ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toString
|
|
|
3
3
|
const vue = require("vue");
|
|
4
4
|
const data = require("./data.cjs");
|
|
5
5
|
const config = require("../common/config.cjs");
|
|
6
|
-
const index$
|
|
6
|
+
const index$4 = require("../../table/index.cjs");
|
|
7
7
|
require("../../loading/index.cjs");
|
|
8
|
-
const index$
|
|
8
|
+
const index$5 = require("../../no-data/index.cjs");
|
|
9
9
|
require("./columns.cjs");
|
|
10
10
|
const index = require("../../../hooks/cssname/index.cjs");
|
|
11
11
|
const index$1 = require("../../../hooks/inherit/index.cjs");
|
|
12
12
|
const use = require("../../common/use.cjs");
|
|
13
|
-
const
|
|
13
|
+
const index$3 = require("../../../hooks/compons/index.cjs");
|
|
14
14
|
const index$2 = require("../../../hooks/props-default/index.cjs");
|
|
15
15
|
const columns_vue_vue_type_script_lang = require("./columns2.cjs");
|
|
16
|
-
const index$
|
|
16
|
+
const index$6 = require("element-plus/es/components/loading/index");
|
|
17
17
|
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
18
18
|
__name: "index",
|
|
19
19
|
props: index$2.getProps(data.dataProps),
|
|
@@ -25,7 +25,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
25
25
|
const prs = __props;
|
|
26
26
|
const props = index$2.usePropsDefault(data.name, prs, data.dataProps);
|
|
27
27
|
index$2.viewProps(props, data.name);
|
|
28
|
-
|
|
28
|
+
index$3.useCompons(config.provides.compons, props);
|
|
29
29
|
const tableRef = vue.ref();
|
|
30
30
|
const emit = __emit;
|
|
31
31
|
const rowObj = vue.ref();
|
|
@@ -122,6 +122,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
122
122
|
function clearSelection() {
|
|
123
123
|
tableRef.value.clearSelection();
|
|
124
124
|
}
|
|
125
|
+
function setCurrentRow(row) {
|
|
126
|
+
tableRef.value.setCurrentRow(row);
|
|
127
|
+
}
|
|
128
|
+
function clearCurrentRow() {
|
|
129
|
+
tableRef.value.setCurrentRow();
|
|
130
|
+
}
|
|
125
131
|
function getSelections() {
|
|
126
132
|
var _a;
|
|
127
133
|
return (_a = tableRef.value) == null ? void 0 : _a.getSelectionRows();
|
|
@@ -135,9 +141,11 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
135
141
|
});
|
|
136
142
|
__expose({
|
|
137
143
|
...data.dataExpose,
|
|
138
|
-
clearSelection,
|
|
139
144
|
clearSort,
|
|
145
|
+
setCurrentRow,
|
|
146
|
+
clearCurrentRow,
|
|
140
147
|
getSelections,
|
|
148
|
+
clearSelection,
|
|
141
149
|
toggleRowSelection
|
|
142
150
|
});
|
|
143
151
|
return (_ctx, _cache) => {
|
|
@@ -150,7 +158,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
150
158
|
minHeight: _ctx.minHeight
|
|
151
159
|
})
|
|
152
160
|
}), [
|
|
153
|
-
vue.withDirectives((vue.openBlock(), vue.createBlock(vue.unref(index$
|
|
161
|
+
vue.withDirectives((vue.openBlock(), vue.createBlock(vue.unref(index$4.Table), vue.mergeProps(vue.unref(attrs).assem, {
|
|
154
162
|
align: "left",
|
|
155
163
|
ref_key: "tableRef",
|
|
156
164
|
ref: tableRef,
|
|
@@ -166,7 +174,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
166
174
|
}), {
|
|
167
175
|
empty: vue.withCtx(() => [
|
|
168
176
|
vue.renderSlot(_ctx.$slots, "no-data", {}, () => [
|
|
169
|
-
vue.createVNode(vue.unref(index$
|
|
177
|
+
vue.createVNode(vue.unref(index$5.NoData))
|
|
170
178
|
])
|
|
171
179
|
]),
|
|
172
180
|
default: vue.withCtx(() => [
|
|
@@ -192,7 +200,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
192
200
|
]),
|
|
193
201
|
_: 3
|
|
194
202
|
}, 16, ["class", "height", "max-height", "row-style", "data", "default-sort"])), [
|
|
195
|
-
[vue.unref(index$
|
|
203
|
+
[vue.unref(index$6.vLoading), vue.unref(props).loading]
|
|
196
204
|
])
|
|
197
205
|
], 16);
|
|
198
206
|
};
|
|
@@ -8,7 +8,7 @@ import "./columns.js";
|
|
|
8
8
|
import { useCssName } from "../../../hooks/cssname/index.js";
|
|
9
9
|
import { useInherit } from "../../../hooks/inherit/index.js";
|
|
10
10
|
import { useObjComponSelected } from "../../common/use.js";
|
|
11
|
-
import { useCompons } from "
|
|
11
|
+
import { useCompons } from "../../../hooks/compons/index.js";
|
|
12
12
|
import { usePropsDefault, viewProps, getProps } from "../../../hooks/props-default/index.js";
|
|
13
13
|
import _sfc_main$1 from "./columns2.js";
|
|
14
14
|
import { vLoading } from "element-plus/es/components/loading/index";
|
|
@@ -23,7 +23,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
23
23
|
const prs = __props;
|
|
24
24
|
const props = usePropsDefault(name, prs, dataProps);
|
|
25
25
|
viewProps(props, name);
|
|
26
|
-
useCompons(provides.compons, props
|
|
26
|
+
useCompons(provides.compons, props);
|
|
27
27
|
const tableRef = ref();
|
|
28
28
|
const emit = __emit;
|
|
29
29
|
const rowObj = ref();
|
|
@@ -120,6 +120,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
120
120
|
function clearSelection() {
|
|
121
121
|
tableRef.value.clearSelection();
|
|
122
122
|
}
|
|
123
|
+
function setCurrentRow(row) {
|
|
124
|
+
tableRef.value.setCurrentRow(row);
|
|
125
|
+
}
|
|
126
|
+
function clearCurrentRow() {
|
|
127
|
+
tableRef.value.setCurrentRow();
|
|
128
|
+
}
|
|
123
129
|
function getSelections() {
|
|
124
130
|
var _a;
|
|
125
131
|
return (_a = tableRef.value) == null ? void 0 : _a.getSelectionRows();
|
|
@@ -133,9 +139,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
133
139
|
});
|
|
134
140
|
__expose({
|
|
135
141
|
...dataExpose,
|
|
136
|
-
clearSelection,
|
|
137
142
|
clearSort,
|
|
143
|
+
setCurrentRow,
|
|
144
|
+
clearCurrentRow,
|
|
138
145
|
getSelections,
|
|
146
|
+
clearSelection,
|
|
139
147
|
toggleRowSelection
|
|
140
148
|
});
|
|
141
149
|
return (_ctx, _cache) => {
|