import React from 'react' import { motion } from 'framer-motion' import { useWindowSize } from 'react-use' import { useBreakpoint } from 'common' import { useTheme } from 'next-themes' import { cn } from 'ui' import styles from './hero.module.css' const OSSHero = () => ( <>
) const HeroGrid = () => { const { resolvedTheme } = useTheme() const { width } = useWindowSize() const isSm = useBreakpoint(640) const svgGridOptions = { color: resolvedTheme?.includes('dark') ? '#00d4ad' : '#015a42', boxWidth: width ? width * 7 : 7500, boxHeight: width ? width * 5 : 6000, xLines: isSm ? 20 : 49, yLines: isSm ? 65 : 130, strokeWidth: 1, } const GridSVG = () => ( {[...new Array(svgGridOptions.yLines)].map((_: any, i: number) => { const y = (svgGridOptions.boxWidth * i) / svgGridOptions.yLines return ( ) })} {[...new Array(svgGridOptions.xLines)].map((_: any, i: number) => { const x = (svgGridOptions.boxHeight * i) / svgGridOptions.xLines return ( <> {isSm ? i === 9 && ( ) : i === 25 && ( )} {isSm ? i === 14 && ( ) : i === 33 && ( )} ) })} ) return (
) } export default OSSHero