replace primary color with textColor

This commit is contained in:
Halit Aksoy 2022-07-13 15:21:30 +03:00
parent fb6045c229
commit 50c6dd92a6
5 changed files with 12 additions and 12 deletions

View File

@ -202,8 +202,8 @@ const Home: FunctionComponent<{ initial?: number }> = ({ initial = 0 }) => {
};
const menuTextColor = getColorByBrightness(
context.themeManager.theme.appBarBgColor,
context.themeManager.theme.primary,
context.themeManager.theme.primaryLight
context.themeManager.theme.textColor,
context.themeManager.theme.textLightColor
);
return (
<div
@ -225,8 +225,8 @@ const Home: FunctionComponent<{ initial?: number }> = ({ initial = 0 }) => {
borderTopRightRadius: "1vw",
minWidth: "10vw",
minHeight: "1vw",
background: context.themeManager.theme.primary,
color: context.themeManager.theme.primaryLight,
background: context.themeManager.theme.textColor,
color: context.themeManager.theme.textLightColor,
}}
>
{connectionStateText()}

View File

@ -70,8 +70,8 @@ const StoreView: FunctionComponent<{
));
const textColor = getColorByBrightness(
pitViewModel.pitColor,
context.themeManager.theme.primary,
context.themeManager.theme.primaryLight
context.themeManager.theme.textColor,
context.themeManager.theme.textLightColor
);
return (
<div

View File

@ -11,8 +11,8 @@ const Button: FunctionComponent<{
}> = ({ context, text, color, onClick }) => {
const textColor = getColorByBrightness(
color,
context.themeManager.theme.primary,
context.themeManager.theme.primaryLight
context.themeManager.theme.textColor,
context.themeManager.theme.textLightColor
);
return (
<button

View File

@ -89,8 +89,8 @@ const InfoPanel: FunctionComponent<{
: context.themeManager.theme.boardColor;
const textColor = getColorByBrightness(
containerColor,
context.themeManager.theme.primary,
context.themeManager.theme.primaryLight
context.themeManager.theme.textColor,
context.themeManager.theme.textLightColor
);
const text = getInfoPanelTextByGameState({
context,

View File

@ -1,8 +1,8 @@
export type Theme = {
id: string;
name: string;
primary: string;
primaryLight: string;
textColor: string;
textLightColor: string;
background: string;
appBarBgColor: string;
playerTurnColor: string;