@@ -10,6 +10,9 @@ Component({
10
10
'l-input-class' ,
11
11
'l-cancel-class'
12
12
] ,
13
+ options : {
14
+ multipleSlots : true // 在组件定义时的选项中启用多slot支持
15
+ } ,
13
16
properties : {
14
17
confirmType : {
15
18
type : String ,
@@ -24,7 +27,7 @@ Component({
24
27
type : String ,
25
28
value : '取消'
26
29
} ,
27
- address :String ,
30
+ address : String ,
28
31
iconColor : {
29
32
type : String ,
30
33
value : '#333'
@@ -33,23 +36,23 @@ Component({
33
36
type : String ,
34
37
value : '28'
35
38
} ,
36
- bgColor :{
37
- type :String ,
38
- value :'#f3f3f3'
39
+ bgColor : {
40
+ type : String ,
41
+ value : '#f3f3f3'
39
42
} ,
40
43
showCancel : {
41
44
type : Boolean ,
42
45
value : true
43
46
} ,
44
- shape :{
45
- type :String ,
46
- value :'primary'
47
+ shape : {
48
+ type : String ,
49
+ value : 'primary'
47
50
} ,
48
- TextAlign :{
49
- type :String ,
50
- value :'left'
51
+ TextAlign : {
52
+ type : String ,
53
+ value : 'left'
51
54
} ,
52
- adress :String ,
55
+ adress : String ,
53
56
// 获取焦点
54
57
focus : {
55
58
type : Boolean ,
@@ -88,8 +91,8 @@ Component({
88
91
* 组件的方法列表
89
92
*/
90
93
methods : {
91
- onCancel ( ) {
92
- this . triggerEvent ( 'onCancel ' )
94
+ onCancel ( ) {
95
+ this . triggerEvent ( 'lincancel ' )
93
96
} ,
94
97
// input属性列表
95
98
handleInputChange ( event ) {
@@ -104,15 +107,15 @@ Component({
104
107
value
105
108
} ) ;
106
109
107
- this . triggerEvent ( 'linchange' , event ) ;
110
+ this . triggerEvent ( 'linchange' , detail ) ;
108
111
} ,
109
112
110
113
handleInputFocus ( event ) {
111
- this . triggerEvent ( 'linfocus' , event ) ;
114
+ this . triggerEvent ( 'linfocus' , event . detail ) ;
112
115
} ,
113
116
114
117
handleInputBlur ( event ) {
115
- this . triggerEvent ( 'linblur' , event ) ;
118
+ this . triggerEvent ( 'linblur' , event . detail ) ;
116
119
} ,
117
120
118
121
handleInputConfirm ( event ) {
@@ -127,14 +130,14 @@ Component({
127
130
value
128
131
} ) ;
129
132
130
- this . triggerEvent ( 'linconfirm' , event ) ;
133
+ this . triggerEvent ( 'linconfirm' , detail ) ;
131
134
} ,
132
135
133
136
onClearTap ( event ) {
134
137
this . setData ( {
135
138
value : ''
136
139
} ) ;
137
- this . triggerEvent ( 'linclear' , event ) ;
140
+ this . triggerEvent ( 'linclear' , event . detail ) ;
138
141
}
139
142
}
140
143
} ) ;
0 commit comments