Files
a098a19a-94d0-4c8d-aa4b-e0b…/src/components/shared/SvgTextLogo/SvgTextLogo.tsx

54 lines
1.1 KiB
TypeScript

import React from 'react';
interface SvgTextLogoProps {
text: string;
className?: string;
fontSize?: number;
fontWeight?: number | string;
letterSpacing?: number;
textAnchor?: 'start' | 'middle' | 'end';
dominantBaseline?: 'auto' | 'middle' | 'hanging';
fill?: string;
stroke?: string;
strokeWidth?: number;
}
const SvgTextLogo: React.FC<SvgTextLogoProps> = ({
text,
className = '',
fontSize = 48,
fontWeight = 700,
letterSpacing = 2,
textAnchor = 'middle',
dominantBaseline = 'middle',
fill = 'currentColor',
stroke,
strokeWidth,
}) => {
return (
<svg
viewBox="0 0 1000 200"
className={className}
role="img"
aria-label={text}
>
<text
x="500"
y="100"
fontSize={fontSize}
fontWeight={fontWeight}
letterSpacing={letterSpacing}
textAnchor={textAnchor}
dominantBaseline={dominantBaseline}
fill={fill}
stroke={stroke}
strokeWidth={strokeWidth}
fontFamily="inherit"
>
{text}
</text>
</svg>
);
};
export default SvgTextLogo;