Files
oxygen-ui/src/components/common/FitFullscreen.tsx
2024-01-14 00:51:03 +08:00

28 lines
790 B
TypeScript

import { DetailedHTMLProps, HTMLAttributes } from 'react'
import '@/assets/css/components/common/fit-fullscreen.scss'
interface FitFullscreenProps
extends DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement> {
zIndex?: number
backgroundColor?: string
}
const FitFullscreen = forwardRef<HTMLDivElement, FitFullscreenProps>(
({ zIndex, backgroundColor, className, style, ...props }, ref) => {
return (
<div
className={`fit-fullscreen${className ? ` ${className}` : ''}`}
style={{
zIndex,
backgroundColor,
...style
}}
ref={ref}
{...props}
/>
)
}
)
export default FitFullscreen