This commit is contained in:
2023-08-11 10:45:20 +08:00
commit 161ca982f3
31850 changed files with 2706500 additions and 0 deletions

22
node_modules/cssnano/LICENSE-MIT generated vendored Normal file
View File

@ -0,0 +1,22 @@
Copyright (c) Ben Briggs <beneb.info@gmail.com> (http://beneb.info)
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.

6
node_modules/cssnano/README.md generated vendored Normal file
View File

@ -0,0 +1,6 @@
# cssnano
For documentation, please see the following links:
* Repository: https://github.com/cssnano/cssnano
* Website: http://cssnano.co

82
node_modules/cssnano/package.json generated vendored Normal file
View File

@ -0,0 +1,82 @@
{
"_from": "cssnano@^5.0.0",
"_id": "cssnano@5.1.15",
"_inBundle": false,
"_integrity": "sha512-j+BKgDcLDQA+eDifLx0EO4XSA56b7uut3BQFH+wbSaSTuGLuiyTa/wbRYthUXX8LC9mLg+WWKe8h+qJuwTAbHw==",
"_location": "/cssnano",
"_phantomChildren": {},
"_requested": {
"type": "range",
"registry": true,
"raw": "cssnano@^5.0.0",
"name": "cssnano",
"escapedName": "cssnano",
"rawSpec": "^5.0.0",
"saveSpec": null,
"fetchSpec": "^5.0.0"
},
"_requiredBy": [
"/@vue/cli-service",
"/css-minimizer-webpack-plugin"
],
"_resolved": "https://registry.npmjs.org/cssnano/-/cssnano-5.1.15.tgz",
"_shasum": "ded66b5480d5127fcb44dac12ea5a983755136bf",
"_spec": "cssnano@^5.0.0",
"_where": "C:\\Users\\zhouxueli\\Desktop\\scheduling-app\\node_modules\\@vue\\cli-service",
"author": {
"name": "Ben Briggs",
"email": "beneb.info@gmail.com",
"url": "http://beneb.info"
},
"bugs": {
"url": "https://github.com/cssnano/cssnano/issues"
},
"bundleDependencies": false,
"dependencies": {
"cssnano-preset-default": "^5.2.14",
"lilconfig": "^2.0.3",
"yaml": "^1.10.2"
},
"deprecated": false,
"description": "A modular minifier, built on top of the PostCSS ecosystem.",
"devDependencies": {
"autoprefixer": "^10.4.12",
"cssnano-preset-advanced": "^5.3.10",
"cssnano-preset-lite": "^2.1.3",
"postcss": "^8.2.15"
},
"engines": {
"node": "^10 || ^12 || >=14.0"
},
"files": [
"src",
"LICENSE-MIT",
"types"
],
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/cssnano"
},
"homepage": "https://github.com/cssnano/cssnano",
"keywords": [
"css",
"compress",
"minify",
"optimise",
"optimisation",
"postcss",
"postcss-plugin"
],
"license": "MIT",
"main": "src/index.js",
"name": "cssnano",
"peerDependencies": {
"postcss": "^8.2.15"
},
"repository": {
"type": "git",
"url": "git+https://github.com/cssnano/cssnano.git"
},
"types": "types/index.d.ts",
"version": "5.1.15"
}

171
node_modules/cssnano/src/index.js generated vendored Normal file
View File

