LibWeb: Stub the ServiceWorkerRegistration interface

This commit is contained in:
Tim Ledbetter 2024-08-22 22:59:01 +01:00 committed by Andreas Kling
commit 0c0a4a6042
Notes: github-actions[bot] 2024-08-25 10:54:13 +00:00
8 changed files with 88 additions and 0 deletions

View file

@ -0,0 +1,26 @@
#import <DOM/EventTarget.idl>
#import <DOM/EventHandler.idl>
// https://w3c.github.io/ServiceWorker/#serviceworkerregistration-interface
[SecureContext, Exposed=(Window,Worker)]
interface ServiceWorkerRegistration : EventTarget {
[FIXME] readonly attribute ServiceWorker? installing;
[FIXME] readonly attribute ServiceWorker? waiting;
[FIXME] readonly attribute ServiceWorker? active;
[FIXME, SameObject] readonly attribute NavigationPreloadManager navigationPreload;
[FIXME] readonly attribute USVString scope;
[FIXME] readonly attribute ServiceWorkerUpdateViaCache updateViaCache;
[FIXME, NewObject] Promise<undefined> update();
[FIXME, NewObject] Promise<boolean> unregister();
// event
[FIXME] attribute EventHandler onupdatefound;
};
enum ServiceWorkerUpdateViaCache {
"imports",
"all",
"none"
};