fix(SW-203): added translations and now using updater function to set state
This commit is contained in:
@@ -41,11 +41,11 @@ export function Rooms({ rooms }: RoomsProps) {
|
|||||||
.sort((a, b) => a.sortOrder - b.sortOrder)
|
.sort((a, b) => a.sortOrder - b.sortOrder)
|
||||||
|
|
||||||
function handleToggleShowMore() {
|
function handleToggleShowMore() {
|
||||||
const newState = !allRoomsVisible
|
if (scrollRef.current && allRoomsVisible) {
|
||||||
setAllRoomsVisible(newState)
|
|
||||||
if (scrollRef.current && !newState) {
|
|
||||||
scrollRef.current.scrollIntoView({ behavior: "smooth" })
|
scrollRef.current.scrollIntoView({ behavior: "smooth" })
|
||||||
}
|
}
|
||||||
|
|
||||||
|
setAllRoomsVisible((previousState) => !previousState)
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@@ -104,6 +104,7 @@
|
|||||||
"Select country of residence": "Vælg bopælsland",
|
"Select country of residence": "Vælg bopælsland",
|
||||||
"Select date of birth": "Vælg fødselsdato",
|
"Select date of birth": "Vælg fødselsdato",
|
||||||
"Select language": "Vælg sprog",
|
"Select language": "Vælg sprog",
|
||||||
|
"Show less": "Vis mindre",
|
||||||
"Show more": "Vis mere",
|
"Show more": "Vis mere",
|
||||||
"Show all amenities": "Vis alle faciliteter",
|
"Show all amenities": "Vis alle faciliteter",
|
||||||
"Skip to main content": "Spring over og gå til hovedindhold",
|
"Skip to main content": "Spring over og gå til hovedindhold",
|
||||||
|
|||||||
@@ -99,7 +99,8 @@
|
|||||||
"Select country of residence": "Wählen Sie das Land Ihres Wohnsitzes aus",
|
"Select country of residence": "Wählen Sie das Land Ihres Wohnsitzes aus",
|
||||||
"Select date of birth": "Geburtsdatum auswählen",
|
"Select date of birth": "Geburtsdatum auswählen",
|
||||||
"Select language": "Sprache auswählen",
|
"Select language": "Sprache auswählen",
|
||||||
"Show more": "Zeig mehr",
|
"Show less": "Weniger anzeigen",
|
||||||
|
"Show more": "Mehr anzeigen",
|
||||||
"Show all amenities": "Alle Annehmlichkeiten anzeigen",
|
"Show all amenities": "Alle Annehmlichkeiten anzeigen",
|
||||||
"Skip to main content": "Direkt zum Inhalt",
|
"Skip to main content": "Direkt zum Inhalt",
|
||||||
"Something went wrong!": "Etwas ist schief gelaufen!",
|
"Something went wrong!": "Etwas ist schief gelaufen!",
|
||||||
|
|||||||
@@ -104,6 +104,7 @@
|
|||||||
"Select country of residence": "Valitse asuinmaa",
|
"Select country of residence": "Valitse asuinmaa",
|
||||||
"Select date of birth": "Valitse syntymäaika",
|
"Select date of birth": "Valitse syntymäaika",
|
||||||
"Select language": "Valitse kieli",
|
"Select language": "Valitse kieli",
|
||||||
|
"Show less": "Näytä vähemmän",
|
||||||
"Show more": "Näytä lisää",
|
"Show more": "Näytä lisää",
|
||||||
"Show all amenities": "Näytä kaikki mukavuudet",
|
"Show all amenities": "Näytä kaikki mukavuudet",
|
||||||
"Skip to main content": "Siirry pääsisältöön",
|
"Skip to main content": "Siirry pääsisältöön",
|
||||||
|
|||||||
@@ -104,6 +104,7 @@
|
|||||||
"Select country of residence": "Velg bostedsland",
|
"Select country of residence": "Velg bostedsland",
|
||||||
"Select date of birth": "Velg fødselsdato",
|
"Select date of birth": "Velg fødselsdato",
|
||||||
"Select language": "Velg språk",
|
"Select language": "Velg språk",
|
||||||
|
"Show less": "Vis mindre",
|
||||||
"Show more": "Vis mer",
|
"Show more": "Vis mer",
|
||||||
"Show all amenities": "Vis alle fasiliteter",
|
"Show all amenities": "Vis alle fasiliteter",
|
||||||
"Skip to main content": "Gå videre til hovedsiden",
|
"Skip to main content": "Gå videre til hovedsiden",
|
||||||
|
|||||||
@@ -107,6 +107,7 @@
|
|||||||
"Select country of residence": "Välj bosättningsland",
|
"Select country of residence": "Välj bosättningsland",
|
||||||
"Select date of birth": "Välj födelsedatum",
|
"Select date of birth": "Välj födelsedatum",
|
||||||
"Select language": "Välj språk",
|
"Select language": "Välj språk",
|
||||||
|
"Show less": "Visa mindre",
|
||||||
"Show more": "Visa mer",
|
"Show more": "Visa mer",
|
||||||
"Show all amenities": "Visa alla bekvämligheter",
|
"Show all amenities": "Visa alla bekvämligheter",
|
||||||
"Skip to main content": "Fortsätt till huvudinnehåll",
|
"Skip to main content": "Fortsätt till huvudinnehåll",
|
||||||
|
|||||||
Reference in New Issue
Block a user