htui-yllkbz 1.4.24 → 1.4.25
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/lib/htui.common.js +62 -57
- package/lib/htui.common.js.gz +0 -0
- package/lib/htui.css +1 -1
- package/lib/htui.umd.js +62 -57
- package/lib/htui.umd.js.gz +0 -0
- package/lib/htui.umd.min.js +9 -9
- package/lib/htui.umd.min.js.gz +0 -0
- package/package.json +1 -1
- package/src/packages/HtMore/index.vue +14 -4
- package/src/packages/HtPopover/index.vue +43 -33
package/lib/htui.umd.min.js.gz
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @Author: hutao
|
|
5
5
|
* @Date: 2022-09-28 10:24:08
|
|
6
6
|
* @LastEditors: hutao
|
|
7
|
-
* @LastEditTime: 2023-04-
|
|
7
|
+
* @LastEditTime: 2023-04-25 09:45:13
|
|
8
8
|
-->
|
|
9
9
|
<template>
|
|
10
10
|
<el-dropdown :trigger="trigger" @command="handleCommand($event, 'command')">
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
>删除</el-dropdown-item
|
|
30
30
|
>
|
|
31
31
|
</el-popconfirm> -->
|
|
32
|
-
<el-popover
|
|
32
|
+
<!-- <el-popover
|
|
33
33
|
width="200"
|
|
34
34
|
trigger="click"
|
|
35
35
|
v-model="state.visible"
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
style="color:var(--danger);font-size:16px"
|
|
43
43
|
></i>
|
|
44
44
|
<p style="padding:0 0 0 6px;margin:0">
|
|
45
|
-
{{
|
|
45
|
+
{{ `删除后无法恢复,请确认是否删除${tips ? `【${tips}】` : ''}?` }}
|
|
46
46
|
</p>
|
|
47
47
|
</div>
|
|
48
48
|
<div style="text-align:right;width:100%;margin-top:16px">
|
|
@@ -62,7 +62,16 @@
|
|
|
62
62
|
<el-dropdown-item slot="reference" command="delete"
|
|
63
63
|
>删除</el-dropdown-item
|
|
64
64
|
>
|
|
65
|
-
</el-popover>
|
|
65
|
+
</el-popover> -->
|
|
66
|
+
<ht-popover
|
|
67
|
+
@confirm="handleCommand('delete', 'confirm')"
|
|
68
|
+
:tips="`删除后无法恢复,请确认是否删除${tips ? `【${tips}】` : ''}?`"
|
|
69
|
+
v-if="!!showTabs.includes('delete')"
|
|
70
|
+
>
|
|
71
|
+
<el-dropdown-item slot="reference" command="delete"
|
|
72
|
+
>删除</el-dropdown-item
|
|
73
|
+
>
|
|
74
|
+
</ht-popover>
|
|
66
75
|
</el-dropdown-menu>
|
|
67
76
|
</el-dropdown>
|
|
68
77
|
</template>
|
|
@@ -93,6 +102,7 @@ export default class Index extends Vue {
|
|
|
93
102
|
};
|
|
94
103
|
/** 生命周期 */
|
|
95
104
|
handleCommand(e: string, type: string) {
|
|
105
|
+
// console.log('e', e, type);
|
|
96
106
|
if (type === 'command' && e === 'delete') {
|
|
97
107
|
//console.log('111');
|
|
98
108
|
// this.$confirm(`请确认是否删除${this.tips ? `【${this.tips}】` : ''}?`)
|
|
@@ -4,41 +4,50 @@
|
|
|
4
4
|
* @Author: hutao
|
|
5
5
|
* @Date: 2022-09-28 10:24:08
|
|
6
6
|
* @LastEditors: hutao
|
|
7
|
-
* @LastEditTime: 2023-04-
|
|
7
|
+
* @LastEditTime: 2023-04-25 09:38:05
|
|
8
8
|
-->
|
|
9
9
|
<template>
|
|
10
|
-
<el-popover
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
10
|
+
<el-popover
|
|
11
|
+
placement="top-start"
|
|
12
|
+
:width="width"
|
|
13
|
+
:disabled="!!disabled"
|
|
14
|
+
:trigger="trigger"
|
|
15
|
+
v-model="state.visible"
|
|
16
|
+
>
|
|
17
|
+
<template
|
|
18
|
+
><slot>
|
|
19
|
+
<div>
|
|
20
|
+
<div style="display:flex;margin-top:12px">
|
|
21
|
+
<i :class="icon" :style="iconStyle"></i>
|
|
22
|
+
<p style="padding:0 0 0 6px;margin:0">
|
|
23
|
+
{{ tips }}
|
|
24
|
+
</p>
|
|
25
|
+
</div>
|
|
26
|
+
<div style="text-align:right;width:100%;margin-top:16px">
|
|
27
|
+
<el-button
|
|
28
|
+
:type="okType"
|
|
29
|
+
size="mini"
|
|
30
|
+
@click="
|
|
31
|
+
state.visible = false;
|
|
32
|
+
$emit('confirm');
|
|
33
|
+
"
|
|
34
|
+
style=""
|
|
35
|
+
>{{ okText }}</el-button
|
|
36
|
+
>
|
|
37
|
+
<el-button
|
|
38
|
+
size="mini"
|
|
39
|
+
:type="cancelType"
|
|
40
|
+
@click="
|
|
41
|
+
state.visible = false;
|
|
42
|
+
$emit('cancel');
|
|
43
|
+
"
|
|
44
|
+
>{{ cancelText }}</el-button
|
|
45
|
+
>
|
|
46
|
+
</div>
|
|
18
47
|
</div>
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
size="mini"
|
|
23
|
-
@click="
|
|
24
|
-
state.visible = false;
|
|
25
|
-
$emit('confirm');
|
|
26
|
-
"
|
|
27
|
-
style=""
|
|
28
|
-
></el-button>
|
|
29
|
-
<el-button
|
|
30
|
-
size="mini"
|
|
31
|
-
:type="cancelType"
|
|
32
|
-
@click="
|
|
33
|
-
state.visible = false;
|
|
34
|
-
$emit('cancel');
|
|
35
|
-
"
|
|
36
|
-
>{{ cancelText }}</el-button
|
|
37
|
-
>
|
|
38
|
-
</div>
|
|
39
|
-
</div>
|
|
40
|
-
</slot>
|
|
41
|
-
<slot name="reference"></slot>
|
|
48
|
+
</slot>
|
|
49
|
+
</template>
|
|
50
|
+
<template slot="reference"> <slot name="reference"></slot></template>
|
|
42
51
|
</el-popover>
|
|
43
52
|
</template>
|
|
44
53
|
<script lang="ts">
|
|
@@ -65,9 +74,10 @@ export default class Index extends Vue {
|
|
|
65
74
|
@Prop({ default: 'danger' }) okType?: string;
|
|
66
75
|
@Prop() cancelType?: string;
|
|
67
76
|
@Prop({ default: 'el-icon-warning' }) icon?: string;
|
|
68
|
-
@Prop() tips?: string;
|
|
77
|
+
@Prop({ default: '删除后无法恢复,请确认是否删除' }) tips?: string;
|
|
69
78
|
@Prop({ default: 'click' }) trigger?: string;
|
|
70
79
|
@Prop({ default: 200 }) width?: number;
|
|
80
|
+
@Prop() disabled?: boolean;
|
|
71
81
|
@Prop({ default: 'color:var(--danger);font-size:16px' }) iconStyle?: string;
|
|
72
82
|
|
|
73
83
|
/** 数据 */
|