UNPKG

denwa-web-shared

Version:

A shared library for Next.js App Router projects containing reusable components, hooks, schemas, and utilities.

26 lines (25 loc) 907 B
import { DetailedHTMLProps, FC, HTMLAttributes, ImgHTMLAttributes } from 'react'; import { ImageType } from '../types'; export interface BasePictureProps extends DetailedHTMLProps<HTMLAttributes<HTMLPictureElement>, HTMLPictureElement> { imgProps?: DetailedHTMLProps<ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>; data: PictureData | undefined; type: ImageType | undefined; alt: string; mobileMaxWidth?: number; loading?: 'eager' | 'lazy'; } export interface PictureData { image1x: string | undefined; image2x?: string; image1xWebp?: string; image2xWebp?: string; image1xAvif?: string; image2xAvif?: string; mobileImage1x?: string; mobileImage2x?: string; mobileImage1xWebp?: string; mobileImage2xWebp?: string; mobileImage1xAvif?: string; mobileImage2xAvif?: string; } export declare const BasePicture: FC<BasePictureProps>;