Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

447 B
Raw Blame
import { PropsWithChildren } from 'react'

const LoadingOpacity = ({
  children,
  active,
  className,
}: PropsWithChildren<{
  children?: React.ReactNode
  active: boolean
  className?: string
}>) => {
  return (
    <div
      className={[
        className,
        'flex h-full grow transition-opacity ',
        active ? 'opacity-30' : 'opacity-100',
      ].join(' ')}
    >
      {children}
    </div>
  )
}

export default LoadingOpacity