♻️ (notification) typing
This commit is contained in:
@@ -1,28 +1,19 @@
|
||||
declare const Notification: any
|
||||
|
||||
let showNotification:
|
||||
| ((
|
||||
title: string,
|
||||
options?: NotificationOptions | undefined
|
||||
) => Promise<void>)
|
||||
| ((title: string, options?: NotificationOptions) => Promise<void>)
|
||||
| null = null
|
||||
|
||||
export const setNotificationInstance = (
|
||||
sn: (
|
||||
title: string,
|
||||
options?: NotificationOptions | undefined
|
||||
) => Promise<void>
|
||||
sn: (title: string, options?: NotificationOptions) => Promise<void>
|
||||
) => {
|
||||
showNotification = sn
|
||||
}
|
||||
|
||||
export const notify = (
|
||||
title: string,
|
||||
options?: NotificationOptions | undefined
|
||||
) => {
|
||||
export const notify = (title: string, options?: NotificationOptions) => {
|
||||
const showCustomNotification = (
|
||||
title: string,
|
||||
options?: NotificationOptions | undefined
|
||||
options?: NotificationOptions
|
||||
) => {
|
||||
if (!showNotification) {
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user