uview-plus 3.4.14 → 3.4.15

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.4.15(2025-04-10)
2
+ improvment: 优化移步加载数据时swiper组件displayMultipleItems报错
3
+
4
+ feat: modal增加contentStyle属性
5
+
6
+ fix: 修复下拉菜单收起动画缺失
7
+
8
+ fix: 修复sticky的offset属性值为响应式数据时失效 #237
9
+
10
+
1
11
  ## 3.4.14(2025-04-09)
2
12
  feat: 支持自托管内置图标及扩展自定义图标
3
13
 
@@ -20,11 +20,12 @@
20
20
  </view>
21
21
  </view>
22
22
  <view class="u-dropdown__content" :style="[contentStyle, {
23
- transition: `opacity ${duration / 1000}s linear`,
23
+ transition: `opacity ${duration / 1000}s, z-index ${duration / 1000}s linear`,
24
24
  top: addUnit(height)
25
25
  }]"
26
26
  @tap="maskClick" @touchmove.stop.prevent>
27
- <view @tap.stop.prevent class="u-dropdown__content__popup" :style="[popupStyle]">
27
+ <view @tap.stop.prevent class="u-dropdown__content__popup" :style="[popupStyle, {
28
+ }]">
28
29
  <slot></slot>
29
30
  </view>
30
31
  <view class="u-dropdown__content__mask"></view>
@@ -147,11 +148,11 @@
147
148
  this.active = false;
148
149
  this.current = 99999;
149
150
  // 下拉内容的样式进行调整,不透明度设置为0
150
- this.contentStyle = {
151
- zIndex: -1,
152
- opacity: 0,
153
- height: '0px'
154
- }
151
+ this.contentStyle.zIndex = -1;
152
+ this.contentStyle.opacity = 0;
153
+ setTimeout(() => {
154
+ this.contentStyle.height = 0;
155
+ }, this.duration)
155
156
  },
156
157
  // 点击遮罩
157
158
  maskClick() {
@@ -28,6 +28,7 @@ export default {
28
28
  confirmButtonShape: '',
29
29
  contentTextAlign: 'left',
30
30
  asyncCloseTip: '操作中...',
31
- asyncCancelClose: false
31
+ asyncCancelClose: false,
32
+ contentStyle: {}
32
33
  }
33
34
  }
@@ -97,6 +97,11 @@ export const props = defineMixin({
97
97
  type: Boolean,
98
98
  default: () => defProps.modal.asyncCancelClose
99
99
  },
100
+ // 内容样式
101
+ contentStyle: {
102
+ type: Object,
103
+ default: () => defProps.modal.contentStyle
104
+ },
100
105
 
101
106
  }
102
107
  })
@@ -26,9 +26,7 @@
26
26
  >{{ title }}</view>
27
27
  <view
28
28
  class="u-modal__content"
29
- :style="{
30
- paddingTop: `${title ? 12 : 25}px`
31
- }"
29
+ :style="contentStyleCpu"
32
30
  >
33
31
  <slot>
34
32
  <text class="u-modal__content__text" :style="{textAlign: contentTextAlign}">
@@ -138,6 +136,13 @@
138
136
  }
139
137
  },
140
138
  emits: ["confirm", "cancel", "close", "update:show", 'cancelOnAsync'],
139
+ computed: {
140
+ contentStyleCpu() {
141
+ let style = this.contentStyle;
142
+ style.paddingTop = `${title ? 12 : 25}px`
143
+ return style;
144
+ }
145
+ },
141
146
  methods: {
142
147
  addUnit,
143
148
  // 点击确定按钮
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <view class="u-picker-data">
3
3
  <view class="u-picker-data__trigger">
4
- <slot name="trigger"></slot>
4
+ <slot name="trigger" :current="current"></slot>
5
5
  <up-input
6
6
  v-if="!$slots['trigger']"
7
7
  :modelValue="current"
@@ -90,6 +90,11 @@
90
90
  mounted() {
91
91
  this.init()
92
92
  },
93
+ watch: {
94
+ offsetTop(nval) {
95
+ this.getStickyTop()
96
+ }
97
+ },
93
98
  methods: {
94
99
  init() {
95
100
  this.getStickyTop()
@@ -30,7 +30,7 @@
30
30
  :previousMargin="addUnit(previousMargin)"
31
31
  :nextMargin="addUnit(nextMargin)"
32
32
  :acceleration="acceleration"
33
- :displayMultipleItems="displayMultipleItems"
33
+ :displayMultipleItems="list.length > 0 ? displayMultipleItems : 0"
34
34
  :easingFunction="easingFunction"
35
35
  >
36
36
  <swiper-item
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "id": "uview-plus",
3
3
  "name": "uview-plus",
4
4
  "displayName": "零云®uview-plus3.0重磅发布,全面的Vue3鸿蒙移动组件库。",
5
- "version": "3.4.14",
5
+ "version": "3.4.15",
6
6
  "description": "零云®uview-plus已兼容vue3,全面的组件和便捷的工具会让您信手拈来,如鱼得水",
7
7
  "keywords": [
8
8
  "uview",