mirror of
https://github.com/Modernizr/Modernizr.git
synced 2026-01-09 23:57:57 -05:00
25 lines
689 B
JavaScript
25 lines
689 B
JavaScript
/*!
|
|
{
|
|
"property": "speechrecognition",
|
|
"tags": ["input", "speech"],
|
|
"authors": ["Cătălin Mariș"],
|
|
"name": "Speech Recognition API",
|
|
"notes": [{
|
|
"name": "W3C Spec",
|
|
"href": "https://w3c.github.io/speech-api/speechapi.html#speechreco-section"
|
|
}, {
|
|
"name": "Introduction to the Web Speech API",
|
|
"href": "https://developers.google.com/web/updates/2013/01/Voice-Driven-Web-Apps-Introduction-to-the-Web-Speech-API"
|
|
}]
|
|
}
|
|
!*/
|
|
define(['Modernizr', 'prefixed'], function(Modernizr, prefixed) {
|
|
Modernizr.addTest('speechrecognition', function() {
|
|
try {
|
|
return !!prefixed('SpeechRecognition', window);
|
|
} catch (e) {
|
|
return false;
|
|
}
|
|
});
|
|
});
|