@fangzhongya/fang-ui 0.1.39 → 0.1.41
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/common/use.cjs +148 -101
- package/dist/components/common/use.d.ts +26 -6
- package/dist/components/common/use.js +149 -102
- package/dist/components/company-select/src/index2.cjs +1 -2
- package/dist/components/company-select/src/index2.js +1 -2
- package/dist/components/double/src/index2.cjs +2 -2
- package/dist/components/double/src/index2.js +2 -2
- package/dist/components/forms/index.css +18 -0
- package/dist/components/forms/src/index2.cjs +9 -6
- package/dist/components/forms/src/index2.js +9 -6
- package/dist/components/forms/src/setup.cjs +9 -12
- package/dist/components/forms/src/setup.js +9 -12
- package/dist/components/forms/src/util.cjs +6 -8
- package/dist/components/forms/src/util.js +6 -8
- package/dist/components/forms-div/src/data.cjs +8 -5
- package/dist/components/forms-div/src/data.d.ts +21 -3
- package/dist/components/forms-div/src/data.js +8 -5
- package/dist/components/forms-div/src/index2.cjs +41 -70
- package/dist/components/forms-div/src/index2.js +43 -72
- package/dist/components/forms-item/index.css +49 -0
- package/dist/components/forms-item/src/data.cjs +6 -0
- package/dist/components/forms-item/src/data.d.ts +19 -0
- package/dist/components/forms-item/src/data.js +6 -0
- package/dist/components/forms-item/src/index2.cjs +11 -7
- package/dist/components/forms-item/src/index2.js +11 -7
- package/dist/components/forms-item/src/indexts.d.ts +40 -1
- package/dist/components/forms-item/src/label.cjs +7 -1
- package/dist/components/forms-item/src/label.d.ts +40 -1
- package/dist/components/forms-item/src/label.js +7 -1
- package/dist/components/forms-items/index.css +18 -0
- package/dist/components/forms-items/index.scss +21 -0
- package/dist/components/forms-items/src/data.cjs +9 -0
- package/dist/components/forms-items/src/data.d.ts +22 -0
- package/dist/components/forms-items/src/data.js +9 -0
- package/dist/components/forms-items/src/index2.cjs +22 -10
- package/dist/components/forms-items/src/index2.js +22 -10
- package/dist/components/forms-items/style/index2.scss +1 -0
- package/dist/components/icon/src/index2.cjs +1 -2
- package/dist/components/icon/src/index2.js +1 -2
- package/dist/components/input-history/src/index2.cjs +1 -1
- package/dist/components/input-history/src/index2.js +1 -1
- package/dist/components/input-select/src/index2.cjs +0 -2
- package/dist/components/input-select/src/index2.js +0 -2
- package/dist/components/inputs/src/index2.cjs +1 -1
- package/dist/components/inputs/src/index2.js +1 -1
- package/dist/components/list/src/index2.cjs +4 -8
- package/dist/components/list/src/index2.js +4 -8
- package/dist/components/list/src/util.cjs +7 -5
- package/dist/components/list/src/util.d.ts +29 -1
- package/dist/components/list/src/util.js +7 -5
- package/dist/components/lists/src/index2.cjs +1 -2
- package/dist/components/lists/src/index2.js +1 -2
- package/dist/components/menus/src/util.cjs +8 -24
- package/dist/components/menus/src/util.js +9 -25
- package/dist/components/page/index.css +18 -0
- package/dist/components/right-key/src/index2.cjs +3 -3
- package/dist/components/right-key/src/index2.js +3 -3
- package/dist/components/seamless-scroll/src/index2.cjs +1 -1
- package/dist/components/seamless-scroll/src/index2.js +1 -1
- package/dist/components/selects/src/index2.cjs +2 -2
- package/dist/components/selects/src/index2.js +2 -2
- package/dist/components/stick-edge/src/index2.cjs +2 -2
- package/dist/components/stick-edge/src/index2.js +2 -2
- package/dist/components/switchs/src/index2.cjs +1 -1
- package/dist/components/switchs/src/index2.js +1 -1
- package/dist/components/tables/common/com-color2.cjs +0 -3
- package/dist/components/tables/common/com-color2.js +0 -3
- package/dist/components/tables/common/com-lis2.cjs +0 -1
- package/dist/components/tables/common/com-lis2.js +0 -1
- package/dist/components/tables/common/pagin.d.ts +6 -0
- package/dist/components/tables/common/tooltip.cjs +1 -1
- package/dist/components/tables/common/tooltip.js +1 -1
- package/dist/components/tables/common/util.cjs +2 -4
- package/dist/components/tables/common/util.js +2 -4
- package/dist/components/tables/src/column.cjs +11 -3
- package/dist/components/tables/src/column.d.ts +29 -0
- package/dist/components/tables/src/column.js +11 -3
- package/dist/components/tables/src/columns.d.ts +7 -0
- package/dist/components/tables/src/columns3.cjs +1 -7
- package/dist/components/tables/src/columns3.js +1 -7
- package/dist/components/tables/src/index2.cjs +2 -2
- package/dist/components/tables/src/index2.js +2 -2
- package/dist/components/tablesv/src/column.cjs +11 -3
- package/dist/components/tablesv/src/column.d.ts +25 -0
- package/dist/components/tablesv/src/column.js +11 -3
- package/dist/components/tablesv/src/columns.d.ts +7 -0
- package/dist/components/tablesv/src/columns3.cjs +1 -7
- package/dist/components/tablesv/src/columns3.js +1 -7
- package/dist/components/tablesv/src/index2.cjs +2 -2
- package/dist/components/tablesv/src/index2.js +2 -2
- package/dist/components/uploads/src/util.cjs +2 -3
- package/dist/components/uploads/src/util.d.ts +7 -0
- package/dist/components/uploads/src/util.js +2 -3
- package/dist/css/forms-item.css +49 -0
- package/dist/css/forms-items.css +18 -0
- package/dist/css/forms.css +18 -0
- package/dist/css/index.css +18 -0
- package/dist/css/page.css +18 -0
- package/dist/directives/adjust/index.cjs +4 -8
- package/dist/directives/adjust/index.js +4 -8
- package/dist/directives/drag/index.cjs +6 -1
- package/dist/directives/drag/index.js +6 -1
- package/dist/directives/expose/index.cjs +6 -0
- package/dist/directives/expose/index.js +6 -0
- package/dist/directives/inserted/index.cjs +5 -0
- package/dist/directives/inserted/index.js +5 -0
- package/dist/directives/locus/index.cjs +5 -0
- package/dist/directives/locus/index.js +5 -0
- package/dist/directives/scroll/index.cjs +10 -0
- package/dist/directives/scroll/index.d.ts +0 -5
- package/dist/directives/scroll/index.js +10 -0
- package/dist/directives/sortable/index.cjs +5 -0
- package/dist/directives/sortable/index.js +5 -0
- package/dist/directives/stick/index.cjs +13 -8
- package/dist/directives/stick/index.js +13 -8
- package/dist/hooks/attrs-default/index.d.ts +5 -3
- package/dist/hooks/compons/index.d.ts +13 -0
- package/dist/hooks/cssname/index.cjs +1 -1
- package/dist/hooks/cssname/index.d.ts +22 -1
- package/dist/hooks/cssname/index.js +1 -1
- package/dist/hooks/default-config/index.d.ts +10 -0
- package/dist/hooks/expose/index.cjs +2 -0
- package/dist/hooks/expose/index.d.ts +6 -0
- package/dist/hooks/expose/index.js +2 -0
- package/dist/hooks/full-screen/index.d.ts +6 -0
- package/dist/hooks/global-config/index.d.ts +16 -0
- package/dist/hooks/inherit/index.cjs +2 -0
- package/dist/hooks/inherit/index.d.ts +8 -0
- package/dist/hooks/inherit/index.js +2 -0
- package/dist/hooks/locale/index.d.ts +24 -0
- package/dist/hooks/props-default/index.d.ts +14 -5
- package/dist/icons/iconify.d.ts +7 -0
- package/dist/icons/iconifyCss.d.ts +6 -0
- package/dist/icons/index.json +1 -1
- package/dist/index.css +18 -0
- package/dist/type.d.ts +8 -0
- package/dist/utils/local.cjs +12 -6
- package/dist/utils/local.js +12 -6
- package/dist/utils/util.cjs +7 -5
- package/dist/utils/util.js +7 -5
- package/package.json +3 -3
|
@@ -40,14 +40,22 @@ function handlePropertyMapping(value, ckey, obj, robj) {
|
|
|
40
40
|
handler();
|
|
41
41
|
}
|
|
42
42
|
function setSslot(obj, scope, emit, slots, props, index$12) {
|
|
43
|
-
const
|
|
43
|
+
const optionss = props.options || {};
|
|
44
|
+
const slot = use.useSetSlot(
|
|
45
|
+
obj,
|
|
46
|
+
scope.row,
|
|
47
|
+
slots,
|
|
48
|
+
optionss,
|
|
49
|
+
emit,
|
|
50
|
+
index$12,
|
|
51
|
+
scope
|
|
52
|
+
);
|
|
44
53
|
if (slot) {
|
|
45
54
|
return slot;
|
|
46
55
|
}
|
|
47
56
|
if (obj.compon) {
|
|
48
57
|
const isComponSelected = props.isComponSelected;
|
|
49
58
|
if (isComponSelected(obj, scope)) {
|
|
50
|
-
const optionss = props.options || {};
|
|
51
59
|
const column = use.useSetCompon(
|
|
52
60
|
obj,
|
|
53
61
|
scope.row,
|
|
@@ -55,7 +63,7 @@ function setSslot(obj, scope, emit, slots, props, index$12) {
|
|
|
55
63
|
index.useComponsGet(config.provides.compons),
|
|
56
64
|
emit,
|
|
57
65
|
index$12,
|
|
58
|
-
{ ...scope, options:
|
|
66
|
+
{ ...scope, options: optionss, config: props.table }
|
|
59
67
|
);
|
|
60
68
|
if (column) {
|
|
61
69
|
return column;
|
|
@@ -1,8 +1,37 @@
|
|
|
1
1
|
import { VNode, RendererNode, RendererElement } from 'vue';
|
|
2
|
+
/**
|
|
3
|
+
* 设置表头函数
|
|
4
|
+
* @param obj - 列表对象
|
|
5
|
+
* @param scope - 作用域对象
|
|
6
|
+
* @param slots - 插槽对象
|
|
7
|
+
* @param emit - 事件发射函数
|
|
8
|
+
* @param props - 属性对象
|
|
9
|
+
* @param index - 索引值
|
|
10
|
+
* @returns 返回处理后的DOM标签
|
|
11
|
+
*/
|
|
2
12
|
export declare function setHeader(obj: ListObj, scope: ObjAny, slots: ObjAny, emit: Function, props: ObjAny, index: number): any;
|
|
13
|
+
/**
|
|
14
|
+
* 获取表格列组件
|
|
15
|
+
* @param obj - 列配置对象,包含列的基本信息和配置
|
|
16
|
+
* @param emit - 事件发射函数,用于触发自定义事件
|
|
17
|
+
* @param props - 组件属性对象
|
|
18
|
+
* @param slots - 插槽对象,包含自定义插槽内容
|
|
19
|
+
* @param index - 列索引位置
|
|
20
|
+
* @param def - 默认渲染函数,可选参数
|
|
21
|
+
* @returns 返回Element Plus的TableColumn组件实例
|
|
22
|
+
*/
|
|
3
23
|
export declare function getTableColumn(obj: ListObj, emit: Function, props: ObjAny, slots: ObjAny, index: number, def?: Function): VNode<RendererNode, RendererElement, {
|
|
4
24
|
[key: string]: any;
|
|
5
25
|
}>;
|
|
26
|
+
/**
|
|
27
|
+
* 渲染列组件的函数
|
|
28
|
+
* @param obj - 列表对象,包含列的配置信息
|
|
29
|
+
* @param emit - 事件发射函数,用于触发自定义事件
|
|
30
|
+
* @param props - 组件属性对象,包含传入的props数据
|
|
31
|
+
* @param slots - 插槽对象,包含可用的插槽内容
|
|
32
|
+
* @param index - 当前项的索引位置
|
|
33
|
+
* @returns 返回渲染后的DOM元素
|
|
34
|
+
*/
|
|
6
35
|
export declare function columnRender(obj: ListObj, emit: Function, props: ObjAny, slots: ObjAny, index: number): VNode<RendererNode, RendererElement, {
|
|
7
36
|
[key: string]: any;
|
|
8
37
|
}>;
|
|
@@ -38,14 +38,22 @@ function handlePropertyMapping(value, ckey, obj, robj) {
|
|
|
38
38
|
handler();
|
|
39
39
|
}
|
|
40
40
|
function setSslot(obj, scope, emit, slots, props, index) {
|
|
41
|
-
const
|
|
41
|
+
const optionss = props.options || {};
|
|
42
|
+
const slot = useSetSlot(
|
|
43
|
+
obj,
|
|
44
|
+
scope.row,
|
|
45
|
+
slots,
|
|
46
|
+
optionss,
|
|
47
|
+
emit,
|
|
48
|
+
index,
|
|
49
|
+
scope
|
|
50
|
+
);
|
|
42
51
|
if (slot) {
|
|
43
52
|
return slot;
|
|
44
53
|
}
|
|
45
54
|
if (obj.compon) {
|
|
46
55
|
const isComponSelected = props.isComponSelected;
|
|
47
56
|
if (isComponSelected(obj, scope)) {
|
|
48
|
-
const optionss = props.options || {};
|
|
49
57
|
const column = useSetCompon(
|
|
50
58
|
obj,
|
|
51
59
|
scope.row,
|
|
@@ -53,7 +61,7 @@ function setSslot(obj, scope, emit, slots, props, index) {
|
|
|
53
61
|
useComponsGet(provides.compons),
|
|
54
62
|
emit,
|
|
55
63
|
index,
|
|
56
|
-
{ ...scope, options:
|
|
64
|
+
{ ...scope, options: optionss, config: props.table }
|
|
57
65
|
);
|
|
58
66
|
if (column) {
|
|
59
67
|
return column;
|
|
@@ -12,13 +12,7 @@ function getLists(arrs, emit, props, slots, listobj) {
|
|
|
12
12
|
if (obj.children && obj.children.length > 0) {
|
|
13
13
|
if (obj.isdiv) {
|
|
14
14
|
arr.push(
|
|
15
|
-
...getLists(
|
|
16
|
-
obj.children,
|
|
17
|
-
emit,
|
|
18
|
-
props,
|
|
19
|
-
slots,
|
|
20
|
-
obj
|
|
21
|
-
)
|
|
15
|
+
...getLists(obj.children, emit, props, slots, obj)
|
|
22
16
|
);
|
|
23
17
|
} else {
|
|
24
18
|
arr.push(
|
|
@@ -10,13 +10,7 @@ function getLists(arrs, emit, props, slots, listobj) {
|
|
|
10
10
|
if (obj.children && obj.children.length > 0) {
|
|
11
11
|
if (obj.isdiv) {
|
|
12
12
|
arr.push(
|
|
13
|
-
...getLists(
|
|
14
|
-
obj.children,
|
|
15
|
-
emit,
|
|
16
|
-
props,
|
|
17
|
-
slots,
|
|
18
|
-
obj
|
|
19
|
-
)
|
|
13
|
+
...getLists(obj.children, emit, props, slots, obj)
|
|
20
14
|
);
|
|
21
15
|
} else {
|
|
22
16
|
arr.push(
|
|
@@ -135,8 +135,8 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
135
135
|
return tableRef.value;
|
|
136
136
|
};
|
|
137
137
|
vue.onMounted(() => {
|
|
138
|
-
if (
|
|
139
|
-
|
|
138
|
+
if (globalThis) {
|
|
139
|
+
globalThis.addEventListener("click", () => {
|
|
140
140
|
isfocus.value = false;
|
|
141
141
|
});
|
|
142
142
|
}
|
|
@@ -133,8 +133,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
133
133
|
return tableRef.value;
|
|
134
134
|
};
|
|
135
135
|
onMounted(() => {
|
|
136
|
-
if (
|
|
137
|
-
|
|
136
|
+
if (globalThis) {
|
|
137
|
+
globalThis.addEventListener("click", () => {
|
|
138
138
|
isfocus.value = false;
|
|
139
139
|
});
|
|
140
140
|
}
|
|
@@ -71,14 +71,22 @@ function handleSelectableConfig(obj, vxeconfig, table) {
|
|
|
71
71
|
};
|
|
72
72
|
}
|
|
73
73
|
function setSslot(obj, scope, emit, slots, props, index$12) {
|
|
74
|
-
const
|
|
74
|
+
const optionss = props.options || {};
|
|
75
|
+
const slot = use.useSetSlot(
|
|
76
|
+
obj,
|
|
77
|
+
scope.row,
|
|
78
|
+
slots,
|
|
79
|
+
optionss,
|
|
80
|
+
emit,
|
|
81
|
+
index$12,
|
|
82
|
+
scope
|
|
83
|
+
);
|
|
75
84
|
if (slot) {
|
|
76
85
|
return slot;
|
|
77
86
|
}
|
|
78
87
|
if (obj.compon) {
|
|
79
88
|
const isComponSelected = props.isComponSelected;
|
|
80
89
|
if (isComponSelected(obj, scope)) {
|
|
81
|
-
const optionss = props.options || {};
|
|
82
90
|
const column2 = use.useSetCompon(
|
|
83
91
|
obj,
|
|
84
92
|
scope.row,
|
|
@@ -86,7 +94,7 @@ function setSslot(obj, scope, emit, slots, props, index$12) {
|
|
|
86
94
|
index.useComponsGet(config.provides.compons),
|
|
87
95
|
emit,
|
|
88
96
|
index$12,
|
|
89
|
-
{ ...scope, options:
|
|
97
|
+
{ ...scope, options: optionss, config: props.table }
|
|
90
98
|
);
|
|
91
99
|
if (column2) {
|
|
92
100
|
return column2;
|
|
@@ -1,6 +1,31 @@
|
|
|
1
1
|
import { VNode, RendererNode, RendererElement } from 'vue';
|
|
2
|
+
/**
|
|
3
|
+
* 设置对象属性
|
|
4
|
+
* @param obj - 列表对象,用于获取原始数据
|
|
5
|
+
* @param props - 属性配置对象,包含table和vxeconfig配置
|
|
6
|
+
* @returns 处理后的属性对象
|
|
7
|
+
*/
|
|
2
8
|
export declare function setProps(obj: ListObj, props: ObjAny): ObjAny;
|
|
9
|
+
/**
|
|
10
|
+
* 设置表头函数
|
|
11
|
+
* @param obj - 列表对象
|
|
12
|
+
* @param scope - 作用域对象
|
|
13
|
+
* @param slots - 插槽对象
|
|
14
|
+
* @param emit - 事件发射函数
|
|
15
|
+
* @param props - 属性对象
|
|
16
|
+
* @param index - 索引值
|
|
17
|
+
* @returns 返回处理后的DOM标签
|
|
18
|
+
*/
|
|
3
19
|
export declare function setHeader(obj: ListObj, scope: ObjAny, slots: ObjAny, emit: Function, props: ObjAny, index: number): any;
|
|
20
|
+
/**
|
|
21
|
+
* 渲染列组件的函数
|
|
22
|
+
* @param obj - 列表对象,包含列的相关配置信息
|
|
23
|
+
* @param emit - 事件发射函数,用于触发自定义事件
|
|
24
|
+
* @param props - 组件属性对象,包含传入的props数据
|
|
25
|
+
* @param slots - 插槽对象,包含可用的插槽内容
|
|
26
|
+
* @param index - 当前项的索引位置
|
|
27
|
+
* @returns 返回渲染后的DOM元素
|
|
28
|
+
*/
|
|
4
29
|
export declare function columnRender(obj: ListObj, emit: Function, props: ObjAny, slots: ObjAny, index: number): VNode<RendererNode, RendererElement, {
|
|
5
30
|
[key: string]: any;
|
|
6
31
|
}>;
|
|
@@ -69,14 +69,22 @@ function handleSelectableConfig(obj, vxeconfig, table) {
|
|
|
69
69
|
};
|
|
70
70
|
}
|
|
71
71
|
function setSslot(obj, scope, emit, slots, props, index) {
|
|
72
|
-
const
|
|
72
|
+
const optionss = props.options || {};
|
|
73
|
+
const slot = useSetSlot(
|
|
74
|
+
obj,
|
|
75
|
+
scope.row,
|
|
76
|
+
slots,
|
|
77
|
+
optionss,
|
|
78
|
+
emit,
|
|
79
|
+
index,
|
|
80
|
+
scope
|
|
81
|
+
);
|
|
73
82
|
if (slot) {
|
|
74
83
|
return slot;
|
|
75
84
|
}
|
|
76
85
|
if (obj.compon) {
|
|
77
86
|
const isComponSelected = props.isComponSelected;
|
|
78
87
|
if (isComponSelected(obj, scope)) {
|
|
79
|
-
const optionss = props.options || {};
|
|
80
88
|
const column = useSetCompon(
|
|
81
89
|
obj,
|
|
82
90
|
scope.row,
|
|
@@ -84,7 +92,7 @@ function setSslot(obj, scope, emit, slots, props, index) {
|
|
|
84
92
|
useComponsGet(provides.compons),
|
|
85
93
|
emit,
|
|
86
94
|
index,
|
|
87
|
-
{ ...scope, options:
|
|
95
|
+
{ ...scope, options: optionss, config: props.table }
|
|
88
96
|
);
|
|
89
97
|
if (column) {
|
|
90
98
|
return column;
|
|
@@ -18,13 +18,7 @@ function getLists(arrs, emit, props, slots, listobj) {
|
|
|
18
18
|
if (obj.children && obj.children.length > 0) {
|
|
19
19
|
const slotObj = {
|
|
20
20
|
default: (scope) => {
|
|
21
|
-
return getLists(
|
|
22
|
-
obj.children,
|
|
23
|
-
emit,
|
|
24
|
-
props,
|
|
25
|
-
slots,
|
|
26
|
-
obj
|
|
27
|
-
);
|
|
21
|
+
return getLists(obj.children, emit, props, slots, obj);
|
|
28
22
|
}
|
|
29
23
|
};
|
|
30
24
|
if (obj.type != "selection") {
|
|
@@ -16,13 +16,7 @@ function getLists(arrs, emit, props, slots, listobj) {
|
|
|
16
16
|
if (obj.children && obj.children.length > 0) {
|
|
17
17
|
const slotObj = {
|
|
18
18
|
default: (scope) => {
|
|
19
|
-
return getLists(
|
|
20
|
-
obj.children,
|
|
21
|
-
emit,
|
|
22
|
-
props,
|
|
23
|
-
slots,
|
|
24
|
-
obj
|
|
25
|
-
);
|
|
19
|
+
return getLists(obj.children, emit, props, slots, obj);
|
|
26
20
|
}
|
|
27
21
|
};
|
|
28
22
|
if (obj.type != "selection") {
|
|
@@ -206,8 +206,8 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
206
206
|
return tableRef.value;
|
|
207
207
|
};
|
|
208
208
|
vue.onMounted(() => {
|
|
209
|
-
if (
|
|
210
|
-
|
|
209
|
+
if (globalThis) {
|
|
210
|
+
globalThis.addEventListener("click", () => {
|
|
211
211
|
isfocus.value = false;
|
|
212
212
|
});
|
|
213
213
|
}
|
|
@@ -204,8 +204,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
204
204
|
return tableRef.value;
|
|
205
205
|
};
|
|
206
206
|
onMounted(() => {
|
|
207
|
-
if (
|
|
208
|
-
|
|
207
|
+
if (globalThis) {
|
|
208
|
+
globalThis.addEventListener("click", () => {
|
|
209
209
|
isfocus.value = false;
|
|
210
210
|
});
|
|
211
211
|
}
|
|
@@ -7,8 +7,7 @@ const getExtension = (fileName) => {
|
|
|
7
7
|
const extension = fileName.toLowerCase();
|
|
8
8
|
if (extension) {
|
|
9
9
|
const ks = Object.keys(data.types);
|
|
10
|
-
for (
|
|
11
|
-
const key = ks[index];
|
|
10
|
+
for (const key of ks) {
|
|
12
11
|
if (data.types[key].includes(extension)) {
|
|
13
12
|
return key;
|
|
14
13
|
}
|
|
@@ -65,7 +64,7 @@ function smartFileHandler(url) {
|
|
|
65
64
|
iframe.style.display = "none";
|
|
66
65
|
iframe.src = url;
|
|
67
66
|
iframe.onload = function() {
|
|
68
|
-
|
|
67
|
+
globalThis.open(url, "_blank");
|
|
69
68
|
iframe.remove();
|
|
70
69
|
};
|
|
71
70
|
iframe.onerror = function() {
|
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
import { ListValue } from '../../players/common/util';
|
|
2
2
|
export declare const getType: (accept?: string) => string;
|
|
3
|
+
/**
|
|
4
|
+
* 获取列表项的类型
|
|
5
|
+
* @param obj - 列表值对象,可选参数
|
|
6
|
+
* @param type - 指定的类型,可选参数
|
|
7
|
+
* @param accept - 接受的类型,可选参数
|
|
8
|
+
* @returns 返回确定的类型字符串
|
|
9
|
+
*/
|
|
3
10
|
export declare const getListType: (obj?: ListValue, type?: string, accept?: string) => string;
|
|
4
11
|
/**
|
|
5
12
|
* 从 URL 下载文件
|
|
@@ -5,8 +5,7 @@ const getExtension = (fileName) => {
|
|
|
5
5
|
const extension = fileName.toLowerCase();
|
|
6
6
|
if (extension) {
|
|
7
7
|
const ks = Object.keys(types);
|
|
8
|
-
for (
|
|
9
|
-
const key = ks[index];
|
|
8
|
+
for (const key of ks) {
|
|
10
9
|
if (types[key].includes(extension)) {
|
|
11
10
|
return key;
|
|
12
11
|
}
|
|
@@ -63,7 +62,7 @@ function smartFileHandler(url) {
|
|
|
63
62
|
iframe.style.display = "none";
|
|
64
63
|
iframe.src = url;
|
|
65
64
|
iframe.onload = function() {
|
|
66
|
-
|
|
65
|
+
globalThis.open(url, "_blank");
|
|
67
66
|
iframe.remove();
|
|
68
67
|
};
|
|
69
68
|
iframe.onerror = function() {
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
:root {
|
|
2
|
+
--on: rgb(91, 189, 246);
|
|
3
|
+
--color-primary: #409eff;
|
|
4
|
+
--bag-primary: #409eff;
|
|
5
|
+
--bag-primary-text: #ffffff;
|
|
6
|
+
--border: #eee;
|
|
7
|
+
--layout-panel-gap: 10px;
|
|
8
|
+
--layout-panel-padding: 20px;
|
|
9
|
+
--layout-form-item-padding-right: var(
|
|
10
|
+
--layout-panel-gap
|
|
11
|
+
);
|
|
12
|
+
--g-main-bg: var(--bg-color-page);
|
|
13
|
+
--lable-array-height: 20px;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.com-footer {
|
|
17
|
+
border-top: 1px solid var(--border);
|
|
18
|
+
padding: 20px 20px;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.com-lable-array {
|
|
22
|
+
line-height: var(--lable-array-height);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.forms-div {
|
|
26
|
+
width: 100%;
|
|
27
|
+
height: 100%;
|
|
28
|
+
}
|
|
29
|
+
.forms-div-com {
|
|
30
|
+
height: 100%;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.forms-item {
|
|
34
|
+
width: 100%;
|
|
35
|
+
}
|
|
36
|
+
.forms-item-el-item.is-height {
|
|
37
|
+
min-height: var(--forms-item-row-height);
|
|
38
|
+
}
|
|
39
|
+
.forms-item-el-item.is-height .el-form-item__label {
|
|
40
|
+
height: var(--forms-item-row-height);
|
|
41
|
+
line-height: var(--forms-item-row-height);
|
|
42
|
+
}
|
|
43
|
+
.forms-item-el-item .el-form-item__label {
|
|
44
|
+
white-space: pre-wrap;
|
|
45
|
+
}
|
|
46
|
+
.forms-item-el-item.is-top .el-form-item__content {
|
|
47
|
+
min-height: var(--forms-item-row-height);
|
|
48
|
+
display: grid;
|
|
49
|
+
}
|
package/dist/css/forms-items.css
CHANGED
|
@@ -46,4 +46,22 @@
|
|
|
46
46
|
.forms-item-el-item.is-top .el-form-item__content {
|
|
47
47
|
min-height: var(--forms-item-row-height);
|
|
48
48
|
display: grid;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.forms-items {
|
|
52
|
+
width: 100%;
|
|
53
|
+
}
|
|
54
|
+
.forms-items.row {
|
|
55
|
+
display: flex;
|
|
56
|
+
flex-direction: row;
|
|
57
|
+
}
|
|
58
|
+
.forms-items.column {
|
|
59
|
+
display: flex;
|
|
60
|
+
flex-direction: column;
|
|
61
|
+
}
|
|
62
|
+
.forms-items-li.no-error {
|
|
63
|
+
--el-color-danger: var(--el-border-color);
|
|
64
|
+
}
|
|
65
|
+
.forms-items-li.no-error .el-input__wrapper.is-focus {
|
|
66
|
+
--el-color-danger: var(--el-input-focus-border);
|
|
49
67
|
}
|
package/dist/css/forms.css
CHANGED
|
@@ -49,6 +49,24 @@
|
|
|
49
49
|
display: grid;
|
|
50
50
|
}
|
|
51
51
|
|
|
52
|
+
.forms-items {
|
|
53
|
+
width: 100%;
|
|
54
|
+
}
|
|
55
|
+
.forms-items.row {
|
|
56
|
+
display: flex;
|
|
57
|
+
flex-direction: row;
|
|
58
|
+
}
|
|
59
|
+
.forms-items.column {
|
|
60
|
+
display: flex;
|
|
61
|
+
flex-direction: column;
|
|
62
|
+
}
|
|
63
|
+
.forms-items-li.no-error {
|
|
64
|
+
--el-color-danger: var(--el-border-color);
|
|
65
|
+
}
|
|
66
|
+
.forms-items-li.no-error .el-input__wrapper.is-focus {
|
|
67
|
+
--el-color-danger: var(--el-input-focus-border);
|
|
68
|
+
}
|
|
69
|
+
|
|
52
70
|
.double {
|
|
53
71
|
width: 100%;
|
|
54
72
|
display: inline-flex;
|
package/dist/css/index.css
CHANGED
|
@@ -49,6 +49,24 @@
|
|
|
49
49
|
display: grid;
|
|
50
50
|
}
|
|
51
51
|
|
|
52
|
+
.forms-items {
|
|
53
|
+
width: 100%;
|
|
54
|
+
}
|
|
55
|
+
.forms-items.row {
|
|
56
|
+
display: flex;
|
|
57
|
+
flex-direction: row;
|
|
58
|
+
}
|
|
59
|
+
.forms-items.column {
|
|
60
|
+
display: flex;
|
|
61
|
+
flex-direction: column;
|
|
62
|
+
}
|
|
63
|
+
.forms-items-li.no-error {
|
|
64
|
+
--el-color-danger: var(--el-border-color);
|
|
65
|
+
}
|
|
66
|
+
.forms-items-li.no-error .el-input__wrapper.is-focus {
|
|
67
|
+
--el-color-danger: var(--el-input-focus-border);
|
|
68
|
+
}
|
|
69
|
+
|
|
52
70
|
.double {
|
|
53
71
|
width: 100%;
|
|
54
72
|
display: inline-flex;
|
package/dist/css/page.css
CHANGED
|
@@ -49,6 +49,24 @@
|
|
|
49
49
|
display: grid;
|
|
50
50
|
}
|
|
51
51
|
|
|
52
|
+
.forms-items {
|
|
53
|
+
width: 100%;
|
|
54
|
+
}
|
|
55
|
+
.forms-items.row {
|
|
56
|
+
display: flex;
|
|
57
|
+
flex-direction: row;
|
|
58
|
+
}
|
|
59
|
+
.forms-items.column {
|
|
60
|
+
display: flex;
|
|
61
|
+
flex-direction: column;
|
|
62
|
+
}
|
|
63
|
+
.forms-items-li.no-error {
|
|
64
|
+
--el-color-danger: var(--el-border-color);
|
|
65
|
+
}
|
|
66
|
+
.forms-items-li.no-error .el-input__wrapper.is-focus {
|
|
67
|
+
--el-color-danger: var(--el-input-focus-border);
|
|
68
|
+
}
|
|
69
|
+
|
|
52
70
|
.double {
|
|
53
71
|
width: 100%;
|
|
54
72
|
display: inline-flex;
|
|
@@ -22,9 +22,7 @@ function getPosition(el) {
|
|
|
22
22
|
return obj;
|
|
23
23
|
}
|
|
24
24
|
function getNext(el, paren) {
|
|
25
|
-
|
|
26
|
-
paren = el.parentElement || el;
|
|
27
|
-
}
|
|
25
|
+
paren ?? (paren = el.parentElement ?? el);
|
|
28
26
|
const cs = paren.childNodes;
|
|
29
27
|
let index = 0;
|
|
30
28
|
let k = cs.length;
|
|
@@ -40,9 +38,7 @@ function getNext(el, paren) {
|
|
|
40
38
|
return cs[index];
|
|
41
39
|
}
|
|
42
40
|
function getFront(el, paren) {
|
|
43
|
-
|
|
44
|
-
paren = el.parentElement || el;
|
|
45
|
-
}
|
|
41
|
+
paren ?? (paren = el.parentElement ?? el);
|
|
46
42
|
const cs = paren.childNodes;
|
|
47
43
|
let index = cs.length - 1;
|
|
48
44
|
let k = -1;
|
|
@@ -500,8 +496,8 @@ const vAdjust = {
|
|
|
500
496
|
if (value && Object.keys(value).length > 0) {
|
|
501
497
|
let getVobj = function(e) {
|
|
502
498
|
let is = true;
|
|
503
|
-
for (
|
|
504
|
-
const v =
|
|
499
|
+
for (const fun of arr) {
|
|
500
|
+
const v = fun(e, eps);
|
|
505
501
|
if (v) {
|
|
506
502
|
vobj = v;
|
|
507
503
|
isCur = true;
|
|
@@ -20,9 +20,7 @@ function getPosition(el) {
|
|
|
20
20
|
return obj;
|
|
21
21
|
}
|
|
22
22
|
function getNext(el, paren) {
|
|
23
|
-
|
|
24
|
-
paren = el.parentElement || el;
|
|
25
|
-
}
|
|
23
|
+
paren ?? (paren = el.parentElement ?? el);
|
|
26
24
|
const cs = paren.childNodes;
|
|
27
25
|
let index = 0;
|
|
28
26
|
let k = cs.length;
|
|
@@ -38,9 +36,7 @@ function getNext(el, paren) {
|
|
|
38
36
|
return cs[index];
|
|
39
37
|
}
|
|
40
38
|
function getFront(el, paren) {
|
|
41
|
-
|
|
42
|
-
paren = el.parentElement || el;
|
|
43
|
-
}
|
|
39
|
+
paren ?? (paren = el.parentElement ?? el);
|
|
44
40
|
const cs = paren.childNodes;
|
|
45
41
|
let index = cs.length - 1;
|
|
46
42
|
let k = -1;
|
|
@@ -498,8 +494,8 @@ const vAdjust = {
|
|
|
498
494
|
if (value && Object.keys(value).length > 0) {
|
|
499
495
|
let getVobj = function(e) {
|
|
500
496
|
let is = true;
|
|
501
|
-
for (
|
|
502
|
-
const v =
|
|
497
|
+
for (const fun of arr) {
|
|
498
|
+
const v = fun(e, eps);
|
|
503
499
|
if (v) {
|
|
504
500
|
vobj = v;
|
|
505
501
|
isCur = true;
|
|
@@ -28,7 +28,7 @@ function setDom(dom, el, value) {
|
|
|
28
28
|
});
|
|
29
29
|
};
|
|
30
30
|
const handleMouseMove = (event) => {
|
|
31
|
-
if (
|
|
31
|
+
if (value.often === void 0 || value.often) {
|
|
32
32
|
setValue(event);
|
|
33
33
|
}
|
|
34
34
|
if (value.onMouseMove) {
|
|
@@ -77,6 +77,11 @@ function setDom(dom, el, value) {
|
|
|
77
77
|
}
|
|
78
78
|
const vDrag = {
|
|
79
79
|
name: "Drag",
|
|
80
|
+
/**
|
|
81
|
+
* Vue指令的mounted钩子函数,用于在元素挂载时设置DOM相关属性
|
|
82
|
+
* @param el - 指令绑定的DOM元素
|
|
83
|
+
* @param binding - 指令绑定的相关信息对象
|
|
84
|
+
*/
|
|
80
85
|
mounted(el, binding) {
|
|
81
86
|
const value = binding.value;
|
|
82
87
|
let dom;
|
|
@@ -26,7 +26,7 @@ function setDom(dom, el, value) {
|
|
|
26
26
|
});
|
|
27
27
|
};
|
|
28
28
|
const handleMouseMove = (event) => {
|
|
29
|
-
if (
|
|
29
|
+
if (value.often === void 0 || value.often) {
|
|
30
30
|
setValue(event);
|
|
31
31
|
}
|
|
32
32
|
if (value.onMouseMove) {
|
|
@@ -75,6 +75,11 @@ function setDom(dom, el, value) {
|
|
|
75
75
|
}
|
|
76
76
|
const vDrag = {
|
|
77
77
|
name: "Drag",
|
|
78
|
+
/**
|
|
79
|
+
* Vue指令的mounted钩子函数,用于在元素挂载时设置DOM相关属性
|
|
80
|
+
* @param el - 指令绑定的DOM元素
|
|
81
|
+
* @param binding - 指令绑定的相关信息对象
|
|
82
|
+
*/
|
|
78
83
|
mounted(el, binding) {
|
|
79
84
|
const value = binding.value;
|
|
80
85
|
let dom;
|
|
@@ -3,6 +3,12 @@ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toString
|
|
|
3
3
|
const hasOwn = require("@fangzhongya/utils/basic/object/hasOwn");
|
|
4
4
|
const index = {
|
|
5
5
|
name: "expose",
|
|
6
|
+
/**
|
|
7
|
+
* Vue指令的created钩子函数,在指令绑定元素被创建时执行
|
|
8
|
+
* @param el 指令绑定的DOM元素
|
|
9
|
+
* @param binding 包含指令信息的绑定对象
|
|
10
|
+
* @param vnode 虚拟节点对象
|
|
11
|
+
*/
|
|
6
12
|
created(el, binding, vnode) {
|
|
7
13
|
var _a, _b, _c, _d;
|
|
8
14
|
if (!(binding == null ? void 0 : binding.instance)) return;
|