mirror of
https://github.com/vladmandic/automatic
synced 2026-09-17 16:24:33 +02:00
reorganize js callbacks and startup sequence
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
let lastHeadImg = null;
|
||||
let notificationButton = null;
|
||||
|
||||
function initNotifications() {
|
||||
async function initNotifications() {
|
||||
if (!notificationButton) {
|
||||
notificationButton = gradioApp().getElementById('request_notifications');
|
||||
if (notificationButton) notificationButton.addEventListener('click', (evt) => Notification.requestPermission(), true);
|
||||
@@ -28,5 +28,3 @@ function initNotifications() {
|
||||
};
|
||||
log('sendNotification');
|
||||
}
|
||||
|
||||
onAfterUiUpdate(initNotifications);
|
||||
|
||||
Reference in New Issue
Block a user