Skip to content

feat: add the custom theme #1234

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

Open
wants to merge 16 commits into
base: main
Choose a base branch
from

Conversation

Jasmer529
Copy link

I added the custom theme for users to choose the colors they like to define the application.
redb
three
32

Copy link
Member

@Feichtmeier Feichtmeier left a comment

Choose a reason for hiding this comment

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

HI 👋🏻
Thank you very much for your contribution! 🙇🏻

This is a great idea!

To get this ready it would be great if you could:

  • translate all chinese strings in comments to english
  • add new translantions to a the english app_en.arb file, the translations to chinese/german/etc are handled over at weblate https://hosted.weblate.org/projects/musicpod/app/ please remove the changes to the chinese arb file because this might cause conflicts with the way weblate pulls the changes from this repository to present new translateable strings to translators
  • generate the translations from the new strings you added by running flutter pub get
  • use the new strings in your code as variables of the context.l10n object

Additionally I don't think the app is already flexible enough to have such a sophisticated theme change like gradients. But the UI you added is awesome, so what we could do is:

  • I made a theme called "phoenix_theme" which is used for windows and macos (for linux yaru is used)
  • both phoenix_theme and yaru have functions already included to create new theme variations by passing the primary color (i.e. createYaruLightTheme() / createYaruDarkTheme() and phoenixTheme())
  • we could then use the color you created from your UI/service/model to create new versions of yaru/phoenix and use them in the app. I would prefer this because I designed the app currently around those two themes in terms of color/layout/borderr-radii and so on. Maybe we could make the app more flexible by removing remaining hard coded theme code to fully follow a new theme in the future, but I fear for the moment this is not yet possible

@Feichtmeier
Copy link
Member

@Jasmer529 if you have more questions we also have a discord: https://discord.gg/vJgPV9Yn3n

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.

2 participants