uview-plus 3.0.13 → 3.0.17

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,11 @@
1
+ ## 3.0.17(2022-08-03)
2
+ 修复u-image组件报borderRadius警告
3
+ ## 3.0.16(2022-07-30)
4
+ 修复方法重复,属性重复等多个编译到APP时的warning
5
+ ## 3.0.15(2022-07-22)
6
+ 修复支付宝下不支持this.$slots导致cell的slot失效
7
+ ## 3.0.14(2022-07-22)
8
+ 修复u-grid-item与u-swipe-action-item在支付宝编译报错问题
1
9
  ## 3.0.13(2022-07-22)
2
10
  修复u--input与u--textarea组件多个事件执行两次问题
3
11
  ## 3.0.12(2022-07-20)
@@ -4,10 +4,12 @@
4
4
  @tap="clickHandler">
5
5
  <view class="u-cell__body" :class="[ center && 'u-cell--center', size === 'large' && 'u-cell__body--large']">
6
6
  <view class="u-cell__body__content">
7
- <view class="u-cell__left-icon-wrap" v-if="$slots.icon || icon">
8
- <slot name="icon" v-if="$slots.icon">
7
+ <view class="u-cell__left-icon-wrap">
8
+ <slot name="icon">
9
+ <u-icon v-if="icon" :name="icon"
10
+ :custom-style="iconStyle"
11
+ :size="size === 'large' ? 22 : 18"></u-icon>
9
12
  </slot>
10
- <u-icon v-else :name="icon" :custom-style="iconStyle" :size="size === 'large' ? 22 : 18"></u-icon>
11
13
  </view>
12
14
  <view class="u-cell__title">
13
15
  <slot name="title">
@@ -25,12 +27,12 @@
25
27
  :class="[disabled && 'u-cell--disabled', size === 'large' && 'u-cell__value--large']"
26
28
  v-if="!$u.test.empty(value)">{{ value }}</text>
27
29
  </slot>
28
- <view class="u-cell__right-icon-wrap" v-if="$slots['right-icon'] || isLink"
30
+ <view class="u-cell__right-icon-wrap"
29
31
  :class="[`u-cell__right-icon-wrap--${arrowDirection}`]">
30
- <slot name="right-icon" v-if="$slots['right-icon']">
32
+ <slot name="right-icon">
33
+ <u-icon v-if="isLink" :name="rightIcon" :custom-style="rightIconStyle" :color="disabled ? '#c8c9cc' : 'info'"
34
+ :size="size === 'large' ? 18 : 16"></u-icon>
31
35
  </slot>
32
- <u-icon v-else :name="rightIcon" :custom-style="rightIconStyle" :color="disabled ? '#c8c9cc' : 'info'"
33
- :size="size === 'large' ? 18 : 16"></u-icon>
34
36
  </view>
35
37
  </view>
36
38
  <u-line v-if="border"></u-line>
@@ -23,6 +23,15 @@
23
23
  watch: {
24
24
  needInit() {
25
25
  this.init()
26
+ },
27
+ // 当父组件需要子组件需要共享的参数发生了变化,手动通知子组件
28
+ parentData() {
29
+ if (this.children.length) {
30
+ this.children.map(child => {
31
+ // 判断子组件(u-checkbox)如果有updateParentData方法的话,就就执行(执行的结果是子组件重新从父组件拉取了最新的值)
32
+ typeof(child.updateParentData) === 'function' && child.updateParentData()
33
+ })
34
+ }
26
35
  }
27
36
  },
28
37
  created() {
@@ -35,17 +44,6 @@
35
44
  return [this.accordion, this.value]
36
45
  }
37
46
  },
