Merge version_1 into main #1

Merged
bender merged 2 commits from version_1 into main 2026-03-12 20:26:53 +00:00
2 changed files with 34 additions and 39 deletions

View File

@@ -43,7 +43,7 @@ export default function LandingPage() {
background={{ variant: "plain" }}
tag="North Beach's Favorite"
tagIcon={Star}
tagAnimation="entrance-slide"
tagAnimation="slide-up"
imageSrc="http://img.b2bpic.net/free-photo/closeup-eclairs-yellow-glaze-black-background_169016-18562.jpg"
imageAlt="Fresh golden Argentine churros on a plate"
mediaAnimation="slide-up"
@@ -51,7 +51,7 @@ export default function LandingPage() {
{ text: "Visit Us Today", href: "contact" },
{ text: "Learn More", href: "about" }
]}
buttonAnimation="entrance-slide"
buttonAnimation="slide-up"
/>
</div>

View File

@@ -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;
fontSize?: number;
fontWeight?: 'normal' | 'bold' | 'lighter';
textColor?: string;
strokeColor?: string;
strokeWidth?: number;
}
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 = '',
fontSize = 48,
fontWeight = 'bold',
textColor = '#000000',
strokeColor = 'none',
strokeWidth = 0,
}) => {
return (
<svg
ref={svgRef}
viewBox={viewBox}
className={cls("w-full", className)}
style={{ aspectRatio: aspectRatio }}
preserveAspectRatio="none"
role="img"
aria-label={`${logoText} logo`}
className={className}
viewBox={`0 0 ${text.length * (fontSize * 0.6)} ${fontSize * 1.5}`}
xmlns="http://www.w3.org/2000/svg"
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={fontSize * 0.3}
y={fontSize}
fontSize={fontSize}
fontWeight={fontWeight}
fill={textColor}
stroke={strokeColor}
strokeWidth={strokeWidth}
fontFamily="Arial, sans-serif"
dominantBaseline="auto"
>
{logoText}
{text}
</text>
</svg>
);
});
};
SvgTextLogo.displayName = "SvgTextLogo";
export default SvgTextLogo;
export default SvgTextLogo;