uview-plus 3.2.5 → 3.2.7

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.
Files changed (104) hide show
  1. package/changelog.md +7 -0
  2. package/components/u-action-sheet/props.js +11 -10
  3. package/components/u-album/props.js +12 -11
  4. package/components/u-alert/props.js +9 -8
  5. package/components/u-avatar/props.js +15 -14
  6. package/components/u-avatar-group/props.js +10 -9
  7. package/components/u-back-top/props.js +11 -10
  8. package/components/u-badge/props.js +15 -14
  9. package/components/u-button/props.js +29 -37
  10. package/components/u-calendar/props.js +28 -27
  11. package/components/u-car-keyboard/props.js +1 -0
  12. package/components/u-cell/props.js +21 -20
  13. package/components/u-cell/u-cell.vue +3 -2
  14. package/components/u-cell-group/props.js +3 -2
  15. package/components/u-checkbox/props.js +14 -13
  16. package/components/u-checkbox-group/props.js +17 -16
  17. package/components/u-circle-progress/props.js +2 -1
  18. package/components/u-code/props.js +7 -6
  19. package/components/u-code-input/props.js +17 -16
  20. package/components/u-col/props.js +6 -5
  21. package/components/u-collapse/props.js +4 -3
  22. package/components/u-collapse-item/props.js +12 -11
  23. package/components/u-column-notice/props.js +11 -10
  24. package/components/u-count-down/props.js +5 -4
  25. package/components/u-count-to/props.js +12 -11
  26. package/components/u-datetime-picker/props.js +25 -24
  27. package/components/u-divider/props.js +9 -8
  28. package/components/u-dropdown/props.js +1 -0
  29. package/components/u-dropdown-item/props.js +1 -0
  30. package/components/u-dropdown-item/u-dropdown-item.vue +3 -5
  31. package/components/u-empty/props.js +12 -11
  32. package/components/u-form/props.js +9 -8
  33. package/components/u-form-item/props.js +11 -10
  34. package/components/u-gap/props.js +5 -4
  35. package/components/u-grid/props.js +4 -3
  36. package/components/u-grid-item/props.js +3 -2
  37. package/components/u-icon/props.js +18 -17
  38. package/components/u-image/props.js +17 -16
  39. package/components/u-index-anchor/props.js +6 -5
  40. package/components/u-index-item/props.js +1 -0
  41. package/components/u-index-list/props.js +6 -5
  42. package/components/u-input/props.js +36 -35
  43. package/components/u-keyboard/props.js +17 -16
  44. package/components/u-line/props.js +7 -6
  45. package/components/u-line-progress/props.js +6 -5
  46. package/components/u-link/props.js +8 -7
  47. package/components/u-list/props.js +15 -14
  48. package/components/u-list-item/props.js +2 -1
  49. package/components/u-loading-icon/props.js +12 -11
  50. package/components/u-loading-page/props.js +10 -9
  51. package/components/u-loadmore/props.js +19 -18
  52. package/components/u-modal/props.js +17 -16
  53. package/components/u-navbar/props.js +17 -16
  54. package/components/u-no-network/props.js +4 -3
  55. package/components/u-notice-bar/props.js +14 -13
  56. package/components/u-notify/props.js +10 -9
  57. package/components/u-number-box/props.js +23 -22
  58. package/components/u-number-keyboard/props.js +4 -3
  59. package/components/u-overlay/props.js +5 -4
  60. package/components/u-parse/props.js +9 -8
  61. package/components/u-picker/props.js +17 -16
  62. package/components/u-picker-column/props.js +1 -0
  63. package/components/u-popup/props.js +16 -15
  64. package/components/u-radio/props.js +14 -13
  65. package/components/u-radio-group/props.js +18 -17
  66. package/components/u-rate/props.js +15 -14
  67. package/components/u-read-more/props.js +9 -8
  68. package/components/u-row/props.js +4 -3
  69. package/components/u-row-notice/props.js +8 -7
  70. package/components/u-safe-bottom/props.js +1 -0
  71. package/components/u-scroll-list/props.js +7 -6
  72. package/components/u-search/props.js +25 -24
  73. package/components/u-skeleton/props.js +12 -11
  74. package/components/u-slider/props.js +12 -11
  75. package/components/u-status-bar/props.js +2 -1
  76. package/components/u-steps/props.js +8 -7
  77. package/components/u-steps-item/props.js +5 -4
  78. package/components/u-sticky/props.js +7 -6
  79. package/components/u-subsection/props.js +10 -9
  80. package/components/u-swipe-action/props.js +2 -1
  81. package/components/u-swipe-action-item/props.js +8 -7
  82. package/components/u-swipe-action-item/u-swipe-action-item.vue +18 -1
  83. package/components/u-swiper/props.js +25 -24
  84. package/components/u-swiper-indicator/props.js +6 -5
  85. package/components/u-switch/props.js +12 -11
  86. package/components/u-tabbar/props.js +9 -8
  87. package/components/u-tabbar-item/props.js +7 -6
  88. package/components/u-table/props.js +1 -0
  89. package/components/u-tabs/props.js +13 -12
  90. package/components/u-tabs-item/props.js +1 -0
  91. package/components/u-tag/props.js +20 -18
  92. package/components/u-td/props.js +1 -0
  93. package/components/u-text/props.js +22 -21
  94. package/components/u-textarea/props.js +24 -23
  95. package/components/u-toolbar/props.js +7 -6
  96. package/components/u-tooltip/props.js +12 -11
  97. package/components/u-tr/props.js +1 -0
  98. package/components/u-transition/props.js +5 -4
  99. package/components/u-upload/props.js +23 -22
  100. package/index.js +16 -1
  101. package/libs/function/index.js +30 -23
  102. package/package.json +2 -1
  103. package/types/index.d.ts +1 -0
  104. package/types/package.json +26 -0
