forked from enviPath/enviPy
Current Dev State
This commit is contained in:
52
static/js/ketcher2/node_modules/gulp-autoprefixer/index.js
generated
vendored
Normal file
52
static/js/ketcher2/node_modules/gulp-autoprefixer/index.js
generated
vendored
Normal file
@ -0,0 +1,52 @@
|
||||
'use strict';
|
||||
const gutil = require('gulp-util');
|
||||
const through = require('through2');
|
||||
const applySourceMap = require('vinyl-sourcemaps-apply');
|
||||
const autoprefixer = require('autoprefixer');
|
||||
const postcss = require('postcss');
|
||||
|
||||
module.exports = opts => {
|
||||
return through.obj((file, enc, cb) => {
|
||||
if (file.isNull()) {
|
||||
cb(null, file);
|
||||
return;
|
||||
}
|
||||
|
||||
if (file.isStream()) {
|
||||
cb(new gutil.PluginError('gulp-autoprefixer', 'Streaming not supported'));
|
||||
return;
|
||||
}
|
||||
|
||||
postcss(autoprefixer(opts)).process(file.contents.toString(), {
|
||||
map: file.sourceMap ? {annotation: false} : false,
|
||||
from: file.path,
|
||||
to: file.path
|
||||
}).then(res => {
|
||||
file.contents = Buffer.from(res.css);
|
||||
|
||||
if (res.map && file.sourceMap) {
|
||||
applySourceMap(file, res.map.toString());
|
||||
}
|
||||
|
||||
const warnings = res.warnings();
|
||||
|
||||
if (warnings.length > 0) {
|
||||
gutil.log('gulp-autoprefixer:', '\n ' + warnings.join('\n '));
|
||||
}
|
||||
|
||||
setImmediate(cb, null, file);
|
||||
}).catch(err => {
|
||||
const cssError = err.name === 'CssSyntaxError';
|
||||
|
||||
if (cssError) {
|
||||
err.message += err.showSourceCode();
|
||||
}
|
||||
|
||||
// Prevent stream unhandled exception from being suppressed by Promise
|
||||
setImmediate(cb, new gutil.PluginError('gulp-autoprefixer', err, {
|
||||
fileName: file.path,
|
||||
showStack: !cssError
|
||||
}));
|
||||
});
|
||||
});
|
||||
};
|
||||
21
static/js/ketcher2/node_modules/gulp-autoprefixer/license
generated
vendored
Normal file
21
static/js/ketcher2/node_modules/gulp-autoprefixer/license
generated
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
|
||||
|
||||
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.
|
||||
77
static/js/ketcher2/node_modules/gulp-autoprefixer/package.json
generated
vendored
Normal file
77
static/js/ketcher2/node_modules/gulp-autoprefixer/package.json
generated
vendored
Normal file
@ -0,0 +1,77 @@
|
||||
{
|
||||
"_from": "gulp-autoprefixer@4.0.0",
|
||||
"_id": "gulp-autoprefixer@4.0.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-4AqMVxuF0GUWrCY0G+kN/Z/B6rA=",
|
||||
"_location": "/gulp-autoprefixer",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "version",
|
||||
"registry": true,
|
||||
"raw": "gulp-autoprefixer@4.0.0",
|
||||
"name": "gulp-autoprefixer",
|
||||
"escapedName": "gulp-autoprefixer",
|
||||
"rawSpec": "4.0.0",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "4.0.0"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"#DEV:/"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/gulp-autoprefixer/-/gulp-autoprefixer-4.0.0.tgz",
|
||||
"_shasum": "e00a8c571b85d06516ac26341be90dfd9fc1eab0",
|
||||
"_spec": "gulp-autoprefixer@4.0.0",
|
||||
"_where": "/home/manfred/enviPath/ketcher2/ketcher",
|
||||
"author": {
|
||||
"name": "Sindre Sorhus",
|
||||
"email": "sindresorhus@gmail.com",
|
||||
"url": "sindresorhus.com"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/sindresorhus/gulp-autoprefixer/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {
|
||||
"autoprefixer": "^7.0.0",
|
||||
"gulp-util": "^3.0.0",
|
||||
"postcss": "^6.0.1",
|
||||
"through2": "^2.0.0",
|
||||
"vinyl-sourcemaps-apply": "^0.2.0"
|
||||
},
|
||||
"deprecated": false,
|
||||
"description": "Prefix CSS",
|
||||
"devDependencies": {
|
||||
"ava": "*",
|
||||
"gulp-sourcemaps": "^2.6.0",
|
||||
"p-event": "^1.1.0",
|
||||
"xo": "*"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=4.5"
|
||||
},
|
||||
"files": [
|
||||
"index.js"
|
||||
],
|
||||
"homepage": "https://github.com/sindresorhus/gulp-autoprefixer#readme",
|
||||
"keywords": [
|
||||
"gulpplugin",
|
||||
"autoprefixer",
|
||||
"postcss",
|
||||
"css",
|
||||
"prefix",
|
||||
"prefixes",
|
||||
"stylesheet",
|
||||
"preprocess",
|
||||
"postcss-runner"
|
||||
],
|
||||
"license": "MIT",
|
||||
"name": "gulp-autoprefixer",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/sindresorhus/gulp-autoprefixer.git"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "xo && ava"
|
||||
},
|
||||
"version": "4.0.0"
|
||||
}
|
||||
79
static/js/ketcher2/node_modules/gulp-autoprefixer/readme.md
generated
vendored
Normal file
79
static/js/ketcher2/node_modules/gulp-autoprefixer/readme.md
generated
vendored
Normal file
@ -0,0 +1,79 @@
|
||||
# gulp-autoprefixer [](https://travis-ci.org/sindresorhus/gulp-autoprefixer)
|
||||
|
||||
> Prefix CSS with [Autoprefixer](https://github.com/postcss/autoprefixer)
|
||||
|
||||
*Issues with the output should be reported on the Autoprefixer [issue tracker](https://github.com/postcss/autoprefixer/issues).*
|
||||
|
||||
|
||||
---
|
||||
|
||||
<p align="center">👾</p>
|
||||
<p align="center"><b>Improve your JavaScript skills with this awesome <a href="https://ES6.io/friend/AWESOME">ES6 course</a> by Wes Bos.</b><br>Try his free <a href="https://javascript30.com/friend/AWESOME">JavaScript 30 course</a> for a taste of what to expect. You might also like his <a href="https://ReactForBeginners.com/friend/AWESOME">React</a> & <a href="https://SublimeTextBook.com/friend/AWESOME">Sublime</a> course.</p>
|
||||
|
||||
---
|
||||
|
||||
|
||||
## Install
|
||||
|
||||
```
|
||||
$ npm install --save-dev gulp-autoprefixer
|
||||
```
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
const gulp = require('gulp');
|
||||
const autoprefixer = require('gulp-autoprefixer');
|
||||
|
||||
gulp.task('default', () =>
|
||||
gulp.src('src/app.css')
|
||||
.pipe(autoprefixer({
|
||||
browsers: ['last 2 versions'],
|
||||
cascade: false
|
||||
}))
|
||||
.pipe(gulp.dest('dist'))
|
||||
);
|
||||
```
|
||||
|
||||
|
||||
## API
|
||||
|
||||
### autoprefixer([options])
|
||||
|
||||
#### options
|
||||
|
||||
Type: `Object`
|
||||
|
||||
See the Autoprefixer [options](https://github.com/postcss/autoprefixer#options).
|
||||
|
||||
|
||||
## Source Maps
|
||||
|
||||
Use [gulp-sourcemaps](https://github.com/gulp-sourcemaps/gulp-sourcemaps) like this:
|
||||
|
||||
```js
|
||||
const gulp = require('gulp');
|
||||
const sourcemaps = require('gulp-sourcemaps');
|
||||
const autoprefixer = require('gulp-autoprefixer');
|
||||
const concat = require('gulp-concat');
|
||||
|
||||
gulp.task('default', () =>
|
||||
gulp.src('src/**/*.css')
|
||||
.pipe(sourcemaps.init())
|
||||
.pipe(autoprefixer())
|
||||
.pipe(concat('all.css'))
|
||||
.pipe(sourcemaps.write('.'))
|
||||
.pipe(gulp.dest('dist'))
|
||||
);
|
||||
```
|
||||
|
||||
|
||||
## Tip
|
||||
|
||||
If you use other PostCSS based tools, like `cssnano`, you may want to run them together using [`gulp-postcss`](https://github.com/postcss/autoprefixer#gulp) instead of `gulp-autoprefixer`. It will be faster, as the CSS is parsed only once for all PostCSS based tools, including Autoprefixer.
|
||||
|
||||
|
||||
## License
|
||||
|
||||
MIT © [Sindre Sorhus](https://sindresorhus.com)
|
||||
Reference in New Issue
Block a user