UNPKG

@native-html/heuristic-table-plugin

Version:

🔠 A 100% native component using heuristics to render tables in react-native-render-html

18 lines (17 loc) • 581 B
import { TNode } from 'react-native-render-html'; import { TCellConstraints } from '../shared-types'; export default class TCellConstraintsComputer { private baseFontCoeff; private fallbackFontSize; private fontWeightCoeffs; constructor({ baseFontCoeff, fallbackFontSize }: { baseFontCoeff?: number; fallbackFontSize?: number; }); private getContentDensity; private geTextMinWidth; private getTextCoeff; private assembleCellStats; private computeTextConstraints; computeCellConstraints(tnode: TNode): TCellConstraints; }