Skip to content

Commit 8775fa8

Browse files
committed
feat: add support for light and dark themes
1 parent dcc66af commit 8775fa8

3 files changed

Lines changed: 22 additions & 9 deletions

File tree

css/styles.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ body {
4949

5050
.github-btn {
5151
background: linear-gradient(135deg, #689d6a, #427b58);
52-
border: 1px solid #427b58;
52+
/* border: 1px solid #427b58; */
5353
transition: all 0.3s ease;
5454
}
5555

index.html

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,26 @@
55
<meta name="viewport" content="width=device-width, initial-scale=1.0">
66
<title>CacheVector - Advancing ML Libraries</title>
77
<script src="https://cdn.tailwindcss.com"></script>
8+
<script>
9+
tailwind.config = {
10+
darkMode: 'class',
11+
}
12+
</script>
813
<script src="js/main.js"></script>
14+
<script src="js/theme.js" defer></script>
15+
16+
<link rel="icon" type="image/png" href="assets/favicons/favicon-96x96.png" sizes="96x96" />
17+
<link rel="icon" type="image/svg+xml" href="assets/favicons/favicon.svg" />
18+
<link rel="shortcut icon" href="assets/favicons/favicon.ico" />
19+
<link rel="apple-touch-icon" sizes="180x180" href="assets/favicons/apple-touch-icon.png" />
20+
<link rel="manifest" href="assets/favicons/site.webmanifest" />
21+
922
<link rel="stylesheet" href="css/styles.css">
1023
</head>
11-
<body class="bg-[#1d2021] text-[#fbf1c7] flex flex-col min-h-screen">
24+
<body class="bg-[#f9f5d7] dark:bg-[#1d2021] text-[#1d2021] dark:text-[#f9f5d7] flex flex-col min-h-screen">
1225

1326
<!-- Navigation -->
14-
<div class="w-full flex justify-center text-lg">
27+
<div class="w-full flex justify-center text-md">
1528
<nav class="w-3/5 flex items-center justify-between p-6">
1629
<img src="assets/logos/Cache_Vector.svg" alt="CacheVector Logo" class="w-12 h-12">
1730

@@ -22,7 +35,7 @@
2235
<a href="#Blogs" class="nav-item space-mono-bold">[#Blogs]</a>
2336
</div>
2437

25-
<button class="hover:text-white">
38+
<button id="theme-toggle" class="hover:text-[#427b58]">
2639
<svg class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20">
2740
<path fill-rule="evenodd" d="M10 2a1 1 0 011 1v1a1 1 0 11-2 0V3a1 1 0 011-1zm4 8a4 4 0 11-8 0 4 4 0 018 0zm-.464 4.95l.707.707a1 1 0 001.414-1.414l-.707-.707a1 1 0 00-1.414 1.414zm2.12-10.607a1 1 0 010 1.414l-.706.707a1 1 0 11-1.414-1.414l.707-.707a1 1 0 011.414 0zM17 11a1 1 0 100-2h-1a1 1 0 100 2h1zm-7 4a1 1 0 011 1v1a1 1 0 11-2 0v-1a1 1 0 011-1zM5.05 6.464A1 1 0 106.465 5.05l-.708-.707a1 1 0 00-1.414 1.414l.707.707zm1.414 8.486l-.707.707a1 1 0 01-1.414-1.414l.707-.707a1 1 0 011.414 1.414zM4 11a1 1 0 100-2H3a1 1 0 000 2h1z" clip-rule="evenodd" />
2841
</svg>
@@ -45,7 +58,7 @@ <h1 class="text-6xl md:text-8xl font-bold mb-8">
4558
</p>
4659

4760
<div class="flex flex-col items-center justify-center space-y-4 ">
48-
<a href="https://github.com/cachevector" target="_blank" class="github-btn px-6 py-3 rounded-sm font-medium flex items-center space-x-2">
61+
<a href="https://github.com/cachevector" target="_blank" class="border border-[#fbf1c7] dark:border-[#427b58] github-btn px-6 py-3 rounded-sm font-bold text-[#f9f5d7] flex items-center space-x-2">
4962
<svg class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20">
5063
<path fill-rule="evenodd" d="M10 0C4.477 0 0 4.484 0 10.017c0 4.425 2.865 8.18 6.839 9.504.5.092.682-.217.682-.483 0-.237-.008-.868-.013-1.703-2.782.605-3.369-1.343-3.369-1.343-.454-1.158-1.11-1.466-1.11-1.466-.908-.62.069-.608.069-.608 1.003.07 1.531 1.032 1.531 1.032.892 1.53 2.341 1.088 2.91.832.092-.647.35-1.088.636-1.338-2.22-.253-4.555-1.113-4.555-4.951 0-1.093.39-1.988 1.029-2.688-.103-.253-.446-1.272.098-2.65 0 0 .84-.27 2.75 1.026A9.564 9.564 0 0110 4.844c.85.004 1.705.115 2.504.337 1.909-1.296 2.747-1.027 2.747-1.027.546 1.379.203 2.398.1 2.651.64.7 1.028 1.595 1.028 2.688 0 3.848-2.339 4.695-4.566 4.942.359.31.678.921.678 1.856 0 1.338-.012 2.419-.012 2.747 0 .268.18.58.688.482A10.019 10.019 0 0020 10.017C20 4.484 15.522 0 10 0z" clip-rule="evenodd" />
5164
</svg>
@@ -62,7 +75,7 @@ <h1 class="text-6xl md:text-8xl font-bold mb-8">
6275
</div>
6376

6477
<!-- Footer -->
65-
<footer class="w-3/5 container mx-auto px-6 py-8 border-t border-[#fbf1c7] text-lg">
78+
<footer class="w-3/5 container mx-auto px-6 py-8 border-t border-[#1d2021] dark:border-[#f9f5d7] text-lg">
6679
<div class="flex items-center justify-between">
6780

6881
<!-- Left Side -->

pages/mission.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
<body>
22
<section id="mission" class="container mx-auto px-6 py-8">
33
<div class="rounded-lg p-4 max-w-4xl mx-auto text-justify">
4-
<h2 class="text-[#689d6a] text-left text-2xl font-bold mb-12 pb-4 border-b-2 border-[#689d6a]">
4+
<h2 class="text-[#427b58] dark:text-[#689d6a] text-left text-2xl font-bold mb-12 pb-4 border-b-2 border-[#689d6a]">
55
# our mission
66
</h2>
77

8-
<div class="space-y-6 text-[#fbf1c7] leading-relaxed">
8+
<div class="space-y-6 text-[#1d2021] dark:text-[#f9f5d7] leading-relaxed">
99
<p>
1010
at cachevector, we're building the future one function at a time.
1111
</p>
@@ -22,7 +22,7 @@ <h2 class="text-[#689d6a] text-left text-2xl font-bold mb-12 pb-4 border-b-2 bor
2222
we don't just tinker. we publish, package, and push to prod. from lightweight utils to heavy-duty research, if it's solving a real problem, we're in. and if it helps devs, researchers, or the next generation of builders do more with less friction - that's exactly our kind of project.
2323
</p>
2424

25-
<p class="text-[#689d6a] font-semibold">
25+
<p class="text-[#427b58] font-semibold">
2626
follow the work. star the ideas. we're not trying to be loud - we're trying to be useful.
2727
</p>
2828

0 commit comments

Comments
 (0)