uview-plus 3.1.52 → 3.2.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.
Files changed (42) hide show
  1. package/changelog.md +44 -0
  2. package/components/u-action-sheet/u-action-sheet.vue +1 -1
  3. package/components/u-album/u-album.vue +261 -261
  4. package/components/u-avatar/u-avatar.vue +3 -2
  5. package/components/u-avatar-group/u-avatar-group.vue +106 -106
  6. package/components/u-button/u-button.vue +6 -1
  7. package/components/u-calendar/u-calendar.vue +4 -3
  8. package/components/u-cell/u-cell.vue +4 -2
  9. package/components/u-checkbox/props.js +5 -0
  10. package/components/u-checkbox/u-checkbox.vue +27 -15
  11. package/components/u-code/u-code.vue +1 -1
  12. package/components/u-dropdown/props.js +8 -14
  13. package/components/u-dropdown/u-dropdown.vue +202 -77
  14. package/components/u-dropdown-item/props.js +45 -36
  15. package/components/u-dropdown-item/u-dropdown-item.vue +121 -148
  16. package/components/u-form/u-form.vue +1 -1
  17. package/components/u-form-item/props.js +6 -1
  18. package/components/u-form-item/u-form-item.vue +1 -1
  19. package/components/u-grid/u-grid.vue +4 -2
  20. package/components/u-grid-item/u-grid-item.vue +8 -7
  21. package/components/u-input/u-input.vue +1 -1
  22. package/components/u-lazy-load/u-lazy-load.vue +251 -0
  23. package/components/u-picker/u-picker.vue +4 -1
  24. package/components/u-popup/u-popup.vue +1 -1
  25. package/components/u-read-more/u-read-more.vue +164 -160
  26. package/components/u-slider/u-slider.vue +6 -6
  27. package/components/u-steps-item/u-steps-item.vue +318 -318
  28. package/components/u-subsection/u-subsection.vue +14 -8
  29. package/components/u-swiper/u-swiper.vue +6 -8
  30. package/components/u-tabs/u-tabs.vue +1 -0
  31. package/components/u-tag/props.js +5 -2
  32. package/components/u-text/u-text.vue +226 -226
  33. package/components/u-textarea/u-textarea.vue +275 -275
  34. package/components/u-transition/u-transition.vue +1 -1
  35. package/components/u-waterfall/u-waterfall.vue +225 -0
  36. package/libs/config/props/formItem.js +1 -0
  37. package/libs/config/props/tag.js +30 -29
  38. package/libs/css/common.scss +1 -1
  39. package/libs/css/components.scss +5 -5
  40. package/libs/css/flex.scss +45 -45
  41. package/libs/mixin/mixin.js +2 -2
  42. package/package.json +1 -1
