uview-plus 3.0.17 → 3.1.3
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 +8 -0
- package/components/u--form/u--form.vue +4 -2
- package/components/u--image/u--image.vue +4 -2
- package/components/u--input/u--input.vue +5 -3
- package/components/u--text/u--text.vue +4 -2
- package/components/u--textarea/u--textarea.vue +4 -2
- package/components/u-action-sheet/props.js +11 -10
- package/components/u-action-sheet/u-action-sheet.vue +3 -1
- package/components/u-album/props.js +12 -11
- package/components/u-album/u-album.vue +4 -2
- package/components/u-alert/props.js +9 -8
- package/components/u-alert/u-alert.vue +3 -1
- package/components/u-avatar/props.js +15 -14
- package/components/u-avatar/u-avatar.vue +3 -1
- package/components/u-avatar-group/props.js +10 -9
- package/components/u-avatar-group/u-avatar-group.vue +3 -1
- package/components/u-back-top/props.js +11 -10
- package/components/u-back-top/u-back-top.vue +2 -0
- package/components/u-badge/props.js +15 -14
- package/components/u-badge/u-badge.vue +3 -1
- package/components/u-button/props.js +29 -28
- package/components/u-button/u-button.vue +4 -2
- package/components/u-calendar/month.vue +5 -2
- package/components/u-calendar/props.js +28 -27
- package/components/u-calendar/u-calendar.vue +3 -1
- package/components/u-calendar/util.js +1 -0
- package/components/u-car-keyboard/props.js +1 -0
- package/components/u-car-keyboard/u-car-keyboard.vue +4 -2
- package/components/u-cell/props.js +18 -17
- package/components/u-cell/u-cell.vue +3 -1
- package/components/u-cell-group/props.js +3 -2
- package/components/u-cell-group/u-cell-group.vue +3 -1
- package/components/u-checkbox/props.js +14 -13
- package/components/u-checkbox/u-checkbox.vue +3 -1
- package/components/u-checkbox-group/props.js +16 -15
- package/components/u-checkbox-group/u-checkbox-group.vue +3 -1
- package/components/u-circle-progress/props.js +2 -1
- package/components/u-circle-progress/u-circle-progress.vue +3 -1
- package/components/u-code/props.js +7 -6
- package/components/u-code/u-code.vue +3 -1
- package/components/u-code-input/props.js +16 -15
- package/components/u-code-input/u-code-input.vue +3 -1
- package/components/u-col/props.js +6 -5
- package/components/u-col/u-col.vue +3 -1
- package/components/u-collapse/props.js +4 -3
- package/components/u-collapse/u-collapse.vue +3 -1
- package/components/u-collapse-item/props.js +12 -11
- package/components/u-collapse-item/u-collapse-item.vue +20 -18
- package/components/u-column-notice/props.js +11 -10
- package/components/u-column-notice/u-column-notice.vue +3 -1
- package/components/u-count-down/props.js +5 -4
- package/components/u-count-down/u-count-down.vue +5 -3
- package/components/u-count-to/props.js +12 -11
- package/components/u-count-to/u-count-to.vue +3 -1
- package/components/u-datetime-picker/props.js +24 -23
- package/components/u-datetime-picker/u-datetime-picker.vue +3 -1
- package/components/u-divider/props.js +9 -8
- package/components/u-divider/u-divider.vue +3 -1
- package/components/u-dropdown/props.js +5 -4
- package/components/u-dropdown/u-dropdown.vue +4 -2
- package/components/u-dropdown-item/props.js +2 -1
- package/components/u-dropdown-item/u-dropdown-item.vue +4 -2
- package/components/u-empty/props.js +12 -11
- package/components/u-empty/u-empty.vue +3 -2
- package/components/u-form/props.js +9 -8
- package/components/u-form/u-form.vue +13 -11
- package/components/u-form-item/props.js +9 -8
- package/components/u-form-item/u-form-item.vue +3 -1
- package/components/u-gap/props.js +5 -4
- package/components/u-gap/u-gap.vue +3 -1
- package/components/u-grid/props.js +4 -3
- package/components/u-grid/u-grid.vue +3 -1
- package/components/u-grid-item/props.js +3 -2
- package/components/u-grid-item/u-grid-item.vue +3 -1
- package/components/u-icon/props.js +18 -17
- package/components/u-icon/u-icon.vue +4 -2
- package/components/u-image/props.js +18 -17
- package/components/u-image/u-image.vue +3 -1
- package/components/u-index-anchor/props.js +6 -5
- package/components/u-index-anchor/u-index-anchor.vue +3 -1
- package/components/u-index-item/props.js +1 -0
- package/components/u-index-item/u-index-item.vue +3 -1
- package/components/u-index-list/props.js +6 -5
- package/components/u-index-list/u-index-list.vue +3 -1
- package/components/u-input/props.js +36 -35
- package/components/u-input/u-input.vue +3 -1
- package/components/u-keyboard/props.js +17 -16
- package/components/u-keyboard/u-keyboard.vue +3 -1
- package/components/u-line/props.js +7 -6
- package/components/u-line/u-line.vue +3 -1
- package/components/u-line-progress/props.js +6 -5
- package/components/u-line-progress/u-line-progress.vue +3 -1
- package/components/u-link/props.js +8 -7
- package/components/u-link/u-link.vue +3 -1
- package/components/u-list/props.js +15 -14
- package/components/u-list/u-list.vue +3 -1
- package/components/u-list-item/props.js +2 -1
- package/components/u-list-item/u-list-item.vue +3 -1
- package/components/u-loading-icon/props.js +13 -12
- package/components/u-loading-icon/u-loading-icon.vue +4 -2
- package/components/u-loading-page/props.js +10 -9
- package/components/u-loading-page/u-loading-page.vue +3 -1
- package/components/u-loadmore/props.js +19 -18
- package/components/u-loadmore/u-loadmore.vue +3 -1
- package/components/u-modal/props.js +17 -16
- package/components/u-modal/u-modal.vue +4 -2
- package/components/u-navbar/props.js +34 -33
- package/components/u-navbar/u-navbar.vue +3 -1
- package/components/u-no-network/props.js +4 -3
- package/components/u-no-network/u-no-network.vue +3 -1
- package/components/u-notice-bar/props.js +14 -13
- package/components/u-notice-bar/u-notice-bar.vue +3 -1
- package/components/u-notify/props.js +10 -9
- package/components/u-notify/u-notify.vue +3 -1
- package/components/u-number-box/props.js +23 -22
- package/components/u-number-box/u-number-box.vue +3 -1
- package/components/u-number-keyboard/props.js +4 -3
- package/components/u-number-keyboard/u-number-keyboard.vue +3 -1
- package/components/u-overlay/props.js +5 -4
- package/components/u-overlay/u-overlay.vue +3 -1
- package/components/u-parse/props.js +9 -8
- package/components/u-picker/props.js +16 -15
- package/components/u-picker/u-picker.vue +3 -1
- package/components/u-picker-column/props.js +1 -0
- package/components/u-picker-column/u-picker-column.vue +3 -1
- package/components/u-popup/props.js +16 -15
- package/components/u-popup/u-popup.vue +4 -2
- package/components/u-radio/props.js +13 -12
- package/components/u-radio/u-radio.vue +3 -1
- package/components/u-radio-group/props.js +18 -17
- package/components/u-radio-group/u-radio-group.vue +3 -1
- package/components/u-rate/props.js +15 -14
- package/components/u-rate/u-rate.vue +3 -1
- package/components/u-read-more/props.js +9 -8
- package/components/u-read-more/u-read-more.vue +3 -1
- package/components/u-row/props.js +4 -3
- package/components/u-row/u-row.vue +3 -1
- package/components/u-row-notice/props.js +8 -7
- package/components/u-row-notice/u-row-notice.vue +3 -1
- package/components/u-safe-bottom/props.js +1 -0
- package/components/u-safe-bottom/u-safe-bottom.vue +4 -2
- package/components/u-scroll-list/props.js +7 -6
- package/components/u-scroll-list/u-scroll-list.vue +3 -1
- package/components/u-search/props.js +25 -24
- package/components/u-search/u-search.vue +3 -1
- package/components/u-skeleton/props.js +12 -11
- package/components/u-skeleton/u-skeleton.vue +3 -1
- package/components/u-slider/props.js +11 -10
- package/components/u-slider/u-slider.vue +5 -3
- package/components/u-status-bar/props.js +2 -1
- package/components/u-status-bar/u-status-bar.vue +3 -1
- package/components/u-steps/props.js +9 -8
- package/components/u-steps/u-steps.vue +3 -1
- package/components/u-steps-item/props.js +5 -4
- package/components/u-steps-item/u-steps-item.vue +3 -1
- package/components/u-sticky/props.js +7 -6
- package/components/u-sticky/u-sticky.vue +4 -2
- package/components/u-subsection/props.js +10 -9
- package/components/u-subsection/u-subsection.vue +3 -1
- package/components/u-swipe-action/props.js +2 -1
- package/components/u-swipe-action/u-swipe-action.vue +3 -1
- package/components/u-swipe-action-item/props.js +7 -6
- package/components/u-swipe-action-item/u-swipe-action-item.vue +5 -3
- package/components/u-swiper/props.js +25 -24
- package/components/u-swiper/u-swiper.vue +3 -1
- package/components/u-swiper-indicator/props.js +6 -5
- package/components/u-swiper-indicator/u-swiper-indicator.vue +3 -1
- package/components/u-switch/props.js +12 -11
- package/components/u-switch/u-switch.vue +3 -1
- package/components/u-tabbar/props.js +9 -8
- package/components/u-tabbar/u-tabbar.vue +3 -1
- package/components/u-tabbar-item/props.js +7 -6
- package/components/u-tabbar-item/u-tabbar-item.vue +3 -1
- package/components/u-table/props.js +1 -0
- package/components/u-table/u-table.vue +3 -1
- package/components/u-tabs/props.js +13 -12
- package/components/u-tabs/u-tabs.vue +3 -1
- package/components/u-tabs-item/props.js +1 -0
- package/components/u-tabs-item/u-tabs-item.vue +3 -1
- package/components/u-tag/props.js +16 -15
- package/components/u-tag/u-tag.vue +5 -3
- package/components/u-td/props.js +1 -0
- package/components/u-td/u-td.vue +3 -1
- package/components/u-text/props.js +22 -21
- package/components/u-text/u-text.vue +4 -2
- package/components/u-textarea/props.js +24 -23
- package/components/u-textarea/u-textarea.vue +3 -1
- package/components/u-toast/u-toast.vue +3 -1
- package/components/u-toolbar/props.js +7 -6
- package/components/u-toolbar/u-toolbar.vue +3 -1
- package/components/u-tooltip/props.js +12 -11
- package/components/u-tooltip/u-tooltip.vue +3 -1
- package/components/u-tr/props.js +1 -0
- package/components/u-tr/u-tr.vue +3 -1
- package/components/u-transition/{nvue.ani-map.js → nvue-ani-map.js} +0 -0
- package/components/u-transition/props.js +5 -4
- package/components/u-transition/transition.js +3 -1
- package/components/u-transition/u-transition.vue +3 -1
- package/components/u-upload/props.js +23 -22
- package/components/u-upload/u-upload.vue +4 -2
- package/index.js +1 -0
- package/libs/config/config.js +2 -2
- package/package.json +1 -1
|
@@ -1,78 +1,79 @@
|
|
|
1
|
+
import defprops from '../../libs/config/props';
|
|
1
2
|
export default {
|
|
2
3
|
props: {
|
|
3
4
|
// #ifdef VUE3
|
|
4
5
|
// 用于v-model双向绑定选中的星星数量
|
|
5
6
|
modelValue: {
|
|
6
7
|
type: [String, Number],
|
|
7
|
-
default:
|
|
8
|
+
default: defprops.rate.value
|
|
8
9
|
},
|
|
9
10
|
// #endif
|
|
10
11
|
// #ifdef VUE2
|
|
11
12
|
// 用于v-model双向绑定选中的星星数量
|
|
12
13
|
value: {
|
|
13
14
|
type: [String, Number],
|
|
14
|
-
default:
|
|
15
|
+
default: defprops.rate.value
|
|
15
16
|
},
|
|
16
17
|
// #endif
|
|
17
18
|
// 要显示的星星数量
|
|
18
19
|
count: {
|
|
19
20
|
type: [String, Number],
|
|
20
|
-
default:
|
|
21
|
+
default: defprops.rate.count
|
|
21
22
|
},
|
|
22
23
|
// 是否不可选中
|
|
23
24
|
disabled: {
|
|
24
25
|
type: Boolean,
|
|
25
|
-
default:
|
|
26
|
+
default: defprops.rate.disabled
|
|
26
27
|
},
|
|
27
28
|
// 是否只读
|
|
28
29
|
readonly: {
|
|
29
30
|
type: Boolean,
|
|
30
|
-
default:
|
|
31
|
+
default: defprops.rate.readonly
|
|
31
32
|
},
|
|
32
33
|
// 星星的大小,单位px
|
|
33
34
|
size: {
|
|
34
35
|
type: [String, Number],
|
|
35
|
-
default:
|
|
36
|
+
default: defprops.rate.size
|
|
36
37
|
},
|
|
37
38
|
// 未选中时的颜色
|
|
38
39
|
inactiveColor: {
|
|
39
40
|
type: String,
|
|
40
|
-
default:
|
|
41
|
+
default: defprops.rate.inactiveColor
|
|
41
42
|
},
|
|
42
43
|
// 选中的颜色
|
|
43
44
|
activeColor: {
|
|
44
45
|
type: String,
|
|
45
|
-
default:
|
|
46
|
+
default: defprops.rate.activeColor
|
|
46
47
|
},
|
|
47
48
|
// 星星之间的间距,单位px
|
|
48
49
|
gutter: {
|
|
49
50
|
type: [String, Number],
|
|
50
|
-
default:
|
|
51
|
+
default: defprops.rate.gutter
|
|
51
52
|
},
|
|
52
53
|
// 最少能选择的星星个数
|
|
53
54
|
minCount: {
|
|
54
55
|
type: [String, Number],
|
|
55
|
-
default:
|
|
56
|
+
default: defprops.rate.minCount
|
|
56
57
|
},
|
|
57
58
|
// 是否允许半星
|
|
58
59
|
allowHalf: {
|
|
59
60
|
type: Boolean,
|
|
60
|
-
default:
|
|
61
|
+
default: defprops.rate.allowHalf
|
|
61
62
|
},
|
|
62
63
|
// 选中时的图标(星星)
|
|
63
64
|
activeIcon: {
|
|
64
65
|
type: String,
|
|
65
|
-
default:
|
|
66
|
+
default: defprops.rate.activeIcon
|
|
66
67
|
},
|
|
67
68
|
// 未选中时的图标(星星)
|
|
68
69
|
inactiveIcon: {
|
|
69
70
|
type: String,
|
|
70
|
-
default:
|
|
71
|
+
default: defprops.rate.inactiveIcon
|
|
71
72
|
},
|
|
72
73
|
// 是否可以通过滑动手势选择评分
|
|
73
74
|
touchable: {
|
|
74
75
|
type: Boolean,
|
|
75
|
-
default:
|
|
76
|
+
default: defprops.rate.touchable
|
|
76
77
|
}
|
|
77
78
|
}
|
|
78
79
|
}
|
|
@@ -75,6 +75,8 @@
|
|
|
75
75
|
|
|
76
76
|
<script>
|
|
77
77
|
import props from './props.js';
|
|
78
|
+
import mpMixin from '../../libs/mixin/mpMixin.js';
|
|
79
|
+
import mixin from '../../libs/mixin/mixin.js';
|
|
78
80
|
|
|
79
81
|
// #ifdef APP-NVUE
|
|
80
82
|
const dom = weex.requireModule("dom");
|
|
@@ -102,7 +104,7 @@
|
|
|
102
104
|
*/
|
|
103
105
|
export default {
|
|
104
106
|
name: "u-rate",
|
|
105
|
-
mixins: [
|
|
107
|
+
mixins: [mpMixin, mixin, props],
|
|
106
108
|
data() {
|
|
107
109
|
return {
|
|
108
110
|
// 生成一个唯一id,否则一个页面多个评分组件,会造成冲突
|
|
@@ -1,34 +1,35 @@
|
|
|
1
|
+
import defprops from '../../libs/config/props';
|
|
1
2
|
export default {
|
|
2
3
|
props: {
|
|
3
4
|
// 默认的显示占位高度
|
|
4
5
|
showHeight: {
|
|
5
6
|
type: [String, Number],
|
|
6
|
-
default:
|
|
7
|
+
default: defprops.readMore.showHeight
|
|
7
8
|
},
|
|
8
9
|
// 展开后是否显示"收起"按钮
|
|
9
10
|
toggle: {
|
|
10
11
|
type: Boolean,
|
|
11
|
-
default:
|
|
12
|
+
default: defprops.readMore.toggle
|
|
12
13
|
},
|
|
13
14
|
// 关闭时的提示文字
|
|
14
15
|
closeText: {
|
|
15
16
|
type: String,
|
|
16
|
-
default:
|
|
17
|
+
default: defprops.readMore.closeText
|
|
17
18
|
},
|
|
18
19
|
// 展开时的提示文字
|
|
19
20
|
openText: {
|
|
20
21
|
type: String,
|
|
21
|
-
default:
|
|
22
|
+
default: defprops.readMore.openText
|
|
22
23
|
},
|
|
23
24
|
// 提示的文字颜色
|
|
24
25
|
color: {
|
|
25
26
|
type: String,
|
|
26
|
-
default:
|
|
27
|
+
default: defprops.readMore.color
|
|
27
28
|
},
|
|
28
29
|
// 提示文字的大小
|
|
29
30
|
fontSize: {
|
|
30
31
|
type: [String, Number],
|
|
31
|
-
default:
|
|
32
|
+
default: defprops.readMore.fontSize
|
|
32
33
|
},
|
|
33
34
|
// 是否显示阴影
|
|
34
35
|
// 此参数不能写在props/readMore.js中进行默认配置,因为使用了条件编译,在外部js中
|
|
@@ -50,12 +51,12 @@ export default {
|
|
|
50
51
|
// 段落首行缩进的字符个数
|
|
51
52
|
textIndent: {
|
|
52
53
|
type: String,
|
|
53
|
-
default:
|
|
54
|
+
default: defprops.readMore.textIndent
|
|
54
55
|
},
|
|
55
56
|
// open和close事件时,将此参数返回在回调参数中
|
|
56
57
|
name: {
|
|
57
58
|
type: [String, Number],
|
|
58
|
-
default:
|
|
59
|
+
default: defprops.readMore.name
|
|
59
60
|
}
|
|
60
61
|
}
|
|
61
62
|
}
|
|
@@ -50,6 +50,8 @@
|
|
|
50
50
|
const dom = uni.requireNativePlugin('dom')
|
|
51
51
|
// #endif
|
|
52
52
|
import props from './props.js';
|
|
53
|
+
import mpMixin from '../../libs/mixin/mpMixin.js';
|
|
54
|
+
import mixin from '../../libs/mixin/mixin.js';
|
|
53
55
|
/**
|
|
54
56
|
* readMore 阅读更多
|
|
55
57
|
* @description 该组件一般用于内容较长,预先收起一部分,点击展开全部内容的场景。
|
|
@@ -69,7 +71,7 @@
|
|
|
69
71
|
*/
|
|
70
72
|
export default {
|
|
71
73
|
name: 'u-read-more',
|
|
72
|
-
mixins: [
|
|
74
|
+
mixins: [mpMixin, mixin, props],
|
|
73
75
|
data() {
|
|
74
76
|
return {
|
|
75
77
|
isLongContent: false, // 是否需要隐藏一部分内容
|
|
@@ -1,19 +1,20 @@
|
|
|
1
|
+
import defprops from '../../libs/config/props';
|
|
1
2
|
export default {
|
|
2
3
|
props: {
|
|
3
4
|
// 给col添加间距,左右边距各占一半
|
|
4
5
|
gutter: {
|
|
5
6
|
type: [String, Number],
|
|
6
|
-
default:
|
|
7
|
+
default: defprops.row.gutter
|
|
7
8
|
},
|
|
8
9
|
// 水平排列方式,可选值为`start`(或`flex-start`)、`end`(或`flex-end`)、`center`、`around`(或`space-around`)、`between`(或`space-between`)
|
|
9
10
|
justify: {
|
|
10
11
|
type: String,
|
|
11
|
-
default:
|
|
12
|
+
default: defprops.row.justify
|
|
12
13
|
},
|
|
13
14
|
// 垂直对齐方式,可选值为top、center、bottom
|
|
14
15
|
align: {
|
|
15
16
|
type: String,
|
|
16
|
-
default:
|
|
17
|
+
default: defprops.row.align
|
|
17
18
|
}
|
|
18
19
|
}
|
|
19
20
|
}
|
|
@@ -14,6 +14,8 @@
|
|
|
14
14
|
const dom = uni.requireNativePlugin('dom')
|
|
15
15
|
// #endif
|
|
16
16
|
import props from './props.js';
|
|
17
|
+
import mpMixin from '../../libs/mixin/mpMixin.js';
|
|
18
|
+
import mixin from '../../libs/mixin/mixin.js';
|
|
17
19
|
/**
|
|
18
20
|
* Row 栅格系统中的行
|
|
19
21
|
* @description 通过基础的 12 分栏,迅速简便地创建布局
|
|
@@ -28,7 +30,7 @@
|
|
|
28
30
|
*/
|
|
29
31
|
export default {
|
|
30
32
|
name: "u-row",
|
|
31
|
-
mixins: [
|
|
33
|
+
mixins: [mpMixin, mixin, props],
|
|
32
34
|
data() {
|
|
33
35
|
return {
|
|
34
36
|
|
|
@@ -1,39 +1,40 @@
|
|
|
1
|
+
import defprops from '../../libs/config/props';
|
|
1
2
|
export default {
|
|
2
3
|
props: {
|
|
3
4
|
// 显示的内容,字符串
|
|
4
5
|
text: {
|
|
5
6
|
type: String,
|
|
6
|
-
default:
|
|
7
|
+
default: defprops.rowNotice.text
|
|
7
8
|
},
|
|
8
9
|
// 是否显示左侧的音量图标
|
|
9
10
|
icon: {
|
|
10
11
|
type: String,
|
|
11
|
-
default:
|
|
12
|
+
default: defprops.rowNotice.icon
|
|
12
13
|
},
|
|
13
14
|
// 通告模式,link-显示右箭头,closable-显示右侧关闭图标
|
|
14
15
|
mode: {
|
|
15
16
|
type: String,
|
|
16
|
-
default:
|
|
17
|
+
default: defprops.rowNotice.mode
|
|
17
18
|
},
|
|
18
19
|
// 文字颜色,各图标也会使用文字颜色
|
|
19
20
|
color: {
|
|
20
21
|
type: String,
|
|
21
|
-
default:
|
|
22
|
+
default: defprops.rowNotice.color
|
|
22
23
|
},
|
|
23
24
|
// 背景颜色
|
|
24
25
|
bgColor: {
|
|
25
26
|
type: String,
|
|
26
|
-
default:
|
|
27
|
+
default: defprops.rowNotice.bgColor
|
|
27
28
|
},
|
|
28
29
|
// 字体大小,单位px
|
|
29
30
|
fontSize: {
|
|
30
31
|
type: [String, Number],
|
|
31
|
-
default:
|
|
32
|
+
default: defprops.rowNotice.fontSize
|
|
32
33
|
},
|
|
33
34
|
// 水平滚动时的滚动速度,即每秒滚动多少px(rpx),这有利于控制文字无论多少时,都能有一个恒定的速度
|
|
34
35
|
speed: {
|
|
35
36
|
type: [String, Number],
|
|
36
|
-
default:
|
|
37
|
+
default: defprops.rowNotice.speed
|
|
37
38
|
}
|
|
38
39
|
}
|
|
39
40
|
}
|
|
@@ -53,6 +53,8 @@
|
|
|
53
53
|
</template>
|
|
54
54
|
<script>
|
|
55
55
|
import props from './props.js';
|
|
56
|
+
import mpMixin from '../../libs/mixin/mpMixin.js';
|
|
57
|
+
import mixin from '../../libs/mixin/mixin.js';
|
|
56
58
|
// #ifdef APP-NVUE
|
|
57
59
|
const animation = uni.requireNativePlugin('animation')
|
|
58
60
|
const dom = uni.requireNativePlugin('dom')
|
|
@@ -75,7 +77,7 @@
|
|
|
75
77
|
*/
|
|
76
78
|
export default {
|
|
77
79
|
name: 'u-row-notice',
|
|
78
|
-
mixins: [
|
|
80
|
+
mixins: [mpMixin, mixin, props],
|
|
79
81
|
data() {
|
|
80
82
|
return {
|
|
81
83
|
animationDuration: '0', // 动画执行时间
|
|
@@ -8,7 +8,9 @@
|
|
|
8
8
|
</template>
|
|
9
9
|
|
|
10
10
|
<script>
|
|
11
|
-
import props from "./props.js";
|
|
11
|
+
import props from "./props.js";
|
|
12
|
+
import mpMixin from '../../libs/mixin/mpMixin.js';
|
|
13
|
+
import mixin from '../../libs/mixin/mixin.js';
|
|
12
14
|
/**
|
|
13
15
|
* SafeBottom 底部安全区
|
|
14
16
|
* @description 这个适配,主要是针对IPhone X等一些底部带指示条的机型,指示条的操作区域与页面底部存在重合,容易导致用户误操作,因此我们需要针对这些机型进行底部安全区适配。
|
|
@@ -21,7 +23,7 @@
|
|
|
21
23
|
*/
|
|
22
24
|
export default {
|
|
23
25
|
name: "u-safe-bottom",
|
|
24
|
-
mixins: [
|
|
26
|
+
mixins: [mpMixin, mixin, props],
|
|
25
27
|
data() {
|
|
26
28
|
return {
|
|
27
29
|
safeAreaBottomHeight: 0,
|
|
@@ -1,34 +1,35 @@
|
|
|
1
|
+
import defprops from '../../libs/config/props';
|
|
1
2
|
export default {
|
|
2
3
|
props: {
|
|
3
4
|
// 指示器的整体宽度
|
|
4
5
|
indicatorWidth: {
|
|
5
6
|
type: [String, Number],
|
|
6
|
-
default:
|
|
7
|
+
default: defprops.scrollList.indicatorWidth
|
|
7
8
|
},
|
|
8
9
|
// 滑块的宽度
|
|
9
10
|
indicatorBarWidth: {
|
|
10
11
|
type: [String, Number],
|
|
11
|
-
default:
|
|
12
|
+
default: defprops.scrollList.indicatorBarWidth
|
|
12
13
|
},
|
|
13
14
|
// 是否显示面板指示器
|
|
14
15
|
indicator: {
|
|
15
16
|
type: Boolean,
|
|
16
|
-
default:
|
|
17
|
+
default: defprops.scrollList.indicator
|
|
17
18
|
},
|
|
18
19
|
// 指示器非激活颜色
|
|
19
20
|
indicatorColor: {
|
|
20
21
|
type: String,
|
|
21
|
-
default:
|
|
22
|
+
default: defprops.scrollList.indicatorColor
|
|
22
23
|
},
|
|
23
24
|
// 指示器的激活颜色
|
|
24
25
|
indicatorActiveColor: {
|
|
25
26
|
type: String,
|
|
26
|
-
default:
|
|
27
|
+
default: defprops.scrollList.indicatorActiveColor
|
|
27
28
|
},
|
|
28
29
|
// 指示器样式,可通过bottom,left,right进行定位
|
|
29
30
|
indicatorStyle: {
|
|
30
31
|
type: [String, Object],
|
|
31
|
-
default:
|
|
32
|
+
default: defprops.scrollList.indicatorStyle
|
|
32
33
|
}
|
|
33
34
|
}
|
|
34
35
|
}
|
|
@@ -98,10 +98,12 @@ const dom = uni.requireNativePlugin('dom')
|
|
|
98
98
|
import nvueMixin from "./nvue.js"
|
|
99
99
|
// #endif
|
|
100
100
|
import props from './props.js';
|
|
101
|
+
import mpMixin from '../../libs/mixin/mpMixin.js';
|
|
102
|
+
import mixin from '../../libs/mixin/mixin.js';
|
|
101
103
|
export default {
|
|
102
104
|
name: 'u-scroll-list',
|
|
103
105
|
// #ifndef APP-NVUE
|
|
104
|
-
mixins: [
|
|
106
|
+
mixins: [mpMixin, mixin, props],
|
|
105
107
|
// #endif
|
|
106
108
|
// #ifdef APP-NVUE
|
|
107
109
|
mixins: [uni.$u.mpMixin, uni.$u.mixin, nvueMixin, props],
|
|
@@ -1,122 +1,123 @@
|
|
|
1
|
+
import defprops from '../../libs/config/props';
|
|
1
2
|
export default {
|
|
2
3
|
props: {
|
|
3
4
|
// 搜索框形状,round-圆形,square-方形
|
|
4
5
|
shape: {
|
|
5
6
|
type: String,
|
|
6
|
-
default:
|
|
7
|
+
default: defprops.search.shape
|
|
7
8
|
},
|
|
8
9
|
// 搜索框背景色,默认值#f2f2f2
|
|
9
10
|
bgColor: {
|
|
10
11
|
type: String,
|
|
11
|
-
default:
|
|
12
|
+
default: defprops.search.bgColor
|
|
12
13
|
},
|
|
13
14
|
// 占位提示文字
|
|
14
15
|
placeholder: {
|
|
15
16
|
type: String,
|
|
16
|
-
default:
|
|
17
|
+
default: defprops.search.placeholder
|
|
17
18
|
},
|
|
18
19
|
// 是否启用清除控件
|
|
19
20
|
clearabled: {
|
|
20
21
|
type: Boolean,
|
|
21
|
-
default:
|
|
22
|
+
default: defprops.search.clearabled
|
|
22
23
|
},
|
|
23
24
|
// 是否自动聚焦
|
|
24
25
|
focus: {
|
|
25
26
|
type: Boolean,
|
|
26
|
-
default:
|
|
27
|
+
default: defprops.search.focus
|
|
27
28
|
},
|
|
28
29
|
// 是否在搜索框右侧显示取消按钮
|
|
29
30
|
showAction: {
|
|
30
31
|
type: Boolean,
|
|
31
|
-
default:
|
|
32
|
+
default: defprops.search.showAction
|
|
32
33
|
},
|
|
33
34
|
// 右边控件的样式
|
|
34
35
|
actionStyle: {
|
|
35
36
|
type: Object,
|
|
36
|
-
default:
|
|
37
|
+
default: defprops.search.actionStyle
|
|
37
38
|
},
|
|
38
39
|
// 取消按钮文字
|
|
39
40
|
actionText: {
|
|
40
41
|
type: String,
|
|
41
|
-
default:
|
|
42
|
+
default: defprops.search.actionText
|
|
42
43
|
},
|
|
43
44
|
// 输入框内容对齐方式,可选值为 left|center|right
|
|
44
45
|
inputAlign: {
|
|
45
46
|
type: String,
|
|
46
|
-
default:
|
|
47
|
+
default: defprops.search.inputAlign
|
|
47
48
|
},
|
|
48
49
|
// input输入框的样式,可以定义文字颜色,大小等,对象形式
|
|
49
50
|
inputStyle: {
|
|
50
51
|
type: Object,
|
|
51
|
-
default:
|
|
52
|
+
default: defprops.search.inputStyle
|
|
52
53
|
},
|
|
53
54
|
// 是否启用输入框
|
|
54
55
|
disabled: {
|
|
55
56
|
type: Boolean,
|
|
56
|
-
default:
|
|
57
|
+
default: defprops.search.disabled
|
|
57
58
|
},
|
|
58
59
|
// 边框颜色
|
|
59
60
|
borderColor: {
|
|
60
61
|
type: String,
|
|
61
|
-
default:
|
|
62
|
+
default: defprops.search.borderColor
|
|
62
63
|
},
|
|
63
64
|
// 搜索图标的颜色,默认同输入框字体颜色
|
|
64
65
|
searchIconColor: {
|
|
65
66
|
type: String,
|
|
66
|
-
default:
|
|
67
|
+
default: defprops.search.searchIconColor
|
|
67
68
|
},
|
|
68
69
|
// 输入框字体颜色
|
|
69
70
|
color: {
|
|
70
71
|
type: String,
|
|
71
|
-
default:
|
|
72
|
+
default: defprops.search.color
|
|
72
73
|
},
|
|
73
74
|
// placeholder的颜色
|
|
74
75
|
placeholderColor: {
|
|
75
76
|
type: String,
|
|
76
|
-
default:
|
|
77
|
+
default: defprops.search.placeholderColor
|
|
77
78
|
},
|
|
78
79
|
// 左边输入框的图标,可以为uView图标名称或图片路径
|
|
79
80
|
searchIcon: {
|
|
80
81
|
type: String,
|
|
81
|
-
default:
|
|
82
|
+
default: defprops.search.searchIcon
|
|
82
83
|
},
|
|
83
84
|
searchIconSize: {
|
|
84
85
|
type: [Number, String],
|
|
85
|
-
default:
|
|
86
|
+
default: defprops.search.searchIconSize
|
|
86
87
|
},
|
|
87
88
|
// 组件与其他上下左右元素之间的距离,带单位的字符串形式,如"30px"、"30px 20px"等写法
|
|
88
89
|
margin: {
|
|
89
90
|
type: String,
|
|
90
|
-
default:
|
|
91
|
+
default: defprops.search.margin
|
|
91
92
|
},
|
|
92
93
|
// 开启showAction时,是否在input获取焦点时才显示
|
|
93
94
|
animation: {
|
|
94
95
|
type: Boolean,
|
|
95
|
-
default:
|
|
96
|
+
default: defprops.search.animation
|
|
96
97
|
},
|
|
97
98
|
// 输入框的初始化内容
|
|
98
99
|
modelValue: {
|
|
99
100
|
type: String,
|
|
100
|
-
default:
|
|
101
|
+
default: defprops.search.value
|
|
101
102
|
},
|
|
102
103
|
value: {
|
|
103
104
|
type: String,
|
|
104
|
-
default:
|
|
105
|
+
default: defprops.search.value
|
|
105
106
|
},
|
|
106
107
|
// 输入框最大能输入的长度,-1为不限制长度(来自uniapp文档)
|
|
107
108
|
maxlength: {
|
|
108
109
|
type: [String, Number],
|
|
109
|
-
default:
|
|
110
|
+
default: defprops.search.maxlength
|
|
110
111
|
},
|
|
111
112
|
// 搜索框高度,单位px
|
|
112
113
|
height: {
|
|
113
114
|
type: [String, Number],
|
|
114
|
-
default:
|
|
115
|
+
default: defprops.search.height
|
|
115
116
|
},
|
|
116
117
|
// 搜索框左侧文本
|
|
117
118
|
label: {
|
|
118
119
|
type: [String, Number, null],
|
|
119
|
-
default:
|
|
120
|
+
default: defprops.search.label
|
|
120
121
|
}
|
|
121
122
|
}
|
|
122
123
|
}
|
|
@@ -73,6 +73,8 @@
|
|
|
73
73
|
|
|
74
74
|
<script>
|
|
75
75
|
import props from './props.js';
|
|
76
|
+
import mpMixin from '../../libs/mixin/mpMixin.js';
|
|
77
|
+
import mixin from '../../libs/mixin/mixin.js';
|
|
76
78
|
|
|
77
79
|
/**
|
|
78
80
|
* search 搜索框
|
|
@@ -111,7 +113,7 @@
|
|
|
111
113
|
*/
|
|
112
114
|
export default {
|
|
113
115
|
name: "u-search",
|
|
114
|
-
mixins: [
|
|
116
|
+
mixins: [mpMixin, mixin, props],
|
|
115
117
|
data() {
|
|
116
118
|
return {
|
|
117
119
|
keyword: '',
|
|
@@ -1,59 +1,60 @@
|
|
|
1
|
+
import defprops from '../../libs/config/props';
|
|
1
2
|
export default {
|
|
2
3
|
props: {
|
|
3
4
|
// 是否展示骨架组件
|
|
4
5
|
loading: {
|
|
5
6
|
type: Boolean,
|
|
6
|
-
default:
|
|
7
|
+
default: defprops.skeleton.loading
|
|
7
8
|
},
|
|
8
9
|
// 是否开启动画效果
|
|
9
10
|
animate: {
|
|
10
11
|
type: Boolean,
|
|
11
|
-
default:
|
|
12
|
+
default: defprops.skeleton.animate
|
|
12
13
|
},
|
|
13
14
|
// 段落占位图行数
|
|
14
15
|
rows: {
|
|
15
16
|
type: [String, Number],
|
|
16
|
-
default:
|
|
17
|
+
default: defprops.skeleton.rows
|
|
17
18
|
},
|
|
18
19
|
// 段落占位图的宽度
|
|
19
20
|
rowsWidth: {
|
|
20
21
|
type: [String, Number, Array],
|
|
21
|
-
default:
|
|
22
|
+
default: defprops.skeleton.rowsWidth
|
|
22
23
|
},
|
|
23
24
|
// 段落占位图的高度
|
|
24
25
|
rowsHeight: {
|
|
25
26
|
type: [String, Number, Array],
|
|
26
|
-
default:
|
|
27
|
+
default: defprops.skeleton.rowsHeight
|
|
27
28
|
},
|
|
28
29
|
// 是否展示标题占位图
|
|
29
30
|
title: {
|
|
30
31
|
type: Boolean,
|
|
31
|
-
default:
|
|
32
|
+
default: defprops.skeleton.title
|
|
32
33
|
},
|
|
33
34
|
// 段落标题的宽度
|
|
34
35
|
titleWidth: {
|
|
35
36
|
type: [String, Number],
|
|
36
|
-
default:
|
|
37
|
+
default: defprops.skeleton.titleWidth
|
|
37
38
|
},
|
|
38
39
|
// 段落标题的高度
|
|
39
40
|
titleHeight: {
|
|
40
41
|
type: [String, Number],
|
|
41
|
-
default:
|
|
42
|
+
default: defprops.skeleton.titleHeight
|
|
42
43
|
},
|
|
43
44
|
// 是否展示头像占位图
|
|
44
45
|
avatar: {
|
|
45
46
|
type: Boolean,
|
|
46
|
-
default:
|
|
47
|
+
default: defprops.skeleton.avatar
|
|
47
48
|
},
|
|
48
49
|
// 头像占位图大小
|
|
49
50
|
avatarSize: {
|
|
50
51
|
type: [String, Number],
|
|
51
|
-
default:
|
|
52
|
+
default: defprops.skeleton.avatarSize
|
|
52
53
|
},
|
|
53
54
|
// 头像占位图的形状,circle-圆形,square-方形
|
|
54
55
|
avatarShape: {
|
|
55
56
|
type: String,
|
|
56
|
-
default:
|
|
57
|
+
default: defprops.skeleton.avatarShape
|
|
57
58
|
}
|
|
58
59
|
}
|
|
59
60
|
}
|
|
@@ -50,6 +50,8 @@
|
|
|
50
50
|
|
|
51
51
|
<script>
|
|
52
52
|
import props from './props.js';
|
|
53
|
+
import mpMixin from '../../libs/mixin/mpMixin.js';
|
|
54
|
+
import mixin from '../../libs/mixin/mixin.js';
|
|
53
55
|
// #ifdef APP-NVUE
|
|
54
56
|
// 由于weex为阿里的KPI业绩考核的产物,所以不支持百分比单位,这里需要通过dom查询组件的宽度
|
|
55
57
|
const dom = uni.requireNativePlugin('dom')
|
|
@@ -74,7 +76,7 @@
|
|
|
74
76
|
*/
|
|
75
77
|
export default {
|
|
76
78
|
name: 'u-skeleton',
|
|
77
|
-
mixins: [
|
|
79
|
+
mixins: [mpMixin, mixin, props],
|
|
78
80
|
data() {
|
|
79
81
|
return {
|
|
80
82
|
width: 0,
|