Move types to global app file

This commit is contained in:
2022-08-13 23:38:06 +02:00
parent f688928757
commit 222db0c478
4 changed files with 54 additions and 26 deletions

52
src/app.d.ts vendored
View File

@@ -33,4 +33,56 @@ declare type PhotoGridAbout = {
id: string
title: string
}
}
/**
* Notifcation
*/
declare interface Notification {
title: string
name: string
image: string
timeout?: number
id?: number
}
/**
* Smooth Scroll Options
*/
declare interface smoothScrollOptions {
hash: string
changeHash?: boolean
event?: MouseEvent
callback?: Function
}
/**
* Swipe options
*/
interface SwipeOptions {
travelX?: number
travelY?: number
timeframe?: number
}
/**
* Reveal Animation
*/
declare interface RevealOptions {
enable?: boolean
options?: TransitionOptions
children?: string | HTMLElement
animation: any
}
// Options interface
declare interface TransitionOptions {
threshold?: number
duration?: number
stagger?: number
delay?: number
easing?: any
}