mirror of
https://github.com/TeamPiped/Piped.git
synced 2024-08-14 23:57:27 +00:00
parent
acff16a8d4
commit
001f2917f6
2 changed files with 7 additions and 0 deletions
|
@ -7,6 +7,7 @@
|
||||||
<link rel="icon" href="/favicon.ico" />
|
<link rel="icon" href="/favicon.ico" />
|
||||||
<link title="Piped" type="application/opensearchdescription+xml" rel="search" href="/opensearch.xml" />
|
<link title="Piped" type="application/opensearchdescription+xml" rel="search" href="/opensearch.xml" />
|
||||||
<title>Piped</title>
|
<title>Piped</title>
|
||||||
|
<meta name="theme-color" content="#0f0f0f">
|
||||||
<meta property="og:title" content="Piped" />
|
<meta property="og:title" content="Piped" />
|
||||||
<meta property="og:type" content="website" />
|
<meta property="og:type" content="website" />
|
||||||
<meta property="og:image" content="/img/icons/favicon-32x32.png" />
|
<meta property="og:image" content="/img/icons/favicon-32x32.png" />
|
||||||
|
|
|
@ -34,6 +34,12 @@ export default {
|
||||||
if (themePref == "auto") this.theme = darkModePreference.matches ? "dark" : "light";
|
if (themePref == "auto") this.theme = darkModePreference.matches ? "dark" : "light";
|
||||||
else this.theme = themePref;
|
else this.theme = themePref;
|
||||||
|
|
||||||
|
// Change title bar color to white
|
||||||
|
if (this.theme === "light") {
|
||||||
|
const themeColor = document.querySelector("meta[name='theme-color']");
|
||||||
|
themeColor.setAttribute("content", "#FFF");
|
||||||
|
}
|
||||||
|
|
||||||
// Used for the scrollbar
|
// Used for the scrollbar
|
||||||
const root = document.querySelector(":root");
|
const root = document.querySelector(":root");
|
||||||
this.theme == "dark" ? root.classList.add("dark") : root.classList.remove("dark");
|
this.theme == "dark" ? root.classList.add("dark") : root.classList.remove("dark");
|
||||||
|
|
Loading…
Reference in a new issue