From dc976cc74574c75a1775b96d234da7f467adcd5b Mon Sep 17 00:00:00 2001 From: "Manu Mtz.-Almeida" Date: Thu, 4 Oct 2018 17:21:15 +0200 Subject: [PATCH] feat(overlays): expose animation customization --- core/src/components/action-sheet/action-sheet-interface.ts | 4 ++++ core/src/components/alert/alert-interface.ts | 5 ++++- core/src/components/loading/loading-interface.ts | 5 ++++- core/src/components/modal/modal-interface.ts | 5 +++-- core/src/components/picker/picker-interface.ts | 4 ++++ core/src/components/popover/popover-interface.ts | 5 +++-- core/src/components/toast/toast-interface.ts | 5 +++-- 7 files changed, 25 insertions(+), 8 deletions(-) diff --git a/core/src/components/action-sheet/action-sheet-interface.ts b/core/src/components/action-sheet/action-sheet-interface.ts index 05c0defae4..1af727d503 100644 --- a/core/src/components/action-sheet/action-sheet-interface.ts +++ b/core/src/components/action-sheet/action-sheet-interface.ts @@ -1,3 +1,4 @@ +import { AnimationBuilder } from '../../interface'; export interface ActionSheetOptions { header?: string; @@ -10,6 +11,9 @@ export interface ActionSheetOptions { mode?: string; keyboardClose?: boolean; id?: string; + + enterAnimation?: AnimationBuilder; + leaveAnimation?: AnimationBuilder; } export interface ActionSheetButton { diff --git a/core/src/components/alert/alert-interface.ts b/core/src/components/alert/alert-interface.ts index 4afcd935a1..0870f8f829 100644 --- a/core/src/components/alert/alert-interface.ts +++ b/core/src/components/alert/alert-interface.ts @@ -1,4 +1,4 @@ -import { TextFieldTypes } from '../../interface'; +import { AnimationBuilder, TextFieldTypes } from '../../interface'; export interface AlertOptions { header?: string; @@ -14,6 +14,9 @@ export interface AlertOptions { mode?: string; keyboardClose?: boolean; id?: string; + + enterAnimation?: AnimationBuilder; + leaveAnimation?: AnimationBuilder; } export interface AlertInput { diff --git a/core/src/components/loading/loading-interface.ts b/core/src/components/loading/loading-interface.ts index 011587b532..e4f235faab 100644 --- a/core/src/components/loading/loading-interface.ts +++ b/core/src/components/loading/loading-interface.ts @@ -1,4 +1,4 @@ -import { SpinnerTypes } from '../../interface'; +import { AnimationBuilder, SpinnerTypes } from '../../interface'; export interface LoadingOptions { spinner?: SpinnerTypes; @@ -12,4 +12,7 @@ export interface LoadingOptions { mode?: string; keyboardClose?: boolean; id?: string; + + enterAnimation?: AnimationBuilder; + leaveAnimation?: AnimationBuilder; } diff --git a/core/src/components/modal/modal-interface.ts b/core/src/components/modal/modal-interface.ts index b6a3acc498..d4d0dfe308 100644 --- a/core/src/components/modal/modal-interface.ts +++ b/core/src/components/modal/modal-interface.ts @@ -5,8 +5,6 @@ export interface ModalOptions { componentProps?: ComponentProps; showBackdrop?: boolean; backdropDismiss?: boolean; - enterAnimation?: AnimationBuilder; - leaveAnimation?: AnimationBuilder; cssClass?: string | string[]; delegate?: FrameworkDelegate; animated?: boolean; @@ -14,4 +12,7 @@ export interface ModalOptions { mode?: string; keyboardClose?: boolean; id?: string; + + enterAnimation?: AnimationBuilder; + leaveAnimation?: AnimationBuilder; } diff --git a/core/src/components/picker/picker-interface.ts b/core/src/components/picker/picker-interface.ts index 294985aa71..28022eb1d8 100644 --- a/core/src/components/picker/picker-interface.ts +++ b/core/src/components/picker/picker-interface.ts @@ -1,3 +1,4 @@ +import { AnimationBuilder } from '../../interface'; export interface PickerOptions { columns: PickerColumn[]; @@ -9,6 +10,9 @@ export interface PickerOptions { mode?: string; keyboardClose?: boolean; id?: string; + + enterAnimation?: AnimationBuilder; + leaveAnimation?: AnimationBuilder; } export interface PickerButton { diff --git a/core/src/components/popover/popover-interface.ts b/core/src/components/popover/popover-interface.ts index cff3d359f5..81400302f1 100644 --- a/core/src/components/popover/popover-interface.ts +++ b/core/src/components/popover/popover-interface.ts @@ -6,8 +6,6 @@ export interface PopoverOptions { showBackdrop?: boolean; backdropDismiss?: boolean; translucent?: boolean; - enterAnimation?: AnimationBuilder; - leaveAnimation?: AnimationBuilder; cssClass?: string | string[]; event?: Event; delegate?: FrameworkDelegate; @@ -16,4 +14,7 @@ export interface PopoverOptions { mode?: string; keyboardClose?: boolean; id?: string; + + enterAnimation?: AnimationBuilder; + leaveAnimation?: AnimationBuilder; } diff --git a/core/src/components/toast/toast-interface.ts b/core/src/components/toast/toast-interface.ts index 5ff8d520f4..4bb7a9d5c3 100644 --- a/core/src/components/toast/toast-interface.ts +++ b/core/src/components/toast/toast-interface.ts @@ -8,11 +8,12 @@ export interface ToastOptions { closeButtonText?: string; position?: 'top' | 'bottom' | 'middle'; translucent?: boolean; - enterAnimation?: AnimationBuilder; - leaveAnimation?: AnimationBuilder; animated?: boolean; mode?: string; keyboardClose?: boolean; id?: string; + + enterAnimation?: AnimationBuilder; + leaveAnimation?: AnimationBuilder; }