mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 19:21:34 +08:00
update to use host
This commit is contained in:
@ -23,14 +23,12 @@ export class Segment {
|
||||
return {
|
||||
selector: 'ion-segment',
|
||||
appInjector: [ControlDirective],
|
||||
hostListeners: {
|
||||
'click': 'buttonClicked($event)'
|
||||
},
|
||||
properties: [
|
||||
'value'
|
||||
],
|
||||
hostProperties: {
|
||||
value: 'value'
|
||||
host: {
|
||||
'(click)': 'buttonClicked($event)',
|
||||
'[value]': 'value'
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -113,17 +111,14 @@ export class Segment {
|
||||
}
|
||||
|
||||
|
||||
@Component({
|
||||
@Directive({
|
||||
selector: 'ion-segment-button',
|
||||
hostListeners: {
|
||||
'click': 'buttonClicked($event)'
|
||||
},
|
||||
properties: [
|
||||
'value'
|
||||
]
|
||||
})
|
||||
@View({
|
||||
template: '<content></content>'
|
||||
],
|
||||
host: {
|
||||
'(click)': 'buttonClicked($event)'
|
||||
}
|
||||
})
|
||||
export class SegmentButton {
|
||||
constructor(
|
||||
|
Reference in New Issue
Block a user