@loopback/example-webpack 0.5.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.
Files changed (36) hide show
  1. package/CHANGELOG.md +130 -0
  2. package/LICENSE +27 -0
  3. package/README.md +104 -0
  4. package/dist/__tests__/integration/bundle-node.integration.d.ts +1 -0
  5. package/dist/__tests__/integration/bundle-node.integration.js +27 -0
  6. package/dist/__tests__/integration/bundle-node.integration.js.map +1 -0
  7. package/dist/__tests__/integration/bundle-web.integration.d.ts +1 -0
  8. package/dist/__tests__/integration/bundle-web.integration.js +59 -0
  9. package/dist/__tests__/integration/bundle-web.integration.js.map +1 -0
  10. package/dist/__tests__/integration/dependency-injection.integration.d.ts +1 -0
  11. package/dist/__tests__/integration/dependency-injection.integration.js +16 -0
  12. package/dist/__tests__/integration/dependency-injection.integration.js.map +1 -0
  13. package/dist/__tests__/integration/test-helper.d.ts +2 -0
  14. package/dist/__tests__/integration/test-helper.js +31 -0
  15. package/dist/__tests__/integration/test-helper.js.map +1 -0
  16. package/dist/bundle-node.js +2 -0
  17. package/dist/bundle-node.js.LICENSE.txt +38 -0
  18. package/dist/bundle-web.js +2 -0
  19. package/dist/bundle-web.js.LICENSE.txt +54 -0
  20. package/dist/dependency-injection.d.ts +16 -0
  21. package/dist/dependency-injection.js +159 -0
  22. package/dist/dependency-injection.js.map +1 -0
  23. package/dist/index.d.ts +2 -0
  24. package/dist/index.js +10 -0
  25. package/dist/index.js.map +1 -0
  26. package/index.html +31 -0
  27. package/package.json +61 -0
  28. package/src/__tests__/integration/bundle-node.integration.ts +29 -0
  29. package/src/__tests__/integration/bundle-web.integration.ts +70 -0
  30. package/src/__tests__/integration/dependency-injection.integration.ts +15 -0
  31. package/src/__tests__/integration/test-helper.ts +28 -0
  32. package/src/dependency-injection.ts +199 -0
  33. package/src/index.ts +7 -0
  34. package/tsconfig.json +21 -0
  35. package/tsconfig.tsbuildinfo +1 -0
  36. package/webpack.config.js +68 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,130 @@
