From 271f0f8c5ed182628635a89310774c3478c9420b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 23 Jul 2023 06:20:35 +0000 Subject: [PATCH 1/5] chore: bump the eslint group in /site with 5 updates Bumps the eslint group in /site with 5 updates: | Package | Update | | --- | --- | | [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) | 5.62.0 to 6.1.0 | | [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) | 5.62.0 to 6.1.0 | | [eslint](https://github.com/eslint/eslint) | 8.44.0 to 8.45.0 | | [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) | 7.31.1 to 7.33.0 | | [eslint-plugin-unicorn](https://github.com/sindresorhus/eslint-plugin-unicorn) | 47.0.0 to 48.0.0 | Updates `@typescript-eslint/eslint-plugin` from 5.62.0 to 6.1.0 - [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases) - [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/CHANGELOG.md) - [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v6.1.0/packages/eslint-plugin) Updates `@typescript-eslint/parser` from 5.62.0 to 6.1.0 - [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases) - [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/parser/CHANGELOG.md) - [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v6.1.0/packages/parser) Updates `eslint` from 8.44.0 to 8.45.0 - [Release notes](https://github.com/eslint/eslint/releases) - [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md) - [Commits](https://github.com/eslint/eslint/compare/v8.44.0...v8.45.0) Updates `eslint-plugin-react` from 7.31.1 to 7.33.0 - [Release notes](https://github.com/jsx-eslint/eslint-plugin-react/releases) - [Changelog](https://github.com/jsx-eslint/eslint-plugin-react/blob/master/CHANGELOG.md) - [Commits](https://github.com/jsx-eslint/eslint-plugin-react/compare/v7.31.1...v7.33.0) Updates `eslint-plugin-unicorn` from 47.0.0 to 48.0.0 - [Release notes](https://github.com/sindresorhus/eslint-plugin-unicorn/releases) - [Commits](https://github.com/sindresorhus/eslint-plugin-unicorn/compare/v47.0.0...v48.0.0) --- updated-dependencies: - dependency-name: "@typescript-eslint/eslint-plugin" dependency-type: direct:development update-type: version-update:semver-major dependency-group: eslint - dependency-name: "@typescript-eslint/parser" dependency-type: direct:development update-type: version-update:semver-major dependency-group: eslint - dependency-name: eslint dependency-type: direct:development update-type: version-update:semver-minor dependency-group: eslint - dependency-name: eslint-plugin-react dependency-type: direct:development update-type: version-update:semver-minor dependency-group: eslint - dependency-name: eslint-plugin-unicorn dependency-type: direct:development update-type: version-update:semver-major dependency-group: eslint ... Signed-off-by: dependabot[bot] --- site/package.json | 10 +- site/yarn.lock | 229 +++++++++++++++++++++++++++++----------------- 2 files changed, 148 insertions(+), 91 deletions(-) diff --git a/site/package.json b/site/package.json index e2f46bf869b69..1b22fa2fd4dd8 100644 --- a/site/package.json +++ b/site/package.json @@ -126,11 +126,11 @@ "@types/react-window": "1.8.5", "@types/ua-parser-js": "0.7.36", "@types/uuid": "9.0.2", - "@typescript-eslint/eslint-plugin": "5.62.0", - "@typescript-eslint/parser": "5.62.0", + "@typescript-eslint/eslint-plugin": "6.1.0", + "@typescript-eslint/parser": "6.1.0", "@xstate/cli": "0.5.2", "chromatic": "6.20.0", - "eslint": "8.44.0", + "eslint": "8.45.0", "eslint-config-prettier": "8.8.0", "eslint-import-resolver-typescript": "3.5.5", "eslint-plugin-compat": "4.1.4", @@ -138,10 +138,10 @@ "eslint-plugin-import": "2.27.5", "eslint-plugin-jest": "27.2.2", "eslint-plugin-jsx-a11y": "6.7.1", - "eslint-plugin-react": "7.31.1", + "eslint-plugin-react": "7.33.0", "eslint-plugin-react-hooks": "4.6.0", "eslint-plugin-storybook": "0.6.12", - "eslint-plugin-unicorn": "47.0.0", + "eslint-plugin-unicorn": "48.0.0", "jest": "29.5.0", "jest-canvas-mock": "2.4.0", "jest-fetch-mock": "3.0.3", diff --git a/site/yarn.lock b/site/yarn.lock index f3732a5a6b830..7d54921d2dc1b 100644 --- a/site/yarn.lock +++ b/site/yarn.lock @@ -453,12 +453,7 @@ resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz#533f36457a25814cf1df6488523ad547d784a99f" integrity sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw== -"@babel/helper-validator-identifier@^7.18.6", "@babel/helper-validator-identifier@^7.19.1": - version "7.19.1" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz#7eea834cf32901ffdc1a7ee555e2f9c27e249ca2" - integrity sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w== - -"@babel/helper-validator-identifier@^7.22.5": +"@babel/helper-validator-identifier@^7.18.6", "@babel/helper-validator-identifier@^7.19.1", "@babel/helper-validator-identifier@^7.22.5": version "7.22.5" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.5.tgz#9544ef6a33999343c8740fa51350f30eeaaaf193" integrity sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ== @@ -1758,10 +1753,10 @@ dependencies: eslint-visitor-keys "^3.3.0" -"@eslint-community/regexpp@^4.4.0": - version "4.5.1" - resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.5.1.tgz#cdd35dce4fa1a89a4fd42b1599eb35b3af408884" - integrity sha512-Z5ba73P98O1KUYCCJTUeVpja9RcGoMdncZ6T49FCUl2lN38JtCJ+3WgIDBv0AuY4WChU5PmtJmOCTlN6FZTFKQ== +"@eslint-community/regexpp@^4.4.0", "@eslint-community/regexpp@^4.5.1": + version "4.6.0" + resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.6.0.tgz#5b63f0df5528a44e28aa8578d393de908cc3d4d0" + integrity sha512-uiPeRISaglZnaZk8vwrjQZ1CxogZeY/4IYft6gBOTqu1WhVXWmCmZMWxUv2Q/pxSvPdp1JPaO62kLOcOkMqWrw== "@eslint/eslintrc@^2.1.0": version "2.1.0" @@ -3676,6 +3671,11 @@ "@types/tough-cookie" "*" parse5 "^7.0.0" +"@types/json-schema@^7.0.12": + version "7.0.12" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.12.tgz#d70faba7039d5fca54c83c7dbab41051d2b6f6cb" + integrity sha512-Hr5Jfhc9eYOQNPYO5WLDq/n4jqijdHNlDXjuAQkkt+mWdQR+XJToOHrsD4cPaMXpn6KO7y2+wM8AZEs8VpBLVA== + "@types/json-schema@^7.0.9": version "7.0.11" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.11.tgz#d421b6c527a3037f7c84433fd2c4229e016863d3" @@ -3875,7 +3875,7 @@ resolved "https://registry.yarnpkg.com/@types/scheduler/-/scheduler-0.16.2.tgz#1a62f89525723dde24ba1b01b092bf5df8ad4d39" integrity sha512-hppQEBDmlwhFAXKJX2KnWLYu5yMfi91yazPb2l+lbJiwW+wdo1gNeRA+3RgNSO39WYX2euey41KEwnqesU2Jew== -"@types/semver@7.5.0": +"@types/semver@7.5.0", "@types/semver@^7.5.0": version "7.5.0" resolved "https://registry.yarnpkg.com/@types/semver/-/semver-7.5.0.tgz#591c1ce3a702c45ee15f47a42ade72c2fd78978a" integrity sha512-G8hZ6XJiHnuhQKR7ZmysCeJWE08o8T0AXtk5darsCaTVsYZhhgUrq53jizaR2FvsoeCwJhlmwTjkXBY5Pn/ZHw== @@ -3956,30 +3956,33 @@ dependencies: "@types/yargs-parser" "*" -"@typescript-eslint/eslint-plugin@5.62.0": - version "5.62.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.62.0.tgz#aeef0328d172b9e37d9bab6dbc13b87ed88977db" - integrity sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag== - dependencies: - "@eslint-community/regexpp" "^4.4.0" - "@typescript-eslint/scope-manager" "5.62.0" - "@typescript-eslint/type-utils" "5.62.0" - "@typescript-eslint/utils" "5.62.0" +"@typescript-eslint/eslint-plugin@6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-6.1.0.tgz#96f3ca6615717659d06c9f7161a1d14ab0c49c66" + integrity sha512-qg7Bm5TyP/I7iilGyp6DRqqkt8na00lI6HbjWZObgk3FFSzH5ypRwAHXJhJkwiRtTcfn+xYQIMOR5kJgpo6upw== + dependencies: + "@eslint-community/regexpp" "^4.5.1" + "@typescript-eslint/scope-manager" "6.1.0" + "@typescript-eslint/type-utils" "6.1.0" + "@typescript-eslint/utils" "6.1.0" + "@typescript-eslint/visitor-keys" "6.1.0" debug "^4.3.4" graphemer "^1.4.0" - ignore "^5.2.0" + ignore "^5.2.4" + natural-compare "^1.4.0" natural-compare-lite "^1.4.0" - semver "^7.3.7" - tsutils "^3.21.0" + semver "^7.5.4" + ts-api-utils "^1.0.1" -"@typescript-eslint/parser@5.62.0": - version "5.62.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.62.0.tgz#1b63d082d849a2fcae8a569248fbe2ee1b8a56c7" - integrity sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA== +"@typescript-eslint/parser@6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-6.1.0.tgz#3135bf65dca5340d8650703eb8cb83113e156ee5" + integrity sha512-hIzCPvX4vDs4qL07SYzyomamcs2/tQYXg5DtdAfj35AyJ5PIUqhsLf4YrEIFzZcND7R2E8tpQIZKayxg8/6Wbw== dependencies: - "@typescript-eslint/scope-manager" "5.62.0" - "@typescript-eslint/types" "5.62.0" - "@typescript-eslint/typescript-estree" "5.62.0" + "@typescript-eslint/scope-manager" "6.1.0" + "@typescript-eslint/types" "6.1.0" + "@typescript-eslint/typescript-estree" "6.1.0" + "@typescript-eslint/visitor-keys" "6.1.0" debug "^4.3.4" "@typescript-eslint/scope-manager@5.62.0": @@ -3990,21 +3993,34 @@ "@typescript-eslint/types" "5.62.0" "@typescript-eslint/visitor-keys" "5.62.0" -"@typescript-eslint/type-utils@5.62.0": - version "5.62.0" - resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-5.62.0.tgz#286f0389c41681376cdad96b309cedd17d70346a" - integrity sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew== +"@typescript-eslint/scope-manager@6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/scope-manager/-/scope-manager-6.1.0.tgz#a6cdbe11630614f8c04867858a42dd56590796ed" + integrity sha512-AxjgxDn27hgPpe2rQe19k0tXw84YCOsjDJ2r61cIebq1t+AIxbgiXKvD4999Wk49GVaAcdJ/d49FYel+Pp3jjw== dependencies: - "@typescript-eslint/typescript-estree" "5.62.0" - "@typescript-eslint/utils" "5.62.0" + "@typescript-eslint/types" "6.1.0" + "@typescript-eslint/visitor-keys" "6.1.0" + +"@typescript-eslint/type-utils@6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/type-utils/-/type-utils-6.1.0.tgz#21cc6c3bc1980b03f9eb4e64580d0c5be6f08215" + integrity sha512-kFXBx6QWS1ZZ5Ni89TyT1X9Ag6RXVIVhqDs0vZE/jUeWlBv/ixq2diua6G7ece6+fXw3TvNRxP77/5mOMusx2w== + dependencies: + "@typescript-eslint/typescript-estree" "6.1.0" + "@typescript-eslint/utils" "6.1.0" debug "^4.3.4" - tsutils "^3.21.0" + ts-api-utils "^1.0.1" "@typescript-eslint/types@5.62.0": version "5.62.0" resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-5.62.0.tgz#258607e60effa309f067608931c3df6fed41fd2f" integrity sha512-87NVngcbVXUahrRTqIK27gD2t5Cu1yuCXxbLcFtCzZGlfyVWWh8mLHkoxzjsB6DDNnvdL+fW8MiwPEJyGJQDgQ== +"@typescript-eslint/types@6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/types/-/types-6.1.0.tgz#2d607c62827bb416ada5c96ebfa2ef84e45a8dfa" + integrity sha512-+Gfd5NHCpDoHDOaU/yIF3WWRI2PcBRKKpP91ZcVbL0t5tQpqYWBs3z/GGhvU+EV1D0262g9XCnyqQh19prU0JQ== + "@typescript-eslint/typescript-estree@5.62.0": version "5.62.0" resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-5.62.0.tgz#7d17794b77fabcac615d6a48fb143330d962eb9b" @@ -4018,7 +4034,33 @@ semver "^7.3.7" tsutils "^3.21.0" -"@typescript-eslint/utils@5.62.0", "@typescript-eslint/utils@^5.10.0", "@typescript-eslint/utils@^5.45.0", "@typescript-eslint/utils@^5.58.0": +"@typescript-eslint/typescript-estree@6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-6.1.0.tgz#ea382f6482ba698d7e993a88ce5391ea7a66c33d" + integrity sha512-nUKAPWOaP/tQjU1IQw9sOPCDavs/iU5iYLiY/6u7gxS7oKQoi4aUxXS1nrrVGTyBBaGesjkcwwHkbkiD5eBvcg== + dependencies: + "@typescript-eslint/types" "6.1.0" + "@typescript-eslint/visitor-keys" "6.1.0" + debug "^4.3.4" + globby "^11.1.0" + is-glob "^4.0.3" + semver "^7.5.4" + ts-api-utils "^1.0.1" + +"@typescript-eslint/utils@6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-6.1.0.tgz#1641843792b4e3451cc692e2c73055df8b26f453" + integrity sha512-wp652EogZlKmQoMS5hAvWqRKplXvkuOnNzZSE0PVvsKjpexd/XznRVHAtrfHFYmqaJz0DFkjlDsGYC9OXw+OhQ== + dependencies: + "@eslint-community/eslint-utils" "^4.4.0" + "@types/json-schema" "^7.0.12" + "@types/semver" "^7.5.0" + "@typescript-eslint/scope-manager" "6.1.0" + "@typescript-eslint/types" "6.1.0" + "@typescript-eslint/typescript-estree" "6.1.0" + semver "^7.5.4" + +"@typescript-eslint/utils@^5.10.0", "@typescript-eslint/utils@^5.45.0", "@typescript-eslint/utils@^5.58.0": version "5.62.0" resolved "https://registry.yarnpkg.com/@typescript-eslint/utils/-/utils-5.62.0.tgz#141e809c71636e4a75daa39faed2fb5f4b10df86" integrity sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ== @@ -4040,6 +4082,14 @@ "@typescript-eslint/types" "5.62.0" eslint-visitor-keys "^3.3.0" +"@typescript-eslint/visitor-keys@6.1.0": + version "6.1.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/visitor-keys/-/visitor-keys-6.1.0.tgz#d2b84dff6b58944d3257ea03687e269a788c73be" + integrity sha512-yQeh+EXhquh119Eis4k0kYhj9vmFzNpbhM3LftWQVwqVjipCkwHBQOZutcYW+JVkjtTG9k8nrZU1UoNedPDd1A== + dependencies: + "@typescript-eslint/types" "6.1.0" + eslint-visitor-keys "^3.4.1" + "@vitejs/plugin-react@4.0.1": version "4.0.1" resolved "https://registry.yarnpkg.com/@vitejs/plugin-react/-/plugin-react-4.0.1.tgz#793aa790633433558da7ac0a38c58ddf47dff518" @@ -4359,7 +4409,7 @@ array.prototype.flat@^1.3.1: es-abstract "^1.20.4" es-shim-unscopables "^1.0.0" -array.prototype.flatmap@^1.3.0, array.prototype.flatmap@^1.3.1: +array.prototype.flatmap@^1.3.1: version "1.3.1" resolved "https://registry.yarnpkg.com/array.prototype.flatmap/-/array.prototype.flatmap-1.3.1.tgz#1aae7903c2100433cb8261cd4ed310aab5c4a183" integrity sha512-8UGn9O1FDVvMNB0UlLv4voxRMze7+FpHyF5mSMRjWHUMlpoDViniy05870VlxhfgTnLbpuwTzvD76MTtWxB/mQ== @@ -4369,6 +4419,17 @@ array.prototype.flatmap@^1.3.0, array.prototype.flatmap@^1.3.1: es-abstract "^1.20.4" es-shim-unscopables "^1.0.0" +array.prototype.tosorted@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/array.prototype.tosorted/-/array.prototype.tosorted-1.1.1.tgz#ccf44738aa2b5ac56578ffda97c03fd3e23dd532" + integrity sha512-pZYPXPRl2PqWcsUs6LOMn+1f1532nEoPTYowBtqLwAW+W8vSVhkIGnmOX1t/UQjD6YGI0vcD2B1U7ZFGQH9jnQ== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + es-shim-unscopables "^1.0.0" + get-intrinsic "^1.1.3" + assert@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/assert/-/assert-2.0.0.tgz#95fc1c616d48713510680f2eaf2d10dd22e02d32" @@ -5987,25 +6048,26 @@ eslint-plugin-react-hooks@4.6.0: resolved "https://registry.yarnpkg.com/eslint-plugin-react-hooks/-/eslint-plugin-react-hooks-4.6.0.tgz#4c3e697ad95b77e93f8646aaa1630c1ba607edd3" integrity sha512-oFc7Itz9Qxh2x4gNHStv3BqJq54ExXmfC+a1NjAta66IAN87Wu0R/QArgIS9qKzX3dXKPI9H5crl9QchNMY9+g== -eslint-plugin-react@7.31.1: - version "7.31.1" - resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.31.1.tgz#d29793ed27743f3ed8a473c347b1bf5a0a8fb9af" - integrity sha512-j4/2xWqt/R7AZzG8CakGHA6Xa/u7iR8Q3xCxY+AUghdT92bnIDOBEefV456OeH0QvBcroVc0eyvrrLSyQGYIfg== +eslint-plugin-react@7.33.0: + version "7.33.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.33.0.tgz#6c356fb0862fec2cd1b04426c669ea746e9b6eb3" + integrity sha512-qewL/8P34WkY8jAqdQxsiL82pDUeT7nhs8IsuXgfgnsEloKCT4miAV9N9kGtx7/KM9NH/NCGUE7Edt9iGxLXFw== dependencies: - array-includes "^3.1.5" - array.prototype.flatmap "^1.3.0" + array-includes "^3.1.6" + array.prototype.flatmap "^1.3.1" + array.prototype.tosorted "^1.1.1" doctrine "^2.1.0" estraverse "^5.3.0" jsx-ast-utils "^2.4.1 || ^3.0.0" minimatch "^3.1.2" - object.entries "^1.1.5" - object.fromentries "^2.0.5" - object.hasown "^1.1.1" - object.values "^1.1.5" + object.entries "^1.1.6" + object.fromentries "^2.0.6" + object.hasown "^1.1.2" + object.values "^1.1.6" prop-types "^15.8.1" - resolve "^2.0.0-next.3" - semver "^6.3.0" - string.prototype.matchall "^4.0.7" + resolve "^2.0.0-next.4" + semver "^6.3.1" + string.prototype.matchall "^4.0.8" eslint-plugin-storybook@0.6.12: version "0.6.12" @@ -6024,12 +6086,12 @@ eslint-plugin-testing-library@5.11.0: dependencies: "@typescript-eslint/utils" "^5.58.0" -eslint-plugin-unicorn@47.0.0: - version "47.0.0" - resolved "https://registry.yarnpkg.com/eslint-plugin-unicorn/-/eslint-plugin-unicorn-47.0.0.tgz#960e9d3789f656ba3e21982420793b069a911011" - integrity sha512-ivB3bKk7fDIeWOUmmMm9o3Ax9zbMz1Bsza/R2qm46ufw4T6VBFBaJIR1uN3pCKSmSXm8/9Nri8V+iUut1NhQGA== +eslint-plugin-unicorn@48.0.0: + version "48.0.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-unicorn/-/eslint-plugin-unicorn-48.0.0.tgz#074214c0c216e6d97298a98db394b430b6c5a7de" + integrity sha512-8fk/v3p1ro34JSVDBEmtOq6EEQRpMR0iTir79q69KnXFZ6DJyPkT3RAi+ZoTqhQMdDSpGh8BGR68ne1sP5cnAA== dependencies: - "@babel/helper-validator-identifier" "^7.19.1" + "@babel/helper-validator-identifier" "^7.22.5" "@eslint-community/eslint-utils" "^4.4.0" ci-info "^3.8.0" clean-regexp "^1.0.0" @@ -6040,10 +6102,9 @@ eslint-plugin-unicorn@47.0.0: lodash "^4.17.21" pluralize "^8.0.0" read-pkg-up "^7.0.1" - regexp-tree "^0.1.24" + regexp-tree "^0.1.27" regjsparser "^0.10.0" - safe-regex "^2.1.1" - semver "^7.3.8" + semver "^7.5.4" strip-indent "^3.0.0" eslint-scope@^5.1.1: @@ -6067,10 +6128,10 @@ eslint-visitor-keys@^3.3.0, eslint-visitor-keys@^3.4.1: resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.4.1.tgz#c22c48f48942d08ca824cc526211ae400478a994" integrity sha512-pZnmmLwYzf+kWaM/Qgrvpen51upAktaaiI01nsJD/Yr3lMOdNtq0cxkrrg16w64VtisN6okbs7Q8AfGqj4c9fA== -eslint@8.44.0: - version "8.44.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.44.0.tgz#51246e3889b259bbcd1d7d736a0c10add4f0e500" - integrity sha512-0wpHoUbDUHgNCyvFB5aXLiQVfK9B0at6gUvzy83k4kAsQ/u769TQDX6iKC+aO4upIHO9WSaA3QoXYQDHbNwf1A== +eslint@8.45.0: + version "8.45.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.45.0.tgz#bab660f90d18e1364352c0a6b7c6db8edb458b78" + integrity sha512-pd8KSxiQpdYRfYa9Wufvdoct3ZPQQuVuU5O6scNgMuOMYuxvH0IGaYK0wUFjo4UYYQQCUndlXiMbnxopwvvTiw== dependencies: "@eslint-community/eslint-utils" "^4.2.0" "@eslint-community/regexpp" "^4.4.0" @@ -6097,7 +6158,6 @@ eslint@8.44.0: globals "^13.19.0" graphemer "^1.4.0" ignore "^5.2.0" - import-fresh "^3.0.0" imurmurhash "^0.1.4" is-glob "^4.0.0" is-path-inside "^3.0.3" @@ -6109,7 +6169,6 @@ eslint@8.44.0: natural-compare "^1.4.0" optionator "^0.9.3" strip-ansi "^6.0.1" - strip-json-comments "^3.1.0" text-table "^0.2.0" espree@^9.6.0: @@ -7048,7 +7107,7 @@ ignore@^5.0.5, ignore@^5.2.0, ignore@^5.2.4: resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.2.4.tgz#a291c0c6178ff1b960befe47fcdec301674a6324" integrity sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ== -import-fresh@^3.0.0, import-fresh@^3.2.1: +import-fresh@^3.2.1: version "3.3.0" resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== @@ -9281,7 +9340,7 @@ object.assign@^4.1.3, object.assign@^4.1.4: has-symbols "^1.0.3" object-keys "^1.1.1" -object.entries@^1.1.5, object.entries@^1.1.6: +object.entries@^1.1.6: version "1.1.6" resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.1.6.tgz#9737d0e5b8291edd340a3e3264bb8a3b00d5fa23" integrity sha512-leTPzo4Zvg3pmbQ3rDK69Rl8GQvIqMWubrkxONG9/ojtFE2rD9fjMKfSI5BxW3osRH1m6VdzmqK8oAY9aT4x5w== @@ -9290,7 +9349,7 @@ object.entries@^1.1.5, object.entries@^1.1.6: define-properties "^1.1.4" es-abstract "^1.20.4" -object.fromentries@^2.0.5, object.fromentries@^2.0.6: +object.fromentries@^2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/object.fromentries/-/object.fromentries-2.0.6.tgz#cdb04da08c539cffa912dcd368b886e0904bfa73" integrity sha512-VciD13dswC4j1Xt5394WR4MzmAQmlgN72phd/riNp9vtD7tp4QQWJ0R4wvclXcafgcYK8veHRed2W6XeGBvcfg== @@ -9299,7 +9358,7 @@ object.fromentries@^2.0.5, object.fromentries@^2.0.6: define-properties "^1.1.4" es-abstract "^1.20.4" -object.hasown@^1.1.1: +object.hasown@^1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/object.hasown/-/object.hasown-1.1.2.tgz#f919e21fad4eb38a57bc6345b3afd496515c3f92" integrity sha512-B5UIT3J1W+WuWIU55h0mjlwaqxiE5vYENJXIXZ4VFe05pNYrkKuK0U/6aFcb0pKywYJh7IhfoqUfKVmrJJHZHw== @@ -9307,7 +9366,7 @@ object.hasown@^1.1.1: define-properties "^1.1.4" es-abstract "^1.20.4" -object.values@^1.1.5, object.values@^1.1.6: +object.values@^1.1.6: version "1.1.6" resolved "https://registry.yarnpkg.com/object.values/-/object.values-1.1.6.tgz#4abbaa71eba47d63589d402856f908243eea9b1d" integrity sha512-FVVTkD1vENCsAcwNs9k6jea2uHC/X0+JcjG8YA60FN5CMaJmG95wT9jek/xX9nornqGRrBkKtzuAu2wuHpKqvw== @@ -10227,10 +10286,10 @@ regenerator-transform@^0.15.1: dependencies: "@babel/runtime" "^7.8.4" -regexp-tree@^0.1.24, regexp-tree@~0.1.1: - version "0.1.24" - resolved "https://registry.yarnpkg.com/regexp-tree/-/regexp-tree-0.1.24.tgz#3d6fa238450a4d66e5bc9c4c14bb720e2196829d" - integrity sha512-s2aEVuLhvnVJW6s/iPgEGK6R+/xngd2jNQ+xy4bXNDKxZKJH6jpPHY6kVeVv1IeLCHgswRj+Kl3ELaDjG6V1iw== +regexp-tree@^0.1.27: + version "0.1.27" + resolved "https://registry.yarnpkg.com/regexp-tree/-/regexp-tree-0.1.27.tgz#2198f0ef54518ffa743fe74d983b56ffd631b6cd" + integrity sha512-iETxpjK6YoRWJG5o6hXLwvjYAoW+FEZn9os0PD/b6AP6xQwsa/Y7lCVgIixBbUPMfhu+i2LtdeAqVTgGlQarfA== regexp.prototype.flags@^1.4.3: version "1.4.3" @@ -10377,7 +10436,7 @@ resolve@^1.10.0, resolve@^1.14.2, resolve@^1.17.0, resolve@^1.19.0, resolve@^1.2 path-parse "^1.0.7" supports-preserve-symlinks-flag "^1.0.0" -resolve@^2.0.0-next.3: +resolve@^2.0.0-next.4: version "2.0.0-next.4" resolved "https://registry.yarnpkg.com/resolve/-/resolve-2.0.0-next.4.tgz#3d37a113d6429f496ec4752d2a2e58efb1fd4660" integrity sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ== @@ -10494,13 +10553,6 @@ safe-regex-test@^1.0.0: get-intrinsic "^1.1.3" is-regex "^1.1.4" -safe-regex@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/safe-regex/-/safe-regex-2.1.1.tgz#f7128f00d056e2fe5c11e81a1324dd974aadced2" - integrity sha512-rx+x8AMzKb5Q5lQ95Zoi6ZbJqwCLkqi3XuJXp5P3rT8OEc6sZCJG5AE5dU3lsgRr/F4Bs31jSlVN+j5KrsGu9A== - dependencies: - regexp-tree "~0.1.1" - "safer-buffer@>= 2.1.2 < 3", "safer-buffer@>= 2.1.2 < 3.0.0": version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" @@ -10525,7 +10577,7 @@ screenfull@^5.1.0: resolved "https://registry.yarnpkg.com/screenfull/-/screenfull-5.2.0.tgz#6533d524d30621fc1283b9692146f3f13a93d1ba" integrity sha512-9BakfsO2aUQN2K9Fdbj87RJIEZ82Q9IGim7FqM5OsebfoFC6ZHXgDq/KvniuLTPdeM8wY2o6Dj3WQ7KeQCj3cA== -"semver@2 || 3 || 4 || 5", semver@7.3.8, semver@7.5.3, semver@^5.6.0, semver@^6.0.0, semver@^6.3.0, semver@^6.3.1, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7, semver@^7.3.8, semver@^7.5.0, semver@~7.0.0: +"semver@2 || 3 || 4 || 5", semver@7.3.8, semver@7.5.3, semver@^5.6.0, semver@^6.0.0, semver@^6.3.0, semver@^6.3.1, semver@^7.3.4, semver@^7.3.5, semver@^7.3.7, semver@^7.5.0, semver@^7.5.4, semver@~7.0.0: version "7.5.3" resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.3.tgz#161ce8c2c6b4b3bdca6caadc9fa3317a4c4fe88e" integrity sha512-QBlUtyVk/5EeHbi7X0fw6liDZc7BBmEaSYn01fMU1OUYbf6GPsbTtd8WmnqbI20SeycoHSeiybkE/q1Q+qlThQ== @@ -10889,7 +10941,7 @@ string-width@^5.0.1, string-width@^5.1.2: emoji-regex "^9.2.2" strip-ansi "^7.0.1" -string.prototype.matchall@^4.0.7: +string.prototype.matchall@^4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/string.prototype.matchall/-/string.prototype.matchall-4.0.8.tgz#3bf85722021816dcd1bf38bb714915887ca79fd3" integrity sha512-6zOCOcJ+RJAQshcTvXPHoxoQGONa3e/Lqx90wUA+wEzX78sg5Bo+1tQo4N0pohS0erG9qtCqJDjNCQBjeWVxyg== @@ -10971,7 +11023,7 @@ strip-indent@^3.0.0: dependencies: min-indent "^1.0.0" -strip-json-comments@^3.0.1, strip-json-comments@^3.1.0, strip-json-comments@^3.1.1: +strip-json-comments@^3.0.1, strip-json-comments@^3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== @@ -11265,6 +11317,11 @@ trough@^2.0.0: resolved "https://registry.yarnpkg.com/true-myth/-/true-myth-4.1.1.tgz#ff4ac9d5130276e34aa338757e2416ec19248ba2" integrity sha512-rqy30BSpxPznbbTcAcci90oZ1YR4DqvKcNXNerG5gQBU2v4jk0cygheiul5J6ExIMrgDVuanv/MkGfqZbKrNNg== +ts-api-utils@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/ts-api-utils/-/ts-api-utils-1.0.1.tgz#8144e811d44c749cd65b2da305a032510774452d" + integrity sha512-lC/RGlPmwdrIBFTX59wwNzqh7aR2otPNPR/5brHZm/XKFYKsfqxihXUe9pU3JI+3vGkl+vyCoNNnPhJn3aLK1A== + ts-dedent@^2.0.0, ts-dedent@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/ts-dedent/-/ts-dedent-2.2.0.tgz#39e4bd297cd036292ae2394eb3412be63f563bb5" From 55857f920474934ed3360b10e71c8db973d0c0a0 Mon Sep 17 00:00:00 2001 From: Atif Ali Date: Mon, 24 Jul 2023 10:12:55 +0000 Subject: [PATCH 2/5] ignore no-redundant-type-constituents --- site/.eslintrc.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/site/.eslintrc.yaml b/site/.eslintrc.yaml index f7eb30901c5a0..79e458f44fbfc 100644 --- a/site/.eslintrc.yaml +++ b/site/.eslintrc.yaml @@ -75,6 +75,8 @@ rules: "@typescript-eslint/restrict-template-expressions": "off" # TODO: Investigate whether to enable this rule & fix and/or disable all its complaints "@typescript-eslint/unbound-method": "off" + # TODO: Investigate whether to enable this rule & fix and/or disable all its complaints + "@typescript-eslint/no-redundant-type-constituents": "off" # We're disabling the `no-namespace` rule to use a pattern of defining an interface, # and then defining functions that operate on that data via namespace. This is helpful for # dealing with immutable objects. This is a common pattern that shows up in some other From 0c1f210c0b7ba891c4d38b597961080beb2f0651 Mon Sep 17 00:00:00 2001 From: BrunoQuaresma Date: Thu, 27 Jul 2023 13:34:27 +0000 Subject: [PATCH 3/5] Fix minor lint errors --- site/src/components/AuditLogRow/AuditLogDiff/AuditLogDiff.tsx | 2 +- site/src/components/Icons/VSCodeIcon.tsx | 2 +- site/src/components/Icons/VSCodeInsidersIcon.tsx | 2 +- site/src/components/LicenseBanner/LicenseBannerView.tsx | 2 +- site/src/components/ServiceBanner/ServiceBannerView.tsx | 2 +- site/src/contexts/useProxyLatency.ts | 4 ++-- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/site/src/components/AuditLogRow/AuditLogDiff/AuditLogDiff.tsx b/site/src/components/AuditLogRow/AuditLogDiff/AuditLogDiff.tsx index 4ebeffcaf9bf6..6cb1c44cd53b8 100644 --- a/site/src/components/AuditLogRow/AuditLogDiff/AuditLogDiff.tsx +++ b/site/src/components/AuditLogRow/AuditLogDiff/AuditLogDiff.tsx @@ -19,7 +19,7 @@ const getDiffValue = (value: unknown): string => { return "null" } - return value.toString() + return String(value) } export const AuditLogDiff: FC<{ diff: AuditLog["diff"] }> = ({ diff }) => { diff --git a/site/src/components/Icons/VSCodeIcon.tsx b/site/src/components/Icons/VSCodeIcon.tsx index 29cd70a41494a..cb7200ca68523 100644 --- a/site/src/components/Icons/VSCodeIcon.tsx +++ b/site/src/components/Icons/VSCodeIcon.tsx @@ -5,7 +5,7 @@ export const VSCodeIcon = (props: SvgIconProps) => ( ( > = ({
    {messages.map((message) => ( -
  • +
  • {message}
  • ))} diff --git a/site/src/components/ServiceBanner/ServiceBannerView.tsx b/site/src/components/ServiceBanner/ServiceBannerView.tsx index 988085972a791..f452b796d8953 100644 --- a/site/src/components/ServiceBanner/ServiceBannerView.tsx +++ b/site/src/components/ServiceBanner/ServiceBannerView.tsx @@ -31,7 +31,7 @@ export const ServiceBannerView: React.FC = ({ ] return (
    {preview && } diff --git a/site/src/contexts/useProxyLatency.ts b/site/src/contexts/useProxyLatency.ts index 5c5934acb4851..8c6e28f235fb0 100644 --- a/site/src/contexts/useProxyLatency.ts +++ b/site/src/contexts/useProxyLatency.ts @@ -135,7 +135,7 @@ export const useProxyLatency = ( // dispatchProxyLatenciesGuarded will assign the latency to the proxy // via the reducer. But it will only do so if the performance entry is // a resource entry that we care about. - const dispatchProxyLatenciesGuarded = (entry: PerformanceEntry): void => { + const dispatchProxyLatenciesGuarded = (entry: PerformanceEntry) => { if (entry.entryType !== "resource") { // We should never get these, but just in case. return @@ -208,7 +208,7 @@ export const useProxyLatency = ( }) // When all the proxy requests finish - Promise.all(proxyRequests) + void Promise.all(proxyRequests) // TODO: If there is an error on any request, we might want to store some indicator of that? .finally(() => { // takeRecords will return any entries that were not called via the callback yet. From 7a6c6453470148e0cde2003cc056a4bbc246eefd Mon Sep 17 00:00:00 2001 From: Muhammad Atif Ali Date: Thu, 27 Jul 2023 16:40:40 +0300 Subject: [PATCH 4/5] Discard changes to site/.eslintrc.yaml --- site/.eslintrc.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/site/.eslintrc.yaml b/site/.eslintrc.yaml index 79e458f44fbfc..f7eb30901c5a0 100644 --- a/site/.eslintrc.yaml +++ b/site/.eslintrc.yaml @@ -75,8 +75,6 @@ rules: "@typescript-eslint/restrict-template-expressions": "off" # TODO: Investigate whether to enable this rule & fix and/or disable all its complaints "@typescript-eslint/unbound-method": "off" - # TODO: Investigate whether to enable this rule & fix and/or disable all its complaints - "@typescript-eslint/no-redundant-type-constituents": "off" # We're disabling the `no-namespace` rule to use a pattern of defining an interface, # and then defining functions that operate on that data via namespace. This is helpful for # dealing with immutable objects. This is a common pattern that shows up in some other From d753f0e32f4d949b2323701ebe2fd2a59fd06c7c Mon Sep 17 00:00:00 2001 From: BrunoQuaresma Date: Thu, 27 Jul 2023 13:45:43 +0000 Subject: [PATCH 5/5] Fix redudant types --- site/.eslintrc.yaml | 2 -- site/src/api/errors.ts | 10 +++------- site/src/components/DeploySettingsLayout/Option.tsx | 6 ++---- .../components/DeploySettingsLayout/Options.test.tsx | 2 +- .../components/DeploySettingsLayout/OptionsTable.tsx | 4 +--- .../SettingsAccountForm/SettingsAccountForm.tsx | 2 +- site/src/components/Workspace/Workspace.tsx | 2 +- .../components/WorkspacesTable/WorkspacesTable.tsx | 2 +- .../WorkspacesTable/WorkspacesTableBody.tsx | 2 +- site/src/contexts/ProxyContext.tsx | 2 +- site/src/pages/AuditPage/AuditPageView.tsx | 2 +- site/src/pages/CreateTokenPage/CreateTokenForm.tsx | 4 ++-- site/src/pages/CreateTokenPage/CreateTokenPage.tsx | 2 +- site/src/pages/GroupsPage/CreateGroupPageView.tsx | 2 +- .../UserSettingsPage/SSHKeysPage/SSHKeysPageView.tsx | 4 ++-- .../UserSettingsPage/TokensPage/TokensPageView.tsx | 4 ++-- .../WorkspaceProxyPage/WorkspaceProxyView.tsx | 4 ++-- site/src/xServices/appearance/appearanceXService.ts | 4 ++-- site/src/xServices/auth/authMethodsXService.ts | 2 +- site/src/xServices/auth/authXService.ts | 4 ++-- site/src/xServices/buildInfo/buildInfoXService.ts | 2 +- .../createWorkspace/createWorkspaceXService.ts | 2 +- .../xServices/entitlements/entitlementsXService.ts | 2 +- site/src/xServices/experiments/experimentsMachine.ts | 2 +- site/src/xServices/quotas/quotasXService.ts | 2 +- site/src/xServices/roles/siteRolesXService.ts | 2 +- .../xServices/template/templateVariablesXService.ts | 4 ++-- .../templateVersion/templateVersionXService.ts | 2 +- site/src/xServices/templates/templatesXService.ts | 2 +- site/src/xServices/terminal/terminalXService.ts | 8 ++++---- .../src/xServices/updateCheck/updateCheckXService.ts | 2 +- site/src/xServices/users/usersXService.ts | 12 ++++++------ site/src/xServices/workspace/workspaceXService.ts | 8 ++++---- .../workspaceBuild/workspaceBuildXService.ts | 2 +- .../workspaceSchedule/workspaceScheduleXService.ts | 8 ++++---- 35 files changed, 58 insertions(+), 68 deletions(-) diff --git a/site/.eslintrc.yaml b/site/.eslintrc.yaml index 79e458f44fbfc..f7eb30901c5a0 100644 --- a/site/.eslintrc.yaml +++ b/site/.eslintrc.yaml @@ -75,8 +75,6 @@ rules: "@typescript-eslint/restrict-template-expressions": "off" # TODO: Investigate whether to enable this rule & fix and/or disable all its complaints "@typescript-eslint/unbound-method": "off" - # TODO: Investigate whether to enable this rule & fix and/or disable all its complaints - "@typescript-eslint/no-redundant-type-constituents": "off" # We're disabling the `no-namespace` rule to use a pattern of defining an interface, # and then defining functions that operate on that data via namespace. This is helpful for # dealing with immutable objects. This is a common pattern that shows up in some other diff --git a/site/src/api/errors.ts b/site/src/api/errors.ts index 3a39cd0dcfc1d..33e06ae686231 100644 --- a/site/src/api/errors.ts +++ b/site/src/api/errors.ts @@ -59,7 +59,7 @@ export const mapApiErrorToFieldErrors = ( * @returns error's message if ApiError or Error, else defaultMessage */ export const getErrorMessage = ( - error: Error | ApiError | unknown, + error: unknown, defaultMessage: string, ): string => isApiError(error) @@ -74,9 +74,7 @@ export const getErrorMessage = ( * @returns a combined validation error message if the error is an ApiError * and contains validation messages for different form fields. */ -export const getValidationErrorMessage = ( - error: Error | ApiError | unknown, -): string => { +export const getValidationErrorMessage = (error: unknown): string => { const validationErrors = isApiError(error) && error.response.data.validations ? error.response.data.validations @@ -84,9 +82,7 @@ export const getValidationErrorMessage = ( return validationErrors.map((error) => error.detail).join("\n") } -export const getErrorDetail = ( - error: Error | ApiError | unknown, -): string | undefined | null => +export const getErrorDetail = (error: unknown): string | undefined | null => isApiError(error) ? error.response.data.detail : error instanceof Error diff --git a/site/src/components/DeploySettingsLayout/Option.tsx b/site/src/components/DeploySettingsLayout/Option.tsx index f4d5b10c0ee6c..49b680b55e98a 100644 --- a/site/src/components/DeploySettingsLayout/Option.tsx +++ b/site/src/components/DeploySettingsLayout/Option.tsx @@ -1,5 +1,5 @@ import { makeStyles } from "@mui/styles" -import { PropsWithChildren, FC, ReactNode } from "react" +import { PropsWithChildren, FC } from "react" import { MONOSPACE_FONT_FAMILY } from "theme/constants" import { DisabledBadge, EnabledBadge } from "./Badges" @@ -19,9 +19,7 @@ const NotSet: FC = () => { return Not set } -export const OptionValue: FC<{ children?: ReactNode | unknown }> = ({ - children, -}) => { +export const OptionValue: FC<{ children?: unknown }> = ({ children }) => { const styles = useStyles() if (typeof children === "boolean") { diff --git a/site/src/components/DeploySettingsLayout/Options.test.tsx b/site/src/components/DeploySettingsLayout/Options.test.tsx index 9842778510eb4..57bf5da8abeb4 100644 --- a/site/src/components/DeploySettingsLayout/Options.test.tsx +++ b/site/src/components/DeploySettingsLayout/Options.test.tsx @@ -13,7 +13,7 @@ const defaultOption: DeploymentOption = { describe("optionValue", () => { it.each<{ option: DeploymentOption - expected: string | string[] | unknown + expected: unknown }>([ { option: { diff --git a/site/src/components/DeploySettingsLayout/OptionsTable.tsx b/site/src/components/DeploySettingsLayout/OptionsTable.tsx index 75d165dd46429..b573d41b5505b 100644 --- a/site/src/components/DeploySettingsLayout/OptionsTable.tsx +++ b/site/src/components/DeploySettingsLayout/OptionsTable.tsx @@ -62,9 +62,7 @@ const OptionsTable: FC<{ } // optionValue is a helper function to format the value of a specific deployment options -export function optionValue( - option: DeploymentOption, -): string[] | string | unknown { +export function optionValue(option: DeploymentOption) { switch (option.name) { case "Max Token Lifetime": case "Session Duration": diff --git a/site/src/components/SettingsAccountForm/SettingsAccountForm.tsx b/site/src/components/SettingsAccountForm/SettingsAccountForm.tsx index 0141146e8f84b..98feab9cbd171 100644 --- a/site/src/components/SettingsAccountForm/SettingsAccountForm.tsx +++ b/site/src/components/SettingsAccountForm/SettingsAccountForm.tsx @@ -31,7 +31,7 @@ export interface AccountFormProps { isLoading: boolean initialValues: AccountFormValues onSubmit: (values: AccountFormValues) => void - updateProfileError?: Error | unknown + updateProfileError?: unknown // initialTouched is only used for testing the error state of the form. initialTouched?: FormikTouched } diff --git a/site/src/components/Workspace/Workspace.tsx b/site/src/components/Workspace/Workspace.tsx index 6b2f97848f29a..364bb50643bba 100644 --- a/site/src/components/Workspace/Workspace.tsx +++ b/site/src/components/Workspace/Workspace.tsx @@ -64,7 +64,7 @@ export interface WorkspaceProps { canChangeVersions: boolean hideSSHButton?: boolean hideVSCodeDesktopButton?: boolean - workspaceErrors: Partial> + workspaceErrors: Partial> buildInfo?: TypesGen.BuildInfoResponse sshPrefix?: string template?: TypesGen.Template diff --git a/site/src/components/WorkspacesTable/WorkspacesTable.tsx b/site/src/components/WorkspacesTable/WorkspacesTable.tsx index 71c31312f8df4..ece33930fef64 100644 --- a/site/src/components/WorkspacesTable/WorkspacesTable.tsx +++ b/site/src/components/WorkspacesTable/WorkspacesTable.tsx @@ -19,7 +19,7 @@ export interface WorkspacesTableProps { workspaces?: Workspace[] isUsingFilter: boolean onUpdateWorkspace: (workspace: Workspace) => void - error?: Error | unknown + error?: unknown } export const WorkspacesTable: FC = ({ diff --git a/site/src/components/WorkspacesTable/WorkspacesTableBody.tsx b/site/src/components/WorkspacesTable/WorkspacesTableBody.tsx index 3125105493ddd..c610570ae02c8 100644 --- a/site/src/components/WorkspacesTable/WorkspacesTableBody.tsx +++ b/site/src/components/WorkspacesTable/WorkspacesTableBody.tsx @@ -14,7 +14,7 @@ interface TableBodyProps { workspaces?: Workspace[] isUsingFilter: boolean onUpdateWorkspace: (workspace: Workspace) => void - error?: Error | unknown + error?: unknown } export const WorkspacesTableBody: FC< diff --git a/site/src/contexts/ProxyContext.tsx b/site/src/contexts/ProxyContext.tsx index 54a915934dca8..152b0fbd0c997 100644 --- a/site/src/contexts/ProxyContext.tsx +++ b/site/src/contexts/ProxyContext.tsx @@ -46,7 +46,7 @@ export interface ProxyContextValue { // isFetched is true when the 'proxies' api call is complete. isFetched: boolean isLoading: boolean - error?: Error | unknown + error?: unknown // proxyLatencies is a map of proxy id to latency report. If the proxyLatencies[proxy.id] is undefined // then the latency has not been fetched yet. Calculations happen async for each proxy in the list. // Refer to the returned report for a given proxy for more information. diff --git a/site/src/pages/AuditPage/AuditPageView.tsx b/site/src/pages/AuditPage/AuditPageView.tsx index 8aada9516c9ba..e011a8dc8e7dd 100644 --- a/site/src/pages/AuditPage/AuditPageView.tsx +++ b/site/src/pages/AuditPage/AuditPageView.tsx @@ -37,7 +37,7 @@ export interface AuditPageViewProps { onPageChange: (page: number) => void isNonInitialPage: boolean isAuditLogVisible: boolean - error?: Error | unknown + error?: unknown filterProps: ComponentProps } diff --git a/site/src/pages/CreateTokenPage/CreateTokenForm.tsx b/site/src/pages/CreateTokenPage/CreateTokenForm.tsx index eb48a56067b30..fa104cb165427 100644 --- a/site/src/pages/CreateTokenPage/CreateTokenForm.tsx +++ b/site/src/pages/CreateTokenPage/CreateTokenForm.tsx @@ -25,8 +25,8 @@ import { Stack } from "components/Stack/Stack" interface CreateTokenFormProps { form: FormikContextType maxTokenLifetime?: number - formError: Error | unknown - setFormError: (arg0: Error | unknown) => void + formError: unknown + setFormError: (arg0: unknown) => void isCreating: boolean creationFailed: boolean } diff --git a/site/src/pages/CreateTokenPage/CreateTokenPage.tsx b/site/src/pages/CreateTokenPage/CreateTokenPage.tsx index 3a76f3be30b8b..91b58e41ed417 100644 --- a/site/src/pages/CreateTokenPage/CreateTokenPage.tsx +++ b/site/src/pages/CreateTokenPage/CreateTokenPage.tsx @@ -43,7 +43,7 @@ export const CreateTokenPage: FC = () => { queryFn: getTokenConfig, }) - const [formError, setFormError] = useState(undefined) + const [formError, setFormError] = useState(undefined) const onCreateSuccess = () => { displaySuccess(t("createToken.createSuccess")) diff --git a/site/src/pages/GroupsPage/CreateGroupPageView.tsx b/site/src/pages/GroupsPage/CreateGroupPageView.tsx index 961fc97c488b8..b5b132c1f794c 100644 --- a/site/src/pages/GroupsPage/CreateGroupPageView.tsx +++ b/site/src/pages/GroupsPage/CreateGroupPageView.tsx @@ -16,7 +16,7 @@ const validationSchema = Yup.object({ export type CreateGroupPageViewProps = { onSubmit: (data: CreateGroupRequest) => void - formErrors: unknown | undefined + formErrors?: unknown isLoading: boolean } diff --git a/site/src/pages/UserSettingsPage/SSHKeysPage/SSHKeysPageView.tsx b/site/src/pages/UserSettingsPage/SSHKeysPage/SSHKeysPageView.tsx index d1e51406e17ca..5e9b27f043585 100644 --- a/site/src/pages/UserSettingsPage/SSHKeysPage/SSHKeysPageView.tsx +++ b/site/src/pages/UserSettingsPage/SSHKeysPage/SSHKeysPageView.tsx @@ -15,8 +15,8 @@ export const Language = { export interface SSHKeysPageViewProps { isLoading: boolean hasLoaded: boolean - getSSHKeyError?: Error | unknown - regenerateSSHKeyError?: Error | unknown + getSSHKeyError?: unknown + regenerateSSHKeyError?: unknown sshKey?: GitSSHKey onRegenerateClick: () => void } diff --git a/site/src/pages/UserSettingsPage/TokensPage/TokensPageView.tsx b/site/src/pages/UserSettingsPage/TokensPage/TokensPageView.tsx index a094ea765e9db..43150e8422407 100644 --- a/site/src/pages/UserSettingsPage/TokensPage/TokensPageView.tsx +++ b/site/src/pages/UserSettingsPage/TokensPage/TokensPageView.tsx @@ -28,11 +28,11 @@ const lastUsedOrNever = (lastUsed: string) => { export interface TokensPageViewProps { tokens?: APIKeyWithOwner[] - getTokensError?: Error | unknown + getTokensError?: unknown isLoading: boolean hasLoaded: boolean onDelete: (token: APIKeyWithOwner) => void - deleteTokenError?: Error | unknown + deleteTokenError?: unknown } export const TokensPageView: FC< diff --git a/site/src/pages/UserSettingsPage/WorkspaceProxyPage/WorkspaceProxyView.tsx b/site/src/pages/UserSettingsPage/WorkspaceProxyPage/WorkspaceProxyView.tsx index 508aee073131b..de0fad789b0e2 100644 --- a/site/src/pages/UserSettingsPage/WorkspaceProxyPage/WorkspaceProxyView.tsx +++ b/site/src/pages/UserSettingsPage/WorkspaceProxyPage/WorkspaceProxyView.tsx @@ -17,11 +17,11 @@ import { ErrorAlert } from "components/Alert/ErrorAlert" export interface WorkspaceProxyViewProps { proxies?: Region[] proxyLatencies?: Record - getWorkspaceProxiesError?: Error | unknown + getWorkspaceProxiesError?: unknown isLoading: boolean hasLoaded: boolean preferredProxy?: Region - selectProxyError?: Error | unknown + selectProxyError?: unknown } export const WorkspaceProxyView: FC< diff --git a/site/src/xServices/appearance/appearanceXService.ts b/site/src/xServices/appearance/appearanceXService.ts index f05566045447d..267d07608b726 100644 --- a/site/src/xServices/appearance/appearanceXService.ts +++ b/site/src/xServices/appearance/appearanceXService.ts @@ -5,8 +5,8 @@ import { AppearanceConfig } from "../../api/typesGenerated" export type AppearanceContext = { appearance?: AppearanceConfig - getAppearanceError?: Error | unknown - setAppearanceError?: Error | unknown + getAppearanceError?: unknown + setAppearanceError?: unknown preview: boolean } diff --git a/site/src/xServices/auth/authMethodsXService.ts b/site/src/xServices/auth/authMethodsXService.ts index c08e65d9e145c..50a66acaa2a32 100644 --- a/site/src/xServices/auth/authMethodsXService.ts +++ b/site/src/xServices/auth/authMethodsXService.ts @@ -4,7 +4,7 @@ import * as API from "api/api" export interface AuthMethodsContext { authMethods?: TypeGen.AuthMethods - error?: Error | unknown + error?: unknown } export const authMethodsXService = createMachine( diff --git a/site/src/xServices/auth/authXService.ts b/site/src/xServices/auth/authXService.ts index 506a22fbcffe4..983fa0f6386bd 100644 --- a/site/src/xServices/auth/authXService.ts +++ b/site/src/xServices/auth/authXService.ts @@ -181,8 +181,8 @@ const signOut = async () => { } as UnauthenticatedData } export interface AuthContext { - error?: Error | unknown - updateProfileError?: Error | unknown + error?: unknown + updateProfileError?: unknown data?: AuthData } diff --git a/site/src/xServices/buildInfo/buildInfoXService.ts b/site/src/xServices/buildInfo/buildInfoXService.ts index 69d6ab04779b7..9d8775f4ff214 100644 --- a/site/src/xServices/buildInfo/buildInfoXService.ts +++ b/site/src/xServices/buildInfo/buildInfoXService.ts @@ -3,7 +3,7 @@ import * as API from "../../api/api" import * as TypesGen from "../../api/typesGenerated" export interface BuildInfoContext { - getBuildInfoError?: Error | unknown + getBuildInfoError?: unknown buildInfo?: TypesGen.BuildInfoResponse } diff --git a/site/src/xServices/createWorkspace/createWorkspaceXService.ts b/site/src/xServices/createWorkspace/createWorkspaceXService.ts index be7b0b0779db6..0df9f13a1c3ab 100644 --- a/site/src/xServices/createWorkspace/createWorkspaceXService.ts +++ b/site/src/xServices/createWorkspace/createWorkspaceXService.ts @@ -25,7 +25,7 @@ type CreateWorkspaceContext = { templateName: string mode: CreateWorkspaceMode defaultName: string - error?: Error | unknown + error?: unknown // Form template?: Template parameters?: TemplateVersionParameter[] diff --git a/site/src/xServices/entitlements/entitlementsXService.ts b/site/src/xServices/entitlements/entitlementsXService.ts index b1257cb4d18e4..1b35c39b797d2 100644 --- a/site/src/xServices/entitlements/entitlementsXService.ts +++ b/site/src/xServices/entitlements/entitlementsXService.ts @@ -4,7 +4,7 @@ import { Entitlements } from "../../api/typesGenerated" export type EntitlementsContext = { entitlements?: Entitlements - getEntitlementsError?: Error | unknown + getEntitlementsError?: unknown } export const entitlementsMachine = createMachine( diff --git a/site/src/xServices/experiments/experimentsMachine.ts b/site/src/xServices/experiments/experimentsMachine.ts index 0c8eef6cf4a55..53bd5a7d86568 100644 --- a/site/src/xServices/experiments/experimentsMachine.ts +++ b/site/src/xServices/experiments/experimentsMachine.ts @@ -4,7 +4,7 @@ import { createMachine, assign } from "xstate" export interface ExperimentsContext { experiments?: Experiment[] - getExperimentsError?: Error | unknown + getExperimentsError?: unknown } export const experimentsMachine = createMachine( diff --git a/site/src/xServices/quotas/quotasXService.ts b/site/src/xServices/quotas/quotasXService.ts index cf6784a64d917..bc6f2e8e67a22 100644 --- a/site/src/xServices/quotas/quotasXService.ts +++ b/site/src/xServices/quotas/quotasXService.ts @@ -5,7 +5,7 @@ import { WorkspaceQuota } from "../../api/typesGenerated" export type QuotaContext = { username: string quota?: WorkspaceQuota - getQuotaError?: Error | unknown + getQuotaError?: unknown } export const quotaMachine = createMachine( diff --git a/site/src/xServices/roles/siteRolesXService.ts b/site/src/xServices/roles/siteRolesXService.ts index 82ac84ccbedd6..447a30b2527b9 100644 --- a/site/src/xServices/roles/siteRolesXService.ts +++ b/site/src/xServices/roles/siteRolesXService.ts @@ -10,7 +10,7 @@ export const Language = { type SiteRolesContext = { hasPermission: boolean roles?: TypesGen.AssignableRoles[] - getRolesError: Error | unknown + getRolesError: unknown } export const siteRolesMachine = createMachine( diff --git a/site/src/xServices/template/templateVariablesXService.ts b/site/src/xServices/template/templateVariablesXService.ts index 9bd72ed045687..a408a053157cc 100644 --- a/site/src/xServices/template/templateVariablesXService.ts +++ b/site/src/xServices/template/templateVariablesXService.ts @@ -24,8 +24,8 @@ type TemplateVariablesContext = { createTemplateVersionRequest?: CreateTemplateVersionRequest newTemplateVersion?: TemplateVersion - getTemplateDataError?: Error | unknown - updateTemplateError?: Error | unknown + getTemplateDataError?: unknown + updateTemplateError?: unknown jobError?: TemplateVersion["job"]["error"] } diff --git a/site/src/xServices/templateVersion/templateVersionXService.ts b/site/src/xServices/templateVersion/templateVersionXService.ts index 6494571eb4543..407324a0f2e9c 100644 --- a/site/src/xServices/templateVersion/templateVersionXService.ts +++ b/site/src/xServices/templateVersion/templateVersionXService.ts @@ -18,7 +18,7 @@ export interface TemplateVersionMachineContext { template?: Template currentVersion?: TemplateVersion currentFiles?: TemplateVersionFiles - error?: Error | unknown + error?: unknown // Get file diffs previousVersion?: TemplateVersion previousFiles?: TemplateVersionFiles diff --git a/site/src/xServices/templates/templatesXService.ts b/site/src/xServices/templates/templatesXService.ts index 2486e57337050..42249b0410584 100644 --- a/site/src/xServices/templates/templatesXService.ts +++ b/site/src/xServices/templates/templatesXService.ts @@ -8,7 +8,7 @@ export interface TemplatesContext { permissions: Permissions templates?: TypesGen.Template[] examples?: TypesGen.TemplateExample[] - error?: Error | unknown + error?: unknown } export const templatesMachine = createMachine( diff --git a/site/src/xServices/terminal/terminalXService.ts b/site/src/xServices/terminal/terminalXService.ts index 339e757f8a796..8216c23ff2d74 100644 --- a/site/src/xServices/terminal/terminalXService.ts +++ b/site/src/xServices/terminal/terminalXService.ts @@ -4,14 +4,14 @@ import * as Types from "../../api/types" import * as TypesGen from "../../api/typesGenerated" export interface TerminalContext { - workspaceError?: Error | unknown + workspaceError?: unknown workspace?: TypesGen.Workspace workspaceAgent?: TypesGen.WorkspaceAgent - workspaceAgentError?: Error | unknown + workspaceAgentError?: unknown websocket?: WebSocket - websocketError?: Error | unknown + websocketError?: unknown websocketURL?: string - websocketURLError?: Error | unknown + websocketURLError?: unknown // Assigned by connecting! // The workspace agent is entirely optional. If the agent is omitted the diff --git a/site/src/xServices/updateCheck/updateCheckXService.ts b/site/src/xServices/updateCheck/updateCheckXService.ts index c280ff306a0f4..7ab85abd673cb 100644 --- a/site/src/xServices/updateCheck/updateCheckXService.ts +++ b/site/src/xServices/updateCheck/updateCheckXService.ts @@ -6,7 +6,7 @@ import { checks, Permissions } from "xServices/auth/authXService" export interface UpdateCheckContext { permissions: Permissions updateCheck?: UpdateCheckResponse - error?: Error | unknown + error?: unknown } export type UpdateCheckEvent = { type: "DISMISS" } diff --git a/site/src/xServices/users/usersXService.ts b/site/src/xServices/users/usersXService.ts index 37d67b36b1cad..7b5f2f12b5de9 100644 --- a/site/src/xServices/users/usersXService.ts +++ b/site/src/xServices/users/usersXService.ts @@ -35,26 +35,26 @@ export interface UsersContext { // Get users users?: TypesGen.User[] filter: string - getUsersError?: Error | unknown + getUsersError?: unknown // Suspend user userIdToSuspend?: TypesGen.User["id"] usernameToSuspend?: TypesGen.User["username"] - suspendUserError?: Error | unknown + suspendUserError?: unknown // Delete user userIdToDelete?: TypesGen.User["id"] usernameToDelete?: TypesGen.User["username"] - deleteUserError?: Error | unknown + deleteUserError?: unknown // Activate user userIdToActivate?: TypesGen.User["id"] usernameToActivate?: TypesGen.User["username"] - activateUserError?: Error | unknown + activateUserError?: unknown // Reset user password userIdToResetPassword?: TypesGen.User["id"] - resetUserPasswordError?: Error | unknown + resetUserPasswordError?: unknown newUserPassword?: string // Update user roles userIdToUpdateRoles?: TypesGen.User["id"] - updateUserRolesError?: Error | unknown + updateUserRolesError?: unknown paginationContext: PaginationContext paginationRef: PaginationMachineRef count: number diff --git a/site/src/xServices/workspace/workspaceXService.ts b/site/src/xServices/workspace/workspaceXService.ts index c3010526ed71c..1876a2aff0f4e 100644 --- a/site/src/xServices/workspace/workspaceXService.ts +++ b/site/src/xServices/workspace/workspaceXService.ts @@ -59,12 +59,12 @@ export interface WorkspaceContext { build?: TypesGen.WorkspaceBuild // Builds builds?: TypesGen.WorkspaceBuild[] - getBuildsError?: Error | unknown + getBuildsError?: unknown missedParameters?: TypesGen.TemplateVersionParameter[] // error creating a new WorkspaceBuild - buildError?: Error | unknown + buildError?: unknown cancellationMessage?: Types.Message - cancellationError?: Error | unknown + cancellationError?: unknown // debug createBuildLogLevel?: TypesGen.CreateWorkspaceBuildRequest["log_level"] // SSH Config @@ -92,7 +92,7 @@ export type WorkspaceEvent = checkRefresh?: boolean data?: TypesGen.ServerSentEvent["data"] } - | { type: "EVENT_SOURCE_ERROR"; error: Error | unknown } + | { type: "EVENT_SOURCE_ERROR"; error: unknown } | { type: "INCREASE_DEADLINE"; hours: number } | { type: "DECREASE_DEADLINE"; hours: number } | { type: "RETRY_BUILD" } diff --git a/site/src/xServices/workspaceBuild/workspaceBuildXService.ts b/site/src/xServices/workspaceBuild/workspaceBuildXService.ts index 58f6b6fcc5399..980cb5c910e42 100644 --- a/site/src/xServices/workspaceBuild/workspaceBuildXService.ts +++ b/site/src/xServices/workspaceBuild/workspaceBuildXService.ts @@ -11,7 +11,7 @@ type LogsContext = { // Used to reference logs before + after. timeCursor: Date build?: WorkspaceBuild - getBuildError?: Error | unknown + getBuildError?: unknown // Logs logs?: ProvisionerJobLog[] } diff --git a/site/src/xServices/workspaceSchedule/workspaceScheduleXService.ts b/site/src/xServices/workspaceSchedule/workspaceScheduleXService.ts index e931b3142ffad..8b1795c01c0c8 100644 --- a/site/src/xServices/workspaceSchedule/workspaceScheduleXService.ts +++ b/site/src/xServices/workspaceSchedule/workspaceScheduleXService.ts @@ -9,7 +9,7 @@ import * as TypesGen from "../../api/typesGenerated" type Permissions = Record, boolean> export interface WorkspaceScheduleContext { - getWorkspaceError?: Error | unknown + getWorkspaceError?: unknown /** * Each workspace has their own schedule (start and ttl). For this reason, we * re-fetch the workspace to ensure we're up-to-date. As a result, this @@ -17,10 +17,10 @@ export interface WorkspaceScheduleContext { */ workspace: TypesGen.Workspace template?: TypesGen.Template - getTemplateError?: Error | unknown + getTemplateError?: unknown permissions?: Permissions - checkPermissionsError?: Error | unknown - submitScheduleError?: Error | unknown + checkPermissionsError?: unknown + submitScheduleError?: unknown autostopChanged?: boolean shouldRestartWorkspace?: boolean }