@rescript/webapi 0.1.0-alpha-b1d58f9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +35 -0
- package/package.json +61 -0
- package/rescript.json +557 -0
- package/src/animation/Animation.res +149 -0
- package/src/animation/AnimationEffect.res +71 -0
- package/src/animation/DocumentTimeline.res +8 -0
- package/src/canvas/Canvas.res +179 -0
- package/src/canvas/CanvasGradient.res +11 -0
- package/src/canvas/CanvasPattern.res +11 -0
- package/src/canvas/CanvasRenderingContext2D.res +868 -0
- package/src/canvas/CanvasTypes.res +452 -0
- package/src/canvas/FillStyle.res +25 -0
- package/src/canvas/HTMLCanvasElement.res +101 -0
- package/src/canvas/ImageBitmap.res +6 -0
- package/src/canvas/ImageBitmapRenderingContext.res +9 -0
- package/src/canvas/ImageData.res +17 -0
- package/src/canvas/OffscreenCanvas.res +87 -0
- package/src/canvas/Path2D.res +186 -0
- package/src/canvas/VideoColorSpace.res +11 -0
- package/src/canvas/VideoFrame.res +217 -0
- package/src/core/ArrayBufferTypedArrayOrDataView.res +4 -0
- package/src/core/DOM.res +1026 -0
- package/src/core/EventType.res +108 -0
- package/src/crypto/Crypto.res +11 -0
- package/src/crypto/SubtleCrypto.res +173 -0
- package/src/crypto/WebCryptoTypes.res +71 -0
- package/src/css-font-loading/BaseCSSFontLoading.res +24 -0
- package/src/css-font-loading/CssFontLoadingTypes.res +92 -0
- package/src/css-font-loading/FontFace.res +62 -0
- package/src/css-font-loading/FontFaceSet.res +38 -0
- package/src/cssom/CSSRuleList.res +5 -0
- package/src/cssom/CSSStyleDeclaration.res +1734 -0
- package/src/cssom/CSSStyleValue.res +17 -0
- package/src/cssom/MediaList.res +29 -0
- package/src/cssom/MediaQueryList.res +18 -0
- package/src/cssom/StylePropertyMap.res +56 -0
- package/src/cssom/StylePropertyMapReadOnly.res +22 -0
- package/src/cssom/StyleSheet.res +152 -0
- package/src/cssom/StyleSheetList.res +17 -0
- package/src/device/GamepadHapticActuator.res +16 -0
- package/src/device/GamepadTypes.res +86 -0
- package/src/device/Geolocation.res +31 -0
- package/src/device/GeolocationCoordinates.res +5 -0
- package/src/device/GeolocationPosition.res +5 -0
- package/src/device/GeolocationTypes.res +81 -0
- package/src/device/LockManager.res +26 -0
- package/src/device/ScreenOrientation.res +7 -0
- package/src/device/ScreenWakeLockTypes.res +26 -0
- package/src/device/WakeLock.res +8 -0
- package/src/device/WakeLockSentinel.res +7 -0
- package/src/device/WebLocksTypes.res +45 -0
- package/src/device/WebMIDI.res +7 -0
- package/src/device/WebMidiTypes.res +36 -0
- package/src/dom-nodes/AbstractRange.res +30 -0
- package/src/dom-nodes/Attr.res +101 -0
- package/src/dom-nodes/CDATASection.res +7 -0
- package/src/dom-nodes/CaretPosition.res +2 -0
- package/src/dom-nodes/CharacterData.res +199 -0
- package/src/dom-nodes/Comment.res +15 -0
- package/src/dom-nodes/DOMImplementation.res +131 -0
- package/src/dom-nodes/DOMTree.res +1653 -0
- package/src/dom-nodes/DocumentFragment.res +96 -0
- package/src/dom-nodes/Element.res +509 -0
- package/src/dom-nodes/ElementInternals.res +39 -0
- package/src/dom-nodes/HTML.res +11 -0
- package/src/dom-nodes/HTMLCollection.res +25 -0
- package/src/dom-nodes/NamedNodeMap.res +46 -0
- package/src/dom-nodes/Node.res +114 -0
- package/src/dom-nodes/NodeFilter.res +4 -0
- package/src/dom-nodes/NodeIterator.res +38 -0
- package/src/dom-nodes/NodeList.res +6 -0
- package/src/dom-nodes/ProcessingInstruction.res +15 -0
- package/src/dom-nodes/Range.res +156 -0
- package/src/dom-nodes/Selection.res +137 -0
- package/src/dom-nodes/ShadowRoot.res +23 -0
- package/src/dom-nodes/StaticRange.res +6 -0
- package/src/dom-nodes/Text.res +31 -0
- package/src/dom-nodes/TreeWalker.res +65 -0
- package/src/dom-platform/DOMException.res +7 -0
- package/src/dom-platform/DOMStringList.res +15 -0
- package/src/dom-platform/DOMStringMap.res +5 -0
- package/src/dom-platform/DOMTokenList.res +70 -0
- package/src/event/AbortController.res +9 -0
- package/src/event/AbortSignal.res +25 -0
- package/src/event/Event.res +76 -0
- package/src/event/EventTarget.res +91 -0
- package/src/event/ExtendableEvent.res +14 -0
- package/src/fetch/BodyInit.res +46 -0
- package/src/fetch/Fetch.res +12 -0
- package/src/fetch/FetchTypes.res +282 -0
- package/src/fetch/FormData.res +71 -0
- package/src/fetch/FormDataEntryValue.res +2 -0
- package/src/fetch/Headers.res +59 -0
- package/src/fetch/HeadersInit.res +16 -0
- package/src/fetch/Request.res +61 -0
- package/src/fetch/Response.res +127 -0
- package/src/file/BaseFileAndDirectoryEntries.res +72 -0
- package/src/file/Blob.res +48 -0
- package/src/file/File.res +15 -0
- package/src/file/FileAndDirectoryEntriesTypes.res +35 -0
- package/src/file/FileList.res +16 -0
- package/src/file/FileSystemDirectoryEntry.res +42 -0
- package/src/file/FileSystemDirectoryHandle.res +49 -0
- package/src/file/FileSystemDirectoryReader.res +9 -0
- package/src/file/FileSystemEntry.res +9 -0
- package/src/file/FileSystemFileHandle.res +25 -0
- package/src/file/FileSystemHandle.res +6 -0
- package/src/file/FileSystemWritableFileStream.res +65 -0
- package/src/file/FileTypes.res +225 -0
- package/src/file/ReadableStream.res +79 -0
- package/src/file/WritableStream.res +27 -0
- package/src/file/WritableStreamDefaultController.res +5 -0
- package/src/geometry/DOMMatrix.res +206 -0
- package/src/geometry/DOMMatrixReadOnly.res +140 -0
- package/src/geometry/DOMPoint.res +28 -0
- package/src/geometry/DOMPointReadOnly.res +22 -0
- package/src/geometry/DOMRect.res +22 -0
- package/src/geometry/DOMRectList.res +2 -0
- package/src/geometry/DOMRectReadOnly.res +19 -0
- package/src/html/HTMLAnchorElement.res +373 -0
- package/src/html/HTMLAreaElement.res +353 -0
- package/src/html/HTMLBRElement.res +9 -0
- package/src/html/HTMLBaseElement.res +20 -0
- package/src/html/HTMLBodyElement.res +9 -0
- package/src/html/HTMLButtonElement.res +98 -0
- package/src/html/HTMLDListElement.res +9 -0
- package/src/html/HTMLDataElement.res +14 -0
- package/src/html/HTMLDataListElement.res +14 -0
- package/src/html/HTMLDialogElement.res +40 -0
- package/src/html/HTMLDivElement.res +9 -0
- package/src/html/HTMLElement.res +108 -0
- package/src/html/HTMLEmbedElement.res +275 -0
- package/src/html/HTMLFieldSetElement.res +70 -0
- package/src/html/HTMLFormControlsCollection.res +21 -0
- package/src/html/HTMLFormElement.res +39 -0
- package/src/html/HTMLFrameSetElement.res +9 -0
- package/src/html/HTMLHRElement.res +9 -0
- package/src/html/HTMLHeadElement.res +256 -0
- package/src/html/HTMLHeadingElement.res +9 -0
- package/src/html/HTMLHtmlElement.res +9 -0
- package/src/html/HTMLIFrameElement.res +69 -0
- package/src/html/HTMLImageElement.res +349 -0
- package/src/html/HTMLInputElement.res +310 -0
- package/src/html/HTMLLIElement.res +9 -0
- package/src/html/HTMLLabelElement.res +25 -0
- package/src/html/HTMLLegendElement.res +14 -0
- package/src/html/HTMLLinkElement.res +69 -0
- package/src/html/HTMLMapElement.res +20 -0
- package/src/html/HTMLMenuElement.res +8 -0
- package/src/html/HTMLMetaElement.res +29 -0
- package/src/html/HTMLMeterElement.res +38 -0
- package/src/html/HTMLModElement.res +9 -0
- package/src/html/HTMLOListElement.res +24 -0
- package/src/html/HTMLObjectElement.res +89 -0
- package/src/html/HTMLOptGroupElement.res +19 -0
- package/src/html/HTMLOptionElement.res +49 -0
- package/src/html/HTMLOptionsCollection.res +35 -0
- package/src/html/HTMLOutputElement.res +73 -0
- package/src/html/HTMLParagraphElement.res +9 -0
- package/src/html/HTMLPictureElement.res +9 -0
- package/src/html/HTMLPreElement.res +9 -0
- package/src/html/HTMLProgressElement.res +29 -0
- package/src/html/HTMLQuoteElement.res +9 -0
- package/src/html/HTMLScriptElement.res +310 -0
- package/src/html/HTMLSelectElement.res +157 -0
- package/src/html/HTMLSlotElement.res +34 -0
- package/src/html/HTMLSourceElement.res +18 -0
- package/src/html/HTMLSpanElement.res +9 -0
- package/src/html/HTMLStyleElement.res +24 -0
- package/src/html/HTMLTableCaptionElement.res +9 -0
- package/src/html/HTMLTableCellElement.res +40 -0
- package/src/html/HTMLTableElement.res +100 -0
- package/src/html/HTMLTableRowElement.res +40 -0
- package/src/html/HTMLTableSectionElement.res +30 -0
- package/src/html/HTMLTemplateElement.res +31 -0
- package/src/html/HTMLTextAreaElement.res +177 -0
- package/src/html/HTMLTimeElement.res +14 -0
- package/src/html/HTMLTitleElement.res +15 -0
- package/src/html/HTMLUListElement.res +9 -0
- package/src/html/HTMLUnknownElement.res +9 -0
- package/src/media/BaseEncryptedMediaExtensions.res +97 -0
- package/src/media/DomHTMLMediaElement.res +206 -0
- package/src/media/EncryptedMediaExtensionsHTMLMediaElement.res +15 -0
- package/src/media/EncryptedMediaExtensionsTypes.res +43 -0
- package/src/media/HTMLAudioElement.res +9 -0
- package/src/media/HTMLTrackElement.res +14 -0
- package/src/media/HTMLVideoElement.res +78 -0
- package/src/media/MediaCapabilities.res +19 -0
- package/src/media/MediaCapabilitiesTypes.res +83 -0
- package/src/media/MediaCaptureAndStreamsTypes.res +197 -0
- package/src/media/MediaDeviceInfo.res +9 -0
- package/src/media/MediaDevices.res +40 -0
- package/src/media/MediaError.res +14 -0
- package/src/media/MediaKeySession.res +53 -0
- package/src/media/MediaKeyStatusMap.res +11 -0
- package/src/media/MediaKeySystemAccess.res +14 -0
- package/src/media/MediaKeys.res +35 -0
- package/src/media/MediaMetadata.res +10 -0
- package/src/media/MediaSession.res +25 -0
- package/src/media/MediaSessionTypes.res +85 -0
- package/src/media/MediaStream.res +89 -0
- package/src/media/MediaStreamTrack.res +51 -0
- package/src/media/PictureInPicture.res +7 -0
- package/src/media/PictureInPictureTypes.res +17 -0
- package/src/media/RemotePlayback.res +25 -0
- package/src/media/RemotePlaybackTypes.res +20 -0
- package/src/media/SpeechSynthesis.res +33 -0
- package/src/media/SpeechSynthesisUtterance.res +8 -0
- package/src/media/TextTrack.res +15 -0
- package/src/media/TextTrackCueList.res +9 -0
- package/src/media/TextTrackList.res +17 -0
- package/src/media/TimeRanges.res +29 -0
- package/src/media/VideoPlaybackQuality.res +18 -0
- package/src/media/WebSpeechTypes.res +83 -0
- package/src/media/WebVttTypes.res +123 -0
- package/src/messaging/ApplicationServerKey.res +2 -0
- package/src/messaging/ChannelMessagingTypes.res +12 -0
- package/src/messaging/CloseEvent.res +10 -0
- package/src/messaging/MessageEvent.res +43 -0
- package/src/messaging/MessagePort.res +38 -0
- package/src/messaging/Notification.res +46 -0
- package/src/messaging/NotificationTypes.res +107 -0
- package/src/messaging/PushEvent.res +3 -0
- package/src/messaging/PushManager.res +24 -0
- package/src/messaging/PushMessageData.res +15 -0
- package/src/messaging/PushSubscription.res +20 -0
- package/src/messaging/PushTypes.res +88 -0
- package/src/messaging/WebSocket.res +74 -0
- package/src/messaging/WebSocketsTypes.res +124 -0
- package/src/navigator/Clipboard.res +29 -0
- package/src/navigator/ClipboardItem.res +20 -0
- package/src/navigator/ClipboardTypes.res +31 -0
- package/src/navigator/CredentialManagementTypes.res +138 -0
- package/src/navigator/CredentialsContainer.res +33 -0
- package/src/navigator/Navigator.res +166 -0
- package/src/navigator/Permissions.res +10 -0
- package/src/navigator/PermissionsTypes.res +38 -0
- package/src/observers/IntersectionObserver.res +36 -0
- package/src/observers/IntersectionObserverRoot.res +23 -0
- package/src/observers/IntersectionObserverTypes.res +67 -0
- package/src/observers/MutationObserver.res +94 -0
- package/src/observers/ResizeObserver.res +30 -0
- package/src/observers/ResizeObserverTypes.res +56 -0
- package/src/performance/Performance.res +101 -0
- package/src/performance/PerformanceEntry.res +5 -0
- package/src/performance/PerformanceMark.res +16 -0
- package/src/performance/PerformanceTypes.res +86 -0
- package/src/storage/Cache.res +117 -0
- package/src/storage/CacheStorage.res +43 -0
- package/src/storage/CacheTypes.res +24 -0
- package/src/storage/IDBDatabase.res +54 -0
- package/src/storage/IDBFactory.res +34 -0
- package/src/storage/IDBIndex.res +83 -0
- package/src/storage/IDBObjectStore.res +183 -0
- package/src/storage/IDBTransaction.res +22 -0
- package/src/storage/IndexedDbTypes.res +213 -0
- package/src/storage/Storage.res +42 -0
- package/src/storage/StorageEvent.res +10 -0
- package/src/storage/StorageManager.res +24 -0
- package/src/storage/StorageTypes.res +11 -0
- package/src/storage/WebStorageTypes.res +57 -0
- package/src/svg/SVGElement.res +115 -0
- package/src/svg/SVGGraphicsElement.res +16 -0
- package/src/svg/SVGLength.res +9 -0
- package/src/ui-events/CompositionEvent.res +10 -0
- package/src/ui-events/DataTransfer.res +38 -0
- package/src/ui-events/DataTransferItem.res +21 -0
- package/src/ui-events/DataTransferItemList.res +34 -0
- package/src/ui-events/FocusEvent.res +10 -0
- package/src/ui-events/InputEvent.res +16 -0
- package/src/ui-events/KeyboardEvent.res +16 -0
- package/src/ui-events/MouseEvent.res +26 -0
- package/src/ui-events/PointerEvent.res +24 -0
- package/src/ui-events/Touch.res +5 -0
- package/src/ui-events/TouchEvent.res +10 -0
- package/src/ui-events/TouchList.res +5 -0
- package/src/ui-events/UIEvent.res +20 -0
- package/src/ui-events/UiEventsTypes.res +590 -0
- package/src/ui-events/WheelEvent.res +10 -0
- package/src/url/URL.res +38 -0
- package/src/url/URLSearchParams.res +104 -0
- package/src/url/UrlTypes.res +69 -0
- package/src/view-transitions/ViewTransition.res +5 -0
- package/src/view-transitions/ViewTransitionsTypes.res +22 -0
- package/src/web-audio/AnalyserNode.res +38 -0
- package/src/web-audio/AudioBuffer.res +33 -0
- package/src/web-audio/AudioBufferSourceNode.res +21 -0
- package/src/web-audio/AudioContext.res +59 -0
- package/src/web-audio/AudioDestinationNode.res +1 -0
- package/src/web-audio/AudioNode.res +76 -0
- package/src/web-audio/AudioParam.res +65 -0
- package/src/web-audio/AudioProcessingEvent.res +10 -0
- package/src/web-audio/AudioScheduledSourceNode.res +23 -0
- package/src/web-audio/AudioWorkletNode.res +11 -0
- package/src/web-audio/BaseAudioContext.res +141 -0
- package/src/web-audio/BiquadFilterNode.res +21 -0
- package/src/web-audio/ChannelMergerNode.res +10 -0
- package/src/web-audio/ChannelSplitterNode.res +10 -0
- package/src/web-audio/ConstantSourceNode.res +10 -0
- package/src/web-audio/ConvolverNode.res +10 -0
- package/src/web-audio/DelayNode.res +10 -0
- package/src/web-audio/DynamicsCompressorNode.res +10 -0
- package/src/web-audio/GainNode.res +10 -0
- package/src/web-audio/IIRFilterNode.res +21 -0
- package/src/web-audio/MediaElementAudioSourceNode.res +10 -0
- package/src/web-audio/MediaStreamAudioDestinationNode.res +10 -0
- package/src/web-audio/MediaStreamAudioSourceNode.res +10 -0
- package/src/web-audio/OfflineAudioCompletionEvent.res +10 -0
- package/src/web-audio/OfflineAudioContext.res +58 -0
- package/src/web-audio/OscillatorNode.res +17 -0
- package/src/web-audio/PannerNode.res +10 -0
- package/src/web-audio/PeriodicWave.res +8 -0
- package/src/web-audio/StereoPannerNode.res +10 -0
- package/src/web-audio/WaveShaperNode.res +10 -0
- package/src/web-audio/WebAudioTypes.res +1309 -0
- package/src/web-audio/Worklet.res +14 -0
- package/src/window/CustomElementRegistry.res +30 -0
- package/src/window/Document.res +470 -0
- package/src/window/DomGlobal.res +459 -0
- package/src/window/History.res +37 -0
- package/src/window/HistoryTypes.res +26 -0
- package/src/window/IdleDeadline.res +5 -0
- package/src/window/Location.res +108 -0
- package/src/window/VisualViewport.res +5 -0
- package/src/window/VisualViewportTypes.res +37 -0
- package/src/window/Window.res +556 -0
- package/src/window/XPathExpression.res +16 -0
- package/src/window/XPathResult.res +46 -0
- package/src/workers/Clients.res +39 -0
- package/src/workers/NavigationPreloadManager.res +26 -0
- package/src/workers/ServiceWorker.res +38 -0
- package/src/workers/ServiceWorkerContainer.res +34 -0
- package/src/workers/ServiceWorkerRegistration.res +32 -0
- package/src/workers/ServiceWorkerScope.res +12 -0
- package/src/workers/ServiceWorkerTypes.res +153 -0
- package/src/workers/SharedWorker.res +68 -0
- package/src/workers/SharedWorkerScope.res +29 -0
- package/src/workers/WebWorkersTypes.res +46 -0
- package/src/workers/Worker.res +48 -0
- package/src/workers/WorkerLocation.res +18 -0
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
/**
|
|
2
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams)
|
|
3
|
+
*/
|
|
4
|
+
type t = UrlTypes.urlSearchParams = private {...UrlTypes.urlSearchParams}
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams)
|
|
8
|
+
*/
|
|
9
|
+
@new
|
|
10
|
+
external make: unit => t = "URLSearchParams"
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams)
|
|
14
|
+
*/
|
|
15
|
+
@new
|
|
16
|
+
external fromKeyValueArray: array<(string, string)> => t = "URLSearchParams"
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams)
|
|
20
|
+
*/
|
|
21
|
+
@new
|
|
22
|
+
external fromDict: dict<string> => t = "URLSearchParams"
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams)
|
|
26
|
+
*/
|
|
27
|
+
@new
|
|
28
|
+
external fromString: string => t = "URLSearchParams"
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
Appends a specified key/value pair as a new search parameter.
|
|
32
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/append)
|
|
33
|
+
*/
|
|
34
|
+
@send
|
|
35
|
+
external append: (t, ~name: string, ~value: string) => unit = "append"
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
Deletes the given search parameter, and its associated value, from the list of all search parameters.
|
|
39
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/delete)
|
|
40
|
+
*/
|
|
41
|
+
@send
|
|
42
|
+
external delete: (t, ~name: string, ~value: string=?) => unit = "delete"
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
Returns key/value pairs in the same order as they appear in the query string.
|
|
46
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/entries)
|
|
47
|
+
*/
|
|
48
|
+
@send
|
|
49
|
+
external entries: t => iterable<(string, string)> = "entries"
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
Returns the first value associated to the given search parameter.
|
|
53
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/get)
|
|
54
|
+
*/
|
|
55
|
+
@send
|
|
56
|
+
external get: (t, string) => Null.t<string> = "get"
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
Returns all the values association with a given search parameter.
|
|
60
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/getAll)
|
|
61
|
+
*/
|
|
62
|
+
@send
|
|
63
|
+
external getAll: (t, string) => array<string> = "getAll"
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
Returns a Boolean indicating if such a search parameter exists.
|
|
67
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/has)
|
|
68
|
+
*/
|
|
69
|
+
@send
|
|
70
|
+
external has: (t, ~name: string, ~value: string=?) => bool = "has"
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
Returns an iterator allowing iteration through all keys contained in this object.
|
|
74
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/keys)
|
|
75
|
+
*/
|
|
76
|
+
@send
|
|
77
|
+
external keys: t => iterable<string> = "keys"
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
Sets the value associated to a given search parameter to the given value. If there were several values, delete the others.
|
|
81
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/set)
|
|
82
|
+
*/
|
|
83
|
+
@send
|
|
84
|
+
external set: (t, ~name: string, ~value: string) => unit = "set"
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/sort)
|
|
88
|
+
*/
|
|
89
|
+
@send
|
|
90
|
+
external sort: t => unit = "sort"
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
Returns the query string suitable for use in a WebApiURL, without the question mark.
|
|
94
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/toString)
|
|
95
|
+
*/
|
|
96
|
+
@send
|
|
97
|
+
external toString: t => string = "toString"
|
|
98
|
+
|
|
99
|
+
/**
|
|
100
|
+
Returns an iterator allowing iteration through all values contained in this object.
|
|
101
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/values)
|
|
102
|
+
*/
|
|
103
|
+
@send
|
|
104
|
+
external values: t => iterable<string> = "values"
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
@@warning("-30")
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
[See URLSearchParams on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams)
|
|
5
|
+
*/
|
|
6
|
+
@editor.completeFrom(URLSearchParams)
|
|
7
|
+
type urlSearchParams = private {
|
|
8
|
+
/**
|
|
9
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams/size)
|
|
10
|
+
*/
|
|
11
|
+
size: int,
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
The WebApiURL interface represents an object providing static methods used for creating object URLs.
|
|
16
|
+
[See WebApiURL on MDN](https://developer.mozilla.org/docs/Web/API/URL)
|
|
17
|
+
TODO: mark as private once mutating fields of private records is allowed
|
|
18
|
+
*/
|
|
19
|
+
@editor.completeFrom(WebApiURL)
|
|
20
|
+
type url = {
|
|
21
|
+
/**
|
|
22
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/href)
|
|
23
|
+
*/
|
|
24
|
+
mutable href: string,
|
|
25
|
+
/**
|
|
26
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/origin)
|
|
27
|
+
*/
|
|
28
|
+
origin: string,
|
|
29
|
+
/**
|
|
30
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/protocol)
|
|
31
|
+
*/
|
|
32
|
+
mutable protocol: string,
|
|
33
|
+
/**
|
|
34
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/username)
|
|
35
|
+
*/
|
|
36
|
+
mutable username: string,
|
|
37
|
+
/**
|
|
38
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/password)
|
|
39
|
+
*/
|
|
40
|
+
mutable password: string,
|
|
41
|
+
/**
|
|
42
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/host)
|
|
43
|
+
*/
|
|
44
|
+
mutable host: string,
|
|
45
|
+
/**
|
|
46
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/hostname)
|
|
47
|
+
*/
|
|
48
|
+
mutable hostname: string,
|
|
49
|
+
/**
|
|
50
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/port)
|
|
51
|
+
*/
|
|
52
|
+
mutable port: string,
|
|
53
|
+
/**
|
|
54
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/pathname)
|
|
55
|
+
*/
|
|
56
|
+
mutable pathname: string,
|
|
57
|
+
/**
|
|
58
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/search)
|
|
59
|
+
*/
|
|
60
|
+
mutable search: string,
|
|
61
|
+
/**
|
|
62
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/searchParams)
|
|
63
|
+
*/
|
|
64
|
+
searchParams: urlSearchParams,
|
|
65
|
+
/**
|
|
66
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/URL/hash)
|
|
67
|
+
*/
|
|
68
|
+
mutable hash: string,
|
|
69
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
@@warning("-30")
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
[See ViewTransition on MDN](https://developer.mozilla.org/docs/Web/API/ViewTransition)
|
|
5
|
+
*/
|
|
6
|
+
@editor.completeFrom(ViewTransition)
|
|
7
|
+
type viewTransition = private {
|
|
8
|
+
/**
|
|
9
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/ViewTransition/updateCallbackDone)
|
|
10
|
+
*/
|
|
11
|
+
updateCallbackDone: promise<unit>,
|
|
12
|
+
/**
|
|
13
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/ViewTransition/ready)
|
|
14
|
+
*/
|
|
15
|
+
ready: promise<unit>,
|
|
16
|
+
/**
|
|
17
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/ViewTransition/finished)
|
|
18
|
+
*/
|
|
19
|
+
finished: promise<unit>,
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
type viewTransitionUpdateCallback = promise<JSON.t>
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
include AudioNode.Impl({type t = WebAudioTypes.analyserNode})
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AnalyserNode)
|
|
5
|
+
*/
|
|
6
|
+
@new
|
|
7
|
+
external make: (
|
|
8
|
+
~context: WebAudioTypes.baseAudioContext,
|
|
9
|
+
~options: WebAudioTypes.analyserOptions=?,
|
|
10
|
+
) => WebAudioTypes.analyserNode = "AnalyserNode"
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AnalyserNode/getFloatFrequencyData)
|
|
14
|
+
*/
|
|
15
|
+
@send
|
|
16
|
+
external getFloatFrequencyData: (WebAudioTypes.analyserNode, array<float>) => unit =
|
|
17
|
+
"getFloatFrequencyData"
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AnalyserNode/getByteFrequencyData)
|
|
21
|
+
*/
|
|
22
|
+
@send
|
|
23
|
+
external getByteFrequencyData: (WebAudioTypes.analyserNode, array<int>) => unit =
|
|
24
|
+
"getByteFrequencyData"
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AnalyserNode/getFloatTimeDomainData)
|
|
28
|
+
*/
|
|
29
|
+
@send
|
|
30
|
+
external getFloatTimeDomainData: (WebAudioTypes.analyserNode, array<float>) => unit =
|
|
31
|
+
"getFloatTimeDomainData"
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AnalyserNode/getByteTimeDomainData)
|
|
35
|
+
*/
|
|
36
|
+
@send
|
|
37
|
+
external getByteTimeDomainData: (WebAudioTypes.analyserNode, array<int>) => unit =
|
|
38
|
+
"getByteTimeDomainData"
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioBuffer)
|
|
3
|
+
*/
|
|
4
|
+
@throws(JsExn) @new
|
|
5
|
+
external make: WebAudioTypes.audioBufferOptions => WebAudioTypes.audioBuffer = "AudioBuffer"
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioBuffer/getChannelData)
|
|
9
|
+
*/
|
|
10
|
+
@throws(JsExn) @send
|
|
11
|
+
external getChannelData: (WebAudioTypes.audioBuffer, int) => array<float> = "getChannelData"
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioBuffer/copyFromChannel)
|
|
15
|
+
*/
|
|
16
|
+
@throws(JsExn) @send
|
|
17
|
+
external copyFromChannel: (
|
|
18
|
+
WebAudioTypes.audioBuffer,
|
|
19
|
+
~destination: array<float>,
|
|
20
|
+
~channelNumber: int,
|
|
21
|
+
~bufferOffset: int=?,
|
|
22
|
+
) => unit = "copyFromChannel"
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioBuffer/copyToChannel)
|
|
26
|
+
*/
|
|
27
|
+
@throws(JsExn) @send
|
|
28
|
+
external copyToChannel: (
|
|
29
|
+
WebAudioTypes.audioBuffer,
|
|
30
|
+
~source: array<float>,
|
|
31
|
+
~channelNumber: int,
|
|
32
|
+
~bufferOffset: int=?,
|
|
33
|
+
) => unit = "copyToChannel"
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
include AudioScheduledSourceNode.Impl({type t = WebAudioTypes.audioBufferSourceNode})
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioBufferSourceNode)
|
|
5
|
+
*/
|
|
6
|
+
@new
|
|
7
|
+
external make: (
|
|
8
|
+
~context: WebAudioTypes.baseAudioContext,
|
|
9
|
+
~options: WebAudioTypes.audioBufferSourceOptions=?,
|
|
10
|
+
) => WebAudioTypes.audioBufferSourceNode = "AudioBufferSourceNode"
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioBufferSourceNode/start)
|
|
14
|
+
*/
|
|
15
|
+
@throws(JsExn) @send
|
|
16
|
+
external startA: (
|
|
17
|
+
WebAudioTypes.audioBufferSourceNode,
|
|
18
|
+
~when_: float=?,
|
|
19
|
+
~offset: float=?,
|
|
20
|
+
~duration: float=?,
|
|
21
|
+
) => unit = "start"
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
include BaseAudioContext.Impl({type t = WebAudioTypes.audioContext})
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioContext)
|
|
5
|
+
*/
|
|
6
|
+
@throws(JsExn) @new
|
|
7
|
+
external make: (
|
|
8
|
+
~contextOptions: WebAudioTypes.audioContextOptions=?,
|
|
9
|
+
) => WebAudioTypes.audioContext = "AudioContext"
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioContext/getOutputTimestamp)
|
|
13
|
+
*/
|
|
14
|
+
@send
|
|
15
|
+
external getOutputTimestamp: WebAudioTypes.audioContext => WebAudioTypes.audioTimestamp =
|
|
16
|
+
"getOutputTimestamp"
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioContext/resume)
|
|
20
|
+
*/
|
|
21
|
+
@send
|
|
22
|
+
external resume: WebAudioTypes.audioContext => promise<unit> = "resume"
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioContext/suspend)
|
|
26
|
+
*/
|
|
27
|
+
@send
|
|
28
|
+
external suspend: WebAudioTypes.audioContext => promise<unit> = "suspend"
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioContext/close)
|
|
32
|
+
*/
|
|
33
|
+
@send
|
|
34
|
+
external close: WebAudioTypes.audioContext => promise<unit> = "close"
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioContext/createMediaElementSource)
|
|
38
|
+
*/
|
|
39
|
+
@send
|
|
40
|
+
external createMediaElementSource: (
|
|
41
|
+
WebAudioTypes.audioContext,
|
|
42
|
+
DomHTMLMediaElement.t,
|
|
43
|
+
) => WebAudioTypes.mediaElementAudioSourceNode = "createMediaElementSource"
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioContext/createMediaStreamSource)
|
|
47
|
+
*/
|
|
48
|
+
@send
|
|
49
|
+
external createMediaStreamSource: (
|
|
50
|
+
WebAudioTypes.audioContext,
|
|
51
|
+
MediaCaptureAndStreamsTypes.mediaStream,
|
|
52
|
+
) => WebAudioTypes.mediaStreamAudioSourceNode = "createMediaStreamSource"
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioContext/createMediaStreamDestination)
|
|
56
|
+
*/
|
|
57
|
+
@send
|
|
58
|
+
external createMediaStreamDestination: WebAudioTypes.audioContext => WebAudioTypes.mediaStreamAudioDestinationNode =
|
|
59
|
+
"createMediaStreamDestination"
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
include AudioNode.Impl({type t = WebAudioTypes.audioDestinationNode})
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
module Impl = (
|
|
2
|
+
T: {
|
|
3
|
+
type t
|
|
4
|
+
},
|
|
5
|
+
) => {
|
|
6
|
+
include EventTarget.Impl({type t = T.t})
|
|
7
|
+
|
|
8
|
+
external asAudioNode: T.t => WebAudioTypes.audioNode = "%identity"
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/connect)
|
|
12
|
+
*/
|
|
13
|
+
@throws(JsExn) @send
|
|
14
|
+
external connect: (
|
|
15
|
+
T.t,
|
|
16
|
+
~destinationNode: WebAudioTypes.audioNode,
|
|
17
|
+
~output: int=?,
|
|
18
|
+
~input: int=?,
|
|
19
|
+
) => WebAudioTypes.audioNode = "connect"
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/connect)
|
|
23
|
+
*/
|
|
24
|
+
@throws(JsExn) @send
|
|
25
|
+
external connect2: (T.t, ~destinationParam: WebAudioTypes.audioParam, ~output: int=?) => unit =
|
|
26
|
+
"connect"
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/disconnect)
|
|
30
|
+
*/
|
|
31
|
+
@throws(JsExn) @send
|
|
32
|
+
external disconnect: T.t => unit = "disconnect"
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/disconnect)
|
|
36
|
+
*/
|
|
37
|
+
@throws(JsExn) @send
|
|
38
|
+
external disconnect2: (T.t, int) => unit = "disconnect"
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/disconnect)
|
|
42
|
+
*/
|
|
43
|
+
@throws(JsExn) @send
|
|
44
|
+
external disconnect3: (T.t, WebAudioTypes.audioNode) => unit = "disconnect"
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/disconnect)
|
|
48
|
+
*/
|
|
49
|
+
@throws(JsExn) @send
|
|
50
|
+
external disconnect4: (T.t, ~destinationNode: WebAudioTypes.audioNode, ~output: int) => unit =
|
|
51
|
+
"disconnect"
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/disconnect)
|
|
55
|
+
*/
|
|
56
|
+
@throws(JsExn) @send
|
|
57
|
+
external disconnect5: (
|
|
58
|
+
T.t,
|
|
59
|
+
~destinationNode: WebAudioTypes.audioNode,
|
|
60
|
+
~output: int,
|
|
61
|
+
~input: int,
|
|
62
|
+
) => unit = "disconnect"
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/disconnect)
|
|
66
|
+
*/
|
|
67
|
+
@throws(JsExn) @send
|
|
68
|
+
external disconnect6: (T.t, WebAudioTypes.audioParam) => unit = "disconnect"
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioNode/disconnect)
|
|
72
|
+
*/
|
|
73
|
+
@throws(JsExn) @send
|
|
74
|
+
external disconnect7: (T.t, ~destinationParam: WebAudioTypes.audioParam, ~output: int) => unit =
|
|
75
|
+
"disconnect"
|
|
76
|
+
}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioParam/setValueAtTime)
|
|
3
|
+
*/
|
|
4
|
+
@throws(JsExn) @send
|
|
5
|
+
external setValueAtTime: (
|
|
6
|
+
WebAudioTypes.audioParam,
|
|
7
|
+
~value: float,
|
|
8
|
+
~startTime: float,
|
|
9
|
+
) => WebAudioTypes.audioParam = "setValueAtTime"
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioParam/linearRampToValueAtTime)
|
|
13
|
+
*/
|
|
14
|
+
@send
|
|
15
|
+
external linearRampToValueAtTime: (
|
|
16
|
+
WebAudioTypes.audioParam,
|
|
17
|
+
~value: float,
|
|
18
|
+
~endTime: float,
|
|
19
|
+
) => WebAudioTypes.audioParam = "linearRampToValueAtTime"
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioParam/exponentialRampToValueAtTime)
|
|
23
|
+
*/
|
|
24
|
+
@send
|
|
25
|
+
external exponentialRampToValueAtTime: (
|
|
26
|
+
WebAudioTypes.audioParam,
|
|
27
|
+
~value: float,
|
|
28
|
+
~endTime: float,
|
|
29
|
+
) => WebAudioTypes.audioParam = "exponentialRampToValueAtTime"
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioParam/setTargetAtTime)
|
|
33
|
+
*/
|
|
34
|
+
@send
|
|
35
|
+
external setTargetAtTime: (
|
|
36
|
+
WebAudioTypes.audioParam,
|
|
37
|
+
~target: float,
|
|
38
|
+
~startTime: float,
|
|
39
|
+
~timeConstant: float,
|
|
40
|
+
) => WebAudioTypes.audioParam = "setTargetAtTime"
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioParam/setValueCurveAtTime)
|
|
44
|
+
*/
|
|
45
|
+
@throws(JsExn) @send
|
|
46
|
+
external setValueCurveAtTime: (
|
|
47
|
+
WebAudioTypes.audioParam,
|
|
48
|
+
~values: array<float>,
|
|
49
|
+
~startTime: float,
|
|
50
|
+
~duration: float,
|
|
51
|
+
) => WebAudioTypes.audioParam = "setValueCurveAtTime"
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioParam/cancelScheduledValues)
|
|
55
|
+
*/
|
|
56
|
+
@send
|
|
57
|
+
external cancelScheduledValues: (WebAudioTypes.audioParam, float) => WebAudioTypes.audioParam =
|
|
58
|
+
"cancelScheduledValues"
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioParam/cancelAndHoldAtTime)
|
|
62
|
+
*/
|
|
63
|
+
@send
|
|
64
|
+
external cancelAndHoldAtTime: (WebAudioTypes.audioParam, float) => WebAudioTypes.audioParam =
|
|
65
|
+
"cancelAndHoldAtTime"
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
include Event.Impl({type t = WebAudioTypes.audioProcessingEvent})
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioProcessingEvent)
|
|
5
|
+
*/
|
|
6
|
+
@new
|
|
7
|
+
external make: (
|
|
8
|
+
~type_: string,
|
|
9
|
+
~eventInitDict: WebAudioTypes.audioProcessingEventInit,
|
|
10
|
+
) => WebAudioTypes.audioProcessingEvent = "AudioProcessingEvent"
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
module Impl = (
|
|
2
|
+
T: {
|
|
3
|
+
type t
|
|
4
|
+
},
|
|
5
|
+
) => {
|
|
6
|
+
include AudioNode.Impl({type t = T.t})
|
|
7
|
+
|
|
8
|
+
external asAudioScheduledSourceNode: T.t => WebAudioTypes.audioScheduledSourceNode = "%identity"
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioScheduledSourceNode/start)
|
|
12
|
+
*/
|
|
13
|
+
@throws(JsExn) @send
|
|
14
|
+
external start: (T.t, ~when_: float=?) => unit = "start"
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioScheduledSourceNode/stop)
|
|
18
|
+
*/
|
|
19
|
+
@throws(JsExn) @send
|
|
20
|
+
external stop: (T.t, ~when_: float=?) => unit = "stop"
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
include Impl({type t = WebAudioTypes.audioScheduledSourceNode})
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
include AudioNode.Impl({type t = WebAudioTypes.audioWorkletNode})
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
[Read more on MDN](https://developer.mozilla.org/docs/Web/API/AudioWorkletNode)
|
|
5
|
+
*/
|
|
6
|
+
@throws(JsExn) @new
|
|
7
|
+
external make: (
|
|
8
|
+
~context: WebAudioTypes.baseAudioContext,
|
|
9
|
+
~name: string,
|
|
10
|
+
~options: WebAudioTypes.audioWorkletNodeOptions=?,
|
|
11
|
+
) => WebAudioTypes.audioWorkletNode = "AudioWorkletNode"
|