@@ -1,161 +1,153 @@
1
- /*
2
- * @Author : LQ
3
- * @Description :
4
- * @version : 1.0
5
- * @Date : 2021-08-16 10:04:04
6
- * @LastAuthor : LQ
7
- * @lastTime : 2021-08-16 10:04:24
8
- * @FilePath : /u-view2.0/uview-ui/components/u-button/props.js
9
- */
1
+ import defProps from '../../libs/config/props.js';
10
2
  export default {
11
3
  props: {
12
4
  // 是否细边框
13
5
  hairline: {
14
6
  type: Boolean,
15
- default: () => uni.$u.props.button.hairline
7
+ default: () => defProps.button.hairline
16
8
  },
17
9
  // 按钮的预置样式,info,primary,error,warning,success
18
10
  type: {
19
11
  type: String,
20
- default: () => uni.$u.props.button.type
12
+ default: () => defProps.button.type
21
13
  },
22
14
  // 按钮尺寸,large,normal,small,mini
23
15
  size: {
24
16
  type: String,
25
- default: () => uni.$u.props.button.size
17
+ default: () => defProps.button.size
26
18
  },
27
19
  // 按钮形状,circle(两边为半圆),square(带圆角)
28
20
  shape: {
29
21
  type: String,
30
- default: () => uni.$u.props.button.shape
22
+ default: () => defProps.button.shape
31
23
  },
32
24
  // 按钮是否镂空
33
25
  plain: {
34
26
  type: Boolean,
35
- default: () => uni.$u.props.button.plain
27
+ default: () => defProps.button.plain
36
28
  },
37
29
  // 是否禁止状态
38
30
  disabled: {
39
31
  type: Boolean,
40
- default: () => uni.$u.props.button.disabled
32
+ default: () => defProps.button.disabled
41
33
  },
42
34
  // 是否加载中
43
35
  loading: {
44
36
  type: Boolean,
45
- default: () => uni.$u.props.button.loading
37
+ default: () => defProps.button.loading
46
38
  },
47
39
  // 加载中提示文字
48
40
  loadingText: {
49
41
  type: [String, Number],
50
- default: () => uni.$u.props.button.loadingText
42
+ default: () => defProps.button.loadingText
51
43
  },
52
44
  // 加载状态图标类型
53
45
  loadingMode: {
54
46
  type: String,
55
- default: () => uni.$u.props.button.loadingMode
47
+ default: () => defProps.button.loadingMode
56
48
  },
57
49
  // 加载图标大小
58
50
  loadingSize: {
59
51
  type: [String, Number],
60
- default: () => uni.$u.props.button.loadingSize
52
+ default: () => defProps.button.loadingSize
61
53
  },
62
54
  // 开放能力,具体请看uniapp稳定关于button组件部分说明
63
55
  // https://uniapp.dcloud.io/component/button
64
56
  openType: {
65
57
  type: String,
66
- default: () => uni.$u.props.button.openType
58
+ default: () => defProps.button.openType
67
59
  },
68
60
  // 用于 <form> 组件,点击分别会触发 <form> 组件的 submit/reset 事件
69
61
  // 取值为submit(提交表单),reset(重置表单)
70
62
  formType: {
71
63
  type: String,
72
- default: () => uni.$u.props.button.formType
64
+ default: () => defProps.button.formType
73
65
  },
74
66
  // 打开 APP 时,向 APP 传递的参数,open-type=launchApp时有效
75
67
  // 只微信小程序、QQ小程序有效
76
68
  appParameter: {
77
69
  type: String,
78
- default: () => uni.$u.props.button.appParameter
70
+ default: () => defProps.button.appParameter
79
71
  },
80
72
  // 指定是否阻止本节点的祖先节点出现点击态,微信小程序有效
81
73
  hoverStopPropagation: {
82
74
  type: Boolean,
83
- default: () => uni.$u.props.button.hoverStopPropagation
75
+ default: () => defProps.button.hoverStopPropagation
84
76
  },
85
77
  // 指定返回用户信息的语言,zh_CN 简体中文,zh_TW 繁体中文,en 英文。只微信小程序有效
86
78
  lang: {
87
79
  type: String,
88
- default: () => uni.$u.props.button.lang
80
+ default: () => defProps.button.lang
89
81
  },
90
82
  // 会话来源,open-type="contact"时有效。只微信小程序有效
91
83
  sessionFrom: {
92
84
  type: String,
93
- default: () => uni.$u.props.button.sessionFrom
85
+ default: () => defProps.button.sessionFrom
94
86
  },
95
87
  // 会话内消息卡片标题,open-type="contact"时有效
96
88
  // 默认当前标题,只微信小程序有效
97
89
  sendMessageTitle: {
98
90
  type: String,
99
- default: () => uni.$u.props.button.sendMessageTitle
91
+ default: () => defProps.button.sendMessageTitle
100
92
  },
101
93
  // 会话内消息卡片点击跳转小程序路径,open-type="contact"时有效
102
94
  // 默认当前分享路径,只微信小程序有效
103
95
  sendMessagePath: {
104
96
  type: String,
105
- default: () => uni.$u.props.button.sendMessagePath
97
+ default: () => defProps.button.sendMessagePath
106
98
  },
107
99
  // 会话内消息卡片图片,open-type="contact"时有效
108
100
  // 默认当前页面截图,只微信小程序有效
109
101
  sendMessageImg: {
110
102
  type: String,
111
- default: () => uni.$u.props.button.sendMessageImg
103
+ default: () => defProps.button.sendMessageImg
112
104
  },
113
105
  // 是否显示会话内消息卡片,设置此参数为 true,用户进入客服会话会在右下角显示"可能要发送的小程序"提示,
114
106
  // 用户点击后可以快速发送小程序消息,open-type="contact"时有效
115
107
  showMessageCard: {
116
108
  type: Boolean,
117
- default: () => uni.$u.props.button.showMessageCard
109
+ default: () => defProps.button.showMessageCard
118
110
  },
119
111
  // 额外传参参数,用于小程序的data-xxx属性,通过target.dataset.name获取
120
112
  dataName: {
121
113
  type: String,
122
- default: () => uni.$u.props.button.dataName
114
+ default: () => defProps.button.dataName
123
115
  },
124
116
  // 节流,一定时间内只能触发一次
125
117
  throttleTime: {
126
118
  type: [String, Number],
127
- default: () => uni.$u.props.button.throttleTime
119
+ default: () => defProps.button.throttleTime
128
120
  },
129
121
  // 按住后多久出现点击态,单位毫秒
130
122
  hoverStartTime: {
131
123
  type: [String, Number],
132
- default: () => uni.$u.props.button.hoverStartTime
124
+ default: () => defProps.button.hoverStartTime
133
125
  },
134
126
  // 手指松开后点击态保留时间,单位毫秒
135
127
  hoverStayTime: {
136
128
  type: [String, Number],
137
- default: () => uni.$u.props.button.hoverStayTime
129
+ default: () => defProps.button.hoverStayTime
138
130
  },
139
131
  // 按钮文字,之所以通过props传入,是因为slot传入的话
140
132
  // nvue中无法控制文字的样式
141
133
  text: {
142
134
  type: [String, Number],
143
- default: () => uni.$u.props.button.text
135
+ default: () => defProps.button.text
144
136
  },
145
137
  // 按钮图标
146
138
  icon: {
147
139
  type: String,
148
- default: () => uni.$u.props.button.icon
140
+ default: () => defProps.button.icon
149
141
  },
150
142
  // 按钮图标
151
143
  iconColor: {
152
144
  type: String,
153
- default: () => uni.$u.props.button.icon
145
+ default: () => defProps.button.icon
154
146
  },
155
147
  // 按钮颜色,支持传入linear-gradient渐变色
156
148
  color: {
157
149
  type: String,
158
- default: () => uni.$u.props.button.color
150
+ default: () => defProps.button.color
159
151
  }
160
152
  }
161
153
  }
