@revolist/revogrid
Version:
Virtual reactive data grid spreadsheet component - RevoGrid.
9 lines (8 loc) • 351 B
JavaScript
/*!
* Built by Revolist OU ❤️
*/
const LETTER_BLOCK_SIZE = 10;
export const calculateRowHeaderSize = (itemsLength, rowHeaderColumn, minWidth = 50) => {
return ((rowHeaderColumn === null || rowHeaderColumn === void 0 ? void 0 : rowHeaderColumn.size) ||
Math.max((itemsLength.toString().length + 1) * LETTER_BLOCK_SIZE, minWidth));
};