UNPKG

denwa-web-shared

Version:

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

71 lines (70 loc) 1.67 kB
export interface IServerImage { altRU?: string; altEN?: string; altAR?: string; name: string; originalFileExtension: string; entityId: string; fullPathExample: string; folder?: string; prefixes?: string[]; fileExtensions?: string[]; } export interface IServerFile { name: string; fullName: string; extension: string; entityId: string; fullPathExample: string; folder?: string; } export interface IPreparedServerImage { image1x: string; image2x: string; image1xWebp: string; image2xWebp: string; image1xAvif: string; image2xAvif: string; mobileImage1x?: string; mobileImage2x?: string; mobileImage1xWebp?: string; mobileImage2xWebp?: string; mobileImage1xAvif?: string; mobileImage2xAvif?: string; altRU?: string; altEN?: string; altAR?: string; type: ImageType; } export interface IPreparedServerImageWithAlt extends IPreparedServerImage { alt?: string; } export type ImageType = 'image/png' | 'image/jpeg'; export interface IPaginate { page: number; pages: number; previous?: number; next?: number; count: number; limit: number; } export interface PaginationButton { label: string; href: string; isActive: boolean; } export interface PaginationResult { buttons: PaginationButton[]; firstPage?: PaginationButton; lastPage?: PaginationButton; } export type GetErrorType = ({ error, message }: { error?: unknown; message?: string; }) => void; export type CityNamesType = Record<string, { name: string; declination: string; region: string; regionDeclination: string; }>;