Skip to content

Commit

Permalink
i18n for theme cover based style
Browse files Browse the repository at this point in the history
  • Loading branch information
cuong-tran committed Jun 19, 2024
1 parent 8261473 commit 10c4938
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,29 @@ object SettingsAppearanceScreen : SearchableSettings {
title = stringResource(KMR.strings.pref_theme_cover_based_style),
enabled = detailsPageThemeCoverBased,
entries = PaletteStyle.entries
.associateWith { it.name }
.associateWith {
when (it) {
PaletteStyle.TonalSpot ->
stringResource(KMR.strings.pref_theme_cover_based_style_tonalspot)
PaletteStyle.Neutral ->
stringResource(KMR.strings.pref_theme_cover_based_style_neutral)
PaletteStyle.Vibrant ->
stringResource(KMR.strings.pref_theme_cover_based_style_vibrant)
PaletteStyle.Expressive ->
stringResource(KMR.strings.pref_theme_cover_based_style_expressive)
PaletteStyle.Rainbow ->
stringResource(KMR.strings.pref_theme_cover_based_style_rainbow)
PaletteStyle.FruitSalad ->
stringResource(KMR.strings.pref_theme_cover_based_style_fruitsalad)
PaletteStyle.Monochrome ->
stringResource(KMR.strings.pref_theme_cover_based_style_monochrome)
PaletteStyle.Fidelity ->
stringResource(KMR.strings.pref_theme_cover_based_style_fidelity)
PaletteStyle.Content ->
stringResource(KMR.strings.pref_theme_cover_based_style_content)
else -> it.name
}
}
.toImmutableMap(),
),
),
Expand Down
11 changes: 10 additions & 1 deletion i18n-kmk/src/commonMain/resources/MR/base/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,19 @@
<string name="action_faq_and_guides">FAQ and Guides</string>

<!-- Preferences -->
<!-- General section -->
<!-- Appearance section -->
<string name="pref_details_page_theme">Details page</string>
<string name="pref_theme_cover_based">Theme based on cover</string>
<string name="pref_theme_cover_based_style">Theme style</string>
<string name="pref_theme_cover_based_style_tonalspot">Tonal Spot</string>
<string name="pref_theme_cover_based_style_neutral">Neutral</string>
<string name="pref_theme_cover_based_style_vibrant">Vibrant</string>
<string name="pref_theme_cover_based_style_expressive">Expressive</string>
<string name="pref_theme_cover_based_style_rainbow">Rainbow</string>
<string name="pref_theme_cover_based_style_fruitsalad">Fruit Salad</string>
<string name="pref_theme_cover_based_style_monochrome">Monochrome</string>
<string name="pref_theme_cover_based_style_fidelity">Fidelity</string>
<string name="pref_theme_cover_based_style_content">Content</string>
<string name="pref_expand_related_titles">Expand Related titles</string>
<string name="pref_expand_related_titles_summary">If turned off, related titles won\'t automatically load &amp; show expanded</string>

Expand Down

0 comments on commit 10c4938

Please sign in to comment.