UNPKG

@mantine/core

Version:

React components library focused on usability, accessibility and developer experience

32 lines (29 loc) 987 B
'use client'; import { getThemeStyles } from './get-theme-styles/get-theme-styles.mjs'; import { resolveStyle } from './resolve-style/resolve-style.mjs'; import { resolveStyles } from './resolve-styles/resolve-styles.mjs'; import { resolveVars } from './resolve-vars/resolve-vars.mjs'; function getStyle({ theme, themeName, selector, options, props, stylesCtx, rootSelector, styles, style, vars, varsResolver }) { return { ...getThemeStyles({ theme, themeName, props, stylesCtx, selector }), ...resolveStyles({ theme, styles, props, stylesCtx })[selector], ...resolveStyles({ theme, styles: options?.styles, props: options?.props || props, stylesCtx })[selector], ...resolveVars({ theme, props, stylesCtx, vars, varsResolver, selector, themeName }), ...rootSelector === selector ? resolveStyle({ style, theme }) : null, ...resolveStyle({ style: options?.style, theme }) }; } export { getStyle }; //# sourceMappingURL=get-style.mjs.map