Skip to content
Solais Labs

Background

Background utilities paint an element with a theme colour, a subtle tint, the body surface or a gradient. Combine bg-{colour} with bg-opacity-* or the --ui-bg-opacity variable to fade it, and prefer the text-bg-* helpers or -emphasis text colours so contrast stays readable in light and dark mode.

1Theme colour backgrounds

bg-primary to bg-dark fill an element with a theme colour. Pair them with a readable text colour - text-bg-primary picks the one that reads on your brand colour.

bg-primary
bg-secondary
bg-success
bg-danger
bg-warning
bg-info
bg-light
bg-dark

2Subtle backgrounds

The -subtle variants are soft tints that work in light and dark mode; use the matching -emphasis text colour.

bg-primary-subtle
bg-success-subtle
bg-warning-subtle
bg-danger-subtle
bg-info-subtle

3Body backgrounds

bg-body, bg-body-secondary and bg-body-tertiary follow the page surface and adapt to colour mode.

bg-body - the page itself
bg-body-secondary - side panels
bg-body-tertiary - wells and inputs

4Text and background together

text-bg-{colour} sets the background and a contrasting text colour in one class.

text-bg-primary text-bg-warning text-bg-info text-bg-light text-bg-dark

5Background opacity steps

bg-opacity-10, -25, -50, -75 and -100 fade a theme background in fixed steps. White text needs the full colour; the labels sit under the lighter steps.

100
75
50
25
10

6Gradient overlay

bg-gradient adds a soft white-to-transparent gradient on top of any bg-{colour}.

bg-primary bg-gradient
Hands-on workshops
bg-dark bg-gradient
Recorded sessions

7Transparent background

bg-transparent removes a fill, useful when a component's default background must disappear.

bg-white
bg-transparent

8Black and white

bg-black and bg-white are fixed colours that do not change with colour mode, unlike bg-body.

bg-black
bg-white

9Highlighted table row

Background utilities on a table cell or row mark a selection without extra CSS.

OrderCustomerTotal
#PO-1270Zoe Varga$168.01
#PO-5480Priya Sato$361.88
#ORD-3891Jonah Kowalski$351.28

10Feature icons on tinted circles

A subtle background with rounded-circle and fixed size gives each icon a soft colour badge.

Networking lounges
Recorded sessions
World-class speakers

11Section bands

Alternating bg-body and bg-body-tertiary bands separate page sections.

Ideas on stage, connections everywhere

Our evening party is the best place to turn talks into friendships.

Learn, connect and get inspired

Early bird tickets save you up to forty percent until the end of the month.

Big ideas, small rooms, real conversations

Our team has done this many times, so you never have to guess.

12Dark footer strip

bg-dark with text-white-50 and link-light builds a compact footer.

13Alert-like message

A message strip built from bg-danger-subtle, a matching border and emphasis text.

14Background on hoverable list

List items with bg-body-tertiary for the active one; other rows stay on bg-body.

  • Inbox
  • Starred
  • Sent
  • Archive

15Progress made from backgrounds

A bg-body-secondary track and a bg-success fill with a width utility form a simple meter.

Storage75 of 100 GB
Seats5 of 20

16Pricing highlight

The recommended plan gets text-bg-primary (the brand colour with the text colour that reads on it); the others stay on bg-body-tertiary.

Basic
$12.22
Pro
$29.30
Team
$86.62

17Colour swatches

Square swatches with bg-{colour} and a caption below, as used in a style guide.

Primary
Secondary
Success
Warning
Surface

18Card header and footer tints

bg-body-tertiary on the header and footer of a card, bg-body in the middle.

Ten talks you should not miss this year
Clear prices, honest advice and no surprises along the way.
Updated 51 min ago

19Image scrim with bg-black

A bg-black layer at reduced --ui-bg-opacity makes white text readable over a photo.

Join the conference of the year
Talks, workshops and new friendships

20Chat bubbles

Incoming messages on bg-body-tertiary, outgoing on bg-primary, each with a rounded corner set.

We measure success by how many attendees come back and tell their friends.
Workshops are limited to thirty seats, so everyone gets hands-on time.
Thousands of attendees already trust us, and we work hard to keep it that way.