Skip to content

Creating Multiple Variants #403

Description

I am looking for a way to create multiple variants for buttons. For example, let's say I want to have the following three variants:

  1. Size (small, medium, large, etc).
  2. Look (primary, secondary, disabled, etc).
  3. Kind (default, outline, text, etc).

So that I could style a button like this:

<button
 sx={{
    size="buttons.size.large"
    kind="buttons.kind.outline"
    look="buttons.look.secondary"
 }}
/>

This IS possible with style system -- here is an example:

But I can't figure out how to do with with Theme-UI.

Is this possible with Theme-UI? If so, can how can I do it?

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions