diff --git a/baselines/dom.generated.d.ts b/baselines/dom.generated.d.ts index 68476982a..cef8ecfe7 100644 --- a/baselines/dom.generated.d.ts +++ b/baselines/dom.generated.d.ts @@ -1697,6 +1697,12 @@ interface ShadowRootInit { mode: ShadowRootMode; } +interface ShareData { + text?: string; + title?: string; + url?: string; +} + interface SpeechSynthesisErrorEventInit extends SpeechSynthesisEventInit { error: SpeechSynthesisErrorCode; } @@ -10727,6 +10733,7 @@ interface Navigator extends MSFileSaver, MSNavigatorDoNotTrack, NavigatorAutomat msLaunchUri(uri: string, successCallback?: MSLaunchUriCallback, noHandlerCallback?: MSLaunchUriCallback): void; requestMediaKeySystemAccess(keySystem: string, supportedConfigurations: MediaKeySystemConfiguration[]): Promise; sendBeacon(url: string, data?: BodyInit | null): boolean; + share(data?: ShareData): Promise; vibrate(pattern: number | number[]): boolean; } diff --git a/inputfiles/idl/Web Share.widl b/inputfiles/idl/Web Share.widl new file mode 100644 index 000000000..a635a1014 --- /dev/null +++ b/inputfiles/idl/Web Share.widl @@ -0,0 +1,9 @@ +partial interface Navigator { + [SecureContext] Promise share(optional ShareData data = {}); +}; + +dictionary ShareData { + USVString title; + USVString text; + USVString url; +}; diff --git a/inputfiles/idlSources.json b/inputfiles/idlSources.json index 2dd0b18d7..da35b2b38 100644 --- a/inputfiles/idlSources.json +++ b/inputfiles/idlSources.json @@ -635,6 +635,10 @@ "url": "https://w3c.github.io/webrtc-pc/", "title": "WebRTC" }, + { + "url": "https://www.w3.org/TR/web-share/", + "title": "Web Share" + }, { "url": "https://w3c.github.io/speech-api/", "title": "Web Speech API"