Alt-Org / Altzone-WebPages

Altzone-WebPages is an open-source project focused on building modern, dynamic web pages for the Altzone game project. 🌟
https://altzone.fi
13 stars 0 forks source link

Pauliina/enhancement/211 make a custom select menu #281

Open Chromoprotein opened 2 weeks ago

Chromoprotein commented 2 weeks ago

📄 Pull Request Overview

Issue Number: 211

🔧 Changes Made

  1. I made a custom select menu for the LangSwitcher menu. I attempted to follow the style of the other navbar elements.
  2. It also works on mobile.
  3. I also made it work with keyboards for accessibility.
  4. I updated the tests.

📝 Additional Information

desktop2 desktop mobile

Problem: the test "falls back to default language when current language is not in options" fails. If the user types for example altzone.fi/es, it does switch to a supported language, but the incorrect language tag stays in the url, e.g. altzone.fi/en/es, causing the error page to be displayed.

Skoivumaki commented 1 week ago

Build is failing since NavbarDesktop.stories.tsx is missing some NavbarProps. The LangSwitcher test is failing to run. You can run tests with: npm run test:watch to make sure they work. image

Chromoprotein commented 1 week ago

I fixed the test, and the checks pass now.