Merge pull request #27772 from element-hq/t3chguy/modernizr-webaudio
Enable audio/webaudio Modernizr rule
This commit is contained in:
commit
ab54cbc329
2 changed files with 32 additions and 2 deletions
|
@ -31,6 +31,7 @@
|
||||||
"test/json",
|
"test/json",
|
||||||
"test/network/fetch",
|
"test/network/fetch",
|
||||||
"test/storage/localstorage",
|
"test/storage/localstorage",
|
||||||
"test/window/resizeobserver"
|
"test/window/resizeobserver",
|
||||||
|
"test/audio/webaudio"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/*!
|
/*!
|
||||||
* modernizr v3.13.0
|
* modernizr v3.13.0
|
||||||
* Build https://modernizr.com/download?-cors-cryptography-cssanimations-cssfilters-displaytable-es5date-es5function-es5object-es5undefined-es6array-es6collections-es6string-fetch-flexbox-json-localstorage-objectfit-promises-resizeobserver-sandbox-svg-svgasimg-svgfilters-urlparser-urlsearchparams-dontmin
|
* Build https://modernizr.com/download?-cors-cryptography-cssanimations-cssfilters-displaytable-es5date-es5function-es5object-es5undefined-es6array-es6collections-es6string-fetch-flexbox-json-localstorage-objectfit-promises-resizeobserver-sandbox-svg-svgasimg-svgfilters-urlparser-urlsearchparams-webaudio-dontmin
|
||||||
*
|
*
|
||||||
* Copyright (c)
|
* Copyright (c)
|
||||||
* Faruk Ates
|
* Faruk Ates
|
||||||
|
@ -1947,6 +1947,35 @@ Detects support for ResizeObserver.
|
||||||
|
|
||||||
Modernizr.addTest('resizeobserver', 'ResizeObserver' in window);
|
Modernizr.addTest('resizeobserver', 'ResizeObserver' in window);
|
||||||
|
|
||||||
|
/*!
|
||||||
|
{
|
||||||
|
"name": "Web Audio API",
|
||||||
|
"property": "webaudio",
|
||||||
|
"caniuse": "audio-api",
|
||||||
|
"polyfills": ["xaudiojs", "dynamicaudiojs", "audiolibjs"],
|
||||||
|
"tags": ["audio", "media"],
|
||||||
|
"builderAliases": ["audio_webaudio_api"],
|
||||||
|
"authors": ["Addy Osmani"],
|
||||||
|
"notes": [{
|
||||||
|
"name": "W3C Spec",
|
||||||
|
"href": "https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html"
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
!*/
|
||||||
|
/* DOC
|
||||||
|
Detects the older non standard webaudio API, (as opposed to the standards based AudioContext API)
|
||||||
|
*/
|
||||||
|
|
||||||
|
Modernizr.addTest('webaudio', function() {
|
||||||
|
var prefixed = 'webkitAudioContext' in window;
|
||||||
|
var unprefixed = 'AudioContext' in window;
|
||||||
|
|
||||||
|
if (Modernizr._config.usePrefixes) {
|
||||||
|
return prefixed || unprefixed;
|
||||||
|
}
|
||||||
|
return unprefixed;
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
// Run each test
|
// Run each test
|
||||||
testRunner();
|
testRunner();
|
||||||
|
|
Loading…
Reference in a new issue