From 0b55c965e06709373b0b22787953276d85bdcba4 Mon Sep 17 00:00:00 2001 From: Rene Date: Mon, 20 Jul 2020 07:12:57 +0200 Subject: [PATCH] change to rollup --- package-lock.json | 1560 ++--------------- package.json | 21 +- .../dist/overlayscrollbars.esm.js | 137 +- .../dist/overlayscrollbars.esm.js.map | 2 +- .../dist/overlayscrollbars.js | 177 +- .../dist/overlayscrollbars.js.map | 2 +- packages/overlayscrollbars/package-lock.json | 27 + packages/overlayscrollbars/package.json | 8 +- packages/overlayscrollbars/rollup.config.js | 18 + packages/overlayscrollbars/src/index.ts | 17 +- packages/overlayscrollbars/types/index.d.ts | 8 +- packages/overlayscrollbars/webpack.config.js | 7 - rollup.config.js | 118 ++ webpack.config.babel.js | 118 -- 14 files changed, 497 insertions(+), 1723 deletions(-) create mode 100644 packages/overlayscrollbars/package-lock.json create mode 100644 packages/overlayscrollbars/rollup.config.js delete mode 100644 packages/overlayscrollbars/webpack.config.js create mode 100644 rollup.config.js delete mode 100644 webpack.config.babel.js diff --git a/package-lock.json b/package-lock.json index 031bf66..bcbcc6f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1872,13 +1872,29 @@ } } }, - "@npmcli/move-file": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@npmcli/move-file/-/move-file-1.0.1.tgz", - "integrity": "sha512-Uv6h1sT+0DrblvIrolFtbvM1FgWm+/sy4B3pvLp67Zys+thcukzS5ekn7HsZFGpWP4Q3fYJCljbWQE/XivMRLw==", + "@rollup/plugin-babel": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@rollup/plugin-babel/-/plugin-babel-5.1.0.tgz", + "integrity": "sha512-zXBEYmfiLAMvB+ZBa6m/q9hsQYAq1sUFdjuP1F6C2pf6uQcpHwAWQveZgzS63zXdKPUYHD3Dr7BhjCqcr0bbLw==", "dev": true, "requires": { - "mkdirp": "^1.0.4" + "@babel/helper-module-imports": "^7.7.4", + "@rollup/pluginutils": "^3.0.8" + } + }, + "@rollup/plugin-commonjs": { + "version": "14.0.0", + "resolved": "https://registry.npmjs.org/@rollup/plugin-commonjs/-/plugin-commonjs-14.0.0.tgz", + "integrity": "sha512-+PSmD9ePwTAeU106i9FRdc+Zb3XUWyW26mo5Atr2mk82hor8+nPwkztEjFo8/B1fJKfaQDg9aM2bzQkjhi7zOw==", + "dev": true, + "requires": { + "@rollup/pluginutils": "^3.0.8", + "commondir": "^1.0.1", + "estree-walker": "^1.0.1", + "glob": "^7.1.2", + "is-reference": "^1.1.2", + "magic-string": "^0.25.2", + "resolve": "^1.11.0" } }, "@rollup/plugin-node-resolve": { @@ -1897,9 +1913,9 @@ } }, "@rollup/plugin-typescript": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/@rollup/plugin-typescript/-/plugin-typescript-4.1.2.tgz", - "integrity": "sha512-+7UlGat/99e2JbmGNnIauxwEhYLwrL7adO/tSJxUN57xrrS3Ps+ZzYpLCDGPZJ57j+ZJTZLLN89KXW9JMEB+jg==", + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/@rollup/plugin-typescript/-/plugin-typescript-5.0.2.tgz", + "integrity": "sha512-CkS028Itwjqm1uLbFVfpJgtVtnNvZ+og/m6UlNRR5wOOnNTWPcVQzOu5xGdEX+WWJxdvWIqUq2uR/RBt2ZipWg==", "dev": true, "requires": { "@rollup/pluginutils": "^3.0.1", @@ -1935,12 +1951,6 @@ "@sinonjs/commons": "^1.7.0" } }, - "@types/anymatch": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/@types/anymatch/-/anymatch-1.3.1.tgz", - "integrity": "sha512-/+CRPXpBDpo2RK9C68N3b2cOvO0Cf5B9aPijHsoDQTHivnGSObdOF2BRQOYjojWTDy6nQvMjmqRXIxH55VjxxA==", - "dev": true - }, "@types/babel__core": { "version": "7.1.9", "resolved": "https://registry.npmjs.org/@types/babel__core/-/babel__core-7.1.9.tgz", @@ -1994,16 +2004,6 @@ "integrity": "sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==", "dev": true }, - "@types/glob": { - "version": "7.1.3", - "resolved": "https://registry.npmjs.org/@types/glob/-/glob-7.1.3.tgz", - "integrity": "sha512-SEYeGAIQIQX8NN6LDKprLjbrd5dARM5EXsd8GI/A5l0apYI1fGMWgPHSe4ZKL4eozlAyI+doUE9XbYS4xCkQ1w==", - "dev": true, - "requires": { - "@types/minimatch": "*", - "@types/node": "*" - } - }, "@types/graceful-fs": { "version": "4.1.3", "resolved": "https://registry.npmjs.org/@types/graceful-fs/-/graceful-fs-4.1.3.tgz", @@ -2048,18 +2048,6 @@ "pretty-format": "^25.2.1" } }, - "@types/json-schema": { - "version": "7.0.5", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.5.tgz", - "integrity": "sha512-7+2BITlgjgDhH0vvwZU/HZJVyk+2XUlvxXe8dFMedNX/aMkaOq++rMAFXc0tM7ij15QaWlbdQASBR9dihi+bDQ==", - "dev": true - }, - "@types/minimatch": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-3.0.3.tgz", - "integrity": "sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA==", - "dev": true - }, "@types/node": { "version": "14.0.23", "resolved": "https://registry.npmjs.org/@types/node/-/node-14.0.23.tgz", @@ -2087,82 +2075,12 @@ "@types/node": "*" } }, - "@types/source-list-map": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/@types/source-list-map/-/source-list-map-0.1.2.tgz", - "integrity": "sha512-K5K+yml8LTo9bWJI/rECfIPrGgxdpeNbj+d53lwN4QjW1MCwlkhUms+gtdzigTeUyBr09+u8BwOIY3MXvHdcsA==", - "dev": true - }, "@types/stack-utils": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/@types/stack-utils/-/stack-utils-1.0.1.tgz", "integrity": "sha512-l42BggppR6zLmpfU6fq9HEa2oGPEI8yrSPL3GITjfRInppYFahObbIQOQK3UGxEnyQpltZLaPe75046NOZQikw==", "dev": true }, - "@types/tapable": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/@types/tapable/-/tapable-1.0.6.tgz", - "integrity": "sha512-W+bw9ds02rAQaMvaLYxAbJ6cvguW/iJXNT6lTssS1ps6QdrMKttqEAMEG/b5CR8TZl3/L7/lH0ZV5nNR1LXikA==", - "dev": true - }, - "@types/uglify-js": { - "version": "3.9.3", - "resolved": "https://registry.npmjs.org/@types/uglify-js/-/uglify-js-3.9.3.tgz", - "integrity": "sha512-KswB5C7Kwduwjj04Ykz+AjvPcfgv/37Za24O2EDzYNbwyzOo8+ydtvzUfZ5UMguiVu29Gx44l1A6VsPPcmYu9w==", - "dev": true, - "requires": { - "source-map": "^0.6.1" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - } - } - }, - "@types/webpack": { - "version": "4.41.21", - "resolved": "https://registry.npmjs.org/@types/webpack/-/webpack-4.41.21.tgz", - "integrity": "sha512-2j9WVnNrr/8PLAB5csW44xzQSJwS26aOnICsP3pSGCEdsu6KYtfQ6QJsVUKHWRnm1bL7HziJsfh5fHqth87yKA==", - "dev": true, - "requires": { - "@types/anymatch": "*", - "@types/node": "*", - "@types/tapable": "*", - "@types/uglify-js": "*", - "@types/webpack-sources": "*", - "source-map": "^0.6.0" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - } - } - }, - "@types/webpack-sources": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/@types/webpack-sources/-/webpack-sources-1.4.0.tgz", - "integrity": "sha512-c88dKrpSle9BtTqR6ifdaxu1Lvjsl3C5OsfvuUbUwdXymshv1TkufUAXBajCCUM/f/TmnkZC/Esb03MinzSiXQ==", - "dev": true, - "requires": { - "@types/node": "*", - "@types/source-list-map": "*", - "source-map": "^0.7.3" - }, - "dependencies": { - "source-map": { - "version": "0.7.3", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz", - "integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==", - "dev": true - } - } - }, "@types/yargs": { "version": "15.0.5", "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-15.0.5.tgz", @@ -2178,193 +2096,6 @@ "integrity": "sha512-FA/BWv8t8ZWJ+gEOnLLd8ygxH/2UFbAvgEonyfN6yWGLKc7zVjbpl2Y4CTjid9h2RfgPP6SEt6uHwEOply00yw==", "dev": true }, - "@webassemblyjs/ast": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.9.0.tgz", - "integrity": "sha512-C6wW5L+b7ogSDVqymbkkvuW9kruN//YisMED04xzeBBqjHa2FYnmvOlS6Xj68xWQRgWvI9cIglsjFowH/RJyEA==", - "dev": true, - "requires": { - "@webassemblyjs/helper-module-context": "1.9.0", - "@webassemblyjs/helper-wasm-bytecode": "1.9.0", - "@webassemblyjs/wast-parser": "1.9.0" - } - }, - "@webassemblyjs/floating-point-hex-parser": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.9.0.tgz", - "integrity": "sha512-TG5qcFsS8QB4g4MhrxK5TqfdNe7Ey/7YL/xN+36rRjl/BlGE/NcBvJcqsRgCP6Z92mRE+7N50pRIi8SmKUbcQA==", - "dev": true - }, - "@webassemblyjs/helper-api-error": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.9.0.tgz", - "integrity": "sha512-NcMLjoFMXpsASZFxJ5h2HZRcEhDkvnNFOAKneP5RbKRzaWJN36NC4jqQHKwStIhGXu5mUWlUUk7ygdtrO8lbmw==", - "dev": true - }, - "@webassemblyjs/helper-buffer": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.9.0.tgz", - "integrity": "sha512-qZol43oqhq6yBPx7YM3m9Bv7WMV9Eevj6kMi6InKOuZxhw+q9hOkvq5e/PpKSiLfyetpaBnogSbNCfBwyB00CA==", - "dev": true - }, - "@webassemblyjs/helper-code-frame": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-code-frame/-/helper-code-frame-1.9.0.tgz", - "integrity": "sha512-ERCYdJBkD9Vu4vtjUYe8LZruWuNIToYq/ME22igL+2vj2dQ2OOujIZr3MEFvfEaqKoVqpsFKAGsRdBSBjrIvZA==", - "dev": true, - "requires": { - "@webassemblyjs/wast-printer": "1.9.0" - } - }, - "@webassemblyjs/helper-fsm": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-fsm/-/helper-fsm-1.9.0.tgz", - "integrity": "sha512-OPRowhGbshCb5PxJ8LocpdX9Kl0uB4XsAjl6jH/dWKlk/mzsANvhwbiULsaiqT5GZGT9qinTICdj6PLuM5gslw==", - "dev": true - }, - "@webassemblyjs/helper-module-context": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-module-context/-/helper-module-context-1.9.0.tgz", - "integrity": "sha512-MJCW8iGC08tMk2enck1aPW+BE5Cw8/7ph/VGZxwyvGbJwjktKkDK7vy7gAmMDx88D7mhDTCNKAW5tED+gZ0W8g==", - "dev": true, - "requires": { - "@webassemblyjs/ast": "1.9.0" - } - }, - "@webassemblyjs/helper-wasm-bytecode": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.9.0.tgz", - "integrity": "sha512-R7FStIzyNcd7xKxCZH5lE0Bqy+hGTwS3LJjuv1ZVxd9O7eHCedSdrId/hMOd20I+v8wDXEn+bjfKDLzTepoaUw==", - "dev": true - }, - "@webassemblyjs/helper-wasm-section": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.9.0.tgz", - "integrity": "sha512-XnMB8l3ek4tvrKUUku+IVaXNHz2YsJyOOmz+MMkZvh8h1uSJpSen6vYnw3IoQ7WwEuAhL8Efjms1ZWjqh2agvw==", - "dev": true, - "requires": { - "@webassemblyjs/ast": "1.9.0", - "@webassemblyjs/helper-buffer": "1.9.0", - "@webassemblyjs/helper-wasm-bytecode": "1.9.0", - "@webassemblyjs/wasm-gen": "1.9.0" - } - }, - "@webassemblyjs/ieee754": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.9.0.tgz", - "integrity": "sha512-dcX8JuYU/gvymzIHc9DgxTzUUTLexWwt8uCTWP3otys596io0L5aW02Gb1RjYpx2+0Jus1h4ZFqjla7umFniTg==", - "dev": true, - "requires": { - "@xtuc/ieee754": "^1.2.0" - } - }, - "@webassemblyjs/leb128": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.9.0.tgz", - "integrity": "sha512-ENVzM5VwV1ojs9jam6vPys97B/S65YQtv/aanqnU7D8aSoHFX8GyhGg0CMfyKNIHBuAVjy3tlzd5QMMINa7wpw==", - "dev": true, - "requires": { - "@xtuc/long": "4.2.2" - } - }, - "@webassemblyjs/utf8": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.9.0.tgz", - "integrity": "sha512-GZbQlWtopBTP0u7cHrEx+73yZKrQoBMpwkGEIqlacljhXCkVM1kMQge/Mf+csMJAjEdSwhOyLAS0AoR3AG5P8w==", - "dev": true - }, - "@webassemblyjs/wasm-edit": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.9.0.tgz", - "integrity": "sha512-FgHzBm80uwz5M8WKnMTn6j/sVbqilPdQXTWraSjBwFXSYGirpkSWE2R9Qvz9tNiTKQvoKILpCuTjBKzOIm0nxw==", - "dev": true, - "requires": { - "@webassemblyjs/ast": "1.9.0", - "@webassemblyjs/helper-buffer": "1.9.0", - "@webassemblyjs/helper-wasm-bytecode": "1.9.0", - "@webassemblyjs/helper-wasm-section": "1.9.0", - "@webassemblyjs/wasm-gen": "1.9.0", - "@webassemblyjs/wasm-opt": "1.9.0", - "@webassemblyjs/wasm-parser": "1.9.0", - "@webassemblyjs/wast-printer": "1.9.0" - } - }, - "@webassemblyjs/wasm-gen": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.9.0.tgz", - "integrity": "sha512-cPE3o44YzOOHvlsb4+E9qSqjc9Qf9Na1OO/BHFy4OI91XDE14MjFN4lTMezzaIWdPqHnsTodGGNP+iRSYfGkjA==", - "dev": true, - "requires": { - "@webassemblyjs/ast": "1.9.0", - "@webassemblyjs/helper-wasm-bytecode": "1.9.0", - "@webassemblyjs/ieee754": "1.9.0", - "@webassemblyjs/leb128": "1.9.0", - "@webassemblyjs/utf8": "1.9.0" - } - }, - "@webassemblyjs/wasm-opt": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.9.0.tgz", - "integrity": "sha512-Qkjgm6Anhm+OMbIL0iokO7meajkzQD71ioelnfPEj6r4eOFuqm4YC3VBPqXjFyyNwowzbMD+hizmprP/Fwkl2A==", - "dev": true, - "requires": { - "@webassemblyjs/ast": "1.9.0", - "@webassemblyjs/helper-buffer": "1.9.0", - "@webassemblyjs/wasm-gen": "1.9.0", - "@webassemblyjs/wasm-parser": "1.9.0" - } - }, - "@webassemblyjs/wasm-parser": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.9.0.tgz", - "integrity": "sha512-9+wkMowR2AmdSWQzsPEjFU7njh8HTO5MqO8vjwEHuM+AMHioNqSBONRdr0NQQ3dVQrzp0s8lTcYqzUdb7YgELA==", - "dev": true, - "requires": { - "@webassemblyjs/ast": "1.9.0", - "@webassemblyjs/helper-api-error": "1.9.0", - "@webassemblyjs/helper-wasm-bytecode": "1.9.0", - "@webassemblyjs/ieee754": "1.9.0", - "@webassemblyjs/leb128": "1.9.0", - "@webassemblyjs/utf8": "1.9.0" - } - }, - "@webassemblyjs/wast-parser": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-parser/-/wast-parser-1.9.0.tgz", - "integrity": "sha512-qsqSAP3QQ3LyZjNC/0jBJ/ToSxfYJ8kYyuiGvtn/8MK89VrNEfwj7BPQzJVHi0jGTRK2dGdJ5PRqhtjzoww+bw==", - "dev": true, - "requires": { - "@webassemblyjs/ast": "1.9.0", - "@webassemblyjs/floating-point-hex-parser": "1.9.0", - "@webassemblyjs/helper-api-error": "1.9.0", - "@webassemblyjs/helper-code-frame": "1.9.0", - "@webassemblyjs/helper-fsm": "1.9.0", - "@xtuc/long": "4.2.2" - } - }, - "@webassemblyjs/wast-printer": { - "version": "1.9.0", - "resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.9.0.tgz", - "integrity": "sha512-2J0nE95rHXHyQ24cWjMKJ1tqB/ds8z/cyeOZxJhcb+rW+SQASVjuznUSmdz5GpVJTzU8JkhYut0D3siFDD6wsA==", - "dev": true, - "requires": { - "@webassemblyjs/ast": "1.9.0", - "@webassemblyjs/wast-parser": "1.9.0", - "@xtuc/long": "4.2.2" - } - }, - "@xtuc/ieee754": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz", - "integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==", - "dev": true - }, - "@xtuc/long": { - "version": "4.2.2", - "resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz", - "integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==", - "dev": true - }, "abab": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/abab/-/abab-2.0.3.tgz", @@ -2393,16 +2124,6 @@ "integrity": "sha512-OPdCF6GsMIP+Az+aWfAAOEt2/+iVDKE7oy6lJ098aoe59oAmK76qV6Gw60SbZ8jHuG2wH058GF4pLFbYamYrVA==", "dev": true }, - "aggregate-error": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.0.1.tgz", - "integrity": "sha512-quoaXsZ9/BLNae5yiNoUz+Nhkwz83GhWwtYFglcjEQB2NDHCIpApbqXxIFnm4Pq/Nvhrsq5sYJFyohrrxnTGAA==", - "dev": true, - "requires": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - } - }, "ajv": { "version": "6.12.3", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.3.tgz", @@ -2415,12 +2136,6 @@ "uri-js": "^4.2.2" } }, - "ajv-keywords": { - "version": "3.5.1", - "resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-3.5.1.tgz", - "integrity": "sha512-KWcq3xN8fDjSB+IMoh2VaXVhRI0BBGxoYp3rx7Pkb6z0cFjYR9Q9l4yZqqals0/zsioCmocC5H6UvsGD4MoIBA==", - "dev": true - }, "ansi-escapes": { "version": "4.3.1", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.1.tgz", @@ -2490,21 +2205,6 @@ "integrity": "sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ=", "dev": true }, - "array-union": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-1.0.2.tgz", - "integrity": "sha1-mjRBDk9OPaI96jdb5b5w8kd47Dk=", - "dev": true, - "requires": { - "array-uniq": "^1.0.1" - } - }, - "array-uniq": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/array-uniq/-/array-uniq-1.0.3.tgz", - "integrity": "sha1-r2rId6Jcx/dOBYiUdThY39sk/bY=", - "dev": true - }, "array-unique": { "version": "0.3.2", "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", @@ -2769,12 +2469,6 @@ "tweetnacl": "^0.14.3" } }, - "big.js": { - "version": "5.2.2", - "resolved": "https://registry.npmjs.org/big.js/-/big.js-5.2.2.tgz", - "integrity": "sha512-vyL2OymJxmarO8gxMr0mhChsO9QGwhynfuu4+MHTAW6czfq9humCB7rKpUjDd9YUiDPU4mzpyupFSvOClAwbmQ==", - "dev": true - }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -2833,42 +2527,6 @@ "integrity": "sha512-k0KL0aWZuBt2lrxrcASWDfwOLMnodeQjodT/1SxEQAXsHANgo6ZC/VEaSEHCXt7aSTZ4/4H5LKa+tBXmW7Vtvw==", "dev": true }, - "cacache": { - "version": "15.0.5", - "resolved": "https://registry.npmjs.org/cacache/-/cacache-15.0.5.tgz", - "integrity": "sha512-lloiL22n7sOjEEXdL8NAjTgv9a1u43xICE9/203qonkZUCj5X1UEWIdf2/Y0d6QcCtMzbKQyhrcDbdvlZTs/+A==", - "dev": true, - "requires": { - "@npmcli/move-file": "^1.0.1", - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "glob": "^7.1.4", - "infer-owner": "^1.0.4", - "lru-cache": "^6.0.0", - "minipass": "^3.1.1", - "minipass-collect": "^1.0.2", - "minipass-flush": "^1.0.5", - "minipass-pipeline": "^1.2.2", - "mkdirp": "^1.0.3", - "p-map": "^4.0.0", - "promise-inflight": "^1.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.0", - "tar": "^6.0.2", - "unique-filename": "^1.1.1" - }, - "dependencies": { - "p-map": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-4.0.0.tgz", - "integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==", - "dev": true, - "requires": { - "aggregate-error": "^3.0.0" - } - } - } - }, "cache-base": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/cache-base/-/cache-base-1.0.1.tgz", @@ -2936,29 +2594,6 @@ "integrity": "sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw==", "dev": true }, - "chownr": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", - "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==", - "dev": true - }, - "chrome-trace-event": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.2.tgz", - "integrity": "sha512-9e/zx1jw7B4CO+c/RXoCsfg/x1AfUBioy4owYH0bJprEYAx5hRFLRhWBqHAG57D0ZM4H7vxbP7bPe0VwhQRYDQ==", - "dev": true, - "requires": { - "tslib": "^1.9.0" - }, - "dependencies": { - "tslib": { - "version": "1.13.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.13.0.tgz", - "integrity": "sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q==", - "dev": true - } - } - }, "ci-info": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-2.0.0.tgz", @@ -2988,22 +2623,6 @@ } } }, - "clean-stack": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", - "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==", - "dev": true - }, - "clean-webpack-plugin": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/clean-webpack-plugin/-/clean-webpack-plugin-3.0.0.tgz", - "integrity": "sha512-MciirUH5r+cYLGCOL5JX/ZLzOZbVr1ot3Fw+KcvbhUb6PM+yycqd9ZhIlcigQ5gl+XhppNmw3bEFuaaMNyLj3A==", - "dev": true, - "requires": { - "@types/webpack": "^4.4.31", - "del": "^4.1.1" - } - }, "cliui": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/cliui/-/cliui-6.0.0.tgz", @@ -3015,17 +2634,6 @@ "wrap-ansi": "^6.2.0" } }, - "clone-deep": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz", - "integrity": "sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ==", - "dev": true, - "requires": { - "is-plain-object": "^2.0.4", - "kind-of": "^6.0.2", - "shallow-clone": "^3.0.0" - } - }, "co": { "version": "4.6.0", "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", @@ -3303,44 +2911,12 @@ } } }, - "del": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/del/-/del-4.1.1.tgz", - "integrity": "sha512-QwGuEUouP2kVwQenAsOof5Fv8K9t3D8Ca8NxcXKrIpEHjTXK5J2nXLdP+ALI1cgv8wj7KuwBhTwBkOZSJKM5XQ==", - "dev": true, - "requires": { - "@types/glob": "^7.1.1", - "globby": "^6.1.0", - "is-path-cwd": "^2.0.0", - "is-path-in-cwd": "^2.0.0", - "p-map": "^2.0.0", - "pify": "^4.0.1", - "rimraf": "^2.6.3" - }, - "dependencies": { - "rimraf": { - "version": "2.7.1", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", - "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", - "dev": true, - "requires": { - "glob": "^7.1.3" - } - } - } - }, "delayed-stream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", "dev": true }, - "detect-file": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/detect-file/-/detect-file-1.0.0.tgz", - "integrity": "sha1-8NZtA2cqglyxtzvbP+YjEMjlUrc=", - "dev": true - }, "detect-newline": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-3.1.0.tgz", @@ -3392,12 +2968,6 @@ "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", "dev": true }, - "emojis-list": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-3.0.0.tgz", - "integrity": "sha512-/kyM18EfinwXZbno9FyUGeFh87KC8HRQBQGildHZbEuRyWFOmv1U10o9BBp8XVZDVNNuQKyIGIu5ZYAAXJ0V2Q==", - "dev": true - }, "end-of-stream": { "version": "1.4.4", "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", @@ -3407,38 +2977,6 @@ "once": "^1.4.0" } }, - "enhanced-resolve": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-4.3.0.tgz", - "integrity": "sha512-3e87LvavsdxyoCfGusJnrZ5G8SLPOFeHSNpZI/ATL9a5leXo2k0w6MKnbqhdBad9qTobSfB20Ld7UmgoNbAZkQ==", - "dev": true, - "requires": { - "graceful-fs": "^4.1.2", - "memory-fs": "^0.5.0", - "tapable": "^1.0.0" - }, - "dependencies": { - "memory-fs": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.5.0.tgz", - "integrity": "sha512-jA0rdU5KoQMC0e6ppoNRtpp6vjFq6+NY7r8hywnC7V+1Xj/MtHwGIbB1QaK/dunyjWteJzmkpd7ooeWg10T7GA==", - "dev": true, - "requires": { - "errno": "^0.1.3", - "readable-stream": "^2.0.1" - } - } - } - }, - "errno": { - "version": "0.1.7", - "resolved": "https://registry.npmjs.org/errno/-/errno-0.1.7.tgz", - "integrity": "sha512-MfrRBDWzIWifgq6tJj60gkAwtLNb6sQPlcFrSOflcP1aFmmruKQ2wRnze/8V6kgyz7H3FF8Npzv78mZ7XLLflg==", - "dev": true, - "requires": { - "prr": "~1.0.1" - } - }, "error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -3512,31 +3050,12 @@ } } }, - "eslint-scope": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.0.tgz", - "integrity": "sha512-iiGRvtxWqgtx5m8EyQUJihBloE4EnYeGE/bz1wSPwJE6tZuJUtHlhqDM4Xj2ukE8Dyy1+HCZ4hE0fzIVMzb58w==", - "dev": true, - "requires": { - "esrecurse": "^4.1.0", - "estraverse": "^4.1.1" - } - }, "esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", "dev": true }, - "esrecurse": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.2.1.tgz", - "integrity": "sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ==", - "dev": true, - "requires": { - "estraverse": "^4.1.0" - } - }, "estraverse": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", @@ -3555,12 +3074,6 @@ "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", "dev": true }, - "events": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/events/-/events-3.1.0.tgz", - "integrity": "sha512-Rv+u8MLHNOdMjTAFeT3nCjHn2aGlx435FP/sDHNaRhDEMwyI/aB22Kj2qIN8R0cw3z28psEQLYwxVKLsKrMgWg==", - "dev": true - }, "exec-sh": { "version": "0.3.4", "resolved": "https://registry.npmjs.org/exec-sh/-/exec-sh-0.3.4.tgz", @@ -3638,15 +3151,6 @@ } } }, - "expand-tilde": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/expand-tilde/-/expand-tilde-2.0.2.tgz", - "integrity": "sha1-l+gBqgUt8CRU3kawK/YhZCzchQI=", - "dev": true, - "requires": { - "homedir-polyfill": "^1.0.1" - } - }, "expect": { "version": "26.1.0", "resolved": "https://registry.npmjs.org/expect/-/expect-26.1.0.tgz", @@ -3941,123 +3445,6 @@ "path-exists": "^4.0.0" } }, - "findup-sync": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/findup-sync/-/findup-sync-3.0.0.tgz", - "integrity": "sha512-YbffarhcicEhOrm4CtrwdKBdCuz576RLdhJDsIfvNtxUuhdRet1qZcsMjqbePtAseKdAnDyM/IyXbu7PRPRLYg==", - "dev": true, - "requires": { - "detect-file": "^1.0.0", - "is-glob": "^4.0.0", - "micromatch": "^3.0.4", - "resolve-dir": "^1.0.1" - }, - "dependencies": { - "braces": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.2.tgz", - "integrity": "sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==", - "dev": true, - "requires": { - "arr-flatten": "^1.1.0", - "array-unique": "^0.3.2", - "extend-shallow": "^2.0.1", - "fill-range": "^4.0.0", - "isobject": "^3.0.1", - "repeat-element": "^1.1.2", - "snapdragon": "^0.8.1", - "snapdragon-node": "^2.0.1", - "split-string": "^3.0.2", - "to-regex": "^3.0.1" - }, - "dependencies": { - "extend-shallow": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", - "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", - "dev": true, - "requires": { - "is-extendable": "^0.1.0" - } - } - } - }, - "fill-range": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", - "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", - "dev": true, - "requires": { - "extend-shallow": "^2.0.1", - "is-number": "^3.0.0", - "repeat-string": "^1.6.1", - "to-regex-range": "^2.1.0" - }, - "dependencies": { - "extend-shallow": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", - "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", - "dev": true, - "requires": { - "is-extendable": "^0.1.0" - } - } - } - }, - "is-number": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", - "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", - "dev": true, - "requires": { - "kind-of": "^3.0.2" - }, - "dependencies": { - "kind-of": { - "version": "3.2.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", - "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", - "dev": true, - "requires": { - "is-buffer": "^1.1.5" - } - } - } - }, - "micromatch": { - "version": "3.1.10", - "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.10.tgz", - "integrity": "sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==", - "dev": true, - "requires": { - "arr-diff": "^4.0.0", - "array-unique": "^0.3.2", - "braces": "^2.3.1", - "define-property": "^2.0.2", - "extend-shallow": "^3.0.2", - "extglob": "^2.0.4", - "fragment-cache": "^0.2.1", - "kind-of": "^6.0.2", - "nanomatch": "^1.2.9", - "object.pick": "^1.3.0", - "regex-not": "^1.0.0", - "snapdragon": "^0.8.1", - "to-regex": "^3.0.2" - } - }, - "to-regex-range": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-2.1.1.tgz", - "integrity": "sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg=", - "dev": true, - "requires": { - "is-number": "^3.0.0", - "repeat-string": "^1.6.1" - } - } - } - }, "for-in": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", @@ -4090,13 +3477,15 @@ "map-cache": "^0.2.2" } }, - "fs-minipass": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", - "integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==", + "fs-extra": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", + "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", "dev": true, "requires": { - "minipass": "^3.0.0" + "graceful-fs": "^4.2.0", + "jsonfile": "^4.0.0", + "universalify": "^0.1.0" } }, "fs.realpath": { @@ -4174,94 +3563,12 @@ "path-is-absolute": "^1.0.0" } }, - "glob-to-regexp": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", - "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", - "dev": true - }, - "global-modules": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/global-modules/-/global-modules-2.0.0.tgz", - "integrity": "sha512-NGbfmJBp9x8IxyJSd1P+otYK8vonoJactOogrVfFRIAEY1ukil8RSKDz2Yo7wh1oihl51l/r6W4epkeKJHqL8A==", - "dev": true, - "requires": { - "global-prefix": "^3.0.0" - }, - "dependencies": { - "global-prefix": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/global-prefix/-/global-prefix-3.0.0.tgz", - "integrity": "sha512-awConJSVCHVGND6x3tmMaKcQvwXLhjdkmomy2W+Goaui8YPgYgXJZewhg3fWC+DlfqqQuWg8AwqjGTD2nAPVWg==", - "dev": true, - "requires": { - "ini": "^1.3.5", - "kind-of": "^6.0.2", - "which": "^1.3.1" - } - }, - "which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } - }, - "global-prefix": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/global-prefix/-/global-prefix-1.0.2.tgz", - "integrity": "sha1-2/dDxsFJklk8ZVVoy2btMsASLr4=", - "dev": true, - "requires": { - "expand-tilde": "^2.0.2", - "homedir-polyfill": "^1.0.1", - "ini": "^1.3.4", - "is-windows": "^1.0.1", - "which": "^1.2.14" - }, - "dependencies": { - "which": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", - "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", - "dev": true, - "requires": { - "isexe": "^2.0.0" - } - } - } - }, "globals": { "version": "11.12.0", "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", "integrity": "sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==", "dev": true }, - "globby": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/globby/-/globby-6.1.0.tgz", - "integrity": "sha1-9abXDoOV4hyFj7BInWTfAkJNUGw=", - "dev": true, - "requires": { - "array-union": "^1.0.1", - "glob": "^7.0.3", - "object-assign": "^4.0.1", - "pify": "^2.0.0", - "pinkie-promise": "^2.0.0" - }, - "dependencies": { - "pify": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", - "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=", - "dev": true - } - } - }, "graceful-fs": { "version": "4.2.4", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.4.tgz", @@ -4436,18 +3743,6 @@ "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", "dev": true }, - "indent-string": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", - "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", - "dev": true - }, - "infer-owner": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/infer-owner/-/infer-owner-1.0.4.tgz", - "integrity": "sha512-IClj+Xz94+d7irH5qRyfJonOdfTzuDaifE6ZPWfx0N0+/ATZCbuTPq2prFl526urkQd90WyUKIh1DfBQ2hMz9A==", - "dev": true - }, "inflight": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", @@ -4464,18 +3759,6 @@ "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", "dev": true }, - "ini": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", - "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==", - "dev": true - }, - "interpret": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.4.0.tgz", - "integrity": "sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==", - "dev": true - }, "invariant": { "version": "2.2.4", "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", @@ -4596,12 +3879,6 @@ "integrity": "sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik=", "dev": true }, - "is-extglob": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", - "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", - "dev": true - }, "is-fullwidth-code-point": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", @@ -4614,15 +3891,6 @@ "integrity": "sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==", "dev": true }, - "is-glob": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", - "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", - "dev": true, - "requires": { - "is-extglob": "^2.1.1" - } - }, "is-module": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-module/-/is-module-1.0.0.tgz", @@ -4635,30 +3903,6 @@ "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", "dev": true }, - "is-path-cwd": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/is-path-cwd/-/is-path-cwd-2.2.0.tgz", - "integrity": "sha512-w942bTcih8fdJPJmQHFzkS76NEP8Kzzvmw92cXsazb8intwLqPibPPdXf4ANdKV3rYMuuQYGIWtvz9JilB3NFQ==", - "dev": true - }, - "is-path-in-cwd": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-path-in-cwd/-/is-path-in-cwd-2.1.0.tgz", - "integrity": "sha512-rNocXHgipO+rvnP6dk3zI20RpOtrAM/kzbB258Uw5BWr3TpXi861yzjo16Dn4hUox07iw5AyeMLHWsujkjzvRQ==", - "dev": true, - "requires": { - "is-path-inside": "^2.1.0" - } - }, - "is-path-inside": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-2.1.0.tgz", - "integrity": "sha512-wiyhTzfDWsvwAW53OBWF5zuvaOGlZ6PwYxAbPVDhpm+gM09xKQGjBq/8uYN12aDvMxnAnq3dxTyoSoRNmg5YFg==", - "dev": true, - "requires": { - "path-is-inside": "^1.0.2" - } - }, "is-plain-object": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", @@ -4674,6 +3918,15 @@ "integrity": "sha1-DFLlS8yjkbssSUsh6GJtczbG45c=", "dev": true }, + "is-reference": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/is-reference/-/is-reference-1.2.1.tgz", + "integrity": "sha512-U82MsXXiFIrjCK4otLT+o2NA2Cd2g5MLoOVXUZjIOhLurrRxpEXzI8O0KZHr3IjLvlAH1kTPYSuqer5T9ZVBKQ==", + "dev": true, + "requires": { + "@types/estree": "*" + } + }, "is-regex": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.0.tgz", @@ -6924,6 +6177,15 @@ "minimist": "^1.2.5" } }, + "jsonfile": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", + "integrity": "sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss=", + "dev": true, + "requires": { + "graceful-fs": "^4.1.6" + } + }, "jsprim": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", @@ -6979,34 +6241,6 @@ "integrity": "sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA=", "dev": true }, - "loader-runner": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.0.0.tgz", - "integrity": "sha512-Rqf48ufrr48gFjnaqss04QesoXB7VenbpFFIV/0yOKGnpbejrVlOPqTsoX42FG5goXM5Ixekcs4DqDzHOX2z7Q==", - "dev": true - }, - "loader-utils": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.4.0.tgz", - "integrity": "sha512-qH0WSMBtn/oHuwjy/NucEgbx5dbxxnxup9s4PVXJUDHZBQY+s0NWA9rJf53RBnQZxfch7euUui7hpoAPvALZdA==", - "dev": true, - "requires": { - "big.js": "^5.2.2", - "emojis-list": "^3.0.0", - "json5": "^1.0.1" - }, - "dependencies": { - "json5": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz", - "integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==", - "dev": true, - "requires": { - "minimist": "^1.2.0" - } - } - } - }, "locate-path": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz", @@ -7037,13 +6271,13 @@ "js-tokens": "^3.0.0 || ^4.0.0" } }, - "lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "magic-string": { + "version": "0.25.7", + "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.25.7.tgz", + "integrity": "sha512-4CrMT5DOHTDk4HYDlzmwu4FVCcIYI8gauveasrdCu2IKIFOJ3f0v/8MDGJCDL9oD2ppz/Av1b0Nj345H9M+XIA==", "dev": true, "requires": { - "yallist": "^4.0.0" + "sourcemap-codec": "^1.4.4" } }, "make-dir": { @@ -7139,52 +6373,6 @@ "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", "dev": true }, - "minipass": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.3.tgz", - "integrity": "sha512-Mgd2GdMVzY+x3IJ+oHnVM+KG3lA5c8tnabyJKmHSaG2kAGpudxuOf8ToDkhumF7UzME7DecbQE9uOZhNm7PuJg==", - "dev": true, - "requires": { - "yallist": "^4.0.0" - } - }, - "minipass-collect": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/minipass-collect/-/minipass-collect-1.0.2.tgz", - "integrity": "sha512-6T6lH0H8OG9kITm/Jm6tdooIbogG9e0tLgpY6mphXSm/A9u8Nq1ryBG+Qspiub9LjWlBPsPS3tWQ/Botq4FdxA==", - "dev": true, - "requires": { - "minipass": "^3.0.0" - } - }, - "minipass-flush": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/minipass-flush/-/minipass-flush-1.0.5.tgz", - "integrity": "sha512-JmQSYYpPUqX5Jyn1mXaRwOda1uQ8HP5KAT/oDSLCzt1BYRhQU0/hDtsB1ufZfEEzMZ9aAVmsBw8+FWsIXlClWw==", - "dev": true, - "requires": { - "minipass": "^3.0.0" - } - }, - "minipass-pipeline": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/minipass-pipeline/-/minipass-pipeline-1.2.3.tgz", - "integrity": "sha512-cFOknTvng5vqnwOpDsZTWhNll6Jf8o2x+/diplafmxpuIymAjzoOolZG0VvQf3V2HgqzJNhnuKHYp2BqDgz8IQ==", - "dev": true, - "requires": { - "minipass": "^3.0.0" - } - }, - "minizlib": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.0.tgz", - "integrity": "sha512-EzTZN/fjSvifSX0SlqUERCN39o6T40AMarPbv0MrarSFtIITCBh7bi+dU8nxGFHuqs9jdIAeoYoKuQAAASsPPA==", - "dev": true, - "requires": { - "minipass": "^3.0.0", - "yallist": "^4.0.0" - } - }, "mixin-deep": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/mixin-deep/-/mixin-deep-1.3.2.tgz", @@ -7206,12 +6394,6 @@ } } }, - "mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "dev": true - }, "ms": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", @@ -7243,12 +6425,6 @@ "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=", "dev": true }, - "neo-async": { - "version": "2.6.2", - "resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz", - "integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==", - "dev": true - }, "nice-try": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", @@ -7346,12 +6522,6 @@ "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==", "dev": true }, - "object-assign": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", - "dev": true - }, "object-copy": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/object-copy/-/object-copy-0.1.0.tgz", @@ -7497,12 +6667,6 @@ "p-limit": "^2.2.0" } }, - "p-map": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-2.1.0.tgz", - "integrity": "sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==", - "dev": true - }, "p-try": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", @@ -7551,12 +6715,6 @@ "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", "dev": true }, - "path-is-inside": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/path-is-inside/-/path-is-inside-1.0.2.tgz", - "integrity": "sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM=", - "dev": true - }, "path-key": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", @@ -7587,21 +6745,6 @@ "integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==", "dev": true }, - "pinkie": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/pinkie/-/pinkie-2.0.4.tgz", - "integrity": "sha1-clVrgM+g1IqXToDnckjoDtT3+HA=", - "dev": true - }, - "pinkie-promise": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-2.0.1.tgz", - "integrity": "sha1-ITXW36ejWMBprJsXh3YogihFD/o=", - "dev": true, - "requires": { - "pinkie": "^2.0.0" - } - }, "pirates": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.1.tgz", @@ -7671,18 +6814,6 @@ } } }, - "process-nextick-args": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", - "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", - "dev": true - }, - "promise-inflight": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-inflight/-/promise-inflight-1.0.1.tgz", - "integrity": "sha1-mEcocL8igTL8vdhoEputEsPAKeM=", - "dev": true - }, "prompts": { "version": "2.3.2", "resolved": "https://registry.npmjs.org/prompts/-/prompts-2.3.2.tgz", @@ -7693,12 +6824,6 @@ "sisteransi": "^1.0.4" } }, - "prr": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/prr/-/prr-1.0.1.tgz", - "integrity": "sha1-0/wRS6BplaRexok/SEzrHXj19HY=", - "dev": true - }, "psl": { "version": "1.8.0", "resolved": "https://registry.npmjs.org/psl/-/psl-1.8.0.tgz", @@ -7773,21 +6898,6 @@ "type-fest": "^0.8.1" } }, - "readable-stream": { - "version": "2.3.7", - "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", - "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", - "dev": true, - "requires": { - "core-util-is": "~1.0.0", - "inherits": "~2.0.3", - "isarray": "~1.0.0", - "process-nextick-args": "~2.0.0", - "safe-buffer": "~5.1.1", - "string_decoder": "~1.1.1", - "util-deprecate": "~1.0.1" - } - }, "regenerate": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/regenerate/-/regenerate-1.4.1.tgz", @@ -7991,29 +7101,6 @@ "resolve-from": "^5.0.0" } }, - "resolve-dir": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/resolve-dir/-/resolve-dir-1.0.1.tgz", - "integrity": "sha1-eaQGRMNivoLybv/nOcm7U4IEb0M=", - "dev": true, - "requires": { - "expand-tilde": "^2.0.0", - "global-modules": "^1.0.0" - }, - "dependencies": { - "global-modules": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/global-modules/-/global-modules-1.0.0.tgz", - "integrity": "sha512-sKzpEkf11GpOFuw0Zzjzmt4B4UZwjOcG757PPvrfhxcLFbq0wpsgpOqxpxtxFiCG4DtG93M6XRVbF2oGdev7bg==", - "dev": true, - "requires": { - "global-prefix": "^1.0.1", - "is-windows": "^1.0.1", - "resolve-dir": "^1.0.0" - } - } - } - }, "resolve-from": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", @@ -8042,14 +7129,65 @@ } }, "rollup": { - "version": "1.32.1", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-1.32.1.tgz", - "integrity": "sha512-/2HA0Ec70TvQnXdzynFffkjA6XN+1e2pEv/uKS5Ulca40g2L7KuOE3riasHoNVHOsFD5KKZgDsMk1CP3Tw9s+A==", + "version": "2.22.1", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.22.1.tgz", + "integrity": "sha512-K9AUQUCJkVqC+A7uUDacfhmpEeAjc2uOmSpvGI5xaYsm8pXgy4ZWEM8wHPfKj11xvCwFZppkRDo8a0RESJXCnw==", "dev": true, "requires": { - "@types/estree": "*", - "@types/node": "*", - "acorn": "^7.1.0" + "fsevents": "~2.1.2" + } + }, + "rollup-plugin-terser": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/rollup-plugin-terser/-/rollup-plugin-terser-6.1.0.tgz", + "integrity": "sha512-4fB3M9nuoWxrwm39habpd4hvrbrde2W2GG4zEGPQg1YITNkM3Tqur5jSuXlWNzbv/2aMLJ+dZJaySc3GCD8oDw==", + "dev": true, + "requires": { + "@babel/code-frame": "^7.8.3", + "jest-worker": "^26.0.0", + "serialize-javascript": "^3.0.0", + "terser": "^4.7.0" + } + }, + "rollup-plugin-typescript2": { + "version": "0.27.1", + "resolved": "https://registry.npmjs.org/rollup-plugin-typescript2/-/rollup-plugin-typescript2-0.27.1.tgz", + "integrity": "sha512-RJl77Bbj1EunAQDC3dK/O2HWuSUX3oJbRGzyLoS5o9W4Hs1Nix3Gavqj1Lzs5Y6Ff4H2xXfmZ1WWUQCYocSbzQ==", + "dev": true, + "requires": { + "@rollup/pluginutils": "^3.0.8", + "find-cache-dir": "^3.3.1", + "fs-extra": "8.1.0", + "resolve": "1.15.1", + "tslib": "1.11.2" + }, + "dependencies": { + "find-cache-dir": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.1.tgz", + "integrity": "sha512-t2GDMt3oGC/v+BMwzmllWDuJF/xcDtE5j/fCGbqDD7OLuJkj0cfh1YSA5VKPvwMeLFLNDBkwOKZ2X85jGLVftQ==", + "dev": true, + "requires": { + "commondir": "^1.0.1", + "make-dir": "^3.0.2", + "pkg-dir": "^4.1.0" + } + }, + "resolve": { + "version": "1.15.1", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.15.1.tgz", + "integrity": "sha512-84oo6ZTtoTUpjgNEr5SJyzQhzL72gaRodsSfyxC/AXRvwu0Yse9H8eF9IpGo7b8YetZhlI6v7ZQ6bKBFV/6S7w==", + "dev": true, + "requires": { + "path-parse": "^1.0.6" + } + }, + "tslib": { + "version": "1.11.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.11.2.tgz", + "integrity": "sha512-tTSkux6IGPnUGUd1XAZHcpu85MOkIl5zX49pO+jfsie3eP0B6pyhOlLXm3cAC6T7s+euSDDUUV+Acop5WmtkVg==", + "dev": true + } } }, "rsvp": { @@ -8229,17 +7367,6 @@ "xmlchars": "^2.2.0" } }, - "schema-utils": { - "version": "2.7.0", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-2.7.0.tgz", - "integrity": "sha512-0ilKFI6QQF5nxDZLFn2dMjvc4hjg/Wkg7rHd3jK6/A4a1Hl9VFdQWvgB1UMGoU94pad1P/8N7fMcEnLnSiju8A==", - "dev": true, - "requires": { - "@types/json-schema": "^7.0.4", - "ajv": "^6.12.2", - "ajv-keywords": "^3.4.1" - } - }, "semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", @@ -8247,9 +7374,9 @@ "dev": true }, "serialize-javascript": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-4.0.0.tgz", - "integrity": "sha512-GaNA54380uFefWghODBWEGisLZFj00nS5ACs6yHa9nLqlLpVLO8ChDGeKRjZnV4Nh4n0Qi7nhYZD/9fCPzEqkw==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-3.1.0.tgz", + "integrity": "sha512-JIJT1DGiWmIKhzRsG91aS6Ze4sFUrYbltlkg2onR5OrnNM02Kl/hnY/T4FN2omvyeBbQmMJv+K4cPOpGzOTFBg==", "dev": true, "requires": { "randombytes": "^2.1.0" @@ -8284,15 +7411,6 @@ } } }, - "shallow-clone": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/shallow-clone/-/shallow-clone-3.0.1.tgz", - "integrity": "sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA==", - "dev": true, - "requires": { - "kind-of": "^6.0.2" - } - }, "shebang-command": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", @@ -8455,12 +7573,6 @@ } } }, - "source-list-map": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/source-list-map/-/source-list-map-2.0.1.tgz", - "integrity": "sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw==", - "dev": true - }, "source-map": { "version": "0.5.7", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", @@ -8504,6 +7616,12 @@ "integrity": "sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM=", "dev": true }, + "sourcemap-codec": { + "version": "1.4.8", + "resolved": "https://registry.npmjs.org/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz", + "integrity": "sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==", + "dev": true + }, "spdx-correct": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.1.tgz", @@ -8568,15 +7686,6 @@ "tweetnacl": "~0.14.0" } }, - "ssri": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/ssri/-/ssri-8.0.0.tgz", - "integrity": "sha512-aq/pz989nxVYwn16Tsbj1TqFpD5LLrQxHf5zaHuieFV+R0Bbr4y8qUsOA45hXT/N4/9UNXTarBjnjVmjSOVaAA==", - "dev": true, - "requires": { - "minipass": "^3.1.1" - } - }, "stack-utils": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-2.0.2.tgz", @@ -8662,15 +7771,6 @@ "es-abstract": "^1.17.5" } }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "requires": { - "safe-buffer": "~5.1.0" - } - }, "strip-ansi": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.0.tgz", @@ -8740,26 +7840,6 @@ "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", "dev": true }, - "tapable": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/tapable/-/tapable-1.1.3.tgz", - "integrity": "sha512-4WK/bYZmj8xLr+HUCODHGF1ZFzsYffasLUgEiMBY4fgtltdO6B4WJtlSbPaDTLpYTcGVwM2qLnFTICEcNxs3kA==", - "dev": true - }, - "tar": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/tar/-/tar-6.0.2.tgz", - "integrity": "sha512-Glo3jkRtPcvpDlAs/0+hozav78yoXKFr+c4wgw62NNMO3oo4AaJdCo21Uu7lcwr55h39W2XD1LMERc64wtbItg==", - "dev": true, - "requires": { - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "minipass": "^3.0.0", - "minizlib": "^2.1.0", - "mkdirp": "^1.0.3", - "yallist": "^4.0.0" - } - }, "terminal-link": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/terminal-link/-/terminal-link-2.1.1.tgz", @@ -8789,61 +7869,6 @@ } } }, - "terser-webpack-plugin": { - "version": "3.0.7", - "resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-3.0.7.tgz", - "integrity": "sha512-5JqibUOctE6Ou4T00IVGYTQJBOhu24jz0PpqYeitQJJ3hlZY2ZKSwzzuqjmBH8MzbdWMgIefpmHwTkvwm6Q4CQ==", - "dev": true, - "requires": { - "cacache": "^15.0.5", - "find-cache-dir": "^3.3.1", - "jest-worker": "^26.1.0", - "p-limit": "^3.0.2", - "schema-utils": "^2.6.6", - "serialize-javascript": "^4.0.0", - "source-map": "^0.6.1", - "terser": "^4.8.0", - "webpack-sources": "^1.4.3" - }, - "dependencies": { - "find-cache-dir": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.1.tgz", - "integrity": "sha512-t2GDMt3oGC/v+BMwzmllWDuJF/xcDtE5j/fCGbqDD7OLuJkj0cfh1YSA5VKPvwMeLFLNDBkwOKZ2X85jGLVftQ==", - "dev": true, - "requires": { - "commondir": "^1.0.1", - "make-dir": "^3.0.2", - "pkg-dir": "^4.1.0" - } - }, - "p-limit": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.0.2.tgz", - "integrity": "sha512-iwqZSOoWIW+Ew4kAGUlN16J4M7OB3ysMLSZtnhmqx7njIHFPlxWBX8xo3lVTyFVq6mI/lL9qt2IsN1sHwaxJkg==", - "dev": true, - "requires": { - "p-try": "^2.0.0" - } - }, - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - }, - "webpack-sources": { - "version": "1.4.3", - "resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-1.4.3.tgz", - "integrity": "sha512-lgTS3Xhv1lCOKo7SA5TjKXMjpSM4sBjNV5+q2bqesbSPs5FjGmU6jjtBSkX9b4qW87vDIsCIlUPOEhbZrMdjeQ==", - "dev": true, - "requires": { - "source-list-map": "^2.0.0", - "source-map": "~0.6.1" - } - } - } - }, "test-exclude": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-6.0.0.tgz", @@ -8934,27 +7959,6 @@ "punycode": "^2.1.1" } }, - "ts-loader": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/ts-loader/-/ts-loader-8.0.1.tgz", - "integrity": "sha512-I9Nmly0ufJoZRMuAT9d5ijsC2B7oSPvUnOJt/GhgoATlPGYfa17VicDKPcqwUCrHpOkCxr/ybLYwbnS4cOxmvQ==", - "dev": true, - "requires": { - "chalk": "^2.3.0", - "enhanced-resolve": "^4.0.0", - "loader-utils": "^1.0.2", - "micromatch": "^4.0.0", - "semver": "^6.0.0" - }, - "dependencies": { - "semver": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", - "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", - "dev": true - } - } - }, "tslib": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.0.0.tgz", @@ -9052,23 +8056,11 @@ "set-value": "^2.0.1" } }, - "unique-filename": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/unique-filename/-/unique-filename-1.1.1.tgz", - "integrity": "sha512-Vmp0jIp2ln35UTXuryvjzkjGdRyf9b2lTXuSYUiPmzRcl3FDtYqAwOnTJkAngD9SWhnoJzDbTKwaOrZ+STtxNQ==", - "dev": true, - "requires": { - "unique-slug": "^2.0.0" - } - }, - "unique-slug": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/unique-slug/-/unique-slug-2.0.2.tgz", - "integrity": "sha512-zoWr9ObaxALD3DOPfjPSqxt4fnZiWblxHIgeWqW8x7UqDzEtHEQLzji2cuJYQFCU6KmoJikOYAZlrTHHebjx2w==", - "dev": true, - "requires": { - "imurmurhash": "^0.1.4" - } + "universalify": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", + "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==", + "dev": true }, "unset-value": { "version": "1.0.0", @@ -9131,12 +8123,6 @@ "integrity": "sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ==", "dev": true }, - "util-deprecate": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", - "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", - "dev": true - }, "uuid": { "version": "7.0.3", "resolved": "https://registry.npmjs.org/uuid/-/uuid-7.0.3.tgz", @@ -9144,12 +8130,6 @@ "dev": true, "optional": true }, - "v8-compile-cache": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.1.1.tgz", - "integrity": "sha512-8OQ9CL+VWyt3JStj7HX7/ciTL2V3Rl1Wf5OL+SNTm0yK1KvtReVulksyeRnCANHHuUxHlQig+JJDlUhBt1NQDQ==", - "dev": true - }, "v8-to-istanbul": { "version": "4.1.4", "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-4.1.4.tgz", @@ -9226,290 +8206,12 @@ "makeerror": "1.0.x" } }, - "watchpack": { - "version": "2.0.0-beta.13", - "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.0.0-beta.13.tgz", - "integrity": "sha512-ZEFq2mx/k5qgQwgi6NOm+2ImICb8ngAkA/rZ6oyXZ7SgPn3pncf+nfhYTCrs3lmHwOxnPtGLTOuFLfpSMh1VMA==", - "dev": true, - "requires": { - "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.1.2" - } - }, "webidl-conversions": { "version": "6.1.0", "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-6.1.0.tgz", "integrity": "sha512-qBIvFLGiBpLjfwmYAaHPXsn+ho5xZnGvyGvsarywGNc8VyQJUMHJ8OBKGGrPER0okBeMDaan4mNBlgBROxuI8w==", "dev": true }, - "webpack": { - "version": "5.0.0-beta.22", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.0.0-beta.22.tgz", - "integrity": "sha512-t3HnQPy88PASM2ur0rvUXau8vAz287BlH8DpiaHoWkjlLThLx7olzExtTsVJEFen/9uTfWOV21dWS8kiYmGLkA==", - "dev": true, - "requires": { - "@types/estree": "^0.0.45", - "@webassemblyjs/ast": "1.9.0", - "@webassemblyjs/helper-module-context": "1.9.0", - "@webassemblyjs/wasm-edit": "1.9.0", - "@webassemblyjs/wasm-parser": "1.9.0", - "acorn": "^7.3.0", - "chrome-trace-event": "^1.0.2", - "enhanced-resolve": "5.0.0-beta.8", - "eslint-scope": "^5.0.0", - "events": "^3.0.0", - "glob-to-regexp": "^0.4.1", - "graceful-fs": "^4.1.15", - "json-parse-better-errors": "^1.0.2", - "loader-runner": "^4.0.0", - "mime-types": "^2.1.26", - "neo-async": "^2.6.1", - "pkg-dir": "^4.2.0", - "schema-utils": "^2.5.0", - "tapable": "^2.0.0-beta.10", - "terser-webpack-plugin": "^3.0.2", - "watchpack": "2.0.0-beta.13", - "webpack-sources": "2.0.0-beta.8" - }, - "dependencies": { - "@types/estree": { - "version": "0.0.45", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.45.tgz", - "integrity": "sha512-jnqIUKDUqJbDIUxm0Uj7bnlMnRm1T/eZ9N+AVMqhPgzrba2GhGG5o/jCTwmdPK709nEZsGoMzXEDUjcXHa3W0g==", - "dev": true - }, - "enhanced-resolve": { - "version": "5.0.0-beta.8", - "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.0.0-beta.8.tgz", - "integrity": "sha512-6MteIR5h29V8UAsBVXkW7P2cAf+5p/c+Gu79xNCpBPt+hgKcJ0vujcX4vAiMGJjyq3SCHaY5N64C8HXwwRS3gQ==", - "dev": true, - "requires": { - "graceful-fs": "^4.2.0", - "tapable": "^2.0.0-beta.10" - } - }, - "tapable": { - "version": "2.0.0-beta.11", - "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.0.0-beta.11.tgz", - "integrity": "sha512-cAhRzCvMdyJsxmdrSXG8/SUlJG4WJUxD/csuYAybUFjKVt74Y6pTyZ/I1ZK+enmCkWZN0JWxh14G69temaGSiA==", - "dev": true - } - } - }, - "webpack-cli": { - "version": "3.3.12", - "resolved": "https://registry.npmjs.org/webpack-cli/-/webpack-cli-3.3.12.tgz", - "integrity": "sha512-NVWBaz9k839ZH/sinurM+HcDvJOTXwSjYp1ku+5XKeOC03z8v5QitnK/x+lAxGXFyhdayoIf/GOpv85z3/xPag==", - "dev": true, - "requires": { - "chalk": "^2.4.2", - "cross-spawn": "^6.0.5", - "enhanced-resolve": "^4.1.1", - "findup-sync": "^3.0.0", - "global-modules": "^2.0.0", - "import-local": "^2.0.0", - "interpret": "^1.4.0", - "loader-utils": "^1.4.0", - "supports-color": "^6.1.0", - "v8-compile-cache": "^2.1.1", - "yargs": "^13.3.2" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "cliui": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", - "dev": true, - "requires": { - "string-width": "^3.1.0", - "strip-ansi": "^5.2.0", - "wrap-ansi": "^5.1.0" - } - }, - "emoji-regex": { - "version": "7.0.3", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", - "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", - "dev": true - }, - "find-up": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", - "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", - "dev": true, - "requires": { - "locate-path": "^3.0.0" - } - }, - "import-local": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/import-local/-/import-local-2.0.0.tgz", - "integrity": "sha512-b6s04m3O+s3CGSbqDIyP4R6aAwAeYlVq9+WUWep6iHa8ETRf9yei1U48C5MmfJmV9AiLYYBKPMq/W+/WRpQmCQ==", - "dev": true, - "requires": { - "pkg-dir": "^3.0.0", - "resolve-cwd": "^2.0.0" - } - }, - "is-fullwidth-code-point": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", - "dev": true - }, - "locate-path": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", - "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", - "dev": true, - "requires": { - "p-locate": "^3.0.0", - "path-exists": "^3.0.0" - } - }, - "p-locate": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", - "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", - "dev": true, - "requires": { - "p-limit": "^2.0.0" - } - }, - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", - "dev": true - }, - "pkg-dir": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-3.0.0.tgz", - "integrity": "sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw==", - "dev": true, - "requires": { - "find-up": "^3.0.0" - } - }, - "resolve-cwd": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/resolve-cwd/-/resolve-cwd-2.0.0.tgz", - "integrity": "sha1-AKn3OHVW4nA46uIyyqNypqWbZlo=", - "dev": true, - "requires": { - "resolve-from": "^3.0.0" - } - }, - "resolve-from": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-3.0.0.tgz", - "integrity": "sha1-six699nWiBvItuZTM17rywoYh0g=", - "dev": true - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "supports-color": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.1.0.tgz", - "integrity": "sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - }, - "wrap-ansi": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - } - }, - "yargs": { - "version": "13.3.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz", - "integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==", - "dev": true, - "requires": { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.2" - } - }, - "yargs-parser": { - "version": "13.1.2", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz", - "integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - } - } - }, - "webpack-merge": { - "version": "5.0.9", - "resolved": "https://registry.npmjs.org/webpack-merge/-/webpack-merge-5.0.9.tgz", - "integrity": "sha512-P4teh6O26xIDPugOGX61wPxaeP918QOMjmzhu54zTVcLtOS28ffPWtnv+ilt3wscwBUCL2WNMnh97XkrKqt9Fw==", - "dev": true, - "requires": { - "clone-deep": "^4.0.1", - "wildcard": "^2.0.0" - } - }, - "webpack-sources": { - "version": "2.0.0-beta.8", - "resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-2.0.0-beta.8.tgz", - "integrity": "sha512-RUaCJu7HYNeuzlY4WYcArcnOzMIj7kHndQ4pBdgP3iiMpG3Ke0BWY5wvb/VEFgsIXp3ZzPGRECwX+4fgpcKFYw==", - "dev": true, - "requires": { - "source-list-map": "^2.0.1", - "source-map": "~0.6.1" - }, - "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - } - } - }, "whatwg-encoding": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-1.0.5.tgz", @@ -9559,12 +8261,6 @@ "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", "dev": true }, - "wildcard": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/wildcard/-/wildcard-2.0.0.tgz", - "integrity": "sha512-JcKqAHLPxcdb9KM49dufGXn2x3ssnfjbcaQdLlfZsL9rH9wgDQjUtDxbo8NE0F6SFvydeu1VhZe7hZuHsB2/pw==", - "dev": true - }, "word-wrap": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.3.tgz", @@ -9651,12 +8347,6 @@ "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", "dev": true }, - "yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", - "dev": true - }, "yargs": { "version": "15.4.1", "resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz", diff --git a/package.json b/package.json index 4256c52..591187b 100644 --- a/package.json +++ b/package.json @@ -9,22 +9,21 @@ "@babel/plugin-transform-modules-commonjs": "^7.9.6", "@babel/preset-env": "^7.9.6", "@babel/preset-typescript": "^7.9.0", - "@rollup/plugin-node-resolve": "^8.0.0", - "@rollup/plugin-typescript": "^4.1.2", + "@rollup/plugin-babel": "^5.1.0", + "@rollup/plugin-commonjs": "^14.0.0", + "@rollup/plugin-node-resolve": "^8.4.0", + "@rollup/plugin-typescript": "^5.0.2", "@types/jest": "^25.2.3", "babel-jest": "^26.0.1", - "clean-webpack-plugin": "^3.0.0", "jest": "^26.0.1", - "terser-webpack-plugin": "^3.0.7", - "ts-loader": "^8.0.1", + "rollup": "^2.22.1", + "rollup-plugin-terser": "^6.1.0", + "rollup-plugin-typescript2": "^0.27.1", "tslib": "^2.0.0", - "typescript": "^3.9.3", - "webpack": "next", - "webpack-cli": "^3.3.12", - "webpack-merge": "^5.0.9" + "typescript": "^3.9.3" }, "scripts": { "test": "jest --coverage", - "build": "npx webpack --env.project=overlayscrollbars --env.production" + "build": "npx webpack --env.project=overlayscrollbars" } -} \ No newline at end of file +} diff --git a/packages/overlayscrollbars/dist/overlayscrollbars.esm.js b/packages/overlayscrollbars/dist/overlayscrollbars.esm.js index 9f1d740..8611f01 100644 --- a/packages/overlayscrollbars/dist/overlayscrollbars.esm.js +++ b/packages/overlayscrollbars/dist/overlayscrollbars.esm.js @@ -1,62 +1,75 @@ -!function(o, r) { - "object" == typeof exports && "object" == typeof module ? module.exports = r() : "function" == typeof define && define.amd ? define([], r) : "object" == typeof exports ? exports.OverlayScrollbars = r() : o.OverlayScrollbars = r(); -}(window, (function() { - return (() => { - "use strict"; - var o = { - 95: (o, r, e) => { - e.d(r, { - default: () => u - }); - function s(o) { - return "function" == typeof o; - } - function t(o) { - return Array.isArray(o); - } - function n(o) { - const r = !!o && o.length; - return t(o) || !s(o) && function(o) { - return "number" == typeof o; - }(r) && r > -1 && r % 1 == 0; - } - function i(o, r) { - let e = 0; - if (n(o)) for (;e < o.length && !1 !== r(o[e], e, o); e++) ; else if (o) for (e in o) if (!1 === r(o[e], e, o)) break; - return o; - } - const c = o => { - if (n(o)) i(Array.from(o), o => c(o)); else if (o) { - const r = o.parentNode; - r && r.removeChild(o); - } - }, l = o => { - const r = document.createElement("div"); - return r.innerHTML = o.trim(), i((o => o ? Array.from(o.childNodes) : [])(r), o => c(o)); - }; - const a = o => o.charAt(0).toUpperCase() + o.slice(1), d = [ "WebKit", "Moz", "O", "MS", "webkit", "moz", "o", "ms" ], f = {}, v = ((o => { - let r = f[o] || window[o]; - f.hasOwnProperty(o) || (i(d, e => (r = r || window[e + a(o)], !r)), f[o] = r); - })("ResizeObserver"), JSON.stringify, [ "__TPL_", "_TYPE__" ]); - [ "boolean", "number", "string", "array", "object", "function", "null" ].reduce((o, r) => (o[r] = v[0] + r + v[1], - o), {}); - new Set, new WeakMap; - const u = () => l('
fdfhdfgh
'); - } - }, r = {}; - function e(s) { - if (r[s]) return r[s].exports; - var t = r[s] = { - exports: {} - }; - return o[s](t, t.exports, e), t.exports; - } - return e.d = (o, r) => { - for (var s in r) e.o(r, s) && !e.o(o, s) && Object.defineProperty(o, s, { - enumerable: !0, - get: r[s] - }); - }, e.o = (o, r) => Object.prototype.hasOwnProperty.call(o, r), e(95); - })().default; -})); -//# sourceMappingURL=overlayscrollbars.esm.js.map \ No newline at end of file +import j from 'jquery'; + +function isNumber(obj) { + return typeof obj === 'number'; +} + +function isFunction(obj) { + return typeof obj === 'function'; +} + +function isArray(obj) { + return Array.isArray(obj); +} + +function isArrayLike(obj) { + const length = !!obj && obj.length; + return isArray(obj) || !isFunction(obj) && isNumber(length) && length > -1 && length % 1 == 0; +} + +function each(source, callback) { + let i = 0; + + if (isArrayLike(source)) { + for (; i < source.length; i++) { + if (callback(source[i], i, source) === false) break; + } + } else if (source) { + for (i in source) { + if (callback(source[i], i, source) === false) break; + } + } + + return source; +} + +const contents = elm => { + return elm ? Array.from(elm.childNodes) : []; +}; + +const removeElements = nodes => { + if (isArrayLike(nodes)) { + each(Array.from(nodes), e => removeElements(e)); + } else if (nodes) { + const parentNode = nodes.parentNode; + if (parentNode) parentNode.removeChild(nodes); + } +}; + +const createDiv = () => { + return document.createElement('div'); +}; + +const createDOM = html => { + const elm = createDiv(); + elm.innerHTML = html.trim(); + return each(contents(elm), elm => removeElements(elm)); +}; + +const abc = { + a: 1, + b: 1, + c: 1 +}; + +var index = () => { + const { + a, + b, + c + } = abc; + return [createDOM("
fdfhdfgh
"), j('div'), a, b, c]; +}; + +export default index; +//# sourceMappingURL=overlayscrollbars.esm.js.map diff --git a/packages/overlayscrollbars/dist/overlayscrollbars.esm.js.map b/packages/overlayscrollbars/dist/overlayscrollbars.esm.js.map index 4da5fb6..3108bed 100644 --- a/packages/overlayscrollbars/dist/overlayscrollbars.esm.js.map +++ b/packages/overlayscrollbars/dist/overlayscrollbars.esm.js.map @@ -1 +1 @@ -{"version":3,"sources":["webpack://OverlayScrollbars/webpack/universalModuleDefinition","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/utils/types.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/utils/arrays.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/dom/manipulation.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/dom/create.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/dom/traversal.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/compatibility/vendors.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/options/validation.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/compatibility/apis.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/instances.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/index.ts","webpack://OverlayScrollbars/webpack/bootstrap","webpack://OverlayScrollbars/webpack/startup","webpack://OverlayScrollbars/webpack/runtime/define property getters","webpack://OverlayScrollbars/webpack/runtime/hasOwnProperty shorthand"],"names":["root","factory","exports","module","define","amd","window","isFunction","obj","isArray","Array","isArrayLike","length","isNumber","each","source","callback","i","removeElements","nodes","from","e","parentNode","removeChild","createDOM","html","elm","document","createElement","innerHTML","trim","childNodes","contents","firstLetterToUpper","str","charAt","toUpperCase","slice","jsPrefixes","jsCache","templateTypePrefixSuffix","name","result","hasOwnProperty","prefix","jsAPI","JSON","stringify","reduce","item","Set","WeakMap","__webpack_module_cache__","__webpack_require__","moduleId","__webpack_modules__","d","definition","key","o","Object","defineProperty","enumerable","get","prop","prototype","call"],"mappings":"CAAA,SAA2CA,GAAMC;IAC1B,mBAAZC,WAA0C,mBAAXC,SACxCA,OAAOD,UAAUD,MACQ,qBAAXG,UAAyBA,OAAOC,MAC9CD,OAAO,IAAIH,KACe,mBAAZC,UACdA,QAA2B,oBAAID,MAE/BD,EAAwB,oBAAIC;CAR9B,CASGK,SAAQ;IACX,O;;;;;;;gBCgBO,SAASC,EAAWC;oBACvB,OAAsB,qBAARA;;gBAWX,SAASC,EAAQD;oBACpB,OAAOE,MAAMD,QAAQD;;gBAQlB,SAASG,EAAyCH;oBACrD,MAAMI,MAAWJ,KAAOA,EAAII;oBAC5B,OAAOH,EAAQD,OAAUD,EAAWC,MAvCjC,SAAkBA;wBACrB,OAAsB,mBAARA;qBAsC8BK,CAASD,MAAWA,KAAU,KAAKA,IAAS,KAAK;;gBChC1F,SAASE,EAAQC,GAA2CC;oBAC/D,IAAIC,IAAqB;oBAEzB,IAAIN,EAAYI,IACZ,MAAOE,IAAIF,EAAOH,WACyB,MAAnCI,EAASD,EAAOE,IAAIA,GAAGF,IADLE,YAKzB,IAAIF,GACL,KAAKE,KAAKF,GACN,KAAuC,MAAnCC,EAASD,EAAOE,IAAIA,GAAGF,IACvB;oBAGZ,OAAOA;;gBASJ,MCwCMG,IAAmDC;oBAC5D,IAAIR,EAAYQ,IACZL,EAAKJ,MAAMU,KAAKD,IAASE,KAAMH,EAAeG,UAE7C,IAAIF,GAAO;wBACZ,MAAMG,IAAaH,EAAMG;wBACrBA,KACAA,EAAWC,YAAYJ;;mBChFtBK,IAAoDC;oBAC7D,MAAMC,IAJCC,SAASC,cAAc;oBAO9B,OAFAF,EAAIG,YAAYJ,EAAKK,QAEdhB,ECmCgE,CAACY,KACjEA,IAAMhB,MAAMU,KAAgBM,EAAIK,cAAc,GDpCzCC,CAASN,IAAOA,KAAQR,EAAeQ;;gBETvD,MAAMO,IAA+CC,KAC1CA,EAAIC,OAAO,GAAGC,gBAAgBF,EAAIG,MAAM,IAStCC,IAAoC,EAAC,UAAU,OAAO,KAAK,MAAM,UAAU,OAAO,KAAK,QAEvFC,IAAkC,ICNzCC,KD4EsC,CAACC;oBACzC,IAAIC,IAAcH,EAAQE,MAASnC,OAAOmC;oBAEtCF,EAAQI,eAAeF,OAG3B3B,EAAKwB,GAAaM,MACdF,IAASA,KAAUpC,OAAOsC,IAASX,EAAmBQ,MAC9CC,KAGZH,EAAQE,KAAQC;kBE9F2BG,CAAM,mBDEnCC,KAAKC,WAKqC,EAAC,UAAU;gBAMV,EACzD,WACA,UACA,UACA,SACA,UACA,YACA,SACFC,OAAO,CAACN,GAAQO,OACdP,EAAOO,KAAQT,EAAyB,KAAKS,IAAOT,EAAyB;gBACtEE,IACR;gBE1B2B,IAAIQ,KACe,IAAIC;gBADrD,MCWA,UAAqB3B,EAAU;;WCV3B4B,IAA2B;QAG/B,SAASC,EAAoBC;YAE5B,IAAGF,EAAyBE,IAC3B,OAAOF,EAAyBE,GAAUpD;YAG3C,IAAIC,IAASiD,EAAyBE,KAAY;gBAGjDpD,SAAS;;YAOV,OAHAqD,EAAoBD,GAAUnD,GAAQA,EAAOD,SAASmD,IAG/ClD,EAAOD;;QCjBf,OCFAmD,EAAoBG,IAAI,CAACtD,GAASuD;YACjC,KAAI,IAAIC,KAAOD,GACXJ,EAAoBM,EAAEF,GAAYC,OAASL,EAAoBM,EAAEzD,GAASwD,MAC5EE,OAAOC,eAAe3D,GAASwD,GAAK;gBAAEI,aAAY;gBAAMC,KAAKN,EAAWC;;WCJ3EL,EAAoBM,IAAI,CAACnD,GAAKwD,MAASJ,OAAOK,UAAUtB,eAAeuB,KAAK1D,GAAKwD,IFG1EX,EAAoB","file":"overlayscrollbars.esm.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"OverlayScrollbars\"] = factory();\n\telse\n\t\troot[\"OverlayScrollbars\"] = factory();\n})(window, function() {\nreturn ","import { PlainObject } from 'core/typings';\r\n\r\nexport const type: (obj: any) => string = (obj) => {\r\n if (obj === undefined)\r\n return obj + '';\r\n if (obj === null)\r\n return obj + '';\r\n return Object.prototype.toString.call(obj).replace(/^\\[object (.+)\\]$/, '$1').toLowerCase();\r\n}\r\n\r\nexport function isNumber(obj: any): obj is number {\r\n return typeof obj === 'number';\r\n};\r\n\r\nexport function isString(obj: any): obj is string {\r\n return typeof obj === 'string';\r\n}\r\n\r\nexport function isBoolean(obj: any): obj is boolean {\r\n return typeof obj === 'boolean';\r\n}\r\n\r\nexport function isObject(obj: any): boolean {\r\n return typeof obj === 'object' && !isArray(obj) && !isNull(obj);\r\n}\r\n\r\nexport function isFunction(obj: any): obj is Function {\r\n return typeof obj === 'function';\r\n}\r\n\r\nexport function isUndefined(obj: any): obj is undefined {\r\n return obj === undefined;\r\n}\r\n\r\nexport function isNull(obj: any): obj is null {\r\n return obj === null;\r\n}\r\n\r\nexport function isArray(obj: any): obj is Array {\r\n return Array.isArray(obj);\r\n}\r\n\r\n\r\n/**\r\n * Returns true if the given object is array like, false otherwise.\r\n * @param obj The Object\r\n */\r\nexport function isArrayLike(obj: any): obj is ArrayLike {\r\n const length = !!obj && obj.length;\r\n return isArray(obj) || (!isFunction(obj) && isNumber(length) && length > -1 && length % 1 == 0);\r\n}\r\n\r\n/**\r\n * Returns true if the given object is a \"plain\" (e.g. { key: value }) object, false otherwise. \r\n * @param obj The Object.\r\n */\r\nexport function isPlainObject(obj: any): obj is PlainObject {\r\n if (!obj || !isObject(obj) || type(obj) !== 'object')\r\n return false;\r\n\r\n let key;\r\n const proto = 'prototype';\r\n const hasOwnProperty = Object[proto].hasOwnProperty;\r\n const hasOwnConstructor = hasOwnProperty.call(obj, 'constructor');\r\n const hasIsPrototypeOf = obj.constructor && obj.constructor[proto] && hasOwnProperty.call(obj.constructor[proto], 'isPrototypeOf');\r\n\r\n if (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) {\r\n return false;\r\n }\r\n\r\n for (key in obj) { /**/ }\r\n\r\n return isUndefined(key) || hasOwnProperty.call(obj, key);\r\n};\r\n\r\n/**\r\n * Checks whether the given object is a HTMLElement.\r\n * @param obj The object which shall be checked.\r\n */\r\nexport function isHTMLElement(obj: any): obj is HTMLElement {\r\n const instaceOfRightHandSide = window.HTMLElement;\r\n const doInstanceOf = isObject(instaceOfRightHandSide) || isFunction(instaceOfRightHandSide);\r\n return !!(\r\n doInstanceOf ? obj instanceof instaceOfRightHandSide : (obj && isObject(obj) && obj.nodeType === 1 && isString(obj.nodeName))\r\n );\r\n}\r\n\r\n/**\r\n * Returns true if the given object is empty, false otherwise.\r\n * @param obj The Object.\r\n */\r\nexport function isEmptyObject(obj: any): boolean {\r\n for (let name in obj)\r\n return false;\r\n return true;\r\n};","import { isArrayLike } from 'core/utils/types';\r\nimport { PlainObject } from 'core/typings';\r\n\r\n\r\n/**\r\n * Iterates through a array or object\r\n * @param arrayLikeOrObject The array or object through which shall be iterated.\r\n * @param callback The function which is responsible for the iteration. \r\n * If the function returns true its treated like a \"continue\" statement.\r\n * If the function returns false its treated like a \"break\" statement.\r\n */\r\nexport function each(array: Array | ReadonlyArray, callback: (value: T, indexOrKey: number, source: Array) => boolean | void): Array | ReadonlyArray;\r\nexport function each(array: Array | ReadonlyArray | null, callback: (value: T, indexOrKey: number, source: Array) => boolean | void): Array | ReadonlyArray | null;\r\nexport function each(arrayLikeObject: ArrayLike, callback: (value: T, indexOrKey: number, source: ArrayLike) => boolean | void): ArrayLike;\r\nexport function each(arrayLikeObject: ArrayLike | null, callback: (value: T, indexOrKey: number, source: ArrayLike) => boolean | void): ArrayLike | null;\r\nexport function each(obj: PlainObject, callback: (value: any, indexOrKey: string, source: PlainObject) => boolean | void): PlainObject;\r\nexport function each(obj: PlainObject | null, callback: (value: any, indexOrKey: string, source: PlainObject) => boolean | void): PlainObject | null;\r\nexport function each(source: ArrayLike | PlainObject | null, callback: (value: T | any, indexOrKey: any, source: any) => boolean | void): Array | ReadonlyArray | ArrayLike | PlainObject | null {\r\n let i: number | string = 0;\r\n\r\n if (isArrayLike(source)) {\r\n for (; i < source.length; i++) {\r\n if (callback(source[i], i, source) === false)\r\n break;\r\n }\r\n }\r\n else if (source) {\r\n for (i in source) {\r\n if (callback(source[i], i, source) === false)\r\n break;\r\n }\r\n }\r\n return source;\r\n};\r\n\r\n/**\r\n * Returns the index of the given inside the given array or -1 if the given item isn't part of the given array.\r\n * @param arr The array.\r\n * @param item The item.\r\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\r\n */\r\nexport const indexOf: (arr: Array, item: T, fromIndex?: number) => number = (arr, item, fromIndex) => {\r\n return arr.indexOf(item, fromIndex);\r\n}","import { isArrayLike, isHTMLElement } from 'core/utils/types';\r\nimport { each } from 'core/utils/arrays';\r\nimport { parent } from 'core/dom/traversal';\r\n\r\ntype NodeCollection = ArrayLike | Node | undefined | null;\r\n\r\n/**\r\n * Inserts Nodes before the given preferredAnchor element.\r\n * @param parent The parent of the preferredAnchor element or the element which shall be the parent of the inserted Nodes.\r\n * @param preferredAnchor The element before which the Nodes shall be inserted or null if the elements shall be appended at the end.\r\n * @param insertedElms The Nodes which shall be inserted.\r\n */\r\nconst before: (parent: Node | null, preferredAnchor: Node | null, insertedElms: NodeCollection) => void = (parent, preferredAnchor, insertedElms) => {\r\n if (insertedElms) {\r\n let anchor: Node | null = preferredAnchor;\r\n let fragment: DocumentFragment | Node | undefined | null;\r\n\r\n // parent must be defined\r\n if (parent) {\r\n if (isArrayLike(insertedElms)) {\r\n fragment = document.createDocumentFragment();\r\n\r\n // append all insertedElms to the fragment and if one of these is the anchor, change the anchor\r\n each(insertedElms, (insertedElm) => {\r\n if (insertedElm === anchor) {\r\n anchor = insertedElm.previousSibling;\r\n }\r\n fragment!.appendChild(insertedElm);\r\n });\r\n }\r\n else {\r\n fragment = insertedElms;\r\n }\r\n\r\n // if the preferred anchor isn't null set it to a valid anchor\r\n if (preferredAnchor) {\r\n if (!anchor) {\r\n anchor = parent.firstChild;\r\n }\r\n else if (anchor !== preferredAnchor) {\r\n anchor = anchor.nextSibling;\r\n }\r\n }\r\n\r\n parent.insertBefore(fragment, anchor);\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * Appends the given children at the end of the given Node.\r\n * @param node The Node to which the children shall be appended.\r\n * @param children The Nodes which shall be appended.\r\n */\r\nexport const appendChildren: (node: Node | null, children: NodeCollection) => void = (node, children) => { before(node, null, children) };\r\n\r\n/**\r\n * Prepends the given children at the start of the given Node.\r\n * @param node The Node to which the children shall be prepended.\r\n * @param children The Nodes which shall be prepended.\r\n */\r\nexport const prependChildren: (node: Node | null, children: NodeCollection) => void = (node, children) => { before(node, node && node.firstChild, children) };\r\n\r\n/**\r\n * Inserts the given Nodes before the given Node.\r\n * @param node The Node before which the given Nodes shall be inserted.\r\n * @param insertedNodes The Nodes which shall be inserted.\r\n */\r\nexport const insertBefore: (node: Node | null, insertedNodes: NodeCollection) => void = (node, insertedNodes) => { before(parent(node), node, insertedNodes) };\r\n\r\n/**\r\n * Inserts the given Nodes after the given Node.\r\n * @param node The Node after which the given Nodes shall be inserted.\r\n * @param insertedNodes The Nodes which shall be inserted.\r\n */\r\nexport const insertAfter: (node: Node | null, insertedNodes: NodeCollection) => void = (node, insertedNodes) => { before(parent(node), node && node.nextSibling, insertedNodes) };\r\n\r\n/**\r\n * Removes the given Nodes from their parent.\r\n * @param nodes The Nodes which shall be removed.\r\n */\r\nexport const removeElements: (nodes: NodeCollection) => void = (nodes) => {\r\n if (isArrayLike(nodes)) {\r\n each(Array.from(nodes), (e) => removeElements(e));\r\n }\r\n else if (nodes) {\r\n const parentNode = nodes.parentNode;\r\n if (parentNode)\r\n parentNode.removeChild(nodes);\r\n }\r\n}","import { each } from 'core/utils/arrays';\r\nimport { contents } from 'core/dom/traversal';\r\nimport { removeElements } from 'core/dom/manipulation';\r\n\r\nexport const createDiv: () => HTMLDivElement = () => {\r\n return document.createElement('div');\r\n}\r\n\r\nexport const createDOM: (html: string) => ReadonlyArray = (html) => {\r\n const elm = createDiv();\r\n elm.innerHTML = html.trim();\r\n\r\n return each(contents(elm), (elm) => removeElements(elm));\r\n}","import { each } from 'core/utils/arrays';\r\n\r\nconst elementIsVisible: (elm: HTMLElement) => boolean = (elm) => {\r\n return !!(elm.offsetWidth || elm.offsetHeight || elm.getClientRects().length);\r\n}\r\n\r\nexport const find: (selector: string, elm?: Element | null) => ReadonlyArray = (selector, elm?) => {\r\n const arr: Array = [];\r\n\r\n each((elm || document).querySelectorAll(selector), (e: Element) => {\r\n arr.push(e);\r\n });\r\n\r\n return arr;\r\n}\r\n\r\nexport const findFirst: (selector: string, elm?: Element | null) => Element | null = (selector, elm?) => {\r\n return (elm || document).querySelector(selector);\r\n}\r\n\r\nexport const is: (elm: Element | null, selector: string) => boolean = (elm, selector) => {\r\n if (elm) {\r\n if (selector === ':visible')\r\n return elementIsVisible(elm as HTMLElement);\r\n if (selector === ':hidden')\r\n return !elementIsVisible(elm as HTMLElement);\r\n if (elm.matches(selector))\r\n return true;\r\n }\r\n return false;\r\n}\r\n\r\nexport const children: (elm: Element | null, selector?: string) => ReadonlyArray = (elm, selector?) => {\r\n const children: Array = [];\r\n\r\n each(elm && elm.children, (child: Element) => {\r\n if (selector) {\r\n if (child.matches(selector))\r\n children.push(child);\r\n }\r\n else\r\n children.push(child);\r\n });\r\n\r\n return children;\r\n}\r\n\r\nexport const contents: (elm: Element | null) => ReadonlyArray = (elm) => {\r\n return elm ? Array.from(elm.childNodes) : [];\r\n}\r\n\r\nexport const parent: (elm: Node | null) => Node | null = (elm) => elm ? elm.parentElement : null;","import { each } from 'core/utils';\r\nimport { createDiv } from 'core/dom';\r\n\r\nconst firstLetterToUpper: (str: string) => string = (str) => {\r\n return str.charAt(0).toUpperCase() + str.slice(1);\r\n}\r\nconst getDummyStyle: () => CSSStyleDeclaration = () => {\r\n return createDiv().style;\r\n}\r\n\r\n//https://developer.mozilla.org/en-US/docs/Glossary/Vendor_Prefix\r\n\r\nexport const cssPrefixes: ReadonlyArray = ['-webkit-', '-moz-', '-o-', '-ms-'];\r\nexport const jsPrefixes: ReadonlyArray = ['WebKit', 'Moz', 'O', 'MS', 'webkit', 'moz', 'o', 'ms'];\r\n\r\nexport const jsCache: { [key: string]: any } = {};\r\nexport const cssCache: { [key: string]: string } = {};\r\n\r\n/**\r\n * Gets the name of the given CSS property with vendor prefix if it isn't supported without, or undefined if unsupported.\r\n * @param name The name of the CSS property which shall be get.\r\n */\r\nexport const cssProperty: (name: string) => string | undefined = (name) => {\r\n let result: string | undefined = cssCache[name];\r\n\r\n if (cssCache.hasOwnProperty(name))\r\n return result;\r\n\r\n const uppercasedName: string = firstLetterToUpper(name);\r\n const elmStyle: CSSStyleDeclaration = getDummyStyle();\r\n\r\n each(cssPrefixes, (prefix: string) => {\r\n const prefixWithoutDashes: string = prefix.replace(/-/g, '');\r\n const resultPossibilities: Array = [\r\n name, //transition\r\n prefix + name, //-webkit-transition\r\n prefixWithoutDashes + uppercasedName, //webkitTransition\r\n firstLetterToUpper(prefixWithoutDashes) + uppercasedName //WebkitTransition\r\n ];\r\n result = resultPossibilities.find((resultPossibility: string) => elmStyle[resultPossibility] !== undefined);\r\n return !result;\r\n });\r\n\r\n cssCache[name] = result;\r\n return result;\r\n}\r\n\r\n/**\r\n * Get the name of the given CSS property value(s), with vendor prefix if it isn't supported wuthout, or undefined if no value is supported. \r\n * @param property The CSS property to which the CSS property value(s) belong.\r\n * @param values The value(s) separated by spaces which shall be get.\r\n * @param suffix A suffix which is added to each value in case the value is a function or something else more advanced.\r\n */\r\nexport const cssPropertyValue: (property: string, values: string, suffix?: string) => string | undefined = (property, values, suffix) => {\r\n const name: string = property + ' ' + values;\r\n let result: string | undefined = cssCache[name];\r\n\r\n if (cssCache.hasOwnProperty(name))\r\n return result;\r\n\r\n const dummyStyle: CSSStyleDeclaration = getDummyStyle();\r\n const possbleValues: Array = values.split(' ');\r\n const preparedSuffix: string = suffix || '';\r\n const cssPrefixesWithFirstEmpty = [''].concat(cssPrefixes);\r\n\r\n each(possbleValues, (possibleValue: string) => {\r\n each(cssPrefixesWithFirstEmpty, (prefix: string) => {\r\n const prop = prefix + possibleValue;\r\n dummyStyle.cssText = property + ':' + prop + preparedSuffix;\r\n if (dummyStyle.length) {\r\n result = prop;\r\n return false;\r\n }\r\n });\r\n return !result;\r\n });\r\n\r\n cssCache[name] = result;\r\n return result;\r\n}\r\n\r\n/**\r\n * Get the requested JS function, object or constructor with vendor prefix if it isn't supported without or undefined if unsupported.\r\n * @param name The name of the JS function, object or constructor.\r\n */\r\nexport const jsAPI: (name: string) => any = (name) => {\r\n let result: any = jsCache[name] || window[name];\r\n\r\n if (jsCache.hasOwnProperty(name))\r\n return result;\r\n\r\n each(jsPrefixes, (prefix: string) => {\r\n result = result || window[prefix + firstLetterToUpper(name)];\r\n return !result;\r\n });\r\n\r\n jsCache[name] = result;\r\n return result;\r\n}\r\n","import { each, indexOf } from 'core/utils/arrays';\r\nimport { type, isArray, isUndefined, isEmptyObject, isPlainObject, isString } from 'core/utils/types';\r\nimport { PlainObject, OptionsTemplate, OptionsTemplateTypes, OptionsTemplateType, OptionsValidated, Func, OptionsValidatedResult } from 'core/typings';\r\n\r\nconst stringify = JSON.stringify;\r\n\r\n/**\r\n * A prefix and suffix tuple which serves as recognition pattern for template types.\r\n */\r\nconst templateTypePrefixSuffix: readonly [string, string] = ['__TPL_', '_TYPE__'];\r\n/**\r\n * A object which serves as a mapping for \"normal\" types and template types.\r\n * Key = normal type string\r\n * value = template type string\r\n */\r\nconst optionsTemplateTypes: OptionsTemplateTypesDictionary = [\r\n 'boolean',\r\n 'number',\r\n 'string',\r\n 'array',\r\n 'object',\r\n 'function',\r\n 'null'\r\n].reduce((result, item) => {\r\n result[item] = templateTypePrefixSuffix[0] + item + templateTypePrefixSuffix[1];\r\n return result;\r\n}, {} as OptionsTemplateTypesDictionary);\r\n\r\n/**\r\n * Validates the given options object according to the given template object and returns a object which looks like:\r\n * {\r\n * foreign : a object which consists of properties which aren't defined inside the template. (foreign properties)\r\n * validated : a object which consists only of valid properties. (property name is inside the template and value has a correct type)\r\n * }\r\n * @param options The options object which shall be validated.\r\n * @param template The template according to which the options object shall be validated.\r\n * @param optionsDiff When provided the returned validated object will only have properties which are different to this objects properties.\r\n * Example (assume all properties are valid to the template): \r\n * Options object : { a: 'a', b: 'b', c: 'c' }\r\n * optionsDiff object : { a: 'a', b: 'b', c: undefined }\r\n * Returned validated object : { c: 'c' }\r\n * Because the value of the properties a and b didn't change, they aren't included in the returned object.\r\n * Without the optionsDiff object the returned validated object would be: { a: 'a', b: 'b', c: 'c' }\r\n * @param doWriteErrors True if errors shall be logged into the console, false otherwise.\r\n * @param propPath The propertyPath which lead to this object. (used for error logging)\r\n */\r\nconst validateRecursive = function (options: T, template: OptionsTemplate>, optionsDiff: OptionsValidated, doWriteErrors?: boolean, propPath?: string): OptionsValidatedResult {\r\n const validatedOptions: OptionsValidated = {};\r\n const optionsCopy: T = Object.assign({}, options);\r\n const props = Object.keys(template).filter(prop => options.hasOwnProperty(prop));\r\n\r\n each(props, (prop: Extract) => {\r\n const optionsDiffValue: any = isUndefined(optionsDiff[prop]) ? {} : optionsDiff[prop];\r\n const optionsValue: any = options[prop];\r\n const templateValue: PlainObject | string | OptionsTemplateTypes | Array = template[prop];\r\n const templateIsComplex = isPlainObject(templateValue);\r\n const propPrefix = propPath ? propPath + '.' : '';\r\n\r\n //if the template has a object as value, it means that the options are complex (verschachtelt)\r\n if (templateIsComplex && isPlainObject(optionsValue)) {\r\n const validatedResult = validateRecursive(optionsValue, templateValue as PlainObject, optionsDiffValue, doWriteErrors, propPrefix + prop);\r\n validatedOptions[prop] = validatedResult.validated;\r\n optionsCopy[prop] = validatedResult.foreign as any;\r\n\r\n each([optionsCopy, validatedOptions], (value) => {\r\n if (isEmptyObject(value[prop])) {\r\n delete value[prop];\r\n }\r\n });\r\n }\r\n else if (!templateIsComplex) {\r\n let isValid = false;\r\n const errorEnumStrings: Array = [];\r\n const errorPossibleTypes: Array = [];\r\n const optionsValueType = type(optionsValue);\r\n const templateValueArr: Array = !isArray(templateValue) ? [templateValue as string | OptionsTemplateTypes] : templateValue as Array;\r\n\r\n each(templateValueArr, (currTemplateType) => {\r\n //if currType value isn't inside possibleTemplateTypes we assume its a enum string value\r\n const isEnumString = indexOf(Object.values(optionsTemplateTypes), currTemplateType) < 0;\r\n if (isEnumString && isString(optionsValue)) {\r\n //split it into a array which contains all possible values for example: [\"yes\", \"no\", \"maybe\"]\r\n const enumStringSplit = currTemplateType.split(' ');\r\n isValid = !!enumStringSplit.find(possibility => possibility === optionsValue);\r\n\r\n // build error message\r\n errorEnumStrings.push(...enumStringSplit);\r\n }\r\n else {\r\n isValid = optionsTemplateTypes[optionsValueType] === currTemplateType;\r\n }\r\n\r\n // build error message\r\n errorPossibleTypes.push(isEnumString ? optionsTemplateTypes.string : currTemplateType);\r\n\r\n // continue if invalid, break if valid\r\n return !isValid;\r\n });\r\n\r\n\r\n if (isValid) {\r\n const doStringifyComparison = isArray(optionsValue) || isPlainObject(optionsValue);\r\n if (doStringifyComparison ? stringify(optionsValue) !== stringify(optionsDiffValue) : optionsValue !== optionsDiffValue) {\r\n validatedOptions[prop] = optionsValue;\r\n }\r\n }\r\n else if (doWriteErrors) {\r\n console.warn(`The option \"${propPrefix}${prop}\" wasn't set, because it doesn't accept the type [ ${optionsValueType.toUpperCase()} ] with the value of \"${optionsValue}\".\\r\\n` +\r\n `Accepted types are: [ ${errorPossibleTypes.join(', ').toUpperCase()} ].\\r\\n` +\r\n (errorEnumStrings.length > 0 ? `\\r\\nValid strings are: [ ${errorEnumStrings.join(', ')} ].` : ''))\r\n }\r\n\r\n delete optionsCopy[prop];\r\n }\r\n });\r\n\r\n return {\r\n foreign: optionsCopy,\r\n validated: validatedOptions\r\n };\r\n};\r\n\r\n/**\r\n * Validates the given options object according to the given template object and returns a object which looks like:\r\n * {\r\n * foreign : a object which consists of properties which aren't defined inside the template. (foreign properties)\r\n * validated : a object which consists only of valid properties. (property name is inside the template and value has a correct type)\r\n * }\r\n * @param options The options object which shall be validated.\r\n * @param template The template according to which the options object shall be validated.\r\n * @param optionsDiff When provided the returned validated object will only have properties which are different to this objects properties.\r\n * Example (assume all properties are valid to the template): \r\n * Options object : { a: 'a', b: 'b', c: 'c' }\r\n * optionsDiff object : { a: 'a', b: 'b', c: undefined }\r\n * Returned validated object : { c: 'c' }\r\n * Because the value of the properties a and b didn't change, they aren't included in the returned object.\r\n * Without the optionsDiff object the returned validated object would be: { a: 'a', b: 'b', c: 'c' }\r\n * @param doWriteErrors True if errors shall be logged into the console, false otherwise.\r\n */\r\nconst validate = function (options: T, template: OptionsTemplate>, optionsDiff?: OptionsValidated, doWriteErrors?: boolean): OptionsValidatedResult {\r\n /*\r\n if (!isEmptyObject(foreign) && doWriteErrors)\r\n console.warn(`The following options are discarded due to invalidity:\\r\\n ${window.JSON.stringify(foreign, null, 2)}`);\r\n\r\n \r\n //add values, which aren't specified in the template, to the finished validated object to prevent them from being discarded\r\n if (keepForeignProps) {\r\n Object.assign(result.validated, foreign);\r\n }\r\n */\r\n return validateRecursive(options, template, optionsDiff || {}, doWriteErrors || false);\r\n};\r\n\r\nexport { validate, optionsTemplateTypes };\r\n\r\ntype OptionsTemplateTypesDictionary = {\r\n readonly boolean: OptionsTemplateType;\r\n readonly number: OptionsTemplateType;\r\n readonly string: OptionsTemplateType;\r\n readonly array: OptionsTemplateType>;\r\n readonly object: OptionsTemplateType;\r\n readonly function: OptionsTemplateType;\r\n readonly null: OptionsTemplateType;\r\n}\r\n","import { jsAPI } from 'core/compatibility/vendors';\r\n\r\nexport const resizeObserver: any | undefined = jsAPI('ResizeObserver');","const targets: Set = new Set();\r\nconst targetInstanceMap: WeakMap = new WeakMap();\r\n\r\n/**\r\n * Adds the given OverlayScrollbars instance to the given element.\r\n * @param target The element which is the target of the OverlayScrollbars instance.\r\n * @param osInstance The OverlayScrollbars instance.\r\n */\r\nexport const addInstance: (target: Element, osInstance: any) => void = (target, osInstance) => {\r\n targetInstanceMap.set(target, osInstance);\r\n targets.add(target);\r\n}\r\n\r\n/**\r\n * Removes a OverlayScrollbars instance from the given element.\r\n * @param target The element from which its OverlayScrollbars instance shall be removed.\r\n */\r\nexport const removeInstance: (target: Element) => void = (target) => {\r\n targetInstanceMap.delete(target);\r\n targets.delete(target);\r\n}\r\n\r\n/**\r\n * Gets the OverlayScrollbars from the given element or undefined if it doesn't have one.\r\n * @param target The element of which its OverlayScrollbars instance shall be get.\r\n */\r\nexport const getInstance: (target: Element) => any = (target) => {\r\n return targetInstanceMap.get(target);\r\n}\r\n\r\n/**\r\n * Gets a Map which represents all active OverayScrollbars instances. \r\n * The Key is the ekement and the value is the instance.\r\n */\r\nexport const allInstances: () => ReadonlyMap = () => {\r\n const validTargetInstanceMap: Map = new Map();\r\n\r\n targets.forEach((target: Element) => {\r\n /* istanbul ignore else */\r\n if (targetInstanceMap.has(target)) {\r\n validTargetInstanceMap.set(target, targetInstanceMap.get(target))\r\n }\r\n });\r\n\r\n targets.clear();\r\n\r\n validTargetInstanceMap.forEach((instance: any, validTarget: Element) => {\r\n targets.add(validTarget);\r\n });\r\n\r\n return validTargetInstanceMap;\r\n}","\r\nimport { createDOM } from 'core/dom';\r\n\r\nexport * from 'core/compatibility';\r\nexport * from 'core/utils';\r\nexport * from 'core/dom';\r\nexport * from 'core/options';\r\nexport * from 'instances';\r\n\r\n\r\n\r\nexport default () => createDOM(`\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n fdfhdfgh\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
`);","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tif(__webpack_module_cache__[moduleId]) {\n\t\treturn __webpack_module_cache__[moduleId].exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// module exports must be returned from runtime so entry inlining is disabled\n// startup\n// Load entry module and return exports\nreturn __webpack_require__(95);\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => Object.prototype.hasOwnProperty.call(obj, prop)"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"overlayscrollbars.esm.js","sources":["../src/core/utils/types.ts","../src/core/utils/arrays.ts","../src/core/dom/traversal.ts","../src/core/dom/manipulation.ts","../src/core/dom/create.ts","../src/index.ts"],"sourcesContent":["import { PlainObject } from 'core/typings';\r\n\r\nexport const type: (obj: any) => string = (obj) => {\r\n if (obj === undefined)\r\n return obj + '';\r\n if (obj === null)\r\n return obj + '';\r\n return Object.prototype.toString.call(obj).replace(/^\\[object (.+)\\]$/, '$1').toLowerCase();\r\n}\r\n\r\nexport function isNumber(obj: any): obj is number {\r\n return typeof obj === 'number';\r\n};\r\n\r\nexport function isString(obj: any): obj is string {\r\n return typeof obj === 'string';\r\n}\r\n\r\nexport function isBoolean(obj: any): obj is boolean {\r\n return typeof obj === 'boolean';\r\n}\r\n\r\nexport function isObject(obj: any): boolean {\r\n return typeof obj === 'object' && !isArray(obj) && !isNull(obj);\r\n}\r\n\r\nexport function isFunction(obj: any): obj is Function {\r\n return typeof obj === 'function';\r\n}\r\n\r\nexport function isUndefined(obj: any): obj is undefined {\r\n return obj === undefined;\r\n}\r\n\r\nexport function isNull(obj: any): obj is null {\r\n return obj === null;\r\n}\r\n\r\nexport function isArray(obj: any): obj is Array {\r\n return Array.isArray(obj);\r\n}\r\n\r\n\r\n/**\r\n * Returns true if the given object is array like, false otherwise.\r\n * @param obj The Object\r\n */\r\nexport function isArrayLike(obj: any): obj is ArrayLike {\r\n const length = !!obj && obj.length;\r\n return isArray(obj) || (!isFunction(obj) && isNumber(length) && length > -1 && length % 1 == 0);\r\n}\r\n\r\n/**\r\n * Returns true if the given object is a \"plain\" (e.g. { key: value }) object, false otherwise. \r\n * @param obj The Object.\r\n */\r\nexport function isPlainObject(obj: any): obj is PlainObject {\r\n if (!obj || !isObject(obj) || type(obj) !== 'object')\r\n return false;\r\n\r\n let key;\r\n const proto = 'prototype';\r\n const hasOwnProperty = Object[proto].hasOwnProperty;\r\n const hasOwnConstructor = hasOwnProperty.call(obj, 'constructor');\r\n const hasIsPrototypeOf = obj.constructor && obj.constructor[proto] && hasOwnProperty.call(obj.constructor[proto], 'isPrototypeOf');\r\n\r\n if (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) {\r\n return false;\r\n }\r\n\r\n for (key in obj) { /**/ }\r\n\r\n return isUndefined(key) || hasOwnProperty.call(obj, key);\r\n};\r\n\r\n/**\r\n * Checks whether the given object is a HTMLElement.\r\n * @param obj The object which shall be checked.\r\n */\r\nexport function isHTMLElement(obj: any): obj is HTMLElement {\r\n const instaceOfRightHandSide = window.HTMLElement;\r\n const doInstanceOf = isObject(instaceOfRightHandSide) || isFunction(instaceOfRightHandSide);\r\n return !!(\r\n doInstanceOf ? obj instanceof instaceOfRightHandSide : (obj && isObject(obj) && obj.nodeType === 1 && isString(obj.nodeName))\r\n );\r\n}\r\n\r\n/**\r\n * Returns true if the given object is empty, false otherwise.\r\n * @param obj The Object.\r\n */\r\nexport function isEmptyObject(obj: any): boolean {\r\n for (let name in obj)\r\n return false;\r\n return true;\r\n};","import { isArrayLike } from 'core/utils/types';\r\nimport { PlainObject } from 'core/typings';\r\n\r\n\r\n/**\r\n * Iterates through a array or object\r\n * @param arrayLikeOrObject The array or object through which shall be iterated.\r\n * @param callback The function which is responsible for the iteration. \r\n * If the function returns true its treated like a \"continue\" statement.\r\n * If the function returns false its treated like a \"break\" statement.\r\n */\r\nexport function each(array: Array | ReadonlyArray, callback: (value: T, indexOrKey: number, source: Array) => boolean | void): Array | ReadonlyArray;\r\nexport function each(array: Array | ReadonlyArray | null, callback: (value: T, indexOrKey: number, source: Array) => boolean | void): Array | ReadonlyArray | null;\r\nexport function each(arrayLikeObject: ArrayLike, callback: (value: T, indexOrKey: number, source: ArrayLike) => boolean | void): ArrayLike;\r\nexport function each(arrayLikeObject: ArrayLike | null, callback: (value: T, indexOrKey: number, source: ArrayLike) => boolean | void): ArrayLike | null;\r\nexport function each(obj: PlainObject, callback: (value: any, indexOrKey: string, source: PlainObject) => boolean | void): PlainObject;\r\nexport function each(obj: PlainObject | null, callback: (value: any, indexOrKey: string, source: PlainObject) => boolean | void): PlainObject | null;\r\nexport function each(source: ArrayLike | PlainObject | null, callback: (value: T | any, indexOrKey: any, source: any) => boolean | void): Array | ReadonlyArray | ArrayLike | PlainObject | null {\r\n let i: number | string = 0;\r\n\r\n if (isArrayLike(source)) {\r\n for (; i < source.length; i++) {\r\n if (callback(source[i], i, source) === false)\r\n break;\r\n }\r\n }\r\n else if (source) {\r\n for (i in source) {\r\n if (callback(source[i], i, source) === false)\r\n break;\r\n }\r\n }\r\n return source;\r\n};\r\n\r\n/**\r\n * Returns the index of the given inside the given array or -1 if the given item isn't part of the given array.\r\n * @param arr The array.\r\n * @param item The item.\r\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\r\n */\r\nexport const indexOf: (arr: Array, item: T, fromIndex?: number) => number = (arr, item, fromIndex) => {\r\n return arr.indexOf(item, fromIndex);\r\n}","import { each } from 'core/utils/arrays';\r\n\r\nconst elementIsVisible: (elm: HTMLElement) => boolean = (elm) => {\r\n return !!(elm.offsetWidth || elm.offsetHeight || elm.getClientRects().length);\r\n}\r\n\r\nexport const find: (selector: string, elm?: Element | null) => ReadonlyArray = (selector, elm?) => {\r\n const arr: Array = [];\r\n\r\n each((elm || document).querySelectorAll(selector), (e: Element) => {\r\n arr.push(e);\r\n });\r\n\r\n return arr;\r\n}\r\n\r\nexport const findFirst: (selector: string, elm?: Element | null) => Element | null = (selector, elm?) => {\r\n return (elm || document).querySelector(selector);\r\n}\r\n\r\nexport const is: (elm: Element | null, selector: string) => boolean = (elm, selector) => {\r\n if (elm) {\r\n if (selector === ':visible')\r\n return elementIsVisible(elm as HTMLElement);\r\n if (selector === ':hidden')\r\n return !elementIsVisible(elm as HTMLElement);\r\n if (elm.matches(selector))\r\n return true;\r\n }\r\n return false;\r\n}\r\n\r\nexport const children: (elm: Element | null, selector?: string) => ReadonlyArray = (elm, selector?) => {\r\n const children: Array = [];\r\n\r\n each(elm && elm.children, (child: Element) => {\r\n if (selector) {\r\n if (child.matches(selector))\r\n children.push(child);\r\n }\r\n else\r\n children.push(child);\r\n });\r\n\r\n return children;\r\n}\r\n\r\nexport const contents: (elm: Element | null) => ReadonlyArray = (elm) => {\r\n return elm ? Array.from(elm.childNodes) : [];\r\n}\r\n\r\nexport const parent: (elm: Node | null) => Node | null = (elm) => elm ? elm.parentElement : null;","import { isArrayLike, isHTMLElement } from 'core/utils/types';\r\nimport { each } from 'core/utils/arrays';\r\nimport { parent } from 'core/dom/traversal';\r\n\r\ntype NodeCollection = ArrayLike | Node | undefined | null;\r\n\r\n/**\r\n * Inserts Nodes before the given preferredAnchor element.\r\n * @param parent The parent of the preferredAnchor element or the element which shall be the parent of the inserted Nodes.\r\n * @param preferredAnchor The element before which the Nodes shall be inserted or null if the elements shall be appended at the end.\r\n * @param insertedElms The Nodes which shall be inserted.\r\n */\r\nconst before: (parent: Node | null, preferredAnchor: Node | null, insertedElms: NodeCollection) => void = (parent, preferredAnchor, insertedElms) => {\r\n if (insertedElms) {\r\n let anchor: Node | null = preferredAnchor;\r\n let fragment: DocumentFragment | Node | undefined | null;\r\n\r\n // parent must be defined\r\n if (parent) {\r\n if (isArrayLike(insertedElms)) {\r\n fragment = document.createDocumentFragment();\r\n\r\n // append all insertedElms to the fragment and if one of these is the anchor, change the anchor\r\n each(insertedElms, (insertedElm) => {\r\n if (insertedElm === anchor) {\r\n anchor = insertedElm.previousSibling;\r\n }\r\n fragment!.appendChild(insertedElm);\r\n });\r\n }\r\n else {\r\n fragment = insertedElms;\r\n }\r\n\r\n // if the preferred anchor isn't null set it to a valid anchor\r\n if (preferredAnchor) {\r\n if (!anchor) {\r\n anchor = parent.firstChild;\r\n }\r\n else if (anchor !== preferredAnchor) {\r\n anchor = anchor.nextSibling;\r\n }\r\n }\r\n\r\n parent.insertBefore(fragment, anchor);\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * Appends the given children at the end of the given Node.\r\n * @param node The Node to which the children shall be appended.\r\n * @param children The Nodes which shall be appended.\r\n */\r\nexport const appendChildren: (node: Node | null, children: NodeCollection) => void = (node, children) => { before(node, null, children) };\r\n\r\n/**\r\n * Prepends the given children at the start of the given Node.\r\n * @param node The Node to which the children shall be prepended.\r\n * @param children The Nodes which shall be prepended.\r\n */\r\nexport const prependChildren: (node: Node | null, children: NodeCollection) => void = (node, children) => { before(node, node && node.firstChild, children) };\r\n\r\n/**\r\n * Inserts the given Nodes before the given Node.\r\n * @param node The Node before which the given Nodes shall be inserted.\r\n * @param insertedNodes The Nodes which shall be inserted.\r\n */\r\nexport const insertBefore: (node: Node | null, insertedNodes: NodeCollection) => void = (node, insertedNodes) => { before(parent(node), node, insertedNodes) };\r\n\r\n/**\r\n * Inserts the given Nodes after the given Node.\r\n * @param node The Node after which the given Nodes shall be inserted.\r\n * @param insertedNodes The Nodes which shall be inserted.\r\n */\r\nexport const insertAfter: (node: Node | null, insertedNodes: NodeCollection) => void = (node, insertedNodes) => { before(parent(node), node && node.nextSibling, insertedNodes) };\r\n\r\n/**\r\n * Removes the given Nodes from their parent.\r\n * @param nodes The Nodes which shall be removed.\r\n */\r\nexport const removeElements: (nodes: NodeCollection) => void = (nodes) => {\r\n if (isArrayLike(nodes)) {\r\n each(Array.from(nodes), (e) => removeElements(e));\r\n }\r\n else if (nodes) {\r\n const parentNode = nodes.parentNode;\r\n if (parentNode)\r\n parentNode.removeChild(nodes);\r\n }\r\n}","import { each } from 'core/utils/arrays';\r\nimport { contents } from 'core/dom/traversal';\r\nimport { removeElements } from 'core/dom/manipulation';\r\n\r\nexport const createDiv: () => HTMLDivElement = () => {\r\n return document.createElement('div');\r\n}\r\n\r\nexport const createDOM: (html: string) => ReadonlyArray = (html) => {\r\n const elm = createDiv();\r\n elm.innerHTML = html.trim();\r\n\r\n return each(contents(elm), (elm) => removeElements(elm));\r\n}","\r\nimport { createDOM } from 'core/dom';\r\nimport j from 'jquery';\r\n/*\r\nexport * from 'core/compatibility';\r\nexport * from 'core/utils';\r\nexport * from 'core/dom';\r\nexport * from 'core/options';\r\nexport * from 'instances';\r\n*/\r\n\r\nconst abc = {\r\n a: 1,\r\n b: 1,\r\n c: 1,\r\n}\r\n\r\nexport default () => {\r\n const { a, b, c } = abc;\r\n return [createDOM(`\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n fdfhdfgh\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
`), j('div'), a, b, c];\r\n};"],"names":["isNumber","obj","isFunction","isArray","Array","isArrayLike","length","each","source","callback","i","contents","elm","from","childNodes","removeElements","nodes","e","parentNode","removeChild","createDiv","document","createElement","createDOM","html","innerHTML","trim","abc","a","b","c","j"],"mappings":";;SAUgBA,SAASC;AACrB,SAAO,OAAOA,GAAP,KAAe,QAAtB;AACH;;SAceC,WAAWD;AACvB,SAAO,OAAOA,GAAP,KAAe,UAAtB;AACH;;SAUeE,QAAQF;AACpB,SAAOG,KAAK,CAACD,OAAN,CAAcF,GAAd,CAAP;AACH;;SAOeI,YAAyCJ;AACrD,QAAMK,MAAM,GAAG,CAAC,CAACL,GAAF,IAASA,GAAG,CAACK,MAA5B;AACA,SAAOH,OAAO,CAACF,GAAD,CAAP,IAAiB,CAACC,UAAU,CAACD,GAAD,CAAX,IAAoBD,QAAQ,CAACM,MAAD,CAA5B,IAAwCA,MAAM,GAAG,CAAC,CAAlD,IAAuDA,MAAM,GAAG,CAAT,IAAc,CAA7F;;;SChCYC,KAAQC,QAA2CC;AAC/D,MAAIC,CAAC,GAAoB,CAAzB;;AAEA,MAAIL,WAAW,CAACG,MAAD,CAAf,EAAyB;AACrB,WAAOE,CAAC,GAAGF,MAAM,CAACF,MAAlB,EAA0BI,CAAC,EAA3B,EAA+B;AAC3B,UAAID,QAAQ,CAACD,MAAM,CAACE,CAAD,CAAP,EAAYA,CAAZ,EAAeF,MAAf,CAAR,KAAmC,KAAvC,EACI;AACP;AACJ,GALD,MAMK,IAAIA,MAAJ,EAAY;AACb,SAAKE,CAAL,IAAUF,MAAV,EAAkB;AACd,UAAIC,QAAQ,CAACD,MAAM,CAACE,CAAD,CAAP,EAAYA,CAAZ,EAAeF,MAAf,CAAR,KAAmC,KAAvC,EACI;AACP;AACJ;;AACD,SAAOA,MAAP;;;ACeG,MAAMG,QAAQ,GAAuDC,GAAD;AACvE,SAAOA,GAAG,GAAGR,KAAK,CAACS,IAAN,CAAsBD,GAAG,CAACE,UAA1B,CAAH,GAA2C,EAArD;AACH,CAFM;;ACkCA,MAAMC,cAAc,GAAqCC,KAAD;AAC3D,MAAIX,WAAW,CAACW,KAAD,CAAf,EAAwB;AACpBT,IAAAA,IAAI,CAACH,KAAK,CAACS,IAAN,CAAWG,KAAX,CAAD,EAAqBC,CAAD,IAAOF,cAAc,CAACE,CAAD,CAAzC,CAAJ;AACH,GAFD,MAGK,IAAID,KAAJ,EAAW;AACZ,UAAME,UAAU,GAAGF,KAAK,CAACE,UAAzB;AACA,QAAIA,UAAJ,EACIA,UAAU,CAACC,WAAX,CAAuBH,KAAvB;AACP;AACJ,CATM;;AC7EA,MAAMI,SAAS,GAAyB;AAC3C,SAAOC,QAAQ,CAACC,aAAT,CAAuB,KAAvB,CAAP;AACH,CAFM;;AAIA,MAAMC,SAAS,GAA2CC,IAAD;AAC5D,QAAMZ,GAAG,GAAGQ,SAAS,EAArB;AACAR,EAAAA,GAAG,CAACa,SAAJ,GAAgBD,IAAI,CAACE,IAAL,EAAhB;AAEA,SAAOnB,IAAI,CAACI,QAAQ,CAACC,GAAD,CAAT,EAAiBA,GAAD,IAASG,cAAc,CAACH,GAAD,CAAvC,CAAX;AACH,CALM;;ACGP,MAAMe,GAAG,GAAG;AACRC,EAAAA,CAAC,EAAE,CADK;AAERC,EAAAA,CAAC,EAAE,CAFK;AAGRC,EAAAA,CAAC,EAAE;AAHK,CAAZ;;AAMA,YAAe;AACX,QAAM;AAAEF,IAAAA,CAAF;AAAKC,IAAAA,CAAL;AAAQC,IAAAA;AAAR,MAAcH,GAApB;AACA,SAAO,CAACJ,SAAS,wtBAAV,EAqBGQ,CAAC,CAAC,KAAD,CArBJ,EAqBaH,CArBb,EAqBgBC,CArBhB,EAqBmBC,CArBnB,CAAP;AAsBH,CAxBD;;"} \ No newline at end of file diff --git a/packages/overlayscrollbars/dist/overlayscrollbars.js b/packages/overlayscrollbars/dist/overlayscrollbars.js index ff1c2e6..14db1e4 100644 --- a/packages/overlayscrollbars/dist/overlayscrollbars.js +++ b/packages/overlayscrollbars/dist/overlayscrollbars.js @@ -1,77 +1,100 @@ -!function(r, n) { - "object" == typeof exports && "object" == typeof module ? module.exports = n() : "function" == typeof define && define.amd ? define([], n) : "object" == typeof exports ? exports.OverlayScrollbars = n() : r.OverlayScrollbars = n(); -}(window, (function() { - return function() { - "use strict"; - var r = { - 95: function(r, n, o) { - o.d(n, { - default: function() { - return p; - } - }); - function e(r) { - return "function" == typeof r; - } - function t(r) { - return Array.isArray(r); - } - function i(r) { - var n = !!r && r.length; - return t(r) || !e(r) && function(r) { - return "number" == typeof r; - }(n) && n > -1 && n % 1 == 0; - } - function s(r, n) { - var o = 0; - if (i(r)) for (;o < r.length && !1 !== n(r[o], o, r); o++) ; else if (r) for (o in r) if (!1 === n(r[o], o, r)) break; - return r; - } - var c = function(r) { - if (i(r)) s(Array.from(r), (function(r) { - return c(r); - })); else if (r) { - var n = r.parentNode; - n && n.removeChild(r); - } - }, u = function(r) { - var n = document.createElement("div"); - return n.innerHTML = r.trim(), s(function(r) { - return r ? Array.from(r.childNodes) : []; - }(n), (function(r) { - return c(r); - })); - }; - var a, f, l = function(r) { - return r.charAt(0).toUpperCase() + r.slice(1); - }, d = [ "WebKit", "Moz", "O", "MS", "webkit", "moz", "o", "ms" ], v = {}, b = (f = v[a = "ResizeObserver"] || window[a], - v.hasOwnProperty(a) || (s(d, (function(r) { - return !(f = f || window[r + l(a)]); - })), v[a] = f), JSON.stringify, [ "__TPL_", "_TYPE__" ]); - [ "boolean", "number", "string", "array", "object", "function", "null" ].reduce((function(r, n) { - return r[n] = b[0] + n + b[1], r; - }), {}); - new Set, new WeakMap; - var p = function() { - return u('
fdfhdfgh
'); - }; - } - }, n = {}; - function o(e) { - if (n[e]) return n[e].exports; - var t = n[e] = { - exports: {} - }; - return r[e](t, t.exports, o), t.exports; - } - return o.d = function(r, n) { - for (var e in n) o.o(n, e) && !o.o(r, e) && Object.defineProperty(r, e, { - enumerable: !0, - get: n[e] - }); - }, o.o = function(r, n) { - return Object.prototype.hasOwnProperty.call(r, n); - }, o(95); - }().default; -})); -//# sourceMappingURL=overlayscrollbars.js.map \ No newline at end of file +(function (global, factory) { + if (typeof define === "function" && define.amd) { + define("OverlayScrollbars", ["exports", "jquery"], factory); + } else if (typeof exports !== "undefined") { + factory(exports, require("jquery")); + } else { + var mod = { + exports: {} + }; + factory(mod.exports, global.jQuery); + global.OverlayScrollbars = mod.exports; + } +})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports, _jquery) { + "use strict"; + + Object.defineProperty(_exports, "__esModule", { + value: true + }); + _exports.default = void 0; + _jquery = _interopRequireDefault(_jquery); + + function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } + + function isNumber(obj) { + return typeof obj === 'number'; + } + + function isFunction(obj) { + return typeof obj === 'function'; + } + + function isArray(obj) { + return Array.isArray(obj); + } + + function isArrayLike(obj) { + var length = !!obj && obj.length; + return isArray(obj) || !isFunction(obj) && isNumber(length) && length > -1 && length % 1 == 0; + } + + function each(source, callback) { + var i = 0; + + if (isArrayLike(source)) { + for (; i < source.length; i++) { + if (callback(source[i], i, source) === false) break; + } + } else if (source) { + for (i in source) { + if (callback(source[i], i, source) === false) break; + } + } + + return source; + } + + var contents = function contents(elm) { + return elm ? Array.from(elm.childNodes) : []; + }; + + var removeElements = function removeElements(nodes) { + if (isArrayLike(nodes)) { + each(Array.from(nodes), function (e) { + return removeElements(e); + }); + } else if (nodes) { + var parentNode = nodes.parentNode; + if (parentNode) parentNode.removeChild(nodes); + } + }; + + var createDiv = function createDiv() { + return document.createElement('div'); + }; + + var createDOM = function createDOM(html) { + var elm = createDiv(); + elm.innerHTML = html.trim(); + return each(contents(elm), function (elm) { + return removeElements(elm); + }); + }; + + var abc = { + a: 1, + b: 1, + c: 1 + }; + + var index = function index() { + var a = abc.a, + b = abc.b, + c = abc.c; + return [createDOM("
fdfhdfgh
"), (0, _jquery.default)('div'), a, b, c]; + }; + + var _default = index; + _exports.default = _default; +}); +//# sourceMappingURL=overlayscrollbars.js.map diff --git a/packages/overlayscrollbars/dist/overlayscrollbars.js.map b/packages/overlayscrollbars/dist/overlayscrollbars.js.map index 92158ff..96f9335 100644 --- a/packages/overlayscrollbars/dist/overlayscrollbars.js.map +++ b/packages/overlayscrollbars/dist/overlayscrollbars.js.map @@ -1 +1 @@ -{"version":3,"sources":["webpack://OverlayScrollbars/webpack/universalModuleDefinition","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/utils/types.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/utils/arrays.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/dom/manipulation.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/dom/create.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/dom/traversal.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/compatibility/vendors.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/options/validation.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/core/compatibility/apis.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/instances.ts","webpack://OverlayScrollbars/./packages/overlayscrollbars/src/index.ts","webpack://OverlayScrollbars/webpack/bootstrap","webpack://OverlayScrollbars/webpack/startup","webpack://OverlayScrollbars/webpack/runtime/define property getters","webpack://OverlayScrollbars/webpack/runtime/hasOwnProperty shorthand"],"names":["root","factory","exports","module","define","amd","window","isFunction","obj","isArray","Array","isArrayLike","length","isNumber","each","source","callback","i","removeElements","nodes","from","e","parentNode","removeChild","createDOM","html","elm","document","createElement","innerHTML","trim","childNodes","contents","name","result","firstLetterToUpper","str","charAt","toUpperCase","slice","jsPrefixes","jsCache","templateTypePrefixSuffix","hasOwnProperty","prefix","JSON","stringify","reduce","item","Set","WeakMap","__webpack_module_cache__","__webpack_require__","moduleId","__webpack_modules__","d","definition","key","o","Object","defineProperty","enumerable","get","prop","prototype","call"],"mappings":"CAAA,SAA2CA,GAAMC;IAC1B,mBAAZC,WAA0C,mBAAXC,SACxCA,OAAOD,UAAUD,MACQ,qBAAXG,UAAyBA,OAAOC,MAC9CD,OAAO,IAAIH,KACe,mBAAZC,UACdA,QAA2B,oBAAID,MAE/BD,EAAwB,oBAAIC;CAR9B,CASGK,SAAQ;IACX,O;;;;;;;;;gBCgBO,SAASC,EAAWC;oBACvB,OAAsB,qBAARA;;gBAWX,SAASC,EAAQD;oBACpB,OAAOE,MAAMD,QAAQD;;gBAQlB,SAASG,EAAyCH;oBACrD,IAAMI,MAAWJ,KAAOA,EAAII;oBAC5B,OAAOH,EAAQD,OAAUD,EAAWC,MAvCjC,SAAkBA;wBACrB,OAAsB,mBAARA;qBAsC8BK,CAASD,MAAWA,KAAU,KAAKA,IAAS,KAAK;;gBChC1F,SAASE,EAAQC,GAA2CC;oBAC/D,IAAIC,IAAqB;oBAEzB,IAAIN,EAAYI,IACZ,MAAOE,IAAIF,EAAOH,WACyB,MAAnCI,EAASD,EAAOE,IAAIA,GAAGF,IADLE,YAKzB,IAAIF,GACL,KAAKE,KAAKF,GACN,KAAuC,MAAnCC,EAASD,EAAOE,IAAIA,GAAGF,IACvB;oBAGZ,OAAOA;;gBASJ,ICwCMG,IAAkD,SAACC;oBAC5D,IAAIR,EAAYQ,IACZL,EAAKJ,MAAMU,KAAKD,KAAQ,SAACE;wBAAM,OAAAH,EAAeG;8BAE7C,IAAIF,GAAO;wBACZ,IAAMG,IAAaH,EAAMG;wBACrBA,KACAA,EAAWC,YAAYJ;;mBChFtBK,IAAmD,SAACC;oBAC7D,IAAMC,IAJCC,SAASC,cAAc;oBAO9B,OAFAF,EAAIG,YAAYJ,EAAKK,QAEdhB,ECmCgE,SAACY;wBACxE,OAAOA,IAAMhB,MAAMU,KAAgBM,EAAIK,cAAc;qBDpCzCC,CAASN,KAAM,SAACA;wBAAQ,OAAAR,EAAeQ;;;gBETvD,IAkF6CO,GACrCC,GAnFFC,IAA8C,SAACC;oBACjD,OAAOA,EAAIC,OAAO,GAAGC,gBAAgBF,EAAIG,MAAM;mBAStCC,IAAoC,EAAC,UAAU,OAAO,KAAK,MAAM,UAAU,OAAO,KAAK,QAEvFC,IAAkC,ICNzCC,KD6EER,IAAcO,EADuBR,IEnFQ,qBFoFd3B,OAAO2B;gBAEtCQ,EAAQE,eAAeV,OAG3BnB,EAAK0B,IAAY,SAACI;oBAEd,SADAV,IAASA,KAAU5B,OAAOsC,IAAST,EAAmBF;qBAI1DQ,EAAQR,KAAQC,IC5FFW,KAAKC,WAKqC,EAAC,UAAU;gBAMV,EACzD,WACA,UACA,UACA,SACA,UACA,YACA,SACFC,QAAO,SAACb,GAAQc;oBAEd,OADAd,EAAOc,KAAQN,EAAyB,KAAKM,IAAON,EAAyB,IACtER;oBACR;gBE1B2B,IAAIe,KACe,IAAIC;gBADrD,ICWA;oBAAqB,OAAA1B,EAAU;;;WCV3B2B,IAA2B;QAG/B,SAASC,EAAoBC;YAE5B,IAAGF,EAAyBE,IAC3B,OAAOF,EAAyBE,GAAUnD;YAG3C,IAAIC,IAASgD,EAAyBE,KAAY;gBAGjDnD,SAAS;;YAOV,OAHAoD,EAAoBD,GAAUlD,GAAQA,EAAOD,SAASkD,IAG/CjD,EAAOD;;QCjBf,OCFAkD,EAAoBG,IAAI,SAASrD,GAASsD;YACzC,KAAI,IAAIC,KAAOD,GACXJ,EAAoBM,EAAEF,GAAYC,OAASL,EAAoBM,EAAExD,GAASuD,MAC5EE,OAAOC,eAAe1D,GAASuD,GAAK;gBAAEI,aAAY;gBAAMC,KAAKN,EAAWC;;WCJ3EL,EAAoBM,IAAI,SAASlD,GAAKuD;YAAQ,OAAOJ,OAAOK,UAAUrB,eAAesB,KAAKzD,GAAKuD;WFGxFX,EAAoB","file":"overlayscrollbars.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"OverlayScrollbars\"] = factory();\n\telse\n\t\troot[\"OverlayScrollbars\"] = factory();\n})(window, function() {\nreturn ","import { PlainObject } from 'core/typings';\r\n\r\nexport const type: (obj: any) => string = (obj) => {\r\n if (obj === undefined)\r\n return obj + '';\r\n if (obj === null)\r\n return obj + '';\r\n return Object.prototype.toString.call(obj).replace(/^\\[object (.+)\\]$/, '$1').toLowerCase();\r\n}\r\n\r\nexport function isNumber(obj: any): obj is number {\r\n return typeof obj === 'number';\r\n};\r\n\r\nexport function isString(obj: any): obj is string {\r\n return typeof obj === 'string';\r\n}\r\n\r\nexport function isBoolean(obj: any): obj is boolean {\r\n return typeof obj === 'boolean';\r\n}\r\n\r\nexport function isObject(obj: any): boolean {\r\n return typeof obj === 'object' && !isArray(obj) && !isNull(obj);\r\n}\r\n\r\nexport function isFunction(obj: any): obj is Function {\r\n return typeof obj === 'function';\r\n}\r\n\r\nexport function isUndefined(obj: any): obj is undefined {\r\n return obj === undefined;\r\n}\r\n\r\nexport function isNull(obj: any): obj is null {\r\n return obj === null;\r\n}\r\n\r\nexport function isArray(obj: any): obj is Array {\r\n return Array.isArray(obj);\r\n}\r\n\r\n\r\n/**\r\n * Returns true if the given object is array like, false otherwise.\r\n * @param obj The Object\r\n */\r\nexport function isArrayLike(obj: any): obj is ArrayLike {\r\n const length = !!obj && obj.length;\r\n return isArray(obj) || (!isFunction(obj) && isNumber(length) && length > -1 && length % 1 == 0);\r\n}\r\n\r\n/**\r\n * Returns true if the given object is a \"plain\" (e.g. { key: value }) object, false otherwise. \r\n * @param obj The Object.\r\n */\r\nexport function isPlainObject(obj: any): obj is PlainObject {\r\n if (!obj || !isObject(obj) || type(obj) !== 'object')\r\n return false;\r\n\r\n let key;\r\n const proto = 'prototype';\r\n const hasOwnProperty = Object[proto].hasOwnProperty;\r\n const hasOwnConstructor = hasOwnProperty.call(obj, 'constructor');\r\n const hasIsPrototypeOf = obj.constructor && obj.constructor[proto] && hasOwnProperty.call(obj.constructor[proto], 'isPrototypeOf');\r\n\r\n if (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) {\r\n return false;\r\n }\r\n\r\n for (key in obj) { /**/ }\r\n\r\n return isUndefined(key) || hasOwnProperty.call(obj, key);\r\n};\r\n\r\n/**\r\n * Checks whether the given object is a HTMLElement.\r\n * @param obj The object which shall be checked.\r\n */\r\nexport function isHTMLElement(obj: any): obj is HTMLElement {\r\n const instaceOfRightHandSide = window.HTMLElement;\r\n const doInstanceOf = isObject(instaceOfRightHandSide) || isFunction(instaceOfRightHandSide);\r\n return !!(\r\n doInstanceOf ? obj instanceof instaceOfRightHandSide : (obj && isObject(obj) && obj.nodeType === 1 && isString(obj.nodeName))\r\n );\r\n}\r\n\r\n/**\r\n * Returns true if the given object is empty, false otherwise.\r\n * @param obj The Object.\r\n */\r\nexport function isEmptyObject(obj: any): boolean {\r\n for (let name in obj)\r\n return false;\r\n return true;\r\n};","import { isArrayLike } from 'core/utils/types';\r\nimport { PlainObject } from 'core/typings';\r\n\r\n\r\n/**\r\n * Iterates through a array or object\r\n * @param arrayLikeOrObject The array or object through which shall be iterated.\r\n * @param callback The function which is responsible for the iteration. \r\n * If the function returns true its treated like a \"continue\" statement.\r\n * If the function returns false its treated like a \"break\" statement.\r\n */\r\nexport function each(array: Array | ReadonlyArray, callback: (value: T, indexOrKey: number, source: Array) => boolean | void): Array | ReadonlyArray;\r\nexport function each(array: Array | ReadonlyArray | null, callback: (value: T, indexOrKey: number, source: Array) => boolean | void): Array | ReadonlyArray | null;\r\nexport function each(arrayLikeObject: ArrayLike, callback: (value: T, indexOrKey: number, source: ArrayLike) => boolean | void): ArrayLike;\r\nexport function each(arrayLikeObject: ArrayLike | null, callback: (value: T, indexOrKey: number, source: ArrayLike) => boolean | void): ArrayLike | null;\r\nexport function each(obj: PlainObject, callback: (value: any, indexOrKey: string, source: PlainObject) => boolean | void): PlainObject;\r\nexport function each(obj: PlainObject | null, callback: (value: any, indexOrKey: string, source: PlainObject) => boolean | void): PlainObject | null;\r\nexport function each(source: ArrayLike | PlainObject | null, callback: (value: T | any, indexOrKey: any, source: any) => boolean | void): Array | ReadonlyArray | ArrayLike | PlainObject | null {\r\n let i: number | string = 0;\r\n\r\n if (isArrayLike(source)) {\r\n for (; i < source.length; i++) {\r\n if (callback(source[i], i, source) === false)\r\n break;\r\n }\r\n }\r\n else if (source) {\r\n for (i in source) {\r\n if (callback(source[i], i, source) === false)\r\n break;\r\n }\r\n }\r\n return source;\r\n};\r\n\r\n/**\r\n * Returns the index of the given inside the given array or -1 if the given item isn't part of the given array.\r\n * @param arr The array.\r\n * @param item The item.\r\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\r\n */\r\nexport const indexOf: (arr: Array, item: T, fromIndex?: number) => number = (arr, item, fromIndex) => {\r\n return arr.indexOf(item, fromIndex);\r\n}","import { isArrayLike, isHTMLElement } from 'core/utils/types';\r\nimport { each } from 'core/utils/arrays';\r\nimport { parent } from 'core/dom/traversal';\r\n\r\ntype NodeCollection = ArrayLike | Node | undefined | null;\r\n\r\n/**\r\n * Inserts Nodes before the given preferredAnchor element.\r\n * @param parent The parent of the preferredAnchor element or the element which shall be the parent of the inserted Nodes.\r\n * @param preferredAnchor The element before which the Nodes shall be inserted or null if the elements shall be appended at the end.\r\n * @param insertedElms The Nodes which shall be inserted.\r\n */\r\nconst before: (parent: Node | null, preferredAnchor: Node | null, insertedElms: NodeCollection) => void = (parent, preferredAnchor, insertedElms) => {\r\n if (insertedElms) {\r\n let anchor: Node | null = preferredAnchor;\r\n let fragment: DocumentFragment | Node | undefined | null;\r\n\r\n // parent must be defined\r\n if (parent) {\r\n if (isArrayLike(insertedElms)) {\r\n fragment = document.createDocumentFragment();\r\n\r\n // append all insertedElms to the fragment and if one of these is the anchor, change the anchor\r\n each(insertedElms, (insertedElm) => {\r\n if (insertedElm === anchor) {\r\n anchor = insertedElm.previousSibling;\r\n }\r\n fragment!.appendChild(insertedElm);\r\n });\r\n }\r\n else {\r\n fragment = insertedElms;\r\n }\r\n\r\n // if the preferred anchor isn't null set it to a valid anchor\r\n if (preferredAnchor) {\r\n if (!anchor) {\r\n anchor = parent.firstChild;\r\n }\r\n else if (anchor !== preferredAnchor) {\r\n anchor = anchor.nextSibling;\r\n }\r\n }\r\n\r\n parent.insertBefore(fragment, anchor);\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * Appends the given children at the end of the given Node.\r\n * @param node The Node to which the children shall be appended.\r\n * @param children The Nodes which shall be appended.\r\n */\r\nexport const appendChildren: (node: Node | null, children: NodeCollection) => void = (node, children) => { before(node, null, children) };\r\n\r\n/**\r\n * Prepends the given children at the start of the given Node.\r\n * @param node The Node to which the children shall be prepended.\r\n * @param children The Nodes which shall be prepended.\r\n */\r\nexport const prependChildren: (node: Node | null, children: NodeCollection) => void = (node, children) => { before(node, node && node.firstChild, children) };\r\n\r\n/**\r\n * Inserts the given Nodes before the given Node.\r\n * @param node The Node before which the given Nodes shall be inserted.\r\n * @param insertedNodes The Nodes which shall be inserted.\r\n */\r\nexport const insertBefore: (node: Node | null, insertedNodes: NodeCollection) => void = (node, insertedNodes) => { before(parent(node), node, insertedNodes) };\r\n\r\n/**\r\n * Inserts the given Nodes after the given Node.\r\n * @param node The Node after which the given Nodes shall be inserted.\r\n * @param insertedNodes The Nodes which shall be inserted.\r\n */\r\nexport const insertAfter: (node: Node | null, insertedNodes: NodeCollection) => void = (node, insertedNodes) => { before(parent(node), node && node.nextSibling, insertedNodes) };\r\n\r\n/**\r\n * Removes the given Nodes from their parent.\r\n * @param nodes The Nodes which shall be removed.\r\n */\r\nexport const removeElements: (nodes: NodeCollection) => void = (nodes) => {\r\n if (isArrayLike(nodes)) {\r\n each(Array.from(nodes), (e) => removeElements(e));\r\n }\r\n else if (nodes) {\r\n const parentNode = nodes.parentNode;\r\n if (parentNode)\r\n parentNode.removeChild(nodes);\r\n }\r\n}","import { each } from 'core/utils/arrays';\r\nimport { contents } from 'core/dom/traversal';\r\nimport { removeElements } from 'core/dom/manipulation';\r\n\r\nexport const createDiv: () => HTMLDivElement = () => {\r\n return document.createElement('div');\r\n}\r\n\r\nexport const createDOM: (html: string) => ReadonlyArray = (html) => {\r\n const elm = createDiv();\r\n elm.innerHTML = html.trim();\r\n\r\n return each(contents(elm), (elm) => removeElements(elm));\r\n}","import { each } from 'core/utils/arrays';\r\n\r\nconst elementIsVisible: (elm: HTMLElement) => boolean = (elm) => {\r\n return !!(elm.offsetWidth || elm.offsetHeight || elm.getClientRects().length);\r\n}\r\n\r\nexport const find: (selector: string, elm?: Element | null) => ReadonlyArray = (selector, elm?) => {\r\n const arr: Array = [];\r\n\r\n each((elm || document).querySelectorAll(selector), (e: Element) => {\r\n arr.push(e);\r\n });\r\n\r\n return arr;\r\n}\r\n\r\nexport const findFirst: (selector: string, elm?: Element | null) => Element | null = (selector, elm?) => {\r\n return (elm || document).querySelector(selector);\r\n}\r\n\r\nexport const is: (elm: Element | null, selector: string) => boolean = (elm, selector) => {\r\n if (elm) {\r\n if (selector === ':visible')\r\n return elementIsVisible(elm as HTMLElement);\r\n if (selector === ':hidden')\r\n return !elementIsVisible(elm as HTMLElement);\r\n if (elm.matches(selector))\r\n return true;\r\n }\r\n return false;\r\n}\r\n\r\nexport const children: (elm: Element | null, selector?: string) => ReadonlyArray = (elm, selector?) => {\r\n const children: Array = [];\r\n\r\n each(elm && elm.children, (child: Element) => {\r\n if (selector) {\r\n if (child.matches(selector))\r\n children.push(child);\r\n }\r\n else\r\n children.push(child);\r\n });\r\n\r\n return children;\r\n}\r\n\r\nexport const contents: (elm: Element | null) => ReadonlyArray = (elm) => {\r\n return elm ? Array.from(elm.childNodes) : [];\r\n}\r\n\r\nexport const parent: (elm: Node | null) => Node | null = (elm) => elm ? elm.parentElement : null;","import { each } from 'core/utils';\r\nimport { createDiv } from 'core/dom';\r\n\r\nconst firstLetterToUpper: (str: string) => string = (str) => {\r\n return str.charAt(0).toUpperCase() + str.slice(1);\r\n}\r\nconst getDummyStyle: () => CSSStyleDeclaration = () => {\r\n return createDiv().style;\r\n}\r\n\r\n//https://developer.mozilla.org/en-US/docs/Glossary/Vendor_Prefix\r\n\r\nexport const cssPrefixes: ReadonlyArray = ['-webkit-', '-moz-', '-o-', '-ms-'];\r\nexport const jsPrefixes: ReadonlyArray = ['WebKit', 'Moz', 'O', 'MS', 'webkit', 'moz', 'o', 'ms'];\r\n\r\nexport const jsCache: { [key: string]: any } = {};\r\nexport const cssCache: { [key: string]: string } = {};\r\n\r\n/**\r\n * Gets the name of the given CSS property with vendor prefix if it isn't supported without, or undefined if unsupported.\r\n * @param name The name of the CSS property which shall be get.\r\n */\r\nexport const cssProperty: (name: string) => string | undefined = (name) => {\r\n let result: string | undefined = cssCache[name];\r\n\r\n if (cssCache.hasOwnProperty(name))\r\n return result;\r\n\r\n const uppercasedName: string = firstLetterToUpper(name);\r\n const elmStyle: CSSStyleDeclaration = getDummyStyle();\r\n\r\n each(cssPrefixes, (prefix: string) => {\r\n const prefixWithoutDashes: string = prefix.replace(/-/g, '');\r\n const resultPossibilities: Array = [\r\n name, //transition\r\n prefix + name, //-webkit-transition\r\n prefixWithoutDashes + uppercasedName, //webkitTransition\r\n firstLetterToUpper(prefixWithoutDashes) + uppercasedName //WebkitTransition\r\n ];\r\n result = resultPossibilities.find((resultPossibility: string) => elmStyle[resultPossibility] !== undefined);\r\n return !result;\r\n });\r\n\r\n cssCache[name] = result;\r\n return result;\r\n}\r\n\r\n/**\r\n * Get the name of the given CSS property value(s), with vendor prefix if it isn't supported wuthout, or undefined if no value is supported. \r\n * @param property The CSS property to which the CSS property value(s) belong.\r\n * @param values The value(s) separated by spaces which shall be get.\r\n * @param suffix A suffix which is added to each value in case the value is a function or something else more advanced.\r\n */\r\nexport const cssPropertyValue: (property: string, values: string, suffix?: string) => string | undefined = (property, values, suffix) => {\r\n const name: string = property + ' ' + values;\r\n let result: string | undefined = cssCache[name];\r\n\r\n if (cssCache.hasOwnProperty(name))\r\n return result;\r\n\r\n const dummyStyle: CSSStyleDeclaration = getDummyStyle();\r\n const possbleValues: Array = values.split(' ');\r\n const preparedSuffix: string = suffix || '';\r\n const cssPrefixesWithFirstEmpty = [''].concat(cssPrefixes);\r\n\r\n each(possbleValues, (possibleValue: string) => {\r\n each(cssPrefixesWithFirstEmpty, (prefix: string) => {\r\n const prop = prefix + possibleValue;\r\n dummyStyle.cssText = property + ':' + prop + preparedSuffix;\r\n if (dummyStyle.length) {\r\n result = prop;\r\n return false;\r\n }\r\n });\r\n return !result;\r\n });\r\n\r\n cssCache[name] = result;\r\n return result;\r\n}\r\n\r\n/**\r\n * Get the requested JS function, object or constructor with vendor prefix if it isn't supported without or undefined if unsupported.\r\n * @param name The name of the JS function, object or constructor.\r\n */\r\nexport const jsAPI: (name: string) => any = (name) => {\r\n let result: any = jsCache[name] || window[name];\r\n\r\n if (jsCache.hasOwnProperty(name))\r\n return result;\r\n\r\n each(jsPrefixes, (prefix: string) => {\r\n result = result || window[prefix + firstLetterToUpper(name)];\r\n return !result;\r\n });\r\n\r\n jsCache[name] = result;\r\n return result;\r\n}\r\n","import { each, indexOf } from 'core/utils/arrays';\r\nimport { type, isArray, isUndefined, isEmptyObject, isPlainObject, isString } from 'core/utils/types';\r\nimport { PlainObject, OptionsTemplate, OptionsTemplateTypes, OptionsTemplateType, OptionsValidated, Func, OptionsValidatedResult } from 'core/typings';\r\n\r\nconst stringify = JSON.stringify;\r\n\r\n/**\r\n * A prefix and suffix tuple which serves as recognition pattern for template types.\r\n */\r\nconst templateTypePrefixSuffix: readonly [string, string] = ['__TPL_', '_TYPE__'];\r\n/**\r\n * A object which serves as a mapping for \"normal\" types and template types.\r\n * Key = normal type string\r\n * value = template type string\r\n */\r\nconst optionsTemplateTypes: OptionsTemplateTypesDictionary = [\r\n 'boolean',\r\n 'number',\r\n 'string',\r\n 'array',\r\n 'object',\r\n 'function',\r\n 'null'\r\n].reduce((result, item) => {\r\n result[item] = templateTypePrefixSuffix[0] + item + templateTypePrefixSuffix[1];\r\n return result;\r\n}, {} as OptionsTemplateTypesDictionary);\r\n\r\n/**\r\n * Validates the given options object according to the given template object and returns a object which looks like:\r\n * {\r\n * foreign : a object which consists of properties which aren't defined inside the template. (foreign properties)\r\n * validated : a object which consists only of valid properties. (property name is inside the template and value has a correct type)\r\n * }\r\n * @param options The options object which shall be validated.\r\n * @param template The template according to which the options object shall be validated.\r\n * @param optionsDiff When provided the returned validated object will only have properties which are different to this objects properties.\r\n * Example (assume all properties are valid to the template): \r\n * Options object : { a: 'a', b: 'b', c: 'c' }\r\n * optionsDiff object : { a: 'a', b: 'b', c: undefined }\r\n * Returned validated object : { c: 'c' }\r\n * Because the value of the properties a and b didn't change, they aren't included in the returned object.\r\n * Without the optionsDiff object the returned validated object would be: { a: 'a', b: 'b', c: 'c' }\r\n * @param doWriteErrors True if errors shall be logged into the console, false otherwise.\r\n * @param propPath The propertyPath which lead to this object. (used for error logging)\r\n */\r\nconst validateRecursive = function (options: T, template: OptionsTemplate>, optionsDiff: OptionsValidated, doWriteErrors?: boolean, propPath?: string): OptionsValidatedResult {\r\n const validatedOptions: OptionsValidated = {};\r\n const optionsCopy: T = Object.assign({}, options);\r\n const props = Object.keys(template).filter(prop => options.hasOwnProperty(prop));\r\n\r\n each(props, (prop: Extract) => {\r\n const optionsDiffValue: any = isUndefined(optionsDiff[prop]) ? {} : optionsDiff[prop];\r\n const optionsValue: any = options[prop];\r\n const templateValue: PlainObject | string | OptionsTemplateTypes | Array = template[prop];\r\n const templateIsComplex = isPlainObject(templateValue);\r\n const propPrefix = propPath ? propPath + '.' : '';\r\n\r\n //if the template has a object as value, it means that the options are complex (verschachtelt)\r\n if (templateIsComplex && isPlainObject(optionsValue)) {\r\n const validatedResult = validateRecursive(optionsValue, templateValue as PlainObject, optionsDiffValue, doWriteErrors, propPrefix + prop);\r\n validatedOptions[prop] = validatedResult.validated;\r\n optionsCopy[prop] = validatedResult.foreign as any;\r\n\r\n each([optionsCopy, validatedOptions], (value) => {\r\n if (isEmptyObject(value[prop])) {\r\n delete value[prop];\r\n }\r\n });\r\n }\r\n else if (!templateIsComplex) {\r\n let isValid = false;\r\n const errorEnumStrings: Array = [];\r\n const errorPossibleTypes: Array = [];\r\n const optionsValueType = type(optionsValue);\r\n const templateValueArr: Array = !isArray(templateValue) ? [templateValue as string | OptionsTemplateTypes] : templateValue as Array;\r\n\r\n each(templateValueArr, (currTemplateType) => {\r\n //if currType value isn't inside possibleTemplateTypes we assume its a enum string value\r\n const isEnumString = indexOf(Object.values(optionsTemplateTypes), currTemplateType) < 0;\r\n if (isEnumString && isString(optionsValue)) {\r\n //split it into a array which contains all possible values for example: [\"yes\", \"no\", \"maybe\"]\r\n const enumStringSplit = currTemplateType.split(' ');\r\n isValid = !!enumStringSplit.find(possibility => possibility === optionsValue);\r\n\r\n // build error message\r\n errorEnumStrings.push(...enumStringSplit);\r\n }\r\n else {\r\n isValid = optionsTemplateTypes[optionsValueType] === currTemplateType;\r\n }\r\n\r\n // build error message\r\n errorPossibleTypes.push(isEnumString ? optionsTemplateTypes.string : currTemplateType);\r\n\r\n // continue if invalid, break if valid\r\n return !isValid;\r\n });\r\n\r\n\r\n if (isValid) {\r\n const doStringifyComparison = isArray(optionsValue) || isPlainObject(optionsValue);\r\n if (doStringifyComparison ? stringify(optionsValue) !== stringify(optionsDiffValue) : optionsValue !== optionsDiffValue) {\r\n validatedOptions[prop] = optionsValue;\r\n }\r\n }\r\n else if (doWriteErrors) {\r\n console.warn(`The option \"${propPrefix}${prop}\" wasn't set, because it doesn't accept the type [ ${optionsValueType.toUpperCase()} ] with the value of \"${optionsValue}\".\\r\\n` +\r\n `Accepted types are: [ ${errorPossibleTypes.join(', ').toUpperCase()} ].\\r\\n` +\r\n (errorEnumStrings.length > 0 ? `\\r\\nValid strings are: [ ${errorEnumStrings.join(', ')} ].` : ''))\r\n }\r\n\r\n delete optionsCopy[prop];\r\n }\r\n });\r\n\r\n return {\r\n foreign: optionsCopy,\r\n validated: validatedOptions\r\n };\r\n};\r\n\r\n/**\r\n * Validates the given options object according to the given template object and returns a object which looks like:\r\n * {\r\n * foreign : a object which consists of properties which aren't defined inside the template. (foreign properties)\r\n * validated : a object which consists only of valid properties. (property name is inside the template and value has a correct type)\r\n * }\r\n * @param options The options object which shall be validated.\r\n * @param template The template according to which the options object shall be validated.\r\n * @param optionsDiff When provided the returned validated object will only have properties which are different to this objects properties.\r\n * Example (assume all properties are valid to the template): \r\n * Options object : { a: 'a', b: 'b', c: 'c' }\r\n * optionsDiff object : { a: 'a', b: 'b', c: undefined }\r\n * Returned validated object : { c: 'c' }\r\n * Because the value of the properties a and b didn't change, they aren't included in the returned object.\r\n * Without the optionsDiff object the returned validated object would be: { a: 'a', b: 'b', c: 'c' }\r\n * @param doWriteErrors True if errors shall be logged into the console, false otherwise.\r\n */\r\nconst validate = function (options: T, template: OptionsTemplate>, optionsDiff?: OptionsValidated, doWriteErrors?: boolean): OptionsValidatedResult {\r\n /*\r\n if (!isEmptyObject(foreign) && doWriteErrors)\r\n console.warn(`The following options are discarded due to invalidity:\\r\\n ${window.JSON.stringify(foreign, null, 2)}`);\r\n\r\n \r\n //add values, which aren't specified in the template, to the finished validated object to prevent them from being discarded\r\n if (keepForeignProps) {\r\n Object.assign(result.validated, foreign);\r\n }\r\n */\r\n return validateRecursive(options, template, optionsDiff || {}, doWriteErrors || false);\r\n};\r\n\r\nexport { validate, optionsTemplateTypes };\r\n\r\ntype OptionsTemplateTypesDictionary = {\r\n readonly boolean: OptionsTemplateType;\r\n readonly number: OptionsTemplateType;\r\n readonly string: OptionsTemplateType;\r\n readonly array: OptionsTemplateType>;\r\n readonly object: OptionsTemplateType;\r\n readonly function: OptionsTemplateType;\r\n readonly null: OptionsTemplateType;\r\n}\r\n","import { jsAPI } from 'core/compatibility/vendors';\r\n\r\nexport const resizeObserver: any | undefined = jsAPI('ResizeObserver');","const targets: Set = new Set();\r\nconst targetInstanceMap: WeakMap = new WeakMap();\r\n\r\n/**\r\n * Adds the given OverlayScrollbars instance to the given element.\r\n * @param target The element which is the target of the OverlayScrollbars instance.\r\n * @param osInstance The OverlayScrollbars instance.\r\n */\r\nexport const addInstance: (target: Element, osInstance: any) => void = (target, osInstance) => {\r\n targetInstanceMap.set(target, osInstance);\r\n targets.add(target);\r\n}\r\n\r\n/**\r\n * Removes a OverlayScrollbars instance from the given element.\r\n * @param target The element from which its OverlayScrollbars instance shall be removed.\r\n */\r\nexport const removeInstance: (target: Element) => void = (target) => {\r\n targetInstanceMap.delete(target);\r\n targets.delete(target);\r\n}\r\n\r\n/**\r\n * Gets the OverlayScrollbars from the given element or undefined if it doesn't have one.\r\n * @param target The element of which its OverlayScrollbars instance shall be get.\r\n */\r\nexport const getInstance: (target: Element) => any = (target) => {\r\n return targetInstanceMap.get(target);\r\n}\r\n\r\n/**\r\n * Gets a Map which represents all active OverayScrollbars instances. \r\n * The Key is the ekement and the value is the instance.\r\n */\r\nexport const allInstances: () => ReadonlyMap = () => {\r\n const validTargetInstanceMap: Map = new Map();\r\n\r\n targets.forEach((target: Element) => {\r\n /* istanbul ignore else */\r\n if (targetInstanceMap.has(target)) {\r\n validTargetInstanceMap.set(target, targetInstanceMap.get(target))\r\n }\r\n });\r\n\r\n targets.clear();\r\n\r\n validTargetInstanceMap.forEach((instance: any, validTarget: Element) => {\r\n targets.add(validTarget);\r\n });\r\n\r\n return validTargetInstanceMap;\r\n}","\r\nimport { createDOM } from 'core/dom';\r\n\r\nexport * from 'core/compatibility';\r\nexport * from 'core/utils';\r\nexport * from 'core/dom';\r\nexport * from 'core/options';\r\nexport * from 'instances';\r\n\r\n\r\n\r\nexport default () => createDOM(`\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n fdfhdfgh\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
`);","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tif(__webpack_module_cache__[moduleId]) {\n\t\treturn __webpack_module_cache__[moduleId].exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// module exports must be returned from runtime so entry inlining is disabled\n// startup\n// Load entry module and return exports\nreturn __webpack_require__(95);\n","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"overlayscrollbars.js","sources":["../src/core/utils/types.ts","../src/core/utils/arrays.ts","../src/core/dom/traversal.ts","../src/core/dom/manipulation.ts","../src/core/dom/create.ts","../src/index.ts"],"sourcesContent":["import { PlainObject } from 'core/typings';\r\n\r\nexport const type: (obj: any) => string = (obj) => {\r\n if (obj === undefined)\r\n return obj + '';\r\n if (obj === null)\r\n return obj + '';\r\n return Object.prototype.toString.call(obj).replace(/^\\[object (.+)\\]$/, '$1').toLowerCase();\r\n}\r\n\r\nexport function isNumber(obj: any): obj is number {\r\n return typeof obj === 'number';\r\n};\r\n\r\nexport function isString(obj: any): obj is string {\r\n return typeof obj === 'string';\r\n}\r\n\r\nexport function isBoolean(obj: any): obj is boolean {\r\n return typeof obj === 'boolean';\r\n}\r\n\r\nexport function isObject(obj: any): boolean {\r\n return typeof obj === 'object' && !isArray(obj) && !isNull(obj);\r\n}\r\n\r\nexport function isFunction(obj: any): obj is Function {\r\n return typeof obj === 'function';\r\n}\r\n\r\nexport function isUndefined(obj: any): obj is undefined {\r\n return obj === undefined;\r\n}\r\n\r\nexport function isNull(obj: any): obj is null {\r\n return obj === null;\r\n}\r\n\r\nexport function isArray(obj: any): obj is Array {\r\n return Array.isArray(obj);\r\n}\r\n\r\n\r\n/**\r\n * Returns true if the given object is array like, false otherwise.\r\n * @param obj The Object\r\n */\r\nexport function isArrayLike(obj: any): obj is ArrayLike {\r\n const length = !!obj && obj.length;\r\n return isArray(obj) || (!isFunction(obj) && isNumber(length) && length > -1 && length % 1 == 0);\r\n}\r\n\r\n/**\r\n * Returns true if the given object is a \"plain\" (e.g. { key: value }) object, false otherwise. \r\n * @param obj The Object.\r\n */\r\nexport function isPlainObject(obj: any): obj is PlainObject {\r\n if (!obj || !isObject(obj) || type(obj) !== 'object')\r\n return false;\r\n\r\n let key;\r\n const proto = 'prototype';\r\n const hasOwnProperty = Object[proto].hasOwnProperty;\r\n const hasOwnConstructor = hasOwnProperty.call(obj, 'constructor');\r\n const hasIsPrototypeOf = obj.constructor && obj.constructor[proto] && hasOwnProperty.call(obj.constructor[proto], 'isPrototypeOf');\r\n\r\n if (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) {\r\n return false;\r\n }\r\n\r\n for (key in obj) { /**/ }\r\n\r\n return isUndefined(key) || hasOwnProperty.call(obj, key);\r\n};\r\n\r\n/**\r\n * Checks whether the given object is a HTMLElement.\r\n * @param obj The object which shall be checked.\r\n */\r\nexport function isHTMLElement(obj: any): obj is HTMLElement {\r\n const instaceOfRightHandSide = window.HTMLElement;\r\n const doInstanceOf = isObject(instaceOfRightHandSide) || isFunction(instaceOfRightHandSide);\r\n return !!(\r\n doInstanceOf ? obj instanceof instaceOfRightHandSide : (obj && isObject(obj) && obj.nodeType === 1 && isString(obj.nodeName))\r\n );\r\n}\r\n\r\n/**\r\n * Returns true if the given object is empty, false otherwise.\r\n * @param obj The Object.\r\n */\r\nexport function isEmptyObject(obj: any): boolean {\r\n for (let name in obj)\r\n return false;\r\n return true;\r\n};","import { isArrayLike } from 'core/utils/types';\r\nimport { PlainObject } from 'core/typings';\r\n\r\n\r\n/**\r\n * Iterates through a array or object\r\n * @param arrayLikeOrObject The array or object through which shall be iterated.\r\n * @param callback The function which is responsible for the iteration. \r\n * If the function returns true its treated like a \"continue\" statement.\r\n * If the function returns false its treated like a \"break\" statement.\r\n */\r\nexport function each(array: Array | ReadonlyArray, callback: (value: T, indexOrKey: number, source: Array) => boolean | void): Array | ReadonlyArray;\r\nexport function each(array: Array | ReadonlyArray | null, callback: (value: T, indexOrKey: number, source: Array) => boolean | void): Array | ReadonlyArray | null;\r\nexport function each(arrayLikeObject: ArrayLike, callback: (value: T, indexOrKey: number, source: ArrayLike) => boolean | void): ArrayLike;\r\nexport function each(arrayLikeObject: ArrayLike | null, callback: (value: T, indexOrKey: number, source: ArrayLike) => boolean | void): ArrayLike | null;\r\nexport function each(obj: PlainObject, callback: (value: any, indexOrKey: string, source: PlainObject) => boolean | void): PlainObject;\r\nexport function each(obj: PlainObject | null, callback: (value: any, indexOrKey: string, source: PlainObject) => boolean | void): PlainObject | null;\r\nexport function each(source: ArrayLike | PlainObject | null, callback: (value: T | any, indexOrKey: any, source: any) => boolean | void): Array | ReadonlyArray | ArrayLike | PlainObject | null {\r\n let i: number | string = 0;\r\n\r\n if (isArrayLike(source)) {\r\n for (; i < source.length; i++) {\r\n if (callback(source[i], i, source) === false)\r\n break;\r\n }\r\n }\r\n else if (source) {\r\n for (i in source) {\r\n if (callback(source[i], i, source) === false)\r\n break;\r\n }\r\n }\r\n return source;\r\n};\r\n\r\n/**\r\n * Returns the index of the given inside the given array or -1 if the given item isn't part of the given array.\r\n * @param arr The array.\r\n * @param item The item.\r\n * @param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.\r\n */\r\nexport const indexOf: (arr: Array, item: T, fromIndex?: number) => number = (arr, item, fromIndex) => {\r\n return arr.indexOf(item, fromIndex);\r\n}","import { each } from 'core/utils/arrays';\r\n\r\nconst elementIsVisible: (elm: HTMLElement) => boolean = (elm) => {\r\n return !!(elm.offsetWidth || elm.offsetHeight || elm.getClientRects().length);\r\n}\r\n\r\nexport const find: (selector: string, elm?: Element | null) => ReadonlyArray = (selector, elm?) => {\r\n const arr: Array = [];\r\n\r\n each((elm || document).querySelectorAll(selector), (e: Element) => {\r\n arr.push(e);\r\n });\r\n\r\n return arr;\r\n}\r\n\r\nexport const findFirst: (selector: string, elm?: Element | null) => Element | null = (selector, elm?) => {\r\n return (elm || document).querySelector(selector);\r\n}\r\n\r\nexport const is: (elm: Element | null, selector: string) => boolean = (elm, selector) => {\r\n if (elm) {\r\n if (selector === ':visible')\r\n return elementIsVisible(elm as HTMLElement);\r\n if (selector === ':hidden')\r\n return !elementIsVisible(elm as HTMLElement);\r\n if (elm.matches(selector))\r\n return true;\r\n }\r\n return false;\r\n}\r\n\r\nexport const children: (elm: Element | null, selector?: string) => ReadonlyArray = (elm, selector?) => {\r\n const children: Array = [];\r\n\r\n each(elm && elm.children, (child: Element) => {\r\n if (selector) {\r\n if (child.matches(selector))\r\n children.push(child);\r\n }\r\n else\r\n children.push(child);\r\n });\r\n\r\n return children;\r\n}\r\n\r\nexport const contents: (elm: Element | null) => ReadonlyArray = (elm) => {\r\n return elm ? Array.from(elm.childNodes) : [];\r\n}\r\n\r\nexport const parent: (elm: Node | null) => Node | null = (elm) => elm ? elm.parentElement : null;","import { isArrayLike, isHTMLElement } from 'core/utils/types';\r\nimport { each } from 'core/utils/arrays';\r\nimport { parent } from 'core/dom/traversal';\r\n\r\ntype NodeCollection = ArrayLike | Node | undefined | null;\r\n\r\n/**\r\n * Inserts Nodes before the given preferredAnchor element.\r\n * @param parent The parent of the preferredAnchor element or the element which shall be the parent of the inserted Nodes.\r\n * @param preferredAnchor The element before which the Nodes shall be inserted or null if the elements shall be appended at the end.\r\n * @param insertedElms The Nodes which shall be inserted.\r\n */\r\nconst before: (parent: Node | null, preferredAnchor: Node | null, insertedElms: NodeCollection) => void = (parent, preferredAnchor, insertedElms) => {\r\n if (insertedElms) {\r\n let anchor: Node | null = preferredAnchor;\r\n let fragment: DocumentFragment | Node | undefined | null;\r\n\r\n // parent must be defined\r\n if (parent) {\r\n if (isArrayLike(insertedElms)) {\r\n fragment = document.createDocumentFragment();\r\n\r\n // append all insertedElms to the fragment and if one of these is the anchor, change the anchor\r\n each(insertedElms, (insertedElm) => {\r\n if (insertedElm === anchor) {\r\n anchor = insertedElm.previousSibling;\r\n }\r\n fragment!.appendChild(insertedElm);\r\n });\r\n }\r\n else {\r\n fragment = insertedElms;\r\n }\r\n\r\n // if the preferred anchor isn't null set it to a valid anchor\r\n if (preferredAnchor) {\r\n if (!anchor) {\r\n anchor = parent.firstChild;\r\n }\r\n else if (anchor !== preferredAnchor) {\r\n anchor = anchor.nextSibling;\r\n }\r\n }\r\n\r\n parent.insertBefore(fragment, anchor);\r\n }\r\n }\r\n}\r\n\r\n/**\r\n * Appends the given children at the end of the given Node.\r\n * @param node The Node to which the children shall be appended.\r\n * @param children The Nodes which shall be appended.\r\n */\r\nexport const appendChildren: (node: Node | null, children: NodeCollection) => void = (node, children) => { before(node, null, children) };\r\n\r\n/**\r\n * Prepends the given children at the start of the given Node.\r\n * @param node The Node to which the children shall be prepended.\r\n * @param children The Nodes which shall be prepended.\r\n */\r\nexport const prependChildren: (node: Node | null, children: NodeCollection) => void = (node, children) => { before(node, node && node.firstChild, children) };\r\n\r\n/**\r\n * Inserts the given Nodes before the given Node.\r\n * @param node The Node before which the given Nodes shall be inserted.\r\n * @param insertedNodes The Nodes which shall be inserted.\r\n */\r\nexport const insertBefore: (node: Node | null, insertedNodes: NodeCollection) => void = (node, insertedNodes) => { before(parent(node), node, insertedNodes) };\r\n\r\n/**\r\n * Inserts the given Nodes after the given Node.\r\n * @param node The Node after which the given Nodes shall be inserted.\r\n * @param insertedNodes The Nodes which shall be inserted.\r\n */\r\nexport const insertAfter: (node: Node | null, insertedNodes: NodeCollection) => void = (node, insertedNodes) => { before(parent(node), node && node.nextSibling, insertedNodes) };\r\n\r\n/**\r\n * Removes the given Nodes from their parent.\r\n * @param nodes The Nodes which shall be removed.\r\n */\r\nexport const removeElements: (nodes: NodeCollection) => void = (nodes) => {\r\n if (isArrayLike(nodes)) {\r\n each(Array.from(nodes), (e) => removeElements(e));\r\n }\r\n else if (nodes) {\r\n const parentNode = nodes.parentNode;\r\n if (parentNode)\r\n parentNode.removeChild(nodes);\r\n }\r\n}","import { each } from 'core/utils/arrays';\r\nimport { contents } from 'core/dom/traversal';\r\nimport { removeElements } from 'core/dom/manipulation';\r\n\r\nexport const createDiv: () => HTMLDivElement = () => {\r\n return document.createElement('div');\r\n}\r\n\r\nexport const createDOM: (html: string) => ReadonlyArray = (html) => {\r\n const elm = createDiv();\r\n elm.innerHTML = html.trim();\r\n\r\n return each(contents(elm), (elm) => removeElements(elm));\r\n}","\r\nimport { createDOM } from 'core/dom';\r\nimport j from 'jquery';\r\n/*\r\nexport * from 'core/compatibility';\r\nexport * from 'core/utils';\r\nexport * from 'core/dom';\r\nexport * from 'core/options';\r\nexport * from 'instances';\r\n*/\r\n\r\nconst abc = {\r\n a: 1,\r\n b: 1,\r\n c: 1,\r\n}\r\n\r\nexport default () => {\r\n const { a, b, c } = abc;\r\n return [createDOM(`\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n fdfhdfgh\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
\\\r\n
`), j('div'), a, b, c];\r\n};"],"names":["isNumber","obj","isFunction","isArray","Array","isArrayLike","length","each","source","callback","i","contents","elm","from","childNodes","removeElements","nodes","e","parentNode","removeChild","createDiv","document","createElement","createDOM","html","innerHTML","trim","abc","a","b","c"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;WAUgBA,SAASC;AACrB,WAAO,OAAOA,GAAP,KAAe,QAAtB;AACH;;WAceC,WAAWD;AACvB,WAAO,OAAOA,GAAP,KAAe,UAAtB;AACH;;WAUeE,QAAQF;AACpB,WAAOG,KAAK,CAACD,OAAN,CAAcF,GAAd,CAAP;AACH;;WAOeI,YAAyCJ;AACrD,QAAMK,MAAM,GAAG,CAAC,CAACL,GAAF,IAASA,GAAG,CAACK,MAA5B;AACA,WAAOH,OAAO,CAACF,GAAD,CAAP,IAAiB,CAACC,UAAU,CAACD,GAAD,CAAX,IAAoBD,QAAQ,CAACM,MAAD,CAA5B,IAAwCA,MAAM,GAAG,CAAC,CAAlD,IAAuDA,MAAM,GAAG,CAAT,IAAc,CAA7F;;;WChCYC,KAAQC,QAA2CC;AAC/D,QAAIC,CAAC,GAAoB,CAAzB;;AAEA,QAAIL,WAAW,CAACG,MAAD,CAAf,EAAyB;AACrB,aAAOE,CAAC,GAAGF,MAAM,CAACF,MAAlB,EAA0BI,CAAC,EAA3B,EAA+B;AAC3B,YAAID,QAAQ,CAACD,MAAM,CAACE,CAAD,CAAP,EAAYA,CAAZ,EAAeF,MAAf,CAAR,KAAmC,KAAvC,EACI;AACP;AACJ,KALD,MAMK,IAAIA,MAAJ,EAAY;AACb,WAAKE,CAAL,IAAUF,MAAV,EAAkB;AACd,YAAIC,QAAQ,CAACD,MAAM,CAACE,CAAD,CAAP,EAAYA,CAAZ,EAAeF,MAAf,CAAR,KAAmC,KAAvC,EACI;AACP;AACJ;;AACD,WAAOA,MAAP;;;ACeG,MAAMG,QAAQ,GAAsD,SAA9DA,QAA8D,CAACC,GAAD;AACvE,WAAOA,GAAG,GAAGR,KAAK,CAACS,IAAN,CAAsBD,GAAG,CAACE,UAA1B,CAAH,GAA2C,EAArD;AACH,GAFM;;ACkCA,MAAMC,cAAc,GAAoC,SAAlDA,cAAkD,CAACC,KAAD;AAC3D,QAAIX,WAAW,CAACW,KAAD,CAAf,EAAwB;AACpBT,MAAAA,IAAI,CAACH,KAAK,CAACS,IAAN,CAAWG,KAAX,CAAD,EAAoB,UAACC,CAAD;AAAA,eAAOF,cAAc,CAACE,CAAD,CAArB;AAAA,OAApB,CAAJ;AACH,KAFD,MAGK,IAAID,KAAJ,EAAW;AACZ,UAAME,UAAU,GAAGF,KAAK,CAACE,UAAzB;AACA,UAAIA,UAAJ,EACIA,UAAU,CAACC,WAAX,CAAuBH,KAAvB;AACP;AACJ,GATM;;AC7EA,MAAMI,SAAS,GAAyB,SAAlCA,SAAkC;AAC3C,WAAOC,QAAQ,CAACC,aAAT,CAAuB,KAAvB,CAAP;AACH,GAFM;;AAIA,MAAMC,SAAS,GAA0C,SAAnDA,SAAmD,CAACC,IAAD;AAC5D,QAAMZ,GAAG,GAAGQ,SAAS,EAArB;AACAR,IAAAA,GAAG,CAACa,SAAJ,GAAgBD,IAAI,CAACE,IAAL,EAAhB;AAEA,WAAOnB,IAAI,CAACI,QAAQ,CAACC,GAAD,CAAT,EAAgB,UAACA,GAAD;AAAA,aAASG,cAAc,CAACH,GAAD,CAAvB;AAAA,KAAhB,CAAX;AACH,GALM;;ACGP,MAAMe,GAAG,GAAG;AACRC,IAAAA,CAAC,EAAE,CADK;AAERC,IAAAA,CAAC,EAAE,CAFK;AAGRC,IAAAA,CAAC,EAAE;AAHK,GAAZ;;AAMA,cAAe,cAAA;QACHF,IAAYD,IAAZC;QAAGC,IAASF,IAATE;QAAGC,IAAMH,IAANG;AACd,WAAO,CAACP,SAAS,wtBAAV,EAqBG,qBAAE,KAAF,CArBH,EAqBaK,CArBb,EAqBgBC,CArBhB,EAqBmBC,CArBnB,CAAP;AAsBH,GAxBD;;"} \ No newline at end of file diff --git a/packages/overlayscrollbars/package-lock.json b/packages/overlayscrollbars/package-lock.json new file mode 100644 index 0000000..dcbad46 --- /dev/null +++ b/packages/overlayscrollbars/package-lock.json @@ -0,0 +1,27 @@ +{ + "version": "0.0.1", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@types/jquery": { + "version": "3.5.0", + "resolved": "https://registry.npmjs.org/@types/jquery/-/jquery-3.5.0.tgz", + "integrity": "sha512-C7qQUjpMWDUNYQRTXsP5nbYYwCwwgy84yPgoTT7fPN69NH92wLeCtFaMsWeolJD1AF/6uQw3pYt62rzv83sMmw==", + "dev": true, + "requires": { + "@types/sizzle": "*" + } + }, + "@types/sizzle": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/@types/sizzle/-/sizzle-2.3.2.tgz", + "integrity": "sha512-7EJYyKTL7tFR8+gDbB6Wwz/arpGa0Mywk1TJbNzKzHtzbwVmY4HR9WqS5VV7dsBUKQmPNr192jHr/VpBluj/hg==", + "dev": true + }, + "jquery": { + "version": "3.5.1", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.5.1.tgz", + "integrity": "sha512-XwIBPqcMn57FxfT+Go5pzySnm4KWkT1Tv7gjrpT1srtf8Weynl6R273VJ5GjkRb51IzMp5nbaPjJXMWeju2MKg==" + } + } +} diff --git a/packages/overlayscrollbars/package.json b/packages/overlayscrollbars/package.json index 1cb01d5..b1ea60c 100644 --- a/packages/overlayscrollbars/package.json +++ b/packages/overlayscrollbars/package.json @@ -1,5 +1,11 @@ { "private": true, "description": "OverlayScrollbars version 2", - "version": "0.0.1" + "version": "0.0.1", + "peerDependencies": { + "jquery": "^3.5.1" + }, + "devDependencies": { + "@types/jquery": "^3.5.0" + } } \ No newline at end of file diff --git a/packages/overlayscrollbars/rollup.config.js b/packages/overlayscrollbars/rollup.config.js new file mode 100644 index 0000000..5ef8291 --- /dev/null +++ b/packages/overlayscrollbars/rollup.config.js @@ -0,0 +1,18 @@ +const name = 'OverlayScrollbars'; +const exports = 'default'; + + +export default [ + { + name, + exports, + format: 'umd', + sourcemap: true, + }, + { + name, + exports, + format: 'es', + sourcemap: true, + }, +]; \ No newline at end of file diff --git a/packages/overlayscrollbars/src/index.ts b/packages/overlayscrollbars/src/index.ts index 165e320..04750cf 100644 --- a/packages/overlayscrollbars/src/index.ts +++ b/packages/overlayscrollbars/src/index.ts @@ -1,15 +1,23 @@ import { createDOM } from 'core/dom'; - +import j from 'jquery'; +/* export * from 'core/compatibility'; export * from 'core/utils'; export * from 'core/dom'; export * from 'core/options'; export * from 'instances'; +*/ +const abc = { + a: 1, + b: 1, + c: 1, +} - -export default () => createDOM(`\ +export default () => { + const { a, b, c } = abc; + return [createDOM(`\
\
\
\ @@ -30,4 +38,5 @@ export default () => createDOM(`\
\
\
\ - `); \ No newline at end of file + `), j('div'), a, b, c]; +}; \ No newline at end of file diff --git a/packages/overlayscrollbars/types/index.d.ts b/packages/overlayscrollbars/types/index.d.ts index de2be5d..724512d 100644 --- a/packages/overlayscrollbars/types/index.d.ts +++ b/packages/overlayscrollbars/types/index.d.ts @@ -1,7 +1,3 @@ -export * from 'core/compatibility'; -export * from 'core/utils'; -export * from 'core/dom'; -export * from 'core/options'; -export * from 'instances'; -declare const _default: () => readonly Node[]; +/// +declare const _default: () => (number | readonly Node[] | JQuery)[]; export default _default; diff --git a/packages/overlayscrollbars/webpack.config.js b/packages/overlayscrollbars/webpack.config.js deleted file mode 100644 index fb21806..0000000 --- a/packages/overlayscrollbars/webpack.config.js +++ /dev/null @@ -1,7 +0,0 @@ -export default { - output: { - library: 'OverlayScrollbars', - libraryTarget: 'umd', - libraryExport: 'default', - } -} \ No newline at end of file diff --git a/rollup.config.js b/rollup.config.js new file mode 100644 index 0000000..5bf311a --- /dev/null +++ b/rollup.config.js @@ -0,0 +1,118 @@ +import path from 'path'; +import commonjs from '@rollup/plugin-commonjs'; +import resolve from '@rollup/plugin-node-resolve'; +import typescript from 'rollup-plugin-typescript2'; +import { terser } from "rollup-plugin-terser"; +import { getBabelOutputPlugin } from '@rollup/plugin-babel'; + +const projectRootPath = './packages'; +const projectSrcDirectory = './src'; +const projectDistDirectory = './dist'; +const projectTypesDirectory = './types'; +const projectEntry = 'index.ts'; + +export default async (config) => { + const { + 'config-project': project, + 'config-src': src = projectSrcDirectory, + 'config-dist': dist = projectDistDirectory, + 'config-types': types = projectTypesDirectory, + 'config-entry': entry = projectEntry, + } = config; + + const projectPath = path.resolve(__dirname, projectRootPath, project); + const srcPath = path.resolve(projectPath, src); + const distPath = path.resolve(projectPath, dist); + const typesPath = path.resolve(projectPath, types); + const entryPath = path.resolve(srcPath, entry); + + const packageJSONPath = path.resolve(projectPath, 'package.json'); + const tsconfigJSONPath = path.resolve(projectPath, 'tsconfig.json'); + const nodeModulesPath = path.resolve(projectPath, 'node_modules'); + + const { devDependencies = {}, peerDependencies = {} } = await import(packageJSONPath); + + return { + input: entryPath, + output: [ + { + name: "OverlayScrollbars", + format: 'esm', + file: path.resolve(distPath, `${project}.js`), + sourcemap: true, + exports: 'default', + plugins: [getBabelOutputPlugin({ + presets: [['@babel/preset-env', { + modules: 'umd', + targets: { + ie: "11" + } + + }]], + plugins: [["@babel/plugin-transform-modules-umd", { + globals: { + "jquery": "jQuery" + } + }]], + moduleId: "OverlayScrollbars" + })] + }, + { + name: "OverlayScrollbars", + format: 'esm', + file: path.resolve(distPath, `${project}.esm.js`), + sourcemap: true, + exports: 'default', + plugins: [getBabelOutputPlugin({ + presets: [['@babel/preset-env', { + targets: { + chrome: "51", + firefox: "54", + safari: "11" + } + }]], + })] + }, + /* + { + name: "OverlayScrollbars", + format: 'esm', + file: path.resolve(distPath, `${project}.esm.min.js`), + sourcemap: false, + exports: 'default', + plugins: [getBabelOutputPlugin({ presets: ['@babel/preset-env', { modules: 'umd' }] }), terser(),], + } + */ + ], + external: [ + ...Object.keys(devDependencies), + ...Object.keys(peerDependencies) + ], + plugins: [ + resolve({ + extensions: ['.ts', '.tsx', '.js', 'jsx'], + customResolveOptions: { + moduleDirectory: [ + srcPath, + nodeModulesPath, + path.resolve(__dirname, 'node_modules'), + ], + } + }), + commonjs(), + typescript({ + check: true, + useTsconfigDeclarationDir: true, + tsconfig: tsconfigJSONPath, + tsconfigOverride: { + compilerOptions: { + target: 'es6', + sourceMap: true, + declaration: true, + declarationDir: typesPath, + }, + } + }), + ] + } +}; \ No newline at end of file diff --git a/webpack.config.babel.js b/webpack.config.babel.js deleted file mode 100644 index a821bc4..0000000 --- a/webpack.config.babel.js +++ /dev/null @@ -1,118 +0,0 @@ -import path from 'path'; -import TerserPlugin from 'terser-webpack-plugin'; -import { CleanWebpackPlugin } from 'clean-webpack-plugin'; -import { merge } from 'webpack-merge'; - -const projectRootPath = './packages'; -const projectSrcDirectory = './src'; -const projectDistDirectory = './dist'; -const projectTypesDirectory = './types'; -const projectEntry = 'index'; - -const outputs = [{ - extension: 'js', - target: 'es5', - ecmaVersion: 5, -}, { - extension: 'esm.js', - target: 'es6', - ecmaVersion: 6, -}]; - -export default async (env) => { - const { - project, - src = projectSrcDirectory, - dist = projectDistDirectory, - types = projectTypesDirectory, - entry = projectEntry, - production - } = env; - const projectPath = path.resolve(__dirname, projectRootPath, project); - const srcPath = path.resolve(projectPath, src); - const distPath = path.resolve(projectPath, dist); - const typesPath = path.resolve(projectPath, types); - const entryPath = path.resolve(srcPath, entry); - - const webpackConfigPath = path.resolve(projectPath, 'webpack.config.js'); - const packageJSONPath = path.resolve(projectPath, 'package.json'); - const tsconfigJSONPath = path.resolve(projectPath, 'tsconfig.json'); - const nodeModulesPath = path.resolve(projectPath, 'node_modules'); - - const { default: webpackConfig } = await import(webpackConfigPath); - const { compilerOptions } = await import(tsconfigJSONPath); - const { devDependencies = {}, peerDependencies = {} } = await import(packageJSONPath); - - const genConfigObj = ({ target, ecmaVersion, extension }, isFirstRun) => (merge({ - entry: entryPath, - mode: production ? 'production' : 'development', - devtool: 'source-map', - optimization: { - minimize: true, - minimizer: [ - new TerserPlugin({ - sourceMap: true, - extractComments: false, - terserOptions: { - mangle: { - properties: { - regex: /^_/ - } - }, - output: { - beautify: true, - comments: false - } - }, - }), - ], - }, - module: { - rules: [ - { - test: /\.tsx?$/, - exclude: /node_modules/, - use: [ - { - loader: 'ts-loader', - options: { - compilerOptions: { - ...compilerOptions, - target: target, - declarationDir: typesPath, - } - } - } - ] - }, - ], - }, - resolve: { - extensions: ['.tsx', '.ts', '.js', 'jsx'], - modules: [ - srcPath, - nodeModulesPath, - path.resolve(__dirname, 'node_modules'), - ], - }, - output: { - filename: `${project}.${extension}`, - path: distPath, - ecmaVersion - }, - externals: [ - ...Object.keys(devDependencies), - ...Object.keys(peerDependencies) - ], - plugins: [ - ].concat(isFirstRun ? [new CleanWebpackPlugin({ - verbose: true, - cleanOnceBeforeBuildPatterns: [ - distPath, - typesPath - ] - })] : []) - }, webpackConfig)); - - return outputs.map((output, index) => genConfigObj(output, index === 0)) -}; \ No newline at end of file