Omasivusto.fi
Components· Theme

Components

Theme

Colours, typography, spacing, corners, buttons, colour schemes and ready-made palettes that every component takes its look from.

2 components

The examples are rendered in the chosen theme: a gallery template's own colours, fonts and corners, or a dark ready-made palette.

Theme values

Every section and block takes its colours, fonts, spacing and corners from these values. Changing the site's look in the editor changes these, and every component follows. The table shows the chosen theme's values.

Colours

NameValueSample
--color-accentvar(--color-primary)
--color-background#ffffff
--color-border#d5d9e0
--color-danger#b3261e
--color-infovar(--color-primary)
--color-muted#5b6470
--color-onDanger#ffffff
--color-onInfovar(--color-onPrimary)
--color-onPrimary#ffffff
--color-onSuccess#ffffff
--color-onWarning#ffffff
--color-primary#0055ff
--color-secondary#1f2937
--color-success#15803d
--color-surface#f4f5f7
--color-text#111111
--color-warning#b45309

Typography

NameValueSample
--font-bodyInter, system-ui, sans-serifAa Ää Öö
--font-headingInter, system-ui, sans-serifAa Ää Öö
--font-letterSpacing0em
--font-lineHeight1.65
--font-scale1
--font-weight400

Spacing

NameValueSample
--space-lg32px
--space-md16px
--space-mdLg24px
--space-section4rem
--space-sectionGap2rem
--space-sm8px
--space-xl4rem
--space-xs4px

Corner radius

NameValueSample
--radius-full9999px
--radius-md8px
--radius-sm4px
--radius-xl24px

Buttons

NameValueSample
--button-paddingX30px
--button-paddingY14px
--button-radius8px
--button-stylesolid
--button-weight400

Cards

NameValueSample
--card-border1px
--card-radius16px
--card-shadowvar(--shadow-card)

Shadows

NameValueSample
--shadow-card0 2px 8px rgba(0,0,0,0.1)
--shadow-lg0 8px 24px rgba(0,0,0,0.12)
--shadow-md0 2px 8px rgba(0,0,0,0.1)
--shadow-nonenone
--shadow-sm0 1px 2px rgba(0,0,0,0.06)
--shadow-xl0 16px 48px rgba(0,0,0,0.16)

Colour schemes

NameValueSample
--scheme-accent-backgroundvar(--color-primary)
--scheme-accent-bordercolor-mix(in srgb, var(--color-onPrimary) 30%, transparent)
--scheme-accent-mutedcolor-mix(in srgb, var(--color-onPrimary) 80%, transparent)
--scheme-accent-primaryvar(--color-onPrimary)
--scheme-accent-surfacecolor-mix(in srgb, var(--color-onPrimary) 15%, var(--color-primary))
--scheme-accent-textvar(--color-onPrimary)
--scheme-dark-backgroundvar(--color-text)
--scheme-dark-bordercolor-mix(in srgb, var(--color-background) 25%, transparent)
--scheme-dark-mutedcolor-mix(in srgb, var(--color-background) 75%, transparent)
--scheme-dark-primaryvar(--color-background)
--scheme-dark-surfacecolor-mix(in srgb, var(--color-background) 12%, var(--color-text))
--scheme-dark-textvar(--color-background)
--scheme-light-backgroundvar(--color-background)
--scheme-light-bordervar(--color-border)
--scheme-light-mutedvar(--color-muted)
--scheme-light-primaryvar(--color-primary)
--scheme-light-surfacevar(--color-surface)
--scheme-light-textvar(--color-text)
--scheme-muted-backgroundvar(--color-surface)
--scheme-muted-bordervar(--color-border)
--scheme-muted-mutedvar(--color-muted)
--scheme-muted-primaryvar(--color-primary)
--scheme-muted-surfacevar(--color-background)
--scheme-muted-textvar(--color-text)

Ready-made palettes

The palettes of the editor's Look panel and the gallery's "Try other colours". Each one passes WCAG AA contrast in every colour scheme.

  • Northern forest light
  • Sea breeze light
  • Sandy beach light
  • Brick and concrete light
  • Blueberry light
  • Pastel light
  • Night and gold dark
  • Black and white light
  • Graphic black dark
  • Northern lights dark
  • Smoke sauna dark

Colour schemes

Theme schemes

A section's colour scheme (light, muted, dark, accent) changes its background and text, and buttons and links follow. Contrast is checked in each.

Accessibility

Headings follow the page's heading levels, an image's alternative text is given in the editor, and colours come from the theme's values, whose contrast is checked to WCAG AA. No motion and no timed content.

Used in 0 templates

No gallery template uses this yet. Add it to a page from the editor's Add section library.

Typography

Theme typography

Headings H1–H4, body text, link, list and quote in the theme's fonts and sizes.

Accessibility

Headings follow the page's heading levels, an image's alternative text is given in the editor, and colours come from the theme's values, whose contrast is checked to WCAG AA. No motion and no timed content.

Used in 0 templates

No gallery template uses this yet. Add it to a page from the editor's Add section library.