UNPKG

@mantine/core

Version:

React components library focused on usability, accessibility and developer experience

30 lines (28 loc) 600 B
'use client'; function mergeStyles(styles, theme) { if (Array.isArray(styles)) { return [...styles].reduce( (acc, item) => ({ ...acc, ...mergeStyles(item, theme) }), {} ); } if (typeof styles === "function") { return styles(theme); } if (styles == null) { return {}; } return styles; } function getBoxStyle({ theme, style, vars, styleProps }) { const _style = mergeStyles(style, theme); const _vars = mergeStyles(vars, theme); return { ..._style, ..._vars, ...styleProps }; } export { getBoxStyle }; //# sourceMappingURL=get-box-style.mjs.map