Docs Developers Status ForumSpark Hub
Build · Themes

Themes

Theme extensions are distributed as JSON package files containing CSS, layout templates, and settings.

Package structure

{
    "name": "My Custom Theme",
    "inherit_default": true,
    "dark_mode_toggle": true,
    "css": ":root { --fs-body-bg: #1a2332; --fs-panel-bg: #243447; }",
    "layout": "<!-- optional: custom HTML layout template -->",
    "guest_layout": "<!-- optional: layout for logged-out users -->",
    "settings": {
        "body_bg": "#1a2332",
        "panel_bg": "#243447",
        "link_color": "#60a5fa",
        "dark_body_bg": "#0f172a",
        "dark_panel_bg": "#1e293b"
    }
}

Field reference

FieldTypeRequiredDescription
namestringYesTheme display name (max 255 chars)
inherit_defaultbooleanNoWhen true, the board's compiled app.css is loaded alongside your theme. Default: true
dark_mode_togglebooleanNoWhether the dark mode toggle is shown. Default: true
cssstringNoCustom CSS (max 250KB). Can reference any --fs-* variables
layoutstringNoCustom HTML layout template (max 50KB)
guest_layoutstringNoLayout for non-authenticated visitors (max 50KB)
settingsobjectNoKey-value map of CSS variable values (see CSS Variables section)

Inheritance modes

inherit_default: true: your theme builds on top of the ForumSpark base styles. The compiled app.css is loaded, and your CSS variables + custom CSS override specific values. This is the recommended approach for most themes.

inherit_default: false: full control. Only your CSS is loaded, no base styles, no Tailwind utilities. You must style everything yourself including all layout, components, buttons, forms, panels, etc. Use this for completely custom designs.

CSS Variables Reference

ForumSpark uses CSS custom properties for theming. Set these in your theme's settings object. Dark mode values use the same variable names prefixed with dark_ in the settings key.

Layout & body

CSS VariableSettings KeyDescription
--fs-body-bg body_bg Page background
--fs-body-color body_color Default text colour
--fs-text-faint text_faint Faint text colour for meta labels
--fs-link-color link_color Link text colour
--fs-link-hover-color link_hover_color Link hover colour
--fs-font-family font_family Font stack (e.g. "Inter")
--fs-font-size font_size Base font size (e.g. "14px")
--fs-container-max-width container_max_width Max content width

Header & navigation

CSS VariableSettings KeyDescription
--fs-header-from header_from Header gradient start
--fs-header-to header_to Header gradient end
--fs-user-menu-bg user_menu_bg User menu background
--fs-user-menu-color user_menu_color User menu text
--fs-nav-bg nav_bg Navigation bar background
--fs-nav-color nav_color Navigation text
--fs-nav-active-bg nav_active_bg Active nav item background
--fs-nav-active-color nav_active_color Active nav item text
--fs-breadcrumb-bg breadcrumb_bg Breadcrumb bar background
--fs-breadcrumb-color breadcrumb_color Breadcrumb text
--fs-sub-header-color sub_header_color Sub-header text

Panels

CSS VariableSettings KeyDescription
--fs-panel-bg panel_bg Panel background
--fs-panel-border panel_border Panel border colour
--fs-panel-border-width panel_border_width Panel border width (e.g. "1px")
--fs-panel-radius panel_radius Panel border radius
--fs-panel-title-from panel_title_from Panel title gradient start
--fs-panel-title-to panel_title_to Panel title gradient end
--fs-panel-title-color panel_title_color Panel title text
--fs-panel-title-border panel_title_border Panel title border
--fs-panel-section-bg panel_section_bg Panel section background
--fs-panel-footer-from panel_footer_from Panel footer gradient start
--fs-panel-footer-to panel_footer_to Panel footer gradient end
--fs-panel-footer-accent panel_footer_accent Panel footer accent
--fs-panel-secondary-from panel_secondary_from Secondary panel gradient start
--fs-panel-secondary-to panel_secondary_to Secondary panel gradient end
--fs-panel-secondary-border panel_secondary_border Secondary panel border
--fs-panel-secondary-footer-accent panel_secondary_footer_accent Secondary panel footer accent

Forums & topics

CSS VariableSettings KeyDescription
--fs-forum-bg forum_bg Forum row background
--fs-forum-marker-bg forum_marker_bg Forum status marker
--fs-forum-last-bg forum_last_bg Last post info background
--fs-forum-link-color forum_link_color Forum title link colour
--fs-forum-divider forum_divider Forum row divider
--fs-topic-bg topic_bg Topic row background

Replies

CSS VariableSettings KeyDescription
--fs-reply-bg reply_bg Reply background
--fs-reply-details-bg reply_details_bg Reply details panel background
--fs-reply-user-border reply_user_border Reply user info border
--fs-reply-actions-bg reply_actions_bg Reply action bar background
--fs-reply-divider reply_divider Reply divider
--fs-separator-from separator_from Separator gradient start
--fs-separator-to separator_to Separator gradient end
--fs-mini-profile-bg mini_profile_bg Mini profile card background
--fs-mini-profile-border mini_profile_border Mini profile card border

Buttons

