@ddwl/ddwl-ui 1.3.16 → 1.3.18

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ddwl/ddwl-ui",
3
- "version": "1.3.16",
3
+ "version": "1.3.18",
4
4
  "private": false,
5
5
  "main": "dist/index.common.js",
6
6
  "style": "dist/index.css",
@@ -22,20 +22,17 @@
22
22
  "lint": "vue-cli-service lint",
23
23
  "dev": "vue-cli-service lint && vue-cli-service serve",
24
24
  "build": "vue-cli-service lint && vue-cli-service build --target lib --name index src/main.js",
25
- "release": "npm run build && bumpp -r && npm publish --access=public"
25
+ "release": "npm run build && bumpp -r && npm publish --access=public",
26
+ "pub": "node scripts/publish.js"
26
27
  },
27
28
  "dependencies": {
28
- "@vue/eslint-config-standard": "^8.0.1",
29
29
  "core-js": "^3.8.3",
30
30
  "crypto-js": "^4.2.0",
31
31
  "dayjs": "^1.11.13",
32
32
  "element-ui": "2.15.14",
33
33
  "lodash": "^4.17.21",
34
- "sass": "^1.22.10",
35
- "sass-loader": "^7.2.0",
36
- "sass-resources-loader": "^2.2.5",
37
34
  "sortablejs": "^1.15.3",
38
- "svg-sprite-loader": "^6.0.11",
35
+ "ssh2-sftp-client": "^12.0.1",
39
36
  "vue": "^2.7.14"
40
37
  },
41
38
  "devDependencies": {
@@ -44,6 +41,7 @@
44
41
  "@vue/cli-plugin-babel": "~5.0.0",
45
42
  "@vue/cli-plugin-eslint": "~5.0.0",
46
43
  "@vue/cli-service": "~5.0.0",
44
+ "@vue/eslint-config-standard": "^8.0.1",
47
45
  "babel-eslint": "^10.1.0",
48
46
  "bumpp": "^10.2.0",
49
47
  "conventional-changelog-cli": "^5.0.0",
@@ -51,6 +49,10 @@
51
49
  "eslint-config-prettier": "^10.1.8",
52
50
  "eslint-plugin-prettier": "^5.5.4",
53
51
  "eslint-plugin-vue": "^8.0.3",
52
+ "sass": "^1.22.10",
53
+ "sass-loader": "^7.2.0",
54
+ "sass-resources-loader": "^2.2.5",
55
+ "svg-sprite-loader": "^6.0.11",
54
56
  "vue-template-compiler": "^2.6.14"
55
57
  },
56
58
  "eslintConfig": {
@@ -98,7 +98,7 @@ export default {
98
98
  }
99
99
  },
