uview-plus 3.3.55 → 3.3.58

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,13 @@
1
+ ## 3.3.58(2024-12-26)
2
+ fix: slider组件change事件传参
3
+ ## 3.3.57(2024-12-23)
4
+ fix: slider组件change事件传参
5
+
6
+ feat: 更新u-picker组件增加当前选中class类名
7
+
8
+ ## 3.3.56(2024-12-18)
9
+ feat: 在u-alert组件中添加关闭事件
10
+
1
11
  ## 3.3.55(2024-12-17)
2
12
  add: swiper增加双向绑定
3
13
 
@@ -48,6 +48,7 @@
48
48
  <view
49
49
  v-if="testArray(item)"
50
50
  class="u-picker__view__column__item u-line-1"
51
+ :class="[index1 === innerIndex[index] && 'u-picker__view__column__item--selected']"
51
52
  v-for="(item1, index1) in item"
52
53
  :key="index1"
53
54
  :style="{
@@ -269,8 +269,8 @@
269
269
  this.newValue = ((this.distanceX / this.sliderRect.width) * (this.max - this.min)) + parseFloat(this.min);
270
270
  this.status = 'moving';
271
271
  // 发出moving事件
272
- this.$emit('changing');
273
- this.updateValue(this.newValue, true, index);
272
+ let $crtFmtValue = this.updateValue(this.newValue, true, index);
273
+ this.$emit('changing', $crtFmtValue);
274
274
  },
275
275
  onTouchMove(event, index = 1) {
276
276
  if (this.disabled) return;
@@ -293,14 +293,14 @@
293
293
  this.newValue = ((this.distanceX / this.sliderRect.width) * (this.max - this.min)) + parseFloat(this.min);
294
294
  this.status = 'moving';
295
295
  // 发出moving事件
296
- this.$emit('changing');
297
- this.updateValue(this.newValue, true, index);
296
+ let $crtFmtValue = this.updateValue(this.newValue, true, index);
297
+ this.$emit('changing', $crtFmtValue);
298
298
  },
299
299
  onTouchEnd(event, index = 1) {
300
300
  if (this.disabled) return;
301
301
  if (this.status === 'moving') {
302
- this.updateValue(this.newValue, false, index);
303
- this.$emit('change');
302
+ let $crtFmtValue = this.updateValue(this.newValue, false, index);
303
+ this.$emit('change', $crtFmtValue);
304
304
  }
305
305
  this.status = 'end';
306
306
  },
@@ -373,7 +373,11 @@
373
373
  default:
374
374
  break;
375
375
  }
376
-
376
+ if (this.isRange) {
377
+ return this.rangeValue
378
+ } else {
379
+ return valueFormat
380
+ }
377
381
  },
378
382
  format(value, index = 1) {
379
383
  // 将小数变成整数,为了减少对视图的更新,造成视图层与逻辑层的阻塞
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "id": "uview-plus",
3
3
  "name": "uview-plus",
4
- "displayName": "uview-plus3.0重磅发布,全面的Vue3鸿蒙移动组件库。",
5
- "version": "3.3.55",
4
+ "displayName": "零云®uview-plus3.0重磅发布,全面的Vue3鸿蒙移动组件库。",
5
+ "version": "3.3.58",
6
6
  "description": "零云®uview-plus已兼容vue3,全面的组件和便捷的工具会让您信手拈来,如鱼得水",
7
7
  "keywords": [
8
8
  "uview",