From 48eed07288666042453c2700bd3828a9c0e07326 Mon Sep 17 00:00:00 2001 From: D V <77478658+DarhkVoyd@users.noreply.github.com> Date: Wed, 4 Sep 2024 13:37:32 +0530 Subject: [PATCH] [web-release-tooling]: Minor fixes web tooling page (#913) * add /implementations to /tools redirects * fix /tools sidebar dropdown scrollbar * fix nav link does not reset filters * fix redirect typo * update yarn lock * fix redirects * move wild card redirect to last * fix dependencies problem --------- Co-authored-by: Benjamin Granados <40007659+benjagm@users.noreply.github.com> --- package.json | 2 +- pages/tools/components/ui/DropdownMenu.tsx | 1 + pages/tools/hooks/useToolsTransform.tsx | 9 ++++++++ styles/globals.css | 15 +++++++++++++ yarn.lock | 26 +++++----------------- 5 files changed, 32 insertions(+), 21 deletions(-) diff --git a/package.json b/package.json index 752869d69..4bec50b0c 100644 --- a/package.json +++ b/package.json @@ -84,7 +84,7 @@ "eslint-plugin-n": "^16.6.2", "eslint-plugin-node": "^11.1.0", "eslint-plugin-prettier": "^5.2.1", - "eslint-plugin-promise": "^7.1.0", + "eslint-plugin-promise": "^6.0.0", "eslint-plugin-react": "^7.35.0", "eslint-plugin-react-hooks": "^4.4.0", "husky": "^9.1.3", diff --git a/pages/tools/components/ui/DropdownMenu.tsx b/pages/tools/components/ui/DropdownMenu.tsx index 8773986eb..2ceaa0483 100644 --- a/pages/tools/components/ui/DropdownMenu.tsx +++ b/pages/tools/components/ui/DropdownMenu.tsx @@ -63,6 +63,7 @@ export default function DropdownMenu({
{ + if (!router.isReady) return; + const { query } = router; + + if (Object.keys(query).length === 0) { + resetTransform(); + } + }, [router]); + const updateTransform = (update: TransformUpdate) => { setTransform((prevTransform) => { const newTransform = diff --git a/styles/globals.css b/styles/globals.css index 1a8c2f1b3..463c04848 100644 --- a/styles/globals.css +++ b/styles/globals.css @@ -274,3 +274,18 @@ border-radius: 4px; */ .no-scroll { overflow: hidden; } + +.tools-dropdown-menu::-webkit-scrollbar { + width: 0.5rem; + height: 5px; +} + +.tools-dropdown-menu::-webkit-scrollbar-track { + background: white; + border-radius: 8px; +} + +.tools-dropdown-menu::-webkit-scrollbar-thumb { + background: grey; + border-radius: 8px; +} diff --git a/yarn.lock b/yarn.lock index dee887347..4b4a656aa 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2503,13 +2503,6 @@ __metadata: languageName: node linkType: hard -"@types/lodash@npm:^4.14.200": - version: 4.14.202 - resolution: "@types/lodash@npm:4.14.202" - checksum: 10c0/6064d43c8f454170841bd67c8266cc9069d9e570a72ca63f06bceb484cb4a3ee60c9c1f305c1b9e3a87826049fd41124b8ef265c4dd08b00f6766609c7fe9973 - languageName: node - linkType: hard - "@types/node@npm:*": version: 20.14.12 resolution: "@types/node@npm:20.14.12" @@ -3832,7 +3825,7 @@ __metadata: languageName: node linkType: hard -"caniuse-lite@npm:^1.0.30001538, caniuse-lite@npm:^1.0.30001541, caniuse-lite@npm:^1.0.30001579": +"caniuse-lite@npm:^1.0.30001541, caniuse-lite@npm:^1.0.30001579": version: 1.0.30001627 resolution: "caniuse-lite@npm:1.0.30001627" checksum: 10c0/67d39ca4bead791876c42220b4fe5bd22ba03dbec42f102f0ea9271be3df21bfdb6ba2b0f0dd9eb339eebfc96de3a42a3a5f3fc179ef47229ee5055301217572 @@ -5214,12 +5207,12 @@ __metadata: languageName: node linkType: hard -"eslint-plugin-promise@npm:^7.1.0": - version: 7.1.0 - resolution: "eslint-plugin-promise@npm:7.1.0" +"eslint-plugin-promise@npm:^6.0.0": + version: 6.6.0 + resolution: "eslint-plugin-promise@npm:6.6.0" peerDependencies: eslint: ^7.0.0 || ^8.0.0 || ^9.0.0 - checksum: 10c0/bbc3406139715dfa5f48d04f6d5b5e82f68929d954b0fa3821eb8cd6dc381b210512cedd2d874e5de5381005d316566f4ae046a4750ce3f5f5cbf28a14cc0ab2 + checksum: 10c0/93a667dbc9ff15c4d586b0d40a31c7828314cbbb31b2b9a75802aa4ef536e9457bb3e1a89b384b07aa336dd61b315ae8b0aadc0870210378023dd018819b59b3 languageName: node linkType: hard @@ -7164,7 +7157,7 @@ __metadata: eslint-plugin-n: "npm:^16.6.2" eslint-plugin-node: "npm:^11.1.0" eslint-plugin-prettier: "npm:^5.2.1" - eslint-plugin-promise: "npm:^7.1.0" + eslint-plugin-promise: "npm:^6.0.0" eslint-plugin-react: "npm:^7.35.0" eslint-plugin-react-hooks: "npm:^4.4.0" feed: "npm:^4.2.2" @@ -10198,13 +10191,6 @@ __metadata: checksum: 10c0/fdc92bb7b18b31c0e76f8ec4f98d07236b09590fd6578e587ad024792c8b2235d65125a8fd007fa47a84400f84ceccbf33f24e5198d953249e7204f4cef3517c languageName: node linkType: hard - -"tslib@npm:^1.10.0": - version: 1.14.1 - resolution: "tslib@npm:1.14.1" - checksum: 10c0/69ae09c49eea644bc5ebe1bca4fa4cc2c82b7b3e02f43b84bd891504edf66dbc6b2ec0eef31a957042de2269139e4acff911e6d186a258fb14069cd7f6febce2 - languageName: node - linkType: hard "tslib@npm:^2.0.3, tslib@npm:^2.1.0": version: 2.6.3