qtsk-vue3 0.0.42 → 0.0.44

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.
@@ -25,6 +25,7 @@ import Upload from './components/Upload/index.vue'
25
25
  import Tooltip from './components/Tooltip/index.vue'
26
26
  import Skeleton from './components/Skeleton/index.vue'
27
27
  import Alert from './components/Alert/index.vue'
28
+ import PopConfirm from './components/PopConfirm/index.vue'
28
29
  const components =
29
30
  [
30
31
  CommonButton,
@@ -53,6 +54,7 @@ const components =
53
54
  Upload,
54
55
  Tooltip,
55
56
  Skeleton,
56
- Alert
57
+ Alert,
58
+ PopConfirm
57
59
  ]
58
60
  export default components
@@ -4,7 +4,7 @@
4
4
  @open="handleOpen" @close="handleClose">
5
5
  <el-menu-item :index="menu.url" v-for="(menu, index) in menus.filter(item => item)" :key="index">
6
6
  <Icons :type="menu.icon" v-if="menu.icon"></Icons>
7
- <div v-else class="selfIcon">
7
+ <div v-if="menu.activeImg&&menu.negativeImg" class="selfIcon">
8
8
  <img :src="menu.activeImg" v-if="activeMenu === menu.url"/>
9
9
  <img :src="menu.negativeImg" v-else/>
10
10
  </div>
@@ -85,4 +85,8 @@ const handleClose = (key, keyPath) => {
85
85
  height: 100%;
86
86
  }
87
87
  }
88
+ :deep(.el-menu-item) {
89
+ // display: flex;
90
+ // justify-content: center;
91
+ }
88
92
  </style>
@@ -0,0 +1,52 @@
1
+ <template>
2
+ <el-popconfirm
3
+ :title="title"
4
+ v-bind="$attrs"
5
+ @confirm="confirmEvent"
6
+ @cancel="cancelEvent"
7
+ >
8
+ <template #reference>
9
+ <slot></slot>
10
+ </template>
11
+ <template #actions>
12
+ <slot name="actions"></slot>
13
+ </template>
14
+ </el-popconfirm>
15
+ </template>
16
+
17
+ <script setup>
18
+ import { ElPopconfirm } from 'element-plus'
19
+
20
+ defineOptions({
21
+ name: 'PopConfirm'
22
+ })
23
+ const props = defineProps({
24
+ title: {
25
+ type: String,
26
+ default: '标题'
27
+ },
28
+ confirmButtonText: {
29
+ type: String,
30
+ default: '确认'
31
+ },
32
+ cancelButtonText: {
33
+ type: String,
34
+ default: '取消'
35
+ }
36
+ })
37
+ const emits = defineEmits(['confirm', 'cancel'])
38
+ const confirmEvent = () => {
39
+ console.log('confirm!')
40
+ emits('confirm')
41
+ }
42
+ const cancelEvent = () => {
43
+ console.log('cancel!')
44
+ emits('cancel')
45
+ }
46
+ </script>
47
+
48
+ <style lang="less" scoped>
49
+ :deep(.el-textarea__inner:focus), :deep(.el-input__wrapper.is-focus){
50
+ box-shadow: 0 0 0 1px var(--main-color) inset;
51
+ }
52
+ </style>
@@ -7,6 +7,7 @@
7
7
  :append-to="append"
8
8
  :no-data-text="'暂无数据项'"
9
9
  :clearable="clearable"
10
+ :noMatchText="'暂无匹配数据'"
10
11
  >
11
12
  <el-option v-for="item in options" :key="item[valueName]" :label="item[keyName]" :value="item[valueName]">
12
13
  <div v-if="item.icon" style="display: flex;align-items: center;justify-content: space-between;">
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "qtsk-vue3",
3
- "version": "0.0.42",
3
+ "version": "0.0.44",
4
4
  "description": "vue3版组件库",
5
5
  "main": "./package/index.js",
6
6
  "scripts": {