Mobile gallery

This commit is contained in:
space-nuko
2023-05-31 19:19:23 -05:00
parent 3cd623fd20
commit 4547cc1a27
12 changed files with 167 additions and 87 deletions

View File

@@ -18,6 +18,7 @@ function notifyf7(text: string, options: NotifyOptions) {
if (!f7)
return;
console.error(options)
let closeTimeout = options.timeout
if (closeTimeout === undefined)
closeTimeout = 3000;
@@ -27,6 +28,11 @@ function notifyf7(text: string, options: NotifyOptions) {
on.click = () => options.onClick();
}
let icon = null;
if (options.imageUrl) {
icon = `<img src="${options.imageUrl}"/>`
}
const notification = f7.notification.create({
title: options.title,
titleRightText: 'now',
@@ -35,7 +41,7 @@ function notifyf7(text: string, options: NotifyOptions) {
closeOnClick: true,
closeTimeout,
on,
icon: options.imageUrl
icon
});
notification.open();
}