'use client'; import React, { memo } from 'react'; import { cls } from '@/lib/utils'; interface GradientBarsBackgroundProps { className?: string; numBars?: number; gradientFrom?: string; gradientTo?: string; opacity?: number; } const GradientBarsBackground = ({ className = "", numBars = 15, gradientFrom = "var(--color-primary-cta)", gradientTo = "transparent", opacity = 0.5, }: GradientBarsBackgroundProps) => { const calculateHeight = (index: number, total: number): number => { const position = index / (total - 1); const maxHeight = 100; const minHeight = 30; const center = 0.5; const distanceFromCenter = Math.abs(position - center); const heightPercentage = Math.pow(distanceFromCenter * 2, 1.2); return minHeight + (maxHeight - minHeight) * heightPercentage; }; return (
); }; GradientBarsBackground.displayName = 'GradientBarsBackground'; export default memo(GradientBarsBackground);