1self.addEventListener('push', (event) => { 2 const data = event.data ? event.data.json() : {} 3 const title = data.title || 'VidDoc' 4 const options = { 5 body: data.body || 'ТÑанÑкÑибаÑÐ¸Ñ Ð·Ð°Ð²ÐµÑÑена', 6 icon: '/viddoc-logo.svg', 7 badge: '/viddoc-logo.svg', 8 data: { url: data.url || '/cabinet' }, 9 } 10 event.waitUntil(self.registration.showNotification(title, options)) 11}) 12 13self.addEventListener('notificationclick', (event) => { 14 event.notification.close() 15 const url = event.notification.data?.url || '/cabinet' 16 event.waitUntil( 17 clients.matchAll({ type: 'window', includeUncontrolled: true }).then((tabs) => { 18 const existing = tabs.find((tab) => tab.url.includes('/cabinet')) 19 if (existing) { 20 existing.navigate(url) 21 return existing.focus() 22 } 23 return clients.openWindow(url) 24 }) 25 ) 26})
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.