Add dark theme setting for settings screen#339
Conversation
6c3a3b6 to
d456b6c
Compare
| import kotlinx.coroutines.flow.StateFlow | ||
|
|
||
| interface SettingViewModel : | ||
| UnidirectionalViewModel<SettingViewModel.Event, SettingViewModel.Effect, SettingViewModel.State> { |
There was a problem hiding this comment.
Looks like we have a ktlint failure here due to chars are more than 100 in a line.
Exceeded max line length (100)
You can simply break them into multiple lines to pass the GitHub checks.
58765b4 to
117ccb3
Compare
7718501 to
9b74b7f
Compare
9b74b7f to
e54d515
Compare
|
👀 |
| import kotlinx.coroutines.flow.Flow | ||
| import kotlinx.coroutines.flow.StateFlow | ||
|
|
||
| interface DroidKaigiAppViewModel : |
There was a problem hiding this comment.
Currently, I don't use the name of DroidKaigi other than the theme, so I want to use AppViewModel.
| } | ||
|
|
||
| @Composable | ||
| private fun colorPalette(theme: Theme?): Colors { |
| <string name="error_network">ネットワークエラーが発生しました。もう一度お試しください。</string> | ||
| <string name="error_server">サーバーエラーが発生しました。もう一度お試しください。</string> | ||
| <string name="error_unknown">予期しないエラーが発生しました。もう一度お試しください。</string> | ||
| <string name="system">端末設定に従う</string> |
| } | ||
|
|
||
| @Composable | ||
| fun Theme( |
There was a problem hiding this comment.
How about making it private and naming it ThemeSetting, as it can be mistaken for setting Theme? 🎨
There was a problem hiding this comment.
Thanks, I've changed it that way!
👍
Thank you! We will create issue! |
|
Sorry. Please fix conflict 🙏 |
|
@takahirom
I created an issue! |
|
Sorry, the CI is down, I'll contact you after I fix it. |
|
@takahirom |
takahirom
left a comment
There was a problem hiding this comment.
LGTM 👍 I think this is a good sample for changing the theme in app!
Issue
Overview (Required)
Problem
Links
Screenshot