Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(theming): Return default theme if the user never selected a theme #49112

Merged
merged 1 commit into from
Nov 7, 2024

Conversation

provokateurin
Copy link
Member

Summary

While working on nextcloud/ocs_api_viewer#36 I found that if the user never selected a theme the data-themes attribute would only be an empty string instead of containing the default theme.
I'm not sure if the fallback also needs to be changed in other places, but this at least fixes the attribute problem.

Checklist

@provokateurin provokateurin added bug 3. to review Waiting for reviews labels Nov 6, 2024
@provokateurin provokateurin added this to the Nextcloud 31 milestone Nov 6, 2024
@provokateurin
Copy link
Member Author

/backport to stable30

@provokateurin
Copy link
Member Author

/backport to stable29

@provokateurin
Copy link
Member Author

/backport to stable28

Copy link
Contributor

@susnux susnux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense, also tested and works fine.
I am not 100% this is intended, because "default" is not a theme but just an alias to select either dark or light depending on user agent, so empty attribute still means "default".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants