We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2a6689e commit a6925eeCopy full SHA for a6925ee
src/clamp.ts
@@ -113,9 +113,9 @@ const getLineHeight = (elem: HTMLElement | Element): number => {
113
if (lh === 'normal') {
114
// Normal line heights vary from browser to browser. The spec recommends
115
// a value between 1.0 and 1.2 of the font size. Using 1.1 to split the diff.
116
- return parseInt(computeStyle(elem, 'font-size')) * 1.2;
+ return parseFloat(computeStyle(elem, 'font-size')) * 1.2;
117
}
118
- return parseInt(lh);
+ return parseFloat(lh);
119
};
120
121
/**
0 commit comments