@ddwl/ddwl-ui 1.0.21 → 1.0.23

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/CHANGELOG.md CHANGED
@@ -1,3 +1,21 @@
1
+ ## [1.0.23](https://121.40.23.60:51888/frontend/ddwl-ui/compare/v1.0.22...v1.0.23) (2025-07-29)
2
+
3
+
4
+ ### Features
5
+
6
+ * d-description新增border false ([4320737](https://121.40.23.60:51888/frontend/ddwl-ui/commits/4320737b9a6650c5eca86b4d24067fad0e99d464))
7
+
8
+
9
+
10
+ ## [1.0.22](https://121.40.23.60:51888/frontend/ddwl-ui/compare/v1.0.21...v1.0.22) (2025-07-22)
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * d-search-table 修复表单初始化执行多次问题 ([6df514e](https://121.40.23.60:51888/frontend/ddwl-ui/commits/6df514ea4c8fb57c03ccf579f47634904f8ffc7d))
16
+
17
+
18
+
1
19
  ## [1.0.21](https://121.40.23.60:51888/frontend/ddwl-ui/compare/v1.0.20...v1.0.21) (2025-07-16)
2
20
 
3
21
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ddwl/ddwl-ui",
3
- "version": "1.0.21",
3
+ "version": "1.0.23",
4
4
  "private": false,
5
5
  "main": "src/main.js",
6
6
  "description": "ddwl组件库",
@@ -2,16 +2,21 @@
2
2
  <!-- 描述列表 -->
3
3
  <template>
4
4
  <el-descriptions
5
- class="d-descriptions"
6
- :border="true"
5
+ :class="{
6
+ 'd-descriptions': true,
7
+ 'border': border
8
+ }"
9
+ :border="border"
10
+ :label-style="{
11
+ width: labelWidth,
12
+ ...labelStyle
13
+ }"
7
14
  v-bind="$attrs"
8
- v-on="$listeners"
9
15
  >
10
16
  <el-descriptions-item
11
17
  v-for="item in config"
12
18
  :key="item.prop"
13
19
  v-bind="item"
14
- v-on="$listeners"
15
20
  >
16
21
  <template slot="label">
17
22
  <item-render v-if="item.labelRender" :scope="data" :render="item.labelRender" />
@@ -46,6 +51,18 @@ export default {
46
51
  config: {
47
52
  default: () => [],
48
53
  type: Array
54
+ },
55
+ border: {
56
+ default: true,
57
+ type: Boolean
58
+ },
59
+ labelWidth: {
60
+ default: '112px',
61
+ type: String
62
+ },
63
+ labelStyle: {
64
+ default: () => ({}),
65
+ type: Object
49
66
  }
50
67
  },
51
68
  data () {
@@ -60,6 +77,25 @@ export default {
60
77
 
61
78
  <style lang='scss' scoped>
62
79
  .d-descriptions {
80
+ :deep(.el-descriptions__header) {
81
+ margin-bottom: 12px;
82
+ }
83
+ :deep(.el-descriptions-item__label) {
84
+ display: block;
85
+ width: 112px;
86
+ text-align: right;
87
+ color: #333;
88
+ }
89
+ :deep(.el-descriptions-item__cell) {
90
+ padding: 6px 0;
91
+ color: #333;
92
+ vertical-align: middle;
93
+ }
94
+ :deep(.el-descriptions-item__content) {
95
+ color: #666;
96
+ }
97
+ }
98
+ .d-descriptions.border {
63
99
  :deep(.el-descriptions__table.is-bordered) {
64
100
  width: 100%;
65
101
  table-layout: fixed;
@@ -70,13 +106,10 @@ export default {
70
106
  color: #333;
71
107
  border: 1px solid #ebeef5;
72
108
  vertical-align: middle;
73
- }
74
- :deep(.el-descriptions-item__cell.el-descriptions-item__label.is-bordered-label) {
75
- width: 112px;
76
- text-align: right;
77
109
  padding-left: 14px;
78
- background: #f7f7f7;
79
- color: #666;
110
+ }
111
+ :deep(.el-descriptions__body .el-descriptions-item__cell.el-descriptions-item__label.is-bordered-label) {
112
+ display: table-cell;
80
113
  vertical-align: middle;
81
114
  }
82
115
  }
@@ -34,8 +34,7 @@ export default {
34
34
  },
35
35
  data() {
36
36
  return {
37
- form: {},
38
- complateInit: false
37
+ form: {}
39
38
  }
40
39
  },
41
40
  computed: {
@@ -52,16 +51,9 @@ export default {
52
51
  }
53
52
  }
54
53
  },
55
- watch: {
56
- config: {
57
- handler() {
58
- this.createFormBind()
59
- },
60
- deep: true,
61
- immediate: true
62
- }
54
+ created() {
55
+ this.createFormBind()
63
56
  },
64
- created() { },
65
57
  methods: {
66
58
  createFormBind() {
67
59
  const _form = {};