tuil
ReferencePackages@mwillbanks/tuil-themeAPI

resolveComponentProps

function exported by @mwillbanks/tuil-theme.

View rawEdit

function

Public function exported by @mwillbanks/tuil-theme.

export function resolveComponentProps(
  componentName: string,
  options: {
    readonly variant?: string;
    readonly size?: "sm" | "md" | "lg";
    readonly unstyled?: boolean;
    readonly className?: string;
  },
  state: Readonly<Record<string, boolean>>,
  theme: Theme,
): TerminalStyleProps;

Members

This declaration has no public members.

Parameters

MemberTypeRequiredDescriptionRelated types
componentNamestringYesSupplies the componentName value as string.
options&#123; readonly variant?: string; readonly size?: "sm" | "md" | "lg"; readonly unstyled?: boolean; readonly className?: string; &#125;YesSupplies the options value as &#123; readonly variant?: string; readonly size?: "sm" | "md" | "lg"; readonly unstyled?: boolean; readonly className?: string; &#125;.
stateReadonly<Record<string, boolean>>YesSupplies the state value as Readonly<Record<string, boolean>>.
themeThemeYesSupplies the theme value as Theme.Theme

Returns

TerminalStyleProps — Returns a value that satisfies TerminalStyleProps.

Related types: TerminalStyleProps

Throws

No thrown errors are documented for this declaration.

Source

View the secondary source reference

Package

@mwillbanks/tuil-theme

On this page