38
- watch: {
39
- // 当父组件需要子组件需要共享的参数发生了变化,手动通知子组件
40
- parentData() {
41
- if (this.children.length) {
42
- this.children.map(child => {
43
- // 判断子组件(u-checkbox)如果有updateParentData方法的话,就就执行(执行的结果是子组件重新从父组件拉取了最新的值)
44
- typeof(child.updateParentData) === 'function' && child.updateParentData()
45
- })
46
- }
47
- },
48
- },
49
47
  methods: {
50
48
  // 重新初始化一次内部的所有子元素
51
49
  init() {
@@ -129,7 +129,7 @@
129
129
  },
130
130
  gridItemClasses() {
131
131
  if(this.parentData.border) {
132
- const classes = []
132
+ let classes = []
133
133
  this.parent.children.map((child, index) =>{
134
134
  if(this === child) {
135
135
  const len = this.parent.children.length
@@ -134,7 +134,7 @@
134
134
  // 如果是显示圆形,设置一个很多的半径值即可
135
135
  style.borderRadius = this.shape == 'circle' ? '10000px' : uni.$u.addUnit(this.radius)
136
136
  // 如果设置圆角,必须要有hidden,否则可能圆角无效
137
- style.overflow = this.borderRadius > 0 ? 'hidden' : 'visible'
137
+ style.overflow = this.radius > 0 ? 'hidden' : 'visible'
138
138
  // if (this.fade) {
139
139
  // style.opacity = this.opacity
140
140
  // // nvue下,这几个属性必须要分开写
@@ -100,7 +100,9 @@ import nvueMixin from "./nvue.js"
100
100
  import props from './props.js';
101
101
  export default {
102
102
  name: 'u-scroll-list',
103
+ // #ifndef APP-NVUE
103
104
  mixins: [uni.$u.mpMixin, uni.$u.mixin, props],
105
+ // #endif
104
106
  // #ifdef APP-NVUE
105
107
  mixins: [uni.$u.mpMixin, uni.$u.mixin, nvueMixin, props],
106
108
  // #endif
@@ -31,14 +31,16 @@
31
31
  <view class="u-swipe-action-item__content" @touchstart="wxs.touchstart" @touchmove="wxs.touchmove"
32
32
  @touchend="wxs.touchend" :status="status" :change:status="wxs.statusChange" :size="size"
33
33
  :change:size="wxs.sizeChange">
34
- <!-- #endif -->
35
- <!-- #ifdef APP-NVUE -->
36
- <view class="u-swipe-action-item__content" ref="u-swipe-action-item__content" @panstart="onTouchstart"
37
- @tap="clickHandler">
38
- <!-- #endif -->
39
- <slot />
40
- </view>
34
+ <slot></slot>
41
35
  </view>
36
+ <!-- #endif -->
37
+ <!-- #ifdef APP-NVUE -->
38
+ <view class="u-swipe-action-item__content" ref="u-swipe-action-item__content" @panstart="onTouchstart"
39
+ @tap="clickHandler">
40
+ <slot></slot>
41
+ </view>
42
+ <!-- #endif -->
43
+ </view>
42
44
  </template>
43
45
  <!-- #ifdef APP-VUE || MP-WEIXIN || H5 || MP-QQ -->
44
46
  <script src="./index.wxs" module="wxs" lang="wxs"></script>
@@ -69,7 +71,9 @@
69
71
  */
70
72
  export default {
71
73
  name: 'u-swipe-action-item',
74
+ // #ifndef APP-NVUE
72
75
  mixins: [uni.$u.mpMixin, uni.$u.mixin, props, touch],
76
+ // #endif
73
77
  // #ifdef APP-NVUE
74
78
  mixins: [uni.$u.mpMixin, uni.$u.mixin, props, nvue, touch],
75
79
  // #endif
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "id": "uview-plus",
3
3
  "name": "uview-plus",
4
4
  "displayName": "uview-plus3.0重磅发布,利剑出鞘,一统江湖",
5
- "version": "3.0.13",
5
+ "version": "3.0.17",
6
6
  "description": "uview-plus已兼容vue3,全面的组件和便捷的工具会让您信手拈来,如鱼得水",
7
7
  "keywords": [
8
8
  "uview",
@@ -17,12 +17,8 @@
17
17
  "engines": {
18
18
  "HBuilderX": "^3.1.0"
19
19
  },
20
- "dcloudext": {
21
- "category": [
22
- "前端组件",
23
- "通用组件"
24
- ],
25
- "sale": {
20
+ "dcloudext": {
21
+ "sale": {
26
22
  "regular": {
27
23
  "price": "0.00"
28
24
  },
@@ -38,7 +34,8 @@
38
34
  "data": "无",
39
35
  "permissions": "无"
40
36
  },
41
- "npmurl": "https://www.npmjs.com/package/uview-plus"
37
+ "npmurl": "https://www.npmjs.com/package/uview-plus",
38
+ "type": "component-vue"
42
39
  },
43
40
  "uni_modules": {
44
41
  "dependencies": [],