feat(SW-189): added translations and some minor changes

This commit is contained in:
Erik Tiekstra
2024-09-11 14:40:48 +02:00
parent 789133af11
commit 21d8a5835a
32 changed files with 271 additions and 151 deletions

View File

@@ -1,5 +1,6 @@
"use client"
import { useEffect } from "react"
import { Dialog, Modal } from "react-aria-components"
import { useIntl } from "react-intl"
@@ -38,6 +39,13 @@ export default function MobileMenu({
}
})
// Making sure the menu is always opened at the top of the page, just below the header.
useEffect(() => {
if (isHamburgerMenuOpen) {
window.scrollTo({ top: 0, behavior: "instant" })
}
}, [isHamburgerMenuOpen])
return (
<>
<button

View File

@@ -1,5 +1,6 @@
"use client"
import { useEffect } from "react"
import { Dialog, Modal } from "react-aria-components"
import { useIntl } from "react-intl"
@@ -31,6 +32,13 @@ export default function MyPagesMobileMenu({
}
})
// Making sure the menu is always opened at the top of the page, just below the header.
useEffect(() => {
if (isMyPagesMobileMenuOpen) {
window.scrollTo({ top: 0, behavior: "instant" })
}
}, [isMyPagesMobileMenuOpen])
return (
<div className={styles.myPagesMobileMenu}>
<MainMenuButton