ladybird/Libraries/LibWeb/CookieStore/CookieStore.idl

28 lines
753 B
Text
Raw Normal View History

#import <DOM/EventTarget.idl>
#import <DOM/EventHandler.idl>
#import <HTML/Window.idl>
#import <ServiceWorker/ServiceWorkerGlobalScope.idl>
[GenerateToValue]
dictionary CookieListItem {
USVString name;
USVString value;
};
// https://cookiestore.spec.whatwg.org/#cookiestore
[Exposed=(ServiceWorker,Window), SecureContext]
interface CookieStore : EventTarget {
Promise<CookieListItem?> get(USVString name);
};
// https://cookiestore.spec.whatwg.org/#Window
[SecureContext]
partial interface Window {
[SameObject] readonly attribute CookieStore cookieStore;
};
// https://cookiestore.spec.whatwg.org/#ServiceWorkerGlobalScope
partial interface ServiceWorkerGlobalScope {
[SameObject] readonly attribute CookieStore cookieStore;
};