UNPKG

@veracity/vui

Version:

Veracity UI is a React component library crafted for use within Veracity applications and pages. Based on Styled Components and @xstyled.

18 lines (17 loc) 835 B
import { ButtonIntent, ButtonVariant } from "./button.types.js"; //#region src/button/utils.d.ts /** * Converts a two-prop variant+intent pair into the combined theme key used * internally (e.g. `resolveVariantKey('primary','brand') => 'primaryBrand'`). * When `intent` is omitted, `'brand'` is used as the default * (e.g. `resolveVariantKey('primary') => 'primaryBrand'`). * * If `variant` is already a fully-qualified legacy key (e.g. `'primaryBrand'`) * it is returned unchanged so the new API is backward-compatible. * * Returns `'primaryBrand'` (the default variant) when `variant` is absent. */ declare const resolveVariantKey: (variant: ButtonVariant | string | undefined, intent: ButtonIntent | string | undefined) => string | undefined; //#endregion export { resolveVariantKey }; //# sourceMappingURL=utils.d.ts.map