perf(Dialog): inherit opened event

This commit is contained in:
chenjiahan 2020-08-26 14:00:34 +08:00
parent e045fb1596
commit 627e376cfb

View File

@ -50,7 +50,7 @@ export default createComponent({
}, },
}, },
emits: ['opened', 'closed', 'confirm', 'cancel', 'update:show'], emits: ['confirm', 'cancel', 'update:show'],
data() { data() {
return { return {
@ -97,14 +97,6 @@ export default createComponent({
} }
}, },
onOpened() {
this.$emit('opened');
},
onClosed() {
this.$emit('closed');
},
genRoundButtons() { genRoundButtons() {
return ( return (
<ActionBar class={bem('footer')}> <ActionBar class={bem('footer')}>
@ -215,8 +207,6 @@ export default createComponent({
transition={this.transition} transition={this.transition}
lazyRender={this.lazyRender} lazyRender={this.lazyRender}
aria-labelledby={this.title || message} aria-labelledby={this.title || message}
onOpened={this.onOpened}
onClosed={this.onClosed}
> >
{Title} {Title}
{this.genContent(title)} {this.genContent(title)}