diff --git a/example/package.json b/example/package.json index d6b36f5..bde4d26 100644 --- a/example/package.json +++ b/example/package.json @@ -8,15 +8,15 @@ "test:br": "npm run build && http-server dist --cors --brotli -c-1" }, "dependencies": { - "vue": "^3.0.7" + "vue": "^3.0.11" }, "devDependencies": { - "@vitejs/plugin-vue": "^1.1.5", - "@vitejs/plugin-vue-jsx": "^1.1.2", - "@vue/compiler-sfc": "^3.0.7", + "@vitejs/plugin-vue": "^1.2.1", + "@vitejs/plugin-vue-jsx": "^1.1.3", + "@vue/compiler-sfc": "^3.0.11", "cross-env": "^7.0.3", "http-server": "^0.12.3", "typescript": "^4.2.3", - "vite": "^2.1.2" + "vite": "^2.1.5" } } diff --git a/package.json b/package.json index 9c0c30c..275a28b 100644 --- a/package.json +++ b/package.json @@ -48,27 +48,27 @@ "etag": "^1.8.1", "fs-extra": "^9.1.0", "svg-baker": "1.7.0", - "svgo": "^2.2.2" + "svgo": "^2.3.0" }, "peerDependencies": { "vite": ">=2.0.0" }, "devDependencies": { - "@commitlint/cli": "^12.1.0", - "@commitlint/config-conventional": "^12.1.0", + "@commitlint/cli": "^12.1.1", + "@commitlint/config-conventional": "^12.1.1", "@types/debug": "^4.1.5", "@types/etag": "^1.8.0", - "@types/fs-extra": "^9.0.8", - "@types/jest": "^26.0.21", - "@types/node": "^14.14.35", - "@typescript-eslint/eslint-plugin": "^4.18.0", - "@typescript-eslint/parser": "^4.18.0", + "@types/fs-extra": "^9.0.10", + "@types/jest": "^26.0.22", + "@types/node": "^14.14.37", + "@typescript-eslint/eslint-plugin": "^4.20.0", + "@typescript-eslint/parser": "^4.20.0", "commitizen": "^4.2.3", "conventional-changelog-cli": "^2.1.1", - "eslint": "^7.22.0", + "eslint": "^7.23.0", "eslint-config-prettier": "^8.1.0", - "eslint-plugin-jest": "^24.3.2", - "husky": "^5.1.3", + "eslint-plugin-jest": "^24.3.3", + "husky": "^5.2.0", "jest": "^26.6.3", "lint-staged": "^10.5.4", "pinst": "^2.1.6", @@ -76,8 +76,8 @@ "pretty-quick": "^3.1.0", "rimraf": "^3.0.2", "ts-jest": "^26.5.4", - "tsup": "^4.8.18", + "tsup": "^4.8.21", "typescript": "^4.2.3", - "vite": "^2.1.2" + "vite": "^2.1.5" } } diff --git a/src/index.ts b/src/index.ts index c9300df..09791ef 100644 --- a/src/index.ts +++ b/src/index.ts @@ -42,8 +42,8 @@ interface FileStats { export default (opt: ViteSvgIconsPlugin): Plugin => { const cache = new Map(); - let isBuild = false; + let isBuild = false; const options = { svgoOptions: true, symbolId: 'icon-[dir]-[name]', @@ -52,6 +52,7 @@ export default (opt: ViteSvgIconsPlugin): Plugin => { let { svgoOptions } = options; const { symbolId } = options; + if (!symbolId.includes('[name]')) { throw new Error('SymbolId must contain [name] string!'); } @@ -200,7 +201,9 @@ export async function compilerIcon( symbolId: string, svgOptions: SvgoOptions ): Promise { - if (!file) return null; + if (!file) { + return null; + } let content = fs.readFileSync(file, 'utf-8'); @@ -208,6 +211,7 @@ export async function compilerIcon( const { data } = await optimize(content, svgOptions); content = data; } + const svgSymbol = await new SVGCompiler().addSymbol({ id: symbolId, content, @@ -247,7 +251,6 @@ export function discreteDir(name: string) { } const strList = name.split('/'); - const fileName = strList.pop(); const dirName = strList.join('-'); return { fileName, dirName }; diff --git a/yarn.lock b/yarn.lock index 6192d39..9aa2e99 100644 --- a/yarn.lock +++ b/yarn.lock @@ -315,35 +315,35 @@ exec-sh "^0.3.2" minimist "^1.2.0" -"@commitlint/cli@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/cli/-/cli-12.1.0.tgz#6f960b7f89a15ffdbabb2cbecc45514944218906" - integrity sha512-VjDjQ0kSQASvTjk1pKaigHPXCw99hye/laPbOjpX4AVJXJjMm6oV1EitZHatINImDUgVLVLpG2Y9DI/bLcVjcg== - dependencies: - "@commitlint/format" "^12.0.1" - "@commitlint/lint" "^12.1.0" - "@commitlint/load" "^12.1.0" - "@commitlint/read" "^12.1.0" - "@commitlint/types" "^12.0.1" +"@commitlint/cli@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/cli/-/cli-12.1.1.tgz#740370e557a8a17f415052821cdd5276ecb0ab98" + integrity sha512-SB67/s6VJ50seoPx/Sr2gj1fMzKrx+udgarecGdr8h43ah+M2e22gjQJ7xHv5KwyPQ+6ug1YOMCL34ubT4zupQ== + dependencies: + "@commitlint/format" "^12.1.1" + "@commitlint/lint" "^12.1.1" + "@commitlint/load" "^12.1.1" + "@commitlint/read" "^12.1.1" + "@commitlint/types" "^12.1.1" get-stdin "8.0.0" lodash "^4.17.19" resolve-from "5.0.0" resolve-global "1.0.0" yargs "^16.2.0" -"@commitlint/config-conventional@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/config-conventional/-/config-conventional-12.1.0.tgz#be8c8b150d6dd7bd81f59b6def39d1f938fff53c" - integrity sha512-kBQUO9XVyMSOPAFalnwrrvMODLvTGOpLcSkrTCgNChAo7w0FDk9ZWK5SnPfURR6/2A2bu3nCbJsfcYUJ0B7p2g== +"@commitlint/config-conventional@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/config-conventional/-/config-conventional-12.1.1.tgz#73dd3b1a7912138420d248f334f15c94c250bc9e" + integrity sha512-15CqbXMsQiEb0qbzjEHe2OkzaXPYSp7RxaS6KoSVk/4W0QiigquavQ+M0huBZze92h0lMS6Pxoq4AJ5CQ3D+iQ== dependencies: conventional-changelog-conventionalcommits "^4.3.1" -"@commitlint/ensure@^12.0.1": - version "12.0.1" - resolved "https://registry.npmjs.org/@commitlint/ensure/-/ensure-12.0.1.tgz#0ed5e997026db25eb080559b6e67f55a21eea080" - integrity sha512-XdBq+q1YBBDxWIAEjE3Y1YMbzhUnUuSLAEWD8SU1xsvEpQXWRYwDlMBRkjO7funNWTdL0ZQSkZDzme70imYjbw== +"@commitlint/ensure@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/ensure/-/ensure-12.1.1.tgz#bcefc85f7f8a41bb31f67d7a8966e322b47a6e43" + integrity sha512-XEUQvUjzBVQM7Uv8vYz+c7PDukFvx0AvQEyX/V+PaTkCK/xPvexu7FLbFwvypjSt9BPMf+T/rhB1hVmldkd6lw== dependencies: - "@commitlint/types" "^12.0.1" + "@commitlint/types" "^12.1.1" lodash "^4.17.19" "@commitlint/execute-rule@^12.0.1": @@ -351,31 +351,36 @@ resolved "https://registry.npmjs.org/@commitlint/execute-rule/-/execute-rule-12.0.1.tgz#5bb2eba929270cafb2bd8191799d8b451de7fb7e" integrity sha512-JzyweYfZlFLtXpgP+btzSY3YAkGPg61TqUSYQqBr4+5IaVf1FruMm5v4D5eLu9dAJuNKUfHbM3AEfuEPiZ79pg== -"@commitlint/format@^12.0.1": - version "12.0.1" - resolved "https://registry.npmjs.org/@commitlint/format/-/format-12.0.1.tgz#5164e5a9e8592c1983482cbd71e7ea86a645ff1b" - integrity sha512-rF79ipAxR8yFzPzG5tRoEZ//MRkyxCXj4JhpEjtdaCMBAXMssI8uazn3e5D8z4UFgSDe9qOnL0OmQvql7HTMoA== +"@commitlint/execute-rule@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/execute-rule/-/execute-rule-12.1.1.tgz#8aad1d46fb78b3199e4ae36debdc93570bf765ea" + integrity sha512-6mplMGvLCKF5LieL7BRhydpg32tm6LICnWQADrWU4S5g9PKi2utNvhiaiuNPoHUXr29RdbNaGNcyyPv8DSjJsQ== + +"@commitlint/format@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/format/-/format-12.1.1.tgz#a6b14f8605171374eecc2c463098d63c127ab7df" + integrity sha512-bTAoOryTFLqls17JTaRwk2WDVOP0NwuG4F/JPK8RaF6DMZNVQTfajkgTxFENNZRnESfau1BvivvEXfUAW2ZsvA== dependencies: - "@commitlint/types" "^12.0.1" + "@commitlint/types" "^12.1.1" chalk "^4.0.0" -"@commitlint/is-ignored@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/is-ignored/-/is-ignored-12.1.0.tgz#26f0d9fb14dff50e66f6ffedc9408dee513783ac" - integrity sha512-q8urjMNTKqvQzKOn4qLUp30vM6TK8Bxeu7lUfOrevmxuAGsIN5dr/preeFvFstP4hYIEIzrr8A2ZADCp6RSd9A== +"@commitlint/is-ignored@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/is-ignored/-/is-ignored-12.1.1.tgz#6075a5cd2dcda7b6ec93322f5dbe2142cfbb3248" + integrity sha512-Sn4fsnWX+wLAJOD/UZeoVruB98te1TyPYRiDEq0MhRJAQIrP+7jE/O3/ass68AAMq00HvH3OK9kt4UBXggcGjA== dependencies: - "@commitlint/types" "^12.0.1" - semver "7.3.4" + "@commitlint/types" "^12.1.1" + semver "7.3.5" -"@commitlint/lint@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/lint/-/lint-12.1.0.tgz#11b1d72982a67575ea2f666ec1fd88c3f193e925" - integrity sha512-RZEdLZKx+JIBMG4HOemlgU04JQGHU9FZALbjscHZYBofnFfxr95izdP6n5sVIK542/BYpcwXWhqQ06jS8f7U5g== +"@commitlint/lint@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/lint/-/lint-12.1.1.tgz#cdd898af6eadba8f9e71d7f1255b5a479a757078" + integrity sha512-FFFPpku/E0svL1jaUVqosuZJDDWiNWYBlUw5ZEljh3MwWRcoaWtMIX5bseX+IvHpFZsCTAiBs1kCgNulCi0UvA== dependencies: - "@commitlint/is-ignored" "^12.1.0" - "@commitlint/parse" "^12.1.0" - "@commitlint/rules" "^12.1.0" - "@commitlint/types" "^12.0.1" + "@commitlint/is-ignored" "^12.1.1" + "@commitlint/parse" "^12.1.1" + "@commitlint/rules" "^12.1.1" + "@commitlint/types" "^12.1.1" "@commitlint/load@>6.1.1": version "12.0.1" @@ -390,40 +395,40 @@ lodash "^4.17.19" resolve-from "^5.0.0" -"@commitlint/load@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/load/-/load-12.1.0.tgz#ac18ad1b80e239551ad63209d660a04f3950cb58" - integrity sha512-dMQainAoKsqFFY6+BdeoCSqiiG9Y9xsqCUJfICkOUx+kzrRrlANpT/Leyd8M5RYmZiIIrxGVUKfa1c/DTaOakQ== +"@commitlint/load@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/load/-/load-12.1.1.tgz#5a7fb8be11e520931d1237c5e8dc401b7cc9c6c1" + integrity sha512-qOQtgNdJRULUQWP9jkpTwhj7aEtnqUtqeUpbQ9rjS+GIUST65HZbteNUX4S0mAEGPWqy2aK5xGd73cUfFSvuuw== dependencies: - "@commitlint/execute-rule" "^12.0.1" - "@commitlint/resolve-extends" "^12.0.1" - "@commitlint/types" "^12.0.1" + "@commitlint/execute-rule" "^12.1.1" + "@commitlint/resolve-extends" "^12.1.1" + "@commitlint/types" "^12.1.1" chalk "^4.0.0" cosmiconfig "^7.0.0" lodash "^4.17.19" resolve-from "^5.0.0" -"@commitlint/message@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/message/-/message-12.1.0.tgz#661d92715dafa2251d9c46563a243acc2bbd286c" - integrity sha512-5kc4MYWJUV2npn4QQnDWr8B1osB8o/QEPnWxjnCc2JD/PMDR8svt2ja+dyjZQcLC+9Ta1G2Tu6dy1LLhyTsghw== +"@commitlint/message@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/message/-/message-12.1.1.tgz#56eb1dbb561e85e9295380a46ff3b09bc93cac65" + integrity sha512-RakDSLAiOligXjhbLahV8HowF4K75pZIcs0+Ii9Q8Gz5H3DWf1Ngit7alFTWfcbf/+DTjSzVPov5HiwQZPIBUg== -"@commitlint/parse@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/parse/-/parse-12.1.0.tgz#0bb7169e261af070190077a4aca367373c37f7a0" - integrity sha512-n3y6MxsbmsXo/eCDheN1hVsNrhQ7v9vREdLkX7MWnjnrZhD4jyMQ1DfWpd6Fo5ss0gzpfeS/HTXTgkU1S2V8DQ== +"@commitlint/parse@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/parse/-/parse-12.1.1.tgz#3e49d6dc113d59cf266af0db99e320e933108c56" + integrity sha512-nuljIvAbBDr93DgL0wCArftEIhjSghawAwhvrKNV9FFcqAJqfVqitwMxJrNDCQ5pgUMCSKULLOEv+dA0bLlTEQ== dependencies: - "@commitlint/types" "^12.0.1" + "@commitlint/types" "^12.1.1" conventional-changelog-angular "^5.0.11" conventional-commits-parser "^3.0.0" -"@commitlint/read@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/read/-/read-12.1.0.tgz#5d691e7fdc6397dd3dbc1ee8cb16b4d4f25a55d2" - integrity sha512-BXD0U/qFwPQtSOOZpD46pdhDGJ5eCVLwt41So8FdLidb28YWKA1O7Zb9CWCirG/eN42axfSNhz7XY1mD5gNa3Q== +"@commitlint/read@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/read/-/read-12.1.1.tgz#22a2d7fd1eab5e38b9b262311af28ac42f9a5097" + integrity sha512-1k0CQEoZIdixvmqZRKEcWdj2XiKS7SlizEOJ1SE99Qui5d5FlBey8eaooTGgmpR6zObpIHJehtEPzM3VzUT3qA== dependencies: - "@commitlint/top-level" "^12.0.1" - "@commitlint/types" "^12.0.1" + "@commitlint/top-level" "^12.1.1" + "@commitlint/types" "^12.1.1" fs-extra "^9.0.0" git-raw-commits "^2.0.0" @@ -437,25 +442,35 @@ resolve-from "^5.0.0" resolve-global "^1.0.0" -"@commitlint/rules@^12.1.0": - version "12.1.0" - resolved "https://registry.npmjs.org/@commitlint/rules/-/rules-12.1.0.tgz#da612ffda4992ac1c30589f777f92b73f97460cd" - integrity sha512-jVuF/l60u+FBde2tto0iiFsAj0RVlKDkeENEQ6hQjdYNAxeOV7dUBndTY9vmhmCfL928sHBqRGTicdLwHHgSvA== +"@commitlint/resolve-extends@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/resolve-extends/-/resolve-extends-12.1.1.tgz#80a78b0940775d17888dd2985b52f93d93e0a885" + integrity sha512-/DXRt0S0U3o9lq5cc8OL1Lkx0IjW0HcDWjUkUXshAajBIKBYSJB8x/loNCi1krNEJ8SwLXUEFt5OLxNO6wE9yQ== dependencies: - "@commitlint/ensure" "^12.0.1" - "@commitlint/message" "^12.1.0" - "@commitlint/to-lines" "^12.0.1" - "@commitlint/types" "^12.0.1" + import-fresh "^3.0.0" + lodash "^4.17.19" + resolve-from "^5.0.0" + resolve-global "^1.0.0" -"@commitlint/to-lines@^12.0.1": - version "12.0.1" - resolved "https://registry.npmjs.org/@commitlint/to-lines/-/to-lines-12.0.1.tgz#586d89b9f9ff99ef93b3c8aa3d77faffbe3ffedc" - integrity sha512-XwcJ1jY7x2fhudzbGMpNQkTSMVrxWrI8bRMbVe3Abuu7RfYpFf7VXAlhtnLfxBoagaK7RxjC2+eRidp/3txQBg== +"@commitlint/rules@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/rules/-/rules-12.1.1.tgz#d59182a837d2addf301a3a4ef83316ae7e70248f" + integrity sha512-oCcLF/ykcJfhM2DeeaDyrgdaiuKsqIPNocugdPj2WEyhSYqmx1/u18CV96LAtW+WyyiOLCCeiZwiQutx3T5nXg== + dependencies: + "@commitlint/ensure" "^12.1.1" + "@commitlint/message" "^12.1.1" + "@commitlint/to-lines" "^12.1.1" + "@commitlint/types" "^12.1.1" -"@commitlint/top-level@^12.0.1": - version "12.0.1" - resolved "https://registry.npmjs.org/@commitlint/top-level/-/top-level-12.0.1.tgz#9c7efd319a4f8d29001f011ba8b0e21fad6044f6" - integrity sha512-rHdgt7U24GEau2/9i2vEAbksxkBRiVjHj5ECFL5dd0AJOIvaK++vMg4EF/ME0X/1yd9qVTHTNOl2Q4tTFK7VBQ== +"@commitlint/to-lines@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/to-lines/-/to-lines-12.1.1.tgz#40fbed1767d637249ce49b311a51909d8361ecf8" + integrity sha512-W23AH2XF5rI27MOAPSSr0TUDoRe7ZbFoRtYhFnPu2MBmcuDA9Tmfd9N5sM2tBXtdE26uq3SazwKqGt1OoGAilQ== + +"@commitlint/top-level@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/top-level/-/top-level-12.1.1.tgz#228df8fc36b6d7ea7ad149badfb6ef53dbc7001d" + integrity sha512-g7uRbr81QEIg+pbii0OkE17Zh/2C/f6dSmiMDVRn1S0+hNHR1bENCh18hVUKcV/qKTUsKkFlhhWXM9mQBfxQJw== dependencies: find-up "^5.0.0" @@ -466,6 +481,13 @@ dependencies: chalk "^4.0.0" +"@commitlint/types@^12.1.1": + version "12.1.1" + resolved "https://registry.npmjs.org/@commitlint/types/-/types-12.1.1.tgz#8e651f6af0171cd4f8d464c6c37a7cf63ee071bd" + integrity sha512-+qGH+s2Lo6qwacV2X3/ZypZwaAI84ift+1HBjXdXtI/q0F5NtmXucV3lcQOTviMTNiJhq4qWON2fjci2NItASw== + dependencies: + chalk "^4.0.0" + "@eslint/eslintrc@^0.4.0": version "0.4.0" resolved "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-0.4.0.tgz#99cc0a0584d72f1df38b900fb062ba995f395547" @@ -753,10 +775,10 @@ dependencies: "@types/node" "*" -"@types/fs-extra@^9.0.8": - version "9.0.8" - resolved "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-9.0.8.tgz#32c3c07ddf8caa5020f84b5f65a48470519f78ba" - integrity sha512-bnlTVTwq03Na7DpWxFJ1dvnORob+Otb8xHyUqUWhqvz/Ksg8+JXPlR52oeMSZ37YEOa5PyccbgUNutiQdi13TA== +"@types/fs-extra@^9.0.10": + version "9.0.10" + resolved "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-9.0.10.tgz#8023a72e3d06cf54929ea47ec7634e47f33f4046" + integrity sha512-O9T2LLkRDiTlalOBdjEkcnT0MRdT2+wglCl7pJUJ3mkWkR8hX4K+5bg2raQNJcLv4V8zGuTXe7Ud3wSqkTyuyQ== dependencies: "@types/node" "*" @@ -786,10 +808,10 @@ dependencies: "@types/istanbul-lib-report" "*" -"@types/jest@^26.0.21": - version "26.0.21" - resolved "https://registry.npmjs.org/@types/jest/-/jest-26.0.21.tgz#3a73c2731e7e4f0fbaea56ce7ff8c79cf812bd24" - integrity sha512-ab9TyM/69yg7eew9eOwKMUmvIZAKEGZYlq/dhe5/0IMUd/QLJv5ldRMdddSn+u22N13FP3s5jYyktxuBwY0kDA== +"@types/jest@^26.0.22": + version "26.0.22" + resolved "https://registry.npmjs.org/@types/jest/-/jest-26.0.22.tgz#8308a1debdf1b807aa47be2838acdcd91e88fbe6" + integrity sha512-eeWwWjlqxvBxc4oQdkueW5OF/gtfSceKk4OnOAGlUSwS/liBRtZppbJuz1YkgbrbfGOoeBHun9fOvXnjNwrSOw== dependencies: jest-diff "^26.0.0" pretty-format "^26.0.0" @@ -814,10 +836,10 @@ resolved "https://registry.npmjs.org/@types/node/-/node-14.14.24.tgz#541c00e4f7c41c8f108bd5b045248b5224c62946" integrity sha512-6BAlkS4seVjszhrwN0W1WabqWwuJwcYF36Z1rPPyQm80LGRKsIeUPdzI51TezXenjetFNy1gRTpuDn1NBg33LA== -"@types/node@^14.14.35": - version "14.14.35" - resolved "https://registry.npmjs.org/@types/node/-/node-14.14.35.tgz#42c953a4e2b18ab931f72477e7012172f4ffa313" - integrity sha512-Lt+wj8NVPx0zUmUwumiVXapmaLUcAk3yPuHCFVXras9k5VT9TdhJqKqGVUQCD60OTMCl0qxJ57OiTL0Mic3Iag== +"@types/node@^14.14.37": + version "14.14.37" + resolved "https://registry.npmjs.org/@types/node/-/node-14.14.37.tgz#a3dd8da4eb84a996c36e331df98d82abd76b516e" + integrity sha512-XYmBiy+ohOR4Lh5jE379fV2IU+6Jn4g5qASinhitfyO71b/sCo6MKsMLF5tc7Zf2CE8hViVQyYSobJNke8OvUw== "@types/normalize-package-data@^2.4.0": version "2.4.0" @@ -856,13 +878,13 @@ dependencies: "@types/yargs-parser" "*" -"@typescript-eslint/eslint-plugin@^4.18.0": - version "4.18.0" - resolved "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-4.18.0.tgz#50fbce93211b5b690895d20ebec6fe8db48af1f6" - integrity sha512-Lzkc/2+7EoH7+NjIWLS2lVuKKqbEmJhtXe3rmfA8cyiKnZm3IfLf51irnBcmow8Q/AptVV0XBZmBJKuUJTe6cQ== +"@typescript-eslint/eslint-plugin@^4.20.0": + version "4.20.0" + resolved "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-4.20.0.tgz#9d8794bd99aad9153092ad13c96164e3082e9a92" + integrity sha512-sw+3HO5aehYqn5w177z2D82ZQlqHCwcKSMboueo7oE4KU9QiC0SAgfS/D4z9xXvpTc8Bt41Raa9fBR8T2tIhoQ== dependencies: - "@typescript-eslint/experimental-utils" "4.18.0" - "@typescript-eslint/scope-manager" "4.18.0" + "@typescript-eslint/experimental-utils" "4.20.0" + "@typescript-eslint/scope-manager" "4.20.0" debug "^4.1.1" functional-red-black-tree "^1.0.1" lodash "^4.17.15" @@ -870,15 +892,15 @@ semver "^7.3.2" tsutils "^3.17.1" -"@typescript-eslint/experimental-utils@4.18.0": - version "4.18.0" - resolved "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-4.18.0.tgz#ed6c955b940334132b17100d2917449b99a91314" - integrity sha512-92h723Kblt9JcT2RRY3QS2xefFKar4ZQFVs3GityOKWQYgtajxt/tuXIzL7sVCUlM1hgreiV5gkGYyBpdOwO6A== +"@typescript-eslint/experimental-utils@4.20.0": + version "4.20.0" + resolved "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-4.20.0.tgz#a8ab2d7b61924f99042b7d77372996d5f41dc44b" + integrity sha512-sQNlf6rjLq2yB5lELl3gOE7OuoA/6IVXJUJ+Vs7emrQMva14CkOwyQwD7CW+TkmOJ4Q/YGmoDLmbfFrpGmbKng== dependencies: "@types/json-schema" "^7.0.3" - "@typescript-eslint/scope-manager" "4.18.0" - "@typescript-eslint/types" "4.18.0" - "@typescript-eslint/typescript-estree" "4.18.0" + "@typescript-eslint/scope-manager" "4.20.0" + "@typescript-eslint/types" "4.20.0" + "@typescript-eslint/typescript-estree" "4.20.0" eslint-scope "^5.0.0" eslint-utils "^2.0.0" @@ -894,14 +916,14 @@ eslint-scope "^5.0.0" eslint-utils "^2.0.0" -"@typescript-eslint/parser@^4.18.0": - version "4.18.0" - resolved "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.18.0.tgz#a211edb14a69fc5177054bec04c95b185b4dde21" - integrity sha512-W3z5S0ZbecwX3PhJEAnq4mnjK5JJXvXUDBYIYGoweCyWyuvAKfGHvzmpUzgB5L4cRBb+cTu9U/ro66dx7dIimA== +"@typescript-eslint/parser@^4.20.0": + version "4.20.0" + resolved "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.20.0.tgz#8dd403c8b4258b99194972d9799e201b8d083bdd" + integrity sha512-m6vDtgL9EABdjMtKVw5rr6DdeMCH3OA1vFb0dAyuZSa3e5yw1YRzlwFnm9knma9Lz6b2GPvoNSa8vOXrqsaglA== dependencies: - "@typescript-eslint/scope-manager" "4.18.0" - "@typescript-eslint/types" "4.18.0" - "@typescript-eslint/typescript-estree" "4.18.0" + "@typescript-eslint/scope-manager" "4.20.0" + "@typescript-eslint/types" "4.20.0" + "@typescript-eslint/typescript-estree" "4.20.0" debug "^4.1.1" "@typescript-eslint/scope-manager@4.16.1": @@ -912,23 +934,23 @@ "@typescript-eslint/types" "4.16.1" "@typescript-eslint/visitor-keys" "4.16.1" -"@typescript-eslint/scope-manager@4.18.0": - version "4.18.0" - resolved "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.18.0.tgz#d75b55234c35d2ff6ac945758d6d9e53be84a427" - integrity sha512-olX4yN6rvHR2eyFOcb6E4vmhDPsfdMyfQ3qR+oQNkAv8emKKlfxTWUXU5Mqxs2Fwe3Pf1BoPvrwZtwngxDzYzQ== +"@typescript-eslint/scope-manager@4.20.0": + version "4.20.0" + resolved "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.20.0.tgz#953ecbf3b00845ece7be66246608be9d126d05ca" + integrity sha512-/zm6WR6iclD5HhGpcwl/GOYDTzrTHmvf8LLLkwKqqPKG6+KZt/CfSgPCiybshmck66M2L5fWSF/MKNuCwtKQSQ== dependencies: - "@typescript-eslint/types" "4.18.0" - "@typescript-eslint/visitor-keys" "4.18.0" + "@typescript-eslint/types" "4.20.0" + "@typescript-eslint/visitor-keys" "4.20.0" "@typescript-eslint/types@4.16.1": version "4.16.1" resolved "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.16.1.tgz#5ba2d3e38b1a67420d2487519e193163054d9c15" integrity sha512-nnKqBwMgRlhzmJQF8tnFDZWfunXmJyuXj55xc8Kbfup4PbkzdoDXZvzN8//EiKR27J6vUSU8j4t37yUuYPiLqA== -"@typescript-eslint/types@4.18.0": - version "4.18.0" - resolved "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.18.0.tgz#bebe323f81f2a7e2e320fac9415e60856267584a" - integrity sha512-/BRociARpj5E+9yQ7cwCF/SNOWwXJ3qhjurMuK2hIFUbr9vTuDeu476Zpu+ptxY2kSxUHDGLLKy+qGq2sOg37A== +"@typescript-eslint/types@4.20.0": + version "4.20.0" + resolved "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.20.0.tgz#c6cf5ef3c9b1c8f699a9bbdafb7a1da1ca781225" + integrity sha512-cYY+1PIjei1nk49JAPnH1VEnu7OYdWRdJhYI5wiKOUMhLTG1qsx5cQxCUTuwWCmQoyriadz3Ni8HZmGSofeC+w== "@typescript-eslint/typescript-estree@4.16.1": version "4.16.1" @@ -943,13 +965,13 @@ semver "^7.3.2" tsutils "^3.17.1" -"@typescript-eslint/typescript-estree@4.18.0": - version "4.18.0" - resolved "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.18.0.tgz#756d3e61da8c16ab99185532c44872f4cd5538cb" - integrity sha512-wt4xvF6vvJI7epz+rEqxmoNQ4ZADArGQO9gDU+cM0U5fdVv7N+IAuVoVAoZSOZxzGHBfvE3XQMLdy+scsqFfeg== +"@typescript-eslint/typescript-estree@4.20.0": + version "4.20.0" + resolved "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.20.0.tgz#8b3b08f85f18a8da5d88f65cb400f013e88ab7be" + integrity sha512-Knpp0reOd4ZsyoEJdW8i/sK3mtZ47Ls7ZHvD8WVABNx5Xnn7KhenMTRGegoyMTx6TiXlOVgMz9r0pDgXTEEIHA== dependencies: - "@typescript-eslint/types" "4.18.0" - "@typescript-eslint/visitor-keys" "4.18.0" + "@typescript-eslint/types" "4.20.0" + "@typescript-eslint/visitor-keys" "4.20.0" debug "^4.1.1" globby "^11.0.1" is-glob "^4.0.1" @@ -964,12 +986,12 @@ "@typescript-eslint/types" "4.16.1" eslint-visitor-keys "^2.0.0" -"@typescript-eslint/visitor-keys@4.18.0": - version "4.18.0" - resolved "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.18.0.tgz#4e6fe2a175ee33418318a029610845a81e2ff7b6" - integrity sha512-Q9t90JCvfYaN0OfFUgaLqByOfz8yPeTAdotn/XYNm5q9eHax90gzdb+RJ6E9T5s97Kv/UHWKERTmqA0jTKAEHw== +"@typescript-eslint/visitor-keys@4.20.0": + version "4.20.0" + resolved "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.20.0.tgz#1e84db034da13f208325e6bfc995c3b75f7dbd62" + integrity sha512-NXKRM3oOVQL8yNFDNCZuieRIwZ5UtjNLYtmMx2PacEAGmbaEYtGgVHUHVyZvU/0rYZcizdrWjDo+WBtRPSgq+A== dependencies: - "@typescript-eslint/types" "4.18.0" + "@typescript-eslint/types" "4.20.0" eslint-visitor-keys "^2.0.0" JSONStream@^1.0.4: @@ -2286,6 +2308,11 @@ error-ex@^1.2.0, error-ex@^1.3.1: dependencies: is-arrayish "^0.2.1" +esbuild@^0.10.2: + version "0.10.2" + resolved "https://registry.npmjs.org/esbuild/-/esbuild-0.10.2.tgz#caa65a8f3096d547d89159918039df6c5c6c90be" + integrity sha512-/5vsZD7wTJJHC3yNXLUjXNvUDwqwNoIMvFvLd9tcDQ9el5l13pspYm3yufavjIeYvNtAbo+6N/6uoWx9dGA6ug== + esbuild@^0.9.3: version "0.9.4" resolved "https://registry.npmjs.org/esbuild/-/esbuild-0.9.4.tgz#4480ffc4c1e5d5bb25958f889b5de0279bfb2d6f" @@ -2323,10 +2350,10 @@ eslint-config-prettier@^8.1.0: resolved "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.1.0.tgz#4ef1eaf97afe5176e6a75ddfb57c335121abc5a6" integrity sha512-oKMhGv3ihGbCIimCAjqkdzx2Q+jthoqnXSP+d86M9tptwugycmTFdVR4IpLgq2c4SHifbwO90z2fQ8/Aio73yw== -eslint-plugin-jest@^24.3.2: - version "24.3.2" - resolved "https://registry.npmjs.org/eslint-plugin-jest/-/eslint-plugin-jest-24.3.2.tgz#30a8b2dea6278d0da1d6fb9d6cd530aaf58050a1" - integrity sha512-cicWDr+RvTAOKS3Q/k03+Z3odt3VCiWamNUHWd6QWbVQWcYJyYgUTu8x0mx9GfeDEimawU5kQC+nQ3MFxIM6bw== +eslint-plugin-jest@^24.3.3: + version "24.3.3" + resolved "https://registry.npmjs.org/eslint-plugin-jest/-/eslint-plugin-jest-24.3.3.tgz#4e0f9dd6b1667990e7be3a7d7c9a85b952056df9" + integrity sha512-IQ9tLHyKEyBw1BM3IE13WxOXQm03h/7dy1KFknUVkoY2N2+Hw7lb/3YFz/4jwcrxXt2+KhA/GoiK7jt8aK19ww== dependencies: "@typescript-eslint/experimental-utils" "^4.0.1" @@ -2355,10 +2382,10 @@ eslint-visitor-keys@^2.0.0: resolved "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-2.0.0.tgz#21fdc8fbcd9c795cc0321f0563702095751511a8" integrity sha512-QudtT6av5WXels9WjIM7qz1XD1cWGvX4gGXvp/zBn9nXG02D0utdU3Em2m/QjTnrsk6bBjmCygl3rmj118msQQ== -eslint@^7.22.0: - version "7.22.0" - resolved "https://registry.npmjs.org/eslint/-/eslint-7.22.0.tgz#07ecc61052fec63661a2cab6bd507127c07adc6f" - integrity sha512-3VawOtjSJUQiiqac8MQc+w457iGLfuNGLFn8JmF051tTKbh5/x/0vlcEj8OgDCaw7Ysa2Jn8paGshV7x2abKXg== +eslint@^7.23.0: + version "7.23.0" + resolved "https://registry.npmjs.org/eslint/-/eslint-7.23.0.tgz#8d029d252f6e8cf45894b4bee08f5493f8e94325" + integrity sha512-kqvNVbdkjzpFy0XOszNwjkKzZ+6TcwCQ/h+ozlcIWwaimBBuhlQ4nN6kbiM2L+OjDcznkTJxzYfRFH92sx4a0Q== dependencies: "@babel/code-frame" "7.12.11" "@eslint/eslintrc" "^0.4.0" @@ -3172,10 +3199,10 @@ human-signals@^2.1.0: resolved "https://registry.npmjs.org/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" integrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw== -husky@^5.1.3: - version "5.1.3" - resolved "https://registry.npmjs.org/husky/-/husky-5.1.3.tgz#1a0645a4fe3ffc006c4d0d8bd0bcb4c98787cc9d" - integrity sha512-fbNJ+Gz5wx2LIBtMweJNY1D7Uc8p1XERi5KNRMccwfQA+rXlxWNSdUxswo0gT8XqxywTIw7Ywm/F4v/O35RdMg== +husky@^5.2.0: + version "5.2.0" + resolved "https://registry.npmjs.org/husky/-/husky-5.2.0.tgz#fc5e1c2300d34855d47de4753607d00943fc0802" + integrity sha512-AM8T/auHXRBxlrfPVLKP6jt49GCM2Zz47m8G3FOMsLmTv8Dj/fKVWE0Rh2d4Qrvmy131xEsdQnb3OXRib67PGg== iconv-lite@0.4.24, iconv-lite@^0.4.24: version "0.4.24" @@ -5550,7 +5577,14 @@ semver-compare@^1.0.0: resolved "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== -semver@7.3.4, semver@7.x, semver@^7.2.1, semver@^7.3.2: +semver@7.3.5: + version "7.3.5" + resolved "https://registry.npmjs.org/semver/-/semver-7.3.5.tgz#0b621c879348d8998e4b0e4be94b3f12e6018ef7" + integrity sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ== + dependencies: + lru-cache "^6.0.0" + +semver@7.x, semver@^7.2.1, semver@^7.3.2: version "7.3.4" resolved "https://registry.npmjs.org/semver/-/semver-7.3.4.tgz#27aaa7d2e4ca76452f98d3add093a72c943edc97" integrity sha512-tCfb2WLjqFAtXn4KEdxIhalnRtoKFN7nAwj0B3ZXCbQloV2tq5eDbcTmT68JJD3nRJq24/XgxtQKFIpQdtvmVw== @@ -6025,10 +6059,10 @@ svg-baker@1.7.0: query-string "^4.3.2" traverse "^0.6.6" -svgo@^2.2.2: - version "2.2.2" - resolved "https://registry.npmjs.org/svgo/-/svgo-2.2.2.tgz#51d67c7149661282d22a3c8683f4795cdb40f687" - integrity sha512-kJugY2d0yrsONnG4YavppVkKmKULMw2iFRbB9+usyWqzTaqoBuUaqdMnQ2G1n5P1dmOA2tZvc5zmMM6sPOVBSQ== +svgo@^2.3.0: + version "2.3.0" + resolved "https://registry.npmjs.org/svgo/-/svgo-2.3.0.tgz#6b3af81d0cbd1e19c83f5f63cec2cb98c70b5373" + integrity sha512-fz4IKjNO6HDPgIQxu4IxwtubtbSfGEAJUq/IXyTPIkGhWck/faiiwfkvsB8LnBkKLvSoyNNIY6d13lZprJMc9Q== dependencies: "@trysound/sax" "0.1.1" chalk "^4.1.0" @@ -6251,16 +6285,16 @@ tslib@^1.8.1, tslib@^1.9.0: resolved "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== -tsup@^4.8.18: - version "4.8.18" - resolved "https://registry.npmjs.org/tsup/-/tsup-4.8.18.tgz#287fc14e93503f1524a50a561a1e6d86b75dd751" - integrity sha512-GaCqp7u3OrrNdRUbh3opeBSH36vOHy+HRe/DT/2WdHSBcJ8bIFmoLot+N7EFvSMJ6O5Q2LJGI0CeJ28hPCsTwQ== +tsup@^4.8.21: + version "4.8.21" + resolved "https://registry.npmjs.org/tsup/-/tsup-4.8.21.tgz#15c3fc9552b3612f5ac29bc5c875d59e4cc300d8" + integrity sha512-8paK4Q0jvsbZE7v9ptsL1JxUSs83etaml2IrNBOsnTdgrHD/gq9dvxEcWU7rNdyCCh4UhUZ8RlEjRI3etZyfsw== dependencies: cac "^6.7.2" chalk "^4.1.0" chokidar "^3.5.1" debug "^4.3.1" - esbuild "^0.9.3" + esbuild "^0.10.2" execa "^5.0.0" globby "^11.0.2" joycon "^3.0.0" @@ -6440,10 +6474,10 @@ verror@1.10.0: core-util-is "1.0.2" extsprintf "^1.2.0" -vite@^2.1.2: - version "2.1.2" - resolved "https://registry.npmjs.org/vite/-/vite-2.1.2.tgz#0aecaf6d34112b24536df1a14cd8d74fdcab6e20" - integrity sha512-K96k5Nb1kywggFwZNGf/NQVZIrjMSvjebYWFIEQRu8AQWtzxatMF8/reExFXebmrfWAT3PTUk6l4zJBkpMtyVg== +vite@^2.1.5: + version "2.1.5" + resolved "https://registry.npmjs.org/vite/-/vite-2.1.5.tgz#4857da441c62f7982c83cbd5f42a00330f20c9c1" + integrity sha512-tYU5iaYeUgQYvK/CNNz3tiJ8vYqPWfCE9IQ7K0iuzYovWw7lzty7KRYGWwV3CQPh0NKxWjOczAqiJsCL0Xb+Og== dependencies: esbuild "^0.9.3" postcss "^8.2.1"