Skip to content

fix(BBBModal, BBButton): follow the BBB client dark theme and border color when colors are overridden - #94

Merged
Arthurk12 merged 2 commits into
bigbluebutton:developfrom
Arthurk12:issue/89
Oct 1, 2026
Merged

Arthurk12 merged 2 commits into
bigbluebutton:developfrom
Arthurk12:issue/89

Conversation

@Arthurk12

Copy link
Copy Markdown
Member

What does this PR do?

  • BBBModal: the modal and sticky footer background now follow the BBB client dark theme.
    • colorWhite now maps to the client's --color-white, falling back to --color-neutral-white. --color-white is the variable the client remaps in dark mode.
    • The modal background moves out of react-modal's inline style into a styled(ReactModal) class, so regular CSS can override it.
  • BBButton: the border of the secondary variant now follows --color-primary. colorBorderSelected now falls back to colorBrand1 instead of the base brand color.

Closes Issue(s)

Closes #89

BBBModal and its sticky footer take their background from colorWhite,
which resolves to --color-neutral-white. The BBB client does not know
that variable: its own palette and its dark theme are built on
--color-white, so in dark mode the modal keeps a white background, or
at best gets darkreader's generic inversion, which does not match the
client's native modals.

The background is also set through react-modal's inline `style`, so
consumers can only override it with `!important` on the modal id.

Map colorWhite to --color-white, falling back to
--color-neutral-white, following the same "mapped to core css vars"
pattern used by colorBrand1 and colorError. This makes every library
use of colorWhite follow the client's --color-white, which is what
BBB's own components already do.

Move the modal background out of the inline style into a
styled(ReactModal) class. Passing a className makes react-modal drop
its default content styles, including a 1px #ccc border; that border
is not restated, matching BBB's native BaseModal, which has none.

A dedicated token used only by the modal was considered, but it would
leave the rest of the library out of sync with the client theme.
The border of the secondary (outlined) BBButton stays blue even when
the client overrides --color-primary, while the button's text and
outline already follow it. The border comes from colorBorderSelected,
which falls back straight to the library's base brand color
(--color-brand-1, #0F70D7), skipping --color-primary.

Fall back to colorBrand1 instead, so the chain becomes
--color-border-selected -> --color-primary -> --color-brand-1 ->
#0F70D7. The border-specific variable still wins when set, and
otherwise the border follows the client's primary color.

colorBorderSelected is also used for the focus/selected borders of
BBBSelect, BBBSearch, BBBInput and BBBTextInput, which now follow
--color-primary the same way.
@Arthurk12
Arthurk12 merged commit 7b67953 into bigbluebutton:develop Oct 1, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant