fix(SW-1971): now closes mobile menu on clicking the find booking link

removed useless class usage

added customer service url to link
This commit is contained in:
Christian Andolf
2025-03-19 16:31:38 +01:00
parent 0666b62a4c
commit 9a37a2f4c0
4 changed files with 40 additions and 30 deletions

View File

@@ -1,3 +1,5 @@
"use client"
import Link from "next/link"
import { getIconByIconName } from "@/components/Icons/get-icon-by-icon-name"
@@ -12,11 +14,12 @@ export default function HeaderLink({
href,
iconName,
iconSize = 20,
onClick = () => undefined,
}: HeaderLinkProps) {
const Icon = getIconByIconName(iconName)
return (
<Caption type="regular" color="textMediumContrast" asChild>
<Link href={href} className={styles.headerLink}>
<Link href={href} className={styles.headerLink} onClick={onClick}>
{Icon ? (
<Icon className={styles.icon} width={iconSize} height={iconSize} />
) : null}