first commit

This commit is contained in:
armansansd
2023-07-12 16:31:19 +01:00
commit 3424b1927b
23306 changed files with 2217776 additions and 0 deletions
+7
View File
@@ -0,0 +1,7 @@
{
"extends": "gulp",
"env": {
"browser": true,
"mocha": true
}
}
+21
View File
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2018 Rejas
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+108
View File
@@ -0,0 +1,108 @@
# gulp-modernizr [![Build Status](https://secure.travis-ci.org/rejas/gulp-modernizr.png?branch=master,develop)](https://travis-ci.org/rejas/gulp-modernizr)
[![NPM](https://nodei.co/npm/gulp-modernizr.png?compact=true)](https://nodei.co/npm/gulp-modernizr/)
A [Gulp](https://gulpjs.com/) wrapper for [Modernizr](https://github.com/doctyper/customizr).
*Note*: This plugin uses version 3 of Modernizr. Make sure to check the [Github repo](https://github.com/Modernizr/Modernizr/tree/master/feature-detects) for the correct feature names (example: ```Modernizr.touch``` was renamed to ```Modernizr.touchevents```).
## Usage
First, install `gulp-modernizr` as a development dependency:
```shell
npm install --save-dev gulp-modernizr
```
Then, add it to your `gulpfile.js`:
```javascript
var modernizr = require('gulp-modernizr');
gulp.task('modernizr', function() {
return gulp.src('./js/*.js')
.pipe(modernizr())
.pipe(gulp.dest('build/'))
});
```
Running the plugin will search for tests in your `src` files like this one for example:
```javascript
if (!Modernizr.objectfit) { doSomethingLikeCallAPolyfill(); }
```
and in this case add the 'objectfit' test to the ouptut file.
## API
### modernizr(fileName)
#### fileName
Type: `String`
You can optionally pass a fileName to name the Modernizr file (defaults to 'modernizr.js')
```javascript
gulp.src('./js/*.js')
.pipe(modernizr('modernizr-custom.js'));
```
### modernizr(/*fileName, */ settings)
#### settings
Type: `Object`
You can pass settings as an object. See the [customizr repository](https://github.com/doctyper/customizr#config-file) for valid settings.
```javascript
gulp.src('./js/*.js')
.pipe(modernizr({
excludeTests: ['csstransforms3d']
}));
```
The 'settings' object can also be required from a JSON file:
modernizr-config.json:
```javascript
{
'options': ['setClasses'],
'tests': ['webworkers']
}
```
gulpfile.js:
```javascript
gulp.src('./js/*.js')
.pipe(modernizr(require('./modernizr-config.json')))
```
#### Available Settings
##### See the [customizr repository](https://github.com/Modernizr/customizr#config-file) for valid settings.
#### `settings.crawl`
Currently not passed on to customizr, see [issue #36](https://github.com/rejas/gulp-modernizr/issues/36)
#### `settings.quiet`
Defaults to false, setting it to true suppresses any log output from customizr
#### `settings.uglify`
Will never be passed to customizr, see the [Gulp guidelines](https://github.com/gulpjs/gulp/blob/master/docs/writing-a-plugin/guidelines.md). The option to uglify the build goes against guidelines #1 and #3. Thus, this setting has been removed from this plugin. You may use [`gulp-uglify`](https://npmjs.org/package/gulp-uglify) to achieve this functionality in Gulp:
```javascript
gulp.src('./js/*.js')
.pipe(modernizr())
.pipe(uglify())
.pipe(gulp.dest("build/"));
```
[modernizr-travis-url]: https://travis-ci.org/rejas/gulp-modernizr
[modernizr-travis-image]: https://secure.travis-ci.org/rejas/gulp-modernizr.png?branch=master
[modernizr-npm-url]: https://npmjs.org/package/gulp-modernizr
[modernizr-npm-image]: https://badge.fury.io/js/gulp-modernizr.png
## License
Copyright (c) 2018 Rejas
Licensed under the MIT license.
+106
View File
@@ -0,0 +1,106 @@
var path = require('path');
var PluginError = require('plugin-error');
var Vinyl = require('vinyl');
var through = require('through2');
var customizr = require('customizr');
module.exports = function(fileName, opt) {
'use strict';
// Set some defaults
var PLUGIN_NAME = 'gulp-modernizr';
var DEFAULT_FILE_NAME = 'modernizr.js';
// Ensure fileName exists
if (typeof fileName === 'undefined') {
fileName = opt ? opt.dest : DEFAULT_FILE_NAME;
} else if (typeof fileName === typeof{}) {
opt = fileName;
fileName = DEFAULT_FILE_NAME;
}
// Ensure opt exists
opt = opt || {};
// Enable string parsing in customizr
opt.useBuffers = true;
// Set crawl to false, Gulp is providing files & data
opt.crawl = false;
// Reset opt.files. Store buffers here.
opt.files = {
src: [],
};
// Per Gulp docs (https://github.com/gulpjs/gulp/blob/master/docs/writing-a-plugin/guidelines.md)
// "Your plugin shouldn't do things that other plugins are responsible for"
opt.uglify = false;
// Save first file for metadata purposes
var firstFile,
stream;
function storeBuffers(file, enc, callback) {
// Return if null
if (file.isNull()) {
stream.push(file);
return callback();
}
// No stream support (yet?)
if (file.isStream()) {
stream.emit('error', new PluginError({
plugin: PLUGIN_NAME,
message: 'Streaming not supported',
}));
return callback();
}
// Set first file
if (!firstFile) {
firstFile = file;
}
// Save buffer for later use
opt.files.src.push(file);
return callback();
}
function generateModernizr(callback) {
if (opt.files.src.length === 0) {
return callback();
}
// Call customizr
customizr(opt, function(data) {
// Sanity check
if (!data.result) {
return stream.emit('error', new PluginError({
plugin: PLUGIN_NAME,
message: 'No data returned',
}));
}
// Save result
var file = new Vinyl({
path: path.join(firstFile.base, fileName),
base: firstFile.base,
cwd: firstFile.cwd,
contents: Buffer.from(data.result),
});
// Pass data along
stream.push(file);
return callback();
});
}
stream = through.obj(storeBuffers, generateModernizr);
return stream;
};
File diff suppressed because one or more lines are too long
+9
View File
@@ -0,0 +1,9 @@
# The MIT License (MIT)
**Copyright (c) Rod Vagg (the "Original Author") and additional contributors**
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+134
View File
@@ -0,0 +1,134 @@
# through2
[![NPM](https://nodei.co/npm/through2.png?downloads&downloadRank)](https://nodei.co/npm/through2/)
**A tiny wrapper around Node.js streams.Transform (Streams2/3) to avoid explicit subclassing noise**
Inspired by [Dominic Tarr](https://github.com/dominictarr)'s [through](https://github.com/dominictarr/through) in that it's so much easier to make a stream out of a function than it is to set up the prototype chain properly: `through(function (chunk) { ... })`.
***Note: Users of Node.js 0.10 and 0.12 should install `through2@2.x`. As of through2@3.x, readable-stream@3 is being used and is not compatible with older versions of Node.js.*** _v2.x support is being maintained on the [v2.x](https://github.com/rvagg/through2/tree/v2.x) branch._
```js
fs.createReadStream('ex.txt')
.pipe(through2(function (chunk, enc, callback) {
for (var i = 0; i < chunk.length; i++)
if (chunk[i] == 97)
chunk[i] = 122 // swap 'a' for 'z'
this.push(chunk)
callback()
}))
.pipe(fs.createWriteStream('out.txt'))
.on('finish', () => doSomethingSpecial())
```
Or object streams:
```js
var all = []
fs.createReadStream('data.csv')
.pipe(csv2())
.pipe(through2.obj(function (chunk, enc, callback) {
var data = {
name : chunk[0]
, address : chunk[3]
, phone : chunk[10]
}
this.push(data)
callback()
}))
.on('data', (data) => {
all.push(data)
})
.on('end', () => {
doSomethingSpecial(all)
})
```
Note that `through2.obj(fn)` is a convenience wrapper around `through2({ objectMode: true }, fn)`.
## API
<b><code>through2([ options, ] [ transformFunction ] [, flushFunction ])</code></b>
Consult the **[stream.Transform](http://nodejs.org/docs/latest/api/stream.html#stream_class_stream_transform)** documentation for the exact rules of the `transformFunction` (i.e. `this._transform`) and the optional `flushFunction` (i.e. `this._flush`).
### options
The options argument is optional and is passed straight through to `stream.Transform`. So you can use `objectMode:true` if you are processing non-binary streams (or just use `through2.obj()`).
The `options` argument is first, unlike standard convention, because if I'm passing in an anonymous function then I'd prefer for the options argument to not get lost at the end of the call:
```js
fs.createReadStream('/tmp/important.dat')
.pipe(through2({ objectMode: true, allowHalfOpen: false },
(chunk, enc, cb) => {
cb(null, 'wut?') // note we can use the second argument on the callback
// to provide data as an alternative to this.push('wut?')
}
)
.pipe(fs.createWriteStream('/tmp/wut.txt'))
```
### transformFunction
The `transformFunction` must have the following signature: `function (chunk, encoding, callback) {}`. A minimal implementation should call the `callback` function to indicate that the transformation is done, even if that transformation means discarding the chunk.
To queue a new chunk, call `this.push(chunk)`&mdash;this can be called as many times as required before the `callback()` if you have multiple pieces to send on.
Alternatively, you may use `callback(err, chunk)` as shorthand for emitting a single chunk or an error.
If you **do not provide a `transformFunction`** then you will get a simple pass-through stream.
### flushFunction
The optional `flushFunction` is provided as the last argument (2nd or 3rd, depending on whether you've supplied options) is called just prior to the stream ending. Can be used to finish up any processing that may be in progress.
```js
fs.createReadStream('/tmp/important.dat')
.pipe(through2(
(chunk, enc, cb) => cb(null, chunk), // transform is a noop
function (cb) { // flush function
this.push('tacking on an extra buffer to the end');
cb();
}
))
.pipe(fs.createWriteStream('/tmp/wut.txt'));
```
<b><code>through2.ctor([ options, ] transformFunction[, flushFunction ])</code></b>
Instead of returning a `stream.Transform` instance, `through2.ctor()` returns a **constructor** for a custom Transform. This is useful when you want to use the same transform logic in multiple instances.
```js
var FToC = through2.ctor({objectMode: true}, function (record, encoding, callback) {
if (record.temp != null && record.unit == "F") {
record.temp = ( ( record.temp - 32 ) * 5 ) / 9
record.unit = "C"
}
this.push(record)
callback()
})
// Create instances of FToC like so:
var converter = new FToC()
// Or:
var converter = FToC()
// Or specify/override options when you instantiate, if you prefer:
var converter = FToC({objectMode: true})
```
## See Also
- [through2-map](https://github.com/brycebaril/through2-map) - Array.prototype.map analog for streams.
- [through2-filter](https://github.com/brycebaril/through2-filter) - Array.prototype.filter analog for streams.
- [through2-reduce](https://github.com/brycebaril/through2-reduce) - Array.prototype.reduce analog for streams.
- [through2-spy](https://github.com/brycebaril/through2-spy) - Wrapper for simple stream.PassThrough spies.
- the [mississippi stream utility collection](https://github.com/maxogden/mississippi) includes `through2` as well as many more useful stream modules similar to this one
## License
**through2** is Copyright (c) Rod Vagg and additional contributors and licensed under the MIT license. All rights not explicitly granted in the MIT license are reserved. See the included LICENSE file for more details.
+64
View File
@@ -0,0 +1,64 @@
{
"_from": "through2@^3.0.1",
"_id": "through2@3.0.1",
"_inBundle": false,
"_integrity": "sha512-M96dvTalPT3YbYLaKaCuwu+j06D/8Jfib0o/PxbVt6Amhv3dUAtW6rTV1jPgJSBG83I/e04Y6xkVdVhSRhi0ww==",
"_location": "/gulp-modernizr/through2",
"_phantomChildren": {},
"_requested": {
"type": "range",
"registry": true,
"raw": "through2@^3.0.1",
"name": "through2",
"escapedName": "through2",
"rawSpec": "^3.0.1",
"saveSpec": null,
"fetchSpec": "^3.0.1"
},
"_requiredBy": [
"/gulp-modernizr"
],
"_resolved": "https://registry.npmjs.org/through2/-/through2-3.0.1.tgz",
"_shasum": "39276e713c3302edf9e388dd9c812dd3b825bd5a",
"_spec": "through2@^3.0.1",
"_where": "/srv/http/mmap_sarrebourg/user/themes/basic/node_modules/gulp-modernizr",
"author": {
"name": "Rod Vagg",
"email": "r@va.gg",
"url": "https://github.com/rvagg"
},
"bugs": {
"url": "https://github.com/rvagg/through2/issues"
},
"bundleDependencies": false,
"dependencies": {
"readable-stream": "2 || 3"
},
"deprecated": false,
"description": "A tiny wrapper around Node.js streams.Transform (Streams2/3) to avoid explicit subclassing noise",
"devDependencies": {
"bl": "~2.0.1",
"faucet": "0.0.1",
"nyc": "~13.1.0",
"stream-spigot": "~3.0.6",
"tape": "~4.9.1"
},
"homepage": "https://github.com/rvagg/through2#readme",
"keywords": [
"stream",
"streams2",
"through",
"transform"
],
"license": "MIT",
"main": "through2.js",
"name": "through2",
"repository": {
"type": "git",
"url": "git+https://github.com/rvagg/through2.git"
},
"scripts": {
"test": "nyc node test/test.js | faucet && nyc report"
},
"version": "3.0.1"
}
+95
View File
@@ -0,0 +1,95 @@
var Transform = require('readable-stream').Transform
, inherits = require('util').inherits
function DestroyableTransform(opts) {
Transform.call(this, opts)
this._destroyed = false
}
inherits(DestroyableTransform, Transform)
DestroyableTransform.prototype.destroy = function(err) {
if (this._destroyed) return
this._destroyed = true
var self = this
process.nextTick(function() {
if (err)
self.emit('error', err)
self.emit('close')
})
}
// a noop _transform function
function noop (chunk, enc, callback) {
callback(null, chunk)
}
// create a new export function, used by both the main export and
// the .ctor export, contains common logic for dealing with arguments
function through2 (construct) {
return function (options, transform, flush) {
if (typeof options == 'function') {
flush = transform
transform = options
options = {}
}
if (typeof transform != 'function')
transform = noop
if (typeof flush != 'function')
flush = null
return construct(options, transform, flush)
}
}
// main export, just make me a transform stream!
module.exports = through2(function (options, transform, flush) {
var t2 = new DestroyableTransform(options)
t2._transform = transform
if (flush)
t2._flush = flush
return t2
})
// make me a reusable prototype that I can `new`, or implicitly `new`
// with a constructor call
module.exports.ctor = through2(function (options, transform, flush) {
function Through2 (override) {
if (!(this instanceof Through2))
return new Through2(override)
this.options = Object.assign({}, options, override)
DestroyableTransform.call(this, this.options)
}
inherits(Through2, DestroyableTransform)
Through2.prototype._transform = transform
if (flush)
Through2.prototype._flush = flush
return Through2
})
module.exports.obj = through2(function (options, transform, flush) {
var t2 = new DestroyableTransform(Object.assign({ objectMode: true, highWaterMark: 16 }, options))
t2._transform = transform
if (flush)
t2._flush = flush
return t2
})
+73
View File
@@ -0,0 +1,73 @@
{
"_from": "gulp-modernizr",
"_id": "gulp-modernizr@3.2.1",
"_inBundle": false,
"_integrity": "sha512-85xYbrLeywNJyWxiAWq7BZ1XTpbRDzzU2ac6pYhgENNgJB06F2h2STlygv+/1npW4yQ+I0iErGLn64rYBGdOLQ==",
"_location": "/gulp-modernizr",
"_phantomChildren": {
"readable-stream": "2.3.6"
},
"_requested": {
"type": "tag",
"registry": true,
"raw": "gulp-modernizr",
"name": "gulp-modernizr",
"escapedName": "gulp-modernizr",
"rawSpec": "",
"saveSpec": null,
"fetchSpec": "latest"
},
"_requiredBy": [
"#DEV:/",
"#USER"
],
"_resolved": "https://registry.npmjs.org/gulp-modernizr/-/gulp-modernizr-3.2.1.tgz",
"_shasum": "d6ef4a414421752f9588a9495d70db3b32122937",
"_spec": "gulp-modernizr",
"_where": "/srv/http/mmap_sarrebourg/user/themes/basic",
"author": {
"name": "rejas",
"url": "https://github.com/rejas"
},
"bugs": {
"url": "https://github.com/rejas/gulp-modernizr/issues"
},
"bundleDependencies": false,
"dependencies": {
"customizr": "^1.2.1",
"plugin-error": "^1.0.1",
"through2": "^3.0.1",
"vinyl": "^2.2.0"
},
"deprecated": false,
"description": "Gulp wrapper for custom Modernizr builds",
"devDependencies": {
"chai": "^4.2.0",
"eslint": "^5.15.3",
"eslint-config-gulp": "^3.0.1",
"gulp": "^4.0.0",
"mocha": "^6.0.2"
},
"engines": {
"node": ">=6"
},
"homepage": "https://github.com/rejas/gulp-modernizr#readme",
"keywords": [
"gulpplugin",
"gulp",
"modernizr",
"customizr"
],
"license": "MIT",
"main": "index.js",
"name": "gulp-modernizr",
"repository": {
"type": "git",
"url": "git+https://github.com/rejas/gulp-modernizr.git"
},
"scripts": {
"lint": "eslint --fix **/*.js",
"test": "mocha test/runner.js"
},
"version": "3.2.1"
}
+17
View File
@@ -0,0 +1,17 @@
var Mocha = require('mocha');
var mocha = new Mocha({
setup: 'bdd',
reporter: process.env.TRAVIS ? 'tap' : 'spec',
slow: 5000,
timeout: 30000,
});
mocha.addFile('test/tests.js');
var runner = mocha.run();
runner.on('fail', function(test, err) {
process.stderr.write(' ' + err.toString() + '\n\n');
process.exit(1);
});
+31
View File
@@ -0,0 +1,31 @@
'use strict';
var fs = require('fs');
var assert = require('chai').assert;
var Vinyl = require('vinyl');
var modernizr = require('../');
describe('gulp-modernizr', function() {
describe('in buffer mode', function() {
it('should generate a custom Modernizr file', function(done) {
var stream = modernizr();
var TEST_PATH = __dirname + '/vanilla.js';
stream.on('data', function(file) {
assert.notEqual(-1, String(file.path).indexOf('modernizr.js'));
assert.notEqual(-1, String(file.contents).indexOf('Modernizr'));
done();
});
stream.write(new Vinyl({
path: TEST_PATH,
contents: fs.readFileSync(TEST_PATH),
}));
stream.end();
});
});
});
+299
View File
@@ -0,0 +1,299 @@
var Modernizr = window.Modernizr;
/* eslint-disable no-unused-vars */
var tests = {
standalone: {
applicationcache: Modernizr.applicationcache,
audio: Modernizr.audio,
battery: Modernizr.batteryapi,
blob: Modernizr.blobconstructor,
canvas: Modernizr.canvas,
canvastext: Modernizr.canvastext,
contenteditable: Modernizr.contenteditable,
contentsecuritypolicy: Modernizr.contentsecuritypolicy,
contextmenu: Modernizr.contextmenu,
cookies: Modernizr.cookies,
cors: Modernizr.cors,
'custom-protocol-handler': Modernizr.customprotocolhandler,
dart: Modernizr.dart,
'dataview-api': Modernizr.dataview,
draganddrop: Modernizr.draganddrop,
emoji: Modernizr.emoji,
'exif-orientation': Modernizr.exiforientation,
flash: Modernizr.flash,
'fullscreen-api': Modernizr.fullscreen,
gamepad: Modernizr.gamepads,
geolocation: Modernizr.geolocation,
hashchange: Modernizr.hashchange,
history: Modernizr.history,
ie8compat: Modernizr.ie8compat,
indexedDB: Modernizr.indexeddb,
input: Modernizr.input,
inputsearchevent: Modernizr.search,
inputtypes: Modernizr.inputtypes,
intl: Modernizr.Intl,
json: Modernizr.json,
'lists-reversed': Modernizr.olreversed,
mathml: Modernizr.mathml,
notification: Modernizr.notification,
'pagevisibility-api': Modernizr.pagevisibility,
performance: Modernizr.performance,
pointerevents: Modernizr.pointerevents,
'pointerlock-api': Modernizr.pointerlock,
postmessage: Modernizr.postmessage,
'quota-management-api': Modernizr.quotamanagement,
requestanimationframe: Modernizr.requestanimationframe,
serviceworker: Modernizr.serviceworker,
svg: Modernizr.svg,
touchevents: Modernizr.touchevents,
'typed-arrays': Modernizr.typedarrays,
'unicode-range': Modernizr.unicoderange,
unicode: Modernizr.unicode,
userdata: Modernizr.userdata,
vibration: Modernizr.vibrate,
video: Modernizr.video,
vml: Modernizr.vml,
'web-intents': Modernizr.webintents,
webanimations: Modernizr.animation,
webgl: Modernizr.webgl,
websockets: Modernizr.websockets,
},
a: {
download: Modernizr.adownload,
},
audio: {
loop: Modernizr.audioloop,
preload: Modernizr.audiopreload,
webaudio: Modernizr.webaudio,
},
battery: {
lowbattery: Modernizr.lowbattery,
},
canvas: {
todataurl: [
Modernizr['todataurljpeg'],
Modernizr['todataurlpng'],
Modernizr['todataurlwebp'],
],
},
crypto: {
getrandomvalues: Modernizr.getrandomvalues,
},
css: {
animations: Modernizr.cssanimations,
backgroundcliptext: Modernizr.backgroundcliptext,
'backgroundposition-shorthand': Modernizr.bgpositionshorthand,
'backgroundposition-xy': Modernizr.bgpositionxy,
backgroundrepeat: [
Modernizr['bgrepeatspace'],
Modernizr['bgrepeatround'],
],
backgroundsize: Modernizr.backgroundsize,
backgroundsizecover: Modernizr.bgsizecover,
borderimage: Modernizr.borderimage,
borderradius: Modernizr.borderradius,
boxshadow: Modernizr.boxshadow,
boxsizing: Modernizr.boxsizing,
calc: Modernizr.csscalc,
checked: Modernizr.checked,
columns: Modernizr.csscolumns,
cubicbezierrange: Modernizr.cubicbezierrange,
displayrunin: Modernizr['display-runin'],
displaytable: Modernizr.displaytable,
ellipsis: Modernizr.ellipsis,
escape: Modernizr.cssescape,
filters: Modernizr.cssfilters,
flexbox: Modernizr.flexbox,
flexboxlegacy: Modernizr.flexboxlegacy,
flexboxtweener: Modernizr.flexboxtweener,
flexwrap: Modernizr.flexwrap,
fontface: Modernizr.fontface,
generatedcontent: Modernizr.generatedcontent,
gradients: Modernizr.cssgradients,
hsla: Modernizr.hsla,
hyphens: [
Modernizr['csshyphens'],
Modernizr['softhyphens'],
Modernizr['softhyphensfind'],
],
lastchild: Modernizr.lastchild,
mask: Modernizr.cssmask,
mediaqueries: Modernizr.mediaqueries,
multiplebgs: Modernizr.multiplebgs,
nthchild: Modernizr.nthchild,
objectfit: Modernizr.objectfit,
opacity: Modernizr.opacity,
'overflow-scrolling': Modernizr.overflowscrolling,
pointerevents: Modernizr.csspointerevents,
positionsticky: Modernizr.csspositionsticky,
pseudoanimations: Modernizr.csspseudoanimations,
pseudotransitions: Modernizr.csspseudotransitions,
reflections: Modernizr.cssreflections,
regions: Modernizr.regions,
remunit: Modernizr.cssremunit,
resize: Modernizr.cssresize,
rgba: Modernizr.rgba,
scrollbars: Modernizr.cssscrollbar,
shapes: Modernizr.shapes,
siblinggeneral: Modernizr.siblinggeneral,
subpixelfont: Modernizr.subpixelfont,
supports: Modernizr.supports,
target: Modernizr.target,
textshadow: Modernizr.textshadow,
transforms: Modernizr.csstransforms,
transforms3d: Modernizr.csstransforms3d,
transformstylepreserve3d: Modernizr.preserve3d,
transitions: Modernizr.csstransitions,
userselect: Modernizr.userselect,
vhunit: Modernizr.cssvhunit,
vmaxunit: Modernizr.cssvmaxunit,
vminunit: Modernizr.cssvminunit,
vwunit: Modernizr.cssvwunit,
wrapflow: Modernizr.wrapflow,
},
dom: {
classlist: Modernizr.classlist,
'createElement-attrs': [
Modernizr['createelementattrs'],
Modernizr['createelement-attrs'],
],
dataset: Modernizr.dataset,
documentfragment: Modernizr.documentfragment,
microdata: Modernizr.microdata,
},
elem: {
datalist: Modernizr.datalistelem,
details: Modernizr.details,
output: Modernizr.outputelem,
'progress-meter': [
Modernizr['progressbar'],
Modernizr['meter'],
],
ruby: Modernizr.ruby,
template: Modernizr.template,
time: Modernizr.time,
track: [
Modernizr['texttrackapi'],
Modernizr['track'],
],
},
es5: {
array: Modernizr.es5array,
date: Modernizr.es5date,
function: Modernizr.es5function,
object: Modernizr.es5object,
strictmode: Modernizr.strictmode,
string: Modernizr.es5string,
},
es6: {
contains: Modernizr.contains,
promises: Modernizr.promises,
},
event: {
'deviceorientation-motion': [
Modernizr['devicemotion'],
Modernizr['deviceorientation'],
],
oninput: Modernizr.oninput,
},
file: {
api: Modernizr.filereader,
filesystem: Modernizr.filesystem,
},
forms: {
capture: Modernizr.capture,
fileinput: Modernizr.fileinput,
fileinputdirectory: Modernizr.directory,
formattribute: Modernizr.formattribute,
'inputnumber-l10n': Modernizr.localizednumber,
placeholder: Modernizr.placeholder,
requestautocomplete: Modernizr.requestautocomplete,
speechinput: Modernizr.speechinput,
validation: Modernizr.formvalidation,
},
iframe: {
sandbox: Modernizr.sandbox,
seamless: Modernizr.seamless,
srcdoc: Modernizr.srcdoc,
},
img: {
apng: Modernizr.apng,
jpegxr: Modernizr.jpegxr,
srcset: Modernizr.srcset,
'webp-alpha': Modernizr.webpalpha,
'webp-animation': Modernizr.webpanimation,
'webp-lossless': [
Modernizr['webplossless'],
Modernizr['webp-lossless'],
],
webp: Modernizr.webp,
},
input: {
formaction: Modernizr.inputformaction,
formenctype: Modernizr.inputformenctype,
},
network: {
connection: Modernizr.lowbandwidth,
eventsource: Modernizr.eventsource,
'xhr-responsetype-arraybuffer': Modernizr.xhrresponsetypearraybuffer,
'xhr-responsetype-blob': Modernizr.xhrresponsetypeblob,
'xhr-responsetype-document': Modernizr.xhrresponsetypedocument,
'xhr-responsetype-json': Modernizr.xhrresponsetypejson,
'xhr-responsetype-text': Modernizr.xhrresponsetypetext,
'xhr-responsetype': Modernizr.xhrresponsetype,
xhr2: Modernizr.xhr2,
},
script: {
async: Modernizr.scriptasync,
defer: Modernizr.scriptdefer,
},
speech: {
'speech-recognition': Modernizr.speechrecognition,
'speech-synthesis': Modernizr.speechsynthesis,
},
storage: {
localstorage: Modernizr.localstorage,
sessionstorage: Modernizr.sessionstorage,
websqldatabase: Modernizr.websqldatabase,
},
style: {
scoped: Modernizr.stylescoped,
},
svg: {
asimg: Modernizr.svgasimg,
clippaths: Modernizr.svgclippaths,
filters: Modernizr.svgfilters,
inline: Modernizr.inlinesvg,
smil: Modernizr.smil,
},
textarea: {
maxlength: Modernizr.textareamaxlength,
},
url: {
'data-uri': Modernizr.datauri,
},
video: {
autoplay: Modernizr.videoautoplay,
loop: Modernizr.videoloop,
preload: Modernizr.videopreload,
},
webgl: {
extensions: Modernizr.webglextensions,
},
webrtc: {
getusermedia: Modernizr.getusermedia,
peerconnection: Modernizr.peerconnection,
},
websockets: {
binary: Modernizr.websocketsbinary,
},
window: {
framed: Modernizr.framed,
},
workers: {
blobworkers: Modernizr.blobworkers,
dataworkers: Modernizr.dataworkers,
sharedworkers: Modernizr.sharedworkers,
webworkers: Modernizr.webworkers,
},
};