Commit 076148112f937f1c15c2930539cfe47891361e0a
1 parent
11867c87
update Input textarea style
Showing
3 changed files
with
7 additions
and
20 deletions
Show diff stats
examples/routers/input.vue
1 | <template> | 1 | <template> |
2 | - <div style="width: 100px;"> | ||
3 | - <Input autocomplete="on" v-model="value1" size="large" placeholder="large size"></Input> | ||
4 | - <br> | ||
5 | - <Input v-model="value2" placeholder="default size"></Input> | ||
6 | - <br> | ||
7 | - <Input v-model="value3" size="small" placeholder="small size"></Input> | ||
8 | - <br> | ||
9 | - <Input v-model="value1" size="large" placeholder="large size" icon="ios-clock-outline"></Input> | ||
10 | - <br> | ||
11 | - <Input v-model="value2" placeholder="default size" icon="ios-clock-outline"></Input> | ||
12 | - <br> | ||
13 | - <Input v-model="value3" size="small" placeholder="small size" icon="ios-clock-outline"></Input> | ||
14 | - <br> | ||
15 | - <Input v-model="obj.test" type="textarea" autosize></Input> | 2 | + <div style="width: 300px"> |
3 | + <Input v-model="value7" type="textarea" :autosize="true" placeholder="Enter something..."></Input> | ||
4 | + <Input v-model="value8" type="textarea" :autosize="{minRows: 2,maxRows: 5}" placeholder="Enter something..."></Input> | ||
16 | </div> | 5 | </div> |
17 | </template> | 6 | </template> |
18 | <script> | 7 | <script> |
19 | export default { | 8 | export default { |
20 | data () { | 9 | data () { |
21 | return { | 10 | return { |
22 | - value1: '', | ||
23 | - value2: '', | ||
24 | - value3: '', | ||
25 | - obj: { | ||
26 | - | ||
27 | - } | 11 | + value7: '', |
12 | + value8: '' | ||
28 | } | 13 | } |
29 | } | 14 | } |
30 | } | 15 | } |
src/styles/common/normalize.less
src/styles/mixins/input.less
@@ -72,6 +72,7 @@ | @@ -72,6 +72,7 @@ | ||
72 | textarea& { | 72 | textarea& { |
73 | max-width: 100%; | 73 | max-width: 100%; |
74 | height: auto; | 74 | height: auto; |
75 | + min-height: @input-height-base; | ||
75 | vertical-align: bottom; | 76 | vertical-align: bottom; |
76 | font-size: @font-size-base; | 77 | font-size: @font-size-base; |
77 | } | 78 | } |