diff options
| author | littleblack111 <littleblack11111@gmail.com> | 2024-05-14 14:05:49 +0800 |
|---|---|---|
| committer | littleblack111 <littleblack11111@gmail.com> | 2024-05-14 14:05:49 +0800 |
| commit | 06823fbf1c2e763a5bf76c3990ca98fbbcd98691 (patch) | |
| tree | 4280bece3888d12a022093bf1a9cd1b049393602 /node_modules/browserslist | |
| parent | 1368909b3cd552dbb0d12d5863c597f5be46177d (diff) | |
updated node_modules
Diffstat (limited to 'node_modules/browserslist')
| -rw-r--r-- | node_modules/browserslist/README.md | 8 | ||||
| -rw-r--r-- | node_modules/browserslist/index.d.ts | 1 | ||||
| -rw-r--r-- | node_modules/browserslist/index.js | 2 | ||||
| -rw-r--r-- | node_modules/browserslist/node.js | 12 | ||||
| -rw-r--r-- | node_modules/browserslist/package.json | 6 |
5 files changed, 17 insertions, 12 deletions
diff --git a/node_modules/browserslist/README.md b/node_modules/browserslist/README.md index abac4aae..f31bd2cb 100644 --- a/node_modules/browserslist/README.md +++ b/node_modules/browserslist/README.md @@ -46,13 +46,7 @@ You can check how config works at our playground: [`browsersl.ist`](https://brow <br> <br> <div align="center"> - <a href="https://evilmartians.com/?utm_source=browserslist"> - <img src="https://evilmartians.com/badges/sponsored-by-evil-martians.svg" - alt="Sponsored by Evil Martians" width="236" height="54"> - </a> <a href="https://cube.dev/?ref=eco-browserslist-github"> - <img src="https://user-images.githubusercontent.com/986756/154330861-d79ab8ec-aacb-4af8-9e17-1b28f1eccb01.svg" - alt="Supported by Cube" width="227" height="46"> - </a> + <a href="https://evilmartians.com/?utm_source=browserslist"><img src="https://evilmartians.com/badges/sponsored-by-evil-martians.svg" alt="Sponsored by Evil Martians" width="236" height="54"></a> <a href="https://cube.dev/?ref=eco-browserslist-github"><img src="https://user-images.githubusercontent.com/986756/154330861-d79ab8ec-aacb-4af8-9e17-1b28f1eccb01.svg" alt="Supported by Cube" width="227" height="46"></a> </div> [stylelint-no-unsupported-browser-features]: https://github.com/ismay/stylelint-no-unsupported-browser-features diff --git a/node_modules/browserslist/index.d.ts b/node_modules/browserslist/index.d.ts index 7f8e7605..e47c5cfe 100644 --- a/node_modules/browserslist/index.d.ts +++ b/node_modules/browserslist/index.d.ts @@ -193,6 +193,7 @@ declare global { BROWSERSLIST_ENV?: string BROWSERSLIST_IGNORE_OLD_DATA?: string BROWSERSLIST_STATS?: string + BROWSERSLIST_ROOT_PATH?: string } } } diff --git a/node_modules/browserslist/index.js b/node_modules/browserslist/index.js index 6718031a..d2fd7d1d 100644 --- a/node_modules/browserslist/index.js +++ b/node_modules/browserslist/index.js @@ -893,7 +893,7 @@ var QUERIES = { }, supports: { matches: ['supportType', 'feature'], - regexp: /^(?:(fully|partially) )?supports\s+([\w-]+)$/, + regexp: /^(?:(fully|partially)\s+)?supports\s+([\w-]+)$/, select: function (context, node) { env.loadFeature(browserslist.cache, node.feature) var withPartial = node.supportType !== 'fully' diff --git a/node_modules/browserslist/node.js b/node_modules/browserslist/node.js index 100ded66..a935371d 100644 --- a/node_modules/browserslist/node.js +++ b/node_modules/browserslist/node.js @@ -7,7 +7,7 @@ var BrowserslistError = require('./error') var IS_SECTION = /^\s*\[(.+)]\s*$/ var CONFIG_PATTERN = /^browserslist-config-/ -var SCOPED_CONFIG__PATTERN = /@[^/]+\/browserslist-config(-|$|\/)/ +var SCOPED_CONFIG__PATTERN = /@[^/]+(?:\/[^/]+)?\/browserslist-config(?:-|$|\/)/ var TIME_TO_UPDATE_CANIUSE = 6 * 30 * 24 * 60 * 60 * 1000 var FORMAT = 'Browserslist config should be a string or an array ' + @@ -50,12 +50,22 @@ function eachParent(file, callback) { var dir = isFile(file) ? path.dirname(file) : file var loc = path.resolve(dir) do { + if (!pathInRoot(loc)) break; var result = callback(loc) if (typeof result !== 'undefined') return result } while (loc !== (loc = path.dirname(loc))) return undefined } +function pathInRoot(p) { + if (!process.env.BROWSERSLIST_ROOT_PATH) return true + var rootPath = path.resolve(process.env.BROWSERSLIST_ROOT_PATH); + if (path.relative(rootPath, p).substring(0,2) === '..') { + return false; + } + return true +} + function check(section) { if (Array.isArray(section)) { for (var i = 0; i < section.length; i++) { diff --git a/node_modules/browserslist/package.json b/node_modules/browserslist/package.json index 55225bea..b8e17688 100644 --- a/node_modules/browserslist/package.json +++ b/node_modules/browserslist/package.json @@ -1,6 +1,6 @@ { "name": "browserslist", - "version": "4.22.2", + "version": "4.23.0", "description": "Share target browsers between different front-end tools, like Autoprefixer, Stylelint and babel-env-preset", "keywords": [ "caniuse", @@ -25,8 +25,8 @@ "license": "MIT", "repository": "browserslist/browserslist", "dependencies": { - "caniuse-lite": "^1.0.30001565", - "electron-to-chromium": "^1.4.601", + "caniuse-lite": "^1.0.30001587", + "electron-to-chromium": "^1.4.668", "node-releases": "^2.0.14", "update-browserslist-db": "^1.0.13" }, |
