Merge version_1 into main #1
@@ -9,7 +9,7 @@ import TestimonialCardFifteen from '@/components/sections/testimonial/Testimonia
|
||||
import ContactFaq from '@/components/sections/contact/ContactFaq';
|
||||
import FooterCard from '@/components/sections/footer/FooterCard';
|
||||
import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider";
|
||||
import { Award, CheckCircle, Phone, Sparkles } from 'lucide-react';
|
||||
import { Award, CheckCircle, Phone, Sparkles, Instagram, MapPin } from 'lucide-react';
|
||||
|
||||
export default function LandingPage() {
|
||||
return (
|
||||
@@ -182,6 +182,8 @@ export default function LandingPage() {
|
||||
logoText="StyleBuddhas"
|
||||
copyrightText="© 2025 StyleBuddhas | Premium Hair & Beauty Salon Barcelona"
|
||||
socialLinks={[
|
||||
{ icon: Instagram, href: "https://www.instagram.com", ariaLabel: "StyleBuddhas Instagram" },
|
||||
{ icon: MapPin, href: "https://www.google.com/maps/search/StyleBuddhas+Barcelona+Travessera+de+Gràcia+128", ariaLabel: "StyleBuddhas Location" },
|
||||
{ icon: Phone, href: "tel:+34656927129", ariaLabel: "Call StyleBuddhas" }
|
||||
]}
|
||||
/>
|
||||
|
||||
@@ -1,51 +1,49 @@
|
||||
"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;
|
||||
fontSize?: number;
|
||||
fontWeight?: number | string;
|
||||
letterSpacing?: number;
|
||||
className?: string;
|
||||
}
|
||||
|
||||
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,
|
||||
fontSize = 48,
|
||||
fontWeight = 'bold',
|
||||
letterSpacing = 0,
|
||||
className = '',
|
||||
}) => {
|
||||
const textLength = text.length;
|
||||
const charWidth = fontSize * 0.6;
|
||||
const width = textLength * charWidth + letterSpacing * (textLength - 1) + 20;
|
||||
const height = fontSize + 20;
|
||||
|
||||
return (
|
||||
<svg
|
||||
ref={svgRef}
|
||||
viewBox={viewBox}
|
||||
className={cls("w-full", className)}
|
||||
style={{ aspectRatio: aspectRatio }}
|
||||
preserveAspectRatio="none"
|
||||
width={width}
|
||||
height={height}
|
||||
viewBox={`0 0 ${width} ${height}`}
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
className={className}
|
||||
role="img"
|
||||
aria-label={`${logoText} logo`}
|
||||
aria-label={text}
|
||||
>
|
||||
<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}
|
||||
letterSpacing={letterSpacing}
|
||||
textAnchor="middle"
|
||||
dominantBaseline="central"
|
||||
fill="currentColor"
|
||||
>
|
||||
{logoText}
|
||||
{text}
|
||||
</text>
|
||||
</svg>
|
||||
);
|
||||
});
|
||||
|
||||
SvgTextLogo.displayName = "SvgTextLogo";
|
||||
};
|
||||
|
||||
export default SvgTextLogo;
|
||||
|
||||
Reference in New Issue
Block a user