-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6,206 changed files
with
1,299,295 additions
and
4,635 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
; editorconfig.org | ||
# editorconfig.org | ||
root = true | ||
|
||
; Unix-style newlines | ||
[*] | ||
end_of_line = LF | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,5 @@ | ||
modernizr.min.js | ||
.DS_Store | ||
build | ||
dist | ||
tmp | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,7 @@ | ||
language: node_js | ||
node_js: | ||
- 0.7 | ||
notifications: | ||
email: false | ||
- 0.8 | ||
before_script: | ||
- "export DISPLAY=:99.0" | ||
- "sh -e /etc/init.d/xvfb start" | ||
- npm install connect | ||
- sudo node test/js/server.js & | ||
- sleep 5 | ||
script: phantomjs test/qunit/run-qunit.js 'http://localhost:80/test/index.html?filter=!caniuse.com' | ||
- npm install grunt | ||
- grunt build | ||
script: grunt travis --verbose |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/* Modernizr 3.0.0pre (Custom Build) | MIT & BSD */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
({ | ||
"appDir" : ".", // take all the scripts from this dir | ||
"dir" : "build/", // and copy them to this dir, then optimize | ||
"baseUrl" : "src/", | ||
"optimize" : "none", | ||
"optimizeCss" : "none", | ||
"paths" : { | ||
"test" : "../feature-detects" | ||
}, | ||
modules : [ | ||
{ | ||
"name" : "modernizr-build", | ||
"include" : ["modernizr-init"], | ||
"create" : true | ||
} | ||
], | ||
onBuildWrite: function (id, path, contents) { | ||
if ((/define\(.*?\{/).test(contents)) { | ||
//Remove AMD ceremony for use without require.js or almond.js | ||
contents = contents.replace(/define\(.*?\{/, ''); | ||
|
||
contents = contents.replace(/\}\);\s*?$/,''); | ||
|
||
if ( !contents.match(/Modernizr\.addTest\(/) && !contents.match(/Modernizr\.addAsyncTest\(/) ) { | ||
//remove last return statement and trailing }) | ||
contents = contents.replace(/return.*[^return]*$/,''); | ||
} | ||
} | ||
else if ((/require\([^\{]*?\{/).test(contents)) { | ||
contents = contents.replace(/require[^\{]+\{/, ''); | ||
contents = contents.replace(/\}\);\s*$/,''); | ||
} | ||
return contents; | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/usr/bin/env bash | ||
grunt build > /dev/null | ||
cat ./dist/modernizr-build.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#! /usr/bin/env bash | ||
rm -rf build | ||
node r.js -o app.build.js | ||
rm -rf dist | ||
mkdir dist | ||
cp build/src/modernizr-build.js dist/modernizr-build.js | ||
rm -rf build | ||
node processbuild.js | ||
m=$(stat -f "%z" dist/modernizr-build.min.js) | ||
gzip -nfc --best dist/modernizr-build.min.js > dist/modernizr-build.min.js.gz | ||
g=$(stat -f "%z" dist/modernizr-build.min.js.gz) | ||
rm -f dist/modernizr-build.min.js.gz | ||
echo "$m bytes minified, $g bytes gzipped" |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,162 @@ | ||
{ | ||
"classPrefix" : "", | ||
"options": [ | ||
"setClasses", | ||
"addTest", | ||
"html5printshiv", | ||
"load", | ||
"testProp", | ||
"fnBind" | ||
], | ||
"feature-detects": [ | ||
"test/a/download", | ||
"test/audio/audiodata", | ||
"test/audio/webaudio", | ||
"test/battery/lowbattery", | ||
"test/canvas/todataurl", | ||
"test/css/animations", | ||
"test/css/backgroundposition-shorthand", | ||
"test/css/backgroundposition-xy", | ||
"test/css/backgroundrepeat", | ||
"test/css/backgroundsize", | ||
"test/css/backgroundsizecover", | ||
"test/css/borderimage", | ||
"test/css/borderradius", | ||
"test/css/boxshadow", | ||
"test/css/boxsizing", | ||
"test/css/calc", | ||
"test/css/columns", | ||
"test/css/cubicbezierrange", | ||
"test/css/displayrunin", | ||
"test/css/displaytable", | ||
"test/css/filters", | ||
"test/css/flexbox", | ||
"test/css/flexboxlegacy", | ||
"test/css/fontface", | ||
"test/css/generatedcontent", | ||
"test/css/gradients", | ||
"test/css/hsla", | ||
"test/css/hyphens", | ||
"test/css/lastchild", | ||
"test/css/mask", | ||
"test/css/mediaqueries", | ||
"test/css/multiplebgs", | ||
"test/css/objectfit", | ||
"test/css/opacity", | ||
"test/css/overflow-scrolling", | ||
"test/css/pointerevents", | ||
"test/css/positionsticky", | ||
"test/css/reflections", | ||
"test/css/regions", | ||
"test/css/remunit", | ||
"test/css/resize", | ||
"test/css/rgba", | ||
"test/css/scrollbars", | ||
"test/css/subpixelfont", | ||
"test/css/supports", | ||
"test/css/textshadow", | ||
"test/css/transforms", | ||
"test/css/transforms3d", | ||
"test/css/transitions", | ||
"test/css/userselect", | ||
"test/css/vhunit", | ||
"test/css/vmaxunit", | ||
"test/css/vminunit", | ||
"test/css/vwunit", | ||
"test/dom/classlist", | ||
"test/dom/createElement-attrs", | ||
"test/dom/dataset", | ||
"test/dom/microdata", | ||
"test/elem/datalist", | ||
"test/elem/details", | ||
"test/elem/output", | ||
"test/elem/progress-meter", | ||
"test/elem/ruby", | ||
"test/elem/time", | ||
"test/elem/track", | ||
"test/es5/strictmode", | ||
"test/event/deviceorientation-motion", | ||
"test/file/api", | ||
"test/file/filesystem", | ||
"test/forms/fileinput", | ||
"test/forms/formattribute", | ||
"test/forms/inputnumber-l10n", | ||
"test/forms/placeholder", | ||
"test/forms/speechinput", | ||
"test/forms/validation", | ||
"test/iframe/sandbox", | ||
"test/iframe/seamless", | ||
"test/iframe/srcdoc", | ||
"test/img/apng", | ||
"test/img/webp-lossless", | ||
"test/img/webp", | ||
"test/network/connection", | ||
"test/network/eventsource", | ||
"test/network/xhr2", | ||
"test/script/async", | ||
"test/script/defer", | ||
"test/storage/localstorage", | ||
"test/storage/sessionstorage", | ||
"test/storage/websqldatabase", | ||
"test/style/scoped", | ||
"test/svg/clippaths", | ||
"test/svg/filters", | ||
"test/svg/inline", | ||
"test/svg/smil", | ||
"test/url/data-uri", | ||
"test/webgl/extensions", | ||
"test/websockets/binary", | ||
"test/window/framed", | ||
"test/workers/blobworkers", | ||
"test/workers/dataworkers", | ||
"test/workers/webworkers", | ||
"test/applicationcache", | ||
"test/webrtc/getusermedia", | ||
"test/webrtc/peerconnection", | ||
"test/audio", | ||
"test/typed-arrays", | ||
"test/battery", | ||
"test/blob", | ||
"test/canvas", | ||
"test/canvastext", | ||
"test/contenteditable", | ||
"test/contentsecuritypolicy", | ||
"test/contextmenu", | ||
"test/cookies", | ||
"test/cors", | ||
"test/custom-protocol-handler", | ||
"test/dart", | ||
"test/dataview-api", | ||
"test/draganddrop", | ||
"test/emoji", | ||
"test/exif-orientation", | ||
"test/fullscreen-api", | ||
"test/gamepad", | ||
"test/hashchange", | ||
"test/history", | ||
"test/ie8compat", | ||
"test/indexedDB", | ||
"test/input", | ||
"test/inputtypes", | ||
"test/json", | ||
"test/lists-reversed", | ||
"test/mathml", | ||
"test/notification", | ||
"test/pagevisibility-api", | ||
"test/performance", | ||
"test/pointerevents", | ||
"test/pointerlock-api", | ||
"test/postmessage", | ||
"test/quota-management-api", | ||
"test/requestanimationframe", | ||
"test/svg", | ||
"test/touchevents", | ||
"test/unicode", | ||
"test/userdata", | ||
"test/vibration", | ||
"test/video", | ||
"test/web-intents", | ||
"test/webgl", | ||
"test/websockets" | ||
] | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
define(['Modernizr', 'createElement'], function( Modernizr, createElement ) { | ||
// a[download] attribute | ||
// When used on an <a>, this attribute signifies that the resource it | ||
// points to should be downloaded by the browser rather than navigating to it. | ||
// http://developers.whatwg.org/links.html#downloading-resources | ||
|
||
Modernizr.addTest('adownload', 'download' in createElement('a')); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
define(['Modernizr'], function( Modernizr ) { | ||
Modernizr.addTest('applicationcache', !!window.applicationCache); | ||
}); |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
define(['Modernizr', 'createElement'], function( Modernizr, createElement ) { | ||
// This tests evaluates support of the audio element, as well as | ||
// testing what types of content it supports. | ||
// | ||
// We're using the Boolean constructor here, so that we can extend the value | ||
// e.g. Modernizr.audio // true | ||
// Modernizr.video.ogg // 'probably' | ||
// | ||
// Codec values from : github.com/NielsLeenheer/html5test/blob/9106a8/index.html#L845 | ||
// thx to NielsLeenheer and zcorpan | ||
|
||
// Note: in some older browsers, "no" was a return value instead of empty string. | ||
// It was live in FF3.5.0 and 3.5.1, but fixed in 3.5.2 | ||
// It was also live in Safari 4.0.0 - 4.0.4, but fixed in 4.0.5 | ||
Modernizr.addTest('audio', function() { | ||
var elem = createElement('audio'); | ||
var bool = false; | ||
|
||
try { | ||
if ( bool = !!elem.canPlayType ) { | ||
bool = new Boolean(bool); | ||
bool.ogg = elem.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/,''); | ||
bool.mp3 = elem.canPlayType('audio/mpeg;') .replace(/^no$/,''); | ||
|
||
// Mimetypes accepted: | ||
// developer.mozilla.org/En/Media_formats_supported_by_the_audio_and_video_elements | ||
// bit.ly/iphoneoscodecs | ||
bool.wav = elem.canPlayType('audio/wav; codecs="1"') .replace(/^no$/,''); | ||
bool.m4a = ( elem.canPlayType('audio/x-m4a;') || | ||
elem.canPlayType('audio/aac;')) .replace(/^no$/,''); | ||
} | ||
} catch(e) { } | ||
|
||
return bool; | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
define(['Modernizr'], function( Modernizr ) { | ||
// Mozilla Audio Data API | ||
// https://wiki.mozilla.org/Audio_Data_API | ||
// by Addy Osmani | ||
Modernizr.addTest('audiodata', !!window.Audio); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
define(['Modernizr'], function( Modernizr ) { | ||
// Web Audio API | ||
// https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html | ||
// By Addy Osmani | ||
Modernizr.addTest('webaudio', !!(window.webkitAudioContext || window.AudioContext)); | ||
}); |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
define(['Modernizr', 'prefixed'], function( Modernizr, prefixed ) { | ||
// Battery API | ||
// https://developer.mozilla.org/en/DOM/window.navigator.mozBattery | ||
// By: Paul Sayre | ||
Modernizr.addTest('battery-api', | ||
!!prefixed('battery', navigator) | ||
); | ||
}); |
Oops, something went wrong.