@kiwicom/orbit-components
Version:
Orbit-components is a React component library which provides developers with the easiest possible way of building Kiwi.com’s products.
21 lines (17 loc) • 474 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
const tooltipPadding = ({
contentHeight,
theme
}) => {
// one-line text should have smaller top/bottom padding
if (contentHeight <= Math.floor(parseFloat(theme.orbit.lineHeightTextNormal))) {
return `${theme.orbit.spaceXSmall} ${theme.orbit.spaceSmall}`;
}
return theme.orbit.spaceSmall;
};
var _default = tooltipPadding;
exports.default = _default;