Presets

Canned styles for your interface elements.

Presets are pre-defined utility classes that allow you to quickly and easily style buttons, badges, cards, and more. They are implemented using a combination of Skeleton and Tailwind primitives. A number of presets are available out of the box, with guidelines provided for crafting your own.

Skeleton Presets

The following Presets are available to you when using Skeleton. Each comes with a shorthand neutral option.

1
2
3
  1. Filled - a filled preset of the primary brand color.
  2. Tonal - a tonal preset of the primary brand color.
  3. Outlined - an outlined preset of the primary brand color.

Filled

Has a wide variety of use cases and automatically implements contrast colors automatically.

txt
preset-filled
preset-filled-{color}-{lightModeShade}-{darkModeShade}

Tonal

Ideal for alerts and axillary buttons and actions.

txt
preset-tonal
preset-tonal-{color}

Outlined

Ideal when for minimal interfaces, such as a surrounding card.

txt
preset-outlined
preset-outlined-{color}-{shade}-{shade}

User Generated

In a nutshell, Presets are a resuable combination of styles that mix Skeleton and Tailwind primitives. This means you can create as many combinations as you wish to help control the aesthetic of your application. All custom presets should be implemented in your application’s global stylesheet. See our reference examples below.

1
2
3
4
  1. Glass - a custom preset using background transparency and backdrop blur.
  2. Elevated - mixes a filled preset with a shadow.
  3. Ghost - has no style by default, but shows a tonal preset on hover.
  4. Gradient - a custom preset generated using Tailwind gradient primitives.

Pratical Examples

Input Presets

Use Presets to generate your own custom validation classes for inputs.

Gradient Presets

Utilize Tailwind Gradient utility classes to create fancy buttons or cards.

Card
Card
Card

Glass Presets

Fine tune your Presets with special effects, such as the Tailwind Backdrop Blur for a glass-like effect.

Neutral
Primary
Secondary
Tertiary
Success
Warning
Error
Surface

Guidelines

  • When creating custom Presets, you’re only limited by your imagination.
  • Use any combination of Skeleton or Tailwind primitives to generate a Preset.
  • Apply Presets to any relevant element, including: buttons, badges, chips, cards, inputs, and more.
  • Use a set naming convention, such as preset-{foo}-{bar} to keep things standardized.
  • Consider implementing Presets using Tailwind’s @utility directive in your stylesheet.
  • Abstrast Presets to a stylesheet or NPM package for shared used between projects.
  • Use Presets to apply styling for your components via the class attribute.
View page on GitHub