@jetlinks-web/components 2.0.32 → 2.0.34
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/es/FullPage/FullPage.js +1 -1
- package/es/ProTable/Alert.js +73 -0
- package/es/ProTable/Content.js +126 -0
- package/es/ProTable/Header.js +73 -0
- package/es/ProTable/Pagination.js +46 -0
- package/es/ProTable/ProTable.js +310 -0
- package/es/ProTable/index.js +1 -410
- package/es/ProTable/setting.js +119 -0
- package/es/ProTable/style/ProTable.less +120 -0
- package/es/ProTable/style/index.js +1 -1
- package/es/Search/Advanced/SaveHistory.js +1 -1
- package/es/Search/Item.js +1 -1
- package/es/Search/Search.js +1 -1
- package/es/style/index.css +52 -20
- package/es/style/index.less +7 -7
- package/lib/FullPage/FullPage.js +1 -1
- package/lib/ProTable/Alert.js +73 -0
- package/lib/ProTable/Content.js +126 -0
- package/lib/ProTable/Header.js +73 -0
- package/lib/ProTable/Pagination.js +46 -0
- package/lib/ProTable/ProTable.js +310 -0
- package/lib/ProTable/index.js +4 -412
- package/lib/ProTable/setting.js +126 -0
- package/lib/ProTable/style/ProTable.less +120 -0
- package/lib/ProTable/style/index.js +1 -1
- package/lib/Search/Advanced/SaveHistory.js +1 -1
- package/lib/Search/Item.js +1 -1
- package/lib/Search/Search.js +1 -1
- package/lib/style/components.less +0 -1
- package/lib/style/index.css +52 -20
- package/lib/style/index.less +7 -7
- package/package.json +1 -1
- package/es/ProTable/proTableTypes.js +0 -11
- package/es/ProTable/style/index.css +0 -69
- package/es/ProTable/style/index.less +0 -92
- package/lib/ProTable/proTableTypes.js +0 -17
- package/lib/ProTable/style/index.css +0 -69
- package/lib/ProTable/style/index.less +0 -92
package/es/Search/Item.js
CHANGED
|
@@ -78,7 +78,7 @@ function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]
|
|
|
78
78
|
} */
|
|
79
79
|
import { defineComponent as _defineComponent } from 'vue';
|
|
80
80
|
import { unref as _unref, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString, createElementBlock as _createElementBlock, createVNode as _createVNode, Fragment as _Fragment, normalizeStyle as _normalizeStyle, mergeProps as _mergeProps, resolveDynamicComponent as _resolveDynamicComponent, withCtx as _withCtx, createElementVNode as _createElementVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from "vue";
|
|
81
|
-
const _withScopeId = n => (_pushScopeId("data-v-
|
|
81
|
+
const _withScopeId = n => (_pushScopeId("data-v-1716533071139"), n = n(), _popScopeId(), n);
|
|
82
82
|
const _hoisted_1 = { class: "JSearch-item" };
|
|
83
83
|
const _hoisted_2 = {
|
|
84
84
|
key: 0,
|
package/es/Search/Search.js
CHANGED
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
} */
|
|
37
37
|
import { defineComponent as _defineComponent } from 'vue';
|
|
38
38
|
import { renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, createVNode as _createVNode, unref as _unref, withCtx as _withCtx, createBlock as _createBlock, renderSlot as _renderSlot, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, normalizeStyle as _normalizeStyle, createElementVNode as _createElementVNode, normalizeClass as _normalizeClass, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from "vue";
|
|
39
|
-
const _withScopeId = n => (_pushScopeId("data-v-
|
|
39
|
+
const _withScopeId = n => (_pushScopeId("data-v-1716533071278"), n = n(), _popScopeId(), n);
|
|
40
40
|
const _hoisted_1 = { class: "JSearch-content simple" };
|
|
41
41
|
const _hoisted_2 = { class: "JSearch-items" };
|
|
42
42
|
import { Button, Row, Col, Form, FormItemRest, } from 'ant-design-vue';
|
package/es/style/index.css
CHANGED
|
@@ -489,9 +489,8 @@
|
|
|
489
489
|
color: unset;
|
|
490
490
|
}
|
|
491
491
|
.jtable-body-spin {
|
|
492
|
-
|
|
492
|
+
height: 100%;
|
|
493
493
|
width: 100%;
|
|
494
|
-
padding: 16px 24px 24px;
|
|
495
494
|
background-color: #fff;
|
|
496
495
|
}
|
|
497
496
|
.jtable-body-spin .ant-spin-nested-loading {
|
|
@@ -507,51 +506,84 @@
|
|
|
507
506
|
display: flex;
|
|
508
507
|
flex-direction: column;
|
|
509
508
|
}
|
|
510
|
-
.jtable-body-
|
|
509
|
+
.jtable-body-header {
|
|
511
510
|
display: flex;
|
|
512
511
|
justify-content: space-between;
|
|
513
512
|
align-items: center;
|
|
513
|
+
margin-bottom: 16px;
|
|
514
|
+
width: 100%;
|
|
515
|
+
gap: 8px;
|
|
514
516
|
}
|
|
515
|
-
.jtable-body-
|
|
517
|
+
.jtable-body-header .jtable-body-header-left {
|
|
518
|
+
flex: 1;
|
|
519
|
+
min-width: 0;
|
|
520
|
+
}
|
|
521
|
+
.jtable-body-header .jtable-body-header-right {
|
|
516
522
|
display: flex;
|
|
517
523
|
gap: 8px;
|
|
518
524
|
align-items: center;
|
|
519
525
|
}
|
|
520
|
-
.jtable-body-
|
|
526
|
+
.jtable-body-header .jtable-body-header-right .jtable-body-header-right-button {
|
|
527
|
+
width: 62px;
|
|
528
|
+
}
|
|
529
|
+
.jtable-body-header .jtable-body-header-right .jtable-body-header-right-button .right-button-icon {
|
|
521
530
|
font-size: 16px;
|
|
522
531
|
color: #d9d9d9;
|
|
523
532
|
}
|
|
524
|
-
.jtable-body-
|
|
533
|
+
.jtable-body-header .jtable-body-header-right .jtable-body-header-right-button .ant-radio-button-wrapper {
|
|
525
534
|
padding: 0 8px;
|
|
526
535
|
}
|
|
527
|
-
.jtable-body-
|
|
536
|
+
.jtable-body-header .jtable-body-header-right .jtable-body-header-right-button :deep(.ant-radio-button-wrapper-checked) {
|
|
528
537
|
color: #1890ff;
|
|
529
538
|
}
|
|
530
|
-
.jtable-
|
|
539
|
+
.jtable-box {
|
|
531
540
|
flex: 1;
|
|
532
|
-
|
|
541
|
+
min-height: 0;
|
|
533
542
|
}
|
|
534
|
-
.jtable-
|
|
535
|
-
|
|
543
|
+
.jtable-box .jtable-card {
|
|
544
|
+
height: 100%;
|
|
545
|
+
overflow-y: auto;
|
|
536
546
|
}
|
|
537
|
-
.jtable-
|
|
547
|
+
.jtable-box .jtable-card .jtable-card-items {
|
|
538
548
|
display: grid;
|
|
539
549
|
grid-gap: 26px;
|
|
540
550
|
}
|
|
541
|
-
.jtable-
|
|
551
|
+
.jtable-box .jtable-card .jtable-card-items .jtable-card-item {
|
|
542
552
|
display: flex;
|
|
543
553
|
min-width: 0;
|
|
544
554
|
}
|
|
545
|
-
.jtable-
|
|
546
|
-
|
|
555
|
+
.jtable-box .ant-table-wrapper {
|
|
556
|
+
height: 100%;
|
|
557
|
+
}
|
|
558
|
+
.jtable-box .ant-table-wrapper .ant-table {
|
|
559
|
+
height: 100%;
|
|
560
|
+
}
|
|
561
|
+
.jtable-box .ant-table-wrapper .ant-table .ant-table-container {
|
|
562
|
+
height: 100%;
|
|
563
|
+
}
|
|
564
|
+
.jtable-box .ant-table-wrapper .ant-table .ant-table-container .ant-table-content {
|
|
565
|
+
height: 100%;
|
|
566
|
+
}
|
|
567
|
+
.jtable-box .j-table-scroll {
|
|
568
|
+
background-color: red;
|
|
569
|
+
}
|
|
570
|
+
.jtable-box .j-table-scroll .ant-table-container {
|
|
547
571
|
display: flex;
|
|
548
|
-
|
|
572
|
+
flex-direction: column;
|
|
549
573
|
}
|
|
550
|
-
.jtable-
|
|
574
|
+
.jtable-box .j-table-scroll .ant-table-container .ant-table-body {
|
|
575
|
+
flex: 1;
|
|
576
|
+
min-height: 0;
|
|
577
|
+
overflow-y: auto;
|
|
578
|
+
}
|
|
579
|
+
.jtable-alert {
|
|
580
|
+
margin-bottom: 16px;
|
|
581
|
+
}
|
|
582
|
+
.jtable-pagination {
|
|
583
|
+
width: 100%;
|
|
551
584
|
display: flex;
|
|
552
|
-
justify-content:
|
|
553
|
-
|
|
554
|
-
margin: 10% 0;
|
|
585
|
+
justify-content: flex-end;
|
|
586
|
+
margin-top: 16px;
|
|
555
587
|
}
|
|
556
588
|
.JSearch-warp {
|
|
557
589
|
padding: 24px;
|
package/es/style/index.less
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
@import '../Ellipsis/style/index.less';
|
|
2
|
-
@import '../CheckButton/style/index.less';
|
|
3
|
-
@import '../ProLayout/style/style.less';
|
|
4
|
-
@import '../ProTable/style/
|
|
5
|
-
@import '../Search/style/Search.less';
|
|
6
|
-
@import '../Search/style/Item.less';
|
|
7
|
-
@import '../CardSelect/style/index.less';
|
|
1
|
+
@import '../Ellipsis/style/index.less';
|
|
2
|
+
@import '../CheckButton/style/index.less';
|
|
3
|
+
@import '../ProLayout/style/style.less';
|
|
4
|
+
@import '../ProTable/style/ProTable.less';
|
|
5
|
+
@import '../Search/style/Search.less';
|
|
6
|
+
@import '../Search/style/Item.less';
|
|
7
|
+
@import '../CardSelect/style/index.less';
|
package/lib/FullPage/FullPage.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
} */
|
|
7
7
|
import { defineComponent as _defineComponent } from 'vue';
|
|
8
8
|
import { unref as _unref, renderSlot as _renderSlot, createElementVNode as _createElementVNode, normalizeStyle as _normalizeStyle, openBlock as _openBlock, createElementBlock as _createElementBlock, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from "vue";
|
|
9
|
-
const _withScopeId = n => (_pushScopeId("data-v-
|
|
9
|
+
const _withScopeId = n => (_pushScopeId("data-v-1716533070378"), n = n(), _popScopeId(), n);
|
|
10
10
|
const _hoisted_1 = { class: "full-page-warp-content" };
|
|
11
11
|
import { ref } from 'vue';
|
|
12
12
|
import { useElementBounding } from '@vueuse/core';
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) {
|
|
2
|
+
const op = ops[i];
|
|
3
|
+
const fn = ops[i + 1];
|
|
4
|
+
i += 2;
|
|
5
|
+
if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) {
|
|
6
|
+
return undefined;
|
|
7
|
+
}
|
|
8
|
+
if (op === 'access' || op === 'optionalAccess') {
|
|
9
|
+
lastAccessLHS = value;
|
|
10
|
+
value = fn(value);
|
|
11
|
+
}
|
|
12
|
+
else if (op === 'call' || op === 'optionalCall') {
|
|
13
|
+
value = fn((...args) => value.call(lastAccessLHS, ...args));
|
|
14
|
+
lastAccessLHS = undefined;
|
|
15
|
+
}
|
|
16
|
+
} return value; }
|
|
17
|
+
/* Analyzed bindings: {
|
|
18
|
+
"Alert": "setup-maybe-ref",
|
|
19
|
+
"Button": "setup-maybe-ref",
|
|
20
|
+
"computed": "setup-const",
|
|
21
|
+
"_alertProps": "setup-maybe-ref",
|
|
22
|
+
"props": "setup-reactive-const",
|
|
23
|
+
"emits": "setup-const",
|
|
24
|
+
"_message": "setup-ref",
|
|
25
|
+
"onClose": "setup-const"
|
|
26
|
+
} */
|
|
27
|
+
import { defineComponent as _defineComponent } from 'vue';
|
|
28
|
+
import { renderSlot as _renderSlot, createTextVNode as _createTextVNode, unref as _unref, withCtx as _withCtx, createVNode as _createVNode, openBlock as _openBlock, createElementBlock as _createElementBlock } from "vue";
|
|
29
|
+
const _hoisted_1 = { class: "jtable-alert" };
|
|
30
|
+
import { Alert, Button } from 'ant-design-vue';
|
|
31
|
+
import { computed } from "vue";
|
|
32
|
+
import { _alertProps } from "./setting";
|
|
33
|
+
const __sfc_main__ = _defineComponent({
|
|
34
|
+
...{
|
|
35
|
+
name: 'Alert'
|
|
36
|
+
},
|
|
37
|
+
props: { ..._alertProps },
|
|
38
|
+
emits: ['close'],
|
|
39
|
+
setup(__props, { emit: __emit }) {
|
|
40
|
+
const props = __props;
|
|
41
|
+
const emits = __emit;
|
|
42
|
+
const _message = computed(() => {
|
|
43
|
+
return '已选择' + (_optionalChain([props, 'access', _2 => _2.rowSelection, 'optionalAccess', _3 => _3.selectedRowKeys, 'optionalAccess', _4 => _4.length]) || 0) + '项';
|
|
44
|
+
});
|
|
45
|
+
const onClose = () => {
|
|
46
|
+
emits('close');
|
|
47
|
+
};
|
|
48
|
+
return (_ctx, _cache) => {
|
|
49
|
+
return (_openBlock(), _createElementBlock("div", _hoisted_1, [
|
|
50
|
+
_renderSlot(_ctx.$slots, "default", {}, () => [
|
|
51
|
+
_createVNode(_unref(Alert), {
|
|
52
|
+
type: "info",
|
|
53
|
+
message: _message.value
|
|
54
|
+
}, {
|
|
55
|
+
closeText: _withCtx(() => [
|
|
56
|
+
_createVNode(_unref(Button), {
|
|
57
|
+
type: "link",
|
|
58
|
+
onClick: onClose
|
|
59
|
+
}, {
|
|
60
|
+
default: _withCtx(() => [
|
|
61
|
+
_createTextVNode("取消选择")
|
|
62
|
+
]),
|
|
63
|
+
_: 1 /* STABLE */
|
|
64
|
+
})
|
|
65
|
+
]),
|
|
66
|
+
_: 1 /* STABLE */
|
|
67
|
+
}, 8 /* PROPS */, ["message"])
|
|
68
|
+
])
|
|
69
|
+
]));
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
export default __sfc_main__;
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) {
|
|
2
|
+
const op = ops[i];
|
|
3
|
+
const fn = ops[i + 1];
|
|
4
|
+
i += 2;
|
|
5
|
+
if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) {
|
|
6
|
+
return undefined;
|
|
7
|
+
}
|
|
8
|
+
if (op === 'access' || op === 'optionalAccess') {
|
|
9
|
+
lastAccessLHS = value;
|
|
10
|
+
value = fn(value);
|
|
11
|
+
}
|
|
12
|
+
else if (op === 'call' || op === 'optionalCall') {
|
|
13
|
+
value = fn((...args) => value.call(lastAccessLHS, ...args));
|
|
14
|
+
lastAccessLHS = undefined;
|
|
15
|
+
}
|
|
16
|
+
} return value; }
|
|
17
|
+
/* Analyzed bindings: {
|
|
18
|
+
"column": "props",
|
|
19
|
+
"useSlots": "setup-const",
|
|
20
|
+
"computed": "setup-const",
|
|
21
|
+
"_contentProps": "setup-maybe-ref",
|
|
22
|
+
"Table": "setup-maybe-ref",
|
|
23
|
+
"get": "setup-maybe-ref",
|
|
24
|
+
"isString": "setup-maybe-ref",
|
|
25
|
+
"Empty": "setup-maybe-ref",
|
|
26
|
+
"props": "setup-reactive-const",
|
|
27
|
+
"slots": "setup-maybe-ref",
|
|
28
|
+
"_columns": "setup-ref",
|
|
29
|
+
"_scroll": "setup-ref",
|
|
30
|
+
"gridTemplateColumns": "setup-ref"
|
|
31
|
+
} */
|
|
32
|
+
import { defineComponent as _defineComponent } from 'vue';
|
|
33
|
+
import { renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, normalizeProps as _normalizeProps, guardReactiveProps as _guardReactiveProps, renderSlot as _renderSlot, normalizeClass as _normalizeClass, normalizeStyle as _normalizeStyle, unref as _unref, createVNode as _createVNode, mergeProps as _mergeProps, toDisplayString as _toDisplayString, createTextVNode as _createTextVNode, withCtx as _withCtx, createBlock as _createBlock } from "vue";
|
|
34
|
+
const _hoisted_1 = { class: "jtable-box" };
|
|
35
|
+
const _hoisted_2 = {
|
|
36
|
+
key: 0,
|
|
37
|
+
class: "jtable-card"
|
|
38
|
+
};
|
|
39
|
+
const _hoisted_3 = {
|
|
40
|
+
key: 1,
|
|
41
|
+
class: "j-table-empty"
|
|
42
|
+
};
|
|
43
|
+
import { useSlots, computed } from 'vue';
|
|
44
|
+
import { _contentProps } from "./setting";
|
|
45
|
+
import { Table } from 'ant-design-vue';
|
|
46
|
+
import { get, } from 'lodash-es';
|
|
47
|
+
import Empty from '../Empty';
|
|
48
|
+
const __sfc_main__ = _defineComponent({
|
|
49
|
+
...{
|
|
50
|
+
name: 'Content'
|
|
51
|
+
},
|
|
52
|
+
props: {
|
|
53
|
+
..._contentProps,
|
|
54
|
+
column: {
|
|
55
|
+
type: Number,
|
|
56
|
+
default: 4
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
setup(__props) {
|
|
60
|
+
const props = __props;
|
|
61
|
+
const slots = useSlots();
|
|
62
|
+
const _columns = computed(() => props.columns.filter((i) => !_optionalChain([i, 'optionalAccess', _2 => _2.hideInTable])));
|
|
63
|
+
const _scroll = computed(() => {
|
|
64
|
+
let y = _optionalChain([props, 'access', _3 => _3.scroll, 'optionalAccess', _4 => _4.y]) || '100%';
|
|
65
|
+
return {
|
|
66
|
+
x: _optionalChain([props, 'access', _5 => _5.scroll, 'optionalAccess', _6 => _6.x]) || 1366,
|
|
67
|
+
y
|
|
68
|
+
};
|
|
69
|
+
});
|
|
70
|
+
const gridTemplateColumns = computed(() => {
|
|
71
|
+
return `repeat(${props.column}, 1fr)`;
|
|
72
|
+
});
|
|
73
|
+
return (_ctx, _cache) => {
|
|
74
|
+
return (_openBlock(), _createElementBlock("div", _hoisted_1, [
|
|
75
|
+
(_ctx.mode === 'CARD')
|
|
76
|
+
? (_openBlock(), _createElementBlock("div", _hoisted_2, [
|
|
77
|
+
(_ctx.dataSource.length)
|
|
78
|
+
? (_openBlock(), _createElementBlock("div", {
|
|
79
|
+
key: 0,
|
|
80
|
+
class: "jtable-card-items",
|
|
81
|
+
style: _normalizeStyle({ gridTemplateColumns: gridTemplateColumns.value })
|
|
82
|
+
}, [
|
|
83
|
+
(_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.dataSource, (item) => {
|
|
84
|
+
return (_openBlock(), _createElementBlock("div", {
|
|
85
|
+
class: _normalizeClass(['jtable-card-item', props.cardBodyClass]),
|
|
86
|
+
key: item[props.rowKey]
|
|
87
|
+
}, [
|
|
88
|
+
_renderSlot(_ctx.$slots, "card", _normalizeProps(_guardReactiveProps(item)))
|
|
89
|
+
], 2 /* CLASS */));
|
|
90
|
+
}), 128 /* KEYED_FRAGMENT */))
|
|
91
|
+
], 4 /* STYLE */))
|
|
92
|
+
: (_openBlock(), _createElementBlock("div", _hoisted_3, [
|
|
93
|
+
_renderSlot(_ctx.$slots, "emptyText", {}, () => [
|
|
94
|
+
_createVNode(_unref(Empty))
|
|
95
|
+
])
|
|
96
|
+
]))
|
|
97
|
+
]))
|
|
98
|
+
: (_openBlock(), _createBlock(_unref(Table), _mergeProps({ key: 1 }, props, {
|
|
99
|
+
dataSource: _ctx.dataSource,
|
|
100
|
+
columns: _columns.value,
|
|
101
|
+
pagination: false,
|
|
102
|
+
scroll: _scroll.value,
|
|
103
|
+
class: { 'j-table-scroll': !_optionalChain([props, 'access', _7 => _7.scroll, 'optionalAccess', _8 => _8.y]) }
|
|
104
|
+
}), {
|
|
105
|
+
headerCell: _withCtx(({ column, title }) => [
|
|
106
|
+
_renderSlot(_ctx.$slots, "headerCell", _normalizeProps(_guardReactiveProps({ column, title })))
|
|
107
|
+
]),
|
|
108
|
+
bodyCell: _withCtx(({ column, record }) => [
|
|
109
|
+
((_optionalChain([column, 'optionalAccess', _9 => _9.key]) || _optionalChain([column, 'optionalAccess', _10 => _10.dataIndex])) && _optionalChain([column, 'optionalAccess', _11 => _11.scopedSlots]) && (_optionalChain([_unref, 'call', _12 => _12(slots), 'optionalAccess', _13 => _13[_optionalChain([column, 'optionalAccess', _14 => _14.dataIndex])]]) || _optionalChain([_unref, 'call', _15 => _15(slots), 'optionalAccess', _16 => _16[_optionalChain([column, 'optionalAccess', _17 => _17.key])]])))
|
|
110
|
+
? _renderSlot(_ctx.$slots, _optionalChain([column, 'optionalAccess', _18 => _18.key]) || _optionalChain([column, 'optionalAccess', _19 => _19.dataIndex]), _normalizeProps(_mergeProps({ key: 0 }, record)))
|
|
111
|
+
: (_openBlock(), _createElementBlock(_Fragment, { key: 1 }, [
|
|
112
|
+
_createTextVNode(_toDisplayString(_unref(get)(record, _optionalChain([column, 'optionalAccess', _20 => _20.dataIndex]) || _optionalChain([column, 'optionalAccess', _21 => _21.key]))), 1 /* TEXT */)
|
|
113
|
+
], 64 /* STABLE_FRAGMENT */))
|
|
114
|
+
]),
|
|
115
|
+
emptyText: _withCtx(() => [
|
|
116
|
+
_renderSlot(_ctx.$slots, "emptyText", {}, () => [
|
|
117
|
+
_createVNode(_unref(Empty))
|
|
118
|
+
])
|
|
119
|
+
]),
|
|
120
|
+
_: 3 /* FORWARDED */
|
|
121
|
+
}, 16 /* FULL_PROPS */, ["dataSource", "columns", "scroll", "class"]))
|
|
122
|
+
]));
|
|
123
|
+
};
|
|
124
|
+
}
|
|
125
|
+
});
|
|
126
|
+
export default __sfc_main__;
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/* Analyzed bindings: {
|
|
2
|
+
"initMode": "props",
|
|
3
|
+
"RadioGroup": "setup-maybe-ref",
|
|
4
|
+
"RadioButton": "setup-maybe-ref",
|
|
5
|
+
"AIcon": "setup-maybe-ref",
|
|
6
|
+
"_headerProps": "setup-maybe-ref",
|
|
7
|
+
"props": "setup-reactive-const",
|
|
8
|
+
"emits": "setup-const"
|
|
9
|
+
} */
|
|
10
|
+
import { defineComponent as _defineComponent } from 'vue';
|
|
11
|
+
import { renderSlot as _renderSlot, createElementVNode as _createElementVNode, unref as _unref, createVNode as _createVNode, withCtx as _withCtx, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode } from "vue";
|
|
12
|
+
const _hoisted_1 = { class: "jtable-body-header" };
|
|
13
|
+
const _hoisted_2 = { class: "jtable-body-header-left" };
|
|
14
|
+
const _hoisted_3 = { class: "jtable-body-header-right" };
|
|
15
|
+
const _hoisted_4 = {
|
|
16
|
+
key: 0,
|
|
17
|
+
class: "table-body-header-right-button"
|
|
18
|
+
};
|
|
19
|
+
import { RadioGroup, RadioButton } from 'ant-design-vue';
|
|
20
|
+
import AIcon from '../Icon';
|
|
21
|
+
import { _headerProps } from './setting';
|
|
22
|
+
const __sfc_main__ = _defineComponent({
|
|
23
|
+
...{
|
|
24
|
+
name: 'Header'
|
|
25
|
+
},
|
|
26
|
+
props: {
|
|
27
|
+
..._headerProps,
|
|
28
|
+
initMode: {
|
|
29
|
+
type: [String, undefined],
|
|
30
|
+
default: undefined
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
emits: ['change'],
|
|
34
|
+
setup(__props, { emit: __emit }) {
|
|
35
|
+
const props = __props;
|
|
36
|
+
const emits = __emit;
|
|
37
|
+
return (_ctx, _cache) => {
|
|
38
|
+
return (_openBlock(), _createElementBlock("div", _hoisted_1, [
|
|
39
|
+
_createElementVNode("div", _hoisted_2, [
|
|
40
|
+
_renderSlot(_ctx.$slots, "headerLeftRender")
|
|
41
|
+
]),
|
|
42
|
+
_createElementVNode("div", _hoisted_3, [
|
|
43
|
+
_renderSlot(_ctx.$slots, "headerRightRender"),
|
|
44
|
+
(!__props.initMode)
|
|
45
|
+
? (_openBlock(), _createElementBlock("div", _hoisted_4, [
|
|
46
|
+
_createVNode(_unref(RadioGroup), {
|
|
47
|
+
value: _ctx.mode,
|
|
48
|
+
onChange: _cache[0] || (_cache[0] = (e) => emits('change', e))
|
|
49
|
+
}, {
|
|
50
|
+
default: _withCtx(() => [
|
|
51
|
+
_createVNode(_unref(RadioButton), { value: "TABLE" }, {
|
|
52
|
+
default: _withCtx(() => [
|
|
53
|
+
_createVNode(_unref(AIcon), { type: "UnorderedListOutlined" })
|
|
54
|
+
]),
|
|
55
|
+
_: 1 /* STABLE */
|
|
56
|
+
}),
|
|
57
|
+
_createVNode(_unref(RadioButton), { value: "CARD" }, {
|
|
58
|
+
default: _withCtx(() => [
|
|
59
|
+
_createVNode(_unref(AIcon), { type: "AppstoreOutlined" })
|
|
60
|
+
]),
|
|
61
|
+
_: 1 /* STABLE */
|
|
62
|
+
})
|
|
63
|
+
]),
|
|
64
|
+
_: 1 /* STABLE */
|
|
65
|
+
}, 8 /* PROPS */, ["value"])
|
|
66
|
+
]))
|
|
67
|
+
: _createCommentVNode("v-if", true)
|
|
68
|
+
])
|
|
69
|
+
]));
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
export default __sfc_main__;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/* Analyzed bindings: {
|
|
2
|
+
"Pagination": "setup-maybe-ref",
|
|
3
|
+
"paginationProps": "setup-maybe-ref",
|
|
4
|
+
"props": "setup-reactive-const",
|
|
5
|
+
"emits": "setup-const",
|
|
6
|
+
"_showTotal": "setup-const",
|
|
7
|
+
"onChange": "setup-const"
|
|
8
|
+
} */
|
|
9
|
+
import { defineComponent as _defineComponent } from 'vue';
|
|
10
|
+
import { renderSlot as _renderSlot, unref as _unref, createVNode as _createVNode, openBlock as _openBlock, createElementBlock as _createElementBlock } from "vue";
|
|
11
|
+
const _hoisted_1 = { class: "jtable-pagination" };
|
|
12
|
+
import { Pagination } from 'ant-design-vue';
|
|
13
|
+
import { paginationProps } from "./setting";
|
|
14
|
+
const __sfc_main__ = _defineComponent({
|
|
15
|
+
...{
|
|
16
|
+
name: 'Pagination'
|
|
17
|
+
},
|
|
18
|
+
props: { ...paginationProps },
|
|
19
|
+
emits: ['change'],
|
|
20
|
+
setup(__props, { emit: __emit }) {
|
|
21
|
+
const props = __props;
|
|
22
|
+
const emits = __emit;
|
|
23
|
+
const _showTotal = (num) => {
|
|
24
|
+
const minSize = props.pageIndex * props.pageSize + 1;
|
|
25
|
+
const MaxSize = (props.pageIndex + 1) * props.pageSize;
|
|
26
|
+
return `第 ${minSize} - ${MaxSize > num ? num : MaxSize} 条/总共 ${num} 条`;
|
|
27
|
+
};
|
|
28
|
+
const onChange = (page, size) => {
|
|
29
|
+
emits('change', page, size);
|
|
30
|
+
};
|
|
31
|
+
return (_ctx, _cache) => {
|
|
32
|
+
return (_openBlock(), _createElementBlock("div", _hoisted_1, [
|
|
33
|
+
_renderSlot(_ctx.$slots, "default", {}, () => [
|
|
34
|
+
_createVNode(_unref(Pagination), {
|
|
35
|
+
total: _ctx.total,
|
|
36
|
+
pageSize: _ctx.pageSize,
|
|
37
|
+
current: _ctx.pageIndex + 1,
|
|
38
|
+
"show-total": (num) => _showTotal(num),
|
|
39
|
+
onChange: onChange
|
|
40
|
+
}, null, 8 /* PROPS */, ["total", "pageSize", "current", "show-total"])
|
|
41
|
+
])
|
|
42
|
+
]));
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
export default __sfc_main__;
|