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
18 changes: 15 additions & 3 deletions .vitepress/config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,15 @@ export default defineConfig({
title: "Tech Certification Study Notes",
description: "Comprehensive study notes for various technology certifications",

// Dark by default for every visitor, with the toggle to switch to light (docs/DESIGN.md §3 on gobinath.com)
appearance: 'dark',

// Render pages dark so the site is dark without JavaScript too; the head script removes it for light.
transformHtml(code) {
return code.replace(/<html(\s[^>]*)?>/, (tag) =>
/class="/.test(tag) ? tag.replace('class="', 'class="dark ') : tag.replace('<html', '<html class="dark"'))
},

vite: {
build: {
target: 'esnext'
Expand Down Expand Up @@ -76,7 +85,11 @@ export default defineConfig({
head: [
['link', { rel: 'icon', href: '/favicon.ico' }],
['meta', { name: 'robots', content: 'index, follow' }],
['meta', { name: 'theme-color', content: '#10b981' }],
['meta', { name: 'theme-color', content: '#0b0b0a' }],
// Theme: dark by default for every visitor (gobinath.com docs/DESIGN.md §3). The <html> is rendered
// with class="dark" (see transformHtml) so it is dark without JavaScript; this removes it before
// paint only if the visitor chose light.
['script', {}, `;(function(){try{var p=localStorage.getItem('vitepress-theme-appearance');var l=p==='light'||(p==='auto'&&!matchMedia('(prefers-color-scheme: dark)').matches);if(l){document.documentElement.classList.remove('dark');document.querySelector('meta[name="theme-color"]').content='#f7f6f0'}}catch(e){}})()`],
['meta', { property: 'og:type', content: 'website' }],
['meta', { property: 'og:locale', content: 'en' }],
['meta', { property: 'og:site_name', content: 'Tech Certification Study Notes' }],
Expand All @@ -99,8 +112,7 @@ export default defineConfig({
}
})],

// Fonts — self-hosted (Inter bundled by VitePress, Dancing Script in /fonts/)
['link', { rel: 'preload', href: '/fonts/dancing-script-latin.woff2', as: 'font', type: 'font/woff2', crossorigin: '' }],
// Fonts: Archivo, Newsreader, JetBrains Mono, self-hosted through Fontsource (imported in theme/index.ts)

// Umami Analytics (Privacy-First)
['link', { rel: 'preconnect', href: 'https://api-gateway.umami.dev' }],
Expand Down
38 changes: 19 additions & 19 deletions .vitepress/theme/components/AIChatBot.vue
Original file line number Diff line number Diff line change
Expand Up @@ -235,8 +235,8 @@ const exampleQuestions = [
<rect class="bot-eye left-eye" x="17" y="23" width="12" height="12" rx="4" fill="white"/>
<rect class="bot-eye right-eye" x="35" y="23" width="12" height="12" rx="4" fill="white"/>
<!-- Pupils -->
<circle class="bot-pupil" cx="23" cy="29" r="3" fill="#064e3b"/>
<circle class="bot-pupil" cx="41" cy="29" r="3" fill="#064e3b"/>
<circle class="bot-pupil" cx="23" cy="29" r="3" fill="#121211"/>
<circle class="bot-pupil" cx="41" cy="29" r="3" fill="#121211"/>
</g>
<!-- Mouth -->
<rect x="21" y="40" width="22" height="5" rx="2.5" fill="white" fill-opacity="0.85"/>
Expand All @@ -245,7 +245,7 @@ const exampleQuestions = [
<line x1="36" y1="40" x2="36" y2="45" stroke="var(--vp-c-brand-1)" stroke-width="1.5"/>
<!-- AI label near antenna, top-right -->
<g class="ai-label-group">
<circle class="ai-dot-svg" cx="43" cy="5" r="3" fill="#34d399"/>
<circle class="ai-dot-svg" cx="43" cy="5" r="3" fill="#ffd400"/>
<text x="54" y="9" font-size="11" font-weight="900" fill="var(--vp-c-brand-1)" text-anchor="middle" font-family="system-ui, sans-serif" letter-spacing="0.5">AI</text>
</g>
</svg>
Expand Down Expand Up @@ -397,16 +397,16 @@ const exampleQuestions = [

.chatbot-fab:hover {
transform: scale(1.1);
filter: drop-shadow(0 4px 12px rgba(16, 185, 129, 0.4));
filter: drop-shadow(0 4px 12px rgba(255, 212, 0, 0.4));
}

.chatbot-fab.pulse .bot-svg {
animation: fab-pulse 2.5s ease-in-out infinite;
}

@keyframes fab-pulse {
0%, 100% { filter: drop-shadow(0 2px 6px rgba(16, 185, 129, 0.3)); }
50% { filter: drop-shadow(0 2px 14px rgba(16, 185, 129, 0.6)); }
0%, 100% { filter: drop-shadow(0 2px 6px rgba(255, 212, 0, 0.3)); }
50% { filter: drop-shadow(0 2px 14px rgba(255, 212, 0, 0.6)); }
}

.fab-icon {
Expand Down Expand Up @@ -448,12 +448,12 @@ const exampleQuestions = [
/* AI dot pulsating glow (inside SVG) */
.fab-icon :deep(.ai-dot-svg) {
animation: ai-dot-pulse 2s ease-in-out infinite;
filter: drop-shadow(0 0 2px #34d399);
filter: drop-shadow(0 0 2px #ffd400);
}

@keyframes ai-dot-pulse {
0%, 100% { r: 3; opacity: 1; filter: drop-shadow(0 0 2px #34d399); }
50% { r: 4; opacity: 0.7; filter: drop-shadow(0 0 6px #34d399); }
0%, 100% { r: 3; opacity: 1; filter: drop-shadow(0 0 2px #ffd400); }
50% { r: 4; opacity: 0.7; filter: drop-shadow(0 0 6px #ffd400); }
}

/* Chat Panel */
Expand Down Expand Up @@ -548,7 +548,7 @@ html.dark .chatbot-panel {

.mode-btn.active {
background: var(--vp-c-brand-1);
color: white;
color: var(--vp-c-bg);
border-color: var(--vp-c-brand-1);
}

Expand Down Expand Up @@ -602,7 +602,7 @@ html.dark .chatbot-panel {

.example-btn:hover {
border-color: var(--vp-c-brand-1);
background: rgba(16, 185, 129, 0.08);
background: rgba(255, 212, 0, 0.08);
}

/* Messages */
Expand Down Expand Up @@ -682,8 +682,8 @@ html.dark .message-bubble :deep(pre) {
}

.chat-message.user .message-bubble {
background: linear-gradient(135deg, #10b981, #059669);
color: white;
background: var(--gobi-y);
color: #121211;
border-bottom-right-radius: 4px;
}

Expand Down Expand Up @@ -721,8 +721,8 @@ html.dark .message-bubble :deep(pre) {
/* Flashcard mode */
.generate-btn {
padding: 10px 24px;
background: linear-gradient(135deg, #10b981, #059669);
color: white;
background: var(--gobi-y);
color: #121211;
border: none;
border-radius: 10px;
cursor: pointer;
Expand All @@ -733,7 +733,7 @@ html.dark .message-bubble :deep(pre) {

.generate-btn:hover {
transform: translateY(-1px);
box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
box-shadow: 0 4px 12px rgba(255, 212, 0, 0.3);
}

.generate-btn.regenerate {
Expand All @@ -746,7 +746,7 @@ html.dark .message-bubble :deep(pre) {
}

.generate-btn.regenerate:hover {
background: rgba(16, 185, 129, 0.08);
background: rgba(255, 212, 0, 0.08);
}

.flashcard-loading {
Expand Down Expand Up @@ -826,7 +826,7 @@ html.dark .message-bubble :deep(pre) {
border-radius: 10px;
border: none;
background: var(--vp-c-brand-1);
color: white;
color: var(--vp-c-bg);
cursor: pointer;
display: flex;
align-items: center;
Expand All @@ -836,7 +836,7 @@ html.dark .message-bubble :deep(pre) {
}

.send-btn:hover:not(:disabled) {
background: #059669;
background: #f0c800;
}

.send-btn:disabled {
Expand Down
8 changes: 4 additions & 4 deletions .vitepress/theme/components/ExamMeta.vue
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ defineProps({
align-items: center;
gap: 0.35rem;
padding: 0.28rem 0.7rem;
background: rgba(16, 185, 129, 0.08);
border: 1px solid rgba(16, 185, 129, 0.22);
background: rgba(255, 212, 0, 0.08);
border: 1px solid rgba(255, 212, 0, 0.22);
border-radius: 20px;
font-size: 0.78rem;
font-weight: 500;
Expand All @@ -60,8 +60,8 @@ defineProps({
}

.exam-pill:hover {
background: rgba(16, 185, 129, 0.14);
border-color: rgba(16, 185, 129, 0.4);
background: rgba(255, 212, 0, 0.14);
border-color: rgba(255, 212, 0, 0.4);
}

.pill-icon {
Expand Down
2 changes: 1 addition & 1 deletion .vitepress/theme/components/FlashcardDeck.vue
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ const reset = () => {
}

.dot.active {
background: var(--vp-c-brand);
background: var(--gobi-y);
width: 12px;
height: 12px;
}
Expand Down
2 changes: 1 addition & 1 deletion .vitepress/theme/components/ImageModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ onUnmounted(() => {
align-items: center;
gap: 0.5rem;
background: var(--vp-c-brand-1);
color: white;
color: var(--vp-c-bg);
padding: 0.75rem 1.5rem;
border-radius: 30px;
text-decoration: none !important;
Expand Down
10 changes: 5 additions & 5 deletions .vitepress/theme/components/ShareButtons.vue
Original file line number Diff line number Diff line change
Expand Up @@ -222,12 +222,12 @@ const openShare = (url: string) => {
}

.share-btn.copy {
background: rgba(16, 185, 129, 0.2);
box-shadow: 0 4px 12px rgba(16, 185, 129, 0.1);
background: rgba(255, 212, 0, 0.2);
box-shadow: 0 4px 12px rgba(255, 212, 0, 0.1);
}
.share-btn.copy:hover {
background: rgba(16, 185, 129, 0.35);
box-shadow: 0 6px 20px rgba(16, 185, 129, 0.25);
background: rgba(255, 212, 0, 0.35);
box-shadow: 0 6px 20px rgba(255, 212, 0, 0.25);
}

/* Light mode: slightly more opaque for visibility */
Expand All @@ -239,7 +239,7 @@ const openShare = (url: string) => {
:not(.dark) .share-btn.reddit { color: #FF4500; }
:not(.dark) .share-btn.facebook { color: #1877F2; }
:not(.dark) .share-btn.email { color: #6B7280; }
:not(.dark) .share-btn.copy { color: #10b981; }
:not(.dark) .share-btn.copy { color: #121211; }

@media (max-width: 640px) {
.share-buttons {
Expand Down
Loading
Loading