Rename onshow and onhide

animateShow and animateHide are more descriptive
This commit is contained in:
Alexander Skvortsov 2020-09-29 18:37:26 -04:00
parent a2263b8538
commit 9d1a87a4c4
2 changed files with 4 additions and 4 deletions

View File

@ -24,7 +24,7 @@ export default class Modal extends Component {
oncreate(vnode) {
super.oncreate(vnode);
this.attrs.onshow(() => this.onready());
this.attrs.animateShow(() => this.onready());
}
onbeforeremove() {
@ -32,7 +32,7 @@ export default class Modal extends Component {
// we've just opened up a new one, and accordingly,
// we don't need to show a hide animation.
if (!this.attrs.state.modal) {
this.attrs.onhide();
this.attrs.animateHide();
}
}

View File

@ -14,8 +14,8 @@ export default class ModalManager extends Component {
{modal
? modal.componentClass.component({
...modal.attrs,
onshow: this.animateShow.bind(this),
onhide: this.animateHide.bind(this),
animateShow: this.animateShow.bind(this),
animateHide: this.animateHide.bind(this),
state: this.attrs.state,
})
: ''}