@metamask/snaps-execution-environments 0.33.1-flask.1 → 0.34.1-flask.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +55 -45
- package/dist/browserify/iframe/bundle.js +1581 -1383
- package/dist/browserify/node-process/bundle.js +1177 -555
- package/dist/browserify/node-thread/bundle.js +1177 -555
- package/dist/browserify/offscreen/bundle.js +812 -346
- package/dist/browserify/worker-executor/bundle.js +1582 -1384
- package/dist/browserify/worker-pool/bundle.js +814 -348
- package/dist/common/BaseSnapExecutor.js +11 -4
- package/dist/common/BaseSnapExecutor.js.map +1 -1
- package/dist/common/globalEvents.d.ts +1 -0
- package/dist/common/validation.d.ts +1 -1
- package/package.json +12 -11
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
LavaPack.loadBundle([
|
|
2
|
-
[1, {"readable-stream":
|
|
2
|
+
[1, {"readable-stream":35}, function(){
|
|
3
3
|
with (this.scopeTerminator) {
|
|
4
4
|
with (this.globalThis) {
|
|
5
5
|
return function() {
|
|
6
6
|
'use strict';
|
|
7
|
-
// source: /home/runner/work/snaps
|
|
7
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/dist/BasePostMessageStream.js
|
|
8
8
|
return function (require, module, exports) {
|
|
9
9
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.BasePostMessageStream=void 0;const readable_stream_1=require("readable-stream"),noop=()=>{},SYN="SYN",ACK="ACK";class BasePostMessageStream extends readable_stream_1.Duplex{constructor(){super({objectMode:!0}),this._init=!1,this._haveSyn=!1}_handshake(){this._write(SYN,null,noop),this.cork()}_onData(e){if(this._init)try{this.push(e)}catch(e){this.emit("error",e)}else e===SYN?(this._haveSyn=!0,this._write(ACK,null,noop)):e===ACK&&(this._init=!0,this._haveSyn||this._write(ACK,null,noop),this.uncork())}_read(){}_write(e,s,t){this._postMessage(e),t()}}exports.BasePostMessageStream=BasePostMessageStream;
|
|
10
10
|
|
|
@@ -18,7 +18,7 @@ LavaPack.loadBundle([
|
|
|
18
18
|
with (this.globalThis) {
|
|
19
19
|
return function() {
|
|
20
20
|
'use strict';
|
|
21
|
-
// source: /home/runner/work/snaps
|
|
21
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/dist/WebWorker/WebWorkerParentPostMessageStream.js
|
|
22
22
|
return function (require, module, exports) {
|
|
23
23
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.WebWorkerParentPostMessageStream=void 0;const BasePostMessageStream_1=require("../BasePostMessageStream"),utils_1=require("../utils");class WebWorkerParentPostMessageStream extends BasePostMessageStream_1.BasePostMessageStream{constructor({worker:e}){super(),this._target=utils_1.DEDICATED_WORKER_NAME,this._worker=e,this._worker.onmessage=this._onMessage.bind(this),this._handshake()}_postMessage(e){this._worker.postMessage({target:this._target,data:e})}_onMessage(e){const s=e.data;(0,utils_1.isValidStreamMessage)(s)&&this._onData(s.data)}_destroy(){this._worker.onmessage=null,this._worker=null}}exports.WebWorkerParentPostMessageStream=WebWorkerParentPostMessageStream;
|
|
24
24
|
|
|
@@ -32,7 +32,7 @@ LavaPack.loadBundle([
|
|
|
32
32
|
with (this.globalThis) {
|
|
33
33
|
return function() {
|
|
34
34
|
'use strict';
|
|
35
|
-
// source: /home/runner/work/snaps
|
|
35
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/dist/WebWorker/WebWorkerPostMessageStream.js
|
|
36
36
|
return function (require, module, exports) {
|
|
37
37
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.WebWorkerPostMessageStream=void 0;const BasePostMessageStream_1=require("../BasePostMessageStream"),utils_1=require("../utils");class WebWorkerPostMessageStream extends BasePostMessageStream_1.BasePostMessageStream{constructor(){if("undefined"==typeof self||"undefined"==typeof WorkerGlobalScope)throw new Error("WorkerGlobalScope not found. This class should only be instantiated in a WebWorker.");super(),this._name=utils_1.DEDICATED_WORKER_NAME,self.addEventListener("message",this._onMessage.bind(this)),this._handshake()}_postMessage(e){self.postMessage({data:e})}_onMessage(e){const s=e.data;(0,utils_1.isValidStreamMessage)(s)&&s.target===this._name&&this._onData(s.data)}_destroy(){}}exports.WebWorkerPostMessageStream=WebWorkerPostMessageStream;
|
|
38
38
|
|
|
@@ -46,7 +46,7 @@ LavaPack.loadBundle([
|
|
|
46
46
|
with (this.globalThis) {
|
|
47
47
|
return function() {
|
|
48
48
|
'use strict';
|
|
49
|
-
// source: /home/runner/work/snaps
|
|
49
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/dist/browser.js
|
|
50
50
|
return function (require, module, exports) {
|
|
51
51
|
"use strict";var __createBinding=this&&this.__createBinding||(Object.create?function(e,r,t,o){void 0===o&&(o=t),Object.defineProperty(e,o,{enumerable:!0,get:function(){return r[t]}})}:function(e,r,t,o){void 0===o&&(o=t),e[o]=r[t]}),__exportStar=this&&this.__exportStar||function(e,r){for(var t in e)"default"===t||Object.prototype.hasOwnProperty.call(r,t)||__createBinding(r,e,t)};Object.defineProperty(exports,"__esModule",{value:!0}),__exportStar(require("./window/WindowPostMessageStream"),exports),__exportStar(require("./WebWorker/WebWorkerPostMessageStream"),exports),__exportStar(require("./WebWorker/WebWorkerParentPostMessageStream"),exports),__exportStar(require("./runtime/BrowserRuntimePostMessageStream"),exports),__exportStar(require("./BasePostMessageStream"),exports);
|
|
52
52
|
|
|
@@ -60,7 +60,7 @@ LavaPack.loadBundle([
|
|
|
60
60
|
with (this.globalThis) {
|
|
61
61
|
return function() {
|
|
62
62
|
'use strict';
|
|
63
|
-
// source: /home/runner/work/snaps
|
|
63
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/dist/runtime/BrowserRuntimePostMessageStream.js
|
|
64
64
|
return function (require, module, exports) {
|
|
65
65
|
"use strict";var _BrowserRuntimePostMessageStream_name,_BrowserRuntimePostMessageStream_target,__classPrivateFieldSet=this&&this.__classPrivateFieldSet||function(e,s,t,r,a){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!a)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof s?e!==s||!a:!s.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?a.call(e,t):a?a.value=t:s.set(e,t),t},__classPrivateFieldGet=this&&this.__classPrivateFieldGet||function(e,s,t,r){if("a"===t&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof s?e!==s||!r:!s.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===t?r:"a"===t?r.call(e):r?r.value:s.get(e)};Object.defineProperty(exports,"__esModule",{value:!0}),exports.BrowserRuntimePostMessageStream=void 0;const BasePostMessageStream_1=require("../BasePostMessageStream"),utils_1=require("../utils");class BrowserRuntimePostMessageStream extends BasePostMessageStream_1.BasePostMessageStream{constructor({name:e,target:s}){super(),_BrowserRuntimePostMessageStream_name.set(this,void 0),_BrowserRuntimePostMessageStream_target.set(this,void 0),__classPrivateFieldSet(this,_BrowserRuntimePostMessageStream_name,e,"f"),__classPrivateFieldSet(this,_BrowserRuntimePostMessageStream_target,s,"f"),this._onMessage=this._onMessage.bind(this),this._getRuntime().onMessage.addListener(this._onMessage),this._handshake()}_postMessage(e){this._getRuntime().sendMessage({target:__classPrivateFieldGet(this,_BrowserRuntimePostMessageStream_target,"f"),data:e})}_onMessage(e){(0,utils_1.isValidStreamMessage)(e)&&e.target===__classPrivateFieldGet(this,_BrowserRuntimePostMessageStream_name,"f")&&this._onData(e.data)}_getRuntime(){var e,s;if("chrome"in globalThis&&"function"==typeof(null===(e=null===chrome||void 0===chrome?void 0:chrome.runtime)||void 0===e?void 0:e.sendMessage))return chrome.runtime;if("browser"in globalThis&&"function"==typeof(null===(s=null===browser||void 0===browser?void 0:browser.runtime)||void 0===s?void 0:s.sendMessage))return browser.runtime;throw new Error("browser.runtime.sendMessage is not a function. This class should only be instantiated in a web extension.")}_destroy(){this._getRuntime().onMessage.removeListener(this._onMessage)}}exports.BrowserRuntimePostMessageStream=BrowserRuntimePostMessageStream,_BrowserRuntimePostMessageStream_name=new WeakMap,_BrowserRuntimePostMessageStream_target=new WeakMap;
|
|
66
66
|
|
|
@@ -69,12 +69,12 @@ LavaPack.loadBundle([
|
|
|
69
69
|
}
|
|
70
70
|
}
|
|
71
71
|
}, {package:"@metamask/post-message-stream",file:"../../node_modules/@metamask/post-message-stream/dist/runtime/BrowserRuntimePostMessageStream.js",}],
|
|
72
|
-
[6, {"@metamask/utils":
|
|
72
|
+
[6, {"@metamask/utils":16}, function(){
|
|
73
73
|
with (this.scopeTerminator) {
|
|
74
74
|
with (this.globalThis) {
|
|
75
75
|
return function() {
|
|
76
76
|
'use strict';
|
|
77
|
-
// source: /home/runner/work/snaps
|
|
77
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/dist/utils.js
|
|
78
78
|
return function (require, module, exports) {
|
|
79
79
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.isValidStreamMessage=exports.DEDICATED_WORKER_NAME=void 0;const utils_1=require("@metamask/utils");function isValidStreamMessage(e){return(0,utils_1.isObject)(e)&&Boolean(e.data)&&("number"==typeof e.data||"object"==typeof e.data||"string"==typeof e.data)}exports.DEDICATED_WORKER_NAME="dedicatedWorker",exports.isValidStreamMessage=isValidStreamMessage;
|
|
80
80
|
|
|
@@ -83,12 +83,12 @@ LavaPack.loadBundle([
|
|
|
83
83
|
}
|
|
84
84
|
}
|
|
85
85
|
}, {package:"@metamask/post-message-stream",file:"../../node_modules/@metamask/post-message-stream/dist/utils.js",}],
|
|
86
|
-
[7, {"../BasePostMessageStream":1,"../utils":6,"@metamask/utils":
|
|
86
|
+
[7, {"../BasePostMessageStream":1,"../utils":6,"@metamask/utils":16}, function(){
|
|
87
87
|
with (this.scopeTerminator) {
|
|
88
88
|
with (this.globalThis) {
|
|
89
89
|
return function() {
|
|
90
90
|
'use strict';
|
|
91
|
-
// source: /home/runner/work/snaps
|
|
91
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/dist/window/WindowPostMessageStream.js
|
|
92
92
|
return function (require, module, exports) {
|
|
93
93
|
"use strict";var _a,_b;Object.defineProperty(exports,"__esModule",{value:!0}),exports.WindowPostMessageStream=void 0;const utils_1=require("@metamask/utils"),BasePostMessageStream_1=require("../BasePostMessageStream"),utils_2=require("../utils"),getSource=null===(_a=Object.getOwnPropertyDescriptor(MessageEvent.prototype,"source"))||void 0===_a?void 0:_a.get;(0,utils_1.assert)(getSource,"MessageEvent.prototype.source getter is not defined.");const getOrigin=null===(_b=Object.getOwnPropertyDescriptor(MessageEvent.prototype,"origin"))||void 0===_b?void 0:_b.get;(0,utils_1.assert)(getOrigin,"MessageEvent.prototype.origin getter is not defined.");class WindowPostMessageStream extends BasePostMessageStream_1.BasePostMessageStream{constructor({name:e,target:t,targetOrigin:s=location.origin,targetWindow:i=window}){if(super(),"undefined"==typeof window||"function"!=typeof window.postMessage)throw new Error("window.postMessage is not a function. This class should only be instantiated in a Window.");this._name=e,this._target=t,this._targetOrigin=s,this._targetWindow=i,this._onMessage=this._onMessage.bind(this),window.addEventListener("message",this._onMessage,!1),this._handshake()}_postMessage(e){this._targetWindow.postMessage({target:this._target,data:e},this._targetOrigin)}_onMessage(e){const t=e.data;"*"!==this._targetOrigin&&getOrigin.call(e)!==this._targetOrigin||getSource.call(e)!==this._targetWindow||!(0,utils_2.isValidStreamMessage)(t)||t.target!==this._name||this._onData(t.data)}_destroy(){window.removeEventListener("message",this._onMessage,!1)}}exports.WindowPostMessageStream=WindowPostMessageStream;
|
|
94
94
|
|
|
@@ -97,12 +97,266 @@ LavaPack.loadBundle([
|
|
|
97
97
|
}
|
|
98
98
|
}
|
|
99
99
|
}, {package:"@metamask/post-message-stream",file:"../../node_modules/@metamask/post-message-stream/dist/window/WindowPostMessageStream.js",}],
|
|
100
|
-
[8, {"
|
|
100
|
+
[8, {"superstruct":142}, function(){
|
|
101
101
|
with (this.scopeTerminator) {
|
|
102
102
|
with (this.globalThis) {
|
|
103
103
|
return function() {
|
|
104
104
|
'use strict';
|
|
105
|
-
// source: /home/runner/work/snaps
|
|
105
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/assert.js
|
|
106
|
+
return function (require, module, exports) {
|
|
107
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.assertExhaustive=exports.assertStruct=exports.assert=exports.AssertionError=void 0;const superstruct_1=require("superstruct");function isErrorWithMessage(r){return"object"==typeof r&&null!==r&&"message"in r}function isConstructable(r){var s,t;return Boolean("string"==typeof(null===(t=null===(s=null==r?void 0:r.prototype)||void 0===s?void 0:s.constructor)||void 0===t?void 0:t.name))}function getErrorMessage(r){const s=isErrorWithMessage(r)?r.message:String(r);return s.endsWith(".")?s.slice(0,-1):s}function getError(r,s){return isConstructable(r)?new r({message:s}):r({message:s})}class AssertionError extends Error{constructor(r){super(r.message),this.code="ERR_ASSERTION"}}function assert(r,s="Assertion failed.",t=AssertionError){if(!r){if(s instanceof Error)throw s;throw getError(t,s)}}function assertStruct(r,s,t="Assertion failed",e=AssertionError){try{(0,superstruct_1.assert)(r,s)}catch(r){throw getError(e,`${t}: ${getErrorMessage(r)}.`)}}function assertExhaustive(r){throw new Error("Invalid branch reached. Should be detected during compilation.")}exports.AssertionError=AssertionError,exports.assert=assert,exports.assertStruct=assertStruct,exports.assertExhaustive=assertExhaustive;
|
|
108
|
+
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/assert.js",}],
|
|
114
|
+
[9, {"./assert":8,"superstruct":142}, function(){
|
|
115
|
+
with (this.scopeTerminator) {
|
|
116
|
+
with (this.globalThis) {
|
|
117
|
+
return function() {
|
|
118
|
+
'use strict';
|
|
119
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/base64.js
|
|
120
|
+
return function (require, module, exports) {
|
|
121
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.base64=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert"),base64=(e,r={})=>{var s,t;const a=null!==(s=r.paddingRequired)&&void 0!==s&&s,u=null!==(t=r.characterSet)&&void 0!==t?t:"base64";let n,i;return"base64"===u?n=String.raw`[A-Za-z0-9+\/]`:((0,assert_1.assert)("base64url"===u),n=String.raw`[-_A-Za-z0-9]`),i=a?new RegExp(`^(?:${n}{4})*(?:${n}{3}=|${n}{2}==)?$`,"u"):new RegExp(`^(?:${n}{4})*(?:${n}{2,3}|${n}{3}=|${n}{2}==)?$`,"u"),(0,superstruct_1.pattern)(e,i)};exports.base64=base64;
|
|
122
|
+
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/base64.js",}],
|
|
128
|
+
[10, {"./assert":8,"./hex":15,"buffer":64}, function(){
|
|
129
|
+
with (this.scopeTerminator) {
|
|
130
|
+
with (this.globalThis) {
|
|
131
|
+
return function() {
|
|
132
|
+
'use strict';
|
|
133
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/bytes.js
|
|
134
|
+
return function (require, module, exports) {
|
|
135
|
+
(function (Buffer){(function (){
|
|
136
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.createDataView=exports.concatBytes=exports.valueToBytes=exports.stringToBytes=exports.numberToBytes=exports.signedBigIntToBytes=exports.bigIntToBytes=exports.hexToBytes=exports.bytesToString=exports.bytesToNumber=exports.bytesToSignedBigInt=exports.bytesToBigInt=exports.bytesToHex=exports.assertIsBytes=exports.isBytes=void 0;const assert_1=require("./assert"),hex_1=require("./hex"),HEX_MINIMUM_NUMBER_CHARACTER=48,HEX_MAXIMUM_NUMBER_CHARACTER=58,HEX_CHARACTER_OFFSET=87;function getPrecomputedHexValuesBuilder(){const e=[];return()=>{if(0===e.length)for(let t=0;t<256;t++)e.push(t.toString(16).padStart(2,"0"));return e}}const getPrecomputedHexValues=getPrecomputedHexValuesBuilder();function isBytes(e){return e instanceof Uint8Array}function assertIsBytes(e){(0,assert_1.assert)(isBytes(e),"Value must be a Uint8Array.")}function bytesToHex(e){if(assertIsBytes(e),0===e.length)return"0x";const t=getPrecomputedHexValues(),s=new Array(e.length);for(let r=0;r<e.length;r++)s[r]=t[e[r]];return(0,hex_1.add0x)(s.join(""))}function bytesToBigInt(e){assertIsBytes(e);const t=bytesToHex(e);return BigInt(t)}function bytesToSignedBigInt(e){assertIsBytes(e);let t=BigInt(0);for(const s of e)t=(t<<BigInt(8))+BigInt(s);return BigInt.asIntN(8*e.length,t)}function bytesToNumber(e){assertIsBytes(e);const t=bytesToBigInt(e);return(0,assert_1.assert)(t<=BigInt(Number.MAX_SAFE_INTEGER),"Number is not a safe integer. Use `bytesToBigInt` instead."),Number(t)}function bytesToString(e){return assertIsBytes(e),(new TextDecoder).decode(e)}function hexToBytes(e){var t;if("0x"===(null===(t=null==e?void 0:e.toLowerCase)||void 0===t?void 0:t.call(e)))return new Uint8Array;(0,hex_1.assertIsHexString)(e);const s=(0,hex_1.remove0x)(e).toLowerCase(),r=s.length%2==0?s:`0${s}`,n=new Uint8Array(r.length/2);for(let e=0;e<n.length;e++){const t=r.charCodeAt(2*e),s=r.charCodeAt(2*e+1),o=t-(t<HEX_MAXIMUM_NUMBER_CHARACTER?HEX_MINIMUM_NUMBER_CHARACTER:HEX_CHARACTER_OFFSET),i=s-(s<HEX_MAXIMUM_NUMBER_CHARACTER?HEX_MINIMUM_NUMBER_CHARACTER:HEX_CHARACTER_OFFSET);n[e]=16*o+i}return n}function bigIntToBytes(e){(0,assert_1.assert)("bigint"==typeof e,"Value must be a bigint."),(0,assert_1.assert)(e>=BigInt(0),"Value must be a non-negative bigint.");return hexToBytes(e.toString(16))}function bigIntFits(e,t){(0,assert_1.assert)(t>0);const s=e>>BigInt(31);return!((~e&s)+(e&~s)>>BigInt(8*t-1))}function signedBigIntToBytes(e,t){(0,assert_1.assert)("bigint"==typeof e,"Value must be a bigint."),(0,assert_1.assert)("number"==typeof t,"Byte length must be a number."),(0,assert_1.assert)(t>0,"Byte length must be greater than 0."),(0,assert_1.assert)(bigIntFits(e,t),"Byte length is too small to represent the given value.");let s=e;const r=new Uint8Array(t);for(let e=0;e<r.length;e++)r[e]=Number(BigInt.asUintN(8,s)),s>>=BigInt(8);return r.reverse()}function numberToBytes(e){(0,assert_1.assert)("number"==typeof e,"Value must be a number."),(0,assert_1.assert)(e>=0,"Value must be a non-negative number."),(0,assert_1.assert)(Number.isSafeInteger(e),"Value is not a safe integer. Use `bigIntToBytes` instead.");return hexToBytes(e.toString(16))}function stringToBytes(e){return(0,assert_1.assert)("string"==typeof e,"Value must be a string."),(new TextEncoder).encode(e)}function valueToBytes(e){if("bigint"==typeof e)return bigIntToBytes(e);if("number"==typeof e)return numberToBytes(e);if("string"==typeof e)return e.startsWith("0x")?hexToBytes(e):stringToBytes(e);if(isBytes(e))return e;throw new TypeError(`Unsupported value type: "${typeof e}".`)}function concatBytes(e){const t=new Array(e.length);let s=0;for(let r=0;r<e.length;r++){const n=valueToBytes(e[r]);t[r]=n,s+=n.length}const r=new Uint8Array(s);for(let e=0,s=0;e<t.length;e++)r.set(t[e],s),s+=t[e].length;return r}function createDataView(e){if("undefined"!=typeof Buffer&&e instanceof Buffer){const t=e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength);return new DataView(t)}return new DataView(e.buffer,e.byteOffset,e.byteLength)}exports.isBytes=isBytes,exports.assertIsBytes=assertIsBytes,exports.bytesToHex=bytesToHex,exports.bytesToBigInt=bytesToBigInt,exports.bytesToSignedBigInt=bytesToSignedBigInt,exports.bytesToNumber=bytesToNumber,exports.bytesToString=bytesToString,exports.hexToBytes=hexToBytes,exports.bigIntToBytes=bigIntToBytes,exports.signedBigIntToBytes=signedBigIntToBytes,exports.numberToBytes=numberToBytes,exports.stringToBytes=stringToBytes,exports.valueToBytes=valueToBytes,exports.concatBytes=concatBytes,exports.createDataView=createDataView;
|
|
137
|
+
|
|
138
|
+
}).call(this)}).call(this,require("buffer").Buffer)
|
|
139
|
+
};
|
|
140
|
+
};
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/bytes.js",}],
|
|
144
|
+
[11, {"./base64":9,"superstruct":142}, function(){
|
|
145
|
+
with (this.scopeTerminator) {
|
|
146
|
+
with (this.globalThis) {
|
|
147
|
+
return function() {
|
|
148
|
+
'use strict';
|
|
149
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/checksum.js
|
|
150
|
+
return function (require, module, exports) {
|
|
151
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ChecksumStruct=void 0;const superstruct_1=require("superstruct"),base64_1=require("./base64");exports.ChecksumStruct=(0,superstruct_1.size)((0,base64_1.base64)((0,superstruct_1.string)(),{paddingRequired:!0}),44,44);
|
|
152
|
+
|
|
153
|
+
};
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/checksum.js",}],
|
|
158
|
+
[12, {"./assert":8,"./bytes":10,"./hex":15,"superstruct":142}, function(){
|
|
159
|
+
with (this.scopeTerminator) {
|
|
160
|
+
with (this.globalThis) {
|
|
161
|
+
return function() {
|
|
162
|
+
'use strict';
|
|
163
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/coercers.js
|
|
164
|
+
return function (require, module, exports) {
|
|
165
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.createHex=exports.createBytes=exports.createBigInt=exports.createNumber=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert"),bytes_1=require("./bytes"),hex_1=require("./hex"),NumberLikeStruct=(0,superstruct_1.union)([(0,superstruct_1.number)(),(0,superstruct_1.bigint)(),(0,superstruct_1.string)(),hex_1.StrictHexStruct]),NumberCoercer=(0,superstruct_1.coerce)((0,superstruct_1.number)(),NumberLikeStruct,Number),BigIntCoercer=(0,superstruct_1.coerce)((0,superstruct_1.bigint)(),NumberLikeStruct,BigInt),BytesLikeStruct=(0,superstruct_1.union)([hex_1.StrictHexStruct,(0,superstruct_1.instance)(Uint8Array)]),BytesCoercer=(0,superstruct_1.coerce)((0,superstruct_1.instance)(Uint8Array),(0,superstruct_1.union)([hex_1.StrictHexStruct]),bytes_1.hexToBytes),HexCoercer=(0,superstruct_1.coerce)(hex_1.StrictHexStruct,(0,superstruct_1.instance)(Uint8Array),bytes_1.bytesToHex);function createNumber(e){try{const r=(0,superstruct_1.create)(e,NumberCoercer);return(0,assert_1.assert)(Number.isFinite(r),`Expected a number-like value, got "${e}".`),r}catch(r){if(r instanceof superstruct_1.StructError)throw new Error(`Expected a number-like value, got "${e}".`);throw r}}function createBigInt(e){try{return(0,superstruct_1.create)(e,BigIntCoercer)}catch(e){if(e instanceof superstruct_1.StructError)throw new Error(`Expected a number-like value, got "${String(e.value)}".`);throw e}}function createBytes(e){if("string"==typeof e&&"0x"===e.toLowerCase())return new Uint8Array;try{return(0,superstruct_1.create)(e,BytesCoercer)}catch(e){if(e instanceof superstruct_1.StructError)throw new Error(`Expected a bytes-like value, got "${String(e.value)}".`);throw e}}function createHex(e){if(e instanceof Uint8Array&&0===e.length||"string"==typeof e&&"0x"===e.toLowerCase())return"0x";try{return(0,superstruct_1.create)(e,HexCoercer)}catch(e){if(e instanceof superstruct_1.StructError)throw new Error(`Expected a bytes-like value, got "${String(e.value)}".`);throw e}}exports.createNumber=createNumber,exports.createBigInt=createBigInt,exports.createBytes=createBytes,exports.createHex=createHex;
|
|
166
|
+
|
|
167
|
+
};
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/coercers.js",}],
|
|
172
|
+
[13, {}, function(){
|
|
173
|
+
with (this.scopeTerminator) {
|
|
174
|
+
with (this.globalThis) {
|
|
175
|
+
return function() {
|
|
176
|
+
'use strict';
|
|
177
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/collections.js
|
|
178
|
+
return function (require, module, exports) {
|
|
179
|
+
"use strict";var _FrozenMap_map,_FrozenSet_set,__classPrivateFieldSet=this&&this.__classPrivateFieldSet||function(e,t,r,s,a){if("m"===s)throw new TypeError("Private method is not writable");if("a"===s&&!a)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!a:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===s?a.call(e,r):a?a.value=r:t.set(e,r),r},__classPrivateFieldGet=this&&this.__classPrivateFieldGet||function(e,t,r,s){if("a"===r&&!s)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!s:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?s:"a"===r?s.call(e):s?s.value:t.get(e)};Object.defineProperty(exports,"__esModule",{value:!0}),exports.FrozenSet=exports.FrozenMap=void 0;class FrozenMap{constructor(e){_FrozenMap_map.set(this,void 0),__classPrivateFieldSet(this,_FrozenMap_map,new Map(e),"f"),Object.freeze(this)}get size(){return __classPrivateFieldGet(this,_FrozenMap_map,"f").size}[(_FrozenMap_map=new WeakMap,Symbol.iterator)](){return __classPrivateFieldGet(this,_FrozenMap_map,"f")[Symbol.iterator]()}entries(){return __classPrivateFieldGet(this,_FrozenMap_map,"f").entries()}forEach(e,t){return __classPrivateFieldGet(this,_FrozenMap_map,"f").forEach(((r,s,a)=>e.call(t,r,s,this)))}get(e){return __classPrivateFieldGet(this,_FrozenMap_map,"f").get(e)}has(e){return __classPrivateFieldGet(this,_FrozenMap_map,"f").has(e)}keys(){return __classPrivateFieldGet(this,_FrozenMap_map,"f").keys()}values(){return __classPrivateFieldGet(this,_FrozenMap_map,"f").values()}toString(){return`FrozenMap(${this.size}) {${this.size>0?` ${[...this.entries()].map((([e,t])=>`${String(e)} => ${String(t)}`)).join(", ")} `:""}}`}}exports.FrozenMap=FrozenMap;class FrozenSet{constructor(e){_FrozenSet_set.set(this,void 0),__classPrivateFieldSet(this,_FrozenSet_set,new Set(e),"f"),Object.freeze(this)}get size(){return __classPrivateFieldGet(this,_FrozenSet_set,"f").size}[(_FrozenSet_set=new WeakMap,Symbol.iterator)](){return __classPrivateFieldGet(this,_FrozenSet_set,"f")[Symbol.iterator]()}entries(){return __classPrivateFieldGet(this,_FrozenSet_set,"f").entries()}forEach(e,t){return __classPrivateFieldGet(this,_FrozenSet_set,"f").forEach(((r,s,a)=>e.call(t,r,s,this)))}has(e){return __classPrivateFieldGet(this,_FrozenSet_set,"f").has(e)}keys(){return __classPrivateFieldGet(this,_FrozenSet_set,"f").keys()}values(){return __classPrivateFieldGet(this,_FrozenSet_set,"f").values()}toString(){return`FrozenSet(${this.size}) {${this.size>0?` ${[...this.values()].map((e=>String(e))).join(", ")} `:""}}`}}exports.FrozenSet=FrozenSet,Object.freeze(FrozenMap),Object.freeze(FrozenMap.prototype),Object.freeze(FrozenSet),Object.freeze(FrozenSet.prototype);
|
|
180
|
+
|
|
181
|
+
};
|
|
182
|
+
};
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/collections.js",}],
|
|
186
|
+
[14, {}, function(){
|
|
187
|
+
with (this.scopeTerminator) {
|
|
188
|
+
with (this.globalThis) {
|
|
189
|
+
return function() {
|
|
190
|
+
'use strict';
|
|
191
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/encryption-types.js
|
|
192
|
+
return function (require, module, exports) {
|
|
193
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
194
|
+
|
|
195
|
+
};
|
|
196
|
+
};
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/encryption-types.js",}],
|
|
200
|
+
[15, {"./assert":8,"superstruct":142}, function(){
|
|
201
|
+
with (this.scopeTerminator) {
|
|
202
|
+
with (this.globalThis) {
|
|
203
|
+
return function() {
|
|
204
|
+
'use strict';
|
|
205
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/hex.js
|
|
206
|
+
return function (require, module, exports) {
|
|
207
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.remove0x=exports.add0x=exports.assertIsStrictHexString=exports.assertIsHexString=exports.isStrictHexString=exports.isHexString=exports.StrictHexStruct=exports.HexStruct=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert");function isHexString(t){return(0,superstruct_1.is)(t,exports.HexStruct)}function isStrictHexString(t){return(0,superstruct_1.is)(t,exports.StrictHexStruct)}function assertIsHexString(t){(0,assert_1.assert)(isHexString(t),"Value must be a hexadecimal string.")}function assertIsStrictHexString(t){(0,assert_1.assert)(isStrictHexString(t),'Value must be a hexadecimal string, starting with "0x".')}function add0x(t){return t.startsWith("0x")?t:t.startsWith("0X")?`0x${t.substring(2)}`:`0x${t}`}function remove0x(t){return t.startsWith("0x")||t.startsWith("0X")?t.substring(2):t}exports.HexStruct=(0,superstruct_1.pattern)((0,superstruct_1.string)(),/^(?:0x)?[0-9a-f]+$/iu),exports.StrictHexStruct=(0,superstruct_1.pattern)((0,superstruct_1.string)(),/^0x[0-9a-f]+$/iu),exports.isHexString=isHexString,exports.isStrictHexString=isStrictHexString,exports.assertIsHexString=assertIsHexString,exports.assertIsStrictHexString=assertIsStrictHexString,exports.add0x=add0x,exports.remove0x=remove0x;
|
|
208
|
+
|
|
209
|
+
};
|
|
210
|
+
};
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/hex.js",}],
|
|
214
|
+
[16, {"./assert":8,"./base64":9,"./bytes":10,"./checksum":11,"./coercers":12,"./collections":13,"./encryption-types":14,"./hex":15,"./json":17,"./keyring":18,"./logging":19,"./misc":20,"./number":21,"./opaque":22,"./time":23,"./transaction-types":24,"./versions":25}, function(){
|
|
215
|
+
with (this.scopeTerminator) {
|
|
216
|
+
with (this.globalThis) {
|
|
217
|
+
return function() {
|
|
218
|
+
'use strict';
|
|
219
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/index.js
|
|
220
|
+
return function (require, module, exports) {
|
|
221
|
+
"use strict";var __createBinding=this&&this.__createBinding||(Object.create?function(e,r,t,o){void 0===o&&(o=t);var i=Object.getOwnPropertyDescriptor(r,t);i&&!("get"in i?!r.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return r[t]}}),Object.defineProperty(e,o,i)}:function(e,r,t,o){void 0===o&&(o=t),e[o]=r[t]}),__exportStar=this&&this.__exportStar||function(e,r){for(var t in e)"default"===t||Object.prototype.hasOwnProperty.call(r,t)||__createBinding(r,e,t)};Object.defineProperty(exports,"__esModule",{value:!0}),__exportStar(require("./assert"),exports),__exportStar(require("./base64"),exports),__exportStar(require("./bytes"),exports),__exportStar(require("./checksum"),exports),__exportStar(require("./coercers"),exports),__exportStar(require("./collections"),exports),__exportStar(require("./encryption-types"),exports),__exportStar(require("./hex"),exports),__exportStar(require("./json"),exports),__exportStar(require("./keyring"),exports),__exportStar(require("./logging"),exports),__exportStar(require("./misc"),exports),__exportStar(require("./number"),exports),__exportStar(require("./opaque"),exports),__exportStar(require("./time"),exports),__exportStar(require("./transaction-types"),exports),__exportStar(require("./versions"),exports);
|
|
222
|
+
|
|
223
|
+
};
|
|
224
|
+
};
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/index.js",}],
|
|
228
|
+
[17, {"./assert":8,"superstruct":142}, function(){
|
|
229
|
+
with (this.scopeTerminator) {
|
|
230
|
+
with (this.globalThis) {
|
|
231
|
+
return function() {
|
|
232
|
+
'use strict';
|
|
233
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/json.js
|
|
234
|
+
return function (require, module, exports) {
|
|
235
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.getJsonRpcIdValidator=exports.assertIsJsonRpcError=exports.isJsonRpcError=exports.assertIsJsonRpcFailure=exports.isJsonRpcFailure=exports.assertIsJsonRpcSuccess=exports.isJsonRpcSuccess=exports.assertIsJsonRpcResponse=exports.isJsonRpcResponse=exports.assertIsPendingJsonRpcResponse=exports.isPendingJsonRpcResponse=exports.JsonRpcResponseStruct=exports.JsonRpcFailureStruct=exports.JsonRpcSuccessStruct=exports.PendingJsonRpcResponseStruct=exports.assertIsJsonRpcRequest=exports.isJsonRpcRequest=exports.assertIsJsonRpcNotification=exports.isJsonRpcNotification=exports.JsonRpcNotificationStruct=exports.JsonRpcRequestStruct=exports.JsonRpcParamsStruct=exports.JsonRpcErrorStruct=exports.JsonRpcIdStruct=exports.JsonRpcVersionStruct=exports.jsonrpc2=exports.getJsonSize=exports.isValidJson=exports.JsonStruct=exports.UnsafeJsonStruct=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert"),finiteNumber=()=>(0,superstruct_1.define)("finite number",(s=>(0,superstruct_1.is)(s,(0,superstruct_1.number)())&&Number.isFinite(s)));function isValidJson(s){return(0,superstruct_1.is)(s,exports.JsonStruct)}function getJsonSize(s){(0,assert_1.assertStruct)(s,exports.JsonStruct,"Invalid JSON value");const t=JSON.stringify(s);return(new TextEncoder).encode(t).byteLength}function isJsonRpcNotification(s){return(0,superstruct_1.is)(s,exports.JsonRpcNotificationStruct)}function assertIsJsonRpcNotification(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcNotificationStruct,"Invalid JSON-RPC notification",t)}function isJsonRpcRequest(s){return(0,superstruct_1.is)(s,exports.JsonRpcRequestStruct)}function assertIsJsonRpcRequest(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcRequestStruct,"Invalid JSON-RPC request",t)}function isPendingJsonRpcResponse(s){return(0,superstruct_1.is)(s,exports.PendingJsonRpcResponseStruct)}function assertIsPendingJsonRpcResponse(s,t){(0,assert_1.assertStruct)(s,exports.PendingJsonRpcResponseStruct,"Invalid pending JSON-RPC response",t)}function isJsonRpcResponse(s){return(0,superstruct_1.is)(s,exports.JsonRpcResponseStruct)}function assertIsJsonRpcResponse(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcResponseStruct,"Invalid JSON-RPC response",t)}function isJsonRpcSuccess(s){return(0,superstruct_1.is)(s,exports.JsonRpcSuccessStruct)}function assertIsJsonRpcSuccess(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcSuccessStruct,"Invalid JSON-RPC success response",t)}function isJsonRpcFailure(s){return(0,superstruct_1.is)(s,exports.JsonRpcFailureStruct)}function assertIsJsonRpcFailure(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcFailureStruct,"Invalid JSON-RPC failure response",t)}function isJsonRpcError(s){return(0,superstruct_1.is)(s,exports.JsonRpcErrorStruct)}function assertIsJsonRpcError(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcErrorStruct,"Invalid JSON-RPC error",t)}function getJsonRpcIdValidator(s){const{permitEmptyString:t,permitFractions:r,permitNull:e}=Object.assign({permitEmptyString:!0,permitFractions:!1,permitNull:!0},s);return s=>Boolean("number"==typeof s&&(r||Number.isInteger(s))||"string"==typeof s&&(t||s.length>0)||e&&null===s)}exports.UnsafeJsonStruct=(0,superstruct_1.union)([(0,superstruct_1.literal)(null),(0,superstruct_1.boolean)(),(0,superstruct_1.define)("finite number",(s=>(0,superstruct_1.is)(s,(0,superstruct_1.number)())&&Number.isFinite(s))),(0,superstruct_1.string)(),(0,superstruct_1.array)((0,superstruct_1.lazy)((()=>exports.UnsafeJsonStruct))),(0,superstruct_1.record)((0,superstruct_1.string)(),(0,superstruct_1.lazy)((()=>exports.UnsafeJsonStruct)))]),exports.JsonStruct=(0,superstruct_1.define)("Json",((s,t)=>{function r(s,r){const e=[...r.validator(s,t)];return!(e.length>0)||e}try{const t=r(s,exports.UnsafeJsonStruct);return!0!==t?t:r(JSON.parse(JSON.stringify(s)),exports.UnsafeJsonStruct)}catch(s){return s instanceof RangeError&&"Circular reference detected"}})),exports.isValidJson=isValidJson,exports.getJsonSize=getJsonSize,exports.jsonrpc2="2.0",exports.JsonRpcVersionStruct=(0,superstruct_1.literal)(exports.jsonrpc2),exports.JsonRpcIdStruct=(0,superstruct_1.nullable)((0,superstruct_1.union)([(0,superstruct_1.number)(),(0,superstruct_1.string)()])),exports.JsonRpcErrorStruct=(0,superstruct_1.object)({code:(0,superstruct_1.integer)(),message:(0,superstruct_1.string)(),data:(0,superstruct_1.optional)(exports.JsonStruct),stack:(0,superstruct_1.optional)((0,superstruct_1.string)())}),exports.JsonRpcParamsStruct=(0,superstruct_1.optional)((0,superstruct_1.union)([(0,superstruct_1.record)((0,superstruct_1.string)(),exports.JsonStruct),(0,superstruct_1.array)(exports.JsonStruct)])),exports.JsonRpcRequestStruct=(0,superstruct_1.object)({id:exports.JsonRpcIdStruct,jsonrpc:exports.JsonRpcVersionStruct,method:(0,superstruct_1.string)(),params:exports.JsonRpcParamsStruct}),exports.JsonRpcNotificationStruct=(0,superstruct_1.omit)(exports.JsonRpcRequestStruct,["id"]),exports.isJsonRpcNotification=isJsonRpcNotification,exports.assertIsJsonRpcNotification=assertIsJsonRpcNotification,exports.isJsonRpcRequest=isJsonRpcRequest,exports.assertIsJsonRpcRequest=assertIsJsonRpcRequest,exports.PendingJsonRpcResponseStruct=(0,superstruct_1.object)({id:exports.JsonRpcIdStruct,jsonrpc:exports.JsonRpcVersionStruct,result:(0,superstruct_1.optional)((0,superstruct_1.unknown)()),error:(0,superstruct_1.optional)(exports.JsonRpcErrorStruct)}),exports.JsonRpcSuccessStruct=(0,superstruct_1.object)({id:exports.JsonRpcIdStruct,jsonrpc:exports.JsonRpcVersionStruct,result:exports.JsonStruct}),exports.JsonRpcFailureStruct=(0,superstruct_1.object)({id:exports.JsonRpcIdStruct,jsonrpc:exports.JsonRpcVersionStruct,error:exports.JsonRpcErrorStruct}),exports.JsonRpcResponseStruct=(0,superstruct_1.union)([exports.JsonRpcSuccessStruct,exports.JsonRpcFailureStruct]),exports.isPendingJsonRpcResponse=isPendingJsonRpcResponse,exports.assertIsPendingJsonRpcResponse=assertIsPendingJsonRpcResponse,exports.isJsonRpcResponse=isJsonRpcResponse,exports.assertIsJsonRpcResponse=assertIsJsonRpcResponse,exports.isJsonRpcSuccess=isJsonRpcSuccess,exports.assertIsJsonRpcSuccess=assertIsJsonRpcSuccess,exports.isJsonRpcFailure=isJsonRpcFailure,exports.assertIsJsonRpcFailure=assertIsJsonRpcFailure,exports.isJsonRpcError=isJsonRpcError,exports.assertIsJsonRpcError=assertIsJsonRpcError,exports.getJsonRpcIdValidator=getJsonRpcIdValidator;
|
|
236
|
+
|
|
237
|
+
};
|
|
238
|
+
};
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/json.js",}],
|
|
242
|
+
[18, {}, function(){
|
|
243
|
+
with (this.scopeTerminator) {
|
|
244
|
+
with (this.globalThis) {
|
|
245
|
+
return function() {
|
|
246
|
+
'use strict';
|
|
247
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/keyring.js
|
|
248
|
+
return function (require, module, exports) {
|
|
249
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
250
|
+
|
|
251
|
+
};
|
|
252
|
+
};
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/keyring.js",}],
|
|
256
|
+
[19, {"debug":73}, function(){
|
|
257
|
+
with (this.scopeTerminator) {
|
|
258
|
+
with (this.globalThis) {
|
|
259
|
+
return function() {
|
|
260
|
+
'use strict';
|
|
261
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/logging.js
|
|
262
|
+
return function (require, module, exports) {
|
|
263
|
+
"use strict";var __importDefault=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(exports,"__esModule",{value:!0}),exports.createModuleLogger=exports.createProjectLogger=void 0;const debug_1=__importDefault(require("debug")),globalLogger=(0,debug_1.default)("metamask");function createProjectLogger(e){return globalLogger.extend(e)}function createModuleLogger(e,r){return e.extend(r)}exports.createProjectLogger=createProjectLogger,exports.createModuleLogger=createModuleLogger;
|
|
264
|
+
|
|
265
|
+
};
|
|
266
|
+
};
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/logging.js",}],
|
|
270
|
+
[20, {}, function(){
|
|
271
|
+
with (this.scopeTerminator) {
|
|
272
|
+
with (this.globalThis) {
|
|
273
|
+
return function() {
|
|
274
|
+
'use strict';
|
|
275
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/misc.js
|
|
276
|
+
return function (require, module, exports) {
|
|
277
|
+
"use strict";function isNonEmptyArray(e){return Array.isArray(e)&&e.length>0}function isNullOrUndefined(e){return null==e}function isObject(e){return Boolean(e)&&"object"==typeof e&&!Array.isArray(e)}Object.defineProperty(exports,"__esModule",{value:!0}),exports.calculateNumberSize=exports.calculateStringSize=exports.isASCII=exports.isPlainObject=exports.ESCAPE_CHARACTERS_REGEXP=exports.JsonSize=exports.hasProperty=exports.isObject=exports.isNullOrUndefined=exports.isNonEmptyArray=void 0,exports.isNonEmptyArray=isNonEmptyArray,exports.isNullOrUndefined=isNullOrUndefined,exports.isObject=isObject;const hasProperty=(e,t)=>Object.hasOwnProperty.call(e,t);var JsonSize;function isPlainObject(e){if("object"!=typeof e||null===e)return!1;try{let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}catch(e){return!1}}function isASCII(e){return e.charCodeAt(0)<=127}function calculateStringSize(e){var t;return e.split("").reduce(((e,t)=>isASCII(t)?e+1:e+2),0)+(null!==(t=e.match(exports.ESCAPE_CHARACTERS_REGEXP))&&void 0!==t?t:[]).length}function calculateNumberSize(e){return e.toString().length}exports.hasProperty=hasProperty,function(e){e[e.Null=4]="Null",e[e.Comma=1]="Comma",e[e.Wrapper=1]="Wrapper",e[e.True=4]="True",e[e.False=5]="False",e[e.Quote=1]="Quote",e[e.Colon=1]="Colon",e[e.Date=24]="Date"}(JsonSize=exports.JsonSize||(exports.JsonSize={})),exports.ESCAPE_CHARACTERS_REGEXP=/"|\\|\n|\r|\t/gu,exports.isPlainObject=isPlainObject,exports.isASCII=isASCII,exports.calculateStringSize=calculateStringSize,exports.calculateNumberSize=calculateNumberSize;
|
|
278
|
+
|
|
279
|
+
};
|
|
280
|
+
};
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/misc.js",}],
|
|
284
|
+
[21, {"./assert":8,"./hex":15}, function(){
|
|
285
|
+
with (this.scopeTerminator) {
|
|
286
|
+
with (this.globalThis) {
|
|
287
|
+
return function() {
|
|
288
|
+
'use strict';
|
|
289
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/number.js
|
|
290
|
+
return function (require, module, exports) {
|
|
291
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.hexToBigInt=exports.hexToNumber=exports.bigIntToHex=exports.numberToHex=void 0;const assert_1=require("./assert"),hex_1=require("./hex"),numberToHex=e=>((0,assert_1.assert)("number"==typeof e,"Value must be a number."),(0,assert_1.assert)(e>=0,"Value must be a non-negative number."),(0,assert_1.assert)(Number.isSafeInteger(e),"Value is not a safe integer. Use `bigIntToHex` instead."),(0,hex_1.add0x)(e.toString(16)));exports.numberToHex=numberToHex;const bigIntToHex=e=>((0,assert_1.assert)("bigint"==typeof e,"Value must be a bigint."),(0,assert_1.assert)(e>=0,"Value must be a non-negative bigint."),(0,hex_1.add0x)(e.toString(16)));exports.bigIntToHex=bigIntToHex;const hexToNumber=e=>{(0,hex_1.assertIsHexString)(e);const t=parseInt(e,16);return(0,assert_1.assert)(Number.isSafeInteger(t),"Value is not a safe integer. Use `hexToBigInt` instead."),t};exports.hexToNumber=hexToNumber;const hexToBigInt=e=>((0,hex_1.assertIsHexString)(e),BigInt((0,hex_1.add0x)(e)));exports.hexToBigInt=hexToBigInt;
|
|
292
|
+
|
|
293
|
+
};
|
|
294
|
+
};
|
|
295
|
+
}
|
|
296
|
+
}
|
|
297
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/number.js",}],
|
|
298
|
+
[22, {}, function(){
|
|
299
|
+
with (this.scopeTerminator) {
|
|
300
|
+
with (this.globalThis) {
|
|
301
|
+
return function() {
|
|
302
|
+
'use strict';
|
|
303
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/opaque.js
|
|
304
|
+
return function (require, module, exports) {
|
|
305
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
306
|
+
|
|
307
|
+
};
|
|
308
|
+
};
|
|
309
|
+
}
|
|
310
|
+
}
|
|
311
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/opaque.js",}],
|
|
312
|
+
[23, {}, function(){
|
|
313
|
+
with (this.scopeTerminator) {
|
|
314
|
+
with (this.globalThis) {
|
|
315
|
+
return function() {
|
|
316
|
+
'use strict';
|
|
317
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/time.js
|
|
318
|
+
return function (require, module, exports) {
|
|
319
|
+
"use strict";var Duration;Object.defineProperty(exports,"__esModule",{value:!0}),exports.timeSince=exports.inMilliseconds=exports.Duration=void 0,function(e){e[e.Millisecond=1]="Millisecond",e[e.Second=1e3]="Second",e[e.Minute=6e4]="Minute",e[e.Hour=36e5]="Hour",e[e.Day=864e5]="Day",e[e.Week=6048e5]="Week",e[e.Year=31536e6]="Year"}(Duration=exports.Duration||(exports.Duration={}));const isNonNegativeInteger=e=>Number.isInteger(e)&&e>=0,assertIsNonNegativeInteger=(e,n)=>{if(!isNonNegativeInteger(e))throw new Error(`"${n}" must be a non-negative integer. Received: "${e}".`)};function inMilliseconds(e,n){return assertIsNonNegativeInteger(e,"count"),e*n}function timeSince(e){return assertIsNonNegativeInteger(e,"timestamp"),Date.now()-e}exports.inMilliseconds=inMilliseconds,exports.timeSince=timeSince;
|
|
320
|
+
|
|
321
|
+
};
|
|
322
|
+
};
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/time.js",}],
|
|
326
|
+
[24, {}, function(){
|
|
327
|
+
with (this.scopeTerminator) {
|
|
328
|
+
with (this.globalThis) {
|
|
329
|
+
return function() {
|
|
330
|
+
'use strict';
|
|
331
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/transaction-types.js
|
|
332
|
+
return function (require, module, exports) {
|
|
333
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
334
|
+
|
|
335
|
+
};
|
|
336
|
+
};
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/transaction-types.js",}],
|
|
340
|
+
[25, {"./assert":8,"semver":123,"superstruct":142}, function(){
|
|
341
|
+
with (this.scopeTerminator) {
|
|
342
|
+
with (this.globalThis) {
|
|
343
|
+
return function() {
|
|
344
|
+
'use strict';
|
|
345
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/versions.js
|
|
346
|
+
return function (require, module, exports) {
|
|
347
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.satisfiesVersionRange=exports.gtRange=exports.gtVersion=exports.assertIsSemVerRange=exports.assertIsSemVerVersion=exports.isValidSemVerRange=exports.isValidSemVerVersion=exports.VersionRangeStruct=exports.VersionStruct=void 0;const semver_1=require("semver"),superstruct_1=require("superstruct"),assert_1=require("./assert");function isValidSemVerVersion(e){return(0,superstruct_1.is)(e,exports.VersionStruct)}function isValidSemVerRange(e){return(0,superstruct_1.is)(e,exports.VersionRangeStruct)}function assertIsSemVerVersion(e){(0,assert_1.assertStruct)(e,exports.VersionStruct)}function assertIsSemVerRange(e){(0,assert_1.assertStruct)(e,exports.VersionRangeStruct)}function gtVersion(e,r){return(0,semver_1.gt)(e,r)}function gtRange(e,r){return(0,semver_1.gtr)(e,r)}function satisfiesVersionRange(e,r){return(0,semver_1.satisfies)(e,r,{includePrerelease:!0})}exports.VersionStruct=(0,superstruct_1.refine)((0,superstruct_1.string)(),"Version",(e=>null!==(0,semver_1.valid)(e)||`Expected SemVer version, got "${e}"`)),exports.VersionRangeStruct=(0,superstruct_1.refine)((0,superstruct_1.string)(),"Version range",(e=>null!==(0,semver_1.validRange)(e)||`Expected SemVer range, got "${e}"`)),exports.isValidSemVerVersion=isValidSemVerVersion,exports.isValidSemVerRange=isValidSemVerRange,exports.assertIsSemVerVersion=assertIsSemVerVersion,exports.assertIsSemVerRange=assertIsSemVerRange,exports.gtVersion=gtVersion,exports.gtRange=gtRange,exports.satisfiesVersionRange=satisfiesVersionRange;
|
|
348
|
+
|
|
349
|
+
};
|
|
350
|
+
};
|
|
351
|
+
}
|
|
352
|
+
}
|
|
353
|
+
}, {package:"@metamask/post-message-stream>@metamask/utils",file:"../../node_modules/@metamask/post-message-stream/node_modules/@metamask/utils/dist/versions.js",}],
|
|
354
|
+
[26, {"_process":94}, function(){
|
|
355
|
+
with (this.scopeTerminator) {
|
|
356
|
+
with (this.globalThis) {
|
|
357
|
+
return function() {
|
|
358
|
+
'use strict';
|
|
359
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/process-nextick-args/index.js
|
|
106
360
|
return function (require, module, exports) {
|
|
107
361
|
(function (process){(function (){
|
|
108
362
|
"use strict";function nextTick(e,n,c,r){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var s,t,o=arguments.length;switch(o){case 0:case 1:return process.nextTick(e);case 2:return process.nextTick((function(){e.call(null,n)}));case 3:return process.nextTick((function(){e.call(null,n,c)}));case 4:return process.nextTick((function(){e.call(null,n,c,r)}));default:for(s=new Array(o-1),t=0;t<s.length;)s[t++]=arguments[t];return process.nextTick((function(){e.apply(null,s)}))}}!process.version||0===process.version.indexOf("v0.")||0===process.version.indexOf("v1.")&&0!==process.version.indexOf("v1.8.")?module.exports=nextTick:module.exports=process.nextTick;
|
|
@@ -113,12 +367,12 @@ LavaPack.loadBundle([
|
|
|
113
367
|
}
|
|
114
368
|
}
|
|
115
369
|
}, {package:"@metamask/post-message-stream>readable-stream>process-nextick-args",file:"../../node_modules/@metamask/post-message-stream/node_modules/process-nextick-args/index.js",}],
|
|
116
|
-
[
|
|
370
|
+
[27, {"./_stream_readable":29,"./_stream_writable":31,"core-util-is":66,"inherits":89,"process-nextick-args":26}, function(){
|
|
117
371
|
with (this.scopeTerminator) {
|
|
118
372
|
with (this.globalThis) {
|
|
119
373
|
return function() {
|
|
120
374
|
'use strict';
|
|
121
|
-
// source: /home/runner/work/snaps
|
|
375
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_duplex.js
|
|
122
376
|
return function (require, module, exports) {
|
|
123
377
|
"use strict";var processNextTick=require("process-nextick-args"),objectKeys=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};module.exports=Duplex;var util=require("core-util-is");util.inherits=require("inherits");var Readable=require("./_stream_readable"),Writable=require("./_stream_writable");util.inherits(Duplex,Readable);for(var keys=objectKeys(Writable.prototype),v=0;v<keys.length;v++){var method=keys[v];Duplex.prototype[method]||(Duplex.prototype[method]=Writable.prototype[method])}function Duplex(e){if(!(this instanceof Duplex))return new Duplex(e);Readable.call(this,e),Writable.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",onend)}function onend(){this.allowHalfOpen||this._writableState.ended||processNextTick(onEndNT,this)}function onEndNT(e){e.end()}function forEach(e,t){for(var r=0,i=e.length;r<i;r++)t(e[r],r)}Object.defineProperty(Duplex.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),Duplex.prototype._destroy=function(e,t){this.push(null),this.end(),processNextTick(t,e)};
|
|
124
378
|
|
|
@@ -127,12 +381,12 @@ LavaPack.loadBundle([
|
|
|
127
381
|
}
|
|
128
382
|
}
|
|
129
383
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_duplex.js",}],
|
|
130
|
-
[
|
|
384
|
+
[28, {"./_stream_transform":30,"core-util-is":66,"inherits":89}, function(){
|
|
131
385
|
with (this.scopeTerminator) {
|
|
132
386
|
with (this.globalThis) {
|
|
133
387
|
return function() {
|
|
134
388
|
'use strict';
|
|
135
|
-
// source: /home/runner/work/snaps
|
|
389
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_passthrough.js
|
|
136
390
|
return function (require, module, exports) {
|
|
137
391
|
"use strict";module.exports=PassThrough;var Transform=require("./_stream_transform"),util=require("core-util-is");function PassThrough(r){if(!(this instanceof PassThrough))return new PassThrough(r);Transform.call(this,r)}util.inherits=require("inherits"),util.inherits(PassThrough,Transform),PassThrough.prototype._transform=function(r,s,i){i(null,r)};
|
|
138
392
|
|
|
@@ -141,12 +395,12 @@ LavaPack.loadBundle([
|
|
|
141
395
|
}
|
|
142
396
|
}
|
|
143
397
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_passthrough.js",}],
|
|
144
|
-
[
|
|
398
|
+
[29, {"./_stream_duplex":27,"./internal/streams/BufferList":32,"./internal/streams/destroy":33,"./internal/streams/stream":34,"_process":94,"core-util-is":66,"events":75,"inherits":89,"isarray":92,"process-nextick-args":26,"safe-buffer":36,"string_decoder/":37,"util":63}, function(){
|
|
145
399
|
with (this.scopeTerminator) {
|
|
146
400
|
with (this.globalThis) {
|
|
147
401
|
return function() {
|
|
148
402
|
'use strict';
|
|
149
|
-
// source: /home/runner/work/snaps
|
|
403
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_readable.js
|
|
150
404
|
return function (require, module, exports) {
|
|
151
405
|
(function (process){(function (){
|
|
152
406
|
"use strict";var processNextTick=require("process-nextick-args");module.exports=Readable;var Duplex,isArray=require("isarray");Readable.ReadableState=ReadableState;var EE=require("events").EventEmitter,EElistenerCount=function(e,t){return e.listeners(t).length},Stream=require("./internal/streams/stream"),Buffer=require("safe-buffer").Buffer,OurUint8Array=global.Uint8Array||function(){};function _uint8ArrayToBuffer(e){return Buffer.from(e)}function _isUint8Array(e){return Buffer.isBuffer(e)||e instanceof OurUint8Array}var util=require("core-util-is");util.inherits=require("inherits");var debugUtil=require("util"),debug=void 0;debug=debugUtil&&debugUtil.debuglog?debugUtil.debuglog("stream"):function(){};var StringDecoder,BufferList=require("./internal/streams/BufferList"),destroyImpl=require("./internal/streams/destroy");util.inherits(Readable,Stream);var kProxyEvents=["error","close","destroy","pause","resume"];function prependListener(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}function ReadableState(e,t){Duplex=Duplex||require("./_stream_duplex"),e=e||{},this.objectMode=!!e.objectMode,t instanceof Duplex&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var r=e.highWaterMark,n=this.objectMode?16:16384;this.highWaterMark=r||0===r?r:n,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new BufferList,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(StringDecoder||(StringDecoder=require("string_decoder/").StringDecoder),this.decoder=new StringDecoder(e.encoding),this.encoding=e.encoding)}function Readable(e){if(Duplex=Duplex||require("./_stream_duplex"),!(this instanceof Readable))return new Readable(e);this._readableState=new ReadableState(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),Stream.call(this)}function readableAddChunk(e,t,r,n,a){var i,d=e._readableState;null===t?(d.reading=!1,onEofChunk(e,d)):(a||(i=chunkInvalid(d,t)),i?e.emit("error",i):d.objectMode||t&&t.length>0?("string"==typeof t||d.objectMode||Object.getPrototypeOf(t)===Buffer.prototype||(t=_uint8ArrayToBuffer(t)),n?d.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):addChunk(e,d,t,!0):d.ended?e.emit("error",new Error("stream.push() after EOF")):(d.reading=!1,d.decoder&&!r?(t=d.decoder.write(t),d.objectMode||0!==t.length?addChunk(e,d,t,!1):maybeReadMore(e,d)):addChunk(e,d,t,!1))):n||(d.reading=!1));return needMoreData(d)}function addChunk(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&emitReadable(e)),maybeReadMore(e,t)}function chunkInvalid(e,t){var r;return _isUint8Array(t)||"string"==typeof t||void 0===t||e.objectMode||(r=new TypeError("Invalid non-string/buffer chunk")),r}function needMoreData(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(Readable.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),Readable.prototype.destroy=destroyImpl.destroy,Readable.prototype._undestroy=destroyImpl.undestroy,Readable.prototype._destroy=function(e,t){this.push(null),t(e)},Readable.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=Buffer.from(e,t),t=""),r=!0),readableAddChunk(this,e,t,!1,r)},Readable.prototype.unshift=function(e){return readableAddChunk(this,e,null,!0,!1)},Readable.prototype.isPaused=function(){return!1===this._readableState.flowing},Readable.prototype.setEncoding=function(e){return StringDecoder||(StringDecoder=require("string_decoder/").StringDecoder),this._readableState.decoder=new StringDecoder(e),this._readableState.encoding=e,this};var MAX_HWM=8388608;function computeNewHighWaterMark(e){return e>=MAX_HWM?e=MAX_HWM:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function howMuchToRead(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=computeNewHighWaterMark(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function onEofChunk(e,t){if(!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,emitReadable(e)}}function emitReadable(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(debug("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?processNextTick(emitReadable_,e):emitReadable_(e))}function emitReadable_(e){debug("emit readable"),e.emit("readable"),flow(e)}function maybeReadMore(e,t){t.readingMore||(t.readingMore=!0,processNextTick(maybeReadMore_,e,t))}function maybeReadMore_(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(debug("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}function pipeOnDrain(e){return function(){var t=e._readableState;debug("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&EElistenerCount(e,"data")&&(t.flowing=!0,flow(e))}}function nReadingNextTick(e){debug("readable nexttick read 0"),e.read(0)}function resume(e,t){t.resumeScheduled||(t.resumeScheduled=!0,processNextTick(resume_,e,t))}function resume_(e,t){t.reading||(debug("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),flow(e),t.flowing&&!t.reading&&e.read(0)}function flow(e){var t=e._readableState;for(debug("flow",t.flowing);t.flowing&&null!==e.read(););}function fromList(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):r=fromListPartial(e,t.buffer,t.decoder),r);var r}function fromListPartial(e,t,r){var n;return e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):n=e===t.head.data.length?t.shift():r?copyFromBufferString(e,t):copyFromBuffer(e,t),n}function copyFromBufferString(e,t){var r=t.head,n=1,a=r.data;for(e-=a.length;r=r.next;){var i=r.data,d=e>i.length?i.length:e;if(d===i.length?a+=i:a+=i.slice(0,e),0===(e-=d)){d===i.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=i.slice(d));break}++n}return t.length-=n,a}function copyFromBuffer(e,t){var r=Buffer.allocUnsafe(e),n=t.head,a=1;for(n.data.copy(r),e-=n.data.length;n=n.next;){var i=n.data,d=e>i.length?i.length:e;if(i.copy(r,r.length-e,0,d),0===(e-=d)){d===i.length?(++a,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=i.slice(d));break}++a}return t.length-=a,r}function endReadable(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,processNextTick(endReadableNT,t,e))}function endReadableNT(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function forEach(e,t){for(var r=0,n=e.length;r<n;r++)t(e[r],r)}function indexOf(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}Readable.prototype.read=function(e){debug("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return debug("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?endReadable(this):emitReadable(this),null;if(0===(e=howMuchToRead(e,t))&&t.ended)return 0===t.length&&endReadable(this),null;var n,a=t.needReadable;return debug("need readable",a),(0===t.length||t.length-e<t.highWaterMark)&&debug("length less than watermark",a=!0),t.ended||t.reading?debug("reading or ended",a=!1):a&&(debug("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=howMuchToRead(r,t))),null===(n=e>0?fromList(e,t):null)?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&endReadable(this)),null!==n&&this.emit("data",n),n},Readable.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},Readable.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e)}n.pipesCount+=1,debug("pipe count=%d opts=%j",n.pipesCount,t);var a=(!t||!1!==t.end)&&e!==process.stdout&&e!==process.stderr?d:c;function i(t,a){debug("onunpipe"),t===r&&a&&!1===a.hasUnpiped&&(a.hasUnpiped=!0,debug("cleanup"),e.removeListener("close",f),e.removeListener("finish",p),e.removeListener("drain",o),e.removeListener("error",h),e.removeListener("unpipe",i),r.removeListener("end",d),r.removeListener("end",c),r.removeListener("data",l),u=!0,!n.awaitDrain||e._writableState&&!e._writableState.needDrain||o())}function d(){debug("onend"),e.end()}n.endEmitted?processNextTick(a):r.once("end",a),e.on("unpipe",i);var o=pipeOnDrain(r);e.on("drain",o);var u=!1;var s=!1;function l(t){debug("ondata"),s=!1,!1!==e.write(t)||s||((1===n.pipesCount&&n.pipes===e||n.pipesCount>1&&-1!==indexOf(n.pipes,e))&&!u&&(debug("false write response, pause",r._readableState.awaitDrain),r._readableState.awaitDrain++,s=!0),r.pause())}function h(t){debug("onerror",t),c(),e.removeListener("error",h),0===EElistenerCount(e,"error")&&e.emit("error",t)}function f(){e.removeListener("finish",p),c()}function p(){debug("onfinish"),e.removeListener("close",f),c()}function c(){debug("unpipe"),r.unpipe(e)}return r.on("data",l),prependListener(e,"error",h),e.once("close",f),e.once("finish",p),e.emit("pipe",r),n.flowing||(debug("pipe resume"),r.resume()),e},Readable.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,a=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var i=0;i<a;i++)n[i].emit("unpipe",this,r);return this}var d=indexOf(t.pipes,e);return-1===d||(t.pipes.splice(d,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r)),this},Readable.prototype.on=function(e,t){var r=Stream.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var n=this._readableState;n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.emittedReadable=!1,n.reading?n.length&&emitReadable(this):processNextTick(nReadingNextTick,this))}return r},Readable.prototype.addListener=Readable.prototype.on,Readable.prototype.resume=function(){var e=this._readableState;return e.flowing||(debug("resume"),e.flowing=!0,resume(this,e)),this},Readable.prototype.pause=function(){return debug("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(debug("pause"),this._readableState.flowing=!1,this.emit("pause")),this},Readable.prototype.wrap=function(e){var t=this._readableState,r=!1,n=this;for(var a in e.on("end",(function(){if(debug("wrapped end"),t.decoder&&!t.ended){var e=t.decoder.end();e&&e.length&&n.push(e)}n.push(null)})),e.on("data",(function(a){(debug("wrapped data"),t.decoder&&(a=t.decoder.write(a)),t.objectMode&&null==a)||(t.objectMode||a&&a.length)&&(n.push(a)||(r=!0,e.pause()))})),e)void 0===this[a]&&"function"==typeof e[a]&&(this[a]=function(t){return function(){return e[t].apply(e,arguments)}}(a));for(var i=0;i<kProxyEvents.length;i++)e.on(kProxyEvents[i],n.emit.bind(n,kProxyEvents[i]));return n._read=function(t){debug("wrapped _read",t),r&&(r=!1,e.resume())},n},Readable._fromList=fromList;
|
|
@@ -157,12 +411,12 @@ LavaPack.loadBundle([
|
|
|
157
411
|
}
|
|
158
412
|
}
|
|
159
413
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_readable.js",}],
|
|
160
|
-
[
|
|
414
|
+
[30, {"./_stream_duplex":27,"core-util-is":66,"inherits":89}, function(){
|
|
161
415
|
with (this.scopeTerminator) {
|
|
162
416
|
with (this.globalThis) {
|
|
163
417
|
return function() {
|
|
164
418
|
'use strict';
|
|
165
|
-
// source: /home/runner/work/snaps
|
|
419
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_transform.js
|
|
166
420
|
return function (require, module, exports) {
|
|
167
421
|
"use strict";module.exports=Transform;var Duplex=require("./_stream_duplex"),util=require("core-util-is");function TransformState(r){this.afterTransform=function(t,n){return afterTransform(r,t,n)},this.needTransform=!1,this.transforming=!1,this.writecb=null,this.writechunk=null,this.writeencoding=null}function afterTransform(r,t,n){var e=r._transformState;e.transforming=!1;var i=e.writecb;if(!i)return r.emit("error",new Error("write callback called multiple times"));e.writechunk=null,e.writecb=null,null!=n&&r.push(n),i(t);var a=r._readableState;a.reading=!1,(a.needReadable||a.length<a.highWaterMark)&&r._read(a.highWaterMark)}function Transform(r){if(!(this instanceof Transform))return new Transform(r);Duplex.call(this,r),this._transformState=new TransformState(this);var t=this;this._readableState.needReadable=!0,this._readableState.sync=!1,r&&("function"==typeof r.transform&&(this._transform=r.transform),"function"==typeof r.flush&&(this._flush=r.flush)),this.once("prefinish",(function(){"function"==typeof this._flush?this._flush((function(r,n){done(t,r,n)})):done(t)}))}function done(r,t,n){if(t)return r.emit("error",t);null!=n&&r.push(n);var e=r._writableState,i=r._transformState;if(e.length)throw new Error("Calling transform done when ws.length != 0");if(i.transforming)throw new Error("Calling transform done when still transforming");return r.push(null)}util.inherits=require("inherits"),util.inherits(Transform,Duplex),Transform.prototype.push=function(r,t){return this._transformState.needTransform=!1,Duplex.prototype.push.call(this,r,t)},Transform.prototype._transform=function(r,t,n){throw new Error("_transform() is not implemented")},Transform.prototype._write=function(r,t,n){var e=this._transformState;if(e.writecb=n,e.writechunk=r,e.writeencoding=t,!e.transforming){var i=this._readableState;(e.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},Transform.prototype._read=function(r){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},Transform.prototype._destroy=function(r,t){var n=this;Duplex.prototype._destroy.call(this,r,(function(r){t(r),n.emit("close")}))};
|
|
168
422
|
|
|
@@ -171,12 +425,12 @@ LavaPack.loadBundle([
|
|
|
171
425
|
}
|
|
172
426
|
}
|
|
173
427
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_transform.js",}],
|
|
174
|
-
[
|
|
428
|
+
[31, {"./_stream_duplex":27,"./internal/streams/destroy":33,"./internal/streams/stream":34,"_process":94,"core-util-is":66,"inherits":89,"process-nextick-args":26,"safe-buffer":36,"timers":143,"util-deprecate":144}, function(){
|
|
175
429
|
with (this.scopeTerminator) {
|
|
176
430
|
with (this.globalThis) {
|
|
177
431
|
return function() {
|
|
178
432
|
'use strict';
|
|
179
|
-
// source: /home/runner/work/snaps
|
|
433
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_writable.js
|
|
180
434
|
return function (require, module, exports) {
|
|
181
435
|
(function (process,setImmediate){(function (){
|
|
182
436
|
"use strict";var processNextTick=require("process-nextick-args");function WriteReq(e,t,r){this.chunk=e,this.encoding=t,this.callback=r,this.next=null}function CorkedRequest(e){var t=this;this.next=null,this.entry=null,this.finish=function(){onCorkedFinish(t,e)}}module.exports=Writable;var Duplex,asyncWrite=!process.browser&&["v0.10","v0.9."].indexOf(process.version.slice(0,5))>-1?setImmediate:processNextTick;Writable.WritableState=WritableState;var util=require("core-util-is");util.inherits=require("inherits");var internalUtil={deprecate:require("util-deprecate")},Stream=require("./internal/streams/stream"),Buffer=require("safe-buffer").Buffer,OurUint8Array=global.Uint8Array||function(){};function _uint8ArrayToBuffer(e){return Buffer.from(e)}function _isUint8Array(e){return Buffer.isBuffer(e)||e instanceof OurUint8Array}var realHasInstance,destroyImpl=require("./internal/streams/destroy");function nop(){}function WritableState(e,t){Duplex=Duplex||require("./_stream_duplex"),e=e||{},this.objectMode=!!e.objectMode,t instanceof Duplex&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var r=e.highWaterMark,i=this.objectMode?16:16384;this.highWaterMark=r||0===r?r:i,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var n=!1===e.decodeStrings;this.decodeStrings=!n,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){onwrite(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new CorkedRequest(this)}function Writable(e){if(Duplex=Duplex||require("./_stream_duplex"),!(realHasInstance.call(Writable,this)||this instanceof Duplex))return new Writable(e);this._writableState=new WritableState(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),Stream.call(this)}function writeAfterEnd(e,t){var r=new Error("write after end");e.emit("error",r),processNextTick(t,r)}function validChunk(e,t,r,i){var n=!0,o=!1;return null===r?o=new TypeError("May not write null values to stream"):"string"==typeof r||void 0===r||t.objectMode||(o=new TypeError("Invalid non-string/buffer chunk")),o&&(e.emit("error",o),processNextTick(i,o),n=!1),n}function decodeChunk(e,t,r){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=Buffer.from(t,r)),t}function writeOrBuffer(e,t,r,i,n,o){if(!r){var s=decodeChunk(t,i,n);i!==s&&(r=!0,n="buffer",i=s)}var a=t.objectMode?1:i.length;t.length+=a;var f=t.length<t.highWaterMark;if(f||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:i,encoding:n,isBuf:r,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else doWrite(e,t,!1,a,i,n,o);return f}function doWrite(e,t,r,i,n,o,s){t.writelen=i,t.writecb=s,t.writing=!0,t.sync=!0,r?e._writev(n,t.onwrite):e._write(n,o,t.onwrite),t.sync=!1}function onwriteError(e,t,r,i,n){--t.pendingcb,r?(processNextTick(n,i),processNextTick(finishMaybe,e,t),e._writableState.errorEmitted=!0,e.emit("error",i)):(n(i),e._writableState.errorEmitted=!0,e.emit("error",i),finishMaybe(e,t))}function onwriteStateUpdate(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function onwrite(e,t){var r=e._writableState,i=r.sync,n=r.writecb;if(onwriteStateUpdate(r),t)onwriteError(e,r,i,t,n);else{var o=needFinish(r);o||r.corked||r.bufferProcessing||!r.bufferedRequest||clearBuffer(e,r),i?asyncWrite(afterWrite,e,r,o,n):afterWrite(e,r,o,n)}}function afterWrite(e,t,r,i){r||onwriteDrain(e,t),t.pendingcb--,i(),finishMaybe(e,t)}function onwriteDrain(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function clearBuffer(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var i=t.bufferedRequestCount,n=new Array(i),o=t.corkedRequestsFree;o.entry=r;for(var s=0,a=!0;r;)n[s]=r,r.isBuf||(a=!1),r=r.next,s+=1;n.allBuffers=a,doWrite(e,t,!0,t.length,n,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new CorkedRequest(t)}else{for(;r;){var f=r.chunk,u=r.encoding,l=r.callback;if(doWrite(e,t,!1,t.objectMode?1:f.length,f,u,l),r=r.next,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequestCount=0,t.bufferedRequest=r,t.bufferProcessing=!1}function needFinish(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function callFinal(e,t){e._final((function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),finishMaybe(e,t)}))}function prefinish(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,processNextTick(callFinal,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function finishMaybe(e,t){var r=needFinish(t);return r&&(prefinish(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),r}function endWritable(e,t,r){t.ending=!0,finishMaybe(e,t),r&&(t.finished?processNextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}function onCorkedFinish(e,t,r){var i=e.entry;for(e.entry=null;i;){var n=i.callback;t.pendingcb--,n(r),i=i.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}util.inherits(Writable,Stream),WritableState.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(WritableState.prototype,"buffer",{get:internalUtil.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(realHasInstance=Function.prototype[Symbol.hasInstance],Object.defineProperty(Writable,Symbol.hasInstance,{value:function(e){return!!realHasInstance.call(this,e)||e&&e._writableState instanceof WritableState}})):realHasInstance=function(e){return e instanceof this},Writable.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},Writable.prototype.write=function(e,t,r){var i=this._writableState,n=!1,o=_isUint8Array(e)&&!i.objectMode;return o&&!Buffer.isBuffer(e)&&(e=_uint8ArrayToBuffer(e)),"function"==typeof t&&(r=t,t=null),o?t="buffer":t||(t=i.defaultEncoding),"function"!=typeof r&&(r=nop),i.ended?writeAfterEnd(this,r):(o||validChunk(this,i,e,r))&&(i.pendingcb++,n=writeOrBuffer(this,i,o,e,t,r)),n},Writable.prototype.cork=function(){this._writableState.corked++},Writable.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||clearBuffer(this,e))},Writable.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Writable.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},Writable.prototype._writev=null,Writable.prototype.end=function(e,t,r){var i=this._writableState;"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),i.corked&&(i.corked=1,this.uncork()),i.ending||i.finished||endWritable(this,i,r)},Object.defineProperty(Writable.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),Writable.prototype.destroy=destroyImpl.destroy,Writable.prototype._undestroy=destroyImpl.undestroy,Writable.prototype._destroy=function(e,t){this.end(),t(e)};
|
|
@@ -187,12 +441,12 @@ LavaPack.loadBundle([
|
|
|
187
441
|
}
|
|
188
442
|
}
|
|
189
443
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/_stream_writable.js",}],
|
|
190
|
-
[
|
|
444
|
+
[32, {"safe-buffer":36}, function(){
|
|
191
445
|
with (this.scopeTerminator) {
|
|
192
446
|
with (this.globalThis) {
|
|
193
447
|
return function() {
|
|
194
448
|
'use strict';
|
|
195
|
-
// source: /home/runner/work/snaps
|
|
449
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/internal/streams/BufferList.js
|
|
196
450
|
return function (require, module, exports) {
|
|
197
451
|
"use strict";function _classCallCheck(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var Buffer=require("safe-buffer").Buffer;function copyBuffer(t,e,h){t.copy(e,h)}module.exports=function(){function t(){_classCallCheck(this,t),this.head=null,this.tail=null,this.length=0}return t.prototype.push=function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length},t.prototype.unshift=function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length},t.prototype.shift=function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},t.prototype.clear=function(){this.head=this.tail=null,this.length=0},t.prototype.join=function(t){if(0===this.length)return"";for(var e=this.head,h=""+e.data;e=e.next;)h+=t+e.data;return h},t.prototype.concat=function(t){if(0===this.length)return Buffer.alloc(0);if(1===this.length)return this.head.data;for(var e=Buffer.allocUnsafe(t>>>0),h=this.head,n=0;h;)copyBuffer(h.data,e,n),n+=h.data.length,h=h.next;return e},t}();
|
|
198
452
|
|
|
@@ -201,12 +455,12 @@ LavaPack.loadBundle([
|
|
|
201
455
|
}
|
|
202
456
|
}
|
|
203
457
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/internal/streams/BufferList.js",}],
|
|
204
|
-
[
|
|
458
|
+
[33, {"process-nextick-args":26}, function(){
|
|
205
459
|
with (this.scopeTerminator) {
|
|
206
460
|
with (this.globalThis) {
|
|
207
461
|
return function() {
|
|
208
462
|
'use strict';
|
|
209
|
-
// source: /home/runner/work/snaps
|
|
463
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/internal/streams/destroy.js
|
|
210
464
|
return function (require, module, exports) {
|
|
211
465
|
"use strict";var processNextTick=require("process-nextick-args");function destroy(t,e){var r=this,i=this._readableState&&this._readableState.destroyed,a=this._writableState&&this._writableState.destroyed;i||a?e?e(t):!t||this._writableState&&this._writableState.errorEmitted||processNextTick(emitErrorNT,this,t):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(t||null,(function(t){!e&&t?(processNextTick(emitErrorNT,r,t),r._writableState&&(r._writableState.errorEmitted=!0)):e&&e(t)})))}function undestroy(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function emitErrorNT(t,e){t.emit("error",e)}module.exports={destroy:destroy,undestroy:undestroy};
|
|
212
466
|
|
|
@@ -215,12 +469,12 @@ LavaPack.loadBundle([
|
|
|
215
469
|
}
|
|
216
470
|
}
|
|
217
471
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/internal/streams/destroy.js",}],
|
|
218
|
-
[
|
|
472
|
+
[34, {"events":75}, function(){
|
|
219
473
|
with (this.scopeTerminator) {
|
|
220
474
|
with (this.globalThis) {
|
|
221
475
|
return function() {
|
|
222
476
|
'use strict';
|
|
223
|
-
// source: /home/runner/work/snaps
|
|
477
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/internal/streams/stream-browser.js
|
|
224
478
|
return function (require, module, exports) {
|
|
225
479
|
module.exports=require("events").EventEmitter;
|
|
226
480
|
|
|
@@ -229,12 +483,12 @@ module.exports=require("events").EventEmitter;
|
|
|
229
483
|
}
|
|
230
484
|
}
|
|
231
485
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/lib/internal/streams/stream-browser.js",}],
|
|
232
|
-
[
|
|
486
|
+
[35, {"./lib/_stream_duplex.js":27,"./lib/_stream_passthrough.js":28,"./lib/_stream_readable.js":29,"./lib/_stream_transform.js":30,"./lib/_stream_writable.js":31}, function(){
|
|
233
487
|
with (this.scopeTerminator) {
|
|
234
488
|
with (this.globalThis) {
|
|
235
489
|
return function() {
|
|
236
490
|
'use strict';
|
|
237
|
-
// source: /home/runner/work/snaps
|
|
491
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/readable-stream/readable-browser.js
|
|
238
492
|
return function (require, module, exports) {
|
|
239
493
|
exports=module.exports=require("./lib/_stream_readable.js"),exports.Stream=exports,exports.Readable=exports,exports.Writable=require("./lib/_stream_writable.js"),exports.Duplex=require("./lib/_stream_duplex.js"),exports.Transform=require("./lib/_stream_transform.js"),exports.PassThrough=require("./lib/_stream_passthrough.js");
|
|
240
494
|
|
|
@@ -243,12 +497,12 @@ exports=module.exports=require("./lib/_stream_readable.js"),exports.Stream=expor
|
|
|
243
497
|
}
|
|
244
498
|
}
|
|
245
499
|
}, {package:"@metamask/post-message-stream>readable-stream",file:"../../node_modules/@metamask/post-message-stream/node_modules/readable-stream/readable-browser.js",}],
|
|
246
|
-
[
|
|
500
|
+
[36, {"buffer":64}, function(){
|
|
247
501
|
with (this.scopeTerminator) {
|
|
248
502
|
with (this.globalThis) {
|
|
249
503
|
return function() {
|
|
250
504
|
'use strict';
|
|
251
|
-
// source: /home/runner/work/snaps
|
|
505
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/safe-buffer/index.js
|
|
252
506
|
return function (require, module, exports) {
|
|
253
507
|
var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(var e in f)r[e]=f[e]}function SafeBuffer(f,r,e){return Buffer(f,r,e)}Buffer.from&&Buffer.alloc&&Buffer.allocUnsafe&&Buffer.allocUnsafeSlow?module.exports=buffer:(copyProps(buffer,exports),exports.Buffer=SafeBuffer),copyProps(Buffer,SafeBuffer),SafeBuffer.from=function(f,r,e){if("number"==typeof f)throw new TypeError("Argument must not be a number");return Buffer(f,r,e)},SafeBuffer.alloc=function(f,r,e){if("number"!=typeof f)throw new TypeError("Argument must be a number");var u=Buffer(f);return void 0!==r?"string"==typeof e?u.fill(r,e):u.fill(r):u.fill(0),u},SafeBuffer.allocUnsafe=function(f){if("number"!=typeof f)throw new TypeError("Argument must be a number");return Buffer(f)},SafeBuffer.allocUnsafeSlow=function(f){if("number"!=typeof f)throw new TypeError("Argument must be a number");return buffer.SlowBuffer(f)};
|
|
254
508
|
|
|
@@ -257,12 +511,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
257
511
|
}
|
|
258
512
|
}
|
|
259
513
|
}, {package:"@metamask/post-message-stream>readable-stream>safe-buffer",file:"../../node_modules/@metamask/post-message-stream/node_modules/safe-buffer/index.js",}],
|
|
260
|
-
[
|
|
514
|
+
[37, {"safe-buffer":36}, function(){
|
|
261
515
|
with (this.scopeTerminator) {
|
|
262
516
|
with (this.globalThis) {
|
|
263
517
|
return function() {
|
|
264
518
|
'use strict';
|
|
265
|
-
// source: /home/runner/work/snaps
|
|
519
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/post-message-stream/node_modules/string_decoder/lib/string_decoder.js
|
|
266
520
|
return function (require, module, exports) {
|
|
267
521
|
"use strict";var Buffer=require("safe-buffer").Buffer,isEncoding=Buffer.isEncoding||function(t){switch((t=""+t)&&t.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function _normalizeEncoding(t){if(!t)return"utf8";for(var e;;)switch(t){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return t;default:if(e)return;t=(""+t).toLowerCase(),e=!0}}function normalizeEncoding(t){var e=_normalizeEncoding(t);if("string"!=typeof e&&(Buffer.isEncoding===isEncoding||!isEncoding(t)))throw new Error("Unknown encoding: "+t);return e||t}function StringDecoder(t){var e;switch(this.encoding=normalizeEncoding(t),this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,e=4;break;case"utf8":this.fillLast=utf8FillLast,e=4;break;case"base64":this.text=base64Text,this.end=base64End,e=3;break;default:return this.write=simpleWrite,void(this.end=simpleEnd)}this.lastNeed=0,this.lastTotal=0,this.lastChar=Buffer.allocUnsafe(e)}function utf8CheckByte(t){return t<=127?0:t>>5==6?2:t>>4==14?3:t>>3==30?4:-1}function utf8CheckIncomplete(t,e,s){var i=e.length-1;if(i<s)return 0;var a=utf8CheckByte(e[i]);return a>=0?(a>0&&(t.lastNeed=a-1),a):--i<s?0:(a=utf8CheckByte(e[i]))>=0?(a>0&&(t.lastNeed=a-2),a):--i<s?0:(a=utf8CheckByte(e[i]))>=0?(a>0&&(2===a?a=0:t.lastNeed=a-3),a):0}function utf8CheckExtraBytes(t,e,s){if(128!=(192&e[0]))return t.lastNeed=0,"�".repeat(s);if(t.lastNeed>1&&e.length>1){if(128!=(192&e[1]))return t.lastNeed=1,"�".repeat(s+1);if(t.lastNeed>2&&e.length>2&&128!=(192&e[2]))return t.lastNeed=2,"�".repeat(s+2)}}function utf8FillLast(t){var e=this.lastTotal-this.lastNeed,s=utf8CheckExtraBytes(this,t,e);return void 0!==s?s:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(t.copy(this.lastChar,e,0,t.length),void(this.lastNeed-=t.length))}function utf8Text(t,e){var s=utf8CheckIncomplete(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=s;var i=t.length-(s-this.lastNeed);return t.copy(this.lastChar,0,i),t.toString("utf8",e,i)}function utf8End(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+"�".repeat(this.lastTotal-this.lastNeed):e}function utf16Text(t,e){if((t.length-e)%2==0){var s=t.toString("utf16le",e);if(s){var i=s.charCodeAt(s.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],s.slice(0,-1)}return s}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function utf16End(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var s=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,s)}return e}function base64Text(t,e){var s=(t.length-e)%3;return 0===s?t.toString("base64",e):(this.lastNeed=3-s,this.lastTotal=3,1===s?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-s))}function base64End(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function simpleWrite(t){return t.toString(this.encoding)}function simpleEnd(t){return t&&t.length?this.write(t):""}exports.StringDecoder=StringDecoder,StringDecoder.prototype.write=function(t){if(0===t.length)return"";var e,s;if(this.lastNeed){if(void 0===(e=this.fillLast(t)))return"";s=this.lastNeed,this.lastNeed=0}else s=0;return s<t.length?e?e+this.text(t,s):this.text(t,s):e||""},StringDecoder.prototype.end=utf8End,StringDecoder.prototype.text=utf8Text,StringDecoder.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length};
|
|
268
522
|
|
|
@@ -271,43 +525,43 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
271
525
|
}
|
|
272
526
|
}
|
|
273
527
|
}, {package:"@metamask/post-message-stream>readable-stream>string_decoder",file:"../../node_modules/@metamask/post-message-stream/node_modules/string_decoder/lib/string_decoder.js",}],
|
|
274
|
-
[
|
|
528
|
+
[38, {"superstruct":142}, function(){
|
|
275
529
|
with (this.scopeTerminator) {
|
|
276
530
|
with (this.globalThis) {
|
|
277
531
|
return function() {
|
|
278
532
|
'use strict';
|
|
279
|
-
// source: /home/runner/work/snaps
|
|
533
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/assert.js
|
|
280
534
|
return function (require, module, exports) {
|
|
281
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.assertExhaustive=exports.assertStruct=exports.assert=exports.AssertionError=void 0;const superstruct_1=require("superstruct");function isErrorWithMessage(r){return"object"==typeof r&&null!==r&&"message"in r}function isConstructable(r){
|
|
535
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.assertExhaustive=exports.assertStruct=exports.assert=exports.AssertionError=void 0;const superstruct_1=require("superstruct");function isErrorWithMessage(r){return"object"==typeof r&&null!==r&&"message"in r}function isConstructable(r){return Boolean("string"==typeof r?.prototype?.constructor?.name)}function getErrorMessage(r){const s=isErrorWithMessage(r)?r.message:String(r);return s.endsWith(".")?s.slice(0,-1):s}function getError(r,s){return isConstructable(r)?new r({message:s}):r({message:s})}class AssertionError extends Error{constructor(r){super(r.message),this.code="ERR_ASSERTION"}}function assert(r,s="Assertion failed.",t=AssertionError){if(!r){if(s instanceof Error)throw s;throw getError(t,s)}}function assertStruct(r,s,t="Assertion failed",e=AssertionError){try{(0,superstruct_1.assert)(r,s)}catch(r){throw getError(e,`${t}: ${getErrorMessage(r)}.`)}}function assertExhaustive(r){throw new Error("Invalid branch reached. Should be detected during compilation.")}exports.AssertionError=AssertionError,exports.assert=assert,exports.assertStruct=assertStruct,exports.assertExhaustive=assertExhaustive;
|
|
282
536
|
|
|
283
537
|
};
|
|
284
538
|
};
|
|
285
539
|
}
|
|
286
540
|
}
|
|
287
541
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/assert.js",}],
|
|
288
|
-
[
|
|
542
|
+
[39, {"./assert":38,"superstruct":142}, function(){
|
|
289
543
|
with (this.scopeTerminator) {
|
|
290
544
|
with (this.globalThis) {
|
|
291
545
|
return function() {
|
|
292
546
|
'use strict';
|
|
293
|
-
// source: /home/runner/work/snaps
|
|
547
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/base64.js
|
|
294
548
|
return function (require, module, exports) {
|
|
295
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.base64=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert"),base64=(e,r={})=>{
|
|
549
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.base64=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert"),base64=(e,r={})=>{const s=r.paddingRequired??!1,t=r.characterSet??"base64";let a,u;return"base64"===t?a=String.raw`[A-Za-z0-9+\/]`:((0,assert_1.assert)("base64url"===t),a=String.raw`[-_A-Za-z0-9]`),u=s?new RegExp(`^(?:${a}{4})*(?:${a}{3}=|${a}{2}==)?$`,"u"):new RegExp(`^(?:${a}{4})*(?:${a}{2,3}|${a}{3}=|${a}{2}==)?$`,"u"),(0,superstruct_1.pattern)(e,u)};exports.base64=base64;
|
|
296
550
|
|
|
297
551
|
};
|
|
298
552
|
};
|
|
299
553
|
}
|
|
300
554
|
}
|
|
301
555
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/base64.js",}],
|
|
302
|
-
[
|
|
556
|
+
[40, {"./assert":38,"./hex":45,"buffer":64}, function(){
|
|
303
557
|
with (this.scopeTerminator) {
|
|
304
558
|
with (this.globalThis) {
|
|
305
559
|
return function() {
|
|
306
560
|
'use strict';
|
|
307
|
-
// source: /home/runner/work/snaps
|
|
561
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/bytes.js
|
|
308
562
|
return function (require, module, exports) {
|
|
309
563
|
(function (Buffer){(function (){
|
|
310
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.createDataView=exports.concatBytes=exports.valueToBytes=exports.stringToBytes=exports.numberToBytes=exports.signedBigIntToBytes=exports.bigIntToBytes=exports.hexToBytes=exports.bytesToString=exports.bytesToNumber=exports.bytesToSignedBigInt=exports.bytesToBigInt=exports.bytesToHex=exports.assertIsBytes=exports.isBytes=void 0;const assert_1=require("./assert"),hex_1=require("./hex"),HEX_MINIMUM_NUMBER_CHARACTER=48,HEX_MAXIMUM_NUMBER_CHARACTER=58,HEX_CHARACTER_OFFSET=87;function getPrecomputedHexValuesBuilder(){const e=[];return()=>{if(0===e.length)for(let t=0;t<256;t++)e.push(t.toString(16).padStart(2,"0"));return e}}const getPrecomputedHexValues=getPrecomputedHexValuesBuilder();function isBytes(e){return e instanceof Uint8Array}function assertIsBytes(e){(0,assert_1.assert)(isBytes(e),"Value must be a Uint8Array.")}function bytesToHex(e){if(assertIsBytes(e),0===e.length)return"0x";const t=getPrecomputedHexValues(),s=new Array(e.length);for(let r=0;r<e.length;r++)s[r]=t[e[r]];return(0,hex_1.add0x)(s.join(""))}function bytesToBigInt(e){assertIsBytes(e);const t=bytesToHex(e);return BigInt(t)}function bytesToSignedBigInt(e){assertIsBytes(e);let t=BigInt(0);for(const s of e)t=(t<<BigInt(8))+BigInt(s);return BigInt.asIntN(8*e.length,t)}function bytesToNumber(e){assertIsBytes(e);const t=bytesToBigInt(e);return(0,assert_1.assert)(t<=BigInt(Number.MAX_SAFE_INTEGER),"Number is not a safe integer. Use `bytesToBigInt` instead."),Number(t)}function bytesToString(e){return assertIsBytes(e),(new TextDecoder).decode(e)}function hexToBytes(e){
|
|
564
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.createDataView=exports.concatBytes=exports.valueToBytes=exports.stringToBytes=exports.numberToBytes=exports.signedBigIntToBytes=exports.bigIntToBytes=exports.hexToBytes=exports.bytesToString=exports.bytesToNumber=exports.bytesToSignedBigInt=exports.bytesToBigInt=exports.bytesToHex=exports.assertIsBytes=exports.isBytes=void 0;const assert_1=require("./assert"),hex_1=require("./hex"),HEX_MINIMUM_NUMBER_CHARACTER=48,HEX_MAXIMUM_NUMBER_CHARACTER=58,HEX_CHARACTER_OFFSET=87;function getPrecomputedHexValuesBuilder(){const e=[];return()=>{if(0===e.length)for(let t=0;t<256;t++)e.push(t.toString(16).padStart(2,"0"));return e}}const getPrecomputedHexValues=getPrecomputedHexValuesBuilder();function isBytes(e){return e instanceof Uint8Array}function assertIsBytes(e){(0,assert_1.assert)(isBytes(e),"Value must be a Uint8Array.")}function bytesToHex(e){if(assertIsBytes(e),0===e.length)return"0x";const t=getPrecomputedHexValues(),s=new Array(e.length);for(let r=0;r<e.length;r++)s[r]=t[e[r]];return(0,hex_1.add0x)(s.join(""))}function bytesToBigInt(e){assertIsBytes(e);const t=bytesToHex(e);return BigInt(t)}function bytesToSignedBigInt(e){assertIsBytes(e);let t=BigInt(0);for(const s of e)t=(t<<BigInt(8))+BigInt(s);return BigInt.asIntN(8*e.length,t)}function bytesToNumber(e){assertIsBytes(e);const t=bytesToBigInt(e);return(0,assert_1.assert)(t<=BigInt(Number.MAX_SAFE_INTEGER),"Number is not a safe integer. Use `bytesToBigInt` instead."),Number(t)}function bytesToString(e){return assertIsBytes(e),(new TextDecoder).decode(e)}function hexToBytes(e){if("0x"===e?.toLowerCase?.())return new Uint8Array;(0,hex_1.assertIsHexString)(e);const t=(0,hex_1.remove0x)(e).toLowerCase(),s=t.length%2==0?t:`0${t}`,r=new Uint8Array(s.length/2);for(let e=0;e<r.length;e++){const t=s.charCodeAt(2*e),n=s.charCodeAt(2*e+1),o=t-(t<HEX_MAXIMUM_NUMBER_CHARACTER?HEX_MINIMUM_NUMBER_CHARACTER:HEX_CHARACTER_OFFSET),i=n-(n<HEX_MAXIMUM_NUMBER_CHARACTER?HEX_MINIMUM_NUMBER_CHARACTER:HEX_CHARACTER_OFFSET);r[e]=16*o+i}return r}function bigIntToBytes(e){(0,assert_1.assert)("bigint"==typeof e,"Value must be a bigint."),(0,assert_1.assert)(e>=BigInt(0),"Value must be a non-negative bigint.");return hexToBytes(e.toString(16))}function bigIntFits(e,t){(0,assert_1.assert)(t>0);const s=e>>BigInt(31);return!((~e&s)+(e&~s)>>BigInt(8*t-1))}function signedBigIntToBytes(e,t){(0,assert_1.assert)("bigint"==typeof e,"Value must be a bigint."),(0,assert_1.assert)("number"==typeof t,"Byte length must be a number."),(0,assert_1.assert)(t>0,"Byte length must be greater than 0."),(0,assert_1.assert)(bigIntFits(e,t),"Byte length is too small to represent the given value.");let s=e;const r=new Uint8Array(t);for(let e=0;e<r.length;e++)r[e]=Number(BigInt.asUintN(8,s)),s>>=BigInt(8);return r.reverse()}function numberToBytes(e){(0,assert_1.assert)("number"==typeof e,"Value must be a number."),(0,assert_1.assert)(e>=0,"Value must be a non-negative number."),(0,assert_1.assert)(Number.isSafeInteger(e),"Value is not a safe integer. Use `bigIntToBytes` instead.");return hexToBytes(e.toString(16))}function stringToBytes(e){return(0,assert_1.assert)("string"==typeof e,"Value must be a string."),(new TextEncoder).encode(e)}function valueToBytes(e){if("bigint"==typeof e)return bigIntToBytes(e);if("number"==typeof e)return numberToBytes(e);if("string"==typeof e)return e.startsWith("0x")?hexToBytes(e):stringToBytes(e);if(isBytes(e))return e;throw new TypeError(`Unsupported value type: "${typeof e}".`)}function concatBytes(e){const t=new Array(e.length);let s=0;for(let r=0;r<e.length;r++){const n=valueToBytes(e[r]);t[r]=n,s+=n.length}const r=new Uint8Array(s);for(let e=0,s=0;e<t.length;e++)r.set(t[e],s),s+=t[e].length;return r}function createDataView(e){if("undefined"!=typeof Buffer&&e instanceof Buffer){const t=e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength);return new DataView(t)}return new DataView(e.buffer,e.byteOffset,e.byteLength)}exports.isBytes=isBytes,exports.assertIsBytes=assertIsBytes,exports.bytesToHex=bytesToHex,exports.bytesToBigInt=bytesToBigInt,exports.bytesToSignedBigInt=bytesToSignedBigInt,exports.bytesToNumber=bytesToNumber,exports.bytesToString=bytesToString,exports.hexToBytes=hexToBytes,exports.bigIntToBytes=bigIntToBytes,exports.signedBigIntToBytes=signedBigIntToBytes,exports.numberToBytes=numberToBytes,exports.stringToBytes=stringToBytes,exports.valueToBytes=valueToBytes,exports.concatBytes=concatBytes,exports.createDataView=createDataView;
|
|
311
565
|
|
|
312
566
|
}).call(this)}).call(this,require("buffer").Buffer)
|
|
313
567
|
};
|
|
@@ -315,12 +569,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
315
569
|
}
|
|
316
570
|
}
|
|
317
571
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/bytes.js",}],
|
|
318
|
-
[
|
|
572
|
+
[41, {"./base64":39,"superstruct":142}, function(){
|
|
319
573
|
with (this.scopeTerminator) {
|
|
320
574
|
with (this.globalThis) {
|
|
321
575
|
return function() {
|
|
322
576
|
'use strict';
|
|
323
|
-
// source: /home/runner/work/snaps
|
|
577
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/checksum.js
|
|
324
578
|
return function (require, module, exports) {
|
|
325
579
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ChecksumStruct=void 0;const superstruct_1=require("superstruct"),base64_1=require("./base64");exports.ChecksumStruct=(0,superstruct_1.size)((0,base64_1.base64)((0,superstruct_1.string)(),{paddingRequired:!0}),44,44);
|
|
326
580
|
|
|
@@ -329,12 +583,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
329
583
|
}
|
|
330
584
|
}
|
|
331
585
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/checksum.js",}],
|
|
332
|
-
[
|
|
586
|
+
[42, {"./assert":38,"./bytes":40,"./hex":45,"superstruct":142}, function(){
|
|
333
587
|
with (this.scopeTerminator) {
|
|
334
588
|
with (this.globalThis) {
|
|
335
589
|
return function() {
|
|
336
590
|
'use strict';
|
|
337
|
-
// source: /home/runner/work/snaps
|
|
591
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/coercers.js
|
|
338
592
|
return function (require, module, exports) {
|
|
339
593
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.createHex=exports.createBytes=exports.createBigInt=exports.createNumber=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert"),bytes_1=require("./bytes"),hex_1=require("./hex"),NumberLikeStruct=(0,superstruct_1.union)([(0,superstruct_1.number)(),(0,superstruct_1.bigint)(),(0,superstruct_1.string)(),hex_1.StrictHexStruct]),NumberCoercer=(0,superstruct_1.coerce)((0,superstruct_1.number)(),NumberLikeStruct,Number),BigIntCoercer=(0,superstruct_1.coerce)((0,superstruct_1.bigint)(),NumberLikeStruct,BigInt),BytesLikeStruct=(0,superstruct_1.union)([hex_1.StrictHexStruct,(0,superstruct_1.instance)(Uint8Array)]),BytesCoercer=(0,superstruct_1.coerce)((0,superstruct_1.instance)(Uint8Array),(0,superstruct_1.union)([hex_1.StrictHexStruct]),bytes_1.hexToBytes),HexCoercer=(0,superstruct_1.coerce)(hex_1.StrictHexStruct,(0,superstruct_1.instance)(Uint8Array),bytes_1.bytesToHex);function createNumber(e){try{const r=(0,superstruct_1.create)(e,NumberCoercer);return(0,assert_1.assert)(Number.isFinite(r),`Expected a number-like value, got "${e}".`),r}catch(r){if(r instanceof superstruct_1.StructError)throw new Error(`Expected a number-like value, got "${e}".`);throw r}}function createBigInt(e){try{return(0,superstruct_1.create)(e,BigIntCoercer)}catch(e){if(e instanceof superstruct_1.StructError)throw new Error(`Expected a number-like value, got "${String(e.value)}".`);throw e}}function createBytes(e){if("string"==typeof e&&"0x"===e.toLowerCase())return new Uint8Array;try{return(0,superstruct_1.create)(e,BytesCoercer)}catch(e){if(e instanceof superstruct_1.StructError)throw new Error(`Expected a bytes-like value, got "${String(e.value)}".`);throw e}}function createHex(e){if(e instanceof Uint8Array&&0===e.length||"string"==typeof e&&"0x"===e.toLowerCase())return"0x";try{return(0,superstruct_1.create)(e,HexCoercer)}catch(e){if(e instanceof superstruct_1.StructError)throw new Error(`Expected a bytes-like value, got "${String(e.value)}".`);throw e}}exports.createNumber=createNumber,exports.createBigInt=createBigInt,exports.createBytes=createBytes,exports.createHex=createHex;
|
|
340
594
|
|
|
@@ -343,12 +597,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
343
597
|
}
|
|
344
598
|
}
|
|
345
599
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/coercers.js",}],
|
|
346
|
-
[
|
|
600
|
+
[43, {}, function(){
|
|
347
601
|
with (this.scopeTerminator) {
|
|
348
602
|
with (this.globalThis) {
|
|
349
603
|
return function() {
|
|
350
604
|
'use strict';
|
|
351
|
-
// source: /home/runner/work/snaps
|
|
605
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/collections.js
|
|
352
606
|
return function (require, module, exports) {
|
|
353
607
|
"use strict";var _FrozenMap_map,_FrozenSet_set,__classPrivateFieldSet=this&&this.__classPrivateFieldSet||function(e,t,r,s,a){if("m"===s)throw new TypeError("Private method is not writable");if("a"===s&&!a)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!a:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===s?a.call(e,r):a?a.value=r:t.set(e,r),r},__classPrivateFieldGet=this&&this.__classPrivateFieldGet||function(e,t,r,s){if("a"===r&&!s)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!s:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?s:"a"===r?s.call(e):s?s.value:t.get(e)};Object.defineProperty(exports,"__esModule",{value:!0}),exports.FrozenSet=exports.FrozenMap=void 0;class FrozenMap{constructor(e){_FrozenMap_map.set(this,void 0),__classPrivateFieldSet(this,_FrozenMap_map,new Map(e),"f"),Object.freeze(this)}get size(){return __classPrivateFieldGet(this,_FrozenMap_map,"f").size}[(_FrozenMap_map=new WeakMap,Symbol.iterator)](){return __classPrivateFieldGet(this,_FrozenMap_map,"f")[Symbol.iterator]()}entries(){return __classPrivateFieldGet(this,_FrozenMap_map,"f").entries()}forEach(e,t){return __classPrivateFieldGet(this,_FrozenMap_map,"f").forEach(((r,s,a)=>e.call(t,r,s,this)))}get(e){return __classPrivateFieldGet(this,_FrozenMap_map,"f").get(e)}has(e){return __classPrivateFieldGet(this,_FrozenMap_map,"f").has(e)}keys(){return __classPrivateFieldGet(this,_FrozenMap_map,"f").keys()}values(){return __classPrivateFieldGet(this,_FrozenMap_map,"f").values()}toString(){return`FrozenMap(${this.size}) {${this.size>0?` ${[...this.entries()].map((([e,t])=>`${String(e)} => ${String(t)}`)).join(", ")} `:""}}`}}exports.FrozenMap=FrozenMap;class FrozenSet{constructor(e){_FrozenSet_set.set(this,void 0),__classPrivateFieldSet(this,_FrozenSet_set,new Set(e),"f"),Object.freeze(this)}get size(){return __classPrivateFieldGet(this,_FrozenSet_set,"f").size}[(_FrozenSet_set=new WeakMap,Symbol.iterator)](){return __classPrivateFieldGet(this,_FrozenSet_set,"f")[Symbol.iterator]()}entries(){return __classPrivateFieldGet(this,_FrozenSet_set,"f").entries()}forEach(e,t){return __classPrivateFieldGet(this,_FrozenSet_set,"f").forEach(((r,s,a)=>e.call(t,r,s,this)))}has(e){return __classPrivateFieldGet(this,_FrozenSet_set,"f").has(e)}keys(){return __classPrivateFieldGet(this,_FrozenSet_set,"f").keys()}values(){return __classPrivateFieldGet(this,_FrozenSet_set,"f").values()}toString(){return`FrozenSet(${this.size}) {${this.size>0?` ${[...this.values()].map((e=>String(e))).join(", ")} `:""}}`}}exports.FrozenSet=FrozenSet,Object.freeze(FrozenMap),Object.freeze(FrozenMap.prototype),Object.freeze(FrozenSet),Object.freeze(FrozenSet.prototype);
|
|
354
608
|
|
|
@@ -357,12 +611,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
357
611
|
}
|
|
358
612
|
}
|
|
359
613
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/collections.js",}],
|
|
360
|
-
[
|
|
614
|
+
[44, {}, function(){
|
|
361
615
|
with (this.scopeTerminator) {
|
|
362
616
|
with (this.globalThis) {
|
|
363
617
|
return function() {
|
|
364
618
|
'use strict';
|
|
365
|
-
// source: /home/runner/work/snaps
|
|
619
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/encryption-types.js
|
|
366
620
|
return function (require, module, exports) {
|
|
367
621
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
368
622
|
|
|
@@ -371,12 +625,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
371
625
|
}
|
|
372
626
|
}
|
|
373
627
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/encryption-types.js",}],
|
|
374
|
-
[
|
|
628
|
+
[45, {"./assert":38,"superstruct":142}, function(){
|
|
375
629
|
with (this.scopeTerminator) {
|
|
376
630
|
with (this.globalThis) {
|
|
377
631
|
return function() {
|
|
378
632
|
'use strict';
|
|
379
|
-
// source: /home/runner/work/snaps
|
|
633
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/hex.js
|
|
380
634
|
return function (require, module, exports) {
|
|
381
635
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.remove0x=exports.add0x=exports.assertIsStrictHexString=exports.assertIsHexString=exports.isStrictHexString=exports.isHexString=exports.StrictHexStruct=exports.HexStruct=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert");function isHexString(t){return(0,superstruct_1.is)(t,exports.HexStruct)}function isStrictHexString(t){return(0,superstruct_1.is)(t,exports.StrictHexStruct)}function assertIsHexString(t){(0,assert_1.assert)(isHexString(t),"Value must be a hexadecimal string.")}function assertIsStrictHexString(t){(0,assert_1.assert)(isStrictHexString(t),'Value must be a hexadecimal string, starting with "0x".')}function add0x(t){return t.startsWith("0x")?t:t.startsWith("0X")?`0x${t.substring(2)}`:`0x${t}`}function remove0x(t){return t.startsWith("0x")||t.startsWith("0X")?t.substring(2):t}exports.HexStruct=(0,superstruct_1.pattern)((0,superstruct_1.string)(),/^(?:0x)?[0-9a-f]+$/iu),exports.StrictHexStruct=(0,superstruct_1.pattern)((0,superstruct_1.string)(),/^0x[0-9a-f]+$/iu),exports.isHexString=isHexString,exports.isStrictHexString=isStrictHexString,exports.assertIsHexString=assertIsHexString,exports.assertIsStrictHexString=assertIsStrictHexString,exports.add0x=add0x,exports.remove0x=remove0x;
|
|
382
636
|
|
|
@@ -385,12 +639,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
385
639
|
}
|
|
386
640
|
}
|
|
387
641
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/hex.js",}],
|
|
388
|
-
[
|
|
642
|
+
[46, {"./assert":38,"./base64":39,"./bytes":40,"./checksum":41,"./coercers":42,"./collections":43,"./encryption-types":44,"./hex":45,"./json":47,"./keyring":48,"./logging":49,"./misc":50,"./number":51,"./opaque":52,"./time":53,"./transaction-types":54,"./versions":55}, function(){
|
|
389
643
|
with (this.scopeTerminator) {
|
|
390
644
|
with (this.globalThis) {
|
|
391
645
|
return function() {
|
|
392
646
|
'use strict';
|
|
393
|
-
// source: /home/runner/work/snaps
|
|
647
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/index.js
|
|
394
648
|
return function (require, module, exports) {
|
|
395
649
|
"use strict";var __createBinding=this&&this.__createBinding||(Object.create?function(e,r,t,o){void 0===o&&(o=t);var i=Object.getOwnPropertyDescriptor(r,t);i&&!("get"in i?!r.__esModule:i.writable||i.configurable)||(i={enumerable:!0,get:function(){return r[t]}}),Object.defineProperty(e,o,i)}:function(e,r,t,o){void 0===o&&(o=t),e[o]=r[t]}),__exportStar=this&&this.__exportStar||function(e,r){for(var t in e)"default"===t||Object.prototype.hasOwnProperty.call(r,t)||__createBinding(r,e,t)};Object.defineProperty(exports,"__esModule",{value:!0}),__exportStar(require("./assert"),exports),__exportStar(require("./base64"),exports),__exportStar(require("./bytes"),exports),__exportStar(require("./checksum"),exports),__exportStar(require("./coercers"),exports),__exportStar(require("./collections"),exports),__exportStar(require("./encryption-types"),exports),__exportStar(require("./hex"),exports),__exportStar(require("./json"),exports),__exportStar(require("./keyring"),exports),__exportStar(require("./logging"),exports),__exportStar(require("./misc"),exports),__exportStar(require("./number"),exports),__exportStar(require("./opaque"),exports),__exportStar(require("./time"),exports),__exportStar(require("./transaction-types"),exports),__exportStar(require("./versions"),exports);
|
|
396
650
|
|
|
@@ -399,26 +653,26 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
399
653
|
}
|
|
400
654
|
}
|
|
401
655
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/index.js",}],
|
|
402
|
-
[
|
|
656
|
+
[47, {"./assert":38,"superstruct":142}, function(){
|
|
403
657
|
with (this.scopeTerminator) {
|
|
404
658
|
with (this.globalThis) {
|
|
405
659
|
return function() {
|
|
406
660
|
'use strict';
|
|
407
|
-
// source: /home/runner/work/snaps
|
|
661
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/json.js
|
|
408
662
|
return function (require, module, exports) {
|
|
409
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.getJsonRpcIdValidator=exports.assertIsJsonRpcError=exports.isJsonRpcError=exports.assertIsJsonRpcFailure=exports.isJsonRpcFailure=exports.assertIsJsonRpcSuccess=exports.isJsonRpcSuccess=exports.assertIsJsonRpcResponse=exports.isJsonRpcResponse=exports.assertIsPendingJsonRpcResponse=exports.isPendingJsonRpcResponse=exports.JsonRpcResponseStruct=exports.JsonRpcFailureStruct=exports.JsonRpcSuccessStruct=exports.PendingJsonRpcResponseStruct=exports.assertIsJsonRpcRequest=exports.isJsonRpcRequest=exports.assertIsJsonRpcNotification=exports.isJsonRpcNotification=exports.JsonRpcNotificationStruct=exports.JsonRpcRequestStruct=exports.JsonRpcParamsStruct=exports.JsonRpcErrorStruct=exports.JsonRpcIdStruct=exports.JsonRpcVersionStruct=exports.jsonrpc2=exports.getJsonSize=exports.isValidJson=exports.JsonStruct=exports.UnsafeJsonStruct=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert"),finiteNumber=()=>(0,superstruct_1.define)("finite number",(s=>(0,superstruct_1.is)(s,(0,superstruct_1.number)())&&Number.isFinite(s)));function isValidJson(s){return(0,superstruct_1.
|
|
663
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.getJsonRpcIdValidator=exports.assertIsJsonRpcError=exports.isJsonRpcError=exports.assertIsJsonRpcFailure=exports.isJsonRpcFailure=exports.assertIsJsonRpcSuccess=exports.isJsonRpcSuccess=exports.assertIsJsonRpcResponse=exports.isJsonRpcResponse=exports.assertIsPendingJsonRpcResponse=exports.isPendingJsonRpcResponse=exports.JsonRpcResponseStruct=exports.JsonRpcFailureStruct=exports.JsonRpcSuccessStruct=exports.PendingJsonRpcResponseStruct=exports.assertIsJsonRpcRequest=exports.isJsonRpcRequest=exports.assertIsJsonRpcNotification=exports.isJsonRpcNotification=exports.JsonRpcNotificationStruct=exports.JsonRpcRequestStruct=exports.JsonRpcParamsStruct=exports.JsonRpcErrorStruct=exports.JsonRpcIdStruct=exports.JsonRpcVersionStruct=exports.jsonrpc2=exports.getJsonSize=exports.getSafeJson=exports.isValidJson=exports.JsonStruct=exports.UnsafeJsonStruct=void 0;const superstruct_1=require("superstruct"),assert_1=require("./assert"),finiteNumber=()=>(0,superstruct_1.define)("finite number",(s=>(0,superstruct_1.is)(s,(0,superstruct_1.number)())&&Number.isFinite(s)));function isValidJson(s){try{return getSafeJson(s),!0}catch{return!1}}function getSafeJson(s){return(0,superstruct_1.create)(s,exports.JsonStruct)}function getJsonSize(s){(0,assert_1.assertStruct)(s,exports.JsonStruct,"Invalid JSON value");const t=JSON.stringify(s);return(new TextEncoder).encode(t).byteLength}function isJsonRpcNotification(s){return(0,superstruct_1.is)(s,exports.JsonRpcNotificationStruct)}function assertIsJsonRpcNotification(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcNotificationStruct,"Invalid JSON-RPC notification",t)}function isJsonRpcRequest(s){return(0,superstruct_1.is)(s,exports.JsonRpcRequestStruct)}function assertIsJsonRpcRequest(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcRequestStruct,"Invalid JSON-RPC request",t)}function isPendingJsonRpcResponse(s){return(0,superstruct_1.is)(s,exports.PendingJsonRpcResponseStruct)}function assertIsPendingJsonRpcResponse(s,t){(0,assert_1.assertStruct)(s,exports.PendingJsonRpcResponseStruct,"Invalid pending JSON-RPC response",t)}function isJsonRpcResponse(s){return(0,superstruct_1.is)(s,exports.JsonRpcResponseStruct)}function assertIsJsonRpcResponse(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcResponseStruct,"Invalid JSON-RPC response",t)}function isJsonRpcSuccess(s){return(0,superstruct_1.is)(s,exports.JsonRpcSuccessStruct)}function assertIsJsonRpcSuccess(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcSuccessStruct,"Invalid JSON-RPC success response",t)}function isJsonRpcFailure(s){return(0,superstruct_1.is)(s,exports.JsonRpcFailureStruct)}function assertIsJsonRpcFailure(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcFailureStruct,"Invalid JSON-RPC failure response",t)}function isJsonRpcError(s){return(0,superstruct_1.is)(s,exports.JsonRpcErrorStruct)}function assertIsJsonRpcError(s,t){(0,assert_1.assertStruct)(s,exports.JsonRpcErrorStruct,"Invalid JSON-RPC error",t)}function getJsonRpcIdValidator(s){const{permitEmptyString:t,permitFractions:r,permitNull:e}={permitEmptyString:!0,permitFractions:!1,permitNull:!0,...s};return s=>Boolean("number"==typeof s&&(r||Number.isInteger(s))||"string"==typeof s&&(t||s.length>0)||e&&null===s)}exports.UnsafeJsonStruct=(0,superstruct_1.union)([(0,superstruct_1.literal)(null),(0,superstruct_1.boolean)(),(0,superstruct_1.define)("finite number",(s=>(0,superstruct_1.is)(s,(0,superstruct_1.number)())&&Number.isFinite(s))),(0,superstruct_1.string)(),(0,superstruct_1.array)((0,superstruct_1.lazy)((()=>exports.UnsafeJsonStruct))),(0,superstruct_1.record)((0,superstruct_1.string)(),(0,superstruct_1.lazy)((()=>exports.UnsafeJsonStruct)))]),exports.JsonStruct=(0,superstruct_1.coerce)(exports.UnsafeJsonStruct,(0,superstruct_1.any)(),(s=>((0,assert_1.assertStruct)(s,exports.UnsafeJsonStruct),JSON.parse(JSON.stringify(s))))),exports.isValidJson=isValidJson,exports.getSafeJson=getSafeJson,exports.getJsonSize=getJsonSize,exports.jsonrpc2="2.0",exports.JsonRpcVersionStruct=(0,superstruct_1.literal)(exports.jsonrpc2),exports.JsonRpcIdStruct=(0,superstruct_1.nullable)((0,superstruct_1.union)([(0,superstruct_1.number)(),(0,superstruct_1.string)()])),exports.JsonRpcErrorStruct=(0,superstruct_1.object)({code:(0,superstruct_1.integer)(),message:(0,superstruct_1.string)(),data:(0,superstruct_1.optional)(exports.JsonStruct),stack:(0,superstruct_1.optional)((0,superstruct_1.string)())}),exports.JsonRpcParamsStruct=(0,superstruct_1.optional)((0,superstruct_1.union)([(0,superstruct_1.record)((0,superstruct_1.string)(),exports.JsonStruct),(0,superstruct_1.array)(exports.JsonStruct)])),exports.JsonRpcRequestStruct=(0,superstruct_1.object)({id:exports.JsonRpcIdStruct,jsonrpc:exports.JsonRpcVersionStruct,method:(0,superstruct_1.string)(),params:exports.JsonRpcParamsStruct}),exports.JsonRpcNotificationStruct=(0,superstruct_1.omit)(exports.JsonRpcRequestStruct,["id"]),exports.isJsonRpcNotification=isJsonRpcNotification,exports.assertIsJsonRpcNotification=assertIsJsonRpcNotification,exports.isJsonRpcRequest=isJsonRpcRequest,exports.assertIsJsonRpcRequest=assertIsJsonRpcRequest,exports.PendingJsonRpcResponseStruct=(0,superstruct_1.object)({id:exports.JsonRpcIdStruct,jsonrpc:exports.JsonRpcVersionStruct,result:(0,superstruct_1.optional)((0,superstruct_1.unknown)()),error:(0,superstruct_1.optional)(exports.JsonRpcErrorStruct)}),exports.JsonRpcSuccessStruct=(0,superstruct_1.object)({id:exports.JsonRpcIdStruct,jsonrpc:exports.JsonRpcVersionStruct,result:exports.JsonStruct}),exports.JsonRpcFailureStruct=(0,superstruct_1.object)({id:exports.JsonRpcIdStruct,jsonrpc:exports.JsonRpcVersionStruct,error:exports.JsonRpcErrorStruct}),exports.JsonRpcResponseStruct=(0,superstruct_1.union)([exports.JsonRpcSuccessStruct,exports.JsonRpcFailureStruct]),exports.isPendingJsonRpcResponse=isPendingJsonRpcResponse,exports.assertIsPendingJsonRpcResponse=assertIsPendingJsonRpcResponse,exports.isJsonRpcResponse=isJsonRpcResponse,exports.assertIsJsonRpcResponse=assertIsJsonRpcResponse,exports.isJsonRpcSuccess=isJsonRpcSuccess,exports.assertIsJsonRpcSuccess=assertIsJsonRpcSuccess,exports.isJsonRpcFailure=isJsonRpcFailure,exports.assertIsJsonRpcFailure=assertIsJsonRpcFailure,exports.isJsonRpcError=isJsonRpcError,exports.assertIsJsonRpcError=assertIsJsonRpcError,exports.getJsonRpcIdValidator=getJsonRpcIdValidator;
|
|
410
664
|
|
|
411
665
|
};
|
|
412
666
|
};
|
|
413
667
|
}
|
|
414
668
|
}
|
|
415
669
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/json.js",}],
|
|
416
|
-
[
|
|
670
|
+
[48, {}, function(){
|
|
417
671
|
with (this.scopeTerminator) {
|
|
418
672
|
with (this.globalThis) {
|
|
419
673
|
return function() {
|
|
420
674
|
'use strict';
|
|
421
|
-
// source: /home/runner/work/snaps
|
|
675
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/keyring.js
|
|
422
676
|
return function (require, module, exports) {
|
|
423
677
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
424
678
|
|
|
@@ -427,12 +681,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
427
681
|
}
|
|
428
682
|
}
|
|
429
683
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/keyring.js",}],
|
|
430
|
-
[
|
|
684
|
+
[49, {"debug":73}, function(){
|
|
431
685
|
with (this.scopeTerminator) {
|
|
432
686
|
with (this.globalThis) {
|
|
433
687
|
return function() {
|
|
434
688
|
'use strict';
|
|
435
|
-
// source: /home/runner/work/snaps
|
|
689
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/logging.js
|
|
436
690
|
return function (require, module, exports) {
|
|
437
691
|
"use strict";var __importDefault=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(exports,"__esModule",{value:!0}),exports.createModuleLogger=exports.createProjectLogger=void 0;const debug_1=__importDefault(require("debug")),globalLogger=(0,debug_1.default)("metamask");function createProjectLogger(e){return globalLogger.extend(e)}function createModuleLogger(e,r){return e.extend(r)}exports.createProjectLogger=createProjectLogger,exports.createModuleLogger=createModuleLogger;
|
|
438
692
|
|
|
@@ -441,26 +695,26 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
441
695
|
}
|
|
442
696
|
}
|
|
443
697
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/logging.js",}],
|
|
444
|
-
[
|
|
698
|
+
[50, {}, function(){
|
|
445
699
|
with (this.scopeTerminator) {
|
|
446
700
|
with (this.globalThis) {
|
|
447
701
|
return function() {
|
|
448
702
|
'use strict';
|
|
449
|
-
// source: /home/runner/work/snaps
|
|
703
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/misc.js
|
|
450
704
|
return function (require, module, exports) {
|
|
451
|
-
"use strict";function isNonEmptyArray(e){return Array.isArray(e)&&e.length>0}function isNullOrUndefined(e){return null==e}function isObject(e){return Boolean(e)&&"object"==typeof e&&!Array.isArray(e)}Object.defineProperty(exports,"__esModule",{value:!0}),exports.calculateNumberSize=exports.calculateStringSize=exports.isASCII=exports.isPlainObject=exports.ESCAPE_CHARACTERS_REGEXP=exports.JsonSize=exports.hasProperty=exports.isObject=exports.isNullOrUndefined=exports.isNonEmptyArray=void 0,exports.isNonEmptyArray=isNonEmptyArray,exports.isNullOrUndefined=isNullOrUndefined,exports.isObject=isObject;const hasProperty=(e,t)=>Object.hasOwnProperty.call(e,t);var JsonSize;function isPlainObject(e){if("object"!=typeof e||null===e)return!1;try{let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}catch(e){return!1}}function isASCII(e){return e.charCodeAt(0)<=127}function calculateStringSize(e){
|
|
705
|
+
"use strict";function isNonEmptyArray(e){return Array.isArray(e)&&e.length>0}function isNullOrUndefined(e){return null==e}function isObject(e){return Boolean(e)&&"object"==typeof e&&!Array.isArray(e)}Object.defineProperty(exports,"__esModule",{value:!0}),exports.calculateNumberSize=exports.calculateStringSize=exports.isASCII=exports.isPlainObject=exports.ESCAPE_CHARACTERS_REGEXP=exports.JsonSize=exports.hasProperty=exports.isObject=exports.isNullOrUndefined=exports.isNonEmptyArray=void 0,exports.isNonEmptyArray=isNonEmptyArray,exports.isNullOrUndefined=isNullOrUndefined,exports.isObject=isObject;const hasProperty=(e,t)=>Object.hasOwnProperty.call(e,t);var JsonSize;function isPlainObject(e){if("object"!=typeof e||null===e)return!1;try{let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}catch(e){return!1}}function isASCII(e){return e.charCodeAt(0)<=127}function calculateStringSize(e){return e.split("").reduce(((e,t)=>isASCII(t)?e+1:e+2),0)+(e.match(exports.ESCAPE_CHARACTERS_REGEXP)??[]).length}function calculateNumberSize(e){return e.toString().length}exports.hasProperty=hasProperty,function(e){e[e.Null=4]="Null",e[e.Comma=1]="Comma",e[e.Wrapper=1]="Wrapper",e[e.True=4]="True",e[e.False=5]="False",e[e.Quote=1]="Quote",e[e.Colon=1]="Colon",e[e.Date=24]="Date"}(JsonSize=exports.JsonSize||(exports.JsonSize={})),exports.ESCAPE_CHARACTERS_REGEXP=/"|\\|\n|\r|\t/gu,exports.isPlainObject=isPlainObject,exports.isASCII=isASCII,exports.calculateStringSize=calculateStringSize,exports.calculateNumberSize=calculateNumberSize;
|
|
452
706
|
|
|
453
707
|
};
|
|
454
708
|
};
|
|
455
709
|
}
|
|
456
710
|
}
|
|
457
711
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/misc.js",}],
|
|
458
|
-
[
|
|
712
|
+
[51, {"./assert":38,"./hex":45}, function(){
|
|
459
713
|
with (this.scopeTerminator) {
|
|
460
714
|
with (this.globalThis) {
|
|
461
715
|
return function() {
|
|
462
716
|
'use strict';
|
|
463
|
-
// source: /home/runner/work/snaps
|
|
717
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/number.js
|
|
464
718
|
return function (require, module, exports) {
|
|
465
719
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.hexToBigInt=exports.hexToNumber=exports.bigIntToHex=exports.numberToHex=void 0;const assert_1=require("./assert"),hex_1=require("./hex"),numberToHex=e=>((0,assert_1.assert)("number"==typeof e,"Value must be a number."),(0,assert_1.assert)(e>=0,"Value must be a non-negative number."),(0,assert_1.assert)(Number.isSafeInteger(e),"Value is not a safe integer. Use `bigIntToHex` instead."),(0,hex_1.add0x)(e.toString(16)));exports.numberToHex=numberToHex;const bigIntToHex=e=>((0,assert_1.assert)("bigint"==typeof e,"Value must be a bigint."),(0,assert_1.assert)(e>=0,"Value must be a non-negative bigint."),(0,hex_1.add0x)(e.toString(16)));exports.bigIntToHex=bigIntToHex;const hexToNumber=e=>{(0,hex_1.assertIsHexString)(e);const t=parseInt(e,16);return(0,assert_1.assert)(Number.isSafeInteger(t),"Value is not a safe integer. Use `hexToBigInt` instead."),t};exports.hexToNumber=hexToNumber;const hexToBigInt=e=>((0,hex_1.assertIsHexString)(e),BigInt((0,hex_1.add0x)(e)));exports.hexToBigInt=hexToBigInt;
|
|
466
720
|
|
|
@@ -469,12 +723,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
469
723
|
}
|
|
470
724
|
}
|
|
471
725
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/number.js",}],
|
|
472
|
-
[
|
|
726
|
+
[52, {}, function(){
|
|
473
727
|
with (this.scopeTerminator) {
|
|
474
728
|
with (this.globalThis) {
|
|
475
729
|
return function() {
|
|
476
730
|
'use strict';
|
|
477
|
-
// source: /home/runner/work/snaps
|
|
731
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/opaque.js
|
|
478
732
|
return function (require, module, exports) {
|
|
479
733
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
480
734
|
|
|
@@ -483,12 +737,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
483
737
|
}
|
|
484
738
|
}
|
|
485
739
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/opaque.js",}],
|
|
486
|
-
[
|
|
740
|
+
[53, {}, function(){
|
|
487
741
|
with (this.scopeTerminator) {
|
|
488
742
|
with (this.globalThis) {
|
|
489
743
|
return function() {
|
|
490
744
|
'use strict';
|
|
491
|
-
// source: /home/runner/work/snaps
|
|
745
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/time.js
|
|
492
746
|
return function (require, module, exports) {
|
|
493
747
|
"use strict";var Duration;Object.defineProperty(exports,"__esModule",{value:!0}),exports.timeSince=exports.inMilliseconds=exports.Duration=void 0,function(e){e[e.Millisecond=1]="Millisecond",e[e.Second=1e3]="Second",e[e.Minute=6e4]="Minute",e[e.Hour=36e5]="Hour",e[e.Day=864e5]="Day",e[e.Week=6048e5]="Week",e[e.Year=31536e6]="Year"}(Duration=exports.Duration||(exports.Duration={}));const isNonNegativeInteger=e=>Number.isInteger(e)&&e>=0,assertIsNonNegativeInteger=(e,n)=>{if(!isNonNegativeInteger(e))throw new Error(`"${n}" must be a non-negative integer. Received: "${e}".`)};function inMilliseconds(e,n){return assertIsNonNegativeInteger(e,"count"),e*n}function timeSince(e){return assertIsNonNegativeInteger(e,"timestamp"),Date.now()-e}exports.inMilliseconds=inMilliseconds,exports.timeSince=timeSince;
|
|
494
748
|
|
|
@@ -497,12 +751,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
497
751
|
}
|
|
498
752
|
}
|
|
499
753
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/time.js",}],
|
|
500
|
-
[
|
|
754
|
+
[54, {}, function(){
|
|
501
755
|
with (this.scopeTerminator) {
|
|
502
756
|
with (this.globalThis) {
|
|
503
757
|
return function() {
|
|
504
758
|
'use strict';
|
|
505
|
-
// source: /home/runner/work/snaps
|
|
759
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/transaction-types.js
|
|
506
760
|
return function (require, module, exports) {
|
|
507
761
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});
|
|
508
762
|
|
|
@@ -511,12 +765,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
511
765
|
}
|
|
512
766
|
}
|
|
513
767
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/transaction-types.js",}],
|
|
514
|
-
[
|
|
768
|
+
[55, {"./assert":38,"semver":123,"superstruct":142}, function(){
|
|
515
769
|
with (this.scopeTerminator) {
|
|
516
770
|
with (this.globalThis) {
|
|
517
771
|
return function() {
|
|
518
772
|
'use strict';
|
|
519
|
-
// source: /home/runner/work/snaps
|
|
773
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@metamask/utils/dist/versions.js
|
|
520
774
|
return function (require, module, exports) {
|
|
521
775
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.satisfiesVersionRange=exports.gtRange=exports.gtVersion=exports.assertIsSemVerRange=exports.assertIsSemVerVersion=exports.isValidSemVerRange=exports.isValidSemVerVersion=exports.VersionRangeStruct=exports.VersionStruct=void 0;const semver_1=require("semver"),superstruct_1=require("superstruct"),assert_1=require("./assert");function isValidSemVerVersion(e){return(0,superstruct_1.is)(e,exports.VersionStruct)}function isValidSemVerRange(e){return(0,superstruct_1.is)(e,exports.VersionRangeStruct)}function assertIsSemVerVersion(e){(0,assert_1.assertStruct)(e,exports.VersionStruct)}function assertIsSemVerRange(e){(0,assert_1.assertStruct)(e,exports.VersionRangeStruct)}function gtVersion(e,r){return(0,semver_1.gt)(e,r)}function gtRange(e,r){return(0,semver_1.gtr)(e,r)}function satisfiesVersionRange(e,r){return(0,semver_1.satisfies)(e,r,{includePrerelease:!0})}exports.VersionStruct=(0,superstruct_1.refine)((0,superstruct_1.string)(),"Version",(e=>null!==(0,semver_1.valid)(e)||`Expected SemVer version, got "${e}"`)),exports.VersionRangeStruct=(0,superstruct_1.refine)((0,superstruct_1.string)(),"Version range",(e=>null!==(0,semver_1.validRange)(e)||`Expected SemVer range, got "${e}"`)),exports.isValidSemVerVersion=isValidSemVerVersion,exports.isValidSemVerRange=isValidSemVerRange,exports.assertIsSemVerVersion=assertIsSemVerVersion,exports.assertIsSemVerRange=assertIsSemVerRange,exports.gtVersion=gtVersion,exports.gtRange=gtRange,exports.satisfiesVersionRange=satisfiesVersionRange;
|
|
522
776
|
|
|
@@ -525,12 +779,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
525
779
|
}
|
|
526
780
|
}
|
|
527
781
|
}, {package:"@metamask/utils",file:"../../node_modules/@metamask/utils/dist/versions.js",}],
|
|
528
|
-
[
|
|
782
|
+
[56, {}, function(){
|
|
529
783
|
with (this.scopeTerminator) {
|
|
530
784
|
with (this.globalThis) {
|
|
531
785
|
return function() {
|
|
532
786
|
'use strict';
|
|
533
|
-
// source: /home/runner/work/snaps
|
|
787
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@noble/hashes/_assert.js
|
|
534
788
|
return function (require, module, exports) {
|
|
535
789
|
"use strict";function number(e){if(!Number.isSafeInteger(e)||e<0)throw new Error(`Wrong positive integer: ${e}`)}function bool(e){if("boolean"!=typeof e)throw new Error(`Expected boolean, not ${e}`)}function bytes(e,...t){if(!(e instanceof Uint8Array))throw new TypeError("Expected Uint8Array");if(t.length>0&&!t.includes(e.length))throw new TypeError(`Expected Uint8Array of length ${t}, not of length=${e.length}`)}function hash(e){if("function"!=typeof e||"function"!=typeof e.create)throw new Error("Hash should be wrapped by utils.wrapConstructor");number(e.outputLen),number(e.blockLen)}function exists(e,t=!0){if(e.destroyed)throw new Error("Hash instance has been destroyed");if(t&&e.finished)throw new Error("Hash#digest() has already been called")}function output(e,t){bytes(e);const o=t.outputLen;if(e.length<o)throw new Error(`digestInto() expects output buffer of length at least ${o}`)}Object.defineProperty(exports,"__esModule",{value:!0}),/* common-shake removed: exports.output = */ /* common-shake removed: exports.exists = */ /* common-shake removed: exports.hash = */ /* common-shake removed: exports.bytes = */ /* common-shake removed: exports.bool = */ /* common-shake removed: exports.number = */ void 0,/* common-shake removed: exports.number = */ void number,/* common-shake removed: exports.bool = */ void bool,/* common-shake removed: exports.bytes = */ void bytes,/* common-shake removed: exports.hash = */ void hash,/* common-shake removed: exports.exists = */ void exists,/* common-shake removed: exports.output = */ void output;const assert={number:number,bool:bool,bytes:bytes,hash:hash,exists:exists,output:output};exports.default=assert;
|
|
536
790
|
|
|
@@ -539,12 +793,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
539
793
|
}
|
|
540
794
|
}
|
|
541
795
|
}, {package:"@metamask/rpc-methods>@noble/hashes",file:"../../node_modules/@noble/hashes/_assert.js",}],
|
|
542
|
-
[
|
|
796
|
+
[57, {"./_assert.js":56,"./utils.js":60}, function(){
|
|
543
797
|
with (this.scopeTerminator) {
|
|
544
798
|
with (this.globalThis) {
|
|
545
799
|
return function() {
|
|
546
800
|
'use strict';
|
|
547
|
-
// source: /home/runner/work/snaps
|
|
801
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@noble/hashes/_sha2.js
|
|
548
802
|
return function (require, module, exports) {
|
|
549
803
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SHA2=void 0;const _assert_js_1=require("./_assert.js"),utils_js_1=require("./utils.js");function setBigUint64(t,s,e,i){if("function"==typeof t.setBigUint64)return t.setBigUint64(s,e,i);const r=BigInt(32),n=BigInt(4294967295),o=Number(e>>r&n),h=Number(e&n),u=i?4:0,f=i?0:4;t.setUint32(s+u,o,i),t.setUint32(s+f,h,i)}class SHA2 extends utils_js_1.Hash{constructor(t,s,e,i){super(),this.blockLen=t,this.outputLen=s,this.padOffset=e,this.isLE=i,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(t),this.view=(0,utils_js_1.createView)(this.buffer)}update(t){_assert_js_1.default.exists(this);const{view:s,buffer:e,blockLen:i}=this,r=(t=(0,utils_js_1.toBytes)(t)).length;for(let n=0;n<r;){const o=Math.min(i-this.pos,r-n);if(o!==i)e.set(t.subarray(n,n+o),this.pos),this.pos+=o,n+=o,this.pos===i&&(this.process(s,0),this.pos=0);else{const s=(0,utils_js_1.createView)(t);for(;i<=r-n;n+=i)this.process(s,n)}}return this.length+=t.length,this.roundClean(),this}digestInto(t){_assert_js_1.default.exists(this),_assert_js_1.default.output(t,this),this.finished=!0;const{buffer:s,view:e,blockLen:i,isLE:r}=this;let{pos:n}=this;s[n++]=128,this.buffer.subarray(n).fill(0),this.padOffset>i-n&&(this.process(e,0),n=0);for(let t=n;t<i;t++)s[t]=0;setBigUint64(e,i-8,BigInt(8*this.length),r),this.process(e,0);const o=(0,utils_js_1.createView)(t),h=this.outputLen;if(h%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const u=h/4,f=this.get();if(u>f.length)throw new Error("_sha2: outputLen bigger than state");for(let t=0;t<u;t++)o.setUint32(4*t,f[t],r)}digest(){const{buffer:t,outputLen:s}=this;this.digestInto(t);const e=t.slice(0,s);return this.destroy(),e}_cloneInto(t){t||(t=new this.constructor),t.set(...this.get());const{blockLen:s,buffer:e,length:i,finished:r,destroyed:n,pos:o}=this;return t.length=i,t.pos=o,t.finished=r,t.destroyed=n,i%s&&t.buffer.set(e),t}}exports.SHA2=SHA2;
|
|
550
804
|
|
|
@@ -553,12 +807,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
553
807
|
}
|
|
554
808
|
}
|
|
555
809
|
}, {package:"@metamask/rpc-methods>@noble/hashes",file:"../../node_modules/@noble/hashes/_sha2.js",}],
|
|
556
|
-
[
|
|
810
|
+
[58, {}, function(){
|
|
557
811
|
with (this.scopeTerminator) {
|
|
558
812
|
with (this.globalThis) {
|
|
559
813
|
return function() {
|
|
560
814
|
'use strict';
|
|
561
|
-
// source: /home/runner/work/snaps
|
|
815
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@noble/hashes/crypto.js
|
|
562
816
|
return function (require, module, exports) {
|
|
563
817
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.crypto=void 0,exports.crypto="object"==typeof globalThis&&"crypto"in globalThis?globalThis.crypto:void 0;
|
|
564
818
|
|
|
@@ -567,12 +821,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
567
821
|
}
|
|
568
822
|
}
|
|
569
823
|
}, {package:"@metamask/rpc-methods>@noble/hashes",file:"../../node_modules/@noble/hashes/crypto.js",}],
|
|
570
|
-
[
|
|
824
|
+
[59, {"./_sha2.js":57,"./utils.js":60}, function(){
|
|
571
825
|
with (this.scopeTerminator) {
|
|
572
826
|
with (this.globalThis) {
|
|
573
827
|
return function() {
|
|
574
828
|
'use strict';
|
|
575
|
-
// source: /home/runner/work/snaps
|
|
829
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@noble/hashes/sha256.js
|
|
576
830
|
return function (require, module, exports) {
|
|
577
831
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),/* common-shake removed: exports.sha224 = */ exports.sha256=void 0;const _sha2_js_1=require("./_sha2.js"),utils_js_1=require("./utils.js"),Chi=(s,t,i)=>s&t^~s&i,Maj=(s,t,i)=>s&t^s&i^t&i,SHA256_K=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),IV=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),SHA256_W=new Uint32Array(64);class SHA256 extends _sha2_js_1.SHA2{constructor(){super(64,32,8,!1),this.A=0|IV[0],this.B=0|IV[1],this.C=0|IV[2],this.D=0|IV[3],this.E=0|IV[4],this.F=0|IV[5],this.G=0|IV[6],this.H=0|IV[7]}get(){const{A:s,B:t,C:i,D:r,E:h,F:_,G:e,H:o}=this;return[s,t,i,r,h,_,e,o]}set(s,t,i,r,h,_,e,o){this.A=0|s,this.B=0|t,this.C=0|i,this.D=0|r,this.E=0|h,this.F=0|_,this.G=0|e,this.H=0|o}process(s,t){for(let i=0;i<16;i++,t+=4)SHA256_W[i]=s.getUint32(t,!1);for(let s=16;s<64;s++){const t=SHA256_W[s-15],i=SHA256_W[s-2],r=(0,utils_js_1.rotr)(t,7)^(0,utils_js_1.rotr)(t,18)^t>>>3,h=(0,utils_js_1.rotr)(i,17)^(0,utils_js_1.rotr)(i,19)^i>>>10;SHA256_W[s]=h+SHA256_W[s-7]+r+SHA256_W[s-16]|0}let{A:i,B:r,C:h,D:_,E:e,F:o,G:u,H:l}=this;for(let s=0;s<64;s++){const t=l+((0,utils_js_1.rotr)(e,6)^(0,utils_js_1.rotr)(e,11)^(0,utils_js_1.rotr)(e,25))+((A=e)&o^~A&u)+SHA256_K[s]+SHA256_W[s]|0,n=((0,utils_js_1.rotr)(i,2)^(0,utils_js_1.rotr)(i,13)^(0,utils_js_1.rotr)(i,22))+Maj(i,r,h)|0;l=u,u=o,o=e,e=_+t|0,_=h,h=r,r=i,i=t+n|0}var A;i=i+this.A|0,r=r+this.B|0,h=h+this.C|0,_=_+this.D|0,e=e+this.E|0,o=o+this.F|0,u=u+this.G|0,l=l+this.H|0,this.set(i,r,h,_,e,o,u,l)}roundClean(){SHA256_W.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}class SHA224 extends SHA256{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}exports.sha256=(0,utils_js_1.wrapConstructor)((()=>new SHA256)),/* common-shake removed: exports.sha224 = */ void (0,utils_js_1.wrapConstructor)((()=>new SHA224));
|
|
578
832
|
|
|
@@ -581,12 +835,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
581
835
|
}
|
|
582
836
|
}
|
|
583
837
|
}, {package:"@metamask/rpc-methods>@noble/hashes",file:"../../node_modules/@noble/hashes/sha256.js",}],
|
|
584
|
-
[
|
|
838
|
+
[60, {"@noble/hashes/crypto":58}, function(){
|
|
585
839
|
with (this.scopeTerminator) {
|
|
586
840
|
with (this.globalThis) {
|
|
587
841
|
return function() {
|
|
588
842
|
'use strict';
|
|
589
|
-
// source: /home/runner/work/snaps
|
|
843
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@noble/hashes/utils.js
|
|
590
844
|
return function (require, module, exports) {
|
|
591
845
|
"use strict";
|
|
592
846
|
/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */Object.defineProperty(exports,"__esModule",{value:!0}),/* common-shake removed: exports.randomBytes = */ /* common-shake removed: exports.wrapConstructorWithOpts = */ exports.wrapConstructor=/* common-shake removed: exports.checkOpts = */ exports.Hash=/* common-shake removed: exports.concatBytes = */ exports.toBytes=/* common-shake removed: exports.utf8ToBytes = */ /* common-shake removed: exports.asyncLoop = */ exports.nextTick=/* common-shake removed: exports.hexToBytes = */ /* common-shake removed: exports.bytesToHex = */ exports.isLE=exports.rotr=exports.createView=/* common-shake removed: exports.u32 = */ /* common-shake removed: exports.u8 = */ void 0;const crypto_1=require("@noble/hashes/crypto"),u8=t=>new Uint8Array(t.buffer,t.byteOffset,t.byteLength);/* common-shake removed: exports.u8 = */ void u8;const u32=t=>new Uint32Array(t.buffer,t.byteOffset,Math.floor(t.byteLength/4));/* common-shake removed: exports.u32 = */ void u32;const createView=t=>new DataView(t.buffer,t.byteOffset,t.byteLength);exports.createView=createView;const rotr=(t,e)=>t<<32-e|t>>>e;if(exports.rotr=rotr,exports.isLE=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0],!exports.isLE)throw new Error("Non little-endian hardware is not supported");const hexes=Array.from({length:256},((t,e)=>e.toString(16).padStart(2,"0")));function bytesToHex(t){if(!(t instanceof Uint8Array))throw new Error("Uint8Array expected");let e="";for(let r=0;r<t.length;r++)e+=hexes[t[r]];return e}function hexToBytes(t){if("string"!=typeof t)throw new TypeError("hexToBytes: expected string, got "+typeof t);if(t.length%2)throw new Error("hexToBytes: received invalid unpadded hex");const e=new Uint8Array(t.length/2);for(let r=0;r<e.length;r++){const o=2*r,n=t.slice(o,o+2),s=Number.parseInt(n,16);if(Number.isNaN(s)||s<0)throw new Error("Invalid byte sequence");e[r]=s}return e}/* common-shake removed: exports.bytesToHex = */ void bytesToHex,/* common-shake removed: exports.hexToBytes = */ void hexToBytes;const nextTick=async()=>{};async function asyncLoop(t,e,r){let o=Date.now();for(let n=0;n<t;n++){r(n);const t=Date.now()-o;t>=0&&t<e||(await(0,exports.nextTick)(),o+=t)}}function utf8ToBytes(t){if("string"!=typeof t)throw new TypeError("utf8ToBytes expected string, got "+typeof t);return(new TextEncoder).encode(t)}function toBytes(t){if("string"==typeof t&&(t=utf8ToBytes(t)),!(t instanceof Uint8Array))throw new TypeError(`Expected input type is Uint8Array (got ${typeof t})`);return t}function concatBytes(...t){if(!t.every((t=>t instanceof Uint8Array)))throw new Error("Uint8Array list expected");if(1===t.length)return t[0];const e=t.reduce(((t,e)=>t+e.length),0),r=new Uint8Array(e);for(let e=0,o=0;e<t.length;e++){const n=t[e];r.set(n,o),o+=n.length}return r}exports.nextTick=nextTick,/* common-shake removed: exports.asyncLoop = */ void asyncLoop,/* common-shake removed: exports.utf8ToBytes = */ void utf8ToBytes,exports.toBytes=toBytes,/* common-shake removed: exports.concatBytes = */ void concatBytes;class Hash{clone(){return this._cloneInto()}}exports.Hash=Hash;const isPlainObject=t=>"[object Object]"===Object.prototype.toString.call(t)&&t.constructor===Object;function checkOpts(t,e){if(void 0!==e&&("object"!=typeof e||!isPlainObject(e)))throw new TypeError("Options should be object or undefined");return Object.assign(t,e)}function wrapConstructor(t){const e=e=>t().update(toBytes(e)).digest(),r=t();return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=()=>t(),e}function wrapConstructorWithOpts(t){const e=(e,r)=>t(r).update(toBytes(e)).digest(),r=t({});return e.outputLen=r.outputLen,e.blockLen=r.blockLen,e.create=e=>t(e),e}function randomBytes(t=32){if(crypto_1.crypto&&"function"==typeof crypto_1.crypto.getRandomValues)return crypto_1.crypto.getRandomValues(new Uint8Array(t));throw new Error("crypto.getRandomValues must be defined")}/* common-shake removed: exports.checkOpts = */ void checkOpts,exports.wrapConstructor=wrapConstructor,/* common-shake removed: exports.wrapConstructorWithOpts = */ void wrapConstructorWithOpts,/* common-shake removed: exports.randomBytes = */ void randomBytes;
|
|
@@ -596,12 +850,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
596
850
|
}
|
|
597
851
|
}
|
|
598
852
|
}, {package:"@metamask/rpc-methods>@noble/hashes",file:"../../node_modules/@noble/hashes/utils.js",}],
|
|
599
|
-
[
|
|
853
|
+
[61, {}, function(){
|
|
600
854
|
with (this.scopeTerminator) {
|
|
601
855
|
with (this.globalThis) {
|
|
602
856
|
return function() {
|
|
603
857
|
'use strict';
|
|
604
|
-
// source: /home/runner/work/snaps
|
|
858
|
+
// source: /home/runner/work/snaps/snaps/node_modules/@scure/base/lib/index.js
|
|
605
859
|
return function (require, module, exports) {
|
|
606
860
|
"use strict";
|
|
607
861
|
/*! scure-base - MIT License (c) 2022 Paul Miller (paulmillr.com) */function assertNumber(r){if(!Number.isSafeInteger(r))throw new Error(`Wrong integer: ${r}`)}function chain(...r){const e=(r,e)=>o=>r(e(o));return{encode:Array.from(r).reverse().reduce(((r,o)=>r?e(r,o.encode):o.encode),void 0),decode:r.reduce(((r,o)=>r?e(r,o.decode):o.decode),void 0)}}function alphabet(r){return{encode:e=>{if(!Array.isArray(e)||e.length&&"number"!=typeof e[0])throw new Error("alphabet.encode input should be an array of numbers");return e.map((e=>{if(assertNumber(e),e<0||e>=r.length)throw new Error(`Digit index outside alphabet: ${e} (alphabet: ${r.length})`);return r[e]}))},decode:e=>{if(!Array.isArray(e)||e.length&&"string"!=typeof e[0])throw new Error("alphabet.decode input should be array of strings");return e.map((e=>{if("string"!=typeof e)throw new Error(`alphabet.decode: not string element=${e}`);const o=r.indexOf(e);if(-1===o)throw new Error(`Unknown letter: "${e}". Allowed: ${r}`);return o}))}}}function join(r=""){if("string"!=typeof r)throw new Error("join separator should be string");return{encode:e=>{if(!Array.isArray(e)||e.length&&"string"!=typeof e[0])throw new Error("join.encode input should be array of strings");for(let r of e)if("string"!=typeof r)throw new Error(`join.encode: non-string input=${r}`);return e.join(r)},decode:e=>{if("string"!=typeof e)throw new Error("join.decode input should be string");return e.split(r)}}}function padding(r,e="="){if(assertNumber(r),"string"!=typeof e)throw new Error("padding chr should be string");return{encode(o){if(!Array.isArray(o)||o.length&&"string"!=typeof o[0])throw new Error("padding.encode input should be array of strings");for(let r of o)if("string"!=typeof r)throw new Error(`padding.encode: non-string input=${r}`);for(;o.length*r%8;)o.push(e);return o},decode(o){if(!Array.isArray(o)||o.length&&"string"!=typeof o[0])throw new Error("padding.encode input should be array of strings");for(let r of o)if("string"!=typeof r)throw new Error(`padding.decode: non-string input=${r}`);let t=o.length;if(t*r%8)throw new Error("Invalid padding: string should have whole number of bytes");for(;t>0&&o[t-1]===e;t--)if(!((t-1)*r%8))throw new Error("Invalid padding: string has too much padding");return o.slice(0,t)}}}function normalize(r){if("function"!=typeof r)throw new Error("normalize fn should be function");return{encode:r=>r,decode:e=>r(e)}}function convertRadix(r,e,o){if(e<2)throw new Error(`convertRadix: wrong from=${e}, base cannot be less than 2`);if(o<2)throw new Error(`convertRadix: wrong to=${o}, base cannot be less than 2`);if(!Array.isArray(r))throw new Error("convertRadix: data should be array");if(!r.length)return[];let t=0;const n=[],s=Array.from(r);for(s.forEach((r=>{if(assertNumber(r),r<0||r>=e)throw new Error(`Wrong integer: ${r}`)}));;){let r=0,i=!0;for(let n=t;n<s.length;n++){const a=s[n],c=e*r+a;if(!Number.isSafeInteger(c)||e*r/e!==r||c-a!=e*r)throw new Error("convertRadix: carry overflow");if(r=c%o,s[n]=Math.floor(c/o),!Number.isSafeInteger(s[n])||s[n]*o+r!==c)throw new Error("convertRadix: carry overflow");i&&(s[n]?i=!1:t=n)}if(n.push(r),i)break}for(let e=0;e<r.length-1&&0===r[e];e++)n.push(0);return n.reverse()}Object.defineProperty(exports,"__esModule",{value:!0}),/* common-shake removed: exports.bytes = */ /* common-shake removed: exports.stringToBytes = */ /* common-shake removed: exports.str = */ /* common-shake removed: exports.bytesToString = */ exports.hex=exports.utf8=/* common-shake removed: exports.bech32m = */ /* common-shake removed: exports.bech32 = */ /* common-shake removed: exports.base58check = */ exports.base58xmr=/* common-shake removed: exports.base58xrp = */ /* common-shake removed: exports.base58flickr = */ exports.base58=exports.base64url=exports.base64=/* common-shake removed: exports.base32crockford = */ /* common-shake removed: exports.base32hex = */ exports.base32=exports.base16=/* common-shake removed: exports.utils = */ /* common-shake removed: exports.assertNumber = */ void 0,/* common-shake removed: exports.assertNumber = */ void assertNumber;const gcd=(r,e)=>e?gcd(e,r%e):r,radix2carry=(r,e)=>r+(e-gcd(r,e));function convertRadix2(r,e,o,t){if(!Array.isArray(r))throw new Error("convertRadix2: data should be array");if(e<=0||e>32)throw new Error(`convertRadix2: wrong from=${e}`);if(o<=0||o>32)throw new Error(`convertRadix2: wrong to=${o}`);if(radix2carry(e,o)>32)throw new Error(`convertRadix2: carry overflow from=${e} to=${o} carryBits=${radix2carry(e,o)}`);let n=0,s=0;const i=2**o-1,a=[];for(const t of r){if(assertNumber(t),t>=2**e)throw new Error(`convertRadix2: invalid data word=${t} from=${e}`);if(n=n<<e|t,s+e>32)throw new Error(`convertRadix2: carry overflow pos=${s} from=${e}`);for(s+=e;s>=o;s-=o)a.push((n>>s-o&i)>>>0);n&=2**s-1}if(n=n<<o-s&i,!t&&s>=e)throw new Error("Excess padding");if(!t&&n)throw new Error(`Non-zero padding: ${n}`);return t&&s>0&&a.push(n>>>0),a}function radix(r){return assertNumber(r),{encode:e=>{if(!(e instanceof Uint8Array))throw new Error("radix.encode input should be Uint8Array");return convertRadix(Array.from(e),256,r)},decode:e=>{if(!Array.isArray(e)||e.length&&"number"!=typeof e[0])throw new Error("radix.decode input should be array of strings");return Uint8Array.from(convertRadix(e,r,256))}}}function radix2(r,e=!1){if(assertNumber(r),r<=0||r>32)throw new Error("radix2: bits should be in (0..32]");if(radix2carry(8,r)>32||radix2carry(r,8)>32)throw new Error("radix2: carry overflow");return{encode:o=>{if(!(o instanceof Uint8Array))throw new Error("radix2.encode input should be Uint8Array");return convertRadix2(Array.from(o),8,r,!e)},decode:o=>{if(!Array.isArray(o)||o.length&&"number"!=typeof o[0])throw new Error("radix2.decode input should be array of strings");return Uint8Array.from(convertRadix2(o,r,8,e))}}}function unsafeWrapper(r){if("function"!=typeof r)throw new Error("unsafeWrapper fn should be function");return function(...e){try{return r.apply(null,e)}catch(r){}}}function checksum(r,e){if(assertNumber(r),"function"!=typeof e)throw new Error("checksum fn should be function");return{encode(o){if(!(o instanceof Uint8Array))throw new Error("checksum.encode: input should be Uint8Array");const t=e(o).slice(0,r),n=new Uint8Array(o.length+r);return n.set(o),n.set(t,o.length),n},decode(o){if(!(o instanceof Uint8Array))throw new Error("checksum.decode: input should be Uint8Array");const t=o.slice(0,-r),n=e(t).slice(0,r),s=o.slice(-r);for(let e=0;e<r;e++)if(n[e]!==s[e])throw new Error("Invalid checksum");return t}}}/* common-shake removed: exports.utils = */ void {alphabet:alphabet,chain:chain,checksum:checksum,radix:radix,radix2:radix2,join:join,padding:padding},exports.base16=chain(radix2(4),alphabet("0123456789ABCDEF"),join("")),exports.base32=chain(radix2(5),alphabet("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"),padding(5),join("")),/* common-shake removed: exports.base32hex = */ void chain(radix2(5),alphabet("0123456789ABCDEFGHIJKLMNOPQRSTUV"),padding(5),join("")),/* common-shake removed: exports.base32crockford = */ void chain(radix2(5),alphabet("0123456789ABCDEFGHJKMNPQRSTVWXYZ"),join(""),normalize((r=>r.toUpperCase().replace(/O/g,"0").replace(/[IL]/g,"1")))),exports.base64=chain(radix2(6),alphabet("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),padding(6),join("")),exports.base64url=chain(radix2(6),alphabet("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"),padding(6),join(""));const genBase58=r=>chain(radix(58),alphabet(r),join(""));exports.base58=genBase58("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),/* common-shake removed: exports.base58flickr = */ void genBase58("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"),/* common-shake removed: exports.base58xrp = */ void genBase58("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz");const XMR_BLOCK_LEN=[0,2,3,5,6,7,9,10,11];exports.base58xmr={encode(r){let e="";for(let o=0;o<r.length;o+=8){const t=r.subarray(o,o+8);e+=exports.base58.encode(t).padStart(XMR_BLOCK_LEN[t.length],"1")}return e},decode(r){let e=[];for(let o=0;o<r.length;o+=11){const t=r.slice(o,o+11),n=XMR_BLOCK_LEN.indexOf(t.length),s=exports.base58.decode(t);for(let r=0;r<s.length-n;r++)if(0!==s[r])throw new Error("base58xmr: wrong padding");e=e.concat(Array.from(s.slice(s.length-n)))}return Uint8Array.from(e)}};const base58check=r=>chain(checksum(4,(e=>r(r(e)))),exports.base58);/* common-shake removed: exports.base58check = */ void base58check;const BECH_ALPHABET=chain(alphabet("qpzry9x8gf2tvdw0s3jn54khce6mua7l"),join("")),POLYMOD_GENERATORS=[996825010,642813549,513874426,1027748829,705979059];function bech32Polymod(r){const e=r>>25;let o=(33554431&r)<<5;for(let r=0;r<POLYMOD_GENERATORS.length;r++)1==(e>>r&1)&&(o^=POLYMOD_GENERATORS[r]);return o}function bechChecksum(r,e,o=1){const t=r.length;let n=1;for(let e=0;e<t;e++){const o=r.charCodeAt(e);if(o<33||o>126)throw new Error(`Invalid prefix (${r})`);n=bech32Polymod(n)^o>>5}n=bech32Polymod(n);for(let e=0;e<t;e++)n=bech32Polymod(n)^31&r.charCodeAt(e);for(let r of e)n=bech32Polymod(n)^r;for(let r=0;r<6;r++)n=bech32Polymod(n);return n^=o,BECH_ALPHABET.encode(convertRadix2([n%2**30],30,5,!1))}function genBech32(r){const e="bech32"===r?1:734539939,o=radix2(5),t=o.decode,n=o.encode,s=unsafeWrapper(t);function i(r,o=90){if("string"!=typeof r)throw new Error("bech32.decode input should be string, not "+typeof r);if(r.length<8||!1!==o&&r.length>o)throw new TypeError(`Wrong string length: ${r.length} (${r}). Expected (8..${o})`);const t=r.toLowerCase();if(r!==t&&r!==r.toUpperCase())throw new Error("String must be lowercase or uppercase");const n=(r=t).lastIndexOf("1");if(0===n||-1===n)throw new Error('Letter "1" must be present between prefix and data only');const s=r.slice(0,n),i=r.slice(n+1);if(i.length<6)throw new Error("Data must be at least 6 characters long");const a=BECH_ALPHABET.decode(i).slice(0,-6),c=bechChecksum(s,a,e);if(!i.endsWith(c))throw new Error(`Invalid checksum in ${r}: expected "${c}"`);return{prefix:s,words:a}}return{encode:function(r,o,t=90){if("string"!=typeof r)throw new Error("bech32.encode prefix should be string, not "+typeof r);if(!Array.isArray(o)||o.length&&"number"!=typeof o[0])throw new Error("bech32.encode words should be array of numbers, not "+typeof o);const n=r.length+7+o.length;if(!1!==t&&n>t)throw new TypeError(`Length ${n} exceeds limit ${t}`);return`${r=r.toLowerCase()}1${BECH_ALPHABET.encode(o)}${bechChecksum(r,o,e)}`},decode:i,decodeToBytes:function(r){const{prefix:e,words:o}=i(r,!1);return{prefix:e,words:o,bytes:t(o)}},decodeUnsafe:unsafeWrapper(i),fromWords:t,fromWordsUnsafe:s,toWords:n}}/* common-shake removed: exports.bech32 = */ void genBech32("bech32"),/* common-shake removed: exports.bech32m = */ void genBech32("bech32m"),exports.utf8={encode:r=>(new TextDecoder).decode(r),decode:r=>(new TextEncoder).encode(r)},exports.hex=chain(radix2(4),alphabet("0123456789abcdef"),join(""),normalize((r=>{if("string"!=typeof r||r.length%2)throw new TypeError(`hex.decode: expected string, got ${typeof r} with length ${r.length}`);return r.toLowerCase()})));const CODERS={utf8:exports.utf8,hex:exports.hex,base16:exports.base16,base32:exports.base32,base64:exports.base64,base64url:exports.base64url,base58:exports.base58,base58xmr:exports.base58xmr},coderTypeError=`Invalid encoding type. Available types: ${Object.keys(CODERS).join(", ")}`,bytesToString=(r,e)=>{if("string"!=typeof r||!CODERS.hasOwnProperty(r))throw new TypeError(coderTypeError);if(!(e instanceof Uint8Array))throw new TypeError("bytesToString() expects Uint8Array");return CODERS[r].encode(e)};/* common-shake removed: exports.bytesToString = */ void bytesToString,/* common-shake removed: exports.str = */ void exports.bytesToString;const stringToBytes=(r,e)=>{if(!CODERS.hasOwnProperty(r))throw new TypeError(coderTypeError);if("string"!=typeof e)throw new TypeError("stringToBytes() expects string");return CODERS[r].decode(e)};/* common-shake removed: exports.stringToBytes = */ void stringToBytes,/* common-shake removed: exports.bytes = */ void exports.stringToBytes;
|
|
@@ -611,12 +865,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
611
865
|
}
|
|
612
866
|
}
|
|
613
867
|
}, {package:"@metamask/snaps-utils>@scure/base",file:"../../node_modules/@scure/base/lib/index.js",}],
|
|
614
|
-
[
|
|
868
|
+
[62, {}, function(){
|
|
615
869
|
with (this.scopeTerminator) {
|
|
616
870
|
with (this.globalThis) {
|
|
617
871
|
return function() {
|
|
618
872
|
'use strict';
|
|
619
|
-
// source: /home/runner/work/snaps
|
|
873
|
+
// source: /home/runner/work/snaps/snaps/node_modules/base64-js/index.js
|
|
620
874
|
return function (require, module, exports) {
|
|
621
875
|
"use strict";/* common-shake removed: exports.byteLength = */ void byteLength,exports.toByteArray=toByteArray,exports.fromByteArray=fromByteArray;for(var lookup=[],revLookup=[],Arr="undefined"!=typeof Uint8Array?Uint8Array:Array,code="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",i=0,len=code.length;i<len;++i)lookup[i]=code[i],revLookup[code.charCodeAt(i)]=i;function getLens(o){var r=o.length;if(r%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var e=o.indexOf("=");return-1===e&&(e=r),[e,e===r?0:4-e%4]}function byteLength(o){var r=getLens(o),e=r[0],t=r[1];return 3*(e+t)/4-t}function _byteLength(o,r,e){return 3*(r+e)/4-e}function toByteArray(o){var r,e,t=getLens(o),n=t[0],u=t[1],p=new Arr(_byteLength(o,n,u)),a=0,h=u>0?n-4:n;for(e=0;e<h;e+=4)r=revLookup[o.charCodeAt(e)]<<18|revLookup[o.charCodeAt(e+1)]<<12|revLookup[o.charCodeAt(e+2)]<<6|revLookup[o.charCodeAt(e+3)],p[a++]=r>>16&255,p[a++]=r>>8&255,p[a++]=255&r;return 2===u&&(r=revLookup[o.charCodeAt(e)]<<2|revLookup[o.charCodeAt(e+1)]>>4,p[a++]=255&r),1===u&&(r=revLookup[o.charCodeAt(e)]<<10|revLookup[o.charCodeAt(e+1)]<<4|revLookup[o.charCodeAt(e+2)]>>2,p[a++]=r>>8&255,p[a++]=255&r),p}function tripletToBase64(o){return lookup[o>>18&63]+lookup[o>>12&63]+lookup[o>>6&63]+lookup[63&o]}function encodeChunk(o,r,e){for(var t,n=[],u=r;u<e;u+=3)t=(o[u]<<16&16711680)+(o[u+1]<<8&65280)+(255&o[u+2]),n.push(tripletToBase64(t));return n.join("")}function fromByteArray(o){for(var r,e=o.length,t=e%3,n=[],u=16383,p=0,a=e-t;p<a;p+=u)n.push(encodeChunk(o,p,p+u>a?a:p+u));return 1===t?(r=o[e-1],n.push(lookup[r>>2]+lookup[r<<4&63]+"==")):2===t&&(r=(o[e-2]<<8)+o[e-1],n.push(lookup[r>>10]+lookup[r>>4&63]+lookup[r<<2&63]+"=")),n.join("")}revLookup["-".charCodeAt(0)]=62,revLookup["_".charCodeAt(0)]=63;
|
|
622
876
|
|
|
@@ -625,12 +879,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
625
879
|
}
|
|
626
880
|
}
|
|
627
881
|
}, {package:"buffer>base64-js",file:"../../node_modules/base64-js/index.js",}],
|
|
628
|
-
[
|
|
882
|
+
[63, {}, function(){
|
|
629
883
|
with (this.scopeTerminator) {
|
|
630
884
|
with (this.globalThis) {
|
|
631
885
|
return function() {
|
|
632
886
|
'use strict';
|
|
633
|
-
// source: /home/runner/work/snaps
|
|
887
|
+
// source: /home/runner/work/snaps/snaps/node_modules/browser-resolve/empty.js
|
|
634
888
|
return function (require, module, exports) {
|
|
635
889
|
|
|
636
890
|
};
|
|
@@ -638,12 +892,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
638
892
|
}
|
|
639
893
|
}
|
|
640
894
|
}, {package:"browserify>browser-resolve",file:"../../node_modules/browser-resolve/empty.js",}],
|
|
641
|
-
[
|
|
895
|
+
[64, {"base64-js":62,"buffer":64,"ieee754":88}, function(){
|
|
642
896
|
with (this.scopeTerminator) {
|
|
643
897
|
with (this.globalThis) {
|
|
644
898
|
return function() {
|
|
645
899
|
'use strict';
|
|
646
|
-
// source: /home/runner/work/snaps
|
|
900
|
+
// source: /home/runner/work/snaps/snaps/node_modules/browserify/node_modules/buffer/index.js
|
|
647
901
|
return function (require, module, exports) {
|
|
648
902
|
(function (Buffer){(function (){
|
|
649
903
|
/*!
|
|
@@ -660,12 +914,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
660
914
|
}
|
|
661
915
|
}
|
|
662
916
|
}, {package:"browserify>buffer",file:"../../node_modules/browserify/node_modules/buffer/index.js",}],
|
|
663
|
-
[
|
|
917
|
+
[65, {"_process":94,"semver":123}, function(){
|
|
664
918
|
with (this.scopeTerminator) {
|
|
665
919
|
with (this.globalThis) {
|
|
666
920
|
return function() {
|
|
667
921
|
'use strict';
|
|
668
|
-
// source: /home/runner/work/snaps
|
|
922
|
+
// source: /home/runner/work/snaps/snaps/node_modules/builtins/index.js
|
|
669
923
|
return function (require, module, exports) {
|
|
670
924
|
(function (process){(function (){
|
|
671
925
|
"use strict";const semver=require("semver"),permanentModules=["assert","buffer","child_process","cluster","console","constants","crypto","dgram","dns","domain","events","fs","http","https","module","net","os","path","punycode","querystring","readline","repl","stream","string_decoder","sys","timers","tls","tty","url","util","vm","zlib"],versionLockedModules={freelist:"<6.0.0",v8:">=1.0.0",process:">=1.1.0",inspector:">=8.0.0",async_hooks:">=8.1.0",http2:">=8.4.0",perf_hooks:">=8.5.0",trace_events:">=10.0.0",worker_threads:">=12.0.0","node:test":">=18.0.0"},experimentalModules={worker_threads:">=10.5.0",wasi:">=12.16.0",diagnostics_channel:"^14.17.0 || >=15.1.0"};module.exports=({version:e=process.version,experimental:s=!1}={})=>{const r=[...permanentModules];for(const[s,t]of Object.entries(versionLockedModules))("*"===e||semver.satisfies(e,t))&&r.push(s);if(s)for(const[s,t]of Object.entries(experimentalModules))r.includes(s)||"*"!==e&&!semver.satisfies(e,t)||r.push(s);return r};
|
|
@@ -676,12 +930,12 @@ var buffer=require("buffer"),Buffer=buffer.Buffer;function copyProps(f,r){for(va
|
|
|
676
930
|
}
|
|
677
931
|
}
|
|
678
932
|
}, {package:"@metamask/snaps-utils>validate-npm-package-name>builtins",file:"../../node_modules/builtins/index.js",}],
|
|
679
|
-
[
|
|
933
|
+
[66, {"../../is-buffer/index.js":90}, function(){
|
|
680
934
|
with (this.scopeTerminator) {
|
|
681
935
|
with (this.globalThis) {
|
|
682
936
|
return function() {
|
|
683
937
|
'use strict';
|
|
684
|
-
// source: /home/runner/work/snaps
|
|
938
|
+
// source: /home/runner/work/snaps/snaps/node_modules/core-util-is/lib/util.js
|
|
685
939
|
return function (require, module, exports) {
|
|
686
940
|
(function (Buffer){(function (){
|
|
687
941
|
function isArray(r){return Array.isArray?Array.isArray(r):"[object Array]"===objectToString(r)}function isBoolean(r){return"boolean"==typeof r}function isNull(r){return null===r}function isNullOrUndefined(r){return null==r}function isNumber(r){return"number"==typeof r}function isString(r){return"string"==typeof r}function isSymbol(r){return"symbol"==typeof r}function isUndefined(r){return void 0===r}function isRegExp(r){return"[object RegExp]"===objectToString(r)}function isObject(r){return"object"==typeof r&&null!==r}function isDate(r){return"[object Date]"===objectToString(r)}function isError(r){return"[object Error]"===objectToString(r)||r instanceof Error}function isFunction(r){return"function"==typeof r}function isPrimitive(r){return null===r||"boolean"==typeof r||"number"==typeof r||"string"==typeof r||"symbol"==typeof r||void 0===r}function objectToString(r){return Object.prototype.toString.call(r)}exports.isArray=isArray,exports.isBoolean=isBoolean,exports.isNull=isNull,exports.isNullOrUndefined=isNullOrUndefined,exports.isNumber=isNumber,exports.isString=isString,exports.isSymbol=isSymbol,exports.isUndefined=isUndefined,exports.isRegExp=isRegExp,exports.isObject=isObject,exports.isDate=isDate,exports.isError=isError,exports.isFunction=isFunction,exports.isPrimitive=isPrimitive,exports.isBuffer=Buffer.isBuffer;
|
|
@@ -692,12 +946,12 @@ function isArray(r){return Array.isArray?Array.isArray(r):"[object Array]"===obj
|
|
|
692
946
|
}
|
|
693
947
|
}
|
|
694
948
|
}, {package:"browserify>readable-stream>core-util-is",file:"../../node_modules/core-util-is/lib/util.js",}],
|
|
695
|
-
[
|
|
949
|
+
[67, {"luxon":93}, function(){
|
|
696
950
|
with (this.scopeTerminator) {
|
|
697
951
|
with (this.globalThis) {
|
|
698
952
|
return function() {
|
|
699
953
|
'use strict';
|
|
700
|
-
// source: /home/runner/work/snaps
|
|
954
|
+
// source: /home/runner/work/snaps/snaps/node_modules/cron-parser/lib/date.js
|
|
701
955
|
return function (require, module, exports) {
|
|
702
956
|
"use strict";var luxon=require("luxon");function CronDate(t,e){var o={zone:e};if(t?t instanceof CronDate?this._date=t._date:t instanceof Date?this._date=luxon.DateTime.fromJSDate(t,o):"number"==typeof t?this._date=luxon.DateTime.fromMillis(t,o):"string"==typeof t&&(this._date=luxon.DateTime.fromISO(t,o),this._date.isValid||(this._date=luxon.DateTime.fromRFC2822(t,o)),this._date.isValid||(this._date=luxon.DateTime.fromSQL(t,o)),this._date.isValid||(this._date=luxon.DateTime.fromFormat(t,"EEE, d MMM yyyy HH:mm:ss",o))):this._date=luxon.DateTime.local(),!this._date||!this._date.isValid)throw new Error("CronDate: unhandled timestamp: "+JSON.stringify(t));e&&e!==this._date.zoneName&&(this._date=this._date.setZone(e))}CronDate.prototype.addYear=function(){this._date=this._date.plus({years:1})},CronDate.prototype.addMonth=function(){this._date=this._date.plus({months:1}).startOf("month")},CronDate.prototype.addDay=function(){this._date=this._date.plus({days:1}).startOf("day")},CronDate.prototype.addHour=function(){var t=this._date;this._date=this._date.plus({hours:1}).startOf("hour"),this._date<=t&&(this._date=this._date.plus({hours:1}))},CronDate.prototype.addMinute=function(){var t=this._date;this._date=this._date.plus({minutes:1}).startOf("minute"),this._date<t&&(this._date=this._date.plus({hours:1}))},CronDate.prototype.addSecond=function(){var t=this._date;this._date=this._date.plus({seconds:1}).startOf("second"),this._date<t&&(this._date=this._date.plus({hours:1}))},CronDate.prototype.subtractYear=function(){this._date=this._date.minus({years:1})},CronDate.prototype.subtractMonth=function(){this._date=this._date.minus({months:1}).endOf("month").startOf("second")},CronDate.prototype.subtractDay=function(){this._date=this._date.minus({days:1}).endOf("day").startOf("second")},CronDate.prototype.subtractHour=function(){var t=this._date;this._date=this._date.minus({hours:1}).endOf("hour").startOf("second"),this._date>=t&&(this._date=this._date.minus({hours:1}))},CronDate.prototype.subtractMinute=function(){var t=this._date;this._date=this._date.minus({minutes:1}).endOf("minute").startOf("second"),this._date>t&&(this._date=this._date.minus({hours:1}))},CronDate.prototype.subtractSecond=function(){var t=this._date;this._date=this._date.minus({seconds:1}).startOf("second"),this._date>t&&(this._date=this._date.minus({hours:1}))},CronDate.prototype.getDate=function(){return this._date.day},CronDate.prototype.getFullYear=function(){return this._date.year},CronDate.prototype.getDay=function(){var t=this._date.weekday;return 7==t?0:t},CronDate.prototype.getMonth=function(){return this._date.month-1},CronDate.prototype.getHours=function(){return this._date.hour},CronDate.prototype.getMinutes=function(){return this._date.minute},CronDate.prototype.getSeconds=function(){return this._date.second},CronDate.prototype.getMilliseconds=function(){return this._date.millisecond},CronDate.prototype.getTime=function(){return this._date.valueOf()},CronDate.prototype.getUTCDate=function(){return this._getUTC().day},CronDate.prototype.getUTCFullYear=function(){return this._getUTC().year},CronDate.prototype.getUTCDay=function(){var t=this._getUTC().weekday;return 7==t?0:t},CronDate.prototype.getUTCMonth=function(){return this._getUTC().month-1},CronDate.prototype.getUTCHours=function(){return this._getUTC().hour},CronDate.prototype.getUTCMinutes=function(){return this._getUTC().minute},CronDate.prototype.getUTCSeconds=function(){return this._getUTC().second},CronDate.prototype.toISOString=function(){return this._date.toUTC().toISO()},CronDate.prototype.toJSON=function(){return this._date.toJSON()},CronDate.prototype.setDate=function(t){this._date=this._date.set({day:t})},CronDate.prototype.setFullYear=function(t){this._date=this._date.set({year:t})},CronDate.prototype.setDay=function(t){this._date=this._date.set({weekday:t})},CronDate.prototype.setMonth=function(t){this._date=this._date.set({month:t+1})},CronDate.prototype.setHours=function(t){this._date=this._date.set({hour:t})},CronDate.prototype.setMinutes=function(t){this._date=this._date.set({minute:t})},CronDate.prototype.setSeconds=function(t){this._date=this._date.set({second:t})},CronDate.prototype.setMilliseconds=function(t){this._date=this._date.set({millisecond:t})},CronDate.prototype._getUTC=function(){return this._date.toUTC()},CronDate.prototype.toString=function(){return this.toDate().toString()},CronDate.prototype.toDate=function(){return this._date.toJSDate()},CronDate.prototype.isLastDayOfMonth=function(){var t=this._date.plus({days:1}).startOf("day");return this._date.month!==t.month},CronDate.prototype.isLastWeekdayOfMonth=function(){var t=this._date.plus({days:7}).startOf("day");return this._date.month!==t.month},module.exports=CronDate;
|
|
703
957
|
|
|
@@ -706,12 +960,12 @@ function isArray(r){return Array.isArray?Array.isArray(r):"[object Array]"===obj
|
|
|
706
960
|
}
|
|
707
961
|
}
|
|
708
962
|
}, {package:"@metamask/snaps-utils>cron-parser",file:"../../node_modules/cron-parser/lib/date.js",}],
|
|
709
|
-
[
|
|
963
|
+
[68, {"./date":67,"./field_stringify":70}, function(){
|
|
710
964
|
with (this.scopeTerminator) {
|
|
711
965
|
with (this.globalThis) {
|
|
712
966
|
return function() {
|
|
713
967
|
'use strict';
|
|
714
|
-
// source: /home/runner/work/snaps
|
|
968
|
+
// source: /home/runner/work/snaps/snaps/node_modules/cron-parser/lib/expression.js
|
|
715
969
|
return function (require, module, exports) {
|
|
716
970
|
"use strict";var CronDate=require("./date"),stringifyField=require("./field_stringify"),LOOP_LIMIT=1e4;function CronExpression(e,r){this._options=r,this._utc=r.utc||!1,this._tz=this._utc?"UTC":r.tz,this._currentDate=new CronDate(r.currentDate,this._tz),this._startDate=r.startDate?new CronDate(r.startDate,this._tz):null,this._endDate=r.endDate?new CronDate(r.endDate,this._tz):null,this._isIterator=r.iterator||!1,this._hasIterated=!1,this._nthDayOfWeek=r.nthDayOfWeek||0,this.fields=CronExpression._freezeFields(e)}CronExpression.map=["second","minute","hour","dayOfMonth","month","dayOfWeek"],CronExpression.predefined={"@yearly":"0 0 1 1 *","@monthly":"0 0 1 * *","@weekly":"0 0 * * 0","@daily":"0 0 * * *","@hourly":"0 * * * *"},CronExpression.constraints=[{min:0,max:59,chars:[]},{min:0,max:59,chars:[]},{min:0,max:23,chars:[]},{min:1,max:31,chars:["L"]},{min:1,max:12,chars:[]},{min:0,max:7,chars:["L"]}],CronExpression.daysInMonth=[31,29,31,30,31,30,31,31,30,31,30,31],CronExpression.aliases={month:{jan:1,feb:2,mar:3,apr:4,may:5,jun:6,jul:7,aug:8,sep:9,oct:10,nov:11,dec:12},dayOfWeek:{sun:0,mon:1,tue:2,wed:3,thu:4,fri:5,sat:6}},CronExpression.parseDefaults=["0","*","*","*","*","*"],CronExpression.standardValidCharacters=/^[,*\d/-]+$/,CronExpression.dayOfWeekValidCharacters=/^[?,*\dL#/-]+$/,CronExpression.dayOfMonthValidCharacters=/^[?,*\dL/-]+$/,CronExpression.validCharacters={second:CronExpression.standardValidCharacters,minute:CronExpression.standardValidCharacters,hour:CronExpression.standardValidCharacters,dayOfMonth:CronExpression.dayOfMonthValidCharacters,month:CronExpression.standardValidCharacters,dayOfWeek:CronExpression.dayOfWeekValidCharacters},CronExpression._isValidConstraintChar=function(e,r){return"string"==typeof r&&e.chars.some((function(e){return r.indexOf(e)>-1}))},CronExpression._parseField=function(e,r,n){switch(e){case"month":case"dayOfWeek":var t=CronExpression.aliases[e];r=r.replace(/[a-z]{3}/gi,(function(e){if(e=e.toLowerCase(),void 0!==t[e])return t[e];throw new Error('Validation error, cannot resolve alias "'+e+'"')}))}if(!CronExpression.validCharacters[e].test(r))throw new Error("Invalid characters, got value: "+r);function i(e){var r=e.split("/");if(r.length>2)throw new Error("Invalid repeat: "+e);return r.length>1?(r[0]==+r[0]&&(r=[r[0]+"-"+n.max,r[1]]),s(r[0],r[r.length-1])):s(e,1)}function s(r,t){var i=[],s=r.split("-");if(s.length>1){if(s.length<2)return+r;if(!s[0].length){if(!s[1].length)throw new Error("Invalid range: "+r);return+r}var o=+s[0],a=+s[1];if(Number.isNaN(o)||Number.isNaN(a)||o<n.min||a>n.max)throw new Error("Constraint error, got range "+o+"-"+a+" expected range "+n.min+"-"+n.max);if(o>a)throw new Error("Invalid range: "+r);var h=+t;if(Number.isNaN(h)||h<=0)throw new Error("Constraint error, cannot repeat at every "+h+" time.");"dayOfWeek"===e&&a%7==0&&i.push(0);for(var f=o,d=a;f<=d;f++){!(-1!==i.indexOf(f))&&h>0&&h%t==0?(h=1,i.push(f)):h++}return i}return Number.isNaN(+r)?r:+r}return-1!==r.indexOf("*")?r=r.replace(/\*/g,n.min+"-"+n.max):-1!==r.indexOf("?")&&(r=r.replace(/\?/g,n.min+"-"+n.max)),function(r){var t=[];function s(r){if(r instanceof Array)for(var i=0,s=r.length;i<s;i++){var o=r[i];if(CronExpression._isValidConstraintChar(n,o))t.push(o);else{if("number"!=typeof o||Number.isNaN(o)||o<n.min||o>n.max)throw new Error("Constraint error, got value "+o+" expected range "+n.min+"-"+n.max);t.push(o)}}else{if(CronExpression._isValidConstraintChar(n,r))return void t.push(r);var a=+r;if(Number.isNaN(a)||a<n.min||a>n.max)throw new Error("Constraint error, got value "+r+" expected range "+n.min+"-"+n.max);"dayOfWeek"===e&&(a%=7),t.push(a)}}var o=r.split(",");if(!o.every((function(e){return e.length>0})))throw new Error("Invalid list value format");if(o.length>1)for(var a=0,h=o.length;a<h;a++)s(i(o[a]));else s(i(r));return t.sort(CronExpression._sortCompareFn),t}(r)},CronExpression._sortCompareFn=function(e,r){var n="number"==typeof e,t="number"==typeof r;return n&&t?e-r:!n&&t?1:n&&!t?-1:e.localeCompare(r)},CronExpression._handleMaxDaysInMonth=function(e){if(1===e.month.length){var r=CronExpression.daysInMonth[e.month[0]-1];if(e.dayOfMonth[0]>r)throw new Error("Invalid explicit day of month definition");return e.dayOfMonth.filter((function(e){return"L"===e||e<=r})).sort(CronExpression._sortCompareFn)}},CronExpression._freezeFields=function(e){for(var r=0,n=CronExpression.map.length;r<n;++r){var t=CronExpression.map[r],i=e[t];e[t]=Object.freeze(i)}return Object.freeze(e)},CronExpression.prototype._applyTimezoneShift=function(e,r,n){if("Month"===n||"Day"===n){var t=e.getTime();e[r+n](),t===e.getTime()&&(0===e.getMinutes()&&0===e.getSeconds()?e.addHour():59===e.getMinutes()&&59===e.getSeconds()&&e.subtractHour())}else{var i=e.getHours();e[r+n]();var s=e.getHours(),o=s-i;2===o?24!==this.fields.hour.length&&(this._dstStart=s):0===o&&0===e.getMinutes()&&0===e.getSeconds()&&24!==this.fields.hour.length&&(this._dstEnd=s)}},CronExpression.prototype._findSchedule=function(e){function r(e,r){for(var n=0,t=r.length;n<t;n++)if(r[n]>=e)return r[n]===e;return r[0]===e}function n(e,r){if(r<6){if(e.getDate()<8&&1===r)return!0;var n=e.getDate()%7?1:0,t=e.getDate()-e.getDate()%7;return Math.floor(t/7)+n===r}return!1}function t(e){return e.length>0&&e.some((function(e){return"string"==typeof e&&e.indexOf("L")>=0}))}var i=(e=e||!1)?"subtract":"add",s=new CronDate(this._currentDate,this._tz),o=this._startDate,a=this._endDate,h=s.getTime(),f=0;for(;f<LOOP_LIMIT;){if(f++,e){if(o&&s.getTime()-o.getTime()<0)throw new Error("Out of the timespan range")}else if(a&&a.getTime()-s.getTime()<0)throw new Error("Out of the timespan range");var d=r(s.getDate(),this.fields.dayOfMonth);t(this.fields.dayOfMonth)&&(d=d||s.isLastDayOfMonth());var l=r(s.getDay(),this.fields.dayOfWeek);t(this.fields.dayOfWeek)&&(l=l||this.fields.dayOfWeek.some((function(e){if(!t([e]))return!1;var r=Number.parseInt(e[0])%7;if(Number.isNaN(r))throw new Error("Invalid last weekday of the month expression: "+e);return s.getDay()===r&&s.isLastWeekdayOfMonth()})));var p=this.fields.dayOfMonth.length>=CronExpression.daysInMonth[s.getMonth()],u=this.fields.dayOfWeek.length===CronExpression.constraints[5].max-CronExpression.constraints[5].min+1,c=s.getHours();if(d||l&&!u)if(p||!u||d)if(!p||u||l)if(this._nthDayOfWeek>0&&!n(s,this._nthDayOfWeek))this._applyTimezoneShift(s,i,"Day");else if(r(s.getMonth()+1,this.fields.month)){if(r(c,this.fields.hour)){if(this._dstEnd===c&&!e){this._dstEnd=null,this._applyTimezoneShift(s,"add","Hour");continue}}else{if(this._dstStart!==c){this._dstStart=null,this._applyTimezoneShift(s,i,"Hour");continue}if(!r(c-1,this.fields.hour)){s[i+"Hour"]();continue}}if(r(s.getMinutes(),this.fields.minute))if(r(s.getSeconds(),this.fields.second)){if(h!==s.getTime())break;"add"===i||0===s.getMilliseconds()?this._applyTimezoneShift(s,i,"Second"):s.setMilliseconds(0)}else this._applyTimezoneShift(s,i,"Second");else this._applyTimezoneShift(s,i,"Minute")}else this._applyTimezoneShift(s,i,"Month");else this._applyTimezoneShift(s,i,"Day");else this._applyTimezoneShift(s,i,"Day");else this._applyTimezoneShift(s,i,"Day")}if(f>=LOOP_LIMIT)throw new Error("Invalid expression, loop limit exceeded");return this._currentDate=new CronDate(s,this._tz),this._hasIterated=!0,s},CronExpression.prototype.next=function(){var e=this._findSchedule();return this._isIterator?{value:e,done:!this.hasNext()}:e},CronExpression.prototype.prev=function(){var e=this._findSchedule(!0);return this._isIterator?{value:e,done:!this.hasPrev()}:e},CronExpression.prototype.hasNext=function(){var e=this._currentDate,r=this._hasIterated;try{return this._findSchedule(),!0}catch(e){return!1}finally{this._currentDate=e,this._hasIterated=r}},CronExpression.prototype.hasPrev=function(){var e=this._currentDate,r=this._hasIterated;try{return this._findSchedule(!0),!0}catch(e){return!1}finally{this._currentDate=e,this._hasIterated=r}},CronExpression.prototype.iterate=function(e,r){var n=[];if(e>=0)for(var t=0,i=e;t<i;t++)try{var s=this.next();n.push(s),r&&r(s,t)}catch(e){break}else for(t=0,i=e;t>i;t--)try{s=this.prev();n.push(s),r&&r(s,t)}catch(e){break}return n},CronExpression.prototype.reset=function(e){this._currentDate=new CronDate(e||this._options.currentDate)},CronExpression.prototype.stringify=function(e){for(var r=[],n=e?0:1,t=CronExpression.map.length;n<t;++n){var i=CronExpression.map[n],s=this.fields[i],o=CronExpression.constraints[n];"dayOfMonth"===i&&1===this.fields.month.length?o={min:1,max:CronExpression.daysInMonth[this.fields.month[0]-1]}:"dayOfWeek"===i&&(o={min:0,max:6},s=7===s[s.length-1]?s.slice(0,-1):s),r.push(stringifyField(s,o.min,o.max))}return r.join(" ")},CronExpression.parse=function(e,r){var n=this;function t(e,r){r||(r={}),void 0===r.currentDate&&(r.currentDate=new CronDate(void 0,n._tz)),CronExpression.predefined[e]&&(e=CronExpression.predefined[e]);var t=[],i=(e+"").trim().split(/\s+/);if(i.length>6)throw new Error("Invalid cron expression");for(var s=CronExpression.map.length-i.length,o=0,a=CronExpression.map.length;o<a;++o){var h=CronExpression.map[o],f=i[i.length>a?o:o-s];if(o<s||!f)t.push(CronExpression._parseField(h,CronExpression.parseDefaults[o],CronExpression.constraints[o]));else{var d="dayOfWeek"===h?u(f):f;t.push(CronExpression._parseField(h,d,CronExpression.constraints[o]))}}var l={};for(o=0,a=CronExpression.map.length;o<a;o++){l[CronExpression.map[o]]=t[o]}var p=CronExpression._handleMaxDaysInMonth(l);return l.dayOfMonth=p||l.dayOfMonth,new CronExpression(l,r);function u(e){var n=e.split("#");if(n.length>1){var t=+n[n.length-1];if(/,/.test(e))throw new Error("Constraint error, invalid dayOfWeek `#` and `,` special characters are incompatible");if(/\//.test(e))throw new Error("Constraint error, invalid dayOfWeek `#` and `/` special characters are incompatible");if(/-/.test(e))throw new Error("Constraint error, invalid dayOfWeek `#` and `-` special characters are incompatible");if(n.length>2||Number.isNaN(t)||t<1||t>5)throw new Error("Constraint error, invalid dayOfWeek occurrence number (#)");return r.nthDayOfWeek=t,n[0]}return e}}return"function"==typeof r&&(r={}),t(e,r)},CronExpression.fieldsToExpression=function(e,r){function n(e,r,n){if(!r)throw new Error("Validation error, Field "+e+" is missing");if(0===r.length)throw new Error("Validation error, Field "+e+" contains no values");for(var t=0,i=r.length;t<i;t++){var s=r[t];if(!CronExpression._isValidConstraintChar(n,s)&&("number"!=typeof s||Number.isNaN(s)||s<n.min||s>n.max))throw new Error("Constraint error, got value "+s+" expected range "+n.min+"-"+n.max)}}for(var t={},i=0,s=CronExpression.map.length;i<s;++i){var o=CronExpression.map[i],a=e[o];n(o,a,CronExpression.constraints[i]);for(var h=[],f=-1;++f<a.length;)h[f]=a[f];if((a=h.sort(CronExpression._sortCompareFn).filter((function(e,r,n){return!r||e!==n[r-1]}))).length!==h.length)throw new Error("Validation error, Field "+o+" contains duplicate values");t[o]=a}var d=CronExpression._handleMaxDaysInMonth(t);return t.dayOfMonth=d||t.dayOfMonth,new CronExpression(t,r||{})},module.exports=CronExpression;
|
|
717
971
|
|
|
@@ -720,12 +974,12 @@ function isArray(r){return Array.isArray?Array.isArray(r):"[object Array]"===obj
|
|
|
720
974
|
}
|
|
721
975
|
}
|
|
722
976
|
}, {package:"@metamask/snaps-utils>cron-parser",file:"../../node_modules/cron-parser/lib/expression.js",}],
|
|
723
|
-
[
|
|
977
|
+
[69, {}, function(){
|
|
724
978
|
with (this.scopeTerminator) {
|
|
725
979
|
with (this.globalThis) {
|
|
726
980
|
return function() {
|
|
727
981
|
'use strict';
|
|
728
|
-
// source: /home/runner/work/snaps
|
|
982
|
+
// source: /home/runner/work/snaps/snaps/node_modules/cron-parser/lib/field_compactor.js
|
|
729
983
|
return function (require, module, exports) {
|
|
730
984
|
"use strict";function buildRange(e){return{start:e,count:1}}function completeRangeWithItem(e,n){e.end=n,e.step=n-e.start,e.count=2}function finalizeCurrentRange(e,n,t){n&&(2===n.count?(e.push(buildRange(n.start)),e.push(buildRange(n.end))):e.push(n)),t&&e.push(t)}function compactField(e){for(var n=[],t=void 0,u=0;u<e.length;u++){var i=e[u];"number"!=typeof i?(finalizeCurrentRange(n,t,buildRange(i)),t=void 0):t?1===t.count?completeRangeWithItem(t,i):t.step===i-t.end?(t.count++,t.end=i):2===t.count?(n.push(buildRange(t.start)),completeRangeWithItem(t=buildRange(t.end),i)):(finalizeCurrentRange(n,t),t=buildRange(i)):t=buildRange(i)}return finalizeCurrentRange(n,t),n}module.exports=compactField;
|
|
731
985
|
|
|
@@ -734,12 +988,12 @@ function isArray(r){return Array.isArray?Array.isArray(r):"[object Array]"===obj
|
|
|
734
988
|
}
|
|
735
989
|
}
|
|
736
990
|
}, {package:"@metamask/snaps-utils>cron-parser",file:"../../node_modules/cron-parser/lib/field_compactor.js",}],
|
|
737
|
-
[
|
|
991
|
+
[70, {"./field_compactor":69}, function(){
|
|
738
992
|
with (this.scopeTerminator) {
|
|
739
993
|
with (this.globalThis) {
|
|
740
994
|
return function() {
|
|
741
995
|
'use strict';
|
|
742
|
-
// source: /home/runner/work/snaps
|
|
996
|
+
// source: /home/runner/work/snaps/snaps/node_modules/cron-parser/lib/field_stringify.js
|
|
743
997
|
return function (require, module, exports) {
|
|
744
998
|
"use strict";var compactField=require("./field_compactor");function stringifyField(t,e,r){var s=compactField(t);if(1===s.length){var n=s[0];if(1===(o=n.step)&&n.start===e&&n.end===r)return"*";if(1!==o&&n.start===e&&n.end===r-o+1)return"*/"+o}for(var i=[],a=0,p=s.length;a<p;++a){var u=s[a];if(1!==u.count){var o=u.step;if(1!==u.step){var d=0==u.start?u.count-1:u.count;u.step*d>u.end?i.push(t.join(",")):u.end===r-u.step+1?i.push(u.start+"/"+u.step):i.push(u.start+"-"+u.end+"/"+u.step)}else i.push(u.start+"-"+u.end)}else i.push(u.start)}return i.join(",")}module.exports=stringifyField;
|
|
745
999
|
|
|
@@ -748,12 +1002,12 @@ function isArray(r){return Array.isArray?Array.isArray(r):"[object Array]"===obj
|
|
|
748
1002
|
}
|
|
749
1003
|
}
|
|
750
1004
|
}, {package:"@metamask/snaps-utils>cron-parser",file:"../../node_modules/cron-parser/lib/field_stringify.js",}],
|
|
751
|
-
[
|
|
1005
|
+
[71, {"./expression":68,"fs":63}, function(){
|
|
752
1006
|
with (this.scopeTerminator) {
|
|
753
1007
|
with (this.globalThis) {
|
|
754
1008
|
return function() {
|
|
755
1009
|
'use strict';
|
|
756
|
-
// source: /home/runner/work/snaps
|
|
1010
|
+
// source: /home/runner/work/snaps/snaps/node_modules/cron-parser/lib/parser.js
|
|
757
1011
|
return function (require, module, exports) {
|
|
758
1012
|
"use strict";var CronExpression=require("./expression");function CronParser(){}CronParser._parseEntry=function(r){var e=r.split(" ");if(6===e.length)return{interval:CronExpression.parse(r)};if(e.length>6)return{interval:CronExpression.parse(e.slice(0,6).join(" ")),command:e.slice(6,e.length)};throw new Error("Invalid entry: "+r)},CronParser.parseExpression=function(r,e){return CronExpression.parse(r,e)},CronParser.fieldsToExpression=function(r,e){return CronExpression.fieldsToExpression(r,e)},CronParser.parseString=function(r){for(var e=r.split("\n"),n={variables:{},expressions:[],errors:{}},s=0,i=e.length;s<i;s++){var o=null,t=e[s].trim();if(t.length>0){if(t.match(/^#/))continue;if(o=t.match(/^(.*)=(.*)$/))n.variables[o[1]]=o[2];else{var a=null;try{a=CronParser._parseEntry("0 "+t),n.expressions.push(a.interval)}catch(r){n.errors[t]=r}}}}return n},CronParser.parseFile=function(r,e){require("fs").readFile(r,(function(r,n){if(!r)return e(null,CronParser.parseString(n.toString()));e(r)}))},module.exports=CronParser;
|
|
759
1013
|
|
|
@@ -762,12 +1016,12 @@ function isArray(r){return Array.isArray?Array.isArray(r):"[object Array]"===obj
|
|
|
762
1016
|
}
|
|
763
1017
|
}
|
|
764
1018
|
}, {package:"@metamask/snaps-utils>cron-parser",file:"../../node_modules/cron-parser/lib/parser.js",}],
|
|
765
|
-
[
|
|
1019
|
+
[72, {}, function(){
|
|
766
1020
|
with (this.scopeTerminator) {
|
|
767
1021
|
with (this.globalThis) {
|
|
768
1022
|
return function() {
|
|
769
1023
|
'use strict';
|
|
770
|
-
// source: /home/runner/work/snaps
|
|
1024
|
+
// source: /home/runner/work/snaps/snaps/node_modules/debug/node_modules/ms/index.js
|
|
771
1025
|
return function (require, module, exports) {
|
|
772
1026
|
var s=1e3,m=60*s,h=60*m,d=24*h,w=7*d,y=365.25*d;function parse(e){if(!((e=String(e)).length>100)){var r=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(r){var a=parseFloat(r[1]);switch((r[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return a*y;case"weeks":case"week":case"w":return a*w;case"days":case"day":case"d":return a*d;case"hours":case"hour":case"hrs":case"hr":case"h":return a*h;case"minutes":case"minute":case"mins":case"min":case"m":return a*m;case"seconds":case"second":case"secs":case"sec":case"s":return a*s;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}function fmtShort(e){var r=Math.abs(e);return r>=d?Math.round(e/d)+"d":r>=h?Math.round(e/h)+"h":r>=m?Math.round(e/m)+"m":r>=s?Math.round(e/s)+"s":e+"ms"}function fmtLong(e){var r=Math.abs(e);return r>=d?plural(e,r,d,"day"):r>=h?plural(e,r,h,"hour"):r>=m?plural(e,r,m,"minute"):r>=s?plural(e,r,s,"second"):e+" ms"}function plural(s,e,r,a){var n=e>=1.5*r;return Math.round(s/r)+" "+a+(n?"s":"")}module.exports=function(s,e){e=e||{};var r=typeof s;if("string"===r&&s.length>0)return parse(s);if("number"===r&&isFinite(s))return e.long?fmtLong(s):fmtShort(s);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(s))};
|
|
773
1027
|
|
|
@@ -776,12 +1030,12 @@ var s=1e3,m=60*s,h=60*m,d=24*h,w=7*d,y=365.25*d;function parse(e){if(!((e=String
|
|
|
776
1030
|
}
|
|
777
1031
|
}
|
|
778
1032
|
}, {package:"eslint>debug>ms",file:"../../node_modules/debug/node_modules/ms/index.js",}],
|
|
779
|
-
[
|
|
1033
|
+
[73, {"./common":74,"_process":94}, function(){
|
|
780
1034
|
with (this.scopeTerminator) {
|
|
781
1035
|
with (this.globalThis) {
|
|
782
1036
|
return function() {
|
|
783
1037
|
'use strict';
|
|
784
|
-
// source: /home/runner/work/snaps
|
|
1038
|
+
// source: /home/runner/work/snaps/snaps/node_modules/debug/src/browser.js
|
|
785
1039
|
return function (require, module, exports) {
|
|
786
1040
|
(function (process){(function (){
|
|
787
1041
|
function useColors(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function formatArgs(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+module.exports.humanize(this.diff),!this.useColors)return;const o="color: "+this.color;e.splice(1,0,o,"color: inherit");let t=0,C=0;e[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(t++,"%c"===e&&(C=t))})),e.splice(C,0,o)}function save(e){try{e?exports.storage.setItem("debug",e):exports.storage.removeItem("debug")}catch(e){}}function load(){let e;try{e=exports.storage.getItem("debug")}catch(e){}return!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG),e}function localstorage(){try{return localStorage}catch(e){}}exports.formatArgs=formatArgs,exports.save=save,exports.load=load,exports.useColors=useColors,exports.storage=localstorage(),exports.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),exports.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],exports.log=console.debug||console.log||(()=>{}),module.exports=require("./common")(exports);const{formatters:formatters}=module.exports;formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}};
|
|
@@ -792,12 +1046,12 @@ function useColors(){return!("undefined"==typeof window||!window.process||"rende
|
|
|
792
1046
|
}
|
|
793
1047
|
}
|
|
794
1048
|
}, {package:"eslint>debug",file:"../../node_modules/debug/src/browser.js",}],
|
|
795
|
-
[
|
|
1049
|
+
[74, {"ms":72}, function(){
|
|
796
1050
|
with (this.scopeTerminator) {
|
|
797
1051
|
with (this.globalThis) {
|
|
798
1052
|
return function() {
|
|
799
1053
|
'use strict';
|
|
800
|
-
// source: /home/runner/work/snaps
|
|
1054
|
+
// source: /home/runner/work/snaps/snaps/node_modules/debug/src/common.js
|
|
801
1055
|
return function (require, module, exports) {
|
|
802
1056
|
function setup(e){function n(e){let r,s,o,l=null;function a(...e){if(!a.enabled)return;const t=a,s=Number(new Date),o=s-(r||s);t.diff=o,t.prev=r,t.curr=s,r=s,e[0]=n.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let l=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((r,s)=>{if("%%"===r)return"%";l++;const o=n.formatters[s];if("function"==typeof o){const n=e[l];r=o.call(t,n),e.splice(l,1),l--}return r})),n.formatArgs.call(t,e);(t.log||n.log).apply(t,e)}return a.namespace=e,a.useColors=n.useColors(),a.color=n.selectColor(e),a.extend=t,a.destroy=n.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==l?l:(s!==n.namespaces&&(s=n.namespaces,o=n.enabled(e)),o),set:e=>{l=e}}),"function"==typeof n.init&&n.init(a),a}function t(e,t){const r=n(this.namespace+(void 0===t?":":t)+e);return r.log=this.log,r}function r(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return n.debug=n,n.default=n,n.coerce=function(e){if(e instanceof Error)return e.stack||e.message;return e},n.disable=function(){const e=[...n.names.map(r),...n.skips.map(r).map((e=>"-"+e))].join(",");return n.enable(""),e},n.enable=function(e){let t;n.save(e),n.namespaces=e,n.names=[],n.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),s=r.length;for(t=0;t<s;t++)r[t]&&("-"===(e=r[t].replace(/\*/g,".*?"))[0]?n.skips.push(new RegExp("^"+e.slice(1)+"$")):n.names.push(new RegExp("^"+e+"$")))},n.enabled=function(e){if("*"===e[e.length-1])return!0;let t,r;for(t=0,r=n.skips.length;t<r;t++)if(n.skips[t].test(e))return!1;for(t=0,r=n.names.length;t<r;t++)if(n.names[t].test(e))return!0;return!1},n.humanize=require("ms"),n.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((t=>{n[t]=e[t]})),n.names=[],n.skips=[],n.formatters={},n.selectColor=function(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return n.colors[Math.abs(t)%n.colors.length]},n.enable(n.load()),n}module.exports=setup;
|
|
803
1057
|
|
|
@@ -806,12 +1060,12 @@ function setup(e){function n(e){let r,s,o,l=null;function a(...e){if(!a.enabled)
|
|
|
806
1060
|
}
|
|
807
1061
|
}
|
|
808
1062
|
}, {package:"eslint>debug",file:"../../node_modules/debug/src/common.js",}],
|
|
809
|
-
[
|
|
1063
|
+
[75, {}, function(){
|
|
810
1064
|
with (this.scopeTerminator) {
|
|
811
1065
|
with (this.globalThis) {
|
|
812
1066
|
return function() {
|
|
813
1067
|
'use strict';
|
|
814
|
-
// source: /home/runner/work/snaps
|
|
1068
|
+
// source: /home/runner/work/snaps/snaps/node_modules/events/events.js
|
|
815
1069
|
return function (require, module, exports) {
|
|
816
1070
|
"use strict";var ReflectOwnKeys,R="object"==typeof Reflect?Reflect:null,ReflectApply=R&&"function"==typeof R.apply?R.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)};function ProcessEmitWarning(e){console&&console.warn&&console.warn(e)}ReflectOwnKeys=R&&"function"==typeof R.ownKeys?R.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var NumberIsNaN=Number.isNaN||function(e){return e!=e};function EventEmitter(){EventEmitter.init.call(this)}module.exports=EventEmitter,module.exports.once=once,EventEmitter.EventEmitter=EventEmitter,EventEmitter.prototype._events=void 0,EventEmitter.prototype._eventsCount=0,EventEmitter.prototype._maxListeners=void 0;var defaultMaxListeners=10;function checkListener(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function _getMaxListeners(e){return void 0===e._maxListeners?EventEmitter.defaultMaxListeners:e._maxListeners}function _addListener(e,t,n,r){var i,o,s;if(checkListener(n),void 0===(o=e._events)?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),o=e._events),s=o[t]),void 0===s)s=o[t]=n,++e._eventsCount;else if("function"==typeof s?s=o[t]=r?[n,s]:[s,n]:r?s.unshift(n):s.push(n),(i=_getMaxListeners(e))>0&&s.length>i&&!s.warned){s.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=e,u.type=t,u.count=s.length,ProcessEmitWarning(u)}return e}function onceWrapper(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function _onceWrap(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=onceWrapper.bind(r);return i.listener=n,r.wrapFn=i,i}function _listeners(e,t,n){var r=e._events;if(void 0===r)return[];var i=r[t];return void 0===i?[]:"function"==typeof i?n?[i.listener||i]:[i]:n?unwrapListeners(i):arrayClone(i,i.length)}function listenerCount(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"==typeof n)return 1;if(void 0!==n)return n.length}return 0}function arrayClone(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function spliceOne(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function unwrapListeners(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}function once(e,t){return new Promise((function(n,r){function i(n){e.removeListener(t,o),r(n)}function o(){"function"==typeof e.removeListener&&e.removeListener("error",i),n([].slice.call(arguments))}eventTargetAgnosticAddListener(e,t,o,{once:!0}),"error"!==t&&addErrorHandlerIfEventEmitter(e,i,{once:!0})}))}function addErrorHandlerIfEventEmitter(e,t,n){"function"==typeof e.on&&eventTargetAgnosticAddListener(e,"error",t,n)}function eventTargetAgnosticAddListener(e,t,n,r){if("function"==typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function i(o){r.once&&e.removeEventListener(t,i),n(o)}))}}Object.defineProperty(EventEmitter,"defaultMaxListeners",{enumerable:!0,get:function(){return defaultMaxListeners},set:function(e){if("number"!=typeof e||e<0||NumberIsNaN(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");defaultMaxListeners=e}}),EventEmitter.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},EventEmitter.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||NumberIsNaN(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},EventEmitter.prototype.getMaxListeners=function(){return _getMaxListeners(this)},EventEmitter.prototype.emit=function(e){for(var t=[],n=1;n<arguments.length;n++)t.push(arguments[n]);var r="error"===e,i=this._events;if(void 0!==i)r=r&&void 0===i.error;else if(!r)return!1;if(r){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var u=i[e];if(void 0===u)return!1;if("function"==typeof u)ReflectApply(u,this,t);else{var f=u.length,v=arrayClone(u,f);for(n=0;n<f;++n)ReflectApply(v[n],this,t)}return!0},EventEmitter.prototype.addListener=function(e,t){return _addListener(this,e,t,!1)},EventEmitter.prototype.on=EventEmitter.prototype.addListener,EventEmitter.prototype.prependListener=function(e,t){return _addListener(this,e,t,!0)},EventEmitter.prototype.once=function(e,t){return checkListener(t),this.on(e,_onceWrap(this,e,t)),this},EventEmitter.prototype.prependOnceListener=function(e,t){return checkListener(t),this.prependListener(e,_onceWrap(this,e,t)),this},EventEmitter.prototype.removeListener=function(e,t){var n,r,i,o,s;if(checkListener(t),void 0===(r=this._events))return this;if(void 0===(n=r[e]))return this;if(n===t||n.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!=typeof n){for(i=-1,o=n.length-1;o>=0;o--)if(n[o]===t||n[o].listener===t){s=n[o].listener,i=o;break}if(i<0)return this;0===i?n.shift():spliceOne(n,i),1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,s||t)}return this},EventEmitter.prototype.off=EventEmitter.prototype.removeListener,EventEmitter.prototype.removeAllListeners=function(e){var t,n,r;if(void 0===(n=this._events))return this;if(void 0===n.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete n[e]),this;if(0===arguments.length){var i,o=Object.keys(n);for(r=0;r<o.length;++r)"removeListener"!==(i=o[r])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(void 0!==t)for(r=t.length-1;r>=0;r--)this.removeListener(e,t[r]);return this},EventEmitter.prototype.listeners=function(e){return _listeners(this,e,!0)},EventEmitter.prototype.rawListeners=function(e){return _listeners(this,e,!1)},EventEmitter.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):listenerCount.call(e,t)},EventEmitter.prototype.listenerCount=listenerCount,EventEmitter.prototype.eventNames=function(){return this._eventsCount>0?ReflectOwnKeys(this._events):[]};
|
|
817
1071
|
|
|
@@ -820,12 +1074,12 @@ function setup(e){function n(e){let r,s,o,l=null;function a(...e){if(!a.enabled)
|
|
|
820
1074
|
}
|
|
821
1075
|
}
|
|
822
1076
|
}, {package:"browserify>events",file:"../../node_modules/events/events.js",}],
|
|
823
|
-
[
|
|
1077
|
+
[76, {}, function(){
|
|
824
1078
|
with (this.scopeTerminator) {
|
|
825
1079
|
with (this.globalThis) {
|
|
826
1080
|
return function() {
|
|
827
1081
|
'use strict';
|
|
828
|
-
// source: /home/runner/work/snaps
|
|
1082
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-json-stable-stringify/index.js
|
|
829
1083
|
return function (require, module, exports) {
|
|
830
1084
|
"use strict";module.exports=function(r,t){t||(t={}),"function"==typeof t&&(t={cmp:t});var e,n="boolean"==typeof t.cycles&&t.cycles,i=t.cmp&&(e=t.cmp,function(r){return function(t,n){var i={key:t,value:r[t]},u={key:n,value:r[n]};return e(i,u)}}),u=[];return function r(t){if(t&&t.toJSON&&"function"==typeof t.toJSON&&(t=t.toJSON()),void 0!==t){if("number"==typeof t)return isFinite(t)?""+t:"null";if("object"!=typeof t)return JSON.stringify(t);var e,o;if(Array.isArray(t)){for(o="[",e=0;e<t.length;e++)e&&(o+=","),o+=r(t[e])||"null";return o+"]"}if(null===t)return"null";if(-1!==u.indexOf(t)){if(n)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var f=u.push(t)-1,c=Object.keys(t).sort(i&&i(t));for(o="",e=0;e<c.length;e++){var l=c[e],y=r(t[l]);y&&(o&&(o+=","),o+=JSON.stringify(l)+":"+y)}return u.splice(f,1),"{"+o+"}"}}(r)};
|
|
831
1085
|
|
|
@@ -833,13 +1087,167 @@ function setup(e){function n(e){let r,s,o,l=null;function a(...e){if(!a.enabled)
|
|
|
833
1087
|
};
|
|
834
1088
|
}
|
|
835
1089
|
}
|
|
836
|
-
}, {package:"
|
|
837
|
-
[
|
|
1090
|
+
}, {package:"@metamask/snaps-utils>fast-json-stable-stringify",file:"../../node_modules/fast-json-stable-stringify/index.js",}],
|
|
1091
|
+
[77, {"./validator":79,"./xmlbuilder/json2xml":80,"./xmlparser/XMLParser":85}, function(){
|
|
1092
|
+
with (this.scopeTerminator) {
|
|
1093
|
+
with (this.globalThis) {
|
|
1094
|
+
return function() {
|
|
1095
|
+
'use strict';
|
|
1096
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/fxp.js
|
|
1097
|
+
return function (require, module, exports) {
|
|
1098
|
+
"use strict";const validator=require("./validator"),XMLParser=require("./xmlparser/XMLParser"),XMLBuilder=require("./xmlbuilder/json2xml");module.exports={XMLParser:XMLParser,XMLValidator:validator,/* common-shake removed: XMLBuilder:XMLBuilder */};
|
|
1099
|
+
|
|
1100
|
+
};
|
|
1101
|
+
};
|
|
1102
|
+
}
|
|
1103
|
+
}
|
|
1104
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/fxp.js",}],
|
|
1105
|
+
[78, {}, function(){
|
|
1106
|
+
with (this.scopeTerminator) {
|
|
1107
|
+
with (this.globalThis) {
|
|
1108
|
+
return function() {
|
|
1109
|
+
'use strict';
|
|
1110
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/util.js
|
|
1111
|
+
return function (require, module, exports) {
|
|
1112
|
+
"use strict";const nameStartChar=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",nameChar=nameStartChar+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",nameRegexp="["+nameStartChar+"]["+nameChar+"]*",regexName=new RegExp("^"+nameRegexp+"$"),getAllMatches=function(e,t){const u=[];let n=t.exec(e);for(;n;){const r=[];r.startIndex=t.lastIndex-n[0].length;const s=n.length;for(let e=0;e<s;e++)r.push(n[e]);u.push(r),n=t.exec(e)}return u},isName=function(e){const t=regexName.exec(e);return!(null==t)};exports.isExist=function(e){return void 0!==e},/* common-shake removed: exports.isEmptyObject = */ void 0, function(e){return 0===Object.keys(e).length},/* common-shake removed: exports.merge = */ void 0, function(e,t,u){if(t){const n=Object.keys(t),r=n.length;for(let s=0;s<r;s++)e[n[s]]="strict"===u?[t[n[s]]]:t[n[s]]}},/* common-shake removed: exports.getValue = */ void 0, function(e){return exports.isExist(e)?e:""},exports.isName=isName,exports.getAllMatches=getAllMatches,exports.nameRegexp=nameRegexp;
|
|
1113
|
+
|
|
1114
|
+
};
|
|
1115
|
+
};
|
|
1116
|
+
}
|
|
1117
|
+
}
|
|
1118
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/util.js",}],
|
|
1119
|
+
[79, {"./util":78}, function(){
|
|
1120
|
+
with (this.scopeTerminator) {
|
|
1121
|
+
with (this.globalThis) {
|
|
1122
|
+
return function() {
|
|
1123
|
+
'use strict';
|
|
1124
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/validator.js
|
|
1125
|
+
return function (require, module, exports) {
|
|
1126
|
+
"use strict";const util=require("./util"),defaultOptions={allowBooleanAttributes:!1,unpairedTags:[]};function isWhiteSpace(t){return" "===t||"\t"===t||"\n"===t||"\r"===t}function readPI(t,e){const r=e;for(;e<t.length;e++)if("?"!=t[e]&&" "!=t[e]);else{const n=t.substr(r,e-r);if(e>5&&"xml"===n)return getErrorObject("InvalidXml","XML declaration allowed only at the start of the document.",getLineNumberForPosition(t,e));if("?"==t[e]&&">"==t[e+1]){e++;break}}return e}function readCommentAndCDATA(t,e){if(t.length>e+5&&"-"===t[e+1]&&"-"===t[e+2]){for(e+=3;e<t.length;e++)if("-"===t[e]&&"-"===t[e+1]&&">"===t[e+2]){e+=2;break}}else if(t.length>e+8&&"D"===t[e+1]&&"O"===t[e+2]&&"C"===t[e+3]&&"T"===t[e+4]&&"Y"===t[e+5]&&"P"===t[e+6]&&"E"===t[e+7]){let r=1;for(e+=8;e<t.length;e++)if("<"===t[e])r++;else if(">"===t[e]&&(r--,0===r))break}else if(t.length>e+9&&"["===t[e+1]&&"C"===t[e+2]&&"D"===t[e+3]&&"A"===t[e+4]&&"T"===t[e+5]&&"A"===t[e+6]&&"["===t[e+7])for(e+=8;e<t.length;e++)if("]"===t[e]&&"]"===t[e+1]&&">"===t[e+2]){e+=2;break}return e}exports.validate=function(t,e){e=Object.assign({},defaultOptions,e);const r=[];let n=!1,i=!1;"\ufeff"===t[0]&&(t=t.substr(1));for(let o=0;o<t.length;o++)if("<"===t[o]&&"?"===t[o+1]){if(o+=2,o=readPI(t,o),o.err)return o}else{if("<"!==t[o]){if(isWhiteSpace(t[o]))continue;return getErrorObject("InvalidChar","char '"+t[o]+"' is not expected.",getLineNumberForPosition(t,o))}{let a=o;if(o++,"!"===t[o]){o=readCommentAndCDATA(t,o);continue}{let l=!1;"/"===t[o]&&(l=!0,o++);let g="";for(;o<t.length&&">"!==t[o]&&" "!==t[o]&&"\t"!==t[o]&&"\n"!==t[o]&&"\r"!==t[o];o++)g+=t[o];if(g=g.trim(),"/"===g[g.length-1]&&(g=g.substring(0,g.length-1),o--),!validateTagName(g)){let e;return e=0===g.trim().length?"Invalid space after '<'.":"Tag '"+g+"' is an invalid name.",getErrorObject("InvalidTag",e,getLineNumberForPosition(t,o))}const s=readAttributeStr(t,o);if(!1===s)return getErrorObject("InvalidAttr","Attributes for '"+g+"' have open quote.",getLineNumberForPosition(t,o));let u=s.value;if(o=s.index,"/"===u[u.length-1]){const r=o-u.length;u=u.substring(0,u.length-1);const i=validateAttributeString(u,e);if(!0!==i)return getErrorObject(i.err.code,i.err.msg,getLineNumberForPosition(t,r+i.err.line));n=!0}else if(l){if(!s.tagClosed)return getErrorObject("InvalidTag","Closing tag '"+g+"' doesn't have proper closing.",getLineNumberForPosition(t,o));if(u.trim().length>0)return getErrorObject("InvalidTag","Closing tag '"+g+"' can't have attributes or invalid starting.",getLineNumberForPosition(t,a));{const e=r.pop();if(g!==e.tagName){let r=getLineNumberForPosition(t,e.tagStartPos);return getErrorObject("InvalidTag","Expected closing tag '"+e.tagName+"' (opened in line "+r.line+", col "+r.col+") instead of closing tag '"+g+"'.",getLineNumberForPosition(t,a))}0==r.length&&(i=!0)}}else{const l=validateAttributeString(u,e);if(!0!==l)return getErrorObject(l.err.code,l.err.msg,getLineNumberForPosition(t,o-u.length+l.err.line));if(!0===i)return getErrorObject("InvalidXml","Multiple possible root nodes found.",getLineNumberForPosition(t,o));-1!==e.unpairedTags.indexOf(g)||r.push({tagName:g,tagStartPos:a}),n=!0}for(o++;o<t.length;o++)if("<"===t[o]){if("!"===t[o+1]){o++,o=readCommentAndCDATA(t,o);continue}if("?"!==t[o+1])break;if(o=readPI(t,++o),o.err)return o}else if("&"===t[o]){const e=validateAmpersand(t,o);if(-1==e)return getErrorObject("InvalidChar","char '&' is not expected.",getLineNumberForPosition(t,o));o=e}else if(!0===i&&!isWhiteSpace(t[o]))return getErrorObject("InvalidXml","Extra text at the end",getLineNumberForPosition(t,o));"<"===t[o]&&o--}}}return n?1==r.length?getErrorObject("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",getLineNumberForPosition(t,r[0].tagStartPos)):!(r.length>0)||getErrorObject("InvalidXml","Invalid '"+JSON.stringify(r.map((t=>t.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):getErrorObject("InvalidXml","Start tag expected.",1)};const doubleQuote='"',singleQuote="'";function readAttributeStr(t,e){let r="",n="",i=!1;for(;e<t.length;e++){if(t[e]===doubleQuote||t[e]===singleQuote)""===n?n=t[e]:n!==t[e]||(n="");else if(">"===t[e]&&""===n){i=!0;break}r+=t[e]}return""===n&&{value:r,index:e,tagClosed:i}}const validAttrStrRegxp=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g");function validateAttributeString(t,e){const r=util.getAllMatches(t,validAttrStrRegxp),n={};for(let t=0;t<r.length;t++){if(0===r[t][1].length)return getErrorObject("InvalidAttr","Attribute '"+r[t][2]+"' has no space in starting.",getPositionFromMatch(r[t]));if(void 0!==r[t][3]&&void 0===r[t][4])return getErrorObject("InvalidAttr","Attribute '"+r[t][2]+"' is without value.",getPositionFromMatch(r[t]));if(void 0===r[t][3]&&!e.allowBooleanAttributes)return getErrorObject("InvalidAttr","boolean attribute '"+r[t][2]+"' is not allowed.",getPositionFromMatch(r[t]));const i=r[t][2];if(!validateAttrName(i))return getErrorObject("InvalidAttr","Attribute '"+i+"' is an invalid name.",getPositionFromMatch(r[t]));if(n.hasOwnProperty(i))return getErrorObject("InvalidAttr","Attribute '"+i+"' is repeated.",getPositionFromMatch(r[t]));n[i]=1}return!0}function validateNumberAmpersand(t,e){let r=/\d/;for("x"===t[e]&&(e++,r=/[\da-fA-F]/);e<t.length;e++){if(";"===t[e])return e;if(!t[e].match(r))break}return-1}function validateAmpersand(t,e){if(";"===t[++e])return-1;if("#"===t[e])return validateNumberAmpersand(t,++e);let r=0;for(;e<t.length;e++,r++)if(!(t[e].match(/\w/)&&r<20)){if(";"===t[e])break;return-1}return e}function getErrorObject(t,e,r){return{err:{code:t,msg:e,line:r.line||r,col:r.col}}}function validateAttrName(t){return util.isName(t)}function validateTagName(t){return util.isName(t)}function getLineNumberForPosition(t,e){const r=t.substring(0,e).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}function getPositionFromMatch(t){return t.startIndex+t[1].length}
|
|
1127
|
+
|
|
1128
|
+
};
|
|
1129
|
+
};
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/validator.js",}],
|
|
1133
|
+
[80, {"./orderedJs2Xml":81}, function(){
|
|
1134
|
+
with (this.scopeTerminator) {
|
|
1135
|
+
with (this.globalThis) {
|
|
1136
|
+
return function() {
|
|
1137
|
+
'use strict';
|
|
1138
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/xmlbuilder/json2xml.js
|
|
1139
|
+
return function (require, module, exports) {
|
|
1140
|
+
"use strict";const buildFromOrderedJs=require("./orderedJs2Xml"),defaultOptions={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};function Builder(t){this.options=Object.assign({},defaultOptions,t),this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=isAttribute),this.processTextOrObjNode=processTextOrObjNode,this.options.format?(this.indentate=indentate,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function processTextOrObjNode(t,e,i){const s=this.j2x(t,i+1);return void 0!==t[this.options.textNodeName]&&1===Object.keys(t).length?this.buildTextValNode(t[this.options.textNodeName],e,s.attrStr,i):this.buildObjectNode(s.val,e,s.attrStr,i)}function buildEmptyObjNode(t,e,i,s){return""!==t?this.buildObjectNode(t,e,i,s):"?"===e[0]?this.indentate(s)+"<"+e+i+"?"+this.tagEndChar:this.indentate(s)+"<"+e+i+"/"+this.tagEndChar}function indentate(t){return this.options.indentBy.repeat(t)}function isAttribute(t){return!!t.startsWith(this.options.attributeNamePrefix)&&t.substr(this.attrPrefixLen)}Builder.prototype.build=function(t){return this.options.preserveOrder?buildFromOrderedJs(t,this.options):(Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t}),this.j2x(t,0).val)},Builder.prototype.j2x=function(t,e){let i="",s="";for(let n in t)if(void 0===t[n]);else if(null===t[n])"?"===n[0]?s+=this.indentate(e)+"<"+n+"?"+this.tagEndChar:s+=this.indentate(e)+"<"+n+"/"+this.tagEndChar;else if(t[n]instanceof Date)s+=this.buildTextValNode(t[n],n,"",e);else if("object"!=typeof t[n]){const r=this.isAttribute(n);if(r)i+=this.buildAttrPairStr(r,""+t[n]);else if(n===this.options.textNodeName){let e=this.options.tagValueProcessor(n,""+t[n]);s+=this.replaceEntitiesValue(e)}else s+=this.buildTextValNode(t[n],n,"",e)}else if(Array.isArray(t[n])){const i=t[n].length;let r="";for(let o=0;o<i;o++){const i=t[n][o];void 0===i||(null===i?"?"===n[0]?s+=this.indentate(e)+"<"+n+"?"+this.tagEndChar:s+=this.indentate(e)+"<"+n+"/"+this.tagEndChar:"object"==typeof i?this.options.oneListGroup?r+=this.j2x(i,e+1).val:r+=this.processTextOrObjNode(i,n,e):r+=this.buildTextValNode(i,n,"",e))}this.options.oneListGroup&&(r=this.buildObjectNode(r,n,"",e)),s+=r}else if(this.options.attributesGroupName&&n===this.options.attributesGroupName){const e=Object.keys(t[n]),s=e.length;for(let r=0;r<s;r++)i+=this.buildAttrPairStr(e[r],""+t[n][e[r]])}else s+=this.processTextOrObjNode(t[n],n,e);return{attrStr:i,val:s}},Builder.prototype.buildAttrPairStr=function(t,e){return e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e),this.options.suppressBooleanAttributes&&"true"===e?" "+t:" "+t+'="'+e+'"'},Builder.prototype.buildObjectNode=function(t,e,i,s){if(""===t)return"?"===e[0]?this.indentate(s)+"<"+e+i+"?"+this.tagEndChar:this.indentate(s)+"<"+e+i+this.closeTag(e)+this.tagEndChar;{let n="</"+e+this.tagEndChar,r="";return"?"===e[0]&&(r="?",n=""),i&&-1===t.indexOf("<")?this.indentate(s)+"<"+e+i+r+">"+t+n:!1!==this.options.commentPropName&&e===this.options.commentPropName&&0===r.length?this.indentate(s)+`\x3c!--${t}--\x3e`+this.newLine:this.indentate(s)+"<"+e+i+r+this.tagEndChar+t+this.indentate(s)+n}},Builder.prototype.closeTag=function(t){let e="";return-1!==this.options.unpairedTags.indexOf(t)?this.options.suppressUnpairedNode||(e="/"):e=this.options.suppressEmptyNode?"/":`></${t}`,e},Builder.prototype.buildTextValNode=function(t,e,i,s){if(!1!==this.options.cdataPropName&&e===this.options.cdataPropName)return this.indentate(s)+`<![CDATA[${t}]]>`+this.newLine;if(!1!==this.options.commentPropName&&e===this.options.commentPropName)return this.indentate(s)+`\x3c!--${t}--\x3e`+this.newLine;if("?"===e[0])return this.indentate(s)+"<"+e+i+"?"+this.tagEndChar;{let n=this.options.tagValueProcessor(e,t);return n=this.replaceEntitiesValue(n),""===n?this.indentate(s)+"<"+e+i+this.closeTag(e)+this.tagEndChar:this.indentate(s)+"<"+e+i+">"+n+"</"+e+this.tagEndChar}},Builder.prototype.replaceEntitiesValue=function(t){if(t&&t.length>0&&this.options.processEntities)for(let e=0;e<this.options.entities.length;e++){const i=this.options.entities[e];t=t.replace(i.regex,i.val)}return t},module.exports=Builder;
|
|
1141
|
+
|
|
1142
|
+
};
|
|
1143
|
+
};
|
|
1144
|
+
}
|
|
1145
|
+
}
|
|
1146
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/xmlbuilder/json2xml.js",}],
|
|
1147
|
+
[81, {}, function(){
|
|
1148
|
+
with (this.scopeTerminator) {
|
|
1149
|
+
with (this.globalThis) {
|
|
1150
|
+
return function() {
|
|
1151
|
+
'use strict';
|
|
1152
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/xmlbuilder/orderedJs2Xml.js
|
|
1153
|
+
return function (require, module, exports) {
|
|
1154
|
+
const EOL="\n";function toXml(t,e){let n="";return e.format&&e.indentBy.length>0&&(n=EOL),arrToStr(t,e,"",n)}function arrToStr(t,e,n,r){let o="",s=!1;for(let i=0;i<t.length;i++){const l=t[i],a=propName(l);let u="";if(u=0===n.length?a:`${n}.${a}`,a===e.textNodeName){let t=l[a];isStopNode(u,e)||(t=e.tagValueProcessor(a,t),t=replaceEntitiesValue(t,e)),s&&(o+=r),o+=t,s=!1;continue}if(a===e.cdataPropName){s&&(o+=r),o+=`<![CDATA[${l[a][0][e.textNodeName]}]]>`,s=!1;continue}if(a===e.commentPropName){o+=r+`\x3c!--${l[a][0][e.textNodeName]}--\x3e`,s=!0;continue}if("?"===a[0]){const t=attr_to_str(l[":@"],e),n="?xml"===a?"":r;let i=l[a][0][e.textNodeName];i=0!==i.length?" "+i:"",o+=n+`<${a}${i}${t}?>`,s=!0;continue}let c=r;""!==c&&(c+=e.indentBy);const p=r+`<${a}${attr_to_str(l[":@"],e)}`,d=arrToStr(l[a],e,u,c);-1!==e.unpairedTags.indexOf(a)?e.suppressUnpairedNode?o+=p+">":o+=p+"/>":d&&0!==d.length||!e.suppressEmptyNode?d&&d.endsWith(">")?o+=p+`>${d}${r}</${a}>`:(o+=p+">",d&&""!==r&&(d.includes("/>")||d.includes("</"))?o+=r+e.indentBy+d+r:o+=d,o+=`</${a}>`):o+=p+"/>",s=!0}return o}function propName(t){const e=Object.keys(t);for(let t=0;t<e.length;t++){const n=e[t];if(":@"!==n)return n}}function attr_to_str(t,e){let n="";if(t&&!e.ignoreAttributes)for(let r in t){let o=e.attributeValueProcessor(r,t[r]);o=replaceEntitiesValue(o,e),!0===o&&e.suppressBooleanAttributes?n+=` ${r.substr(e.attributeNamePrefix.length)}`:n+=` ${r.substr(e.attributeNamePrefix.length)}="${o}"`}return n}function isStopNode(t,e){let n=(t=t.substr(0,t.length-e.textNodeName.length-1)).substr(t.lastIndexOf(".")+1);for(let r in e.stopNodes)if(e.stopNodes[r]===t||e.stopNodes[r]==="*."+n)return!0;return!1}function replaceEntitiesValue(t,e){if(t&&t.length>0&&e.processEntities)for(let n=0;n<e.entities.length;n++){const r=e.entities[n];t=t.replace(r.regex,r.val)}return t}module.exports=toXml;
|
|
1155
|
+
|
|
1156
|
+
};
|
|
1157
|
+
};
|
|
1158
|
+
}
|
|
1159
|
+
}
|
|
1160
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/xmlbuilder/orderedJs2Xml.js",}],
|
|
1161
|
+
[82, {}, function(){
|
|
1162
|
+
with (this.scopeTerminator) {
|
|
1163
|
+
with (this.globalThis) {
|
|
1164
|
+
return function() {
|
|
1165
|
+
'use strict';
|
|
1166
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/xmlparser/DocTypeReader.js
|
|
1167
|
+
return function (require, module, exports) {
|
|
1168
|
+
function readDocType(t,e){const n={};if("O"!==t[e+3]||"C"!==t[e+4]||"T"!==t[e+5]||"Y"!==t[e+6]||"P"!==t[e+7]||"E"!==t[e+8])throw new Error("Invalid Tag instead of DOCTYPE");{e+=9;let i=1,r=!1,o=!1,s="";for(;e<t.length;e++)if("<"!==t[e]||o)if(">"===t[e]){if(o?"-"===t[e-1]&&"-"===t[e-2]&&(o=!1,i--):i--,0===i)break}else"["===t[e]?r=!0:s+=t[e];else{if(r&&isEntity(t,e))e+=7,[entityName,val,e]=readEntityExp(t,e+1),-1===val.indexOf("&")&&(n[entityName]={regx:RegExp(`&${entityName};`,"g"),val:val});else if(r&&isElement(t,e))e+=8;else if(r&&isAttlist(t,e))e+=8;else if(r&&isNotation(t,e))e+=9;else{if(!isComment)throw new Error("Invalid DOCTYPE");o=!0}i++,s=""}if(0!==i)throw new Error("Unclosed DOCTYPE")}return{entities:n,i:e}}function readEntityExp(t,e){let n="";for(;e<t.length&&"'"!==t[e]&&'"'!==t[e];e++)n+=t[e];if(n=n.trim(),-1!==n.indexOf(" "))throw new Error("External entites are not supported");const i=t[e++];let r="";for(;e<t.length&&t[e]!==i;e++)r+=t[e];return[n,r,e]}function isComment(t,e){return"!"===t[e+1]&&"-"===t[e+2]&&"-"===t[e+3]}function isEntity(t,e){return"!"===t[e+1]&&"E"===t[e+2]&&"N"===t[e+3]&&"T"===t[e+4]&&"I"===t[e+5]&&"T"===t[e+6]&&"Y"===t[e+7]}function isElement(t,e){return"!"===t[e+1]&&"E"===t[e+2]&&"L"===t[e+3]&&"E"===t[e+4]&&"M"===t[e+5]&&"E"===t[e+6]&&"N"===t[e+7]&&"T"===t[e+8]}function isAttlist(t,e){return"!"===t[e+1]&&"A"===t[e+2]&&"T"===t[e+3]&&"T"===t[e+4]&&"L"===t[e+5]&&"I"===t[e+6]&&"S"===t[e+7]&&"T"===t[e+8]}function isNotation(t,e){return"!"===t[e+1]&&"N"===t[e+2]&&"O"===t[e+3]&&"T"===t[e+4]&&"A"===t[e+5]&&"T"===t[e+6]&&"I"===t[e+7]&&"O"===t[e+8]&&"N"===t[e+9]}module.exports=readDocType;
|
|
1169
|
+
|
|
1170
|
+
};
|
|
1171
|
+
};
|
|
1172
|
+
}
|
|
1173
|
+
}
|
|
1174
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/xmlparser/DocTypeReader.js",}],
|
|
1175
|
+
[83, {}, function(){
|
|
1176
|
+
with (this.scopeTerminator) {
|
|
1177
|
+
with (this.globalThis) {
|
|
1178
|
+
return function() {
|
|
1179
|
+
'use strict';
|
|
1180
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/xmlparser/OptionsBuilder.js
|
|
1181
|
+
return function (require, module, exports) {
|
|
1182
|
+
const defaultOptions={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(e,t,r){return e}},buildOptions=function(e){return Object.assign({},defaultOptions,e)};exports.buildOptions=buildOptions,/* common-shake removed: exports.defaultOptions = */ void defaultOptions;
|
|
1183
|
+
|
|
1184
|
+
};
|
|
1185
|
+
};
|
|
1186
|
+
}
|
|
1187
|
+
}
|
|
1188
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/xmlparser/OptionsBuilder.js",}],
|
|
1189
|
+
[84, {"../util":78,"./DocTypeReader":82,"./xmlNode":87,"strnum":141}, function(){
|
|
1190
|
+
with (this.scopeTerminator) {
|
|
1191
|
+
with (this.globalThis) {
|
|
1192
|
+
return function() {
|
|
1193
|
+
'use strict';
|
|
1194
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/xmlparser/OrderedObjParser.js
|
|
1195
|
+
return function (require, module, exports) {
|
|
1196
|
+
"use strict";const util=require("../util"),xmlNode=require("./xmlNode"),readDocType=require("./DocTypeReader"),toNumber=require("strnum"),regx="<((!\\[CDATA\\[([\\s\\S]*?)(]]>))|((NAME:)?(NAME))([^>]*)>|((\\/)(NAME)\\s*>))([^<]*)".replace(/NAME/g,util.nameRegexp);class OrderedObjParser{constructor(t){this.options=t,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"}},this.addExternalEntities=addExternalEntities,this.parseXml=parseXml,this.parseTextData=parseTextData,this.resolveNameSpace=resolveNameSpace,this.buildAttributesMap=buildAttributesMap,this.isItStopNode=isItStopNode,this.replaceEntitiesValue=replaceEntitiesValue,this.readStopNodeData=readStopNodeData,this.saveTextToParentTag=saveTextToParentTag,this.addChild=addChild}}function addExternalEntities(t){const e=Object.keys(t);for(let s=0;s<e.length;s++){const i=e[s];this.lastEntities[i]={regex:new RegExp("&"+i+";","g"),val:t[i]}}}function parseTextData(t,e,s,i,n,o,a){if(void 0!==t&&(this.options.trimValues&&!i&&(t=t.trim()),t.length>0)){a||(t=this.replaceEntitiesValue(t));const i=this.options.tagValueProcessor(e,t,s,n,o);if(null==i)return t;if(typeof i!=typeof t||i!==t)return i;if(this.options.trimValues)return parseValue(t,this.options.parseTagValue,this.options.numberParseOptions);return t.trim()===t?parseValue(t,this.options.parseTagValue,this.options.numberParseOptions):t}}function resolveNameSpace(t){if(this.options.removeNSPrefix){const e=t.split(":"),s="/"===t.charAt(0)?"/":"";if("xmlns"===e[0])return"";2===e.length&&(t=s+e[1])}return t}const attrsRegx=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");function buildAttributesMap(t,e,s){if(!this.options.ignoreAttributes&&"string"==typeof t){const s=util.getAllMatches(t,attrsRegx),i=s.length,n={};for(let t=0;t<i;t++){const i=this.resolveNameSpace(s[t][1]);let o=s[t][4],a=this.options.attributeNamePrefix+i;if(i.length)if(this.options.transformAttributeName&&(a=this.options.transformAttributeName(a)),"__proto__"===a&&(a="#__proto__"),void 0!==o){this.options.trimValues&&(o=o.trim()),o=this.replaceEntitiesValue(o);const t=this.options.attributeValueProcessor(i,o,e);n[a]=null==t?o:typeof t!=typeof o||t!==o?t:parseValue(o,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(n[a]=!0)}if(!Object.keys(n).length)return;if(this.options.attributesGroupName){const t={};return t[this.options.attributesGroupName]=n,t}return n}}const parseXml=function(t){t=t.replace(/\r\n?/g,"\n");const e=new xmlNode("!xml");let s=e,i="",n="";for(let o=0;o<t.length;o++){if("<"===t[o])if("/"===t[o+1]){const e=findClosingIndex(t,">",o,"Closing Tag is not closed.");let a=t.substring(o+2,e).trim();if(this.options.removeNSPrefix){const t=a.indexOf(":");-1!==t&&(a=a.substr(t+1))}this.options.transformTagName&&(a=this.options.transformTagName(a)),s&&(i=this.saveTextToParentTag(i,s,n));const r=n.substring(n.lastIndexOf(".")+1);if(a&&-1!==this.options.unpairedTags.indexOf(a))throw new Error(`Unpaired tag can not be used as closing tag: </${a}>`);let l=0;r&&-1!==this.options.unpairedTags.indexOf(r)?(l=n.lastIndexOf(".",n.lastIndexOf(".")-1),this.tagsNodeStack.pop()):l=n.lastIndexOf("."),n=n.substring(0,l),s=this.tagsNodeStack.pop(),i="",o=e}else if("?"===t[o+1]){let e=readTagExp(t,o,!1,"?>");if(!e)throw new Error("Pi Tag is not closed.");if(i=this.saveTextToParentTag(i,s,n),this.options.ignoreDeclaration&&"?xml"===e.tagName||this.options.ignorePiTags);else{const t=new xmlNode(e.tagName);t.add(this.options.textNodeName,""),e.tagName!==e.tagExp&&e.attrExpPresent&&(t[":@"]=this.buildAttributesMap(e.tagExp,n,e.tagName)),this.addChild(s,t,n)}o=e.closeIndex+1}else if("!--"===t.substr(o+1,3)){const e=findClosingIndex(t,"--\x3e",o+4,"Comment is not closed.");if(this.options.commentPropName){const a=t.substring(o+4,e-2);i=this.saveTextToParentTag(i,s,n),s.add(this.options.commentPropName,[{[this.options.textNodeName]:a}])}o=e}else if("!D"===t.substr(o+1,2)){const e=readDocType(t,o);this.docTypeEntities=e.entities,o=e.i}else if("!["===t.substr(o+1,2)){const e=findClosingIndex(t,"]]>",o,"CDATA is not closed.")-2,a=t.substring(o+9,e);if(i=this.saveTextToParentTag(i,s,n),this.options.cdataPropName)s.add(this.options.cdataPropName,[{[this.options.textNodeName]:a}]);else{let t=this.parseTextData(a,s.tagname,n,!0,!1,!0);null==t&&(t=""),s.add(this.options.textNodeName,t)}o=e+2}else{let a=readTagExp(t,o,this.options.removeNSPrefix),r=a.tagName,l=a.tagExp,d=a.attrExpPresent,p=a.closeIndex;this.options.transformTagName&&(r=this.options.transformTagName(r)),s&&i&&"!xml"!==s.tagname&&(i=this.saveTextToParentTag(i,s,n,!1));const g=s;if(g&&-1!==this.options.unpairedTags.indexOf(g.tagname)&&(s=this.tagsNodeStack.pop(),n=n.substring(0,n.lastIndexOf("."))),r!==e.tagname&&(n+=n?"."+r:r),this.isItStopNode(this.options.stopNodes,n,r)){let e="";if(l.length>0&&l.lastIndexOf("/")===l.length-1)o=a.closeIndex;else if(-1!==this.options.unpairedTags.indexOf(r))o=a.closeIndex;else{const s=this.readStopNodeData(t,r,p+1);if(!s)throw new Error(`Unexpected end of ${r}`);o=s.i,e=s.tagContent}const i=new xmlNode(r);r!==l&&d&&(i[":@"]=this.buildAttributesMap(l,n,r)),e&&(e=this.parseTextData(e,r,n,!0,d,!0,!0)),n=n.substr(0,n.lastIndexOf(".")),i.add(this.options.textNodeName,e),this.addChild(s,i,n)}else{if(l.length>0&&l.lastIndexOf("/")===l.length-1){"/"===r[r.length-1]?(r=r.substr(0,r.length-1),l=r):l=l.substr(0,l.length-1),this.options.transformTagName&&(r=this.options.transformTagName(r));const t=new xmlNode(r);r!==l&&d&&(t[":@"]=this.buildAttributesMap(l,n,r)),this.addChild(s,t,n),n=n.substr(0,n.lastIndexOf("."))}else{const t=new xmlNode(r);this.tagsNodeStack.push(s),r!==l&&d&&(t[":@"]=this.buildAttributesMap(l,n,r)),this.addChild(s,t,n),s=t}i="",o=p}}else i+=t[o]}return e.child};function addChild(t,e,s){const i=this.options.updateTag(e.tagname,s,e[":@"]);!1===i||("string"==typeof i?(e.tagname=i,t.addChild(e)):t.addChild(e))}const replaceEntitiesValue=function(t){if(this.options.processEntities){for(let e in this.docTypeEntities){const s=this.docTypeEntities[e];t=t.replace(s.regx,s.val)}for(let e in this.lastEntities){const s=this.lastEntities[e];t=t.replace(s.regex,s.val)}if(this.options.htmlEntities)for(let e in this.htmlEntities){const s=this.htmlEntities[e];t=t.replace(s.regex,s.val)}t=t.replace(this.ampEntity.regex,this.ampEntity.val)}return t};function saveTextToParentTag(t,e,s,i){return t&&(void 0===i&&(i=0===Object.keys(e.child).length),void 0!==(t=this.parseTextData(t,e.tagname,s,!1,!!e[":@"]&&0!==Object.keys(e[":@"]).length,i))&&""!==t&&e.add(this.options.textNodeName,t),t=""),t}function isItStopNode(t,e,s){const i="*."+s;for(const s in t){const n=t[s];if(i===n||e===n)return!0}return!1}function tagExpWithClosingIndex(t,e,s=">"){let i,n="";for(let o=e;o<t.length;o++){let e=t[o];if(i)e===i&&(i="");else if('"'===e||"'"===e)i=e;else if(e===s[0]){if(!s[1])return{data:n,index:o};if(t[o+1]===s[1])return{data:n,index:o}}else"\t"===e&&(e=" ");n+=e}}function findClosingIndex(t,e,s,i){const n=t.indexOf(e,s);if(-1===n)throw new Error(i);return n+e.length-1}function readTagExp(t,e,s,i=">"){const n=tagExpWithClosingIndex(t,e+1,i);if(!n)return;let o=n.data;const a=n.index,r=o.search(/\s/);let l=o,d=!0;if(-1!==r&&(l=o.substr(0,r).replace(/\s\s*$/,""),o=o.substr(r+1)),s){const t=l.indexOf(":");-1!==t&&(l=l.substr(t+1),d=l!==n.data.substr(t+1))}return{tagName:l,tagExp:o,closeIndex:a,attrExpPresent:d}}function readStopNodeData(t,e,s){const i=s;let n=1;for(;s<t.length;s++)if("<"===t[s])if("/"===t[s+1]){const o=findClosingIndex(t,">",s,`${e} is not closed`);if(t.substring(s+2,o).trim()===e&&(n--,0===n))return{tagContent:t.substring(i,s),i:o};s=o}else if("?"===t[s+1]){s=findClosingIndex(t,"?>",s+1,"StopNode is not closed.")}else if("!--"===t.substr(s+1,3)){s=findClosingIndex(t,"--\x3e",s+3,"StopNode is not closed.")}else if("!["===t.substr(s+1,2)){s=findClosingIndex(t,"]]>",s,"StopNode is not closed.")-2}else{const i=readTagExp(t,s,">");if(i){(i&&i.tagName)===e&&"/"!==i.tagExp[i.tagExp.length-1]&&n++,s=i.closeIndex}}}function parseValue(t,e,s){if(e&&"string"==typeof t){const e=t.trim();return"true"===e||"false"!==e&&toNumber(t,s)}return util.isExist(t)?t:""}module.exports=OrderedObjParser;
|
|
1197
|
+
|
|
1198
|
+
};
|
|
1199
|
+
};
|
|
1200
|
+
}
|
|
1201
|
+
}
|
|
1202
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/xmlparser/OrderedObjParser.js",}],
|
|
1203
|
+
[85, {"../validator":79,"./OptionsBuilder":83,"./OrderedObjParser":84,"./node2json":86}, function(){
|
|
1204
|
+
with (this.scopeTerminator) {
|
|
1205
|
+
with (this.globalThis) {
|
|
1206
|
+
return function() {
|
|
1207
|
+
'use strict';
|
|
1208
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/xmlparser/XMLParser.js
|
|
1209
|
+
return function (require, module, exports) {
|
|
1210
|
+
const{buildOptions:buildOptions}=require("./OptionsBuilder"),OrderedObjParser=require("./OrderedObjParser"),{prettify:prettify}=require("./node2json"),validator=require("../validator");class XMLParser{constructor(r){this.externalEntities={},this.options=buildOptions(r)}parse(r,t){if("string"==typeof r);else{if(!r.toString)throw new Error("XML data is accepted in String or Bytes[] form.");r=r.toString()}if(t){!0===t&&(t={});const e=validator.validate(r,t);if(!0!==e)throw Error(`${e.err.msg}:${e.err.line}:${e.err.col}`)}const e=new OrderedObjParser(this.options);e.addExternalEntities(this.externalEntities);const i=e.parseXml(r);return this.options.preserveOrder||void 0===i?i:prettify(i,this.options)}addEntity(r,t){if(-1!==t.indexOf("&"))throw new Error("Entity value can't have '&'");if(-1!==r.indexOf("&")||-1!==r.indexOf(";"))throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'");if("&"===t)throw new Error("An entity with value '&' is not permitted");this.externalEntities[r]=t}}module.exports=XMLParser;
|
|
1211
|
+
|
|
1212
|
+
};
|
|
1213
|
+
};
|
|
1214
|
+
}
|
|
1215
|
+
}
|
|
1216
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/xmlparser/XMLParser.js",}],
|
|
1217
|
+
[86, {}, function(){
|
|
838
1218
|
with (this.scopeTerminator) {
|
|
839
1219
|
with (this.globalThis) {
|
|
840
1220
|
return function() {
|
|
841
1221
|
'use strict';
|
|
842
|
-
// source: /home/runner/work/snaps
|
|
1222
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/xmlparser/node2json.js
|
|
1223
|
+
return function (require, module, exports) {
|
|
1224
|
+
"use strict";function prettify(e,t){return compress(e,t)}function compress(e,t,o){let s;const n={};for(let r=0;r<e.length;r++){const i=e[r],a=propName(i);let c="";if(c=void 0===o?a:o+"."+a,a===t.textNodeName)void 0===s?s=i[a]:s+=""+i[a];else{if(void 0===a)continue;if(i[a]){let e=compress(i[a],t,c);const o=isLeafTag(e,t);i[":@"]?assignAttributes(e,i[":@"],c,t):1!==Object.keys(e).length||void 0===e[t.textNodeName]||t.alwaysCreateTextNode?0===Object.keys(e).length&&(t.alwaysCreateTextNode?e[t.textNodeName]="":e=""):e=e[t.textNodeName],void 0!==n[a]&&n.hasOwnProperty(a)?(Array.isArray(n[a])||(n[a]=[n[a]]),n[a].push(e)):t.isArray(a,c,o)?n[a]=[e]:n[a]=e}}}return"string"==typeof s?s.length>0&&(n[t.textNodeName]=s):void 0!==s&&(n[t.textNodeName]=s),n}function propName(e){const t=Object.keys(e);for(let e=0;e<t.length;e++){const o=t[e];if(":@"!==o)return o}}function assignAttributes(e,t,o,s){if(t){const n=Object.keys(t),r=n.length;for(let i=0;i<r;i++){const r=n[i];s.isArray(r,o+"."+r,!0,!0)?e[r]=[t[r]]:e[r]=t[r]}}}function isLeafTag(e,t){const{textNodeName:o}=t,s=Object.keys(e).length;return 0===s||!(1!==s||!e[o]&&"boolean"!=typeof e[o]&&0!==e[o])}exports.prettify=prettify;
|
|
1225
|
+
|
|
1226
|
+
};
|
|
1227
|
+
};
|
|
1228
|
+
}
|
|
1229
|
+
}
|
|
1230
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/xmlparser/node2json.js",}],
|
|
1231
|
+
[87, {}, function(){
|
|
1232
|
+
with (this.scopeTerminator) {
|
|
1233
|
+
with (this.globalThis) {
|
|
1234
|
+
return function() {
|
|
1235
|
+
'use strict';
|
|
1236
|
+
// source: /home/runner/work/snaps/snaps/node_modules/fast-xml-parser/src/xmlparser/xmlNode.js
|
|
1237
|
+
return function (require, module, exports) {
|
|
1238
|
+
"use strict";class XmlNode{constructor(t){this.tagname=t,this.child=[],this[":@"]={}}add(t,h){"__proto__"===t&&(t="#__proto__"),this.child.push({[t]:h})}addChild(t){"__proto__"===t.tagname&&(t.tagname="#__proto__"),t[":@"]&&Object.keys(t[":@"]).length>0?this.child.push({[t.tagname]:t.child,":@":t[":@"]}):this.child.push({[t.tagname]:t.child})}}module.exports=XmlNode;
|
|
1239
|
+
|
|
1240
|
+
};
|
|
1241
|
+
};
|
|
1242
|
+
}
|
|
1243
|
+
}
|
|
1244
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser",file:"../../node_modules/fast-xml-parser/src/xmlparser/xmlNode.js",}],
|
|
1245
|
+
[88, {}, function(){
|
|
1246
|
+
with (this.scopeTerminator) {
|
|
1247
|
+
with (this.globalThis) {
|
|
1248
|
+
return function() {
|
|
1249
|
+
'use strict';
|
|
1250
|
+
// source: /home/runner/work/snaps/snaps/node_modules/ieee754/index.js
|
|
843
1251
|
return function (require, module, exports) {
|
|
844
1252
|
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
845
1253
|
exports.read=function(a,o,t,r,h){var M,p,w=8*h-r-1,f=(1<<w)-1,e=f>>1,i=-7,N=t?h-1:0,n=t?-1:1,s=a[o+N];for(N+=n,M=s&(1<<-i)-1,s>>=-i,i+=w;i>0;M=256*M+a[o+N],N+=n,i-=8);for(p=M&(1<<-i)-1,M>>=-i,i+=r;i>0;p=256*p+a[o+N],N+=n,i-=8);if(0===M)M=1-e;else{if(M===f)return p?NaN:1/0*(s?-1:1);p+=Math.pow(2,r),M-=e}return(s?-1:1)*p*Math.pow(2,M-r)},exports.write=function(a,o,t,r,h,M){var p,w,f,e=8*M-h-1,i=(1<<e)-1,N=i>>1,n=23===h?Math.pow(2,-24)-Math.pow(2,-77):0,s=r?0:M-1,u=r?1:-1,l=o<0||0===o&&1/o<0?1:0;for(o=Math.abs(o),isNaN(o)||o===1/0?(w=isNaN(o)?1:0,p=i):(p=Math.floor(Math.log(o)/Math.LN2),o*(f=Math.pow(2,-p))<1&&(p--,f*=2),(o+=p+N>=1?n/f:n*Math.pow(2,1-N))*f>=2&&(p++,f/=2),p+N>=i?(w=0,p=i):p+N>=1?(w=(o*f-1)*Math.pow(2,h),p+=N):(w=o*Math.pow(2,N-1)*Math.pow(2,h),p=0));h>=8;a[t+s]=255&w,s+=u,w/=256,h-=8);for(p=p<<h|w,e+=h;e>0;a[t+s]=255&p,s+=u,p/=256,e-=8);a[t+s-u]|=128*l};
|
|
@@ -849,12 +1257,12 @@ exports.read=function(a,o,t,r,h){var M,p,w=8*h-r-1,f=(1<<w)-1,e=f>>1,i=-7,N=t?h-
|
|
|
849
1257
|
}
|
|
850
1258
|
}
|
|
851
1259
|
}, {package:"buffer>ieee754",file:"../../node_modules/ieee754/index.js",}],
|
|
852
|
-
[
|
|
1260
|
+
[89, {}, function(){
|
|
853
1261
|
with (this.scopeTerminator) {
|
|
854
1262
|
with (this.globalThis) {
|
|
855
1263
|
return function() {
|
|
856
1264
|
'use strict';
|
|
857
|
-
// source: /home/runner/work/snaps
|
|
1265
|
+
// source: /home/runner/work/snaps/snaps/node_modules/inherits/inherits_browser.js
|
|
858
1266
|
return function (require, module, exports) {
|
|
859
1267
|
"function"==typeof Object.create?module.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:module.exports=function(t,e){if(e){t.super_=e;var o=function(){};o.prototype=e.prototype,t.prototype=new o,t.prototype.constructor=t}};
|
|
860
1268
|
|
|
@@ -863,12 +1271,12 @@ exports.read=function(a,o,t,r,h){var M,p,w=8*h-r-1,f=(1<<w)-1,e=f>>1,i=-7,N=t?h-
|
|
|
863
1271
|
}
|
|
864
1272
|
}
|
|
865
1273
|
}, {package:"browserify>inherits",file:"../../node_modules/inherits/inherits_browser.js",}],
|
|
866
|
-
[
|
|
1274
|
+
[90, {}, function(){
|
|
867
1275
|
with (this.scopeTerminator) {
|
|
868
1276
|
with (this.globalThis) {
|
|
869
1277
|
return function() {
|
|
870
1278
|
'use strict';
|
|
871
|
-
// source: /home/runner/work/snaps
|
|
1279
|
+
// source: /home/runner/work/snaps/snaps/node_modules/is-buffer/index.js
|
|
872
1280
|
return function (require, module, exports) {
|
|
873
1281
|
/*!
|
|
874
1282
|
* Determine if an object is a Buffer
|
|
@@ -883,12 +1291,26 @@ function isBuffer(f){return!!f.constructor&&"function"==typeof f.constructor.isB
|
|
|
883
1291
|
}
|
|
884
1292
|
}
|
|
885
1293
|
}, {package:"browserify>insert-module-globals>is-buffer",file:"../../node_modules/is-buffer/index.js",}],
|
|
886
|
-
[
|
|
1294
|
+
[91, {"fast-xml-parser":77}, function(){
|
|
1295
|
+
with (this.scopeTerminator) {
|
|
1296
|
+
with (this.globalThis) {
|
|
1297
|
+
return function() {
|
|
1298
|
+
'use strict';
|
|
1299
|
+
// source: /home/runner/work/snaps/snaps/node_modules/is-svg/index.js
|
|
1300
|
+
return function (require, module, exports) {
|
|
1301
|
+
"use strict";const{XMLParser:XMLParser,XMLValidator:XMLValidator}=require("fast-xml-parser"),isSvg=r=>{if(null==r)return!1;if(0===(r=r.toString().trim()).length)return!1;if(!0!==XMLValidator.validate(r))return!1;let t;const e=new XMLParser;try{t=e.parse(r)}catch(r){return!1}return!!t&&"svg"in t};module.exports=isSvg,module.exports.default=isSvg;
|
|
1302
|
+
|
|
1303
|
+
};
|
|
1304
|
+
};
|
|
1305
|
+
}
|
|
1306
|
+
}
|
|
1307
|
+
}, {package:"@metamask/snaps-utils>is-svg",file:"../../node_modules/is-svg/index.js",}],
|
|
1308
|
+
[92, {}, function(){
|
|
887
1309
|
with (this.scopeTerminator) {
|
|
888
1310
|
with (this.globalThis) {
|
|
889
1311
|
return function() {
|
|
890
1312
|
'use strict';
|
|
891
|
-
// source: /home/runner/work/snaps
|
|
1313
|
+
// source: /home/runner/work/snaps/snaps/node_modules/isarray/index.js
|
|
892
1314
|
return function (require, module, exports) {
|
|
893
1315
|
var toString={}.toString;module.exports=Array.isArray||function(r){return"[object Array]"==toString.call(r)};
|
|
894
1316
|
|
|
@@ -897,12 +1319,12 @@ var toString={}.toString;module.exports=Array.isArray||function(r){return"[objec
|
|
|
897
1319
|
}
|
|
898
1320
|
}
|
|
899
1321
|
}, {package:"browserify>readable-stream>isarray",file:"../../node_modules/isarray/index.js",}],
|
|
900
|
-
[
|
|
1322
|
+
[93, {}, function(){
|
|
901
1323
|
with (this.scopeTerminator) {
|
|
902
1324
|
with (this.globalThis) {
|
|
903
1325
|
return function() {
|
|
904
1326
|
'use strict';
|
|
905
|
-
// source: /home/runner/work/snaps
|
|
1327
|
+
// source: /home/runner/work/snaps/snaps/node_modules/luxon/build/cjs-browser/luxon.js
|
|
906
1328
|
return function (require, module, exports) {
|
|
907
1329
|
"use strict";function _defineProperties(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,_toPropertyKey(r.key),r)}}function _createClass(e,t,n){return t&&_defineProperties(e.prototype,t),n&&_defineProperties(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function _extends(){return _extends=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_extends.apply(this,arguments)}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,_setPrototypeOf(e,t)}function _getPrototypeOf(e){return _getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},_getPrototypeOf(e)}function _setPrototypeOf(e,t){return _setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},_setPrototypeOf(e,t)}function _isNativeReflectConstruct(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function _construct(e,t,n){return _construct=_isNativeReflectConstruct()?Reflect.construct.bind():function(e,t,n){var r=[null];r.push.apply(r,t);var i=new(Function.bind.apply(e,r));return n&&_setPrototypeOf(i,n.prototype),i},_construct.apply(null,arguments)}function _isNativeFunction(e){return-1!==Function.toString.call(e).indexOf("[native code]")}function _wrapNativeSuper(e){var t="function"==typeof Map?new Map:void 0;return _wrapNativeSuper=function(e){if(null===e||!_isNativeFunction(e))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return _construct(e,arguments,_getPrototypeOf(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),_setPrototypeOf(n,e)},_wrapNativeSuper(e)}function _objectWithoutPropertiesLoose(e,t){if(null==e)return{};var n,r,i={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}function _unsupportedIterableToArray(e,t){if(e){if("string"==typeof e)return _arrayLikeToArray(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(e,t):void 0}}function _arrayLikeToArray(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function _createForOfIteratorHelperLoose(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=_unsupportedIterableToArray(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _toPrimitive(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function _toPropertyKey(e){var t=_toPrimitive(e,"string");return"symbol"==typeof t?t:String(t)}Object.defineProperty(exports,"__esModule",{value:!0});var LuxonError=function(e){function t(){return e.apply(this,arguments)||this}return _inheritsLoose(t,e),t}(_wrapNativeSuper(Error)),InvalidDateTimeError=function(e){function t(t){return e.call(this,"Invalid DateTime: "+t.toMessage())||this}return _inheritsLoose(t,e),t}(LuxonError),InvalidIntervalError=function(e){function t(t){return e.call(this,"Invalid Interval: "+t.toMessage())||this}return _inheritsLoose(t,e),t}(LuxonError),InvalidDurationError=function(e){function t(t){return e.call(this,"Invalid Duration: "+t.toMessage())||this}return _inheritsLoose(t,e),t}(LuxonError),ConflictingSpecificationError=function(e){function t(){return e.apply(this,arguments)||this}return _inheritsLoose(t,e),t}(LuxonError),InvalidUnitError=function(e){function t(t){return e.call(this,"Invalid unit "+t)||this}return _inheritsLoose(t,e),t}(LuxonError),InvalidArgumentError=function(e){function t(){return e.apply(this,arguments)||this}return _inheritsLoose(t,e),t}(LuxonError),ZoneIsAbstractError=function(e){function t(){return e.call(this,"Zone is an abstract class")||this}return _inheritsLoose(t,e),t}(LuxonError),n="numeric",s="short",l="long",DATE_SHORT={year:n,month:n,day:n},DATE_MED={year:n,month:s,day:n},DATE_MED_WITH_WEEKDAY={year:n,month:s,day:n,weekday:s},DATE_FULL={year:n,month:l,day:n},DATE_HUGE={year:n,month:l,day:n,weekday:l},TIME_SIMPLE={hour:n,minute:n},TIME_WITH_SECONDS={hour:n,minute:n,second:n},TIME_WITH_SHORT_OFFSET={hour:n,minute:n,second:n,timeZoneName:s},TIME_WITH_LONG_OFFSET={hour:n,minute:n,second:n,timeZoneName:l},TIME_24_SIMPLE={hour:n,minute:n,hourCycle:"h23"},TIME_24_WITH_SECONDS={hour:n,minute:n,second:n,hourCycle:"h23"},TIME_24_WITH_SHORT_OFFSET={hour:n,minute:n,second:n,hourCycle:"h23",timeZoneName:s},TIME_24_WITH_LONG_OFFSET={hour:n,minute:n,second:n,hourCycle:"h23",timeZoneName:l},DATETIME_SHORT={year:n,month:n,day:n,hour:n,minute:n},DATETIME_SHORT_WITH_SECONDS={year:n,month:n,day:n,hour:n,minute:n,second:n},DATETIME_MED={year:n,month:s,day:n,hour:n,minute:n},DATETIME_MED_WITH_SECONDS={year:n,month:s,day:n,hour:n,minute:n,second:n},DATETIME_MED_WITH_WEEKDAY={year:n,month:s,day:n,weekday:s,hour:n,minute:n},DATETIME_FULL={year:n,month:l,day:n,hour:n,minute:n,timeZoneName:s},DATETIME_FULL_WITH_SECONDS={year:n,month:l,day:n,hour:n,minute:n,second:n,timeZoneName:s},DATETIME_HUGE={year:n,month:l,day:n,weekday:l,hour:n,minute:n,timeZoneName:l},DATETIME_HUGE_WITH_SECONDS={year:n,month:l,day:n,weekday:l,hour:n,minute:n,second:n,timeZoneName:l},Zone=function(){function e(){}var t=e.prototype;return t.offsetName=function(e,t){throw new ZoneIsAbstractError},t.formatOffset=function(e,t){throw new ZoneIsAbstractError},t.offset=function(e){throw new ZoneIsAbstractError},t.equals=function(e){throw new ZoneIsAbstractError},_createClass(e,[{key:"type",get:function(){throw new ZoneIsAbstractError}},{key:"name",get:function(){throw new ZoneIsAbstractError}},{key:"ianaName",get:function(){return this.name}},{key:"isUniversal",get:function(){throw new ZoneIsAbstractError}},{key:"isValid",get:function(){throw new ZoneIsAbstractError}}]),e}(),singleton$1=null,SystemZone=function(e){function t(){return e.apply(this,arguments)||this}_inheritsLoose(t,e);var n=t.prototype;return n.offsetName=function(e,t){return parseZoneInfo(e,t.format,t.locale)},n.formatOffset=function(e,t){return formatOffset(this.offset(e),t)},n.offset=function(e){return-new Date(e).getTimezoneOffset()},n.equals=function(e){return"system"===e.type},_createClass(t,[{key:"type",get:function(){return"system"}},{key:"name",get:function(){return(new Intl.DateTimeFormat).resolvedOptions().timeZone}},{key:"isUniversal",get:function(){return!1}},{key:"isValid",get:function(){return!0}}],[{key:"instance",get:function(){return null===singleton$1&&(singleton$1=new t),singleton$1}}]),t}(Zone),dtfCache={};function makeDTF(e){return dtfCache[e]||(dtfCache[e]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),dtfCache[e]}var typeToPos={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function hackyOffset(e,t){var n=e.format(t).replace(/\u200E/g,""),r=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(n),i=r[1],a=r[2];return[r[3],i,a,r[4],r[5],r[6],r[7]]}function partsOffset(e,t){for(var n=e.formatToParts(t),r=[],i=0;i<n.length;i++){var a=n[i],o=a.type,s=a.value,u=typeToPos[o];"era"===o?r[u]=s:isUndefined(u)||(r[u]=parseInt(s,10))}return r}var ianaZoneCache={},IANAZone=function(e){function t(n){var r;return(r=e.call(this)||this).zoneName=n,r.valid=t.isValidZone(n),r}_inheritsLoose(t,e),t.create=function(e){return ianaZoneCache[e]||(ianaZoneCache[e]=new t(e)),ianaZoneCache[e]},t.resetCache=function(){ianaZoneCache={},dtfCache={}},t.isValidSpecifier=function(e){return this.isValidZone(e)},t.isValidZone=function(e){if(!e)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:e}).format(),!0}catch(e){return!1}};var n=t.prototype;return n.offsetName=function(e,t){return parseZoneInfo(e,t.format,t.locale,this.name)},n.formatOffset=function(e,t){return formatOffset(this.offset(e),t)},n.offset=function(e){var t=new Date(e);if(isNaN(t))return NaN;var n=makeDTF(this.name),r=n.formatToParts?partsOffset(n,t):hackyOffset(n,t),i=r[0],a=r[1],o=r[2],s=r[3],u=r[4],c=r[5],l=r[6];"BC"===s&&(i=1-Math.abs(i));var d=+t,f=d%1e3;return(objToLocalTS({year:i,month:a,day:o,hour:24===u?0:u,minute:c,second:l,millisecond:0})-(d-=f>=0?f:1e3+f))/6e4},n.equals=function(e){return"iana"===e.type&&e.name===this.name},_createClass(t,[{key:"type",get:function(){return"iana"}},{key:"name",get:function(){return this.zoneName}},{key:"isUniversal",get:function(){return!1}},{key:"isValid",get:function(){return this.valid}}]),t}(Zone),_excluded=["base"],_excluded2=["padTo","floor"],intlLFCache={};function getCachedLF(e,t){void 0===t&&(t={});var n=JSON.stringify([e,t]),r=intlLFCache[n];return r||(r=new Intl.ListFormat(e,t),intlLFCache[n]=r),r}var intlDTCache={};function getCachedDTF(e,t){void 0===t&&(t={});var n=JSON.stringify([e,t]),r=intlDTCache[n];return r||(r=new Intl.DateTimeFormat(e,t),intlDTCache[n]=r),r}var intlNumCache={};function getCachedINF(e,t){void 0===t&&(t={});var n=JSON.stringify([e,t]),r=intlNumCache[n];return r||(r=new Intl.NumberFormat(e,t),intlNumCache[n]=r),r}var intlRelCache={};function getCachedRTF(e,t){void 0===t&&(t={});var n=t;n.base;var r=_objectWithoutPropertiesLoose(n,_excluded),i=JSON.stringify([e,r]),a=intlRelCache[i];return a||(a=new Intl.RelativeTimeFormat(e,t),intlRelCache[i]=a),a}var sysLocaleCache=null;function systemLocale(){return sysLocaleCache||(sysLocaleCache=(new Intl.DateTimeFormat).resolvedOptions().locale)}function parseLocaleString(e){var t=e.indexOf("-x-");-1!==t&&(e=e.substring(0,t));var n,r,i=e.indexOf("-u-");if(-1===i)return[e];try{n=getCachedDTF(e).resolvedOptions(),r=e}catch(t){var a=e.substring(0,i);n=getCachedDTF(a).resolvedOptions(),r=a}var o=n;return[r,o.numberingSystem,o.calendar]}function intlConfigString(e,t,n){return n||t?(e.includes("-u-")||(e+="-u"),n&&(e+="-ca-"+n),t&&(e+="-nu-"+t),e):e}function mapMonths(e){for(var t=[],n=1;n<=12;n++){var r=DateTime.utc(2016,n,1);t.push(e(r))}return t}function mapWeekdays(e){for(var t=[],n=1;n<=7;n++){var r=DateTime.utc(2016,11,13+n);t.push(e(r))}return t}function listStuff(e,t,n,r,i){var a=e.listingMode(n);return"error"===a?null:"en"===a?r(t):i(t)}function supportsFastNumbers(e){return(!e.numberingSystem||"latn"===e.numberingSystem)&&("latn"===e.numberingSystem||!e.locale||e.locale.startsWith("en")||"latn"===new Intl.DateTimeFormat(e.intl).resolvedOptions().numberingSystem)}var PolyNumberFormatter=function(){function e(e,t,n){this.padTo=n.padTo||0,this.floor=n.floor||!1,n.padTo,n.floor;var r=_objectWithoutPropertiesLoose(n,_excluded2);if(!t||Object.keys(r).length>0){var i=_extends({useGrouping:!1},n);n.padTo>0&&(i.minimumIntegerDigits=n.padTo),this.inf=getCachedINF(e,i)}}return e.prototype.format=function(e){if(this.inf){var t=this.floor?Math.floor(e):e;return this.inf.format(t)}return padStart(this.floor?Math.floor(e):roundTo(e,3),this.padTo)},e}(),PolyDateFormatter=function(){function e(e,t,n){this.opts=n,this.originalZone=void 0;var r=void 0;if(this.opts.timeZone)this.dt=e;else if("fixed"===e.zone.type){var i=e.offset/60*-1,a=i>=0?"Etc/GMT+"+i:"Etc/GMT"+i;0!==e.offset&&IANAZone.create(a).valid?(r=a,this.dt=e):(r="UTC",this.dt=0===e.offset?e:e.setZone("UTC").plus({minutes:e.offset}),this.originalZone=e.zone)}else"system"===e.zone.type?this.dt=e:"iana"===e.zone.type?(this.dt=e,r=e.zone.name):(r="UTC",this.dt=e.setZone("UTC").plus({minutes:e.offset}),this.originalZone=e.zone);var o=_extends({},this.opts);o.timeZone=o.timeZone||r,this.dtf=getCachedDTF(t,o)}var t=e.prototype;return t.format=function(){return this.originalZone?this.formatToParts().map((function(e){return e.value})).join(""):this.dtf.format(this.dt.toJSDate())},t.formatToParts=function(){var e=this,t=this.dtf.formatToParts(this.dt.toJSDate());return this.originalZone?t.map((function(t){return"timeZoneName"===t.type?_extends({},t,{value:e.originalZone.offsetName(e.dt.ts,{locale:e.dt.locale,format:e.opts.timeZoneName})}):t})):t},t.resolvedOptions=function(){return this.dtf.resolvedOptions()},e}(),PolyRelFormatter=function(){function e(e,t,n){this.opts=_extends({style:"long"},n),!t&&hasRelative()&&(this.rtf=getCachedRTF(e,n))}var t=e.prototype;return t.format=function(e,t){return this.rtf?this.rtf.format(e,t):formatRelativeTime(t,e,this.opts.numeric,"long"!==this.opts.style)},t.formatToParts=function(e,t){return this.rtf?this.rtf.formatToParts(e,t):[]},e}(),Locale=function(){function e(e,t,n,r){var i=parseLocaleString(e),a=i[0],o=i[1],s=i[2];this.locale=a,this.numberingSystem=t||o||null,this.outputCalendar=n||s||null,this.intl=intlConfigString(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=r,this.fastNumbersCached=null}e.fromOpts=function(t){return e.create(t.locale,t.numberingSystem,t.outputCalendar,t.defaultToEN)},e.create=function(t,n,r,i){void 0===i&&(i=!1);var a=t||Settings.defaultLocale;return new e(a||(i?"en-US":systemLocale()),n||Settings.defaultNumberingSystem,r||Settings.defaultOutputCalendar,a)},e.resetCache=function(){sysLocaleCache=null,intlDTCache={},intlNumCache={},intlRelCache={}},e.fromObject=function(t){var n=void 0===t?{}:t,r=n.locale,i=n.numberingSystem,a=n.outputCalendar;return e.create(r,i,a)};var t=e.prototype;return t.listingMode=function(){var e=this.isEnglish(),t=!(null!==this.numberingSystem&&"latn"!==this.numberingSystem||null!==this.outputCalendar&&"gregory"!==this.outputCalendar);return e&&t?"en":"intl"},t.clone=function(t){return t&&0!==Object.getOwnPropertyNames(t).length?e.create(t.locale||this.specifiedLocale,t.numberingSystem||this.numberingSystem,t.outputCalendar||this.outputCalendar,t.defaultToEN||!1):this},t.redefaultToEN=function(e){return void 0===e&&(e={}),this.clone(_extends({},e,{defaultToEN:!0}))},t.redefaultToSystem=function(e){return void 0===e&&(e={}),this.clone(_extends({},e,{defaultToEN:!1}))},t.months=function(e,t,n){var r=this;return void 0===t&&(t=!1),void 0===n&&(n=!0),listStuff(this,e,n,months,(function(){var n=t?{month:e,day:"numeric"}:{month:e},i=t?"format":"standalone";return r.monthsCache[i][e]||(r.monthsCache[i][e]=mapMonths((function(e){return r.extract(e,n,"month")}))),r.monthsCache[i][e]}))},t.weekdays=function(e,t,n){var r=this;return void 0===t&&(t=!1),void 0===n&&(n=!0),listStuff(this,e,n,weekdays,(function(){var n=t?{weekday:e,year:"numeric",month:"long",day:"numeric"}:{weekday:e},i=t?"format":"standalone";return r.weekdaysCache[i][e]||(r.weekdaysCache[i][e]=mapWeekdays((function(e){return r.extract(e,n,"weekday")}))),r.weekdaysCache[i][e]}))},t.meridiems=function(e){var t=this;return void 0===e&&(e=!0),listStuff(this,void 0,e,(function(){return meridiems}),(function(){if(!t.meridiemCache){var e={hour:"numeric",hourCycle:"h12"};t.meridiemCache=[DateTime.utc(2016,11,13,9),DateTime.utc(2016,11,13,19)].map((function(n){return t.extract(n,e,"dayperiod")}))}return t.meridiemCache}))},t.eras=function(e,t){var n=this;return void 0===t&&(t=!0),listStuff(this,e,t,eras,(function(){var t={era:e};return n.eraCache[e]||(n.eraCache[e]=[DateTime.utc(-40,1,1),DateTime.utc(2017,1,1)].map((function(e){return n.extract(e,t,"era")}))),n.eraCache[e]}))},t.extract=function(e,t,n){var r=this.dtFormatter(e,t).formatToParts().find((function(e){return e.type.toLowerCase()===n}));return r?r.value:null},t.numberFormatter=function(e){return void 0===e&&(e={}),new PolyNumberFormatter(this.intl,e.forceSimple||this.fastNumbers,e)},t.dtFormatter=function(e,t){return void 0===t&&(t={}),new PolyDateFormatter(e,this.intl,t)},t.relFormatter=function(e){return void 0===e&&(e={}),new PolyRelFormatter(this.intl,this.isEnglish(),e)},t.listFormatter=function(e){return void 0===e&&(e={}),getCachedLF(this.intl,e)},t.isEnglish=function(){return"en"===this.locale||"en-us"===this.locale.toLowerCase()||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")},t.equals=function(e){return this.locale===e.locale&&this.numberingSystem===e.numberingSystem&&this.outputCalendar===e.outputCalendar},_createClass(e,[{key:"fastNumbers",get:function(){return null==this.fastNumbersCached&&(this.fastNumbersCached=supportsFastNumbers(this)),this.fastNumbersCached}}]),e}(),singleton=null,FixedOffsetZone=function(e){function t(t){var n;return(n=e.call(this)||this).fixed=t,n}_inheritsLoose(t,e),t.instance=function(e){return 0===e?t.utcInstance:new t(e)},t.parseSpecifier=function(e){if(e){var n=e.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(n)return new t(signedOffset(n[1],n[2]))}return null};var n=t.prototype;return n.offsetName=function(){return this.name},n.formatOffset=function(e,t){return formatOffset(this.fixed,t)},n.offset=function(){return this.fixed},n.equals=function(e){return"fixed"===e.type&&e.fixed===this.fixed},_createClass(t,[{key:"type",get:function(){return"fixed"}},{key:"name",get:function(){return 0===this.fixed?"UTC":"UTC"+formatOffset(this.fixed,"narrow")}},{key:"ianaName",get:function(){return 0===this.fixed?"Etc/UTC":"Etc/GMT"+formatOffset(-this.fixed,"narrow")}},{key:"isUniversal",get:function(){return!0}},{key:"isValid",get:function(){return!0}}],[{key:"utcInstance",get:function(){return null===singleton&&(singleton=new t(0)),singleton}}]),t}(Zone),InvalidZone=function(e){function t(t){var n;return(n=e.call(this)||this).zoneName=t,n}_inheritsLoose(t,e);var n=t.prototype;return n.offsetName=function(){return null},n.formatOffset=function(){return""},n.offset=function(){return NaN},n.equals=function(){return!1},_createClass(t,[{key:"type",get:function(){return"invalid"}},{key:"name",get:function(){return this.zoneName}},{key:"isUniversal",get:function(){return!1}},{key:"isValid",get:function(){return!1}}]),t}(Zone);function normalizeZone(e,t){if(isUndefined(e)||null===e)return t;if(e instanceof Zone)return e;if(isString(e)){var n=e.toLowerCase();return"default"===n?t:"local"===n||"system"===n?SystemZone.instance:"utc"===n||"gmt"===n?FixedOffsetZone.utcInstance:FixedOffsetZone.parseSpecifier(n)||IANAZone.create(e)}return isNumber(e)?FixedOffsetZone.instance(e):"object"==typeof e&&e.offset&&"number"==typeof e.offset?e:new InvalidZone(e)}var throwOnInvalid,now=function(){return Date.now()},defaultZone="system",defaultLocale=null,defaultNumberingSystem=null,defaultOutputCalendar=null,twoDigitCutoffYear=60,Settings=function(){function e(){}return e.resetCaches=function(){Locale.resetCache(),IANAZone.resetCache()},_createClass(e,null,[{key:"now",get:function(){return now},set:function(e){now=e}},{key:"defaultZone",get:function(){return normalizeZone(defaultZone,SystemZone.instance)},set:function(e){defaultZone=e}},{key:"defaultLocale",get:function(){return defaultLocale},set:function(e){defaultLocale=e}},{key:"defaultNumberingSystem",get:function(){return defaultNumberingSystem},set:function(e){defaultNumberingSystem=e}},{key:"defaultOutputCalendar",get:function(){return defaultOutputCalendar},set:function(e){defaultOutputCalendar=e}},{key:"twoDigitCutoffYear",get:function(){return twoDigitCutoffYear},set:function(e){twoDigitCutoffYear=e%100}},{key:"throwOnInvalid",get:function(){return throwOnInvalid},set:function(e){throwOnInvalid=e}}]),e}();function isUndefined(e){return void 0===e}function isNumber(e){return"number"==typeof e}function isInteger(e){return"number"==typeof e&&e%1==0}function isString(e){return"string"==typeof e}function isDate(e){return"[object Date]"===Object.prototype.toString.call(e)}function hasRelative(){try{return"undefined"!=typeof Intl&&!!Intl.RelativeTimeFormat}catch(e){return!1}}function maybeArray(e){return Array.isArray(e)?e:[e]}function bestBy(e,t,n){if(0!==e.length)return e.reduce((function(e,r){var i=[t(r),r];return e&&n(e[0],i[0])===e[0]?e:i}),null)[1]}function pick(e,t){return t.reduce((function(t,n){return t[n]=e[n],t}),{})}function hasOwnProperty(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function integerBetween(e,t,n){return isInteger(e)&&e>=t&&e<=n}function floorMod(e,t){return e-t*Math.floor(e/t)}function padStart(e,t){return void 0===t&&(t=2),e<0?"-"+(""+-e).padStart(t,"0"):(""+e).padStart(t,"0")}function parseInteger(e){return isUndefined(e)||null===e||""===e?void 0:parseInt(e,10)}function parseFloating(e){return isUndefined(e)||null===e||""===e?void 0:parseFloat(e)}function parseMillis(e){if(!isUndefined(e)&&null!==e&&""!==e){var t=1e3*parseFloat("0."+e);return Math.floor(t)}}function roundTo(e,t,n){void 0===n&&(n=!1);var r=Math.pow(10,t);return(n?Math.trunc:Math.round)(e*r)/r}function isLeapYear(e){return e%4==0&&(e%100!=0||e%400==0)}function daysInYear(e){return isLeapYear(e)?366:365}function daysInMonth(e,t){var n=floorMod(t-1,12)+1;return 2===n?isLeapYear(e+(t-n)/12)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][n-1]}function objToLocalTS(e){var t=Date.UTC(e.year,e.month-1,e.day,e.hour,e.minute,e.second,e.millisecond);return e.year<100&&e.year>=0&&(t=new Date(t)).setUTCFullYear(e.year,e.month-1,e.day),+t}function weeksInWeekYear(e){var t=(e+Math.floor(e/4)-Math.floor(e/100)+Math.floor(e/400))%7,n=e-1,r=(n+Math.floor(n/4)-Math.floor(n/100)+Math.floor(n/400))%7;return 4===t||3===r?53:52}function untruncateYear(e){return e>99?e:e>Settings.twoDigitCutoffYear?1900+e:2e3+e}function parseZoneInfo(e,t,n,r){void 0===r&&(r=null);var i=new Date(e),a={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};r&&(a.timeZone=r);var o=_extends({timeZoneName:t},a),s=new Intl.DateTimeFormat(n,o).formatToParts(i).find((function(e){return"timezonename"===e.type.toLowerCase()}));return s?s.value:null}function signedOffset(e,t){var n=parseInt(e,10);Number.isNaN(n)&&(n=0);var r=parseInt(t,10)||0;return 60*n+(n<0||Object.is(n,-0)?-r:r)}function asNumber(e){var t=Number(e);if("boolean"==typeof e||""===e||Number.isNaN(t))throw new InvalidArgumentError("Invalid unit value "+e);return t}function normalizeObject(e,t){var n={};for(var r in e)if(hasOwnProperty(e,r)){var i=e[r];if(null==i)continue;n[t(r)]=asNumber(i)}return n}function formatOffset(e,t){var n=Math.trunc(Math.abs(e/60)),r=Math.trunc(Math.abs(e%60)),i=e>=0?"+":"-";switch(t){case"short":return""+i+padStart(n,2)+":"+padStart(r,2);case"narrow":return""+i+n+(r>0?":"+r:"");case"techie":return""+i+padStart(n,2)+padStart(r,2);default:throw new RangeError("Value format "+t+" is out of range for property format")}}function timeObject(e){return pick(e,["hour","minute","second","millisecond"])}var monthsLong=["January","February","March","April","May","June","July","August","September","October","November","December"],monthsShort=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],monthsNarrow=["J","F","M","A","M","J","J","A","S","O","N","D"];function months(e){switch(e){case"narrow":return[].concat(monthsNarrow);case"short":return[].concat(monthsShort);case"long":return[].concat(monthsLong);case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}var weekdaysLong=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],weekdaysShort=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],weekdaysNarrow=["M","T","W","T","F","S","S"];function weekdays(e){switch(e){case"narrow":return[].concat(weekdaysNarrow);case"short":return[].concat(weekdaysShort);case"long":return[].concat(weekdaysLong);case"numeric":return["1","2","3","4","5","6","7"];default:return null}}var meridiems=["AM","PM"],erasLong=["Before Christ","Anno Domini"],erasShort=["BC","AD"],erasNarrow=["B","A"];function eras(e){switch(e){case"narrow":return[].concat(erasNarrow);case"short":return[].concat(erasShort);case"long":return[].concat(erasLong);default:return null}}function meridiemForDateTime(e){return meridiems[e.hour<12?0:1]}function weekdayForDateTime(e,t){return weekdays(t)[e.weekday-1]}function monthForDateTime(e,t){return months(t)[e.month-1]}function eraForDateTime(e,t){return eras(t)[e.year<0?0:1]}function formatRelativeTime(e,t,n,r){void 0===n&&(n="always"),void 0===r&&(r=!1);var i={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},a=-1===["hours","minutes","seconds"].indexOf(e);if("auto"===n&&a){var o="days"===e;switch(t){case 1:return o?"tomorrow":"next "+i[e][0];case-1:return o?"yesterday":"last "+i[e][0];case 0:return o?"today":"this "+i[e][0]}}var s=Object.is(t,-0)||t<0,u=Math.abs(t),c=1===u,l=i[e],d=r?c?l[1]:l[2]||l[1]:c?i[e][0]:e;return s?u+" "+d+" ago":"in "+u+" "+d}function stringifyTokens(e,t){for(var n,r="",i=_createForOfIteratorHelperLoose(e);!(n=i()).done;){var a=n.value;a.literal?r+=a.val:r+=t(a.val)}return r}var _macroTokenToFormatOpts={D:DATE_SHORT,DD:DATE_MED,DDD:DATE_FULL,DDDD:DATE_HUGE,t:TIME_SIMPLE,tt:TIME_WITH_SECONDS,ttt:TIME_WITH_SHORT_OFFSET,tttt:TIME_WITH_LONG_OFFSET,T:TIME_24_SIMPLE,TT:TIME_24_WITH_SECONDS,TTT:TIME_24_WITH_SHORT_OFFSET,TTTT:TIME_24_WITH_LONG_OFFSET,f:DATETIME_SHORT,ff:DATETIME_MED,fff:DATETIME_FULL,ffff:DATETIME_HUGE,F:DATETIME_SHORT_WITH_SECONDS,FF:DATETIME_MED_WITH_SECONDS,FFF:DATETIME_FULL_WITH_SECONDS,FFFF:DATETIME_HUGE_WITH_SECONDS},Formatter=function(){function e(e,t){this.opts=t,this.loc=e,this.systemLoc=null}e.create=function(t,n){return void 0===n&&(n={}),new e(t,n)},e.parseFormat=function(e){for(var t=null,n="",r=!1,i=[],a=0;a<e.length;a++){var o=e.charAt(a);"'"===o?(n.length>0&&i.push({literal:r||/^\s+$/.test(n),val:n}),t=null,n="",r=!r):r||o===t?n+=o:(n.length>0&&i.push({literal:/^\s+$/.test(n),val:n}),n=o,t=o)}return n.length>0&&i.push({literal:r||/^\s+$/.test(n),val:n}),i},e.macroTokenToFormatOpts=function(e){return _macroTokenToFormatOpts[e]};var t=e.prototype;return t.formatWithSystemDefault=function(e,t){return null===this.systemLoc&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(e,_extends({},this.opts,t)).format()},t.formatDateTime=function(e,t){return void 0===t&&(t={}),this.loc.dtFormatter(e,_extends({},this.opts,t)).format()},t.formatDateTimeParts=function(e,t){return void 0===t&&(t={}),this.loc.dtFormatter(e,_extends({},this.opts,t)).formatToParts()},t.formatInterval=function(e,t){return void 0===t&&(t={}),this.loc.dtFormatter(e.start,_extends({},this.opts,t)).dtf.formatRange(e.start.toJSDate(),e.end.toJSDate())},t.resolvedOptions=function(e,t){return void 0===t&&(t={}),this.loc.dtFormatter(e,_extends({},this.opts,t)).resolvedOptions()},t.num=function(e,t){if(void 0===t&&(t=0),this.opts.forceSimple)return padStart(e,t);var n=_extends({},this.opts);return t>0&&(n.padTo=t),this.loc.numberFormatter(n).format(e)},t.formatDateTimeFromString=function(t,n){var r=this,i="en"===this.loc.listingMode(),a=this.loc.outputCalendar&&"gregory"!==this.loc.outputCalendar,o=function(e,n){return r.loc.extract(t,e,n)},s=function(e){return t.isOffsetFixed&&0===t.offset&&e.allowZ?"Z":t.isValid?t.zone.formatOffset(t.ts,e.format):""},u=function(e,n){return i?monthForDateTime(t,e):o(n?{month:e}:{month:e,day:"numeric"},"month")},c=function(e,n){return i?weekdayForDateTime(t,e):o(n?{weekday:e}:{weekday:e,month:"long",day:"numeric"},"weekday")},l=function(e){return i?eraForDateTime(t,e):o({era:e},"era")};return stringifyTokens(e.parseFormat(n),(function(n){switch(n){case"S":return r.num(t.millisecond);case"u":case"SSS":return r.num(t.millisecond,3);case"s":return r.num(t.second);case"ss":return r.num(t.second,2);case"uu":return r.num(Math.floor(t.millisecond/10),2);case"uuu":return r.num(Math.floor(t.millisecond/100));case"m":return r.num(t.minute);case"mm":return r.num(t.minute,2);case"h":return r.num(t.hour%12==0?12:t.hour%12);case"hh":return r.num(t.hour%12==0?12:t.hour%12,2);case"H":return r.num(t.hour);case"HH":return r.num(t.hour,2);case"Z":return s({format:"narrow",allowZ:r.opts.allowZ});case"ZZ":return s({format:"short",allowZ:r.opts.allowZ});case"ZZZ":return s({format:"techie",allowZ:r.opts.allowZ});case"ZZZZ":return t.zone.offsetName(t.ts,{format:"short",locale:r.loc.locale});case"ZZZZZ":return t.zone.offsetName(t.ts,{format:"long",locale:r.loc.locale});case"z":return t.zoneName;case"a":return i?meridiemForDateTime(t):o({hour:"numeric",hourCycle:"h12"},"dayperiod");case"d":return a?o({day:"numeric"},"day"):r.num(t.day);case"dd":return a?o({day:"2-digit"},"day"):r.num(t.day,2);case"c":case"E":return r.num(t.weekday);case"ccc":return c("short",!0);case"cccc":return c("long",!0);case"ccccc":return c("narrow",!0);case"EEE":return c("short",!1);case"EEEE":return c("long",!1);case"EEEEE":return c("narrow",!1);case"L":return a?o({month:"numeric",day:"numeric"},"month"):r.num(t.month);case"LL":return a?o({month:"2-digit",day:"numeric"},"month"):r.num(t.month,2);case"LLL":return u("short",!0);case"LLLL":return u("long",!0);case"LLLLL":return u("narrow",!0);case"M":return a?o({month:"numeric"},"month"):r.num(t.month);case"MM":return a?o({month:"2-digit"},"month"):r.num(t.month,2);case"MMM":return u("short",!1);case"MMMM":return u("long",!1);case"MMMMM":return u("narrow",!1);case"y":return a?o({year:"numeric"},"year"):r.num(t.year);case"yy":return a?o({year:"2-digit"},"year"):r.num(t.year.toString().slice(-2),2);case"yyyy":return a?o({year:"numeric"},"year"):r.num(t.year,4);case"yyyyyy":return a?o({year:"numeric"},"year"):r.num(t.year,6);case"G":return l("short");case"GG":return l("long");case"GGGGG":return l("narrow");case"kk":return r.num(t.weekYear.toString().slice(-2),2);case"kkkk":return r.num(t.weekYear,4);case"W":return r.num(t.weekNumber);case"WW":return r.num(t.weekNumber,2);case"o":return r.num(t.ordinal);case"ooo":return r.num(t.ordinal,3);case"q":return r.num(t.quarter);case"qq":return r.num(t.quarter,2);case"X":return r.num(Math.floor(t.ts/1e3));case"x":return r.num(t.ts);default:return function(n){var i=e.macroTokenToFormatOpts(n);return i?r.formatWithSystemDefault(t,i):n}(n)}}))},t.formatDurationFromString=function(t,n){var r,i=this,a=function(e){switch(e[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},o=e.parseFormat(n),s=o.reduce((function(e,t){var n=t.literal,r=t.val;return n?e:e.concat(r)}),[]),u=t.shiftTo.apply(t,s.map(a).filter((function(e){return e})));return stringifyTokens(o,(r=u,function(e){var t=a(e);return t?i.num(r.get(t),e.length):e}))},e}(),Invalid=function(){function e(e,t){this.reason=e,this.explanation=t}return e.prototype.toMessage=function(){return this.explanation?this.reason+": "+this.explanation:this.reason},e}(),ianaRegex=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function combineRegexes(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t.reduce((function(e,t){return e+t.source}),"");return RegExp("^"+r+"$")}function combineExtractors(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){return t.reduce((function(t,n){var r=t[0],i=t[1],a=t[2],o=n(e,a),s=o[0],u=o[1],c=o[2];return[_extends({},r,s),u||i,c]}),[{},null,1]).slice(0,2)}}function parse(e){if(null==e)return[null,null];for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];for(var i=0,a=n;i<a.length;i++){var o=a[i],s=o[0],u=o[1],c=s.exec(e);if(c)return u(c)}return[null,null]}function simpleParse(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e,n){var r,i={};for(r=0;r<t.length;r++)i[t[r]]=parseInteger(e[n+r]);return[i,null,n+r]}}var offsetRegex=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,isoExtendedZone="(?:"+offsetRegex.source+"?(?:\\[("+ianaRegex.source+")\\])?)?",isoTimeBaseRegex=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,isoTimeRegex=RegExp(""+isoTimeBaseRegex.source+isoExtendedZone),isoTimeExtensionRegex=RegExp("(?:T"+isoTimeRegex.source+")?"),isoYmdRegex=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,isoWeekRegex=/(\d{4})-?W(\d\d)(?:-?(\d))?/,isoOrdinalRegex=/(\d{4})-?(\d{3})/,extractISOWeekData=simpleParse("weekYear","weekNumber","weekDay"),extractISOOrdinalData=simpleParse("year","ordinal"),sqlYmdRegex=/(\d{4})-(\d\d)-(\d\d)/,sqlTimeRegex=RegExp(isoTimeBaseRegex.source+" ?(?:"+offsetRegex.source+"|("+ianaRegex.source+"))?"),sqlTimeExtensionRegex=RegExp("(?: "+sqlTimeRegex.source+")?");function int(e,t,n){var r=e[t];return isUndefined(r)?n:parseInteger(r)}function extractISOYmd(e,t){return[{year:int(e,t),month:int(e,t+1,1),day:int(e,t+2,1)},null,t+3]}function extractISOTime(e,t){return[{hours:int(e,t,0),minutes:int(e,t+1,0),seconds:int(e,t+2,0),milliseconds:parseMillis(e[t+3])},null,t+4]}function extractISOOffset(e,t){var n=!e[t]&&!e[t+1],r=signedOffset(e[t+1],e[t+2]);return[{},n?null:FixedOffsetZone.instance(r),t+3]}function extractIANAZone(e,t){return[{},e[t]?IANAZone.create(e[t]):null,t+1]}var isoTimeOnly=RegExp("^T?"+isoTimeBaseRegex.source+"$"),isoDuration=/^-?P(?:(?:(-?\d{1,20}(?:\.\d{1,20})?)Y)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20}(?:\.\d{1,20})?)W)?(?:(-?\d{1,20}(?:\.\d{1,20})?)D)?(?:T(?:(-?\d{1,20}(?:\.\d{1,20})?)H)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,20}))?S)?)?)$/;function extractISODuration(e){var t=e[0],n=e[1],r=e[2],i=e[3],a=e[4],o=e[5],s=e[6],u=e[7],c=e[8],l="-"===t[0],d=u&&"-"===u[0],f=function(e,t){return void 0===t&&(t=!1),void 0!==e&&(t||e&&l)?-e:e};return[{years:f(parseFloating(n)),months:f(parseFloating(r)),weeks:f(parseFloating(i)),days:f(parseFloating(a)),hours:f(parseFloating(o)),minutes:f(parseFloating(s)),seconds:f(parseFloating(u),"-0"===u),milliseconds:f(parseMillis(c),d)}]}var obsOffsets={GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function fromStrings(e,t,n,r,i,a,o){var s={year:2===t.length?untruncateYear(parseInteger(t)):parseInteger(t),month:monthsShort.indexOf(n)+1,day:parseInteger(r),hour:parseInteger(i),minute:parseInteger(a)};return o&&(s.second=parseInteger(o)),e&&(s.weekday=e.length>3?weekdaysLong.indexOf(e)+1:weekdaysShort.indexOf(e)+1),s}var rfc2822=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function extractRFC2822(e){var t,n=e[1],r=e[2],i=e[3],a=e[4],o=e[5],s=e[6],u=e[7],c=e[8],l=e[9],d=e[10],f=e[11],m=fromStrings(n,a,i,r,o,s,u);return t=c?obsOffsets[c]:l?0:signedOffset(d,f),[m,new FixedOffsetZone(t)]}function preprocessRFC2822(e){return e.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}var rfc1123=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,rfc850=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,ascii=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function extractRFC1123Or850(e){var t=e[1],n=e[2],r=e[3];return[fromStrings(t,e[4],r,n,e[5],e[6],e[7]),FixedOffsetZone.utcInstance]}function extractASCII(e){var t=e[1],n=e[2],r=e[3],i=e[4],a=e[5],o=e[6];return[fromStrings(t,e[7],n,r,i,a,o),FixedOffsetZone.utcInstance]}var isoYmdWithTimeExtensionRegex=combineRegexes(isoYmdRegex,isoTimeExtensionRegex),isoWeekWithTimeExtensionRegex=combineRegexes(isoWeekRegex,isoTimeExtensionRegex),isoOrdinalWithTimeExtensionRegex=combineRegexes(isoOrdinalRegex,isoTimeExtensionRegex),isoTimeCombinedRegex=combineRegexes(isoTimeRegex),extractISOYmdTimeAndOffset=combineExtractors(extractISOYmd,extractISOTime,extractISOOffset,extractIANAZone),extractISOWeekTimeAndOffset=combineExtractors(extractISOWeekData,extractISOTime,extractISOOffset,extractIANAZone),extractISOOrdinalDateAndTime=combineExtractors(extractISOOrdinalData,extractISOTime,extractISOOffset,extractIANAZone),extractISOTimeAndOffset=combineExtractors(extractISOTime,extractISOOffset,extractIANAZone);function parseISODate(e){return parse(e,[isoYmdWithTimeExtensionRegex,extractISOYmdTimeAndOffset],[isoWeekWithTimeExtensionRegex,extractISOWeekTimeAndOffset],[isoOrdinalWithTimeExtensionRegex,extractISOOrdinalDateAndTime],[isoTimeCombinedRegex,extractISOTimeAndOffset])}function parseRFC2822Date(e){return parse(preprocessRFC2822(e),[rfc2822,extractRFC2822])}function parseHTTPDate(e){return parse(e,[rfc1123,extractRFC1123Or850],[rfc850,extractRFC1123Or850],[ascii,extractASCII])}function parseISODuration(e){return parse(e,[isoDuration,extractISODuration])}var extractISOTimeOnly=combineExtractors(extractISOTime);function parseISOTimeOnly(e){return parse(e,[isoTimeOnly,extractISOTimeOnly])}var sqlYmdWithTimeExtensionRegex=combineRegexes(sqlYmdRegex,sqlTimeExtensionRegex),sqlTimeCombinedRegex=combineRegexes(sqlTimeRegex),extractISOTimeOffsetAndIANAZone=combineExtractors(extractISOTime,extractISOOffset,extractIANAZone);function parseSQL(e){return parse(e,[sqlYmdWithTimeExtensionRegex,extractISOYmdTimeAndOffset],[sqlTimeCombinedRegex,extractISOTimeOffsetAndIANAZone])}var INVALID$2="Invalid Duration",lowOrderMatrix={weeks:{days:7,hours:168,minutes:10080,seconds:604800,milliseconds:6048e5},days:{hours:24,minutes:1440,seconds:86400,milliseconds:864e5},hours:{minutes:60,seconds:3600,milliseconds:36e5},minutes:{seconds:60,milliseconds:6e4},seconds:{milliseconds:1e3}},casualMatrix=_extends({years:{quarters:4,months:12,weeks:52,days:365,hours:8760,minutes:525600,seconds:31536e3,milliseconds:31536e6},quarters:{months:3,weeks:13,days:91,hours:2184,minutes:131040,seconds:7862400,milliseconds:78624e5},months:{weeks:4,days:30,hours:720,minutes:43200,seconds:2592e3,milliseconds:2592e6}},lowOrderMatrix),daysInYearAccurate=365.2425,daysInMonthAccurate=30.436875,accurateMatrix=_extends({years:{quarters:4,months:12,weeks:daysInYearAccurate/7,days:daysInYearAccurate,hours:24*daysInYearAccurate,minutes:24*daysInYearAccurate*60,seconds:24*daysInYearAccurate*60*60,milliseconds:24*daysInYearAccurate*60*60*1e3},quarters:{months:3,weeks:daysInYearAccurate/28,days:daysInYearAccurate/4,hours:24*daysInYearAccurate/4,minutes:24*daysInYearAccurate*60/4,seconds:24*daysInYearAccurate*60*60/4,milliseconds:24*daysInYearAccurate*60*60*1e3/4},months:{weeks:daysInMonthAccurate/7,days:daysInMonthAccurate,hours:24*daysInMonthAccurate,minutes:24*daysInMonthAccurate*60,seconds:24*daysInMonthAccurate*60*60,milliseconds:24*daysInMonthAccurate*60*60*1e3}},lowOrderMatrix),orderedUnits$1=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],reverseUnits=orderedUnits$1.slice(0).reverse();function clone$1(e,t,n){void 0===n&&(n=!1);var r={values:n?t.values:_extends({},e.values,t.values||{}),loc:e.loc.clone(t.loc),conversionAccuracy:t.conversionAccuracy||e.conversionAccuracy,matrix:t.matrix||e.matrix};return new Duration(r)}function antiTrunc(e){return e<0?Math.floor(e):Math.ceil(e)}function convert(e,t,n,r,i){var a=e[i][n],o=t[n]/a,s=!(Math.sign(o)===Math.sign(r[i]))&&0!==r[i]&&Math.abs(o)<=1?antiTrunc(o):Math.trunc(o);r[i]+=s,t[n]-=s*a}function normalizeValues(e,t){reverseUnits.reduce((function(n,r){return isUndefined(t[r])?n:(n&&convert(e,t,n,t,r),r)}),null)}function removeZeroes(e){for(var t={},n=0,r=Object.entries(e);n<r.length;n++){var i=r[n],a=i[0],o=i[1];0!==o&&(t[a]=o)}return t}var Duration=function(){function e(e){var t="longterm"===e.conversionAccuracy||!1,n=t?accurateMatrix:casualMatrix;e.matrix&&(n=e.matrix),this.values=e.values,this.loc=e.loc||Locale.create(),this.conversionAccuracy=t?"longterm":"casual",this.invalid=e.invalid||null,this.matrix=n,this.isLuxonDuration=!0}e.fromMillis=function(t,n){return e.fromObject({milliseconds:t},n)},e.fromObject=function(t,n){if(void 0===n&&(n={}),null==t||"object"!=typeof t)throw new InvalidArgumentError("Duration.fromObject: argument expected to be an object, got "+(null===t?"null":typeof t));return new e({values:normalizeObject(t,e.normalizeUnit),loc:Locale.fromObject(n),conversionAccuracy:n.conversionAccuracy,matrix:n.matrix})},e.fromDurationLike=function(t){if(isNumber(t))return e.fromMillis(t);if(e.isDuration(t))return t;if("object"==typeof t)return e.fromObject(t);throw new InvalidArgumentError("Unknown duration argument "+t+" of type "+typeof t)},e.fromISO=function(t,n){var r=parseISODuration(t)[0];return r?e.fromObject(r,n):e.invalid("unparsable",'the input "'+t+"\" can't be parsed as ISO 8601")},e.fromISOTime=function(t,n){var r=parseISOTimeOnly(t)[0];return r?e.fromObject(r,n):e.invalid("unparsable",'the input "'+t+"\" can't be parsed as ISO 8601")},e.invalid=function(t,n){if(void 0===n&&(n=null),!t)throw new InvalidArgumentError("need to specify a reason the Duration is invalid");var r=t instanceof Invalid?t:new Invalid(t,n);if(Settings.throwOnInvalid)throw new InvalidDurationError(r);return new e({invalid:r})},e.normalizeUnit=function(e){var t={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[e?e.toLowerCase():e];if(!t)throw new InvalidUnitError(e);return t},e.isDuration=function(e){return e&&e.isLuxonDuration||!1};var t=e.prototype;return t.toFormat=function(e,t){void 0===t&&(t={});var n=_extends({},t,{floor:!1!==t.round&&!1!==t.floor});return this.isValid?Formatter.create(this.loc,n).formatDurationFromString(this,e):INVALID$2},t.toHuman=function(e){var t=this;void 0===e&&(e={});var n=orderedUnits$1.map((function(n){var r=t.values[n];return isUndefined(r)?null:t.loc.numberFormatter(_extends({style:"unit",unitDisplay:"long"},e,{unit:n.slice(0,-1)})).format(r)})).filter((function(e){return e}));return this.loc.listFormatter(_extends({type:"conjunction",style:e.listStyle||"narrow"},e)).format(n)},t.toObject=function(){return this.isValid?_extends({},this.values):{}},t.toISO=function(){if(!this.isValid)return null;var e="P";return 0!==this.years&&(e+=this.years+"Y"),0===this.months&&0===this.quarters||(e+=this.months+3*this.quarters+"M"),0!==this.weeks&&(e+=this.weeks+"W"),0!==this.days&&(e+=this.days+"D"),0===this.hours&&0===this.minutes&&0===this.seconds&&0===this.milliseconds||(e+="T"),0!==this.hours&&(e+=this.hours+"H"),0!==this.minutes&&(e+=this.minutes+"M"),0===this.seconds&&0===this.milliseconds||(e+=roundTo(this.seconds+this.milliseconds/1e3,3)+"S"),"P"===e&&(e+="T0S"),e},t.toISOTime=function(e){if(void 0===e&&(e={}),!this.isValid)return null;var t=this.toMillis();if(t<0||t>=864e5)return null;e=_extends({suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended"},e);var n=this.shiftTo("hours","minutes","seconds","milliseconds"),r="basic"===e.format?"hhmm":"hh:mm";e.suppressSeconds&&0===n.seconds&&0===n.milliseconds||(r+="basic"===e.format?"ss":":ss",e.suppressMilliseconds&&0===n.milliseconds||(r+=".SSS"));var i=n.toFormat(r);return e.includePrefix&&(i="T"+i),i},t.toJSON=function(){return this.toISO()},t.toString=function(){return this.toISO()},t.toMillis=function(){return this.as("milliseconds")},t.valueOf=function(){return this.toMillis()},t.plus=function(t){if(!this.isValid)return this;for(var n=e.fromDurationLike(t),r={},i=0,a=orderedUnits$1;i<a.length;i++){var o=a[i];(hasOwnProperty(n.values,o)||hasOwnProperty(this.values,o))&&(r[o]=n.get(o)+this.get(o))}return clone$1(this,{values:r},!0)},t.minus=function(t){if(!this.isValid)return this;var n=e.fromDurationLike(t);return this.plus(n.negate())},t.mapUnits=function(e){if(!this.isValid)return this;for(var t={},n=0,r=Object.keys(this.values);n<r.length;n++){var i=r[n];t[i]=asNumber(e(this.values[i],i))}return clone$1(this,{values:t},!0)},t.get=function(t){return this[e.normalizeUnit(t)]},t.set=function(t){return this.isValid?clone$1(this,{values:_extends({},this.values,normalizeObject(t,e.normalizeUnit))}):this},t.reconfigure=function(e){var t=void 0===e?{}:e,n=t.locale,r=t.numberingSystem,i=t.conversionAccuracy,a=t.matrix;return clone$1(this,{loc:this.loc.clone({locale:n,numberingSystem:r}),matrix:a,conversionAccuracy:i})},t.as=function(e){return this.isValid?this.shiftTo(e).get(e):NaN},t.normalize=function(){if(!this.isValid)return this;var e=this.toObject();return normalizeValues(this.matrix,e),clone$1(this,{values:e},!0)},t.rescale=function(){return this.isValid?clone$1(this,{values:removeZeroes(this.normalize().shiftToAll().toObject())},!0):this},t.shiftTo=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!this.isValid)return this;if(0===n.length)return this;n=n.map((function(t){return e.normalizeUnit(t)}));for(var i,a={},o={},s=this.toObject(),u=0,c=orderedUnits$1;u<c.length;u++){var l=c[u];if(n.indexOf(l)>=0){i=l;var d=0;for(var f in o)d+=this.matrix[f][l]*o[f],o[f]=0;isNumber(s[l])&&(d+=s[l]);var m=Math.trunc(d);for(var h in a[l]=m,o[l]=(1e3*d-1e3*m)/1e3,s)orderedUnits$1.indexOf(h)>orderedUnits$1.indexOf(l)&&convert(this.matrix,s,h,a,l)}else isNumber(s[l])&&(o[l]=s[l])}for(var y in o)0!==o[y]&&(a[i]+=y===i?o[y]:o[y]/this.matrix[i][y]);return clone$1(this,{values:a},!0).normalize()},t.shiftToAll=function(){return this.isValid?this.shiftTo("years","months","weeks","days","hours","minutes","seconds","milliseconds"):this},t.negate=function(){if(!this.isValid)return this;for(var e={},t=0,n=Object.keys(this.values);t<n.length;t++){var r=n[t];e[r]=0===this.values[r]?0:-this.values[r]}return clone$1(this,{values:e},!0)},t.equals=function(e){if(!this.isValid||!e.isValid)return!1;if(!this.loc.equals(e.loc))return!1;for(var t=0,n=orderedUnits$1;t<n.length;t++){var r=n[t];if(i=this.values[r],a=e.values[r],!(void 0===i||0===i?void 0===a||0===a:i===a))return!1}var i,a;return!0},_createClass(e,[{key:"locale",get:function(){return this.isValid?this.loc.locale:null}},{key:"numberingSystem",get:function(){return this.isValid?this.loc.numberingSystem:null}},{key:"years",get:function(){return this.isValid?this.values.years||0:NaN}},{key:"quarters",get:function(){return this.isValid?this.values.quarters||0:NaN}},{key:"months",get:function(){return this.isValid?this.values.months||0:NaN}},{key:"weeks",get:function(){return this.isValid?this.values.weeks||0:NaN}},{key:"days",get:function(){return this.isValid?this.values.days||0:NaN}},{key:"hours",get:function(){return this.isValid?this.values.hours||0:NaN}},{key:"minutes",get:function(){return this.isValid?this.values.minutes||0:NaN}},{key:"seconds",get:function(){return this.isValid?this.values.seconds||0:NaN}},{key:"milliseconds",get:function(){return this.isValid?this.values.milliseconds||0:NaN}},{key:"isValid",get:function(){return null===this.invalid}},{key:"invalidReason",get:function(){return this.invalid?this.invalid.reason:null}},{key:"invalidExplanation",get:function(){return this.invalid?this.invalid.explanation:null}}]),e}(),INVALID$1="Invalid Interval";function validateStartEnd(e,t){return e&&e.isValid?t&&t.isValid?t<e?Interval.invalid("end before start","The end of an interval must be after its start, but you had start="+e.toISO()+" and end="+t.toISO()):null:Interval.invalid("missing or invalid end"):Interval.invalid("missing or invalid start")}var Interval=function(){function e(e){this.s=e.start,this.e=e.end,this.invalid=e.invalid||null,this.isLuxonInterval=!0}e.invalid=function(t,n){if(void 0===n&&(n=null),!t)throw new InvalidArgumentError("need to specify a reason the Interval is invalid");var r=t instanceof Invalid?t:new Invalid(t,n);if(Settings.throwOnInvalid)throw new InvalidIntervalError(r);return new e({invalid:r})},e.fromDateTimes=function(t,n){var r=friendlyDateTime(t),i=friendlyDateTime(n),a=validateStartEnd(r,i);return null==a?new e({start:r,end:i}):a},e.after=function(t,n){var r=Duration.fromDurationLike(n),i=friendlyDateTime(t);return e.fromDateTimes(i,i.plus(r))},e.before=function(t,n){var r=Duration.fromDurationLike(n),i=friendlyDateTime(t);return e.fromDateTimes(i.minus(r),i)},e.fromISO=function(t,n){var r=(t||"").split("/",2),i=r[0],a=r[1];if(i&&a){var o,s,u,c;try{s=(o=DateTime.fromISO(i,n)).isValid}catch(a){s=!1}try{c=(u=DateTime.fromISO(a,n)).isValid}catch(a){c=!1}if(s&&c)return e.fromDateTimes(o,u);if(s){var l=Duration.fromISO(a,n);if(l.isValid)return e.after(o,l)}else if(c){var d=Duration.fromISO(i,n);if(d.isValid)return e.before(u,d)}}return e.invalid("unparsable",'the input "'+t+"\" can't be parsed as ISO 8601")},e.isInterval=function(e){return e&&e.isLuxonInterval||!1};var t=e.prototype;return t.length=function(e){return void 0===e&&(e="milliseconds"),this.isValid?this.toDuration.apply(this,[e]).get(e):NaN},t.count=function(e){if(void 0===e&&(e="milliseconds"),!this.isValid)return NaN;var t=this.start.startOf(e),n=this.end.startOf(e);return Math.floor(n.diff(t,e).get(e))+(n.valueOf()!==this.end.valueOf())},t.hasSame=function(e){return!!this.isValid&&(this.isEmpty()||this.e.minus(1).hasSame(this.s,e))},t.isEmpty=function(){return this.s.valueOf()===this.e.valueOf()},t.isAfter=function(e){return!!this.isValid&&this.s>e},t.isBefore=function(e){return!!this.isValid&&this.e<=e},t.contains=function(e){return!!this.isValid&&(this.s<=e&&this.e>e)},t.set=function(t){var n=void 0===t?{}:t,r=n.start,i=n.end;return this.isValid?e.fromDateTimes(r||this.s,i||this.e):this},t.splitAt=function(){var t=this;if(!this.isValid)return[];for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];for(var a=r.map(friendlyDateTime).filter((function(e){return t.contains(e)})).sort(),o=[],s=this.s,u=0;s<this.e;){var c=a[u]||this.e,l=+c>+this.e?this.e:c;o.push(e.fromDateTimes(s,l)),s=l,u+=1}return o},t.splitBy=function(t){var n=Duration.fromDurationLike(t);if(!this.isValid||!n.isValid||0===n.as("milliseconds"))return[];for(var r,i=this.s,a=1,o=[];i<this.e;){var s=this.start.plus(n.mapUnits((function(e){return e*a})));r=+s>+this.e?this.e:s,o.push(e.fromDateTimes(i,r)),i=r,a+=1}return o},t.divideEqually=function(e){return this.isValid?this.splitBy(this.length()/e).slice(0,e):[]},t.overlaps=function(e){return this.e>e.s&&this.s<e.e},t.abutsStart=function(e){return!!this.isValid&&+this.e==+e.s},t.abutsEnd=function(e){return!!this.isValid&&+e.e==+this.s},t.engulfs=function(e){return!!this.isValid&&(this.s<=e.s&&this.e>=e.e)},t.equals=function(e){return!(!this.isValid||!e.isValid)&&(this.s.equals(e.s)&&this.e.equals(e.e))},t.intersection=function(t){if(!this.isValid)return this;var n=this.s>t.s?this.s:t.s,r=this.e<t.e?this.e:t.e;return n>=r?null:e.fromDateTimes(n,r)},t.union=function(t){if(!this.isValid)return this;var n=this.s<t.s?this.s:t.s,r=this.e>t.e?this.e:t.e;return e.fromDateTimes(n,r)},e.merge=function(e){var t=e.sort((function(e,t){return e.s-t.s})).reduce((function(e,t){var n=e[0],r=e[1];return r?r.overlaps(t)||r.abutsStart(t)?[n,r.union(t)]:[n.concat([r]),t]:[n,t]}),[[],null]),n=t[0],r=t[1];return r&&n.push(r),n},e.xor=function(t){for(var n,r,i=null,a=0,o=[],s=t.map((function(e){return[{time:e.s,type:"s"},{time:e.e,type:"e"}]})),u=_createForOfIteratorHelperLoose((n=Array.prototype).concat.apply(n,s).sort((function(e,t){return e.time-t.time})));!(r=u()).done;){var c=r.value;1===(a+="s"===c.type?1:-1)?i=c.time:(i&&+i!=+c.time&&o.push(e.fromDateTimes(i,c.time)),i=null)}return e.merge(o)},t.difference=function(){for(var t=this,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return e.xor([this].concat(r)).map((function(e){return t.intersection(e)})).filter((function(e){return e&&!e.isEmpty()}))},t.toString=function(){return this.isValid?"["+this.s.toISO()+" – "+this.e.toISO()+")":INVALID$1},Reflect.defineProperty(t,"toLocaleString",{value:function(e,t){return void 0===e&&(e=DATE_SHORT),void 0===t&&(t={}),this.isValid?Formatter.create(this.s.loc.clone(t),e).formatInterval(this):INVALID$1}}),t.toISO=function(e){return this.isValid?this.s.toISO(e)+"/"+this.e.toISO(e):INVALID$1},t.toISODate=function(){return this.isValid?this.s.toISODate()+"/"+this.e.toISODate():INVALID$1},t.toISOTime=function(e){return this.isValid?this.s.toISOTime(e)+"/"+this.e.toISOTime(e):INVALID$1},t.toFormat=function(e,t){var n=(void 0===t?{}:t).separator,r=void 0===n?" – ":n;return this.isValid?""+this.s.toFormat(e)+r+this.e.toFormat(e):INVALID$1},t.toDuration=function(e,t){return this.isValid?this.e.diff(this.s,e,t):Duration.invalid(this.invalidReason)},t.mapEndpoints=function(t){return e.fromDateTimes(t(this.s),t(this.e))},_createClass(e,[{key:"start",get:function(){return this.isValid?this.s:null}},{key:"end",get:function(){return this.isValid?this.e:null}},{key:"isValid",get:function(){return null===this.invalidReason}},{key:"invalidReason",get:function(){return this.invalid?this.invalid.reason:null}},{key:"invalidExplanation",get:function(){return this.invalid?this.invalid.explanation:null}}]),e}(),Info=function(){function e(){}return e.hasDST=function(e){void 0===e&&(e=Settings.defaultZone);var t=DateTime.now().setZone(e).set({month:12});return!e.isUniversal&&t.offset!==t.set({month:6}).offset},e.isValidIANAZone=function(e){return IANAZone.isValidZone(e)},e.normalizeZone=function(e){return normalizeZone(e,Settings.defaultZone)},e.months=function(e,t){void 0===e&&(e="long");var n=void 0===t?{}:t,r=n.locale,i=void 0===r?null:r,a=n.numberingSystem,o=void 0===a?null:a,s=n.locObj,u=void 0===s?null:s,c=n.outputCalendar,l=void 0===c?"gregory":c;return(u||Locale.create(i,o,l)).months(e)},e.monthsFormat=function(e,t){void 0===e&&(e="long");var n=void 0===t?{}:t,r=n.locale,i=void 0===r?null:r,a=n.numberingSystem,o=void 0===a?null:a,s=n.locObj,u=void 0===s?null:s,c=n.outputCalendar,l=void 0===c?"gregory":c;return(u||Locale.create(i,o,l)).months(e,!0)},e.weekdays=function(e,t){void 0===e&&(e="long");var n=void 0===t?{}:t,r=n.locale,i=void 0===r?null:r,a=n.numberingSystem,o=void 0===a?null:a,s=n.locObj;return((void 0===s?null:s)||Locale.create(i,o,null)).weekdays(e)},e.weekdaysFormat=function(e,t){void 0===e&&(e="long");var n=void 0===t?{}:t,r=n.locale,i=void 0===r?null:r,a=n.numberingSystem,o=void 0===a?null:a,s=n.locObj;return((void 0===s?null:s)||Locale.create(i,o,null)).weekdays(e,!0)},e.meridiems=function(e){var t=(void 0===e?{}:e).locale,n=void 0===t?null:t;return Locale.create(n).meridiems()},e.eras=function(e,t){void 0===e&&(e="short");var n=(void 0===t?{}:t).locale,r=void 0===n?null:n;return Locale.create(r,null,"gregory").eras(e)},e.features=function(){return{relative:hasRelative()}},e}();function dayDiff(e,t){var n=function(e){return e.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf()},r=n(t)-n(e);return Math.floor(Duration.fromMillis(r).as("days"))}function highOrderDiffs(e,t,n){for(var r,i,a={},o=e,s=0,u=[["years",function(e,t){return t.year-e.year}],["quarters",function(e,t){return t.quarter-e.quarter+4*(t.year-e.year)}],["months",function(e,t){return t.month-e.month+12*(t.year-e.year)}],["weeks",function(e,t){var n=dayDiff(e,t);return(n-n%7)/7}],["days",dayDiff]];s<u.length;s++){var c=u[s],l=c[0],d=c[1];n.indexOf(l)>=0&&(r=l,a[l]=d(e,t),(i=o.plus(a))>t?(a[l]--,e=o.plus(a)):e=i)}return[e,a,i,r]}function _diff(e,t,n,r){var i=highOrderDiffs(e,t,n),a=i[0],o=i[1],s=i[2],u=i[3],c=t-a,l=n.filter((function(e){return["hours","minutes","seconds","milliseconds"].indexOf(e)>=0}));if(0===l.length){var d;if(s<t)s=a.plus(((d={})[u]=1,d));s!==a&&(o[u]=(o[u]||0)+c/(s-a))}var f,m=Duration.fromObject(o,r);return l.length>0?(f=Duration.fromMillis(c,r)).shiftTo.apply(f,l).plus(m):m}var numberingSystems={arab:"[٠-٩]",arabext:"[۰-۹]",bali:"[᭐-᭙]",beng:"[০-৯]",deva:"[०-९]",fullwide:"[0-9]",gujr:"[૦-૯]",hanidec:"[〇|一|二|三|四|五|六|七|八|九]",khmr:"[០-៩]",knda:"[೦-೯]",laoo:"[໐-໙]",limb:"[᥆-᥏]",mlym:"[൦-൯]",mong:"[᠐-᠙]",mymr:"[၀-၉]",orya:"[୦-୯]",tamldec:"[௦-௯]",telu:"[౦-౯]",thai:"[๐-๙]",tibt:"[༠-༩]",latn:"\\d"},numberingSystemsUTF16={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},hanidecChars=numberingSystems.hanidec.replace(/[\[|\]]/g,"").split("");function parseDigits(e){var t=parseInt(e,10);if(isNaN(t)){t="";for(var n=0;n<e.length;n++){var r=e.charCodeAt(n);if(-1!==e[n].search(numberingSystems.hanidec))t+=hanidecChars.indexOf(e[n]);else for(var i in numberingSystemsUTF16){var a=numberingSystemsUTF16[i],o=a[0],s=a[1];r>=o&&r<=s&&(t+=r-o)}}return parseInt(t,10)}return t}function digitRegex(e,t){var n=e.numberingSystem;return void 0===t&&(t=""),new RegExp(""+numberingSystems[n||"latn"]+t)}var MISSING_FTP="missing Intl.DateTimeFormat.formatToParts support";function intUnit(e,t){return void 0===t&&(t=function(e){return e}),{regex:e,deser:function(e){var n=e[0];return t(parseDigits(n))}}}var NBSP=String.fromCharCode(160),spaceOrNBSP="[ "+NBSP+"]",spaceOrNBSPRegExp=new RegExp(spaceOrNBSP,"g");function fixListRegex(e){return e.replace(/\./g,"\\.?").replace(spaceOrNBSPRegExp,spaceOrNBSP)}function stripInsensitivities(e){return e.replace(/\./g,"").replace(spaceOrNBSPRegExp," ").toLowerCase()}function oneOf(e,t){return null===e?null:{regex:RegExp(e.map(fixListRegex).join("|")),deser:function(n){var r=n[0];return e.findIndex((function(e){return stripInsensitivities(r)===stripInsensitivities(e)}))+t}}}function offset(e,t){return{regex:e,deser:function(e){return signedOffset(e[1],e[2])},groups:t}}function simple(e){return{regex:e,deser:function(e){return e[0]}}}function escapeToken(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function unitForToken(e,t){var n=digitRegex(t),r=digitRegex(t,"{2}"),i=digitRegex(t,"{3}"),a=digitRegex(t,"{4}"),o=digitRegex(t,"{6}"),s=digitRegex(t,"{1,2}"),u=digitRegex(t,"{1,3}"),c=digitRegex(t,"{1,6}"),l=digitRegex(t,"{1,9}"),d=digitRegex(t,"{2,4}"),f=digitRegex(t,"{4,6}"),m=function(e){return{regex:RegExp(escapeToken(e.val)),deser:function(e){return e[0]},literal:!0}},h=function(h){if(e.literal)return m(h);switch(h.val){case"G":return oneOf(t.eras("short",!1),0);case"GG":return oneOf(t.eras("long",!1),0);case"y":return intUnit(c);case"yy":case"kk":return intUnit(d,untruncateYear);case"yyyy":case"kkkk":return intUnit(a);case"yyyyy":return intUnit(f);case"yyyyyy":return intUnit(o);case"M":case"L":case"d":case"H":case"h":case"m":case"q":case"s":case"W":return intUnit(s);case"MM":case"LL":case"dd":case"HH":case"hh":case"mm":case"qq":case"ss":case"WW":return intUnit(r);case"MMM":return oneOf(t.months("short",!0,!1),1);case"MMMM":return oneOf(t.months("long",!0,!1),1);case"LLL":return oneOf(t.months("short",!1,!1),1);case"LLLL":return oneOf(t.months("long",!1,!1),1);case"o":case"S":return intUnit(u);case"ooo":case"SSS":return intUnit(i);case"u":return simple(l);case"uu":return simple(s);case"uuu":case"E":case"c":return intUnit(n);case"a":return oneOf(t.meridiems(),0);case"EEE":return oneOf(t.weekdays("short",!1,!1),1);case"EEEE":return oneOf(t.weekdays("long",!1,!1),1);case"ccc":return oneOf(t.weekdays("short",!0,!1),1);case"cccc":return oneOf(t.weekdays("long",!0,!1),1);case"Z":case"ZZ":return offset(new RegExp("([+-]"+s.source+")(?::("+r.source+"))?"),2);case"ZZZ":return offset(new RegExp("([+-]"+s.source+")("+r.source+")?"),2);case"z":return simple(/[a-z_+-/]{1,256}?/i);case" ":return simple(/[^\S\n\r]/);default:return m(h)}}(e)||{invalidReason:MISSING_FTP};return h.token=e,h}var partTypeStyleToTokenVal={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour:{numeric:"h","2-digit":"hh"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"},timeZoneName:{long:"ZZZZZ",short:"ZZZ"}};function tokenForPart(e,t){var n=e.type,r=e.value;if("literal"===n){var i=/^\s+$/.test(r);return{literal:!i,val:i?" ":r}}var a=t[n],o=partTypeStyleToTokenVal[n];if("object"==typeof o&&(o=o[a]),o)return{literal:!1,val:o}}function buildRegex(e){return["^"+e.map((function(e){return e.regex})).reduce((function(e,t){return e+"("+t.source+")"}),"")+"$",e]}function match(e,t,n){var r=e.match(t);if(r){var i={},a=1;for(var o in n)if(hasOwnProperty(n,o)){var s=n[o],u=s.groups?s.groups+1:1;!s.literal&&s.token&&(i[s.token.val[0]]=s.deser(r.slice(a,a+u))),a+=u}return[r,i]}return[r,{}]}function dateTimeFromMatches(e){var t,n=null;return isUndefined(e.z)||(n=IANAZone.create(e.z)),isUndefined(e.Z)||(n||(n=new FixedOffsetZone(e.Z)),t=e.Z),isUndefined(e.q)||(e.M=3*(e.q-1)+1),isUndefined(e.h)||(e.h<12&&1===e.a?e.h+=12:12===e.h&&0===e.a&&(e.h=0)),0===e.G&&e.y&&(e.y=-e.y),isUndefined(e.u)||(e.S=parseMillis(e.u)),[Object.keys(e).reduce((function(t,n){var r=function(e){switch(e){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}}(n);return r&&(t[r]=e[n]),t}),{}),n,t]}var dummyDateTimeCache=null;function getDummyDateTime(){return dummyDateTimeCache||(dummyDateTimeCache=DateTime.fromMillis(1555555555555)),dummyDateTimeCache}function maybeExpandMacroToken(e,t){if(e.literal)return e;var n=formatOptsToTokens(Formatter.macroTokenToFormatOpts(e.val),t);return null==n||n.includes(void 0)?e:n}function expandMacroTokens(e,t){var n;return(n=Array.prototype).concat.apply(n,e.map((function(e){return maybeExpandMacroToken(e,t)})))}function explainFromTokens(e,t,n){var r=expandMacroTokens(Formatter.parseFormat(n),e),i=r.map((function(t){return unitForToken(t,e)})),a=i.find((function(e){return e.invalidReason}));if(a)return{input:t,tokens:r,invalidReason:a.invalidReason};var o=buildRegex(i),s=o[0],u=o[1],c=RegExp(s,"i"),l=match(t,c,u),d=l[0],f=l[1],m=f?dateTimeFromMatches(f):[null,null,void 0],h=m[0],y=m[1],v=m[2];if(hasOwnProperty(f,"a")&&hasOwnProperty(f,"H"))throw new ConflictingSpecificationError("Can't include meridiem when specifying 24-hour format");return{input:t,tokens:r,regex:c,rawMatches:d,matches:f,result:h,zone:y,specificOffset:v}}function parseFromTokens(e,t,n){var r=explainFromTokens(e,t,n);return[r.result,r.zone,r.specificOffset,r.invalidReason]}function formatOptsToTokens(e,t){return e?Formatter.create(t,e).formatDateTimeParts(getDummyDateTime()).map((function(t){return tokenForPart(t,e)})):null}var nonLeapLadder=[0,31,59,90,120,151,181,212,243,273,304,334],leapLadder=[0,31,60,91,121,152,182,213,244,274,305,335];function unitOutOfRange(e,t){return new Invalid("unit out of range","you specified "+t+" (of type "+typeof t+") as a "+e+", which is invalid")}function dayOfWeek(e,t,n){var r=new Date(Date.UTC(e,t-1,n));e<100&&e>=0&&r.setUTCFullYear(r.getUTCFullYear()-1900);var i=r.getUTCDay();return 0===i?7:i}function computeOrdinal(e,t,n){return n+(isLeapYear(e)?leapLadder:nonLeapLadder)[t-1]}function uncomputeOrdinal(e,t){var n=isLeapYear(e)?leapLadder:nonLeapLadder,r=n.findIndex((function(e){return e<t}));return{month:r+1,day:t-n[r]}}function gregorianToWeek(e){var t,n=e.year,r=e.month,i=e.day,a=computeOrdinal(n,r,i),o=dayOfWeek(n,r,i),s=Math.floor((a-o+10)/7);return s<1?s=weeksInWeekYear(t=n-1):s>weeksInWeekYear(n)?(t=n+1,s=1):t=n,_extends({weekYear:t,weekNumber:s,weekday:o},timeObject(e))}function weekToGregorian(e){var t,n=e.weekYear,r=e.weekNumber,i=e.weekday,a=dayOfWeek(n,1,4),o=daysInYear(n),s=7*r+i-a-3;s<1?s+=daysInYear(t=n-1):s>o?(t=n+1,s-=daysInYear(n)):t=n;var u=uncomputeOrdinal(t,s);return _extends({year:t,month:u.month,day:u.day},timeObject(e))}function gregorianToOrdinal(e){var t=e.year;return _extends({year:t,ordinal:computeOrdinal(t,e.month,e.day)},timeObject(e))}function ordinalToGregorian(e){var t=e.year,n=uncomputeOrdinal(t,e.ordinal);return _extends({year:t,month:n.month,day:n.day},timeObject(e))}function hasInvalidWeekData(e){var t=isInteger(e.weekYear),n=integerBetween(e.weekNumber,1,weeksInWeekYear(e.weekYear)),r=integerBetween(e.weekday,1,7);return t?n?!r&&unitOutOfRange("weekday",e.weekday):unitOutOfRange("week",e.week):unitOutOfRange("weekYear",e.weekYear)}function hasInvalidOrdinalData(e){var t=isInteger(e.year),n=integerBetween(e.ordinal,1,daysInYear(e.year));return t?!n&&unitOutOfRange("ordinal",e.ordinal):unitOutOfRange("year",e.year)}function hasInvalidGregorianData(e){var t=isInteger(e.year),n=integerBetween(e.month,1,12),r=integerBetween(e.day,1,daysInMonth(e.year,e.month));return t?n?!r&&unitOutOfRange("day",e.day):unitOutOfRange("month",e.month):unitOutOfRange("year",e.year)}function hasInvalidTimeData(e){var t=e.hour,n=e.minute,r=e.second,i=e.millisecond,a=integerBetween(t,0,23)||24===t&&0===n&&0===r&&0===i,o=integerBetween(n,0,59),s=integerBetween(r,0,59),u=integerBetween(i,0,999);return a?o?s?!u&&unitOutOfRange("millisecond",i):unitOutOfRange("second",r):unitOutOfRange("minute",n):unitOutOfRange("hour",t)}var INVALID="Invalid DateTime",MAX_DATE=864e13;function unsupportedZone(e){return new Invalid("unsupported zone",'the zone "'+e.name+'" is not supported')}function possiblyCachedWeekData(e){return null===e.weekData&&(e.weekData=gregorianToWeek(e.c)),e.weekData}function clone(e,t){var n={ts:e.ts,zone:e.zone,c:e.c,o:e.o,loc:e.loc,invalid:e.invalid};return new DateTime(_extends({},n,t,{old:n}))}function fixOffset(e,t,n){var r=e-60*t*1e3,i=n.offset(r);if(t===i)return[r,t];r-=60*(i-t)*1e3;var a=n.offset(r);return i===a?[r,i]:[e-60*Math.min(i,a)*1e3,Math.max(i,a)]}function tsToObj(e,t){var n=new Date(e+=60*t*1e3);return{year:n.getUTCFullYear(),month:n.getUTCMonth()+1,day:n.getUTCDate(),hour:n.getUTCHours(),minute:n.getUTCMinutes(),second:n.getUTCSeconds(),millisecond:n.getUTCMilliseconds()}}function objToTS(e,t,n){return fixOffset(objToLocalTS(e),t,n)}function adjustTime(e,t){var n=e.o,r=e.c.year+Math.trunc(t.years),i=e.c.month+Math.trunc(t.months)+3*Math.trunc(t.quarters),a=_extends({},e.c,{year:r,month:i,day:Math.min(e.c.day,daysInMonth(r,i))+Math.trunc(t.days)+7*Math.trunc(t.weeks)}),o=Duration.fromObject({years:t.years-Math.trunc(t.years),quarters:t.quarters-Math.trunc(t.quarters),months:t.months-Math.trunc(t.months),weeks:t.weeks-Math.trunc(t.weeks),days:t.days-Math.trunc(t.days),hours:t.hours,minutes:t.minutes,seconds:t.seconds,milliseconds:t.milliseconds}).as("milliseconds"),s=fixOffset(objToLocalTS(a),n,e.zone),u=s[0],c=s[1];return 0!==o&&(u+=o,c=e.zone.offset(u)),{ts:u,o:c}}function parseDataToDateTime(e,t,n,r,i,a){var o=n.setZone,s=n.zone;if(e&&0!==Object.keys(e).length||t){var u=t||s,c=DateTime.fromObject(e,_extends({},n,{zone:u,specificOffset:a}));return o?c:c.setZone(s)}return DateTime.invalid(new Invalid("unparsable",'the input "'+i+"\" can't be parsed as "+r))}function toTechFormat(e,t,n){return void 0===n&&(n=!0),e.isValid?Formatter.create(Locale.create("en-US"),{allowZ:n,forceSimple:!0}).formatDateTimeFromString(e,t):null}function _toISODate(e,t){var n=e.c.year>9999||e.c.year<0,r="";return n&&e.c.year>=0&&(r+="+"),r+=padStart(e.c.year,n?6:4),t?(r+="-",r+=padStart(e.c.month),r+="-",r+=padStart(e.c.day)):(r+=padStart(e.c.month),r+=padStart(e.c.day)),r}function _toISOTime(e,t,n,r,i,a){var o=padStart(e.c.hour);return t?(o+=":",o+=padStart(e.c.minute),0===e.c.second&&n||(o+=":")):o+=padStart(e.c.minute),0===e.c.second&&n||(o+=padStart(e.c.second),0===e.c.millisecond&&r||(o+=".",o+=padStart(e.c.millisecond,3))),i&&(e.isOffsetFixed&&0===e.offset&&!a?o+="Z":e.o<0?(o+="-",o+=padStart(Math.trunc(-e.o/60)),o+=":",o+=padStart(Math.trunc(-e.o%60))):(o+="+",o+=padStart(Math.trunc(e.o/60)),o+=":",o+=padStart(Math.trunc(e.o%60)))),a&&(o+="["+e.zone.ianaName+"]"),o}var defaultUnitValues={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},defaultWeekUnitValues={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},defaultOrdinalUnitValues={ordinal:1,hour:0,minute:0,second:0,millisecond:0},orderedUnits=["year","month","day","hour","minute","second","millisecond"],orderedWeekUnits=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],orderedOrdinalUnits=["year","ordinal","hour","minute","second","millisecond"];function normalizeUnit(e){var t={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[e.toLowerCase()];if(!t)throw new InvalidUnitError(e);return t}function quickDT(e,t){var n,r,i=normalizeZone(t.zone,Settings.defaultZone),a=Locale.fromObject(t),o=Settings.now();if(isUndefined(e.year))n=o;else{for(var s=0,u=orderedUnits;s<u.length;s++){var c=u[s];isUndefined(e[c])&&(e[c]=defaultUnitValues[c])}var l=hasInvalidGregorianData(e)||hasInvalidTimeData(e);if(l)return DateTime.invalid(l);var d=objToTS(e,i.offset(o),i);n=d[0],r=d[1]}return new DateTime({ts:n,zone:i,loc:a,o:r})}function diffRelative(e,t,n){var r=!!isUndefined(n.round)||n.round,i=function(e,i){return e=roundTo(e,r||n.calendary?0:2,!0),t.loc.clone(n).relFormatter(n).format(e,i)},a=function(r){return n.calendary?t.hasSame(e,r)?0:t.startOf(r).diff(e.startOf(r),r).get(r):t.diff(e,r).get(r)};if(n.unit)return i(a(n.unit),n.unit);for(var o,s=_createForOfIteratorHelperLoose(n.units);!(o=s()).done;){var u=o.value,c=a(u);if(Math.abs(c)>=1)return i(c,u)}return i(e>t?-0:0,n.units[n.units.length-1])}function lastOpts(e){var t,n={};return e.length>0&&"object"==typeof e[e.length-1]?(n=e[e.length-1],t=Array.from(e).slice(0,e.length-1)):t=Array.from(e),[n,t]}var DateTime=function(){function e(e){var t=e.zone||Settings.defaultZone,n=e.invalid||(Number.isNaN(e.ts)?new Invalid("invalid input"):null)||(t.isValid?null:unsupportedZone(t));this.ts=isUndefined(e.ts)?Settings.now():e.ts;var r=null,i=null;if(!n)if(e.old&&e.old.ts===this.ts&&e.old.zone.equals(t)){var a=[e.old.c,e.old.o];r=a[0],i=a[1]}else{var o=t.offset(this.ts);r=tsToObj(this.ts,o),r=(n=Number.isNaN(r.year)?new Invalid("invalid input"):null)?null:r,i=n?null:o}this._zone=t,this.loc=e.loc||Locale.create(),this.invalid=n,this.weekData=null,this.c=r,this.o=i,this.isLuxonDateTime=!0}e.now=function(){return new e({})},e.local=function(){var e=lastOpts(arguments),t=e[0],n=e[1];return quickDT({year:n[0],month:n[1],day:n[2],hour:n[3],minute:n[4],second:n[5],millisecond:n[6]},t)},e.utc=function(){var e=lastOpts(arguments),t=e[0],n=e[1],r=n[0],i=n[1],a=n[2],o=n[3],s=n[4],u=n[5],c=n[6];return t.zone=FixedOffsetZone.utcInstance,quickDT({year:r,month:i,day:a,hour:o,minute:s,second:u,millisecond:c},t)},e.fromJSDate=function(t,n){void 0===n&&(n={});var r=isDate(t)?t.valueOf():NaN;if(Number.isNaN(r))return e.invalid("invalid input");var i=normalizeZone(n.zone,Settings.defaultZone);return i.isValid?new e({ts:r,zone:i,loc:Locale.fromObject(n)}):e.invalid(unsupportedZone(i))},e.fromMillis=function(t,n){if(void 0===n&&(n={}),isNumber(t))return t<-MAX_DATE||t>MAX_DATE?e.invalid("Timestamp out of range"):new e({ts:t,zone:normalizeZone(n.zone,Settings.defaultZone),loc:Locale.fromObject(n)});throw new InvalidArgumentError("fromMillis requires a numerical input, but received a "+typeof t+" with value "+t)},e.fromSeconds=function(t,n){if(void 0===n&&(n={}),isNumber(t))return new e({ts:1e3*t,zone:normalizeZone(n.zone,Settings.defaultZone),loc:Locale.fromObject(n)});throw new InvalidArgumentError("fromSeconds requires a numerical input")},e.fromObject=function(t,n){void 0===n&&(n={}),t=t||{};var r=normalizeZone(n.zone,Settings.defaultZone);if(!r.isValid)return e.invalid(unsupportedZone(r));var i=Settings.now(),a=isUndefined(n.specificOffset)?r.offset(i):n.specificOffset,o=normalizeObject(t,normalizeUnit),s=!isUndefined(o.ordinal),u=!isUndefined(o.year),c=!isUndefined(o.month)||!isUndefined(o.day),l=u||c,d=o.weekYear||o.weekNumber,f=Locale.fromObject(n);if((l||s)&&d)throw new ConflictingSpecificationError("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(c&&s)throw new ConflictingSpecificationError("Can't mix ordinal dates with month/day");var m,h,y=d||o.weekday&&!l,v=tsToObj(i,a);y?(m=orderedWeekUnits,h=defaultWeekUnitValues,v=gregorianToWeek(v)):s?(m=orderedOrdinalUnits,h=defaultOrdinalUnitValues,v=gregorianToOrdinal(v)):(m=orderedUnits,h=defaultUnitValues);for(var g,p=!1,T=_createForOfIteratorHelperLoose(m);!(g=T()).done;){var O=g.value;isUndefined(o[O])?o[O]=p?h[O]:v[O]:p=!0}var S=(y?hasInvalidWeekData(o):s?hasInvalidOrdinalData(o):hasInvalidGregorianData(o))||hasInvalidTimeData(o);if(S)return e.invalid(S);var I=objToTS(y?weekToGregorian(o):s?ordinalToGregorian(o):o,a,r),w=new e({ts:I[0],zone:r,o:I[1],loc:f});return o.weekday&&l&&t.weekday!==w.weekday?e.invalid("mismatched weekday","you can't specify both a weekday of "+o.weekday+" and a date of "+w.toISO()):w},e.fromISO=function(e,t){void 0===t&&(t={});var n=parseISODate(e);return parseDataToDateTime(n[0],n[1],t,"ISO 8601",e)},e.fromRFC2822=function(e,t){void 0===t&&(t={});var n=parseRFC2822Date(e);return parseDataToDateTime(n[0],n[1],t,"RFC 2822",e)},e.fromHTTP=function(e,t){void 0===t&&(t={});var n=parseHTTPDate(e);return parseDataToDateTime(n[0],n[1],t,"HTTP",t)},e.fromFormat=function(t,n,r){if(void 0===r&&(r={}),isUndefined(t)||isUndefined(n))throw new InvalidArgumentError("fromFormat requires an input string and a format");var i=r,a=i.locale,o=void 0===a?null:a,s=i.numberingSystem,u=void 0===s?null:s,c=parseFromTokens(Locale.fromOpts({locale:o,numberingSystem:u,defaultToEN:!0}),t,n),l=c[0],d=c[1],f=c[2],m=c[3];return m?e.invalid(m):parseDataToDateTime(l,d,r,"format "+n,t,f)},e.fromString=function(t,n,r){return void 0===r&&(r={}),e.fromFormat(t,n,r)},e.fromSQL=function(e,t){void 0===t&&(t={});var n=parseSQL(e);return parseDataToDateTime(n[0],n[1],t,"SQL",e)},e.invalid=function(t,n){if(void 0===n&&(n=null),!t)throw new InvalidArgumentError("need to specify a reason the DateTime is invalid");var r=t instanceof Invalid?t:new Invalid(t,n);if(Settings.throwOnInvalid)throw new InvalidDateTimeError(r);return new e({invalid:r})},e.isDateTime=function(e){return e&&e.isLuxonDateTime||!1},e.parseFormatForOpts=function(e,t){void 0===t&&(t={});var n=formatOptsToTokens(e,Locale.fromObject(t));return n?n.map((function(e){return e?e.val:null})).join(""):null},e.expandFormat=function(e,t){return void 0===t&&(t={}),expandMacroTokens(Formatter.parseFormat(e),Locale.fromObject(t)).map((function(e){return e.val})).join("")};var t=e.prototype;return t.get=function(e){return this[e]},t.resolvedLocaleOptions=function(e){void 0===e&&(e={});var t=Formatter.create(this.loc.clone(e),e).resolvedOptions(this);return{locale:t.locale,numberingSystem:t.numberingSystem,outputCalendar:t.calendar}},t.toUTC=function(e,t){return void 0===e&&(e=0),void 0===t&&(t={}),this.setZone(FixedOffsetZone.instance(e),t)},t.toLocal=function(){return this.setZone(Settings.defaultZone)},t.setZone=function(t,n){var r=void 0===n?{}:n,i=r.keepLocalTime,a=void 0!==i&&i,o=r.keepCalendarTime,s=void 0!==o&&o;if((t=normalizeZone(t,Settings.defaultZone)).equals(this.zone))return this;if(t.isValid){var u=this.ts;if(a||s){var c=t.offset(this.ts);u=objToTS(this.toObject(),c,t)[0]}return clone(this,{ts:u,zone:t})}return e.invalid(unsupportedZone(t))},t.reconfigure=function(e){var t=void 0===e?{}:e,n=t.locale,r=t.numberingSystem,i=t.outputCalendar;return clone(this,{loc:this.loc.clone({locale:n,numberingSystem:r,outputCalendar:i})})},t.setLocale=function(e){return this.reconfigure({locale:e})},t.set=function(e){if(!this.isValid)return this;var t,n=normalizeObject(e,normalizeUnit),r=!isUndefined(n.weekYear)||!isUndefined(n.weekNumber)||!isUndefined(n.weekday),i=!isUndefined(n.ordinal),a=!isUndefined(n.year),o=!isUndefined(n.month)||!isUndefined(n.day),s=a||o,u=n.weekYear||n.weekNumber;if((s||i)&&u)throw new ConflictingSpecificationError("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(o&&i)throw new ConflictingSpecificationError("Can't mix ordinal dates with month/day");r?t=weekToGregorian(_extends({},gregorianToWeek(this.c),n)):isUndefined(n.ordinal)?(t=_extends({},this.toObject(),n),isUndefined(n.day)&&(t.day=Math.min(daysInMonth(t.year,t.month),t.day))):t=ordinalToGregorian(_extends({},gregorianToOrdinal(this.c),n));var c=objToTS(t,this.o,this.zone);return clone(this,{ts:c[0],o:c[1]})},t.plus=function(e){return this.isValid?clone(this,adjustTime(this,Duration.fromDurationLike(e))):this},t.minus=function(e){return this.isValid?clone(this,adjustTime(this,Duration.fromDurationLike(e).negate())):this},t.startOf=function(e){if(!this.isValid)return this;var t={},n=Duration.normalizeUnit(e);switch(n){case"years":t.month=1;case"quarters":case"months":t.day=1;case"weeks":case"days":t.hour=0;case"hours":t.minute=0;case"minutes":t.second=0;case"seconds":t.millisecond=0}if("weeks"===n&&(t.weekday=1),"quarters"===n){var r=Math.ceil(this.month/3);t.month=3*(r-1)+1}return this.set(t)},t.endOf=function(e){var t;return this.isValid?this.plus((t={},t[e]=1,t)).startOf(e).minus(1):this},t.toFormat=function(e,t){return void 0===t&&(t={}),this.isValid?Formatter.create(this.loc.redefaultToEN(t)).formatDateTimeFromString(this,e):INVALID},Reflect.defineProperty(t,"toLocaleString",{value:function(e,t){return void 0===e&&(e=DATE_SHORT),void 0===t&&(t={}),this.isValid?Formatter.create(this.loc.clone(t),e).formatDateTime(this):INVALID}}),t.toLocaleParts=function(e){return void 0===e&&(e={}),this.isValid?Formatter.create(this.loc.clone(e),e).formatDateTimeParts(this):[]},t.toISO=function(e){var t=void 0===e?{}:e,n=t.format,r=void 0===n?"extended":n,i=t.suppressSeconds,a=void 0!==i&&i,o=t.suppressMilliseconds,s=void 0!==o&&o,u=t.includeOffset,c=void 0===u||u,l=t.extendedZone,d=void 0!==l&&l;if(!this.isValid)return null;var f="extended"===r,m=_toISODate(this,f);return m+="T",m+=_toISOTime(this,f,a,s,c,d)},t.toISODate=function(e){var t=(void 0===e?{}:e).format,n=void 0===t?"extended":t;return this.isValid?_toISODate(this,"extended"===n):null},t.toISOWeekDate=function(){return toTechFormat(this,"kkkk-'W'WW-c")},t.toISOTime=function(e){var t=void 0===e?{}:e,n=t.suppressMilliseconds,r=void 0!==n&&n,i=t.suppressSeconds,a=void 0!==i&&i,o=t.includeOffset,s=void 0===o||o,u=t.includePrefix,c=void 0!==u&&u,l=t.extendedZone,d=void 0!==l&&l,f=t.format,m=void 0===f?"extended":f;return this.isValid?(c?"T":"")+_toISOTime(this,"extended"===m,a,r,s,d):null},t.toRFC2822=function(){return toTechFormat(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)},t.toHTTP=function(){return toTechFormat(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")},t.toSQLDate=function(){return this.isValid?_toISODate(this,!0):null},t.toSQLTime=function(e){var t=void 0===e?{}:e,n=t.includeOffset,r=void 0===n||n,i=t.includeZone,a=void 0!==i&&i,o=t.includeOffsetSpace,s="HH:mm:ss.SSS";return(a||r)&&((void 0===o||o)&&(s+=" "),a?s+="z":r&&(s+="ZZ")),toTechFormat(this,s,!0)},t.toSQL=function(e){return void 0===e&&(e={}),this.isValid?this.toSQLDate()+" "+this.toSQLTime(e):null},t.toString=function(){return this.isValid?this.toISO():INVALID},t.valueOf=function(){return this.toMillis()},t.toMillis=function(){return this.isValid?this.ts:NaN},t.toSeconds=function(){return this.isValid?this.ts/1e3:NaN},t.toUnixInteger=function(){return this.isValid?Math.floor(this.ts/1e3):NaN},t.toJSON=function(){return this.toISO()},t.toBSON=function(){return this.toJSDate()},t.toObject=function(e){if(void 0===e&&(e={}),!this.isValid)return{};var t=_extends({},this.c);return e.includeConfig&&(t.outputCalendar=this.outputCalendar,t.numberingSystem=this.loc.numberingSystem,t.locale=this.loc.locale),t},t.toJSDate=function(){return new Date(this.isValid?this.ts:NaN)},t.diff=function(e,t,n){if(void 0===t&&(t="milliseconds"),void 0===n&&(n={}),!this.isValid||!e.isValid)return Duration.invalid("created by diffing an invalid DateTime");var r=_extends({locale:this.locale,numberingSystem:this.numberingSystem},n),i=maybeArray(t).map(Duration.normalizeUnit),a=e.valueOf()>this.valueOf(),o=_diff(a?this:e,a?e:this,i,r);return a?o.negate():o},t.diffNow=function(t,n){return void 0===t&&(t="milliseconds"),void 0===n&&(n={}),this.diff(e.now(),t,n)},t.until=function(e){return this.isValid?Interval.fromDateTimes(this,e):this},t.hasSame=function(e,t){if(!this.isValid)return!1;var n=e.valueOf(),r=this.setZone(e.zone,{keepLocalTime:!0});return r.startOf(t)<=n&&n<=r.endOf(t)},t.equals=function(e){return this.isValid&&e.isValid&&this.valueOf()===e.valueOf()&&this.zone.equals(e.zone)&&this.loc.equals(e.loc)},t.toRelative=function(t){if(void 0===t&&(t={}),!this.isValid)return null;var n=t.base||e.fromObject({},{zone:this.zone}),r=t.padding?this<n?-t.padding:t.padding:0,i=["years","months","days","hours","minutes","seconds"],a=t.unit;return Array.isArray(t.unit)&&(i=t.unit,a=void 0),diffRelative(n,this.plus(r),_extends({},t,{numeric:"always",units:i,unit:a}))},t.toRelativeCalendar=function(t){return void 0===t&&(t={}),this.isValid?diffRelative(t.base||e.fromObject({},{zone:this.zone}),this,_extends({},t,{numeric:"auto",units:["years","months","days"],calendary:!0})):null},e.min=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.every(e.isDateTime))throw new InvalidArgumentError("min requires all arguments be DateTimes");return bestBy(n,(function(e){return e.valueOf()}),Math.min)},e.max=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.every(e.isDateTime))throw new InvalidArgumentError("max requires all arguments be DateTimes");return bestBy(n,(function(e){return e.valueOf()}),Math.max)},e.fromFormatExplain=function(e,t,n){void 0===n&&(n={});var r=n,i=r.locale,a=void 0===i?null:i,o=r.numberingSystem,s=void 0===o?null:o;return explainFromTokens(Locale.fromOpts({locale:a,numberingSystem:s,defaultToEN:!0}),e,t)},e.fromStringExplain=function(t,n,r){return void 0===r&&(r={}),e.fromFormatExplain(t,n,r)},_createClass(e,[{key:"isValid",get:function(){return null===this.invalid}},{key:"invalidReason",get:function(){return this.invalid?this.invalid.reason:null}},{key:"invalidExplanation",get:function(){return this.invalid?this.invalid.explanation:null}},{key:"locale",get:function(){return this.isValid?this.loc.locale:null}},{key:"numberingSystem",get:function(){return this.isValid?this.loc.numberingSystem:null}},{key:"outputCalendar",get:function(){return this.isValid?this.loc.outputCalendar:null}},{key:"zone",get:function(){return this._zone}},{key:"zoneName",get:function(){return this.isValid?this.zone.name:null}},{key:"year",get:function(){return this.isValid?this.c.year:NaN}},{key:"quarter",get:function(){return this.isValid?Math.ceil(this.c.month/3):NaN}},{key:"month",get:function(){return this.isValid?this.c.month:NaN}},{key:"day",get:function(){return this.isValid?this.c.day:NaN}},{key:"hour",get:function(){return this.isValid?this.c.hour:NaN}},{key:"minute",get:function(){return this.isValid?this.c.minute:NaN}},{key:"second",get:function(){return this.isValid?this.c.second:NaN}},{key:"millisecond",get:function(){return this.isValid?this.c.millisecond:NaN}},{key:"weekYear",get:function(){return this.isValid?possiblyCachedWeekData(this).weekYear:NaN}},{key:"weekNumber",get:function(){return this.isValid?possiblyCachedWeekData(this).weekNumber:NaN}},{key:"weekday",get:function(){return this.isValid?possiblyCachedWeekData(this).weekday:NaN}},{key:"ordinal",get:function(){return this.isValid?gregorianToOrdinal(this.c).ordinal:NaN}},{key:"monthShort",get:function(){return this.isValid?Info.months("short",{locObj:this.loc})[this.month-1]:null}},{key:"monthLong",get:function(){return this.isValid?Info.months("long",{locObj:this.loc})[this.month-1]:null}},{key:"weekdayShort",get:function(){return this.isValid?Info.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}},{key:"weekdayLong",get:function(){return this.isValid?Info.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}},{key:"offset",get:function(){return this.isValid?+this.o:NaN}},{key:"offsetNameShort",get:function(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}},{key:"offsetNameLong",get:function(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}},{key:"isOffsetFixed",get:function(){return this.isValid?this.zone.isUniversal:null}},{key:"isInDST",get:function(){return!this.isOffsetFixed&&(this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset)}},{key:"isInLeapYear",get:function(){return isLeapYear(this.year)}},{key:"daysInMonth",get:function(){return daysInMonth(this.year,this.month)}},{key:"daysInYear",get:function(){return this.isValid?daysInYear(this.year):NaN}},{key:"weeksInWeekYear",get:function(){return this.isValid?weeksInWeekYear(this.weekYear):NaN}}],[{key:"DATE_SHORT",get:function(){return DATE_SHORT}},{key:"DATE_MED",get:function(){return DATE_MED}},{key:"DATE_MED_WITH_WEEKDAY",get:function(){return DATE_MED_WITH_WEEKDAY}},{key:"DATE_FULL",get:function(){return DATE_FULL}},{key:"DATE_HUGE",get:function(){return DATE_HUGE}},{key:"TIME_SIMPLE",get:function(){return TIME_SIMPLE}},{key:"TIME_WITH_SECONDS",get:function(){return TIME_WITH_SECONDS}},{key:"TIME_WITH_SHORT_OFFSET",get:function(){return TIME_WITH_SHORT_OFFSET}},{key:"TIME_WITH_LONG_OFFSET",get:function(){return TIME_WITH_LONG_OFFSET}},{key:"TIME_24_SIMPLE",get:function(){return TIME_24_SIMPLE}},{key:"TIME_24_WITH_SECONDS",get:function(){return TIME_24_WITH_SECONDS}},{key:"TIME_24_WITH_SHORT_OFFSET",get:function(){return TIME_24_WITH_SHORT_OFFSET}},{key:"TIME_24_WITH_LONG_OFFSET",get:function(){return TIME_24_WITH_LONG_OFFSET}},{key:"DATETIME_SHORT",get:function(){return DATETIME_SHORT}},{key:"DATETIME_SHORT_WITH_SECONDS",get:function(){return DATETIME_SHORT_WITH_SECONDS}},{key:"DATETIME_MED",get:function(){return DATETIME_MED}},{key:"DATETIME_MED_WITH_SECONDS",get:function(){return DATETIME_MED_WITH_SECONDS}},{key:"DATETIME_MED_WITH_WEEKDAY",get:function(){return DATETIME_MED_WITH_WEEKDAY}},{key:"DATETIME_FULL",get:function(){return DATETIME_FULL}},{key:"DATETIME_FULL_WITH_SECONDS",get:function(){return DATETIME_FULL_WITH_SECONDS}},{key:"DATETIME_HUGE",get:function(){return DATETIME_HUGE}},{key:"DATETIME_HUGE_WITH_SECONDS",get:function(){return DATETIME_HUGE_WITH_SECONDS}}]),e}();function friendlyDateTime(e){if(DateTime.isDateTime(e))return e;if(e&&e.valueOf&&isNumber(e.valueOf()))return DateTime.fromJSDate(e);if(e&&"object"==typeof e)return DateTime.fromObject(e);throw new InvalidArgumentError("Unknown datetime argument: "+e+", of type "+typeof e)}var VERSION="3.3.0";exports.DateTime=DateTime,/* common-shake removed: exports.Duration = */ void Duration,/* common-shake removed: exports.FixedOffsetZone = */ void FixedOffsetZone,/* common-shake removed: exports.IANAZone = */ void IANAZone,/* common-shake removed: exports.Info = */ void Info,/* common-shake removed: exports.Interval = */ void Interval,/* common-shake removed: exports.InvalidZone = */ void InvalidZone,/* common-shake removed: exports.Settings = */ void Settings,/* common-shake removed: exports.SystemZone = */ void SystemZone,/* common-shake removed: exports.VERSION = */ void VERSION,/* common-shake removed: exports.Zone = */ void Zone;
|
|
908
1330
|
|
|
@@ -911,12 +1333,12 @@ var toString={}.toString;module.exports=Array.isArray||function(r){return"[objec
|
|
|
911
1333
|
}
|
|
912
1334
|
}
|
|
913
1335
|
}, {package:"@metamask/snaps-utils>cron-parser>luxon",file:"../../node_modules/luxon/build/cjs-browser/luxon.js",}],
|
|
914
|
-
[
|
|
1336
|
+
[94, {}, function(){
|
|
915
1337
|
with (this.scopeTerminator) {
|
|
916
1338
|
with (this.globalThis) {
|
|
917
1339
|
return function() {
|
|
918
1340
|
'use strict';
|
|
919
|
-
// source: /home/runner/work/snaps
|
|
1341
|
+
// source: /home/runner/work/snaps/snaps/node_modules/process/browser.js
|
|
920
1342
|
return function (require, module, exports) {
|
|
921
1343
|
var cachedSetTimeout,cachedClearTimeout,process=module.exports={};function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}function runTimeout(e){if(cachedSetTimeout===setTimeout)return setTimeout(e,0);if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout)return cachedSetTimeout=setTimeout,setTimeout(e,0);try{return cachedSetTimeout(e,0)}catch(t){try{return cachedSetTimeout.call(null,e,0)}catch(t){return cachedSetTimeout.call(this,e,0)}}}function runClearTimeout(e){if(cachedClearTimeout===clearTimeout)return clearTimeout(e);if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout)return cachedClearTimeout=clearTimeout,clearTimeout(e);try{return cachedClearTimeout(e)}catch(t){try{return cachedClearTimeout.call(null,e)}catch(t){return cachedClearTimeout.call(this,e)}}}!function(){try{cachedSetTimeout="function"==typeof setTimeout?setTimeout:defaultSetTimout}catch(e){cachedSetTimeout=defaultSetTimout}try{cachedClearTimeout="function"==typeof clearTimeout?clearTimeout:defaultClearTimeout}catch(e){cachedClearTimeout=defaultClearTimeout}}();var currentQueue,queue=[],draining=!1,queueIndex=-1;function cleanUpNextTick(){draining&¤tQueue&&(draining=!1,currentQueue.length?queue=currentQueue.concat(queue):queueIndex=-1,queue.length&&drainQueue())}function drainQueue(){if(!draining){var e=runTimeout(cleanUpNextTick);draining=!0;for(var t=queue.length;t;){for(currentQueue=queue,queue=[];++queueIndex<t;)currentQueue&¤tQueue[queueIndex].run();queueIndex=-1,t=queue.length}currentQueue=null,draining=!1,runClearTimeout(e)}}function Item(e,t){this.fun=e,this.array=t}function noop(){}process.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];queue.push(new Item(e,t)),1!==queue.length||draining||runTimeout(drainQueue)},Item.prototype.run=function(){this.fun.apply(null,this.array)},process.title="browser",process.browser=!0,process.env={},process.argv=[],process.version="",process.versions={},process.on=noop,process.addListener=noop,process.once=noop,process.off=noop,process.removeListener=noop,process.removeAllListeners=noop,process.emit=noop,process.prependListener=noop,process.prependOnceListener=noop,process.listeners=function(e){return[]},process.binding=function(e){throw new Error("process.binding is not supported")},process.cwd=function(){return"/"},process.chdir=function(e){throw new Error("process.chdir is not supported")},process.umask=function(){return 0};
|
|
922
1344
|
|
|
@@ -925,12 +1347,12 @@ var cachedSetTimeout,cachedClearTimeout,process=module.exports={};function defau
|
|
|
925
1347
|
}
|
|
926
1348
|
}
|
|
927
1349
|
}, {package:"process",file:"../../node_modules/process/browser.js",}],
|
|
928
|
-
[
|
|
1350
|
+
[95, {"buffer":64}, function(){
|
|
929
1351
|
with (this.scopeTerminator) {
|
|
930
1352
|
with (this.globalThis) {
|
|
931
1353
|
return function() {
|
|
932
1354
|
'use strict';
|
|
933
|
-
// source: /home/runner/work/snaps
|
|
1355
|
+
// source: /home/runner/work/snaps/snaps/node_modules/rfdc/index.js
|
|
934
1356
|
return function (require, module, exports) {
|
|
935
1357
|
(function (Buffer){(function (){
|
|
936
1358
|
"use strict";function copyBuffer(e){return e instanceof Buffer?Buffer.from(e):new e.constructor(e.buffer.slice(),e.byteOffset,e.length)}function rfdc(e){return(e=e||{}).circles?rfdcCircles(e):e.proto?function e(n){if("object"!=typeof n||null===n)return n;if(n instanceof Date)return new Date(n);if(Array.isArray(n))return r(n,e);if(n instanceof Map)return new Map(r(Array.from(n),e));if(n instanceof Set)return new Set(r(Array.from(n),e));var f={};for(var t in n){var a=n[t];"object"!=typeof a||null===a?f[t]=a:a instanceof Date?f[t]=new Date(a):a instanceof Map?f[t]=new Map(r(Array.from(a),e)):a instanceof Set?f[t]=new Set(r(Array.from(a),e)):ArrayBuffer.isView(a)?f[t]=copyBuffer(a):f[t]=e(a)}return f}:function e(n){if("object"!=typeof n||null===n)return n;if(n instanceof Date)return new Date(n);if(Array.isArray(n))return r(n,e);if(n instanceof Map)return new Map(r(Array.from(n),e));if(n instanceof Set)return new Set(r(Array.from(n),e));var f={};for(var t in n)if(!1!==Object.hasOwnProperty.call(n,t)){var a=n[t];"object"!=typeof a||null===a?f[t]=a:a instanceof Date?f[t]=new Date(a):a instanceof Map?f[t]=new Map(r(Array.from(a),e)):a instanceof Set?f[t]=new Set(r(Array.from(a),e)):ArrayBuffer.isView(a)?f[t]=copyBuffer(a):f[t]=e(a)}return f};function r(e,r){for(var n=Object.keys(e),f=new Array(n.length),t=0;t<n.length;t++){var a=n[t],o=e[a];"object"!=typeof o||null===o?f[a]=o:o instanceof Date?f[a]=new Date(o):ArrayBuffer.isView(o)?f[a]=copyBuffer(o):f[a]=r(o)}return f}}function rfdcCircles(e){var r=[],n=[];return e.proto?function e(t){if("object"!=typeof t||null===t)return t;if(t instanceof Date)return new Date(t);if(Array.isArray(t))return f(t,e);if(t instanceof Map)return new Map(f(Array.from(t),e));if(t instanceof Set)return new Set(f(Array.from(t),e));var a={};for(var o in r.push(t),n.push(a),t){var i=t[o];if("object"!=typeof i||null===i)a[o]=i;else if(i instanceof Date)a[o]=new Date(i);else if(i instanceof Map)a[o]=new Map(f(Array.from(i),e));else if(i instanceof Set)a[o]=new Set(f(Array.from(i),e));else if(ArrayBuffer.isView(i))a[o]=copyBuffer(i);else{var c=r.indexOf(i);a[o]=-1!==c?n[c]:e(i)}}return r.pop(),n.pop(),a}:function e(t){if("object"!=typeof t||null===t)return t;if(t instanceof Date)return new Date(t);if(Array.isArray(t))return f(t,e);if(t instanceof Map)return new Map(f(Array.from(t),e));if(t instanceof Set)return new Set(f(Array.from(t),e));var a={};for(var o in r.push(t),n.push(a),t)if(!1!==Object.hasOwnProperty.call(t,o)){var i=t[o];if("object"!=typeof i||null===i)a[o]=i;else if(i instanceof Date)a[o]=new Date(i);else if(i instanceof Map)a[o]=new Map(f(Array.from(i),e));else if(i instanceof Set)a[o]=new Set(f(Array.from(i),e));else if(ArrayBuffer.isView(i))a[o]=copyBuffer(i);else{var c=r.indexOf(i);a[o]=-1!==c?n[c]:e(i)}}return r.pop(),n.pop(),a};function f(e,f){for(var t=Object.keys(e),a=new Array(t.length),o=0;o<t.length;o++){var i=t[o],c=e[i];if("object"!=typeof c||null===c)a[i]=c;else if(c instanceof Date)a[i]=new Date(c);else if(ArrayBuffer.isView(c))a[i]=copyBuffer(c);else{var u=r.indexOf(c);a[i]=-1!==u?n[u]:f(c)}}return a}}module.exports=rfdc;
|
|
@@ -941,54 +1363,54 @@ var cachedSetTimeout,cachedClearTimeout,process=module.exports={};function defau
|
|
|
941
1363
|
}
|
|
942
1364
|
}
|
|
943
1365
|
}, {package:"@metamask/snaps-utils>rfdc",file:"../../node_modules/rfdc/index.js",}],
|
|
944
|
-
[
|
|
1366
|
+
[96, {"../functions/cmp":100,"../internal/debug":125,"../internal/parse-options":127,"../internal/re":128,"./range":97,"./semver":98}, function(){
|
|
945
1367
|
with (this.scopeTerminator) {
|
|
946
1368
|
with (this.globalThis) {
|
|
947
1369
|
return function() {
|
|
948
1370
|
'use strict';
|
|
949
|
-
// source: /home/runner/work/snaps
|
|
1371
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/classes/comparator.js
|
|
950
1372
|
return function (require, module, exports) {
|
|
951
|
-
const ANY=Symbol("SemVer ANY");class Comparator{static get ANY(){return ANY}constructor(e,
|
|
1373
|
+
const ANY=Symbol("SemVer ANY");class Comparator{static get ANY(){return ANY}constructor(e,t){if(t=parseOptions(t),e instanceof Comparator){if(e.loose===!!t.loose)return e;e=e.value}debug("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===ANY?this.value="":this.value=this.operator+this.semver.version,debug("comp",this)}parse(e){const r=this.options.loose?re[t.COMPARATORLOOSE]:re[t.COMPARATOR],s=e.match(r);if(!s)throw new TypeError(`Invalid comparator: ${e}`);this.operator=void 0!==s[1]?s[1]:"","="===this.operator&&(this.operator=""),s[2]?this.semver=new SemVer(s[2],this.options.loose):this.semver=ANY}toString(){return this.value}test(e){if(debug("Comparator.test",e,this.options.loose),this.semver===ANY||e===ANY)return!0;if("string"==typeof e)try{e=new SemVer(e,this.options)}catch(e){return!1}return cmp(e,this.operator,this.semver,this.options)}intersects(e,t){if(!(e instanceof Comparator))throw new TypeError("a Comparator is required");return""===this.operator?""===this.value||new Range(e.value,t).test(this.value):""===e.operator?""===e.value||new Range(this.value,t).test(e.semver):(!(t=parseOptions(t)).includePrerelease||"<0.0.0-0"!==this.value&&"<0.0.0-0"!==e.value)&&(!(!t.includePrerelease&&(this.value.startsWith("<0.0.0")||e.value.startsWith("<0.0.0")))&&(!(!this.operator.startsWith(">")||!e.operator.startsWith(">"))||(!(!this.operator.startsWith("<")||!e.operator.startsWith("<"))||(!(this.semver.version!==e.semver.version||!this.operator.includes("=")||!e.operator.includes("="))||(!!(cmp(this.semver,"<",e.semver,t)&&this.operator.startsWith(">")&&e.operator.startsWith("<"))||!!(cmp(this.semver,">",e.semver,t)&&this.operator.startsWith("<")&&e.operator.startsWith(">")))))))}}module.exports=Comparator;const parseOptions=require("../internal/parse-options"),{re:re,t:t}=require("../internal/re"),cmp=require("../functions/cmp"),debug=require("../internal/debug"),SemVer=require("./semver"),Range=require("./range");
|
|
952
1374
|
|
|
953
1375
|
};
|
|
954
1376
|
};
|
|
955
1377
|
}
|
|
956
1378
|
}
|
|
957
|
-
}, {package:"
|
|
958
|
-
[
|
|
1379
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/classes/comparator.js",}],
|
|
1380
|
+
[97, {"../internal/constants":124,"../internal/debug":125,"../internal/parse-options":127,"../internal/re":128,"./comparator":96,"./semver":98,"lru-cache":129}, function(){
|
|
959
1381
|
with (this.scopeTerminator) {
|
|
960
1382
|
with (this.globalThis) {
|
|
961
1383
|
return function() {
|
|
962
1384
|
'use strict';
|
|
963
|
-
// source: /home/runner/work/snaps
|
|
1385
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/classes/range.js
|
|
964
1386
|
return function (require, module, exports) {
|
|
965
|
-
class Range{constructor(e,r){if(r=parseOptions(r),e instanceof Range)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new Range(e.raw,r);if(e instanceof Comparator)return this.raw=e.value,this.set=[[e]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e,this.set=e.split("||").map((e=>this.parseRange(e.trim()))).filter((e=>e.length)),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${e}`);if(this.set.length>1){const e=this.set[0];if(this.set=this.set.filter((e=>!isNullSet(e[0]))),0===this.set.length)this.set=[e];else if(this.set.length>1)for(const e of this.set)if(1===e.length&&isAny(e[0])){this.set=[e];break}}this.format()}format(){return this.range=this.set.map((e=>e.join(" ").trim())).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();const r
|
|
1387
|
+
class Range{constructor(e,r){if(r=parseOptions(r),e instanceof Range)return e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease?e:new Range(e.raw,r);if(e instanceof Comparator)return this.raw=e.value,this.set=[[e]],this.format(),this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=e,this.set=e.split("||").map((e=>this.parseRange(e.trim()))).filter((e=>e.length)),!this.set.length)throw new TypeError(`Invalid SemVer Range: ${e}`);if(this.set.length>1){const e=this.set[0];if(this.set=this.set.filter((e=>!isNullSet(e[0]))),0===this.set.length)this.set=[e];else if(this.set.length>1)for(const e of this.set)if(1===e.length&&isAny(e[0])){this.set=[e];break}}this.format()}format(){return this.range=this.set.map((e=>e.join(" ").trim())).join("||").trim(),this.range}toString(){return this.range}parseRange(e){e=e.trim();const r=((this.options.includePrerelease&&FLAG_INCLUDE_PRERELEASE)|(this.options.loose&&FLAG_LOOSE))+":"+e,s=cache.get(r);if(s)return s;const i=this.options.loose,a=i?re[t.HYPHENRANGELOOSE]:re[t.HYPHENRANGE];e=e.replace(a,hyphenReplace(this.options.includePrerelease)),debug("hyphen replace",e),e=e.replace(re[t.COMPARATORTRIM],comparatorTrimReplace),debug("comparator trim",e);let l=(e=(e=(e=e.replace(re[t.TILDETRIM],tildeTrimReplace)).replace(re[t.CARETTRIM],caretTrimReplace)).split(/\s+/).join(" ")).split(" ").map((e=>parseComparator(e,this.options))).join(" ").split(/\s+/).map((e=>replaceGTE0(e,this.options)));i&&(l=l.filter((e=>(debug("loose invalid filter",e,this.options),!!e.match(re[t.COMPARATORLOOSE]))))),debug("range list",l);const n=new Map,o=l.map((e=>new Comparator(e,this.options)));for(const e of o){if(isNullSet(e))return[e];n.set(e.value,e)}n.size>1&&n.has("")&&n.delete("");const p=[...n.values()];return cache.set(r,p),p}intersects(e,r){if(!(e instanceof Range))throw new TypeError("a Range is required");return this.set.some((t=>isSatisfiable(t,r)&&e.set.some((e=>isSatisfiable(e,r)&&t.every((t=>e.every((e=>t.intersects(e,r)))))))))}test(e){if(!e)return!1;if("string"==typeof e)try{e=new SemVer(e,this.options)}catch(e){return!1}for(let r=0;r<this.set.length;r++)if(testSet(this.set[r],e,this.options))return!0;return!1}}module.exports=Range;const LRU=require("lru-cache"),cache=new LRU({max:1e3}),parseOptions=require("../internal/parse-options"),Comparator=require("./comparator"),debug=require("../internal/debug"),SemVer=require("./semver"),{re:re,t:t,comparatorTrimReplace:comparatorTrimReplace,tildeTrimReplace:tildeTrimReplace,caretTrimReplace:caretTrimReplace}=require("../internal/re"),{FLAG_INCLUDE_PRERELEASE:FLAG_INCLUDE_PRERELEASE,FLAG_LOOSE:FLAG_LOOSE}=require("../internal/constants"),isNullSet=e=>"<0.0.0-0"===e.value,isAny=e=>""===e.value,isSatisfiable=(e,r)=>{let t=!0;const s=e.slice();let i=s.pop();for(;t&&s.length;)t=s.every((e=>i.intersects(e,r))),i=s.pop();return t},parseComparator=(e,r)=>(debug("comp",e,r),e=replaceCarets(e,r),debug("caret",e),e=replaceTildes(e,r),debug("tildes",e),e=replaceXRanges(e,r),debug("xrange",e),e=replaceStars(e,r),debug("stars",e),e),isX=e=>!e||"x"===e.toLowerCase()||"*"===e,replaceTildes=(e,r)=>e.trim().split(/\s+/).map((e=>replaceTilde(e,r))).join(" "),replaceTilde=(e,r)=>{const s=r.loose?re[t.TILDELOOSE]:re[t.TILDE];return e.replace(s,((r,t,s,i,a)=>{let l;return debug("tilde",e,r,t,s,i,a),isX(t)?l="":isX(s)?l=`>=${t}.0.0 <${+t+1}.0.0-0`:isX(i)?l=`>=${t}.${s}.0 <${t}.${+s+1}.0-0`:a?(debug("replaceTilde pr",a),l=`>=${t}.${s}.${i}-${a} <${t}.${+s+1}.0-0`):l=`>=${t}.${s}.${i} <${t}.${+s+1}.0-0`,debug("tilde return",l),l}))},replaceCarets=(e,r)=>e.trim().split(/\s+/).map((e=>replaceCaret(e,r))).join(" "),replaceCaret=(e,r)=>{debug("caret",e,r);const s=r.loose?re[t.CARETLOOSE]:re[t.CARET],i=r.includePrerelease?"-0":"";return e.replace(s,((r,t,s,a,l)=>{let n;return debug("caret",e,r,t,s,a,l),isX(t)?n="":isX(s)?n=`>=${t}.0.0${i} <${+t+1}.0.0-0`:isX(a)?n="0"===t?`>=${t}.${s}.0${i} <${t}.${+s+1}.0-0`:`>=${t}.${s}.0${i} <${+t+1}.0.0-0`:l?(debug("replaceCaret pr",l),n="0"===t?"0"===s?`>=${t}.${s}.${a}-${l} <${t}.${s}.${+a+1}-0`:`>=${t}.${s}.${a}-${l} <${t}.${+s+1}.0-0`:`>=${t}.${s}.${a}-${l} <${+t+1}.0.0-0`):(debug("no pr"),n="0"===t?"0"===s?`>=${t}.${s}.${a}${i} <${t}.${s}.${+a+1}-0`:`>=${t}.${s}.${a}${i} <${t}.${+s+1}.0-0`:`>=${t}.${s}.${a} <${+t+1}.0.0-0`),debug("caret return",n),n}))},replaceXRanges=(e,r)=>(debug("replaceXRanges",e,r),e.split(/\s+/).map((e=>replaceXRange(e,r))).join(" ")),replaceXRange=(e,r)=>{e=e.trim();const s=r.loose?re[t.XRANGELOOSE]:re[t.XRANGE];return e.replace(s,((t,s,i,a,l,n)=>{debug("xRange",e,t,s,i,a,l,n);const o=isX(i),p=o||isX(a),c=p||isX(l),$=c;return"="===s&&$&&(s=""),n=r.includePrerelease?"-0":"",o?t=">"===s||"<"===s?"<0.0.0-0":"*":s&&$?(p&&(a=0),l=0,">"===s?(s=">=",p?(i=+i+1,a=0,l=0):(a=+a+1,l=0)):"<="===s&&(s="<",p?i=+i+1:a=+a+1),"<"===s&&(n="-0"),t=`${s+i}.${a}.${l}${n}`):p?t=`>=${i}.0.0${n} <${+i+1}.0.0-0`:c&&(t=`>=${i}.${a}.0${n} <${i}.${+a+1}.0-0`),debug("xRange return",t),t}))},replaceStars=(e,r)=>(debug("replaceStars",e,r),e.trim().replace(re[t.STAR],"")),replaceGTE0=(e,r)=>(debug("replaceGTE0",e,r),e.trim().replace(re[r.includePrerelease?t.GTE0PRE:t.GTE0],"")),hyphenReplace=e=>(r,t,s,i,a,l,n,o,p,c,$,u,h)=>`${t=isX(s)?"":isX(i)?`>=${s}.0.0${e?"-0":""}`:isX(a)?`>=${s}.${i}.0${e?"-0":""}`:l?`>=${t}`:`>=${t}${e?"-0":""}`} ${o=isX(p)?"":isX(c)?`<${+p+1}.0.0-0`:isX($)?`<${p}.${+c+1}.0-0`:u?`<=${p}.${c}.${$}-${u}`:e?`<${p}.${c}.${+$+1}-0`:`<=${o}`}`.trim(),testSet=(e,r,t)=>{for(let t=0;t<e.length;t++)if(!e[t].test(r))return!1;if(r.prerelease.length&&!t.includePrerelease){for(let t=0;t<e.length;t++)if(debug(e[t].semver),e[t].semver!==Comparator.ANY&&e[t].semver.prerelease.length>0){const s=e[t].semver;if(s.major===r.major&&s.minor===r.minor&&s.patch===r.patch)return!0}return!1}return!0};
|
|
966
1388
|
|
|
967
1389
|
};
|
|
968
1390
|
};
|
|
969
1391
|
}
|
|
970
1392
|
}
|
|
971
|
-
}, {package:"
|
|
972
|
-
[
|
|
1393
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/classes/range.js",}],
|
|
1394
|
+
[98, {"../internal/constants":124,"../internal/debug":125,"../internal/identifiers":126,"../internal/parse-options":127,"../internal/re":128}, function(){
|
|
973
1395
|
with (this.scopeTerminator) {
|
|
974
1396
|
with (this.globalThis) {
|
|
975
1397
|
return function() {
|
|
976
1398
|
'use strict';
|
|
977
|
-
// source: /home/runner/work/snaps
|
|
1399
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/classes/semver.js
|
|
978
1400
|
return function (require, module, exports) {
|
|
979
|
-
const debug=require("../internal/debug"),{MAX_LENGTH:MAX_LENGTH,MAX_SAFE_INTEGER:MAX_SAFE_INTEGER}=require("../internal/constants"),{re:re,t:t}=require("../internal/re"),parseOptions=require("../internal/parse-options"),{compareIdentifiers:compareIdentifiers}=require("../internal/identifiers");class SemVer{constructor(e,r){if(r=parseOptions(r),e instanceof SemVer){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if("string"!=typeof e)throw new TypeError(`Invalid
|
|
1401
|
+
const debug=require("../internal/debug"),{MAX_LENGTH:MAX_LENGTH,MAX_SAFE_INTEGER:MAX_SAFE_INTEGER}=require("../internal/constants"),{re:re,t:t}=require("../internal/re"),parseOptions=require("../internal/parse-options"),{compareIdentifiers:compareIdentifiers}=require("../internal/identifiers");class SemVer{constructor(e,r){if(r=parseOptions(r),e instanceof SemVer){if(e.loose===!!r.loose&&e.includePrerelease===!!r.includePrerelease)return e;e=e.version}else if("string"!=typeof e)throw new TypeError(`Invalid version. Must be a string. Got type "${typeof e}".`);if(e.length>MAX_LENGTH)throw new TypeError(`version is longer than ${MAX_LENGTH} characters`);debug("SemVer",e,r),this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease;const i=e.trim().match(r.loose?re[t.LOOSE]:re[t.FULL]);if(!i)throw new TypeError(`Invalid Version: ${e}`);if(this.raw=e,this.major=+i[1],this.minor=+i[2],this.patch=+i[3],this.major>MAX_SAFE_INTEGER||this.major<0)throw new TypeError("Invalid major version");if(this.minor>MAX_SAFE_INTEGER||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>MAX_SAFE_INTEGER||this.patch<0)throw new TypeError("Invalid patch version");i[4]?this.prerelease=i[4].split(".").map((e=>{if(/^[0-9]+$/.test(e)){const r=+e;if(r>=0&&r<MAX_SAFE_INTEGER)return r}return e})):this.prerelease=[],this.build=i[5]?i[5].split("."):[],this.format()}format(){return this.version=`${this.major}.${this.minor}.${this.patch}`,this.prerelease.length&&(this.version+=`-${this.prerelease.join(".")}`),this.version}toString(){return this.version}compare(e){if(debug("SemVer.compare",this.version,this.options,e),!(e instanceof SemVer)){if("string"==typeof e&&e===this.version)return 0;e=new SemVer(e,this.options)}return e.version===this.version?0:this.compareMain(e)||this.comparePre(e)}compareMain(e){return e instanceof SemVer||(e=new SemVer(e,this.options)),compareIdentifiers(this.major,e.major)||compareIdentifiers(this.minor,e.minor)||compareIdentifiers(this.patch,e.patch)}comparePre(e){if(e instanceof SemVer||(e=new SemVer(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;let r=0;do{const i=this.prerelease[r],t=e.prerelease[r];if(debug("prerelease compare",r,i,t),void 0===i&&void 0===t)return 0;if(void 0===t)return 1;if(void 0===i)return-1;if(i!==t)return compareIdentifiers(i,t)}while(++r)}compareBuild(e){e instanceof SemVer||(e=new SemVer(e,this.options));let r=0;do{const i=this.build[r],t=e.build[r];if(debug("prerelease compare",r,i,t),void 0===i&&void 0===t)return 0;if(void 0===t)return 1;if(void 0===i)return-1;if(i!==t)return compareIdentifiers(i,t)}while(++r)}inc(e,r,i){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",r,i);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",r,i);break;case"prepatch":this.prerelease.length=0,this.inc("patch",r,i),this.inc("pre",r,i);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",r,i),this.inc("pre",r,i);break;case"major":0===this.minor&&0===this.patch&&0!==this.prerelease.length||this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":0===this.patch&&0!==this.prerelease.length||this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":{const e=Number(i)?1:0;if(!r&&!1===i)throw new Error("invalid increment argument: identifier is empty");if(0===this.prerelease.length)this.prerelease=[e];else{let t=this.prerelease.length;for(;--t>=0;)"number"==typeof this.prerelease[t]&&(this.prerelease[t]++,t=-2);if(-1===t){if(r===this.prerelease.join(".")&&!1===i)throw new Error("invalid increment argument: identifier already exists");this.prerelease.push(e)}}if(r){let t=[r,e];!1===i&&(t=[r]),0===compareIdentifiers(this.prerelease[0],r)?isNaN(this.prerelease[1])&&(this.prerelease=t):this.prerelease=t}break}default:throw new Error(`invalid increment argument: ${e}`)}return this.format(),this.raw=this.version,this}}module.exports=SemVer;
|
|
980
1402
|
|
|
981
1403
|
};
|
|
982
1404
|
};
|
|
983
1405
|
}
|
|
984
1406
|
}
|
|
985
|
-
}, {package:"
|
|
986
|
-
[
|
|
1407
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/classes/semver.js",}],
|
|
1408
|
+
[99, {"./parse":115}, function(){
|
|
987
1409
|
with (this.scopeTerminator) {
|
|
988
1410
|
with (this.globalThis) {
|
|
989
1411
|
return function() {
|
|
990
1412
|
'use strict';
|
|
991
|
-
// source: /home/runner/work/snaps
|
|
1413
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/clean.js
|
|
992
1414
|
return function (require, module, exports) {
|
|
993
1415
|
const parse=require("./parse"),clean=(e,r)=>{const n=parse(e.trim().replace(/^[=v]+/,""),r);return n?n.version:null};module.exports=clean;
|
|
994
1416
|
|
|
@@ -996,13 +1418,13 @@ const parse=require("./parse"),clean=(e,r)=>{const n=parse(e.trim().replace(/^[=
|
|
|
996
1418
|
};
|
|
997
1419
|
}
|
|
998
1420
|
}
|
|
999
|
-
}, {package:"
|
|
1000
|
-
[
|
|
1421
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/clean.js",}],
|
|
1422
|
+
[100, {"./eq":106,"./gt":107,"./gte":108,"./lt":110,"./lte":111,"./neq":114}, function(){
|
|
1001
1423
|
with (this.scopeTerminator) {
|
|
1002
1424
|
with (this.globalThis) {
|
|
1003
1425
|
return function() {
|
|
1004
1426
|
'use strict';
|
|
1005
|
-
// source: /home/runner/work/snaps
|
|
1427
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/cmp.js
|
|
1006
1428
|
return function (require, module, exports) {
|
|
1007
1429
|
const eq=require("./eq"),neq=require("./neq"),gt=require("./gt"),gte=require("./gte"),lt=require("./lt"),lte=require("./lte"),cmp=(e,r,t,o)=>{switch(r){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof t&&(t=t.version),e===t;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof t&&(t=t.version),e!==t;case"":case"=":case"==":return eq(e,t,o);case"!=":return neq(e,t,o);case">":return gt(e,t,o);case">=":return gte(e,t,o);case"<":return lt(e,t,o);case"<=":return lte(e,t,o);default:throw new TypeError(`Invalid operator: ${r}`)}};module.exports=cmp;
|
|
1008
1430
|
|
|
@@ -1010,13 +1432,13 @@ const eq=require("./eq"),neq=require("./neq"),gt=require("./gt"),gte=require("./
|
|
|
1010
1432
|
};
|
|
1011
1433
|
}
|
|
1012
1434
|
}
|
|
1013
|
-
}, {package:"
|
|
1014
|
-
[
|
|
1435
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/cmp.js",}],
|
|
1436
|
+
[101, {"../classes/semver":98,"../internal/re":128,"./parse":115}, function(){
|
|
1015
1437
|
with (this.scopeTerminator) {
|
|
1016
1438
|
with (this.globalThis) {
|
|
1017
1439
|
return function() {
|
|
1018
1440
|
'use strict';
|
|
1019
|
-
// source: /home/runner/work/snaps
|
|
1441
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/coerce.js
|
|
1020
1442
|
return function (require, module, exports) {
|
|
1021
1443
|
const SemVer=require("../classes/semver"),parse=require("./parse"),{re:re,t:t}=require("../internal/re"),coerce=(e,r)=>{if(e instanceof SemVer)return e;if("number"==typeof e&&(e=String(e)),"string"!=typeof e)return null;let n=null;if((r=r||{}).rtl){let r;for(;(r=re[t.COERCERTL].exec(e))&&(!n||n.index+n[0].length!==e.length);)n&&r.index+r[0].length===n.index+n[0].length||(n=r),re[t.COERCERTL].lastIndex=r.index+r[1].length+r[2].length;re[t.COERCERTL].lastIndex=-1}else n=e.match(re[t.COERCE]);return null===n?null:parse(`${n[2]}.${n[3]||"0"}.${n[4]||"0"}`,r)};module.exports=coerce;
|
|
1022
1444
|
|
|
@@ -1024,13 +1446,13 @@ const SemVer=require("../classes/semver"),parse=require("./parse"),{re:re,t:t}=r
|
|
|
1024
1446
|
};
|
|
1025
1447
|
}
|
|
1026
1448
|
}
|
|
1027
|
-
}, {package:"
|
|
1028
|
-
[
|
|
1449
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/coerce.js",}],
|
|
1450
|
+
[102, {"../classes/semver":98}, function(){
|
|
1029
1451
|
with (this.scopeTerminator) {
|
|
1030
1452
|
with (this.globalThis) {
|
|
1031
1453
|
return function() {
|
|
1032
1454
|
'use strict';
|
|
1033
|
-
// source: /home/runner/work/snaps
|
|
1455
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/compare-build.js
|
|
1034
1456
|
return function (require, module, exports) {
|
|
1035
1457
|
const SemVer=require("../classes/semver"),compareBuild=(e,r,m)=>{const o=new SemVer(e,m),c=new SemVer(r,m);return o.compare(c)||o.compareBuild(c)};module.exports=compareBuild;
|
|
1036
1458
|
|
|
@@ -1038,13 +1460,13 @@ const SemVer=require("../classes/semver"),compareBuild=(e,r,m)=>{const o=new Sem
|
|
|
1038
1460
|
};
|
|
1039
1461
|
}
|
|
1040
1462
|
}
|
|
1041
|
-
}, {package:"
|
|
1042
|
-
[
|
|
1463
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/compare-build.js",}],
|
|
1464
|
+
[103, {"./compare":104}, function(){
|
|
1043
1465
|
with (this.scopeTerminator) {
|
|
1044
1466
|
with (this.globalThis) {
|
|
1045
1467
|
return function() {
|
|
1046
1468
|
'use strict';
|
|
1047
|
-
// source: /home/runner/work/snaps
|
|
1469
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/compare-loose.js
|
|
1048
1470
|
return function (require, module, exports) {
|
|
1049
1471
|
const compare=require("./compare"),compareLoose=(o,e)=>compare(o,e,!0);module.exports=compareLoose;
|
|
1050
1472
|
|
|
@@ -1052,13 +1474,13 @@ const compare=require("./compare"),compareLoose=(o,e)=>compare(o,e,!0);module.ex
|
|
|
1052
1474
|
};
|
|
1053
1475
|
}
|
|
1054
1476
|
}
|
|
1055
|
-
}, {package:"
|
|
1056
|
-
[
|
|
1477
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/compare-loose.js",}],
|
|
1478
|
+
[104, {"../classes/semver":98}, function(){
|
|
1057
1479
|
with (this.scopeTerminator) {
|
|
1058
1480
|
with (this.globalThis) {
|
|
1059
1481
|
return function() {
|
|
1060
1482
|
'use strict';
|
|
1061
|
-
// source: /home/runner/work/snaps
|
|
1483
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/compare.js
|
|
1062
1484
|
return function (require, module, exports) {
|
|
1063
1485
|
const SemVer=require("../classes/semver"),compare=(e,r,m)=>new SemVer(e,m).compare(new SemVer(r,m));module.exports=compare;
|
|
1064
1486
|
|
|
@@ -1066,27 +1488,27 @@ const SemVer=require("../classes/semver"),compare=(e,r,m)=>new SemVer(e,m).compa
|
|
|
1066
1488
|
};
|
|
1067
1489
|
}
|
|
1068
1490
|
}
|
|
1069
|
-
}, {package:"
|
|
1070
|
-
[
|
|
1491
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/compare.js",}],
|
|
1492
|
+
[105, {"./parse.js":115}, function(){
|
|
1071
1493
|
with (this.scopeTerminator) {
|
|
1072
1494
|
with (this.globalThis) {
|
|
1073
1495
|
return function() {
|
|
1074
1496
|
'use strict';
|
|
1075
|
-
// source: /home/runner/work/snaps
|
|
1497
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/diff.js
|
|
1076
1498
|
return function (require, module, exports) {
|
|
1077
|
-
const parse=require("./parse"),
|
|
1499
|
+
const parse=require("./parse.js"),diff=(r,e)=>{const a=parse(r,null,!0),o=parse(e,null,!0),n=a.compare(o);if(0===n)return null;const p=n>0,t=p?o:a,m=!!(p?a:o).prerelease.length,s=m?"pre":"";return a.major!==o.major?s+"major":a.minor!==o.minor?s+"minor":a.patch!==o.patch?s+"patch":m?"prerelease":t.patch?"patch":t.minor?"minor":"major"};module.exports=diff;
|
|
1078
1500
|
|
|
1079
1501
|
};
|
|
1080
1502
|
};
|
|
1081
1503
|
}
|
|
1082
1504
|
}
|
|
1083
|
-
}, {package:"
|
|
1084
|
-
[
|
|
1505
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/diff.js",}],
|
|
1506
|
+
[106, {"./compare":104}, function(){
|
|
1085
1507
|
with (this.scopeTerminator) {
|
|
1086
1508
|
with (this.globalThis) {
|
|
1087
1509
|
return function() {
|
|
1088
1510
|
'use strict';
|
|
1089
|
-
// source: /home/runner/work/snaps
|
|
1511
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/eq.js
|
|
1090
1512
|
return function (require, module, exports) {
|
|
1091
1513
|
const compare=require("./compare"),eq=(e,o,r)=>0===compare(e,o,r);module.exports=eq;
|
|
1092
1514
|
|
|
@@ -1094,13 +1516,13 @@ const compare=require("./compare"),eq=(e,o,r)=>0===compare(e,o,r);module.exports
|
|
|
1094
1516
|
};
|
|
1095
1517
|
}
|
|
1096
1518
|
}
|
|
1097
|
-
}, {package:"
|
|
1098
|
-
[
|
|
1519
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/eq.js",}],
|
|
1520
|
+
[107, {"./compare":104}, function(){
|
|
1099
1521
|
with (this.scopeTerminator) {
|
|
1100
1522
|
with (this.globalThis) {
|
|
1101
1523
|
return function() {
|
|
1102
1524
|
'use strict';
|
|
1103
|
-
// source: /home/runner/work/snaps
|
|
1525
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/gt.js
|
|
1104
1526
|
return function (require, module, exports) {
|
|
1105
1527
|
const compare=require("./compare"),gt=(e,o,r)=>compare(e,o,r)>0;module.exports=gt;
|
|
1106
1528
|
|
|
@@ -1108,13 +1530,13 @@ const compare=require("./compare"),gt=(e,o,r)=>compare(e,o,r)>0;module.exports=g
|
|
|
1108
1530
|
};
|
|
1109
1531
|
}
|
|
1110
1532
|
}
|
|
1111
|
-
}, {package:"
|
|
1112
|
-
[
|
|
1533
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/gt.js",}],
|
|
1534
|
+
[108, {"./compare":104}, function(){
|
|
1113
1535
|
with (this.scopeTerminator) {
|
|
1114
1536
|
with (this.globalThis) {
|
|
1115
1537
|
return function() {
|
|
1116
1538
|
'use strict';
|
|
1117
|
-
// source: /home/runner/work/snaps
|
|
1539
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/gte.js
|
|
1118
1540
|
return function (require, module, exports) {
|
|
1119
1541
|
const compare=require("./compare"),gte=(e,o,r)=>compare(e,o,r)>=0;module.exports=gte;
|
|
1120
1542
|
|
|
@@ -1122,27 +1544,27 @@ const compare=require("./compare"),gte=(e,o,r)=>compare(e,o,r)>=0;module.exports
|
|
|
1122
1544
|
};
|
|
1123
1545
|
}
|
|
1124
1546
|
}
|
|
1125
|
-
}, {package:"
|
|
1126
|
-
[
|
|
1547
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/gte.js",}],
|
|
1548
|
+
[109, {"../classes/semver":98}, function(){
|
|
1127
1549
|
with (this.scopeTerminator) {
|
|
1128
1550
|
with (this.globalThis) {
|
|
1129
1551
|
return function() {
|
|
1130
1552
|
'use strict';
|
|
1131
|
-
// source: /home/runner/work/snaps
|
|
1553
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/inc.js
|
|
1132
1554
|
return function (require, module, exports) {
|
|
1133
|
-
const SemVer=require("../classes/semver"),inc=(e,r,n,s)=>{"string"==typeof n&&(s=n,n=void 0);try{return new SemVer(e instanceof SemVer?e.version:e,n).inc(r,s).version}catch(e){return null}};module.exports=inc;
|
|
1555
|
+
const SemVer=require("../classes/semver"),inc=(e,r,n,s,i)=>{"string"==typeof n&&(i=s,s=n,n=void 0);try{return new SemVer(e instanceof SemVer?e.version:e,n).inc(r,s,i).version}catch(e){return null}};module.exports=inc;
|
|
1134
1556
|
|
|
1135
1557
|
};
|
|
1136
1558
|
};
|
|
1137
1559
|
}
|
|
1138
1560
|
}
|
|
1139
|
-
}, {package:"
|
|
1140
|
-
[
|
|
1561
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/inc.js",}],
|
|
1562
|
+
[110, {"./compare":104}, function(){
|
|
1141
1563
|
with (this.scopeTerminator) {
|
|
1142
1564
|
with (this.globalThis) {
|
|
1143
1565
|
return function() {
|
|
1144
1566
|
'use strict';
|
|
1145
|
-
// source: /home/runner/work/snaps
|
|
1567
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/lt.js
|
|
1146
1568
|
return function (require, module, exports) {
|
|
1147
1569
|
const compare=require("./compare"),lt=(e,o,r)=>compare(e,o,r)<0;module.exports=lt;
|
|
1148
1570
|
|
|
@@ -1150,13 +1572,13 @@ const compare=require("./compare"),lt=(e,o,r)=>compare(e,o,r)<0;module.exports=l
|
|
|
1150
1572
|
};
|
|
1151
1573
|
}
|
|
1152
1574
|
}
|
|
1153
|
-
}, {package:"
|
|
1154
|
-
[
|
|
1575
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/lt.js",}],
|
|
1576
|
+
[111, {"./compare":104}, function(){
|
|
1155
1577
|
with (this.scopeTerminator) {
|
|
1156
1578
|
with (this.globalThis) {
|
|
1157
1579
|
return function() {
|
|
1158
1580
|
'use strict';
|
|
1159
|
-
// source: /home/runner/work/snaps
|
|
1581
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/lte.js
|
|
1160
1582
|
return function (require, module, exports) {
|
|
1161
1583
|
const compare=require("./compare"),lte=(e,o,r)=>compare(e,o,r)<=0;module.exports=lte;
|
|
1162
1584
|
|
|
@@ -1164,13 +1586,13 @@ const compare=require("./compare"),lte=(e,o,r)=>compare(e,o,r)<=0;module.exports
|
|
|
1164
1586
|
};
|
|
1165
1587
|
}
|
|
1166
1588
|
}
|
|
1167
|
-
}, {package:"
|
|
1168
|
-
[
|
|
1589
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/lte.js",}],
|
|
1590
|
+
[112, {"../classes/semver":98}, function(){
|
|
1169
1591
|
with (this.scopeTerminator) {
|
|
1170
1592
|
with (this.globalThis) {
|
|
1171
1593
|
return function() {
|
|
1172
1594
|
'use strict';
|
|
1173
|
-
// source: /home/runner/work/snaps
|
|
1595
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/major.js
|
|
1174
1596
|
return function (require, module, exports) {
|
|
1175
1597
|
const SemVer=require("../classes/semver"),major=(e,r)=>new SemVer(e,r).major;module.exports=major;
|
|
1176
1598
|
|
|
@@ -1178,13 +1600,13 @@ const SemVer=require("../classes/semver"),major=(e,r)=>new SemVer(e,r).major;mod
|
|
|
1178
1600
|
};
|
|
1179
1601
|
}
|
|
1180
1602
|
}
|
|
1181
|
-
}, {package:"
|
|
1182
|
-
[
|
|
1603
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/major.js",}],
|
|
1604
|
+
[113, {"../classes/semver":98}, function(){
|
|
1183
1605
|
with (this.scopeTerminator) {
|
|
1184
1606
|
with (this.globalThis) {
|
|
1185
1607
|
return function() {
|
|
1186
1608
|
'use strict';
|
|
1187
|
-
// source: /home/runner/work/snaps
|
|
1609
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/minor.js
|
|
1188
1610
|
return function (require, module, exports) {
|
|
1189
1611
|
const SemVer=require("../classes/semver"),minor=(e,r)=>new SemVer(e,r).minor;module.exports=minor;
|
|
1190
1612
|
|
|
@@ -1192,13 +1614,13 @@ const SemVer=require("../classes/semver"),minor=(e,r)=>new SemVer(e,r).minor;mod
|
|
|
1192
1614
|
};
|
|
1193
1615
|
}
|
|
1194
1616
|
}
|
|
1195
|
-
}, {package:"
|
|
1196
|
-
[
|
|
1617
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/minor.js",}],
|
|
1618
|
+
[114, {"./compare":104}, function(){
|
|
1197
1619
|
with (this.scopeTerminator) {
|
|
1198
1620
|
with (this.globalThis) {
|
|
1199
1621
|
return function() {
|
|
1200
1622
|
'use strict';
|
|
1201
|
-
// source: /home/runner/work/snaps
|
|
1623
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/neq.js
|
|
1202
1624
|
return function (require, module, exports) {
|
|
1203
1625
|
const compare=require("./compare"),neq=(e,o,r)=>0!==compare(e,o,r);module.exports=neq;
|
|
1204
1626
|
|
|
@@ -1206,27 +1628,27 @@ const compare=require("./compare"),neq=(e,o,r)=>0!==compare(e,o,r);module.export
|
|
|
1206
1628
|
};
|
|
1207
1629
|
}
|
|
1208
1630
|
}
|
|
1209
|
-
}, {package:"
|
|
1210
|
-
[
|
|
1631
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/neq.js",}],
|
|
1632
|
+
[115, {"../classes/semver":98}, function(){
|
|
1211
1633
|
with (this.scopeTerminator) {
|
|
1212
1634
|
with (this.globalThis) {
|
|
1213
1635
|
return function() {
|
|
1214
1636
|
'use strict';
|
|
1215
|
-
// source: /home/runner/work/snaps
|
|
1637
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/parse.js
|
|
1216
1638
|
return function (require, module, exports) {
|
|
1217
|
-
const
|
|
1639
|
+
const SemVer=require("../classes/semver"),parse=(e,r,s=!1)=>{if(e instanceof SemVer)return e;try{return new SemVer(e,r)}catch(e){if(!s)return null;throw e}};module.exports=parse;
|
|
1218
1640
|
|
|
1219
1641
|
};
|
|
1220
1642
|
};
|
|
1221
1643
|
}
|
|
1222
1644
|
}
|
|
1223
|
-
}, {package:"
|
|
1224
|
-
[
|
|
1645
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/parse.js",}],
|
|
1646
|
+
[116, {"../classes/semver":98}, function(){
|
|
1225
1647
|
with (this.scopeTerminator) {
|
|
1226
1648
|
with (this.globalThis) {
|
|
1227
1649
|
return function() {
|
|
1228
1650
|
'use strict';
|
|
1229
|
-
// source: /home/runner/work/snaps
|
|
1651
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/patch.js
|
|
1230
1652
|
return function (require, module, exports) {
|
|
1231
1653
|
const SemVer=require("../classes/semver"),patch=(e,r)=>new SemVer(e,r).patch;module.exports=patch;
|
|
1232
1654
|
|
|
@@ -1234,13 +1656,13 @@ const SemVer=require("../classes/semver"),patch=(e,r)=>new SemVer(e,r).patch;mod
|
|
|
1234
1656
|
};
|
|
1235
1657
|
}
|
|
1236
1658
|
}
|
|
1237
|
-
}, {package:"
|
|
1238
|
-
[
|
|
1659
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/patch.js",}],
|
|
1660
|
+
[117, {"./parse":115}, function(){
|
|
1239
1661
|
with (this.scopeTerminator) {
|
|
1240
1662
|
with (this.globalThis) {
|
|
1241
1663
|
return function() {
|
|
1242
1664
|
'use strict';
|
|
1243
|
-
// source: /home/runner/work/snaps
|
|
1665
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/prerelease.js
|
|
1244
1666
|
return function (require, module, exports) {
|
|
1245
1667
|
const parse=require("./parse"),prerelease=(e,r)=>{const s=parse(e,r);return s&&s.prerelease.length?s.prerelease:null};module.exports=prerelease;
|
|
1246
1668
|
|
|
@@ -1248,13 +1670,13 @@ const parse=require("./parse"),prerelease=(e,r)=>{const s=parse(e,r);return s&&s
|
|
|
1248
1670
|
};
|
|
1249
1671
|
}
|
|
1250
1672
|
}
|
|
1251
|
-
}, {package:"
|
|
1252
|
-
[
|
|
1673
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/prerelease.js",}],
|
|
1674
|
+
[118, {"./compare":104}, function(){
|
|
1253
1675
|
with (this.scopeTerminator) {
|
|
1254
1676
|
with (this.globalThis) {
|
|
1255
1677
|
return function() {
|
|
1256
1678
|
'use strict';
|
|
1257
|
-
// source: /home/runner/work/snaps
|
|
1679
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/rcompare.js
|
|
1258
1680
|
return function (require, module, exports) {
|
|
1259
1681
|
const compare=require("./compare"),rcompare=(r,e,o)=>compare(e,r,o);module.exports=rcompare;
|
|
1260
1682
|
|
|
@@ -1262,13 +1684,13 @@ const compare=require("./compare"),rcompare=(r,e,o)=>compare(e,r,o);module.expor
|
|
|
1262
1684
|
};
|
|
1263
1685
|
}
|
|
1264
1686
|
}
|
|
1265
|
-
}, {package:"
|
|
1266
|
-
[
|
|
1687
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/rcompare.js",}],
|
|
1688
|
+
[119, {"./compare-build":102}, function(){
|
|
1267
1689
|
with (this.scopeTerminator) {
|
|
1268
1690
|
with (this.globalThis) {
|
|
1269
1691
|
return function() {
|
|
1270
1692
|
'use strict';
|
|
1271
|
-
// source: /home/runner/work/snaps
|
|
1693
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/rsort.js
|
|
1272
1694
|
return function (require, module, exports) {
|
|
1273
1695
|
const compareBuild=require("./compare-build"),rsort=(r,o)=>r.sort(((r,e)=>compareBuild(e,r,o)));module.exports=rsort;
|
|
1274
1696
|
|
|
@@ -1276,13 +1698,13 @@ const compareBuild=require("./compare-build"),rsort=(r,o)=>r.sort(((r,e)=>compar
|
|
|
1276
1698
|
};
|
|
1277
1699
|
}
|
|
1278
1700
|
}
|
|
1279
|
-
}, {package:"
|
|
1280
|
-
[
|
|
1701
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/rsort.js",}],
|
|
1702
|
+
[120, {"../classes/range":97}, function(){
|
|
1281
1703
|
with (this.scopeTerminator) {
|
|
1282
1704
|
with (this.globalThis) {
|
|
1283
1705
|
return function() {
|
|
1284
1706
|
'use strict';
|
|
1285
|
-
// source: /home/runner/work/snaps
|
|
1707
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/satisfies.js
|
|
1286
1708
|
return function (require, module, exports) {
|
|
1287
1709
|
const Range=require("../classes/range"),satisfies=(e,s,t)=>{try{s=new Range(s,t)}catch(e){return!1}return s.test(e)};module.exports=satisfies;
|
|
1288
1710
|
|
|
@@ -1290,13 +1712,13 @@ const Range=require("../classes/range"),satisfies=(e,s,t)=>{try{s=new Range(s,t)
|
|
|
1290
1712
|
};
|
|
1291
1713
|
}
|
|
1292
1714
|
}
|
|
1293
|
-
}, {package:"
|
|
1294
|
-
[
|
|
1715
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/satisfies.js",}],
|
|
1716
|
+
[121, {"./compare-build":102}, function(){
|
|
1295
1717
|
with (this.scopeTerminator) {
|
|
1296
1718
|
with (this.globalThis) {
|
|
1297
1719
|
return function() {
|
|
1298
1720
|
'use strict';
|
|
1299
|
-
// source: /home/runner/work/snaps
|
|
1721
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/sort.js
|
|
1300
1722
|
return function (require, module, exports) {
|
|
1301
1723
|
const compareBuild=require("./compare-build"),sort=(o,r)=>o.sort(((o,e)=>compareBuild(o,e,r)));module.exports=sort;
|
|
1302
1724
|
|
|
@@ -1304,13 +1726,13 @@ const compareBuild=require("./compare-build"),sort=(o,r)=>o.sort(((o,e)=>compare
|
|
|
1304
1726
|
};
|
|
1305
1727
|
}
|
|
1306
1728
|
}
|
|
1307
|
-
}, {package:"
|
|
1308
|
-
[
|
|
1729
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/sort.js",}],
|
|
1730
|
+
[122, {"./parse":115}, function(){
|
|
1309
1731
|
with (this.scopeTerminator) {
|
|
1310
1732
|
with (this.globalThis) {
|
|
1311
1733
|
return function() {
|
|
1312
1734
|
'use strict';
|
|
1313
|
-
// source: /home/runner/work/snaps
|
|
1735
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/functions/valid.js
|
|
1314
1736
|
return function (require, module, exports) {
|
|
1315
1737
|
const parse=require("./parse"),valid=(e,r)=>{const s=parse(e,r);return s?s.version:null};module.exports=valid;
|
|
1316
1738
|
|
|
@@ -1318,41 +1740,41 @@ const parse=require("./parse"),valid=(e,r)=>{const s=parse(e,r);return s?s.versi
|
|
|
1318
1740
|
};
|
|
1319
1741
|
}
|
|
1320
1742
|
}
|
|
1321
|
-
}, {package:"
|
|
1322
|
-
[
|
|
1743
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/functions/valid.js",}],
|
|
1744
|
+
[123, {"./classes/comparator":96,"./classes/range":97,"./classes/semver":98,"./functions/clean":99,"./functions/cmp":100,"./functions/coerce":101,"./functions/compare":104,"./functions/compare-build":102,"./functions/compare-loose":103,"./functions/diff":105,"./functions/eq":106,"./functions/gt":107,"./functions/gte":108,"./functions/inc":109,"./functions/lt":110,"./functions/lte":111,"./functions/major":112,"./functions/minor":113,"./functions/neq":114,"./functions/parse":115,"./functions/patch":116,"./functions/prerelease":117,"./functions/rcompare":118,"./functions/rsort":119,"./functions/satisfies":120,"./functions/sort":121,"./functions/valid":122,"./internal/constants":124,"./internal/identifiers":126,"./internal/re":128,"./ranges/gtr":130,"./ranges/intersects":131,"./ranges/ltr":132,"./ranges/max-satisfying":133,"./ranges/min-satisfying":134,"./ranges/min-version":135,"./ranges/outside":136,"./ranges/simplify":137,"./ranges/subset":138,"./ranges/to-comparators":139,"./ranges/valid":140}, function(){
|
|
1323
1745
|
with (this.scopeTerminator) {
|
|
1324
1746
|
with (this.globalThis) {
|
|
1325
1747
|
return function() {
|
|
1326
1748
|
'use strict';
|
|
1327
|
-
// source: /home/runner/work/snaps
|
|
1749
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/index.js
|
|
1328
1750
|
return function (require, module, exports) {
|
|
1329
|
-
const internalRe=require("./internal/re"),constants=require("./internal/constants"),SemVer=require("./classes/semver"),identifiers=require("./internal/identifiers"),parse=require("./functions/parse"),valid=require("./functions/valid"),clean=require("./functions/clean"),inc=require("./functions/inc"),diff=require("./functions/diff"),major=require("./functions/major"),minor=require("./functions/minor"),patch=require("./functions/patch"),prerelease=require("./functions/prerelease"),compare=require("./functions/compare"),rcompare=require("./functions/rcompare"),compareLoose=require("./functions/compare-loose"),compareBuild=require("./functions/compare-build"),sort=require("./functions/sort"),rsort=require("./functions/rsort"),gt=require("./functions/gt"),lt=require("./functions/lt"),eq=require("./functions/eq"),neq=require("./functions/neq"),gte=require("./functions/gte"),lte=require("./functions/lte"),cmp=require("./functions/cmp"),coerce=require("./functions/coerce"),Comparator=require("./classes/comparator"),Range=require("./classes/range"),satisfies=require("./functions/satisfies"),toComparators=require("./ranges/to-comparators"),maxSatisfying=require("./ranges/max-satisfying"),minSatisfying=require("./ranges/min-satisfying"),minVersion=require("./ranges/min-version"),validRange=require("./ranges/valid"),outside=require("./ranges/outside"),gtr=require("./ranges/gtr"),ltr=require("./ranges/ltr"),intersects=require("./ranges/intersects"),simplifyRange=require("./ranges/simplify"),subset=require("./ranges/subset");module.exports={/* common-shake removed: parse:parse */valid:valid,/* common-shake removed: clean:clean *//* common-shake removed: inc:inc *//* common-shake removed: diff:diff *//* common-shake removed: major:major *//* common-shake removed: minor:minor *//* common-shake removed: patch:patch *//* common-shake removed: prerelease:prerelease *//* common-shake removed: compare:compare *//* common-shake removed: rcompare:rcompare *//* common-shake removed: compareLoose:compareLoose *//* common-shake removed: compareBuild:compareBuild *//* common-shake removed: sort:sort *//* common-shake removed: rsort:rsort */gt:gt,/* common-shake removed: lt:lt *//* common-shake removed: eq:eq *//* common-shake removed: neq:neq *//* common-shake removed: gte:gte *//* common-shake removed: lte:lte *//* common-shake removed: cmp:cmp *//* common-shake removed: coerce:coerce *//* common-shake removed: Comparator:Comparator *//* common-shake removed: Range:Range */satisfies:satisfies,/* common-shake removed: toComparators:toComparators */maxSatisfying:maxSatisfying,/* common-shake removed: minSatisfying:minSatisfying *//* common-shake removed: minVersion:minVersion */validRange:validRange,/* common-shake removed: outside:outside */gtr:gtr,/* common-shake removed: ltr:ltr *//* common-shake removed: intersects:intersects *//* common-shake removed: simplifyRange:simplifyRange *//* common-shake removed: subset:subset *//* common-shake removed: SemVer:SemVer *//* common-shake removed: re:internalRe.re *//* common-shake removed: src:internalRe.src *//* common-shake removed: tokens:internalRe.t *//* common-shake removed: SEMVER_SPEC_VERSION:constants.SEMVER_SPEC_VERSION *//* common-shake removed: compareIdentifiers:identifiers.compareIdentifiers *//* common-shake removed: rcompareIdentifiers:identifiers.rcompareIdentifiers */};
|
|
1751
|
+
const internalRe=require("./internal/re"),constants=require("./internal/constants"),SemVer=require("./classes/semver"),identifiers=require("./internal/identifiers"),parse=require("./functions/parse"),valid=require("./functions/valid"),clean=require("./functions/clean"),inc=require("./functions/inc"),diff=require("./functions/diff"),major=require("./functions/major"),minor=require("./functions/minor"),patch=require("./functions/patch"),prerelease=require("./functions/prerelease"),compare=require("./functions/compare"),rcompare=require("./functions/rcompare"),compareLoose=require("./functions/compare-loose"),compareBuild=require("./functions/compare-build"),sort=require("./functions/sort"),rsort=require("./functions/rsort"),gt=require("./functions/gt"),lt=require("./functions/lt"),eq=require("./functions/eq"),neq=require("./functions/neq"),gte=require("./functions/gte"),lte=require("./functions/lte"),cmp=require("./functions/cmp"),coerce=require("./functions/coerce"),Comparator=require("./classes/comparator"),Range=require("./classes/range"),satisfies=require("./functions/satisfies"),toComparators=require("./ranges/to-comparators"),maxSatisfying=require("./ranges/max-satisfying"),minSatisfying=require("./ranges/min-satisfying"),minVersion=require("./ranges/min-version"),validRange=require("./ranges/valid"),outside=require("./ranges/outside"),gtr=require("./ranges/gtr"),ltr=require("./ranges/ltr"),intersects=require("./ranges/intersects"),simplifyRange=require("./ranges/simplify"),subset=require("./ranges/subset");module.exports={/* common-shake removed: parse:parse */valid:valid,/* common-shake removed: clean:clean *//* common-shake removed: inc:inc *//* common-shake removed: diff:diff *//* common-shake removed: major:major *//* common-shake removed: minor:minor *//* common-shake removed: patch:patch *//* common-shake removed: prerelease:prerelease *//* common-shake removed: compare:compare *//* common-shake removed: rcompare:rcompare *//* common-shake removed: compareLoose:compareLoose *//* common-shake removed: compareBuild:compareBuild *//* common-shake removed: sort:sort *//* common-shake removed: rsort:rsort */gt:gt,/* common-shake removed: lt:lt *//* common-shake removed: eq:eq *//* common-shake removed: neq:neq *//* common-shake removed: gte:gte *//* common-shake removed: lte:lte *//* common-shake removed: cmp:cmp *//* common-shake removed: coerce:coerce *//* common-shake removed: Comparator:Comparator *//* common-shake removed: Range:Range */satisfies:satisfies,/* common-shake removed: toComparators:toComparators */maxSatisfying:maxSatisfying,/* common-shake removed: minSatisfying:minSatisfying *//* common-shake removed: minVersion:minVersion */validRange:validRange,/* common-shake removed: outside:outside */gtr:gtr,/* common-shake removed: ltr:ltr *//* common-shake removed: intersects:intersects *//* common-shake removed: simplifyRange:simplifyRange *//* common-shake removed: subset:subset *//* common-shake removed: SemVer:SemVer *//* common-shake removed: re:internalRe.re *//* common-shake removed: src:internalRe.src *//* common-shake removed: tokens:internalRe.t *//* common-shake removed: SEMVER_SPEC_VERSION:constants.SEMVER_SPEC_VERSION *//* common-shake removed: RELEASE_TYPES:constants.RELEASE_TYPES *//* common-shake removed: compareIdentifiers:identifiers.compareIdentifiers *//* common-shake removed: rcompareIdentifiers:identifiers.rcompareIdentifiers */};
|
|
1330
1752
|
|
|
1331
1753
|
};
|
|
1332
1754
|
};
|
|
1333
1755
|
}
|
|
1334
1756
|
}
|
|
1335
|
-
}, {package:"
|
|
1336
|
-
[
|
|
1757
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/index.js",}],
|
|
1758
|
+
[124, {}, function(){
|
|
1337
1759
|
with (this.scopeTerminator) {
|
|
1338
1760
|
with (this.globalThis) {
|
|
1339
1761
|
return function() {
|
|
1340
1762
|
'use strict';
|
|
1341
|
-
// source: /home/runner/work/snaps
|
|
1763
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/internal/constants.js
|
|
1342
1764
|
return function (require, module, exports) {
|
|
1343
|
-
const SEMVER_SPEC_VERSION="2.0.0",MAX_LENGTH=256,MAX_SAFE_INTEGER=Number.MAX_SAFE_INTEGER||9007199254740991,MAX_SAFE_COMPONENT_LENGTH=16;module.exports={
|
|
1765
|
+
const SEMVER_SPEC_VERSION="2.0.0",MAX_LENGTH=256,MAX_SAFE_INTEGER=Number.MAX_SAFE_INTEGER||9007199254740991,MAX_SAFE_COMPONENT_LENGTH=16,RELEASE_TYPES=["major","premajor","minor","preminor","patch","prepatch","prerelease"];module.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:16,MAX_SAFE_INTEGER:MAX_SAFE_INTEGER,/* common-shake removed: RELEASE_TYPES:RELEASE_TYPES *//* common-shake removed: SEMVER_SPEC_VERSION:"2.0.0" */FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2};
|
|
1344
1766
|
|
|
1345
1767
|
};
|
|
1346
1768
|
};
|
|
1347
1769
|
}
|
|
1348
1770
|
}
|
|
1349
|
-
}, {package:"
|
|
1350
|
-
[
|
|
1771
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/internal/constants.js",}],
|
|
1772
|
+
[125, {"_process":94}, function(){
|
|
1351
1773
|
with (this.scopeTerminator) {
|
|
1352
1774
|
with (this.globalThis) {
|
|
1353
1775
|
return function() {
|
|
1354
1776
|
'use strict';
|
|
1355
|
-
// source: /home/runner/work/snaps
|
|
1777
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/internal/debug.js
|
|
1356
1778
|
return function (require, module, exports) {
|
|
1357
1779
|
(function (process){(function (){
|
|
1358
1780
|
const debug="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?(...e)=>console.error("SEMVER",...e):()=>{};module.exports=debug;
|
|
@@ -1362,13 +1784,13 @@ const debug="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bse
|
|
|
1362
1784
|
};
|
|
1363
1785
|
}
|
|
1364
1786
|
}
|
|
1365
|
-
}, {package:"
|
|
1366
|
-
[
|
|
1787
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/internal/debug.js",}],
|
|
1788
|
+
[126, {}, function(){
|
|
1367
1789
|
with (this.scopeTerminator) {
|
|
1368
1790
|
with (this.globalThis) {
|
|
1369
1791
|
return function() {
|
|
1370
1792
|
'use strict';
|
|
1371
|
-
// source: /home/runner/work/snaps
|
|
1793
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/internal/identifiers.js
|
|
1372
1794
|
return function (require, module, exports) {
|
|
1373
1795
|
const numeric=/^[0-9]+$/,compareIdentifiers=(e,r)=>{const i=numeric.test(e),t=numeric.test(r);return i&&t&&(e=+e,r=+r),e===r?0:i&&!t?-1:t&&!i?1:e<r?-1:1},rcompareIdentifiers=(e,r)=>compareIdentifiers(r,e);module.exports={compareIdentifiers:compareIdentifiers,/* common-shake removed: rcompareIdentifiers:rcompareIdentifiers */};
|
|
1374
1796
|
|
|
@@ -1376,27 +1798,27 @@ const numeric=/^[0-9]+$/,compareIdentifiers=(e,r)=>{const i=numeric.test(e),t=nu
|
|
|
1376
1798
|
};
|
|
1377
1799
|
}
|
|
1378
1800
|
}
|
|
1379
|
-
}, {package:"
|
|
1380
|
-
[
|
|
1801
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/internal/identifiers.js",}],
|
|
1802
|
+
[127, {}, function(){
|
|
1381
1803
|
with (this.scopeTerminator) {
|
|
1382
1804
|
with (this.globalThis) {
|
|
1383
1805
|
return function() {
|
|
1384
1806
|
'use strict';
|
|
1385
|
-
// source: /home/runner/work/snaps
|
|
1807
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/internal/parse-options.js
|
|
1386
1808
|
return function (require, module, exports) {
|
|
1387
|
-
const
|
|
1809
|
+
const looseOption=Object.freeze({loose:!0}),emptyOpts=Object.freeze({}),parseOptions=e=>e?"object"!=typeof e?looseOption:e:emptyOpts;module.exports=parseOptions;
|
|
1388
1810
|
|
|
1389
1811
|
};
|
|
1390
1812
|
};
|
|
1391
1813
|
}
|
|
1392
1814
|
}
|
|
1393
|
-
}, {package:"
|
|
1394
|
-
[
|
|
1815
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/internal/parse-options.js",}],
|
|
1816
|
+
[128, {"./constants":124,"./debug":125}, function(){
|
|
1395
1817
|
with (this.scopeTerminator) {
|
|
1396
1818
|
with (this.globalThis) {
|
|
1397
1819
|
return function() {
|
|
1398
1820
|
'use strict';
|
|
1399
|
-
// source: /home/runner/work/snaps
|
|
1821
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/internal/re.js
|
|
1400
1822
|
return function (require, module, exports) {
|
|
1401
1823
|
const{MAX_SAFE_COMPONENT_LENGTH:MAX_SAFE_COMPONENT_LENGTH}=require("./constants"),debug=require("./debug");exports=module.exports={};const re=exports.re=[],src=exports.src=[],t=exports.t={};let R=0;const createToken=(E,I,e)=>{const N=R++;debug(E,N,I),t[E]=N,src[N]=I,re[N]=new RegExp(I,e?"g":void 0)};createToken("NUMERICIDENTIFIER","0|[1-9]\\d*"),createToken("NUMERICIDENTIFIERLOOSE","[0-9]+"),createToken("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*"),createToken("MAINVERSION",`(${src[t.NUMERICIDENTIFIER]})\\.(${src[t.NUMERICIDENTIFIER]})\\.(${src[t.NUMERICIDENTIFIER]})`),createToken("MAINVERSIONLOOSE",`(${src[t.NUMERICIDENTIFIERLOOSE]})\\.(${src[t.NUMERICIDENTIFIERLOOSE]})\\.(${src[t.NUMERICIDENTIFIERLOOSE]})`),createToken("PRERELEASEIDENTIFIER",`(?:${src[t.NUMERICIDENTIFIER]}|${src[t.NONNUMERICIDENTIFIER]})`),createToken("PRERELEASEIDENTIFIERLOOSE",`(?:${src[t.NUMERICIDENTIFIERLOOSE]}|${src[t.NONNUMERICIDENTIFIER]})`),createToken("PRERELEASE",`(?:-(${src[t.PRERELEASEIDENTIFIER]}(?:\\.${src[t.PRERELEASEIDENTIFIER]})*))`),createToken("PRERELEASELOOSE",`(?:-?(${src[t.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${src[t.PRERELEASEIDENTIFIERLOOSE]})*))`),createToken("BUILDIDENTIFIER","[0-9A-Za-z-]+"),createToken("BUILD",`(?:\\+(${src[t.BUILDIDENTIFIER]}(?:\\.${src[t.BUILDIDENTIFIER]})*))`),createToken("FULLPLAIN",`v?${src[t.MAINVERSION]}${src[t.PRERELEASE]}?${src[t.BUILD]}?`),createToken("FULL",`^${src[t.FULLPLAIN]}$`),createToken("LOOSEPLAIN",`[v=\\s]*${src[t.MAINVERSIONLOOSE]}${src[t.PRERELEASELOOSE]}?${src[t.BUILD]}?`),createToken("LOOSE",`^${src[t.LOOSEPLAIN]}$`),createToken("GTLT","((?:<|>)?=?)"),createToken("XRANGEIDENTIFIERLOOSE",`${src[t.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),createToken("XRANGEIDENTIFIER",`${src[t.NUMERICIDENTIFIER]}|x|X|\\*`),createToken("XRANGEPLAIN",`[v=\\s]*(${src[t.XRANGEIDENTIFIER]})(?:\\.(${src[t.XRANGEIDENTIFIER]})(?:\\.(${src[t.XRANGEIDENTIFIER]})(?:${src[t.PRERELEASE]})?${src[t.BUILD]}?)?)?`),createToken("XRANGEPLAINLOOSE",`[v=\\s]*(${src[t.XRANGEIDENTIFIERLOOSE]})(?:\\.(${src[t.XRANGEIDENTIFIERLOOSE]})(?:\\.(${src[t.XRANGEIDENTIFIERLOOSE]})(?:${src[t.PRERELEASELOOSE]})?${src[t.BUILD]}?)?)?`),createToken("XRANGE",`^${src[t.GTLT]}\\s*${src[t.XRANGEPLAIN]}$`),createToken("XRANGELOOSE",`^${src[t.GTLT]}\\s*${src[t.XRANGEPLAINLOOSE]}$`),createToken("COERCE",`(^|[^\\d])(\\d{1,${MAX_SAFE_COMPONENT_LENGTH}})(?:\\.(\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?(?:\\.(\\d{1,${MAX_SAFE_COMPONENT_LENGTH}}))?(?:$|[^\\d])`),createToken("COERCERTL",src[t.COERCE],!0),createToken("LONETILDE","(?:~>?)"),createToken("TILDETRIM",`(\\s*)${src[t.LONETILDE]}\\s+`,!0),exports.tildeTrimReplace="$1~",createToken("TILDE",`^${src[t.LONETILDE]}${src[t.XRANGEPLAIN]}$`),createToken("TILDELOOSE",`^${src[t.LONETILDE]}${src[t.XRANGEPLAINLOOSE]}$`),createToken("LONECARET","(?:\\^)"),createToken("CARETTRIM",`(\\s*)${src[t.LONECARET]}\\s+`,!0),exports.caretTrimReplace="$1^",createToken("CARET",`^${src[t.LONECARET]}${src[t.XRANGEPLAIN]}$`),createToken("CARETLOOSE",`^${src[t.LONECARET]}${src[t.XRANGEPLAINLOOSE]}$`),createToken("COMPARATORLOOSE",`^${src[t.GTLT]}\\s*(${src[t.LOOSEPLAIN]})$|^$`),createToken("COMPARATOR",`^${src[t.GTLT]}\\s*(${src[t.FULLPLAIN]})$|^$`),createToken("COMPARATORTRIM",`(\\s*)${src[t.GTLT]}\\s*(${src[t.LOOSEPLAIN]}|${src[t.XRANGEPLAIN]})`,!0),exports.comparatorTrimReplace="$1$2$3",createToken("HYPHENRANGE",`^\\s*(${src[t.XRANGEPLAIN]})\\s+-\\s+(${src[t.XRANGEPLAIN]})\\s*$`),createToken("HYPHENRANGELOOSE",`^\\s*(${src[t.XRANGEPLAINLOOSE]})\\s+-\\s+(${src[t.XRANGEPLAINLOOSE]})\\s*$`),createToken("STAR","(<|>)?=?\\s*\\*"),createToken("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),createToken("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$");
|
|
1402
1824
|
|
|
@@ -1404,13 +1826,13 @@ const{MAX_SAFE_COMPONENT_LENGTH:MAX_SAFE_COMPONENT_LENGTH}=require("./constants"
|
|
|
1404
1826
|
};
|
|
1405
1827
|
}
|
|
1406
1828
|
}
|
|
1407
|
-
}, {package:"
|
|
1408
|
-
[
|
|
1829
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/internal/re.js",}],
|
|
1830
|
+
[129, {"yallist":147}, function(){
|
|
1409
1831
|
with (this.scopeTerminator) {
|
|
1410
1832
|
with (this.globalThis) {
|
|
1411
1833
|
return function() {
|
|
1412
1834
|
'use strict';
|
|
1413
|
-
// source: /home/runner/work/snaps
|
|
1835
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/node_modules/lru-cache/index.js
|
|
1414
1836
|
return function (require, module, exports) {
|
|
1415
1837
|
"use strict";const Yallist=require("yallist"),MAX=Symbol("max"),LENGTH=Symbol("length"),LENGTH_CALCULATOR=Symbol("lengthCalculator"),ALLOW_STALE=Symbol("allowStale"),MAX_AGE=Symbol("maxAge"),DISPOSE=Symbol("dispose"),NO_DISPOSE_ON_SET=Symbol("noDisposeOnSet"),LRU_LIST=Symbol("lruList"),CACHE=Symbol("cache"),UPDATE_AGE_ON_GET=Symbol("updateAgeOnGet"),naiveLength=()=>1;class LRUCache{constructor(t){if("number"==typeof t&&(t={max:t}),t||(t={}),t.max&&("number"!=typeof t.max||t.max<0))throw new TypeError("max must be a non-negative number");this[MAX]=t.max||1/0;const e=t.length||naiveLength;if(this[LENGTH_CALCULATOR]="function"!=typeof e?naiveLength:e,this[ALLOW_STALE]=t.stale||!1,t.maxAge&&"number"!=typeof t.maxAge)throw new TypeError("maxAge must be a number");this[MAX_AGE]=t.maxAge||0,this[DISPOSE]=t.dispose,this[NO_DISPOSE_ON_SET]=t.noDisposeOnSet||!1,this[UPDATE_AGE_ON_GET]=t.updateAgeOnGet||!1,this.reset()}set max(t){if("number"!=typeof t||t<0)throw new TypeError("max must be a non-negative number");this[MAX]=t||1/0,trim(this)}get max(){return this[MAX]}set allowStale(t){this[ALLOW_STALE]=!!t}get allowStale(){return this[ALLOW_STALE]}set maxAge(t){if("number"!=typeof t)throw new TypeError("maxAge must be a non-negative number");this[MAX_AGE]=t,trim(this)}get maxAge(){return this[MAX_AGE]}set lengthCalculator(t){"function"!=typeof t&&(t=naiveLength),t!==this[LENGTH_CALCULATOR]&&(this[LENGTH_CALCULATOR]=t,this[LENGTH]=0,this[LRU_LIST].forEach((t=>{t.length=this[LENGTH_CALCULATOR](t.value,t.key),this[LENGTH]+=t.length}))),trim(this)}get lengthCalculator(){return this[LENGTH_CALCULATOR]}get length(){return this[LENGTH]}get itemCount(){return this[LRU_LIST].length}rforEach(t,e){e=e||this;for(let s=this[LRU_LIST].tail;null!==s;){const i=s.prev;forEachStep(this,t,s,e),s=i}}forEach(t,e){e=e||this;for(let s=this[LRU_LIST].head;null!==s;){const i=s.next;forEachStep(this,t,s,e),s=i}}keys(){return this[LRU_LIST].toArray().map((t=>t.key))}values(){return this[LRU_LIST].toArray().map((t=>t.value))}reset(){this[DISPOSE]&&this[LRU_LIST]&&this[LRU_LIST].length&&this[LRU_LIST].forEach((t=>this[DISPOSE](t.key,t.value))),this[CACHE]=new Map,this[LRU_LIST]=new Yallist,this[LENGTH]=0}dump(){return this[LRU_LIST].map((t=>!isStale(this,t)&&{k:t.key,v:t.value,e:t.now+(t.maxAge||0)})).toArray().filter((t=>t))}dumpLru(){return this[LRU_LIST]}set(t,e,s){if((s=s||this[MAX_AGE])&&"number"!=typeof s)throw new TypeError("maxAge must be a number");const i=s?Date.now():0,h=this[LENGTH_CALCULATOR](e,t);if(this[CACHE].has(t)){if(h>this[MAX])return del(this,this[CACHE].get(t)),!1;const n=this[CACHE].get(t).value;return this[DISPOSE]&&(this[NO_DISPOSE_ON_SET]||this[DISPOSE](t,n.value)),n.now=i,n.maxAge=s,n.value=e,this[LENGTH]+=h-n.length,n.length=h,this.get(t),trim(this),!0}const n=new Entry(t,e,h,i,s);return n.length>this[MAX]?(this[DISPOSE]&&this[DISPOSE](t,e),!1):(this[LENGTH]+=n.length,this[LRU_LIST].unshift(n),this[CACHE].set(t,this[LRU_LIST].head),trim(this),!0)}has(t){if(!this[CACHE].has(t))return!1;const e=this[CACHE].get(t).value;return!isStale(this,e)}get(t){return get(this,t,!0)}peek(t){return get(this,t,!1)}pop(){const t=this[LRU_LIST].tail;return t?(del(this,t),t.value):null}del(t){del(this,this[CACHE].get(t))}load(t){this.reset();const e=Date.now();for(let s=t.length-1;s>=0;s--){const i=t[s],h=i.e||0;if(0===h)this.set(i.k,i.v);else{const t=h-e;t>0&&this.set(i.k,i.v,t)}}}prune(){this[CACHE].forEach(((t,e)=>get(this,e,!1)))}}const get=(t,e,s)=>{const i=t[CACHE].get(e);if(i){const e=i.value;if(isStale(t,e)){if(del(t,i),!t[ALLOW_STALE])return}else s&&(t[UPDATE_AGE_ON_GET]&&(i.value.now=Date.now()),t[LRU_LIST].unshiftNode(i));return e.value}},isStale=(t,e)=>{if(!e||!e.maxAge&&!t[MAX_AGE])return!1;const s=Date.now()-e.now;return e.maxAge?s>e.maxAge:t[MAX_AGE]&&s>t[MAX_AGE]},trim=t=>{if(t[LENGTH]>t[MAX])for(let e=t[LRU_LIST].tail;t[LENGTH]>t[MAX]&&null!==e;){const s=e.prev;del(t,e),e=s}},del=(t,e)=>{if(e){const s=e.value;t[DISPOSE]&&t[DISPOSE](s.key,s.value),t[LENGTH]-=s.length,t[CACHE].delete(s.key),t[LRU_LIST].removeNode(e)}};class Entry{constructor(t,e,s,i,h){this.key=t,this.value=e,this.length=s,this.now=i,this.maxAge=h||0}}const forEachStep=(t,e,s,i)=>{let h=s.value;isStale(t,h)&&(del(t,s),t[ALLOW_STALE]||(h=void 0)),h&&e.call(i,h.value,h.key,t)};module.exports=LRUCache;
|
|
1416
1838
|
|
|
@@ -1418,13 +1840,13 @@ const{MAX_SAFE_COMPONENT_LENGTH:MAX_SAFE_COMPONENT_LENGTH}=require("./constants"
|
|
|
1418
1840
|
};
|
|
1419
1841
|
}
|
|
1420
1842
|
}
|
|
1421
|
-
}, {package:"
|
|
1422
|
-
[
|
|
1843
|
+
}, {package:"@metamask/utils>semver>lru-cache",file:"../../node_modules/semver/node_modules/lru-cache/index.js",}],
|
|
1844
|
+
[130, {"./outside":136}, function(){
|
|
1423
1845
|
with (this.scopeTerminator) {
|
|
1424
1846
|
with (this.globalThis) {
|
|
1425
1847
|
return function() {
|
|
1426
1848
|
'use strict';
|
|
1427
|
-
// source: /home/runner/work/snaps
|
|
1849
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/gtr.js
|
|
1428
1850
|
return function (require, module, exports) {
|
|
1429
1851
|
const outside=require("./outside"),gtr=(e,t,o)=>outside(e,t,">",o);module.exports=gtr;
|
|
1430
1852
|
|
|
@@ -1432,27 +1854,27 @@ const outside=require("./outside"),gtr=(e,t,o)=>outside(e,t,">",o);module.export
|
|
|
1432
1854
|
};
|
|
1433
1855
|
}
|
|
1434
1856
|
}
|
|
1435
|
-
}, {package:"
|
|
1436
|
-
[
|
|
1857
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/gtr.js",}],
|
|
1858
|
+
[131, {"../classes/range":97}, function(){
|
|
1437
1859
|
with (this.scopeTerminator) {
|
|
1438
1860
|
with (this.globalThis) {
|
|
1439
1861
|
return function() {
|
|
1440
1862
|
'use strict';
|
|
1441
|
-
// source: /home/runner/work/snaps
|
|
1863
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/intersects.js
|
|
1442
1864
|
return function (require, module, exports) {
|
|
1443
|
-
const Range=require("../classes/range"),intersects=(e,s,n)=>(e=new Range(e,n),s=new Range(s,n),e.intersects(s));module.exports=intersects;
|
|
1865
|
+
const Range=require("../classes/range"),intersects=(e,s,n)=>(e=new Range(e,n),s=new Range(s,n),e.intersects(s,n));module.exports=intersects;
|
|
1444
1866
|
|
|
1445
1867
|
};
|
|
1446
1868
|
};
|
|
1447
1869
|
}
|
|
1448
1870
|
}
|
|
1449
|
-
}, {package:"
|
|
1450
|
-
[
|
|
1871
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/intersects.js",}],
|
|
1872
|
+
[132, {"./outside":136}, function(){
|
|
1451
1873
|
with (this.scopeTerminator) {
|
|
1452
1874
|
with (this.globalThis) {
|
|
1453
1875
|
return function() {
|
|
1454
1876
|
'use strict';
|
|
1455
|
-
// source: /home/runner/work/snaps
|
|
1877
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/ltr.js
|
|
1456
1878
|
return function (require, module, exports) {
|
|
1457
1879
|
const outside=require("./outside"),ltr=(e,t,o)=>outside(e,t,"<",o);module.exports=ltr;
|
|
1458
1880
|
|
|
@@ -1460,13 +1882,13 @@ const outside=require("./outside"),ltr=(e,t,o)=>outside(e,t,"<",o);module.export
|
|
|
1460
1882
|
};
|
|
1461
1883
|
}
|
|
1462
1884
|
}
|
|
1463
|
-
}, {package:"
|
|
1464
|
-
[
|
|
1885
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/ltr.js",}],
|
|
1886
|
+
[133, {"../classes/range":97,"../classes/semver":98}, function(){
|
|
1465
1887
|
with (this.scopeTerminator) {
|
|
1466
1888
|
with (this.globalThis) {
|
|
1467
1889
|
return function() {
|
|
1468
1890
|
'use strict';
|
|
1469
|
-
// source: /home/runner/work/snaps
|
|
1891
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/max-satisfying.js
|
|
1470
1892
|
return function (require, module, exports) {
|
|
1471
1893
|
const SemVer=require("../classes/semver"),Range=require("../classes/range"),maxSatisfying=(e,r,n)=>{let a=null,l=null,s=null;try{s=new Range(r,n)}catch(e){return null}return e.forEach((e=>{s.test(e)&&(a&&-1!==l.compare(e)||(a=e,l=new SemVer(a,n)))})),a};module.exports=maxSatisfying;
|
|
1472
1894
|
|
|
@@ -1474,13 +1896,13 @@ const SemVer=require("../classes/semver"),Range=require("../classes/range"),maxS
|
|
|
1474
1896
|
};
|
|
1475
1897
|
}
|
|
1476
1898
|
}
|
|
1477
|
-
}, {package:"
|
|
1478
|
-
[
|
|
1899
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/max-satisfying.js",}],
|
|
1900
|
+
[134, {"../classes/range":97,"../classes/semver":98}, function(){
|
|
1479
1901
|
with (this.scopeTerminator) {
|
|
1480
1902
|
with (this.globalThis) {
|
|
1481
1903
|
return function() {
|
|
1482
1904
|
'use strict';
|
|
1483
|
-
// source: /home/runner/work/snaps
|
|
1905
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/min-satisfying.js
|
|
1484
1906
|
return function (require, module, exports) {
|
|
1485
1907
|
const SemVer=require("../classes/semver"),Range=require("../classes/range"),minSatisfying=(e,n,r)=>{let l=null,s=null,t=null;try{t=new Range(n,r)}catch(e){return null}return e.forEach((e=>{t.test(e)&&(l&&1!==s.compare(e)||(l=e,s=new SemVer(l,r)))})),l};module.exports=minSatisfying;
|
|
1486
1908
|
|
|
@@ -1488,13 +1910,13 @@ const SemVer=require("../classes/semver"),Range=require("../classes/range"),minS
|
|
|
1488
1910
|
};
|
|
1489
1911
|
}
|
|
1490
1912
|
}
|
|
1491
|
-
}, {package:"
|
|
1492
|
-
[
|
|
1913
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/min-satisfying.js",}],
|
|
1914
|
+
[135, {"../classes/range":97,"../classes/semver":98,"../functions/gt":107}, function(){
|
|
1493
1915
|
with (this.scopeTerminator) {
|
|
1494
1916
|
with (this.globalThis) {
|
|
1495
1917
|
return function() {
|
|
1496
1918
|
'use strict';
|
|
1497
|
-
// source: /home/runner/work/snaps
|
|
1919
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/min-version.js
|
|
1498
1920
|
return function (require, module, exports) {
|
|
1499
1921
|
const SemVer=require("../classes/semver"),Range=require("../classes/range"),gt=require("../functions/gt"),minVersion=(e,r)=>{e=new Range(e,r);let t=new SemVer("0.0.0");if(e.test(t))return t;if(t=new SemVer("0.0.0-0"),e.test(t))return t;t=null;for(let r=0;r<e.set.length;++r){const s=e.set[r];let n=null;s.forEach((e=>{const r=new SemVer(e.semver.version);switch(e.operator){case">":0===r.prerelease.length?r.patch++:r.prerelease.push(0),r.raw=r.format();case"":case">=":n&&!gt(r,n)||(n=r);break;case"<":case"<=":break;default:throw new Error(`Unexpected operation: ${e.operator}`)}})),!n||t&&!gt(t,n)||(t=n)}return t&&e.test(t)?t:null};module.exports=minVersion;
|
|
1500
1922
|
|
|
@@ -1502,13 +1924,13 @@ const SemVer=require("../classes/semver"),Range=require("../classes/range"),gt=r
|
|
|
1502
1924
|
};
|
|
1503
1925
|
}
|
|
1504
1926
|
}
|
|
1505
|
-
}, {package:"
|
|
1506
|
-
[
|
|
1927
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/min-version.js",}],
|
|
1928
|
+
[136, {"../classes/comparator":96,"../classes/range":97,"../classes/semver":98,"../functions/gt":107,"../functions/gte":108,"../functions/lt":110,"../functions/lte":111,"../functions/satisfies":120}, function(){
|
|
1507
1929
|
with (this.scopeTerminator) {
|
|
1508
1930
|
with (this.globalThis) {
|
|
1509
1931
|
return function() {
|
|
1510
1932
|
'use strict';
|
|
1511
|
-
// source: /home/runner/work/snaps
|
|
1933
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/outside.js
|
|
1512
1934
|
return function (require, module, exports) {
|
|
1513
1935
|
const SemVer=require("../classes/semver"),Comparator=require("../classes/comparator"),{ANY:ANY}=Comparator,Range=require("../classes/range"),satisfies=require("../functions/satisfies"),gt=require("../functions/gt"),lt=require("../functions/lt"),lte=require("../functions/lte"),gte=require("../functions/gte"),outside=(e,r,t,s)=>{let o,a,i,n,u;switch(e=new SemVer(e,s),r=new Range(r,s),t){case">":o=gt,a=lte,i=lt,n=">",u=">=";break;case"<":o=lt,a=gte,i=gt,n="<",u="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(satisfies(e,r,s))return!1;for(let t=0;t<r.set.length;++t){const l=r.set[t];let f=null,c=null;if(l.forEach((e=>{e.semver===ANY&&(e=new Comparator(">=0.0.0")),f=f||e,c=c||e,o(e.semver,f.semver,s)?f=e:i(e.semver,c.semver,s)&&(c=e)})),f.operator===n||f.operator===u)return!1;if((!c.operator||c.operator===n)&&a(e,c.semver))return!1;if(c.operator===u&&i(e,c.semver))return!1}return!0};module.exports=outside;
|
|
1514
1936
|
|
|
@@ -1516,13 +1938,13 @@ const SemVer=require("../classes/semver"),Comparator=require("../classes/compara
|
|
|
1516
1938
|
};
|
|
1517
1939
|
}
|
|
1518
1940
|
}
|
|
1519
|
-
}, {package:"
|
|
1520
|
-
[
|
|
1941
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/outside.js",}],
|
|
1942
|
+
[137, {"../functions/compare.js":104,"../functions/satisfies.js":120}, function(){
|
|
1521
1943
|
with (this.scopeTerminator) {
|
|
1522
1944
|
with (this.globalThis) {
|
|
1523
1945
|
return function() {
|
|
1524
1946
|
'use strict';
|
|
1525
|
-
// source: /home/runner/work/snaps
|
|
1947
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/simplify.js
|
|
1526
1948
|
return function (require, module, exports) {
|
|
1527
1949
|
const satisfies=require("../functions/satisfies.js"),compare=require("../functions/compare.js");module.exports=(s,n,o)=>{const t=[];let u=null,e=null;const r=s.sort(((s,n)=>compare(s,n,o)));for(const s of r){satisfies(s,n,o)?(e=s,u||(u=s)):(e&&t.push([u,e]),e=null,u=null)}u&&t.push([u,null]);const l=[];for(const[s,n]of t)s===n?l.push(s):n||s!==r[0]?n?s===r[0]?l.push(`<=${n}`):l.push(`${s} - ${n}`):l.push(`>=${s}`):l.push("*");const i=l.join(" || "),c="string"==typeof n.raw?n.raw:String(n);return i.length<c.length?i:n};
|
|
1528
1950
|
|
|
@@ -1530,27 +1952,27 @@ const satisfies=require("../functions/satisfies.js"),compare=require("../functio
|
|
|
1530
1952
|
};
|
|
1531
1953
|
}
|
|
1532
1954
|
}
|
|
1533
|
-
}, {package:"
|
|
1534
|
-
[
|
|
1955
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/simplify.js",}],
|
|
1956
|
+
[138, {"../classes/comparator.js":96,"../classes/range.js":97,"../functions/compare.js":104,"../functions/satisfies.js":120}, function(){
|
|
1535
1957
|
with (this.scopeTerminator) {
|
|
1536
1958
|
with (this.globalThis) {
|
|
1537
1959
|
return function() {
|
|
1538
1960
|
'use strict';
|
|
1539
|
-
// source: /home/runner/work/snaps
|
|
1961
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/subset.js
|
|
1540
1962
|
return function (require, module, exports) {
|
|
1541
|
-
const Range=require("../classes/range.js"),Comparator=require("../classes/comparator.js"),{ANY:ANY}=Comparator,satisfies=require("../functions/satisfies.js"),compare=require("../functions/compare.js"),subset=(e,r,o={})=>{if(e===r)return!0;e=new Range(e,o),r=new Range(r,o);let
|
|
1963
|
+
const Range=require("../classes/range.js"),Comparator=require("../classes/comparator.js"),{ANY:ANY}=Comparator,satisfies=require("../functions/satisfies.js"),compare=require("../functions/compare.js"),subset=(e,r,o={})=>{if(e===r)return!0;e=new Range(e,o),r=new Range(r,o);let s=!1;e:for(const t of e.set){for(const e of r.set){const r=simpleSubset(t,e,o);if(s=s||null!==r,r)continue e}if(s)return!1}return!0},minimumVersionWithPreRelease=[new Comparator(">=0.0.0-0")],minimumVersion=[new Comparator(">=0.0.0")],simpleSubset=(e,r,o)=>{if(e===r)return!0;if(1===e.length&&e[0].semver===ANY){if(1===r.length&&r[0].semver===ANY)return!0;e=o.includePrerelease?minimumVersionWithPreRelease:minimumVersion}if(1===r.length&&r[0].semver===ANY){if(o.includePrerelease)return!0;r=minimumVersion}const s=new Set;let t,n,i,a,m,l,u;for(const r of e)">"===r.operator||">="===r.operator?t=higherGT(t,r,o):"<"===r.operator||"<="===r.operator?n=lowerLT(n,r,o):s.add(r.semver);if(s.size>1)return null;if(t&&n){if(i=compare(t.semver,n.semver,o),i>0)return null;if(0===i&&(">="!==t.operator||"<="!==n.operator))return null}for(const e of s){if(t&&!satisfies(e,String(t),o))return null;if(n&&!satisfies(e,String(n),o))return null;for(const s of r)if(!satisfies(e,String(s),o))return!1;return!0}let f=!(!n||o.includePrerelease||!n.semver.prerelease.length)&&n.semver,p=!(!t||o.includePrerelease||!t.semver.prerelease.length)&&t.semver;f&&1===f.prerelease.length&&"<"===n.operator&&0===f.prerelease[0]&&(f=!1);for(const e of r){if(u=u||">"===e.operator||">="===e.operator,l=l||"<"===e.operator||"<="===e.operator,t)if(p&&e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===p.major&&e.semver.minor===p.minor&&e.semver.patch===p.patch&&(p=!1),">"===e.operator||">="===e.operator){if(a=higherGT(t,e,o),a===e&&a!==t)return!1}else if(">="===t.operator&&!satisfies(t.semver,String(e),o))return!1;if(n)if(f&&e.semver.prerelease&&e.semver.prerelease.length&&e.semver.major===f.major&&e.semver.minor===f.minor&&e.semver.patch===f.patch&&(f=!1),"<"===e.operator||"<="===e.operator){if(m=lowerLT(n,e,o),m===e&&m!==n)return!1}else if("<="===n.operator&&!satisfies(n.semver,String(e),o))return!1;if(!e.operator&&(n||t)&&0!==i)return!1}return!(t&&l&&!n&&0!==i)&&(!(n&&u&&!t&&0!==i)&&(!p&&!f))},higherGT=(e,r,o)=>{if(!e)return r;const s=compare(e.semver,r.semver,o);return s>0?e:s<0||">"===r.operator&&">="===e.operator?r:e},lowerLT=(e,r,o)=>{if(!e)return r;const s=compare(e.semver,r.semver,o);return s<0?e:s>0||"<"===r.operator&&"<="===e.operator?r:e};module.exports=subset;
|
|
1542
1964
|
|
|
1543
1965
|
};
|
|
1544
1966
|
};
|
|
1545
1967
|
}
|
|
1546
1968
|
}
|
|
1547
|
-
}, {package:"
|
|
1548
|
-
[
|
|
1969
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/subset.js",}],
|
|
1970
|
+
[139, {"../classes/range":97}, function(){
|
|
1549
1971
|
with (this.scopeTerminator) {
|
|
1550
1972
|
with (this.globalThis) {
|
|
1551
1973
|
return function() {
|
|
1552
1974
|
'use strict';
|
|
1553
|
-
// source: /home/runner/work/snaps
|
|
1975
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/to-comparators.js
|
|
1554
1976
|
return function (require, module, exports) {
|
|
1555
1977
|
const Range=require("../classes/range"),toComparators=(a,e)=>new Range(a,e).set.map((a=>a.map((a=>a.value)).join(" ").trim().split(" ")));module.exports=toComparators;
|
|
1556
1978
|
|
|
@@ -1558,13 +1980,13 @@ const Range=require("../classes/range"),toComparators=(a,e)=>new Range(a,e).set.
|
|
|
1558
1980
|
};
|
|
1559
1981
|
}
|
|
1560
1982
|
}
|
|
1561
|
-
}, {package:"
|
|
1562
|
-
[
|
|
1983
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/to-comparators.js",}],
|
|
1984
|
+
[140, {"../classes/range":97}, function(){
|
|
1563
1985
|
with (this.scopeTerminator) {
|
|
1564
1986
|
with (this.globalThis) {
|
|
1565
1987
|
return function() {
|
|
1566
1988
|
'use strict';
|
|
1567
|
-
// source: /home/runner/work/snaps
|
|
1989
|
+
// source: /home/runner/work/snaps/snaps/node_modules/semver/ranges/valid.js
|
|
1568
1990
|
return function (require, module, exports) {
|
|
1569
1991
|
const Range=require("../classes/range"),validRange=(e,n)=>{try{return new Range(e,n).range||"*"}catch(e){return null}};module.exports=validRange;
|
|
1570
1992
|
|
|
@@ -1572,13 +1994,27 @@ const Range=require("../classes/range"),validRange=(e,n)=>{try{return new Range(
|
|
|
1572
1994
|
};
|
|
1573
1995
|
}
|
|
1574
1996
|
}
|
|
1575
|
-
}, {package:"
|
|
1576
|
-
[
|
|
1997
|
+
}, {package:"@metamask/utils>semver",file:"../../node_modules/semver/ranges/valid.js",}],
|
|
1998
|
+
[141, {}, function(){
|
|
1999
|
+
with (this.scopeTerminator) {
|
|
2000
|
+
with (this.globalThis) {
|
|
2001
|
+
return function() {
|
|
2002
|
+
'use strict';
|
|
2003
|
+
// source: /home/runner/work/snaps/snaps/node_modules/strnum/strnum.js
|
|
2004
|
+
return function (require, module, exports) {
|
|
2005
|
+
const hexRegex=/^[-+]?0x[a-fA-F0-9]+$/,numRegex=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;!Number.parseInt&&window.parseInt&&(Number.parseInt=window.parseInt),!Number.parseFloat&&window.parseFloat&&(Number.parseFloat=window.parseFloat);const consider={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};function toNumber(e,t={}){if(t=Object.assign({},consider,t),!e||"string"!=typeof e)return e;let r=e.trim();if(void 0!==t.skipLike&&t.skipLike.test(r))return e;if(t.hex&&hexRegex.test(r))return Number.parseInt(r,16);{const n=numRegex.exec(r);if(n){const o=n[1],i=n[2];let s=trimZeros(n[3]);const a=n[4]||n[6];if(!t.leadingZeros&&i.length>0&&o&&"."!==r[2])return e;if(!t.leadingZeros&&i.length>0&&!o&&"."!==r[1])return e;{const n=Number(r),u=""+n;return-1!==u.search(/[eE]/)||a?t.eNotation?n:e:-1!==r.indexOf(".")?"0"===u&&""===s||u===s||o&&u==="-"+s?n:e:i?s===u||o+s===u?n:e:r===u||r===o+u?n:e}}return e}}function trimZeros(e){return e&&-1!==e.indexOf(".")?("."===(e=e.replace(/0+$/,""))?e="0":"."===e[0]?e="0"+e:"."===e[e.length-1]&&(e=e.substr(0,e.length-1)),e):e}module.exports=toNumber;
|
|
2006
|
+
|
|
2007
|
+
};
|
|
2008
|
+
};
|
|
2009
|
+
}
|
|
2010
|
+
}
|
|
2011
|
+
}, {package:"@metamask/snaps-utils>is-svg>fast-xml-parser>strnum",file:"../../node_modules/strnum/strnum.js",}],
|
|
2012
|
+
[142, {}, function(){
|
|
1577
2013
|
with (this.scopeTerminator) {
|
|
1578
2014
|
with (this.globalThis) {
|
|
1579
2015
|
return function() {
|
|
1580
2016
|
'use strict';
|
|
1581
|
-
// source: /home/runner/work/snaps
|
|
2017
|
+
// source: /home/runner/work/snaps/snaps/node_modules/superstruct/dist/index.cjs
|
|
1582
2018
|
return function (require, module, exports) {
|
|
1583
2019
|
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).Superstruct={})}(this,(function(e){"use strict";class t extends TypeError{constructor(e,t){let n;const{message:r,explanation:o,...i}=e,{path:c}=e,a=0===c.length?r:`At path: ${c.join(".")} -- ${r}`;super(o??a),null!=o&&(this.cause=a),Object.assign(this,i),this.name=this.constructor.name,this.failures=()=>n??(n=[e,...t()])}}function n(e){return"object"==typeof e&&null!=e}function r(e){if("[object Object]"!==Object.prototype.toString.call(e))return!1;const t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}function o(e){return"symbol"==typeof e?e.toString():"string"==typeof e?JSON.stringify(e):`${e}`}function i(e,t,n,r){if(!0===e)return;!1===e?e={}:"string"==typeof e&&(e={message:e});const{path:i,branch:c}=t,{type:a}=n,{refinement:s,message:u=`Expected a value of type \`${a}\`${s?` with refinement \`${s}\``:""}, but received: \`${o(r)}\``}=e;return{value:r,type:a,refinement:s,key:i[i.length-1],path:i,branch:c,...e,message:u}}function*c(e,t,r,o){var c;n(c=e)&&"function"==typeof c[Symbol.iterator]||(e=[e]);for(const n of e){const e=i(n,t,r,o);e&&(yield e)}}function*a(e,t,r={}){const{path:o=[],branch:i=[e],coerce:c=!1,mask:s=!1}=r,u={path:o,branch:i};if(c&&(e=t.coercer(e,u),s&&"type"!==t.type&&n(t.schema)&&n(e)&&!Array.isArray(e)))for(const n in e)void 0===t.schema[n]&&delete e[n];let f="valid";for(const n of t.validator(e,u))n.explanation=r.message,f="not_valid",yield[n,void 0];for(let[l,d,p]of t.entries(e,u)){const t=a(d,p,{path:void 0===l?o:[...o,l],branch:void 0===l?i:[...i,d],coerce:c,mask:s,message:r.message});for(const r of t)r[0]?(f=null!=r[0].refinement?"not_refined":"not_valid",yield[r[0],void 0]):c&&(d=r[1],void 0===l?e=d:e instanceof Map?e.set(l,d):e instanceof Set?e.add(d):n(e)&&(void 0!==d||l in e)&&(e[l]=d))}if("not_valid"!==f)for(const n of t.refiner(e,u))n.explanation=r.message,f="not_refined",yield[n,void 0];"valid"===f&&(yield[void 0,e])}class s{constructor(e){const{type:t,schema:n,validator:r,refiner:o,coercer:i=(e=>e),entries:a=function*(){}}=e;this.type=t,this.schema=n,this.entries=a,this.coercer=i,this.validator=r?(e,t)=>c(r(e,t),t,this,e):()=>[],this.refiner=o?(e,t)=>c(o(e,t),t,this,e):()=>[]}assert(e,t){return u(e,this,t)}create(e,t){return f(e,this,t)}is(e){return d(e,this)}mask(e,t){return l(e,this,t)}validate(e,t={}){return p(e,this,t)}}function u(e,t,n){const r=p(e,t,{message:n});if(r[0])throw r[0]}function f(e,t,n){const r=p(e,t,{coerce:!0,message:n});if(r[0])throw r[0];return r[1]}function l(e,t,n){const r=p(e,t,{coerce:!0,mask:!0,message:n});if(r[0])throw r[0];return r[1]}function d(e,t){return!p(e,t)[0]}function p(e,n,r={}){const o=a(e,n,r),i=function(e){const{done:t,value:n}=e.next();return t?void 0:n}(o);if(i[0]){return[new t(i[0],(function*(){for(const e of o)e[0]&&(yield e[0])})),void 0]}return[void 0,i[1]]}function y(e,t){return new s({type:e,schema:null,validator:t})}function v(){return y("never",(()=>!1))}function m(e){const t=e?Object.keys(e):[],r=v();return new s({type:"object",schema:e||null,*entries(o){if(e&&n(o)){const n=new Set(Object.keys(o));for(const r of t)n.delete(r),yield[r,o[r],e[r]];for(const e of n)yield[e,o[e],r]}},validator:e=>n(e)||`Expected an object, but received: ${o(e)}`,coercer:e=>n(e)?{...e}:e})}function h(e){return new s({...e,validator:(t,n)=>void 0===t||e.validator(t,n),refiner:(t,n)=>void 0===t||e.refiner(t,n)})}function b(){return y("string",(e=>"string"==typeof e||`Expected a string, but received: ${o(e)}`))}function $(e){const t=Object.keys(e);return new s({type:"type",schema:e,*entries(r){if(n(r))for(const n of t)yield[n,r[n],e[n]]},validator:e=>n(e)||`Expected an object, but received: ${o(e)}`,coercer:e=>n(e)?{...e}:e})}function g(){return y("unknown",(()=>!0))}function x(e,t,n){return new s({...e,coercer:(r,o)=>d(r,t)?e.coercer(n(r,o),o):e.coercer(r,o)})}function w(e){return e instanceof Map||e instanceof Set?e.size:e.length}function E(e,t,n){return new s({...e,*refiner(r,o){yield*e.refiner(r,o);const i=c(n(r,o),o,e,r);for(const e of i)yield{...e,refinement:t}}})}e.Struct=s,e.StructError=t,e.any=function(){return y("any",(()=>!0))},e.array=function(e){return new s({type:"array",schema:e,*entries(t){if(e&&Array.isArray(t))for(const[n,r]of t.entries())yield[n,r,e]},coercer:e=>Array.isArray(e)?e.slice():e,validator:e=>Array.isArray(e)||`Expected an array value, but received: ${o(e)}`})},e.assert=u,e.assign=function(...e){const t="type"===e[0].type,n=e.map((e=>e.schema)),r=Object.assign({},...n);return t?$(r):m(r)},e.bigint=function(){return y("bigint",(e=>"bigint"==typeof e))},e.boolean=function(){return y("boolean",(e=>"boolean"==typeof e))},e.coerce=x,e.create=f,e.date=function(){return y("date",(e=>e instanceof Date&&!isNaN(e.getTime())||`Expected a valid \`Date\` object, but received: ${o(e)}`))},e.defaulted=function(e,t,n={}){return x(e,g(),(e=>{const o="function"==typeof t?t():t;if(void 0===e)return o;if(!n.strict&&r(e)&&r(o)){const t={...e};let n=!1;for(const e in o)void 0===t[e]&&(t[e]=o[e],n=!0);if(n)return t}return e}))},e.define=y,e.deprecated=function(e,t){return new s({...e,refiner:(t,n)=>void 0===t||e.refiner(t,n),validator:(n,r)=>void 0===n||(t(n,r),e.validator(n,r))})},e.dynamic=function(e){return new s({type:"dynamic",schema:null,*entries(t,n){const r=e(t,n);yield*r.entries(t,n)},validator:(t,n)=>e(t,n).validator(t,n),coercer:(t,n)=>e(t,n).coercer(t,n),refiner:(t,n)=>e(t,n).refiner(t,n)})},e.empty=function(e){return E(e,"empty",(t=>{const n=w(t);return 0===n||`Expected an empty ${e.type} but received one with a size of \`${n}\``}))},e.enums=function(e){const t={},n=e.map((e=>o(e))).join();for(const n of e)t[n]=n;return new s({type:"enums",schema:t,validator:t=>e.includes(t)||`Expected one of \`${n}\`, but received: ${o(t)}`})},e.func=function(){return y("func",(e=>"function"==typeof e||`Expected a function, but received: ${o(e)}`))},e.instance=function(e){return y("instance",(t=>t instanceof e||`Expected a \`${e.name}\` instance, but received: ${o(t)}`))},e.integer=function(){return y("integer",(e=>"number"==typeof e&&!isNaN(e)&&Number.isInteger(e)||`Expected an integer, but received: ${o(e)}`))},e.intersection=function(e){return new s({type:"intersection",schema:null,*entries(t,n){for(const r of e)yield*r.entries(t,n)},*validator(t,n){for(const r of e)yield*r.validator(t,n)},*refiner(t,n){for(const r of e)yield*r.refiner(t,n)}})},e.is=d,e.lazy=function(e){let t;return new s({type:"lazy",schema:null,*entries(n,r){t??(t=e()),yield*t.entries(n,r)},validator:(n,r)=>(t??(t=e()),t.validator(n,r)),coercer:(n,r)=>(t??(t=e()),t.coercer(n,r)),refiner:(n,r)=>(t??(t=e()),t.refiner(n,r))})},e.literal=function(e){const t=o(e),n=typeof e;return new s({type:"literal",schema:"string"===n||"number"===n||"boolean"===n?e:null,validator:n=>n===e||`Expected the literal \`${t}\`, but received: ${o(n)}`})},e.map=function(e,t){return new s({type:"map",schema:null,*entries(n){if(e&&t&&n instanceof Map)for(const[r,o]of n.entries())yield[r,r,e],yield[r,o,t]},coercer:e=>e instanceof Map?new Map(e):e,validator:e=>e instanceof Map||`Expected a \`Map\` object, but received: ${o(e)}`})},e.mask=l,e.max=function(e,t,n={}){const{exclusive:r}=n;return E(e,"max",(n=>r?n<t:n<=t||`Expected a ${e.type} less than ${r?"":"or equal to "}${t} but received \`${n}\``))},e.min=function(e,t,n={}){const{exclusive:r}=n;return E(e,"min",(n=>r?n>t:n>=t||`Expected a ${e.type} greater than ${r?"":"or equal to "}${t} but received \`${n}\``))},e.never=v,e.nonempty=function(e){return E(e,"nonempty",(t=>w(t)>0||`Expected a nonempty ${e.type} but received an empty one`))},e.nullable=function(e){return new s({...e,validator:(t,n)=>null===t||e.validator(t,n),refiner:(t,n)=>null===t||e.refiner(t,n)})},e.number=function(){return y("number",(e=>"number"==typeof e&&!isNaN(e)||`Expected a number, but received: ${o(e)}`))},e.object=m,e.omit=function(e,t){const{schema:n}=e,r={...n};for(const e of t)delete r[e];return"type"===e.type?$(r):m(r)},e.optional=h,e.partial=function(e){const t=e instanceof s?{...e.schema}:{...e};for(const e in t)t[e]=h(t[e]);return m(t)},e.pattern=function(e,t){return E(e,"pattern",(n=>t.test(n)||`Expected a ${e.type} matching \`/${t.source}/\` but received "${n}"`))},e.pick=function(e,t){const{schema:n}=e,r={};for(const e of t)r[e]=n[e];return m(r)},e.record=function(e,t){return new s({type:"record",schema:null,*entries(r){if(n(r))for(const n in r){const o=r[n];yield[n,n,e],yield[n,o,t]}},validator:e=>n(e)||`Expected an object, but received: ${o(e)}`})},e.refine=E,e.regexp=function(){return y("regexp",(e=>e instanceof RegExp))},e.set=function(e){return new s({type:"set",schema:null,*entries(t){if(e&&t instanceof Set)for(const n of t)yield[n,n,e]},coercer:e=>e instanceof Set?new Set(e):e,validator:e=>e instanceof Set||`Expected a \`Set\` object, but received: ${o(e)}`})},e.size=function(e,t,n=t){const r=`Expected a ${e.type}`,o=t===n?`of \`${t}\``:`between \`${t}\` and \`${n}\``;return E(e,"size",(e=>{if("number"==typeof e||e instanceof Date)return t<=e&&e<=n||`${r} ${o} but received \`${e}\``;if(e instanceof Map||e instanceof Set){const{size:i}=e;return t<=i&&i<=n||`${r} with a size ${o} but received one with a size of \`${i}\``}{const{length:i}=e;return t<=i&&i<=n||`${r} with a length ${o} but received one with a length of \`${i}\``}}))},e.string=b,e.struct=function(e,t){return console.warn("superstruct@0.11 - The `struct` helper has been renamed to `define`."),y(e,t)},e.trimmed=function(e){return x(e,b(),(e=>e.trim()))},e.tuple=function(e){const t=v();return new s({type:"tuple",schema:null,*entries(n){if(Array.isArray(n)){const r=Math.max(e.length,n.length);for(let o=0;o<r;o++)yield[o,n[o],e[o]||t]}},validator:e=>Array.isArray(e)||`Expected an array, but received: ${o(e)}`})},e.type=$,e.union=function(e){const t=e.map((e=>e.type)).join(" | ");return new s({type:"union",schema:null,coercer(t){for(const n of e){const[e,r]=n.validate(t,{coerce:!0});if(!e)return r}return t},validator(n,r){const i=[];for(const t of e){const[...e]=a(n,t,r),[o]=e;if(!o[0])return[];for(const[t]of e)t&&i.push(t)}return[`Expected the value to satisfy a union of \`${t}\`, but received: ${o(n)}`,...i]}})},e.unknown=g,e.validate=p}));
|
|
1584
2020
|
|
|
@@ -1587,12 +2023,12 @@ const Range=require("../classes/range"),validRange=(e,n)=>{try{return new Range(
|
|
|
1587
2023
|
}
|
|
1588
2024
|
}
|
|
1589
2025
|
}, {package:"superstruct",file:"../../node_modules/superstruct/dist/index.cjs",}],
|
|
1590
|
-
[
|
|
2026
|
+
[143, {"process/browser.js":94,"timers":143}, function(){
|
|
1591
2027
|
with (this.scopeTerminator) {
|
|
1592
2028
|
with (this.globalThis) {
|
|
1593
2029
|
return function() {
|
|
1594
2030
|
'use strict';
|
|
1595
|
-
// source: /home/runner/work/snaps
|
|
2031
|
+
// source: /home/runner/work/snaps/snaps/node_modules/timers-browserify/main.js
|
|
1596
2032
|
return function (require, module, exports) {
|
|
1597
2033
|
(function (setImmediate,clearImmediate){(function (){
|
|
1598
2034
|
var nextTick=require("process/browser.js").nextTick,apply=Function.prototype.apply,slice=Array.prototype.slice,immediateIds={},nextImmediateId=0;function Timeout(e,t){this._id=e,this._clearFn=t}/* common-shake removed: exports.setTimeout = */ void 0, function(){return new Timeout(apply.call(setTimeout,window,arguments),clearTimeout)},/* common-shake removed: exports.setInterval = */ void 0, function(){return new Timeout(apply.call(setInterval,window,arguments),clearInterval)},/* common-shake removed: exports.clearTimeout = */ void 0, /* common-shake removed: exports.clearInterval = */ function(e){e.close()},Timeout.prototype.unref=Timeout.prototype.ref=function(){},Timeout.prototype.close=function(){this._clearFn.call(window,this._id)},/* common-shake removed: exports.enroll = */ void 0, function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},/* common-shake removed: exports.unenroll = */ void 0, function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},/* common-shake removed: exports._unrefActive = */ void 0, /* common-shake removed: exports.active = */ function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),t))},exports.setImmediate="function"==typeof setImmediate?setImmediate:function(e){var t=nextImmediateId++,i=!(arguments.length<2)&&slice.call(arguments,1);return immediateIds[t]=!0,nextTick((function(){immediateIds[t]&&(i?e.apply(null,i):e.call(null),exports.clearImmediate(t))})),t},exports.clearImmediate="function"==typeof clearImmediate?clearImmediate:function(e){delete immediateIds[e]};
|
|
@@ -1603,12 +2039,12 @@ var nextTick=require("process/browser.js").nextTick,apply=Function.prototype.app
|
|
|
1603
2039
|
}
|
|
1604
2040
|
}
|
|
1605
2041
|
}, {package:"browserify>timers-browserify",file:"../../node_modules/timers-browserify/main.js",}],
|
|
1606
|
-
[
|
|
2042
|
+
[144, {}, function(){
|
|
1607
2043
|
with (this.scopeTerminator) {
|
|
1608
2044
|
with (this.globalThis) {
|
|
1609
2045
|
return function() {
|
|
1610
2046
|
'use strict';
|
|
1611
|
-
// source: /home/runner/work/snaps
|
|
2047
|
+
// source: /home/runner/work/snaps/snaps/node_modules/util-deprecate/browser.js
|
|
1612
2048
|
return function (require, module, exports) {
|
|
1613
2049
|
function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return function(){if(!o){if(config("throwDeprecation"))throw new Error(e);config("traceDeprecation")?console.trace(e):console.warn(e),o=!0}return r.apply(this,arguments)}}function config(r){try{if(!global.localStorage)return!1}catch(r){return!1}var e=global.localStorage[r];return null!=e&&"true"===String(e).toLowerCase()}module.exports=deprecate;
|
|
1614
2050
|
|
|
@@ -1617,12 +2053,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1617
2053
|
}
|
|
1618
2054
|
}
|
|
1619
2055
|
}, {package:"browserify>readable-stream>util-deprecate",file:"../../node_modules/util-deprecate/browser.js",}],
|
|
1620
|
-
[
|
|
2056
|
+
[145, {"builtins":65}, function(){
|
|
1621
2057
|
with (this.scopeTerminator) {
|
|
1622
2058
|
with (this.globalThis) {
|
|
1623
2059
|
return function() {
|
|
1624
2060
|
'use strict';
|
|
1625
|
-
// source: /home/runner/work/snaps
|
|
2061
|
+
// source: /home/runner/work/snaps/snaps/node_modules/validate-npm-package-name/lib/index.js
|
|
1626
2062
|
return function (require, module, exports) {
|
|
1627
2063
|
"use strict";var scopedPackagePattern=new RegExp("^(?:@([^/]+?)[/])?([^/]+?)$"),builtins=require("builtins"),blacklist=["node_modules","favicon.ico"];function validate(e){var n=[],a=[];if(null===e)return a.push("name cannot be null"),done(n,a);if(void 0===e)return a.push("name cannot be undefined"),done(n,a);if("string"!=typeof e)return a.push("name must be a string"),done(n,a);if(e.length||a.push("name length must be greater than zero"),e.match(/^\./)&&a.push("name cannot start with a period"),e.match(/^_/)&&a.push("name cannot start with an underscore"),e.trim()!==e&&a.push("name cannot contain leading or trailing spaces"),blacklist.forEach((function(n){e.toLowerCase()===n&&a.push(n+" is a blacklisted name")})),builtins({version:"*"}).forEach((function(a){e.toLowerCase()===a&&n.push(a+" is a core module name")})),e.length>214&&n.push("name can no longer contain more than 214 characters"),e.toLowerCase()!==e&&n.push("name can no longer contain capital letters"),/[~'!()*]/.test(e.split("/").slice(-1)[0])&&n.push('name can no longer contain special characters ("~\'!()*")'),encodeURIComponent(e)!==e){var t=e.match(scopedPackagePattern);if(t){var r=t[1],o=t[2];if(encodeURIComponent(r)===r&&encodeURIComponent(o)===o)return done(n,a)}a.push("name can only contain URL-friendly characters")}return done(n,a)}var done=function(e,n){var a={validForNewPackages:0===n.length&&0===e.length,validForOldPackages:0===n.length,warnings:e,errors:n};return a.warnings.length||delete a.warnings,a.errors.length||delete a.errors,a};module.exports=validate;
|
|
1628
2064
|
|
|
@@ -1631,12 +2067,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1631
2067
|
}
|
|
1632
2068
|
}
|
|
1633
2069
|
}, {package:"@metamask/snaps-utils>validate-npm-package-name",file:"../../node_modules/validate-npm-package-name/lib/index.js",}],
|
|
1634
|
-
[
|
|
2070
|
+
[146, {}, function(){
|
|
1635
2071
|
with (this.scopeTerminator) {
|
|
1636
2072
|
with (this.globalThis) {
|
|
1637
2073
|
return function() {
|
|
1638
2074
|
'use strict';
|
|
1639
|
-
// source: /home/runner/work/snaps
|
|
2075
|
+
// source: /home/runner/work/snaps/snaps/node_modules/yallist/iterator.js
|
|
1640
2076
|
return function (require, module, exports) {
|
|
1641
2077
|
"use strict";module.exports=function(t){t.prototype[Symbol.iterator]=function*(){for(let t=this.head;t;t=t.next)yield t.value}};
|
|
1642
2078
|
|
|
@@ -1644,13 +2080,13 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1644
2080
|
};
|
|
1645
2081
|
}
|
|
1646
2082
|
}
|
|
1647
|
-
}, {package:"
|
|
1648
|
-
[
|
|
2083
|
+
}, {package:"@metamask/utils>semver>lru-cache>yallist",file:"../../node_modules/yallist/iterator.js",}],
|
|
2084
|
+
[147, {"./iterator.js":146}, function(){
|
|
1649
2085
|
with (this.scopeTerminator) {
|
|
1650
2086
|
with (this.globalThis) {
|
|
1651
2087
|
return function() {
|
|
1652
2088
|
'use strict';
|
|
1653
|
-
// source: /home/runner/work/snaps
|
|
2089
|
+
// source: /home/runner/work/snaps/snaps/node_modules/yallist/yallist.js
|
|
1654
2090
|
return function (require, module, exports) {
|
|
1655
2091
|
"use strict";function Yallist(t){var e=this;if(e instanceof Yallist||(e=new Yallist),e.tail=null,e.head=null,e.length=0,t&&"function"==typeof t.forEach)t.forEach((function(t){e.push(t)}));else if(arguments.length>0)for(var l=0,i=arguments.length;l<i;l++)e.push(arguments[l]);return e}function insert(t,e,l){var i=e===t.head?new Node(l,null,e,t):new Node(l,e,e.next,t);return null===i.next&&(t.tail=i),null===i.prev&&(t.head=i),t.length++,i}function push(t,e){t.tail=new Node(e,t.tail,null,t),t.head||(t.head=t.tail),t.length++}function unshift(t,e){t.head=new Node(e,null,t.head,t),t.tail||(t.tail=t.head),t.length++}function Node(t,e,l,i){if(!(this instanceof Node))return new Node(t,e,l,i);this.list=i,this.value=t,e?(e.next=this,this.prev=e):this.prev=null,l?(l.prev=this,this.next=l):this.next=null}module.exports=Yallist,Yallist.Node=Node,Yallist.create=Yallist,Yallist.prototype.removeNode=function(t){if(t.list!==this)throw new Error("removing node which does not belong to this list");var e=t.next,l=t.prev;return e&&(e.prev=l),l&&(l.next=e),t===this.head&&(this.head=e),t===this.tail&&(this.tail=l),t.list.length--,t.next=null,t.prev=null,t.list=null,e},Yallist.prototype.unshiftNode=function(t){if(t!==this.head){t.list&&t.list.removeNode(t);var e=this.head;t.list=this,t.next=e,e&&(e.prev=t),this.head=t,this.tail||(this.tail=t),this.length++}},Yallist.prototype.pushNode=function(t){if(t!==this.tail){t.list&&t.list.removeNode(t);var e=this.tail;t.list=this,t.prev=e,e&&(e.next=t),this.tail=t,this.head||(this.head=t),this.length++}},Yallist.prototype.push=function(){for(var t=0,e=arguments.length;t<e;t++)push(this,arguments[t]);return this.length},Yallist.prototype.unshift=function(){for(var t=0,e=arguments.length;t<e;t++)unshift(this,arguments[t]);return this.length},Yallist.prototype.pop=function(){if(this.tail){var t=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,t}},Yallist.prototype.shift=function(){if(this.head){var t=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,t}},Yallist.prototype.forEach=function(t,e){e=e||this;for(var l=this.head,i=0;null!==l;i++)t.call(e,l.value,i,this),l=l.next},Yallist.prototype.forEachReverse=function(t,e){e=e||this;for(var l=this.tail,i=this.length-1;null!==l;i--)t.call(e,l.value,i,this),l=l.prev},Yallist.prototype.get=function(t){for(var e=0,l=this.head;null!==l&&e<t;e++)l=l.next;if(e===t&&null!==l)return l.value},Yallist.prototype.getReverse=function(t){for(var e=0,l=this.tail;null!==l&&e<t;e++)l=l.prev;if(e===t&&null!==l)return l.value},Yallist.prototype.map=function(t,e){e=e||this;for(var l=new Yallist,i=this.head;null!==i;)l.push(t.call(e,i.value,this)),i=i.next;return l},Yallist.prototype.mapReverse=function(t,e){e=e||this;for(var l=new Yallist,i=this.tail;null!==i;)l.push(t.call(e,i.value,this)),i=i.prev;return l},Yallist.prototype.reduce=function(t,e){var l,i=this.head;if(arguments.length>1)l=e;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");i=this.head.next,l=this.head.value}for(var n=0;null!==i;n++)l=t(l,i.value,n),i=i.next;return l},Yallist.prototype.reduceReverse=function(t,e){var l,i=this.tail;if(arguments.length>1)l=e;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");i=this.tail.prev,l=this.tail.value}for(var n=this.length-1;null!==i;n--)l=t(l,i.value,n),i=i.prev;return l},Yallist.prototype.toArray=function(){for(var t=new Array(this.length),e=0,l=this.head;null!==l;e++)t[e]=l.value,l=l.next;return t},Yallist.prototype.toArrayReverse=function(){for(var t=new Array(this.length),e=0,l=this.tail;null!==l;e++)t[e]=l.value,l=l.prev;return t},Yallist.prototype.slice=function(t,e){(e=e||this.length)<0&&(e+=this.length),(t=t||0)<0&&(t+=this.length);var l=new Yallist;if(e<t||e<0)return l;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=0,n=this.head;null!==n&&i<t;i++)n=n.next;for(;null!==n&&i<e;i++,n=n.next)l.push(n.value);return l},Yallist.prototype.sliceReverse=function(t,e){(e=e||this.length)<0&&(e+=this.length),(t=t||0)<0&&(t+=this.length);var l=new Yallist;if(e<t||e<0)return l;t<0&&(t=0),e>this.length&&(e=this.length);for(var i=this.length,n=this.tail;null!==n&&i>e;i--)n=n.prev;for(;null!==n&&i>t;i--,n=n.prev)l.push(n.value);return l},Yallist.prototype.splice=function(t,e,...l){t>this.length&&(t=this.length-1),t<0&&(t=this.length+t);for(var i=0,n=this.head;null!==n&&i<t;i++)n=n.next;var h=[];for(i=0;n&&i<e;i++)h.push(n.value),n=this.removeNode(n);null===n&&(n=this.tail),n!==this.head&&n!==this.tail&&(n=n.prev);for(i=0;i<l.length;i++)n=insert(this,n,l[i]);return h},Yallist.prototype.reverse=function(){for(var t=this.head,e=this.tail,l=t;null!==l;l=l.prev){var i=l.prev;l.prev=l.next,l.next=i}return this.head=e,this.tail=t,this};try{require("./iterator.js")(Yallist)}catch(t){}
|
|
1656
2092
|
|
|
@@ -1658,13 +2094,13 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1658
2094
|
};
|
|
1659
2095
|
}
|
|
1660
2096
|
}
|
|
1661
|
-
}, {package:"
|
|
1662
|
-
[
|
|
2097
|
+
}, {package:"@metamask/utils>semver>lru-cache>yallist",file:"../../node_modules/yallist/yallist.js",}],
|
|
2098
|
+
[148, {"@metamask/utils":46}, function(){
|
|
1663
2099
|
with (this.scopeTerminator) {
|
|
1664
2100
|
with (this.globalThis) {
|
|
1665
2101
|
return function() {
|
|
1666
2102
|
'use strict';
|
|
1667
|
-
// source: /home/runner/work/snaps
|
|
2103
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-execution-environments/src/common/lockdown/lockdown-events.ts
|
|
1668
2104
|
return function (require, module, exports) {
|
|
1669
2105
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.executeLockdownEvents=executeLockdownEvents;var _utils=require("@metamask/utils");const targetEvents=new Map;function executeLockdownEvents(){targetEvents.forEach(((t,e)=>{for(const o of t)Object.defineProperty(e,o,{value:void 0,configurable:!1,writable:!1})}))}(0,_utils.hasProperty)(globalThis,"UIEvent")&&targetEvents.set(UIEvent.prototype,["view"]),(0,_utils.hasProperty)(globalThis,"MutationEvent")&&targetEvents.set(MutationEvent.prototype,["relatedNode"]),(0,_utils.hasProperty)(globalThis,"MessageEvent")&&targetEvents.set(MessageEvent.prototype,["source"]),(0,_utils.hasProperty)(globalThis,"FocusEvent")&&targetEvents.set(FocusEvent.prototype,["relatedTarget"]),(0,_utils.hasProperty)(globalThis,"MouseEvent")&&targetEvents.set(MouseEvent.prototype,["relatedTarget","fromElement","toElement"]),(0,_utils.hasProperty)(globalThis,"TouchEvent")&&targetEvents.set(TouchEvent.prototype,["targetTouches","touches"]),(0,_utils.hasProperty)(globalThis,"Event")&&targetEvents.set(Event.prototype,["target","currentTarget","srcElement","composedPath"]);
|
|
1670
2106
|
|
|
@@ -1673,12 +2109,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1673
2109
|
}
|
|
1674
2110
|
}
|
|
1675
2111
|
}, {package:"$root$",file:"src/common/lockdown/lockdown-events.ts",}],
|
|
1676
|
-
[
|
|
2112
|
+
[149, {"./../../../../snaps-utils/src/index.browser":161}, function(){
|
|
1677
2113
|
with (this.scopeTerminator) {
|
|
1678
2114
|
with (this.globalThis) {
|
|
1679
2115
|
return function() {
|
|
1680
2116
|
'use strict';
|
|
1681
|
-
// source: /home/runner/work/snaps
|
|
2117
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-execution-environments/src/common/lockdown/lockdown-more.ts
|
|
1682
2118
|
return function (require, module, exports) {
|
|
1683
2119
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.executeLockdownMore=executeLockdownMore;var _index=require("./../../../../snaps-utils/src/index.browser");function executeLockdownMore(){try{const e=Reflect.ownKeys((new Compartment).globalThis),o=new Set(["eval","Function"]);new Set([...e]).forEach((e=>{const r=Reflect.getOwnPropertyDescriptor(globalThis,e);r&&(r.configurable&&(hasAccessor(r)?Object.defineProperty(globalThis,e,{configurable:!1}):Object.defineProperty(globalThis,e,{configurable:!1,writable:!1})),o.has(e)&&harden(globalThis[e]))}))}catch(e){throw(0,_index.logError)("Protecting intrinsics failed:",e),e}}function hasAccessor(e){return"set"in e||"get"in e}
|
|
1684
2120
|
|
|
@@ -1687,12 +2123,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1687
2123
|
}
|
|
1688
2124
|
}
|
|
1689
2125
|
}, {package:"$root$",file:"src/common/lockdown/lockdown-more.ts",}],
|
|
1690
|
-
[
|
|
2126
|
+
[150, {"./../../../snaps-utils/src/index.browser":161,"@metamask/post-message-stream":4,"@metamask/utils":46}, function(){
|
|
1691
2127
|
with (this.scopeTerminator) {
|
|
1692
2128
|
with (this.globalThis) {
|
|
1693
2129
|
return function() {
|
|
1694
2130
|
'use strict';
|
|
1695
|
-
// source: /home/runner/work/snaps
|
|
2131
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-execution-environments/src/offscreen/OffscreenSnapExecutor.ts
|
|
1696
2132
|
return function (require, module, exports) {
|
|
1697
2133
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.OffscreenSnapExecutor=void 0;var _postMessageStream=require("@metamask/post-message-stream"),_index=require("./../../../snaps-utils/src/index.browser"),_utils=require("@metamask/utils");function _classPrivateMethodInitSpec(e,t){_checkPrivateRedeclaration(e,t),t.add(e)}function _defineProperty(e,t,i){return(t=_toPropertyKey(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function _toPropertyKey(e){var t=_toPrimitive(e,"string");return"symbol"==typeof t?t:String(t)}function _toPrimitive(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var r=i.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function _classPrivateFieldInitSpec(e,t,i){_checkPrivateRedeclaration(e,t),t.set(e,i)}function _checkPrivateRedeclaration(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function _classPrivateMethodGet(e,t,i){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return i}function _classPrivateFieldGet(e,t){return _classApplyDescriptorGet(e,_classExtractFieldDescriptor(e,t,"get"))}function _classApplyDescriptorGet(e,t){return t.get?t.get.call(e):t.value}function _classPrivateFieldSet(e,t,i){return _classApplyDescriptorSet(e,_classExtractFieldDescriptor(e,t,"set"),i),i}function _classExtractFieldDescriptor(e,t,i){if(!t.has(e))throw new TypeError("attempted to "+i+" private field on non-instance");return t.get(e)}function _classApplyDescriptorSet(e,t,i){if(t.set)t.set.call(e,i);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=i}}var _stream=new WeakMap,_onData=new WeakSet,_initializeJob=new WeakSet,_terminateJob=new WeakSet;class OffscreenSnapExecutor{static initialize(e){return new OffscreenSnapExecutor(e)}constructor(e){_classPrivateMethodInitSpec(this,_terminateJob),_classPrivateMethodInitSpec(this,_initializeJob),_classPrivateMethodInitSpec(this,_onData),_classPrivateFieldInitSpec(this,_stream,{writable:!0,value:void 0}),_defineProperty(this,"jobs",{}),_classPrivateFieldSet(this,_stream,e),_classPrivateFieldGet(this,_stream).on("data",_classPrivateMethodGet(this,_onData,_onData2).bind(this))}}function _onData2(e){const{jobId:t,extra:{frameUrl:i},data:r}=e;this.jobs[t]?"terminateJob"!==r.method?this.jobs[t].stream.write(r):_classPrivateMethodGet(this,_terminateJob,_terminateJob2).call(this,t):_classPrivateMethodGet(this,_initializeJob,_initializeJob2).call(this,t,i).then((()=>{_classPrivateMethodGet(this,_onData,_onData2).call(this,e)})).catch((e=>{(0,_index.logError)("[Worker] Error initializing job:",e)}))}async function _initializeJob2(e,t){const i=await(0,_index.createWindow)(t,e),r=new _postMessageStream.WindowPostMessageStream({name:"parent",target:"child",targetWindow:i,targetOrigin:"*"});return r.on("data",(t=>{_classPrivateFieldGet(this,_stream).write({data:t,jobId:e})})),this.jobs[e]={id:e,window:i,stream:r},this.jobs[e]}function _terminateJob2(e){(0,_utils.assert)(this.jobs[e],`Job "${e}" not found.`);const t=document.getElementById(e);(0,_utils.assert)(t,`Iframe with ID "${e}" not found.`),t.remove(),this.jobs[e].stream.destroy(),delete this.jobs[e]}exports.OffscreenSnapExecutor=OffscreenSnapExecutor;
|
|
1698
2134
|
|
|
@@ -1701,12 +2137,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1701
2137
|
}
|
|
1702
2138
|
}
|
|
1703
2139
|
}, {package:"$root$",file:"src/offscreen/OffscreenSnapExecutor.ts",}],
|
|
1704
|
-
[
|
|
2140
|
+
[151, {"../common/lockdown/lockdown-events":148,"../common/lockdown/lockdown-more":149,"./OffscreenSnapExecutor":150,"@metamask/post-message-stream":4}, function(){
|
|
1705
2141
|
with (this.scopeTerminator) {
|
|
1706
2142
|
with (this.globalThis) {
|
|
1707
2143
|
return function() {
|
|
1708
2144
|
'use strict';
|
|
1709
|
-
// source: /home/runner/work/snaps
|
|
2145
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-execution-environments/src/offscreen/index.ts
|
|
1710
2146
|
return function (require, module, exports) {
|
|
1711
2147
|
"use strict";var _postMessageStream=require("@metamask/post-message-stream"),_lockdownEvents=require("../common/lockdown/lockdown-events"),_lockdownMore=require("../common/lockdown/lockdown-more"),_OffscreenSnapExecutor=require("./OffscreenSnapExecutor");(0,_lockdownMore.executeLockdownMore)(),(0,_lockdownEvents.executeLockdownEvents)();const parentStream=new _postMessageStream.BrowserRuntimePostMessageStream({name:"child",target:"parent"});_OffscreenSnapExecutor.OffscreenSnapExecutor.initialize(parentStream);
|
|
1712
2148
|
|
|
@@ -1715,12 +2151,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1715
2151
|
}
|
|
1716
2152
|
}
|
|
1717
2153
|
}, {package:"$root$",file:"src/offscreen/index.ts",}],
|
|
1718
|
-
[
|
|
2154
|
+
[152, {}, function(){
|
|
1719
2155
|
with (this.scopeTerminator) {
|
|
1720
2156
|
with (this.globalThis) {
|
|
1721
2157
|
return function() {
|
|
1722
2158
|
'use strict';
|
|
1723
|
-
// source: /home/runner/work/snaps
|
|
2159
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/caveats.ts
|
|
1724
2160
|
return function (require, module, exports) {
|
|
1725
2161
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SnapCaveatType=void 0;let SnapCaveatType=function(e){return e.PermittedDerivationPaths="permittedDerivationPaths",e.PermittedCoinTypes="permittedCoinTypes",e.SnapKeyring="snapKeyring",e.SnapCronjob="snapCronjob",e.TransactionOrigin="transactionOrigin",e.RpcOrigin="rpcOrigin",e.SnapIds="snapIds",e}({});exports.SnapCaveatType=SnapCaveatType;
|
|
1726
2162
|
|
|
@@ -1729,12 +2165,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1729
2165
|
}
|
|
1730
2166
|
}
|
|
1731
2167
|
}, {package:"external:../snaps-utils/src/caveats.ts",file:"../snaps-utils/src/caveats.ts",}],
|
|
1732
|
-
[
|
|
2168
|
+
[153, {"./virtual-file/VirtualFile":173,"@metamask/utils":46,"@noble/hashes/sha256":59}, function(){
|
|
1733
2169
|
with (this.scopeTerminator) {
|
|
1734
2170
|
with (this.globalThis) {
|
|
1735
2171
|
return function() {
|
|
1736
2172
|
'use strict';
|
|
1737
|
-
// source: /home/runner/work/snaps
|
|
2173
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/checksum.ts
|
|
1738
2174
|
return function (require, module, exports) {
|
|
1739
2175
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.checksum=checksum,exports.checksumFiles=checksumFiles;var _utils=require("@metamask/utils"),_sha=require("@noble/hashes/sha256"),_VirtualFile=require("./virtual-file/VirtualFile");function checksum(e){const s=e instanceof _VirtualFile.VirtualFile?e.value:e;return(0,_sha.sha256)(s)}function checksumFiles(e){return checksum((0,_utils.concatBytes)([...e].sort(((e,s)=>((0,_utils.assert)(e.path!==s.path,"Tried to sort files with non-unique paths."),e.path<s.path?-1:1))).map((e=>checksum(e)))))}
|
|
1740
2176
|
|
|
@@ -1743,12 +2179,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1743
2179
|
}
|
|
1744
2180
|
}
|
|
1745
2181
|
}, {package:"external:../snaps-utils/src/checksum.ts",file:"../snaps-utils/src/checksum.ts",}],
|
|
1746
|
-
[
|
|
2182
|
+
[154, {"@metamask/utils":46,"cron-parser":71,"superstruct":142}, function(){
|
|
1747
2183
|
with (this.scopeTerminator) {
|
|
1748
2184
|
with (this.globalThis) {
|
|
1749
2185
|
return function() {
|
|
1750
2186
|
'use strict';
|
|
1751
|
-
// source: /home/runner/work/snaps
|
|
2187
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/cronjob.ts
|
|
1752
2188
|
return function (require, module, exports) {
|
|
1753
2189
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.CronjobSpecificationStruct=exports.CronjobSpecificationArrayStruct=exports.CronjobRpcRequestStruct=exports.CronExpressionStruct=void 0,exports.isCronjobSpecification=isCronjobSpecification,exports.isCronjobSpecificationArray=isCronjobSpecificationArray,exports.parseCronExpression=parseCronExpression;var _utils=require("@metamask/utils"),_cronParser=require("cron-parser"),_superstruct=require("superstruct");const CronjobRpcRequestStruct=(0,_superstruct.assign)((0,_superstruct.partial)((0,_superstruct.pick)(_utils.JsonRpcRequestStruct,["id","jsonrpc"])),(0,_superstruct.omit)(_utils.JsonRpcRequestStruct,["id","jsonrpc"]));exports.CronjobRpcRequestStruct=CronjobRpcRequestStruct;const CronExpressionStruct=(0,_superstruct.refine)((0,_superstruct.coerce)((0,_superstruct.string)(),(0,_superstruct.object)({minute:(0,_superstruct.optional)((0,_superstruct.string)()),hour:(0,_superstruct.optional)((0,_superstruct.string)()),dayOfMonth:(0,_superstruct.optional)((0,_superstruct.string)()),month:(0,_superstruct.optional)((0,_superstruct.string)()),dayOfWeek:(0,_superstruct.optional)((0,_superstruct.string)())}),(r=>`${r.minute??"*"} ${r.hour??"*"} ${r.dayOfMonth??"*"} ${r.month??"*"} ${r.dayOfWeek??"*"}`)),"CronExpression",(r=>{try{return(0,_cronParser.parseExpression)(r),!0}catch{return!1}}));function parseCronExpression(r){const t=(0,_superstruct.create)(r,CronExpressionStruct);return(0,_cronParser.parseExpression)(t)}exports.CronExpressionStruct=CronExpressionStruct;const CronjobSpecificationStruct=(0,_superstruct.object)({expression:CronExpressionStruct,request:CronjobRpcRequestStruct});function isCronjobSpecification(r){try{return(0,_superstruct.create)(r,CronjobSpecificationStruct),!0}catch{return!1}}exports.CronjobSpecificationStruct=CronjobSpecificationStruct;const CronjobSpecificationArrayStruct=(0,_superstruct.array)(CronjobSpecificationStruct);function isCronjobSpecificationArray(r){try{return(0,_superstruct.create)(r,CronjobSpecificationArrayStruct),!0}catch{return!1}}exports.CronjobSpecificationArrayStruct=CronjobSpecificationArrayStruct;
|
|
1754
2190
|
|
|
@@ -1757,12 +2193,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1757
2193
|
}
|
|
1758
2194
|
}
|
|
1759
2195
|
}, {package:"external:../snaps-utils/src/cronjob.ts",file:"../snaps-utils/src/cronjob.ts",}],
|
|
1760
|
-
[
|
|
2196
|
+
[155, {"rfdc":95}, function(){
|
|
1761
2197
|
with (this.scopeTerminator) {
|
|
1762
2198
|
with (this.globalThis) {
|
|
1763
2199
|
return function() {
|
|
1764
2200
|
'use strict';
|
|
1765
|
-
// source: /home/runner/work/snaps
|
|
2201
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/deep-clone.ts
|
|
1766
2202
|
return function (require, module, exports) {
|
|
1767
2203
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.deepClone=void 0;var _rfdc=_interopRequireDefault(require("rfdc"));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}const deepClone=(0,_rfdc.default)({proto:!1,circles:!1});exports.deepClone=deepClone;
|
|
1768
2204
|
|
|
@@ -1771,12 +2207,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1771
2207
|
}
|
|
1772
2208
|
}
|
|
1773
2209
|
}, {package:"external:../snaps-utils/src/deep-clone.ts",file:"../snaps-utils/src/deep-clone.ts",}],
|
|
1774
|
-
[
|
|
2210
|
+
[156, {}, function(){
|
|
1775
2211
|
with (this.scopeTerminator) {
|
|
1776
2212
|
with (this.globalThis) {
|
|
1777
2213
|
return function() {
|
|
1778
2214
|
'use strict';
|
|
1779
|
-
// source: /home/runner/work/snaps
|
|
2215
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/default-endowments.ts
|
|
1780
2216
|
return function (require, module, exports) {
|
|
1781
2217
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.DEFAULT_ENDOWMENTS=void 0;const DEFAULT_ENDOWMENTS=Object.freeze(["atob","btoa","BigInt","console","crypto","Date","Math","setTimeout","clearTimeout","SubtleCrypto","TextDecoder","TextEncoder","URL","setInterval","clearInterval","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","Uint32Array","Float32Array","Float64Array","BigInt64Array","BigUint64Array","DataView","ArrayBuffer","AbortController","AbortSignal"]);exports.DEFAULT_ENDOWMENTS=DEFAULT_ENDOWMENTS;
|
|
1782
2218
|
|
|
@@ -1785,12 +2221,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1785
2221
|
}
|
|
1786
2222
|
}
|
|
1787
2223
|
}, {package:"external:../snaps-utils/src/default-endowments.ts",file:"../snaps-utils/src/default-endowments.ts",}],
|
|
1788
|
-
[
|
|
2224
|
+
[157, {}, function(){
|
|
1789
2225
|
with (this.scopeTerminator) {
|
|
1790
2226
|
with (this.globalThis) {
|
|
1791
2227
|
return function() {
|
|
1792
2228
|
'use strict';
|
|
1793
|
-
// source: /home/runner/work/snaps
|
|
2229
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/entropy.ts
|
|
1794
2230
|
return function (require, module, exports) {
|
|
1795
2231
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.STATE_ENCRYPTION_MAGIC_VALUE=exports.SIP_6_MAGIC_VALUE=void 0;const SIP_6_MAGIC_VALUE="1399742832'";exports.SIP_6_MAGIC_VALUE="1399742832'";const STATE_ENCRYPTION_MAGIC_VALUE="572232532'";exports.STATE_ENCRYPTION_MAGIC_VALUE="572232532'";
|
|
1796
2232
|
|
|
@@ -1799,12 +2235,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1799
2235
|
}
|
|
1800
2236
|
}
|
|
1801
2237
|
}, {package:"external:../snaps-utils/src/entropy.ts",file:"../snaps-utils/src/entropy.ts",}],
|
|
1802
|
-
[
|
|
2238
|
+
[158, {}, function(){
|
|
1803
2239
|
with (this.scopeTerminator) {
|
|
1804
2240
|
with (this.globalThis) {
|
|
1805
2241
|
return function() {
|
|
1806
2242
|
'use strict';
|
|
1807
|
-
// source: /home/runner/work/snaps
|
|
2243
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/handlers.ts
|
|
1808
2244
|
return function (require, module, exports) {
|
|
1809
2245
|
"use strict";
|
|
1810
2246
|
|
|
@@ -1813,12 +2249,28 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1813
2249
|
}
|
|
1814
2250
|
}
|
|
1815
2251
|
}, {package:"external:../snaps-utils/src/handlers.ts",file:"../snaps-utils/src/handlers.ts",}],
|
|
1816
|
-
[
|
|
2252
|
+
[159, {"@metamask/utils":46,"buffer":64,"is-svg":91}, function(){
|
|
1817
2253
|
with (this.scopeTerminator) {
|
|
1818
2254
|
with (this.globalThis) {
|
|
1819
2255
|
return function() {
|
|
1820
2256
|
'use strict';
|
|
1821
|
-
// source: /home/runner/work/snaps
|
|
2257
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/icon.ts
|
|
2258
|
+
return function (require, module, exports) {
|
|
2259
|
+
(function (Buffer){(function (){
|
|
2260
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.assertIsSnapIcon=/* common-shake removed: exports.SVG_MAX_BYTE_SIZE_TEXT = */ /* common-shake removed: exports.SVG_MAX_BYTE_SIZE = */ void 0;var _utils=require("@metamask/utils"),_isSvg=_interopRequireDefault(require("is-svg"));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}const SVG_MAX_BYTE_SIZE=1e5;/* common-shake removed: exports.SVG_MAX_BYTE_SIZE = */ void 1e5;const SVG_MAX_BYTE_SIZE_TEXT=`${Math.floor(100)}kb`;/* common-shake removed: exports.SVG_MAX_BYTE_SIZE_TEXT = */ void SVG_MAX_BYTE_SIZE_TEXT;const assertIsSnapIcon=e=>{(0,_utils.assert)(e.path.endsWith(".svg"),'Expected snap icon to end in ".svg".'),(0,_utils.assert)(Buffer.byteLength(e.value,"utf8")<=1e5,`The specified SVG icon exceeds the maximum size of ${SVG_MAX_BYTE_SIZE_TEXT}.`),(0,_utils.assert)((0,_isSvg.default)(e.toString()),"Snap icon must be a valid SVG.")};exports.assertIsSnapIcon=assertIsSnapIcon;
|
|
2261
|
+
|
|
2262
|
+
}).call(this)}).call(this,require("buffer").Buffer)
|
|
2263
|
+
};
|
|
2264
|
+
};
|
|
2265
|
+
}
|
|
2266
|
+
}
|
|
2267
|
+
}, {package:"external:../snaps-utils/src/icon.ts",file:"../snaps-utils/src/icon.ts",}],
|
|
2268
|
+
[160, {}, function(){
|
|
2269
|
+
with (this.scopeTerminator) {
|
|
2270
|
+
with (this.globalThis) {
|
|
2271
|
+
return function() {
|
|
2272
|
+
'use strict';
|
|
2273
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/iframe.ts
|
|
1822
2274
|
return function (require, module, exports) {
|
|
1823
2275
|
"use strict";async function createWindow(e,t,n=!0){return await new Promise(((o,r)=>{const i=document.createElement("iframe");i.setAttribute("id",t),i.setAttribute("data-testid","snaps-iframe"),n&&i.setAttribute("sandbox","allow-scripts"),i.setAttribute("src",e),document.body.appendChild(i),i.addEventListener("load",(()=>{i.contentWindow?o(i.contentWindow):r(new Error(`iframe.contentWindow not present on load for job "${t}".`))}))}))}Object.defineProperty(exports,"__esModule",{value:!0}),exports.createWindow=createWindow;
|
|
1824
2276
|
|
|
@@ -1827,26 +2279,26 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1827
2279
|
}
|
|
1828
2280
|
}
|
|
1829
2281
|
}, {package:"external:../snaps-utils/src/iframe.ts",file:"../snaps-utils/src/iframe.ts",}],
|
|
1830
|
-
[
|
|
2282
|
+
[161, {"./caveats":152,"./checksum":153,"./cronjob":154,"./deep-clone":155,"./default-endowments":156,"./entropy":157,"./handlers":158,"./iframe":160,"./json-rpc":162,"./logging":163,"./manifest/index.browser":164,"./namespace":166,"./notification":167,"./path":168,"./snaps":169,"./types":170,"./validation":171,"./versions":172,"./virtual-file/index.browser":174}, function(){
|
|
1831
2283
|
with (this.scopeTerminator) {
|
|
1832
2284
|
with (this.globalThis) {
|
|
1833
2285
|
return function() {
|
|
1834
2286
|
'use strict';
|
|
1835
|
-
// source: /home/runner/work/snaps
|
|
2287
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/index.browser.ts
|
|
1836
2288
|
return function (require, module, exports) {
|
|
1837
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var _caveats=require("./caveats");Object.keys(_caveats).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_caveats[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _caveats[e]}}))}));var _checksum=require("./checksum");Object.keys(_checksum).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_checksum[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _checksum[e]}}))}));var _cronjob=require("./cronjob");Object.keys(_cronjob).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_cronjob[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _cronjob[e]}}))}));var _deepClone=require("./deep-clone");Object.keys(_deepClone).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_deepClone[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _deepClone[e]}}))}));var _defaultEndowments=require("./default-endowments");Object.keys(_defaultEndowments).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_defaultEndowments[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _defaultEndowments[e]}}))}));var _entropy=require("./entropy");Object.keys(_entropy).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_entropy[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _entropy[e]}}))}));var _handlers=require("./handlers");Object.keys(_handlers).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_handlers[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _handlers[e]}}))}));var _iframe=require("./iframe");Object.keys(_iframe).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_iframe[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _iframe[e]}}))}));var _jsonRpc=require("./json-rpc");Object.keys(_jsonRpc).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_jsonRpc[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _jsonRpc[e]}}))}));var _logging=require("./logging");Object.keys(_logging).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_logging[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _logging[e]}}))}));var _index=require("./manifest/index.browser");Object.keys(_index).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_index[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _index[e]}}))}));var _namespace=require("./namespace");Object.keys(_namespace).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_namespace[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _namespace[e]}}))}));var _notification=require("./notification");Object.keys(_notification).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_notification[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _notification[e]}}))}));var _path=require("./path");Object.keys(_path).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_path[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _path[e]}}))}));var _snaps=require("./snaps");Object.keys(_snaps).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_snaps[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _snaps[e]}}))}));var _types=require("./types");Object.keys(_types).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_types[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _types[e]}}))}));var _versions=require("./versions");Object.keys(_versions).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_versions[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _versions[e]}}))}));var _index2=require("./virtual-file/index.browser");Object.keys(_index2).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_index2[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _index2[e]}}))}));
|
|
2289
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var _caveats=require("./caveats");Object.keys(_caveats).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_caveats[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _caveats[e]}}))}));var _checksum=require("./checksum");Object.keys(_checksum).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_checksum[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _checksum[e]}}))}));var _cronjob=require("./cronjob");Object.keys(_cronjob).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_cronjob[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _cronjob[e]}}))}));var _deepClone=require("./deep-clone");Object.keys(_deepClone).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_deepClone[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _deepClone[e]}}))}));var _defaultEndowments=require("./default-endowments");Object.keys(_defaultEndowments).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_defaultEndowments[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _defaultEndowments[e]}}))}));var _entropy=require("./entropy");Object.keys(_entropy).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_entropy[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _entropy[e]}}))}));var _handlers=require("./handlers");Object.keys(_handlers).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_handlers[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _handlers[e]}}))}));var _iframe=require("./iframe");Object.keys(_iframe).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_iframe[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _iframe[e]}}))}));var _jsonRpc=require("./json-rpc");Object.keys(_jsonRpc).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_jsonRpc[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _jsonRpc[e]}}))}));var _logging=require("./logging");Object.keys(_logging).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_logging[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _logging[e]}}))}));var _index=require("./manifest/index.browser");Object.keys(_index).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_index[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _index[e]}}))}));var _namespace=require("./namespace");Object.keys(_namespace).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_namespace[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _namespace[e]}}))}));var _notification=require("./notification");Object.keys(_notification).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_notification[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _notification[e]}}))}));var _path=require("./path");Object.keys(_path).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_path[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _path[e]}}))}));var _snaps=require("./snaps");Object.keys(_snaps).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_snaps[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _snaps[e]}}))}));var _types=require("./types");Object.keys(_types).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_types[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _types[e]}}))}));var _validation=require("./validation");Object.keys(_validation).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_validation[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _validation[e]}}))}));var _versions=require("./versions");Object.keys(_versions).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_versions[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _versions[e]}}))}));var _index2=require("./virtual-file/index.browser");Object.keys(_index2).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_index2[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _index2[e]}}))}));
|
|
1838
2290
|
|
|
1839
2291
|
};
|
|
1840
2292
|
};
|
|
1841
2293
|
}
|
|
1842
2294
|
}
|
|
1843
2295
|
}, {package:"external:../snaps-utils/src/index.browser.ts",file:"../snaps-utils/src/index.browser.ts",}],
|
|
1844
|
-
[
|
|
2296
|
+
[162, {"@metamask/utils":46,"superstruct":142}, function(){
|
|
1845
2297
|
with (this.scopeTerminator) {
|
|
1846
2298
|
with (this.globalThis) {
|
|
1847
2299
|
return function() {
|
|
1848
2300
|
'use strict';
|
|
1849
|
-
// source: /home/runner/work/snaps
|
|
2301
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/json-rpc.ts
|
|
1850
2302
|
return function (require, module, exports) {
|
|
1851
2303
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.RpcOriginsStruct=void 0,exports.assertIsJsonRpcSuccess=assertIsJsonRpcSuccess,exports.assertIsRpcOrigins=assertIsRpcOrigins;var _utils=require("@metamask/utils"),_superstruct=require("superstruct");const RpcOriginsStruct=(0,_superstruct.refine)((0,_superstruct.object)({dapps:(0,_superstruct.optional)((0,_superstruct.boolean)()),snaps:(0,_superstruct.optional)((0,_superstruct.boolean)())}),"RPC origins",(s=>{if(!Object.values(s).some(Boolean))throw new Error("Must specify at least one JSON-RPC origin");return!0}));function assertIsRpcOrigins(s,r){(0,_utils.assertStruct)(s,RpcOriginsStruct,"Invalid JSON-RPC origins",r)}function assertIsJsonRpcSuccess(s){if(!(0,_utils.isJsonRpcSuccess)(s)){if((0,_utils.isJsonRpcFailure)(s))throw new Error(`JSON-RPC request failed: ${s.error.message}`);throw new Error("Invalid JSON-RPC response.")}}exports.RpcOriginsStruct=RpcOriginsStruct;
|
|
1852
2304
|
|
|
@@ -1855,12 +2307,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1855
2307
|
}
|
|
1856
2308
|
}
|
|
1857
2309
|
}, {package:"external:../snaps-utils/src/json-rpc.ts",file:"../snaps-utils/src/json-rpc.ts",}],
|
|
1858
|
-
[
|
|
2310
|
+
[163, {"@metamask/utils":46}, function(){
|
|
1859
2311
|
with (this.scopeTerminator) {
|
|
1860
2312
|
with (this.globalThis) {
|
|
1861
2313
|
return function() {
|
|
1862
2314
|
'use strict';
|
|
1863
|
-
// source: /home/runner/work/snaps
|
|
2315
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/logging.ts
|
|
1864
2316
|
return function (require, module, exports) {
|
|
1865
2317
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.logError=logError,exports.logInfo=logInfo,exports.logWarning=logWarning,exports.snapsLogger=void 0;var _utils=require("@metamask/utils");const snapsLogger=(0,_utils.createProjectLogger)("snaps");function logInfo(o,...r){console.log(o,...r)}function logError(o,...r){console.error(o,...r)}function logWarning(o,...r){console.warn(o,...r)}exports.snapsLogger=snapsLogger;
|
|
1866
2318
|
|
|
@@ -1869,12 +2321,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1869
2321
|
}
|
|
1870
2322
|
}
|
|
1871
2323
|
}, {package:"external:../snaps-utils/src/logging.ts",file:"../snaps-utils/src/logging.ts",}],
|
|
1872
|
-
[
|
|
2324
|
+
[164, {"./validation":165}, function(){
|
|
1873
2325
|
with (this.scopeTerminator) {
|
|
1874
2326
|
with (this.globalThis) {
|
|
1875
2327
|
return function() {
|
|
1876
2328
|
'use strict';
|
|
1877
|
-
// source: /home/runner/work/snaps
|
|
2329
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/manifest/index.browser.ts
|
|
1878
2330
|
return function (require, module, exports) {
|
|
1879
2331
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var _validation=require("./validation");Object.keys(_validation).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_validation[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _validation[e]}}))}));
|
|
1880
2332
|
|
|
@@ -1883,26 +2335,26 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1883
2335
|
}
|
|
1884
2336
|
}
|
|
1885
2337
|
}, {package:"external:../snaps-utils/src/manifest/index.browser.ts",file:"../snaps-utils/src/manifest/index.browser.ts",}],
|
|
1886
|
-
[
|
|
2338
|
+
[165, {"../cronjob":154,"../entropy":157,"../json-rpc":162,"../namespace":166,"../snaps":169,"../types":170,"@metamask/utils":46,"superstruct":142}, function(){
|
|
1887
2339
|
with (this.scopeTerminator) {
|
|
1888
2340
|
with (this.globalThis) {
|
|
1889
2341
|
return function() {
|
|
1890
2342
|
'use strict';
|
|
1891
|
-
// source: /home/runner/work/snaps
|
|
2343
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/manifest/validation.ts
|
|
1892
2344
|
return function (require, module, exports) {
|
|
1893
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SnapManifestStruct=exports.SnapIdsStruct=exports.SnapGetBip32EntropyPermissionsStruct=exports.SemVerRangeStruct=exports.PermissionsStruct=exports.Bip32PathStruct=exports.Bip32EntropyStruct=void 0,exports.assertIsSnapManifest=assertIsSnapManifest,exports.bip32entropy=void 0,exports.createSnapManifest=createSnapManifest,exports.isSnapManifest=isSnapManifest;var _utils=require("@metamask/utils"),_superstruct=require("superstruct"),_cronjob=require("../cronjob"),_entropy=require("../entropy"),_jsonRpc=require("../json-rpc"),_namespace=require("../namespace"),_snaps=require("../snaps"),_types=require("../types");const FORBIDDEN_PURPOSES=[_entropy.SIP_6_MAGIC_VALUE,_entropy.STATE_ENCRYPTION_MAGIC_VALUE],BIP32_INDEX_REGEX=/^\d+'?$/u,Bip32PathStruct=(0,_superstruct.refine)((0,_superstruct.array)((0,_superstruct.string)()),"BIP-32 path",(t=>0===t.length?"Path must be a non-empty BIP-32 derivation path array":"m"!==t[0]?'Path must start with "m".':t.length<3?"Paths must have a length of at least three.":t.slice(1).some((t=>!BIP32_INDEX_REGEX.test(t)))?"Path must be a valid BIP-32 derivation path array.":!FORBIDDEN_PURPOSES.includes(t[1])||`The purpose "${t[1]}" is not allowed for entropy derivation.`));exports.Bip32PathStruct=Bip32PathStruct;const bip32entropy=t=>(0,_superstruct.refine)(t,"BIP-32 entropy",(t=>"ed25519"!==t.curve||!t.path.slice(1).some((t=>!t.endsWith("'")))||"Ed25519 does not support unhardened paths."));exports.bip32entropy=bip32entropy;const Bip32EntropyStruct=bip32entropy((0,_superstruct.type)({path:Bip32PathStruct,curve:(0,_superstruct.enums)(["ed25519","secp256k1"])}));exports.Bip32EntropyStruct=Bip32EntropyStruct;const SnapGetBip32EntropyPermissionsStruct=(0,_superstruct.size)((0,_superstruct.array)(Bip32EntropyStruct),1,1/0);exports.SnapGetBip32EntropyPermissionsStruct=SnapGetBip32EntropyPermissionsStruct;const SemVerRangeStruct=(0,_superstruct.refine)((0,_superstruct.string)(),"SemVer range",(t=>!!(0,_utils.isValidSemVerRange)(t)||"Expected a valid SemVer range."));exports.SemVerRangeStruct=SemVerRangeStruct;const SnapIdsStruct=(0,_superstruct.refine)((0,_superstruct.record)(_snaps.SnapIdStruct,(0,_superstruct.object)({version:(0,_superstruct.optional)(SemVerRangeStruct)})),"SnapIds",(t=>0!==Object.keys(t).length));exports.SnapIdsStruct=SnapIdsStruct;const PermissionsStruct=(0,_superstruct.type)({"endowment:long-running":(0,_superstruct.optional)((0,_superstruct.object)({})),"endowment:network-access":(0,_superstruct.optional)((0,_superstruct.object)({})),"endowment:webassembly":(0,_superstruct.optional)((0,_superstruct.object)({})),"endowment:transaction-insight":(0,_superstruct.optional)((0,_superstruct.object)({allowTransactionOrigin:(0,_superstruct.optional)((0,_superstruct.boolean)())})),"endowment:cronjob":(0,_superstruct.optional)((0,_superstruct.object)({jobs:_cronjob.CronjobSpecificationArrayStruct})),"endowment:rpc":(0,_superstruct.optional)(_jsonRpc.RpcOriginsStruct),snap_dialog:(0,_superstruct.optional)((0,_superstruct.object)({})),snap_confirm:(0,_superstruct.optional)((0,_superstruct.object)({})),snap_manageState:(0,_superstruct.optional)((0,_superstruct.object)({})),snap_notify:(0,_superstruct.optional)((0,_superstruct.object)({})),snap_getBip32Entropy:(0,_superstruct.optional)(SnapGetBip32EntropyPermissionsStruct),snap_getBip32PublicKey:(0,_superstruct.optional)(SnapGetBip32EntropyPermissionsStruct),snap_getBip44Entropy:(0,_superstruct.optional)((0,_superstruct.size)((0,_superstruct.array)((0,_superstruct.object)({coinType:(0,_superstruct.size)((0,_superstruct.integer)(),0,2**32-1)})),1,1/0)),snap_getEntropy:(0,_superstruct.optional)((0,_superstruct.object)({})),"endowment:keyring":(0,_superstruct.optional)((0,_superstruct.object)({namespaces:_namespace.NamespacesStruct})),wallet_snap:(0,_superstruct.optional)(SnapIdsStruct)});exports.PermissionsStruct=PermissionsStruct;const SnapManifestStruct=(0,_superstruct.object)({version:_utils.VersionStruct,description:(0,_superstruct.size)((0,_superstruct.string)(),1,280),proposedName:(0,_superstruct.size)((0,_superstruct.pattern)((0,_superstruct.string)(),/^(?:[A-Za-z0-9-_]+( [A-Za-z0-9-_]+)*)|(?:(?:@[A-Za-z0-9-*~][A-Za-z0-9-*._~]*\/)?[A-Za-z0-9-~][A-Za-z0-9-._~]*)$/u),1,214),repository:(0,_superstruct.optional)((0,_superstruct.object)({type:(0,_superstruct.size)((0,_superstruct.string)(),1,1/0),url:(0,_superstruct.size)((0,_superstruct.string)(),1,1/0)})),source:(0,_superstruct.object)({shasum:_utils.ChecksumStruct,location:(0,_superstruct.object)({npm:(0,_superstruct.object)({filePath:(0,_superstruct.size)((0,_superstruct.string)(),1,1/0),iconPath:(0,_superstruct.optional)((0,_superstruct.size)((0,_superstruct.string)(),1,1/0)),packageName:_types.NameStruct,registry:(0,_superstruct.union)([(0,_superstruct.literal)("https://registry.npmjs.org"),(0,_superstruct.literal)("https://registry.npmjs.org/")])})})}),initialPermissions:PermissionsStruct,manifestVersion:(0,_superstruct.literal)("0.1")});function isSnapManifest(t){return(0,_superstruct.is)(t,SnapManifestStruct)}function assertIsSnapManifest(t){(0,_utils.assertStruct)(t,SnapManifestStruct,`"${_types.NpmSnapFileNames.Manifest}" is invalid`)}function createSnapManifest(t){return(0,_superstruct.create)(t,SnapManifestStruct)}exports.SnapManifestStruct=SnapManifestStruct;
|
|
2345
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SnapManifestStruct=exports.SnapIdsStruct=exports.SnapGetBip32EntropyPermissionsStruct=exports.SemVerRangeStruct=exports.PermissionsStruct=exports.Bip32PathStruct=exports.Bip32EntropyStruct=void 0,exports.assertIsSnapManifest=assertIsSnapManifest,exports.bip32entropy=void 0,exports.createSnapManifest=createSnapManifest,exports.isSnapManifest=isSnapManifest;var _utils=require("@metamask/utils"),_superstruct=require("superstruct"),_cronjob=require("../cronjob"),_entropy=require("../entropy"),_jsonRpc=require("../json-rpc"),_namespace=require("../namespace"),_snaps=require("../snaps"),_types=require("../types");const FORBIDDEN_PURPOSES=[_entropy.SIP_6_MAGIC_VALUE,_entropy.STATE_ENCRYPTION_MAGIC_VALUE],BIP32_INDEX_REGEX=/^\d+'?$/u,Bip32PathStruct=(0,_superstruct.refine)((0,_superstruct.array)((0,_superstruct.string)()),"BIP-32 path",(t=>0===t.length?"Path must be a non-empty BIP-32 derivation path array":"m"!==t[0]?'Path must start with "m".':t.length<3?"Paths must have a length of at least three.":t.slice(1).some((t=>!BIP32_INDEX_REGEX.test(t)))?"Path must be a valid BIP-32 derivation path array.":!FORBIDDEN_PURPOSES.includes(t[1])||`The purpose "${t[1]}" is not allowed for entropy derivation.`));exports.Bip32PathStruct=Bip32PathStruct;const bip32entropy=t=>(0,_superstruct.refine)(t,"BIP-32 entropy",(t=>"ed25519"!==t.curve||!t.path.slice(1).some((t=>!t.endsWith("'")))||"Ed25519 does not support unhardened paths."));exports.bip32entropy=bip32entropy;const Bip32EntropyStruct=bip32entropy((0,_superstruct.type)({path:Bip32PathStruct,curve:(0,_superstruct.enums)(["ed25519","secp256k1"])}));exports.Bip32EntropyStruct=Bip32EntropyStruct;const SnapGetBip32EntropyPermissionsStruct=(0,_superstruct.size)((0,_superstruct.array)(Bip32EntropyStruct),1,1/0);exports.SnapGetBip32EntropyPermissionsStruct=SnapGetBip32EntropyPermissionsStruct;const SemVerRangeStruct=(0,_superstruct.refine)((0,_superstruct.string)(),"SemVer range",(t=>!!(0,_utils.isValidSemVerRange)(t)||"Expected a valid SemVer range."));exports.SemVerRangeStruct=SemVerRangeStruct;const SnapIdsStruct=(0,_superstruct.refine)((0,_superstruct.record)(_snaps.SnapIdStruct,(0,_superstruct.object)({version:(0,_superstruct.optional)(SemVerRangeStruct)})),"SnapIds",(t=>0!==Object.keys(t).length));exports.SnapIdsStruct=SnapIdsStruct;const PermissionsStruct=(0,_superstruct.type)({"endowment:long-running":(0,_superstruct.optional)((0,_superstruct.object)({})),"endowment:network-access":(0,_superstruct.optional)((0,_superstruct.object)({})),"endowment:webassembly":(0,_superstruct.optional)((0,_superstruct.object)({})),"endowment:transaction-insight":(0,_superstruct.optional)((0,_superstruct.object)({allowTransactionOrigin:(0,_superstruct.optional)((0,_superstruct.boolean)())})),"endowment:cronjob":(0,_superstruct.optional)((0,_superstruct.object)({jobs:_cronjob.CronjobSpecificationArrayStruct})),"endowment:rpc":(0,_superstruct.optional)(_jsonRpc.RpcOriginsStruct),snap_dialog:(0,_superstruct.optional)((0,_superstruct.object)({})),snap_confirm:(0,_superstruct.optional)((0,_superstruct.object)({})),snap_manageState:(0,_superstruct.optional)((0,_superstruct.object)({})),snap_notify:(0,_superstruct.optional)((0,_superstruct.object)({})),snap_getBip32Entropy:(0,_superstruct.optional)(SnapGetBip32EntropyPermissionsStruct),snap_getBip32PublicKey:(0,_superstruct.optional)(SnapGetBip32EntropyPermissionsStruct),snap_getBip44Entropy:(0,_superstruct.optional)((0,_superstruct.size)((0,_superstruct.array)((0,_superstruct.object)({coinType:(0,_superstruct.size)((0,_superstruct.integer)(),0,2**32-1)})),1,1/0)),snap_getEntropy:(0,_superstruct.optional)((0,_superstruct.object)({})),"endowment:keyring":(0,_superstruct.optional)((0,_superstruct.object)({namespaces:_namespace.NamespacesStruct})),wallet_snap:(0,_superstruct.optional)(SnapIdsStruct)});exports.PermissionsStruct=PermissionsStruct;const SnapManifestStruct=(0,_superstruct.object)({version:_utils.VersionStruct,description:(0,_superstruct.size)((0,_superstruct.string)(),1,280),proposedName:(0,_superstruct.size)((0,_superstruct.pattern)((0,_superstruct.string)(),/^(?:[A-Za-z0-9-_]+( [A-Za-z0-9-_]+)*)|(?:(?:@[A-Za-z0-9-*~][A-Za-z0-9-*._~]*\/)?[A-Za-z0-9-~][A-Za-z0-9-._~]*)$/u),1,214),repository:(0,_superstruct.optional)((0,_superstruct.object)({type:(0,_superstruct.size)((0,_superstruct.string)(),1,1/0),url:(0,_superstruct.size)((0,_superstruct.string)(),1,1/0)})),source:(0,_superstruct.object)({shasum:_utils.ChecksumStruct,location:(0,_superstruct.object)({npm:(0,_superstruct.object)({filePath:(0,_superstruct.size)((0,_superstruct.string)(),1,1/0),iconPath:(0,_superstruct.optional)((0,_superstruct.size)((0,_superstruct.string)(),1,1/0)),packageName:_types.NameStruct,registry:(0,_superstruct.union)([(0,_superstruct.literal)("https://registry.npmjs.org"),(0,_superstruct.literal)("https://registry.npmjs.org/")])})})}),initialPermissions:PermissionsStruct,manifestVersion:(0,_superstruct.literal)("0.1"),$schema:(0,_superstruct.optional)((0,_superstruct.string)())});function isSnapManifest(t){return(0,_superstruct.is)(t,SnapManifestStruct)}function assertIsSnapManifest(t){(0,_utils.assertStruct)(t,SnapManifestStruct,`"${_types.NpmSnapFileNames.Manifest}" is invalid`)}function createSnapManifest(t){return(0,_superstruct.create)(t,SnapManifestStruct)}exports.SnapManifestStruct=SnapManifestStruct;
|
|
1894
2346
|
|
|
1895
2347
|
};
|
|
1896
2348
|
};
|
|
1897
2349
|
}
|
|
1898
2350
|
}
|
|
1899
2351
|
}, {package:"external:../snaps-utils/src/manifest/validation.ts",file:"../snaps-utils/src/manifest/validation.ts",}],
|
|
1900
|
-
[
|
|
2352
|
+
[166, {"@metamask/utils":46,"superstruct":142}, function(){
|
|
1901
2353
|
with (this.scopeTerminator) {
|
|
1902
2354
|
with (this.globalThis) {
|
|
1903
2355
|
return function() {
|
|
1904
2356
|
'use strict';
|
|
1905
|
-
// source: /home/runner/work/snaps
|
|
2357
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/namespace.ts
|
|
1906
2358
|
return function (require, module, exports) {
|
|
1907
2359
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SessionStruct=exports.SessionNamespaceStruct=exports.RequestNamespaceStruct=exports.RequestArgumentsStruct=exports.NamespacesStruct=exports.NamespaceStruct=exports.NamespaceIdStruct=exports.MultiChainRequestStruct=exports.LimitedString=exports.ConnectArgumentsStruct=exports.ChainStruct=exports.ChainIdStruct=exports.CHAIN_ID_REGEX=exports.AccountIdStruct=exports.AccountIdArrayStruct=exports.ACCOUNT_ID_REGEX=void 0,exports.assertIsConnectArguments=assertIsConnectArguments,exports.assertIsMultiChainRequest=assertIsMultiChainRequest,exports.assertIsNamespacesObject=assertIsNamespacesObject,exports.assertIsSession=assertIsSession,exports.isAccountId=isAccountId,exports.isAccountIdArray=isAccountIdArray,exports.isChainId=isChainId,exports.isConnectArguments=isConnectArguments,exports.isMultiChainRequest=isMultiChainRequest,exports.isNamespace=isNamespace,exports.isNamespaceId=isNamespaceId,exports.isNamespacesObject=isNamespacesObject,exports.parseAccountId=parseAccountId,exports.parseChainId=parseChainId;var _utils=require("@metamask/utils"),_superstruct=require("superstruct");const CHAIN_ID_REGEX=/^(?<namespace>[-a-z0-9]{3,8}):(?<reference>[-a-zA-Z0-9]{1,32})$/u;exports.CHAIN_ID_REGEX=CHAIN_ID_REGEX;const ACCOUNT_ID_REGEX=/^(?<chainId>(?<namespace>[-a-z0-9]{3,8}):(?<reference>[-a-zA-Z0-9]{1,32})):(?<accountAddress>[a-zA-Z0-9]{1,64})$/u;function parseChainId(t){const s=CHAIN_ID_REGEX.exec(t);if(null==s||!s.groups)throw new Error("Invalid chain ID.");return{namespace:s.groups.namespace,reference:s.groups.reference}}function parseAccountId(t){const s=ACCOUNT_ID_REGEX.exec(t);if(null==s||!s.groups)throw new Error("Invalid account ID.");return{address:s.groups.accountAddress,chainId:s.groups.chainId,chain:{namespace:s.groups.namespace,reference:s.groups.reference}}}exports.ACCOUNT_ID_REGEX=ACCOUNT_ID_REGEX;const LimitedString=(0,_superstruct.size)((0,_superstruct.string)(),1,40);exports.LimitedString=LimitedString;const ChainIdStruct=(0,_superstruct.pattern)((0,_superstruct.string)(),CHAIN_ID_REGEX);exports.ChainIdStruct=ChainIdStruct;const AccountIdStruct=(0,_superstruct.pattern)((0,_superstruct.string)(),ACCOUNT_ID_REGEX);exports.AccountIdStruct=AccountIdStruct;const AccountIdArrayStruct=(0,_superstruct.array)(AccountIdStruct);exports.AccountIdArrayStruct=AccountIdArrayStruct;const ChainStruct=(0,_superstruct.object)({id:ChainIdStruct,name:LimitedString});exports.ChainStruct=ChainStruct;const NamespaceStruct=(0,_superstruct.object)({chains:(0,_superstruct.array)(ChainStruct),methods:(0,_superstruct.optional)((0,_superstruct.array)(LimitedString)),events:(0,_superstruct.optional)((0,_superstruct.array)(LimitedString))});exports.NamespaceStruct=NamespaceStruct;const RequestNamespaceStruct=(0,_superstruct.assign)((0,_superstruct.omit)(NamespaceStruct,["chains"]),(0,_superstruct.object)({chains:(0,_superstruct.array)(ChainIdStruct)}));exports.RequestNamespaceStruct=RequestNamespaceStruct;const SessionNamespaceStruct=(0,_superstruct.assign)(RequestNamespaceStruct,(0,_superstruct.object)({accounts:(0,_superstruct.array)(AccountIdStruct)}));exports.SessionNamespaceStruct=SessionNamespaceStruct;const NamespaceIdStruct=(0,_superstruct.pattern)((0,_superstruct.string)(),/^[-a-z0-9]{3,8}$/u);exports.NamespaceIdStruct=NamespaceIdStruct;const NamespacesStruct=(0,_superstruct.record)(NamespaceIdStruct,NamespaceStruct);exports.NamespacesStruct=NamespacesStruct;const SessionStruct=(0,_superstruct.object)({namespaces:(0,_superstruct.record)(NamespaceIdStruct,SessionNamespaceStruct)});function assertIsSession(t){(0,_utils.assertStruct)(t,SessionStruct,"Invalid session")}exports.SessionStruct=SessionStruct;const ConnectArgumentsStruct=(0,_superstruct.object)({requiredNamespaces:(0,_superstruct.record)(NamespaceIdStruct,RequestNamespaceStruct)});exports.ConnectArgumentsStruct=ConnectArgumentsStruct;const RequestArgumentsStruct=(0,_superstruct.assign)((0,_superstruct.partial)((0,_superstruct.pick)(_utils.JsonRpcRequestStruct,["id","jsonrpc"])),(0,_superstruct.omit)(_utils.JsonRpcRequestStruct,["id","jsonrpc"]));exports.RequestArgumentsStruct=RequestArgumentsStruct;const MultiChainRequestStruct=(0,_superstruct.object)({chainId:ChainIdStruct,request:RequestArgumentsStruct});function isNamespaceId(t){return(0,_superstruct.is)(t,NamespaceIdStruct)}function isChainId(t){return(0,_superstruct.is)(t,ChainIdStruct)}function isAccountId(t){return(0,_superstruct.is)(t,AccountIdStruct)}function isAccountIdArray(t){return(0,_superstruct.is)(t,AccountIdArrayStruct)}function isConnectArguments(t){return(0,_superstruct.is)(t,ConnectArgumentsStruct)}function assertIsConnectArguments(t){(0,_utils.assertStruct)(t,ConnectArgumentsStruct,"Invalid connect arguments")}function isMultiChainRequest(t){return(0,_superstruct.is)(t,MultiChainRequestStruct)}function assertIsMultiChainRequest(t){(0,_utils.assertStruct)(t,MultiChainRequestStruct,"Invalid request arguments")}function isNamespace(t){return(0,_superstruct.is)(t,NamespaceStruct)}function isNamespacesObject(t){return(0,_superstruct.is)(t,NamespacesStruct)}function assertIsNamespacesObject(t,s){(0,_utils.assertStruct)(t,NamespacesStruct,"Invalid namespaces object",s)}exports.MultiChainRequestStruct=MultiChainRequestStruct;
|
|
1908
2360
|
|
|
@@ -1911,12 +2363,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1911
2363
|
}
|
|
1912
2364
|
}
|
|
1913
2365
|
}, {package:"external:../snaps-utils/src/namespace.ts",file:"../snaps-utils/src/namespace.ts",}],
|
|
1914
|
-
[
|
|
2366
|
+
[167, {"./namespace":166,"@metamask/utils":46,"superstruct":142}, function(){
|
|
1915
2367
|
with (this.scopeTerminator) {
|
|
1916
2368
|
with (this.globalThis) {
|
|
1917
2369
|
return function() {
|
|
1918
2370
|
'use strict';
|
|
1919
|
-
// source: /home/runner/work/snaps
|
|
2371
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/notification.ts
|
|
1920
2372
|
return function (require, module, exports) {
|
|
1921
2373
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.MetaMaskNotificationStruct=exports.EventStruct=void 0,exports.assertIsEvent=assertIsEvent,exports.assertIsMetaMaskNotification=assertIsMetaMaskNotification,exports.isEvent=isEvent,exports.isMetaMaskNotification=isMetaMaskNotification;var _utils=require("@metamask/utils"),_superstruct=require("superstruct"),_namespace=require("./namespace");const EventStruct=(0,_superstruct.object)({name:(0,_superstruct.string)(),data:(0,_superstruct.unknown)()});function isEvent(t){return(0,_superstruct.is)(t,EventStruct)}function assertIsEvent(t){(0,_utils.assertStruct)(t,EventStruct,"Invalid event")}exports.EventStruct=EventStruct;const MetaMaskNotificationStruct=(0,_superstruct.object)({method:(0,_superstruct.literal)("multichainHack_metamask_event"),params:(0,_superstruct.object)({chainId:_namespace.ChainIdStruct,event:EventStruct})});function isMetaMaskNotification(t){return(0,_superstruct.is)(t,MetaMaskNotificationStruct)}function assertIsMetaMaskNotification(t){(0,_utils.assertStruct)(t,MetaMaskNotificationStruct,"Invalid notification")}exports.MetaMaskNotificationStruct=MetaMaskNotificationStruct;
|
|
1922
2374
|
|
|
@@ -1925,12 +2377,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1925
2377
|
}
|
|
1926
2378
|
}
|
|
1927
2379
|
}, {package:"external:../snaps-utils/src/notification.ts",file:"../snaps-utils/src/notification.ts",}],
|
|
1928
|
-
[
|
|
2380
|
+
[168, {"@metamask/utils":46}, function(){
|
|
1929
2381
|
with (this.scopeTerminator) {
|
|
1930
2382
|
with (this.globalThis) {
|
|
1931
2383
|
return function() {
|
|
1932
2384
|
'use strict';
|
|
1933
|
-
// source: /home/runner/work/snaps
|
|
2385
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/path.ts
|
|
1934
2386
|
return function (require, module, exports) {
|
|
1935
2387
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.normalizeRelative=normalizeRelative;var _utils=require("@metamask/utils");function normalizeRelative(e){return(0,_utils.assert)(!e.startsWith("/")),(0,_utils.assert)(-1===e.search(/:|\/\//u),`Path "${e}" potentially an URI instead of local relative`),e.startsWith("./")?e.slice(2):e}
|
|
1936
2388
|
|
|
@@ -1939,26 +2391,26 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1939
2391
|
}
|
|
1940
2392
|
}
|
|
1941
2393
|
}, {package:"external:../snaps-utils/src/path.ts",file:"../snaps-utils/src/path.ts",}],
|
|
1942
|
-
[
|
|
2394
|
+
[169, {"./caveats":152,"./checksum":153,"./types":170,"@metamask/utils":46,"@scure/base":61,"fast-json-stable-stringify":76,"superstruct":142,"validate-npm-package-name":145}, function(){
|
|
1943
2395
|
with (this.scopeTerminator) {
|
|
1944
2396
|
with (this.globalThis) {
|
|
1945
2397
|
return function() {
|
|
1946
2398
|
'use strict';
|
|
1947
|
-
// source: /home/runner/work/snaps
|
|
2399
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/snaps.ts
|
|
1948
2400
|
return function (require, module, exports) {
|
|
1949
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SnapStatusEvents=exports.SnapStatus=exports.SnapIdStruct=exports.ProgrammaticallyFixableSnapError=exports.PROPOSED_NAME_REGEX=exports.NpmSnapIdStruct=exports.LocalSnapIdStruct=exports.LOCALHOST_HOSTNAMES=exports.HttpSnapIdStruct=exports.BaseSnapIdStruct=void 0,exports.assertIsValidSnapId=assertIsValidSnapId,exports.getSnapChecksum=getSnapChecksum,exports.getSnapPrefix=getSnapPrefix,exports.isCaipChainId=isCaipChainId,exports.isSnapPermitted=isSnapPermitted,exports.validateSnapShasum=validateSnapShasum,exports.verifyRequestedSnapPermissions=verifyRequestedSnapPermissions;var _utils=require("@metamask/utils"),_base=require("@scure/base"),_fastJsonStableStringify=_interopRequireDefault(require("fast-json-stable-stringify")),_superstruct=require("superstruct"),_validateNpmPackageName=_interopRequireDefault(require("validate-npm-package-name")),_caveats=require("./caveats"),_checksum=require("./checksum"),_types=require("./types");function _interopRequireDefault(t){return t&&t.__esModule?t:{default:t}}function _defineProperty(t,e,r){return(e=_toPropertyKey(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function _toPropertyKey(t){var e=_toPrimitive(t,"string");return"symbol"==typeof e?e:String(e)}function _toPrimitive(t,e){if("object"!=typeof t||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var s=r.call(t,e||"default");if("object"!=typeof s)return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}const PROPOSED_NAME_REGEX=/^(?:[A-Za-z0-9-_]+( [A-Za-z0-9-_]+)*)|(?:(?:@[A-Za-z0-9-*~][A-Za-z0-9-*._~]*\/)?[A-Za-z0-9-~][A-Za-z0-9-._~]*)$/u;exports.PROPOSED_NAME_REGEX=PROPOSED_NAME_REGEX;let SnapStatus=function(t){return t.Installing="installing",t.Updating="updating",t.Running="running",t.Stopped="stopped",t.Crashed="crashed",t}({});exports.SnapStatus=SnapStatus;let SnapStatusEvents=function(t){return t.Start="START",t.Stop="STOP",t.Crash="CRASH",t.Update="UPDATE",t}({});exports.SnapStatusEvents=SnapStatusEvents;class ProgrammaticallyFixableSnapError extends Error{constructor(t,e){super(t),_defineProperty(this,"reason",void 0),this.reason=e}}function getChecksummableManifest(t){const e=t.clone();return delete e.result.source.shasum,e.value=(0,_fastJsonStableStringify.default)(e.result),e}function getSnapChecksum(t){const{manifest:e,sourceCode:r,svgIcon:s}=t,a=[getChecksummableManifest(e),r,s].filter((t=>void 0!==t));return _base.base64.encode((0,_checksum.checksumFiles)(a))}function validateSnapShasum(t,e="Invalid Snap manifest: manifest shasum does not match computed shasum."){if(t.manifest.result.source.shasum!==getSnapChecksum(t))throw new ProgrammaticallyFixableSnapError(e,_types.SnapValidationFailureReason.ShasumMismatch)}exports.ProgrammaticallyFixableSnapError=ProgrammaticallyFixableSnapError;const LOCALHOST_HOSTNAMES=["localhost","127.0.0.1","[::1]"];exports.LOCALHOST_HOSTNAMES=LOCALHOST_HOSTNAMES;const BaseSnapIdStruct=(0,_superstruct.pattern)((0,_superstruct.string)(),/^[\x21-\x7E]*$/u);exports.BaseSnapIdStruct=BaseSnapIdStruct;const LocalSnapIdSubUrlStruct=(0,_types.uri)({protocol:(0,_superstruct.enums)(["http:","https:"]),hostname:(0,_superstruct.enums)(LOCALHOST_HOSTNAMES),hash:(0,_superstruct.empty)((0,_superstruct.string)()),search:(0,_superstruct.empty)((0,_superstruct.string)())}),LocalSnapIdStruct=(0,_superstruct.refine)(BaseSnapIdStruct,"local Snap Id",(t=>{if(!t.startsWith(_types.SnapIdPrefixes.local))return`Expected local snap ID, got "${t}".`;const[e]=(0,_superstruct.validate)(t.slice(_types.SnapIdPrefixes.local.length),LocalSnapIdSubUrlStruct);return e??!0}));exports.LocalSnapIdStruct=LocalSnapIdStruct;const NpmSnapIdStruct=(0,_superstruct.intersection)([BaseSnapIdStruct,(0,_types.uri)({protocol:(0,_superstruct.literal)(_types.SnapIdPrefixes.npm),pathname:(0,_superstruct.refine)((0,_superstruct.string)(),"package name",(function*(t){const e=t.startsWith("/")?t.slice(1):t,{errors:r,validForNewPackages:s,warnings:a}=(0,_validateNpmPackageName.default)(e);return s||(void 0===r?((0,_utils.assert)(void 0!==a),yield*a):yield*r),!0})),search:(0,_superstruct.empty)((0,_superstruct.string)()),hash:(0,_superstruct.empty)((0,_superstruct.string)())})]);exports.NpmSnapIdStruct=NpmSnapIdStruct;const HttpSnapIdStruct=(0,_superstruct.intersection)([BaseSnapIdStruct,(0,_types.uri)({protocol:(0,_superstruct.enums)(["http:","https:"]),search:(0,_superstruct.empty)((0,_superstruct.string)()),hash:(0,_superstruct.empty)((0,_superstruct.string)())})]);exports.HttpSnapIdStruct=HttpSnapIdStruct;const SnapIdStruct=(0,_superstruct.union)([NpmSnapIdStruct,LocalSnapIdStruct]);function getSnapPrefix(t){const e=Object.values(_types.SnapIdPrefixes).find((e=>t.startsWith(e)));if(void 0!==e)return e;throw new Error(`Invalid or no prefix found for "${t}"`)}function assertIsValidSnapId(t){(0,_utils.assertStruct)(t,SnapIdStruct,"Invalid snap ID")}function isCaipChainId(t){return"string"==typeof t&&/^(?<namespace>[-a-z0-9]{3,8}):(?<reference>[-a-zA-Z0-9]{1,32})$/u.test(t)}function isSnapPermitted(t,e){var r,s,a;return Boolean(null===(r=((null==t||null===(s=t.wallet_snap)||void 0===s||null===(a=s.caveats)||void 0===a?void 0:a.find((t=>t.type===_caveats.SnapCaveatType.SnapIds)))??{}).value)||void 0===r?void 0:r[e])}function verifyRequestedSnapPermissions(t){(0,_utils.assert)((0,_utils.isObject)(t),"Requested permissions must be an object.");const{wallet_snap:e}=t;(0,_utils.assert)((0,_utils.isObject)(e),"wallet_snap is missing from the requested permissions.");const{caveats:r}=e;(0,_utils.assert)(Array.isArray(r)&&1===r.length,"wallet_snap must have a caveat property with a single-item array value.");const[s]=r;(0,_utils.assert)((0,_utils.isObject)(s)&&s.type===_caveats.SnapCaveatType.SnapIds&&(0,_utils.isObject)(s.value),`The requested permissions do not have a valid ${_caveats.SnapCaveatType.SnapIds} caveat.`)}exports.SnapIdStruct=SnapIdStruct;
|
|
2401
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.SnapStatusEvents=exports.SnapStatus=exports.SnapIdStruct=exports.ProgrammaticallyFixableSnapError=exports.PROPOSED_NAME_REGEX=exports.NpmSnapIdStruct=exports.LocalSnapIdStruct=exports.LOCALHOST_HOSTNAMES=exports.HttpSnapIdStruct=exports.BaseSnapIdStruct=void 0,exports.assertIsValidSnapId=assertIsValidSnapId,exports.getSnapChecksum=getSnapChecksum,exports.getSnapPrefix=getSnapPrefix,exports.isCaipChainId=isCaipChainId,exports.isSnapPermitted=isSnapPermitted,exports.stripSnapPrefix=stripSnapPrefix,exports.validateSnapShasum=validateSnapShasum,exports.verifyRequestedSnapPermissions=verifyRequestedSnapPermissions;var _utils=require("@metamask/utils"),_base=require("@scure/base"),_fastJsonStableStringify=_interopRequireDefault(require("fast-json-stable-stringify")),_superstruct=require("superstruct"),_validateNpmPackageName=_interopRequireDefault(require("validate-npm-package-name")),_caveats=require("./caveats"),_checksum=require("./checksum"),_types=require("./types");function _interopRequireDefault(t){return t&&t.__esModule?t:{default:t}}function _defineProperty(t,e,r){return(e=_toPropertyKey(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function _toPropertyKey(t){var e=_toPrimitive(t,"string");return"symbol"==typeof e?e:String(e)}function _toPrimitive(t,e){if("object"!=typeof t||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var s=r.call(t,e||"default");if("object"!=typeof s)return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}const PROPOSED_NAME_REGEX=/^(?:[A-Za-z0-9-_]+( [A-Za-z0-9-_]+)*)|(?:(?:@[A-Za-z0-9-*~][A-Za-z0-9-*._~]*\/)?[A-Za-z0-9-~][A-Za-z0-9-._~]*)$/u;exports.PROPOSED_NAME_REGEX=PROPOSED_NAME_REGEX;let SnapStatus=function(t){return t.Installing="installing",t.Updating="updating",t.Running="running",t.Stopped="stopped",t.Crashed="crashed",t}({});exports.SnapStatus=SnapStatus;let SnapStatusEvents=function(t){return t.Start="START",t.Stop="STOP",t.Crash="CRASH",t.Update="UPDATE",t}({});exports.SnapStatusEvents=SnapStatusEvents;class ProgrammaticallyFixableSnapError extends Error{constructor(t,e){super(t),_defineProperty(this,"reason",void 0),this.reason=e}}function getChecksummableManifest(t){const e=t.clone();return delete e.result.source.shasum,e.value=(0,_fastJsonStableStringify.default)(e.result),e}function getSnapChecksum(t){const{manifest:e,sourceCode:r,svgIcon:s}=t,a=[getChecksummableManifest(e),r,s].filter((t=>void 0!==t));return _base.base64.encode((0,_checksum.checksumFiles)(a))}function validateSnapShasum(t,e="Invalid Snap manifest: manifest shasum does not match computed shasum."){if(t.manifest.result.source.shasum!==getSnapChecksum(t))throw new ProgrammaticallyFixableSnapError(e,_types.SnapValidationFailureReason.ShasumMismatch)}exports.ProgrammaticallyFixableSnapError=ProgrammaticallyFixableSnapError;const LOCALHOST_HOSTNAMES=["localhost","127.0.0.1","[::1]"];exports.LOCALHOST_HOSTNAMES=LOCALHOST_HOSTNAMES;const BaseSnapIdStruct=(0,_superstruct.pattern)((0,_superstruct.string)(),/^[\x21-\x7E]*$/u);exports.BaseSnapIdStruct=BaseSnapIdStruct;const LocalSnapIdSubUrlStruct=(0,_types.uri)({protocol:(0,_superstruct.enums)(["http:","https:"]),hostname:(0,_superstruct.enums)(LOCALHOST_HOSTNAMES),hash:(0,_superstruct.empty)((0,_superstruct.string)()),search:(0,_superstruct.empty)((0,_superstruct.string)())}),LocalSnapIdStruct=(0,_superstruct.refine)(BaseSnapIdStruct,"local Snap Id",(t=>{if(!t.startsWith(_types.SnapIdPrefixes.local))return`Expected local snap ID, got "${t}".`;const[e]=(0,_superstruct.validate)(t.slice(_types.SnapIdPrefixes.local.length),LocalSnapIdSubUrlStruct);return e??!0}));exports.LocalSnapIdStruct=LocalSnapIdStruct;const NpmSnapIdStruct=(0,_superstruct.intersection)([BaseSnapIdStruct,(0,_types.uri)({protocol:(0,_superstruct.literal)(_types.SnapIdPrefixes.npm),pathname:(0,_superstruct.refine)((0,_superstruct.string)(),"package name",(function*(t){const e=t.startsWith("/")?t.slice(1):t,{errors:r,validForNewPackages:s,warnings:a}=(0,_validateNpmPackageName.default)(e);return s||(void 0===r?((0,_utils.assert)(void 0!==a),yield*a):yield*r),!0})),search:(0,_superstruct.empty)((0,_superstruct.string)()),hash:(0,_superstruct.empty)((0,_superstruct.string)())})]);exports.NpmSnapIdStruct=NpmSnapIdStruct;const HttpSnapIdStruct=(0,_superstruct.intersection)([BaseSnapIdStruct,(0,_types.uri)({protocol:(0,_superstruct.enums)(["http:","https:"]),search:(0,_superstruct.empty)((0,_superstruct.string)()),hash:(0,_superstruct.empty)((0,_superstruct.string)())})]);exports.HttpSnapIdStruct=HttpSnapIdStruct;const SnapIdStruct=(0,_superstruct.union)([NpmSnapIdStruct,LocalSnapIdStruct]);function getSnapPrefix(t){const e=Object.values(_types.SnapIdPrefixes).find((e=>t.startsWith(e)));if(void 0!==e)return e;throw new Error(`Invalid or no prefix found for "${t}"`)}function stripSnapPrefix(t){return t.replace(getSnapPrefix(t),"")}function assertIsValidSnapId(t){(0,_utils.assertStruct)(t,SnapIdStruct,"Invalid snap ID")}function isCaipChainId(t){return"string"==typeof t&&/^(?<namespace>[-a-z0-9]{3,8}):(?<reference>[-a-zA-Z0-9]{1,32})$/u.test(t)}function isSnapPermitted(t,e){var r,s,a;return Boolean(null===(r=((null==t||null===(s=t.wallet_snap)||void 0===s||null===(a=s.caveats)||void 0===a?void 0:a.find((t=>t.type===_caveats.SnapCaveatType.SnapIds)))??{}).value)||void 0===r?void 0:r[e])}function verifyRequestedSnapPermissions(t){(0,_utils.assert)((0,_utils.isObject)(t),"Requested permissions must be an object.");const{wallet_snap:e}=t;(0,_utils.assert)((0,_utils.isObject)(e),"wallet_snap is missing from the requested permissions.");const{caveats:r}=e;(0,_utils.assert)(Array.isArray(r)&&1===r.length,"wallet_snap must have a caveat property with a single-item array value.");const[s]=r;(0,_utils.assert)((0,_utils.isObject)(s)&&s.type===_caveats.SnapCaveatType.SnapIds&&(0,_utils.isObject)(s.value),`The requested permissions do not have a valid ${_caveats.SnapCaveatType.SnapIds} caveat.`)}exports.SnapIdStruct=SnapIdStruct;
|
|
1950
2402
|
|
|
1951
2403
|
};
|
|
1952
2404
|
};
|
|
1953
2405
|
}
|
|
1954
2406
|
}
|
|
1955
2407
|
}, {package:"external:../snaps-utils/src/snaps.ts",file:"../snaps-utils/src/snaps.ts",}],
|
|
1956
|
-
[
|
|
2408
|
+
[170, {"@metamask/utils":46,"superstruct":142}, function(){
|
|
1957
2409
|
with (this.scopeTerminator) {
|
|
1958
2410
|
with (this.globalThis) {
|
|
1959
2411
|
return function() {
|
|
1960
2412
|
'use strict';
|
|
1961
|
-
// source: /home/runner/work/snaps
|
|
2413
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/types.ts
|
|
1962
2414
|
return function (require, module, exports) {
|
|
1963
2415
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.WALLET_SNAP_PERMISSION_KEY=exports.SnapValidationFailureReason=exports.SnapIdPrefixes=exports.SNAP_STREAM_NAMES=exports.SNAP_EXPORT_NAMES=exports.NpmSnapPackageJsonStruct=exports.NpmSnapFileNames=exports.NameStruct=exports.HandlerType=void 0,exports.assertIsNpmSnapPackageJson=assertIsNpmSnapPackageJson,exports.isNpmSnapPackageJson=isNpmSnapPackageJson,exports.isValidUrl=isValidUrl,exports.uri=void 0;var _utils=require("@metamask/utils"),_superstruct=require("superstruct");let NpmSnapFileNames=function(t){return t.PackageJson="package.json",t.Manifest="snap.manifest.json",t}({});exports.NpmSnapFileNames=NpmSnapFileNames;const NameStruct=(0,_superstruct.size)((0,_superstruct.pattern)((0,_superstruct.string)(),/^(?:@[a-z0-9-*~][a-z0-9-*._~]*\/)?[a-z0-9-~][a-z0-9-._~]*$/u),1,214);exports.NameStruct=NameStruct;const NpmSnapPackageJsonStruct=(0,_superstruct.type)({version:_utils.VersionStruct,name:NameStruct,main:(0,_superstruct.optional)((0,_superstruct.size)((0,_superstruct.string)(),1,1/0)),repository:(0,_superstruct.optional)((0,_superstruct.object)({type:(0,_superstruct.size)((0,_superstruct.string)(),1,1/0),url:(0,_superstruct.size)((0,_superstruct.string)(),1,1/0)}))});function isNpmSnapPackageJson(t){return(0,_superstruct.is)(t,NpmSnapPackageJsonStruct)}function assertIsNpmSnapPackageJson(t){(0,_utils.assertStruct)(t,NpmSnapPackageJsonStruct,`"${NpmSnapFileNames.PackageJson}" is invalid`)}exports.NpmSnapPackageJsonStruct=NpmSnapPackageJsonStruct;let SnapIdPrefixes=function(t){return t.npm="npm:",t.local="local:",t}({});exports.SnapIdPrefixes=SnapIdPrefixes;let SnapValidationFailureReason=function(t){return t.NameMismatch='"name" field mismatch',t.VersionMismatch='"version" field mismatch',t.RepositoryMismatch='"repository" field mismatch',t.ShasumMismatch='"shasum" field mismatch',t}({});exports.SnapValidationFailureReason=SnapValidationFailureReason;let SNAP_STREAM_NAMES=function(t){return t.JSON_RPC="jsonRpc",t.COMMAND="command",t}({});exports.SNAP_STREAM_NAMES=SNAP_STREAM_NAMES;let HandlerType=function(t){return t.OnRpcRequest="onRpcRequest",t.OnTransaction="onTransaction",t.SnapKeyring="keyring",t.OnCronjob="onCronjob",t}({});exports.HandlerType=HandlerType;const SNAP_EXPORT_NAMES=Object.values(HandlerType);exports.SNAP_EXPORT_NAMES=SNAP_EXPORT_NAMES;const uri=(t={})=>(0,_superstruct.refine)((0,_superstruct.union)([(0,_superstruct.string)(),(0,_superstruct.instance)(URL)]),"uri",(e=>{try{const s=new URL(e),r=(0,_superstruct.type)(t);return(0,_superstruct.assert)(s,r),!0}catch{return`Expected URL, got "${e.toString()}".`}}));function isValidUrl(t,e={}){return(0,_superstruct.is)(t,uri(e))}exports.uri=uri;const WALLET_SNAP_PERMISSION_KEY="wallet_snap";exports.WALLET_SNAP_PERMISSION_KEY="wallet_snap";
|
|
1964
2416
|
|
|
@@ -1967,12 +2419,26 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1967
2419
|
}
|
|
1968
2420
|
}
|
|
1969
2421
|
}, {package:"external:../snaps-utils/src/types.ts",file:"../snaps-utils/src/types.ts",}],
|
|
1970
|
-
[
|
|
2422
|
+
[171, {"./icon":159,"./manifest/validation":165,"./snaps":169}, function(){
|
|
2423
|
+
with (this.scopeTerminator) {
|
|
2424
|
+
with (this.globalThis) {
|
|
2425
|
+
return function() {
|
|
2426
|
+
'use strict';
|
|
2427
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/validation.ts
|
|
2428
|
+
return function (require, module, exports) {
|
|
2429
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.validateFetchedSnap=validateFetchedSnap;var _icon=require("./icon"),_validation=require("./manifest/validation"),_snaps=require("./snaps");function validateFetchedSnap(e){(0,_validation.assertIsSnapManifest)(e.manifest.result),(0,_snaps.validateSnapShasum)(e),e.svgIcon&&(0,_icon.assertIsSnapIcon)(e.svgIcon)}
|
|
2430
|
+
|
|
2431
|
+
};
|
|
2432
|
+
};
|
|
2433
|
+
}
|
|
2434
|
+
}
|
|
2435
|
+
}, {package:"external:../snaps-utils/src/validation.ts",file:"../snaps-utils/src/validation.ts",}],
|
|
2436
|
+
[172, {"@metamask/utils":46,"semver":123,"superstruct":142}, function(){
|
|
1971
2437
|
with (this.scopeTerminator) {
|
|
1972
2438
|
with (this.globalThis) {
|
|
1973
2439
|
return function() {
|
|
1974
2440
|
'use strict';
|
|
1975
|
-
// source: /home/runner/work/snaps
|
|
2441
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/versions.ts
|
|
1976
2442
|
return function (require, module, exports) {
|
|
1977
2443
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.DEFAULT_REQUESTED_SNAP_VERSION=void 0,exports.getTargetVersion=getTargetVersion,exports.resolveVersionRange=resolveVersionRange;var _utils=require("@metamask/utils"),_semver=require("semver"),_superstruct=require("superstruct");const DEFAULT_REQUESTED_SNAP_VERSION="*";function getTargetVersion(e,r){const s=(0,_semver.maxSatisfying)(e,r);return s||(0,_semver.maxSatisfying)(e,r,{includePrerelease:!0})}function resolveVersionRange(e){return void 0===e||"latest"===e?[void 0,DEFAULT_REQUESTED_SNAP_VERSION]:(0,_superstruct.validate)(e,_utils.VersionRangeStruct)}exports.DEFAULT_REQUESTED_SNAP_VERSION=DEFAULT_REQUESTED_SNAP_VERSION;
|
|
1978
2444
|
|
|
@@ -1981,12 +2447,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1981
2447
|
}
|
|
1982
2448
|
}
|
|
1983
2449
|
}, {package:"external:../snaps-utils/src/versions.ts",file:"../snaps-utils/src/versions.ts",}],
|
|
1984
|
-
[
|
|
2450
|
+
[173, {"../deep-clone":155,"@metamask/utils":46}, function(){
|
|
1985
2451
|
with (this.scopeTerminator) {
|
|
1986
2452
|
with (this.globalThis) {
|
|
1987
2453
|
return function() {
|
|
1988
2454
|
'use strict';
|
|
1989
|
-
// source: /home/runner/work/snaps
|
|
2455
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/virtual-file/VirtualFile.ts
|
|
1990
2456
|
return function (require, module, exports) {
|
|
1991
2457
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.VirtualFile=void 0;var _utils=require("@metamask/utils"),_deepClone=require("../deep-clone");function _defineProperty(e,t,i){return(t=_toPropertyKey(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function _toPropertyKey(e){var t=_toPrimitive(e,"string");return"symbol"==typeof t?t:String(t)}function _toPrimitive(e,t){if("object"!=typeof e||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var r=i.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}class VirtualFile{constructor(e){var t,i,r,o;let l;_defineProperty(this,"value",void 0),_defineProperty(this,"result",void 0),_defineProperty(this,"data",void 0),_defineProperty(this,"path",void 0),l="string"==typeof e||e instanceof Uint8Array?{value:e}:e,this.value=(null===(t=l)||void 0===t?void 0:t.value)??"",this.result=(null===(i=l)||void 0===i?void 0:i.result)??void 0,this.data=(null===(r=l)||void 0===r?void 0:r.data)??{},this.path=(null===(o=l)||void 0===o?void 0:o.path)??"/"}toString(e){if("string"==typeof this.value)return(0,_utils.assert)(void 0===e,"Tried to encode string."),this.value;return new TextDecoder(e).decode(this.value)}clone(){const e=new VirtualFile;return"string"==typeof this.value?e.value=this.value:e.value=this.value.slice(0),e.result=(0,_deepClone.deepClone)(this.result),e.data=(0,_deepClone.deepClone)(this.data),e.path=this.path,e}}exports.VirtualFile=VirtualFile;
|
|
1992
2458
|
|
|
@@ -1995,12 +2461,12 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
1995
2461
|
}
|
|
1996
2462
|
}
|
|
1997
2463
|
}, {package:"external:../snaps-utils/src/virtual-file/VirtualFile.ts",file:"../snaps-utils/src/virtual-file/VirtualFile.ts",}],
|
|
1998
|
-
[
|
|
2464
|
+
[174, {"./VirtualFile":173}, function(){
|
|
1999
2465
|
with (this.scopeTerminator) {
|
|
2000
2466
|
with (this.globalThis) {
|
|
2001
2467
|
return function() {
|
|
2002
2468
|
'use strict';
|
|
2003
|
-
// source: /home/runner/work/snaps
|
|
2469
|
+
// source: /home/runner/work/snaps/snaps/packages/snaps-utils/src/virtual-file/index.browser.ts
|
|
2004
2470
|
return function (require, module, exports) {
|
|
2005
2471
|
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var _VirtualFile=require("./VirtualFile");Object.keys(_VirtualFile).forEach((function(e){"default"!==e&&"__esModule"!==e&&(e in exports&&exports[e]===_VirtualFile[e]||Object.defineProperty(exports,e,{enumerable:!0,get:function(){return _VirtualFile[e]}}))}));
|
|
2006
2472
|
|
|
@@ -2008,5 +2474,5 @@ function deprecate(r,e){if(config("noDeprecation"))return r;var o=!1;return func
|
|
|
2008
2474
|
};
|
|
2009
2475
|
}
|
|
2010
2476
|
}
|
|
2011
|
-
}, {package:"external:../snaps-utils/src/virtual-file/index.browser.ts",file:"../snaps-utils/src/virtual-file/index.browser.ts",}]],[
|
|
2477
|
+
}, {package:"external:../snaps-utils/src/virtual-file/index.browser.ts",file:"../snaps-utils/src/virtual-file/index.browser.ts",}]],[151],{"resources":{"@metamask/post-message-stream":{"globals":{"MessageEvent.prototype":true,"WorkerGlobalScope":true,"addEventListener":true,"browser":true,"chrome":true,"location.origin":true,"postMessage":true,"removeEventListener":true},"packages":{"@metamask/post-message-stream>@metamask/utils":true,"@metamask/post-message-stream>readable-stream":true}},"@metamask/post-message-stream>@metamask/utils":{"globals":{"TextDecoder":true,"TextEncoder":true},"packages":{"@metamask/utils>semver":true,"browserify>buffer":true,"eslint>debug":true,"superstruct":true}},"@metamask/post-message-stream>readable-stream":{"packages":{"@metamask/post-message-stream>readable-stream>process-nextick-args":true,"@metamask/post-message-stream>readable-stream>safe-buffer":true,"@metamask/post-message-stream>readable-stream>string_decoder":true,"browserify>browser-resolve":true,"browserify>events":true,"browserify>inherits":true,"browserify>readable-stream>core-util-is":true,"browserify>readable-stream>isarray":true,"browserify>readable-stream>util-deprecate":true,"browserify>timers-browserify":true,"process":true}},"@metamask/post-message-stream>readable-stream>process-nextick-args":{"packages":{"process":true}},"@metamask/post-message-stream>readable-stream>safe-buffer":{"packages":{"browserify>buffer":true}},"@metamask/post-message-stream>readable-stream>string_decoder":{"packages":{"@metamask/post-message-stream>readable-stream>safe-buffer":true}},"@metamask/rpc-methods>@noble/hashes":{"globals":{"TextEncoder":true,"crypto":true}},"@metamask/snaps-utils>@scure/base":{"globals":{"TextDecoder":true,"TextEncoder":true}},"@metamask/snaps-utils>cron-parser":{"packages":{"@metamask/snaps-utils>cron-parser>luxon":true,"browserify>browser-resolve":true}},"@metamask/snaps-utils>cron-parser>luxon":{"globals":{"Intl":true}},"@metamask/snaps-utils>is-svg":{"packages":{"@metamask/snaps-utils>is-svg>fast-xml-parser":true}},"@metamask/snaps-utils>is-svg>fast-xml-parser":{"globals":{"entityName":true,"val":true},"packages":{"@metamask/snaps-utils>is-svg>fast-xml-parser>strnum":true}},"@metamask/snaps-utils>rfdc":{"packages":{"browserify>buffer":true}},"@metamask/snaps-utils>validate-npm-package-name":{"packages":{"@metamask/snaps-utils>validate-npm-package-name>builtins":true}},"@metamask/snaps-utils>validate-npm-package-name>builtins":{"packages":{"@metamask/utils>semver":true,"process":true}},"@metamask/utils":{"globals":{"TextDecoder":true,"TextEncoder":true},"packages":{"@metamask/utils>semver":true,"browserify>buffer":true,"eslint>debug":true,"superstruct":true}},"@metamask/utils>semver":{"globals":{"console.error":true},"packages":{"@metamask/utils>semver>lru-cache":true,"process":true}},"@metamask/utils>semver>lru-cache":{"packages":{"@metamask/utils>semver>lru-cache>yallist":true}},"browserify>buffer":{"globals":{"console":true},"packages":{"buffer>base64-js":true,"buffer>ieee754":true}},"browserify>events":{"globals":{"console":true}},"browserify>readable-stream>core-util-is":{"packages":{"browserify>insert-module-globals>is-buffer":true}},"browserify>readable-stream>util-deprecate":{"globals":{"console.trace":true,"console.warn":true,"localStorage":true}},"browserify>timers-browserify":{"globals":{"clearInterval":true,"clearTimeout":true,"setInterval":true,"setTimeout":true},"packages":{"process":true}},"eslint>debug":{"globals":{"console":true,"document":true,"localStorage":true,"navigator":true,"process":true},"packages":{"eslint>debug>ms":true,"process":true}},"external:../snaps-utils/src/checksum.ts":{"packages":{"@metamask/rpc-methods>@noble/hashes":true,"@metamask/utils":true,"external:../snaps-utils/src/virtual-file/VirtualFile.ts":true}},"external:../snaps-utils/src/cronjob.ts":{"packages":{"@metamask/snaps-utils>cron-parser":true,"@metamask/utils":true,"superstruct":true}},"external:../snaps-utils/src/deep-clone.ts":{"packages":{"@metamask/snaps-utils>rfdc":true}},"external:../snaps-utils/src/icon.ts":{"builtin":{"buffer":true},"packages":{"@metamask/snaps-utils>is-svg":true,"@metamask/utils":true,"browserify>buffer":true}},"external:../snaps-utils/src/index.browser.ts":{"packages":{"external:../snaps-utils/src/caveats.ts":true,"external:../snaps-utils/src/checksum.ts":true,"external:../snaps-utils/src/cronjob.ts":true,"external:../snaps-utils/src/deep-clone.ts":true,"external:../snaps-utils/src/default-endowments.ts":true,"external:../snaps-utils/src/entropy.ts":true,"external:../snaps-utils/src/handlers.ts":true,"external:../snaps-utils/src/iframe.ts":true,"external:../snaps-utils/src/json-rpc.ts":true,"external:../snaps-utils/src/logging.ts":true,"external:../snaps-utils/src/manifest/index.browser.ts":true,"external:../snaps-utils/src/namespace.ts":true,"external:../snaps-utils/src/notification.ts":true,"external:../snaps-utils/src/path.ts":true,"external:../snaps-utils/src/snaps.ts":true,"external:../snaps-utils/src/types.ts":true,"external:../snaps-utils/src/validation.ts":true,"external:../snaps-utils/src/versions.ts":true,"external:../snaps-utils/src/virtual-file/index.browser.ts":true}},"external:../snaps-utils/src/json-rpc.ts":{"packages":{"@metamask/utils":true,"superstruct":true}},"external:../snaps-utils/src/logging.ts":{"globals":{"console":true},"packages":{"@metamask/utils":true}},"external:../snaps-utils/src/manifest/index.browser.ts":{"packages":{"external:../snaps-utils/src/manifest/validation.ts":true}},"external:../snaps-utils/src/manifest/validation.ts":{"packages":{"@metamask/utils":true,"external:../snaps-utils/src/cronjob.ts":true,"external:../snaps-utils/src/entropy.ts":true,"external:../snaps-utils/src/json-rpc.ts":true,"external:../snaps-utils/src/namespace.ts":true,"external:../snaps-utils/src/snaps.ts":true,"external:../snaps-utils/src/types.ts":true,"superstruct":true}},"external:../snaps-utils/src/namespace.ts":{"packages":{"@metamask/utils":true,"superstruct":true}},"external:../snaps-utils/src/notification.ts":{"packages":{"@metamask/utils":true,"external:../snaps-utils/src/namespace.ts":true,"superstruct":true}},"external:../snaps-utils/src/path.ts":{"packages":{"@metamask/utils":true}},"external:../snaps-utils/src/snaps.ts":{"packages":{"@metamask/snaps-utils>@scure/base":true,"@metamask/snaps-utils>fast-json-stable-stringify":true,"@metamask/snaps-utils>validate-npm-package-name":true,"@metamask/utils":true,"external:../snaps-utils/src/caveats.ts":true,"external:../snaps-utils/src/checksum.ts":true,"external:../snaps-utils/src/types.ts":true,"superstruct":true}},"external:../snaps-utils/src/types.ts":{"packages":{"@metamask/utils":true,"superstruct":true}},"external:../snaps-utils/src/validation.ts":{"packages":{"external:../snaps-utils/src/icon.ts":true,"external:../snaps-utils/src/manifest/validation.ts":true,"external:../snaps-utils/src/snaps.ts":true}},"external:../snaps-utils/src/versions.ts":{"packages":{"@metamask/utils":true,"@metamask/utils>semver":true,"superstruct":true}},"external:../snaps-utils/src/virtual-file/VirtualFile.ts":{"packages":{"@metamask/utils":true,"external:../snaps-utils/src/deep-clone.ts":true}},"external:../snaps-utils/src/virtual-file/index.browser.ts":{"packages":{"external:../snaps-utils/src/virtual-file/VirtualFile.ts":true}},"process":{"globals":{"clearTimeout":true,"setTimeout":true}}}})
|
|
2012
2478
|
//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsImZpbGUiOiJnZW5lcmF0ZWQuanMiLCJzb3VyY2VSb290IjoiIn0=
|