mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 19:21:34 +08:00
fix(actionsheet): iOS transition speed
This commit is contained in:
@ -140,7 +140,7 @@ const OVERLAY_TYPE = 'action-sheet';
|
|||||||
class ActionSheetAnimation extends Animation {
|
class ActionSheetAnimation extends Animation {
|
||||||
constructor(element) {
|
constructor(element) {
|
||||||
super(element);
|
super(element);
|
||||||
this.easing('cubic-bezier(.36, .66, .04, 1)').duration(450);
|
this.easing('cubic-bezier(.36, .66, .04, 1)');
|
||||||
|
|
||||||
this.backdrop = new Animation(element.querySelector('backdrop'));
|
this.backdrop = new Animation(element.querySelector('backdrop'));
|
||||||
this.wrapper = new Animation(element.querySelector('action-sheet-wrapper'));
|
this.wrapper = new Animation(element.querySelector('action-sheet-wrapper'));
|
||||||
@ -152,6 +152,7 @@ class ActionSheetAnimation extends Animation {
|
|||||||
class ActionSheetSlideIn extends ActionSheetAnimation {
|
class ActionSheetSlideIn extends ActionSheetAnimation {
|
||||||
constructor(element) {
|
constructor(element) {
|
||||||
super(element);
|
super(element);
|
||||||
|
this.duration(400);
|
||||||
this.backdrop.fromTo('opacity', 0.01, 0.4);
|
this.backdrop.fromTo('opacity', 0.01, 0.4);
|
||||||
this.wrapper.fromTo('translateY', '100%', '0%');
|
this.wrapper.fromTo('translateY', '100%', '0%');
|
||||||
}
|
}
|
||||||
@ -161,6 +162,7 @@ Animation.register('action-sheet-slide-in', ActionSheetSlideIn);
|
|||||||
class ActionSheetSlideOut extends ActionSheetAnimation {
|
class ActionSheetSlideOut extends ActionSheetAnimation {
|
||||||
constructor(element) {
|
constructor(element) {
|
||||||
super(element);
|
super(element);
|
||||||
|
this.duration(300);
|
||||||
this.backdrop.fromTo('opacity', 0.4, 0.01);
|
this.backdrop.fromTo('opacity', 0.4, 0.01);
|
||||||
this.wrapper.fromTo('translateY', '0%', '100%');
|
this.wrapper.fromTo('translateY', '0%', '100%');
|
||||||
}
|
}
|
||||||
@ -171,6 +173,7 @@ Animation.register('action-sheet-slide-out', ActionSheetSlideOut);
|
|||||||
class ActionSheetMdSlideIn extends ActionSheetSlideIn {
|
class ActionSheetMdSlideIn extends ActionSheetSlideIn {
|
||||||
constructor(element) {
|
constructor(element) {
|
||||||
super(element);
|
super(element);
|
||||||
|
this.duration(450);
|
||||||
this.backdrop.fromTo('opacity', 0.01, 0.26);
|
this.backdrop.fromTo('opacity', 0.01, 0.26);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -179,6 +182,7 @@ Animation.register('action-sheet-md-slide-in', ActionSheetMdSlideIn);
|
|||||||
class ActionSheetMdSlideOut extends ActionSheetSlideOut {
|
class ActionSheetMdSlideOut extends ActionSheetSlideOut {
|
||||||
constructor(element) {
|
constructor(element) {
|
||||||
super(element);
|
super(element);
|
||||||
|
this.duration(450);
|
||||||
this.backdrop.fromTo('opacity', 0.26, 0.01);
|
this.backdrop.fromTo('opacity', 0.26, 0.01);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user