@coveord/plasma-mantine
Version:
A Plasma flavoured Mantine theme
17 lines (16 loc) • 508 B
JavaScript
/**
* Converts column size configuration to CSS styles.
* Handles both numeric (px) and string (%, fr, etc.) size values.
*/ export const getColumnSizeStyles = (column)=>{
const sizeToStyle = (size)=>{
if (size === undefined) {
return undefined;
}
return typeof size === 'number' ? `${size}px` : size;
};
return {
minWidth: sizeToStyle(column.minSize),
maxWidth: sizeToStyle(column.maxSize)
};
};
//# sourceMappingURL=columnUtils.js.map