UNPKG

@orca-fe/pocket

Version:

UI components by orca-team

18 lines (17 loc) 633 B
import React from 'react'; import { useRatio } from './EqRatioBoxContext'; export interface EqRatioBoxProps extends React.HTMLAttributes<HTMLDivElement> { width: number; height: number; mode?: 'contain' | 'cover'; xAlign?: 'left' | 'right' | 'center'; yAlign?: 'top' | 'bottom' | 'center'; scaleMode?: boolean; onRatioChange?: (ratio: number) => void; } declare const EqRatioBox: { (props: EqRatioBoxProps): import("react/jsx-runtime").JSX.Element; useRatio: typeof useRatio; EqRatioBoxContext: React.Context<import("./EqRatioBoxContext").EqRatioBoxContextType>; }; export default EqRatioBox;