synapse-react-client
Version:
[](https://badge.fury.io/js/synapse-react-client) [](https://github.com/prettier/prettie
21 lines (20 loc) • 564 B
JavaScript
const i = {
// Approximate effective width of each header IconButton (icon + padding)
pin: 28,
help: 28,
spacing: 4,
// gap between elements
padding: 4
// container padding
};
function h(a, c, n) {
const e = c?.type?.format === "date-time" ? 215 : 175, d = a.length * 11;
let t = 0;
n?.showPinIcon && (t += i.pin + i.spacing), n?.hasDescription && (t += i.help + i.spacing), t > 0 && (t += i.padding);
const o = d + t;
return Math.max(e, o);
}
export {
h as calculateDefaultColumnWidth
};
//# sourceMappingURL=calculateColumnWidth.js.map