100
100
  slots() {
101
- return Object.entries(this.config.slots || []).map(([key, value]) => ({
101
+ return Object.entries(this.config.slots || {}).map(([key, value]) => ({
102
102
  slotName: key,
103
103
  render: value
104
104
  }))
@@ -49,7 +49,6 @@
49
49
  </template>
50
50
 
51
51
  <script>
52
- import { template } from 'lodash'
53
52
  import DDialog from '../dialog'
54
53
 
55
54
  export default {
@@ -6,23 +6,23 @@
6
6
  :index="data.path"
7
7
  >
8
8
  <template slot="title">
9
- <img v-if="data.meta.icon" class="mr8 d-menu-icon" :src="data.meta.icon" />
9
+ <img v-if="data.meta.icon" class="d-menu-icon ml5 mr11" :src="data.meta.icon" />
10
10
  <span>{{ data.meta.title }}</span>
11
11
  </template>
12
12
  <menu-item v-for="item in data.children" :key="item.name" :data="item" />
13
13
  </el-submenu>
14
14
  <el-menu-item v-else class="d-menu__submenu-item" :index="data.path">
15
15
  <template slot="title">
16
- <div v-if="data.meta.icon" class="d-menu-icon-box">
16
+ <div v-if="data.meta.icon" class="d-menu-icon-box mr6">
17
17
  <img class="d-menu-icon" :src="data.meta.icon" />
18
18
  </div>
19
19
  <span
20
20
  v-if="data.meta.isNewWindow"
21
- class="ml6 ellipsis flex-1"
21
+ class="ellipsis flex-1"
22
22
  @click.stop="openNewWindow(data)"
23
23
  >{{ data.meta.title }}</span
24
24
  >
25
- <span v-else class="ml6 ellipsis flex-1">{{ data.meta.title }}</span>
25
+ <span v-else class="ellipsis flex-1">{{ data.meta.title }}</span>
26
26
  </template>
27
27
  </el-menu-item>
28
28
  </template>
@@ -50,9 +50,6 @@
50
50
  import FormItem from '../form-item'
51
51
  import { cloneDeep } from 'lodash'
52
52
 
53
- // 初始化表单
54
- let initForm = {}
55
-
56
53
  export default {
57
54
  name: 'DSearchForm',
58
55
  components: {
@@ -64,7 +61,7 @@ export default {
64
61
  },
65
62
  props: {
66
63
  config: {
67
- require: true,
64
+ required: true,
68
65
  default: () => [],
69
66
  type: Array
70
67
  },
@@ -91,6 +88,7 @@ export default {
91
88
  },
92
89
  data() {
93
90
  return {
91
+ initForm: {},
94
92
  list: [],
95
93
  hiddenIndex: 0,
96
94
  emptySpan: 0,
@@ -142,7 +140,7 @@ export default {
142
140
  }
143
141
  },
144
142
  created() {
145
- initForm = cloneDeep(this.value)
143
+ this.initForm = cloneDeep(this.value)
146
144
  this.$nextTick(() => {
147
145
  this.hasSlot = !!(this.$slots.default && this.$slots.default.length)
148
146
  this.calcSpan()
@@ -168,7 +166,7 @@ export default {
168
166
  * @description: 重置
169
167
  */
170
168
  async reset() {
171
- this.form = cloneDeep(initForm)
169
+ this.form = cloneDeep(this.initForm)
172
170
  this.$emit('search')
173
171
  if (this.searchData) {
174
172
  this.resetLoading = true
@@ -96,7 +96,7 @@ export default {
96
96
  // request config
97
97
  requestConfig: {
98
98
  type: Object,
99
- require: false,
99
+ required: false,
100
100
  default: () => ({
101
101
  api: () => {}, // 接口
102
102
  params: {}, // 默认参数
@@ -242,8 +242,9 @@ export default {
242
242
  })
243
243
  this.total = total
244
244
  this.handleRequestData(data)
245
- // eslint-disable-next-line no-empty
246
- } catch (e) {}
245
+ } catch (e) {
246
+ console.error(e)
247
+ }
247
248
  this.loading = false
248
249
  },
249
250
  async getData(params) {
@@ -95,7 +95,7 @@
95
95
  </div>
96
96
  <file-preview
97
97
  v-if="previewVisible"
98
- :default-index="preveiwIndex"
98
+ :default-index="previewIndex"
99
99
  :list="imgOrVideoList.map((i) => i.fileUrl)"
100
100
  @close="previewVisible = false"
101
101
  />
@@ -163,7 +163,7 @@ export default {
163
163
  dialogVisible: false,
164
164
  dialogImageUrl: '',
165
165
  videoBg,
166
- preveiwIndex: 0,
166
+ previewIndex: 0,
167
167
  previewVisible: false
168
168
  }
169
169
  },
@@ -258,7 +258,7 @@ export default {
258
258
  this.$parent.$emit('el.form.change')
259
259
  },
260
260
  picturePreview(index) {
261
- this.preveiwIndex = index
261
+ this.previewIndex = index
262
262
  this.previewVisible = true
263
263
  }
264
264
  }