Skip to content

Commit 9b31657

Browse files
authored
Adding new theme (#475)
1 parent 45bfa53 commit 9b31657

4 files changed

Lines changed: 133 additions & 0 deletions

File tree

app/src/main/java/com/dessalines/thumbkey/ui/theme/Color.kt

Lines changed: 130 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -657,3 +657,133 @@ fun dracula(): Pair<ColorScheme, ColorScheme> {
657657
)
658658
return Pair(light, dark)
659659
}
660+
fun twilight(): Pair<ColorScheme, ColorScheme> {
661+
val md_theme_light_primary = Color(0xFF44475A)
662+
val md_theme_light_onPrimary = Color(0xFFFFFFFF)
663+
val md_theme_light_primaryContainer = Color(0xFFDDE1FF)
664+
val md_theme_light_onPrimaryContainer = Color(0xFF001257)
665+
val md_theme_light_secondary = Color(0xFF6272A3)
666+
val md_theme_light_onSecondary = Color(0xFFFFFFFF)
667+
val md_theme_light_secondaryContainer = Color(0xFFDFE1F9)
668+
val md_theme_light_onSecondaryContainer = Color(0xFF171B2C)
669+
val md_theme_light_tertiary = Color(0xFFB978C9)
670+
val md_theme_light_onTertiary = Color(0xFFFFFFFF)
671+
val md_theme_light_tertiaryContainer = Color(0xFFFEB76C)
672+
val md_theme_light_onTertiaryContainer = Color(0xFF2D1228)
673+
val md_theme_light_error = Color(0xFFBA1A1A)
674+
val md_theme_light_errorContainer = Color(0xFFFFDAD6)
675+
val md_theme_light_onError = Color(0xFFFFFFFF)
676+
val md_theme_light_onErrorContainer = Color(0xFF410002)
677+
val md_theme_light_background = Color(0xFFF7F7F1)
678+
val md_theme_light_onBackground = Color(0xFF794172)
679+
val md_theme_light_surface = Color(0xFFA3FEFE)
680+
val md_theme_light_onSurface = Color(0xFFB978C9)
681+
val md_theme_light_surfaceVariant = Color(0xFF8AE8FC)
682+
val md_theme_light_onSurfaceVariant = Color(0xFF44475A)
683+
val md_theme_light_outline = Color(0xFF44475A)
684+
val md_theme_light_inverseOnSurface = Color(0xFFF3F0F4)
685+
val md_theme_light_inverseSurface = Color(0xFF303034)
686+
val md_theme_light_inversePrimary = Color(0xFFFEFEA4)
687+
val md_theme_light_shadow = Color(0xFF000000)
688+
val md_theme_light_surfaceTint = Color(0xFF4758A9)
689+
val md_theme_light_outlineVariant = Color(0xFFC6C5D0)
690+
val md_theme_light_scrim = Color(0xFF000000)
691+
692+
val md_theme_dark_primary = Color(0xFFF7F7F1)
693+
val md_theme_dark_onPrimary = Color(0xFF132778)
694+
val md_theme_dark_primaryContainer = Color(0xFF2E4090)
695+
val md_theme_dark_onPrimaryContainer = Color(0xFFDDE1FF)
696+
val md_theme_dark_secondary = Color(0xFFBD93F9)
697+
val md_theme_dark_onSecondary = Color(0xFF2C2F42)
698+
val md_theme_dark_secondaryContainer = Color(0xFF434659)
699+
val md_theme_dark_onSecondaryContainer = Color(0xFFDFE1F9)
700+
val md_theme_dark_tertiary = Color(0xFFE5BAD8)
701+
val md_theme_dark_onTertiary = Color(0xFF44263E)
702+
val md_theme_dark_tertiaryContainer = Color(0xFFFEB76C)
703+
val md_theme_dark_onTertiaryContainer = Color(0xFFFFD7F2)
704+
val md_theme_dark_error = Color(0xFFFFB4AB)
705+
val md_theme_dark_errorContainer = Color(0xFF93000A)
706+
val md_theme_dark_onError = Color(0xFF690005)
707+
val md_theme_dark_onErrorContainer = Color(0xFFFFDAD6)
708+
val md_theme_dark_background = Color(0xFF1D1E26)
709+
val md_theme_dark_onBackground = Color(0xFFE4E1E6)
710+
val md_theme_dark_surface = Color(0xFF282A36)
711+
val md_theme_dark_onSurface = Color(0xFFF8F8F2)
712+
val md_theme_dark_surfaceVariant = Color(0xFF44475A)
713+
val md_theme_dark_onSurfaceVariant = Color(0xFFFF79C6)
714+
val md_theme_dark_outline = Color(0xFF6272A4)
715+
val md_theme_dark_inverseOnSurface = Color(0xFF1B1B1F)
716+
val md_theme_dark_inverseSurface = Color(0xFFE4E1E6)
717+
val md_theme_dark_inversePrimary = Color(0xFFF0F98B)
718+
val md_theme_dark_shadow = Color(0xFF000000)
719+
val md_theme_dark_surfaceTint = Color(0xFFB9C3FF)
720+
val md_theme_dark_outlineVariant = Color(0xFF45464F)
721+
val md_theme_dark_scrim = Color(0xFF000000)
722+
723+
val seed = Color(0xFF44475A)
724+
725+
val light = lightColorScheme(
726+
primary = md_theme_light_primary,
727+
onPrimary = md_theme_light_onPrimary,
728+
primaryContainer = md_theme_light_primaryContainer,
729+
onPrimaryContainer = md_theme_light_onPrimaryContainer,
730+
secondary = md_theme_light_secondary,
731+
onSecondary = md_theme_light_onSecondary,
732+
secondaryContainer = md_theme_light_secondaryContainer,
733+
onSecondaryContainer = md_theme_light_onSecondaryContainer,
734+
tertiary = md_theme_light_tertiary,
735+
onTertiary = md_theme_light_onTertiary,
736+
tertiaryContainer = md_theme_light_tertiaryContainer,
737+
onTertiaryContainer = md_theme_light_onTertiaryContainer,
738+
error = md_theme_light_error,
739+
errorContainer = md_theme_light_errorContainer,
740+
onError = md_theme_light_onError,
741+
onErrorContainer = md_theme_light_onErrorContainer,
742+
background = md_theme_light_background,
743+
onBackground = md_theme_light_onBackground,
744+
surface = md_theme_light_surface,
745+
onSurface = md_theme_light_onSurface,
746+
surfaceVariant = md_theme_light_surfaceVariant,
747+
onSurfaceVariant = md_theme_light_onSurfaceVariant,
748+
outline = md_theme_light_outline,
749+
inverseOnSurface = md_theme_light_inverseOnSurface,
750+
inverseSurface = md_theme_light_inverseSurface,
751+
inversePrimary = md_theme_light_inversePrimary,
752+
surfaceTint = md_theme_light_surfaceTint,
753+
outlineVariant = md_theme_light_outlineVariant,
754+
scrim = md_theme_light_scrim,
755+
)
756+
757+
val dark = darkColorScheme(
758+
primary = md_theme_dark_primary,
759+
onPrimary = md_theme_dark_onPrimary,
760+
primaryContainer = md_theme_dark_primaryContainer,
761+
onPrimaryContainer = md_theme_dark_onPrimaryContainer,
762+
secondary = md_theme_dark_secondary,
763+
onSecondary = md_theme_dark_onSecondary,
764+
secondaryContainer = md_theme_dark_secondaryContainer,
765+
onSecondaryContainer = md_theme_dark_onSecondaryContainer,
766+
tertiary = md_theme_dark_tertiary,
767+
onTertiary = md_theme_dark_onTertiary,
768+
tertiaryContainer = md_theme_dark_tertiaryContainer,
769+
onTertiaryContainer = md_theme_dark_onTertiaryContainer,
770+
error = md_theme_dark_error,
771+
errorContainer = md_theme_dark_errorContainer,
772+
onError = md_theme_dark_onError,
773+
onErrorContainer = md_theme_dark_onErrorContainer,
774+
background = md_theme_dark_background,
775+
onBackground = md_theme_dark_onBackground,
776+
surface = md_theme_dark_surface,
777+
onSurface = md_theme_dark_onSurface,
778+
surfaceVariant = md_theme_dark_surfaceVariant,
779+
onSurfaceVariant = md_theme_dark_onSurfaceVariant,
780+
outline = md_theme_dark_outline,
781+
inverseOnSurface = md_theme_dark_inverseOnSurface,
782+
inverseSurface = md_theme_dark_inverseSurface,
783+
inversePrimary = md_theme_dark_inversePrimary,
784+
surfaceTint = md_theme_dark_surfaceTint,
785+
outlineVariant = md_theme_dark_outlineVariant,
786+
scrim = md_theme_dark_scrim,
787+
)
788+
return Pair(light, dark)
789+
}

app/src/main/java/com/dessalines/thumbkey/ui/theme/Theme.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ fun ThumbkeyTheme(
3636
ThemeColor.Srcery -> srcery()
3737
ThemeColor.Blue -> blue()
3838
ThemeColor.Dracula -> dracula()
39+
ThemeColor.Twilight -> twilight()
3940
}
4041

4142
val systemTheme = if (!isSystemInDarkTheme()) {

app/src/main/java/com/dessalines/thumbkey/utils/Types.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ enum class ThemeColor(private val stringId: Int) {
9292
Srcery(R.string.srcery),
9393
Blue(R.string.blue),
9494
Dracula(R.string.dracula),
95+
Twilight(R.string.twilight),
9596
;
9697

9798
@Composable

app/src/main/res/values/strings.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
<string name="srcery">Srcery</string>
1111
<string name="blue">Blue</string>
1212
<string name="dracula">Dracula</string>
13+
<string name="twilight">Twilight</string>
1314
<string name="center">Center</string>
1415
<string name="right">Right</string>
1516
<string name="left">Left</string>

0 commit comments

Comments
 (0)