How to make SendbirdUIKit appearance follow the system appearance, including Liquid Glass? #193
lookdeceline
announced in
8. Commons
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Keeping SendbirdUIKit — Liquid Glass chrome included — in sync when the system appearance changes. Copy the case that matches your theme colors.
UIColorCase 1. Static colors
Leave
SBUTheme.liquidGlassAppearanceat its default.theme. Liquid Glass followsSBUTheme.colorScheme.Register once, on the container that hosts your Sendbird screens.
Result. Group channel screen kept on display while the system appearance is toggled. The code above runs on the toggle, so the navigation bar tint and the whole screen follow it.
Case 2. Dynamic
UIColorNo appearance observer, no
SBUTheme.set(colorScheme:), noupdateStyles().Result. Same screen, same toggle as Case 1, and the same end state — with no app-side sync code.
Watch out
.systemis for Case 2 only. With static colors it moves the glass material while your tint stays put.SBUTheme.liquidGlassAppearanceis launch-time configuration. A glass view reads it once, when created.SBUTheme.set(theme:)andset(colorScheme:)reset every component theme. Set them first, your colors after.UIColorread as.cgColor, or baked into aUIImage, is pinned to the trait it was created under. Rebuild those withupdateStyles().SBUConfig.Common.isLiquidGlassEnabled = falseturns Liquid Glass off on iOS 26.0+.All reactions