sadais-piui 1.2.7-beta100 → 1.2.7-beta101

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.
@@ -126,7 +126,9 @@ export default {
126
126
  // `''`
127
127
  default: checkboxGroup.activeMode,
128
128
  validator: function(value) {
129
- return ['', 'line', 'line-circle', 'fill', 'fill-circle'].includes(value)
129
+ return ['', 'line', 'line-circle', 'fill', 'fill-circle'].includes(
130
+ value
131
+ )
130
132
  }
131
133
  },
132
134
  // 是否点击图标才能选中,默认点击整行都能选中
@@ -143,6 +145,8 @@ export default {
143
145
  },
144
146
  watch: {
145
147
  val: {
148
+ deep: true,
149
+ immediate: true,
146
150
  handler(value) {
147
151
  this.handleValChange()
148
152
  }
@@ -154,7 +158,9 @@ export default {
154
158
  this._children.forEach(child => {
155
159
  // 对设置了name属性的checkbox才做同步
156
160
  if (child.name) {
157
- child.val = this.val.includes(child.name)
161
+ setTimeout(() => {
162
+ child.val = this.val.includes(child.name)
163
+ }, 50)
158
164
  }
159
165
  })
160
166
  },
@@ -183,7 +189,8 @@ export default {
183
189
  const vals = []
184
190
  this._children.forEach(child => {
185
191
  console.log(child.val, child.name)
186
- if (child.val && !this.$pi.lang.isEmpty(child.name)) vals.push(child.name)
192
+ if (child.val && !this.$pi.lang.isEmpty(child.name))
193
+ vals.push(child.name)
187
194
  })
188
195
  this.val = vals
189
196
  this.handleEmitChange()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sadais-piui",
3
- "version": "1.2.7-beta100",
3
+ "version": "1.2.7-beta101",
4
4
  "description": "piui组件库",
5
5
  "main": "index.js",
6
6
  "scripts": {