Update web-platform-tests to revision 4333a1d2f109795547fc5e22ebfc8481fa649de7

This commit is contained in:
WPT Sync Bot 2018-06-22 21:05:34 -04:00
parent 728ebcc932
commit 8c46b67f8e
456 changed files with 10561 additions and 5108 deletions

View file

@ -1,4 +1,7 @@
// 4.1. Extensions to ServiceWorkerGlobalScope
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Background Fetch" spec.
// See: https://wicg.github.io/background-fetch/
partial interface ServiceWorkerGlobalScope {
attribute EventHandler onbackgroundfetched;
@ -7,14 +10,10 @@ partial interface ServiceWorkerGlobalScope {
attribute EventHandler onbackgroundfetchclick;
};
// 4.2. Extensions to ServiceWorkerRegistration
partial interface ServiceWorkerRegistration {
readonly attribute BackgroundFetchManager backgroundFetch;
};
// 4.3. BackgroundFetchManager
[Exposed=(Window,Worker)]
interface BackgroundFetchManager {
Promise<BackgroundFetchRegistration> fetch(DOMString id, (RequestInfo or sequence<RequestInfo>) requests, optional BackgroundFetchOptions options);
@ -24,21 +23,19 @@ interface BackgroundFetchManager {
};
dictionary BackgroundFetchOptions {
sequence<IconDefinition> icons;
DOMString title;
unsigned long long downloadTotal;
sequence<IconDefinition> icons = [];
DOMString title = "";
unsigned long long downloadTotal = 0;
};
// This is taken from https://w3c.github.io/manifest/#icons-member.
// This definition should probably be moved somewhere more general.
dictionary IconDefinition {
DOMString src;
DOMString sizes;
DOMString type;
DOMString sizes = "";
DOMString type = "";
};
// 4.4. BackgroundFetchRegistration
[Exposed=(Window,Worker)]
interface BackgroundFetchRegistration : EventTarget {
readonly attribute DOMString id;
@ -70,8 +67,6 @@ interface BackgroundFetchActiveFetch : BackgroundFetchFetch {
// In future this will include a fetch observer
};
// 4.4.3. BackgroundFetchEvent
[Constructor(DOMString type, BackgroundFetchEventInit init), Exposed=ServiceWorker]
interface BackgroundFetchEvent : ExtendableEvent {
readonly attribute DOMString id;
@ -81,8 +76,6 @@ dictionary BackgroundFetchEventInit : ExtendableEventInit {
required DOMString id;
};
// 4.4.4. BackgroundFetchSettledEvent
[Constructor(DOMString type, BackgroundFetchSettledEventInit init), Exposed=ServiceWorker]
interface BackgroundFetchSettledEvent : BackgroundFetchEvent {
readonly attribute BackgroundFetchSettledFetches fetches;
@ -103,15 +96,11 @@ interface BackgroundFetchSettledFetch : BackgroundFetchFetch {
readonly attribute Response? response;
};
// 4.4.5. BackgroundFetchUpdateEvent
[Constructor(DOMString type, BackgroundFetchSettledEventInit init), Exposed=ServiceWorker]
interface BackgroundFetchUpdateEvent : BackgroundFetchSettledEvent {
Promise<void> updateUI(DOMString title);
};
// 4.4.6. BackgroundFetchClickEvent
[Constructor(DOMString type, BackgroundFetchClickEventInit init), Exposed=ServiceWorker]
interface BackgroundFetchClickEvent : BackgroundFetchEvent {
readonly attribute BackgroundFetchState state;

View file

@ -0,0 +1,8 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Beacon" spec.
// See: https://w3c.github.io/beacon/
partial interface Navigator {
boolean sendBeacon(USVString url, optional BodyInit? data = null);
};

View file

@ -0,0 +1,14 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "CORS and RFC1918" spec.
// See: https://wicg.github.io/cors-rfc1918/
enum AddressSpace { "local", "private", "public" };
partial interface Document {
readonly attribute AddressSpace addressSpace;
};
partial interface WorkerGlobalScope {
readonly attribute AddressSpace addressSpace;
};

View file

@ -0,0 +1,45 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "CSS Animations Level 1" spec.
// See: https://drafts.csswg.org/css-animations/
[Exposed=Window,
Constructor(CSSOMString type, optional AnimationEventInit animationEventInitDict)]
interface AnimationEvent : Event {
readonly attribute CSSOMString animationName;
readonly attribute double elapsedTime;
readonly attribute CSSOMString pseudoElement;
};
dictionary AnimationEventInit : EventInit {
CSSOMString animationName = "";
double elapsedTime = 0.0;
CSSOMString pseudoElement = "";
};
partial interface CSSRule {
const unsigned short KEYFRAMES_RULE = 7;
const unsigned short KEYFRAME_RULE = 8;
};
[Exposed=Window]
interface CSSKeyframeRule : CSSRule {
attribute CSSOMString keyText;
[SameObject, PutForwards=cssText] readonly attribute CSSStyleDeclaration style;
};
[Exposed=Window]
interface CSSKeyframesRule : CSSRule {
attribute CSSOMString name;
readonly attribute CSSRuleList cssRules;
void appendRule(CSSOMString rule);
void deleteRule(CSSOMString select);
CSSKeyframeRule? findRule(CSSOMString select);
};
partial interface GlobalEventHandlers {
attribute EventHandler onanimationstart;
attribute EventHandler onanimationiteration;
attribute EventHandler onanimationend;
attribute EventHandler onanimationcancel;
};

View file

@ -0,0 +1,33 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the CSS Conditional Rules spec.
// See https://drafts.csswg.org/css-conditional/
partial interface CSSRule {
const unsigned short SUPPORTS_RULE = 12;
};
[Exposed=Window]
interface CSSGroupingRule : CSSRule {
readonly attribute CSSRuleList cssRules;
unsigned long insertRule (CSSOMString rule, unsigned long index);
void deleteRule (unsigned long index);
};
[Exposed=Window]
interface CSSConditionRule : CSSGroupingRule {
attribute CSSOMString conditionText;
};
[Exposed=Window]
interface CSSMediaRule : CSSConditionRule {
[SameObject, PutForwards=mediaText] readonly attribute MediaList media;
};
[Exposed=Window]
interface CSSSupportsRule : CSSConditionRule {
};
partial interface CSS {
static boolean supports(CSSOMString property, CSSOMString value);
static boolean supports(CSSOMString conditionText);
};

View file

@ -0,0 +1,25 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "CSS Transitions" spec.
// See: https://drafts.csswg.org/css-transitions/
[Exposed=Window,
Constructor(CSSOMString type, optional TransitionEventInit transitionEventInitDict)]
interface TransitionEvent : Event {
readonly attribute CSSOMString propertyName;
readonly attribute double elapsedTime;
readonly attribute CSSOMString pseudoElement;
};
dictionary TransitionEventInit : EventInit {
CSSOMString propertyName = "";
double elapsedTime = 0.0;
CSSOMString pseudoElement = "";
};
partial interface GlobalEventHandlers {
attribute EventHandler ontransitionrun;
attribute EventHandler ontransitionstart;
attribute EventHandler ontransitionend;
attribute EventHandler ontransitioncancel;
};

View file

@ -1,75 +1,72 @@
// Encrypted Media Extensions WebIDL
//
// NOTE: Please update the link below to the specification version from
// which this IDL was extracted.
//
// https://www.w3.org/TR/2016/WD-encrypted-media-20160610/
// + commit 5499821932391ae2c2e53756ae7ab9fae89d5863
//
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Encrypted Media Extensions" spec.
// See: https://w3c.github.io/encrypted-media/
[Exposed=Window]
partial interface Navigator {
Promise<MediaKeySystemAccess> requestMediaKeySystemAccess (DOMString keySystem, sequence<MediaKeySystemConfiguration> supportedConfigurations);
[SecureContext] Promise<MediaKeySystemAccess> requestMediaKeySystemAccess(DOMString keySystem,
sequence<MediaKeySystemConfiguration> supportedConfigurations);
};
enum MediaKeysRequirement {
"required",
"optional",
"not-allowed"
};
dictionary MediaKeySystemConfiguration {
DOMString label = "";
sequence<DOMString> initDataTypes = [];
sequence<MediaKeySystemMediaCapability> audioCapabilities = [];
sequence<MediaKeySystemMediaCapability> videoCapabilities = [];
MediaKeysRequirement distinctiveIdentifier = "optional";
MediaKeysRequirement persistentState = "optional";
sequence<DOMString> sessionTypes;
DOMString label = "";
sequence<DOMString> initDataTypes = [];
sequence<MediaKeySystemMediaCapability> audioCapabilities = [];
sequence<MediaKeySystemMediaCapability> videoCapabilities = [];
MediaKeysRequirement distinctiveIdentifier = "optional";
MediaKeysRequirement persistentState = "optional";
sequence<DOMString> sessionTypes;
};
dictionary MediaKeySystemMediaCapability {
DOMString contentType = "";
DOMString robustness = "";
DOMString contentType = "";
DOMString robustness = "";
};
[Exposed=Window,
SecureContext]
interface MediaKeySystemAccess {
readonly attribute DOMString keySystem;
MediaKeySystemConfiguration getConfiguration ();
Promise<MediaKeys> createMediaKeys ();
readonly attribute DOMString keySystem;
MediaKeySystemConfiguration getConfiguration();
Promise<MediaKeys> createMediaKeys();
};
enum MediaKeySessionType {
"temporary",
"persistent-usage-record",
"persistent-license"
};
[Exposed=Window,
SecureContext]
interface MediaKeys {
MediaKeySession createSession (optional MediaKeySessionType sessionType = "temporary");
Promise<boolean> setServerCertificate (BufferSource serverCertificate);
MediaKeySession createSession(optional MediaKeySessionType sessionType = "temporary");
Promise<boolean> setServerCertificate(BufferSource serverCertificate);
};
[Exposed=Window,
SecureContext]
interface MediaKeySession : EventTarget {
readonly attribute DOMString sessionId;
readonly attribute unrestricted double expiration;
readonly attribute Promise<void> closed;
readonly attribute MediaKeyStatusMap keyStatuses;
attribute EventHandler onkeystatuseschange;
attribute EventHandler onmessage;
Promise<void> generateRequest (DOMString initDataType, BufferSource initData);
Promise<boolean> load (DOMString sessionId);
Promise<void> update (BufferSource response);
Promise<void> close ();
Promise<void> remove ();
readonly attribute DOMString sessionId;
readonly attribute unrestricted double expiration;
readonly attribute Promise<void> closed;
readonly attribute MediaKeyStatusMap keyStatuses;
attribute EventHandler onkeystatuseschange;
attribute EventHandler onmessage;
Promise<void> generateRequest(DOMString initDataType,
BufferSource initData);
Promise<boolean> load(DOMString sessionId);
Promise<void> update(BufferSource response);
Promise<void> close();
Promise<void> remove();
};
[Exposed=Window,
SecureContext]
interface MediaKeyStatusMap {
iterable<BufferSource,MediaKeyStatus>;
readonly attribute unsigned long size;
boolean has (BufferSource keyId);
any get (BufferSource keyId);
iterable<BufferSource, MediaKeyStatus>;
readonly attribute unsigned long size;
boolean has(BufferSource keyId);
any get(BufferSource keyId);
};
enum MediaKeyStatus {
"usable",
"expired",
@ -79,41 +76,38 @@ enum MediaKeyStatus {
"status-pending",
"internal-error"
};
enum MediaKeyMessageType {
"license-request",
"license-renewal",
"license-release",
"individualization-request"
};
[Constructor(DOMString type, MediaKeyMessageEventInit eventInitDict)]
[Exposed=Window,
SecureContext,
Constructor(DOMString type, MediaKeyMessageEventInit eventInitDict)]
interface MediaKeyMessageEvent : Event {
readonly attribute MediaKeyMessageType messageType;
readonly attribute ArrayBuffer message;
readonly attribute MediaKeyMessageType messageType;
readonly attribute ArrayBuffer message;
};
dictionary MediaKeyMessageEventInit : EventInit {
required MediaKeyMessageType messageType;
required ArrayBuffer message;
required MediaKeyMessageType messageType;
required ArrayBuffer message;
};
// partial interface HTMLMediaElement : EventTarget {
[Exposed=Window]
partial interface HTMLMediaElement {
readonly attribute MediaKeys? mediaKeys;
attribute EventHandler onencrypted;
attribute EventHandler onwaitingforkey;
Promise<void> setMediaKeys (MediaKeys? mediaKeys);
[SecureContext]
readonly attribute MediaKeys? mediaKeys;
attribute EventHandler onencrypted;
attribute EventHandler onwaitingforkey;
[SecureContext] Promise<void> setMediaKeys(MediaKeys? mediaKeys);
};
[Constructor(DOMString type, optional MediaEncryptedEventInit eventInitDict)]
[Exposed=Window,
Constructor(DOMString type, optional MediaEncryptedEventInit eventInitDict)]
interface MediaEncryptedEvent : Event {
readonly attribute DOMString initDataType;
readonly attribute ArrayBuffer? initData;
readonly attribute DOMString initDataType;
readonly attribute ArrayBuffer? initData;
};
dictionary MediaEncryptedEventInit : EventInit {
DOMString initDataType = "";
ArrayBuffer? initData = null;
DOMString initDataType = "";
ArrayBuffer? initData = null;
};

View file

@ -0,0 +1,76 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Media Capture Depth Stream Extensions" spec.
// See: https://w3c.github.io/mediacapture-depth/
partial dictionary MediaTrackSupportedConstraints {
// Apply to both depth stream track and color stream track:
boolean videoKind = true;
boolean focalLengthX = false;
boolean focalLengthY = false;
boolean principalPointX = false;
boolean principalPointY = false;
boolean deprojectionDistortionCoefficients = false;
boolean projectionDistortionCoefficients = false;
// Apply to depth stream track:
boolean depthNear = false;
boolean depthFar = false;
boolean depthToVideoTransform = false;
};
partial dictionary MediaTrackCapabilities {
// Apply to both depth stream track and color stream track:
DOMString videoKind;
(double or DoubleRange) focalLengthX;
(double or DoubleRange) focalLengthY;
(double or DoubleRange) principalPointX;
(double or DoubleRange) principalPointY;
boolean deprojectionDistortionCoefficients;
boolean projectionDistortionCoefficients;
// Apply to depth stream track:
(double or DoubleRange) depthNear;
(double or DoubleRange) depthFar;
boolean depthToVideoTransform;
};
partial dictionary MediaTrackConstraintSet {
// Apply to both depth stream track and color stream track:
ConstrainDOMString videoKind;
ConstrainDouble focalLengthX;
ConstrainDouble focalLengthY;
ConstrainDouble principalPointX;
ConstrainDouble principalPointY;
ConstrainBoolean deprojectionDistortionCoefficients;
ConstrainBoolean projectionDistortionCoefficients;
// Apply to depth stream track:
ConstrainDouble depthNear;
ConstrainDouble depthFar;
ConstrainBoolean depthToVideoTransform;
};
partial dictionary MediaTrackSettings {
// Apply to both depth stream track and color stream track:
DOMString videoKind;
double focalLengthX;
double focalLengthY;
double principalPointX;
double principalPointY;
DistortionCoefficients deprojectionDistortionCoefficients;
DistortionCoefficients projectionDistortionCoefficients;
// Apply to depth stream track:
double depthNear;
double depthFar;
Transformation depthToVideoTransform;
};
dictionary DistortionCoefficients {
double k1;
double k2;
double p1;
double p2;
double k3;
};
dictionary Transformation {
Float32Array transformationMatrix;
DOMString videoDeviceId;
};
enum VideoKindEnum {
"color",
"depth"
};

View file

@ -0,0 +1,16 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Media Capture from DOM Elements" spec.
// See: https://w3c.github.io/mediacapture-fromelement/
partial interface HTMLMediaElement {
MediaStream captureStream();
};
partial interface HTMLCanvasElement {
MediaStream captureStream(optional double frameRequestRate);
};
[Exposed=Window]
interface CanvasCaptureMediaStreamTrack : MediaStreamTrack {
readonly attribute HTMLCanvasElement canvas;
void requestFrame();
};

View file

@ -0,0 +1,150 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the MediaStream Image Capture spec.
// See https://w3c.github.io/mediacapture-image/
[Exposed=Window, Constructor(MediaStreamTrack videoTrack)]
interface ImageCapture {
Promise<Blob> takePhoto(optional PhotoSettings photoSettings);
Promise<PhotoCapabilities> getPhotoCapabilities();
Promise<PhotoSettings> getPhotoSettings();
Promise<ImageBitmap> grabFrame();
readonly attribute MediaStreamTrack track;
};
[Exposed=Window] interface PhotoCapabilities {
readonly attribute RedEyeReduction redEyeReduction;
readonly attribute MediaSettingsRange imageHeight;
readonly attribute MediaSettingsRange imageWidth;
readonly attribute FrozenArray<FillLightMode> fillLightMode;
};
dictionary PhotoSettings {
FillLightMode fillLightMode;
double imageHeight;
double imageWidth;
boolean redEyeReduction;
};
[Exposed=Window] interface MediaSettingsRange {
readonly attribute double max;
readonly attribute double min;
readonly attribute double step;
};
enum RedEyeReduction {
"never",
"always",
"controllable"
};
enum FillLightMode {
"auto",
"off",
"flash"
};
partial dictionary MediaTrackSupportedConstraints {
boolean whiteBalanceMode = true;
boolean exposureMode = true;
boolean focusMode = true;
boolean pointsOfInterest = true;
boolean exposureCompensation = true;
boolean exposureTime = true;
boolean colorTemperature = true;
boolean iso = true;
boolean brightness = true;
boolean contrast = true;
boolean saturation = true;
boolean sharpness = true;
boolean focusDistance = true;
boolean zoom = true;
boolean torch = true;
};
partial dictionary MediaTrackCapabilities {
sequence<DOMString> whiteBalanceMode;
sequence<DOMString> exposureMode;
sequence<DOMString> focusMode;
MediaSettingsRange exposureCompensation;
MediaSettingsRange exposureTime;
MediaSettingsRange colorTemperature;
MediaSettingsRange iso;
MediaSettingsRange brightness;
MediaSettingsRange contrast;
MediaSettingsRange saturation;
MediaSettingsRange sharpness;
MediaSettingsRange focusDistance;
MediaSettingsRange zoom;
boolean torch;
};
partial dictionary MediaTrackConstraintSet {
ConstrainDOMString whiteBalanceMode;
ConstrainDOMString exposureMode;
ConstrainDOMString focusMode;
ConstrainPoint2D pointsOfInterest;
ConstrainDouble exposureCompensation;
ConstrainDouble exposureTime;
ConstrainDouble colorTemperature;
ConstrainDouble iso;
ConstrainDouble brightness;
ConstrainDouble contrast;
ConstrainDouble saturation;
ConstrainDouble sharpness;
ConstrainDouble focusDistance;
ConstrainDouble zoom;
ConstrainBoolean torch;
};
partial dictionary MediaTrackSettings {
DOMString whiteBalanceMode;
DOMString exposureMode;
DOMString focusMode;
sequence<Point2D> pointsOfInterest;
double exposureCompensation;
double exposureTime;
double colorTemperature;
double iso;
double brightness;
double contrast;
double saturation;
double sharpness;
double focusDistance;
double zoom;
boolean torch;
};
dictionary ConstrainPoint2DParameters {
sequence<Point2D> exact;
sequence<Point2D> ideal;
};
typedef (sequence<Point2D> or ConstrainPoint2DParameters) ConstrainPoint2D;
enum MeteringMode {
"none",
"manual",
"single-shot",
"continuous"
};
dictionary Point2D {
double x = 0.0;
double y = 0.0;
};

View file

@ -1,39 +1,43 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the Media Capture and Streams spec.
// See https://w3c.github.io/mediacapture-main/
[Exposed=Window,
Constructor,
Constructor(MediaStream stream),
Constructor(sequence<MediaStreamTrack> tracks)]
Constructor (MediaStream stream),
Constructor (sequence<MediaStreamTrack> tracks)]
interface MediaStream : EventTarget {
readonly attribute DOMString id;
sequence<MediaStreamTrack> getAudioTracks();
sequence<MediaStreamTrack> getVideoTracks();
sequence<MediaStreamTrack> getTracks();
MediaStreamTrack? getTrackById(DOMString trackId);
void addTrack(MediaStreamTrack track);
void removeTrack(MediaStreamTrack track);
MediaStream clone();
readonly attribute boolean active;
attribute EventHandler onaddtrack;
attribute EventHandler onremovetrack;
readonly attribute DOMString id;
sequence<MediaStreamTrack> getAudioTracks ();
sequence<MediaStreamTrack> getVideoTracks ();
sequence<MediaStreamTrack> getTracks ();
MediaStreamTrack? getTrackById (DOMString trackId);
void addTrack (MediaStreamTrack track);
void removeTrack (MediaStreamTrack track);
MediaStream clone ();
readonly attribute boolean active;
attribute EventHandler onaddtrack;
attribute EventHandler onremovetrack;
};
[Exposed=Window]
interface MediaStreamTrack : EventTarget {
readonly attribute DOMString kind;
readonly attribute DOMString id;
readonly attribute DOMString label;
attribute boolean enabled;
readonly attribute boolean muted;
attribute EventHandler onmute;
attribute EventHandler onunmute;
readonly attribute MediaStreamTrackState readyState;
attribute EventHandler onended;
MediaStreamTrack clone();
void stop();
MediaTrackCapabilities getCapabilities();
MediaTrackConstraints getConstraints();
MediaTrackSettings getSettings();
Promise<void> applyConstraints(optional MediaTrackConstraints constraints);
attribute EventHandler onoverconstrained;
readonly attribute DOMString kind;
readonly attribute DOMString id;
readonly attribute DOMString label;
attribute boolean enabled;
readonly attribute boolean muted;
attribute EventHandler onmute;
attribute EventHandler onunmute;
readonly attribute MediaStreamTrackState readyState;
attribute EventHandler onended;
MediaStreamTrack clone ();
void stop ();
MediaTrackCapabilities getCapabilities ();
MediaTrackConstraints getConstraints ();
MediaTrackSettings getSettings ();
Promise<void> applyConstraints (optional MediaTrackConstraints constraints);
attribute EventHandler onoverconstrained;
};
enum MediaStreamTrackState {
@ -42,71 +46,83 @@ enum MediaStreamTrackState {
};
dictionary MediaTrackSupportedConstraints {
boolean width = true;
boolean height = true;
boolean aspectRatio = true;
boolean frameRate = true;
boolean facingMode = true;
boolean volume = true;
boolean sampleRate = true;
boolean sampleSize = true;
boolean echoCancellation = true;
boolean latency = true;
boolean channelCount = true;
boolean deviceId = true;
boolean groupId = true;
boolean width = true;
boolean height = true;
boolean aspectRatio = true;
boolean frameRate = true;
boolean facingMode = true;
boolean resizeMode = true;
boolean volume = true;
boolean sampleRate = true;
boolean sampleSize = true;
boolean echoCancellation = true;
boolean autoGainControl = true;
boolean noiseSuppression = true;
boolean latency = true;
boolean channelCount = true;
boolean deviceId = true;
boolean groupId = true;
};
dictionary MediaTrackCapabilities {
LongRange width;
LongRange height;
DoubleRange aspectRatio;
DoubleRange frameRate;
sequence<DOMString> facingMode;
DoubleRange volume;
LongRange sampleRate;
LongRange sampleSize;
sequence<boolean> echoCancellation;
DoubleRange latency;
LongRange channelCount;
DOMString deviceId;
DOMString groupId;
ULongRange width;
ULongRange height;
DoubleRange aspectRatio;
DoubleRange frameRate;
sequence<DOMString> facingMode;
sequence<DOMString> resizeMode;
DoubleRange volume;
ULongRange sampleRate;
ULongRange sampleSize;
sequence<boolean> echoCancellation;
sequence<boolean> autoGainControl;
sequence<boolean> noiseSuppression;
DoubleRange latency;
ULongRange channelCount;
DOMString deviceId;
DOMString groupId;
};
dictionary MediaTrackConstraints : MediaTrackConstraintSet {
sequence<MediaTrackConstraintSet> advanced;
dictionary MediaTrackConstraints : MediaTrackConstraintSet {
sequence<MediaTrackConstraintSet> advanced;
};
dictionary MediaTrackConstraintSet {
ConstrainLong width;
ConstrainLong height;
ConstrainDouble aspectRatio;
ConstrainDouble frameRate;
ConstrainDOMString facingMode;
ConstrainDouble volume;
ConstrainLong sampleRate;
ConstrainLong sampleSize;
ConstrainBoolean echoCancellation;
ConstrainDouble latency;
ConstrainLong channelCount;
ConstrainDOMString deviceId;
ConstrainDOMString groupId;
ConstrainULong width;
ConstrainULong height;
ConstrainDouble aspectRatio;
ConstrainDouble frameRate;
ConstrainDOMString facingMode;
ConstrainDOMString resizeMode;
ConstrainDouble volume;
ConstrainULong sampleRate;
ConstrainULong sampleSize;
ConstrainBoolean echoCancellation;
ConstrainBoolean autoGainControl;
ConstrainBoolean noiseSuppression;
ConstrainDouble latency;
ConstrainULong channelCount;
ConstrainDOMString deviceId;
ConstrainDOMString groupId;
};
dictionary MediaTrackSettings {
long width;
long height;
double aspectRatio;
double frameRate;
DOMString facingMode;
double volume;
long sampleRate;
long sampleSize;
boolean echoCancellation;
double latency;
long channelCount;
DOMString deviceId;
DOMString groupId;
long width;
long height;
double aspectRatio;
double frameRate;
DOMString facingMode;
DOMString resizeMode;
double volume;
long sampleRate;
long sampleSize;
boolean echoCancellation;
boolean autoGainControl;
boolean noiseSuppression;
double latency;
long channelCount;
DOMString deviceId;
DOMString groupId;
};
enum VideoFacingModeEnum {
@ -116,11 +132,16 @@ enum VideoFacingModeEnum {
"right"
};
enum VideoResizeModeEnum {
"none",
"crop-and-scale"
};
[Exposed=Window,
Constructor(DOMString type, MediaStreamTrackEventInit eventInitDict)]
Constructor (DOMString type, MediaStreamTrackEventInit eventInitDict)]
interface MediaStreamTrackEvent : Event {
[SameObject]
readonly attribute MediaStreamTrack track;
readonly attribute MediaStreamTrack track;
};
dictionary MediaStreamTrackEventInit : EventInit {
@ -128,36 +149,35 @@ dictionary MediaStreamTrackEventInit : EventInit {
};
[Exposed=Window,
Constructor(DOMString type, OverconstrainedErrorEventInit eventInitDict)]
Constructor (DOMString type, OverconstrainedErrorEventInit eventInitDict)]
interface OverconstrainedErrorEvent : Event {
readonly attribute OverconstrainedError? error;
readonly attribute OverconstrainedError? error;
};
dictionary OverconstrainedErrorEventInit : EventInit {
OverconstrainedError? error = null;
OverconstrainedError? error = null;
};
[Exposed=Window,
NoInterfaceObject]
[Exposed=Window, NoInterfaceObject]
interface NavigatorUserMedia {
[SameObject]
readonly attribute MediaDevices mediaDevices;
readonly attribute MediaDevices mediaDevices;
};
Navigator implements NavigatorUserMedia;
[Exposed=Window]
interface MediaDevices : EventTarget {
attribute EventHandler ondevicechange;
Promise<sequence<MediaDeviceInfo>> enumerateDevices();
attribute EventHandler ondevicechange;
Promise<sequence<MediaDeviceInfo>> enumerateDevices ();
};
[Exposed=Window]
interface MediaDeviceInfo {
readonly attribute DOMString deviceId;
readonly attribute MediaDeviceKind kind;
readonly attribute DOMString label;
readonly attribute DOMString groupId;
readonly attribute DOMString deviceId;
readonly attribute MediaDeviceKind kind;
readonly attribute DOMString label;
readonly attribute DOMString groupId;
[Default] object toJSON();
};
@ -167,25 +187,22 @@ enum MediaDeviceKind {
"videoinput"
};
[Exposed=Window]
interface InputDeviceInfo : MediaDeviceInfo {
MediaTrackCapabilities getCapabilities();
[Exposed=Window] interface InputDeviceInfo : MediaDeviceInfo {
MediaTrackCapabilities getCapabilities ();
};
partial interface NavigatorUserMedia {
void getUserMedia(MediaStreamConstraints constraints,
NavigatorUserMediaSuccessCallback successCallback,
NavigatorUserMediaErrorCallback errorCallback);
void getUserMedia (MediaStreamConstraints constraints, NavigatorUserMediaSuccessCallback successCallback, NavigatorUserMediaErrorCallback errorCallback);
};
partial interface MediaDevices {
MediaTrackSupportedConstraints getSupportedConstraints();
Promise<MediaStream> getUserMedia(optional MediaStreamConstraints constraints);
MediaTrackSupportedConstraints getSupportedConstraints ();
Promise<MediaStream> getUserMedia (optional MediaStreamConstraints constraints);
};
dictionary MediaStreamConstraints {
(boolean or MediaTrackConstraints) video = false;
(boolean or MediaTrackConstraints) audio = false;
(boolean or MediaTrackConstraints) video = false;
(boolean or MediaTrackConstraints) audio = false;
};
callback NavigatorUserMediaSuccessCallback = void (MediaStream stream);
@ -196,44 +213,44 @@ typedef object MediaStreamError;
[NoInterfaceObject]
interface ConstrainablePattern {
Capabilities getCapabilities();
Constraints getConstraints();
Settings getSettings();
Promise<void> applyConstraints(optional Constraints constraints);
attribute EventHandler onoverconstrained;
Capabilities getCapabilities ();
Constraints getConstraints ();
Settings getSettings ();
Promise<void> applyConstraints (optional Constraints constraints);
attribute EventHandler onoverconstrained;
};
dictionary DoubleRange {
double max;
double min;
double max;
double min;
};
dictionary ConstrainDoubleRange : DoubleRange {
double exact;
double ideal;
double exact;
double ideal;
};
dictionary LongRange {
long max;
long min;
dictionary ULongRange {
[Clamp] unsigned long max;
[Clamp] unsigned long min;
};
dictionary ConstrainLongRange : LongRange {
long exact;
long ideal;
dictionary ConstrainULongRange : ULongRange {
[Clamp] unsigned long exact;
[Clamp] unsigned long ideal;
};
dictionary ConstrainBooleanParameters {
boolean exact;
boolean ideal;
boolean exact;
boolean ideal;
};
dictionary ConstrainDOMStringParameters {
(DOMString or sequence<DOMString>) exact;
(DOMString or sequence<DOMString>) ideal;
(DOMString or sequence<DOMString>) exact;
(DOMString or sequence<DOMString>) ideal;
};
typedef (long or ConstrainLongRange) ConstrainLong;
typedef ([Clamp] unsigned long or ConstrainULongRange) ConstrainULong;
typedef (double or ConstrainDoubleRange) ConstrainDouble;
@ -251,5 +268,5 @@ dictionary ConstraintSet {
};
dictionary Constraints : ConstraintSet {
sequence<ConstraintSet> advanced;
sequence<ConstraintSet> advanced;
};

View file

@ -0,0 +1,60 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the MediaStream Recording spec.
// See https://w3c.github.io/mediacapture-record/
[Exposed=Window,
Constructor(MediaStream stream, optional MediaRecorderOptions options)]
interface MediaRecorder : EventTarget {
readonly attribute MediaStream stream;
readonly attribute DOMString mimeType;
readonly attribute RecordingState state;
attribute EventHandler onstart;
attribute EventHandler onstop;
attribute EventHandler ondataavailable;
attribute EventHandler onpause;
attribute EventHandler onresume;
attribute EventHandler onerror;
readonly attribute unsigned long videoBitsPerSecond;
readonly attribute unsigned long audioBitsPerSecond;
void start(optional long timeslice);
void stop();
void pause();
void resume();
void requestData();
static boolean isTypeSupported(DOMString type);
};
dictionary MediaRecorderOptions {
DOMString mimeType;
unsigned long audioBitsPerSecond;
unsigned long videoBitsPerSecond;
unsigned long bitsPerSecond;
};
enum RecordingState {
"inactive",
"recording",
"paused"
};
[Exposed=Window, Constructor(DOMString type, BlobEventInit eventInitDict)]
interface BlobEvent : Event {
[SameObject] readonly attribute Blob data;
readonly attribute DOMHighResTimeStamp timecode;
};
dictionary BlobEventInit {
required Blob data;
DOMHighResTimeStamp timecode;
};
dictionary MediaRecorderErrorEventInit : EventInit {
required DOMException error;
};
[Exposed=Window, Constructor(DOMString type, MediaRecorderErrorEventInit eventInitDict)]
interface MediaRecorderErrorEvent : Event {
[SameObject] readonly attribute DOMException error;
};

View file

@ -0,0 +1,68 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "DeviceOrientation Event Specification" spec.
// See: https://w3c.github.io/deviceorientation/spec-source-orientation.html
partial interface Window {
attribute EventHandler ondeviceorientation;
};
[Constructor(DOMString type, optional DeviceOrientationEventInit eventInitDict), Exposed=Window]
interface DeviceOrientationEvent : Event {
readonly attribute double? alpha;
readonly attribute double? beta;
readonly attribute double? gamma;
readonly attribute boolean absolute;
};
dictionary DeviceOrientationEventInit : EventInit {
double? alpha = null;
double? beta = null;
double? gamma = null;
boolean absolute = false;
};
partial interface Window {
attribute EventHandler ondevicemotion;
};
[NoInterfaceObject]
interface DeviceAcceleration {
readonly attribute double? x;
readonly attribute double? y;
readonly attribute double? z;
};
[NoInterfaceObject]
interface DeviceRotationRate {
readonly attribute double? alpha;
readonly attribute double? beta;
readonly attribute double? gamma;
};
[Constructor(DOMString type, optional DeviceMotionEventInit eventInitDict), Exposed=Window]
interface DeviceMotionEvent : Event {
readonly attribute DeviceAcceleration? acceleration;
readonly attribute DeviceAcceleration? accelerationIncludingGravity;
readonly attribute DeviceRotationRate? rotationRate;
readonly attribute double interval;
};
dictionary DeviceAccelerationInit {
double? x = null;
double? y = null;
double? z = null;
};
dictionary DeviceRotationRateInit {
double? alpha = null;
double? beta = null;
double? gamma = null;
};
dictionary DeviceMotionEventInit : EventInit {
DeviceAccelerationInit? acceleration;
DeviceAccelerationInit? accelerationIncludingGravity;
DeviceRotationRateInit? rotationRate;
double interval = 0;
};

View file

@ -0,0 +1,111 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Presentation API" spec.
// See: https://w3c.github.io/presentation-api/
partial interface Navigator {
[SecureContext,
SameObject]
readonly attribute Presentation presentation;
};
[SecureContext,
Exposed=Window]
interface Presentation {
};
partial interface Presentation {
attribute PresentationRequest? defaultRequest;
};
partial interface Presentation {
readonly attribute PresentationReceiver? receiver;
};
[Constructor(USVString url),
Constructor(sequence<USVString> urls),
SecureContext,
Exposed=Window]
interface PresentationRequest : EventTarget {
Promise<PresentationConnection> start();
Promise<PresentationConnection> reconnect(USVString presentationId);
Promise<PresentationAvailability> getAvailability();
attribute EventHandler onconnectionavailable;
};
[SecureContext,
Exposed=Window]
interface PresentationAvailability : EventTarget {
readonly attribute boolean value;
attribute EventHandler onchange;
};
[Constructor(DOMString type, PresentationConnectionAvailableEventInit eventInitDict),
SecureContext,
Exposed=Window]
interface PresentationConnectionAvailableEvent : Event {
[SameObject]
readonly attribute PresentationConnection connection;
};
dictionary PresentationConnectionAvailableEventInit : EventInit {
required PresentationConnection connection;
};
enum PresentationConnectionState {
"connecting",
"connected",
"closed",
"terminated"
};
enum BinaryType {
"blob",
"arraybuffer"
};
[SecureContext,
Exposed=Window]
interface PresentationConnection : EventTarget {
readonly attribute USVString id;
readonly attribute USVString url;
readonly attribute PresentationConnectionState state;
void close();
void terminate();
attribute EventHandler onconnect;
attribute EventHandler onclose;
attribute EventHandler onterminate;
// Communication
attribute BinaryType binaryType;
attribute EventHandler onmessage;
void send(DOMString message);
void send(Blob data);
void send(ArrayBuffer data);
void send(ArrayBufferView data);
};
enum PresentationConnectionCloseReason {
"error",
"closed",
"wentaway"
};
[Constructor(DOMString type, PresentationConnectionCloseEventInit eventInitDict),
SecureContext,
Exposed=Window]
interface PresentationConnectionCloseEvent : Event {
readonly attribute PresentationConnectionCloseReason reason;
readonly attribute DOMString message;
};
dictionary PresentationConnectionCloseEventInit : EventInit {
required PresentationConnectionCloseReason reason;
DOMString message = "";
};
[SecureContext,
Exposed=Window]
interface PresentationReceiver {
readonly attribute Promise<PresentationConnectionList> connectionList;
};
[SecureContext,
Exposed=Window]
interface PresentationConnectionList : EventTarget {
readonly attribute FrozenArray<PresentationConnection> connections;
attribute EventHandler onconnectionavailable;
};

View file

@ -0,0 +1,96 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Push API" spec.
// See: https://w3c.github.io/push-api/
[SecureContext]
partial interface ServiceWorkerRegistration {
readonly attribute PushManager pushManager;
};
[Exposed=(Window,Worker),
SecureContext]
interface PushManager {
[SameObject]
static readonly attribute FrozenArray<DOMString> supportedContentEncodings;
Promise<PushSubscription> subscribe(optional PushSubscriptionOptionsInit options);
Promise<PushSubscription?> getSubscription();
Promise<PushPermissionState> permissionState(optional PushSubscriptionOptionsInit options);
};
dictionary PushSubscriptionOptionsInit {
boolean userVisibleOnly = false;
(BufferSource or DOMString)? applicationServerKey = null;
};
[Exposed=(Window,Worker),
SecureContext]
interface PushSubscriptionOptions {
readonly attribute boolean userVisibleOnly;
[SameObject]
readonly attribute ArrayBuffer? applicationServerKey;
};
[Exposed=(Window,Worker),
SecureContext]
interface PushSubscription {
readonly attribute USVString endpoint;
readonly attribute DOMTimeStamp? expirationTime;
[SameObject]
readonly attribute PushSubscriptionOptions options;
ArrayBuffer? getKey(PushEncryptionKeyName name);
Promise<boolean> unsubscribe();
PushSubscriptionJSON toJSON();
};
dictionary PushSubscriptionJSON {
USVString endpoint;
DOMTimeStamp? expirationTime;
record<DOMString, USVString> keys;
};
enum PushEncryptionKeyName {
"p256dh",
"auth"
};
[Exposed=ServiceWorker,
SecureContext]
interface PushMessageData {
ArrayBuffer arrayBuffer();
Blob blob();
any json();
USVString text();
};
[Exposed=ServiceWorker,
SecureContext]
partial interface ServiceWorkerGlobalScope {
attribute EventHandler onpush;
attribute EventHandler onpushsubscriptionchange;
};
typedef (BufferSource or USVString) PushMessageDataInit;
dictionary PushEventInit : ExtendableEventInit {
PushMessageDataInit data;
};
[Constructor(DOMString type, optional PushEventInit eventInitDict),
Exposed=ServiceWorker,
SecureContext]
interface PushEvent : ExtendableEvent {
readonly attribute PushMessageData? data;
};
dictionary PushSubscriptionChangeInit : ExtendableEventInit {
PushSubscription newSubscription = null;
PushSubscription oldSubscription = null;
};
[Constructor(DOMString type, optional PushSubscriptionChangeInit eventInitDict),
Exposed=ServiceWorker,
SecureContext]
interface PushSubscriptionChangeEvent : ExtendableEvent {
readonly attribute PushSubscription? newSubscription;
readonly attribute PushSubscription? oldSubscription;
};
enum PushPermissionState {
"denied",
"granted",
"prompt",
};

View file

@ -1,6 +1,7 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the Referrer Policy spec.
// See https://w3c.github.io/webappsec-referrer-policy/
// Content of this file was automatically extracted from the
// "Referrer Policy" spec.
// See: https://w3c.github.io/webappsec-referrer-policy/
enum ReferrerPolicy {
"",

View file

@ -0,0 +1,33 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Scroll-linked Animations" spec.
// See: https://wicg.github.io/scroll-animations/
enum ScrollDirection {
"auto",
"block",
"inline",
"horizontal",
"vertical"
};
enum ScrollTimelineAutoKeyword { "auto" };
dictionary ScrollTimelineOptions {
Element scrollSource;
ScrollDirection orientation = "auto";
DOMString startScrollOffset = "auto";
DOMString endScrollOffset = "auto";
(double or ScrollTimelineAutoKeyword) timeRange = "auto";
FillMode fill = "none";
};
[Constructor(optional ScrollTimelineOptions options)]
interface ScrollTimeline : AnimationTimeline {
readonly attribute Element scrollSource;
readonly attribute ScrollDirection orientation;
readonly attribute DOMString startScrollOffset;
readonly attribute DOMString endScrollOffset;
readonly attribute (double or ScrollTimelineAutoKeyword) timeRange;
readonly attribute FillMode fill;
};

View file

@ -0,0 +1,8 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Secure Contexts" spec.
// See: https://w3c.github.io/webappsec-secure-contexts/
partial interface WindowOrWorkerGlobalScope {
readonly attribute boolean isSecureContext;
};

View file

@ -0,0 +1,67 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Accelerated Shape Detection in Images" spec.
// See: https://wicg.github.io/shape-detection-api/
[Exposed=(Window,Worker),
Constructor(optional FaceDetectorOptions faceDetectorOptions)]
interface FaceDetector {
Promise<sequence<DetectedFace>> detect(ImageBitmapSource image);
};
dictionary FaceDetectorOptions {
unsigned short maxDetectedFaces;
boolean fastMode;
};
interface DetectedFace {
[SameObject] readonly attribute DOMRectReadOnly boundingBox;
[SameObject] readonly attribute FrozenArray<Landmark>? landmarks;
};
dictionary Landmark {
required FrozenArray<Point2D> locations;
LandmarkType type;
};
enum LandmarkType {
"mouth",
"eye",
"nose"
};
[Exposed=(Window,Worker),
Constructor(optional BarcodeDetectorOptions barcodeDetectorOptions)]
interface BarcodeDetector {
readonly attribute FrozenArray<BarcodeFormat> supportedFormats;
Promise<sequence<DetectedBarcode>> detect(ImageBitmapSource image);
};
dictionary BarcodeDetectorOptions {
sequence<BarcodeFormat> formats;
};
interface DetectedBarcode {
[SameObject] readonly attribute DOMRectReadOnly boundingBox;
[SameObject] readonly attribute DOMString rawValue;
[SameObject] readonly attribute BarcodeFormat format;
[SameObject] readonly attribute FrozenArray<Point2D> cornerPoints;
};
enum BarcodeFormat {
"aztec",
"code_128",
"code_39",
"code_93",
"codabar",
"data_matrix",
"ean_13",
"ean_8",
"itf",
"pdf417",
"qr_code",
"unknown",
"upc_a",
"upc_e"
};

View file

@ -0,0 +1,86 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Touch Events - Level 2" spec.
// See: https://w3c.github.io/touch-events/
enum TouchType {
"direct",
"stylus"
};
dictionary TouchInit {
required long identifier;
required EventTarget target;
double clientX = 0;
double clientY = 0;
double screenX = 0;
double screenY = 0;
double pageX = 0;
double pageY = 0;
float radiusX = 0;
float radiusY = 0;
float rotationAngle = 0;
float force = 0;
double altitudeAngle = 0;
double azimuthAngle = 0;
TouchType touchType = "direct";
};
[Constructor(TouchInit touchInitDict),
Exposed=Window]
interface Touch {
readonly attribute long identifier;
readonly attribute EventTarget target;
readonly attribute double screenX;
readonly attribute double screenY;
readonly attribute double clientX;
readonly attribute double clientY;
readonly attribute double pageX;
readonly attribute double pageY;
readonly attribute float radiusX;
readonly attribute float radiusY;
readonly attribute float rotationAngle;
readonly attribute float force;
readonly attribute float altitudeAngle;
readonly attribute float azimuthAngle;
readonly attribute TouchType touchType;
};
interface TouchList {
readonly attribute unsigned long length;
getter Touch? item(unsigned long index);
};
dictionary TouchEventInit : EventModifierInit {
sequence<Touch> touches = [];
sequence<Touch> targetTouches = [];
sequence<Touch> changedTouches = [];
};
[Constructor(DOMString type, optional TouchEventInit eventInitDict),
Exposed=Window]
interface TouchEvent : UIEvent {
readonly attribute TouchList touches;
readonly attribute TouchList targetTouches;
readonly attribute TouchList changedTouches;
readonly attribute boolean altKey;
readonly attribute boolean metaKey;
readonly attribute boolean ctrlKey;
readonly attribute boolean shiftKey;
};
partial interface GlobalEventHandlers {
attribute EventHandler ontouchstart;
attribute EventHandler ontouchend;
attribute EventHandler ontouchmove;
attribute EventHandler ontouchcancel;
};
partial interface Document {
// Deprecated in this specification
Touch createTouch(WindowProxy view,
EventTarget target,
long identifier,
double pageX,
double pageY,
double screenX,
double screenY);
// Deprecated in this specification
TouchList createTouchList(Touch... touches);
};

View file

@ -0,0 +1,216 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the
// "Web Bluetooth" spec.
// See: https://webbluetoothcg.github.io/web-bluetooth/
dictionary BluetoothDataFilterInit {
BufferSource dataPrefix;
BufferSource mask;
};
dictionary BluetoothLEScanFilterInit {
sequence<BluetoothServiceUUID> services;
DOMString name;
DOMString namePrefix;
// Maps unsigned shorts to BluetoothDataFilters.
object manufacturerData;
// Maps BluetoothServiceUUIDs to BluetoothDataFilters.
object serviceData;
};
dictionary RequestDeviceOptions {
sequence<BluetoothLEScanFilterInit> filters;
sequence<BluetoothServiceUUID> optionalServices = [];
boolean acceptAllDevices = false;
};
interface Bluetooth : EventTarget {
[SecureContext]
Promise<boolean> getAvailability();
[SecureContext]
attribute EventHandler onavailabilitychanged;
[SecureContext, SameObject]
readonly attribute BluetoothDevice? referringDevice;
[SecureContext]
Promise<BluetoothDevice> requestDevice(optional RequestDeviceOptions options);
};
Bluetooth implements BluetoothDeviceEventHandlers;
Bluetooth implements CharacteristicEventHandlers;
Bluetooth implements ServiceEventHandlers;
dictionary BluetoothPermissionDescriptor : PermissionDescriptor {
DOMString deviceId;
// These match RequestDeviceOptions.
sequence<BluetoothLEScanFilterInit> filters;
sequence<BluetoothServiceUUID> optionalServices = [];
boolean acceptAllDevices = false;
};
dictionary AllowedBluetoothDevice {
required DOMString deviceId;
required boolean mayUseGATT;
// An allowedServices of "all" means all services are allowed.
required (DOMString or sequence<UUID>) allowedServices;
};
dictionary BluetoothPermissionData {
required sequence<AllowedBluetoothDevice> allowedDevices;
};
interface BluetoothPermissionResult : PermissionStatus {
attribute FrozenArray<BluetoothDevice> devices;
};
[Constructor(DOMString type, optional ValueEventInit initDict)]
interface ValueEvent : Event {
readonly attribute any value;
};
dictionary ValueEventInit : EventInit {
any value = null;
};
interface BluetoothDevice {
readonly attribute DOMString id;
readonly attribute DOMString? name;
readonly attribute BluetoothRemoteGATTServer? gatt;
Promise<void> watchAdvertisements();
void unwatchAdvertisements();
readonly attribute boolean watchingAdvertisements;
};
BluetoothDevice implements EventTarget;
BluetoothDevice implements BluetoothDeviceEventHandlers;
BluetoothDevice implements CharacteristicEventHandlers;
BluetoothDevice implements ServiceEventHandlers;
interface BluetoothManufacturerDataMap {
readonly maplike<unsigned short, DataView>;
};
interface BluetoothServiceDataMap {
readonly maplike<UUID, DataView>;
};
[Constructor(DOMString type, BluetoothAdvertisingEventInit init)]
interface BluetoothAdvertisingEvent : Event {
[SameObject]
readonly attribute BluetoothDevice device;
readonly attribute FrozenArray<UUID> uuids;
readonly attribute DOMString? name;
readonly attribute unsigned short? appearance;
readonly attribute byte? txPower;
readonly attribute byte? rssi;
[SameObject]
readonly attribute BluetoothManufacturerDataMap manufacturerData;
[SameObject]
readonly attribute BluetoothServiceDataMap serviceData;
};
dictionary BluetoothAdvertisingEventInit : EventInit {
required BluetoothDevice device;
sequence<(DOMString or unsigned long)> uuids;
DOMString name;
unsigned short appearance;
byte txPower;
byte rssi;
Map manufacturerData;
Map serviceData;
};
interface BluetoothRemoteGATTServer {
[SameObject]
readonly attribute BluetoothDevice device;
readonly attribute boolean connected;
Promise<BluetoothRemoteGATTServer> connect();
void disconnect();
Promise<BluetoothRemoteGATTService> getPrimaryService(BluetoothServiceUUID service);
Promise<sequence<BluetoothRemoteGATTService>>
getPrimaryServices(optional BluetoothServiceUUID service);
};
interface BluetoothRemoteGATTService {
[SameObject]
readonly attribute BluetoothDevice device;
readonly attribute UUID uuid;
readonly attribute boolean isPrimary;
Promise<BluetoothRemoteGATTCharacteristic>
getCharacteristic(BluetoothCharacteristicUUID characteristic);
Promise<sequence<BluetoothRemoteGATTCharacteristic>>
getCharacteristics(optional BluetoothCharacteristicUUID characteristic);
Promise<BluetoothRemoteGATTService>
getIncludedService(BluetoothServiceUUID service);
Promise<sequence<BluetoothRemoteGATTService>>
getIncludedServices(optional BluetoothServiceUUID service);
};
BluetoothRemoteGATTService implements EventTarget;
BluetoothRemoteGATTService implements CharacteristicEventHandlers;
BluetoothRemoteGATTService implements ServiceEventHandlers;
interface BluetoothRemoteGATTCharacteristic {
[SameObject]
readonly attribute BluetoothRemoteGATTService service;
readonly attribute UUID uuid;
readonly attribute BluetoothCharacteristicProperties properties;
readonly attribute DataView? value;
Promise<BluetoothRemoteGATTDescriptor> getDescriptor(BluetoothDescriptorUUID descriptor);
Promise<sequence<BluetoothRemoteGATTDescriptor>>
getDescriptors(optional BluetoothDescriptorUUID descriptor);
Promise<DataView> readValue();
Promise<void> writeValue(BufferSource value);
Promise<BluetoothRemoteGATTCharacteristic> startNotifications();
Promise<BluetoothRemoteGATTCharacteristic> stopNotifications();
};
BluetoothRemoteGATTCharacteristic implements EventTarget;
BluetoothRemoteGATTCharacteristic implements CharacteristicEventHandlers;
interface BluetoothCharacteristicProperties {
readonly attribute boolean broadcast;
readonly attribute boolean read;
readonly attribute boolean writeWithoutResponse;
readonly attribute boolean write;
readonly attribute boolean notify;
readonly attribute boolean indicate;
readonly attribute boolean authenticatedSignedWrites;
readonly attribute boolean reliableWrite;
readonly attribute boolean writableAuxiliaries;
};
interface BluetoothRemoteGATTDescriptor {
[SameObject]
readonly attribute BluetoothRemoteGATTCharacteristic characteristic;
readonly attribute UUID uuid;
readonly attribute DataView? value;
Promise<DataView> readValue();
Promise<void> writeValue(BufferSource value);
};
[NoInterfaceObject]
interface CharacteristicEventHandlers {
attribute EventHandler oncharacteristicvaluechanged;
};
[NoInterfaceObject]
interface BluetoothDeviceEventHandlers {
attribute EventHandler ongattserverdisconnected;
};
[NoInterfaceObject]
interface ServiceEventHandlers {
attribute EventHandler onserviceadded;
attribute EventHandler onservicechanged;
attribute EventHandler onserviceremoved;
};
typedef DOMString UUID;
interface BluetoothUUID {
static UUID getService((DOMString or unsigned long) name);
static UUID getCharacteristic((DOMString or unsigned long) name);
static UUID getDescriptor((DOMString or unsigned long) name);
static UUID canonicalUUID([EnforceRange] unsigned long alias);
};
typedef (DOMString or unsigned long) BluetoothServiceUUID;
typedef (DOMString or unsigned long) BluetoothCharacteristicUUID;
typedef (DOMString or unsigned long) BluetoothDescriptorUUID;
partial interface Navigator {
[SameObject]
readonly attribute Bluetooth bluetooth;
};

View file

@ -1,6 +1,7 @@
// GENERATED CONTENT - DO NOT EDIT
// Content of this file was automatically extracted from the Web Audio API spec.
// See https://webaudio.github.io/web-audio-api/
// Content of this file was automatically extracted from the
// "Web Audio API" spec.
// See: https://webaudio.github.io/web-audio-api/
enum AudioContextState {
"suspended",
@ -21,34 +22,35 @@ interface BaseAudioContext : EventTarget {
readonly attribute AudioContextState state;
[SameObject, SecureContext]
readonly attribute AudioWorklet audioWorklet;
Promise<void> resume ();
attribute EventHandler onstatechange;
AnalyserNode createAnalyser ();
BiquadFilterNode createBiquadFilter ();
AudioBuffer createBuffer (unsigned long numberOfChannels, unsigned long length, float sampleRate);
Promise<AudioBuffer> decodeAudioData (ArrayBuffer audioData,
optional DecodeSuccessCallback successCallback,
optional DecodeErrorCallback errorCallback);
AudioBufferSourceNode createBufferSource ();
ChannelMergerNode createChannelMerger (optional unsigned long numberOfInputs = 6);
ChannelSplitterNode createChannelSplitter (optional unsigned long numberOfOutputs = 6);
ConstantSourceNode createConstantSource ();
ConvolverNode createConvolver ();
DelayNode createDelay (optional double maxDelayTime = 1.0);
DynamicsCompressorNode createDynamicsCompressor ();
GainNode createGain ();
IIRFilterNode createIIRFilter (sequence<double> feedforward, sequence<double> feedback);
OscillatorNode createOscillator ();
PannerNode createPanner ();
PeriodicWave createPeriodicWave (sequence<float> real, sequence<float> imag, optional PeriodicWaveConstraints constraints);
ScriptProcessorNode createScriptProcessor(optional unsigned long bufferSize = 0,
optional unsigned long numberOfInputChannels = 2,
optional unsigned long numberOfOutputChannels = 2);
AnalyserNode createAnalyser ();
GainNode createGain ();
DelayNode createDelay (optional double maxDelayTime = 1.0);
BiquadFilterNode createBiquadFilter ();
IIRFilterNode createIIRFilter (sequence<double> feedforward, sequence<double> feedback);
WaveShaperNode createWaveShaper ();
PannerNode createPanner ();
StereoPannerNode createStereoPanner ();
ConvolverNode createConvolver ();
ChannelSplitterNode createChannelSplitter (optional unsigned long numberOfOutputs = 6);
ChannelMergerNode createChannelMerger (optional unsigned long numberOfInputs = 6);
DynamicsCompressorNode createDynamicsCompressor ();
OscillatorNode createOscillator ();
PeriodicWave createPeriodicWave (sequence<float> real, sequence<float> imag, optional PeriodicWaveConstraints constraints);
WaveShaperNode createWaveShaper ();
Promise<AudioBuffer> decodeAudioData (ArrayBuffer audioData,
optional DecodeSuccessCallback successCallback,
optional DecodeErrorCallback errorCallback);
Promise<void> resume ();
};
[Exposed=Window]
enum AudioContextLatencyCategory {
"balanced",
"interactive",
@ -69,13 +71,11 @@ interface AudioContext : BaseAudioContext {
MediaStreamAudioDestinationNode createMediaStreamDestination ();
};
[Exposed=Window]
dictionary AudioContextOptions {
(AudioContextLatencyCategory or double) latencyHint = "interactive";
float sampleRate;
};
[Exposed=Window]
dictionary AudioTimestamp {
double contextTime;
DOMHighResTimeStamp performanceTime;
@ -91,7 +91,6 @@ interface OfflineAudioContext : BaseAudioContext {
attribute EventHandler oncomplete;
};
[Exposed=Window]
dictionary OfflineAudioContextOptions {
unsigned long numberOfChannels = 1;
required unsigned long length;
@ -104,7 +103,6 @@ interface OfflineAudioCompletionEvent : Event {
readonly attribute AudioBuffer renderedBuffer;
};
[Exposed=Window]
dictionary OfflineAudioCompletionEventInit : EventInit {
required AudioBuffer renderedBuffer;
};
@ -148,14 +146,12 @@ interface AudioNode : EventTarget {
attribute ChannelInterpretation channelInterpretation;
};
[Exposed=Window]
enum ChannelCountMode {
"max",
"clamped-max",
"explicit"
};
[Exposed=Window]
enum ChannelInterpretation {
"speakers",
"discrete"
@ -228,7 +224,6 @@ interface AudioBufferSourceNode : AudioScheduledSourceNode {
void start (optional double when = 0,
optional double offset,
optional double duration);
void stop (optional double when = 0);
};
dictionary AudioBufferSourceOptions {
@ -314,7 +309,7 @@ dictionary ChannelMergerOptions : AudioNodeOptions {
};
[Exposed=Window,
Constructor (BaseAudioContext context, optional ChannelSplitterNode options)]
Constructor (BaseAudioContext context, optional ChannelSplitterOptions options)]
interface ChannelSplitterNode : AudioNode {
};
@ -396,7 +391,7 @@ dictionary IIRFilterOptions : AudioNodeOptions {
};
[Exposed=Window,
Constructor (BaseAudioContext context, MediaElementAudioSourceOptions options)]
Constructor (AudioContext context, MediaElementAudioSourceOptions options)]
interface MediaElementAudioSourceNode : AudioNode {
[SameObject] readonly attribute HTMLMediaElement mediaElement;
};
@ -406,13 +401,13 @@ dictionary MediaElementAudioSourceOptions {
};
[Exposed=Window,
Constructor (BaseAudioContext context, optional AudioNodeOptions options)]
Constructor (AudioContext context, optional AudioNodeOptions options)]
interface MediaStreamAudioDestinationNode : AudioNode {
readonly attribute MediaStream stream;
};
[Exposed=Window,
Constructor (BaseAudioContext context, MediaStreamAudioSourceOptions options)]
Constructor (AudioContext context, MediaStreamAudioSourceOptions options)]
interface MediaStreamAudioSourceNode : AudioNode {
[SameObject] readonly attribute MediaStream mediaStream;
};
@ -558,6 +553,7 @@ interface AudioWorklet : Worklet {
[Global=(Worklet, AudioWorklet), Exposed=AudioWorklet]
interface AudioWorkletGlobalScope : WorkletGlobalScope {
void registerProcessor (DOMString name, VoidFunction processorCtor);
readonly attribute unsigned long long currentFrame;
readonly attribute double currentTime;
readonly attribute float sampleRate;
};
@ -567,21 +563,13 @@ interface AudioParamMap {
readonly maplike<DOMString, AudioParam>;
};
enum AudioWorkletProcessorState {
"pending",
"running",
"stopped",
"error"
};
[Exposed=Window,
SecureContext,
Constructor (BaseAudioContext context, DOMString name, optional AudioWorkletNodeOptions options)]
interface AudioWorkletNode : AudioNode {
readonly attribute AudioParamMap parameters;
readonly attribute MessagePort port;
readonly attribute AudioWorkletProcessorState processorState;
attribute EventHandler onprocessorstatechange;
attribute EventHandler onprocessorerror;
};
dictionary AudioWorkletNodeOptions : AudioNodeOptions {
@ -589,7 +577,7 @@ dictionary AudioWorkletNodeOptions : AudioNodeOptions {
unsigned long numberOfOutputs = 1;
sequence<unsigned long> outputChannelCount;
record<DOMString, double> parameterData;
object processorOptions = null;
object? processorOptions = null;
};
[Exposed=AudioWorklet,
@ -603,4 +591,5 @@ dictionary AudioParamDescriptor {
float defaultValue = 0;
float minValue = -3.4028235e38;
float maxValue = 3.4028235e38;
AutomationRate automationRate = "a-rate";
};

View file

@ -47,9 +47,9 @@ dictionary XRSessionCreationOptions {
attribute EventHandler onend;
};
callback XRFrameRequestCallback = void (DOMHighResTimeStamp time, XRPresentationFrame frame);
callback XRFrameRequestCallback = void (DOMHighResTimeStamp time, XRFrame frame);
[SecureContext, Exposed=Window] interface XRPresentationFrame {
[SecureContext, Exposed=Window] interface XRFrame {
readonly attribute FrozenArray<XRView> views;
XRDevicePose? getDevicePose(XRCoordinateSystem coordinateSystem);