Skip to content

Action Module

The Action module provides grouped interactive controls inside an .actions container. It supports secondary, loading, rounded, disabled, and color variants, and extends the Element module.

Signature:

scss
@mixin use-action($colors: ());

Example:

scss
@include termeh.use-action(("primary", "indigo", "maroon"));

Module:

This module is registered as action in the presented modules.

Dependencies

Action module uses the following Termeh global var():

ComponentTypeUsageDefault
gapmicroNumberSpacing between action items8px
radiusnormalNumberDefault action border radiusnull
radiusroundedNumberRounded action border radiusnull
decoratorsizeNumberLoading spinner and focus ring sizenull
controlheightNumberDefault action height2.2em

Action module uses the following Termeh color() and variant():

Color / VariantUsageDefault
primaryDefault action backgroundnull
primaryforegroundDefault action text and spinner colornull
shadeDefault focus/active outline colornull
shadereadableSecondary action text and spinner colornull

Action Container

Container for action items: .actions

  • Uses a horizontal flex layout with item gaps
  • On mobile, horizontal overflow is scrollable

Modifiers

  • .is-secondary → transparent background with readable text color
  • .is-loading → locks the action and replaces text with a loader
  • .is-rounded → applies rounded border radius
  • .is-disabled → applies disabled style and disables interaction
  • .is-<color> → applies a registered color variant to an .actions container

Color Scope

Apply a color to the .actions container or any parent element. Individual .action elements do not support color classes.

  • .actions.is-primary
  • .is-primary .actions