diff --git a/interfaces.d.ts b/interfaces.d.ts index 472b8bb4..26807bf6 100644 --- a/interfaces.d.ts +++ b/interfaces.d.ts @@ -95,6 +95,15 @@ declare module './dist/vaadin-router' { redirect?: string; } + interface AnimateCustomClasses { + enter?: string; + leave?: string; + } + + interface AnimatableRoute extends BaseRoute { + animate?: boolean | AnimateCustomClasses; + } + interface RouteWithAction extends BaseRoute { action: ActionFn; } @@ -103,11 +112,11 @@ declare module './dist/vaadin-router' { bundle: string; } - interface RouteWithChildren extends BaseRoute { + interface RouteWithChildren extends AnimatableRoute { children: Route[] | ChildrenFn; } - interface RouteWithComponent extends BaseRoute { + interface RouteWithComponent extends AnimatableRoute { component: string; } @@ -119,7 +128,7 @@ declare module './dist/vaadin-router' { | RouteWithBundle | RouteWithChildren | RouteWithComponent - | RouteWithRedirect; + | RouteWithRedirect type _Route = Route; export interface RouterOptions {