UNPKG

react-simple-clamp

Version:

React clamping component, supporting both text and html inline content.

14 lines (13 loc) 393 B
import React from 'react'; export interface ClampTextProps { autoresize?: boolean; maxLines: number; maxHeight: number | string; ellipsis?: string; expanded?: boolean; content: string; className?: string; renderAfter: (clamped: boolean) => JSX.Element | JSX.Element[]; } declare const ClampText: React.FC<ClampTextProps>; export default ClampText;