@mantine/core
Version:
React components library focused on usability, accessibility and developer experience
19 lines (18 loc) • 577 B
JavaScript
"use client";
//#region packages/@mantine/core/src/core/Box/style-props/resolvers/line-height-resolver/line-height-resolver.ts
const headings = [
"h1",
"h2",
"h3",
"h4",
"h5",
"h6"
];
function lineHeightResolver(value, theme) {
if (typeof value === "string" && value in theme.lineHeights) return `var(--mantine-line-height-${value})`;
if (typeof value === "string" && headings.includes(value)) return `var(--mantine-${value}-line-height)`;
return value;
}
//#endregion
exports.lineHeightResolver = lineHeightResolver;
//# sourceMappingURL=line-height-resolver.cjs.map