1
+ # Change Log
2
+
3
+ All notable changes to this project will be documented in this file.
4
+ See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
+
6
+ ## [0.5.1](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.5.0...@loopback/example-webpack@0.5.1) (2021-09-16)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * use puppeteer for browser testing ([e354380](https://github.com/loopbackio/loopback-next/commit/e35438073e5f23c070b4e9e6c76c4b6b4b05cb7a))
12
+
13
+
14
+
15
+
16
+
17
+ # [0.5.0](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.4.1...@loopback/example-webpack@0.5.0) (2021-07-15)
18
+
19
+
20
+ ### Features
21
+
22
+ * **rest:** upgrade to ajv@8.x ([d3b20ed](https://github.com/loopbackio/loopback-next/commit/d3b20edc142d5c014c17ffbfa69f74403793330f))
23
+
24
+
25
+ ### BREAKING CHANGES
26
+
27
+ * **rest:** We upgrade to ajv@8.x, which contains breaking changes
28
+ for validations. See https://github.com/ajv-validator/ajv/blob/master/docs/v6-to-v8-migration.md.
29
+
30
+ Signed-off-by: Raymond Feng <enjoyjava@gmail.com>
31
+
32
+
33
+
34
+
35
+
36
+ ## [0.4.1](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.4.0...@loopback/example-webpack@0.4.1) (2021-06-10)
37
+
38
+ **Note:** Version bump only for package @loopback/example-webpack
39
+
40
+
41
+
42
+
43
+
44
+ # [0.4.0](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.3.1...@loopback/example-webpack@0.4.0) (2021-05-03)
45
+
46
+
47
+ ### Features
48
+
49
+ * support node v16 ([ac99415](https://github.com/loopbackio/loopback-next/commit/ac994154543bde22b4482ba98813351656db1b55))
50
+
51
+
52
+
53
+
54
+
55
+ ## [0.3.1](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.3.0...@loopback/example-webpack@0.3.1) (2021-04-06)
56
+
57
+ **Note:** Version bump only for package @loopback/example-webpack
58
+
59
+
60
+
61
+
62
+
63
+ # [0.3.0](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.2.4...@loopback/example-webpack@0.3.0) (2021-03-18)
64
+
65
+
66
+ ### Features
67
+
68
+ * update package-lock.json to v2 consistently ([dfc3fbd](https://github.com/loopbackio/loopback-next/commit/dfc3fbdae0c9ca9f34c64154a471bef22d5ac6b7))
69
+ * upgrade to TypeScript 4.2.x ([05930bc](https://github.com/loopbackio/loopback-next/commit/05930bc0cece3909dd66f75ad91eeaa2d365a480))
70
+
71
+
72
+
73
+
74
+
75
+ ## [0.2.4](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.2.3...@loopback/example-webpack@0.2.4) (2021-02-09)
76
+
77
+ **Note:** Version bump only for package @loopback/example-webpack
78
+
79
+
80
+
81
+
82
+
83
+ ## [0.2.3](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.2.2...@loopback/example-webpack@0.2.3) (2021-01-21)
84
+
85
+ **Note:** Version bump only for package @loopback/example-webpack
86
+
87
+
88
+
89
+
90
+
91
+ ## [0.2.2](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.2.1...@loopback/example-webpack@0.2.2) (2020-12-07)
92
+
93
+ **Note:** Version bump only for package @loopback/example-webpack
94
+
95
+
96
+
97
+
98
+
99
+ ## [0.2.1](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.2.0...@loopback/example-webpack@0.2.1) (2020-11-18)
100
+
101
+ **Note:** Version bump only for package @loopback/example-webpack
102
+
103
+
104
+
105
+
106
+
107
+ # [0.2.0](https://github.com/loopbackio/loopback-next/compare/@loopback/example-webpack@0.1.0...@loopback/example-webpack@0.2.0) (2020-11-05)
108
+
109
+
110
+ ### Bug Fixes
111
+
112
+ * **cli:** update affected example projects ([a4386e9](https://github.com/loopbackio/loopback-next/commit/a4386e921713739417de5d4795950209d2f14e22)), closes [#3259](https://github.com/loopbackio/loopback-next/issues/3259)
113
+ * **example-webpack:** remove --silent as it's not supported by webpack-cli 4.x ([cf61cef](https://github.com/loopbackio/loopback-next/commit/cf61cef6ef2fd5314ac678db10c28cab8e4f97f2))
114
+
115
+
116
+ ### Features
117
+
118
+ * **example-webpack:** add polyfill for Node.js core modules ([9ee2b6e](https://github.com/loopbackio/loopback-next/commit/9ee2b6ef7ad4ea0566c1b6f967895a2a8917c73f))
119
+ * **example-webpack:** speed up webpack by using js only ([3bd0fa9](https://github.com/loopbackio/loopback-next/commit/3bd0fa91d551eb21750ba9a55b2701ac3d80cfc5))
120
+
121
+
122
+
123
+
124
+
125
+ # 0.1.0 (2020-10-07)
126
+
127
+
128
+ ### Features
129
+
130
+ * **example-webpack:** add an example to generate bundles with webpack ([53bbb3a](https://github.com/loopbackio/loopback-next/commit/53bbb3a1ad36e45672bf8f64257e343f18258bd5))
package/LICENSE ADDED
@@ -0,0 +1,27 @@
1
+ Copyright (c) IBM Corp. 2020.
2
+ Node module: @loopback/example-webpack
3
+ This project is licensed under the MIT License, full text below.
4
+
5
+ --------
6
+
7
+ MIT License
8
+
9
+ MIT License Copyright (c) IBM Corp. 2020
10
+
11
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
12
+ this software and associated documentation files (the "Software"), to deal in
13
+ the Software without restriction, including without limitation the rights to
14
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
15
+ the Software, and to permit persons to whom the Software is furnished to do so,
16
+ subject to the following conditions:
17
+
18
+ The above copyright notice and this permission notice (including the next
19
+ paragraph) shall be included in all copies or substantial portions of the
20
+ Software.
21
+
22
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
24
+ FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
25
+ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
26
+ IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
27
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,104 @@
1
+ # @loopback/example-webpack
2
+
3
+ This example illustrates how to bundle `@loopback/core` using
4
+ [webpack](https://webpack.js.org/) to allow LoopBack's Dependency Injection can
5
+ be run inside a browser.
6
+
7
+ ## Webpack configurations
8
+
9
+ We add `webpack.config.js` to define two configurations for Node.js and Web.
10
+
11
+ ## Use
12
+
13
+ Use one of the following commands to build `dist/bundle-web.js` to package this
14
+ example application into a JavaScript file for browsers.
15
+
16
+ ```sh
17
+ npm run build:webpack-web
18
+ ```
19
+
20
+ ```sh
21
+ npx webpack --config-name web
22
+ ```
23
+
24
+ Now `dist/bundle-web.js` can be used for HTML pages, for example:
25
+
26
+ ```html
27
+ <!DOCTYPE html>
28
+ <html>
29
+ <head>
30
+ <title>LoopBack 4 Core Modules WebPack Demo</title>
31
+ <script src="dist/bundle-web.js" charset="utf-8"></script>
32
+ </head>
33
+ <body>
34
+ <div id="greetings"></div>
35
+
36
+ <script>
37
+ async function greet() {
38
+ const element = document.getElementById('greetings');
39
+
40
+ // Exported TypeScript functions/classes/types/constants are now
41
+ // available under `LoopBack` namespace
42
+ const greetings = await LoopBack.main();
43
+
44
+ const list = greetings.map(g => `<li>${g}</li>`);
45
+ element.innerHTML = `
46
+ <h1>Hello from LoopBack</h1>
47
+ <p/>
48
+ <ul>
49
+ ${list.join('\n')}
50
+ </ul>`;
51
+ return greetings;
52
+ }
53
+
54
+ greet().catch(err => alert(err));
55
+ </script>
56
+ </body>
57
+ </html>
58
+ ```
59
+
60
+ Open `index.html` in a browser, you'll see LoopBack is now running inside the
61
+ browser as client-side JavaScript:
62
+
63
+ ```
64
+ Hello from LoopBack:
65
+ [2020-09-14T07:54:09.220Z] (en) Hello, Jane!
66
+ [2020-09-14T07:54:09.227Z] Hello, John!
67
+ [2020-09-14T07:54:09.230Z] (zh) 你好,John!
68
+ [2020-09-14T07:54:09.231Z] (en) Hello, Jane!
69
+ ```
70
+
71
+ ## CDN
72
+
73
+ Once the package is published to npm, we can use `unpkg` as the CDN using one of
74
+ the following flavors:
75
+
76
+ ```html
77
+ <script src="https://unpkg.com/@loopback/example-webpack" crossorigin></script>
78
+ <script
79
+ src="https://unpkg.com/@loopback/example-webpack@0.1.0"
80
+ crossorigin
81
+ ></script>
82
+ <script
83
+ src="https://unpkg.com/@loopback/example-webpack@0.1.0/dist/bundle-web.js"
84
+ crossorigin
85
+ ></script>
86
+ ```
87
+
88
+ ## Contributions
89
+
90
+ - [Guidelines](https://github.com/loopbackio/loopback-next/blob/master/docs/CONTRIBUTING.md)
91
+ - [Join the team](https://github.com/loopbackio/loopback-next/issues/110)
92
+
93
+ ## Tests
94
+
95
+ Run `npm test` from the root folder.
96
+
97
+ ## Contributors
98
+
99
+ See
100
+ [all contributors](https://github.com/loopbackio/loopback-next/graphs/contributors).
101
+
102
+ ## License
103
+
104
+ MIT
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ // Copyright IBM Corp. 2020. All Rights Reserved.
3
+ // Node module: @loopback/example-webpack
4
+ // This file is licensed under the MIT License.
5
+ // License text available at https://opensource.org/licenses/MIT
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ const testlab_1 = require("@loopback/testlab");
8
+ const test_helper_1 = require("./test-helper");
9
+ describe('bundle-node.js', () => {
10
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
11
+ let bundle;
12
+ before('generate bundle-node.js', async function () {
13
+ // It may take some time to generate the bundle using webpack
14
+ this.timeout(30000);
15
+ await test_helper_1.generateBundle('node');
16
+ bundle = require('../../bundle-node');
17
+ });
18
+ it('invokes main function', async () => {
19
+ const greetings = await bundle.main();
20
+ test_helper_1.assertGreetings(greetings);
21
+ });
22
+ it('has access to Context', async () => {
23
+ const ctx = new bundle.Context('my-ctx');
24
+ testlab_1.expect(ctx.name).to.eql('my-ctx');
25
+ });
26
+ });
27
+ //# sourceMappingURL=bundle-node.integration.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bundle-node.integration.js","sourceRoot":"","sources":["../../../src/__tests__/integration/bundle-node.integration.ts"],"names":[],"mappings":";AAAA,iDAAiD;AACjD,yCAAyC;AACzC,+CAA+C;AAC/C,gEAAgE;;AAEhE,+CAAyC;AACzC,+CAA8D;AAE9D,QAAQ,CAAC,gBAAgB,EAAE,GAAG,EAAE;IAC9B,8DAA8D;IAC9D,IAAI,MAAW,CAAC;IAEhB,MAAM,CAAC,yBAAyB,EAAE,KAAK;QACrC,6DAA6D;QAC7D,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;QACpB,MAAM,4BAAc,CAAC,MAAM,CAAC,CAAC;QAC7B,MAAM,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAAC;IACxC,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,uBAAuB,EAAE,KAAK,IAAI,EAAE;QACrC,MAAM,SAAS,GAAa,MAAM,MAAM,CAAC,IAAI,EAAE,CAAC;QAChD,6BAAe,CAAC,SAAS,CAAC,CAAC;IAC7B,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,uBAAuB,EAAE,KAAK,IAAI,EAAE;QACrC,MAAM,GAAG,GAAG,IAAI,MAAM,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;QACzC,gBAAM,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;IACpC,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1,59 @@
1
+ "use strict";
2
+ // Copyright IBM Corp. 2020. All Rights Reserved.
3
+ // Node module: @loopback/example-webpack
4
+ // This file is licensed under the MIT License.
5
+ // License text available at https://opensource.org/licenses/MIT
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ const tslib_1 = require("tslib");
8
+ const testlab_1 = require("@loopback/testlab");
9
+ const fs_1 = tslib_1.__importDefault(require("fs"));
10
+ const path_1 = tslib_1.__importDefault(require("path"));
11
+ const puppeteer_1 = tslib_1.__importDefault(require("puppeteer"));
12
+ const url_1 = tslib_1.__importDefault(require("url"));
13
+ const test_helper_1 = require("./test-helper");
14
+ //
15
+ /*
16
+ * `zombie` fails to load the html file url with 404 on Windows
17
+ * 1) bundle-web.js
18
+ * "before all" hook for "should see the page with greetings":
19
+ * Error: Server returned status code 404 from file:///C:/projects/loopback-next/examples/webpack/index.html
20
+ * at C:\projects\loopback-next\examples\webpack\node_modules\zombie\lib\document.js:649:15
21
+ * at process._tickCallback (internal/process/next_tick.js:68:7)
22
+ *
23
+ * See https://github.com/assaf/zombie/issues/915
24
+ */
25
+ testlab_1.skipIf(process.platform === 'win32', // Skip on Windows
26
+ describe, 'bundle-web.js', () => {
27
+ before('generate bundle-web.js', async function () {
28
+ // It may take some time to generate the bundle using webpack
29
+ this.timeout(30000);
30
+ await test_helper_1.generateBundle('web');
31
+ testlab_1.expect(fs_1.default.existsSync(path_1.default.join(__dirname, '../../bundle-web.js'))).to.be.true();
32
+ });
33
+ let browser;
34
+ let html;
35
+ before(async function () {
36
+ this.timeout(15000);
37
+ browser = await puppeteer_1.default.launch();
38
+ const page = await browser.newPage();
39
+ await page.goto(url_1.default
40
+ .pathToFileURL(path_1.default.join(__dirname, '../../../index.html'))
41
+ .toString(), { waitUntil: 'networkidle2' });
42
+ html = await page.content();
43
+ /*
44
+ const bodyHandle = await page.$('body');
45
+ html = await page.evaluate(body => body.innerHTML, bodyHandle);
46
+ await bodyHandle!.dispose();
47
+ */
48
+ await browser.close();
49
+ });
50
+ it('should see the page with greetings', () => {
51
+ let body = html;
52
+ body = body.replace(/\[[^\[\]]+\] /g, '');
53
+ testlab_1.expect(body).to.match(/<li>\(en\) Hello, Jane!<\/li>/);
54
+ testlab_1.expect(body).to.match(/<li>Hello, John!<\/li>/);
55
+ testlab_1.expect(body).to.match(/<li>\(zh\) 你好,John!<\/li>/);
56
+ testlab_1.expect(body).to.match(/<li>\(en\) Hello, Jane!<\/li>/);
57
+ });
58
+ });
59
+ //# sourceMappingURL=bundle-web.integration.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bundle-web.integration.js","sourceRoot":"","sources":["../../../src/__tests__/integration/bundle-web.integration.ts"],"names":[],"mappings":";AAAA,iDAAiD;AACjD,yCAAyC;AACzC,+CAA+C;AAC/C,gEAAgE;;;AAEhE,+CAAiD;AACjD,oDAAoB;AAEpB,wDAAwB;AACxB,kEAA6C;AAC7C,sDAAsB;AACtB,+CAA6C;AAE7C,EAAE;AACF;;;;;;;;;GASG;AACH,gBAAM,CACJ,OAAO,CAAC,QAAQ,KAAK,OAAO,EAAE,kBAAkB;AAChD,QAAQ,EACR,eAAe,EACf,GAAG,EAAE;IACH,MAAM,CAAC,wBAAwB,EAAE,KAAK;QACpC,6DAA6D;QAC7D,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;QACpB,MAAM,4BAAc,CAAC,KAAK,CAAC,CAAC;QAC5B,gBAAM,CACJ,YAAE,CAAC,UAAU,CAAC,cAAI,CAAC,IAAI,CAAC,SAAS,EAAE,qBAAqB,CAAC,CAAC,CAC3D,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,EAAE,CAAC;IACjB,CAAC,CAAC,CAAC;IAEH,IAAI,OAAgB,CAAC;IACrB,IAAI,IAAY,CAAC;IACjB,MAAM,CAAC,KAAK;QACV,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;QACpB,OAAO,GAAG,MAAM,mBAAS,CAAC,MAAM,EAAE,CAAC;QACnC,MAAM,IAAI,GAAG,MAAM,OAAO,CAAC,OAAO,EAAE,CAAC;QACrC,MAAM,IAAI,CAAC,IAAI,CACb,aAAG;aACA,aAAa,CAAC,cAAI,CAAC,IAAI,CAAC,SAAS,EAAE,qBAAqB,CAAC,CAAC;aAC1D,QAAQ,EAAE,EACb,EAAC,SAAS,EAAE,cAAc,EAAC,CAC5B,CAAC;QACF,IAAI,GAAG,MAAM,IAAI,CAAC,OAAO,EAAE,CAAC;QAC5B;;;;UAIE;QAEF,MAAM,OAAO,CAAC,KAAK,EAAE,CAAC;IACxB,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,oCAAoC,EAAE,GAAG,EAAE;QAC5C,IAAI,IAAI,GAAG,IAAI,CAAC;QAChB,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,gBAAgB,EAAE,EAAE,CAAC,CAAC;QAC1C,gBAAM,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,+BAA+B,CAAC,CAAC;QACvD,gBAAM,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,wBAAwB,CAAC,CAAC;QAChD,gBAAM,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,2BAA2B,CAAC,CAAC;QACnD,gBAAM,CAAC,IAAI,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,+BAA+B,CAAC,CAAC;IACzD,CAAC,CAAC,CAAC;AACL,CAAC,CACF,CAAC"}
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ // Copyright IBM Corp. 2020. All Rights Reserved.
3
+ // Node module: @loopback/example-webpack
4
+ // This file is licensed under the MIT License.
5
+ // License text available at https://opensource.org/licenses/MIT
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ const __1 = require("../..");
8
+ const test_helper_1 = require("./test-helper");
9
+ describe('dependency injection', () => {
10
+ it('invokes main function', async () => {
11
+ const greetings = await __1.main();
12
+ // Trim date headers
13
+ test_helper_1.assertGreetings(greetings);
14
+ });
15
+ });
16
+ //# sourceMappingURL=dependency-injection.integration.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dependency-injection.integration.js","sourceRoot":"","sources":["../../../src/__tests__/integration/dependency-injection.integration.ts"],"names":[],"mappings":";AAAA,iDAAiD;AACjD,yCAAyC;AACzC,+CAA+C;AAC/C,gEAAgE;;AAEhE,6BAA2B;AAC3B,+CAA8C;AAE9C,QAAQ,CAAC,sBAAsB,EAAE,GAAG,EAAE;IACpC,EAAE,CAAC,uBAAuB,EAAE,KAAK,IAAI,EAAE;QACrC,MAAM,SAAS,GAAa,MAAM,QAAI,EAAE,CAAC;QACzC,oBAAoB;QACpB,6BAAe,CAAC,SAAS,CAAC,CAAC;IAC7B,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare function assertGreetings(greetings: string[]): void;
2
+ export declare function generateBundle(type: 'web' | 'node'): Promise<any[]>;
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ // Copyright IBM Corp. 2020. All Rights Reserved.
3
+ // Node module: @loopback/example-webpack
4
+ // This file is licensed under the MIT License.
5
+ // License text available at https://opensource.org/licenses/MIT
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.generateBundle = exports.assertGreetings = void 0;
8
+ const tslib_1 = require("tslib");
9
+ const testlab_1 = require("@loopback/testlab");
10
+ const events_1 = require("events");
11
+ const path_1 = tslib_1.__importDefault(require("path"));
12
+ const runShell = require('@loopback/build').runShell;
13
+ function assertGreetings(greetings) {
14
+ greetings = greetings.map(g => g.replace(/\[[^\[\]]+\] /, ''));
15
+ testlab_1.expect(greetings).to.eql([
16
+ '(en) Hello, Jane!',
17
+ 'Hello, John!',
18
+ '(zh) 你好,John!',
19
+ '(en) Hello, Jane!',
20
+ ]);
21
+ }
22
+ exports.assertGreetings = assertGreetings;
23
+ function generateBundle(type) {
24
+ const child = runShell('npm', ['run', `build:webpack-${type}`], {
25
+ stdio: 'ignore',
26
+ cwd: path_1.default.join(__dirname, '../../..'),
27
+ });
28
+ return events_1.once(child, 'close');
29
+ }
30
+ exports.generateBundle = generateBundle;
31
+ //# sourceMappingURL=test-helper.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"test-helper.js","sourceRoot":"","sources":["../../../src/__tests__/integration/test-helper.ts"],"names":[],"mappings":";AAAA,iDAAiD;AACjD,yCAAyC;AACzC,+CAA+C;AAC/C,gEAAgE;;;;AAEhE,+CAAyC;AACzC,mCAA4B;AAC5B,wDAAwB;AAExB,MAAM,QAAQ,GAAG,OAAO,CAAC,iBAAiB,CAAC,CAAC,QAAQ,CAAC;AAErD,SAAgB,eAAe,CAAC,SAAmB;IACjD,SAAS,GAAG,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC,CAAC,CAAC;IAC/D,gBAAM,CAAC,SAAS,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC;QACvB,mBAAmB;QACnB,cAAc;QACd,eAAe;QACf,mBAAmB;KACpB,CAAC,CAAC;AACL,CAAC;AARD,0CAQC;AAED,SAAgB,cAAc,CAAC,IAAoB;IACjD,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,EAAE,CAAC,KAAK,EAAE,iBAAiB,IAAI,EAAE,CAAC,EAAE;QAC9D,KAAK,EAAE,QAAQ;QACf,GAAG,EAAE,cAAI,CAAC,IAAI,CAAC,SAAS,EAAE,UAAU,CAAC;KACtC,CAAC,CAAC;IACH,OAAO,aAAI,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC;AAC9B,CAAC;AAND,wCAMC"}
@@ -0,0 +1,2 @@
1
+ /*! For license information please see bundle-node.js.LICENSE.txt */
2
+ !function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var n=e();for(var r in n)("object"==typeof exports?exports:t)[r]=n[r]}}(global,(function(){return(()=>{var t={7529:(t,e,n)=>{"use strict";t=n.nmd(t),Object.defineProperty(e,"__esModule",{value:!0}),e.GreetingApplication=e.main=void 0;const r=n(655),o=n(5292),i=o.BindingKey.create("currentDate"),s=o.BindingKey.create("currentUser"),a=o.BindingKey.create("currentLanguage"),u=o.BindingKey.create("services.GreetingService"),c=()=>new Date;class l{constructor(){this.language="zh"}greet(t){return`你好,${t}!`}}class f{constructor(){this.language="en"}greet(t){return`Hello, ${t}!`}}let p=class{constructor(t){this.greetersView=t}async greet(t,e){const n=await this.now(),r=await this.greetersView.values();for(const o of r)if(o.language===t){const r=o.greet(e);return`[${n.toISOString()}] (${t}) ${r}`}return`[${n.toISOString()}] Hello, ${e}!`}};async function d(){const t=new h;return t.addGreeter("greeters.EnglishGreeter",f),await t.greetInEnglish(),t.addGreeter("greeters.ChineseGreeter",l),await t.greetInChineseThenEnglish(),t.greetings}r.__decorate([o.inject.getter(i),r.__metadata("design:type",Function)],p.prototype,"now",void 0),r.__decorate([r.__param(0,o.inject(a)),r.__param(1,o.inject(s)),r.__metadata("design:type",Function),r.__metadata("design:paramtypes",[String,String]),r.__metadata("design:returntype",Promise)],p.prototype,"greet",null),p=r.__decorate([r.__param(0,o.inject.view(o.filterByTag("greeter"))),r.__metadata("design:paramtypes",[o.ContextView])],p),e.main=d;class h extends o.Application{constructor(){super(),this.greetings=[],this.bind(u).toClass(p),this.bind(i).toDynamicValue(c)}addGreeter(t,e){this.bind(t).toClass(e).tag("greeter")}async greetInEnglish(){const{greetingService:t,requestCtx:e}=await this.createRequest("John","zh");let n=await t.greet("en","Jane");this.greetings.push(n),n=await o.invokeMethod(t,"greet",e),this.greetings.push(n),e.close()}async greetInChineseThenEnglish(){const{greetingService:t,requestCtx:e}=await this.createRequest("John","zh");let n=await o.invokeMethod(t,"greet",e);this.greetings.push(n),e.bind(a).to("en"),e.bind(s).to("Jane"),n=await o.invokeMethod(t,"greet",e),this.greetings.push(n),e.close()}async createRequest(t,e){const n=new o.Context(this,"request-"+h.requestCounter++);return n.bind(s).to(t),n.bind(a).to(e),{greetingService:await n.get(u),requestCtx:n}}}e.GreetingApplication=h,h.requestCounter=0,n.c[n.s]===t&&d().then((t=>t.forEach((t=>console.log(t))))).catch((t=>{console.error(t),process.exit(1)}))},5590:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const r=n(655);r.__exportStar(n(5292),e),r.__exportStar(n(7529),e)},655:(t,e,n)=>{"use strict";n.r(e),n.d(e,{__extends:()=>o,__assign:()=>i,__rest:()=>s,__decorate:()=>a,__param:()=>u,__metadata:()=>c,__awaiter:()=>l,__generator:()=>f,__createBinding:()=>p,__exportStar:()=>d,__values:()=>h,__read:()=>g,__spread:()=>y,__spreadArrays:()=>v,__spreadArray:()=>_,__await:()=>m,__asyncGenerator:()=>b,__asyncDelegator:()=>w,__asyncValues:()=>C,__makeTemplateObject:()=>O,__importStar:()=>x,__importDefault:()=>S,__classPrivateFieldGet:()=>I,__classPrivateFieldSet:()=>T});var r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var i=function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};function s(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]])}return n}function a(t,e,n,r){var o,i=arguments.length,s=i<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(i<3?o(s):i>3?o(e,n,s):o(e,n))||s);return i>3&&s&&Object.defineProperty(e,n,s),s}function u(t,e){return function(n,r){e(n,r,t)}}function c(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function l(t,e,n,r){return new(n||(n=Promise))((function(o,i){function s(t){try{u(r.next(t))}catch(t){i(t)}}function a(t){try{u(r.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(s,a)}u((r=r.apply(t,e||[])).next())}))}function f(t,e){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!((o=(o=s.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=e.call(t,s)}catch(t){i=[6,t],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}}var p=Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]};function d(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||p(e,t,n)}function h(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function g(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),s=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)s.push(r.value)}catch(t){o={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return s}function y(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(g(arguments[e]));return t}function v(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),o=0;for(e=0;e<n;e++)for(var i=arguments[e],s=0,a=i.length;s<a;s++,o++)r[o]=i[s];return r}function _(t,e,n){if(n||2===arguments.length)for(var r,o=0,i=e.length;o<i;o++)!r&&o in e||(r||(r=Array.prototype.slice.call(e,0,o)),r[o]=e[o]);return t.concat(r||Array.prototype.slice.call(e))}function m(t){return this instanceof m?(this.v=t,this):new m(t)}function b(t,e,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,o=n.apply(t,e||[]),i=[];return r={},s("next"),s("throw"),s("return"),r[Symbol.asyncIterator]=function(){return this},r;function s(t){o[t]&&(r[t]=function(e){return new Promise((function(n,r){i.push([t,e,n,r])>1||a(t,e)}))})}function a(t,e){try{(n=o[t](e)).value instanceof m?Promise.resolve(n.value.v).then(u,c):l(i[0][2],n)}catch(t){l(i[0][3],t)}var n}function u(t){a("next",t)}function c(t){a("throw",t)}function l(t,e){t(e),i.shift(),i.length&&a(i[0][0],i[0][1])}}function w(t){var e,n;return e={},r("next"),r("throw",(function(t){throw t})),r("return"),e[Symbol.iterator]=function(){return this},e;function r(r,o){e[r]=t[r]?function(e){return(n=!n)?{value:m(t[r](e)),done:"return"===r}:o?o(e):e}:o}}function C(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=h(t),e={},r("next"),r("throw"),r("return"),e[Symbol.asyncIterator]=function(){return this},e);function r(n){e[n]=t[n]&&function(e){return new Promise((function(r,o){!function(t,e,n,r){Promise.resolve(r).then((function(e){t({value:e,done:n})}),e)}(r,o,(e=t[n](e)).done,e.value)}))}}}function O(t,e){return Object.defineProperty?Object.defineProperty(t,"raw",{value:e}):t.raw=e,t}var E=Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e};function x(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&p(e,t,n);return E(e,t),e}function S(t){return t&&t.__esModule?t:{default:t}}function I(t,e,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!r:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(t):r?r.value:e.get(t)}function T(t,e,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!o:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(t,n):o?o.value=n:e.set(t,n),n}},8137:t=>{"use strict";t.exports=(t,e=process.argv)=>{const n=t.startsWith("-")?"":1===t.length?"-":"--",r=e.indexOf(n+t),o=e.indexOf("--");return-1!==r&&(-1===o||r<o)}},7013:(t,e,n)=>{"use strict";const r=n(2037),o=n(6224),i=n(8137),{env:s}=process;let a;function u(t){return 0!==t&&{level:t,hasBasic:!0,has256:t>=2,has16m:t>=3}}function c(t,e){if(0===a)return 0;if(i("color=16m")||i("color=full")||i("color=truecolor"))return 3;if(i("color=256"))return 2;if(t&&!e&&void 0===a)return 0;const n=a||0;if("dumb"===s.TERM)return n;if("win32"===process.platform){const t=r.release().split(".");return Number(t[0])>=10&&Number(t[2])>=10586?Number(t[2])>=14931?3:2:1}if("CI"in s)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((t=>t in s))||"codeship"===s.CI_NAME?1:n;if("TEAMCITY_VERSION"in s)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(s.TEAMCITY_VERSION)?1:0;if("truecolor"===s.COLORTERM)return 3;if("TERM_PROGRAM"in s){const t=parseInt((s.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(s.TERM_PROGRAM){case"iTerm.app":return t>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(s.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(s.TERM)||"COLORTERM"in s?1:n}i("no-color")||i("no-colors")||i("color=false")||i("color=never")?a=0:(i("color")||i("colors")||i("color=true")||i("color=always"))&&(a=1),"FORCE_COLOR"in s&&(a="true"===s.FORCE_COLOR?1:"false"===s.FORCE_COLOR?0:0===s.FORCE_COLOR.length?1:Math.min(parseInt(s.FORCE_COLOR,10),3)),t.exports={supportsColor:function(t){return u(c(t,t&&t.isTTY))},stdout:u(c(!0,o.isatty(1))),stderr:u(c(!0,o.isatty(2)))}},217:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.configBindingKeyFor=e.DefaultConfigurationResolver=void 0;const r=n(1808);function o(t,e){return r.BindingKey.create(r.BindingKey.buildKeyForConfig(t).toString(),e)}e.DefaultConfigurationResolver=class{constructor(t){this.context=t}getConfigAsValueOrPromise(t,e,n){const r=o(t,e=null!=e?e:""),i=Object.assign({optional:!0},n);return this.context.getValueOrPromise(r,i)}},e.configBindingKeyFor=o},6353:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.bind=e.injectable=void 0;const r=n(3481),o=n(7849);class i extends r.ClassDecoratorFactory{mergeWithInherited(t,e){return t?{templates:[...t.templates,o.removeNameAndKeyTags,...this.spec.templates],target:this.spec.target}:(this.withTarget(this.spec,e),this.spec)}mergeWithOwn(t){return{templates:[...t.templates,...this.spec.templates],target:this.spec.target}}withTarget(t,e){return t.target=e,t}}function s(...t){const e=t.map((t=>"function"==typeof t?t:o.asBindingTemplate(t)));return t=>{const n=t,r={templates:[o.asClassOrProvider(n),...e],target:n};i.createDecorator(o.BINDING_METADATA_KEY,r,{decoratorName:"@injectable"})(t)}}function a(...t){return s(...t)}e.injectable=s,function(t){t.provider=function(...e){return n=>{if(!o.isProviderClass(n))throw new Error(`Target ${n} is not a Provider`);t(o.asProvider(n),...e)(n)}}}(s=e.injectable||(e.injectable={})),e.bind=a,function(t){t.provider=s.provider}(a=e.bind||(e.bind={}))},4282:(t,e)=>{"use strict";function n(t,e,n){const r=n[e];return r===t||"function"==typeof t&&t(r,e,n)}function r(t){let e=t.replace(/[\-\[\]\/\{\}\(\)\+\.\\\^\$\|\:]/g,"\\$&");return e=e.replace(/\*/g,"[^.:]*").replace(/\?/g,"[^.:]"),new RegExp(`^${e}$`)}Object.defineProperty(e,"__esModule",{value:!0}),e.filterByKey=e.filterByTag=e.includesTagValue=e.ANY_TAG_VALUE=e.isBindingTagFilter=e.isBindingAddress=void 0,e.isBindingAddress=function(t){return"function"!=typeof t&&("string"==typeof t||null!=(e=t)&&"object"==typeof e&&"string"==typeof e.key&&"function"==typeof e.deepProperty);var e},e.isBindingTagFilter=function(t){if(null==t||!("bindingTagPattern"in t))return!1;const e=t.bindingTagPattern;return e instanceof RegExp||"string"==typeof e||"object"==typeof e},e.ANY_TAG_VALUE=(t,e,n)=>e in n,e.includesTagValue=function(...t){return e=>t.some((t=>e===t||Array.isArray(e)&&e.includes(t)))},e.filterByTag=function(t){let e,o;if(t instanceof RegExp&&(o=t),"string"==typeof t&&(t.includes("*")||t.includes("?"))&&(o=r(t)),null!=o)e=t=>t.tagNames.some((t=>o.test(t)));else if("string"==typeof t)e=e=>e.tagNames.includes(t);else{const r=t;e=t=>{for(const e in r)if(!n(r[e],e,t.tagMap))return!1;return!0}}const i=e;return i.bindingTagPattern=null!=o?o:t,i},e.filterByKey=function(t){if("string"==typeof t){const e=r(t);return t=>e.test(t.key)}return t instanceof RegExp?e=>t.test(e.key):"function"==typeof t?t:()=>!0}},7849:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createBindingFromClass=e.DEFAULT_TYPE_NAMESPACES=e.bindingTemplateFor=e.removeNameAndKeyTags=e.getBindingMetadata=e.asBindingTemplate=e.asClassOrProvider=e.asProvider=e.isProviderClass=e.BINDING_METADATA_KEY=void 0;const r=n(4474),o=n(3481),i=r.__importDefault(n(4806)),s=n(7572),a=n(7653),u=i.default("loopback:context:binding-inspector");function c(t){var e;return"function"==typeof t&&"function"==typeof(null===(e=t.prototype)||void 0===e?void 0:e.value)}function l(t){return function(e){e.toProvider(t).tag(a.ContextTags.PROVIDER,{[a.ContextTags.TYPE]:a.ContextTags.PROVIDER})}}function f(t){return function(e){c(t)?l(t)(e):s.isDynamicValueProviderClass(t)?e.toDynamicValue(t).tag(a.ContextTags.DYNAMIC_VALUE_PROVIDER,{[a.ContextTags.TYPE]:a.ContextTags.DYNAMIC_VALUE_PROVIDER}):e.toClass(t)}}function p(t){return o.MetadataInspector.getClassMetadata(e.BINDING_METADATA_KEY,t)}function d(t){t.tagMap&&(delete t.tagMap.name,delete t.tagMap.key)}function h(t,e){var n;const r=p(t);u("class %s has binding metadata",t.name,r);const o=null!==(n=null==r?void 0:r.templates)&&void 0!==n?n:[];return(null==r?void 0:r.target)!==t&&o.push(f(t)),function(n){for(const t of o)n.apply(t);(null==r?void 0:r.target)!==t&&n.apply(d),null!=e&&function(t,e){e.name&&t.tag({name:e.name}),e.type&&t.tag({type:e.type},e.type),e.defaultScope&&t.applyDefaultScope(e.defaultScope)}(n,e)}}e.BINDING_METADATA_KEY=o.MetadataAccessor.create("binding.metadata"),e.isProviderClass=c,e.asProvider=l,e.asClassOrProvider=f,e.asBindingTemplate=function(t){return function(e){t.scope&&e.inScope(t.scope),t.tags&&(Array.isArray(t.tags)?e.tag(...t.tags):e.tag(t.tags))}},e.getBindingMetadata=p,e.removeNameAndKeyTags=d,e.bindingTemplateFor=h,e.DEFAULT_TYPE_NAMESPACES={class:"classes",provider:"providers",dynamicValueProvider:"dynamicValueProviders"},e.createBindingFromClass=function(t,n={}){u("create binding from class %s with options",t.name,n);try{const r=h(t,n),o=function(t,n={}){var r,o,i,u,c;if(n.key)return n.key;const l=h(t),f=new s.Binding("template").apply(l);let p=f.tagMap[a.ContextTags.KEY];if(p)return p;let d=null!==(o=null!==(r=n.namespace)&&void 0!==r?r:f.tagMap[a.ContextTags.NAMESPACE])&&void 0!==o?o:n.defaultNamespace;if(!d){const t=Object.assign({},e.DEFAULT_TYPE_NAMESPACES,n.typeNamespaceMapping);let r=null!==(i=n.type)&&void 0!==i?i:f.tagMap[a.ContextTags.TYPE];r||(r=null!==(u=f.tagNames.find((e=>null!=t[e])))&&void 0!==u?u:a.ContextTags.CLASS),d=function(t,n=e.DEFAULT_TYPE_NAMESPACES){return t in n?n[t]:`${t}s`}(r,t)}return p=`${d}.${null!==(c=n.name)&&void 0!==c?c:f.tagMap[a.ContextTags.NAME]||t.name}`,p}(t,n);return s.Binding.bind(o).apply(r)}catch(e){throw e.message+=` (while building binding for class ${t.name})`,e}}},1808:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BindingKey=void 0;const r=n(454);class o{constructor(t,e){this.key=t,this.propertyPath=e}static create(t,e){return e?(o.validate(t),new o(t,e)):o.parseKeyWithPath(t)}toString(){return this.propertyPath?`${this.key}${o.PROPERTY_SEPARATOR}${this.propertyPath}`:this.key}deepProperty(t){return o.create(this.key,t)}static validate(t){if(!t)throw new Error("Binding key must be provided.");if((t=t.toString()).includes(o.PROPERTY_SEPARATOR))throw new Error(`Binding key ${t} cannot contain '${o.PROPERTY_SEPARATOR}'.`);return t}static parseKeyWithPath(t){if("string"!=typeof t)return o.create(t.key,t.propertyPath);const e=t.indexOf(o.PROPERTY_SEPARATOR);return-1===e?new o(t):o.create(t.substr(0,e).trim(),t.substr(e+1))}static buildKeyForConfig(t=""){const e=o.CONFIG_NAMESPACE;return t?`${t}:${e}`:e}static generate(t=""){const e=t?`${t}.`:"",n=r.generateUniqueId();return o.create(`${e}${n}`)}}e.BindingKey=o,o.PROPERTY_SEPARATOR="#",o.CONFIG_NAMESPACE="$config"},3567:(t,e)=>{"use strict";function n(t="phase",e=[]){return(n,o)=>r(n.tagMap[t],o.tagMap[t],e)}function r(t,e,n=[]){t=null!=t?t:"",e=null!=e?e:"";const r=n.indexOf(t),o=n.indexOf(e);return-1!==r||-1!==o?r-o:"symbol"==typeof t&&"string"==typeof e?-1:"string"==typeof t&&"symbol"==typeof e?1:("symbol"==typeof t&&(t=t.toString()),"symbol"==typeof e&&(e=e.toString()),t<e?-1:t>e?1:0)}Object.defineProperty(e,"__esModule",{value:!0}),e.sortBindingsByPhase=e.compareByOrder=e.compareBindingsByTag=void 0,e.compareBindingsByTag=n,e.compareByOrder=r,e.sortBindingsByPhase=function(t,e,r){return t.sort(n(e,r))}},7572:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Binding=e.isDynamicValueProviderClass=e.BindingType=e.BindingScope=void 0;const r=n(4474).__importDefault(n(4806)),o=n(2361),i=n(7849),s=n(1808),a=n(3539),u=n(5741),c=n(2650),l=n(7653),f=n(1414),p=n(8740),d=n(7324),h=r.default("loopback:context:binding");var g,y;function v(t){return!("function"!=typeof t||!String(t).startsWith("class "))&&"function"==typeof t.value}!function(t){t.TRANSIENT="Transient",t.CONTEXT="Context",t.SINGLETON="Singleton",t.APPLICATION="Application",t.SERVER="Server",t.REQUEST="Request"}(g=e.BindingScope||(e.BindingScope={})),function(t){t.CONSTANT="Constant",t.DYNAMIC_VALUE="DynamicValue",t.CLASS="Class",t.PROVIDER="Provider",t.ALIAS="Alias"}(y=e.BindingType||(e.BindingType={})),e.isDynamicValueProviderClass=v;class _ extends o.EventEmitter{constructor(t,e=!1){super(),this.isLocked=e,this.tagMap={},s.BindingKey.validate(t),this.key=t.toString()}get scope(){var t;return null!==(t=this._scope)&&void 0!==t?t:g.TRANSIENT}get type(){var t;return null===(t=this._source)||void 0===t?void 0:t.type}get source(){return this._source}get valueConstructor(){var t,e;return(null===(t=this._source)||void 0===t?void 0:t.type)===y.CLASS?null===(e=this._source)||void 0===e?void 0:e.value:void 0}get providerConstructor(){var t,e;return(null===(t=this._source)||void 0===t?void 0:t.type)===y.PROVIDER?null===(e=this._source)||void 0===e?void 0:e.value:void 0}_cacheValue(t,e){return this._cache||(this._cache=new WeakMap),this.scope!==g.TRANSIENT&&this._cache.set(t,e),e}_clearCache(){this._cache&&(this._cache=new WeakMap)}refresh(t){if(this._cache&&this.scope!==g.TRANSIENT){const e=t.getResolutionContext(this);null!=e&&this._cache.delete(e)}}getValue(t,e){var n;h.enabled&&h("Get value for binding %s",this.key);const r=f.asResolutionOptions(e),o=this.getResolutionContext(t,r);if(null==o)return;const i=null!==(n=f.ResolutionSession.fork(r.session))&&void 0!==n?n:new f.ResolutionSession;if(this._cache&&this.scope!==g.TRANSIENT&&o&&this._cache.has(o)){const t=this._cache.get(o);return this.getValueOrProxy(o,{...r,session:i},t)}const s={context:o,binding:this,options:r};if("function"==typeof this._getValue){const t=f.ResolutionSession.runWithBinding((t=>{const e={...r,session:t,asProxyWithInterceptors:!1};return this._getValue({...s,options:e})}),this,r.session),e=this._cacheValue(o,t);return this.getValueOrProxy(o,{...r,session:i},e)}return r.optional?void 0:Promise.reject(new f.ResolutionError(`No value was configured for binding ${this.key}.`,s))}getValueOrProxy(t,e,n){return e.session.pushBinding(this),_.valueOrProxy({context:t,binding:this,options:e},n)}getResolutionContext(t,e){const n=t.getResolutionContext(this);switch(this.scope){case g.APPLICATION:case g.SERVER:case g.REQUEST:if(null==n){const n=`Binding "${this.key}" in context "${t.name}" cannot be resolved in scope "${this.scope}"`;if(e.optional)return void h(n);throw new Error(n)}}const r=t.getOwnerContext(this.key);if(null!=r&&!r.isVisibleTo(n)){const t=`Resolution context "${null==n?void 0:n.name}" does not have visibility to binding "${this.key} (scope:${this.scope})" in context "${r.name}"`;if(e.optional)return void h(t);throw new Error(t)}return n}lock(){return this.isLocked=!0,this}emitChangedEvent(t){const e={binding:this,operation:t,type:"changed"};this.emit("changed",e)}tag(...t){for(const e of t)if("string"==typeof e)this.tagMap[e]=e;else{if(Array.isArray(e))throw new Error("Tag must be a string or an object (but not array): "+e);Object.assign(this.tagMap,e)}return this.emitChangedEvent("tag"),this}get tagNames(){return Object.keys(this.tagMap)}inScope(t){return this._scope!==t&&this._clearCache(),this._scope=t,this.emitChangedEvent("scope"),this}applyDefaultScope(t){return this._scope||this.inScope(t),this}_setValueGetter(t){this._clearCache(),this._getValue=e=>t(e),this.emitChangedEvent("value")}to(t){if(d.isPromiseLike(t))throw new Error('Promise instances are not allowed for constant values bound via ".to()". Register an async getter function via ".toDynamicValue()" instead.');return h.enabled&&h("Bind %s to constant:",this.key,t),this._source={type:y.CONSTANT,value:t},this._setValueGetter((e=>_.valueOrProxy(e,t))),this}toDynamicValue(t){let e;var n;return h.enabled&&h("Bind %s to dynamic value:",this.key,t),this._source={type:y.DYNAMIC_VALUE,value:t},v(t)?(n=t,e=t=>c.invokeMethod(n,"value",t.context,[],{skipInterceptors:!0,session:t.options.session})):e=t,this._setValueGetter((t=>{const n=e(t);return _.valueOrProxy(t,n)})),this}static valueOrProxy(t,e){return t.options.asProxyWithInterceptors?(n=e,r=t.context,o=t.options.session,d.transformValueOrPromise(n,(t=>"object"!=typeof t||null==t?t:u.createProxyWithInterceptors(t,r,o)))):e;var n,r,o}toProvider(t){return h.enabled&&h("Bind %s to provider %s",this.key,t.name),this._source={type:y.PROVIDER,value:t},this._setValueGetter((e=>{const n=p.instantiateClass(t,e.context,e.options.session),r=d.transformValueOrPromise(n,(t=>t.value()));return _.valueOrProxy(e,r)})),this}toClass(t){return h.enabled&&h("Bind %s to class %s",this.key,t.name),this._source={type:y.CLASS,value:t},this._setValueGetter((e=>{const n=p.instantiateClass(t,e.context,e.options.session);return _.valueOrProxy(e,n)})),this}toInjectable(t){return this.apply(i.bindingTemplateFor(t)),this}toAlias(t){return h.enabled&&h("Bind %s to alias %s",this.key,t),this._source={type:y.ALIAS,value:t},this._setValueGetter((({context:e,options:n})=>e.getValueOrPromise(t,n))),this}unlock(){return this.isLocked=!1,this}apply(...t){for(const e of t)e(this);return this}toJSON(){var t,e,n,r;const o={key:this.key,scope:this.scope,tags:this.tagMap,isLocked:this.isLocked};switch(null!=this.type&&(o.type=this.type),null===(t=this._source)||void 0===t?void 0:t.type){case y.CLASS:o.valueConstructor=null===(e=this._source)||void 0===e?void 0:e.value.name;break;case y.PROVIDER:o.providerConstructor=null===(n=this._source)||void 0===n?void 0:n.value.name;break;case y.ALIAS:o.alias=null===(r=this._source)||void 0===r?void 0:r.value.toString()}return o}inspect(t={}){t={includeInjections:!1,...t};const e=this.toJSON();if(t.includeInjections){const t=a.inspectInjections(this);Object.keys(t).length&&(e.injections=t)}return e}static bind(t){return new _(t)}static configure(t){return new _(s.BindingKey.buildKeyForConfig(t)).tag({[l.ContextTags.CONFIGURATION_FOR]:t.toString()})}on(t,e){return super.on(t,e)}once(t,e){return super.once(t,e)}}e.Binding=_},4540:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},6501:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},999:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ContextSubscriptionManager=void 0;const r=n(4474).__importDefault(n(4806)),o=n(2361),i=n(2131),s=r.default("loopback:context:subscription");class a{constructor(t,e){this.context=t,this.observer=e,this._closed=!1}unsubscribe(){this.context.unsubscribe(this.observer),this._closed=!0}get closed(){return this._closed}}class u extends o.EventEmitter{constructor(t){super(),this.context=t,this.pendingNotifications=0,this.setMaxListeners(1/0)}get parentContextEventListener(){return this._parentContextEventListener}get observers(){return this._observers}_debug(...t){if(!s.enabled)return;const e=t.shift();"string"==typeof e?s(`[%s] ${e}`,this.context.name,...t):s("[%s] ",this.context.name,e,...t)}setupEventHandlersIfNeeded(){if(null!=this.notificationQueue)return;null!=this.context.parent&&(this._parentContextEventListener=t=>{this.handleParentEvent(t)},this.context.parent.on("bind",this._parentContextEventListener),this.context.parent.on("unbind",this._parentContextEventListener)),this.startNotificationTask().catch((t=>{this.handleNotificationError(t)}));let t=this.context.parent;for(;t;)t.subscriptionManager.setupEventHandlersIfNeeded(),t=t.parent}handleParentEvent(t){const{binding:e,context:n,type:r}=t;this.context.contains(e.key)?this._debug("Event %s %s is not re-emitted from %s to %s",r,e.key,n.name,this.context.name):(this._debug("Re-emitting %s %s from %s to %s",r,e.key,n.name,this.context.name),this.context.emitEvent(r,t))}emitEvent(t,e){this.emit(t,e)}emitError(t){this.emit("error",t)}startNotificationTask(){return this.setupNotification("bind","unbind"),this.notificationQueue=i.iterator(this,"notification",{rejectionEvents:[]}),this.processNotifications()}async notifyObservers(t,e=this._observers){if(!e||0===e.size)return;const{type:n,binding:r,context:o}=t;for(const t of e)"function"==typeof t?await t(n,r,o):t.filter&&!t.filter(r)||await t.observe(n,r,o)}async processNotifications(){const t=this.notificationQueue;if(null!=t)for await(const{type:e,binding:n,context:r,observers:o}of t)try{await this.notifyObservers({type:e,binding:n,context:r},o),this.pendingNotifications--,this._debug("Observers notified for %s of binding %s",e,n.key),this.emitEvent("observersNotified",{type:e,binding:n,context:r})}catch(t){this._debug("Error caught from observers",t),this.listenerCount("error")>0?this.emitError(t):this.handleNotificationError(t)}}setupNotification(...t){for(const e of t)this.context.on(e,(({binding:t,context:n})=>{this._observers&&0!==this._observers.size&&(this.pendingNotifications++,this.emitEvent("notification",{type:e,binding:t,context:n,observers:new Set(this._observers)}))}))}async waitUntilPendingNotificationsDone(t){const e=this.pendingNotifications;s("Number of pending notifications: %d",e),0!==e&&await i.multiple(this,"observersNotified",{count:e,timeout:t})}subscribe(t){var e;return this._observers=null!==(e=this._observers)&&void 0!==e?e:new Set,this.setupEventHandlersIfNeeded(),this._observers.add(t),new a(this.context,t)}unsubscribe(t){return!!this._observers&&this._observers.delete(t)}isSubscribed(t){return!!this._observers&&this._observers.has(t)}handleNotificationError(t){let e=this.context;for(;e;){if(0!==e.listenerCount("error"))return this._debug("Emitting error to context %s",e.name,t),void e.emitError(t);e=e.parent}this._debug("No error handler is configured for the context chain",t),this.context.emitError(t)}close(){this._observers=void 0,null!=this.notificationQueue&&(this.notificationQueue.return(void 0).catch((t=>{this.handleNotificationError(t)})),this.notificationQueue=void 0),this.context.parent&&this._parentContextEventListener&&(this.context.parent.removeListener("bind",this._parentContextEventListener),this.context.parent.removeListener("unbind",this._parentContextEventListener),this._parentContextEventListener=void 0)}}e.ContextSubscriptionManager=u},46:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ContextTagIndexer=void 0;const r=n(4282);e.ContextTagIndexer=class{constructor(t){this.context=t,this.bindingsIndexedByTag=new Map,this.setupTagIndexForBindings()}setupTagIndexForBindings(){this.bindingEventListener=({binding:t,operation:e})=>{"tag"===e&&this.updateTagIndexForBinding(t)},this.tagIndexListener=t=>{const{binding:e,type:n}=t;t.context===this.context&&("bind"===n?(this.updateTagIndexForBinding(e),e.on("changed",this.bindingEventListener)):"unbind"===n&&(this.removeTagIndexForBinding(e),e.removeListener("changed",this.bindingEventListener)))},this.context.on("bind",this.tagIndexListener),this.context.on("unbind",this.tagIndexListener)}removeTagIndexForBinding(t){for(const[,e]of this.bindingsIndexedByTag)e.delete(t)}updateTagIndexForBinding(t){this.removeTagIndexForBinding(t);for(const e of t.tagNames){let n=this.bindingsIndexedByTag.get(e);null==n&&(n=new Set,this.bindingsIndexedByTag.set(e,n)),n.add(t)}}findByTagIndex(t){let e,n,o,i=!1;if(t instanceof RegExp){i=!0,e=[];for(const n of this.bindingsIndexedByTag.keys())t.test(n)&&e.push(n)}else e="string"==typeof t?[t]:Object.keys(t);for(const s of e){const e=this.bindingsIndexedByTag.get(s);if(null==e)break;n=null!=n?n:r.filterByTag(t);const a=new Set(Array.from(e).filter(n));if(!i&&0===a.size)break;if(null==o)o=a;else{if(i)a.forEach((t=>null==o?void 0:o.add(t)));else{const t=new Set;o.forEach((e=>{a.has(e)&&t.add(e)})),o=t}if(!i&&0===o.size)break}}return null==o?[]:Array.from(o)}close(){this.context.removeListener("bind",this.tagIndexListener),this.context.removeListener("unbind",this.tagIndexListener)}}},492:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createViewGetter=e.ContextView=void 0;const r=n(4474).__importDefault(n(4806)),o=n(2361),i=n(3837),s=n(1414),a=n(7324),u=r.default("loopback:context:view"),c=i.promisify(process.nextTick);class l extends o.EventEmitter{constructor(t,e,n){super(),this.context=t,this.filter=e,this.comparator=n}updateCachedValues(t){var e;if(null!=this._cachedBindings){this._cachedValues=new Map;for(let n=0;n<(null===(e=this._cachedBindings)||void 0===e?void 0:e.length);n++)this._cachedValues.set(this._cachedBindings[n],t[n]);return this._cachedValues}}getCachedValues(){var t,e;return Array.from(null!==(e=null===(t=this._cachedValues)||void 0===t?void 0:t.values())&&void 0!==e?e:[])}open(){return u("Start listening on changes of context %s",this.context.name),this.context.isSubscribed(this)||(this._subscription=this.context.subscribe(this)),this._subscription}close(){u("Stop listening on changes of context %s",this.context.name),this._subscription&&!this._subscription.closed&&(this._subscription.unsubscribe(),this._subscription=void 0,this.emit("close"))}get bindings(){return u("Reading bindings"),null==this._cachedBindings&&(this._cachedBindings=this.findBindings()),this._cachedBindings}findBindings(){u("Finding matching bindings");const t=this.context.find(this.filter);return"function"==typeof this.comparator&&t.sort(this.comparator),u.enabled&&u("Bindings found",t.map((t=>t.key))),t}observe(t,e,n){var r;const o={context:n,binding:e,type:t};if(u("Observed event %s %s %s",t,e.key,n.name),"unbind"===t){const n=null===(r=this._cachedValues)||void 0===r?void 0:r.get(e);this.emit(t,{...o,cachedValue:n})}else this.emit(t,o);this.refresh()}refresh(){u("Refreshing the view by invalidating cache"),this._cachedBindings=void 0,this._cachedValues=void 0,this.emit("refresh")}resolve(t){if(u("Resolving values"),null!=this._cachedValues)return this.getCachedValues();const e=this.bindings;let n=a.resolveList(e,(e=>e.getValue(this.context,s.ResolutionSession.fork(t))));return a.isPromiseLike(n)?n=n.then((t=>(this.updateCachedValues(t),this.emit("resolve",t),t))):(this.updateCachedValues(n),this.emit("resolve",n)),n}async values(t){return u("Reading values"),await c(),null==this._cachedValues?this.resolve(t):this.getCachedValues()}asGetter(t){return()=>this.values(t)}async singleValue(t){const e=await this.values(t);if(0!==e.length){if(1===e.length)return e[0];throw new Error("The ContextView has more than one value. Use values() to access them.")}}on(t,e){return super.on(t,e)}once(t,e){return super.once(t,e)}}e.ContextView=l,e.createViewGetter=function(t,e,n,r){let o;"function"==typeof n?o=n:n instanceof s.ResolutionSession&&(r=n);const i=new l(t,e,o);return i.open(),i.asGetter(r)}},7975:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BindingCreationPolicy=e.Context=void 0;const r=n(4474).__importDefault(n(4806)),o=n(2361),i=n(7572),s=n(217),a=n(4282),u=n(1808),c=n(999),l=n(46),f=n(492),p=n(7653),d=n(1414),h=n(454),g=n(7324);class y extends o.EventEmitter{constructor(t,e){super(),this.registry=new Map,this.scope=i.BindingScope.CONTEXT,this.setMaxListeners(1/0),"string"==typeof t&&(e=t,t=void 0),this._parent=t,this.name=null!=e?e:this.generateName(),this.tagIndexer=new l.ContextTagIndexer(this),this.subscriptionManager=new c.ContextSubscriptionManager(this),this._debug=r.default(this.getDebugNamespace())}getDebugNamespace(){return this.constructor===y?"loopback:context":`loopback:context:${this.constructor.name.toLowerCase()}`}generateName(){const t=h.generateUniqueId();return this.constructor===y?t:`${this.constructor.name}-${t}`}get parent(){return this._parent}debug(...t){if(!this._debug.enabled)return;const e=t.shift();"string"==typeof e?this._debug(`[%s] ${e}`,this.name,...t):this._debug("[%s] ",this.name,e,...t)}emitEvent(t,e){this.emit(t,e)}emitError(t){this.emit("error",t)}bind(t){const e=new i.Binding(t.toString());return this.add(e),e}add(t){const e=t.key;let n;if(this.debug("[%s] Adding binding: %s",e),this.registry.has(e)&&(n=this.registry.get(e),null==n?void 0:n.isLocked))throw new Error(`Cannot rebind key "${e}" to a locked binding`);return this.registry.set(e,t),n!==t&&(null!=n&&this.emitEvent("unbind",{binding:n,context:this,type:"unbind"}),this.emitEvent("bind",{binding:t,context:this,type:"bind"})),this}configure(t=""){const e=i.Binding.configure(t);return this.add(e),e}getConfigAsValueOrPromise(t,e,n){return this.setupConfigurationResolverIfNeeded(),this.configResolver.getConfigAsValueOrPromise(t,e,n)}setupConfigurationResolverIfNeeded(){if(!this.configResolver){const t=this.getSync(p.ContextBindings.CONFIGURATION_RESOLVER,{optional:!0});t?(this.debug("Custom ConfigurationResolver is loaded from %s.",p.ContextBindings.CONFIGURATION_RESOLVER.toString()),this.configResolver=t):(this.debug("DefaultConfigurationResolver is used."),this.configResolver=new s.DefaultConfigurationResolver(this))}return this.configResolver}async getConfig(t,e,n){return this.getConfigAsValueOrPromise(t,e,n)}getConfigSync(t,e,n){const r=this.getConfigAsValueOrPromise(t,e,n);if(g.isPromiseLike(r))throw new Error(`Cannot get config${e?` property ${e}`:""} for ${t} synchronously: the value is a promise`);return r}unbind(t){this.debug("Unbind %s",t),t=u.BindingKey.validate(t);const e=this.registry.get(t);if(null==e)return!1;if(null==e?void 0:e.isLocked)throw new Error(`Cannot unbind key "${t}" of a locked binding`);return this.registry.delete(t),this.emitEvent("unbind",{binding:e,context:this,type:"unbind"}),!0}subscribe(t){return this.subscriptionManager.subscribe(t)}unsubscribe(t){return this.subscriptionManager.unsubscribe(t)}close(){this.debug("Closing context..."),this.subscriptionManager.close(),this.tagIndexer.close()}isSubscribed(t){return this.subscriptionManager.isSubscribed(t)}createView(t,e){const n=new f.ContextView(this,t,e);return n.open(),n}contains(t){return t=u.BindingKey.validate(t),this.registry.has(t)}isBound(t){return!!this.contains(t)||!!this._parent&&this._parent.isBound(t)}getOwnerContext(t){let e;return e=t instanceof i.Binding?t.key:t,this.contains(e)?t instanceof i.Binding?this.registry.get(e.toString())===t?this:void 0:this:this._parent?this._parent.getOwnerContext(e):void 0}getScopedContext(t){return this.scope===t?this:this._parent?this._parent.getScopedContext(t):void 0}getResolutionContext(t){let e;switch(t.scope){case i.BindingScope.SINGLETON:return this.getOwnerContext(t.key);case i.BindingScope.TRANSIENT:case i.BindingScope.CONTEXT:return this;case i.BindingScope.REQUEST:return e=this.getScopedContext(t.scope),null!=e?e:(this.debug('No context is found for binding "%s (scope=%s)". Fall back to the current context.',t.key,t.scope),this);default:return this.getScopedContext(t.scope)}}isVisibleTo(t){let e=t;for(;null!=e;){if(e===this)return!0;e=e._parent}return!1}find(t){var e;if("function"==typeof t&&a.isBindingTagFilter(t))return this._findByTagIndex(t.bindingTagPattern);const n=[],r=a.filterByKey(t);for(const t of this.registry.values())r(t)&&n.push(t);const o=null===(e=this._parent)||void 0===e?void 0:e.find(r);return this._mergeWithParent(n,o)}findByTag(t){return this.find(a.filterByTag(t))}_findByTagIndex(t){var e;const n=this.tagIndexer.findByTagIndex(t),r=null===(e=this._parent)||void 0===e?void 0:e._findByTagIndex(t);return this._mergeWithParent(n,r)}_mergeWithParent(t,e){if(!e)return t;const n=e.filter((e=>!t.some((t=>t.key===e.key))));return t.concat(n)}async get(t,e){return this.debug("Resolving binding: %s",t),this.getValueOrPromise(t,e)}getSync(t,e){this.debug("Resolving binding synchronously: %s",t);const n=this.getValueOrPromise(t,e);if(g.isPromiseLike(n))throw new Error(`Cannot get ${t} synchronously: the value is a promise`);return n}getBinding(t,e){t=u.BindingKey.validate(t);const n=this.registry.get(t);if(n)return n;if(this._parent)return this._parent.getBinding(t,e);if(!(null==e?void 0:e.optional))throw new Error(`The key '${t}' is not bound to any value in context ${this.name}`)}findOrCreateBinding(t,e){let n;return n=e===_.ALWAYS_CREATE?this.bind(t):e===_.NEVER_CREATE||this.isBound(t)?this.getBinding(t):this.bind(t),n}getValueOrPromise(t,e){const{key:n,propertyPath:r}=u.BindingKey.parseKeyWithPath(t),o=d.asResolutionOptions(e),s=this.getBinding(n,{optional:!0});if(null==s){if(o.optional)return;throw new d.ResolutionError(`The key '${n}' is not bound to any value in context ${this.name}`,{context:this,binding:i.Binding.bind(n),options:o})}const a=s.getValue(this,o);return null==r||""===r?a:g.transformValueOrPromise(a,(t=>g.getDeepProperty(t,r)))}toJSON(){const t={};for(const[e,n]of this.registry)t[e]=n.toJSON();return t}inspect(t={}){return this._inspect(t,new v)}_inspect(t,e){var n;t={includeParent:!0,includeInjections:!1,...t};const r={};for(const[o,i]of this.registry){const s=null!==(n=i.valueConstructor)&&void 0!==n?n:i.providerConstructor;let a;if(null!=s&&(a=e.visit(s)),r[o]=i.inspect(t),null!=a){const t=r[o];i.valueConstructor?t.valueConstructor=a:i.providerConstructor&&(t.providerConstructor=a)}}const o={name:this.name,bindings:r};return t.includeParent?(this._parent&&(o.parent=this._parent._inspect(t,e)),o):o}on(t,e){return super.on(t,e)}once(t,e){return super.once(t,e)}}e.Context=y;class v{constructor(){this.classes=new Map,this.nameIndex=new Map}visit(t){let e=this.classes.get(t);if(null==e){e=t.name;let n=this.nameIndex.get(e);"number"==typeof n?(this.nameIndex.set(e,++n),e=`${e} #${n}`):this.nameIndex.set(e,0),this.classes.set(t,e)}return e}}var _;!function(t){t.ALWAYS_CREATE="Always",t.NEVER_CREATE="Never",t.CREATE_IF_NOT_BOUND="IfNotBound"}(_=e.BindingCreationPolicy||(e.BindingCreationPolicy={}))},1170:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const r=n(4474);r.__exportStar(n(3481),e),r.__exportStar(n(7572),e),r.__exportStar(n(217),e),r.__exportStar(n(6353),e),r.__exportStar(n(4282),e),r.__exportStar(n(7849),e),r.__exportStar(n(1808),e),r.__exportStar(n(3567),e),r.__exportStar(n(7975),e),r.__exportStar(n(4540),e),r.__exportStar(n(6501),e),r.__exportStar(n(999),e),r.__exportStar(n(492),e),r.__exportStar(n(3539),e),r.__exportStar(n(4249),e),r.__exportStar(n(5741),e),r.__exportStar(n(8252),e),r.__exportStar(n(7427),e),r.__exportStar(n(2650),e),r.__exportStar(n(4682),e),r.__exportStar(n(7653),e),r.__exportStar(n(1178),e),r.__exportStar(n(1414),e),r.__exportStar(n(8740),e),r.__exportStar(n(454),e),r.__exportStar(n(7324),e)},4249:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.config=void 0;const r=n(1808),o=n(492),i=n(3539),s=n(1414),a=n(7324);function u(t,e){return"object"==typeof(t=null!=t?t:"")&&(e=t,t=""),e=Object.assign({propertyPath:t,decorator:"@config",optional:!0},e),i.inject("",e,l)}function c(t,e){return t.metadata.fromBinding||function(t){var e;return null===(e=t.currentBinding)||void 0===e?void 0:e.key}(e)}function l(t,e,n){const r=c(e,n);if(!r)return;const o=e.metadata;return t.getConfigAsValueOrPromise(r,o.propertyPath,{session:n,optional:o.optional})}function f(t,e,n){i.assertTargetType(e,Function,"Getter function");const r=c(e,n),o=s.ResolutionSession.fork(n),a=e.metadata;return async function(){if(r)return t.getConfigAsValueOrPromise(r,a.propertyPath,{session:o,optional:a.optional})}}function p(t,e,n){i.assertTargetType(e,o.ContextView);const s=c(e,n);if(!s)return;const a=new d(t,(t=>t.key===r.BindingKey.buildKeyForConfig(s).toString()),e.metadata.propertyPath);return a.open(),a}e.config=u,function(t){t.getter=function(t,e){return"object"==typeof(t=null!=t?t:"")&&(e=t,t=""),e=Object.assign({propertyPath:t,decorator:"@config.getter",optional:!0},e),i.inject("",e,f)},t.view=function(t,e){return"object"==typeof(t=null!=t?t:"")&&(e=t,t=""),e=Object.assign({propertyPath:t,decorator:"@config.view",optional:!0},e),i.inject("",e,p)}}(u=e.config||(e.config={}));class d extends o.ContextView{constructor(t,e,n){super(t,e),this.propertyPath=n}async values(t){const e=await super.values(t),n=this.propertyPath;return n?e.map((t=>a.getDeepProperty(t,n))):e}}},3539:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.hasInjections=e.inspectInjections=e.describeInjectedProperties=e.inspectTargetType=e.describeInjectedArguments=e.assertTargetType=e.Getter=e.inject=void 0;const r=n(3481),o=n(7572),i=n(4282),s=n(492),a=n(1414),u=r.MetadataAccessor.create("inject:parameters"),c=r.MetadataAccessor.create("inject:properties"),l=r.MetadataAccessor.create("inject:methods");function f(t,e,n){"function"!=typeof t||n||(n=m);const o=Object.assign({decorator:"@inject"},e);if(o.bindingComparator&&!n)throw new Error("Binding comparator is only allowed with a binding filter");if(!t&&"function"!=typeof n)throw new Error("A non-empty binding selector or resolve function is required for @inject");return function(e,i,s){if("number"==typeof s)r.ParameterDecoratorFactory.createDecorator(u,{target:e,member:i,methodDescriptorOrParameterIndex:s,bindingSelector:t,metadata:o,resolve:n},{cloneInputSpec:!1,decoratorName:o.decorator})(e,i,s);else{if(!i)throw new Error("@inject can only be used on a property or a method parameter");if(e instanceof Function)throw new Error("@inject is not supported for a static property: "+r.DecoratorFactory.getTargetName(e,i));if(s)throw new Error("@inject cannot be used on a method: "+r.DecoratorFactory.getTargetName(e,i,s));r.PropertyDecoratorFactory.createDecorator(c,{target:e,member:i,methodDescriptorOrParameterIndex:s,bindingSelector:t,metadata:o,resolve:n},{cloneInputSpec:!1,decoratorName:o.decorator})(e,i)}}}function p(t,e,n){const r=a.ResolutionSession.describeInjection(t).targetName,o=_(t);if(o&&o!==e)throw n=null!=n?n:e.name,new Error(`The type of ${r} (${o.name}) is not ${n}`);return r}function d(t,e,n){p(e,Function,"Getter function");const r=e.bindingSelector,o={session:a.ResolutionSession.fork(n),...e.metadata};return function(){return t.get(r,o)}}function h(t,e){const n=p(e,Function,"Setter function"),r=e.bindingSelector;if(!i.isBindingAddress(r))throw new Error(`@inject.setter (${n}) does not allow BindingFilter.`);if(""===r)throw new Error("Binding key is not set for @inject.setter");return function(n){y(t,e).to(n)}}function g(t,e,n){const r=p(e,o.Binding),s=e.bindingSelector;if(!i.isBindingAddress(s))throw new Error(`@inject.binding (${r}) does not allow BindingFilter.`);return y(t,e,n)}function y(t,e,n){if(""===e.bindingSelector)return null==n?void 0:n.currentBinding;const r=e.metadata&&e.metadata.bindingCreation;return t.findOrCreateBinding(e.bindingSelector,r)}function v(t,e){var n,o;e=null!=e?e:"";const i=null!==(n=r.MetadataInspector.getAllMethodMetadata(l,t,{ownMetadataOnly:!0}))&&void 0!==n?n:{};let s=i[e];if(s)return s;const a={};return""===e?function(t){const e=t.toString();return!e.match(/\s+constructor\s*\(\s*\)\s*\{\s*super\(\.\.\.arguments\)/)&&e.match(/\s+constructor\s*\([^\)]*\)\s+\{/m)}(t)&&(a.ownMetadataOnly=!0):Object.prototype.hasOwnProperty.call(t,e)&&(a.ownMetadataOnly=!0),s=null!==(o=r.MetadataInspector.getAllParameterMetadata(u,t,e,a))&&void 0!==o?o:[],i[e]=s,r.MetadataInspector.defineMetadata(l,i,t),s}function _(t){var e;if("number"==typeof t.methodDescriptorOrParameterIndex){const n=r.MetadataInspector.getDesignTypeForMethod(t.target,t.member);return null===(e=null==n?void 0:n.parameterTypes)||void 0===e?void 0:e[t.methodDescriptorOrParameterIndex]}return r.MetadataInspector.getDesignTypeForProperty(t.target,t.member)}function m(t,e,n){p(e,Array);const r=e.bindingSelector;return new s.ContextView(t,r,e.metadata.bindingComparator).resolve(n)}function b(t,e,n){p(e,Function,"Getter function");const r=e.bindingSelector;return s.createViewGetter(t,r,e.metadata.bindingComparator,n)}function w(t,e){p(e,s.ContextView);const n=e.bindingSelector,r=new s.ContextView(t,n,e.metadata.bindingComparator);return r.open(),r}function C(t){var e;return null!==(e=r.MetadataInspector.getAllPropertyMetadata(c,t))&&void 0!==e?e:{}}function O(t){var e,n;const r=a.ResolutionSession.describeInjection(t),o={};return r.targetName&&(o.targetName=r.targetName),i.isBindingAddress(r.bindingSelector)?o.bindingKey=r.bindingSelector.toString():i.isBindingTagFilter(r.bindingSelector)?o.bindingTagPattern=JSON.parse(JSON.stringify(r.bindingSelector.bindingTagPattern)):o.bindingFilter=null!==(n=null===(e=r.bindingSelector)||void 0===e?void 0:e.name)&&void 0!==n?n:"<function>",r.metadata&&(r.metadata.decorator&&"@inject"!==r.metadata.decorator&&(o.decorator=r.metadata.decorator),r.metadata.optional&&(o.optional=r.metadata.optional)),o}e.inject=f,(e.Getter||(e.Getter={})).fromValue=function(t){return()=>Promise.resolve(t)},function(t){t.getter=function(e,n){return n=Object.assign({decorator:"@inject.getter"},n),t(e,n,i.isBindingAddress(e)?d:b)},t.setter=function(e,n){return n=Object.assign({decorator:"@inject.setter"},n),t(e,n,h)},t.binding=function(e,n){return n=Object.assign({decorator:"@inject.binding"},n),t(null!=e?e:"",n,g)},t.tag=function(e,n){return n=Object.assign({decorator:"@inject.tag",tag:e},n),t(i.filterByTag(e),n)},t.view=function(e,n){return n=Object.assign({decorator:"@inject.view"},n),t(e,n,w)},t.context=function(){return t("",{decorator:"@inject.context"},(t=>t))}}(f=e.inject||(e.inject={})),e.assertTargetType=p,e.describeInjectedArguments=v,e.inspectTargetType=_,e.describeInjectedProperties=C,e.inspectInjections=function(t){var e;const n={},r=null!==(e=t.valueConstructor)&&void 0!==e?e:t.providerConstructor;if(null==r)return n;const o=v(r,"").map(O);o.length&&(n.constructorArguments=o);const i=C(r.prototype),s={};for(const t in i)s[t]=O(i[t]);return Object.keys(s).length&&(n.properties=s),n},e.hasInjections=function(t){return null!=r.MetadataInspector.getClassMetadata(u,t)||null!=r.Reflector.getMetadata(u.toString(),t.prototype)||null!=r.MetadataInspector.getAllPropertyMetadata(c,t.prototype)}},5741:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createProxyWithInterceptors=e.InterceptionHandler=e.ProxySource=void 0;const r=n(7975),o=n(8252),i=n(1414);class s{constructor(t){this.value=t,this.type="proxy"}toString(){return this.value.getBindingPath()}}e.ProxySource=s;class a{constructor(t=new r.Context,e,n){this.context=t,this.session=e,this.source=n}get(t,e,n){const r=t;if("string"!=typeof e)return r[e];const i=r[e];return"function"==typeof i?(...n)=>{var r;return o.invokeMethodWithInterceptors(this.context,t,e,n,{source:null!==(r=this.source)&&void 0!==r?r:this.session&&new s(this.session)})}:i}}e.InterceptionHandler=a,e.createProxyWithInterceptors=function(t,e,n,r){return new Proxy(t,new a(e,i.ResolutionSession.fork(n),r))}},7427:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.composeInterceptors=e.invokeInterceptors=e.GenericInterceptorChain=void 0;const r=n(4474).__importDefault(n(4806)),o=n(7324),i=r.default("loopback:context:interceptor-chain");class s{constructor(t,e=(()=>{})){this.interceptors=t,this.finalHandler=e,this._index=0}get index(){return this._index}done(){return this._index===this.interceptors.length}next(){if(this.done())throw new Error("No more interceptor is in the chain");return this.interceptors[this._index++]}}class a{constructor(t,e,n){if(this.context=t,"function"==typeof e){const r=t.createView(e,n);this.getInterceptors=()=>{const t=r.bindings;return n&&t.sort(n),t.map((t=>t.key))}}else Array.isArray(e)&&(this.getInterceptors=()=>e)}invokeInterceptors(t){const e=new s(this.getInterceptors(),t);return this.next(e)}asInterceptor(){return(t,e)=>this.invokeInterceptors(e)}next(t){return t.done()?t.finalHandler():this.invokeNextInterceptor(t)}invokeNextInterceptor(t){const e=t.index,n=t.next(),r=this.loadInterceptor(n);return o.transformValueOrPromise(r,(n=>(i.enabled&&i("Invoking interceptor %d (%s) on %s",e,n.name),n(this.context,(()=>this.next(t))))))}loadInterceptor(t){return"function"==typeof t?t:(i("Resolving interceptor binding %s",t),this.context.getValueOrPromise(t))}}e.GenericInterceptorChain=a,e.invokeInterceptors=function(t,e){return new a(t,e).invokeInterceptors()},e.composeInterceptors=function(...t){return(e,n)=>new a(e,t).asInterceptor()(e,n)}},8252:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.registerInterceptor=e.invokeMethodWithInterceptors=e.intercept=e.INTERCEPT_CLASS_KEY=e.mergeInterceptors=e.INTERCEPT_METHOD_KEY=e.globalInterceptor=e.asGlobalInterceptor=e.InterceptedInvocationContext=void 0;const r=n(4474),o=n(3481),i=r.__importDefault(n(9491)),s=r.__importDefault(n(4806)),a=n(6353),u=n(7849),c=n(1808),l=n(3567),f=n(7427),p=n(2650),d=n(7653),h=n(7324),g=s.default("loopback:context:interceptor");class y extends p.InvocationContext{getGlobalInterceptorBindingKeys(){let t=this.findByTag(d.ContextTags.GLOBAL_INTERCEPTOR);t=t.filter((t=>this.applicableTo(t))),this.sortGlobalInterceptorBindings(t);const e=t.map((t=>t.key));return g("Global interceptor binding keys:",e),e}applicableTo(t){var e;const n=null===(e=this.source)||void 0===e?void 0:e.type;if(null==n)return!0;const r=t.tagMap[d.ContextTags.GLOBAL_INTERCEPTOR_SOURCE];return null==r||r===n||Array.isArray(r)&&r.includes(n)}sortGlobalInterceptorBindings(t){var e;const n=null!==(e=this.getSync(d.ContextBindings.GLOBAL_INTERCEPTOR_ORDERED_GROUPS,{optional:!0}))&&void 0!==e?e:[];return l.sortBindingsByPhase(t,d.ContextTags.GLOBAL_INTERCEPTOR_GROUP,n)}loadInterceptors(){var t,n;let r=null!==(t=o.MetadataInspector.getMethodMetadata(e.INTERCEPT_METHOD_KEY,this.target,this.methodName))&&void 0!==t?t:[];const i="function"==typeof this.target?this.target:this.target.constructor;return r=_(null!==(n=o.MetadataInspector.getClassMetadata(e.INTERCEPT_CLASS_KEY,i))&&void 0!==n?n:[],r),r=_(this.getGlobalInterceptorBindingKeys(),r),g("Interceptors for %s",this.targetName,r),r}}function v(t){return e=>{e.tag(d.ContextTags.GLOBAL_INTERCEPTOR).tag({[d.ContextTags.NAMESPACE]:d.GLOBAL_INTERCEPTOR_NAMESPACE}),t&&e.tag({[d.ContextTags.GLOBAL_INTERCEPTOR_GROUP]:t})}}function _(t,e){const n=new Set(t),r=new Set(e);for(const t of n)r.has(t)&&n.delete(t);for(const t of r)n.add(t);return Array.from(n)}e.InterceptedInvocationContext=y,e.asGlobalInterceptor=v,e.globalInterceptor=function(t,...e){return a.injectable(v(t),...e)},e.INTERCEPT_METHOD_KEY=o.MetadataAccessor.create("intercept:method"),e.mergeInterceptors=_,e.INTERCEPT_CLASS_KEY=o.MetadataAccessor.create("intercept:class");class m extends o.ClassDecoratorFactory{mergeWithOwn(t,e){return t=t||[],_(this.spec,t)}}class b extends o.MethodDecoratorFactory{mergeWithOwn(t,e,n,r){const o=(t=t||{})[n]||[];return t[n]=_(this.spec,o),t}}e.intercept=function(...t){return function(n,r,i){if(r&&i)return b.createDecorator(e.INTERCEPT_METHOD_KEY,t,{decoratorName:"@intercept"})(n,r,i);if("function"==typeof n&&!r&&!i)return m.createDecorator(e.INTERCEPT_CLASS_KEY,t,{decoratorName:"@intercept"})(n);throw new Error("@intercept cannot be used on a property: "+o.DecoratorFactory.getTargetName(n,r,i))}},e.invokeMethodWithInterceptors=function(t,e,n,r,o={}){i.default(!o.skipInterceptors,"skipInterceptors is not allowed");const s=new y(t,e,n,r,o.source);return s.assertMethodExists(),h.tryWithFinally((()=>{const t=s.loadInterceptors();return t.push((()=>s.invokeTargetMethod(o))),f.invokeInterceptors(s,t)}),(()=>s.close()))},e.registerInterceptor=function(t,e,n={}){var r,o,i;let{global:s}=n;const{group:a,source:l}=n;null==a&&null==l||(s=!1!==s);const f=(null!==(o=null!==(r=n.namespace)&&void 0!==r?r:n.defaultNamespace)&&void 0!==o?o:s)?d.GLOBAL_INTERCEPTOR_NAMESPACE:d.LOCAL_INTERCEPTOR_NAMESPACE;let p;if(u.isProviderClass(e))p=u.createBindingFromClass(e,{defaultNamespace:f,...n}),p.tagMap[d.ContextTags.GLOBAL_INTERCEPTOR]&&(s=!0),t.add(p);else{let r=n.key;if(!r){const t=null!==(i=n.name)&&void 0!==i?i:e.name;r=t?`${f}.${t}`:c.BindingKey.generate(f).key}p=t.bind(r).to(e)}return s&&(p.apply(v(a)),l&&p.tag({[d.ContextTags.GLOBAL_INTERCEPTOR_SOURCE]:l})),p}},2650:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.invokeMethod=e.InvocationContext=void 0;const r=n(4474),o=n(3481),i=r.__importDefault(n(9491)),s=r.__importDefault(n(4806)),a=n(7975),u=n(8252),c=n(8740),l=n(7324),f=s.default("loopback:context:invocation"),p=o.DecoratorFactory.getTargetName;class d extends a.Context{constructor(t,e,n,r,o){super(t),this.target=e,this.methodName=n,this.args=r,this.source=o}get targetClass(){return"function"==typeof this.target?this.target:this.target.constructor}get targetName(){return p(this.target,this.methodName)}get description(){const t=null==this.source?"":`${this.source} => `;return`InvocationContext(${this.name}): ${t}${this.targetName}`}toString(){return this.description}assertMethodExists(){const t=this.target;if("function"!=typeof t[this.methodName]){const t=p(this.target,this.methodName);i.default(!1,`Method ${t} not found`)}return t}invokeTargetMethod(t={skipParameterInjection:!0}){const e=this.assertMethodExists();return t.skipParameterInjection?g(0,e,this.methodName,this.args):h(this,e,this.methodName,this.args,t.session)}}function h(t,e,n,r,o){const s=p(e,n);f.enabled&&(f("Invoking method %s",s),(null==r?void 0:r.length)&&f("Non-injected arguments:",r));const a=c.resolveInjectedArguments(e,n,t,o,r),u=e;return i.default("function"==typeof u[n],`Method ${n} not found`),l.transformValueOrPromise(a,(t=>(f.enabled&&f("Injected arguments for %s:",s,t),g(0,u,n,t))))}function g(t,e,n,r){const o=e;f.enabled&&f("Invoking method %s",p(e,n),r);const i=o[n](...r);return f.enabled&&f("Method invoked: %s",p(e,n),i),i}e.InvocationContext=d,e.invokeMethod=function(t,e,n,r=[],o={}){return o.skipInterceptors?o.skipParameterInjection?g(0,t,e,r):h(n,t,e,r,o.session):u.invokeMethodWithInterceptors(n,t,e,r,o)}},4682:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},7653:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ContextBindings=e.LOCAL_INTERCEPTOR_NAMESPACE=e.GLOBAL_INTERCEPTOR_NAMESPACE=e.ContextTags=void 0;const r=n(1808);var o,i;(i=e.ContextTags||(e.ContextTags={})).CLASS="class",i.PROVIDER="provider",i.DYNAMIC_VALUE_PROVIDER="dynamicValueProvider",i.TYPE="type",i.NAMESPACE="namespace",i.NAME="name",i.KEY="key",i.CONFIGURATION_FOR="configurationFor",i.GLOBAL_INTERCEPTOR="globalInterceptor",i.GLOBAL_INTERCEPTOR_SOURCE="globalInterceptorSource",i.GLOBAL_INTERCEPTOR_GROUP="globalInterceptorGroup",e.GLOBAL_INTERCEPTOR_NAMESPACE="globalInterceptors",e.LOCAL_INTERCEPTOR_NAMESPACE="interceptors",(o=e.ContextBindings||(e.ContextBindings={})).CONFIGURATION_RESOLVER=r.BindingKey.create(`${r.BindingKey.CONFIG_NAMESPACE}.resolver`),o.GLOBAL_INTERCEPTOR_ORDERED_GROUPS=r.BindingKey.create("globalInterceptor.orderedGroups")},1178:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},1414:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ResolutionError=e.asResolutionOptions=e.ResolutionSession=void 0;const r=n(4474),o=n(3481),i=r.__importDefault(n(4806)),s=n(7324),a=i.default("loopback:context:resolver:session"),u=o.DecoratorFactory.getTargetName;function c(t){return null!=t&&"binding"===t.type}function l(t){return null!=t&&"injection"===t.type}class f{constructor(){this.stack=[]}static fork(t){if(void 0===t)return;const e=new f;return e.stack.push(...t.stack),e}static runWithBinding(t,e,n=new f){return n.pushBinding(e),s.tryWithFinally((()=>t(n)),(()=>n.popBinding()))}static runWithInjection(t,e,n=new f){return n.pushInjection(e),s.tryWithFinally((()=>t(n)),(()=>n.popInjection()))}static describeInjection(t){return{targetName:u(t.target,t.member,t.methodDescriptorOrParameterIndex),bindingSelector:t.bindingSelector,metadata:t.metadata}}pushInjection(t){a.enabled&&a("Enter injection:",f.describeInjection(t)),this.stack.push({type:"injection",value:t}),a.enabled&&a("Resolution path:",this.getResolutionPath())}popInjection(){const t=this.stack.pop();if(!l(t))throw new Error("The top element must be an injection");const e=t.value;return a.enabled&&(a("Exit injection:",f.describeInjection(e)),a("Resolution path:",this.getResolutionPath()||"<empty>")),e}get currentInjection(){for(let t=this.stack.length-1;t>=0;t--){const e=this.stack[t];if(l(e))return e.value}}get currentBinding(){for(let t=this.stack.length-1;t>=0;t--){const e=this.stack[t];if(c(e))return e.value}}pushBinding(t){if(a.enabled&&a("Enter binding:",t.toJSON()),this.stack.find((e=>c(e)&&e.value===t))){const e=`Circular dependency detected: ${this.getResolutionPath()} --\x3e ${t.key}`;throw a(e),new Error(e)}this.stack.push({type:"binding",value:t}),a.enabled&&a("Resolution path:",this.getResolutionPath())}popBinding(){const t=this.stack.pop();if(!c(t))throw new Error("The top element must be a binding");const e=t.value;return a.enabled&&(a("Exit binding:",null==e?void 0:e.toJSON()),a("Resolution path:",this.getResolutionPath()||"<empty>")),e}get bindingStack(){return this.stack.filter(c).map((t=>t.value))}get injectionStack(){return this.stack.filter(l).map((t=>t.value))}getBindingPath(){return this.stack.filter(c).map(p).join(" --\x3e ")}getInjectionPath(){return this.injectionStack.map((t=>f.describeInjection(t).targetName)).join(" --\x3e ")}getResolutionPath(){return this.stack.map(p).join(" --\x3e ")}toString(){return this.getResolutionPath()}}function p(t){switch(t.type){case"injection":return"@"+f.describeInjection(t.value).targetName;case"binding":return t.value.key}}e.ResolutionSession=f,e.asResolutionOptions=function(t){return t instanceof f?{session:t}:null!=t?t:{}};class d extends Error{constructor(t,e){super(d.buildMessage(t,e)),this.resolutionCtx=e,this.name=d.name}static buildDetails(t){var e,n,r,o,i,s,a;return{context:null!==(n=null===(e=t.context)||void 0===e?void 0:e.name)&&void 0!==n?n:"",binding:null!==(o=null===(r=t.binding)||void 0===r?void 0:r.key)&&void 0!==o?o:"",resolutionPath:null!==(a=null===(s=null===(i=t.options)||void 0===i?void 0:i.session)||void 0===s?void 0:s.getResolutionPath())&&void 0!==a?a:""}}static buildMessage(t,e){return`${t} (${this.describeResolutionContext(e)})`}static describeResolutionContext(t){const e=d.buildDetails(t),n=[];for(const[t,r]of Object.entries(e))""!==r&&n.push(`${t}: ${r}`);return n.join(", ")}}e.ResolutionError=d},8740:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.resolveInjectedProperties=e.resolveInjectedArguments=e.instantiateClass=void 0;const r=n(4474),o=n(3481),i=r.__importDefault(n(9491)),s=r.__importDefault(n(4806)),a=n(4282),u=n(3539),c=n(1414),l=n(7324),f=s.default("loopback:context:resolver"),p=o.DecoratorFactory.getTargetName;function d(t,e,n){return f.enabled&&f("Resolving an injection:",c.ResolutionSession.describeInjection(e)),t=function(t,e,n){const r=null==n?void 0:n.currentBinding;return null==r||(!e.member||"number"!=typeof e.methodDescriptorOrParameterIndex)&&(t=t.getResolutionContext(r)),t}(t,e,n),c.ResolutionSession.runWithInjection((n=>{if(e.resolve)return e.resolve(t,e,n);{i.default(a.isBindingAddress(e.bindingSelector),"The binding selector must be an address (string or BindingKey)");const r=e.bindingSelector,o={session:n,...e.metadata};return t.getValueOrPromise(r,o)}}),e,n)}function h(t,e,n,r,s){f.enabled&&f("Resolving injected arguments for %s",p(t,e));const a=t;e&&i.default("function"==typeof a[e],`Method ${e} not found`);const h=u.describeInjectedArguments(t,e),g=null!=s?s:[];let y=o.DecoratorFactory.getNumberOfParameters(t,e);const v=h.filter((t=>null!=t)).length;y<v+g.length&&(y=v+g.length);let _=0;return l.resolveList(new Array(y),((o,i)=>{const s=i<h.length?h[i]:void 0;if(null==s||!s.bindingSelector&&!s.resolve){if(_<g.length)return g[_++];{const o=p(t,e,i);throw new c.ResolutionError(`The argument '${o}' is not decorated for dependency injection but no value was supplied by the caller. Did you forget to apply @inject() to the argument?`,{context:n,options:{session:r}})}}return d(n,s,c.ResolutionSession.fork(r))}))}function g(t,e,n){f.enabled&&f("Resolving injected properties for %s",p(t));const r=u.describeInjectedProperties(t.prototype);return l.resolveMap(r,(t=>d(e,t,c.ResolutionSession.fork(n))))}e.instantiateClass=function(t,e,n,r){f.enabled&&(f("Instantiating %s",p(t)),(null==r?void 0:r.length)&&f("Non-injected arguments:",r));const o=h(t,"",e,n,r),i=g(t,e,n),s=l.transformValueOrPromise(o,(e=>(f.enabled&&f("Injected arguments for %s():",t.name,e),new t(...e))));return l.transformValueOrPromise(i,(e=>(f.enabled&&f("Injected properties for %s:",t.name,e),l.transformValueOrPromise(s,(t=>Object.assign(t,e))))))},e.resolveInjectedArguments=h,e.resolveInjectedProperties=g},454:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UNIQUE_ID_PATTERN=e.generateUniqueId=void 0;const r=n(4474).__importDefault(n(4610));e.generateUniqueId=r.default({fixedLength:!1,urlSafe:!0}),e.UNIQUE_ID_PATTERN=/[A-Za-z0-9-_]+-\d+/},7324:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UUID_PATTERN=e.uuid=e.transformValueOrPromise=e.resolveUntil=e.tryCatchFinally=e.tryWithFinally=e.resolveList=e.resolveMap=e.getDeepProperty=e.isPromiseLike=void 0;const r=n(5061);function o(t){return!!t&&("object"==typeof t||"function"==typeof t)&&"function"==typeof t.then}function i(t,e=(t=>{throw t}),n=(()=>{})){let r;try{r=t()}catch(t){r=s(t)}return o(r)?r.then(i,s):i(r);function i(t){try{return t}finally{n()}}function s(t){try{return e(t)}finally{n()}}}e.isPromiseLike=o,e.getDeepProperty=function(t,e){let n=t;const r=e.split(".").filter(Boolean);for(const t of r){if(null==n)return;n=n[t]}return n},e.resolveMap=function(t,e){const n={};let r;const i=t=>e=>{void 0!==e&&(n[t]=e)};for(const s in t){const a=e(t[s],s,t);o(a)?(r||(r=[]),r.push(a.then(i(s)))):void 0!==a&&(n[s]=a)}return r?Promise.all(r).then((()=>n)):n},e.resolveList=function(t,e){const n=new Array(t.length);let r;const i=t=>e=>{n[t]=e};for(let s=0;s<t.length;s++){const a=e(t[s],s,t);o(a)?(r||(r=[]),r.push(a.then(i(s)))):n[s]=a}return r?Promise.all(r).then((()=>n)):n},e.tryWithFinally=function(t,e){return i(t,void 0,e)},e.tryCatchFinally=i,e.resolveUntil=function t(e,n,r){for(;;){const i=e.next();if(i.done)return;const s=i.value,a=n(s);if(o(a))return a.then((o=>r(s,o)?o:t(e,n,r)));if(r(s,a))return a}},e.transformValueOrPromise=function(t,e){return o(t)?t.then(e):e(t)},e.uuid=function(){return r.v4()},e.UUID_PATTERN=/[0-9A-F]{8}-[0-9A-F]{4}-[4][0-9A-F]{3}-[89AB][0-9A-F]{3}-[0-9A-F]{12}/i},3380:(t,e,n)=>{e.formatArgs=function(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+t.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;e.splice(1,0,n,"color: inherit");let r=0,o=0;e[0].replace(/%[a-zA-Z%]/g,(t=>{"%%"!==t&&(r++,"%c"===t&&(o=r))})),e.splice(o,0,n)},e.save=function(t){try{t?e.storage.setItem("debug",t):e.storage.removeItem("debug")}catch(t){}},e.load=function(){let t;try{t=e.storage.getItem("debug")}catch(t){}return!t&&"undefined"!=typeof process&&"env"in process&&(t=process.env.DEBUG),t},e.useColors=function(){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+)/))},e.storage=function(){try{return localStorage}catch(t){}}(),e.destroy=(()=>{let t=!1;return()=>{t||(t=!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`."))}})(),e.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"],e.log=console.debug||console.log||(()=>{}),t.exports=n(8448)(e);const{formatters:r}=t.exports;r.j=function(t){try{return JSON.stringify(t)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}}},8448:(t,e,n)=>{t.exports=function(t){function e(t){let n,o,i,s=null;function a(...t){if(!a.enabled)return;const r=a,o=Number(new Date),i=o-(n||o);r.diff=i,r.prev=n,r.curr=o,n=o,t[0]=e.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");let s=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return"%";s++;const i=e.formatters[o];if("function"==typeof i){const e=t[s];n=i.call(r,e),t.splice(s,1),s--}return n})),e.formatArgs.call(r,t),(r.log||e.log).apply(r,t)}return a.namespace=t,a.useColors=e.useColors(),a.color=e.selectColor(t),a.extend=r,a.destroy=e.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(o!==e.namespaces&&(o=e.namespaces,i=e.enabled(t)),i),set:t=>{s=t}}),"function"==typeof e.init&&e.init(a),a}function r(t,n){const r=e(this.namespace+(void 0===n?":":n)+t);return r.log=this.log,r}function o(t){return t.toString().substring(2,t.toString().length-2).replace(/\.\*\?$/,"*")}return e.debug=e,e.default=e,e.coerce=function(t){return t instanceof Error?t.stack||t.message:t},e.disable=function(){const t=[...e.names.map(o),...e.skips.map(o).map((t=>"-"+t))].join(",");return e.enable(""),t},e.enable=function(t){let n;e.save(t),e.namespaces=t,e.names=[],e.skips=[];const r=("string"==typeof t?t:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(t=r[n].replace(/\*/g,".*?"))[0]?e.skips.push(new RegExp("^"+t.substr(1)+"$")):e.names.push(new RegExp("^"+t+"$")))},e.enabled=function(t){if("*"===t[t.length-1])return!0;let n,r;for(n=0,r=e.skips.length;n<r;n++)if(e.skips[n].test(t))return!1;for(n=0,r=e.names.length;n<r;n++)if(e.names[n].test(t))return!0;return!1},e.humanize=n(2050),e.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(t).forEach((n=>{e[n]=t[n]})),e.names=[],e.skips=[],e.formatters={},e.selectColor=function(t){let n=0;for(let e=0;e<t.length;e++)n=(n<<5)-n+t.charCodeAt(e),n|=0;return e.colors[Math.abs(n)%e.colors.length]},e.enable(e.load()),e}},4806:(t,e,n)=>{"undefined"==typeof process||"renderer"===process.type||!0===process.browser||process.__nwjs?t.exports=n(3380):t.exports=n(1949)},1949:(t,e,n)=>{const r=n(6224),o=n(3837);e.init=function(t){t.inspectOpts={};const n=Object.keys(e.inspectOpts);for(let r=0;r<n.length;r++)t.inspectOpts[n[r]]=e.inspectOpts[n[r]]},e.log=function(...t){return process.stderr.write(o.format(...t)+"\n")},e.formatArgs=function(n){const{namespace:r,useColors:o}=this;if(o){const e=this.color,o="[3"+(e<8?e:"8;5;"+e),i=` ${o};1m${r} `;n[0]=i+n[0].split("\n").join("\n"+i),n.push(o+"m+"+t.exports.humanize(this.diff)+"")}else n[0]=(e.inspectOpts.hideDate?"":(new Date).toISOString()+" ")+r+" "+n[0]},e.save=function(t){t?process.env.DEBUG=t:delete process.env.DEBUG},e.load=function(){return process.env.DEBUG},e.useColors=function(){return"colors"in e.inspectOpts?Boolean(e.inspectOpts.colors):r.isatty(process.stderr.fd)},e.destroy=o.deprecate((()=>{}),"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."),e.colors=[6,2,3,4,5,1];try{const t=n(7013);t&&(t.stderr||t).level>=2&&(e.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(t){}e.inspectOpts=Object.keys(process.env).filter((t=>/^debug_/i.test(t))).reduce(((t,e)=>{const n=e.substring(6).toLowerCase().replace(/_([a-z])/g,((t,e)=>e.toUpperCase()));let r=process.env[e];return r=!!/^(yes|on|true|enabled)$/i.test(r)||!/^(no|off|false|disabled)$/i.test(r)&&("null"===r?null:Number(r)),t[n]=r,t}),{}),t.exports=n(8448)(e);const{formatters:i}=t.exports;i.o=function(t){return this.inspectOpts.colors=this.useColors,o.inspect(t,this.inspectOpts).split("\n").map((t=>t.trim())).join(" ")},i.O=function(t){return this.inspectOpts.colors=this.useColors,o.inspect(t,this.inspectOpts)}},4610:(t,e,n)=>{"use strict";const r=n(7092),o=n(4061),i=Math.pow(2,31)-1,s=n(4300).Buffer;function a(t,e){let n=s.from(o.parse(t)).toString("base64");const r=n.length;return e?("="===n[r-2]&&"="===n[r-1]&&(n=n.substr(0,r-2)+"-"),n.replace(/\+/g,"_").replace(/\//g,"-")):"="===n[r-2]&&"="===n[r-1]?n.substr(0,r-2)+"/":n}function u(t,e){(e=e||{}).urlSafe&&(t=t.replace(/-/g,"/").replace(/_/g,"+"));const n=t.lastIndexOf("/");if(-1===n)return null;const r=t.substring(0,n),i=Number(t.substring(n+1));return!r||isNaN(i)?null:{uuid:o.unparse(s.from(r+"==","base64")),count:i}}t.exports=function(t){let e=!1,n=!1;"boolean"==typeof t?e=t:(n=!!(t=t||{}).urlSafe,e=!!t.fixedLength),c.uuid=r(),c.decode=u;let o=a(c.uuid,n),s=Math.floor(t.startFrom||0);if(isNaN(s)||!(i>s&&s>=0))throw new Error([`when passed, opts.startFrom must be a number between 0 and ${i}.`,"Only the integer part matters.",`- got: ${t.startFrom}`].join("\n"));return c;function c(){const t=e?o+function(t){return t<10?"000000000"+t:t<100?"00000000"+t:t<1e3?"0000000"+t:t<1e4?"000000"+t:t<1e5?"00000"+t:t<1e6?"0000"+t:t<1e7?"000"+t:t<1e8?"00"+t:t<1e9?"0"+t:t}(s++):o+s++;return s===i&&(c.uuid=r(),o=a(c.uuid,n),s=0),t}},t.exports.decode=u},7092:(t,e,n)=>{"use strict";const r=n(5061),o=n(6113);t.exports="function"==typeof o.randomUUID?o.randomUUID:r.v4},2050:t=>{var e=1e3,n=60*e,r=60*n,o=24*r;function i(t,e,n,r){var o=e>=1.5*n;return Math.round(t/n)+" "+r+(o?"s":"")}t.exports=function(t,s){s=s||{};var a,u,c=typeof t;if("string"===c&&t.length>0)return function(t){if(!((t=String(t)).length>100)){var i=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(i){var s=parseFloat(i[1]);switch((i[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"weeks":case"week":case"w":return 6048e5*s;case"days":case"day":case"d":return s*o;case"hours":case"hour":case"hrs":case"hr":case"h":return s*r;case"minutes":case"minute":case"mins":case"min":case"m":return s*n;case"seconds":case"second":case"secs":case"sec":case"s":return s*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}}(t);if("number"===c&&isFinite(t))return s.long?(a=t,(u=Math.abs(a))>=o?i(a,u,o,"day"):u>=r?i(a,u,r,"hour"):u>=n?i(a,u,n,"minute"):u>=e?i(a,u,e,"second"):a+" ms"):function(t){var i=Math.abs(t);return i>=o?Math.round(t/o)+"d":i>=r?Math.round(t/r)+"h":i>=n?Math.round(t/n)+"m":i>=e?Math.round(t/e)+"s":t+"ms"}(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))}},2131:(t,e,n)=>{"use strict";const r=n(5842),o=Symbol.asyncIterator||"@@asyncIterator",i=t=>{const e=t.on||t.addListener||t.addEventListener,n=t.off||t.removeListener||t.removeEventListener;if(!e||!n)throw new TypeError("Emitter is not compatible");return{addListener:e.bind(t),removeListener:n.bind(t)}},s=t=>Array.isArray(t)?t:[t],a=(t,e,n)=>{let o;const a=new Promise(((r,a)=>{if(!((n={rejectionEvents:["error"],multiArgs:!1,resolveImmediately:!1,...n}).count>=0)||n.count!==1/0&&!Number.isInteger(n.count))throw new TypeError("The `count` option should be at least 0 or more");const u=s(e),c=[],{addListener:l,removeListener:f}=i(t),p=(...t)=>{const e=n.multiArgs?t:t[0];n.filter&&!n.filter(e)||(c.push(e),n.count===c.length&&(o(),r(c)))},d=t=>{o(),a(t)};o=()=>{for(const t of u)f(t,p);for(const t of n.rejectionEvents)f(t,d)};for(const t of u)l(t,p);for(const t of n.rejectionEvents)l(t,d);n.resolveImmediately&&r(c)}));if(a.cancel=o,"number"==typeof n.timeout){const t=r(a,n.timeout);return t.cancel=o,t}return a},u=(t,e,n)=>{"function"==typeof n&&(n={filter:n}),n={...n,count:1,resolveImmediately:!1};const r=a(t,e,n),o=r.then((t=>t[0]));return o.cancel=r.cancel,o};t.exports=u,t.exports.default=u,t.exports.multiple=a,t.exports.iterator=(t,e,n)=>{"function"==typeof n&&(n={filter:n});const r=s(e);n={rejectionEvents:["error"],resolutionEvents:[],limit:1/0,multiArgs:!1,...n};const{limit:a}=n;if(!(a>=0)||a!==1/0&&!Number.isInteger(a))throw new TypeError("The `limit` option should be a non-negative integer or Infinity");if(0===a)return{[Symbol.asyncIterator](){return this},next:async()=>({done:!0,value:void 0})};const{addListener:u,removeListener:c}=i(t);let l,f=!1,p=!1;const d=[],h=[];let g=0,y=!1;const v=(...t)=>{g++,y=g===a;const e=n.multiArgs?t:t[0];if(d.length>0){const{resolve:t}=d.shift();return t({done:!1,value:e}),void(y&&_())}h.push(e),y&&_()},_=()=>{f=!0;for(const t of r)c(t,v);for(const t of n.rejectionEvents)c(t,m);for(const t of n.resolutionEvents)c(t,b);for(;d.length>0;){const{resolve:t}=d.shift();t({done:!0,value:void 0})}},m=(...t)=>{if(l=n.multiArgs?t:t[0],d.length>0){const{reject:t}=d.shift();t(l)}else p=!0;_()},b=(...t)=>{const e=n.multiArgs?t:t[0];if(!n.filter||n.filter(e)){if(d.length>0){const{resolve:t}=d.shift();t({done:!0,value:e})}else h.push(e);_()}};for(const t of r)u(t,v);for(const t of n.rejectionEvents)u(t,m);for(const t of n.resolutionEvents)u(t,b);return{[o](){return this},async next(){if(h.length>0){const t=h.shift();return{done:f&&0===h.length&&!y,value:t}}if(p)throw p=!1,l;return f?{done:!0,value:void 0}:new Promise(((t,e)=>d.push({resolve:t,reject:e})))},return:async t=>(_(),{done:f,value:t})}},t.exports.TimeoutError=r.TimeoutError},1604:t=>{"use strict";t.exports=(t,e)=>(e=e||(()=>{}),t.then((t=>new Promise((t=>{t(e())})).then((()=>t))),(t=>new Promise((t=>{t(e())})).then((()=>{throw t})))))},5842:(t,e,n)=>{"use strict";const r=n(1604);class o extends Error{constructor(t){super(t),this.name="TimeoutError"}}const i=(t,e,n)=>new Promise(((i,s)=>{if("number"!=typeof e||e<0)throw new TypeError("Expected `milliseconds` to be a positive number");if(e===1/0)return void i(t);const a=setTimeout((()=>{if("function"==typeof n){try{i(n())}catch(t){s(t)}return}const r=n instanceof Error?n:new o("string"==typeof n?n:`Promise timed out after ${e} milliseconds`);"function"==typeof t.cancel&&t.cancel(),s(r)}),e);r(t.then(i,s),(()=>{clearTimeout(a)}))}));t.exports=i,t.exports.default=i,t.exports.TimeoutError=o},4474:(t,e,n)=>{"use strict";n.r(e),n.d(e,{__extends:()=>o,__assign:()=>i,__rest:()=>s,__decorate:()=>a,__param:()=>u,__metadata:()=>c,__awaiter:()=>l,__generator:()=>f,__createBinding:()=>p,__exportStar:()=>d,__values:()=>h,__read:()=>g,__spread:()=>y,__spreadArrays:()=>v,__spreadArray:()=>_,__await:()=>m,__asyncGenerator:()=>b,__asyncDelegator:()=>w,__asyncValues:()=>C,__makeTemplateObject:()=>O,__importStar:()=>x,__importDefault:()=>S,__classPrivateFieldGet:()=>I,__classPrivateFieldSet:()=>T});var r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var i=function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};function s(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]])}return n}function a(t,e,n,r){var o,i=arguments.length,s=i<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(i<3?o(s):i>3?o(e,n,s):o(e,n))||s);return i>3&&s&&Object.defineProperty(e,n,s),s}function u(t,e){return function(n,r){e(n,r,t)}}function c(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function l(t,e,n,r){return new(n||(n=Promise))((function(o,i){function s(t){try{u(r.next(t))}catch(t){i(t)}}function a(t){try{u(r.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(s,a)}u((r=r.apply(t,e||[])).next())}))}function f(t,e){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!((o=(o=s.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=e.call(t,s)}catch(t){i=[6,t],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}}var p=Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]};function d(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||p(e,t,n)}function h(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function g(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),s=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)s.push(r.value)}catch(t){o={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return s}function y(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(g(arguments[e]));return t}function v(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),o=0;for(e=0;e<n;e++)for(var i=arguments[e],s=0,a=i.length;s<a;s++,o++)r[o]=i[s];return r}function _(t,e,n){if(n||2===arguments.length)for(var r,o=0,i=e.length;o<i;o++)!r&&o in e||(r||(r=Array.prototype.slice.call(e,0,o)),r[o]=e[o]);return t.concat(r||Array.prototype.slice.call(e))}function m(t){return this instanceof m?(this.v=t,this):new m(t)}function b(t,e,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,o=n.apply(t,e||[]),i=[];return r={},s("next"),s("throw"),s("return"),r[Symbol.asyncIterator]=function(){return this},r;function s(t){o[t]&&(r[t]=function(e){return new Promise((function(n,r){i.push([t,e,n,r])>1||a(t,e)}))})}function a(t,e){try{(n=o[t](e)).value instanceof m?Promise.resolve(n.value.v).then(u,c):l(i[0][2],n)}catch(t){l(i[0][3],t)}var n}function u(t){a("next",t)}function c(t){a("throw",t)}function l(t,e){t(e),i.shift(),i.length&&a(i[0][0],i[0][1])}}function w(t){var e,n;return e={},r("next"),r("throw",(function(t){throw t})),r("return"),e[Symbol.iterator]=function(){return this},e;function r(r,o){e[r]=t[r]?function(e){return(n=!n)?{value:m(t[r](e)),done:"return"===r}:o?o(e):e}:o}}function C(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=h(t),e={},r("next"),r("throw"),r("return"),e[Symbol.asyncIterator]=function(){return this},e);function r(n){e[n]=t[n]&&function(e){return new Promise((function(r,o){!function(t,e,n,r){Promise.resolve(r).then((function(e){t({value:e,done:n})}),e)}(r,o,(e=t[n](e)).done,e.value)}))}}}function O(t,e){return Object.defineProperty?Object.defineProperty(t,"raw",{value:e}):t.raw=e,t}var E=Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e};function x(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&p(e,t,n);return E(e,t),e}function S(t){return t&&t.__esModule?t:{default:t}}function I(t,e,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!r:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(t):r?r.value:e.get(t)}function T(t,e,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!o:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(t,n):o?o.value=n:e.set(t,n),n}},4061:t=>{"use strict";for(var e=[],n={},r=0;r<256;r++)e[r]=(r+256).toString(16).substr(1),n[e[r]]=r;t.exports={parse:function(t,e,r){var o=e&&r||0,i=0;for(e=e||[],t.toLowerCase().replace(/[0-9a-f]{2}/g,(function(t){i<16&&(e[o+i++]=n[t])}));i<16;)e[o+i++]=0;return e},unparse:function(t,n){var r=n||0,o=e;return o[t[r++]]+o[t[r++]]+o[t[r++]]+o[t[r++]]+"-"+o[t[r++]]+o[t[r++]]+"-"+o[t[r++]]+o[t[r++]]+"-"+o[t[r++]]+o[t[r++]]+"-"+o[t[r++]]+o[t[r++]]+o[t[r++]]+o[t[r++]]+o[t[r++]]+o[t[r++]]}}},5061:(t,e,n)=>{"use strict";n.r(e),n.d(e,{NIL:()=>C,parse:()=>v,stringify:()=>f,v1:()=>y,v3:()=>m,v4:()=>b,v5:()=>w,validate:()=>c,version:()=>O});var r=n(6113),o=n.n(r);const i=new Uint8Array(256);let s=i.length;function a(){return s>i.length-16&&(o().randomFillSync(i),s=0),i.slice(s,s+=16)}const u=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,c=function(t){return"string"==typeof t&&u.test(t)},l=[];for(let t=0;t<256;++t)l.push((t+256).toString(16).substr(1));const f=function(t,e=0){const n=(l[t[e+0]]+l[t[e+1]]+l[t[e+2]]+l[t[e+3]]+"-"+l[t[e+4]]+l[t[e+5]]+"-"+l[t[e+6]]+l[t[e+7]]+"-"+l[t[e+8]]+l[t[e+9]]+"-"+l[t[e+10]]+l[t[e+11]]+l[t[e+12]]+l[t[e+13]]+l[t[e+14]]+l[t[e+15]]).toLowerCase();if(!c(n))throw TypeError("Stringified UUID is invalid");return n};let p,d,h=0,g=0;const y=function(t,e,n){let r=e&&n||0;const o=e||new Array(16);let i=(t=t||{}).node||p,s=void 0!==t.clockseq?t.clockseq:d;if(null==i||null==s){const e=t.random||(t.rng||a)();null==i&&(i=p=[1|e[0],e[1],e[2],e[3],e[4],e[5]]),null==s&&(s=d=16383&(e[6]<<8|e[7]))}let u=void 0!==t.msecs?t.msecs:Date.now(),c=void 0!==t.nsecs?t.nsecs:g+1;const l=u-h+(c-g)/1e4;if(l<0&&void 0===t.clockseq&&(s=s+1&16383),(l<0||u>h)&&void 0===t.nsecs&&(c=0),c>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");h=u,g=c,d=s,u+=122192928e5;const y=(1e4*(268435455&u)+c)%4294967296;o[r++]=y>>>24&255,o[r++]=y>>>16&255,o[r++]=y>>>8&255,o[r++]=255&y;const v=u/4294967296*1e4&268435455;o[r++]=v>>>8&255,o[r++]=255&v,o[r++]=v>>>24&15|16,o[r++]=v>>>16&255,o[r++]=s>>>8|128,o[r++]=255&s;for(let t=0;t<6;++t)o[r+t]=i[t];return e||f(o)},v=function(t){if(!c(t))throw TypeError("Invalid UUID");let e;const n=new Uint8Array(16);return n[0]=(e=parseInt(t.slice(0,8),16))>>>24,n[1]=e>>>16&255,n[2]=e>>>8&255,n[3]=255&e,n[4]=(e=parseInt(t.slice(9,13),16))>>>8,n[5]=255&e,n[6]=(e=parseInt(t.slice(14,18),16))>>>8,n[7]=255&e,n[8]=(e=parseInt(t.slice(19,23),16))>>>8,n[9]=255&e,n[10]=(e=parseInt(t.slice(24,36),16))/1099511627776&255,n[11]=e/4294967296&255,n[12]=e>>>24&255,n[13]=e>>>16&255,n[14]=e>>>8&255,n[15]=255&e,n};function _(t,e,n){function r(t,r,o,i){if("string"==typeof t&&(t=function(t){t=unescape(encodeURIComponent(t));const e=[];for(let n=0;n<t.length;++n)e.push(t.charCodeAt(n));return e}(t)),"string"==typeof r&&(r=v(r)),16!==r.length)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let s=new Uint8Array(16+t.length);if(s.set(r),s.set(t,r.length),s=n(s),s[6]=15&s[6]|e,s[8]=63&s[8]|128,o){i=i||0;for(let t=0;t<16;++t)o[i+t]=s[t];return o}return f(s)}try{r.name=t}catch(t){}return r.DNS="6ba7b810-9dad-11d1-80b4-00c04fd430c8",r.URL="6ba7b811-9dad-11d1-80b4-00c04fd430c8",r}const m=_("v3",48,(function(t){return Array.isArray(t)?t=Buffer.from(t):"string"==typeof t&&(t=Buffer.from(t,"utf8")),o().createHash("md5").update(t).digest()})),b=function(t,e,n){const r=(t=t||{}).random||(t.rng||a)();if(r[6]=15&r[6]|64,r[8]=63&r[8]|128,e){n=n||0;for(let t=0;t<16;++t)e[n+t]=r[t];return e}return f(r)},w=_("v5",80,(function(t){return Array.isArray(t)?t=Buffer.from(t):"string"==typeof t&&(t=Buffer.from(t,"utf8")),o().createHash("sha1").update(t).digest()})),C="00000000-0000-0000-0000-000000000000",O=function(t){if(!c(t))throw TypeError("Invalid UUID");return parseInt(t.substr(14,1),16)}},7316:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Application=void 0;const r=n(437),o=n(1170),i=r.__importDefault(n(9491)),s=r.__importDefault(n(9708)),a=n(2361),u=n(123),c=n(3669),l=n(5098),f=n(3987),p=n(8200),d=s.default("loopback:core:application"),h=s.default("loopback:core:application:shutdown"),g=s.default("loopback:core:application:warning");class y extends o.Context{constructor(t,e){super(...function(t,e){let n,r;return t instanceof o.Context?(r=t,n=void 0):(r=e,n=null==t?void 0:t.name),[r,n]}(t,e)),this._isShuttingDown=!1,this._initialized=!1,this._state="created",this.scope=o.BindingScope.APPLICATION,this.options=t instanceof o.Context?{}:null!=t?t:{},this._debug=d,this.bind(c.CoreBindings.LIFE_CYCLE_OBSERVER_REGISTRY).toClass(f.LifeCycleObserverRegistry).inScope(o.BindingScope.SINGLETON),this.bind(c.CoreBindings.APPLICATION_INSTANCE).to(this),this.bind(c.CoreBindings.APPLICATION_CONFIG).to(this.options),this.configure(c.CoreBindings.APPLICATION_INSTANCE).toAlias(c.CoreBindings.APPLICATION_CONFIG),this._shutdownOptions={signals:["SIGTERM"],...this.options.shutdown}}get state(){return this._state}controller(t,e){this.debug("Adding controller %s",null!=e?e:t.name);const n=o.createBindingFromClass(t,{namespace:c.CoreBindings.CONTROLLERS,type:c.CoreTags.CONTROLLER,defaultScope:o.BindingScope.TRANSIENT,...v(e)});return this.add(n),n}server(t,e){this.debug("Adding server %s",null!=e?e:t.name);const n=o.createBindingFromClass(t,{namespace:c.CoreBindings.SERVERS,type:c.CoreTags.SERVER,defaultScope:o.BindingScope.SINGLETON,...v(e)}).apply(l.asLifeCycleObserver);return this.add(n),n}servers(t){return t.map((t=>this.server(t)))}async getServer(t){let e;if("string"==typeof t)e=`${c.CoreBindings.SERVERS}.${t}`;else{const n=t;e=`${c.CoreBindings.SERVERS}.${n.name}`}return this.get(e)}assertNotInProcess(t){i.default(!this._state.endsWith("ing"),`Cannot ${t} the application as it is ${this._state}.`)}assertInStates(t,...e){i.default(e.includes(this._state),`Cannot ${t} the application as it is ${this._state}. Valid states are ${e}.`)}setState(t){const e=this._state;this._state=t,e!==t&&(this.emit("stateChanged",{from:e,to:this._state}),this.emit(t))}async awaitState(t){await a.once(this,t)}async init(){if(this._initialized)return;if("initializing"===this._state)return this.awaitState("initialized");this.assertNotInProcess("initialize"),this.setState("initializing");const t=await this.getLifeCycleObserverRegistry();await t.init(),this._initialized=!0,this.setState("initialized")}onInit(t){const e=[c.CoreBindings.LIFE_CYCLE_OBSERVERS,t.name||"<onInit>",o.generateUniqueId()].join(".");return this.bind(e).to({init:t}).apply(l.asLifeCycleObserver)}async start(){if(this._initialized||await this.init(),"starting"===this._state)return this.awaitState("started");if(this.assertNotInProcess("start"),"started"===this._state)return;this.setState("starting"),this.setupShutdown();const t=await this.getLifeCycleObserverRegistry();await t.start(),this.setState("started")}onStart(t){const e=[c.CoreBindings.LIFE_CYCLE_OBSERVERS,t.name||"<onStart>",o.generateUniqueId()].join(".");return this.bind(e).to({start:t}).apply(l.asLifeCycleObserver)}async stop(){if("stopping"===this._state)return this.awaitState("stopped");if(this.assertNotInProcess("stop"),"started"!==this._state)return;this.setState("stopping"),this._isShuttingDown||this.removeSignalListener();const t=await this.getLifeCycleObserverRegistry();await t.stop(),this.setState("stopped")}onStop(t){const e=[c.CoreBindings.LIFE_CYCLE_OBSERVERS,t.name||"<onStop>",o.generateUniqueId()].join(".");return this.bind(e).to({stop:t}).apply(l.asLifeCycleObserver)}async getLifeCycleObserverRegistry(){return this.get(c.CoreBindings.LIFE_CYCLE_OBSERVER_REGISTRY)}component(t,e){this.debug("Adding component: %s",null!=e?e:t.name);const n=o.createBindingFromClass(t,{namespace:c.CoreBindings.COMPONENTS,type:c.CoreTags.COMPONENT,defaultScope:o.BindingScope.SINGLETON,...v(e)});l.isLifeCycleObserverClass(t)&&n.apply(l.asLifeCycleObserver),this.add(n);const r=this.getSync(n.key);return u.mountComponent(this,r),n}setMetadata(t){this.bind(c.CoreBindings.APPLICATION_METADATA).to(t)}lifeCycleObserver(t,e){this.debug("Adding life cycle observer %s",null!=e?e:t.name);const n=o.createBindingFromClass(t,{namespace:c.CoreBindings.LIFE_CYCLE_OBSERVERS,type:c.CoreTags.LIFE_CYCLE_OBSERVER,defaultScope:o.BindingScope.SINGLETON,...v(e)}).apply(l.asLifeCycleObserver);return this.add(n),n}service(t,e){const n=v(e),r=p.createServiceBinding(t,n);return this.add(r),r}interceptor(t,e){const n=v(e);return o.registerInterceptor(this,t,n)}setupShutdown(){if(null!=this._signalListener)return this.registerSignalListener(),this._signalListener;const t=this._shutdownOptions.gracePeriod;return this._signalListener=async e=>{const n=()=>{this.removeSignalListener(),process.kill(process.pid,e)};if(h("[%s] Signal %s received for process %d",this.name,e,process.pid),!this._isShuttingDown){let e;this._isShuttingDown=!0,"number"!=typeof t||isNaN(t)||(e=setTimeout(n,t));try{await this.stop()}finally{null!=e&&clearTimeout(e),n()}}},this.registerSignalListener(),this._signalListener}registerSignalListener(){const{signals:t=[]}=this._shutdownOptions;h("[%s] Registering signal listeners on the process %d",this.name,process.pid,t),t.forEach((t=>{process.getMaxListeners()<=process.listenerCount(t)&&g.enabled&&g("[%s] %d %s listeners are added to process %d",this.name,process.listenerCount(t),t,process.pid,new Error("MaxListenersExceededWarning")),process.on(t,this._signalListener)}))}removeSignalListener(){if(null==this._signalListener)return;const{signals:t=[]}=this._shutdownOptions;h("[%s] Removing signal listeners on the process %d",this.name,process.pid,t),t.forEach((t=>process.removeListener(t,this._signalListener)))}}function v(t){return"string"==typeof t?{name:t}:null!=t?t:{}}e.Application=y},123:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.mountComponent=void 0;const r=n(1170);e.mountComponent=function(t,e){if(e.classes)for(const n in e.classes){const o=r.createBindingFromClass(e.classes[n],{key:n});t.add(o)}if(e.providers)for(const n in e.providers){const o=r.createBindingFromClass(e.providers[n],{key:n});t.add(o)}if(e.bindings)for(const n of e.bindings)t.add(n);if(e.controllers)for(const n of e.controllers)t.controller(n);if(e.servers)for(const n in e.servers)t.server(e.servers[n],n);if(e.lifeCycleObservers)for(const n of e.lifeCycleObservers)t.lifeCycleObserver(n);if(e.services)for(const n of e.services)t.service(n)}},2330:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.addExtension=e.extensionFor=e.extensionFilter=e.extensions=e.extensionPoint=void 0;const r=n(1170),o=n(3669);function i(t){return r.inject("",{decorator:"@extensions"},((e,n,o)=>{r.assertTargetType(n,Function,"Getter function");const i=s(n,o,t);return r.createViewGetter(e,i,n.metadata.bindingComparator,o)}))}function s(t,e,n){return a(n=null!=n?n:function(t,e){if(e){const t=e.tagMap[o.CoreTags.EXTENSION_POINT]||e.tagMap[r.ContextTags.NAME];if(t)return t}let n;return n="function"==typeof t?t:t.constructor,n.name}(t.target,e.currentBinding))}function a(...t){return r.filterByTag({[o.CoreTags.EXTENSION_FOR]:r.includesTagValue(...t)})}function u(...t){return e=>{if(0===t.length)return;let n=e.tagMap[o.CoreTags.EXTENSION_FOR];null==n?n=[]:"string"==typeof n&&(n=[n]);for(const e of t)n.includes(e)||n.push(e);1===n.length&&(n=n[0]),e.tag({[o.CoreTags.EXTENSION_FOR]:n})}}e.extensionPoint=function(t,...e){return r.injectable({tags:{[o.CoreTags.EXTENSION_POINT]:t}},...e)},e.extensions=i,function(t){t.view=function(t){return r.inject("",{decorator:"@extensions.view"},((e,n,o)=>{r.assertTargetType(n,r.ContextView);const i=s(n,o,t);return e.createView(i,n.metadata.bindingComparator)}))},t.list=function(t){return r.inject("",{decorator:"@extensions.instances"},((e,n,o)=>{r.assertTargetType(n,Array);const i=s(n,o,t);return new r.ContextView(e,i,n.metadata.bindingComparator).resolve(o)}))}}(i=e.extensions||(e.extensions={})),e.extensionFilter=a,e.extensionFor=u,e.addExtension=function(t,e,n,o){const i=r.createBindingFromClass(n,o).apply(u(e));return t.add(i),i}},5292:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const r=n(437);r.__exportStar(n(1170),e),r.__exportStar(n(7316),e),r.__exportStar(n(123),e),r.__exportStar(n(2330),e),r.__exportStar(n(3669),e),r.__exportStar(n(5098),e),r.__exportStar(n(3987),e),r.__exportStar(n(6577),e),r.__exportStar(n(8395),e),r.__exportStar(n(8200),e)},3669:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CoreTags=e.CoreBindings=void 0;const r=n(1170);var o,i;(i=e.CoreBindings||(e.CoreBindings={})).APPLICATION_INSTANCE=r.BindingKey.create("application.instance"),i.APPLICATION_CONFIG=r.BindingKey.create("application.config"),i.APPLICATION_METADATA=r.BindingKey.create("application.metadata"),i.SERVERS="servers",i.COMPONENTS="components",i.CONTROLLERS="controllers",i.CONTROLLER_CLASS=r.BindingKey.create("controller.current.ctor"),i.CONTROLLER_METHOD_NAME=r.BindingKey.create("controller.current.operation"),i.CONTROLLER_METHOD_META="controller.method.meta",i.CONTROLLER_CURRENT=r.BindingKey.create("controller.current"),i.LIFE_CYCLE_OBSERVERS="lifeCycleObservers",i.LIFE_CYCLE_OBSERVER_REGISTRY=r.BindingKey.create("lifeCycleObserver.registry"),i.LIFE_CYCLE_OBSERVER_OPTIONS=r.BindingKey.create("lifeCycleObserver.options"),(o=e.CoreTags||(e.CoreTags={})).COMPONENT="component",o.SERVER="server",o.CONTROLLER="controller",o.SERVICE="service",o.SERVICE_INTERFACE="serviceInterface",o.LIFE_CYCLE_OBSERVER="lifeCycleObserver",o.LIFE_CYCLE_OBSERVER_GROUP="lifeCycleObserverGroup",o.EXTENSION_FOR="extensionFor",o.EXTENSION_POINT="extensionPoint"},3987:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.LifeCycleObserverRegistry=e.DEFAULT_ORDERED_GROUPS=void 0;const r=n(437),o=n(1170),i=n(3669),s=n(5098),a=n(9708)("loopback:core:lifecycle");e.DEFAULT_ORDERED_GROUPS=["server"];let u=class{constructor(t,n,r={parallel:!0,orderedGroups:e.DEFAULT_ORDERED_GROUPS}){this.context=t,this.observersView=n,this.options=r}setOrderedGroups(t){this.options.orderedGroups=t}getObserverGroupsByOrder(){const t=this.observersView.bindings,e=this.sortObserverBindingsByGroup(t);return a.enabled&&a("Observer groups: %j",e.map((t=>({group:t.group,bindings:t.bindings.map((t=>t.key))})))),e}getObserverGroup(t){let e=t.tagMap[i.CoreTags.LIFE_CYCLE_OBSERVER_GROUP];return e||(e=this.options.orderedGroups.find((e=>t.tagMap[e]===e))),e=e||"",a("Binding %s is configured with observer group %s",t.key,e),e}sortObserverBindingsByGroup(t){const e=new Map;o.sortBindingsByPhase(t,i.CoreTags.LIFE_CYCLE_OBSERVER_GROUP,this.options.orderedGroups);for(const n of t){const t=this.getObserverGroup(n);let r=e.get(t);null==r&&(r=[],e.set(t,r)),r.push(n)}const n=[];for(const[t,r]of e)n.push({group:t,bindings:r});return n}async notifyObservers(t,e,n){if(!this.options.parallel){let r=0;for(const o of t)a("Invoking %s observer for binding %s",n,e[r].key),r++,await this.invokeObserver(o,n);return}const r=t.map(((t,r)=>(a("Invoking %s observer for binding %s",n,e[r].key),this.invokeObserver(t,n))));await Promise.all(r)}async invokeObserver(t,e){"function"==typeof t[e]&&await o.invokeMethod(t,e,this.context,[void 0],{skipInterceptors:!0})}async notifyGroups(t,e,n=!1){var r;const o=await this.observersView.values(),i=this.observersView.bindings;if(o.some((e=>t.some((t=>"function"==typeof e[t]))))){n&&(e=[...e].reverse());for(const s of e){if(null===(r=this.options.disabledGroups)||void 0===r?void 0:r.includes(s.group)){a("Notification skipped (Group is disabled): %s",s.group);continue}const e=[],u=n?s.bindings.reverse():s.bindings;for(const t of u){const n=i.indexOf(t);e.push(o[n])}for(const n of t)a("Beginning notification %s of %s...",n),await this.notifyObservers(e,s.bindings,n),a("Finished notification %s of %s",n)}}}async init(){a("Initializing the %s...");const t=this.getObserverGroupsByOrder();await this.notifyGroups(["init"],t)}async start(){a("Starting the %s...");const t=this.getObserverGroupsByOrder();await this.notifyGroups(["start"],t)}async stop(){a("Stopping the %s...");const t=this.getObserverGroupsByOrder();await this.notifyGroups(["stop"],t,!0)}};u=r.__decorate([r.__param(0,o.inject.context()),r.__param(1,o.inject.view(s.lifeCycleObserverFilter)),r.__param(2,o.inject(i.CoreBindings.LIFE_CYCLE_OBSERVER_OPTIONS,{optional:!0})),r.__metadata("design:paramtypes",[o.Context,o.ContextView,Object])],u),e.LifeCycleObserverRegistry=u},5098:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.lifeCycleObserver=e.lifeCycleObserverFilter=e.asLifeCycleObserver=e.isLifeCycleObserverClass=e.isLifeCycleObserver=void 0;const r=n(1170),o=n(3669),i=["init","start","stop"];function s(t){const e=t;return i.some((t=>"function"==typeof e[t]))}function a(t){return t.tag(o.CoreTags.LIFE_CYCLE_OBSERVER)}e.isLifeCycleObserver=s,e.isLifeCycleObserverClass=function(t){return t.prototype&&s(t.prototype)},e.asLifeCycleObserver=a,e.lifeCycleObserverFilter=r.filterByTag(o.CoreTags.LIFE_CYCLE_OBSERVER),e.lifeCycleObserver=function(t="",...e){return r.injectable(a,{tags:{[o.CoreTags.LIFE_CYCLE_OBSERVER_GROUP]:t}},...e)}},6577:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},8395:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},8200:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.asService=e.createServiceBinding=e.filterByServiceInterface=e.service=void 0;const r=n(1170),o=n(3669);function i(t){return e=>e.valueConstructor===t||e.tagMap[o.CoreTags.SERVICE_INTERFACE]===t}function s(t){return function(e){e.tag({[r.ContextTags.TYPE]:o.CoreTags.SERVICE,[o.CoreTags.SERVICE_INTERFACE]:t})}}e.service=function(t,e){return r.inject("",{decorator:"@service",...e},((n,o,s)=>{var a;let u=t;if(u||(u="number"==typeof o.methodDescriptorOrParameterIndex?null===(a=r.MetadataInspector.getDesignTypeForMethod(o.target,o.member))||void 0===a?void 0:a.parameterTypes[o.methodDescriptorOrParameterIndex]:r.MetadataInspector.getDesignTypeForProperty(o.target,o.member)),void 0===u){const t=r.DecoratorFactory.getTargetName(o.target,o.member,o.methodDescriptorOrParameterIndex);throw new Error(`No design-time type metadata found while inspecting ${t}. You can either use \`@service(ServiceClass)\` or ensure \`emitDecoratorMetadata\` is enabled in your TypeScript configuration. Run \`tsc --showConfig\` to print the final TypeScript configuration of your project.`)}if(u===Object||u===Array)throw new Error("Service class cannot be inferred from design type. Use @service(ServiceClass).");const c=new r.ContextView(n,i(u)).resolve(s),l="string"==typeof u?u:"symbol"==typeof u?u.toString():u.name;return r.transformValueOrPromise(c,(t=>{if(1===t.length)return t[0];if(t.length>=1)throw new Error(`More than one bindings found for ${l}`);if(!(null==e?void 0:e.optional))throw new Error(`No binding found for ${l}. Make sure a service binding is created in context ${n.name} with serviceInterface (${l}).`)}))}))},e.filterByServiceInterface=i,e.createServiceBinding=function(t,e={}){var n;let i=e.name;if(!i&&r.isProviderClass(t)){const e=r.bindingTemplateFor(t),n=r.Binding.bind("template").apply(e);n.tagMap[r.ContextTags.PROVIDER]&&!n.tagMap[r.ContextTags.NAME]&&(i=t.name.replace(/Provider$/,""))}if(!i&&r.isDynamicValueProviderClass(t)){const e=r.bindingTemplateFor(t),n=r.Binding.bind("template").apply(e);n.tagMap[r.ContextTags.DYNAMIC_VALUE_PROVIDER]&&!n.tagMap[r.ContextTags.NAME]&&(i=t.name.replace(/Provider$/,""))}return r.createBindingFromClass(t,{name:i,type:o.CoreTags.SERVICE,...e}).apply(s(null!==(n=e.interface)&&void 0!==n?n:t))},e.asService=s},1841:(t,e,n)=>{e.formatArgs=function(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+t.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;e.splice(1,0,n,"color: inherit");let r=0,o=0;e[0].replace(/%[a-zA-Z%]/g,(t=>{"%%"!==t&&(r++,"%c"===t&&(o=r))})),e.splice(o,0,n)},e.save=function(t){try{t?e.storage.setItem("debug",t):e.storage.removeItem("debug")}catch(t){}},e.load=function(){let t;try{t=e.storage.getItem("debug")}catch(t){}return!t&&"undefined"!=typeof process&&"env"in process&&(t=process.env.DEBUG),t},e.useColors=function(){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+)/))},e.storage=function(){try{return localStorage}catch(t){}}(),e.destroy=(()=>{let t=!1;return()=>{t||(t=!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`."))}})(),e.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"],e.log=console.debug||console.log||(()=>{}),t.exports=n(1689)(e);const{formatters:r}=t.exports;r.j=function(t){try{return JSON.stringify(t)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}}},1689:(t,e,n)=>{t.exports=function(t){function e(t){let n,o,i,s=null;function a(...t){if(!a.enabled)return;const r=a,o=Number(new Date),i=o-(n||o);r.diff=i,r.prev=n,r.curr=o,n=o,t[0]=e.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");let s=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return"%";s++;const i=e.formatters[o];if("function"==typeof i){const e=t[s];n=i.call(r,e),t.splice(s,1),s--}return n})),e.formatArgs.call(r,t),(r.log||e.log).apply(r,t)}return a.namespace=t,a.useColors=e.useColors(),a.color=e.selectColor(t),a.extend=r,a.destroy=e.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(o!==e.namespaces&&(o=e.namespaces,i=e.enabled(t)),i),set:t=>{s=t}}),"function"==typeof e.init&&e.init(a),a}function r(t,n){const r=e(this.namespace+(void 0===n?":":n)+t);return r.log=this.log,r}function o(t){return t.toString().substring(2,t.toString().length-2).replace(/\.\*\?$/,"*")}return e.debug=e,e.default=e,e.coerce=function(t){return t instanceof Error?t.stack||t.message:t},e.disable=function(){const t=[...e.names.map(o),...e.skips.map(o).map((t=>"-"+t))].join(",");return e.enable(""),t},e.enable=function(t){let n;e.save(t),e.namespaces=t,e.names=[],e.skips=[];const r=("string"==typeof t?t:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(t=r[n].replace(/\*/g,".*?"))[0]?e.skips.push(new RegExp("^"+t.substr(1)+"$")):e.names.push(new RegExp("^"+t+"$")))},e.enabled=function(t){if("*"===t[t.length-1])return!0;let n,r;for(n=0,r=e.skips.length;n<r;n++)if(e.skips[n].test(t))return!1;for(n=0,r=e.names.length;n<r;n++)if(e.names[n].test(t))return!0;return!1},e.humanize=n(5432),e.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(t).forEach((n=>{e[n]=t[n]})),e.names=[],e.skips=[],e.formatters={},e.selectColor=function(t){let n=0;for(let e=0;e<t.length;e++)n=(n<<5)-n+t.charCodeAt(e),n|=0;return e.colors[Math.abs(n)%e.colors.length]},e.enable(e.load()),e}},9708:(t,e,n)=>{"undefined"==typeof process||"renderer"===process.type||!0===process.browser||process.__nwjs?t.exports=n(1841):t.exports=n(7258)},7258:(t,e,n)=>{const r=n(6224),o=n(3837);e.init=function(t){t.inspectOpts={};const n=Object.keys(e.inspectOpts);for(let r=0;r<n.length;r++)t.inspectOpts[n[r]]=e.inspectOpts[n[r]]},e.log=function(...t){return process.stderr.write(o.format(...t)+"\n")},e.formatArgs=function(n){const{namespace:r,useColors:o}=this;if(o){const e=this.color,o="[3"+(e<8?e:"8;5;"+e),i=` ${o};1m${r} `;n[0]=i+n[0].split("\n").join("\n"+i),n.push(o+"m+"+t.exports.humanize(this.diff)+"")}else n[0]=(e.inspectOpts.hideDate?"":(new Date).toISOString()+" ")+r+" "+n[0]},e.save=function(t){t?process.env.DEBUG=t:delete process.env.DEBUG},e.load=function(){return process.env.DEBUG},e.useColors=function(){return"colors"in e.inspectOpts?Boolean(e.inspectOpts.colors):r.isatty(process.stderr.fd)},e.destroy=o.deprecate((()=>{}),"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."),e.colors=[6,2,3,4,5,1];try{const t=n(7013);t&&(t.stderr||t).level>=2&&(e.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(t){}e.inspectOpts=Object.keys(process.env).filter((t=>/^debug_/i.test(t))).reduce(((t,e)=>{const n=e.substring(6).toLowerCase().replace(/_([a-z])/g,((t,e)=>e.toUpperCase()));let r=process.env[e];return r=!!/^(yes|on|true|enabled)$/i.test(r)||!/^(no|off|false|disabled)$/i.test(r)&&("null"===r?null:Number(r)),t[n]=r,t}),{}),t.exports=n(1689)(e);const{formatters:i}=t.exports;i.o=function(t){return this.inspectOpts.colors=this.useColors,o.inspect(t,this.inspectOpts).split("\n").map((t=>t.trim())).join(" ")},i.O=function(t){return this.inspectOpts.colors=this.useColors,o.inspect(t,this.inspectOpts)}},5432:t=>{var e=1e3,n=60*e,r=60*n,o=24*r;function i(t,e,n,r){var o=e>=1.5*n;return Math.round(t/n)+" "+r+(o?"s":"")}t.exports=function(t,s){s=s||{};var a,u,c=typeof t;if("string"===c&&t.length>0)return function(t){if(!((t=String(t)).length>100)){var i=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(i){var s=parseFloat(i[1]);switch((i[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"weeks":case"week":case"w":return 6048e5*s;case"days":case"day":case"d":return s*o;case"hours":case"hour":case"hrs":case"hr":case"h":return s*r;case"minutes":case"minute":case"mins":case"min":case"m":return s*n;case"seconds":case"second":case"secs":case"sec":case"s":return s*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}}(t);if("number"===c&&isFinite(t))return s.long?(a=t,(u=Math.abs(a))>=o?i(a,u,o,"day"):u>=r?i(a,u,r,"hour"):u>=n?i(a,u,n,"minute"):u>=e?i(a,u,e,"second"):a+" ms"):function(t){var i=Math.abs(t);return i>=o?Math.round(t/o)+"d":i>=r?Math.round(t/r)+"h":i>=n?Math.round(t/n)+"m":i>=e?Math.round(t/e)+"s":t+"ms"}(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))}},437:(t,e,n)=>{"use strict";n.r(e),n.d(e,{__extends:()=>o,__assign:()=>i,__rest:()=>s,__decorate:()=>a,__param:()=>u,__metadata:()=>c,__awaiter:()=>l,__generator:()=>f,__createBinding:()=>p,__exportStar:()=>d,__values:()=>h,__read:()=>g,__spread:()=>y,__spreadArrays:()=>v,__spreadArray:()=>_,__await:()=>m,__asyncGenerator:()=>b,__asyncDelegator:()=>w,__asyncValues:()=>C,__makeTemplateObject:()=>O,__importStar:()=>x,__importDefault:()=>S,__classPrivateFieldGet:()=>I,__classPrivateFieldSet:()=>T});var r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var i=function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};function s(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]])}return n}function a(t,e,n,r){var o,i=arguments.length,s=i<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(i<3?o(s):i>3?o(e,n,s):o(e,n))||s);return i>3&&s&&Object.defineProperty(e,n,s),s}function u(t,e){return function(n,r){e(n,r,t)}}function c(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function l(t,e,n,r){return new(n||(n=Promise))((function(o,i){function s(t){try{u(r.next(t))}catch(t){i(t)}}function a(t){try{u(r.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(s,a)}u((r=r.apply(t,e||[])).next())}))}function f(t,e){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!((o=(o=s.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=e.call(t,s)}catch(t){i=[6,t],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}}var p=Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]};function d(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||p(e,t,n)}function h(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function g(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),s=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)s.push(r.value)}catch(t){o={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return s}function y(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(g(arguments[e]));return t}function v(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),o=0;for(e=0;e<n;e++)for(var i=arguments[e],s=0,a=i.length;s<a;s++,o++)r[o]=i[s];return r}function _(t,e,n){if(n||2===arguments.length)for(var r,o=0,i=e.length;o<i;o++)!r&&o in e||(r||(r=Array.prototype.slice.call(e,0,o)),r[o]=e[o]);return t.concat(r||Array.prototype.slice.call(e))}function m(t){return this instanceof m?(this.v=t,this):new m(t)}function b(t,e,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,o=n.apply(t,e||[]),i=[];return r={},s("next"),s("throw"),s("return"),r[Symbol.asyncIterator]=function(){return this},r;function s(t){o[t]&&(r[t]=function(e){return new Promise((function(n,r){i.push([t,e,n,r])>1||a(t,e)}))})}function a(t,e){try{(n=o[t](e)).value instanceof m?Promise.resolve(n.value.v).then(u,c):l(i[0][2],n)}catch(t){l(i[0][3],t)}var n}function u(t){a("next",t)}function c(t){a("throw",t)}function l(t,e){t(e),i.shift(),i.length&&a(i[0][0],i[0][1])}}function w(t){var e,n;return e={},r("next"),r("throw",(function(t){throw t})),r("return"),e[Symbol.iterator]=function(){return this},e;function r(r,o){e[r]=t[r]?function(e){return(n=!n)?{value:m(t[r](e)),done:"return"===r}:o?o(e):e}:o}}function C(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=h(t),e={},r("next"),r("throw"),r("return"),e[Symbol.asyncIterator]=function(){return this},e);function r(n){e[n]=t[n]&&function(e){return new Promise((function(r,o){!function(t,e,n,r){Promise.resolve(r).then((function(e){t({value:e,done:n})}),e)}(r,o,(e=t[n](e)).done,e.value)}))}}}function O(t,e){return Object.defineProperty?Object.defineProperty(t,"raw",{value:e}):t.raw=e,t}var E=Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e};function x(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&p(e,t,n);return E(e,t),e}function S(t){return t&&t.__esModule?t:{default:t}}function I(t,e,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!r:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(t):r?r.value:e.get(t)}function T(t,e,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!o:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(t,n):o?o.value=n:e.set(t,n),n}},650:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.MethodMultiDecoratorFactory=e.MethodParameterDecoratorFactory=e.ParameterDecoratorFactory=e.MethodDecoratorFactory=e.PropertyDecoratorFactory=e.ClassDecoratorFactory=e.DecoratorFactory=void 0;const r=n(2595),o=r.__importDefault(n(3301)),i=r.__importDefault(n(5245)),s=n(2737),a=o.default("loopback:metadata:decorator");class u{constructor(t,e,n={}){var r;this.key=t,this.spec=e,this.options=n,this.options=Object.assign({allowInheritance:!0,cloneInputSpec:!0},n);const o=this.constructor.name.replace(/Factory$/,"");this.decoratorName=null!==(r=this.options.decoratorName)&&void 0!==r?r:o,this.options.cloneInputSpec&&(this.spec=u.cloneDeep(e))}allowInheritance(){var t;return!!(null===(t=this.options)||void 0===t?void 0:t.allowInheritance)}inherit(t){return this.allowInheritance()?null==t?this.spec:null==this.spec?t:"object"!=typeof t||Array.isArray(t)||Array.isArray(this.spec)?this.spec:Object.assign(t,this.spec):this.spec}static getTargetName(t,e,n){let r=t instanceof Function?t.name:`${t.constructor.name}.prototype`;if(null==e&&null==n)return`class ${r}`;null!=e&&""!==e||(e="constructor");const o="symbol"==typeof e?"["+e.toString()+"]":"."+e;return r="number"==typeof n?`${r}${o}[${n}]`:null!=n?`${r}${o}()`:`${r}${o}`,r}static getNumberOfParameters(t,e){return"function"!=typeof t||e?t[e].length:t.length}withTarget(t,e){return"object"==typeof t&&null!=t&&Object.defineProperty(t,u.TARGET,{value:e,enumerable:!1,configurable:!1}),t}getTarget(t){if("object"==typeof t&&null!=t)return t[u.TARGET]}mergeWithInherited(t,e,n,r){throw new Error(`mergeWithInherited() is not implemented for ${this.decoratorName}`)}mergeWithOwn(t,e,n,r){throw new Error(`mergeWithOwn() is not implemented for ${this.decoratorName}`)}duplicateDecorationError(t,e,n){const r=u.getTargetName(t,e,n);return new Error(`${this.decoratorName} cannot be applied more than once on ${r}`)}create(){throw new Error(`create() is not implemented for ${this.decoratorName}`)}decorate(t,e,n){const r=u.getTargetName(t,e,n);let o=s.Reflector.getOwnMetadata(this.key,t);null==o&&this.allowInheritance()?(o=u.cloneDeep(s.Reflector.getMetadata(this.key,t)),o=this.mergeWithInherited(o,t,e,n),a.enabled&&a("%s: %j",r,o),s.Reflector.defineMetadata(this.key,o,t)):(o=this.mergeWithOwn(o,t,e,n),a.enabled&&a("%s: %j",r,o),s.Reflector.defineMetadata(this.key,o,t))}static _createDecorator(t,e,n){return new this(t.toString(),e,n).create()}static cloneDeep(t){return"object"!=typeof t?t:i.default.cloneDeepWith(t,(t=>"object"!=typeof t||null==t?t:null==t.constructor||u._cloneableTypes.includes(t.constructor)?void 0:t))}}e.DecoratorFactory=u,u.TARGET="__decoratorTarget",u._cloneableTypes=[Object,Array,Set,Map,RegExp,Date,Buffer,ArrayBuffer,Float32Array,Float64Array,Int8Array,Int16Array,Int32Array,Uint8Array,Uint8ClampedArray,Uint16Array,Uint32Array],e.ClassDecoratorFactory=class extends u{mergeWithInherited(t,e,n,r){return this.withTarget(this.inherit(t),e)}mergeWithOwn(t,e,n,r){if(null!=t)throw this.duplicateDecorationError(e,n,r);return this.withTarget(this.spec,e)}create(){return t=>this.decorate(t)}static createDecorator(t,e,n){return super._createDecorator(t,e,n)}},e.PropertyDecoratorFactory=class extends u{mergeWithInherited(t,e,n,r){t=t||{};const o=this.withTarget(this.inherit(t[n]),e);return t[n]=o,t}mergeWithOwn(t,e,n,r){if(null!=(t=t||{})[n])throw this.duplicateDecorationError(e,n,r);return t[n]=this.withTarget(this.spec,e),t}create(){return(t,e)=>this.decorate(t,e)}static createDecorator(t,e,n){return super._createDecorator(t,e,n)}};class c extends u{mergeWithInherited(t,e,n,r){t=t||{};const o=this.withTarget(this.inherit(t[n]),e);return t[n]=o,t}mergeWithOwn(t,e,n,r){const o=(t=t||{})[n];if(this.getTarget(o)===e)throw this.duplicateDecorationError(e,n,r);return t[n]=this.withTarget(this.spec,e),t}create(){return(t,e,n)=>this.decorate(t,e,n)}static createDecorator(t,e,n){return super._createDecorator(t,e,n)}}e.MethodDecoratorFactory=c,e.ParameterDecoratorFactory=class extends u{getOrInitMetadata(t,e,n){const r=n||"";let o=t[r];return null==o&&(o=new Array(u.getNumberOfParameters(e,n)).fill(void 0),t[r]=o),o}mergeWithInherited(t,e,n,r){t=t||{};const o=this.getOrInitMetadata(t,e,n),i=r;return o[i]=this.withTarget(this.inherit(o[i]),e),t}mergeWithOwn(t,e,n,r){t=t||{};const o=this.getOrInitMetadata(t,e,n),i=r;if(this.getTarget(o[i])===e)throw this.duplicateDecorationError(e,n,r);return o[i]=this.withTarget(this.inherit(o[i]),e),t}create(){return(t,e,n)=>this.decorate(t,e,n)}static createDecorator(t,e,n){return super._createDecorator(t,e,n)}},e.MethodParameterDecoratorFactory=class extends u{getParameterIndex(t,e,n){const r=u.getNumberOfParameters(t,e);let o=s.Reflector.getOwnMetadata(`${this.key}:index`,t,e);if(null==o&&(o=r-1),o<0){const o=u.getTargetName(t,e,n);throw new Error(`${this.decoratorName} is used more than ${r} time(s) on ${o}`)}return o}mergeWithInherited(t,e,n,r){t=t||{};const o=this.getParameterIndex(e,n,r),i=t[n]||new Array(o+1).fill(void 0);return i.length&&(i[o]=this.withTarget(this.inherit(i[o]),e)),s.Reflector.defineMetadata(`${this.key}:index`,o-1,e,n),t[n]=i,t}mergeWithOwn(t,e,n,r){t=t||{};const o=this.getParameterIndex(e,n,r),i=t[n]||new Array(o+1).fill(void 0);return i[o]=this.withTarget(this.inherit(i[o]),e),t[n]=i,s.Reflector.defineMetadata(`${this.key}:index`,o-1,e,n),t}create(){return(t,e,n)=>this.decorate(t,e,n)}static createDecorator(t,e,n){return super._createDecorator(t,e,n)}},e.MethodMultiDecoratorFactory=class extends c{mergeWithInherited(t,e,n){return(t=t||{})[n]=this._mergeArray(t[n],this.withTarget(this.spec,e)),t}mergeWithOwn(t,e,n,r){return(t=t||{})[n]=this._mergeArray(t[n],this.withTarget(this.spec,e)),t}_mergeArray(t,e){return t?Array.isArray(e)?t.push(...e):t.push(e):t=Array.isArray(e)?e:[e],t}}},3481:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const r=n(2595);r.__exportStar(n(650),e),r.__exportStar(n(8484),e),r.__exportStar(n(2737),e),r.__exportStar(n(1430),e)},8484:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.MetadataInspector=void 0;const r=n(2595).__importDefault(n(3301)),o=n(650),i=n(2737),s=r.default("loopback:metadata:inspector"),a=new i.NamespacedReflect;class u{static getClassMetadata(t,e,n){return(null==n?void 0:n.ownMetadataOnly)?i.Reflector.getOwnMetadata(t.toString(),e):i.Reflector.getMetadata(t.toString(),e)}static defineMetadata(t,e,n,r){i.Reflector.defineMetadata(t.toString(),e,n,r)}static getAllMethodMetadata(t,e,n){return(null==n?void 0:n.ownMetadataOnly)?i.Reflector.getOwnMetadata(t.toString(),e):i.Reflector.getMetadata(t.toString(),e)}static getMethodMetadata(t,e,n,r){n=null!=n?n:"";const o=(null==r?void 0:r.ownMetadataOnly)?i.Reflector.getOwnMetadata(t.toString(),e):i.Reflector.getMetadata(t.toString(),e);return null==o?void 0:o[n]}static getAllPropertyMetadata(t,e,n){return(null==n?void 0:n.ownMetadataOnly)?i.Reflector.getOwnMetadata(t.toString(),e):i.Reflector.getMetadata(t.toString(),e)}static getPropertyMetadata(t,e,n,r){const o=(null==r?void 0:r.ownMetadataOnly)?i.Reflector.getOwnMetadata(t.toString(),e):i.Reflector.getMetadata(t.toString(),e);return null==o?void 0:o[n]}static getAllParameterMetadata(t,e,n,r){n=null!=n?n:"";const o=(null==r?void 0:r.ownMetadataOnly)?i.Reflector.getOwnMetadata(t.toString(),e):i.Reflector.getMetadata(t.toString(),e);return null==o?void 0:o[n]}static getParameterMetadata(t,e,n,r,o){n=n||"";const s=(null==o?void 0:o.ownMetadataOnly)?i.Reflector.getOwnMetadata(t.toString(),e):i.Reflector.getMetadata(t.toString(),e),a=null==s?void 0:s[n];return null==a?void 0:a[r]}static getDesignTypeForProperty(t,e){return a.getMetadata("design:type",t,e)}static getDesignTypeForMethod(t,e){const n=a.getMetadata("design:type",t,e),r=a.getMetadata("design:paramtypes",t,e),i=a.getMetadata("design:returntype",t,e);if(void 0!==n||void 0!==r||void 0!==i)return{type:n,parameterTypes:r,returnType:i};if(s.enabled){const n=o.DecoratorFactory.getTargetName(t,e);s("No design-time type metadata found while inspecting %s. Did you forget to enable TypeScript compiler option `emitDecoratorMetadata`?",n)}}}e.MetadataInspector=u,u.Reflector=i.Reflector,u.DesignTimeReflector=a},2737:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Reflector=e.NamespacedReflect=void 0,n(9248);class r{constructor(t){this.namespace=t}getMetadataKey(t){return this.namespace?this.namespace+":"+t:t}defineMetadata(t,e,n,r){t=this.getMetadataKey(t),r?Reflect.defineMetadata(t,e,n,r):Reflect.defineMetadata(t,e,n)}getMetadata(t,e,n){return t=this.getMetadataKey(t),n?Reflect.getMetadata(t,e,n):Reflect.getMetadata(t,e)}getOwnMetadata(t,e,n){return t=this.getMetadataKey(t),n?Reflect.getOwnMetadata(t,e,n):Reflect.getOwnMetadata(t,e)}hasMetadata(t,e,n){return t=this.getMetadataKey(t),n?Reflect.hasMetadata(t,e,n):Reflect.hasMetadata(t,e)}hasOwnMetadata(t,e,n){return t=this.getMetadataKey(t),n?Reflect.hasOwnMetadata(t,e,n):Reflect.hasOwnMetadata(t,e)}deleteMetadata(t,e,n){return t=this.getMetadataKey(t),n?Reflect.deleteMetadata(t,e,n):Reflect.deleteMetadata(t,e)}getMetadataKeys(t,e){let n;n=e?Reflect.getMetadataKeys(t,e):Reflect.getMetadataKeys(t);const r=[];if(n){if(!this.namespace)return n;const t=this.namespace+":";for(const e of n)0===e.indexOf(t)&&r.push(e.substr(t.length))}return r}getOwnMetadataKeys(t,e){let n;n=e?Reflect.getOwnMetadataKeys(t,e):Reflect.getOwnMetadataKeys(t);const r=[];if(n){if(!this.namespace)return n;const t=this.namespace+":";for(const e of n)0===e.indexOf(t)&&r.push(e.substr(t.length))}return r}decorate(t,e,n,r){return n?Reflect.decorate(t,e,n,r):Reflect.decorate(t,e)}metadata(t,e){return t=this.getMetadataKey(t),Reflect.metadata(t,e)}}e.NamespacedReflect=r,e.Reflector=new r("loopback")},1430:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.MetadataAccessor=void 0;class n{constructor(t){this.key=t}toString(){return this.key}static create(t){return new n(t)}}e.MetadataAccessor=n},798:(t,e,n)=>{e.formatArgs=function(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+t.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;e.splice(1,0,n,"color: inherit");let r=0,o=0;e[0].replace(/%[a-zA-Z%]/g,(t=>{"%%"!==t&&(r++,"%c"===t&&(o=r))})),e.splice(o,0,n)},e.save=function(t){try{t?e.storage.setItem("debug",t):e.storage.removeItem("debug")}catch(t){}},e.load=function(){let t;try{t=e.storage.getItem("debug")}catch(t){}return!t&&"undefined"!=typeof process&&"env"in process&&(t=process.env.DEBUG),t},e.useColors=function(){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+)/))},e.storage=function(){try{return localStorage}catch(t){}}(),e.destroy=(()=>{let t=!1;return()=>{t||(t=!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`."))}})(),e.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"],e.log=console.debug||console.log||(()=>{}),t.exports=n(5555)(e);const{formatters:r}=t.exports;r.j=function(t){try{return JSON.stringify(t)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}}},5555:(t,e,n)=>{t.exports=function(t){function e(t){let n,o,i,s=null;function a(...t){if(!a.enabled)return;const r=a,o=Number(new Date),i=o-(n||o);r.diff=i,r.prev=n,r.curr=o,n=o,t[0]=e.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");let s=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return"%";s++;const i=e.formatters[o];if("function"==typeof i){const e=t[s];n=i.call(r,e),t.splice(s,1),s--}return n})),e.formatArgs.call(r,t),(r.log||e.log).apply(r,t)}return a.namespace=t,a.useColors=e.useColors(),a.color=e.selectColor(t),a.extend=r,a.destroy=e.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(o!==e.namespaces&&(o=e.namespaces,i=e.enabled(t)),i),set:t=>{s=t}}),"function"==typeof e.init&&e.init(a),a}function r(t,n){const r=e(this.namespace+(void 0===n?":":n)+t);return r.log=this.log,r}function o(t){return t.toString().substring(2,t.toString().length-2).replace(/\.\*\?$/,"*")}return e.debug=e,e.default=e,e.coerce=function(t){return t instanceof Error?t.stack||t.message:t},e.disable=function(){const t=[...e.names.map(o),...e.skips.map(o).map((t=>"-"+t))].join(",");return e.enable(""),t},e.enable=function(t){let n;e.save(t),e.namespaces=t,e.names=[],e.skips=[];const r=("string"==typeof t?t:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(t=r[n].replace(/\*/g,".*?"))[0]?e.skips.push(new RegExp("^"+t.substr(1)+"$")):e.names.push(new RegExp("^"+t+"$")))},e.enabled=function(t){if("*"===t[t.length-1])return!0;let n,r;for(n=0,r=e.skips.length;n<r;n++)if(e.skips[n].test(t))return!1;for(n=0,r=e.names.length;n<r;n++)if(e.names[n].test(t))return!0;return!1},e.humanize=n(5984),e.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(t).forEach((n=>{e[n]=t[n]})),e.names=[],e.skips=[],e.formatters={},e.selectColor=function(t){let n=0;for(let e=0;e<t.length;e++)n=(n<<5)-n+t.charCodeAt(e),n|=0;return e.colors[Math.abs(n)%e.colors.length]},e.enable(e.load()),e}},3301:(t,e,n)=>{"undefined"==typeof process||"renderer"===process.type||!0===process.browser||process.__nwjs?t.exports=n(798):t.exports=n(8587)},8587:(t,e,n)=>{const r=n(6224),o=n(3837);e.init=function(t){t.inspectOpts={};const n=Object.keys(e.inspectOpts);for(let r=0;r<n.length;r++)t.inspectOpts[n[r]]=e.inspectOpts[n[r]]},e.log=function(...t){return process.stderr.write(o.format(...t)+"\n")},e.formatArgs=function(n){const{namespace:r,useColors:o}=this;if(o){const e=this.color,o="[3"+(e<8?e:"8;5;"+e),i=` ${o};1m${r} `;n[0]=i+n[0].split("\n").join("\n"+i),n.push(o+"m+"+t.exports.humanize(this.diff)+"")}else n[0]=(e.inspectOpts.hideDate?"":(new Date).toISOString()+" ")+r+" "+n[0]},e.save=function(t){t?process.env.DEBUG=t:delete process.env.DEBUG},e.load=function(){return process.env.DEBUG},e.useColors=function(){return"colors"in e.inspectOpts?Boolean(e.inspectOpts.colors):r.isatty(process.stderr.fd)},e.destroy=o.deprecate((()=>{}),"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."),e.colors=[6,2,3,4,5,1];try{const t=n(7013);t&&(t.stderr||t).level>=2&&(e.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(t){}e.inspectOpts=Object.keys(process.env).filter((t=>/^debug_/i.test(t))).reduce(((t,e)=>{const n=e.substring(6).toLowerCase().replace(/_([a-z])/g,((t,e)=>e.toUpperCase()));let r=process.env[e];return r=!!/^(yes|on|true|enabled)$/i.test(r)||!/^(no|off|false|disabled)$/i.test(r)&&("null"===r?null:Number(r)),t[n]=r,t}),{}),t.exports=n(5555)(e);const{formatters:i}=t.exports;i.o=function(t){return this.inspectOpts.colors=this.useColors,o.inspect(t,this.inspectOpts).split("\n").map((t=>t.trim())).join(" ")},i.O=function(t){return this.inspectOpts.colors=this.useColors,o.inspect(t,this.inspectOpts)}},5245:function(t,e,n){var r;t=n.nmd(t),function(){var o,i="Expected a function",s="__lodash_hash_undefined__",a="__lodash_placeholder__",u=32,c=128,l=1/0,f=9007199254740991,p=NaN,d=4294967295,h=[["ary",c],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",u],["partialRight",64],["rearg",256]],g="[object Arguments]",y="[object Array]",v="[object Boolean]",_="[object Date]",m="[object Error]",b="[object Function]",w="[object GeneratorFunction]",C="[object Map]",O="[object Number]",E="[object Object]",x="[object Promise]",S="[object RegExp]",I="[object Set]",T="[object String]",R="[object Symbol]",P="[object WeakMap]",A="[object ArrayBuffer]",j="[object DataView]",F="[object Float32Array]",M="[object Float64Array]",k="[object Int8Array]",N="[object Int16Array]",B="[object Int32Array]",L="[object Uint8Array]",D="[object Uint8ClampedArray]",V="[object Uint16Array]",$="[object Uint32Array]",G=/\b__p \+= '';/g,U=/\b(__p \+=) '' \+/g,W=/(__e\(.*?\)|\b__t\)) \+\n'';/g,z=/&(?:amp|lt|gt|quot|#39);/g,K=/[&<>"']/g,Y=RegExp(z.source),q=RegExp(K.source),J=/<%-([\s\S]+?)%>/g,H=/<%([\s\S]+?)%>/g,Z=/<%=([\s\S]+?)%>/g,Q=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,X=/^\w*$/,tt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,et=/[\\^$.*+?()[\]{}|]/g,nt=RegExp(et.source),rt=/^\s+/,ot=/\s/,it=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,st=/\{\n\/\* \[wrapped with (.+)\] \*/,at=/,? & /,ut=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ct=/[()=,{}\[\]\/\s]/,lt=/\\(\\)?/g,ft=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,pt=/\w*$/,dt=/^[-+]0x[0-9a-f]+$/i,ht=/^0b[01]+$/i,gt=/^\[object .+?Constructor\]$/,yt=/^0o[0-7]+$/i,vt=/^(?:0|[1-9]\d*)$/,_t=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,mt=/($^)/,bt=/['\n\r\u2028\u2029\\]/g,wt="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Ct="a-z\\xdf-\\xf6\\xf8-\\xff",Ot="A-Z\\xc0-\\xd6\\xd8-\\xde",Et="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",xt="["+Et+"]",St="["+wt+"]",It="\\d+",Tt="["+Ct+"]",Rt="[^\\ud800-\\udfff"+Et+It+"\\u2700-\\u27bf"+Ct+Ot+"]",Pt="\\ud83c[\\udffb-\\udfff]",At="[^\\ud800-\\udfff]",jt="(?:\\ud83c[\\udde6-\\uddff]){2}",Ft="[\\ud800-\\udbff][\\udc00-\\udfff]",Mt="["+Ot+"]",kt="(?:"+Tt+"|"+Rt+")",Nt="(?:"+Mt+"|"+Rt+")",Bt="(?:['’](?:d|ll|m|re|s|t|ve))?",Lt="(?:['’](?:D|LL|M|RE|S|T|VE))?",Dt="(?:"+St+"|"+Pt+")?",Vt="[\\ufe0e\\ufe0f]?",$t=Vt+Dt+"(?:\\u200d(?:"+[At,jt,Ft].join("|")+")"+Vt+Dt+")*",Gt="(?:"+["[\\u2700-\\u27bf]",jt,Ft].join("|")+")"+$t,Ut="(?:"+[At+St+"?",St,jt,Ft,"[\\ud800-\\udfff]"].join("|")+")",Wt=RegExp("['’]","g"),zt=RegExp(St,"g"),Kt=RegExp(Pt+"(?="+Pt+")|"+Ut+$t,"g"),Yt=RegExp([Mt+"?"+Tt+"+"+Bt+"(?="+[xt,Mt,"$"].join("|")+")",Nt+"+"+Lt+"(?="+[xt,Mt+kt,"$"].join("|")+")",Mt+"?"+kt+"+"+Bt,Mt+"+"+Lt,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",It,Gt].join("|"),"g"),qt=RegExp("[\\u200d\\ud800-\\udfff"+wt+"\\ufe0e\\ufe0f]"),Jt=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Ht=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Zt=-1,Qt={};Qt[F]=Qt[M]=Qt[k]=Qt[N]=Qt[B]=Qt[L]=Qt[D]=Qt[V]=Qt[$]=!0,Qt[g]=Qt[y]=Qt[A]=Qt[v]=Qt[j]=Qt[_]=Qt[m]=Qt[b]=Qt[C]=Qt[O]=Qt[E]=Qt[S]=Qt[I]=Qt[T]=Qt[P]=!1;var Xt={};Xt[g]=Xt[y]=Xt[A]=Xt[j]=Xt[v]=Xt[_]=Xt[F]=Xt[M]=Xt[k]=Xt[N]=Xt[B]=Xt[C]=Xt[O]=Xt[E]=Xt[S]=Xt[I]=Xt[T]=Xt[R]=Xt[L]=Xt[D]=Xt[V]=Xt[$]=!0,Xt[m]=Xt[b]=Xt[P]=!1;var te={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ee=parseFloat,ne=parseInt,re="object"==typeof global&&global&&global.Object===Object&&global,oe="object"==typeof self&&self&&self.Object===Object&&self,ie=re||oe||Function("return this")(),se=e&&!e.nodeType&&e,ae=se&&t&&!t.nodeType&&t,ue=ae&&ae.exports===se,ce=ue&&re.process,le=function(){try{return ae&&ae.require&&ae.require("util").types||ce&&ce.binding&&ce.binding("util")}catch(t){}}(),fe=le&&le.isArrayBuffer,pe=le&&le.isDate,de=le&&le.isMap,he=le&&le.isRegExp,ge=le&&le.isSet,ye=le&&le.isTypedArray;function ve(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function _e(t,e,n,r){for(var o=-1,i=null==t?0:t.length;++o<i;){var s=t[o];e(r,s,n(s),t)}return r}function me(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}function be(t,e){for(var n=null==t?0:t.length;n--&&!1!==e(t[n],n,t););return t}function we(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(!e(t[n],n,t))return!1;return!0}function Ce(t,e){for(var n=-1,r=null==t?0:t.length,o=0,i=[];++n<r;){var s=t[n];e(s,n,t)&&(i[o++]=s)}return i}function Oe(t,e){return!(null==t||!t.length)&&Fe(t,e,0)>-1}function Ee(t,e,n){for(var r=-1,o=null==t?0:t.length;++r<o;)if(n(e,t[r]))return!0;return!1}function xe(t,e){for(var n=-1,r=null==t?0:t.length,o=Array(r);++n<r;)o[n]=e(t[n],n,t);return o}function Se(t,e){for(var n=-1,r=e.length,o=t.length;++n<r;)t[o+n]=e[n];return t}function Ie(t,e,n,r){var o=-1,i=null==t?0:t.length;for(r&&i&&(n=t[++o]);++o<i;)n=e(n,t[o],o,t);return n}function Te(t,e,n,r){var o=null==t?0:t.length;for(r&&o&&(n=t[--o]);o--;)n=e(n,t[o],o,t);return n}function Re(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}var Pe=Be("length");function Ae(t,e,n){var r;return n(t,(function(t,n,o){if(e(t,n,o))return r=n,!1})),r}function je(t,e,n,r){for(var o=t.length,i=n+(r?1:-1);r?i--:++i<o;)if(e(t[i],i,t))return i;return-1}function Fe(t,e,n){return e==e?function(t,e,n){for(var r=n-1,o=t.length;++r<o;)if(t[r]===e)return r;return-1}(t,e,n):je(t,ke,n)}function Me(t,e,n,r){for(var o=n-1,i=t.length;++o<i;)if(r(t[o],e))return o;return-1}function ke(t){return t!=t}function Ne(t,e){var n=null==t?0:t.length;return n?Ve(t,e)/n:p}function Be(t){return function(e){return null==e?o:e[t]}}function Le(t){return function(e){return null==t?o:t[e]}}function De(t,e,n,r,o){return o(t,(function(t,o,i){n=r?(r=!1,t):e(n,t,o,i)})),n}function Ve(t,e){for(var n,r=-1,i=t.length;++r<i;){var s=e(t[r]);s!==o&&(n=n===o?s:n+s)}return n}function $e(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}function Ge(t){return t?t.slice(0,an(t)+1).replace(rt,""):t}function Ue(t){return function(e){return t(e)}}function We(t,e){return xe(e,(function(e){return t[e]}))}function ze(t,e){return t.has(e)}function Ke(t,e){for(var n=-1,r=t.length;++n<r&&Fe(e,t[n],0)>-1;);return n}function Ye(t,e){for(var n=t.length;n--&&Fe(e,t[n],0)>-1;);return n}function qe(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}var Je=Le({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"}),He=Le({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"});function Ze(t){return"\\"+te[t]}function Qe(t){return qt.test(t)}function Xe(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function tn(t,e){return function(n){return t(e(n))}}function en(t,e){for(var n=-1,r=t.length,o=0,i=[];++n<r;){var s=t[n];s!==e&&s!==a||(t[n]=a,i[o++]=n)}return i}function nn(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}function rn(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=[t,t]})),n}function on(t){return Qe(t)?function(t){for(var e=Kt.lastIndex=0;Kt.test(t);)++e;return e}(t):Pe(t)}function sn(t){return Qe(t)?function(t){return t.match(Kt)||[]}(t):function(t){return t.split("")}(t)}function an(t){for(var e=t.length;e--&&ot.test(t.charAt(e)););return e}var un=Le({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"}),cn=function t(e){var n,r=(e=null==e?ie:cn.defaults(ie.Object(),e,cn.pick(ie,Ht))).Array,ot=e.Date,wt=e.Error,Ct=e.Function,Ot=e.Math,Et=e.Object,xt=e.RegExp,St=e.String,It=e.TypeError,Tt=r.prototype,Rt=Ct.prototype,Pt=Et.prototype,At=e["__core-js_shared__"],jt=Rt.toString,Ft=Pt.hasOwnProperty,Mt=0,kt=(n=/[^.]+$/.exec(At&&At.keys&&At.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",Nt=Pt.toString,Bt=jt.call(Et),Lt=ie._,Dt=xt("^"+jt.call(Ft).replace(et,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Vt=ue?e.Buffer:o,$t=e.Symbol,Gt=e.Uint8Array,Ut=Vt?Vt.allocUnsafe:o,Kt=tn(Et.getPrototypeOf,Et),qt=Et.create,te=Pt.propertyIsEnumerable,re=Tt.splice,oe=$t?$t.isConcatSpreadable:o,se=$t?$t.iterator:o,ae=$t?$t.toStringTag:o,ce=function(){try{var t=li(Et,"defineProperty");return t({},"",{}),t}catch(t){}}(),le=e.clearTimeout!==ie.clearTimeout&&e.clearTimeout,Pe=ot&&ot.now!==ie.Date.now&&ot.now,Le=e.setTimeout!==ie.setTimeout&&e.setTimeout,ln=Ot.ceil,fn=Ot.floor,pn=Et.getOwnPropertySymbols,dn=Vt?Vt.isBuffer:o,hn=e.isFinite,gn=Tt.join,yn=tn(Et.keys,Et),vn=Ot.max,_n=Ot.min,mn=ot.now,bn=e.parseInt,wn=Ot.random,Cn=Tt.reverse,On=li(e,"DataView"),En=li(e,"Map"),xn=li(e,"Promise"),Sn=li(e,"Set"),In=li(e,"WeakMap"),Tn=li(Et,"create"),Rn=In&&new In,Pn={},An=Di(On),jn=Di(En),Fn=Di(xn),Mn=Di(Sn),kn=Di(In),Nn=$t?$t.prototype:o,Bn=Nn?Nn.valueOf:o,Ln=Nn?Nn.toString:o;function Dn(t){if(na(t)&&!zs(t)&&!(t instanceof Un)){if(t instanceof Gn)return t;if(Ft.call(t,"__wrapped__"))return Vi(t)}return new Gn(t)}var Vn=function(){function t(){}return function(e){if(!ea(e))return{};if(qt)return qt(e);t.prototype=e;var n=new t;return t.prototype=o,n}}();function $n(){}function Gn(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=o}function Un(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=d,this.__views__=[]}function Wn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function zn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Kn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function Yn(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new Kn;++e<n;)this.add(t[e])}function qn(t){var e=this.__data__=new zn(t);this.size=e.size}function Jn(t,e){var n=zs(t),r=!n&&Ws(t),o=!n&&!r&&Js(t),i=!n&&!r&&!o&&la(t),s=n||r||o||i,a=s?$e(t.length,St):[],u=a.length;for(var c in t)!e&&!Ft.call(t,c)||s&&("length"==c||o&&("offset"==c||"parent"==c)||i&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||vi(c,u))||a.push(c);return a}function Hn(t){var e=t.length;return e?t[Kr(0,e-1)]:o}function Zn(t,e){return Mi(To(t),sr(e,0,t.length))}function Qn(t){return Mi(To(t))}function Xn(t,e,n){(n!==o&&!$s(t[e],n)||n===o&&!(e in t))&&or(t,e,n)}function tr(t,e,n){var r=t[e];Ft.call(t,e)&&$s(r,n)&&(n!==o||e in t)||or(t,e,n)}function er(t,e){for(var n=t.length;n--;)if($s(t[n][0],e))return n;return-1}function nr(t,e,n,r){return fr(t,(function(t,o,i){e(r,t,n(t),i)})),r}function rr(t,e){return t&&Ro(e,ja(e),t)}function or(t,e,n){"__proto__"==e&&ce?ce(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function ir(t,e){for(var n=-1,i=e.length,s=r(i),a=null==t;++n<i;)s[n]=a?o:Ia(t,e[n]);return s}function sr(t,e,n){return t==t&&(n!==o&&(t=t<=n?t:n),e!==o&&(t=t>=e?t:e)),t}function ar(t,e,n,r,i,s){var a,u=1&e,c=2&e,l=4&e;if(n&&(a=i?n(t,r,i,s):n(t)),a!==o)return a;if(!ea(t))return t;var f=zs(t);if(f){if(a=function(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&Ft.call(t,"index")&&(n.index=t.index,n.input=t.input),n}(t),!u)return To(t,a)}else{var p=di(t),d=p==b||p==w;if(Js(t))return Co(t,u);if(p==E||p==g||d&&!i){if(a=c||d?{}:gi(t),!u)return c?function(t,e){return Ro(t,pi(t),e)}(t,function(t,e){return t&&Ro(e,Fa(e),t)}(a,t)):function(t,e){return Ro(t,fi(t),e)}(t,rr(a,t))}else{if(!Xt[p])return i?t:{};a=function(t,e,n){var r,o=t.constructor;switch(e){case A:return Oo(t);case v:case _:return new o(+t);case j:return function(t,e){var n=e?Oo(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case F:case M:case k:case N:case B:case L:case D:case V:case $:return Eo(t,n);case C:return new o;case O:case T:return new o(t);case S:return function(t){var e=new t.constructor(t.source,pt.exec(t));return e.lastIndex=t.lastIndex,e}(t);case I:return new o;case R:return r=t,Bn?Et(Bn.call(r)):{}}}(t,p,u)}}s||(s=new qn);var h=s.get(t);if(h)return h;s.set(t,a),aa(t)?t.forEach((function(r){a.add(ar(r,e,n,r,t,s))})):ra(t)&&t.forEach((function(r,o){a.set(o,ar(r,e,n,o,t,s))}));var y=f?o:(l?c?ri:ni:c?Fa:ja)(t);return me(y||t,(function(r,o){y&&(r=t[o=r]),tr(a,o,ar(r,e,n,o,t,s))})),a}function ur(t,e,n){var r=n.length;if(null==t)return!r;for(t=Et(t);r--;){var i=n[r],s=e[i],a=t[i];if(a===o&&!(i in t)||!s(a))return!1}return!0}function cr(t,e,n){if("function"!=typeof t)throw new It(i);return Pi((function(){t.apply(o,n)}),e)}function lr(t,e,n,r){var o=-1,i=Oe,s=!0,a=t.length,u=[],c=e.length;if(!a)return u;n&&(e=xe(e,Ue(n))),r?(i=Ee,s=!1):e.length>=200&&(i=ze,s=!1,e=new Yn(e));t:for(;++o<a;){var l=t[o],f=null==n?l:n(l);if(l=r||0!==l?l:0,s&&f==f){for(var p=c;p--;)if(e[p]===f)continue t;u.push(l)}else i(e,f,r)||u.push(l)}return u}Dn.templateSettings={escape:J,evaluate:H,interpolate:Z,variable:"",imports:{_:Dn}},Dn.prototype=$n.prototype,Dn.prototype.constructor=Dn,Gn.prototype=Vn($n.prototype),Gn.prototype.constructor=Gn,Un.prototype=Vn($n.prototype),Un.prototype.constructor=Un,Wn.prototype.clear=function(){this.__data__=Tn?Tn(null):{},this.size=0},Wn.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},Wn.prototype.get=function(t){var e=this.__data__;if(Tn){var n=e[t];return n===s?o:n}return Ft.call(e,t)?e[t]:o},Wn.prototype.has=function(t){var e=this.__data__;return Tn?e[t]!==o:Ft.call(e,t)},Wn.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=Tn&&e===o?s:e,this},zn.prototype.clear=function(){this.__data__=[],this.size=0},zn.prototype.delete=function(t){var e=this.__data__,n=er(e,t);return!(n<0||(n==e.length-1?e.pop():re.call(e,n,1),--this.size,0))},zn.prototype.get=function(t){var e=this.__data__,n=er(e,t);return n<0?o:e[n][1]},zn.prototype.has=function(t){return er(this.__data__,t)>-1},zn.prototype.set=function(t,e){var n=this.__data__,r=er(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this},Kn.prototype.clear=function(){this.size=0,this.__data__={hash:new Wn,map:new(En||zn),string:new Wn}},Kn.prototype.delete=function(t){var e=ui(this,t).delete(t);return this.size-=e?1:0,e},Kn.prototype.get=function(t){return ui(this,t).get(t)},Kn.prototype.has=function(t){return ui(this,t).has(t)},Kn.prototype.set=function(t,e){var n=ui(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this},Yn.prototype.add=Yn.prototype.push=function(t){return this.__data__.set(t,s),this},Yn.prototype.has=function(t){return this.__data__.has(t)},qn.prototype.clear=function(){this.__data__=new zn,this.size=0},qn.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},qn.prototype.get=function(t){return this.__data__.get(t)},qn.prototype.has=function(t){return this.__data__.has(t)},qn.prototype.set=function(t,e){var n=this.__data__;if(n instanceof zn){var r=n.__data__;if(!En||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new Kn(r)}return n.set(t,e),this.size=n.size,this};var fr=jo(mr),pr=jo(br,!0);function dr(t,e){var n=!0;return fr(t,(function(t,r,o){return n=!!e(t,r,o)})),n}function hr(t,e,n){for(var r=-1,i=t.length;++r<i;){var s=t[r],a=e(s);if(null!=a&&(u===o?a==a&&!ca(a):n(a,u)))var u=a,c=s}return c}function gr(t,e){var n=[];return fr(t,(function(t,r,o){e(t,r,o)&&n.push(t)})),n}function yr(t,e,n,r,o){var i=-1,s=t.length;for(n||(n=yi),o||(o=[]);++i<s;){var a=t[i];e>0&&n(a)?e>1?yr(a,e-1,n,r,o):Se(o,a):r||(o[o.length]=a)}return o}var vr=Fo(),_r=Fo(!0);function mr(t,e){return t&&vr(t,e,ja)}function br(t,e){return t&&_r(t,e,ja)}function wr(t,e){return Ce(e,(function(e){return Qs(t[e])}))}function Cr(t,e){for(var n=0,r=(e=_o(e,t)).length;null!=t&&n<r;)t=t[Li(e[n++])];return n&&n==r?t:o}function Or(t,e,n){var r=e(t);return zs(t)?r:Se(r,n(t))}function Er(t){return null==t?t===o?"[object Undefined]":"[object Null]":ae&&ae in Et(t)?function(t){var e=Ft.call(t,ae),n=t[ae];try{t[ae]=o;var r=!0}catch(t){}var i=Nt.call(t);return r&&(e?t[ae]=n:delete t[ae]),i}(t):function(t){return Nt.call(t)}(t)}function xr(t,e){return t>e}function Sr(t,e){return null!=t&&Ft.call(t,e)}function Ir(t,e){return null!=t&&e in Et(t)}function Tr(t,e,n){for(var i=n?Ee:Oe,s=t[0].length,a=t.length,u=a,c=r(a),l=1/0,f=[];u--;){var p=t[u];u&&e&&(p=xe(p,Ue(e))),l=_n(p.length,l),c[u]=!n&&(e||s>=120&&p.length>=120)?new Yn(u&&p):o}p=t[0];var d=-1,h=c[0];t:for(;++d<s&&f.length<l;){var g=p[d],y=e?e(g):g;if(g=n||0!==g?g:0,!(h?ze(h,y):i(f,y,n))){for(u=a;--u;){var v=c[u];if(!(v?ze(v,y):i(t[u],y,n)))continue t}h&&h.push(y),f.push(g)}}return f}function Rr(t,e,n){var r=null==(t=Si(t,e=_o(e,t)))?t:t[Li(Zi(e))];return null==r?o:ve(r,t,n)}function Pr(t){return na(t)&&Er(t)==g}function Ar(t,e,n,r,i){return t===e||(null==t||null==e||!na(t)&&!na(e)?t!=t&&e!=e:function(t,e,n,r,i,s){var a=zs(t),u=zs(e),c=a?y:di(t),l=u?y:di(e),f=(c=c==g?E:c)==E,p=(l=l==g?E:l)==E,d=c==l;if(d&&Js(t)){if(!Js(e))return!1;a=!0,f=!1}if(d&&!f)return s||(s=new qn),a||la(t)?ti(t,e,n,r,i,s):function(t,e,n,r,o,i,s){switch(n){case j:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case A:return!(t.byteLength!=e.byteLength||!i(new Gt(t),new Gt(e)));case v:case _:case O:return $s(+t,+e);case m:return t.name==e.name&&t.message==e.message;case S:case T:return t==e+"";case C:var a=Xe;case I:var u=1&r;if(a||(a=nn),t.size!=e.size&&!u)return!1;var c=s.get(t);if(c)return c==e;r|=2,s.set(t,e);var l=ti(a(t),a(e),r,o,i,s);return s.delete(t),l;case R:if(Bn)return Bn.call(t)==Bn.call(e)}return!1}(t,e,c,n,r,i,s);if(!(1&n)){var h=f&&Ft.call(t,"__wrapped__"),b=p&&Ft.call(e,"__wrapped__");if(h||b){var w=h?t.value():t,x=b?e.value():e;return s||(s=new qn),i(w,x,n,r,s)}}return!!d&&(s||(s=new qn),function(t,e,n,r,i,s){var a=1&n,u=ni(t),c=u.length;if(c!=ni(e).length&&!a)return!1;for(var l=c;l--;){var f=u[l];if(!(a?f in e:Ft.call(e,f)))return!1}var p=s.get(t),d=s.get(e);if(p&&d)return p==e&&d==t;var h=!0;s.set(t,e),s.set(e,t);for(var g=a;++l<c;){var y=t[f=u[l]],v=e[f];if(r)var _=a?r(v,y,f,e,t,s):r(y,v,f,t,e,s);if(!(_===o?y===v||i(y,v,n,r,s):_)){h=!1;break}g||(g="constructor"==f)}if(h&&!g){var m=t.constructor,b=e.constructor;m==b||!("constructor"in t)||!("constructor"in e)||"function"==typeof m&&m instanceof m&&"function"==typeof b&&b instanceof b||(h=!1)}return s.delete(t),s.delete(e),h}(t,e,n,r,i,s))}(t,e,n,r,Ar,i))}function jr(t,e,n,r){var i=n.length,s=i,a=!r;if(null==t)return!s;for(t=Et(t);i--;){var u=n[i];if(a&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++i<s;){var c=(u=n[i])[0],l=t[c],f=u[1];if(a&&u[2]){if(l===o&&!(c in t))return!1}else{var p=new qn;if(r)var d=r(l,f,c,t,e,p);if(!(d===o?Ar(f,l,3,r,p):d))return!1}}return!0}function Fr(t){return!(!ea(t)||(e=t,kt&&kt in e))&&(Qs(t)?Dt:gt).test(Di(t));var e}function Mr(t){return"function"==typeof t?t:null==t?ou:"object"==typeof t?zs(t)?Dr(t[0],t[1]):Lr(t):du(t)}function kr(t){if(!Ci(t))return yn(t);var e=[];for(var n in Et(t))Ft.call(t,n)&&"constructor"!=n&&e.push(n);return e}function Nr(t,e){return t<e}function Br(t,e){var n=-1,o=Ys(t)?r(t.length):[];return fr(t,(function(t,r,i){o[++n]=e(t,r,i)})),o}function Lr(t){var e=ci(t);return 1==e.length&&e[0][2]?Ei(e[0][0],e[0][1]):function(n){return n===t||jr(n,t,e)}}function Dr(t,e){return mi(t)&&Oi(e)?Ei(Li(t),e):function(n){var r=Ia(n,t);return r===o&&r===e?Ta(n,t):Ar(e,r,3)}}function Vr(t,e,n,r,i){t!==e&&vr(e,(function(s,a){if(i||(i=new qn),ea(s))!function(t,e,n,r,i,s,a){var u=Ti(t,n),c=Ti(e,n),l=a.get(c);if(l)Xn(t,n,l);else{var f=s?s(u,c,n+"",t,e,a):o,p=f===o;if(p){var d=zs(c),h=!d&&Js(c),g=!d&&!h&&la(c);f=c,d||h||g?zs(u)?f=u:qs(u)?f=To(u):h?(p=!1,f=Co(c,!0)):g?(p=!1,f=Eo(c,!0)):f=[]:ia(c)||Ws(c)?(f=u,Ws(u)?f=_a(u):ea(u)&&!Qs(u)||(f=gi(c))):p=!1}p&&(a.set(c,f),i(f,c,r,s,a),a.delete(c)),Xn(t,n,f)}}(t,e,a,n,Vr,r,i);else{var u=r?r(Ti(t,a),s,a+"",t,e,i):o;u===o&&(u=s),Xn(t,a,u)}}),Fa)}function $r(t,e){var n=t.length;if(n)return vi(e+=e<0?n:0,n)?t[e]:o}function Gr(t,e,n){e=e.length?xe(e,(function(t){return zs(t)?function(e){return Cr(e,1===t.length?t[0]:t)}:t})):[ou];var r=-1;return e=xe(e,Ue(ai())),function(t,e){var r=t.length;for(t.sort((function(t,e){return function(t,e,n){for(var r=-1,o=t.criteria,i=e.criteria,s=o.length,a=n.length;++r<s;){var u=xo(o[r],i[r]);if(u)return r>=a?u:u*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}));r--;)t[r]=t[r].value;return t}(Br(t,(function(t,n,o){return{criteria:xe(e,(function(e){return e(t)})),index:++r,value:t}})))}function Ur(t,e,n){for(var r=-1,o=e.length,i={};++r<o;){var s=e[r],a=Cr(t,s);n(a,s)&&Zr(i,_o(s,t),a)}return i}function Wr(t,e,n,r){var o=r?Me:Fe,i=-1,s=e.length,a=t;for(t===e&&(e=To(e)),n&&(a=xe(t,Ue(n)));++i<s;)for(var u=0,c=e[i],l=n?n(c):c;(u=o(a,l,u,r))>-1;)a!==t&&re.call(a,u,1),re.call(t,u,1);return t}function zr(t,e){for(var n=t?e.length:0,r=n-1;n--;){var o=e[n];if(n==r||o!==i){var i=o;vi(o)?re.call(t,o,1):co(t,o)}}return t}function Kr(t,e){return t+fn(wn()*(e-t+1))}function Yr(t,e){var n="";if(!t||e<1||e>f)return n;do{e%2&&(n+=t),(e=fn(e/2))&&(t+=t)}while(e);return n}function qr(t,e){return Ai(xi(t,e,ou),t+"")}function Jr(t){return Hn($a(t))}function Hr(t,e){var n=$a(t);return Mi(n,sr(e,0,n.length))}function Zr(t,e,n,r){if(!ea(t))return t;for(var i=-1,s=(e=_o(e,t)).length,a=s-1,u=t;null!=u&&++i<s;){var c=Li(e[i]),l=n;if("__proto__"===c||"constructor"===c||"prototype"===c)return t;if(i!=a){var f=u[c];(l=r?r(f,c,u):o)===o&&(l=ea(f)?f:vi(e[i+1])?[]:{})}tr(u,c,l),u=u[c]}return t}var Qr=Rn?function(t,e){return Rn.set(t,e),t}:ou,Xr=ce?function(t,e){return ce(t,"toString",{configurable:!0,enumerable:!1,value:eu(e),writable:!0})}:ou;function to(t){return Mi($a(t))}function eo(t,e,n){var o=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var s=r(i);++o<i;)s[o]=t[o+e];return s}function no(t,e){var n;return fr(t,(function(t,r,o){return!(n=e(t,r,o))})),!!n}function ro(t,e,n){var r=0,o=null==t?r:t.length;if("number"==typeof e&&e==e&&o<=2147483647){for(;r<o;){var i=r+o>>>1,s=t[i];null!==s&&!ca(s)&&(n?s<=e:s<e)?r=i+1:o=i}return o}return oo(t,e,ou,n)}function oo(t,e,n,r){var i=0,s=null==t?0:t.length;if(0===s)return 0;for(var a=(e=n(e))!=e,u=null===e,c=ca(e),l=e===o;i<s;){var f=fn((i+s)/2),p=n(t[f]),d=p!==o,h=null===p,g=p==p,y=ca(p);if(a)var v=r||g;else v=l?g&&(r||d):u?g&&d&&(r||!h):c?g&&d&&!h&&(r||!y):!h&&!y&&(r?p<=e:p<e);v?i=f+1:s=f}return _n(s,4294967294)}function io(t,e){for(var n=-1,r=t.length,o=0,i=[];++n<r;){var s=t[n],a=e?e(s):s;if(!n||!$s(a,u)){var u=a;i[o++]=0===s?0:s}}return i}function so(t){return"number"==typeof t?t:ca(t)?p:+t}function ao(t){if("string"==typeof t)return t;if(zs(t))return xe(t,ao)+"";if(ca(t))return Ln?Ln.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function uo(t,e,n){var r=-1,o=Oe,i=t.length,s=!0,a=[],u=a;if(n)s=!1,o=Ee;else if(i>=200){var c=e?null:qo(t);if(c)return nn(c);s=!1,o=ze,u=new Yn}else u=e?[]:a;t:for(;++r<i;){var l=t[r],f=e?e(l):l;if(l=n||0!==l?l:0,s&&f==f){for(var p=u.length;p--;)if(u[p]===f)continue t;e&&u.push(f),a.push(l)}else o(u,f,n)||(u!==a&&u.push(f),a.push(l))}return a}function co(t,e){return null==(t=Si(t,e=_o(e,t)))||delete t[Li(Zi(e))]}function lo(t,e,n,r){return Zr(t,e,n(Cr(t,e)),r)}function fo(t,e,n,r){for(var o=t.length,i=r?o:-1;(r?i--:++i<o)&&e(t[i],i,t););return n?eo(t,r?0:i,r?i+1:o):eo(t,r?i+1:0,r?o:i)}function po(t,e){var n=t;return n instanceof Un&&(n=n.value()),Ie(e,(function(t,e){return e.func.apply(e.thisArg,Se([t],e.args))}),n)}function ho(t,e,n){var o=t.length;if(o<2)return o?uo(t[0]):[];for(var i=-1,s=r(o);++i<o;)for(var a=t[i],u=-1;++u<o;)u!=i&&(s[i]=lr(s[i]||a,t[u],e,n));return uo(yr(s,1),e,n)}function go(t,e,n){for(var r=-1,i=t.length,s=e.length,a={};++r<i;){var u=r<s?e[r]:o;n(a,t[r],u)}return a}function yo(t){return qs(t)?t:[]}function vo(t){return"function"==typeof t?t:ou}function _o(t,e){return zs(t)?t:mi(t,e)?[t]:Bi(ma(t))}var mo=qr;function bo(t,e,n){var r=t.length;return n=n===o?r:n,!e&&n>=r?t:eo(t,e,n)}var wo=le||function(t){return ie.clearTimeout(t)};function Co(t,e){if(e)return t.slice();var n=t.length,r=Ut?Ut(n):new t.constructor(n);return t.copy(r),r}function Oo(t){var e=new t.constructor(t.byteLength);return new Gt(e).set(new Gt(t)),e}function Eo(t,e){var n=e?Oo(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function xo(t,e){if(t!==e){var n=t!==o,r=null===t,i=t==t,s=ca(t),a=e!==o,u=null===e,c=e==e,l=ca(e);if(!u&&!l&&!s&&t>e||s&&a&&c&&!u&&!l||r&&a&&c||!n&&c||!i)return 1;if(!r&&!s&&!l&&t<e||l&&n&&i&&!r&&!s||u&&n&&i||!a&&i||!c)return-1}return 0}function So(t,e,n,o){for(var i=-1,s=t.length,a=n.length,u=-1,c=e.length,l=vn(s-a,0),f=r(c+l),p=!o;++u<c;)f[u]=e[u];for(;++i<a;)(p||i<s)&&(f[n[i]]=t[i]);for(;l--;)f[u++]=t[i++];return f}function Io(t,e,n,o){for(var i=-1,s=t.length,a=-1,u=n.length,c=-1,l=e.length,f=vn(s-u,0),p=r(f+l),d=!o;++i<f;)p[i]=t[i];for(var h=i;++c<l;)p[h+c]=e[c];for(;++a<u;)(d||i<s)&&(p[h+n[a]]=t[i++]);return p}function To(t,e){var n=-1,o=t.length;for(e||(e=r(o));++n<o;)e[n]=t[n];return e}function Ro(t,e,n,r){var i=!n;n||(n={});for(var s=-1,a=e.length;++s<a;){var u=e[s],c=r?r(n[u],t[u],u,n,t):o;c===o&&(c=t[u]),i?or(n,u,c):tr(n,u,c)}return n}function Po(t,e){return function(n,r){var o=zs(n)?_e:nr,i=e?e():{};return o(n,t,ai(r,2),i)}}function Ao(t){return qr((function(e,n){var r=-1,i=n.length,s=i>1?n[i-1]:o,a=i>2?n[2]:o;for(s=t.length>3&&"function"==typeof s?(i--,s):o,a&&_i(n[0],n[1],a)&&(s=i<3?o:s,i=1),e=Et(e);++r<i;){var u=n[r];u&&t(e,u,r,s)}return e}))}function jo(t,e){return function(n,r){if(null==n)return n;if(!Ys(n))return t(n,r);for(var o=n.length,i=e?o:-1,s=Et(n);(e?i--:++i<o)&&!1!==r(s[i],i,s););return n}}function Fo(t){return function(e,n,r){for(var o=-1,i=Et(e),s=r(e),a=s.length;a--;){var u=s[t?a:++o];if(!1===n(i[u],u,i))break}return e}}function Mo(t){return function(e){var n=Qe(e=ma(e))?sn(e):o,r=n?n[0]:e.charAt(0),i=n?bo(n,1).join(""):e.slice(1);return r[t]()+i}}function ko(t){return function(e){return Ie(Qa(Wa(e).replace(Wt,"")),t,"")}}function No(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4]);case 6:return new t(e[0],e[1],e[2],e[3],e[4],e[5]);case 7:return new t(e[0],e[1],e[2],e[3],e[4],e[5],e[6])}var n=Vn(t.prototype),r=t.apply(n,e);return ea(r)?r:n}}function Bo(t){return function(e,n,r){var i=Et(e);if(!Ys(e)){var s=ai(n,3);e=ja(e),n=function(t){return s(i[t],t,i)}}var a=t(e,n,r);return a>-1?i[s?e[a]:a]:o}}function Lo(t){return ei((function(e){var n=e.length,r=n,s=Gn.prototype.thru;for(t&&e.reverse();r--;){var a=e[r];if("function"!=typeof a)throw new It(i);if(s&&!u&&"wrapper"==ii(a))var u=new Gn([],!0)}for(r=u?r:n;++r<n;){var c=ii(a=e[r]),l="wrapper"==c?oi(a):o;u=l&&bi(l[0])&&424==l[1]&&!l[4].length&&1==l[9]?u[ii(l[0])].apply(u,l[3]):1==a.length&&bi(a)?u[c]():u.thru(a)}return function(){var t=arguments,r=t[0];if(u&&1==t.length&&zs(r))return u.plant(r).value();for(var o=0,i=n?e[o].apply(this,t):r;++o<n;)i=e[o].call(this,i);return i}}))}function Do(t,e,n,i,s,a,u,l,f,p){var d=e&c,h=1&e,g=2&e,y=24&e,v=512&e,_=g?o:No(t);return function o(){for(var c=arguments.length,m=r(c),b=c;b--;)m[b]=arguments[b];if(y)var w=si(o),C=qe(m,w);if(i&&(m=So(m,i,s,y)),a&&(m=Io(m,a,u,y)),c-=C,y&&c<p){var O=en(m,w);return Ko(t,e,Do,o.placeholder,n,m,O,l,f,p-c)}var E=h?n:this,x=g?E[t]:t;return c=m.length,l?m=Ii(m,l):v&&c>1&&m.reverse(),d&&f<c&&(m.length=f),this&&this!==ie&&this instanceof o&&(x=_||No(x)),x.apply(E,m)}}function Vo(t,e){return function(n,r){return function(t,e,n,r){return mr(t,(function(t,o,i){e(r,n(t),o,i)})),r}(n,t,e(r),{})}}function $o(t,e){return function(n,r){var i;if(n===o&&r===o)return e;if(n!==o&&(i=n),r!==o){if(i===o)return r;"string"==typeof n||"string"==typeof r?(n=ao(n),r=ao(r)):(n=so(n),r=so(r)),i=t(n,r)}return i}}function Go(t){return ei((function(e){return e=xe(e,Ue(ai())),qr((function(n){var r=this;return t(e,(function(t){return ve(t,r,n)}))}))}))}function Uo(t,e){var n=(e=e===o?" ":ao(e)).length;if(n<2)return n?Yr(e,t):e;var r=Yr(e,ln(t/on(e)));return Qe(e)?bo(sn(r),0,t).join(""):r.slice(0,t)}function Wo(t){return function(e,n,i){return i&&"number"!=typeof i&&_i(e,n,i)&&(n=i=o),e=ha(e),n===o?(n=e,e=0):n=ha(n),function(t,e,n,o){for(var i=-1,s=vn(ln((e-t)/(n||1)),0),a=r(s);s--;)a[o?s:++i]=t,t+=n;return a}(e,n,i=i===o?e<n?1:-1:ha(i),t)}}function zo(t){return function(e,n){return"string"==typeof e&&"string"==typeof n||(e=va(e),n=va(n)),t(e,n)}}function Ko(t,e,n,r,i,s,a,c,l,f){var p=8&e;e|=p?u:64,4&(e&=~(p?64:u))||(e&=-4);var d=[t,e,i,p?s:o,p?a:o,p?o:s,p?o:a,c,l,f],h=n.apply(o,d);return bi(t)&&Ri(h,d),h.placeholder=r,ji(h,t,e)}function Yo(t){var e=Ot[t];return function(t,n){if(t=va(t),(n=null==n?0:_n(ga(n),292))&&hn(t)){var r=(ma(t)+"e").split("e");return+((r=(ma(e(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return e(t)}}var qo=Sn&&1/nn(new Sn([,-0]))[1]==l?function(t){return new Sn(t)}:cu;function Jo(t){return function(e){var n=di(e);return n==C?Xe(e):n==I?rn(e):function(t,e){return xe(e,(function(e){return[e,t[e]]}))}(e,t(e))}}function Ho(t,e,n,s,l,f,p,d){var h=2&e;if(!h&&"function"!=typeof t)throw new It(i);var g=s?s.length:0;if(g||(e&=-97,s=l=o),p=p===o?p:vn(ga(p),0),d=d===o?d:ga(d),g-=l?l.length:0,64&e){var y=s,v=l;s=l=o}var _=h?o:oi(t),m=[t,e,n,s,l,y,v,f,p,d];if(_&&function(t,e){var n=t[1],r=e[1],o=n|r,i=o<131,s=r==c&&8==n||r==c&&256==n&&t[7].length<=e[8]||384==r&&e[7].length<=e[8]&&8==n;if(!i&&!s)return t;1&r&&(t[2]=e[2],o|=1&n?0:4);var u=e[3];if(u){var l=t[3];t[3]=l?So(l,u,e[4]):u,t[4]=l?en(t[3],a):e[4]}(u=e[5])&&(l=t[5],t[5]=l?Io(l,u,e[6]):u,t[6]=l?en(t[5],a):e[6]),(u=e[7])&&(t[7]=u),r&c&&(t[8]=null==t[8]?e[8]:_n(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=o}(m,_),t=m[0],e=m[1],n=m[2],s=m[3],l=m[4],!(d=m[9]=m[9]===o?h?0:t.length:vn(m[9]-g,0))&&24&e&&(e&=-25),e&&1!=e)b=8==e||16==e?function(t,e,n){var i=No(t);return function s(){for(var a=arguments.length,u=r(a),c=a,l=si(s);c--;)u[c]=arguments[c];var f=a<3&&u[0]!==l&&u[a-1]!==l?[]:en(u,l);return(a-=f.length)<n?Ko(t,e,Do,s.placeholder,o,u,f,o,o,n-a):ve(this&&this!==ie&&this instanceof s?i:t,this,u)}}(t,e,d):e!=u&&33!=e||l.length?Do.apply(o,m):function(t,e,n,o){var i=1&e,s=No(t);return function e(){for(var a=-1,u=arguments.length,c=-1,l=o.length,f=r(l+u),p=this&&this!==ie&&this instanceof e?s:t;++c<l;)f[c]=o[c];for(;u--;)f[c++]=arguments[++a];return ve(p,i?n:this,f)}}(t,e,n,s);else var b=function(t,e,n){var r=1&e,o=No(t);return function e(){return(this&&this!==ie&&this instanceof e?o:t).apply(r?n:this,arguments)}}(t,e,n);return ji((_?Qr:Ri)(b,m),t,e)}function Zo(t,e,n,r){return t===o||$s(t,Pt[n])&&!Ft.call(r,n)?e:t}function Qo(t,e,n,r,i,s){return ea(t)&&ea(e)&&(s.set(e,t),Vr(t,e,o,Qo,s),s.delete(e)),t}function Xo(t){return ia(t)?o:t}function ti(t,e,n,r,i,s){var a=1&n,u=t.length,c=e.length;if(u!=c&&!(a&&c>u))return!1;var l=s.get(t),f=s.get(e);if(l&&f)return l==e&&f==t;var p=-1,d=!0,h=2&n?new Yn:o;for(s.set(t,e),s.set(e,t);++p<u;){var g=t[p],y=e[p];if(r)var v=a?r(y,g,p,e,t,s):r(g,y,p,t,e,s);if(v!==o){if(v)continue;d=!1;break}if(h){if(!Re(e,(function(t,e){if(!ze(h,e)&&(g===t||i(g,t,n,r,s)))return h.push(e)}))){d=!1;break}}else if(g!==y&&!i(g,y,n,r,s)){d=!1;break}}return s.delete(t),s.delete(e),d}function ei(t){return Ai(xi(t,o,Ki),t+"")}function ni(t){return Or(t,ja,fi)}function ri(t){return Or(t,Fa,pi)}var oi=Rn?function(t){return Rn.get(t)}:cu;function ii(t){for(var e=t.name+"",n=Pn[e],r=Ft.call(Pn,e)?n.length:0;r--;){var o=n[r],i=o.func;if(null==i||i==t)return o.name}return e}function si(t){return(Ft.call(Dn,"placeholder")?Dn:t).placeholder}function ai(){var t=Dn.iteratee||iu;return t=t===iu?Mr:t,arguments.length?t(arguments[0],arguments[1]):t}function ui(t,e){var n,r,o=t.__data__;return("string"==(r=typeof(n=e))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?o["string"==typeof e?"string":"hash"]:o.map}function ci(t){for(var e=ja(t),n=e.length;n--;){var r=e[n],o=t[r];e[n]=[r,o,Oi(o)]}return e}function li(t,e){var n=function(t,e){return null==t?o:t[e]}(t,e);return Fr(n)?n:o}var fi=pn?function(t){return null==t?[]:(t=Et(t),Ce(pn(t),(function(e){return te.call(t,e)})))}:yu,pi=pn?function(t){for(var e=[];t;)Se(e,fi(t)),t=Kt(t);return e}:yu,di=Er;function hi(t,e,n){for(var r=-1,o=(e=_o(e,t)).length,i=!1;++r<o;){var s=Li(e[r]);if(!(i=null!=t&&n(t,s)))break;t=t[s]}return i||++r!=o?i:!!(o=null==t?0:t.length)&&ta(o)&&vi(s,o)&&(zs(t)||Ws(t))}function gi(t){return"function"!=typeof t.constructor||Ci(t)?{}:Vn(Kt(t))}function yi(t){return zs(t)||Ws(t)||!!(oe&&t&&t[oe])}function vi(t,e){var n=typeof t;return!!(e=null==e?f:e)&&("number"==n||"symbol"!=n&&vt.test(t))&&t>-1&&t%1==0&&t<e}function _i(t,e,n){if(!ea(n))return!1;var r=typeof e;return!!("number"==r?Ys(n)&&vi(e,n.length):"string"==r&&e in n)&&$s(n[e],t)}function mi(t,e){if(zs(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!ca(t))||X.test(t)||!Q.test(t)||null!=e&&t in Et(e)}function bi(t){var e=ii(t),n=Dn[e];if("function"!=typeof n||!(e in Un.prototype))return!1;if(t===n)return!0;var r=oi(n);return!!r&&t===r[0]}(On&&di(new On(new ArrayBuffer(1)))!=j||En&&di(new En)!=C||xn&&di(xn.resolve())!=x||Sn&&di(new Sn)!=I||In&&di(new In)!=P)&&(di=function(t){var e=Er(t),n=e==E?t.constructor:o,r=n?Di(n):"";if(r)switch(r){case An:return j;case jn:return C;case Fn:return x;case Mn:return I;case kn:return P}return e});var wi=At?Qs:vu;function Ci(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Pt)}function Oi(t){return t==t&&!ea(t)}function Ei(t,e){return function(n){return null!=n&&n[t]===e&&(e!==o||t in Et(n))}}function xi(t,e,n){return e=vn(e===o?t.length-1:e,0),function(){for(var o=arguments,i=-1,s=vn(o.length-e,0),a=r(s);++i<s;)a[i]=o[e+i];i=-1;for(var u=r(e+1);++i<e;)u[i]=o[i];return u[e]=n(a),ve(t,this,u)}}function Si(t,e){return e.length<2?t:Cr(t,eo(e,0,-1))}function Ii(t,e){for(var n=t.length,r=_n(e.length,n),i=To(t);r--;){var s=e[r];t[r]=vi(s,n)?i[s]:o}return t}function Ti(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var Ri=Fi(Qr),Pi=Le||function(t,e){return ie.setTimeout(t,e)},Ai=Fi(Xr);function ji(t,e,n){var r=e+"";return Ai(t,function(t,e){var n=e.length;if(!n)return t;var r=n-1;return e[r]=(n>1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(it,"{\n/* [wrapped with "+e+"] */\n")}(r,function(t,e){return me(h,(function(n){var r="_."+n[0];e&n[1]&&!Oe(t,r)&&t.push(r)})),t.sort()}(function(t){var e=t.match(st);return e?e[1].split(at):[]}(r),n)))}function Fi(t){var e=0,n=0;return function(){var r=mn(),i=16-(r-n);if(n=r,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(o,arguments)}}function Mi(t,e){var n=-1,r=t.length,i=r-1;for(e=e===o?r:e;++n<e;){var s=Kr(n,i),a=t[s];t[s]=t[n],t[n]=a}return t.length=e,t}var ki,Ni,Bi=(ki=ks((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(tt,(function(t,n,r,o){e.push(r?o.replace(lt,"$1"):n||t)})),e}),(function(t){return 500===Ni.size&&Ni.clear(),t})),Ni=ki.cache,ki);function Li(t){if("string"==typeof t||ca(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Di(t){if(null!=t){try{return jt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function Vi(t){if(t instanceof Un)return t.clone();var e=new Gn(t.__wrapped__,t.__chain__);return e.__actions__=To(t.__actions__),e.__index__=t.__index__,e.__values__=t.__values__,e}var $i=qr((function(t,e){return qs(t)?lr(t,yr(e,1,qs,!0)):[]})),Gi=qr((function(t,e){var n=Zi(e);return qs(n)&&(n=o),qs(t)?lr(t,yr(e,1,qs,!0),ai(n,2)):[]})),Ui=qr((function(t,e){var n=Zi(e);return qs(n)&&(n=o),qs(t)?lr(t,yr(e,1,qs,!0),o,n):[]}));function Wi(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var o=null==n?0:ga(n);return o<0&&(o=vn(r+o,0)),je(t,ai(e,3),o)}function zi(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=r-1;return n!==o&&(i=ga(n),i=n<0?vn(r+i,0):_n(i,r-1)),je(t,ai(e,3),i,!0)}function Ki(t){return null!=t&&t.length?yr(t,1):[]}function Yi(t){return t&&t.length?t[0]:o}var qi=qr((function(t){var e=xe(t,yo);return e.length&&e[0]===t[0]?Tr(e):[]})),Ji=qr((function(t){var e=Zi(t),n=xe(t,yo);return e===Zi(n)?e=o:n.pop(),n.length&&n[0]===t[0]?Tr(n,ai(e,2)):[]})),Hi=qr((function(t){var e=Zi(t),n=xe(t,yo);return(e="function"==typeof e?e:o)&&n.pop(),n.length&&n[0]===t[0]?Tr(n,o,e):[]}));function Zi(t){var e=null==t?0:t.length;return e?t[e-1]:o}var Qi=qr(Xi);function Xi(t,e){return t&&t.length&&e&&e.length?Wr(t,e):t}var ts=ei((function(t,e){var n=null==t?0:t.length,r=ir(t,e);return zr(t,xe(e,(function(t){return vi(t,n)?+t:t})).sort(xo)),r}));function es(t){return null==t?t:Cn.call(t)}var ns=qr((function(t){return uo(yr(t,1,qs,!0))})),rs=qr((function(t){var e=Zi(t);return qs(e)&&(e=o),uo(yr(t,1,qs,!0),ai(e,2))})),os=qr((function(t){var e=Zi(t);return e="function"==typeof e?e:o,uo(yr(t,1,qs,!0),o,e)}));function is(t){if(!t||!t.length)return[];var e=0;return t=Ce(t,(function(t){if(qs(t))return e=vn(t.length,e),!0})),$e(e,(function(e){return xe(t,Be(e))}))}function ss(t,e){if(!t||!t.length)return[];var n=is(t);return null==e?n:xe(n,(function(t){return ve(e,o,t)}))}var as=qr((function(t,e){return qs(t)?lr(t,e):[]})),us=qr((function(t){return ho(Ce(t,qs))})),cs=qr((function(t){var e=Zi(t);return qs(e)&&(e=o),ho(Ce(t,qs),ai(e,2))})),ls=qr((function(t){var e=Zi(t);return e="function"==typeof e?e:o,ho(Ce(t,qs),o,e)})),fs=qr(is),ps=qr((function(t){var e=t.length,n=e>1?t[e-1]:o;return n="function"==typeof n?(t.pop(),n):o,ss(t,n)}));function ds(t){var e=Dn(t);return e.__chain__=!0,e}function hs(t,e){return e(t)}var gs=ei((function(t){var e=t.length,n=e?t[0]:0,r=this.__wrapped__,i=function(e){return ir(e,t)};return!(e>1||this.__actions__.length)&&r instanceof Un&&vi(n)?((r=r.slice(n,+n+(e?1:0))).__actions__.push({func:hs,args:[i],thisArg:o}),new Gn(r,this.__chain__).thru((function(t){return e&&!t.length&&t.push(o),t}))):this.thru(i)})),ys=Po((function(t,e,n){Ft.call(t,n)?++t[n]:or(t,n,1)})),vs=Bo(Wi),_s=Bo(zi);function ms(t,e){return(zs(t)?me:fr)(t,ai(e,3))}function bs(t,e){return(zs(t)?be:pr)(t,ai(e,3))}var ws=Po((function(t,e,n){Ft.call(t,n)?t[n].push(e):or(t,n,[e])})),Cs=qr((function(t,e,n){var o=-1,i="function"==typeof e,s=Ys(t)?r(t.length):[];return fr(t,(function(t){s[++o]=i?ve(e,t,n):Rr(t,e,n)})),s})),Os=Po((function(t,e,n){or(t,n,e)}));function Es(t,e){return(zs(t)?xe:Br)(t,ai(e,3))}var xs=Po((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]})),Ss=qr((function(t,e){if(null==t)return[];var n=e.length;return n>1&&_i(t,e[0],e[1])?e=[]:n>2&&_i(e[0],e[1],e[2])&&(e=[e[0]]),Gr(t,yr(e,1),[])})),Is=Pe||function(){return ie.Date.now()};function Ts(t,e,n){return e=n?o:e,e=t&&null==e?t.length:e,Ho(t,c,o,o,o,o,e)}function Rs(t,e){var n;if("function"!=typeof e)throw new It(i);return t=ga(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=o),n}}var Ps=qr((function(t,e,n){var r=1;if(n.length){var o=en(n,si(Ps));r|=u}return Ho(t,r,e,n,o)})),As=qr((function(t,e,n){var r=3;if(n.length){var o=en(n,si(As));r|=u}return Ho(e,r,t,n,o)}));function js(t,e,n){var r,s,a,u,c,l,f=0,p=!1,d=!1,h=!0;if("function"!=typeof t)throw new It(i);function g(e){var n=r,i=s;return r=s=o,f=e,u=t.apply(i,n)}function y(t){return f=t,c=Pi(_,e),p?g(t):u}function v(t){var n=t-l;return l===o||n>=e||n<0||d&&t-f>=a}function _(){var t=Is();if(v(t))return m(t);c=Pi(_,function(t){var n=e-(t-l);return d?_n(n,a-(t-f)):n}(t))}function m(t){return c=o,h&&r?g(t):(r=s=o,u)}function b(){var t=Is(),n=v(t);if(r=arguments,s=this,l=t,n){if(c===o)return y(l);if(d)return wo(c),c=Pi(_,e),g(l)}return c===o&&(c=Pi(_,e)),u}return e=va(e)||0,ea(n)&&(p=!!n.leading,a=(d="maxWait"in n)?vn(va(n.maxWait)||0,e):a,h="trailing"in n?!!n.trailing:h),b.cancel=function(){c!==o&&wo(c),f=0,r=l=s=c=o},b.flush=function(){return c===o?u:m(Is())},b}var Fs=qr((function(t,e){return cr(t,1,e)})),Ms=qr((function(t,e,n){return cr(t,va(e)||0,n)}));function ks(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new It(i);var n=function(){var r=arguments,o=e?e.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var s=t.apply(this,r);return n.cache=i.set(o,s)||i,s};return n.cache=new(ks.Cache||Kn),n}function Ns(t){if("function"!=typeof t)throw new It(i);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}ks.Cache=Kn;var Bs=mo((function(t,e){var n=(e=1==e.length&&zs(e[0])?xe(e[0],Ue(ai())):xe(yr(e,1),Ue(ai()))).length;return qr((function(r){for(var o=-1,i=_n(r.length,n);++o<i;)r[o]=e[o].call(this,r[o]);return ve(t,this,r)}))})),Ls=qr((function(t,e){var n=en(e,si(Ls));return Ho(t,u,o,e,n)})),Ds=qr((function(t,e){var n=en(e,si(Ds));return Ho(t,64,o,e,n)})),Vs=ei((function(t,e){return Ho(t,256,o,o,o,e)}));function $s(t,e){return t===e||t!=t&&e!=e}var Gs=zo(xr),Us=zo((function(t,e){return t>=e})),Ws=Pr(function(){return arguments}())?Pr:function(t){return na(t)&&Ft.call(t,"callee")&&!te.call(t,"callee")},zs=r.isArray,Ks=fe?Ue(fe):function(t){return na(t)&&Er(t)==A};function Ys(t){return null!=t&&ta(t.length)&&!Qs(t)}function qs(t){return na(t)&&Ys(t)}var Js=dn||vu,Hs=pe?Ue(pe):function(t){return na(t)&&Er(t)==_};function Zs(t){if(!na(t))return!1;var e=Er(t);return e==m||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!ia(t)}function Qs(t){if(!ea(t))return!1;var e=Er(t);return e==b||e==w||"[object AsyncFunction]"==e||"[object Proxy]"==e}function Xs(t){return"number"==typeof t&&t==ga(t)}function ta(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=f}function ea(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function na(t){return null!=t&&"object"==typeof t}var ra=de?Ue(de):function(t){return na(t)&&di(t)==C};function oa(t){return"number"==typeof t||na(t)&&Er(t)==O}function ia(t){if(!na(t)||Er(t)!=E)return!1;var e=Kt(t);if(null===e)return!0;var n=Ft.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&jt.call(n)==Bt}var sa=he?Ue(he):function(t){return na(t)&&Er(t)==S},aa=ge?Ue(ge):function(t){return na(t)&&di(t)==I};function ua(t){return"string"==typeof t||!zs(t)&&na(t)&&Er(t)==T}function ca(t){return"symbol"==typeof t||na(t)&&Er(t)==R}var la=ye?Ue(ye):function(t){return na(t)&&ta(t.length)&&!!Qt[Er(t)]},fa=zo(Nr),pa=zo((function(t,e){return t<=e}));function da(t){if(!t)return[];if(Ys(t))return ua(t)?sn(t):To(t);if(se&&t[se])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[se]());var e=di(t);return(e==C?Xe:e==I?nn:$a)(t)}function ha(t){return t?(t=va(t))===l||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function ga(t){var e=ha(t),n=e%1;return e==e?n?e-n:e:0}function ya(t){return t?sr(ga(t),0,d):0}function va(t){if("number"==typeof t)return t;if(ca(t))return p;if(ea(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=ea(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Ge(t);var n=ht.test(t);return n||yt.test(t)?ne(t.slice(2),n?2:8):dt.test(t)?p:+t}function _a(t){return Ro(t,Fa(t))}function ma(t){return null==t?"":ao(t)}var ba=Ao((function(t,e){if(Ci(e)||Ys(e))Ro(e,ja(e),t);else for(var n in e)Ft.call(e,n)&&tr(t,n,e[n])})),wa=Ao((function(t,e){Ro(e,Fa(e),t)})),Ca=Ao((function(t,e,n,r){Ro(e,Fa(e),t,r)})),Oa=Ao((function(t,e,n,r){Ro(e,ja(e),t,r)})),Ea=ei(ir),xa=qr((function(t,e){t=Et(t);var n=-1,r=e.length,i=r>2?e[2]:o;for(i&&_i(e[0],e[1],i)&&(r=1);++n<r;)for(var s=e[n],a=Fa(s),u=-1,c=a.length;++u<c;){var l=a[u],f=t[l];(f===o||$s(f,Pt[l])&&!Ft.call(t,l))&&(t[l]=s[l])}return t})),Sa=qr((function(t){return t.push(o,Qo),ve(ka,o,t)}));function Ia(t,e,n){var r=null==t?o:Cr(t,e);return r===o?n:r}function Ta(t,e){return null!=t&&hi(t,e,Ir)}var Ra=Vo((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=Nt.call(e)),t[e]=n}),eu(ou)),Pa=Vo((function(t,e,n){null!=e&&"function"!=typeof e.toString&&(e=Nt.call(e)),Ft.call(t,e)?t[e].push(n):t[e]=[n]}),ai),Aa=qr(Rr);function ja(t){return Ys(t)?Jn(t):kr(t)}function Fa(t){return Ys(t)?Jn(t,!0):function(t){if(!ea(t))return function(t){var e=[];if(null!=t)for(var n in Et(t))e.push(n);return e}(t);var e=Ci(t),n=[];for(var r in t)("constructor"!=r||!e&&Ft.call(t,r))&&n.push(r);return n}(t)}var Ma=Ao((function(t,e,n){Vr(t,e,n)})),ka=Ao((function(t,e,n,r){Vr(t,e,n,r)})),Na=ei((function(t,e){var n={};if(null==t)return n;var r=!1;e=xe(e,(function(e){return e=_o(e,t),r||(r=e.length>1),e})),Ro(t,ri(t),n),r&&(n=ar(n,7,Xo));for(var o=e.length;o--;)co(n,e[o]);return n})),Ba=ei((function(t,e){return null==t?{}:function(t,e){return Ur(t,e,(function(e,n){return Ta(t,n)}))}(t,e)}));function La(t,e){if(null==t)return{};var n=xe(ri(t),(function(t){return[t]}));return e=ai(e),Ur(t,n,(function(t,n){return e(t,n[0])}))}var Da=Jo(ja),Va=Jo(Fa);function $a(t){return null==t?[]:We(t,ja(t))}var Ga=ko((function(t,e,n){return e=e.toLowerCase(),t+(n?Ua(e):e)}));function Ua(t){return Za(ma(t).toLowerCase())}function Wa(t){return(t=ma(t))&&t.replace(_t,Je).replace(zt,"")}var za=ko((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Ka=ko((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Ya=Mo("toLowerCase"),qa=ko((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()})),Ja=ko((function(t,e,n){return t+(n?" ":"")+Za(e)})),Ha=ko((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),Za=Mo("toUpperCase");function Qa(t,e,n){return t=ma(t),(e=n?o:e)===o?function(t){return Jt.test(t)}(t)?function(t){return t.match(Yt)||[]}(t):function(t){return t.match(ut)||[]}(t):t.match(e)||[]}var Xa=qr((function(t,e){try{return ve(t,o,e)}catch(t){return Zs(t)?t:new wt(t)}})),tu=ei((function(t,e){return me(e,(function(e){e=Li(e),or(t,e,Ps(t[e],t))})),t}));function eu(t){return function(){return t}}var nu=Lo(),ru=Lo(!0);function ou(t){return t}function iu(t){return Mr("function"==typeof t?t:ar(t,1))}var su=qr((function(t,e){return function(n){return Rr(n,t,e)}})),au=qr((function(t,e){return function(n){return Rr(t,n,e)}}));function uu(t,e,n){var r=ja(e),o=wr(e,r);null!=n||ea(e)&&(o.length||!r.length)||(n=e,e=t,t=this,o=wr(e,ja(e)));var i=!(ea(n)&&"chain"in n&&!n.chain),s=Qs(t);return me(o,(function(n){var r=e[n];t[n]=r,s&&(t.prototype[n]=function(){var e=this.__chain__;if(i||e){var n=t(this.__wrapped__),o=n.__actions__=To(this.__actions__);return o.push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,Se([this.value()],arguments))})})),t}function cu(){}var lu=Go(xe),fu=Go(we),pu=Go(Re);function du(t){return mi(t)?Be(Li(t)):function(t){return function(e){return Cr(e,t)}}(t)}var hu=Wo(),gu=Wo(!0);function yu(){return[]}function vu(){return!1}var _u,mu=$o((function(t,e){return t+e}),0),bu=Yo("ceil"),wu=$o((function(t,e){return t/e}),1),Cu=Yo("floor"),Ou=$o((function(t,e){return t*e}),1),Eu=Yo("round"),xu=$o((function(t,e){return t-e}),0);return Dn.after=function(t,e){if("function"!=typeof e)throw new It(i);return t=ga(t),function(){if(--t<1)return e.apply(this,arguments)}},Dn.ary=Ts,Dn.assign=ba,Dn.assignIn=wa,Dn.assignInWith=Ca,Dn.assignWith=Oa,Dn.at=Ea,Dn.before=Rs,Dn.bind=Ps,Dn.bindAll=tu,Dn.bindKey=As,Dn.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return zs(t)?t:[t]},Dn.chain=ds,Dn.chunk=function(t,e,n){e=(n?_i(t,e,n):e===o)?1:vn(ga(e),0);var i=null==t?0:t.length;if(!i||e<1)return[];for(var s=0,a=0,u=r(ln(i/e));s<i;)u[a++]=eo(t,s,s+=e);return u},Dn.compact=function(t){for(var e=-1,n=null==t?0:t.length,r=0,o=[];++e<n;){var i=t[e];i&&(o[r++]=i)}return o},Dn.concat=function(){var t=arguments.length;if(!t)return[];for(var e=r(t-1),n=arguments[0],o=t;o--;)e[o-1]=arguments[o];return Se(zs(n)?To(n):[n],yr(e,1))},Dn.cond=function(t){var e=null==t?0:t.length,n=ai();return t=e?xe(t,(function(t){if("function"!=typeof t[1])throw new It(i);return[n(t[0]),t[1]]})):[],qr((function(n){for(var r=-1;++r<e;){var o=t[r];if(ve(o[0],this,n))return ve(o[1],this,n)}}))},Dn.conforms=function(t){return function(t){var e=ja(t);return function(n){return ur(n,t,e)}}(ar(t,1))},Dn.constant=eu,Dn.countBy=ys,Dn.create=function(t,e){var n=Vn(t);return null==e?n:rr(n,e)},Dn.curry=function t(e,n,r){var i=Ho(e,8,o,o,o,o,o,n=r?o:n);return i.placeholder=t.placeholder,i},Dn.curryRight=function t(e,n,r){var i=Ho(e,16,o,o,o,o,o,n=r?o:n);return i.placeholder=t.placeholder,i},Dn.debounce=js,Dn.defaults=xa,Dn.defaultsDeep=Sa,Dn.defer=Fs,Dn.delay=Ms,Dn.difference=$i,Dn.differenceBy=Gi,Dn.differenceWith=Ui,Dn.drop=function(t,e,n){var r=null==t?0:t.length;return r?eo(t,(e=n||e===o?1:ga(e))<0?0:e,r):[]},Dn.dropRight=function(t,e,n){var r=null==t?0:t.length;return r?eo(t,0,(e=r-(e=n||e===o?1:ga(e)))<0?0:e):[]},Dn.dropRightWhile=function(t,e){return t&&t.length?fo(t,ai(e,3),!0,!0):[]},Dn.dropWhile=function(t,e){return t&&t.length?fo(t,ai(e,3),!0):[]},Dn.fill=function(t,e,n,r){var i=null==t?0:t.length;return i?(n&&"number"!=typeof n&&_i(t,e,n)&&(n=0,r=i),function(t,e,n,r){var i=t.length;for((n=ga(n))<0&&(n=-n>i?0:i+n),(r=r===o||r>i?i:ga(r))<0&&(r+=i),r=n>r?0:ya(r);n<r;)t[n++]=e;return t}(t,e,n,r)):[]},Dn.filter=function(t,e){return(zs(t)?Ce:gr)(t,ai(e,3))},Dn.flatMap=function(t,e){return yr(Es(t,e),1)},Dn.flatMapDeep=function(t,e){return yr(Es(t,e),l)},Dn.flatMapDepth=function(t,e,n){return n=n===o?1:ga(n),yr(Es(t,e),n)},Dn.flatten=Ki,Dn.flattenDeep=function(t){return null!=t&&t.length?yr(t,l):[]},Dn.flattenDepth=function(t,e){return null!=t&&t.length?yr(t,e=e===o?1:ga(e)):[]},Dn.flip=function(t){return Ho(t,512)},Dn.flow=nu,Dn.flowRight=ru,Dn.fromPairs=function(t){for(var e=-1,n=null==t?0:t.length,r={};++e<n;){var o=t[e];r[o[0]]=o[1]}return r},Dn.functions=function(t){return null==t?[]:wr(t,ja(t))},Dn.functionsIn=function(t){return null==t?[]:wr(t,Fa(t))},Dn.groupBy=ws,Dn.initial=function(t){return null!=t&&t.length?eo(t,0,-1):[]},Dn.intersection=qi,Dn.intersectionBy=Ji,Dn.intersectionWith=Hi,Dn.invert=Ra,Dn.invertBy=Pa,Dn.invokeMap=Cs,Dn.iteratee=iu,Dn.keyBy=Os,Dn.keys=ja,Dn.keysIn=Fa,Dn.map=Es,Dn.mapKeys=function(t,e){var n={};return e=ai(e,3),mr(t,(function(t,r,o){or(n,e(t,r,o),t)})),n},Dn.mapValues=function(t,e){var n={};return e=ai(e,3),mr(t,(function(t,r,o){or(n,r,e(t,r,o))})),n},Dn.matches=function(t){return Lr(ar(t,1))},Dn.matchesProperty=function(t,e){return Dr(t,ar(e,1))},Dn.memoize=ks,Dn.merge=Ma,Dn.mergeWith=ka,Dn.method=su,Dn.methodOf=au,Dn.mixin=uu,Dn.negate=Ns,Dn.nthArg=function(t){return t=ga(t),qr((function(e){return $r(e,t)}))},Dn.omit=Na,Dn.omitBy=function(t,e){return La(t,Ns(ai(e)))},Dn.once=function(t){return Rs(2,t)},Dn.orderBy=function(t,e,n,r){return null==t?[]:(zs(e)||(e=null==e?[]:[e]),zs(n=r?o:n)||(n=null==n?[]:[n]),Gr(t,e,n))},Dn.over=lu,Dn.overArgs=Bs,Dn.overEvery=fu,Dn.overSome=pu,Dn.partial=Ls,Dn.partialRight=Ds,Dn.partition=xs,Dn.pick=Ba,Dn.pickBy=La,Dn.property=du,Dn.propertyOf=function(t){return function(e){return null==t?o:Cr(t,e)}},Dn.pull=Qi,Dn.pullAll=Xi,Dn.pullAllBy=function(t,e,n){return t&&t.length&&e&&e.length?Wr(t,e,ai(n,2)):t},Dn.pullAllWith=function(t,e,n){return t&&t.length&&e&&e.length?Wr(t,e,o,n):t},Dn.pullAt=ts,Dn.range=hu,Dn.rangeRight=gu,Dn.rearg=Vs,Dn.reject=function(t,e){return(zs(t)?Ce:gr)(t,Ns(ai(e,3)))},Dn.remove=function(t,e){var n=[];if(!t||!t.length)return n;var r=-1,o=[],i=t.length;for(e=ai(e,3);++r<i;){var s=t[r];e(s,r,t)&&(n.push(s),o.push(r))}return zr(t,o),n},Dn.rest=function(t,e){if("function"!=typeof t)throw new It(i);return qr(t,e=e===o?e:ga(e))},Dn.reverse=es,Dn.sampleSize=function(t,e,n){return e=(n?_i(t,e,n):e===o)?1:ga(e),(zs(t)?Zn:Hr)(t,e)},Dn.set=function(t,e,n){return null==t?t:Zr(t,e,n)},Dn.setWith=function(t,e,n,r){return r="function"==typeof r?r:o,null==t?t:Zr(t,e,n,r)},Dn.shuffle=function(t){return(zs(t)?Qn:to)(t)},Dn.slice=function(t,e,n){var r=null==t?0:t.length;return r?(n&&"number"!=typeof n&&_i(t,e,n)?(e=0,n=r):(e=null==e?0:ga(e),n=n===o?r:ga(n)),eo(t,e,n)):[]},Dn.sortBy=Ss,Dn.sortedUniq=function(t){return t&&t.length?io(t):[]},Dn.sortedUniqBy=function(t,e){return t&&t.length?io(t,ai(e,2)):[]},Dn.split=function(t,e,n){return n&&"number"!=typeof n&&_i(t,e,n)&&(e=n=o),(n=n===o?d:n>>>0)?(t=ma(t))&&("string"==typeof e||null!=e&&!sa(e))&&!(e=ao(e))&&Qe(t)?bo(sn(t),0,n):t.split(e,n):[]},Dn.spread=function(t,e){if("function"!=typeof t)throw new It(i);return e=null==e?0:vn(ga(e),0),qr((function(n){var r=n[e],o=bo(n,0,e);return r&&Se(o,r),ve(t,this,o)}))},Dn.tail=function(t){var e=null==t?0:t.length;return e?eo(t,1,e):[]},Dn.take=function(t,e,n){return t&&t.length?eo(t,0,(e=n||e===o?1:ga(e))<0?0:e):[]},Dn.takeRight=function(t,e,n){var r=null==t?0:t.length;return r?eo(t,(e=r-(e=n||e===o?1:ga(e)))<0?0:e,r):[]},Dn.takeRightWhile=function(t,e){return t&&t.length?fo(t,ai(e,3),!1,!0):[]},Dn.takeWhile=function(t,e){return t&&t.length?fo(t,ai(e,3)):[]},Dn.tap=function(t,e){return e(t),t},Dn.throttle=function(t,e,n){var r=!0,o=!0;if("function"!=typeof t)throw new It(i);return ea(n)&&(r="leading"in n?!!n.leading:r,o="trailing"in n?!!n.trailing:o),js(t,e,{leading:r,maxWait:e,trailing:o})},Dn.thru=hs,Dn.toArray=da,Dn.toPairs=Da,Dn.toPairsIn=Va,Dn.toPath=function(t){return zs(t)?xe(t,Li):ca(t)?[t]:To(Bi(ma(t)))},Dn.toPlainObject=_a,Dn.transform=function(t,e,n){var r=zs(t),o=r||Js(t)||la(t);if(e=ai(e,4),null==n){var i=t&&t.constructor;n=o?r?new i:[]:ea(t)&&Qs(i)?Vn(Kt(t)):{}}return(o?me:mr)(t,(function(t,r,o){return e(n,t,r,o)})),n},Dn.unary=function(t){return Ts(t,1)},Dn.union=ns,Dn.unionBy=rs,Dn.unionWith=os,Dn.uniq=function(t){return t&&t.length?uo(t):[]},Dn.uniqBy=function(t,e){return t&&t.length?uo(t,ai(e,2)):[]},Dn.uniqWith=function(t,e){return e="function"==typeof e?e:o,t&&t.length?uo(t,o,e):[]},Dn.unset=function(t,e){return null==t||co(t,e)},Dn.unzip=is,Dn.unzipWith=ss,Dn.update=function(t,e,n){return null==t?t:lo(t,e,vo(n))},Dn.updateWith=function(t,e,n,r){return r="function"==typeof r?r:o,null==t?t:lo(t,e,vo(n),r)},Dn.values=$a,Dn.valuesIn=function(t){return null==t?[]:We(t,Fa(t))},Dn.without=as,Dn.words=Qa,Dn.wrap=function(t,e){return Ls(vo(e),t)},Dn.xor=us,Dn.xorBy=cs,Dn.xorWith=ls,Dn.zip=fs,Dn.zipObject=function(t,e){return go(t||[],e||[],tr)},Dn.zipObjectDeep=function(t,e){return go(t||[],e||[],Zr)},Dn.zipWith=ps,Dn.entries=Da,Dn.entriesIn=Va,Dn.extend=wa,Dn.extendWith=Ca,uu(Dn,Dn),Dn.add=mu,Dn.attempt=Xa,Dn.camelCase=Ga,Dn.capitalize=Ua,Dn.ceil=bu,Dn.clamp=function(t,e,n){return n===o&&(n=e,e=o),n!==o&&(n=(n=va(n))==n?n:0),e!==o&&(e=(e=va(e))==e?e:0),sr(va(t),e,n)},Dn.clone=function(t){return ar(t,4)},Dn.cloneDeep=function(t){return ar(t,5)},Dn.cloneDeepWith=function(t,e){return ar(t,5,e="function"==typeof e?e:o)},Dn.cloneWith=function(t,e){return ar(t,4,e="function"==typeof e?e:o)},Dn.conformsTo=function(t,e){return null==e||ur(t,e,ja(e))},Dn.deburr=Wa,Dn.defaultTo=function(t,e){return null==t||t!=t?e:t},Dn.divide=wu,Dn.endsWith=function(t,e,n){t=ma(t),e=ao(e);var r=t.length,i=n=n===o?r:sr(ga(n),0,r);return(n-=e.length)>=0&&t.slice(n,i)==e},Dn.eq=$s,Dn.escape=function(t){return(t=ma(t))&&q.test(t)?t.replace(K,He):t},Dn.escapeRegExp=function(t){return(t=ma(t))&&nt.test(t)?t.replace(et,"\\$&"):t},Dn.every=function(t,e,n){var r=zs(t)?we:dr;return n&&_i(t,e,n)&&(e=o),r(t,ai(e,3))},Dn.find=vs,Dn.findIndex=Wi,Dn.findKey=function(t,e){return Ae(t,ai(e,3),mr)},Dn.findLast=_s,Dn.findLastIndex=zi,Dn.findLastKey=function(t,e){return Ae(t,ai(e,3),br)},Dn.floor=Cu,Dn.forEach=ms,Dn.forEachRight=bs,Dn.forIn=function(t,e){return null==t?t:vr(t,ai(e,3),Fa)},Dn.forInRight=function(t,e){return null==t?t:_r(t,ai(e,3),Fa)},Dn.forOwn=function(t,e){return t&&mr(t,ai(e,3))},Dn.forOwnRight=function(t,e){return t&&br(t,ai(e,3))},Dn.get=Ia,Dn.gt=Gs,Dn.gte=Us,Dn.has=function(t,e){return null!=t&&hi(t,e,Sr)},Dn.hasIn=Ta,Dn.head=Yi,Dn.identity=ou,Dn.includes=function(t,e,n,r){t=Ys(t)?t:$a(t),n=n&&!r?ga(n):0;var o=t.length;return n<0&&(n=vn(o+n,0)),ua(t)?n<=o&&t.indexOf(e,n)>-1:!!o&&Fe(t,e,n)>-1},Dn.indexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var o=null==n?0:ga(n);return o<0&&(o=vn(r+o,0)),Fe(t,e,o)},Dn.inRange=function(t,e,n){return e=ha(e),n===o?(n=e,e=0):n=ha(n),function(t,e,n){return t>=_n(e,n)&&t<vn(e,n)}(t=va(t),e,n)},Dn.invoke=Aa,Dn.isArguments=Ws,Dn.isArray=zs,Dn.isArrayBuffer=Ks,Dn.isArrayLike=Ys,Dn.isArrayLikeObject=qs,Dn.isBoolean=function(t){return!0===t||!1===t||na(t)&&Er(t)==v},Dn.isBuffer=Js,Dn.isDate=Hs,Dn.isElement=function(t){return na(t)&&1===t.nodeType&&!ia(t)},Dn.isEmpty=function(t){if(null==t)return!0;if(Ys(t)&&(zs(t)||"string"==typeof t||"function"==typeof t.splice||Js(t)||la(t)||Ws(t)))return!t.length;var e=di(t);if(e==C||e==I)return!t.size;if(Ci(t))return!kr(t).length;for(var n in t)if(Ft.call(t,n))return!1;return!0},Dn.isEqual=function(t,e){return Ar(t,e)},Dn.isEqualWith=function(t,e,n){var r=(n="function"==typeof n?n:o)?n(t,e):o;return r===o?Ar(t,e,o,n):!!r},Dn.isError=Zs,Dn.isFinite=function(t){return"number"==typeof t&&hn(t)},Dn.isFunction=Qs,Dn.isInteger=Xs,Dn.isLength=ta,Dn.isMap=ra,Dn.isMatch=function(t,e){return t===e||jr(t,e,ci(e))},Dn.isMatchWith=function(t,e,n){return n="function"==typeof n?n:o,jr(t,e,ci(e),n)},Dn.isNaN=function(t){return oa(t)&&t!=+t},Dn.isNative=function(t){if(wi(t))throw new wt("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Fr(t)},Dn.isNil=function(t){return null==t},Dn.isNull=function(t){return null===t},Dn.isNumber=oa,Dn.isObject=ea,Dn.isObjectLike=na,Dn.isPlainObject=ia,Dn.isRegExp=sa,Dn.isSafeInteger=function(t){return Xs(t)&&t>=-9007199254740991&&t<=f},Dn.isSet=aa,Dn.isString=ua,Dn.isSymbol=ca,Dn.isTypedArray=la,Dn.isUndefined=function(t){return t===o},Dn.isWeakMap=function(t){return na(t)&&di(t)==P},Dn.isWeakSet=function(t){return na(t)&&"[object WeakSet]"==Er(t)},Dn.join=function(t,e){return null==t?"":gn.call(t,e)},Dn.kebabCase=za,Dn.last=Zi,Dn.lastIndexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=r;return n!==o&&(i=(i=ga(n))<0?vn(r+i,0):_n(i,r-1)),e==e?function(t,e,n){for(var r=n+1;r--;)if(t[r]===e)return r;return r}(t,e,i):je(t,ke,i,!0)},Dn.lowerCase=Ka,Dn.lowerFirst=Ya,Dn.lt=fa,Dn.lte=pa,Dn.max=function(t){return t&&t.length?hr(t,ou,xr):o},Dn.maxBy=function(t,e){return t&&t.length?hr(t,ai(e,2),xr):o},Dn.mean=function(t){return Ne(t,ou)},Dn.meanBy=function(t,e){return Ne(t,ai(e,2))},Dn.min=function(t){return t&&t.length?hr(t,ou,Nr):o},Dn.minBy=function(t,e){return t&&t.length?hr(t,ai(e,2),Nr):o},Dn.stubArray=yu,Dn.stubFalse=vu,Dn.stubObject=function(){return{}},Dn.stubString=function(){return""},Dn.stubTrue=function(){return!0},Dn.multiply=Ou,Dn.nth=function(t,e){return t&&t.length?$r(t,ga(e)):o},Dn.noConflict=function(){return ie._===this&&(ie._=Lt),this},Dn.noop=cu,Dn.now=Is,Dn.pad=function(t,e,n){t=ma(t);var r=(e=ga(e))?on(t):0;if(!e||r>=e)return t;var o=(e-r)/2;return Uo(fn(o),n)+t+Uo(ln(o),n)},Dn.padEnd=function(t,e,n){t=ma(t);var r=(e=ga(e))?on(t):0;return e&&r<e?t+Uo(e-r,n):t},Dn.padStart=function(t,e,n){t=ma(t);var r=(e=ga(e))?on(t):0;return e&&r<e?Uo(e-r,n)+t:t},Dn.parseInt=function(t,e,n){return n||null==e?e=0:e&&(e=+e),bn(ma(t).replace(rt,""),e||0)},Dn.random=function(t,e,n){if(n&&"boolean"!=typeof n&&_i(t,e,n)&&(e=n=o),n===o&&("boolean"==typeof e?(n=e,e=o):"boolean"==typeof t&&(n=t,t=o)),t===o&&e===o?(t=0,e=1):(t=ha(t),e===o?(e=t,t=0):e=ha(e)),t>e){var r=t;t=e,e=r}if(n||t%1||e%1){var i=wn();return _n(t+i*(e-t+ee("1e-"+((i+"").length-1))),e)}return Kr(t,e)},Dn.reduce=function(t,e,n){var r=zs(t)?Ie:De,o=arguments.length<3;return r(t,ai(e,4),n,o,fr)},Dn.reduceRight=function(t,e,n){var r=zs(t)?Te:De,o=arguments.length<3;return r(t,ai(e,4),n,o,pr)},Dn.repeat=function(t,e,n){return e=(n?_i(t,e,n):e===o)?1:ga(e),Yr(ma(t),e)},Dn.replace=function(){var t=arguments,e=ma(t[0]);return t.length<3?e:e.replace(t[1],t[2])},Dn.result=function(t,e,n){var r=-1,i=(e=_o(e,t)).length;for(i||(i=1,t=o);++r<i;){var s=null==t?o:t[Li(e[r])];s===o&&(r=i,s=n),t=Qs(s)?s.call(t):s}return t},Dn.round=Eu,Dn.runInContext=t,Dn.sample=function(t){return(zs(t)?Hn:Jr)(t)},Dn.size=function(t){if(null==t)return 0;if(Ys(t))return ua(t)?on(t):t.length;var e=di(t);return e==C||e==I?t.size:kr(t).length},Dn.snakeCase=qa,Dn.some=function(t,e,n){var r=zs(t)?Re:no;return n&&_i(t,e,n)&&(e=o),r(t,ai(e,3))},Dn.sortedIndex=function(t,e){return ro(t,e)},Dn.sortedIndexBy=function(t,e,n){return oo(t,e,ai(n,2))},Dn.sortedIndexOf=function(t,e){var n=null==t?0:t.length;if(n){var r=ro(t,e);if(r<n&&$s(t[r],e))return r}return-1},Dn.sortedLastIndex=function(t,e){return ro(t,e,!0)},Dn.sortedLastIndexBy=function(t,e,n){return oo(t,e,ai(n,2),!0)},Dn.sortedLastIndexOf=function(t,e){if(null!=t&&t.length){var n=ro(t,e,!0)-1;if($s(t[n],e))return n}return-1},Dn.startCase=Ja,Dn.startsWith=function(t,e,n){return t=ma(t),n=null==n?0:sr(ga(n),0,t.length),e=ao(e),t.slice(n,n+e.length)==e},Dn.subtract=xu,Dn.sum=function(t){return t&&t.length?Ve(t,ou):0},Dn.sumBy=function(t,e){return t&&t.length?Ve(t,ai(e,2)):0},Dn.template=function(t,e,n){var r=Dn.templateSettings;n&&_i(t,e,n)&&(e=o),t=ma(t),e=Ca({},e,r,Zo);var i,s,a=Ca({},e.imports,r.imports,Zo),u=ja(a),c=We(a,u),l=0,f=e.interpolate||mt,p="__p += '",d=xt((e.escape||mt).source+"|"+f.source+"|"+(f===Z?ft:mt).source+"|"+(e.evaluate||mt).source+"|$","g"),h="//# sourceURL="+(Ft.call(e,"sourceURL")?(e.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Zt+"]")+"\n";t.replace(d,(function(e,n,r,o,a,u){return r||(r=o),p+=t.slice(l,u).replace(bt,Ze),n&&(i=!0,p+="' +\n__e("+n+") +\n'"),a&&(s=!0,p+="';\n"+a+";\n__p += '"),r&&(p+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=u+e.length,e})),p+="';\n";var g=Ft.call(e,"variable")&&e.variable;if(g){if(ct.test(g))throw new wt("Invalid `variable` option passed into `_.template`")}else p="with (obj) {\n"+p+"\n}\n";p=(s?p.replace(G,""):p).replace(U,"$1").replace(W,"$1;"),p="function("+(g||"obj")+") {\n"+(g?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(i?", __e = _.escape":"")+(s?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+p+"return __p\n}";var y=Xa((function(){return Ct(u,h+"return "+p).apply(o,c)}));if(y.source=p,Zs(y))throw y;return y},Dn.times=function(t,e){if((t=ga(t))<1||t>f)return[];var n=d,r=_n(t,d);e=ai(e),t-=d;for(var o=$e(r,e);++n<t;)e(n);return o},Dn.toFinite=ha,Dn.toInteger=ga,Dn.toLength=ya,Dn.toLower=function(t){return ma(t).toLowerCase()},Dn.toNumber=va,Dn.toSafeInteger=function(t){return t?sr(ga(t),-9007199254740991,f):0===t?t:0},Dn.toString=ma,Dn.toUpper=function(t){return ma(t).toUpperCase()},Dn.trim=function(t,e,n){if((t=ma(t))&&(n||e===o))return Ge(t);if(!t||!(e=ao(e)))return t;var r=sn(t),i=sn(e);return bo(r,Ke(r,i),Ye(r,i)+1).join("")},Dn.trimEnd=function(t,e,n){if((t=ma(t))&&(n||e===o))return t.slice(0,an(t)+1);if(!t||!(e=ao(e)))return t;var r=sn(t);return bo(r,0,Ye(r,sn(e))+1).join("")},Dn.trimStart=function(t,e,n){if((t=ma(t))&&(n||e===o))return t.replace(rt,"");if(!t||!(e=ao(e)))return t;var r=sn(t);return bo(r,Ke(r,sn(e))).join("")},Dn.truncate=function(t,e){var n=30,r="...";if(ea(e)){var i="separator"in e?e.separator:i;n="length"in e?ga(e.length):n,r="omission"in e?ao(e.omission):r}var s=(t=ma(t)).length;if(Qe(t)){var a=sn(t);s=a.length}if(n>=s)return t;var u=n-on(r);if(u<1)return r;var c=a?bo(a,0,u).join(""):t.slice(0,u);if(i===o)return c+r;if(a&&(u+=c.length-u),sa(i)){if(t.slice(u).search(i)){var l,f=c;for(i.global||(i=xt(i.source,ma(pt.exec(i))+"g")),i.lastIndex=0;l=i.exec(f);)var p=l.index;c=c.slice(0,p===o?u:p)}}else if(t.indexOf(ao(i),u)!=u){var d=c.lastIndexOf(i);d>-1&&(c=c.slice(0,d))}return c+r},Dn.unescape=function(t){return(t=ma(t))&&Y.test(t)?t.replace(z,un):t},Dn.uniqueId=function(t){var e=++Mt;return ma(t)+e},Dn.upperCase=Ha,Dn.upperFirst=Za,Dn.each=ms,Dn.eachRight=bs,Dn.first=Yi,uu(Dn,(_u={},mr(Dn,(function(t,e){Ft.call(Dn.prototype,e)||(_u[e]=t)})),_u),{chain:!1}),Dn.VERSION="4.17.21",me(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){Dn[t].placeholder=Dn})),me(["drop","take"],(function(t,e){Un.prototype[t]=function(n){n=n===o?1:vn(ga(n),0);var r=this.__filtered__&&!e?new Un(this):this.clone();return r.__filtered__?r.__takeCount__=_n(n,r.__takeCount__):r.__views__.push({size:_n(n,d),type:t+(r.__dir__<0?"Right":"")}),r},Un.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),me(["filter","map","takeWhile"],(function(t,e){var n=e+1,r=1==n||3==n;Un.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:ai(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}})),me(["head","last"],(function(t,e){var n="take"+(e?"Right":"");Un.prototype[t]=function(){return this[n](1).value()[0]}})),me(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");Un.prototype[t]=function(){return this.__filtered__?new Un(this):this[n](1)}})),Un.prototype.compact=function(){return this.filter(ou)},Un.prototype.find=function(t){return this.filter(t).head()},Un.prototype.findLast=function(t){return this.reverse().find(t)},Un.prototype.invokeMap=qr((function(t,e){return"function"==typeof t?new Un(this):this.map((function(n){return Rr(n,t,e)}))})),Un.prototype.reject=function(t){return this.filter(Ns(ai(t)))},Un.prototype.slice=function(t,e){t=ga(t);var n=this;return n.__filtered__&&(t>0||e<0)?new Un(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==o&&(n=(e=ga(e))<0?n.dropRight(-e):n.take(e-t)),n)},Un.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},Un.prototype.toArray=function(){return this.take(d)},mr(Un.prototype,(function(t,e){var n=/^(?:filter|find|map|reject)|While$/.test(e),r=/^(?:head|last)$/.test(e),i=Dn[r?"take"+("last"==e?"Right":""):e],s=r||/^find/.test(e);i&&(Dn.prototype[e]=function(){var e=this.__wrapped__,a=r?[1]:arguments,u=e instanceof Un,c=a[0],l=u||zs(e),f=function(t){var e=i.apply(Dn,Se([t],a));return r&&p?e[0]:e};l&&n&&"function"==typeof c&&1!=c.length&&(u=l=!1);var p=this.__chain__,d=!!this.__actions__.length,h=s&&!p,g=u&&!d;if(!s&&l){e=g?e:new Un(this);var y=t.apply(e,a);return y.__actions__.push({func:hs,args:[f],thisArg:o}),new Gn(y,p)}return h&&g?t.apply(this,a):(y=this.thru(f),h?r?y.value()[0]:y.value():y)})})),me(["pop","push","shift","sort","splice","unshift"],(function(t){var e=Tt[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);Dn.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var o=this.value();return e.apply(zs(o)?o:[],t)}return this[n]((function(n){return e.apply(zs(n)?n:[],t)}))}})),mr(Un.prototype,(function(t,e){var n=Dn[e];if(n){var r=n.name+"";Ft.call(Pn,r)||(Pn[r]=[]),Pn[r].push({name:e,func:n})}})),Pn[Do(o,2).name]=[{name:"wrapper",func:o}],Un.prototype.clone=function(){var t=new Un(this.__wrapped__);return t.__actions__=To(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=To(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=To(this.__views__),t},Un.prototype.reverse=function(){if(this.__filtered__){var t=new Un(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},Un.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=zs(t),r=e<0,o=n?t.length:0,i=function(t,e,n){for(var r=-1,o=n.length;++r<o;){var i=n[r],s=i.size;switch(i.type){case"drop":t+=s;break;case"dropRight":e-=s;break;case"take":e=_n(e,t+s);break;case"takeRight":t=vn(t,e-s)}}return{start:t,end:e}}(0,o,this.__views__),s=i.start,a=i.end,u=a-s,c=r?a:s-1,l=this.__iteratees__,f=l.length,p=0,d=_n(u,this.__takeCount__);if(!n||!r&&o==u&&d==u)return po(t,this.__actions__);var h=[];t:for(;u--&&p<d;){for(var g=-1,y=t[c+=e];++g<f;){var v=l[g],_=v.iteratee,m=v.type,b=_(y);if(2==m)y=b;else if(!b){if(1==m)continue t;break t}}h[p++]=y}return h},Dn.prototype.at=gs,Dn.prototype.chain=function(){return ds(this)},Dn.prototype.commit=function(){return new Gn(this.value(),this.__chain__)},Dn.prototype.next=function(){this.__values__===o&&(this.__values__=da(this.value()));var t=this.__index__>=this.__values__.length;return{done:t,value:t?o:this.__values__[this.__index__++]}},Dn.prototype.plant=function(t){for(var e,n=this;n instanceof $n;){var r=Vi(n);r.__index__=0,r.__values__=o,e?i.__wrapped__=r:e=r;var i=r;n=n.__wrapped__}return i.__wrapped__=t,e},Dn.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof Un){var e=t;return this.__actions__.length&&(e=new Un(this)),(e=e.reverse()).__actions__.push({func:hs,args:[es],thisArg:o}),new Gn(e,this.__chain__)}return this.thru(es)},Dn.prototype.toJSON=Dn.prototype.valueOf=Dn.prototype.value=function(){return po(this.__wrapped__,this.__actions__)},Dn.prototype.first=Dn.prototype.head,se&&(Dn.prototype[se]=function(){return this}),Dn}();ie._=cn,(r=function(){return cn}.call(e,n,e,t))===o||(t.exports=r)}.call(this)},5984:t=>{var e=1e3,n=60*e,r=60*n,o=24*r;function i(t,e,n,r){var o=e>=1.5*n;return Math.round(t/n)+" "+r+(o?"s":"")}t.exports=function(t,s){s=s||{};var a,u,c=typeof t;if("string"===c&&t.length>0)return function(t){if(!((t=String(t)).length>100)){var i=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(i){var s=parseFloat(i[1]);switch((i[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"weeks":case"week":case"w":return 6048e5*s;case"days":case"day":case"d":return s*o;case"hours":case"hour":case"hrs":case"hr":case"h":return s*r;case"minutes":case"minute":case"mins":case"min":case"m":return s*n;case"seconds":case"second":case"secs":case"sec":case"s":return s*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}}}(t);if("number"===c&&isFinite(t))return s.long?(a=t,(u=Math.abs(a))>=o?i(a,u,o,"day"):u>=r?i(a,u,r,"hour"):u>=n?i(a,u,n,"minute"):u>=e?i(a,u,e,"second"):a+" ms"):function(t){var i=Math.abs(t);return i>=o?Math.round(t/o)+"d":i>=r?Math.round(t/r)+"h":i>=n?Math.round(t/n)+"m":i>=e?Math.round(t/e)+"s":t+"ms"}(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))}},9248:()=>{var t;!function(t){!function(e){var n="object"==typeof global?global:"object"==typeof self?self:"object"==typeof this?this:Function("return this;")(),r=o(t);function o(t,e){return function(n,r){"function"!=typeof t[n]&&Object.defineProperty(t,n,{configurable:!0,writable:!0,value:r}),e&&e(n,r)}}void 0===n.Reflect?n.Reflect=t:r=o(n.Reflect,r),function(t){var e=Object.prototype.hasOwnProperty,n="function"==typeof Symbol,r=n&&void 0!==Symbol.toPrimitive?Symbol.toPrimitive:"@@toPrimitive",o=n&&void 0!==Symbol.iterator?Symbol.iterator:"@@iterator",i="function"==typeof Object.create,s={__proto__:[]}instanceof Array,a=!i&&!s,u={create:i?function(){return k(Object.create(null))}:s?function(){return k({__proto__:null})}:function(){return k({})},has:a?function(t,n){return e.call(t,n)}:function(t,e){return e in t},get:a?function(t,n){return e.call(t,n)?t[n]:void 0}:function(t,e){return t[e]}},c=Object.getPrototypeOf(Function),l="object"==typeof process&&process.env&&"true"===process.env.REFLECT_METADATA_USE_MAP_POLYFILL,f=l||"function"!=typeof Map||"function"!=typeof Map.prototype.entries?function(){var t={},e=[],n=function(){function t(t,e,n){this._index=0,this._keys=t,this._values=e,this._selector=n}return t.prototype["@@iterator"]=function(){return this},t.prototype[o]=function(){return this},t.prototype.next=function(){var t=this._index;if(t>=0&&t<this._keys.length){var n=this._selector(this._keys[t],this._values[t]);return t+1>=this._keys.length?(this._index=-1,this._keys=e,this._values=e):this._index++,{value:n,done:!1}}return{value:void 0,done:!0}},t.prototype.throw=function(t){throw this._index>=0&&(this._index=-1,this._keys=e,this._values=e),t},t.prototype.return=function(t){return this._index>=0&&(this._index=-1,this._keys=e,this._values=e),{value:t,done:!0}},t}();return function(){function e(){this._keys=[],this._values=[],this._cacheKey=t,this._cacheIndex=-2}return Object.defineProperty(e.prototype,"size",{get:function(){return this._keys.length},enumerable:!0,configurable:!0}),e.prototype.has=function(t){return this._find(t,!1)>=0},e.prototype.get=function(t){var e=this._find(t,!1);return e>=0?this._values[e]:void 0},e.prototype.set=function(t,e){var n=this._find(t,!0);return this._values[n]=e,this},e.prototype.delete=function(e){var n=this._find(e,!1);if(n>=0){for(var r=this._keys.length,o=n+1;o<r;o++)this._keys[o-1]=this._keys[o],this._values[o-1]=this._values[o];return this._keys.length--,this._values.length--,e===this._cacheKey&&(this._cacheKey=t,this._cacheIndex=-2),!0}return!1},e.prototype.clear=function(){this._keys.length=0,this._values.length=0,this._cacheKey=t,this._cacheIndex=-2},e.prototype.keys=function(){return new n(this._keys,this._values,r)},e.prototype.values=function(){return new n(this._keys,this._values,i)},e.prototype.entries=function(){return new n(this._keys,this._values,s)},e.prototype["@@iterator"]=function(){return this.entries()},e.prototype[o]=function(){return this.entries()},e.prototype._find=function(t,e){return this._cacheKey!==t&&(this._cacheIndex=this._keys.indexOf(this._cacheKey=t)),this._cacheIndex<0&&e&&(this._cacheIndex=this._keys.length,this._keys.push(t),this._values.push(void 0)),this._cacheIndex},e}();function r(t,e){return t}function i(t,e){return e}function s(t,e){return[t,e]}}():Map,p=l||"function"!=typeof Set||"function"!=typeof Set.prototype.entries?function(){function t(){this._map=new f}return Object.defineProperty(t.prototype,"size",{get:function(){return this._map.size},enumerable:!0,configurable:!0}),t.prototype.has=function(t){return this._map.has(t)},t.prototype.add=function(t){return this._map.set(t,t),this},t.prototype.delete=function(t){return this._map.delete(t)},t.prototype.clear=function(){this._map.clear()},t.prototype.keys=function(){return this._map.keys()},t.prototype.values=function(){return this._map.values()},t.prototype.entries=function(){return this._map.entries()},t.prototype["@@iterator"]=function(){return this.keys()},t.prototype[o]=function(){return this.keys()},t}():Set,d=new(l||"function"!=typeof WeakMap?function(){var t=u.create(),n=r();return function(){function t(){this._key=r()}return t.prototype.has=function(t){var e=o(t,!1);return void 0!==e&&u.has(e,this._key)},t.prototype.get=function(t){var e=o(t,!1);return void 0!==e?u.get(e,this._key):void 0},t.prototype.set=function(t,e){return o(t,!0)[this._key]=e,this},t.prototype.delete=function(t){var e=o(t,!1);return void 0!==e&&delete e[this._key]},t.prototype.clear=function(){this._key=r()},t}();function r(){var e;do{e="@@WeakMap@@"+s()}while(u.has(t,e));return t[e]=!0,e}function o(t,r){if(!e.call(t,n)){if(!r)return;Object.defineProperty(t,n,{value:u.create()})}return t[n]}function i(t,e){for(var n=0;n<e;++n)t[n]=255*Math.random()|0;return t}function s(){var t,e=(t=16,"function"==typeof Uint8Array?"undefined"!=typeof crypto?crypto.getRandomValues(new Uint8Array(t)):"undefined"!=typeof msCrypto?msCrypto.getRandomValues(new Uint8Array(t)):i(new Uint8Array(t),t):i(new Array(t),t));e[6]=79&e[6]|64,e[8]=191&e[8]|128;for(var n="",r=0;r<16;++r){var o=e[r];4!==r&&6!==r&&8!==r||(n+="-"),o<16&&(n+="0"),n+=o.toString(16).toLowerCase()}return n}}():WeakMap);function h(t,e,n){var r=d.get(t);if(O(r)){if(!n)return;r=new f,d.set(t,r)}var o=r.get(e);if(O(o)){if(!n)return;o=new f,r.set(e,o)}return o}function g(t,e,n){if(y(t,e,n))return!0;var r=M(e);return!E(r)&&g(t,r,n)}function y(t,e,n){var r=h(e,n,!1);return!O(r)&&!!r.has(t)}function v(t,e,n){if(y(t,e,n))return _(t,e,n);var r=M(e);return E(r)?void 0:v(t,r,n)}function _(t,e,n){var r=h(e,n,!1);if(!O(r))return r.get(t)}function m(t,e,n,r){h(n,r,!0).set(t,e)}function b(t,e){var n=w(t,e),r=M(t);if(null===r)return n;var o=b(r,e);if(o.length<=0)return n;if(n.length<=0)return o;for(var i=new p,s=[],a=0,u=n;a<u.length;a++){var c=u[a];i.has(c)||(i.add(c),s.push(c))}for(var l=0,f=o;l<f.length;l++)c=f[l],i.has(c)||(i.add(c),s.push(c));return s}function w(t,e){var n=[],r=h(t,e,!1);if(O(r))return n;for(var i=function(t){var e=A(t,o);if(!R(e))throw new TypeError;var n=e.call(t);if(!x(n))throw new TypeError;return n}(r.keys()),s=0;;){var a=j(i);if(!a)return n.length=s,n;var u=a.value;try{n[s]=u}catch(t){try{F(i)}finally{throw t}}s++}}function C(t){if(null===t)return 1;switch(typeof t){case"undefined":return 0;case"boolean":return 2;case"string":return 3;case"symbol":return 4;case"number":return 5;case"object":return null===t?1:6;default:return 6}}function O(t){return void 0===t}function E(t){return null===t}function x(t){return"object"==typeof t?null!==t:"function"==typeof t}function S(t,e){switch(C(t)){case 0:case 1:case 2:case 3:case 4:case 5:return t}var n=3===e?"string":5===e?"number":"default",o=A(t,r);if(void 0!==o){var i=o.call(t,n);if(x(i))throw new TypeError;return i}return function(t,e){if("string"===e){var n=t.toString;if(R(n)&&!x(o=n.call(t)))return o;if(R(r=t.valueOf)&&!x(o=r.call(t)))return o}else{var r;if(R(r=t.valueOf)&&!x(o=r.call(t)))return o;var o,i=t.toString;if(R(i)&&!x(o=i.call(t)))return o}throw new TypeError}(t,"default"===n?"number":n)}function I(t){var e=S(t,3);return"symbol"==typeof e?e:function(t){return""+t}(e)}function T(t){return Array.isArray?Array.isArray(t):t instanceof Object?t instanceof Array:"[object Array]"===Object.prototype.toString.call(t)}function R(t){return"function"==typeof t}function P(t){return"function"==typeof t}function A(t,e){var n=t[e];if(null!=n){if(!R(n))throw new TypeError;return n}}function j(t){var e=t.next();return!e.done&&e}function F(t){var e=t.return;e&&e.call(t)}function M(t){var e=Object.getPrototypeOf(t);if("function"!=typeof t||t===c)return e;if(e!==c)return e;var n=t.prototype,r=n&&Object.getPrototypeOf(n);if(null==r||r===Object.prototype)return e;var o=r.constructor;return"function"!=typeof o||o===t?e:o}function k(t){return t.__=void 0,delete t.__,t}t("decorate",(function(t,e,n,r){if(O(n)){if(!T(t))throw new TypeError;if(!P(e))throw new TypeError;return function(t,e){for(var n=t.length-1;n>=0;--n){var r=(0,t[n])(e);if(!O(r)&&!E(r)){if(!P(r))throw new TypeError;e=r}}return e}(t,e)}if(!T(t))throw new TypeError;if(!x(e))throw new TypeError;if(!x(r)&&!O(r)&&!E(r))throw new TypeError;return E(r)&&(r=void 0),function(t,e,n,r){for(var o=t.length-1;o>=0;--o){var i=(0,t[o])(e,n,r);if(!O(i)&&!E(i)){if(!x(i))throw new TypeError;r=i}}return r}(t,e,n=I(n),r)})),t("metadata",(function(t,e){return function(n,r){if(!x(n))throw new TypeError;if(!O(r)&&!function(t){switch(C(t)){case 3:case 4:return!0;default:return!1}}(r))throw new TypeError;m(t,e,n,r)}})),t("defineMetadata",(function(t,e,n,r){if(!x(n))throw new TypeError;return O(r)||(r=I(r)),m(t,e,n,r)})),t("hasMetadata",(function(t,e,n){if(!x(e))throw new TypeError;return O(n)||(n=I(n)),g(t,e,n)})),t("hasOwnMetadata",(function(t,e,n){if(!x(e))throw new TypeError;return O(n)||(n=I(n)),y(t,e,n)})),t("getMetadata",(function(t,e,n){if(!x(e))throw new TypeError;return O(n)||(n=I(n)),v(t,e,n)})),t("getOwnMetadata",(function(t,e,n){if(!x(e))throw new TypeError;return O(n)||(n=I(n)),_(t,e,n)})),t("getMetadataKeys",(function(t,e){if(!x(t))throw new TypeError;return O(e)||(e=I(e)),b(t,e)})),t("getOwnMetadataKeys",(function(t,e){if(!x(t))throw new TypeError;return O(e)||(e=I(e)),w(t,e)})),t("deleteMetadata",(function(t,e,n){if(!x(e))throw new TypeError;O(n)||(n=I(n));var r=h(e,n,!1);if(O(r))return!1;if(!r.delete(t))return!1;if(r.size>0)return!0;var o=d.get(e);return o.delete(n),o.size>0||d.delete(e),!0}))}(r)}()}(t||(t={}))},2595:(t,e,n)=>{"use strict";n.r(e),n.d(e,{__extends:()=>o,__assign:()=>i,__rest:()=>s,__decorate:()=>a,__param:()=>u,__metadata:()=>c,__awaiter:()=>l,__generator:()=>f,__createBinding:()=>p,__exportStar:()=>d,__values:()=>h,__read:()=>g,__spread:()=>y,__spreadArrays:()=>v,__spreadArray:()=>_,__await:()=>m,__asyncGenerator:()=>b,__asyncDelegator:()=>w,__asyncValues:()=>C,__makeTemplateObject:()=>O,__importStar:()=>x,__importDefault:()=>S,__classPrivateFieldGet:()=>I,__classPrivateFieldSet:()=>T});var r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var i=function(){return(i=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};function s(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]])}return n}function a(t,e,n,r){var o,i=arguments.length,s=i<3?e:null===r?r=Object.getOwnPropertyDescriptor(e,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,r);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(i<3?o(s):i>3?o(e,n,s):o(e,n))||s);return i>3&&s&&Object.defineProperty(e,n,s),s}function u(t,e){return function(n,r){e(n,r,t)}}function c(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function l(t,e,n,r){return new(n||(n=Promise))((function(o,i){function s(t){try{u(r.next(t))}catch(t){i(t)}}function a(t){try{u(r.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(s,a)}u((r=r.apply(t,e||[])).next())}))}function f(t,e){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!((o=(o=s.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=e.call(t,s)}catch(t){i=[6,t],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}}var p=Object.create?function(t,e,n,r){void 0===r&&(r=n),Object.defineProperty(t,r,{enumerable:!0,get:function(){return e[n]}})}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]};function d(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||p(e,t,n)}function h(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function g(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),s=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)s.push(r.value)}catch(t){o={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return s}function y(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(g(arguments[e]));return t}function v(){for(var t=0,e=0,n=arguments.length;e<n;e++)t+=arguments[e].length;var r=Array(t),o=0;for(e=0;e<n;e++)for(var i=arguments[e],s=0,a=i.length;s<a;s++,o++)r[o]=i[s];return r}function _(t,e,n){if(n||2===arguments.length)for(var r,o=0,i=e.length;o<i;o++)!r&&o in e||(r||(r=Array.prototype.slice.call(e,0,o)),r[o]=e[o]);return t.concat(r||Array.prototype.slice.call(e))}function m(t){return this instanceof m?(this.v=t,this):new m(t)}function b(t,e,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,o=n.apply(t,e||[]),i=[];return r={},s("next"),s("throw"),s("return"),r[Symbol.asyncIterator]=function(){return this},r;function s(t){o[t]&&(r[t]=function(e){return new Promise((function(n,r){i.push([t,e,n,r])>1||a(t,e)}))})}function a(t,e){try{(n=o[t](e)).value instanceof m?Promise.resolve(n.value.v).then(u,c):l(i[0][2],n)}catch(t){l(i[0][3],t)}var n}function u(t){a("next",t)}function c(t){a("throw",t)}function l(t,e){t(e),i.shift(),i.length&&a(i[0][0],i[0][1])}}function w(t){var e,n;return e={},r("next"),r("throw",(function(t){throw t})),r("return"),e[Symbol.iterator]=function(){return this},e;function r(r,o){e[r]=t[r]?function(e){return(n=!n)?{value:m(t[r](e)),done:"return"===r}:o?o(e):e}:o}}function C(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=h(t),e={},r("next"),r("throw"),r("return"),e[Symbol.asyncIterator]=function(){return this},e);function r(n){e[n]=t[n]&&function(e){return new Promise((function(r,o){!function(t,e,n,r){Promise.resolve(r).then((function(e){t({value:e,done:n})}),e)}(r,o,(e=t[n](e)).done,e.value)}))}}}function O(t,e){return Object.defineProperty?Object.defineProperty(t,"raw",{value:e}):t.raw=e,t}var E=Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e};function x(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&p(e,t,n);return E(e,t),e}function S(t){return t&&t.__esModule?t:{default:t}}function I(t,e,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!r:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(t):r?r.value:e.get(t)}function T(t,e,n,r,o){if("m"===r)throw new TypeError("Private method is not writable");if("a"===r&&!o)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!o:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===r?o.call(t,n):o?o.value=n:e.set(t,n),n}},9491:t=>{"use strict";t.exports=require("assert")},4300:t=>{"use strict";t.exports=require("buffer")},6113:t=>{"use strict";t.exports=require("crypto")},2361:t=>{"use strict";t.exports=require("events")},2037:t=>{"use strict";t.exports=require("os")},6224:t=>{"use strict";t.exports=require("tty")},3837:t=>{"use strict";t.exports=require("util")}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={id:r,loaded:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}return n.c=e,n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.nmd=t=>(t.paths=[],t.children||(t.children=[]),t),n(n.s=5590)})()}));
@@ -0,0 +1,38 @@
1
+ /*! *****************************************************************************
2
+ Copyright (C) Microsoft. All rights reserved.
3
+ Licensed under the Apache License, Version 2.0 (the "License"); you may not use
4
+ this file except in compliance with the License. You may obtain a copy of the
5
+ License at http://www.apache.org/licenses/LICENSE-2.0
6
+
7
+ THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
8
+ KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
9
+ WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
10
+ MERCHANTABLITY OR NON-INFRINGEMENT.
11
+
12
+ See the Apache Version 2.0 License for specific language governing permissions
13
+ and limitations under the License.
14
+ ***************************************************************************** */
15
+
16
+ /*! *****************************************************************************
17
+ Copyright (c) Microsoft Corporation.
18
+
19
+ Permission to use, copy, modify, and/or distribute this software for any
20
+ purpose with or without fee is hereby granted.
21
+
22
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
23
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
24
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
25
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
26
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
27
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
28
+ PERFORMANCE OF THIS SOFTWARE.
29
+ ***************************************************************************** */
30
+
31
+ /**
32
+ * @license
33
+ * Lodash <https://lodash.com/>
34
+ * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
35
+ * Released under MIT license <https://lodash.com/license>
36
+ * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
37
+ * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
38
+ */