Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 38 additions & 2 deletions apps/web-dashboard/index.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/png" href="https://cdn.jsdelivr.net/gh/yash-pouranik/urBackend/apps/web-dashboard/public/LOGO_SQ.png" />
<link
rel="icon"
type="image/png"
href="https://cdn.jsdelivr.net/gh/yash-pouranik/urBackend/apps/web-dashboard/public/LOGO_SQ.png"
/>
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>urBackend | Instant Backend for Developers</title>
<!-- Google Fonts -->
Expand All @@ -12,6 +16,38 @@
href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;600&display=swap"
rel="stylesheet"
/>
<script>
(function () {
var storedValue = null;

try {
storedValue = localStorage.getItem("urbackend-theme");
} catch (e) {
/* storage unavailable; fall back to defaults */
}
Comment thread
aliyasyeddd marked this conversation as resolved.

var normalizedValue = (storedValue || "").toLowerCase();
var shouldUseLightMode;

if (normalizedValue) {
shouldUseLightMode =
normalizedValue === "light" || normalizedValue === "light-mode";
} else {
shouldUseLightMode =
window.matchMedia &&
window.matchMedia("(prefers-color-scheme: light)").matches;
}

document.documentElement.classList.toggle(
"light-mode",
shouldUseLightMode,
);
document.documentElement.classList.toggle(
"light-mode",
shouldUseLightMode,
);
})();
</script>
Comment thread
aliyasyeddd marked this conversation as resolved.
</head>
<body>
<div id="root"></div>
Expand Down
Loading
Loading