@@ -1,139 +1,140 @@
1
+ import defProps from '../../libs/config/props.js';
1
2
  export default {
2
3
  props: {
3
4
  // 日历顶部标题
4
5
  title: {
5
6
  type: String,
6
- default: () => uni.$u.props.calendar.title
7
+ default: () => defProps.calendar.title
7
8
  },
8
9
  // 是否显示标题
9
10
  showTitle: {
10
11
  type: Boolean,
11
- default: () => uni.$u.props.calendar.showTitle
12
+ default: () => defProps.calendar.showTitle
12
13
  },
13
14
  // 是否显示副标题
14
15
  showSubtitle: {
15
16
  type: Boolean,
16
- default: () => uni.$u.props.calendar.showSubtitle
17
+ default: () => defProps.calendar.showSubtitle
17
18
  },
18
19
  // 日期类型选择,single-选择单个日期,multiple-可以选择多个日期,range-选择日期范围
19
20
  mode: {
20
21
  type: String,
21
- default: () => uni.$u.props.calendar.mode
22
+ default: () => defProps.calendar.mode
22
23
  },
23
24
  // mode=range时,第一个日期底部的提示文字
24
25
  startText: {
25
26
  type: String,
26
- default: () => uni.$u.props.calendar.startText
27
+ default: () => defProps.calendar.startText
27
28
  },
28
29
  // mode=range时,最后一个日期底部的提示文字
29
30
  endText: {
30
31
  type: String,
31
- default: () => uni.$u.props.calendar.endText
32
+ default: () => defProps.calendar.endText
32
33
  },
33
34
  // 自定义列表
34
35
  customList: {
35
36
  type: Array,
36
- default: () => uni.$u.props.calendar.customList
37
+ default: () => defProps.calendar.customList
37
38
  },
38
39
  // 主题色,对底部按钮和选中日期有效
39
40
  color: {
40
41
  type: String,
41
- default: () => uni.$u.props.calendar.color
42
+ default: () => defProps.calendar.color
42
43
  },
43
44
  // 最小的可选日期
44
45
  minDate: {
45
46
  type: [String, Number],
46
- default: () => uni.$u.props.calendar.minDate
47
+ default: () => defProps.calendar.minDate
47
48
  },
48
49
  // 最大可选日期
49
50
  maxDate: {
50
51
  type: [String, Number],
51
- default: () => uni.$u.props.calendar.maxDate
52
+ default: () => defProps.calendar.maxDate
52
53
  },
53
54
  // 默认选中的日期,mode为multiple或range是必须为数组格式
54
55
  defaultDate: {
55
56
  type: [Array, String, Date, null],
56
- default: () => uni.$u.props.calendar.defaultDate
57
+ default: () => defProps.calendar.defaultDate
57
58
  },
58
59
  // mode=multiple时,最多可选多少个日期
59
60
  maxCount: {
60
61
  type: [String, Number],
61
- default: () => uni.$u.props.calendar.maxCount
62
+ default: () => defProps.calendar.maxCount
62
63
  },
63
64
  // 日期行高
64
65
  rowHeight: {
65
66
  type: [String, Number],
66
- default: () => uni.$u.props.calendar.rowHeight
67
+ default: () => defProps.calendar.rowHeight
67
68
  },
68
69
  // 日期格式化函数
69
70
  formatter: {
70
71
  type: [Function, null],
71
- default: () => uni.$u.props.calendar.formatter
72
+ default: () => defProps.calendar.formatter
72
73
  },
73
74
  // 是否显示农历
74
75
  showLunar: {
75
76
  type: Boolean,
76
- default: () => uni.$u.props.calendar.showLunar
77
+ default: () => defProps.calendar.showLunar
77
78
  },
78
79
  // 是否显示月份背景色
79
80
  showMark: {
80
81
  type: Boolean,
81
- default: () => uni.$u.props.calendar.showMark
82
+ default: () => defProps.calendar.showMark
82
83
  },
83
84
  // 确定按钮的文字
84
85
  confirmText: {
85
86
  type: String,
86
- default: () => uni.$u.props.calendar.confirmText
87
+ default: () => defProps.calendar.confirmText
87
88
  },
88
89
  // 确认按钮处于禁用状态时的文字
89
90
  confirmDisabledText: {
90
91
  type: String,
91
- default: () => uni.$u.props.calendar.confirmDisabledText
92
+ default: () => defProps.calendar.confirmDisabledText
92
93
  },
93
94
  // 是否显示日历弹窗
94
95
  show: {
95
96
  type: Boolean,
96
- default: () => uni.$u.props.calendar.show
97
+ default: () => defProps.calendar.show
97
98
  },
98
99
  // 是否允许点击遮罩关闭日历
99
100
  closeOnClickOverlay: {
100
101
  type: Boolean,
101
- default: () => uni.$u.props.calendar.closeOnClickOverlay
102
+ default: () => defProps.calendar.closeOnClickOverlay
102
103
  },
103
104
  // 是否为只读状态,只读状态下禁止选择日期
104
105
  readonly: {
105
106
  type: Boolean,
106
- default: () => uni.$u.props.calendar.readonly
107
+ default: () => defProps.calendar.readonly
107
108
  },
108
109
  // 是否展示确认按钮
109
110
  showConfirm: {
110
111
  type: Boolean,
111
- default: () => uni.$u.props.calendar.showConfirm
112
+ default: () => defProps.calendar.showConfirm
112
113
  },
113
114
  // 日期区间最多可选天数,默认无限制,mode = range时有效
114
115
  maxRange: {
115
116
  type: [Number, String],
116
- default: () => uni.$u.props.calendar.maxRange
117
+ default: () => defProps.calendar.maxRange
117
118
  },
118
119
  // 范围选择超过最多可选天数时的提示文案,mode = range时有效
119
120
  rangePrompt: {
120
121
  type: String,
121
- default: () => uni.$u.props.calendar.rangePrompt
122
+ default: () => defProps.calendar.rangePrompt
122
123
  },
123
124
  // 范围选择超过最多可选天数时,是否展示提示文案,mode = range时有效
124
125
  showRangePrompt: {
125
126
  type: Boolean,
126
- default: () => uni.$u.props.calendar.showRangePrompt
127
+ default: () => defProps.calendar.showRangePrompt
127
128
  },
128
129
  // 是否允许日期范围的起止时间为同一天,mode = range时有效
129
130
  allowSameDay: {
130
131
  type: Boolean,
131
- default: () => uni.$u.props.calendar.allowSameDay
132
+ default: () => defProps.calendar.allowSameDay
132
133
  },
133
134
  // 圆角值
134
135
  round: {
135
136
  type: [Boolean, String, Number],
136
- default: () => uni.$u.props.calendar.round
137
+ default: () => defProps.calendar.round
137
138
  },
138
139
  // 最多展示月份数量
139
140
  monthNum: {
@@ -1,3 +1,4 @@
1
+ // import defProps from '../../libs/config/props.js';
1
2
  export default {
2
3
  props: {
3
4
  // 是否打乱键盘按键的顺序
@@ -1,110 +1,111 @@
1
+ import defProps from '../../libs/config/props.js';
1
2
  export default {
2
3
  props: {
3
4
  // 标题
4
5
  title: {
5
6
  type: [String, Number],
6
- default: () => uni.$u.props.cell.title
7
+ default: () => defProps.cell.title
7
8
  },
8
9
  // 标题下方的描述信息
9
10
  label: {
10
11
  type: [String, Number],
11
- default: () => uni.$u.props.cell.label
12
+ default: () => defProps.cell.label
12
13
  },
13
14
  // 右侧的内容
14
15
  value: {
15
16
  type: [String, Number],
16
- default: () => uni.$u.props.cell.value
17
+ default: () => defProps.cell.value
17
18
  },
18
19
  // 左侧图标名称,或者图片链接(本地文件建议使用绝对地址)
19
20
  icon: {
20
21
  type: String,
21
- default: () => uni.$u.props.cell.icon
22
+ default: () => defProps.cell.icon
22
23
  },
23
24
  // 是否禁用cell
24
25
  disabled: {
25
26
  type: Boolean,
26
- default: () => uni.$u.props.cell.disabled
27
+ default: () => defProps.cell.disabled
27
28
  },
28
29
  // 是否显示下边框
29
30
  border: {
30
31
  type: Boolean,
31
- default: () => uni.$u.props.cell.border
32
+ default: () => defProps.cell.border
32
33
  },
33
34
  // 内容是否垂直居中(主要是针对右侧的value部分)
34
35
  center: {
35
36
  type: Boolean,
36
- default: () => uni.$u.props.cell.center
37
+ default: () => defProps.cell.center
37
38
  },
38
39
  // 点击后跳转的URL地址
39
40
  url: {
40
41
  type: String,
41
- default: () => uni.$u.props.cell.url
42
+ default: () => defProps.cell.url
42
43
  },
43
44
  // 链接跳转的方式,内部使用的是uView封装的route方法,可能会进行拦截操作
44
45
  linkType: {
45
46
  type: String,
46
- default: () => uni.$u.props.cell.linkType
47
+ default: () => defProps.cell.linkType
47
48
  },
48
49
  // 是否开启点击反馈(表现为点击时加上灰色背景)
49
50
  clickable: {
50
51
  type: Boolean,
51
- default: () => uni.$u.props.cell.clickable
52
+ default: () => defProps.cell.clickable
52
53
  },
53
54
  // 是否展示右侧箭头并开启点击反馈
54
55
  isLink: {
55
56
  type: Boolean,
56
- default: () => uni.$u.props.cell.isLink
57
+ default: () => defProps.cell.isLink
57
58
  },
58
59
  // 是否显示表单状态下的必填星号(此组件可能会内嵌入input组件)
59
60
  required: {
60
61
  type: Boolean,
61
- default: () => uni.$u.props.cell.required
62
+ default: () => defProps.cell.required
62
63
  },
63
64
  // 右侧的图标箭头
64
65
  rightIcon: {
65
66
  type: String,
66
- default: () => uni.$u.props.cell.rightIcon
67
+ default: () => defProps.cell.rightIcon
67
68
  },
68
69
  // 右侧箭头的方向,可选值为:left,up,down
69
70
  arrowDirection: {
70
71
  type: String,
71
- default: () => uni.$u.props.cell.arrowDirection
72
+ default: () => defProps.cell.arrowDirection
72
73
  },
73
74
  // 左侧图标样式
74
75
  iconStyle: {
75
76
  type: [Object, String],
76
77
  default: () => {
77
- return uni.$u.props.cell.iconStyle
78
+ return defProps.cell.iconStyle
78
79
  }
79
80
  },
80
81
  // 右侧箭头图标的样式
81
82
  rightIconStyle: {
82
83
  type: [Object, String],
83
84
  default: () => {
84
- return uni.$u.props.cell.rightIconStyle
85
+ return defProps.cell.rightIconStyle
85
86
  }
86
87
  },
87
88
  // 标题的样式
88
89
  titleStyle: {
89
90
  type: [Object, String],
90
91
  default: () => {
91
- return uni.$u.props.cell.titleStyle
92
+ return defProps.cell.titleStyle
92
93
  }
93
94
  },
94
95
  // 单位元的大小,可选值为large
95
96
  size: {
96
97
  type: String,
97
- default: () => uni.$u.props.cell.size
98
+ default: () => defProps.cell.size
98
99
  },
99
100
  // 点击cell是否阻止事件传播
100
101
  stop: {
101
102
  type: Boolean,
102
- default: () => uni.$u.props.cell.stop
103
+ default: () => defProps.cell.stop
103
104
  },
104
105
  // 标识符,cell被点击时返回
105
106
  name: {
106
107
  type: [Number, String],
107
- default: () => uni.$u.props.cell.name
108
+ default: () => defProps.cell.name
108
109
  }
109
110
  }
110
111
  }
@@ -12,10 +12,11 @@
12
12
  :size="size === 'large' ? 22 : 18"></u-icon>
13
13
  </view>
14
14
  <view class="u-cell__title">
15
+ <!-- 将slot与默认内容用if/else分开主要是因为微信小程序不支持slot嵌套传递,这样才能解决collapse组件的slot不失效问题,label暂时未用到。 -->
15
16
  <slot name="title" v-if="$slots.title || !title">
16
17
  </slot>
17
- <text v-else class="u-cell__title-text" :style="[titleTextStyle]"
18
- :class="[disabled && 'u-cell--disabled', size === 'large' && 'u-cell__title-text--large']">{{ title }}</text>
18
+ <text v-else class="u-cell__title-text" :style="[titleTextStyle]"
19
+ :class="[disabled && 'u-cell--disabled', size === 'large' && 'u-cell__title-text--large']">{{ title }}</text>
19
20
  <slot name="label">
20
21
  <text class="u-cell__label" v-if="label"
21
22
  :class="[disabled && 'u-cell--disabled', size === 'large' && 'u-cell__label--large']">{{ label }}</text>
@@ -1,14 +1,15 @@
1
+ import defProps from '../../libs/config/props.js';
1
2
  export default {
2
3
  props: {
3
4
  // 分组标题
4
5
  title: {
5
6
  type: String,
6
- default: () => uni.$u.props.cellGroup.title
7
+ default: () => defProps.cellGroup.title
7
8
  },
8
9
  // 是否显示外边框
9
10
  border: {
10
11
  type: Boolean,
11
- default: () => uni.$u.props.cellGroup.border
12
+ default: () => defProps.cellGroup.border
12
13
  }
13
14
  }
14
15
  }
@@ -1,69 +1,70 @@
1
+ import defProps from '../../libs/config/props.js';
1
2
  export default {
2
3
  props: {
3
4
  // checkbox的名称
4
5
  name: {
5
6
  type: [String, Number, Boolean],
6
- default: () => uni.$u.props.checkbox.name
7
+ default: () => defProps.checkbox.name
7
8
  },
8
9
  // 形状,square为方形,circle为圆型
9
10
  shape: {
10
11
  type: String,
11
- default: () => uni.$u.props.checkbox.shape
12
+ default: () => defProps.checkbox.shape
12
13
  },
13
14
  // 整体的大小
14
15
  size: {
15
16
  type: [String, Number],
16
- default: () => uni.$u.props.checkbox.size
17
+ default: () => defProps.checkbox.size
17
18
  },
18
19
  // 是否默认选中
19
20
  checked: {
20
21
  type: Boolean,
21
- default: () => uni.$u.props.checkbox.checked
22
+ default: () => defProps.checkbox.checked
22
23
  },
23
24
  // 是否禁用
24
25
  disabled: {
25
26
  type: [String, Boolean],
26
- default: () => uni.$u.props.checkbox.disabled
27
+ default: () => defProps.checkbox.disabled
27
28
  },
28
29
  // 选中状态下的颜色,如设置此值,将会覆盖parent的activeColor值
29
30
  activeColor: {
30
31
  type: String,
31
- default: () => uni.$u.props.checkbox.activeColor
32
+ default: () => defProps.checkbox.activeColor
32
33
  },
33
34
  // 未选中的颜色
34
35
  inactiveColor: {
35
36
  type: String,
36
- default: () => uni.$u.props.checkbox.inactiveColor
37
+ default: () => defProps.checkbox.inactiveColor
37
38
  },
38
39
  // 图标的大小,单位px
39
40
  iconSize: {
40
41
  type: [String, Number],
41
- default: () => uni.$u.props.checkbox.iconSize
42
+ default: () => defProps.checkbox.iconSize
42
43
  },
43
44
  // 图标颜色
44
45
  iconColor: {
45
46
  type: String,
46
- default: () => uni.$u.props.checkbox.iconColor
47
+ default: () => defProps.checkbox.iconColor
47
48
  },
48
49
  // label提示文字,因为nvue下,直接slot进来的文字,由于特殊的结构,无法修改样式
49
50
  label: {
50
51
  type: [String, Number],
51
- default: () => uni.$u.props.checkbox.label
52
+ default: () => defProps.checkbox.label
52
53
  },
53
54
  // label的字体大小,px单位
54
55
  labelSize: {
55
56
  type: [String, Number],
56
- default: () => uni.$u.props.checkbox.labelSize
57
+ default: () => defProps.checkbox.labelSize
57
58
  },
58
59
  // label的颜色
59
60
  labelColor: {
60
61
  type: String,
61
- default: () => uni.$u.props.checkbox.labelColor
62
+ default: () => defProps.checkbox.labelColor
62
63
  },
63
64
  // 是否禁止点击提示语选中复选框
64
65
  labelDisabled: {
65
66
  type: [String, Boolean],
66
- default: () => uni.$u.props.checkbox.labelDisabled
67
+ default: () => defProps.checkbox.labelDisabled
67
68
  },
68
69
  // 是否独立使用
69
70
  usedAlone: {