From 304bd2934405940ef1a52dde4d0db1efb03f788c Mon Sep 17 00:00:00 2001 From: Sandino Scheidegger Date: Sat, 4 Jan 2025 20:21:23 +0100 Subject: [PATCH 01/10] Fixing various screen views --- shared/locales/fr/website-common.json | 2 +- .../src/components/navbar/navbar-client.tsx | 72 ++++++++++--------- website/src/components/navbar/navbar.tsx | 8 +-- 3 files changed, 43 insertions(+), 39 deletions(-) diff --git a/shared/locales/fr/website-common.json b/shared/locales/fr/website-common.json index 47210196f..1fc1d6e19 100644 --- a/shared/locales/fr/website-common.json +++ b/shared/locales/fr/website-common.json @@ -8,7 +8,7 @@ "twitter-image": "/assets/metadata/twitter/default.jpg" }, "navigation": { - "our-promise": "Modèle à 100 %", + "our-promise": "Notre promesse", "about-us": "Qui nous sommes", "contact": "Contact", "contributors": "Donateurs et donatrices", diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index 307b6292c..f861e5a49 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -276,15 +276,20 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig const transparency = navigation![2]; return ( -
-
+
+
- - +
+ +
+ -
+
{translations.myProfile} -
+
{translations.donate} @@ -292,17 +297,12 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
-
-
- {ourWork.title} -
+
+
+ + {ourWork.title} + +
{ourWork.links?.map((link: any, index: number) => ( {link.title} @@ -310,9 +310,11 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
- {aboutUs.title} -
+
+ + {aboutUs.title} + +
{aboutUs.links?.map((link, index) => ( {link.title} @@ -320,9 +322,11 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
- {transparency.title} -
+
+ + {transparency.title} + +
{transparency.links?.map((link: any, index: number) => ( {link.title} @@ -331,14 +335,14 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
-
-
+
+
{(!isIntRegion || (isIntRegion && country)) && ( Country flag{languages.find((l) => l.code === lang)?.translation}
-
-
+
+
{regions .sort((a, b) => a.translation.localeCompare(b.translation)) .map((reg, index) => ( setRegion(reg.code)} @@ -363,13 +367,13 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
+
{languages .sort((a, b) => a.translation.localeCompare(b.translation)) .map((l, index) => ( setLanguage(l.code)} @@ -378,14 +382,14 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
+
{currencies .sort((a, b) => a.code.localeCompare(b.code)) .map((curr, index) => ( setCurrency(curr.code)} diff --git a/website/src/components/navbar/navbar.tsx b/website/src/components/navbar/navbar.tsx index b256301a9..def1e6431 100644 --- a/website/src/components/navbar/navbar.tsx +++ b/website/src/components/navbar/navbar.tsx @@ -70,10 +70,6 @@ async function Navbar({ lang, region }: DefaultParams) { title: translator.t('navigation.recipient-selection'), href: `/${lang}/${region}/transparency/recipient-selection`, }, - { - title: translator.t('navigation.faq'), - href: `/${lang}/${region}/faq`, - }, { title: translator.t('navigation.evidence'), href: `/${lang}/${region}/transparency/evidence`, @@ -82,6 +78,10 @@ async function Navbar({ lang, region }: DefaultParams) { title: translator.t('navigation.reporting'), href: `/${lang}/${region}/transparency/reporting`, }, + { + title: translator.t('navigation.faq'), + href: `/${lang}/${region}/faq`, + }, ], }, ]} From 3a537b54806d6cec6e2d0bcecf0c732a862b2c2e Mon Sep 17 00:00:00 2001 From: ssandino Date: Sat, 4 Jan 2025 19:24:07 +0000 Subject: [PATCH 02/10] Prettified Code! --- .../src/components/navbar/navbar-client.tsx | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index f861e5a49..0a8f3e58e 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -280,16 +280,16 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
- +
{translations.myProfile} -
+
{translations.donate} @@ -298,7 +298,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
-
+
{ourWork.title} @@ -310,7 +310,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
+
{aboutUs.title} @@ -322,7 +322,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
+
{transparency.title} @@ -336,7 +336,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
-
+
{(!isIntRegion || (isIntRegion && country)) && ( {languages.find((l) => l.code === lang)?.translation}
-
-
+
+
{regions .sort((a, b) => a.translation.localeCompare(b.translation)) .map((reg, index) => ( setRegion(reg.code)} @@ -373,7 +373,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig .map((l, index) => ( setLanguage(l.code)} @@ -389,7 +389,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig setCurrency(curr.code)} From 9e8d9ce3c1013b43b43357d1da68dc8093d83d87 Mon Sep 17 00:00:00 2001 From: Sandino Scheidegger Date: Sat, 4 Jan 2025 20:55:47 +0100 Subject: [PATCH 03/10] Small fixes --- .../src/components/navbar/navbar-client.tsx | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index f861e5a49..e97ee5e98 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -276,20 +276,20 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig const transparency = navigation![2]; return ( -
+
- +
-
+
{translations.myProfile} -
+
{translations.donate} @@ -298,11 +298,11 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
-
- +
+ {ourWork.title} -
+
{ourWork.links?.map((link: any, index: number) => ( {link.title} @@ -314,7 +314,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig {aboutUs.title} -
+
{aboutUs.links?.map((link, index) => ( {link.title} @@ -326,7 +326,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig {transparency.title} -
+
{transparency.links?.map((link: any, index: number) => ( {link.title} @@ -350,11 +350,11 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig )}{' '} {languages.find((l) => l.code === lang)?.translation}
-
+
{regions - .sort((a, b) => a.translation.localeCompare(b.translation)) - .map((reg, index) => ( + .sort((a, b) => a.translation.localeCompare(b.translation)) + .map((reg, index) => ( Date: Sat, 4 Jan 2025 22:23:00 +0100 Subject: [PATCH 04/10] Test fix (as it doesn't show on local) --- website/src/components/navbar/navbar-client.tsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index e97ee5e98..6f7fc1a56 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -302,19 +302,19 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig {ourWork.title} -
+
{ourWork.links?.map((link: any, index: number) => ( - + {link.title} ))}
- + {aboutUs.title} -
+
{aboutUs.links?.map((link, index) => ( {link.title} @@ -326,7 +326,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig {transparency.title} -
+
{transparency.links?.map((link: any, index: number) => ( {link.title} From deb2f4d83d3dd8ee1302e9141c2da0e71538f738 Mon Sep 17 00:00:00 2001 From: ssandino Date: Sat, 4 Jan 2025 21:25:05 +0000 Subject: [PATCH 05/10] Prettified Code! --- .../src/components/navbar/navbar-client.tsx | 30 +++++++++---------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index 6f7fc1a56..81557ac4e 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -280,7 +280,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
@@ -299,22 +299,22 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
- + {ourWork.title}
{ourWork.links?.map((link: any, index: number) => ( - + {link.title} ))}
-
- +
+ {aboutUs.title} -
+
{aboutUs.links?.map((link, index) => ( {link.title} @@ -322,7 +322,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
+
{transparency.title} @@ -336,7 +336,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
-
+
{(!isIntRegion || (isIntRegion && country)) && ( {languages.find((l) => l.code === lang)?.translation}
-
-
+
+
{regions - .sort((a, b) => a.translation.localeCompare(b.translation)) - .map((reg, index) => ( + .sort((a, b) => a.translation.localeCompare(b.translation)) + .map((reg, index) => ( setRegion(reg.code)} @@ -373,7 +373,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig .map((l, index) => ( setLanguage(l.code)} @@ -389,7 +389,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig setCurrency(curr.code)} From 30871573cf9b67f3d60eb70c7f9ed7e38c3f4feb Mon Sep 17 00:00:00 2001 From: Sandino Scheidegger Date: Sat, 4 Jan 2025 22:29:45 +0100 Subject: [PATCH 06/10] Test fix (as it doesn't show on local) --- website/src/components/navbar/navbar-client.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index 6f7fc1a56..8fdf8ee86 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -314,7 +314,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig {aboutUs.title} -
+
{aboutUs.links?.map((link, index) => ( {link.title} @@ -326,7 +326,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig {transparency.title} -
+
{transparency.links?.map((link: any, index: number) => ( {link.title} From 1128753b117adae2ce420bffe793c7da789e3c91 Mon Sep 17 00:00:00 2001 From: ssandino Date: Sat, 4 Jan 2025 21:32:15 +0000 Subject: [PATCH 07/10] Prettified Code! --- .../src/components/navbar/navbar-client.tsx | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index 8fdf8ee86..0bcb6a124 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -280,7 +280,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
@@ -299,22 +299,22 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
- + {ourWork.title}
{ourWork.links?.map((link: any, index: number) => ( - + {link.title} ))}
-
- +
+ {aboutUs.title} -
+
{aboutUs.links?.map((link, index) => ( {link.title} @@ -322,11 +322,11 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
+
{transparency.title} -
+
{transparency.links?.map((link: any, index: number) => ( {link.title} @@ -336,7 +336,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
-
+
{(!isIntRegion || (isIntRegion && country)) && ( {languages.find((l) => l.code === lang)?.translation}
-
-
+
+
{regions - .sort((a, b) => a.translation.localeCompare(b.translation)) - .map((reg, index) => ( + .sort((a, b) => a.translation.localeCompare(b.translation)) + .map((reg, index) => ( setRegion(reg.code)} @@ -373,7 +373,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig .map((l, index) => ( setLanguage(l.code)} @@ -389,7 +389,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig setCurrency(curr.code)} From ffc61179283a2126ebb03ad07c9747ce3933e24d Mon Sep 17 00:00:00 2001 From: Sandino Scheidegger Date: Sat, 4 Jan 2025 22:48:06 +0100 Subject: [PATCH 08/10] Clean up --- website/src/components/navbar/navbar-client.tsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index 8fdf8ee86..e0d1b7318 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -302,16 +302,16 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig {ourWork.title} -
+
{ourWork.links?.map((link: any, index: number) => ( - - {link.title} - + + {link.title} + ))}
- + {aboutUs.title}
From 93cab2fa2a8ca229c22540873d187c5aae8b9c78 Mon Sep 17 00:00:00 2001 From: ssandino Date: Sat, 4 Jan 2025 21:50:54 +0000 Subject: [PATCH 09/10] Prettified Code! --- .../src/components/navbar/navbar-client.tsx | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index e0d1b7318..f0c908799 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -280,7 +280,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
@@ -299,22 +299,22 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
- + {ourWork.title} -
+
{ourWork.links?.map((link: any, index: number) => ( - {link.title} - + {link.title} + ))}
-
+
{aboutUs.title} -
+
{aboutUs.links?.map((link, index) => ( {link.title} @@ -322,11 +322,11 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig ))}
-
+
{transparency.title} -
+
{transparency.links?.map((link: any, index: number) => ( {link.title} @@ -336,7 +336,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig
-
+
{(!isIntRegion || (isIntRegion && country)) && ( {languages.find((l) => l.code === lang)?.translation}
-
-
+
+
{regions - .sort((a, b) => a.translation.localeCompare(b.translation)) - .map((reg, index) => ( + .sort((a, b) => a.translation.localeCompare(b.translation)) + .map((reg, index) => ( setRegion(reg.code)} @@ -373,7 +373,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig .map((l, index) => ( setLanguage(l.code)} @@ -389,7 +389,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig setCurrency(curr.code)} From c158311fba5f682c1bbacdd56630556a5faa5825 Mon Sep 17 00:00:00 2001 From: Sandino Scheidegger Date: Sat, 4 Jan 2025 22:58:32 +0100 Subject: [PATCH 10/10] Clean up --- website/src/components/navbar/navbar-client.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/src/components/navbar/navbar-client.tsx b/website/src/components/navbar/navbar-client.tsx index f0c908799..af90fdd57 100644 --- a/website/src/components/navbar/navbar-client.tsx +++ b/website/src/components/navbar/navbar-client.tsx @@ -314,7 +314,7 @@ const DesktopNavigation = ({ lang, region, languages, regions, currencies, navig {aboutUs.title} -
+
{aboutUs.links?.map((link, index) => ( {link.title}