diff --git a/src/components/shared/SvgTextLogo/SvgTextLogo.tsx b/src/components/shared/SvgTextLogo/SvgTextLogo.tsx index f214190..047febc 100644 --- a/src/components/shared/SvgTextLogo/SvgTextLogo.tsx +++ b/src/components/shared/SvgTextLogo/SvgTextLogo.tsx @@ -1,51 +1,80 @@ -"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?: number | string; + letterSpacing?: number; + fillColor?: string; + strokeColor?: string; + strokeWidth?: number; + shadowColor?: string; + shadowBlur?: number; + shadowOffsetX?: number; + shadowOffsetY?: number; } -const SvgTextLogo = memo(function SvgTextLogo({ - logoText, - adjustHeightFactor, - verticalAlign = "top", - className = "", -}) { - const { svgRef, textRef, viewBox, aspectRatio } = useSvgTextLogo(logoText, false, adjustHeightFactor); +const SvgTextLogo = React.forwardRef( + ( + { + text, + className = '', + fontSize = 48, + fontWeight = 700, + letterSpacing = 2, + fillColor = '#000000', + strokeColor = '#ffffff', + strokeWidth = 0, + shadowColor = '#000000', + shadowBlur = 4, + shadowOffsetX = 0, + shadowOffsetY = 2, + }, + ref + ) => { + const filterId = `shadow-${Math.random().toString(36).substr(2, 9)}`; - return ( - - - {logoText} - - - ); -}); + + + + + + + + + + + + + + + {text} + + + ); + } +); -SvgTextLogo.displayName = "SvgTextLogo"; +SvgTextLogo.displayName = 'SvgTextLogo'; export default SvgTextLogo;