From 8d5ce96538afd5b3e0865faedd677498b2cae23c Mon Sep 17 00:00:00 2001 From: "Stephane Lacoin (aka nxmatic)" Date: Tue, 5 Mar 2024 01:39:56 +0100 Subject: [PATCH] WIP introduced content script, still can't use chrome tabs API * better construction of components * bootstrap service worker using content script --- .babelrc | 5 +- .eslintrc | 6 +- package.json | 11 +- pnpm-lock.yaml | 962 +++++++++++---------- src/about/index.js | 39 +- src/content-bridge.js | 49 ++ src/content/index.html | 1 - src/content/index.js | 0 src/content/main.js | 179 ++++ src/main/browser-store.js | 2 - src/main/chrome-notifier.js | 24 +- src/main/connect-locator.js | 14 +- src/main/designer-live-preview.js | 168 ++-- src/main/frontend-message-handler.js | 45 - src/main/main-chrome.js | 228 +---- src/main/manifest-chrome.json | 6 + src/main/repository-indexer.js | 82 +- src/main/server-connector.js | 66 +- src/main/service-worker-message-handler.js | 63 ++ src/main/service-worker.js | 131 +++ src/main/studio-hot-reloader.js | 303 +++---- src/popup/index.js | 89 +- src/service-worker-bridge.js | 68 +- src/tabs-creator.js | 6 +- vite.config.js | 8 +- 25 files changed, 1370 insertions(+), 1185 deletions(-) create mode 100644 src/content-bridge.js delete mode 100644 src/content/index.html delete mode 100644 src/content/index.js create mode 100644 src/content/main.js delete mode 100644 src/main/frontend-message-handler.js create mode 100644 src/main/service-worker-message-handler.js create mode 100644 src/main/service-worker.js diff --git a/.babelrc b/.babelrc index 1320b9a3..fb4113cc 100644 --- a/.babelrc +++ b/.babelrc @@ -1,3 +1,6 @@ { - "presets": ["@babel/preset-env"] + "presets": ["@babel/preset-env"], + "plugins": [ + ["@babel/plugin-proposal-decorators", { "legacy": true }] + ] } diff --git a/.eslintrc b/.eslintrc index bd2eed43..fd4dc82a 100644 --- a/.eslintrc +++ b/.eslintrc @@ -1,6 +1,10 @@ { + "parser": "@babel/eslint-parser", "parserOptions": { - "ecmaVersion": 6 + "ecmaVersion": 2022, + "ecmaFeatures": { + "legacyDecorators": true + } }, "extends": [ "eslint:recommended", diff --git a/package.json b/package.json index fb6ee07c..7c1d81fc 100644 --- a/package.json +++ b/package.json @@ -3,23 +3,26 @@ "bootstrap": "^5.3.3", "chai": "^5.1.0", "dompurify": "^3.0.9", + "fs-extra": "^11.2.0", "highlight": "^0.2.4", + "inversify": "^6.0.2", "jquery": "^3.7.1", "jquery-confirm": "^3.3.4", "nuxeo": "^4.0.3", + "reflect-metadata": "^0.2.1", + "rimraf": "^5.0.5", + "rollup-plugin-copy": "^3.5.0", "webextension-polyfill": "^0.10.0" }, "devDependencies": { "@babel/eslint-parser": "^7.23.10", - "@babel/preset-env": "^7.23.9", + "@babel/plugin-proposal-decorators": "^7.24.0", + "@babel/preset-env": "^7.24.0", "concurrently": "^8.2.2", "cross-env": "^7.0.3", "eslint-config-airbnb-base": "^14.2.1", "eslint-plugin-import": "^2.29.1", - "fs-extra": "^11.2.0", "npm-run-all": "^4.1.5", - "rimraf": "^5.0.5", - "rollup-plugin-copy": "^3.5.0", "rollup-plugin-rename": "^1.0.1", "run-sequence": "^2.2.1", "vite": "^5.1.4", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index fddccfe4..5f90231b 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -17,6 +17,9 @@ dependencies: highlight: specifier: ^0.2.4 version: 0.2.4 + inversify: + specifier: ^6.0.2 + version: 6.0.2 jquery: specifier: ^3.7.1 version: 3.7.1 @@ -26,6 +29,9 @@ dependencies: nuxeo: specifier: ^4.0.3 version: 4.0.3 + reflect-metadata: + specifier: ^0.2.1 + version: 0.2.1 webextension-polyfill: specifier: ^0.10.0 version: 0.10.0 @@ -33,10 +39,13 @@ dependencies: devDependencies: '@babel/eslint-parser': specifier: ^7.23.10 - version: 7.23.10(@babel/core@7.23.9)(eslint@7.32.0) + version: 7.23.10(@babel/core@7.24.0)(eslint@7.32.0) + '@babel/plugin-proposal-decorators': + specifier: ^7.24.0 + version: 7.24.0(@babel/core@7.24.0) '@babel/preset-env': - specifier: ^7.23.9 - version: 7.23.9(@babel/core@7.23.9) + specifier: ^7.24.0 + version: 7.24.0(@babel/core@7.24.0) concurrently: specifier: ^8.2.2 version: 8.2.2 @@ -81,12 +90,12 @@ packages: engines: {node: '>=0.10.0'} dev: true - /@ampproject/remapping@2.2.1: - resolution: {integrity: sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg==} + /@ampproject/remapping@2.3.0: + resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==} engines: {node: '>=6.0.0'} dependencies: - '@jridgewell/gen-mapping': 0.3.3 - '@jridgewell/trace-mapping': 0.3.22 + '@jridgewell/gen-mapping': 0.3.5 + '@jridgewell/trace-mapping': 0.3.25 dev: true /@babel/code-frame@7.12.11: @@ -108,20 +117,20 @@ packages: engines: {node: '>=6.9.0'} dev: true - /@babel/core@7.23.9: - resolution: {integrity: sha512-5q0175NOjddqpvvzU+kDiSOAk4PfdO6FvwCWoQ6RO7rTzEe8vlo+4HVfcnAREhD4npMs0e9uZypjTwzZPCf/cw==} + /@babel/core@7.24.0: + resolution: {integrity: sha512-fQfkg0Gjkza3nf0c7/w6Xf34BW4YvzNfACRLmmb7XRLa6XHdR+K9AlJlxneFfWYf6uhOzuzZVTjF/8KfndZANw==} engines: {node: '>=6.9.0'} dependencies: - '@ampproject/remapping': 2.2.1 + '@ampproject/remapping': 2.3.0 '@babel/code-frame': 7.23.5 '@babel/generator': 7.23.6 '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helpers': 7.23.9 - '@babel/parser': 7.23.9 - '@babel/template': 7.23.9 - '@babel/traverse': 7.23.9 - '@babel/types': 7.23.9 + '@babel/helper-module-transforms': 7.23.3(@babel/core@7.24.0) + '@babel/helpers': 7.24.0 + '@babel/parser': 7.24.0 + '@babel/template': 7.24.0 + '@babel/traverse': 7.24.0 + '@babel/types': 7.24.0 convert-source-map: 2.0.0 debug: 4.3.4(supports-color@8.1.1) gensync: 1.0.0-beta.2 @@ -131,14 +140,14 @@ packages: - supports-color dev: true - /@babel/eslint-parser@7.23.10(@babel/core@7.23.9)(eslint@7.32.0): + /@babel/eslint-parser@7.23.10(@babel/core@7.24.0)(eslint@7.32.0): resolution: {integrity: sha512-3wSYDPZVnhseRnxRJH6ZVTNknBz76AEnyC+AYYhasjP3Yy23qz0ERR7Fcd2SHmYuSFJ2kY9gaaDd3vyqU09eSw==} engines: {node: ^10.13.0 || ^12.13.0 || >=14.0.0} peerDependencies: '@babel/core': ^7.11.0 eslint: ^7.5.0 || ^8.0.0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@nicolo-ribaudo/eslint-scope-5-internals': 5.1.1-v1 eslint: 7.32.0 eslint-visitor-keys: 2.1.0 @@ -149,9 +158,9 @@ packages: resolution: {integrity: sha512-qrSfCYxYQB5owCmGLbl8XRpX1ytXlpueOb0N0UmQwA073KZxejgQTzAmJezxvpwQD9uGtK2shHdi55QT+MbjIw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 - '@jridgewell/gen-mapping': 0.3.3 - '@jridgewell/trace-mapping': 0.3.22 + '@babel/types': 7.24.0 + '@jridgewell/gen-mapping': 0.3.5 + '@jridgewell/trace-mapping': 0.3.25 jsesc: 2.5.2 dev: true @@ -159,14 +168,14 @@ packages: resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true /@babel/helper-builder-binary-assignment-operator-visitor@7.22.15: resolution: {integrity: sha512-QkBXwGgaoC2GtGZRoma6kv7Szfv06khvhFav67ZExau2RaXzy8MpHSMO2PNoP2XtmQphJQRHFfg77Bq731Yizw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true /@babel/helper-compilation-targets@7.23.6: @@ -180,44 +189,44 @@ packages: semver: 6.3.1 dev: true - /@babel/helper-create-class-features-plugin@7.23.10(@babel/core@7.23.9): - resolution: {integrity: sha512-2XpP2XhkXzgxecPNEEK8Vz8Asj9aRxt08oKOqtiZoqV2UGZ5T+EkyP9sXQ9nwMxBIG34a7jmasVqoMop7VdPUw==} + /@babel/helper-create-class-features-plugin@7.24.0(@babel/core@7.24.0): + resolution: {integrity: sha512-QAH+vfvts51BCsNZ2PhY6HAggnlS6omLLFTsIpeqZk/MmJ6cW7tgz5yRv0fMJThcr6FmbMrENh1RgrWPTYA76g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-function-name': 7.23.0 '@babel/helper-member-expression-to-functions': 7.23.0 '@babel/helper-optimise-call-expression': 7.22.5 - '@babel/helper-replace-supers': 7.22.20(@babel/core@7.23.9) + '@babel/helper-replace-supers': 7.22.20(@babel/core@7.24.0) '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 semver: 6.3.1 dev: true - /@babel/helper-create-regexp-features-plugin@7.22.15(@babel/core@7.23.9): + /@babel/helper-create-regexp-features-plugin@7.22.15(@babel/core@7.24.0): resolution: {integrity: sha512-29FkPLFjn4TPEa3RE7GpW+qbE8tlsu3jntNYNfcGsc49LphF1PQIiD+vMZ1z1xVOKt+93khA9tc2JBs3kBjA7w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-annotate-as-pure': 7.22.5 regexpu-core: 5.3.2 semver: 6.3.1 dev: true - /@babel/helper-define-polyfill-provider@0.5.0(@babel/core@7.23.9): + /@babel/helper-define-polyfill-provider@0.5.0(@babel/core@7.24.0): resolution: {integrity: sha512-NovQquuQLAQ5HuyjCz7WQP9MjRj7dx++yspwiyUiGl9ZyadHRSql1HZh5ogRd8W8w6YM6EQ/NTB8rgjLt5W65Q==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.24.0 debug: 4.3.4(supports-color@8.1.1) lodash.debounce: 4.0.8 resolve: 1.22.8 @@ -234,38 +243,38 @@ packages: resolution: {integrity: sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/template': 7.23.9 - '@babel/types': 7.23.9 + '@babel/template': 7.24.0 + '@babel/types': 7.24.0 dev: true /@babel/helper-hoist-variables@7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true /@babel/helper-member-expression-to-functions@7.23.0: resolution: {integrity: sha512-6gfrPwh7OuT6gZyJZvd6WbTfrqAo7vm4xCzAXOusKqq/vWdKXphTpj5klHKNmRUU6/QRGlBsyU9mAIPaWHlqJA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true /@babel/helper-module-imports@7.22.15: resolution: {integrity: sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true - /@babel/helper-module-transforms@7.23.3(@babel/core@7.23.9): + /@babel/helper-module-transforms@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-7bBs4ED9OmswdfDzpz4MpWgSrV7FXlc3zIagvLFjS5H+Mk7Snr21vQ6QwrsoCGMfNC4e4LQPdoULEt4ykz0SRQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-module-imports': 7.22.15 '@babel/helper-simple-access': 7.22.5 @@ -277,33 +286,33 @@ packages: resolution: {integrity: sha512-HBwaojN0xFRx4yIvpwGqxiV2tUfl7401jlok564NgB9EHS1y6QT17FmKWm4ztqjeVdXLuC4fSvHc5ePpQjoTbw==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true - /@babel/helper-plugin-utils@7.22.5: - resolution: {integrity: sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg==} + /@babel/helper-plugin-utils@7.24.0: + resolution: {integrity: sha512-9cUznXMG0+FxRuJfvL82QlTqIzhVW9sL0KjMPHhAOOvpQGL8QtdxnBKILjBqxlHyliz0yCa1G903ZXI/FuHy2w==} engines: {node: '>=6.9.0'} dev: true - /@babel/helper-remap-async-to-generator@7.22.20(@babel/core@7.23.9): + /@babel/helper-remap-async-to-generator@7.22.20(@babel/core@7.24.0): resolution: {integrity: sha512-pBGyV4uBqOns+0UvhsTO8qgl8hO89PmiDYv+/COyp1aeMcmfrfruz+/nCMFiYyFF/Knn0yfrC85ZzNFjembFTw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-wrap-function': 7.22.20 dev: true - /@babel/helper-replace-supers@7.22.20(@babel/core@7.23.9): + /@babel/helper-replace-supers@7.22.20(@babel/core@7.24.0): resolution: {integrity: sha512-qsW0In3dbwQUbK8kejJ4R7IHVGwHJlV6lpG6UA7a9hSa2YEiAib+N1T2kr6PEeUT+Fl7najmSOS6SmAwCHK6Tw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-member-expression-to-functions': 7.23.0 '@babel/helper-optimise-call-expression': 7.22.5 @@ -313,21 +322,21 @@ packages: resolution: {integrity: sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true /@babel/helper-skip-transparent-expression-wrappers@7.22.5: resolution: {integrity: sha512-tK14r66JZKiC43p8Ki33yLBVJKlQDFoA8GYN67lWCDCqoL6EMMSuM9b+Iff2jHaM/RRFYl7K+iiru7hbRqNx8Q==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true /@babel/helper-split-export-declaration@7.22.6: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true /@babel/helper-string-parser@7.23.4: @@ -350,17 +359,17 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/helper-function-name': 7.23.0 - '@babel/template': 7.23.9 - '@babel/types': 7.23.9 + '@babel/template': 7.24.0 + '@babel/types': 7.24.0 dev: true - /@babel/helpers@7.23.9: - resolution: {integrity: sha512-87ICKgU5t5SzOT7sBMfCOZQ2rHjRU+Pcb9BoILMYz600W6DkVRLFBPwQ18gwUVvggqXivaUakpnxWQGbpywbBQ==} + /@babel/helpers@7.24.0: + resolution: {integrity: sha512-ulDZdc0Aj5uLc5nETsa7EPx2L7rM0YJM8r7ck7U73AXi7qOV44IHHRAYZHY6iU1rr3C5N4NtTmMRUJP6kwCWeA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/template': 7.23.9 - '@babel/traverse': 7.23.9 - '@babel/types': 7.23.9 + '@babel/template': 7.24.0 + '@babel/traverse': 7.24.0 + '@babel/types': 7.24.0 transitivePeerDependencies: - supports-color dev: true @@ -374,856 +383,878 @@ packages: js-tokens: 4.0.0 dev: true - /@babel/parser@7.23.9: - resolution: {integrity: sha512-9tcKgqKbs3xGJ+NtKF2ndOBBLVwPjl1SHxPQkd36r3Dlirw3xWUeGaTbqr7uGZcTaxkVNwc+03SVP7aCdWrTlA==} + /@babel/parser@7.24.0: + resolution: {integrity: sha512-QuP/FxEAzMSjXygs8v4N9dvdXzEHN4W1oF3PxuWAtPo08UdM17u89RDMgjLn/mlc56iM0HlLmVkO/wgR+rDgHg==} engines: {node: '>=6.0.0'} hasBin: true dependencies: - '@babel/types': 7.23.9 + '@babel/types': 7.24.0 dev: true - /@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.23.3(@babel/core@7.23.9): + /@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-iRkKcCqb7iGnq9+3G6rZ+Ciz5VywC4XNRHe57lKM+jOeYAoR0lVqdeeDRfh0tQcTfw/+vBhHn926FmQhLtlFLQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.23.3(@babel/core@7.23.9): + /@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-WwlxbfMNdVEpQjZmK5mhm7oSwD3dS6eU+Iwsi4Knl9wAletWem7kaRsGOG+8UEbRyqxY4SS5zvtfXwX+jMxUwQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.13.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - '@babel/plugin-transform-optional-chaining': 7.23.4(@babel/core@7.23.9) + '@babel/plugin-transform-optional-chaining': 7.23.4(@babel/core@7.24.0) dev: true - /@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@7.23.7(@babel/core@7.23.9): + /@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly@7.23.7(@babel/core@7.24.0): resolution: {integrity: sha512-LlRT7HgaifEpQA1ZgLVOIJZZFVPWN5iReq/7/JixwBtwcoeVGDBD53ZV28rrsLYOZs1Y/EHhA8N/Z6aazHR8cw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2(@babel/core@7.23.9): + /@babel/plugin-proposal-decorators@7.24.0(@babel/core@7.24.0): + resolution: {integrity: sha512-LiT1RqZWeij7X+wGxCoYh3/3b8nVOX6/7BZ9wiQgAIyjoeQWdROaodJCgT+dwtbjHaz0r7bEbHJzjSbVfcOyjQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.24.0 + '@babel/helper-create-class-features-plugin': 7.24.0(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-decorators': 7.24.0(@babel/core@7.24.0) + dev: true + + /@babel/plugin-proposal-private-property-in-object@7.21.0-placeholder-for-preset-env.2(@babel/core@7.24.0): resolution: {integrity: sha512-SOSkfJDddaM7mak6cPEpswyTRnuRltl429hMraQEglW+OkovnCzsiszTmsrlY//qLFjCpQDFRvjdm2wA5pPm9w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 dev: true - /@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.23.9): + /@babel/plugin-syntax-async-generators@7.8.4(@babel/core@7.24.0): resolution: {integrity: sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.23.9): + /@babel/plugin-syntax-class-properties@7.12.13(@babel/core@7.24.0): resolution: {integrity: sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-class-static-block@7.14.5(@babel/core@7.23.9): + /@babel/plugin-syntax-class-static-block@7.14.5(@babel/core@7.24.0): resolution: {integrity: sha512-b+YyPmr6ldyNnM6sqYeMWE+bgJcJpO6yS4QD7ymxgH34GBPNDM/THBh8iunyvKIZztiwLH4CJZ0RxTk9emgpjw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + dev: true + + /@babel/plugin-syntax-decorators@7.24.0(@babel/core@7.24.0): + resolution: {integrity: sha512-MXW3pQCu9gUiVGzqkGqsgiINDVYXoAnrY8FYF/rmb+OfufNF0zHMpHPN4ulRrinxYT8Vk/aZJxYqOKsDECjKAw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-dynamic-import@7.8.3(@babel/core@7.23.9): + /@babel/plugin-syntax-dynamic-import@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-export-namespace-from@7.8.3(@babel/core@7.23.9): + /@babel/plugin-syntax-export-namespace-from@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-import-assertions@7.23.3(@babel/core@7.23.9): + /@babel/plugin-syntax-import-assertions@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-lPgDSU+SJLK3xmFDTV2ZRQAiM7UuUjGidwBywFavObCiZc1BeAAcMtHJKUya92hPHO+at63JJPLygilZard8jw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-import-attributes@7.23.3(@babel/core@7.23.9): + /@babel/plugin-syntax-import-attributes@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-pawnE0P9g10xgoP7yKr6CK63K2FMsTE+FZidZO/1PwRdzmAPVs+HS1mAURUsgaoxammTJvULUdIkEK0gOcU2tA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.23.9): + /@babel/plugin-syntax-import-meta@7.10.4(@babel/core@7.24.0): resolution: {integrity: sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.23.9): + /@babel/plugin-syntax-json-strings@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.23.9): + /@babel/plugin-syntax-logical-assignment-operators@7.10.4(@babel/core@7.24.0): resolution: {integrity: sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.23.9): + /@babel/plugin-syntax-nullish-coalescing-operator@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.23.9): + /@babel/plugin-syntax-numeric-separator@7.10.4(@babel/core@7.24.0): resolution: {integrity: sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.23.9): + /@babel/plugin-syntax-object-rest-spread@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.23.9): + /@babel/plugin-syntax-optional-catch-binding@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.23.9): + /@babel/plugin-syntax-optional-chaining@7.8.3(@babel/core@7.24.0): resolution: {integrity: sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-private-property-in-object@7.14.5(@babel/core@7.23.9): + /@babel/plugin-syntax-private-property-in-object@7.14.5(@babel/core@7.24.0): resolution: {integrity: sha512-0wVnp9dxJ72ZUJDV27ZfbSj6iHLoytYZmh3rFcxNnvsJF3ktkzLDZPy/mA17HGsaQT3/DQsWYX1f1QGWkCoVUg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.23.9): + /@babel/plugin-syntax-top-level-await@7.14.5(@babel/core@7.24.0): resolution: {integrity: sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-syntax-unicode-sets-regex@7.18.6(@babel/core@7.23.9): + /@babel/plugin-syntax-unicode-sets-regex@7.18.6(@babel/core@7.24.0): resolution: {integrity: sha512-727YkEAPwSIQTv5im8QHz3upqp92JTWhidIC81Tdx4VJYIte/VndKf1qKrfnnhPLiPghStWfvC/iFaMCQu7Nqg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-arrow-functions@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-arrow-functions@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-NzQcQrzaQPkaEwoTm4Mhyl8jI1huEL/WWIEvudjTCMJ9aBZNpsJbMASx7EQECtQQPS/DcnFpo0FIh3LvEO9cxQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-async-generator-functions@7.23.9(@babel/core@7.23.9): + /@babel/plugin-transform-async-generator-functions@7.23.9(@babel/core@7.24.0): resolution: {integrity: sha512-8Q3veQEDGe14dTYuwagbRtwxQDnytyg1JFu4/HwEMETeofocrB0U0ejBJIXoeG/t2oXZ8kzCyI0ZZfbT80VFNQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-environment-visitor': 7.22.20 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-remap-async-to-generator': 7.22.20(@babel/core@7.23.9) - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.23.9) + '@babel/helper-plugin-utils': 7.24.0 + '@babel/helper-remap-async-to-generator': 7.22.20(@babel/core@7.24.0) + '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-async-to-generator@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-async-to-generator@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-A7LFsKi4U4fomjqXJlZg/u0ft/n8/7n7lpffUP/ZULx/DtV9SGlNKZolHH6PE8Xl1ngCc0M11OaeZptXVkfKSw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-module-imports': 7.22.15 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-remap-async-to-generator': 7.22.20(@babel/core@7.23.9) + '@babel/helper-plugin-utils': 7.24.0 + '@babel/helper-remap-async-to-generator': 7.22.20(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-block-scoped-functions@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-block-scoped-functions@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-vI+0sIaPIO6CNuM9Kk5VmXcMVRiOpDh7w2zZt9GXzmE/9KD70CUEVhvPR/etAeNK/FAEkhxQtXOzVF3EuRL41A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-block-scoping@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-block-scoping@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-0QqbP6B6HOh7/8iNR4CQU2Th/bbRtBp4KS9vcaZd1fZ0wSh5Fyssg0UCIHwxh+ka+pNDREbVLQnHCMHKZfPwfw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-class-properties@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-class-properties@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-uM+AN8yCIjDPccsKGlw271xjJtGii+xQIF/uMPS8H15L12jZTsLfF4o5vNO7d/oUguOyfdikHGc/yi9ge4SGIg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-create-class-features-plugin': 7.24.0(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-class-static-block@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-class-static-block@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-nsWu/1M+ggti1SOALj3hfx5FXzAY06fwPJsUZD4/A5e1bWi46VUIWtD+kOX6/IdhXGsXBWllLFDSnqSCdUNydQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.12.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-create-class-features-plugin': 7.24.0(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-classes@7.23.8(@babel/core@7.23.9): + /@babel/plugin-transform-classes@7.23.8(@babel/core@7.24.0): resolution: {integrity: sha512-yAYslGsY1bX6Knmg46RjiCiNSwJKv2IUC8qOdYKqMMr0491SXFhcHqOdRDeCRohOOIzwN/90C6mQ9qAKgrP7dg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-annotate-as-pure': 7.22.5 '@babel/helper-compilation-targets': 7.23.6 '@babel/helper-environment-visitor': 7.22.20 '@babel/helper-function-name': 7.23.0 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-replace-supers': 7.22.20(@babel/core@7.23.9) + '@babel/helper-plugin-utils': 7.24.0 + '@babel/helper-replace-supers': 7.22.20(@babel/core@7.24.0) '@babel/helper-split-export-declaration': 7.22.6 globals: 11.12.0 dev: true - /@babel/plugin-transform-computed-properties@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-computed-properties@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-dTj83UVTLw/+nbiHqQSFdwO9CbTtwq1DsDqm3CUEtDrZNET5rT5E6bIdTlOftDTDLMYxvxHNEYO4B9SLl8SLZw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/template': 7.23.9 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/template': 7.24.0 dev: true - /@babel/plugin-transform-destructuring@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-destructuring@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-n225npDqjDIr967cMScVKHXJs7rout1q+tt50inyBCPkyZ8KxeI6d+GIbSBTT/w/9WdlWDOej3V9HE5Lgk57gw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-dotall-regex@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-dotall-regex@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-vgnFYDHAKzFaTVp+mneDsIEbnJ2Np/9ng9iviHw3P/KVcgONxpNULEW/51Z/BaFojG2GI2GwwXck5uV1+1NOYQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-duplicate-keys@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-duplicate-keys@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-RrqQ+BQmU3Oyav3J+7/myfvRCq7Tbz+kKLLshUmMwNlDHExbGL7ARhajvoBJEvc+fCguPPu887N+3RRXBVKZUA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-dynamic-import@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-dynamic-import@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-V6jIbLhdJK86MaLh4Jpghi8ho5fGzt3imHOBu/x0jlBaPYqDoWz4RDXjmMOfnh+JWNaQleEAByZLV0QzBT4YQQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-exponentiation-operator@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-exponentiation-operator@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-5fhCsl1odX96u7ILKHBj4/Y8vipoqwsJMh4csSA8qFfxrZDEA4Ssku2DyNvMJSmZNOEBT750LfFPbtrnTP90BQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-builder-binary-assignment-operator-visitor': 7.22.15 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-export-namespace-from@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-export-namespace-from@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-GzuSBcKkx62dGzZI1WVgTWvkkz84FZO5TC5T8dl/Tht/rAla6Dg/Mz9Yhypg+ezVACf/rgDuQt3kbWEv7LdUDQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-for-of@7.23.6(@babel/core@7.23.9): + /@babel/plugin-transform-for-of@7.23.6(@babel/core@7.24.0): resolution: {integrity: sha512-aYH4ytZ0qSuBbpfhuofbg/e96oQ7U2w1Aw/UQmKT+1l39uEhUPoFS3fHevDc1G0OvewyDudfMKY1OulczHzWIw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 dev: true - /@babel/plugin-transform-function-name@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-function-name@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-I1QXp1LxIvt8yLaib49dRW5Okt7Q4oaxao6tFVKS/anCdEOMtYwWVKoiOA1p34GOWIZjUK0E+zCp7+l1pfQyiw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-compilation-targets': 7.23.6 '@babel/helper-function-name': 7.23.0 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-json-strings@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-json-strings@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-81nTOqM1dMwZ/aRXQ59zVubN9wHGqk6UtqRK+/q+ciXmRy8fSolhGVvG09HHRGo4l6fr/c4ZhXUQH0uFW7PZbg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-literals@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-literals@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-wZ0PIXRxnwZvl9AYpqNUxpZ5BiTGrYt7kueGQ+N5FiQ7RCOD4cm8iShd6S6ggfVIWaJf2EMk8eRzAh52RfP4rQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-logical-assignment-operators@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-logical-assignment-operators@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-Mc/ALf1rmZTP4JKKEhUwiORU+vcfarFVLfcFiolKUo6sewoxSEgl36ak5t+4WamRsNr6nzjZXQjM35WsU+9vbg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-member-expression-literals@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-member-expression-literals@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-sC3LdDBDi5x96LA+Ytekz2ZPk8i/Ck+DEuDbRAll5rknJ5XRTSaPKEYwomLcs1AA8wg9b3KjIQRsnApj+q51Ag==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-modules-amd@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-modules-amd@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-vJYQGxeKM4t8hYCKVBlZX/gtIY2I7mRGFNcm85sgXGMTBcoV3QdVtdpbcWEbzbfUIUZKwvgFT82mRvaQIebZzw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-module-transforms': 7.23.3(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-modules-commonjs@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-modules-commonjs@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-aVS0F65LKsdNOtcz6FRCpE4OgsP2OFnW46qNxNIX9h3wuzaNcSQsJysuMwqSibC98HPrf2vCgtxKNwS0DAlgcA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-module-transforms': 7.23.3(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 '@babel/helper-simple-access': 7.22.5 dev: true - /@babel/plugin-transform-modules-systemjs@7.23.9(@babel/core@7.23.9): + /@babel/plugin-transform-modules-systemjs@7.23.9(@babel/core@7.24.0): resolution: {integrity: sha512-KDlPRM6sLo4o1FkiSlXoAa8edLXFsKKIda779fbLrvmeuc3itnjCtaO6RrtoaANsIJANj+Vk1zqbZIMhkCAHVw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-hoist-variables': 7.22.5 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-module-transforms': 7.23.3(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 '@babel/helper-validator-identifier': 7.22.20 dev: true - /@babel/plugin-transform-modules-umd@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-modules-umd@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-zHsy9iXX2nIsCBFPud3jKn1IRPWg3Ing1qOZgeKV39m1ZgIdpJqvlWVeiHBZC6ITRG0MfskhYe9cLgntfSFPIg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-module-transforms': 7.23.3(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-module-transforms': 7.23.3(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-named-capturing-groups-regex@7.22.5(@babel/core@7.23.9): + /@babel/plugin-transform-named-capturing-groups-regex@7.22.5(@babel/core@7.24.0): resolution: {integrity: sha512-YgLLKmS3aUBhHaxp5hi1WJTgOUb/NCuDHzGT9z9WTt3YG+CPRhJs6nprbStx6DnWM4dh6gt7SU3sZodbZ08adQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-new-target@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-new-target@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-YJ3xKqtJMAT5/TIZnpAR3I+K+WaDowYbN3xyxI8zxx/Gsypwf9B9h0VB+1Nh6ACAAPRS5NSRje0uVv5i79HYGQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-nullish-coalescing-operator@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-nullish-coalescing-operator@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-jHE9EVVqHKAQx+VePv5LLGHjmHSJR76vawFPTdlxR/LVJPfOEGxREQwQfjuZEOPTwG92X3LINSh3M40Rv4zpVA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-numeric-separator@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-numeric-separator@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-mps6auzgwjRrwKEZA05cOwuDc9FAzoyFS4ZsG/8F43bTLf/TgkJg7QXOrPO1JO599iA3qgK9MXdMGOEC8O1h6Q==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-object-rest-spread@7.23.4(@babel/core@7.23.9): - resolution: {integrity: sha512-9x9K1YyeQVw0iOXJlIzwm8ltobIIv7j2iLyP2jIhEbqPRQ7ScNgwQufU2I0Gq11VjyG4gI4yMXt2VFags+1N3g==} + /@babel/plugin-transform-object-rest-spread@7.24.0(@babel/core@7.24.0): + resolution: {integrity: sha512-y/yKMm7buHpFFXfxVFS4Vk1ToRJDilIa6fKRioB9Vjichv58TDGXTvqV0dN7plobAmTW5eSEGXDngE+Mm+uO+w==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: '@babel/compat-data': 7.23.5 - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-transform-parameters': 7.23.3(@babel/core@7.23.9) + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-transform-parameters': 7.23.3(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-object-super@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-object-super@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-BwQ8q0x2JG+3lxCVFohg+KbQM7plfpBwThdW9A6TMtWwLsbDA01Ek2Zb/AgDN39BiZsExm4qrXxjk+P1/fzGrA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-replace-supers': 7.22.20(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/helper-replace-supers': 7.22.20(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-optional-catch-binding@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-optional-catch-binding@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-XIq8t0rJPHf6Wvmbn9nFxU6ao4c7WhghTR5WyV8SrJfUFzyxhCm4nhC+iAp3HFhbAKLfYpgzhJ6t4XCtVwqO5A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-optional-chaining@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-optional-chaining@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-ZU8y5zWOfjM5vZ+asjgAPwDaBjJzgufjES89Rs4Lpq63O300R/kOz30WCLo6BxxX6QVEilwSlpClnG5cZaikTA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.23.9) + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-parameters@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-parameters@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-09lMt6UsUb3/34BbECKVbVwrT9bO6lILWln237z7sLaWnMsTi7Yc9fhX5DLpkJzAGfaReXI22wP41SZmnAA3Vw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-private-methods@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-private-methods@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-UzqRcRtWsDMTLrRWFvUBDwmw06tCQH9Rl1uAjfh6ijMSmGYQ+fpdB+cnqRC8EMh5tuuxSv0/TejGL+7vyj+50g==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-create-class-features-plugin': 7.24.0(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-private-property-in-object@7.23.4(@babel/core@7.23.9): + /@babel/plugin-transform-private-property-in-object@7.23.4(@babel/core@7.24.0): resolution: {integrity: sha512-9G3K1YqTq3F4Vt88Djx1UZ79PDyj+yKRnUy7cZGSMe+a7jkwD259uKKuUzQlPkGam7R+8RJwh5z4xO27fA1o2A==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-create-class-features-plugin': 7.23.10(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.23.9) + '@babel/helper-create-class-features-plugin': 7.24.0(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 + '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.24.0) dev: true - /@babel/plugin-transform-property-literals@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-property-literals@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-jR3Jn3y7cZp4oEWPFAlRsSWjxKe4PZILGBSd4nis1TsC5qeSpb+nrtihJuDhNI7QHiVbUaiXa0X2RZY3/TI6Nw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-regenerator@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-regenerator@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-KP+75h0KghBMcVpuKisx3XTu9Ncut8Q8TuvGO4IhY+9D5DFEckQefOuIsB/gQ2tG71lCke4NMrtIPS8pOj18BQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 regenerator-transform: 0.15.2 dev: true - /@babel/plugin-transform-reserved-words@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-reserved-words@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-QnNTazY54YqgGxwIexMZva9gqbPa15t/x9VS+0fsEFWplwVpXYZivtgl43Z1vMpc1bdPP2PP8siFeVcnFvA3Cg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-shorthand-properties@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-shorthand-properties@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-ED2fgqZLmexWiN+YNFX26fx4gh5qHDhn1O2gvEhreLW2iI63Sqm4llRLCXALKrCnbN4Jy0VcMQZl/SAzqug/jg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-spread@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-spread@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-VvfVYlrlBVu+77xVTOAoxQ6mZbnIq5FM0aGBSFEcIh03qHf+zNqA4DC/3XMUozTg7bZV3e3mZQ0i13VB6v5yUg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 '@babel/helper-skip-transparent-expression-wrappers': 7.22.5 dev: true - /@babel/plugin-transform-sticky-regex@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-sticky-regex@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-HZOyN9g+rtvnOU3Yh7kSxXrKbzgrm5X4GncPY1QOquu7epga5MxKHVpYu2hvQnry/H+JjckSYRb93iNfsioAGg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-template-literals@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-template-literals@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-Flok06AYNp7GV2oJPZZcP9vZdszev6vPBkHLwxwSpaIqx75wn6mUd3UFWsSsA0l8nXAKkyCmL/sR02m8RYGeHg==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-typeof-symbol@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-typeof-symbol@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-4t15ViVnaFdrPC74be1gXBSMzXk3B4Us9lP7uLRQHTFpV5Dvt33pn+2MyyNxmN3VTTm3oTrZVMUmuw3oBnQ2oQ==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-unicode-escapes@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-unicode-escapes@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-OMCUx/bU6ChE3r4+ZdylEqAjaQgHAgipgW8nsCfu5pGqDcFytVd91AwRvUJSBZDz0exPGgnjoqhgRYLRjFZc9Q==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-unicode-property-regex@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-unicode-property-regex@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-KcLIm+pDZkWZQAFJ9pdfmh89EwVfmNovFBcXko8szpBeF8z68kWIPeKlmSOkT9BXJxs2C0uk+5LxoxIv62MROA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-unicode-regex@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-unicode-regex@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-wMHpNA4x2cIA32b/ci3AfwNgheiva2W0WUKWTK7vBHBhDKfPsc5cFGNWm69WBqpwd86u1qwZ9PWevKqm1A3yAw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/plugin-transform-unicode-sets-regex@7.23.3(@babel/core@7.23.9): + /@babel/plugin-transform-unicode-sets-regex@7.23.3(@babel/core@7.24.0): resolution: {integrity: sha512-W7lliA/v9bNR83Qc3q1ip9CQMZ09CcHDbHfbLRDNuAhn1Mvkr1ZNF7hPmztMQvtTGVLJ9m8IZqWsTkXOml8dbw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.23.9) - '@babel/helper-plugin-utils': 7.22.5 + '@babel/core': 7.24.0 + '@babel/helper-create-regexp-features-plugin': 7.22.15(@babel/core@7.24.0) + '@babel/helper-plugin-utils': 7.24.0 dev: true - /@babel/preset-env@7.23.9(@babel/core@7.23.9): - resolution: {integrity: sha512-3kBGTNBBk9DQiPoXYS0g0BYlwTQYUTifqgKTjxUwEUkduRT2QOa0FPGBJ+NROQhGyYO5BuTJwGvBnqKDykac6A==} + /@babel/preset-env@7.24.0(@babel/core@7.24.0): + resolution: {integrity: sha512-ZxPEzV9IgvGn73iK0E6VB9/95Nd7aMFpbE0l8KQFDG70cOV9IxRP7Y2FUPmlK0v6ImlLqYX50iuZ3ZTVhOF2lA==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: '@babel/compat-data': 7.23.5 - '@babel/core': 7.23.9 + '@babel/core': 7.24.0 '@babel/helper-compilation-targets': 7.23.6 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.24.0 '@babel/helper-validator-option': 7.23.5 - '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly': 7.23.7(@babel/core@7.23.9) - '@babel/plugin-proposal-private-property-in-object': 7.21.0-placeholder-for-preset-env.2(@babel/core@7.23.9) - '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.23.9) - '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.23.9) - '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.23.9) - '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-import-assertions': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-syntax-import-attributes': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.23.9) - '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.23.9) - '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.23.9) - '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.23.9) - '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.23.9) - '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.23.9) - '@babel/plugin-syntax-unicode-sets-regex': 7.18.6(@babel/core@7.23.9) - '@babel/plugin-transform-arrow-functions': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-async-generator-functions': 7.23.9(@babel/core@7.23.9) - '@babel/plugin-transform-async-to-generator': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-block-scoped-functions': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-block-scoping': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-class-properties': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-class-static-block': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-classes': 7.23.8(@babel/core@7.23.9) - '@babel/plugin-transform-computed-properties': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-destructuring': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-dotall-regex': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-duplicate-keys': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-dynamic-import': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-exponentiation-operator': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-export-namespace-from': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-for-of': 7.23.6(@babel/core@7.23.9) - '@babel/plugin-transform-function-name': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-json-strings': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-literals': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-logical-assignment-operators': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-member-expression-literals': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-modules-amd': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-modules-commonjs': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-modules-systemjs': 7.23.9(@babel/core@7.23.9) - '@babel/plugin-transform-modules-umd': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-named-capturing-groups-regex': 7.22.5(@babel/core@7.23.9) - '@babel/plugin-transform-new-target': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-nullish-coalescing-operator': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-numeric-separator': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-object-rest-spread': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-object-super': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-optional-catch-binding': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-optional-chaining': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-parameters': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-private-methods': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-private-property-in-object': 7.23.4(@babel/core@7.23.9) - '@babel/plugin-transform-property-literals': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-regenerator': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-reserved-words': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-shorthand-properties': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-spread': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-sticky-regex': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-template-literals': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-typeof-symbol': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-unicode-escapes': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-unicode-property-regex': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-unicode-regex': 7.23.3(@babel/core@7.23.9) - '@babel/plugin-transform-unicode-sets-regex': 7.23.3(@babel/core@7.23.9) - '@babel/preset-modules': 0.1.6-no-external-plugins(@babel/core@7.23.9) - babel-plugin-polyfill-corejs2: 0.4.8(@babel/core@7.23.9) - babel-plugin-polyfill-corejs3: 0.9.0(@babel/core@7.23.9) - babel-plugin-polyfill-regenerator: 0.5.5(@babel/core@7.23.9) + '@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-bugfix-v8-static-class-fields-redefine-readonly': 7.23.7(@babel/core@7.24.0) + '@babel/plugin-proposal-private-property-in-object': 7.21.0-placeholder-for-preset-env.2(@babel/core@7.24.0) + '@babel/plugin-syntax-async-generators': 7.8.4(@babel/core@7.24.0) + '@babel/plugin-syntax-class-properties': 7.12.13(@babel/core@7.24.0) + '@babel/plugin-syntax-class-static-block': 7.14.5(@babel/core@7.24.0) + '@babel/plugin-syntax-dynamic-import': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-export-namespace-from': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-import-assertions': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-syntax-import-attributes': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-syntax-import-meta': 7.10.4(@babel/core@7.24.0) + '@babel/plugin-syntax-json-strings': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4(@babel/core@7.24.0) + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-numeric-separator': 7.10.4(@babel/core@7.24.0) + '@babel/plugin-syntax-object-rest-spread': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-optional-catch-binding': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-optional-chaining': 7.8.3(@babel/core@7.24.0) + '@babel/plugin-syntax-private-property-in-object': 7.14.5(@babel/core@7.24.0) + '@babel/plugin-syntax-top-level-await': 7.14.5(@babel/core@7.24.0) + '@babel/plugin-syntax-unicode-sets-regex': 7.18.6(@babel/core@7.24.0) + '@babel/plugin-transform-arrow-functions': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-async-generator-functions': 7.23.9(@babel/core@7.24.0) + '@babel/plugin-transform-async-to-generator': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-block-scoped-functions': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-block-scoping': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-class-properties': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-class-static-block': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-classes': 7.23.8(@babel/core@7.24.0) + '@babel/plugin-transform-computed-properties': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-destructuring': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-dotall-regex': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-duplicate-keys': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-dynamic-import': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-exponentiation-operator': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-export-namespace-from': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-for-of': 7.23.6(@babel/core@7.24.0) + '@babel/plugin-transform-function-name': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-json-strings': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-literals': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-logical-assignment-operators': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-member-expression-literals': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-modules-amd': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-modules-commonjs': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-modules-systemjs': 7.23.9(@babel/core@7.24.0) + '@babel/plugin-transform-modules-umd': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-named-capturing-groups-regex': 7.22.5(@babel/core@7.24.0) + '@babel/plugin-transform-new-target': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-nullish-coalescing-operator': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-numeric-separator': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-object-rest-spread': 7.24.0(@babel/core@7.24.0) + '@babel/plugin-transform-object-super': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-optional-catch-binding': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-optional-chaining': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-parameters': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-private-methods': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-private-property-in-object': 7.23.4(@babel/core@7.24.0) + '@babel/plugin-transform-property-literals': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-regenerator': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-reserved-words': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-shorthand-properties': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-spread': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-sticky-regex': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-template-literals': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-typeof-symbol': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-unicode-escapes': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-unicode-property-regex': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-unicode-regex': 7.23.3(@babel/core@7.24.0) + '@babel/plugin-transform-unicode-sets-regex': 7.23.3(@babel/core@7.24.0) + '@babel/preset-modules': 0.1.6-no-external-plugins(@babel/core@7.24.0) + babel-plugin-polyfill-corejs2: 0.4.8(@babel/core@7.24.0) + babel-plugin-polyfill-corejs3: 0.9.0(@babel/core@7.24.0) + babel-plugin-polyfill-regenerator: 0.5.5(@babel/core@7.24.0) core-js-compat: 3.36.0 semver: 6.3.1 transitivePeerDependencies: - supports-color dev: true - /@babel/preset-modules@0.1.6-no-external-plugins(@babel/core@7.23.9): + /@babel/preset-modules@0.1.6-no-external-plugins(@babel/core@7.24.0): resolution: {integrity: sha512-HrcgcIESLm9aIR842yhJ5RWan/gebQUJ6E/E5+rf0y9o6oj7w0Br+sWuL6kEQ/o/AdfvR1Je9jG18/gnpwjEyA==} peerDependencies: '@babel/core': ^7.0.0-0 || ^8.0.0-0 <8.0.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/types': 7.23.9 + '@babel/core': 7.24.0 + '@babel/helper-plugin-utils': 7.24.0 + '@babel/types': 7.24.0 esutils: 2.0.3 dev: true @@ -1231,24 +1262,24 @@ packages: resolution: {integrity: sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==} dev: true - /@babel/runtime@7.23.9: - resolution: {integrity: sha512-0CX6F+BI2s9dkUqr08KFrAIZgNFj75rdBU/DjCyYLIaV/quFjkk6T+EJ2LkZHyZTbEV4L5p97mNkUsHl2wLFAw==} + /@babel/runtime@7.24.0: + resolution: {integrity: sha512-Chk32uHMg6TnQdvw2e9IlqPpFX/6NLuK0Ys2PqLb7/gL5uFn9mXvK715FGLlOLQrcO4qIkNHkvPGktzzXexsFw==} engines: {node: '>=6.9.0'} dependencies: regenerator-runtime: 0.14.1 dev: true - /@babel/template@7.23.9: - resolution: {integrity: sha512-+xrD2BWLpvHKNmX2QbpdpsBaWnRxahMwJjO+KZk2JOElj5nSmKezyS1B4u+QbHMTX69t4ukm6hh9lsYQ7GHCKA==} + /@babel/template@7.24.0: + resolution: {integrity: sha512-Bkf2q8lMB0AFpX0NFEqSbx1OkTHf0f+0j82mkw+ZpzBnkk7e9Ql0891vlfgi+kHwOk8tQjiQHpqh4LaSa0fKEA==} engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.23.5 - '@babel/parser': 7.23.9 - '@babel/types': 7.23.9 + '@babel/parser': 7.24.0 + '@babel/types': 7.24.0 dev: true - /@babel/traverse@7.23.9: - resolution: {integrity: sha512-I/4UJ9vs90OkBtY6iiiTORVMyIhJ4kAVmsKo9KFc8UOxMeUfi2hvtIBsET5u9GizXE6/GFSuKCTNfgCswuEjRg==} + /@babel/traverse@7.24.0: + resolution: {integrity: sha512-HfuJlI8qq3dEDmNU5ChzzpZRWq+oxCZQyMzIMEqLho+AQnhMnKQUzH6ydo3RBl/YjPCuk68Y6s0Gx0AeyULiWw==} engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.23.5 @@ -1257,16 +1288,16 @@ packages: '@babel/helper-function-name': 7.23.0 '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/parser': 7.23.9 - '@babel/types': 7.23.9 + '@babel/parser': 7.24.0 + '@babel/types': 7.24.0 debug: 4.3.4(supports-color@8.1.1) globals: 11.12.0 transitivePeerDependencies: - supports-color dev: true - /@babel/types@7.23.9: - resolution: {integrity: sha512-dQjSq/7HaSjRM43FFGnv5keM2HsxpmyV1PfaSVm0nzzjwwTmjOe6J4bC8e3+pTEIgHaHj+1ZlLThRJ2auc/w1Q==} + /@babel/types@7.24.0: + resolution: {integrity: sha512-+j7a5c253RfKh8iABBhywc8NSfP5LURe7Uh4qpsh6jc+aLJguvmIUBdjSdEMQv2bENrCR5MfRdjGo7vzS/ob7w==} engines: {node: '>=6.9.0'} dependencies: '@babel/helper-string-parser': 7.23.4 @@ -1525,13 +1556,13 @@ packages: wrap-ansi-cjs: /wrap-ansi@7.0.0 dev: true - /@jridgewell/gen-mapping@0.3.3: - resolution: {integrity: sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==} + /@jridgewell/gen-mapping@0.3.5: + resolution: {integrity: sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==} engines: {node: '>=6.0.0'} dependencies: - '@jridgewell/set-array': 1.1.2 + '@jridgewell/set-array': 1.2.1 '@jridgewell/sourcemap-codec': 1.4.15 - '@jridgewell/trace-mapping': 0.3.22 + '@jridgewell/trace-mapping': 0.3.25 dev: true /@jridgewell/resolve-uri@3.1.2: @@ -1539,8 +1570,8 @@ packages: engines: {node: '>=6.0.0'} dev: true - /@jridgewell/set-array@1.1.2: - resolution: {integrity: sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==} + /@jridgewell/set-array@1.2.1: + resolution: {integrity: sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==} engines: {node: '>=6.0.0'} dev: true @@ -1548,8 +1579,8 @@ packages: resolution: {integrity: sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==} dev: true - /@jridgewell/trace-mapping@0.3.22: - resolution: {integrity: sha512-Wf963MzWtA2sjrNt+g18IAln9lKnlRp+K2eH4jjIoF1wYeq3aMREpG09xhlhdzS0EjwU7qmUJYangWa+151vZw==} + /@jridgewell/trace-mapping@0.3.25: + resolution: {integrity: sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==} dependencies: '@jridgewell/resolve-uri': 3.1.2 '@jridgewell/sourcemap-codec': 1.4.15 @@ -1725,14 +1756,14 @@ packages: /@types/fs-extra@8.1.5: resolution: {integrity: sha512-0dzKcwO+S8s2kuF5Z9oUWatQJj5Uq/iqphEtE3GQJVRRYm/tD1LglU2UnXi2A8jLq5umkGouOXOR9y0n613ZwQ==} dependencies: - '@types/node': 20.11.19 + '@types/node': 20.11.24 dev: true /@types/glob@7.2.0: resolution: {integrity: sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==} dependencies: '@types/minimatch': 5.1.2 - '@types/node': 20.11.19 + '@types/node': 20.11.24 dev: true /@types/json5@0.0.29: @@ -1743,8 +1774,8 @@ packages: resolution: {integrity: sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA==} dev: true - /@types/node@20.11.19: - resolution: {integrity: sha512-7xMnVEcZFu0DikYjWOlRq7NTPETrm7teqUT2WkQjrTIkEgUyyGdWsj/Zg8bEJt5TNklzbPD1X3fqfsHw3SpapQ==} + /@types/node@20.11.24: + resolution: {integrity: sha512-Kza43ewS3xoLgCEpQrsT+xRo/EJej1y0kVYGiLFE1NEODXGzTfwiC6tXTLMQskn1X4/Rjlh0MQUvx9W+L9long==} dependencies: undici-types: 5.26.5 dev: true @@ -1905,7 +1936,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 get-intrinsic: 1.2.4 is-string: 1.0.7 dev: true @@ -1926,7 +1957,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 es-array-method-boxes-properly: 1.0.0 is-string: 1.0.7 dev: true @@ -1937,7 +1968,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 es-errors: 1.3.0 es-shim-unscopables: 1.0.2 dev: true @@ -1948,7 +1979,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 es-shim-unscopables: 1.0.2 dev: true @@ -1958,7 +1989,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 es-shim-unscopables: 1.0.2 dev: true @@ -1969,7 +2000,7 @@ packages: array-buffer-byte-length: 1.0.1 call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 es-errors: 1.3.0 get-intrinsic: 1.2.4 is-array-buffer: 3.0.4 @@ -1997,38 +2028,38 @@ packages: possible-typed-array-names: 1.0.0 dev: true - /babel-plugin-polyfill-corejs2@0.4.8(@babel/core@7.23.9): + /babel-plugin-polyfill-corejs2@0.4.8(@babel/core@7.24.0): resolution: {integrity: sha512-OtIuQfafSzpo/LhnJaykc0R/MMnuLSSVjVYy9mHArIZ9qTCSZ6TpWCuEKZYVoN//t8HqBNScHrOtCrIK5IaGLg==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 dependencies: '@babel/compat-data': 7.23.5 - '@babel/core': 7.23.9 - '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.24.0) semver: 6.3.1 transitivePeerDependencies: - supports-color dev: true - /babel-plugin-polyfill-corejs3@0.9.0(@babel/core@7.23.9): + /babel-plugin-polyfill-corejs3@0.9.0(@babel/core@7.24.0): resolution: {integrity: sha512-7nZPG1uzK2Ymhy/NbaOWTg3uibM2BmGASS4vHS4szRZAIR8R6GwA/xAujpdrXU5iyklrimWnLWU+BLF9suPTqg==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.24.0) core-js-compat: 3.36.0 transitivePeerDependencies: - supports-color dev: true - /babel-plugin-polyfill-regenerator@0.5.5(@babel/core@7.23.9): + /babel-plugin-polyfill-regenerator@0.5.5(@babel/core@7.24.0): resolution: {integrity: sha512-OJGYZlhLqBh2DDHeqAxWB1XIvr49CxiJ2gIt61/PU55CQK4Z58OzMqjDe1zwQdQk+rBYsRc+1rJmdajM3gimHg==} peerDependencies: '@babel/core': ^7.4.0 || ^8.0.0-0 <8.0.0 dependencies: - '@babel/core': 7.23.9 - '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.23.9) + '@babel/core': 7.24.0 + '@babel/helper-define-polyfill-provider': 0.5.0(@babel/core@7.24.0) transitivePeerDependencies: - supports-color dev: true @@ -2081,8 +2112,8 @@ packages: engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true dependencies: - caniuse-lite: 1.0.30001589 - electron-to-chromium: 1.4.679 + caniuse-lite: 1.0.30001593 + electron-to-chromium: 1.4.690 node-releases: 2.0.14 update-browserslist-db: 1.0.13(browserslist@4.23.0) dev: true @@ -2115,8 +2146,8 @@ packages: engines: {node: '>=10'} dev: false - /caniuse-lite@1.0.30001589: - resolution: {integrity: sha512-vNQWS6kI+q6sBlHbh71IIeC+sRwK2N3EDySc/updIGhIee2x5z00J4c1242/5/d6EpEMdOnk/m+6tuk4/tcsqg==} + /caniuse-lite@1.0.30001593: + resolution: {integrity: sha512-UWM1zlo3cZfkpBysd7AS+z+v007q9G1+fLTUU42rQnY6t2axoogPW/xol6T7juU5EUoOhML4WgBIdG+9yYqAjQ==} dev: true /chai@5.1.0: @@ -2303,7 +2334,7 @@ packages: resolution: {integrity: sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==} engines: {node: '>=0.11'} dependencies: - '@babel/runtime': 7.23.9 + '@babel/runtime': 7.24.0 dev: true /debug@3.2.7: @@ -2400,8 +2431,8 @@ packages: resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} dev: true - /electron-to-chromium@1.4.679: - resolution: {integrity: sha512-NhQMsz5k0d6m9z3qAxnsOR/ebal4NAGsrNVRwcDo4Kc/zQ7KdsTKZUxZoygHcVRb0QDW3waEDIcE3isZ79RP6g==} + /electron-to-chromium@1.4.690: + resolution: {integrity: sha512-+2OAGjUx68xElQhydpcbqH50hE8Vs2K6TkAeLhICYfndb67CVH0UsZaijmRUE3rHlIxU1u0jxwhgVe6fK3YANA==} dev: true /emoji-regex@8.0.0: @@ -2425,8 +2456,8 @@ packages: is-arrayish: 0.2.1 dev: true - /es-abstract@1.22.4: - resolution: {integrity: sha512-vZYJlk2u6qHYxBOTjAeg7qUxHdNfih64Uu2J8QqWgXZ2cri0ZpJAkzDUK/q593+mvKwlxyaxr6F1Q+3LKoQRgg==} + /es-abstract@1.22.5: + resolution: {integrity: sha512-oW69R+4q2wG+Hc3KZePPZxOiisRIqfKBVo/HLx94QcJeWGU/8sZhCvc829rd1kS366vlJbzBfXf9yWwf0+Ko7w==} engines: {node: '>= 0.4'} dependencies: array-buffer-byte-length: 1.0.1 @@ -2584,8 +2615,8 @@ packages: - supports-color dev: true - /eslint-module-utils@2.8.0(eslint-import-resolver-node@0.3.9)(eslint@7.32.0): - resolution: {integrity: sha512-aWajIYfsqCKRDgUfjEXNN/JlrzauMuSEy5sbd7WXbtW3EH6A6MpwEh42c7qD+MqQo9QMJ6fWLAeIJynx0g6OAw==} + /eslint-module-utils@2.8.1(eslint-import-resolver-node@0.3.9)(eslint@7.32.0): + resolution: {integrity: sha512-rXDXR3h7cs7dy9RNpUlQf80nX31XWJEyGq1tRMo+6GsO5VmTe4UTwtmonAD4ZkAsrfMVDA2wlGJ3790Ys+D49Q==} engines: {node: '>=4'} peerDependencies: '@typescript-eslint/parser': '*' @@ -2630,7 +2661,7 @@ packages: doctrine: 2.1.0 eslint: 7.32.0 eslint-import-resolver-node: 0.3.9 - eslint-module-utils: 2.8.0(eslint-import-resolver-node@0.3.9)(eslint@7.32.0) + eslint-module-utils: 2.8.1(eslint-import-resolver-node@0.3.9)(eslint@7.32.0) hasown: 2.0.1 is-core-module: 2.13.1 is-glob: 4.0.3 @@ -2923,7 +2954,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 functions-have-names: 1.2.3 dev: true @@ -2948,22 +2979,13 @@ packages: resolution: {integrity: sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==} dev: false - /get-intrinsic@1.2.2: - resolution: {integrity: sha512-0gSo4ml/0j98Y3lngkFEot/zhiCeWsbYIlZ+uZOVgzLyLaUw7wxUL+nCTP0XJvJg1AXulJRI3UJi8GsbDuxdGA==} - dependencies: - function-bind: 1.1.2 - has-proto: 1.0.1 - has-symbols: 1.0.3 - hasown: 2.0.0 - dev: true - /get-intrinsic@1.2.4: resolution: {integrity: sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==} engines: {node: '>= 0.4'} dependencies: es-errors: 1.3.0 function-bind: 1.1.2 - has-proto: 1.0.1 + has-proto: 1.0.3 has-symbols: 1.0.3 hasown: 2.0.1 dev: true @@ -3053,7 +3075,7 @@ packages: /gopd@1.0.1: resolution: {integrity: sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==} dependencies: - get-intrinsic: 1.2.2 + get-intrinsic: 1.2.4 dev: true /graceful-fs@4.2.11: @@ -3086,11 +3108,6 @@ packages: es-define-property: 1.0.0 dev: true - /has-proto@1.0.1: - resolution: {integrity: sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==} - engines: {node: '>= 0.4'} - dev: true - /has-proto@1.0.3: resolution: {integrity: sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==} engines: {node: '>= 0.4'} @@ -3108,13 +3125,6 @@ packages: has-symbols: 1.0.3 dev: true - /hasown@2.0.0: - resolution: {integrity: sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA==} - engines: {node: '>= 0.4'} - dependencies: - function-bind: 1.1.2 - dev: true - /hasown@2.0.1: resolution: {integrity: sha512-1/th4MHjnwncwXsIW6QMzlvYL9kG5e/CpVvLRZe4XPa8TOUNbCELqmvhDmnkNsAjwaG4+I8gJJL0JBvTTLO9qA==} engines: {node: '>= 0.4'} @@ -3178,9 +3188,13 @@ packages: dependencies: es-errors: 1.3.0 hasown: 2.0.1 - side-channel: 1.0.5 + side-channel: 1.0.6 dev: true + /inversify@6.0.2: + resolution: {integrity: sha512-i9m8j/7YIv4mDuYXUAcrpKPSaju/CIly9AHK5jvCBeoiM/2KEsuCQTTP+rzSWWpLYWRukdXFSl6ZTk2/uumbiA==} + dev: false + /is-array-buffer@3.0.4: resolution: {integrity: sha512-wcjaerHw0ydZwfhiKbXJWLDY8A7yV7KhjQOpb83hGgGfId/aQa4TOvwyzn2PuswW2gPCYEL/nEAiSVpdOj1lXw==} engines: {node: '>= 0.4'} @@ -3227,7 +3241,7 @@ packages: /is-core-module@2.13.1: resolution: {integrity: sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw==} dependencies: - hasown: 2.0.0 + hasown: 2.0.1 dev: true /is-date-object@1.0.5: @@ -3723,7 +3737,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 dev: true /object.fromentries@2.0.7: @@ -3732,7 +3746,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 dev: true /object.groupby@1.0.2: @@ -3741,7 +3755,7 @@ packages: array.prototype.filter: 1.0.3 call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 es-errors: 1.3.0 dev: true @@ -3751,7 +3765,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 dev: true /once@1.4.0: @@ -3955,6 +3969,10 @@ packages: picomatch: 2.3.1 dev: false + /reflect-metadata@0.2.1: + resolution: {integrity: sha512-i5lLI6iw9AU3Uu4szRNPPEkomnkjRTaVt9hy/bn5g/oSzekBSMeLZblcjP74AW0vBabqERLLIrz+gR8QYR54Tw==} + dev: false + /regenerate-unicode-properties@10.1.1: resolution: {integrity: sha512-X007RyZLsCJVVrjgEFVpLUTZwyOZk3oiL75ZcuYjlIWd6rNJtOjkBwQc5AsRrpbKVkxN6sklw/k/9m2jJYOf8Q==} engines: {node: '>=4'} @@ -3973,7 +3991,7 @@ packages: /regenerator-transform@0.15.2: resolution: {integrity: sha512-hfMp2BoF0qOk3uc5V20ALGDS2ddjQaLrdl7xrGXvAIow7qeWRM2VA2HuCHkUKk9slq3VwEwLNK3DFBqDfPGYtg==} dependencies: - '@babel/runtime': 7.23.9 + '@babel/runtime': 7.24.0 dev: true /regexp.prototype.flags@1.5.2: @@ -4223,8 +4241,8 @@ packages: resolution: {integrity: sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA==} dev: true - /side-channel@1.0.5: - resolution: {integrity: sha512-QcgiIWV4WV7qWExbN5llt6frQB/lBven9pqliLXfGPB+K9ZYXxDozp0wLkHS24kWCm+6YXH/f0HhnObZnZOBnQ==} + /side-channel@1.0.6: + resolution: {integrity: sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.7 @@ -4315,7 +4333,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 dev: true /string.prototype.trim@1.2.8: @@ -4324,7 +4342,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 dev: true /string.prototype.trimend@1.0.7: @@ -4332,7 +4350,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 dev: true /string.prototype.trimstart@1.0.7: @@ -4340,7 +4358,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.4 + es-abstract: 1.22.5 dev: true /strip-ansi@3.0.1: diff --git a/src/about/index.js b/src/about/index.js index 17f862c5..de28b509 100644 --- a/src/about/index.js +++ b/src/about/index.js @@ -1,3 +1,4 @@ +/* eslint-disable comma-dangle */ /* Copyright 2016-2024 Nuxeo @@ -14,28 +15,32 @@ See the License for the specific language governing permissions and limitations under the License. */ -// eslint-disable-next-line import/no-unresolved import $ from 'jquery'; -import ServiceWorkerBridge from '../service-worker-bridge'; -import TabsCreator from '../tabs-creator'; +import ContentBridge from '../content-bridge'; + +const content = new ContentBridge(); $(() => { const date = new Date().getFullYear(); $('#copyright').append(`${date} Nuxeo`); - ServiceWorkerBridge.INSTANCE.browserStore.get('server', (items) => { - $('#apache').click(() => { - TabsCreator.INSTANCE.createTabs('http://www.apache.org/licenses/LICENSE-2.0', items.server.tabId); - }); - $('#feedback').click(() => { - TabsCreator.INSTANCE.createTabs('https://portal.prodpad.com/40c295d6-739d-11e7-9e52-06df22ffaf6f', items.server.tabId); - }); + $('#apache').click(() => { + content.loadExtensionTab( + 'http://www.apache.org/licenses/LICENSE-2.0' + ); + }); + $('#feedback').click(() => { + content.loadExtensionTab( + 'https://portal.prodpad.com/40c295d6-739d-11e7-9e52-06df22ffaf6f' + ); + }); + $('#apache').click(() => { + content.loadExtensionTab( + 'http://www.apache.org/licenses/LICENSE-2.0' + ); }); - ServiceWorkerBridge.browserStore.get('server', (items) => { - $('#apache').click(() => { - TabsCreator.INSTANCE.createTabs('http://www.apache.org/licenses/LICENSE-2.0', items.server.tabId); - }); - $('#feedback').click(() => { - TabsCreator.INSTANCE.createTabs('https://portal.prodpad.com/40c295d6-739d-11e7-9e52-06df22ffaf6f', items.server.tabId); - }); + $('#feedback').click(() => { + content.loadExtensionTab( + 'https://portal.prodpad.com/40c295d6-739d-11e7-9e52-06df22ffaf6f' + ); }); }); diff --git a/src/content-bridge.js b/src/content-bridge.js new file mode 100644 index 00000000..b3e97864 --- /dev/null +++ b/src/content-bridge.js @@ -0,0 +1,49 @@ +/* eslint-disable comma-dangle */ +class ContentBridge { + // eslint-disable-next-line class-methods-use-this + getCurrentTabUrl(callback) { + chrome.runtime.sendMessage( + { + extension: 'nuxeo-web-extension', + service: 'content', + action: 'getCurrentTabUrl', + params: [] + }, + (response) => { + callback.apply(null, [response.server]); + }, + ); + } + + // eslint-disable-next-line class-methods-use-this + disableTabExtension() { + chrome.runtime.sendMessage( + { + extension: 'nuxeo-web-extension', + service: 'content', + action: 'disableTabExtension', + params: [] + }, + (response) => { + console.log(response); + }, + ); + } + + // eslint-disable-next-line class-methods-use-this + reloadTab() { + chrome.runtime.sendMessage( + { + extension: 'nuxeo-web-extension', + service: 'content', + action: 'reloadTab', + params: [] + }, + (response) => { + console.log(response); + }, + ); + } +} + +export default ContentBridge; diff --git a/src/content/index.html b/src/content/index.html deleted file mode 100644 index 1f551eab..00000000 --- a/src/content/index.html +++ /dev/null @@ -1 +0,0 @@ - diff --git a/src/content/index.js b/src/content/index.js deleted file mode 100644 index e69de29b..00000000 diff --git a/src/content/main.js b/src/content/main.js new file mode 100644 index 00000000..6294ff69 --- /dev/null +++ b/src/content/main.js @@ -0,0 +1,179 @@ +/* eslint-disable comma-dangle */ +/* eslint-disable class-methods-use-this */ +/* eslint-disable max-classes-per-file */ +/* +Copyright 2016-2024 Nuxeo + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + +http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +import ServiceWorkerBridge from '../service-worker-bridge'; + +const serviceWorkerBridge = new ServiceWorkerBridge(); + +class Content { + constructor() { + this.browserStore = serviceWorkerBridge.browserStore; + + // fetch back the server url from the browser store + this.browserStore.get(['server']).then((data) => { + this.server = data.server; + }); + } + + loadExtensionTab(url) { + chrome.tabs.query({ active: true }, (tabs) => { + const index = tabs[0].index; + chrome.tabs.create({ + url, + openerTabId: this.server.tabId, + selected: false, + index: index + 1, + }); + }); + } + + pageActionOnNuxeo(tabInfo) { + const re = /.*\.nuxeo$/; + const login = '/login.jsp'; + chrome.cookies.getAll( + { + url: tabInfo.url, + name: 'JSESSIONID', + }, + (cookies) => { + if (!cookies || cookies.length === 0) { + return; // Exit the function if cookies is not defined or if it's an empty array + } + chrome.pageAction.hide(tabInfo.id); + cookies.forEach((cookie) => { + if (cookie.value.match(re) && tabInfo.url.indexOf(login) < 0) { + chrome.pageAction.show(tabInfo.id); + } + }); + } + ); + } + + disableExt(tabInfo) { + chrome.pageAction.hide(tabInfo.id); + } + + disableTabExtension() { + chrome.tabs.query( + { lastFocusedWindow: true, active: true }, + this.getTabToDisable + ); + } + + getInfoForTab(tabs) { + if (tabs.length > 0) { + chrome.tabs.get(tabs[0].id, this.pageActionOnNuxeo); + } + } + + getTabToDisable(tabs) { + if (tabs.length > 0) { + chrome.tabs.get(tabs[0].id, this.disableExt); + } + } + + onChange() { + chrome.tabs.query( + { lastFocusedWindow: true, active: true }, + this.getInfoForTab + ); + } + + getCurrentTabUrl(callback) { + chrome.tabs + .query({ + active: true, + currentWindow: true, + }) + .then((tabs) => { + if (!tabs || tabs.length === 0) { + return; + } + const nxPattern = /(^https?:\/\/[A-Za-z_\.0-9:-]+\/[A-Za-z_\.0-9-]+\/)(?:(?:nxdoc|nxpath|nxsearch|nxadmin|nxhome|nxdam|nxdamid|site\/[A-Za-z_\.0-9-]+)\/[A-Za-z_\.0-9-]+|view_documents\.faces|ui\/#!\/|[a-zA-Z0-9_%]+\/?|view_domains\.faces|home\.html|view_home\.faces)/; + const [tab] = tabs; + const matchGroups = nxPattern.exec(tab.url); + if (!matchGroups) { + callback(null); + return; + } + const [, url] = matchGroups; + this.browserStore + .set({ server: { url, tabId: tab.id } }) + .then((store) => { + this.server = store.server; + return this.server; + }) + .then((server) => callback(server.url)); + }) + .catch((error) => { + console.error(error); + }); + } + + onTabActivated(activeInfo) { + chrome.tabs.get(activeInfo.tabId, this.pageActionOnNuxeo); + } +} + +class ContentMessageHandler { + constructor(content) { + this.content = content; + } + + handle(request, sender, sendResponse) { + if (request.extension !== 'nuxeo-web-extension') { + return undefined; + } + const service = this.content[request.service]; + if (request.service !== 'content') { + return undefined; + } + if (typeof service[request.action] !== 'function') { + sendResponse({ error: 'Invalid action' }); + return false; + } + Promise.resolve(service[request.action](...request.params)) + .then((result) => { + sendResponse(result); + }) + .catch((error) => { + sendResponse({ error: error.toString() }); + }); + return true; + } +} + +const content = new Content(); +const handler = new ContentMessageHandler(content); + +chrome.tabs.onActivated.addListener((activeInfo) => { + chrome.runtime.sendMessage( + { + extension: 'nuxeo-web-extension', + service: 'worker', + action: 'isEnabled', + }, + (response) => { + if (!response) return; + content.onTabActivated(activeInfo); + } + ); +}); + +chrome.runtime.onMessage.addListener((request, sender, sendResponse) => handler.handle(request, sender, sendResponse)); diff --git a/src/main/browser-store.js b/src/main/browser-store.js index 33326423..cb787a41 100644 --- a/src/main/browser-store.js +++ b/src/main/browser-store.js @@ -1,6 +1,4 @@ class BrowserStore { - static INSTANCE = new BrowserStore(); - constructor(namespace = 'nuxeo-browser-extension.') { this.namespace = namespace; } diff --git a/src/main/chrome-notifier.js b/src/main/chrome-notifier.js index fd540118..fd4e303c 100644 --- a/src/main/chrome-notifier.js +++ b/src/main/chrome-notifier.js @@ -1,3 +1,4 @@ +/* eslint-disable class-methods-use-this */ /* Copyright 2016-2024 Nuxeo @@ -15,14 +16,16 @@ limitations under the License. */ class ChromeNotifier { - static INSTANCE = new ChromeNotifier(); + constructor(worker) { + this.worker = worker; + } - notification = (idP, titleP, messageP, img, interaction, clickHandler) => { + notification(id, title, message, img, interaction, clickHandler) { const click = clickHandler; - createNotification(idP, { + chrome.notifications.create(id, { type: 'basic', - title: titleP, - message: messageP, + title, + message, iconUrl: img, requireInteraction: interaction, }) @@ -35,18 +38,17 @@ class ChromeNotifier { if (clickHandler) { chrome.notifications.onClicked.addListener((notificationId) => { console.log(`notification clicked ${notificationId}`); - if (notificationId === idP) { + if (notificationId === id) { console.log('executing handler'); click(); } }); } - }; + } - createNotification = (id, options) => chrome.notifications.create(id, options); - - // eslint-disable-next-line max-len - addNotificationClickListener = (clickHandler) => chrome.notifications.onClicked.addListener((tab) => clickHandler(tab.id)); + addNotificationClickListener(clickHandler) { + return chrome.notifications.onClicked.addListener((tab) => clickHandler(tab.id)); + } } export default ChromeNotifier; diff --git a/src/main/connect-locator.js b/src/main/connect-locator.js index 6d5ee874..e9b28e2c 100644 --- a/src/main/connect-locator.js +++ b/src/main/connect-locator.js @@ -1,15 +1,17 @@ -import BrowserStore from './browser-store'; - class ConnectLocator { - getURL = () => { - const value = BrowserStore.INSTANCE.get({ 'connect-url': 'https://connect.nuxeo.com' }) + constructor(worker) { + this.browserStore = worker.browserStore; + } + + getURL() { + const value = this.browserStore.get({ 'connect-url': 'https://connect.nuxeo.com' }) .then((data) => data['connect-url']) .catch((error) => console.error(error)); return value; } - setURL = (url) => { - const value = BrowserStore.INSTANCE.set({ 'connect-url': url.toString() }) + setURL(url) { + const value = this.browserStore.set({ 'connect-url': url.toString() }) .then((data) => data['connect-url']) .catch((error) => console.error(error)); return value; diff --git a/src/main/designer-live-preview.js b/src/main/designer-live-preview.js index 1af9600c..f1f6987b 100644 --- a/src/main/designer-live-preview.js +++ b/src/main/designer-live-preview.js @@ -1,3 +1,4 @@ +/* eslint-disable comma-dangle */ /* Copyright 2016-2024 Nuxeo @@ -15,13 +16,12 @@ limitations under the License. */ class DesignerLivePreview { - static INSTANCE = new DesignerLivePreview(); - - userCookies = ''; - - redirectedUrls = {}; - - nuxeoBaseUrl = 'http://localhost:8080/nuxeo/'; + constructor(worker) { + this.nuxeo = worker.nuxeo; + this.connectLocator = worker.connectLocator; + this.userCookies = ''; + this.redirectedUrls = {}; + } storeRedirectedUrlsLocally(json) { Object.keys(json).forEach((basePath) => { @@ -33,7 +33,7 @@ class DesignerLivePreview { const files = Object.keys(json[basePath]); if (files.length > 0) { files.forEach((resource) => { - const nuxeoInstanceResource = `${this.nuxeoBaseUrl}${nuxeoInstanceBasePath}/${resource}`; + const nuxeoInstanceResource = `${this.nuxeo.baseUrl}${nuxeoInstanceBasePath}/${resource}`; // FIXME Warning this replace should be removed (needs fixing on connect side) const connectResource = json[basePath][resource].replace( /http:\/\//, @@ -44,7 +44,7 @@ class DesignerLivePreview { }); } }); - }; + } redirectRequestToConnectIfNeeded(details) { // Sometimes, URLs contain '//' which would prevent us from finding the url for redirect @@ -58,8 +58,9 @@ class DesignerLivePreview { return { redirectUrl, }; - }; + } + // eslint-disable-next-line class-methods-use-this addCookieHeaderForConnectRequest(details) { const requestHeaders = details.requestHeaders; @@ -74,7 +75,7 @@ class DesignerLivePreview { // We need to add cookies as they are stripped by browser requestHeaders.push({ name: 'Cookie', - value: userCookies, + value: this.userCookies, }); return { requestHeaders, @@ -95,7 +96,7 @@ class DesignerLivePreview { // requestHeaders, // }; // }); - }; + } addNewResources(details) { // Detects when Studio users save changes to a new resource in Designer @@ -107,14 +108,14 @@ class DesignerLivePreview { resourcePath = resourcePath.replace(/\/\//, '/'); const connectResource = `${details.url}${resourcePath}`; resourcePath = resourcePath.replace(/^\/(nuxeo\.war\/?\/)?/, ''); - const nuxeoResource = `${this.nuxeoBaseUrl}${resourcePath}`; + const nuxeoResource = `${this.nuxeo.baseUrl}${resourcePath}`; // If there is no redirected URL to the customized resource yet, add one if (!(nuxeoResource in this.redirectedUrls)) { this.redirectedUrls[nuxeoResource] = connectResource; console.log(`New resource added: ${resourcePath}`); } }); - }; + } revertToDefault(details) { // Detects when Studio users revert their customizations to default @@ -133,76 +134,79 @@ class DesignerLivePreview { enable(projectName, nuxeoInstanceBaseUrl) { // URL's port is not allowed in urlPattern, thus had to be removed. - this.nuxeoBaseUrl = nuxeoInstanceBaseUrl; + this.nuxeo.baseUrl = nuxeoInstanceBaseUrl; const urlPattern = `${nuxeoInstanceBaseUrl.replace(/:\d+/, '')}*`; - const connectLocation = CONNECT_URL.toString(); - const workspaceLocation = new URL( - `/nuxeo/site/studio/v2/project/${projectName}/workspace/ws.resources`, - CONNECT_URL - ).toString(); - - chrome.cookies.getAll({ domain: CONNECT_URL.hostname }).then((cookies) => { - const cookieHeader = cookies - .map((x) => `${x.name}=${x.value}`) - .join('; '); - userCookies = cookieHeader; - }); - - chrome.webRequest.onBeforeRequest.addListener( - redirectRequestToConnectIfNeeded, - { - urls: [urlPattern], - }, - ['blocking'] - ); + this.connectLocator.getURL().then((connectUrl) => { + const connectLocation = connectUrl.toString(); + const workspaceLocation = new URL( + `/nuxeo/site/studio/v2/project/${projectName}/workspace/ws.resources`, + connectUrl + ).toString(); + + chrome.cookies + .getAll({ domain: connectUrl.hostname }) + .then((cookies) => { + const cookieHeader = cookies + .map((x) => `${x.name}=${x.value}`) + .join('; '); + this.userCookies = cookieHeader; + }); // This was missing + + chrome.webRequest.onBeforeRequest.addListener( + this.redirectRequestToConnectIfNeeded, + { + urls: [urlPattern], + }, + ['blocking'] + ); - chrome.webRequest.onBeforeRequest.addListener( - addNewResources, - { - urls: [workspaceLocation], - }, - ['requestBody'] - ); + chrome.webRequest.onBeforeRequest.addListener( + this.addNewResources, + { + urls: [workspaceLocation], + }, + ['requestBody'] + ); - const extraInfoSpec = ['blocking', 'requestHeaders']; - if ( - Object.prototype.hasOwnProperty.call( - chrome.webRequest.OnBeforeSendHeadersOptions, - 'EXTRA_HEADERS' - ) - ) { - extraInfoSpec.push('extraHeaders'); - } - // https://groups.google.com/a/chromium.org/g/chromium-extensions/c/vYIaeezZwfQ - chrome.webRequest.onBeforeSendHeaders.addListener( - addCookieHeaderForConnectRequest, - { - urls: [`${connectLocation}/*`], - }, - extraInfoSpec - ); + const extraInfoSpec = ['blocking', 'requestHeaders']; + if ( + Object.prototype.hasOwnProperty.call( + chrome.webRequest.OnBeforeSendHeadersOptions, + 'EXTRA_HEADERS' + ) + ) { + extraInfoSpec.push('extraHeaders'); + } + // https://groups.google.com/a/chromium.org/g/chromium-extensions/c/vYIaeezZwfQ + chrome.webRequest.onBeforeSendHeaders.addListener( + this.addCookieHeaderForConnectRequest, + { + urls: [`${connectLocation}/*`], + }, + extraInfoSpec + ); - chrome.webRequest.onCompleted.addListener( - revertToDefault, - { - urls: [`${connectLocation}/*`], - }, - ['responseHeaders'] - ); + chrome.webRequest.onCompleted.addListener( + this.revertToDefault, + { + urls: [`${connectLocation}/*`], + }, + ['responseHeaders'] + ); - // fetch available resources from Studio Project - return fetch(workspaceLocation, { - credentials: 'include', - }).then((response) => { - if (response.ok) { + // fetch available resources from Studio Project + return fetch(workspaceLocation, { + credentials: 'include', + }).then((response) => { + if (!response.ok) { + throw new Error('Not logged in to connect.'); + } return response.json().then((json) => { - storeRedirectedUrlsLocally(json); - console.log( - `Enabled Designer Live Preview for ${this.nuxeoBaseUrl}` - ); + this.storeRedirectedUrlsLocally(json); + console.log(`Enabled Designer Live Preview for ${this.nuxeo.baseUrl}`); + return true; }); - } - throw new Error('Not logged in to connect.'); + }); }); } @@ -210,14 +214,14 @@ class DesignerLivePreview { return new Promise((resolve) => { console.log('Disabling Designer Live Preview'); chrome.webRequest.onBeforeRequest.removeListener( - redirectRequestToConnectIfNeeded + this.redirectRequestToConnectIfNeeded ); - chrome.webRequest.onBeforeRequest.removeListener(revertToDefault); + chrome.webRequest.onBeforeRequest.removeListener(this.revertToDefault); chrome.webRequest.onBeforeSendHeaders.removeListener( - addCookieHeaderForConnectRequest + this.addCookieHeaderForConnectRequest ); - chrome.webRequest.onCompleted.removeListener(addNewResources); - redirectedUrls = {}; + chrome.webRequest.onCompleted.removeListener(this.addNewResources); + this.redirectedUrls = {}; resolve(); }); } diff --git a/src/main/frontend-message-handler.js b/src/main/frontend-message-handler.js deleted file mode 100644 index 5e589f7c..00000000 --- a/src/main/frontend-message-handler.js +++ /dev/null @@ -1,45 +0,0 @@ -import BrowserStore from './browser-store'; -import ChromeNotifier from './chrome-notifier'; -import ConnectLocator from './connect-locator'; -import DesignerLivePreview from './designer-live-preview'; -import RepositoryIndexer from './repository-indexer'; -import StudioHotReloader from './studio-hot-reloader'; - -// expose services to the popup -class FrontendMessageHandler { - static INSTANCE = new FrontendMessageHandler(); - - browserStore = BrowserStore.INSTANCE; - - chromeNotifier = ChromeNotifier.INSTANCE; - - connectLocator = ConnectLocator.INSTANCE; - - designeLivePreview = DesignerLivePreview.INSTANCE; - - repositoryIndexer = RepositoryIndexer.INSTANCE; - - studioHotReloader = StudioHotReloader.INSTANCE; - - handle(request, sender, sendResponse) { - const service = this[request.service]; - if (!service) { - sendResponse({ error: 'Invalid service' }); - return false; - } - if (typeof service[request.action] !== 'function') { - sendResponse({ error: 'Invalid action' }); - return false; - } - Promise.resolve(service[request.action].apply(service, request.params)) - .then((result) => { - sendResponse(result); - }) - .catch((error) => { - sendResponse({ error: error.toString() }); - }); - return true; // Indicates you will call sendResponse asynchronously - } -} - -export default FrontendMessageHandler; diff --git a/src/main/main-chrome.js b/src/main/main-chrome.js index 8fb93053..373bc92c 100644 --- a/src/main/main-chrome.js +++ b/src/main/main-chrome.js @@ -16,236 +16,30 @@ See the License for the specific language governing permissions and limitations under the License. */ -import FrontendMessageHandler from './frontend-message-handler'; -import DOMPurify from 'dompurify'; -import Nuxeo from 'nuxeo'; +import ServiceWorker from './service-worker'; +import ServiceWorkerMessageHandler from './service-worker-message-handler'; -const uuidPattern = /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i; -const pathPattern = /^\//; -const selectFromPattern = /SELECT .* FROM /i; -const webuiPattern = /nuxeo\/ui\/#!\//; - -class ServiceWorker { - constructor(url) { - this.nuxeo = new Nuxeo({ - baseURL: url, - }); - } - - pageActionOnNuxeo(tabInfo) { - const re = /.*\.nuxeo$/; - const login = '/login.jsp'; - chrome.cookies.getAll( - { - url: tabInfo.url, - name: 'JSESSIONID', - }, - (cookies) => { - if (!cookies || cookies.length === 0) { - return; // Exit the function if cookies is not defined or if it's an empty array - } - chrome.pageAction.hide(tabInfo.id); - cookies.forEach((cookie) => { - if (cookie.value.match(re) && tabInfo.url.indexOf(login) < 0) { - chrome.pageAction.show(tabInfo.id); - } - }); - } - ); - }; - - disableExt = (tabInfo) => { - chrome.pageAction.hide(tabInfo.id); - }; - - getInfoForTab(tabs) { - if (tabs.length > 0) { - chrome.tabs.get(tabs[0].id, this.pageActionOnNuxeo); - } - } - - getTabToDisable(tabs) { - if (tabs.length > 0) { - chrome.tabs.get(tabs[0].id, this.disableExt); - } - } - - onChange() { - chrome.tabs.query( - { lastFocusedWindow: true, active: true }, - this.getInfoForTab, - ); - } - - disableTabExtension() { - // eslint-disable-line no-unused-vars - chrome.tabs.query( - { lastFocusedWindow: true, active: true }, - this.getTabToDisable, - ); - } - - createTabs = (url, tabId) => { - chrome.tabs.query( - { - active: true, - }, - (tabs) => { - const index = tabs[0].index; - chrome.tabs.create({ - url, - openerTabId: tabId, - selected: false, - index: index + 1, - }); - }, - ); - }; - - openDoc(input) { - if (uuidPattern.test(input)) { - this.openDocFromId(input); - } else if (pathPattern.test(input)) { - this.openDocFromPath(input); - } else { - console.error(`Invalid input ${input}`); - } - } - - openDocFromId(id) { - this.doOpenDoc(this.nuxeo.request(`/id/${id}`)); - } - - openDocFromPath(path) { - this.doOpenDoc(this.nuxeo.request(`/path/${path}`)); - } - - doOpenDoc(request) { - const onWebUI = webuiPattern.exec(nuxeo.baseURL); - request - .schemas('*') - .enrichers({ document: ['acls', 'permissions'] }) - .get() - .then((doc) => { - function pathOf(uid) { - if (onWebUI) { - return `ui/#!/doc/${uid}`; - } - return `nxdoc/default/${uid}/view_documents`; - } - const docUrl = nuxeo.baseURL.concat(pathOf(doc.uid)); - this.createTabs(docUrl, studioExt.server.tabId); - }) - .catch((error) => { - console.log(error); - }); - } - - suggestDocument(text, suggest) { - if (uuidPattern.test(text)) { - this.openDocFromId(text); - return; - } - if (pathPattern.test(text)) { - this.openDocFromPath(text); - return; - } - const jsonQueryOf = (query) => { - if (selectFromPattern.test(query)) { - return text; - } - return `SELECT * FROM Document WHERE ecm:fulltext = "${text}"`; - }; - const query = jsonQueryOf(text).replace(/'/g, '"'); - const suggestions = []; - nuxeo - .repository() - .schemas(['dublincore', 'common', 'uid']) - .query({ - query, - sortBy: 'dc:modified', - }) - .then((res) => { - if (res.entries.length > 0) { - res.entries.forEach((doc) => { - suggestions.push({ - content: doc.uid, - description: DOMPurify.sanitize( - `${doc.title} ${doc.path}`, - { ALLOWED_TAGS: ['match', 'dim'] }, - ), - }); - }); - } - if (res.entries.length > 5) { - chrome.omnibox.setDefaultSuggestion({ - description: DOMPurify.sanitize( - 'Want more results? Try the fulltext searchbox from the Nuxeo Dev Tools extension window.', - { ALLOWED_TAGS: ['match', 'dim'] }, - ), - }); - } - suggest(suggestions); - }); - } -} - -function getCurrentTabUrl(callback) { - chrome.tabs - .query({ - active: true, - currentWindow: true, - }) - .then((tabs) => { - if (!tabs || tabs.length === 0) { - return; - } - const nxPattern = /(^https?:\/\/[A-Za-z_\.0-9:-]+\/[A-Za-z_\.0-9-]+\/)(?:(?:nxdoc|nxpath|nxsearch|nxadmin|nxhome|nxdam|nxdamid|site\/[A-Za-z_\.0-9-]+)\/[A-Za-z_\.0-9-]+|view_documents\.faces|ui\/#!\/|[a-zA-Z0-9_%]+\/?|view_domains\.faces|home\.html|view_home\.faces)/; - const [tab] = tabs; - const matchGroups = nxPattern.exec(tab.url); - if (!matchGroups) { - callback(null); - return; - } - const [, url] = matchGroups; - this.browserStore - .set({ server: { url, tabId: tab.id } }) - .then(() => callback(url)); - }) - .catch((error) => { - console.error(error); - }); -} - -let worker; +const handler = new ServiceWorkerMessageHandler(); chrome.omnibox.onInputChanged.addListener((text, suggest) => { - getCurrentTabUrl((url) => { - worker = new ServiceWorker(url); - worker.suggestDocument(text, suggest); + chrome.runtime.sendMessage({ service: 'content', action: 'getCurrentTabUrl' }, (url) => { + handler.worker = new ServiceWorker(url); + handler.worker.suggestDocument(text, suggest); }); }); chrome.omnibox.onInputEntered.addListener((text) => { - if (!worker) { + if (!handler.worker) { return; } - worker.openDocument(text); + handler.worker.openDocument(text); }); chrome.webRequest.onCompleted.addListener(() => { - if (!worker) { // Check if worker exists + if (!handler.worker) { // Check if worker exists return; } - worker.onChange(); + handler.worker.onChange(); }, { urls: [''] }); -chrome.tabs.onActivated.addListener((activeInfo) => { - if (!worker) { // Check if worker exists - return; - } - chrome.tabs.get(activeInfo.tabId, worker.pageActionOnNuxeo); -}); - -// eslint-disable-next-line max-len -chrome.runtime.onMessage.addListener((request, sender, sendResponse) => FrontendMessageHandler.INSTANCE.handle(request, sender, sendResponse)); +chrome.runtime.onMessage.addListener((request, sender, sendResponse) => handler.handle(request, sender, sendResponse)); diff --git a/src/main/manifest-chrome.json b/src/main/manifest-chrome.json index f282e4b4..b7b3d58e 100644 --- a/src/main/manifest-chrome.json +++ b/src/main/manifest-chrome.json @@ -11,6 +11,12 @@ "background": { "service_worker": "main.js" }, + "content_scripts": [ + { + "matches": [""], + "js": ["content/main/index.js"] + } + ], "permissions": [ "storage", "cookies", diff --git a/src/main/repository-indexer.js b/src/main/repository-indexer.js index be0361a5..23026c88 100644 --- a/src/main/repository-indexer.js +++ b/src/main/repository-indexer.js @@ -14,14 +14,18 @@ See the License for the specific language governing permissions and limitations under the License. */ -import ServerConnector from './server-connector'; - class RepositoryIndexer { - withNuxeo = (cb) => { - ServerConnector.fromBrowserStore().then((server) => { + constructor(worker) { + this.browserStore = worker.browserStore; + this.notifier = worker.notifier; + this.nuxeo = worker.nuxeo; + } + + withNuxeo(cb) { + this.browserStore.then((server) => { cb(server.nuxeo); }); - }; + } reindex = () => { this.withNuxeo((nuxeo) => { @@ -29,7 +33,7 @@ class RepositoryIndexer { .operation('Elasticsearch.Index') .execute() .then(() => { - Notifier.INSTANCE.notification( + this.notifier.notification( 'success', 'Success!', 'Your repository index is rebuilding.', @@ -39,7 +43,7 @@ class RepositoryIndexer { }) .catch((e) => { console.error(e); - Notifier.INSTANCE.notification( + this.notifier.notification( 'error', 'Something went wrong...', 'Please try again later.', @@ -50,38 +54,36 @@ class RepositoryIndexer { }); }; - reindexNXQL = (input) => { - this.withNuxeo((nuxeo) => { - nuxeo - .operation('Elasticsearch.Index') - .input(input) - .execute() - .then(() => { - Notifier.INSTANCE.notification( - 'success', - 'Success!', - 'Your repository index is rebuilding.', - '../images/nuxeo-128.png', - false, - ); - }) - .catch((e) => { - console.error(e); - Notifier.INSTANCE.notification( - 'error', - 'Something went wrong...', - 'Please try again later.', - '../images/access_denied.png', - false, - ); - }); - }); - }; + reindexNXQL(input) { + this.nuxeo + .operation('Elasticsearch.Index') + .input(input) + .execute() + .then(() => { + this.notifier.notification( + 'success', + 'Success!', + 'Your repository index is rebuilding.', + '../images/nuxeo-128.png', + false, + ); + }) + .catch((e) => { + console.error(e); + this.notifier.notification( + 'error', + 'Something went wrong...', + 'Please try again later.', + '../images/access_denied.png', + false, + ); + }); + } - reindexDocId = (input) => { - BrowserStore.INSTANCE.get(['server']).then((entries) => { + reindexDocId(input) { + this.browserStore.get(['server']).then((entries) => { const url = entries.server.url; - const nuxeo = newNuxeo({ + const nuxeo = this.newNuxeo({ baseURL: url, }); nuxeo @@ -89,7 +91,7 @@ class RepositoryIndexer { .input(input) .execute() .then(() => { - Notifier.INSTANCE.notification( + this.notifier.notification( 'success', 'Success!', 'Your repository index is rebuilding.', @@ -99,7 +101,7 @@ class RepositoryIndexer { }) .catch((e) => { console.error(e); - Notifier.INSTANCE.notification( + this.notifier.notification( 'error', 'Something went wrong...', 'Please try again later.', @@ -108,7 +110,7 @@ class RepositoryIndexer { ); }); }); - }; + } } export default RepositoryIndexer; diff --git a/src/main/server-connector.js b/src/main/server-connector.js index 39fd57fb..1ed22b07 100644 --- a/src/main/server-connector.js +++ b/src/main/server-connector.js @@ -1,26 +1,16 @@ -import BrowserStore from './browser-store'; - class ServerConnector { - constructor(opts) { - const _opts = opts || {}; - if (window.app.auth) { - _opts.auth = window.app.auth; - } - this.nuxeo = new Nuxeo(_opts); + constructor(worker) { + this.nuxeo = worker.nuxeo; + this.notifier = worker.notifier; + this.content = worker.content; // Workaround until next release of Nuxeo JS client this.nuxeo.SERVER_VERSIONS = Nuxeo.SERVER_VERSIONS; - this.nuxeo.SERVER_VERSIONS.LTS_2019 = nuxeo.SERVER_VERSIONS.LTS_2017; + this.nuxeo.SERVER_VERSIONS.LTS_2019 = Nuxeo.SERVER_VERSIONS.LTS_2017; this.nuxeo.SERVER_VERSIONS.LTS_2019.major = 10; this.nuxeo.SERVER_VERSIONS.LTS_2019.version = '10.10'; } - static fromBrowserStore = () => { - BrowserStore.INSTANCE.get(['server']).then( - (entries) => new ServerConnector({ baseURL: entries.server.url }), - ); - }; - defaultServerError = { id: 'server_error', title: 'Server Error', @@ -29,12 +19,12 @@ class ServerConnector { interaction: false, }; - handleErrors = (error, serverError) => { + handleErrors(error, serverError) { error.response.json().then((json) => { const msg = json.message; const err = error.response.status; if (msg == null) { - Notifier.INSTANCE.notification( + this.notifier.notification( 'no_hot_reload', 'Hot Reload Operation not found.', 'Your current version of Nuxeo does not support the Hot Reload function.', @@ -42,7 +32,7 @@ class ServerConnector { false, ); } else if (err === 401) { - Notifier.INSTANCE.notification( + this.notifier.notification( 'access_denied', 'Access denied!', 'You must have Administrator rights to perform this function.', @@ -50,7 +40,7 @@ class ServerConnector { false, ); } else if (err >= 500) { - Notifier.INSTANCE.notification( + this.notifier.notification( serverError.id, serverError.title, serverError.message, @@ -58,7 +48,7 @@ class ServerConnector { serverError.interaction, ); } else if (err >= 300 && err < 500) { - Notifier.INSTANCE.notification( + this.notifier.notification( 'bad_login', 'Bad Login', 'Your Login and/or Password are incorrect', @@ -66,7 +56,7 @@ class ServerConnector { false, ); } else { - Notifier.INSTANCE.notification( + this.notifier.notification( 'unknown_error', 'Unknown Error', 'An unknown error has occurred. Please try again later.', @@ -75,7 +65,7 @@ class ServerConnector { ); } }); - }; + } execute(script, stopSearch, callback) { const blob = new Nuxeo.Blob({ @@ -102,22 +92,22 @@ class ServerConnector { }); } - restart = (startLoadingRS, stopLoading) => { - disableTabExtension(); - startLoadingRS(); - nuxeo + restart(startLoading, stopLoading) { + this.content.disableTabExtension(); + startLoading(); + this.nuxeo ._http({ method: 'POST', schemas: [], enrichers: [], fetchProperties: [], - url: nuxeo._baseURL.concat('site/connectClient/uninstall/restart'), + url: this.nuxeo._baseURL.concat('site/connectClient/uninstall/restart'), }) .then((res) => { // Handle restart success since 9.10 if (res.status && res.status >= 200 && res.status < 300) { stopLoading(); - Notifier.INSTANCE.notification( + this.notifier.notification( 'info', 'Restarting server...', 'Attempting to restart Nuxeo server.', @@ -125,13 +115,13 @@ class ServerConnector { false, ); setTimeout(() => { - chrome.tabs.reload(studioExt.server.tabId); + this.content.reloadTab(); }, 5000); // Handle errors for 8.10 and FT up to 9.3 } else { console.log(res); stopLoading(); - Notifier.INSTANCE.notification( + this.notifier.notification( 'error', 'Something went wrong...', 'An error occurred.', @@ -149,7 +139,7 @@ class ServerConnector { const err = e.response.status; // Handle restart success for 8.10 and FT up to 9.3 if (msg == null) { - Notifier.INSTANCE.notification( + this.notifier.notification( 'success', 'Success!', 'Nuxeo server is restarting...', @@ -157,11 +147,11 @@ class ServerConnector { false, ); setTimeout(() => { - chrome.tabs.reload(studioExt.server.tabId); + this.content.reloadTab(); }, 4000); // Handle errors since 9.10 } else if (err === 401) { - Notifier.INSTANCE.notification( + this.notifier.notification( 'access_denied', 'Access denied!', 'You must have Administrator rights to perform this function.', @@ -169,7 +159,7 @@ class ServerConnector { false, ); } else if (err >= 500) { - Notifier.INSTANCE.notification( + this.notifier.notification( 'server_error', 'Server Error', 'Please check Studio project and/or dependencies for mismatch and ensure that Dev Mode is activated.', @@ -177,7 +167,7 @@ class ServerConnector { false, ); } else { - Notifier.INSTANCE.notification( + this.notifier.notification( 'unknown_error', 'Unknown Error', 'An unknown error has occurred. Please try again later.', @@ -187,7 +177,7 @@ class ServerConnector { } }); } else if (e instanceof TypeError) { - Notifier.INSTANCE.notification( + this.notifier.notification( 'success', 'Success!', 'Nuxeo server is restarting...', @@ -195,11 +185,11 @@ class ServerConnector { false, ); setTimeout(() => { - chrome.tabs.reload(studioExt.server.tabId); + this.content.reloadTab(); }, 4000); } }); - }; + } } export default ServerConnector; diff --git a/src/main/service-worker-message-handler.js b/src/main/service-worker-message-handler.js new file mode 100644 index 00000000..3251628c --- /dev/null +++ b/src/main/service-worker-message-handler.js @@ -0,0 +1,63 @@ +// Purpose: Expose services to the popup and the content handler +import ContentBridge from '../content-bridge'; +import ServiceWorker from './service-worker'; + +class ServiceWorkerMessageHandler { + constructor() { + this.content = new ContentBridge(); + } + + handle(request, sender, sendResponse) { + if (request.extension !== 'nuxeo-web-extension') { + return undefined; + } + + const setupWorkerIfNeeded = () => { + if (this.worker) { + // If the worker already exists, return a promise that resolves immediately + return Promise.resolve(); + } + // If the worker doesn't exist, return a promise that resolves after setting up the worker + return new Promise((resolve, reject) => { + this.content.getCurrentTabUrl((url) => { + if (!url) { + reject(new Error('No URL')); + } else { + this.worker = new ServiceWorker(url); + resolve(); + } + }); + }); + }; + + const handleRequest = () => { + console.log(`ServiceWorkerMessageHandler.handle(${JSON.stringify(request)}, ${JSON.stringify(sender)}) called`); + const service = this.worker[request.service]; + if (!service) { + sendResponse({ error: 'Invalid action' }); + return; + } + if (typeof service[request.action] !== 'function') { + sendResponse({ error: 'Invalid action' }); + return; + } + Promise.resolve(service[request.action](...request.params)) + .then((result) => { + sendResponse(result); + }) + .catch((error) => { + sendResponse({ error: error.toString() }); + }); + }; + + // First, setup the worker if needed. Then, handle the request. + setupWorkerIfNeeded().then(handleRequest).catch((error) => { + console.error(error); + sendResponse({ error: error.toString() }); + }); + + return true; // Indicates you will call sendResponse asynchronously + } +} + +export default ServiceWorkerMessageHandler; diff --git a/src/main/service-worker.js b/src/main/service-worker.js new file mode 100644 index 00000000..23dc9913 --- /dev/null +++ b/src/main/service-worker.js @@ -0,0 +1,131 @@ +/* eslint-disable comma-dangle */ +import DOMPurify from 'dompurify'; +import Nuxeo from 'nuxeo'; + +import BrowserStore from './browser-store'; +import ChromeNotifier from './chrome-notifier'; +import ConnectLocator from './connect-locator'; +import DesignerLivePreview from './designer-live-preview'; +import RepositoryIndexer from './repository-indexer'; +import ServerConnector from './server-connector'; +import StudioHotReloader from './studio-hot-reloader'; + +const uuidPattern = /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i; +const pathPattern = /^\//; +const selectFromPattern = /SELECT .* FROM /i; +const webuiPattern = /nuxeo\/ui\/#!\//; + +class ServiceWorker { + constructor(url) { + // sub-componments takes reference to others in construtors + // to avoid indirect references, so the creation order is important + this.nuxeo = new Nuxeo({ baseURL: url }); + this.browserStore = new BrowserStore(this); + this.chromeNotifier = new ChromeNotifier(this); + this.connectLocator = new ConnectLocator(this); + this.designerLivePreview = new DesignerLivePreview(this); + this.repositoryIndexer = new RepositoryIndexer(this); + this.serverConnector = new ServerConnector(this); + this.studioHotReloader = new StudioHotReloader(this); + } + + bindClassToContainer(key, clazz) { + this.container.bind(key).to(clazz); + this[key] = this.container.get(key); + } + + openDoc(input) { + if (uuidPattern.test(input)) { + this.openDocFromId(input); + } else if (pathPattern.test(input)) { + this.openDocFromPath(input); + } else { + console.error(`Invalid input ${input}`); + } + } + + openDocFromId(id) { + this.doOpenDoc(this.nuxeo.request(`/id/${id}`)); + } + + openDocFromPath(path) { + this.doOpenDoc(this.nuxeo.request(`/path/${path}`)); + } + + doOpenDoc(request) { + const onWebUI = webuiPattern.exec(this.nuxeo.baseURL); + request + .schemas('*') + .enrichers({ document: ['acls', 'permissions'] }) + .get() + .then((doc) => { + function pathOf(uid) { + if (onWebUI) { + return `ui/#!/doc/${uid}`; + } + return `nxdoc/default/${uid}/view_documents`; + } + const docUrl = this.nuxeo.baseURL.concat(pathOf(doc.uid)); + chrome.runtime.sendMessage({ + service: 'content', + action: 'createTab', + params: [docUrl], + }); + }) + .catch((error) => { + console.log(error); + }); + } + + suggestDocument(text, suggest) { + if (uuidPattern.test(text)) { + this.openDocFromId(text); + return; + } + if (pathPattern.test(text)) { + this.openDocFromPath(text); + return; + } + const jsonQueryOf = (query) => { + if (selectFromPattern.test(query)) { + return text; + } + return `SELECT * FROM Document WHERE ecm:fulltext = "${text}"`; + }; + const query = jsonQueryOf(text).replace(/'/g, '"'); + const suggestions = []; + this.nuxeo + .repository() + .schemas(['dublincore', 'common', 'uid']) + .query({ + query, + sortBy: 'dc:modified', + }) + .then((res) => { + if (res.entries.length > 0) { + res.entries.forEach((doc) => { + const sanitizedDoc = DOMPurify.sanitize( + `${doc.title} ${doc.path}`, + { ALLOWED_TAGS: ['match', 'dim'] } + ); + suggestions.push({ + content: doc.uid, + description: sanitizedDoc, + }); + }); + } + if (res.entries.length > 5) { + const sanitizedDoc = DOMPurify.sanitize( + 'Want more results? Try the fulltext searchbox from the Nuxeo Dev Tools extension window.', + { ALLOWED_TAGS: ['match', 'dim'] } + ); + chrome.omnibox.setDefaultSuggestion({ + description: sanitizedDoc, + }); + } + suggest(suggestions); + }); + } +} + +export default ServiceWorker; diff --git a/src/main/studio-hot-reloader.js b/src/main/studio-hot-reloader.js index eafa7e3e..bf431753 100644 --- a/src/main/studio-hot-reloader.js +++ b/src/main/studio-hot-reloader.js @@ -1,3 +1,4 @@ +/* eslint-disable comma-dangle */ /* Copyright 2016-2024 Nuxeo @@ -14,9 +15,6 @@ See the License for the specific language governing permissions and limitations under the License. */ -import ServerConnector from './server-connector'; -import BrowserStore from './browser-store'; - const checkDependencies = `import groovy.json.JsonOutput; import org.nuxeo.connect.packages.PackageManager; import org.nuxeo.connect.packages.dependencies.TargetPlatformFilterHelper; @@ -40,164 +38,167 @@ def dependencies = snapshotPkg == null ? null : snapshotPkg.getDependencies(); println JsonOutput.toJson([studio: pkgName, nx: nxInstance, studioDistrib: targetPlatform, match: match, deps: dependencies]);`; class StudioHotReloader { - static INSTANCE = new StudioHotReloader(); + constructor(worker) { + this.nuxeo = worker.nuxeo; + this.browserStore = worker.browserStore; + this.notifier = worker.notifier; + this.serverConnector = worker.serverConnector; - constructor() { - BrowserStore.INSTANCE.get({ dependencyMismatch: false }).catch( - (error) => { - console.error(error); - }, - ); + this.browserStore.get({ dependencyMismatch: false }).catch((error) => { + console.error(error); + }); } - reload = (startLoading, stopLoading, validate, showDependencyError) => { - ServerConnector.fromBrowserStore().then((server) => { - const nuxeo = server.nuxeo; - startLoading(); - nuxeo - .operation('Service.HotReloadStudioSnapshot') - .params({ - validate, - }) - .execute() - .then((res) => { + reload(startLoading, stopLoading, validate, showDependencyError) { // should mainly go in server-connector.js + startLoading(); + this.nuxeo + .operation('Service.HotReloadStudioSnapshot') + .params({ + validate, + }) + .execute() + .then((res) => { + try { + stopLoading(); + } catch (e) { + // Popup is closed + } + if (res.length > 0 && res[0].status && res[0].status === 'success') { + this.notifier.notification( + res[0].status, + 'Success!', + res[0].message, + '../images/nuxeo-128.png', + false + ); + chrome.tabs.reload(window.studioExt.server.tabId); + } else if (res.status && res.status === 204) { + this.notifier.notification( + 'success', + 'Success!', + 'A Hot Reload has successfully been completed.', + '../images/nuxeo-128.png', + false + ); + chrome.tabs.reload(window.studioExt.server.tabId); + // Error handling for Nuxeo 9.3 and later + } else if ( + res.length > 0 + && res[0].status + && res[0].status === 'error' + ) { + this.notifier.notification( + res[0].status, + 'Error', + res[0].message, + '../images/access_denied.png', + false + ); + } else if ( + res.length > 0 + && res[0].status + && res[0].status === 'updateInProgress' + ) { + this.notifier.notification( + res[0].status, + 'Error', + res[0].message, + '../images/access_denied.png', + false + ); + } else if ( + res.length > 0 + && res[0].status + && res[0].status === 'DEPENDENCY_MISMATCH' + ) { + this.notifier.notification( + res[0].status, + 'Dependency Mismatch', + res[0].message, + '../images/access_denied.png', + false + ); + console.log(res[0].message); + const uninstalledDeps = res[0].deps || ''; + this.browserStore.set({ + dependencyMismatch: true, + uninstalledDeps, + }); try { - stopLoading(); + showDependencyError(uninstalledDeps); } catch (e) { // Popup is closed } - if (res.length > 0 && res[0].status && res[0].status === 'success') { - Notifier.INSTANCE.notification( - res[0].status, - 'Success!', - res[0].message, - '../images/nuxeo-128.png', - false, - ); - chrome.tabs.reload(window.studioExt.server.tabId); - } else if (res.status && res.status === 204) { - Notifier.INSTANCE.notification( - 'success', - 'Success!', - 'A Hot Reload has successfully been completed.', - '../images/nuxeo-128.png', - false, - ); - chrome.tabs.reload(window.studioExt.server.tabId); - // Error handling for Nuxeo 9.3 and later - } else if ( - res.length > 0 - && res[0].status - && res[0].status === 'error' - ) { - Notifier.INSTANCE.notification( - res[0].status, - 'Error', - res[0].message, - '../images/access_denied.png', - false, - ); - } else if ( - res.length > 0 - && res[0].status - && res[0].status === 'updateInProgress' - ) { - Notifier.INSTANCE.notification( - res[0].status, - 'Error', - res[0].message, - '../images/access_denied.png', - false, - ); - } else if ( - res.length > 0 - && res[0].status - && res[0].status === 'DEPENDENCY_MISMATCH' - ) { - Notifier.INSTANCE.notification( - res[0].status, - 'Dependency Mismatch', - res[0].message, - '../images/access_denied.png', - false, - ); - console.log(res[0].message); - const uninstalledDeps = res[0].deps || ''; - BrowserStore.INSTANCE.set({ dependencyMismatch: true, uninstalledDeps }); - try { - showDependencyError(uninstalledDeps); - } catch (e) { - // Popup is closed - } + } + }) + .catch((e) => { + // Error handling for Nuxeo 9.2 and older + window.executeScript(checkDependencies, null, (text) => { + const checkDeps = JSON.parse(text).match; + let message = ''; + let dependencyError = {}; + if (JSON.parse(text).nx !== JSON.parse(text).studioDistrib[0]) { + message += `${JSON.parse(text).studio} - ${ + JSON.parse(text).studioDistrib[0] + } cannot be installed on Nuxeo ${JSON.parse(text).nx}.`; + dependencyError = { + id: 'dependencyMismatch', + title: 'Dependency Mismatch', + message, + imageUrl: '../images/access_denied.png', + interaction: true, + }; + } else { + dependencyError = this.serverConnector.defaultServerError; } - }) - .catch((e) => { - // Error handling for Nuxeo 9.2 and older - window.executeScript(checkDependencies, null, (text) => { - const checkDeps = JSON.parse(text).match; - let message = ''; - let dependencyError = {}; - if (JSON.parse(text).nx !== JSON.parse(text).studioDistrib[0]) { - message += `${JSON.parse(text).studio} - ${JSON.parse(text).studioDistrib[0]} cannot be installed on Nuxeo ${JSON.parse(text).nx}.`; - dependencyError = { - id: 'dependencyMismatch', - title: 'Dependency Mismatch', - message, - imageUrl: '../images/access_denied.png', - interaction: true, - }; - } else { - dependencyError = defaultServerError; + if (!checkDeps) { + stopLoading(); + this.handleErrors(e, dependencyError); + const deps = JSON.parse(text).deps; + if (deps.length > 0) { + const items = []; + deps.forEach((dep) => { + items.push({ title: '', message: dep.name }); + }); + chrome.notifications.create( + 'dependency_check', + { + type: 'list', + title: 'Check Dependencies', + message: + 'Please check that the following dependencies are installed:', + items, + iconUrl: '../images/access_denied.png', + requireInteraction: true, + }, + () => { + console.log(chrome.runtime.lastError); + } + ); } - if (!checkDeps) { - stopLoading(); - handleErrors(e, dependencyError); - const deps = JSON.parse(text).deps; - if (deps.length > 0) { - const items = []; - deps.forEach((dep) => { - items.push({ title: '', message: dep.name }); - }); - chrome.notifications.create( - 'dependency_check', - { - type: 'list', - title: 'Check Dependencies', - message: - 'Please check that the following dependencies are installed:', - items, - iconUrl: '../images/access_denied.png', - requireInteraction: true, - }, - () => { - console.log(chrome.runtime.lastError); - }, + } else { + startLoading(); + this.nuxeo + .operation('Service.HotReloadStudioSnapshot') + .execute() + .then(() => { + this.notifier.notification( + 'success', + 'Success!', + 'A Hot Reload has successfully been completed.', + '../images/nuxeo-128.png', + false ); - } - } else { - startLoading(); - nuxeo - .operation('Service.HotReloadStudioSnapshot') - .execute() - .then(() => { - Notifier.INSTANCE.notification( - 'success', - 'Success!', - 'A Hot Reload has successfully been completed.', - '../images/nuxeo-128.png', - false, - ); - chrome.tabs.reload(window.studioExt.server.tabId); - }) - .catch((er) => { - handleErrors(er, defaultServerError); - }); - stopLoading(); - } - }); // end executeScript - }); // end catch - }); // end getCurrentTabUrl - }; // end reload + chrome.tabs.reload(window.studioExt.server.tabId); + }) + .catch((er) => { + this.handleErrors(er, this.serverConnector.defasultServerError); + }); + stopLoading(); + } + }); // end executeScript + }); // end catch + } // end reload } export default StudioHotReloader; diff --git a/src/popup/index.js b/src/popup/index.js index 68835cf2..0835426f 100644 --- a/src/popup/index.js +++ b/src/popup/index.js @@ -18,7 +18,10 @@ import 'bootstrap/dist/css/bootstrap.min.css'; import $ from 'jquery'; import DOMPurify from 'dompurify'; import ServiceWorkerBridge from '../service-worker-bridge'; +import ContentBridge from '../content-bridge'; +const serviceWorker = new ServiceWorkerBridge(); +const content = new ContentBridge(); function handle(bridge) { function debounce(fn, delay) { @@ -90,7 +93,7 @@ function handle(bridge) { $('#no-studio-buttons').css('display', 'none'); $('#studio').css('display', 'flex'); $('#studio-buttons').css('display', 'block'); - if (bridge.designerLivePreview.isEnabled()) { + if (bridge.serviceWorker.designerLivePreview.isEnabled()) { $('#designer-live-preview-button').addClass('enabled'); $('#designer-live-preview-button').removeClass('disabled'); } else { @@ -100,26 +103,26 @@ function handle(bridge) { const packageLocation = new URL( `/nuxeo/site/studio/ide?project=${packageName}`, - bridge.connectLocator.url, + bridge.serviceWorker.connectLocator.url, ).toString(); $('#log-into-studio').attr( 'href', - new URL('/nuxeo', bridge.connectLocator.url).toString(), + new URL('/nuxeo', bridge.serviceWorker.connectLocator.url).toString(), ); $('#studio').click(() => { - app.browser.createTabs(packageLocation, bridge.studioExt.server.tabId); + bridge.serviceWorker.browser.loadExtensionTab(packageLocation); }); $('#hot-reload-button').click(() => { - bridge.bridgeHotReload(startLoadingHR, stopLoading, true, showDependencyError); + bridge.serviceWorker.bridgeHotReload(startLoadingHR, stopLoading, true, showDependencyError); }); $('#designer-live-preview-button').click(() => { - if (bridge.designerLivePreview.isEnabled()) { - bridge.designerLivePreview.disable(); + if (bridge.serviceWorker.designerLivePreview.isEnabled()) { + bridge.serviceWorker.designerLivePreview.disable(); $('#designer-live-preview-button').removeClass('enabled'); $('#designer-live-preview-button').addClass('disabled'); } else { - bridge.designerLivePreview - .enable(packageName, bridge.studioExt.server.url) + bridge.serviceWorker.designerLivePreview + .enable(packageName, bridge.serviceWorker.studioExt.server.url) .then(() => { $('#designer-live-preview-button').addClass('enabled'); $('#designer-live-preview-button').removeClass('disabled'); @@ -133,13 +136,13 @@ function handle(bridge) { } }); $('#force-hot-reload-button').click(() => { - bridge.hotReloader.hotReload(startLoadingHR, stopLoading, false, showDependencyError); + bridge.serviceWorker.hotReloader.hotReload(startLoadingHR, stopLoading, false, showDependencyError); hideDependencyError(); - bridge.persistVar('dependencyMismatch', false); + bridge.serviceWorker.persistVar('dependencyMismatch', false); }); $('#cancel-button').click(() => { hideDependencyError(); - bridge.persistVar('dependencyMismatch', false); + bridge.serviceWorker.persistVar('dependencyMismatch', false); $('html').css('height', 'auto'); }); } @@ -150,7 +153,7 @@ function handle(bridge) { $('#message').css('display', 'none'); $('#nopkg').css('display', 'block'); $('#studio, #hot-reload-button').click(() => { - bridge.Notifier.INSTANCE.notification( + bridge.serviceWorker.Notifier.INSTANCE.notification( 'no_studio_project', 'No associated Studio project', "If you'd like to use this function, please associate your Nuxeo server with a studio project", @@ -164,16 +167,16 @@ function handle(bridge) { function registerLink(element, url) { $(element).click(() => { - app.browser.createTabs(url, bridge.studioExt.server.tabId); + content.loadExtensionTab(url); }); } function checkDependencyMismatch() { if ( - bridge.hotReloader.dependencyMismatch - && bridge.hotReloader.uninstalledDeps.length > 0 + bridge.serviceWorker.hotReloader.dependencyMismatch + && bridge.serviceWorker.hotReloader.uninstalledDeps.length > 0 ) { - showDependencyError(bridge.persistedVars.uninstalledDeps); + showDependencyError(bridge.serviceWorker.persistedVars.uninstalledDeps); } else { hideDependencyError(); } @@ -188,14 +191,14 @@ function handle(bridge) { } $(document).ready(() => { - if (app.browser.name === 'Firefox') { + if (bridge.serviceWorker.vendor === 'Firefox') { adjustStorageButtons(); } // For chrome browser, the designer live preview is enable // for version upper 72 $('#designer-livepreview-need-update').hide(); - if (app.browser.name === 'Chrome') { + if (bridge.serviceWorker.vendor === 'Chrome') { const version = parseInt( /(Firefox|Chrome)\/(?[0-9\.]*)/g .exec(navigator.userAgent) @@ -223,11 +226,11 @@ function handle(bridge) { $('#connect-url').toggle(); }); - if (bridge.connectLocator.url.hostname !== 'connect.nuxeo.com') { - $('#connect-url-input').val(bridge.connectLocator.url.toString()); + if (bridge.serviceWorker.connectLocator.url.hostname !== 'connect.nuxeo.com') { + $('#connect-url-input').val(bridge.serviceWorker.connectLocator.url.toString()); } - bridge.browserStore.get({ highlight: true }, (res) => { + bridge.serviceWorker.browserStore.get({ highlight: true }, (res) => { $('#highlight-input').prop('checked', res.highlight); }); @@ -235,12 +238,12 @@ function handle(bridge) { const input = $('#connect-url-input').val(); const highlight = $('#highlight-input').prop('checked'); if (input.length > 0) { - bridge.connectLocator.setURL(input) + bridge.serviceWorker.connectLocator.setURL(input) .then(() => { $('#connect-url').hide(); }); } - bridge.browserStore.set({ highlight }, () => { + bridge.serviceWorker.browserStore.set({ highlight }, () => { console.alert('Your changes have been saved.'); // eslint-disable-line no-alert }); }); @@ -252,7 +255,7 @@ function handle(bridge) { confirmButton: 'Reset', cancelButton: 'Cancel', confirm: () => { - bridge.browserStore.set({ connectUrl: 'https://connect.nuxeo.com', highlight: true }, () => { + bridge.serviceWorker.browserStore.set({ connectUrl: 'https://connect.nuxeo.com', highlight: true }, () => { $('#connect-url-input').val(''); $('#connect-url').hide(); $('#highlight-input').prop('checked', true); @@ -294,7 +297,7 @@ function handle(bridge) { function getJsonFromPath(input) { input = decodeURIComponent(input); - bridge.browserStore.get({ highlight: true }).then((res) => { + bridge.serviceWorker.browserStore.get({ highlight: true }).then((res) => { if (res.highlight) { nuxeo .request(`/repo/${repository}/path${input}`) @@ -308,7 +311,7 @@ function handle(bridge) { }); } else { const jsonUrl = `${nuxeo._baseURL}api/v1/repo/${repository}/path${input}?enrichers.document=acls,permissions&properties=*`; - app.browser.createTabs(jsonUrl, bridge.studioExt.server.tabId); + content.loadExtensionTab(jsonUrl); } }); } @@ -328,12 +331,12 @@ function handle(bridge) { }); } else { const jsonUrl = `${nuxeo._baseURL}api/v1/repo/${repository}/id/${input}?enrichers.document=acls,permissions&properties=*`; - app.browser.createTabs(jsonUrl, bridge.studioExt.server.tabId); + content.loadExtensionTab(jsonUrl); } }); } - bridge.getCurrentTabUrl((url) => { - nuxeo = bridge.newNuxeo({ + bridge.content.getCurrentTabUrl((url) => { + nuxeo = bridge.serviceWorker.newNuxeo({ baseURL: url, }); nuxeo @@ -361,7 +364,7 @@ function handle(bridge) { println JsonOutput.toJson([studio: pkgName]);`; - bridge.executeScript(checkStudioPkg, noStudioPackageFound, (text) => { + bridge.serviceWorker.executeScript(checkStudioPkg, noStudioPackageFound, (text) => { const pkgName = JSON.parse(text).studio; if (pkgName) { studioPackageFound(pkgName); @@ -410,7 +413,7 @@ function handle(bridge) { println JsonOutput.toJson([installed: addons]);`; - bridge.executeScript(checkAddons, null, (text) => { + bridge.serviceWorker.executeScript(checkAddons, null, (text) => { let playgroundUrl = ''; if (JSON.parse(text).installed.includes('nuxeo-api-playground')) { playgroundUrl = nuxeo._baseURL @@ -463,8 +466,8 @@ function handle(bridge) { 'http://showcase.nuxeo.com/nuxeo/styleGuide/', ); - const jsfMatchs = regexes.jsf.doc.exec(bridge.tabUrl); - const uiMatchs = regexes.ui.doc.exec(bridge.tabUrl); + const jsfMatchs = regexes.jsf.doc.exec(bridge.serviceWorker.tabUrl); + const uiMatchs = regexes.ui.doc.exec(bridge.serviceWorker.tabUrl); function exportCurrentLink(docPathOrId) { $('#export-current').css('display', 'block'); @@ -584,7 +587,7 @@ function handle(bridge) { `nxdoc/default/${event.target.id}/view_documents`, ); } - app.browser.createTabs(docURL, bridge.studioExt.server.tabId); + content.loadExtensionTab(docURL); }); $('.json-icon').click((event) => { event.preventDefault(); @@ -600,7 +603,7 @@ function handle(bridge) { }) .catch((error) => { error.response.json().then((json) => { - bridge.Notifier.INSTANCE.notification( + bridge.serviceWorker.Notifier.INSTANCE.notification( 'error', json.code, json.message, @@ -614,8 +617,8 @@ function handle(bridge) { let openJsonWindow = (jsonObject) => { const jsonString = JSON.stringify(jsonObject, undefined, 2); - bridge._text = DOMPurify.sanitize(jsonString); - app.browser.createTabs('json.html', bridge.studioExt.server.tabId); + bridge.serviceWorker._text = DOMPurify.sanitize(jsonString); + content.loadExtensionTab('json.html'); }; $('#restart-button').confirm({ @@ -624,7 +627,7 @@ function handle(bridge) { confirmButton: 'Restart', cancelButton: 'Cancel', confirm: () => { - bridge.restart(startLoadingRS, stopLoading); + bridge.serviceWorker.restart(startLoadingRS, stopLoading); }, }); @@ -638,16 +641,16 @@ function handle(bridge) { }); $('#reindex').click(() => { if ($('#reindex-repo').hasClass('active')) { - bridge.reindex(); + bridge.serviceWorker.reindex(); } else { $('#reindex-form').show(); const input = $('#reindex-input').val(); $('#reindex-input').val(''); const matchGroupId = regexes.uuid.exec(input); if (matchGroupId) { - bridge.reindexDocId(input); + bridge.serviceWorker.reindexDocId(input); } else { - bridge.reindexNXQL(input); + bridge.serviceWorker.reindexNXQL(input); } } }); @@ -808,4 +811,4 @@ function handle(bridge) { }); } -ServiceWorkerBridge.INSTANCE.call(handle); +content.getCurrentTabUrl((url) => serviceWorker.bootstrap(url, handle)); diff --git a/src/service-worker-bridge.js b/src/service-worker-bridge.js index 5e1b291c..01d33864 100644 --- a/src/service-worker-bridge.js +++ b/src/service-worker-bridge.js @@ -1,11 +1,11 @@ -// eslint-disable-next-line no-unused-vars -class ServiceWorkerBridge { - static INSTANCE = new ServiceWorkerBridge(); +import ContentBridge from './content-bridge'; +class ServiceWorkerBridge { designerLivePreview = { enable: (projectName, nuxeoInstanceBaseUrl) => new Promise((resolve, reject) => { chrome.runtime.sendMessage( { + extension: 'nuxeo-web-extension', service: 'designeLivePreview', action: 'enable', params: [projectName, nuxeoInstanceBaseUrl], @@ -22,6 +22,7 @@ class ServiceWorkerBridge { disable: () => new Promise((resolve, reject) => { chrome.runtime.sendMessage( { + extension: 'nuxeo-web-extension', service: 'designeLivePreview', action: 'disable', params: [], @@ -38,6 +39,7 @@ class ServiceWorkerBridge { isEnabled: () => new Promise((resolve, reject) => { chrome.runtime.sendMessage( { + extension: 'nuxeo-web-extension', service: 'designeLivePreview', action: 'isEnabled', params: [], @@ -58,6 +60,7 @@ class ServiceWorkerBridge { get: (input) => new Promise((resolve, reject) => { chrome.runtime.sendMessage( { + extension: 'nuxeo-web-extension', service: 'browserStorage', action: 'get', params: [input], @@ -74,6 +77,7 @@ class ServiceWorkerBridge { set: (entries) => new Promise((resolve, reject) => { chrome.runtime.sendMessage( { + extension: 'nuxeo-web-extension', service: 'browserStorage', action: 'set', params: [entries], @@ -94,6 +98,7 @@ class ServiceWorkerBridge { getURL: () => new Promise((resolve, reject) => { chrome.runtime.sendMessage( { + extension: 'nuxeo-web-extension', service: 'connectLocator', action: 'getURL', params: [], @@ -110,6 +115,7 @@ class ServiceWorkerBridge { setURL: (url) => new Promise((resolve, reject) => { chrome.runtime.sendMessage( { + extension: 'nuxeo-web-extension', service: 'connectLocator', action: 'setURL', params: [url], @@ -130,6 +136,7 @@ class ServiceWorkerBridge { hotReload: (startLoading, stopLoading, force, showDependencyError) => new Promise((resolve, reject) => { chrome.runtime.sendMessage( { + extension: 'nuxeo-web-extension', service: 'hotReloader', action: 'reload', params: [startLoading, stopLoading, force, showDependencyError], @@ -145,62 +152,27 @@ class ServiceWorkerBridge { }), }; - call(handler) { + bootstrap(nuxeoUrl, handler) { + const callback = () => handler({ serviceWorker: this, content: new ContentBridge() }); + if (!nuxeoUrl) { + callback(); + } this.connectLocator .getURL() - .then((url) => { - this.connectLocator.url = url; - return url; + .then((connectUrl) => { + this.connectLocator.url = connectUrl; + return undefined; }) .then(() => this.designerLivePreview.isEnabled()) .then((enabled) => { this.designerLivePreview.enabled = enabled; - return null; + return undefined; }) .then(() => { this.hotReloader.dependencyMismatch = false; this.hotReloader.uninstalledDeps = []; }) - .then(() => handler({ - bridge: this, - getCurrentTabUrl: (callback) => { - // Check if tabUrl is available in the query parameters - const urlParams = new URLSearchParams(window.location.search); - const tabUrl = urlParams.get('tabUrl'); - - if (tabUrl) { - // If tabUrl is available, call the callback with tabUrl and return - callback(tabUrl); - return; - } - - // If tabUrl is not available, continue with the original logic - chrome.tabs - .query({ - active: true, - currentWindow: true, - }) - .then((tabs) => { - if (!tabs || tabs.length === 0) { - return; - } - const nxPattern = /(^https?:\/\/[A-Za-z_\.0-9:-]+\/[A-Za-z_\.0-9-]+\/)(?:(?:nxdoc|nxpath|nxsearch|nxadmin|nxhome|nxdam|nxdamid|site\/[A-Za-z_\.0-9-]+)\/[A-Za-z_\.0-9-]+|view_documents\.faces|ui\/#!\/|[a-zA-Z0-9_%]+\/?|view_domains\.faces|home\.html|view_home\.faces)/; - const [tab] = tabs; - const matchGroups = nxPattern.exec(tab.url); - if (!matchGroups) { - callback(null); - return; - } - const [, url] = matchGroups; - this.browserStore - .set({ server: { url, tabId: tab.id } }) - .then(() => callback(url)); - }) - .catch((error) => { - console.error(error); - }); - }, - })) + .then(() => callback()) .catch((error) => { // Handle the error console.error(error); diff --git a/src/tabs-creator.js b/src/tabs-creator.js index e68d6b40..8dd23b97 100644 --- a/src/tabs-creator.js +++ b/src/tabs-creator.js @@ -14,10 +14,10 @@ See the License for the specific language governing permissions and limitations under the License. */ -class TabsCreator { - static INSTANCE = new TabsCreator(); +class Vendor { + static INSTANCE = new Vendor(); - createTabs(url, tabId) { + loadExtensionTab(url, tabId) { chrome.tabs.query({ active: true }, (tabs) => { const index = tabs[0].index; chrome.tabs.create({ diff --git a/vite.config.js b/vite.config.js index 1a578f7d..4f678a3c 100644 --- a/vite.config.js +++ b/vite.config.js @@ -1,3 +1,4 @@ +/* eslint-disable comma-dangle */ import copy from 'rollup-plugin-copy'; import fs from 'fs'; import fse from 'fs-extra'; @@ -9,7 +10,7 @@ const entry = process.env.ENTRY; const paths = { about: { input: 'about/index.html' }, - content: { input: 'content/index.html' }, + content: { input: 'content/main.js' }, json: { input: 'json/index.html' }, main: { copyPublicDir: true, input: `main/main-${vendor}.js` }, options: { input: 'options/index.html' }, @@ -103,7 +104,8 @@ export default { name: 'rename-popup-bundles', apply: 'build', generateBundle(_, bundle) { - if (entry === 'main') return; // Do not process the main entry + if (!paths[entry].input.endsWith('.html')) return; // Process only html entry points + console.log('Renaming popup bundles ...'); Object.keys(bundle).forEach((name) => { const file = bundle[name]; @@ -116,7 +118,7 @@ export default { }); }, writeBundle() { - if (entry === 'main') return; // Do not process the main entry + if (!paths[entry].input.endsWith('.html')) return; // Process only html entry points // Move index.html to root and update script source const htmlFilePath = path.resolve(__dirname, `dist/chrome/${entry}/src/${entry}/index.html`);