@@ -1,275 +1,275 @@
1
- <template>
2
- <view class="u-textarea" :class="textareaClass" :style="[textareaStyle]">
3
- <textarea
4
- class="u-textarea__field"
5
- :value="innerValue"
6
- :style="{ height: $u.addUnit(height) }"
7
- :placeholder="placeholder"
8
- :placeholder-style="$u.addStyle(placeholderStyle, 'string')"
9
- :placeholder-class="placeholderClass"
10
- :disabled="disabled"
11
- :focus="focus"
12
- :autoHeight="autoHeight"
13
- :fixed="fixed"
14
- :cursorSpacing="cursorSpacing"
15
- :cursor="cursor"
16
- :showConfirmBar="showConfirmBar"
17
- :selectionStart="selectionStart"
18
- :selectionEnd="selectionEnd"
19
- :adjustPosition="adjustPosition"
20
- :disableDefaultPadding="disableDefaultPadding"
21
- :holdKeyboard="holdKeyboard"
22
- :maxlength="maxlength"
23
- :confirm-type="confirmType"
24
- :ignoreCompositionEvent="ignoreCompositionEvent"
25
- @focus="onFocus"
26
- @blur="onBlur"
27
- @linechange="onLinechange"
28
- @input="onInput"
29
- @confirm="onConfirm"
30
- @keyboardheightchange="onKeyboardheightchange"
31
- ></textarea>
32
- <!-- #ifndef MP-ALIPAY -->
33
- <text
34
- class="u-textarea__count"
35
- :style="{
36
- 'background-color': disabled ? 'transparent' : '#fff',
37
- }"
38
- v-if="count"
39
- >{{ innerValue.length }}/{{ maxlength }}</text
40
- >
41
- <!-- #endif -->
42
- </view>
43
- </template>
44
-
45
- <script>
46
- import props from "./props.js";
47
- import mpMixin from '../../libs/mixin/mpMixin.js';
48
- import mixin from '../../libs/mixin/mixin.js';
49
- /**
50
- * Textarea 文本域
51
- * @description 文本域此组件满足了可能出现的表单信息补充,编辑等实际逻辑的功能,内置了字数校验等
52
- * @tutorial https://ijry.github.io/uview-plus/components/textarea.html
53
- *
54
- * @property {String | Number} value 输入框的内容
55
- * @property {String | Number} placeholder 输入框为空时占位符
56
- * @property {String} placeholderClass 指定placeholder的样式类,注意页面或组件的style中写了scoped时,需要在类名前写/deep/ ( 默认 'input-placeholder' )
57
- * @property {String | Object} placeholderStyle 指定placeholder的样式,字符串/对象形式,如"color: red;"
58
- * @property {String | Number} height 输入框高度(默认 70 )
59
- * @property {String} confirmType 设置键盘右下角按钮的文字,仅微信小程序,App-vue和H5有效(默认 'done' )
60
- * @property {Boolean} disabled 是否禁用(默认 false )
61
- * @property {Boolean} count 是否显示统计字数(默认 false )
62
- * @property {Boolean} focus 是否自动获取焦点,nvue不支持,H5取决于浏览器的实现(默认 false )
63
- * @property {Boolean | Function} autoHeight 是否自动增加高度(默认 false )
64
- * @property {Boolean} fixed 如果textarea是在一个position:fixed的区域,需要显示指定属性fixed为true(默认 false )
65
- * @property {Number} cursorSpacing 指定光标与键盘的距离(默认 0 )
66
- * @property {String | Number} cursor 指定focus时的光标位置
67
- * @property {Function} formatter 内容式化函数
68
- * @property {Boolean} showConfirmBar 是否显示键盘上方带有”完成“按钮那一栏,(默认 true )
69
- * @property {Number} selectionStart 光标起始位置,自动聚焦时有效,需与selection-end搭配使用,(默认 -1 )
70
- * @property {Number | Number} selectionEnd 光标结束位置,自动聚焦时有效,需与selection-start搭配使用(默认 -1 )
71
- * @property {Boolean} adjustPosition 键盘弹起时,是否自动上推页面(默认 true )
72
- * @property {Boolean | Number} disableDefaultPadding 是否去掉 iOS 下的默认内边距,只微信小程序有效(默认 false )
73
- * @property {Boolean} holdKeyboard focus时,点击页面的时候不收起键盘,只微信小程序有效(默认 false )
74
- * @property {String | Number} maxlength 最大输入长度,设置为 -1 的时候不限制最大长度(默认 140 )
75
- * @property {String} border 边框类型,surround-四周边框,none-无边框,bottom-底部边框(默认 'surround' )
76
- * @property {Boolean} ignoreCompositionEvent 是否忽略组件内对文本合成系统事件的处理
77
- *
78
- * @event {Function(e)} focus 输入框聚焦时触发,event.detail = { value, height },height 为键盘高度
79
- * @event {Function(e)} blur 输入框失去焦点时触发,event.detail = {value, cursor}
80
- * @event {Function(e)} linechange 输入框行数变化时调用,event.detail = {height: 0, heightRpx: 0, lineCount: 0}
81
- * @event {Function(e)} input 当键盘输入时,触发 input 事件
82
- * @event {Function(e)} confirm 点击完成时, 触发 confirm 事件
83
- * @event {Function(e)} keyboardheightchange 键盘高度发生变化的时候触发此事件
84
- * @example <u--textarea v-model="value1" placeholder="请输入内容" ></u--textarea>
85
- */
86
- export default {
87
- name: "u-textarea",
88
- mixins: [mpMixin, mixin, props],
89
- data() {
90
- return {
91
- // 输入框的值
92
- innerValue: "",
93
- // 是否处于获得焦点状态
94
- focused: false,
95
- // value是否第一次变化,在watch中,由于加入immediate属性,会在第一次触发,此时不应该认为value发生了变化
96
- firstChange: true,
97
- // value绑定值的变化是由内部还是外部引起的
98
- changeFromInner: false,
99
- // 过滤处理方法
100
- innerFormatter: value => value
101
- }
102
- },
103
- created() {
104
- },
105
- watch: {
106
- // #ifdef VUE2
107
- value: {
108
- immediate: true,
109
- handler(newVal, oldVal) {
110
- this.innerValue = newVal;
111
- /* #ifdef H5 */
112
- // 在H5中,外部value变化后,修改input中的值,不会触发@input事件,此时手动调用值变化方法
113
- if (
114
- this.firstChange === false &&
115
- this.changeFromInner === false
116
- ) {
117
- this.valueChange();
118
- }
119
- /* #endif */
120
- this.firstChange = false;
121
- // 重置changeFromInner的值为false,标识下一次引起默认为外部引起的
122
- this.changeFromInner = false;
123
- },
124
- },
125
- // #endif
126
- // #ifdef VUE3
127
- modelValue: {
128
- immediate: true,
129
- handler(newVal, oldVal) {
130
- this.innerValue = newVal;
131
- /* #ifdef H5 */
132
- // 在H5中,外部value变化后,修改input中的值,不会触发@input事件,此时手动调用值变化方法
133
- if (
134
- this.firstChange === false &&
135
- this.changeFromInner === false
136
- ) {
137
- this.valueChange();
138
- }
139
- /* #endif */
140
- this.firstChange = false;
141
- // 重置changeFromInner的值为false,标识下一次引起默认为外部引起的
142
- this.changeFromInner = false;
143
- },
144
- }
145
- // #endif
146
- },
147
- computed: {
148
- // 组件的类名
149
- textareaClass() {
150
- let classes = [],
151
- { border, disabled } = this;
152
- border === "surround" &&
153
- (classes = classes.concat(["u-border", "u-textarea--radius"]));
154
- border === "bottom" &&
155
- (classes = classes.concat([
156
- "u-border-bottom",
157
- "u-textarea--no-radius",
158
- ]));
159
- disabled && classes.push("u-textarea--disabled");
160
- return classes.join(" ");
161
- },
162
- // 组件的样式
163
- textareaStyle() {
164
- const style = {};
165
- // #ifdef APP-NVUE
166
- // 由于textarea在安卓nvue上的差异性,需要额外再调整其内边距
167
- if (uni.$u.os() === "android") {
168
- style.paddingTop = "6px";
169
- style.paddingLeft = "9px";
170
- style.paddingBottom = "3px";
171
- style.paddingRight = "6px";
172
- }
173
- // #endif
174
- return uni.$u.deepMerge(style, uni.$u.addStyle(this.customStyle));
175
- },
176
- },
177
- // #ifdef VUE3
178
- emits: ['update:modelValue', 'linechange', 'focus', 'blur', 'change', 'confirm', 'keyboardheightchange'],
179
- // #endif
180
- methods: {
181
- // 在微信小程序中,不支持将函数当做props参数,故只能通过ref形式调用
182
- setFormatter(e) {
183
- this.innerFormatter = e
184
- },
185
- onFocus(e) {
186
- this.$emit("focus", e);
187
- },
188
- onBlur(e) {
189
- this.$emit("blur", e);
190
- // 尝试调用u-form的验证方法
191
- uni.$u.formValidate(this, "blur");
192
- },
193
- onLinechange(e) {
194
- this.$emit("linechange", e);
195
- },
196
- onInput(e) {
197
- let { value = "" } = e.detail || {};
198
- // 格式化过滤方法
199
- const formatter = this.formatter || this.innerFormatter
200
- const formatValue = formatter(value)
201
- // 为了避免props的单向数据流特性,需要先将innerValue值设置为当前值,再在$nextTick中重新赋予设置后的值才有效
202
- this.innerValue = value
203
- this.$nextTick(() => {
204
- this.innerValue = formatValue;
205
- this.valueChange();
206
- })
207
- },
208
- // 内容发生变化,进行处理
209
- valueChange() {
210
- const value = this.innerValue;
211
- this.$nextTick(() => {
212
- // #ifdef VUE3
213
- this.$emit("update:modelValue", value);
214
- // #endif
215
- // #ifdef VUE2
216
- this.$emit("input", value);
217
- // #endif
218
- // 标识value值的变化是由内部引起的
219
- this.changeFromInner = true;
220
- this.$emit("change", value);
221
- // 尝试调用u-form的验证方法
222
- uni.$u.formValidate(this, "change");
223
- });
224
- },
225
- onConfirm(e) {
226
- this.$emit("confirm", e);
227
- },
228
- onKeyboardheightchange(e) {
229
- this.$emit("keyboardheightchange", e);
230
- },
231
- },
232
- };
233
- </script>
234
-
235
- <style lang="scss" scoped>
236
- @import "../../libs/css/components.scss";
237
-
238
- .u-textarea {
239
- border-radius: 4px;
240
- background-color: #fff;
241
- position: relative;
242
- @include flex;
243
- flex: 1;
244
- padding: 9px;
245
-
246
- &--radius {
247
- border-radius: 4px;
248
- }
249
-
250
- &--no-radius {
251
- border-radius: 0;
252
- }
253
-
254
- &--disabled {
255
- background-color: #f5f7fa;
256
- }
257
-
258
- &__field {
259
- flex: 1;
260
- font-size: 15px;
261
- color: $u-content-color;
262
- width: 100%;
263
- }
264
-
265
- &__count {
266
- position: absolute;
267
- right: 5px;
268
- bottom: 2px;
269
- font-size: 12px;
270
- color: $u-tips-color;
271
- background-color: #ffffff;
272
- padding: 1px 4px;
273
- }
274
- }
275
- </style>
1
+ <template>
2
+ <view class="u-textarea" :class="textareaClass" :style="[textareaStyle]">
3
+ <textarea
4
+ class="u-textarea__field"
5
+ :value="innerValue"
6
+ :style="{ height: $u.addUnit(height) }"
7
+ :placeholder="placeholder"
8
+ :placeholder-style="$u.addStyle(placeholderStyle, 'string')"
9
+ :placeholder-class="placeholderClass"
10
+ :disabled="disabled"
11
+ :focus="focus"
12
+ :autoHeight="autoHeight"
13
+ :fixed="fixed"
14
+ :cursorSpacing="cursorSpacing"
15
+ :cursor="cursor"
16
+ :showConfirmBar="showConfirmBar"
17
+ :selectionStart="selectionStart"
18
+ :selectionEnd="selectionEnd"
19
+ :adjustPosition="adjustPosition"
20
+ :disableDefaultPadding="disableDefaultPadding"
21
+ :holdKeyboard="holdKeyboard"
22
+ :maxlength="maxlength"
23
+ :confirm-type="confirmType"
24
+ :ignoreCompositionEvent="ignoreCompositionEvent"
25
+ @focus="onFocus"
26
+ @blur="onBlur"
27
+ @linechange="onLinechange"
28
+ @input="onInput"
29
+ @confirm="onConfirm"
30
+ @keyboardheightchange="onKeyboardheightchange"
31
+ ></textarea>
32
+ <!-- #ifndef MP-ALIPAY -->
33
+ <text
34
+ class="u-textarea__count"
35
+ :style="{
36
+ 'background-color': disabled ? 'transparent' : '#fff',
37
+ }"
38
+ v-if="count"
39
+ >{{ innerValue.length }}/{{ maxlength }}</text
40
+ >
41
+ <!-- #endif -->
42
+ </view>
43
+ </template>
44
+
45
+ <script>
46
+ import props from "./props.js";
47
+ import mpMixin from '../../libs/mixin/mpMixin.js';
48
+ import mixin from '../../libs/mixin/mixin.js';
49
+ /**
50
+ * Textarea 文本域
51
+ * @description 文本域此组件满足了可能出现的表单信息补充,编辑等实际逻辑的功能,内置了字数校验等
52
+ * @tutorial https://ijry.github.io/uview-plus/components/textarea.html
53
+ *
54
+ * @property {String | Number} value 输入框的内容
55
+ * @property {String | Number} placeholder 输入框为空时占位符
56
+ * @property {String} placeholderClass 指定placeholder的样式类,注意页面或组件的style中写了scoped时,需要在类名前写/deep/ ( 默认 'input-placeholder' )
57
+ * @property {String | Object} placeholderStyle 指定placeholder的样式,字符串/对象形式,如"color: red;"
58
+ * @property {String | Number} height 输入框高度(默认 70 )
59
+ * @property {String} confirmType 设置键盘右下角按钮的文字,仅微信小程序,App-vue和H5有效(默认 'done' )
60
+ * @property {Boolean} disabled 是否禁用(默认 false )
61
+ * @property {Boolean} count 是否显示统计字数(默认 false )
62
+ * @property {Boolean} focus 是否自动获取焦点,nvue不支持,H5取决于浏览器的实现(默认 false )
63
+ * @property {Boolean | Function} autoHeight 是否自动增加高度(默认 false )
64
+ * @property {Boolean} fixed 如果textarea是在一个position:fixed的区域,需要显示指定属性fixed为true(默认 false )
65
+ * @property {Number} cursorSpacing 指定光标与键盘的距离(默认 0 )
66
+ * @property {String | Number} cursor 指定focus时的光标位置
67
+ * @property {Function} formatter 内容式化函数
68
+ * @property {Boolean} showConfirmBar 是否显示键盘上方带有”完成“按钮那一栏,(默认 true )
69
+ * @property {Number} selectionStart 光标起始位置,自动聚焦时有效,需与selection-end搭配使用,(默认 -1 )
70
+ * @property {Number | Number} selectionEnd 光标结束位置,自动聚焦时有效,需与selection-start搭配使用(默认 -1 )
71
+ * @property {Boolean} adjustPosition 键盘弹起时,是否自动上推页面(默认 true )
72
+ * @property {Boolean | Number} disableDefaultPadding 是否去掉 iOS 下的默认内边距,只微信小程序有效(默认 false )
73
+ * @property {Boolean} holdKeyboard focus时,点击页面的时候不收起键盘,只微信小程序有效(默认 false )
74
+ * @property {String | Number} maxlength 最大输入长度,设置为 -1 的时候不限制最大长度(默认 140 )
75
+ * @property {String} border 边框类型,surround-四周边框,none-无边框,bottom-底部边框(默认 'surround' )
76
+ * @property {Boolean} ignoreCompositionEvent 是否忽略组件内对文本合成系统事件的处理
77
+ *
78
+ * @event {Function(e)} focus 输入框聚焦时触发,event.detail = { value, height },height 为键盘高度
79
+ * @event {Function(e)} blur 输入框失去焦点时触发,event.detail = {value, cursor}
80
+ * @event {Function(e)} linechange 输入框行数变化时调用,event.detail = {height: 0, heightRpx: 0, lineCount: 0}
81
+ * @event {Function(e)} input 当键盘输入时,触发 input 事件
82
+ * @event {Function(e)} confirm 点击完成时, 触发 confirm 事件
83
+ * @event {Function(e)} keyboardheightchange 键盘高度发生变化的时候触发此事件
84
+ * @example <up-textarea v-model="value1" placeholder="请输入内容" ></up-textarea>
85
+ */
86
+ export default {
87
+ name: "u-textarea",
88
+ mixins: [mpMixin, mixin, props],
89
+ data() {
90
+ return {
91
+ // 输入框的值
92
+ innerValue: "",
93
+ // 是否处于获得焦点状态
94
+ focused: false,
95
+ // value是否第一次变化,在watch中,由于加入immediate属性,会在第一次触发,此时不应该认为value发生了变化
96
+ firstChange: true,
97
+ // value绑定值的变化是由内部还是外部引起的
98
+ changeFromInner: false,
99
+ // 过滤处理方法
100
+ innerFormatter: value => value
101
+ }
102
+ },
103
+ created() {
104
+ },
105
+ watch: {
106
+ // #ifdef VUE2
107
+ value: {
108
+ immediate: true,
109
+ handler(newVal, oldVal) {
110
+ this.innerValue = newVal;
111
+ /* #ifdef H5 */
112
+ // 在H5中,外部value变化后,修改input中的值,不会触发@input事件,此时手动调用值变化方法
113
+ if (
114
+ this.firstChange === false &&
115
+ this.changeFromInner === false
116
+ ) {
117
+ this.valueChange();
118
+ }
119
+ /* #endif */
120
+ this.firstChange = false;
121
+ // 重置changeFromInner的值为false,标识下一次引起默认为外部引起的
122
+ this.changeFromInner = false;
123
+ },
124
+ },
125
+ // #endif
126
+ // #ifdef VUE3
127
+ modelValue: {
128
+ immediate: true,
129
+ handler(newVal, oldVal) {
130
+ this.innerValue = newVal;
131
+ /* #ifdef H5 */
132
+ // 在H5中,外部value变化后,修改input中的值,不会触发@input事件,此时手动调用值变化方法
133
+ if (
134
+ this.firstChange === false &&
135
+ this.changeFromInner === false
136
+ ) {
137
+ this.valueChange();
138
+ }
139
+ /* #endif */
140
+ this.firstChange = false;
141
+ // 重置changeFromInner的值为false,标识下一次引起默认为外部引起的
142
+ this.changeFromInner = false;
143
+ },
144
+ }
145
+ // #endif
146
+ },
147
+ computed: {
148
+ // 组件的类名
149
+ textareaClass() {
150
+ let classes = [],
151
+ { border, disabled } = this;
152
+ border === "surround" &&
153
+ (classes = classes.concat(["u-border", "u-textarea--radius"]));
154
+ border === "bottom" &&
155
+ (classes = classes.concat([
156
+ "u-border-bottom",
157
+ "u-textarea--no-radius",
158
+ ]));
159
+ disabled && classes.push("u-textarea--disabled");
160
+ return classes.join(" ");
161
+ },
162
+ // 组件的样式
163
+ textareaStyle() {
164
+ const style = {};
165
+ // #ifdef APP-NVUE
166
+ // 由于textarea在安卓nvue上的差异性,需要额外再调整其内边距
167
+ if (uni.$u.os() === "android") {
168
+ style.paddingTop = "6px";
169
+ style.paddingLeft = "9px";
170
+ style.paddingBottom = "3px";
171
+ style.paddingRight = "6px";
172
+ }
173
+ // #endif
174
+ return uni.$u.deepMerge(style, uni.$u.addStyle(this.customStyle));
175
+ },
176
+ },
177
+ // #ifdef VUE3
178
+ emits: ['update:modelValue', 'linechange', 'focus', 'blur', 'change', 'confirm', 'keyboardheightchange'],
179
+ // #endif
180
+ methods: {
181
+ // 在微信小程序中,不支持将函数当做props参数,故只能通过ref形式调用
182
+ setFormatter(e) {
183
+ this.innerFormatter = e
184
+ },
185
+ onFocus(e) {
186
+ this.$emit("focus", e);
187
+ },
188
+ onBlur(e) {
189
+ this.$emit("blur", e);
190
+ // 尝试调用u-form的验证方法
191
+ uni.$u.formValidate(this, "blur");
192
+ },
193
+ onLinechange(e) {
194
+ this.$emit("linechange", e);
195
+ },
196
+ onInput(e) {
197
+ let { value = "" } = e.detail || {};
198
+ // 格式化过滤方法
199
+ const formatter = this.formatter || this.innerFormatter
200
+ const formatValue = formatter(value)
201
+ // 为了避免props的单向数据流特性,需要先将innerValue值设置为当前值,再在$nextTick中重新赋予设置后的值才有效
202
+ this.innerValue = value
203
+ this.$nextTick(() => {
204
+ this.innerValue = formatValue;
205
+ this.valueChange();
206
+ })
207
+ },
208
+ // 内容发生变化,进行处理
209
+ valueChange() {
210
+ const value = this.innerValue;
211
+ this.$nextTick(() => {
212
+ // #ifdef VUE3
213
+ this.$emit("update:modelValue", value);
214
+ // #endif
215
+ // #ifdef VUE2
216
+ this.$emit("input", value);
217
+ // #endif
218
+ // 标识value值的变化是由内部引起的
219
+ this.changeFromInner = true;
220
+ this.$emit("change", value);
221
+ // 尝试调用u-form的验证方法
222
+ uni.$u.formValidate(this, "change");
223
+ });
224
+ },
225
+ onConfirm(e) {
226
+ this.$emit("confirm", e);
227
+ },
228
+ onKeyboardheightchange(e) {
229
+ this.$emit("keyboardheightchange", e);
230
+ },
231
+ },
232
+ };
233
+ </script>
234
+
235
+ <style lang="scss" scoped>
236
+ @import "../../libs/css/components.scss";
237
+
238
+ .u-textarea {
239
+ border-radius: 4px;
240
+ background-color: #fff;
241
+ position: relative;
242
+ @include flex;
243
+ flex: 1;
244
+ padding: 9px;
245
+
246
+ &--radius {
247
+ border-radius: 4px;
248
+ }
249
+
250
+ &--no-radius {
251
+ border-radius: 0;
252
+ }
253
+
254
+ &--disabled {
255
+ background-color: #f5f7fa;
256
+ }
257
+
258
+ &__field {
259
+ flex: 1;
260
+ font-size: 15px;
261
+ color: $u-content-color;
262
+ width: 100%;
263
+ }
264
+
265
+ &__count {
266
+ position: absolute;
267
+ right: 5px;
268
+ bottom: 2px;
269
+ font-size: 12px;
270
+ color: $u-tips-color;
271
+ background-color: #ffffff;
272
+ padding: 1px 4px;
273
+ }
274
+ }
275
+ </style>
@@ -6,7 +6,7 @@
6
6
  @tap="clickHandler"
7
7
  :class="classes"
8
8
  :style="[mergeStyle]"
9
- @touchmove.stop.prevent="noop"
9
+ @touchmove="noop"
10
10
  >
11
11
  <slot />
12
12
  </view>