@ -0,0 +1,171 @@
'use strict';
const path = require('path');
/** @type {any} */
const postcss = require('postcss');
const yaml = require('yaml');
const { lilconfigSync } = require('lilconfig');
const cssnano = 'cssnano';
/** @typedef {{preset?: any, plugins?: any[], configFile?: string}} Options */
/**
* @param {string} moduleId
* @returns {boolean}
*/
function isResolvable(moduleId) {
try {
require.resolve(moduleId);
return true;
} catch (e) {
return false;
}
}
/**
* preset can be one of four possibilities:
* preset = 'default'
* preset = ['default', {}]
* preset = function <- to be invoked
* preset = {plugins: []} <- already invoked function
*
* @param {any} preset
* @return {[import('postcss').PluginCreator<any>, boolean | Record<string, any> | undefined][]}}
*/
function resolvePreset(preset) {
let fn, options;
if (Array.isArray(preset)) {
fn = preset[0];
options = preset[1];
} else {
fn = preset;
options = {};
}
// For JS setups where we invoked the preset already
if (preset.plugins) {
return preset.plugins;
}
// Provide an alias for the default preset, as it is built-in.
if (fn === 'default') {
return require('cssnano-preset-default')(options).plugins;
}
// For non-JS setups; we'll need to invoke the preset ourselves.
if (typeof fn === 'function') {
return fn(options).plugins;
}
// Try loading a preset from node_modules
if (isResolvable(fn)) {
return require(fn)(options).plugins;
}
const sugar = `cssnano-preset-${fn}`;
// Try loading a preset from node_modules (sugar)
if (isResolvable(sugar)) {
return require(sugar)(options).plugins;
}
// If all else fails, we probably have a typo in the config somewhere
throw new Error(
`Cannot load preset "${fn}". Please check your configuration for errors and try again.`
);
}
/**
* cssnano will look for configuration firstly as options passed
* directly to it, and failing this it will use lilconfig to
* load an external file.
* @param {Options} options
*/
function resolveConfig(options) {
if (options.preset) {
return resolvePreset(options.preset);
}
/** @type {string | undefined} */
let searchPath = process.cwd();
let configPath = undefined;
if (options.configFile) {
searchPath = undefined;
configPath = path.resolve(process.cwd(), options.configFile);
}
const configExplorer = lilconfigSync(cssnano, {
searchPlaces: [
'package.json',
'.cssnanorc',
'.cssnanorc.json',
'.cssnanorc.yaml',
'.cssnanorc.yml',
'.cssnanorc.js',
'cssnano.config.js',
],
loaders: {
'.yaml': (filepath, content) => yaml.parse(content),
'.yml': (filepath, content) => yaml.parse(content),
},
});
const config = configPath
? configExplorer.load(configPath)
: configExplorer.search(searchPath);
if (config === null) {
return resolvePreset('default');
}
return resolvePreset(config.config.preset || config.config);
}
/**
* @type {import('postcss').PluginCreator<Options>}
* @param {Options=} options
* @return {import('postcss').Processor}
*/
function cssnanoPlugin(options = {}) {
if (Array.isArray(options.plugins)) {
if (!options.preset || !options.preset.plugins) {
options.preset = { plugins: [] };
}
options.plugins.forEach((plugin) => {
if (Array.isArray(plugin)) {
const [pluginDef, opts = {}] = plugin;
if (typeof pluginDef === 'string' && isResolvable(pluginDef)) {
options.preset.plugins.push([require(pluginDef), opts]);
} else {
options.preset.plugins.push([pluginDef, opts]);
}
} else if (typeof plugin === 'string' && isResolvable(plugin)) {
options.preset.plugins.push([require(plugin), {}]);
} else {
options.preset.plugins.push([plugin, {}]);
}
});
}
const plugins = [];
const nanoPlugins = resolveConfig(options);
for (const nanoPlugin of nanoPlugins) {
if (Array.isArray(nanoPlugin)) {
const [processor, opts] = nanoPlugin;
if (
typeof opts === 'undefined' ||
(typeof opts === 'object' && !opts.exclude) ||
(typeof opts === 'boolean' && opts === true)
) {
plugins.push(processor(opts));
}
} else {
plugins.push(nanoPlugin);
}
}
return postcss(plugins);
}
cssnanoPlugin.postcss = true;
module.exports = cssnanoPlugin;

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

16
node_modules/cssnano/types/index.d.ts generated vendored Normal file
View File

@ -0,0 +1,16 @@
export = cssnanoPlugin;
/**
* @type {import('postcss').PluginCreator<Options>}
* @param {Options=} options
* @return {import('postcss').Processor}
*/
declare function cssnanoPlugin(options?: Options | undefined): import('postcss').Processor;
declare namespace cssnanoPlugin {
export { postcss, Options };
}
type Options = {
preset?: any;
plugins?: any[];
configFile?: string;
};
declare var postcss: true;