export enum StyleColor {
backgroundColor, // 背景色
pageColor, // 页面颜色
cardBgColor, // 悬浮卡片背景色
cardBgActiveColor, // 悬浮卡片背景色激活态颜色
textNormalColor, // 普通文字颜色
textBoldColor, // 加粗文字颜色
blackTextActiveColor, // 日间黑色激活文本颜色
texSubColor, // 次文字颜色
shadowColor, // 阴影颜色
}
export class StyleRes {
static getStyleColor(styleColor: StyleColor, lightMode: boolean) {
let color = "#ffffffff";
switch (styleColor) {
case StyleColor.backgroundColor:
color = lightMode ? "#ffffffff" : "#FF191B27";
break;
case StyleColor.pageColor:
color = lightMode ? "#fff7f8fb" : "#FF191B27";
break;
case StyleColor.cardBgColor:
color = lightMode ? "#ffffffff" : "#FF292B38";
break;
case StyleColor.cardBgActiveColor:
color = lightMode ? "#FFE0EFFF" : "#FF162741";
break;
case StyleColor.textNormalColor:
color = lightMode ? "#FF465069" : "#FF999FB5";
break;
case StyleColor.textBoldColor:
color = lightMode ? "#FF191B27" : "#FF999FB5";
break;
case StyleColor.blackTextActiveColor:
color = lightMode ? "#FF191B27" : "#FF0080FF";
break;
case StyleColor.texSubColor:
color = lightMode ? "#FF465069" : "#FF999FB5";
break;
case StyleColor.shadowColor:
color = lightMode ? "#14000000" : "#FF222634";
break;
}
return color;
}
}
评论