Trongate CSS Docs

Form Buttons

Trongate CSS provides several button styles and variations that can be used within forms. This guide explores the various button options and their common use cases.

Basic Buttons

The standard button style is achieved using either the button element or an anchor tag with the .button class:

Link Button

Trongate CSS file gives buttons a top margin. The relevant rule is:

To mitigate this, a class of .mt-0 can be added to buttons. For example:

Alternative Style

Add the .alt class to create buttons with an outline style:

Back

Status Buttons

Trongate CSS provides contextual button styles for different actions and states:

Button Sizes

Buttons can be sized using Trongate's size classes:

Form Actions

When positioning multiple buttons at the bottom of a form, consider using .justify-between for optimal spacing:

Special Button Styles

Trongate CSS includes metallic button styles for emphasis:

Disabled State

Use the disabled attribute to indicate inactive buttons:

Disabled buttons maintain their basic styling but have reduced opacity and a "not-allowed" cursor to indicate their inactive state.