parent
6875cc33b4
commit
8380a674b9
|
@ -1,6 +1,6 @@
|
|||
/* eslint no-eq-null: 0, eqeqeq: [2, "smart"] */
|
||||
/* global createCache db calcStyleDigest db tryRegExp styleCodeEmpty
|
||||
getStyleWithNoCode msg sync uuid */
|
||||
getStyleWithNoCode msg sync uuidv4 */
|
||||
/* exported styleManager */
|
||||
'use strict';
|
||||
|
||||
|
@ -384,7 +384,7 @@ const styleManager = (() => {
|
|||
delete style.id;
|
||||
}
|
||||
if (!style._id) {
|
||||
style._id = uuid();
|
||||
style._id = uuidv4();
|
||||
}
|
||||
style._rev = Date.now();
|
||||
fixUsoMd5Issue(style);
|
||||
|
@ -523,7 +523,7 @@ const styleManager = (() => {
|
|||
function prepare() {
|
||||
const ADD_MISSING_PROPS = {
|
||||
name: style => `ID: ${style.id}`,
|
||||
_id: () => uuid(),
|
||||
_id: () => uuidv4(),
|
||||
_rev: () => Date.now()
|
||||
};
|
||||
|
||||
|
|
30
package-lock.json
generated
30
package-lock.json
generated
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "Stylus",
|
||||
"version": "1.5.8",
|
||||
"version": "1.5.9",
|
||||
"lockfileVersion": 1,
|
||||
"requires": true,
|
||||
"dependencies": {
|
||||
|
@ -3961,6 +3961,12 @@
|
|||
"remove-trailing-separator": "^1.0.1"
|
||||
}
|
||||
},
|
||||
"uuid": {
|
||||
"version": "3.4.0",
|
||||
"resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz",
|
||||
"integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==",
|
||||
"dev": true
|
||||
},
|
||||
"zip-stream": {
|
||||
"version": "1.2.0",
|
||||
"resolved": "https://registry.npmjs.org/zip-stream/-/zip-stream-1.2.0.tgz",
|
||||
|
@ -6569,6 +6575,14 @@
|
|||
"tough-cookie": "~2.5.0",
|
||||
"tunnel-agent": "^0.6.0",
|
||||
"uuid": "^3.3.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"uuid": {
|
||||
"version": "3.4.0",
|
||||
"resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz",
|
||||
"integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==",
|
||||
"dev": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"require-directory": {
|
||||
|
@ -6945,6 +6959,14 @@
|
|||
"tough-cookie": "~2.4.3",
|
||||
"tunnel-agent": "^0.6.0",
|
||||
"uuid": "^3.3.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"uuid": {
|
||||
"version": "3.4.0",
|
||||
"resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz",
|
||||
"integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==",
|
||||
"dev": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"tough-cookie": {
|
||||
|
@ -8025,9 +8047,9 @@
|
|||
"dev": true
|
||||
},
|
||||
"uuid": {
|
||||
"version": "3.4.0",
|
||||
"resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz",
|
||||
"integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==",
|
||||
"version": "7.0.0-beta.0",
|
||||
"resolved": "https://registry.npmjs.org/uuid/-/uuid-7.0.0-beta.0.tgz",
|
||||
"integrity": "sha512-Am22LVM3UXB0DTzQAeDSsZwP5eyqjIhmff330hqkxGvIxX8RRrUYLtKJ0eYxiBgjeQdUaMONpBZbJachMShxBw==",
|
||||
"dev": true
|
||||
},
|
||||
"v8-compile-cache": {
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
"sync-version": "^1.0.1",
|
||||
"tiny-glob": "^0.2.6",
|
||||
"usercss-meta": "^0.9.0",
|
||||
"uuid": "^3.4.0",
|
||||
"uuid": "^7.0.0-beta.0",
|
||||
"web-ext": "^4.1.0",
|
||||
"webext-tx-fix": "^0.3.3"
|
||||
},
|
||||
|
|
|
@ -61,7 +61,7 @@ const files = {
|
|||
'dist/db-to-cloud.min.js → db-to-cloud.min.js'
|
||||
],
|
||||
'uuid': [
|
||||
'https://bundle.run/uuid@{VERSION}/v4.js → uuid.min.js'
|
||||
'dist/umd/uuidv4.min.js → uuid.min.js'
|
||||
]
|
||||
};
|
||||
|
||||
|
@ -120,6 +120,7 @@ async function buildFiles(pkg, patterns) {
|
|||
await fse.outputFile(`vendor/${pkg}/${dest}`, content);
|
||||
fetchedFiles.push([src, dest]);
|
||||
} else {
|
||||
let dirty = false;
|
||||
for (const file of await glob(`node_modules/${pkg}/${src}`)) {
|
||||
if (dest) {
|
||||
await fse.copy(file, `vendor/${pkg}/${dest}`);
|
||||
|
@ -127,6 +128,10 @@ async function buildFiles(pkg, patterns) {
|
|||
await fse.copy(file, path.join('vendor', path.relative('node_modules', file)));
|
||||
}
|
||||
copiedFiles.push([path.relative(`node_modules/${pkg}`, file), dest]);
|
||||
dirty = true;
|
||||
}
|
||||
if (!dirty) {
|
||||
throw new Error(`Pattern ${src} matches no files`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
7
vendor/uuid/README.md
vendored
7
vendor/uuid/README.md
vendored
|
@ -1,6 +1,5 @@
|
|||
## uuid v3.4.0
|
||||
## uuid v7.0.0-beta.0
|
||||
|
||||
Following files are downloaded from HTTP:
|
||||
|
||||
* uuid.min.js: https://bundle.run/uuid@3.4.0/v4.js
|
||||
Following files are copied from npm (node_modules):
|
||||
|
||||
* uuid.min.js: dist\umd\uuidv4.min.js
|
||||
|
|
2
vendor/uuid/uuid.min.js
vendored
2
vendor/uuid/uuid.min.js
vendored
|
@ -1 +1 @@
|
|||
!function(n){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=n();else if("function"==typeof define&&define.amd)define([],n);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).uuid=n()}}(function(){return function(){return function n(e,r,t){function o(f,u){if(!r[f]){if(!e[f]){var d="function"==typeof require&&require;if(!u&&d)return d(f,!0);if(i)return i(f,!0);var a=new Error("Cannot find module '"+f+"'");throw a.code="MODULE_NOT_FOUND",a}var p=r[f]={exports:{}};e[f][0].call(p.exports,function(n){return o(e[f][1][n]||n)},p,p.exports,n,e,r,t)}return r[f].exports}for(var i="function"==typeof require&&require,f=0;f<t.length;f++)o(t[f]);return o}}()({1:[function(n,e,r){for(var t=[],o=0;o<256;++o)t[o]=(o+256).toString(16).substr(1);e.exports=function(n,e){var r=e||0,o=t;return[o[n[r++]],o[n[r++]],o[n[r++]],o[n[r++]],"-",o[n[r++]],o[n[r++]],"-",o[n[r++]],o[n[r++]],"-",o[n[r++]],o[n[r++]],"-",o[n[r++]],o[n[r++]],o[n[r++]],o[n[r++]],o[n[r++]],o[n[r++]]].join("")}},{}],2:[function(n,e,r){var t="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(t){var o=new Uint8Array(16);e.exports=function(){return t(o),o}}else{var i=new Array(16);e.exports=function(){for(var n,e=0;e<16;e++)0==(3&e)&&(n=4294967296*Math.random()),i[e]=n>>>((3&e)<<3)&255;return i}}},{}],3:[function(n,e,r){var t=n("./lib/rng"),o=n("./lib/bytesToUuid");e.exports=function(n,e,r){var i=e&&r||0;"string"==typeof n&&(e="binary"===n?new Array(16):null,n=null);var f=(n=n||{}).random||(n.rng||t)();if(f[6]=15&f[6]|64,f[8]=63&f[8]|128,e)for(var u=0;u<16;++u)e[i+u]=f[u];return e||o(f)}},{"./lib/bytesToUuid":1,"./lib/rng":2}]},{},[3])(3)});
|
||||
!function(o,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(o=o||self).uuidv4=e()}(this,(function(){"use strict";var o="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto),e=new Uint8Array(16);function r(){if(!o)throw new Error("uuid: This browser does not seem to support crypto.getRandomValues(). If you need to support this browser, please provide a custom random number generator through options.rng.");return o(e)}for(var n=[],t=0;t<256;++t)n[t]=(t+256).toString(16).substr(1);return function(o,e,t){var u=e&&t||0;"string"==typeof o&&(e="binary"===o?new Array(16):null,o=null);var i=(o=o||{}).random||(o.rng||r)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,e)for(var s=0;s<16;++s)e[u+s]=i[s];return e||function(o,e){var r=e||0,t=n;return[t[o[r++]],t[o[r++]],t[o[r++]],t[o[r++]],"-",t[o[r++]],t[o[r++]],"-",t[o[r++]],t[o[r++]],"-",t[o[r++]],t[o[r++]],"-",t[o[r++]],t[o[r++]],t[o[r++]],t[o[r++]],t[o[r++]],t[o[r++]]].join("")}(i)}}));
|
Loading…
Reference in New Issue
Block a user