File tree Expand file tree Collapse file tree 3 files changed +15
-0
lines changed Expand file tree Collapse file tree 3 files changed +15
-0
lines changed Original file line number Diff line number Diff line change 1+ export default {
2+ methods : {
3+ focus ( ) {
4+ this . $refs . input . focus ( )
5+ } ,
6+ blur ( ) {
7+ this . $refs . input . blur ( )
8+ }
9+ }
10+ }
Original file line number Diff line number Diff line change 3030</template >
3131
3232<script type="text/ecmascript-6">
33+ import inputMixin from ' ../../common/mixins/input'
3334 const COMPONENT_NAME = ' cube-input'
3435 const EVENT_INPUT = ' input'
3536 const EVENT_CHANGE = ' change'
3839
3940 export default {
4041 name: COMPONENT_NAME ,
42+ mixins: [inputMixin],
4143 props: {
4244 value: [String , Number ],
4345 type: {
Original file line number Diff line number Diff line change 11<template >
22 <div class =" cube-textarea-wrapper" :class =" {'cube-textarea_expanded': expanded, 'cube-textarea_active': isFocus}" >
33 <textarea
4+ ref =" input"
45 class =" cube-textarea"
56 v-model =" textareaValue"
67 v-bind =" $props"
1516</template >
1617
1718<script type="text/ecmascript-6">
19+ import inputMixin from ' ../../common/mixins/input'
1820 const COMPONENT_NAME = ' cube-textarea'
1921 const EVENT_INPUT = ' input'
2022
2527
2628 export default {
2729 name: COMPONENT_NAME ,
30+ mixins: [inputMixin],
2831 data () {
2932 return {
3033 textareaValue: this .value ,
You can’t perform that action at this time.
0 commit comments