Skip to content

[Desktop] system theme not followed #2914

@jpnurmi

Description

@jpnurmi

Current behavior 🐛

A certain combination of Uno features (Hosting, Navigation, ThemeService, Toolkit) causes the system theme to be incorrectly saved into app settings, which makes the app unfollow the system theme.

Expected behavior 🎯

Uno app follows the system theme when no theme is explicitly requested, which it does if any(?) of these features is removed.

How to reproduce it (as minimally and precisely as possible) 🔬

  1. create project

    $ dotnet new unoapp -platforms desktop -di -nav regions -theme-service -toolkit -o UnoThemeApp
  2. run app

    $ dotnet run -f net9.0-desktop --project UnoThemeApp/UnoThemeApp/UnoThemeApp.csproj
  3. toggle system theme

    Screencast.From.2025-10-17.15-06-08.mp4
  4. observe settings

    $ cat ~/.local/share/UnoThemeApp/com.companyname.unothemeapp/Settings/Local.dat
    CurrentTheme�System.String:Dark/...

Workaround 🛠️

No response

Renderer 🎨

  • Skia
  • Native

Affected platforms 📱💻🖥️

Desktop (Windows), Desktop (macOS), Desktop (X11)

Uno.Sdk version (and other relevant versions) 📦

6.3.28

IDE version 🧑‍💻

JetBrains Rider 2025.2.3

Anything else we need to know? 💬

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions