Merge version_1 into main
Merge version_1 into main
This commit was merged in pull request #2.
This commit is contained in:
@@ -17,7 +17,7 @@ export default function LandingPage() {
|
||||
borderRadius="rounded"
|
||||
contentWidth="compact"
|
||||
sizing="mediumLargeSizeMediumTitles"
|
||||
background="noise"
|
||||
background="circleGradient"
|
||||
cardStyle="layered-gradient"
|
||||
primaryButtonStyle="primary-glow"
|
||||
secondaryButtonStyle="radial-glow"
|
||||
@@ -42,13 +42,13 @@ export default function LandingPage() {
|
||||
<HeroLogoBillboardSplit
|
||||
logoText="CANTINE HURTEAU"
|
||||
description="Découvrez l'authenticité de la cuisine québécoise traditionnelle dans une ambiance chaleureuse et conviviale au cœur de Sorel-Tracy."
|
||||
background={{ variant: "noise" }}
|
||||
background={{ variant: "plain" }}
|
||||
buttons={[
|
||||
{ text: "Réserver une table", href: "#contact" },
|
||||
{ text: "Voir le menu", href: "#menu" }
|
||||
]}
|
||||
layoutOrder="default"
|
||||
imageSrc="http://img.b2bpic.net/free-photo/burning-candle-table_140725-8115.jpg?_wi=1"
|
||||
imageSrc="http://img.b2bpic.net/free-photo/burning-candle-table_140725-8115.jpg"
|
||||
imageAlt="Cantine Hurteau restaurant interior"
|
||||
mediaAnimation="slide-up"
|
||||
frameStyle="card"
|
||||
@@ -74,7 +74,7 @@ export default function LandingPage() {
|
||||
title: "Ingrédients Locaux", description: "Nous sourçons nos produits auprès de fournisseurs locaux de confiance"
|
||||
}
|
||||
]}
|
||||
imageSrc="http://img.b2bpic.net/free-photo/burning-candle-table_140725-8115.jpg?_wi=2"
|
||||
imageSrc="http://img.b2bpic.net/free-photo/burning-candle-table_140725-8115.jpg"
|
||||
imageAlt="Ambiance intérieure de la Cantine Hurteau"
|
||||
mediaAnimation="slide-up"
|
||||
textboxLayout="default"
|
||||
|
||||
@@ -1,51 +1,46 @@
|
||||
"use client";
|
||||
|
||||
import { memo } from "react";
|
||||
import useSvgTextLogo from "./useSvgTextLogo";
|
||||
import { cls } from "@/lib/utils";
|
||||
import React from 'react';
|
||||
|
||||
interface SvgTextLogoProps {
|
||||
logoText: string;
|
||||
adjustHeightFactor?: number;
|
||||
verticalAlign?: "top" | "center";
|
||||
text: string;
|
||||
className?: string;
|
||||
textClassName?: string;
|
||||
fontSize?: number;
|
||||
fontWeight?: 'normal' | 'bold' | '700';
|
||||
fill?: string;
|
||||
textAnchor?: 'start' | 'middle' | 'end';
|
||||
dominantBaseline?: 'auto' | 'text-bottom' | 'alphabetic' | 'ideographic' | 'middle' | 'central' | 'mathematical' | 'hanging';
|
||||
}
|
||||
|
||||
const SvgTextLogo = memo<SvgTextLogoProps>(function SvgTextLogo({
|
||||
logoText,
|
||||
adjustHeightFactor,
|
||||
verticalAlign = "top",
|
||||
className = "",
|
||||
}) {
|
||||
const { svgRef, textRef, viewBox, aspectRatio } = useSvgTextLogo(logoText, false, adjustHeightFactor);
|
||||
|
||||
const SvgTextLogo: React.FC<SvgTextLogoProps> = ({
|
||||
text,
|
||||
className = '',
|
||||
textClassName = '',
|
||||
fontSize = 48,
|
||||
fontWeight = 'bold',
|
||||
fill = 'currentColor',
|
||||
textAnchor = 'middle',
|
||||
dominantBaseline = 'middle',
|
||||
}) => {
|
||||
return (
|
||||
<svg
|
||||
ref={svgRef}
|
||||
viewBox={viewBox}
|
||||
className={cls("w-full", className)}
|
||||
style={{ aspectRatio: aspectRatio }}
|
||||
preserveAspectRatio="none"
|
||||
role="img"
|
||||
aria-label={`${logoText} logo`}
|
||||
viewBox="0 0 800 200"
|
||||
className={`w-full h-auto ${className}`}
|
||||
preserveAspectRatio="xMidYMid meet"
|
||||
>
|
||||
<text
|
||||
ref={textRef}
|
||||
x="0"
|
||||
y={verticalAlign === "center" ? "50%" : "0"}
|
||||
className="font-bold fill-current"
|
||||
style={{
|
||||
fontSize: "20px",
|
||||
letterSpacing: "-0.02em",
|
||||
dominantBaseline: verticalAlign === "center" ? "middle" : "text-before-edge"
|
||||
}}
|
||||
x="50%"
|
||||
y="50%"
|
||||
fontSize={fontSize}
|
||||
fontWeight={fontWeight}
|
||||
textAnchor={textAnchor}
|
||||
dominantBaseline={dominantBaseline}
|
||||
fill={fill}
|
||||
className={`font-bold ${textClassName}`}
|
||||
>
|
||||
{logoText}
|
||||
{text}
|
||||
</text>
|
||||
</svg>
|
||||
);
|
||||
});
|
||||
|
||||
SvgTextLogo.displayName = "SvgTextLogo";
|
||||
};
|
||||
|
||||
export default SvgTextLogo;
|
||||
|
||||
Reference in New Issue
Block a user