CSS VariableSettings KeyDescription
--fs-btn-primary-from btn_primary_from Primary button gradient start
--fs-btn-primary-to btn_primary_to Primary button gradient end
--fs-btn-primary-border btn_primary_border Primary button border
--fs-btn-primary-color btn_primary_color Primary button text
--fs-btn-secondary-from btn_secondary_from Secondary button gradient start
--fs-btn-secondary-to btn_secondary_to Secondary button gradient end
--fs-btn-secondary-border btn_secondary_border Secondary button border
--fs-btn-secondary-color btn_secondary_color Secondary button text
--fs-btn-danger-from btn_danger_from Danger button gradient start
--fs-btn-danger-to btn_danger_to Danger button gradient end
--fs-btn-danger-border btn_danger_border Danger button border
--fs-btn-danger-color btn_danger_color Danger button text
--fs-btn-success-from btn_success_from Success button gradient start
--fs-btn-success-to btn_success_to Success button gradient end
--fs-btn-success-border btn_success_border Success button border
--fs-btn-success-color btn_success_color Success button text
--fs-btn-blue-from btn_blue_from Blue button gradient start
--fs-btn-blue-to btn_blue_to Blue button gradient end
--fs-btn-blue-border btn_blue_border Blue button border

Misc

CSS VariableSettings KeyDescription
--fs-dropdown-bg dropdown_bg Dropdown menu background
--fs-dropdown-border dropdown_border Dropdown menu border
--fs-dropdown-color dropdown_color Dropdown text
--fs-dropdown-hover-bg dropdown_hover_bg Dropdown item hover background
--fs-notification-dot notification_dot Notification badge colour
--fs-online-active online_active Online status: active
--fs-online-away online_away Online status: away
--fs-online-idle online_idle Online status: idle
--fs-bulletin-primary bulletin_primary Bulletin primary colour
--fs-bulletin-accent bulletin_accent Bulletin accent colour
--fs-avatar-radius avatar_radius Avatar border radius (e.g. "50%")
--fs-border-radius border_radius Global border radius
--fs-box-shadow box_shadow Global box shadow

Other tokens

CSS VariableSettings KeyDescription
--fs-logo-height logo_height Logo height on desktop, any CSS length
--fs-logo-height-mobile logo_height_mobile Logo height on phones, falls back to the desktop size

Layout setting: post_layout

One settings key has no CSS variable: post_layout chooses how posts render inside a topic. Leave it out for the default layout, or set "article" or "card".

Platform tokens (CSS-only)

The modern board stylesheet also derives these tokens with light and dark defaults of their own. They are not part of the settings object; override them from your theme's custom CSS instead (scope dark overrides to body.dark).

CSS VariableDescription
--fs-text Base text colour used across v2 board surfaces
--fs-text-primary Strongest text (titles, key figures)
--fs-text-secondary Secondary text
--fs-text-muted Muted text (meta lines, timestamps)
--fs-heading-color Headings on v2 board pages
--fs-divider Hairline dividers between rows and sections
--fs-card-bg Generic card background
--fs-card-border Generic card border
--fs-input-bg Form input background
--fs-input-color Form input text
--fs-input-border Form input border
--fs-button-bg Neutral button background
--fs-button-color Neutral button text
--fs-cta-bg Call-to-action button background
--fs-cta-bg-hover Call-to-action hover background
--fs-cta-border Call-to-action border
--fs-cta-color Call-to-action text
--fs-forum-accent Accent colour on forum rows and markers
--fs-box-shadow-sm Small shadow used on raised elements

Styling the v2 board: b2 classes

The modern board markup uses BEM classes prefixed b2- (for example .b2-cat__head, the category panel header). These classes read their colours from the CSS variables above, so setting variables themes the whole board at once. Target the classes directly in your custom CSS only when you need surgical control over one surface.

Major blocks

BlockSurface
.b2-cat Category panel on the board index (__head, __body)
.b2-forum Forum row inside a category
.b2-fhead Forum view header
.b2-tl Topic list on a forum (rows, __sec section dividers, __foot browsing strip)
.b2-tpv Topic preview details inside forum rows
.b2-peekd Topic peek dropdown
.b2-thead Topic view header
.b2-post A post on the topic view (__rail author rail, __actions bar)
.b2-art Article post layout hero
.b2-composer Quick reply composer (__head toolbar)
.b2-editor Editor chrome
.b2-pager Pagination
.b2-statsbar Online-members strip under topic lists
.b2-modbar Moderation toolbar
.b2-ntp New topic button
.b2-subnav Sub-navigation tabs
.b2-prof Member profile pages
.b2-ucard Member hover card
.b2-aisum AI thread summary panel
.b2-srch Search page
.b2-auth Login and register pages

This list covers the big surfaces; use your browser's dev tools to find element and modifier names within a block. Boards on the classic (v1) edition use the older class names without the b2- prefix.

Dark mode: To set dark mode overrides, use the same settings key prefixed with dark_. For example, dark_body_bg sets --fs-body-bg within the body.dark selector. Colour tokens all have a dark twin; layout and typography tokens (fonts, sizes, radii, shadows, post layout) apply to both modes and take no dark_ prefix.