chore: replace function expression with inline statement

replace destructuring for better static analysis

remove unused variables
This commit is contained in:
Christian Andolf
2024-11-05 10:14:52 +01:00
parent 28c30b2416
commit f6b3cf8b92
25 changed files with 75 additions and 78 deletions

View File

@@ -10,14 +10,14 @@ import { getLang } from "@/i18n/serverContext"
import styles from "./emptyUpcomingStays.module.css"
export default async function EmptyUpcomingStaysBlock() {
const { formatMessage } = await getIntl()
const intl = await getIntl()
return (
<section className={styles.container}>
<div className={styles.titleContainer}>
<Title as="h4" level="h3" color="red" className={styles.title}>
{formatMessage({ id: "You have no upcoming stays." })}
{intl.formatMessage({ id: "You have no upcoming stays." })}
<span className={styles.burgundyTitle}>
{formatMessage({ id: "Where should you go next?" })}
{intl.formatMessage({ id: "Where should you go next?" })}
</span>
</Title>
</div>
@@ -26,7 +26,7 @@ export default async function EmptyUpcomingStaysBlock() {
className={styles.link}
color="peach80"
>
{formatMessage({ id: "Get inspired" })}
{intl.formatMessage({ id: "Get inspired" })}
<ArrowRightIcon color="peach80" />
</Link>
</section>