A Q&A platform software for teams at any scales. Whether it's a community forum, help center, or knowledge management platform, you can always count on Apache Answer.
fix: meta theme-color support primary color
shuaic7c2aad20501
diff --git a/ui/public/index.html b/ui/public/index.htmlindex f754cf9e..b7bce50c 100644--- a/ui/public/index.html+++ b/ui/public/index.html@@ -3,7 +3,7 @@<head><meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover" />- <meta name="theme-color" content="#000000" />+ <meta name="theme-color" content="#0033FF" /><meta name="generator" content="Answer - https://github.com/answerdev/answer"><link rel="manifest" href="%PUBLIC_URL%/manifest.json" /></head>diff --git a/ui/src/components/CustomizeTheme/index.tsx b/ui/src/components/CustomizeTheme/index.tsxindex 42313fb4..e9f91576 100644--- a/ui/src/components/CustomizeTheme/index.tsx+++ b/ui/src/components/CustomizeTheme/index.tsx@@ -11,6 +11,9 @@ const Index: FC = () => {let primaryColor;if (theme_config?.[theme]?.primary_color) {primaryColor = Color(theme_config[theme].primary_color);+ document+ .querySelector('meta[name="theme-color"]')+ ?.setAttribute('content', primaryColor.hex());}return (