first commit
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
+++
|
||||||
|
date = '{{ .Date }}'
|
||||||
|
draft = true
|
||||||
|
title = '{{ replace .File.ContentBaseName "-" " " | title }}'
|
||||||
|
+++
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
baseURL = 'https://juhlin.io/'
|
||||||
|
languageCode = 'en-us'
|
||||||
|
title = 'juhlin.io'
|
||||||
|
|
||||||
|
[params]
|
||||||
|
description = "Personal portal for juhlin.io"
|
||||||
|
name = "Juhlin"
|
||||||
|
tagline = "Welcome to my personal portal"
|
||||||
|
|
||||||
|
[[params.links]]
|
||||||
|
name = "Blog"
|
||||||
|
url = "https://blog.juhlin.io"
|
||||||
|
icon = "edit-3"
|
||||||
|
description = "Thoughts on software engineering and more"
|
||||||
|
|
||||||
|
[[params.links]]
|
||||||
|
name = "Projects"
|
||||||
|
url = "https://github.com/julle"
|
||||||
|
icon = "code"
|
||||||
|
description = "Open source work and experiments"
|
||||||
|
|
||||||
|
[[params.links]]
|
||||||
|
name = "LinkedIn"
|
||||||
|
url = "https://linkedin.com/in/juhlin"
|
||||||
|
icon = "linkedin"
|
||||||
|
description = "Professional profile"
|
||||||
|
|
||||||
|
[[params.links]]
|
||||||
|
name = "Twitter"
|
||||||
|
url = "https://twitter.com/juhlin"
|
||||||
|
icon = "twitter"
|
||||||
|
description = "Short thoughts and updates"
|
||||||
@@ -0,0 +1,443 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="{{ .Site.LanguageCode }}">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<title>{{ if .IsHome }}{{ .Site.Title }}{{ else }}{{ .Title }} | {{ .Site.Title }}{{ end }}</title>
|
||||||
|
<meta name="description" content="{{ .Site.Params.description }}">
|
||||||
|
<script src="https://cdn.tailwindcss.com"></script>
|
||||||
|
<script src="https://unpkg.com/lucide@latest"></script>
|
||||||
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||||
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||||
|
<link href="https://fonts.googleapis.com/css2?family=Press+Start+2P&family=Space+Grotesk:wght@400;500;600;700&display=swap" rel="stylesheet">
|
||||||
|
<style>
|
||||||
|
:root {
|
||||||
|
/* Default: FireRed */
|
||||||
|
--theme-primary: #f83800;
|
||||||
|
--theme-bg-color: #d05050;
|
||||||
|
--theme-bg-gradient-1: #c04040;
|
||||||
|
--theme-bg-gradient-2: #e06060;
|
||||||
|
--pkmn-border-light: #f8f8f8;
|
||||||
|
--pkmn-border-dark: #505050;
|
||||||
|
--pkmn-bg: #ffffff;
|
||||||
|
--pkmn-shadow: rgba(0,0,0,0.4);
|
||||||
|
--ink: #1b1b1b;
|
||||||
|
--paper: #fff7eb;
|
||||||
|
--shadow-soft: rgba(0,0,0,0.12);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Theme: LeafGreen */
|
||||||
|
:root.theme-green,
|
||||||
|
body.theme-green {
|
||||||
|
--theme-primary: #008000;
|
||||||
|
--theme-bg-color: #70d070;
|
||||||
|
--theme-bg-gradient-1: #68c068;
|
||||||
|
--theme-bg-gradient-2: #80e080;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Theme: WaterBlue */
|
||||||
|
:root.theme-blue,
|
||||||
|
body.theme-blue {
|
||||||
|
--theme-primary: #0060e0;
|
||||||
|
--theme-bg-color: #50a0e0;
|
||||||
|
--theme-bg-gradient-1: #4090d0;
|
||||||
|
--theme-bg-gradient-2: #60b0f0;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: 'Space Grotesk', system-ui, sans-serif;
|
||||||
|
background-color: var(--theme-bg-color);
|
||||||
|
background-image:
|
||||||
|
linear-gradient(45deg, rgba(255,255,255,0.08) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.08) 75%, rgba(255,255,255,0.08)),
|
||||||
|
linear-gradient(45deg, rgba(0,0,0,0.05) 25%, transparent 25%, transparent 75%, rgba(0,0,0,0.05) 75%, rgba(0,0,0,0.05)),
|
||||||
|
radial-gradient(1200px 800px at 10% 10%, rgba(255,255,255,0.18), transparent 55%),
|
||||||
|
radial-gradient(900px 600px at 90% 20%, rgba(0,0,0,0.15), transparent 60%);
|
||||||
|
background-size: 26px 26px, 26px 26px, auto, auto;
|
||||||
|
background-position: 0 0, 13px 13px, 0 0, 0 0;
|
||||||
|
box-shadow: inset 0 0 100px rgba(0,0,0,0.3);
|
||||||
|
transition: background-color 0.5s ease;
|
||||||
|
color: var(--ink);
|
||||||
|
position: relative;
|
||||||
|
isolation: isolate;
|
||||||
|
text-rendering: optimizeLegibility;
|
||||||
|
}
|
||||||
|
|
||||||
|
body::before,
|
||||||
|
body::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
inset: auto;
|
||||||
|
width: 520px;
|
||||||
|
height: 520px;
|
||||||
|
border-radius: 999px;
|
||||||
|
filter: blur(40px);
|
||||||
|
opacity: 0.35;
|
||||||
|
z-index: -1;
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
body::before {
|
||||||
|
top: -140px;
|
||||||
|
left: -120px;
|
||||||
|
background: radial-gradient(circle, rgba(255,255,255,0.8), rgba(255,255,255,0));
|
||||||
|
animation: floaty 14s ease-in-out infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
body::after {
|
||||||
|
bottom: -160px;
|
||||||
|
right: -100px;
|
||||||
|
background: radial-gradient(circle, rgba(0,0,0,0.4), rgba(0,0,0,0));
|
||||||
|
animation: floaty 18s ease-in-out infinite reverse;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Pokémon Menu Box Style */
|
||||||
|
.pkmn-box {
|
||||||
|
background-color: var(--pkmn-bg);
|
||||||
|
border: 2px solid var(--pkmn-border-dark);
|
||||||
|
border-radius: 4px;
|
||||||
|
box-shadow: 4px 4px 0 var(--pkmn-shadow), 0 16px 40px var(--shadow-soft);
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.pkmn-box::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
top: 2px;
|
||||||
|
left: 2px;
|
||||||
|
right: 2px;
|
||||||
|
bottom: 2px;
|
||||||
|
border: 2px solid #d0d0d8;
|
||||||
|
border-radius: 2px;
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.pkmn-text-shadow {
|
||||||
|
text-shadow: 2px 2px 0 #d0d0d0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.pixel {
|
||||||
|
font-family: 'Press Start 2P', cursive;
|
||||||
|
letter-spacing: 0.08em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-pop {
|
||||||
|
animation: pop-in 0.5s ease both;
|
||||||
|
animation-delay: var(--delay, 0ms);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Active State */
|
||||||
|
.menu-link.active .cursor { opacity: 1; }
|
||||||
|
.menu-link.active { color: #000; }
|
||||||
|
.menu-link.active .selector { display: block; }
|
||||||
|
|
||||||
|
.menu-link {
|
||||||
|
border-left: 3px solid transparent;
|
||||||
|
transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu-link:hover {
|
||||||
|
background-color: rgba(0,0,0,0.04);
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu-link.active {
|
||||||
|
background-color: rgba(0,0,0,0.05);
|
||||||
|
border-left-color: var(--theme-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu-link.active .cursor {
|
||||||
|
animation: blink 1.1s steps(2, end) infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Modal Styles */
|
||||||
|
.modal {
|
||||||
|
display: none;
|
||||||
|
position: fixed;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
background-color: rgba(0, 0, 0, 0.7);
|
||||||
|
z-index: 50;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
backdrop-filter: blur(2px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.modal.open {
|
||||||
|
display: flex;
|
||||||
|
animation: fade-in 0.2s ease-out;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Badge Styles */
|
||||||
|
.badge {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
background: #ccc;
|
||||||
|
border: 2px solid #505050;
|
||||||
|
border-radius: 50%;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 8px;
|
||||||
|
color: white;
|
||||||
|
text-shadow: 1px 1px 0 #000;
|
||||||
|
box-shadow: 0 2px 0 rgba(0,0,0,0.35);
|
||||||
|
}
|
||||||
|
.badge.js { background: #f7df1e; color: #000; text-shadow: none; border-radius: 0; }
|
||||||
|
.badge.go { background: #00add8; }
|
||||||
|
.badge.py { background: #3776ab; border-radius: 4px; }
|
||||||
|
.badge.ts { background: #3178c6; border-radius: 0; }
|
||||||
|
.badge.re { background: #61dafb; color: #000; text-shadow: none; }
|
||||||
|
.badge.db { background: #336791; border-radius: 0 0 12px 12px; }
|
||||||
|
.badge.git { background: #f05032; transform: rotate(45deg); }
|
||||||
|
.badge.sh { background: #000; border: 2px solid #0f0; color: #0f0; text-shadow: none; }
|
||||||
|
|
||||||
|
.theme-grid {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(3, minmax(0, 1fr));
|
||||||
|
gap: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch {
|
||||||
|
position: relative;
|
||||||
|
border: 2px solid #1b1b1b;
|
||||||
|
border-radius: 8px;
|
||||||
|
padding: 12px;
|
||||||
|
color: #111;
|
||||||
|
background: var(--swatch);
|
||||||
|
box-shadow: inset 0 0 0 2px rgba(255,255,255,0.35), 0 3px 0 rgba(0,0,0,0.25);
|
||||||
|
transition: transform 0.2s ease, box-shadow 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch:hover {
|
||||||
|
transform: translateY(-2px);
|
||||||
|
box-shadow: inset 0 0 0 2px rgba(255,255,255,0.35), 0 6px 0 rgba(0,0,0,0.25);
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch .chip {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 6px;
|
||||||
|
padding: 6px 8px;
|
||||||
|
background: rgba(255,255,255,0.8);
|
||||||
|
border: 1px solid rgba(0,0,0,0.35);
|
||||||
|
border-radius: 999px;
|
||||||
|
font-size: 10px;
|
||||||
|
text-transform: uppercase;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch .dot {
|
||||||
|
width: 10px;
|
||||||
|
height: 10px;
|
||||||
|
border-radius: 999px;
|
||||||
|
background: rgba(0,0,0,0.65);
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch.active {
|
||||||
|
outline: 2px solid #111;
|
||||||
|
outline-offset: 3px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-actions {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
gap: 10px;
|
||||||
|
margin-top: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-actions .menu-link {
|
||||||
|
border: 2px solid #1b1b1b;
|
||||||
|
padding: 8px 12px;
|
||||||
|
background: #fff7eb;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes pop-in {
|
||||||
|
from { opacity: 0; transform: translateY(18px) scale(0.98); }
|
||||||
|
to { opacity: 1; transform: translateY(0) scale(1); }
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes blink {
|
||||||
|
0%, 50% { opacity: 0; }
|
||||||
|
51%, 100% { opacity: 1; }
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fade-in {
|
||||||
|
from { opacity: 0; }
|
||||||
|
to { opacity: 1; }
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes floaty {
|
||||||
|
0%, 100% { transform: translateY(0) translateX(0); }
|
||||||
|
50% { transform: translateY(18px) translateX(12px); }
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<script>
|
||||||
|
// Init Theme
|
||||||
|
const savedTheme = localStorage.getItem('pkmn_theme') || 'theme-red';
|
||||||
|
document.documentElement.classList.add(savedTheme); // Apply to HTML to avoid flash
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
<body class="min-h-screen flex flex-col md:flex-row items-center justify-center p-6 gap-8 overflow-hidden" data-base-classes="min-h-screen flex flex-col md:flex-row items-center justify-center p-6 gap-8 overflow-hidden">
|
||||||
|
{{ block "main" . }}{{ end }}
|
||||||
|
<script>
|
||||||
|
lucide.createIcons();
|
||||||
|
|
||||||
|
// Logic for Menu Navigation & Modals
|
||||||
|
document.addEventListener('DOMContentLoaded', () => {
|
||||||
|
// --- Navigation State ---
|
||||||
|
// We now have multiple "contexts": 'main', 'pokedex', 'bag', 'options'
|
||||||
|
let context = 'main';
|
||||||
|
let activeIndex = 0;
|
||||||
|
|
||||||
|
// Selectors
|
||||||
|
const mainMenu = document.getElementById('main-menu');
|
||||||
|
const mainLinks = mainMenu.querySelectorAll('.menu-link');
|
||||||
|
|
||||||
|
const modals = {
|
||||||
|
pokedex: document.getElementById('modal-pokedex'),
|
||||||
|
bag: document.getElementById('modal-bag'),
|
||||||
|
options: document.getElementById('modal-options')
|
||||||
|
};
|
||||||
|
|
||||||
|
// --- Helper Functions ---
|
||||||
|
|
||||||
|
function getActiveLinks() {
|
||||||
|
if (context === 'main') return mainLinks;
|
||||||
|
if (modals[context]) {
|
||||||
|
return modals[context].querySelectorAll('.menu-link');
|
||||||
|
}
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
|
||||||
|
function updateCursor() {
|
||||||
|
const links = getActiveLinks();
|
||||||
|
links.forEach((link, i) => {
|
||||||
|
if (i === activeIndex) {
|
||||||
|
link.classList.add('active');
|
||||||
|
} else {
|
||||||
|
link.classList.remove('active');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function openModal(modalName) {
|
||||||
|
if (!modals[modalName]) return;
|
||||||
|
context = modalName;
|
||||||
|
activeIndex = 0;
|
||||||
|
modals[modalName].classList.add('open');
|
||||||
|
updateCursor();
|
||||||
|
setupMouseListeners(); // Re-bind for new modal elements
|
||||||
|
}
|
||||||
|
|
||||||
|
function closeModal() {
|
||||||
|
if (context === 'main') return;
|
||||||
|
modals[context].classList.remove('open');
|
||||||
|
context = 'main';
|
||||||
|
activeIndex = 0;
|
||||||
|
updateCursor();
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleActivation(item) {
|
||||||
|
if (!item) return;
|
||||||
|
|
||||||
|
// 1. Link logic
|
||||||
|
if (item.tagName === 'A' && item.href && item.target === '_blank') {
|
||||||
|
window.open(item.href, '_blank');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 2. Data actions
|
||||||
|
const action = item.dataset.action;
|
||||||
|
const payload = item.dataset.payload;
|
||||||
|
|
||||||
|
if (action === 'modal') {
|
||||||
|
openModal(payload);
|
||||||
|
} else if (action === 'close') {
|
||||||
|
closeModal();
|
||||||
|
} else if (action === 'theme') {
|
||||||
|
setTheme(payload);
|
||||||
|
} else if (action === 'link') {
|
||||||
|
// Fallback for custom link items that aren't <a> tags
|
||||||
|
const url = item.getAttribute('onclick')?.match(/'([^']+)'/)?.[1];
|
||||||
|
if (url) window.open(url, '_blank');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function setupMouseListeners() {
|
||||||
|
const links = getActiveLinks();
|
||||||
|
links.forEach((link, index) => {
|
||||||
|
// Sync index on hover
|
||||||
|
link.onmouseenter = () => {
|
||||||
|
activeIndex = index;
|
||||||
|
updateCursor();
|
||||||
|
};
|
||||||
|
// Activate on click
|
||||||
|
link.onclick = (e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
handleActivation(link);
|
||||||
|
};
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
const themes = ['theme-red', 'theme-green', 'theme-blue'];
|
||||||
|
|
||||||
|
function applyTheme(themeName) {
|
||||||
|
themes.forEach((theme) => {
|
||||||
|
document.documentElement.classList.remove(theme);
|
||||||
|
document.body.classList.remove(theme);
|
||||||
|
});
|
||||||
|
document.documentElement.classList.add(themeName);
|
||||||
|
document.body.classList.add(themeName);
|
||||||
|
}
|
||||||
|
|
||||||
|
function setTheme(themeName) {
|
||||||
|
applyTheme(themeName);
|
||||||
|
localStorage.setItem('pkmn_theme', themeName);
|
||||||
|
closeModal();
|
||||||
|
}
|
||||||
|
|
||||||
|
// --- Init ---
|
||||||
|
const savedTheme = localStorage.getItem('pkmn_theme');
|
||||||
|
if (savedTheme) {
|
||||||
|
applyTheme(savedTheme);
|
||||||
|
}
|
||||||
|
|
||||||
|
updateCursor();
|
||||||
|
setupMouseListeners();
|
||||||
|
|
||||||
|
// --- Keyboard Handling ---
|
||||||
|
document.addEventListener('keydown', (e) => {
|
||||||
|
const links = getActiveLinks();
|
||||||
|
|
||||||
|
switch(e.key) {
|
||||||
|
case 'ArrowUp':
|
||||||
|
case 'w':
|
||||||
|
case 'W':
|
||||||
|
e.preventDefault();
|
||||||
|
activeIndex = (activeIndex - 1 + links.length) % links.length;
|
||||||
|
updateCursor();
|
||||||
|
break;
|
||||||
|
case 'ArrowDown':
|
||||||
|
case 's':
|
||||||
|
case 'S':
|
||||||
|
e.preventDefault();
|
||||||
|
activeIndex = (activeIndex + 1) % links.length;
|
||||||
|
updateCursor();
|
||||||
|
break;
|
||||||
|
case 'Enter':
|
||||||
|
case ' ':
|
||||||
|
case 'z':
|
||||||
|
e.preventDefault();
|
||||||
|
handleActivation(links[activeIndex]);
|
||||||
|
break;
|
||||||
|
case 'Escape':
|
||||||
|
case 'x':
|
||||||
|
e.preventDefault();
|
||||||
|
if (context !== 'main') closeModal();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,182 @@
|
|||||||
|
{{ define "main" }}
|
||||||
|
<div class="flex flex-col md:flex-row items-center justify-center gap-8 w-full max-w-5xl z-10">
|
||||||
|
<!-- Left Side: Trainer Card -->
|
||||||
|
<div class="pkmn-box w-full max-w-sm p-1 flex-shrink-0 card-pop" style="--delay: 50ms;">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] p-4 bg-white min-h-[180px] flex flex-col justify-between">
|
||||||
|
<div class="flex gap-4">
|
||||||
|
<div class="flex-1">
|
||||||
|
<h1 class="text-xl mb-4 pkmn-text-shadow text-zinc-800 pixel">TRAINER CARD</h1>
|
||||||
|
<div class="flex justify-between items-end mb-2">
|
||||||
|
<span class="text-xs text-zinc-500 font-bold">NAME</span>
|
||||||
|
<span class="text-sm font-bold text-zinc-800 tracking-wider">JUHLIN</span>
|
||||||
|
</div>
|
||||||
|
<div class="w-full h-[2px] bg-zinc-800 mb-2"></div>
|
||||||
|
<div class="flex justify-between items-end">
|
||||||
|
<span class="text-xs text-zinc-500 font-bold">XP</span>
|
||||||
|
<span class="text-sm font-bold text-zinc-800 tracking-wider">8092</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- Trainer Sprite -->
|
||||||
|
<div class="w-24 h-24 bg-[#f8f8f8] border-2 border-[#d0d0d8] rounded flex items-center justify-center overflow-hidden self-start">
|
||||||
|
<img src="https://play.pokemonshowdown.com/sprites/trainers/red.png"
|
||||||
|
alt="Trainer"
|
||||||
|
class="w-full h-full object-contain"
|
||||||
|
style="image-rendering: pixelated; min-height: 96px; min-width: 96px; display: block;">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Badges Section -->
|
||||||
|
<div class="mt-6">
|
||||||
|
<span class="text-[10px] text-zinc-400 font-bold">BADGES</span>
|
||||||
|
<div class="flex flex-wrap justify-center gap-2 mt-2 px-1">
|
||||||
|
<div class="badge js" title="JavaScript">JS</div>
|
||||||
|
<div class="badge ts" title="TypeScript">TS</div>
|
||||||
|
<div class="badge py" title="Python">PY</div>
|
||||||
|
<div class="badge go" title="Go">GO</div>
|
||||||
|
<div class="badge re" title="React">RE</div>
|
||||||
|
<div class="badge db" title="SQL">DB</div>
|
||||||
|
<div class="badge git" title="Git">GIT</div>
|
||||||
|
<div class="badge sh" title="Shell">SH</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Right Side: Start Menu -->
|
||||||
|
<div class="pkmn-box w-full max-w-[280px] card-pop" style="--delay: 120ms;">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] bg-white py-2" id="main-menu">
|
||||||
|
<ul class="flex flex-col">
|
||||||
|
<!-- POKEDEX (Projects) -->
|
||||||
|
<li>
|
||||||
|
<button data-action="modal" data-payload="pokedex" class="menu-link w-full text-left px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel">POKEDEX</span>
|
||||||
|
</button>
|
||||||
|
</li>
|
||||||
|
<!-- BAG (Resume/Contact) -->
|
||||||
|
<li>
|
||||||
|
<button data-action="modal" data-payload="bag" class="menu-link w-full text-left px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel">BAG</span>
|
||||||
|
</button>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<!-- Standard Links -->
|
||||||
|
{{ range .Site.Params.links }}
|
||||||
|
<li>
|
||||||
|
<a href="{{ .url }}" target="_blank" class="menu-link block px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel uppercase">{{ .name }}</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
<!-- OPTIONS (Theme) -->
|
||||||
|
<li>
|
||||||
|
<button data-action="modal" data-payload="options" class="menu-link w-full text-left px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel">OPTIONS</span>
|
||||||
|
</button>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- MODALS -->
|
||||||
|
|
||||||
|
<!-- Pokedex Modal (Projects) -->
|
||||||
|
<div id="modal-pokedex" class="modal">
|
||||||
|
<div class="pkmn-box w-full max-w-2xl bg-white p-1">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] bg-white h-[400px] flex flex-col relative">
|
||||||
|
<!-- Header -->
|
||||||
|
<div class="bg-[var(--theme-primary)] text-white p-2 text-center border-b-4 border-[#d0d0d8]">
|
||||||
|
<h2 class="text-sm pixel">POKEDEX - PROJECTS</h2>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Content -->
|
||||||
|
<div class="flex-1 overflow-y-auto p-4 space-y-4">
|
||||||
|
<!-- Example Project 1 -->
|
||||||
|
<div class="flex gap-4 items-start menu-link p-2 border-2 border-transparent hover:border-[var(--theme-primary)] transition-colors cursor-pointer" data-action="link" onclick="window.open('https://github.com/julle/project-1', '_blank')">
|
||||||
|
<div class="w-16 h-16 bg-zinc-100 border-2 border-zinc-300 flex items-center justify-center text-xs text-zinc-400">IMG</div>
|
||||||
|
<div class="flex-1">
|
||||||
|
<div class="flex justify-between">
|
||||||
|
<h3 class="font-bold text-sm pixel">#001 PROJECT ONE</h3>
|
||||||
|
<span class="text-[10px] bg-zinc-200 px-1 rounded">WEB</span>
|
||||||
|
</div>
|
||||||
|
<p class="text-[10px] mt-2 text-zinc-600 leading-relaxed">A full-stack web application built with React and Go. Features real-time updates.</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Example Project 2 -->
|
||||||
|
<div class="flex gap-4 items-start menu-link p-2 border-2 border-transparent hover:border-[var(--theme-primary)] transition-colors cursor-pointer" data-action="link" onclick="window.open('https://github.com/julle/project-2', '_blank')">
|
||||||
|
<div class="w-16 h-16 bg-zinc-100 border-2 border-zinc-300 flex items-center justify-center text-xs text-zinc-400">IMG</div>
|
||||||
|
<div class="flex-1">
|
||||||
|
<div class="flex justify-between">
|
||||||
|
<h3 class="font-bold text-sm pixel">#002 CLI TOOL</h3>
|
||||||
|
<span class="text-[10px] bg-zinc-200 px-1 rounded">RUST</span>
|
||||||
|
</div>
|
||||||
|
<p class="text-[10px] mt-2 text-zinc-600 leading-relaxed">Fast command line utility for file processing. 10x faster than Python version.</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Footer -->
|
||||||
|
<div class="p-2 border-t-2 border-[#d0d0d8] text-center">
|
||||||
|
<button data-action="close" class="menu-link text-xs hover:text-[var(--theme-primary)] pixel">[x] CLOSE</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Bag Modal (Resume/Contact) -->
|
||||||
|
<div id="modal-bag" class="modal">
|
||||||
|
<div class="pkmn-box w-full max-w-md bg-white p-1">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] bg-white p-4">
|
||||||
|
<h2 class="text-sm mb-4 border-b-2 border-zinc-200 pb-2 pixel">ITEM POCKET</h2>
|
||||||
|
<ul class="space-y-2">
|
||||||
|
<li>
|
||||||
|
<a href="mailto:[email protected]" class="menu-link flex justify-between p-2 hover:bg-zinc-100 cursor-pointer">
|
||||||
|
<span class="font-bold text-sm pixel">E-MAIL</span>
|
||||||
|
<span class="text-xs text-zinc-500">x 1</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="#" class="menu-link flex justify-between p-2 hover:bg-zinc-100 cursor-pointer">
|
||||||
|
<span class="font-bold text-sm pixel">RESUME.PDF</span>
|
||||||
|
<span class="text-xs text-zinc-500">x 1</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<div class="menu-link flex justify-between p-2 hover:bg-zinc-100 cursor-pointer" data-action="close">
|
||||||
|
<span class="font-bold text-sm pixel">CANCEL</span>
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Options Modal (Theme) -->
|
||||||
|
<div id="modal-options" class="modal">
|
||||||
|
<div class="pkmn-box w-full max-w-sm bg-white p-1">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] bg-white p-4 text-center">
|
||||||
|
<h2 class="text-sm mb-4 pixel">SELECT VERSION</h2>
|
||||||
|
<p class="text-[10px] text-zinc-500 mb-4">Pick a colorway for the UI.</p>
|
||||||
|
<div class="theme-grid">
|
||||||
|
<button data-action="theme" data-payload="theme-red" class="menu-link theme-swatch" style="--swatch: linear-gradient(135deg, #f83800, #ff7a5c);">
|
||||||
|
<span class="chip pixel"><span class="dot"></span>Fire Red</span>
|
||||||
|
</button>
|
||||||
|
<button data-action="theme" data-payload="theme-green" class="menu-link theme-swatch" style="--swatch: linear-gradient(135deg, #008000, #7ee07e);">
|
||||||
|
<span class="chip pixel"><span class="dot"></span>Leaf Green</span>
|
||||||
|
</button>
|
||||||
|
<button data-action="theme" data-payload="theme-blue" class="menu-link theme-swatch" style="--swatch: linear-gradient(135deg, #0060e0, #6db4ff);">
|
||||||
|
<span class="chip pixel"><span class="dot"></span>Water Blue</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
<div class="theme-actions">
|
||||||
|
<button data-action="close" class="menu-link text-xs hover:text-[var(--theme-primary)] pixel">CANCEL</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{{ end }}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Categories on juhlin.io</title><link>https://juhlin.io/categories/</link><description>Recent content in Categories on juhlin.io</description><generator>Hugo</generator><language>en-us</language><atom:link href="https://juhlin.io/categories/index.xml" rel="self" type="application/rss+xml"/></channel></rss>
|
||||||
@@ -0,0 +1,646 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en-us">
|
||||||
|
<head>
|
||||||
|
<meta name="generator" content="Hugo 0.155.2"><script src="/livereload.js?mindelay=10&v=2&port=1313&path=livereload" data-no-instant defer></script>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<title>juhlin.io</title>
|
||||||
|
<meta name="description" content="Personal portal for juhlin.io">
|
||||||
|
<script src="https://cdn.tailwindcss.com"></script>
|
||||||
|
<script src="https://unpkg.com/lucide@latest"></script>
|
||||||
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||||
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||||
|
<link href="https://fonts.googleapis.com/css2?family=Press+Start+2P&family=Space+Grotesk:wght@400;500;600;700&display=swap" rel="stylesheet">
|
||||||
|
<style>
|
||||||
|
:root {
|
||||||
|
|
||||||
|
--theme-primary: #f83800;
|
||||||
|
--theme-bg-color: #d05050;
|
||||||
|
--theme-bg-gradient-1: #c04040;
|
||||||
|
--theme-bg-gradient-2: #e06060;
|
||||||
|
--pkmn-border-light: #f8f8f8;
|
||||||
|
--pkmn-border-dark: #505050;
|
||||||
|
--pkmn-bg: #ffffff;
|
||||||
|
--pkmn-shadow: rgba(0,0,0,0.4);
|
||||||
|
--ink: #1b1b1b;
|
||||||
|
--paper: #fff7eb;
|
||||||
|
--shadow-soft: rgba(0,0,0,0.12);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
:root.theme-green,
|
||||||
|
body.theme-green {
|
||||||
|
--theme-primary: #008000;
|
||||||
|
--theme-bg-color: #70d070;
|
||||||
|
--theme-bg-gradient-1: #68c068;
|
||||||
|
--theme-bg-gradient-2: #80e080;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
:root.theme-blue,
|
||||||
|
body.theme-blue {
|
||||||
|
--theme-primary: #0060e0;
|
||||||
|
--theme-bg-color: #50a0e0;
|
||||||
|
--theme-bg-gradient-1: #4090d0;
|
||||||
|
--theme-bg-gradient-2: #60b0f0;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
font-family: 'Space Grotesk', system-ui, sans-serif;
|
||||||
|
background-color: var(--theme-bg-color);
|
||||||
|
background-image:
|
||||||
|
linear-gradient(45deg, rgba(255,255,255,0.08) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.08) 75%, rgba(255,255,255,0.08)),
|
||||||
|
linear-gradient(45deg, rgba(0,0,0,0.05) 25%, transparent 25%, transparent 75%, rgba(0,0,0,0.05) 75%, rgba(0,0,0,0.05)),
|
||||||
|
radial-gradient(1200px 800px at 10% 10%, rgba(255,255,255,0.18), transparent 55%),
|
||||||
|
radial-gradient(900px 600px at 90% 20%, rgba(0,0,0,0.15), transparent 60%);
|
||||||
|
background-size: 26px 26px, 26px 26px, auto, auto;
|
||||||
|
background-position: 0 0, 13px 13px, 0 0, 0 0;
|
||||||
|
box-shadow: inset 0 0 100px rgba(0,0,0,0.3);
|
||||||
|
transition: background-color 0.5s ease;
|
||||||
|
color: var(--ink);
|
||||||
|
position: relative;
|
||||||
|
isolation: isolate;
|
||||||
|
text-rendering: optimizeLegibility;
|
||||||
|
}
|
||||||
|
|
||||||
|
body::before,
|
||||||
|
body::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
inset: auto;
|
||||||
|
width: 520px;
|
||||||
|
height: 520px;
|
||||||
|
border-radius: 999px;
|
||||||
|
filter: blur(40px);
|
||||||
|
opacity: 0.35;
|
||||||
|
z-index: -1;
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
body::before {
|
||||||
|
top: -140px;
|
||||||
|
left: -120px;
|
||||||
|
background: radial-gradient(circle, rgba(255,255,255,0.8), rgba(255,255,255,0));
|
||||||
|
animation: floaty 14s ease-in-out infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
body::after {
|
||||||
|
bottom: -160px;
|
||||||
|
right: -100px;
|
||||||
|
background: radial-gradient(circle, rgba(0,0,0,0.4), rgba(0,0,0,0));
|
||||||
|
animation: floaty 18s ease-in-out infinite reverse;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.pkmn-box {
|
||||||
|
background-color: var(--pkmn-bg);
|
||||||
|
border: 2px solid var(--pkmn-border-dark);
|
||||||
|
border-radius: 4px;
|
||||||
|
box-shadow: 4px 4px 0 var(--pkmn-shadow), 0 16px 40px var(--shadow-soft);
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.pkmn-box::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
top: 2px;
|
||||||
|
left: 2px;
|
||||||
|
right: 2px;
|
||||||
|
bottom: 2px;
|
||||||
|
border: 2px solid #d0d0d8;
|
||||||
|
border-radius: 2px;
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.pkmn-text-shadow {
|
||||||
|
text-shadow: 2px 2px 0 #d0d0d0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.pixel {
|
||||||
|
font-family: 'Press Start 2P', cursive;
|
||||||
|
letter-spacing: 0.08em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.card-pop {
|
||||||
|
animation: pop-in 0.5s ease both;
|
||||||
|
animation-delay: var(--delay, 0ms);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.menu-link.active .cursor { opacity: 1; }
|
||||||
|
.menu-link.active { color: #000; }
|
||||||
|
.menu-link.active .selector { display: block; }
|
||||||
|
|
||||||
|
.menu-link {
|
||||||
|
border-left: 3px solid transparent;
|
||||||
|
transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu-link:hover {
|
||||||
|
background-color: rgba(0,0,0,0.04);
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu-link.active {
|
||||||
|
background-color: rgba(0,0,0,0.05);
|
||||||
|
border-left-color: var(--theme-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu-link.active .cursor {
|
||||||
|
animation: blink 1.1s steps(2, end) infinite;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.modal {
|
||||||
|
display: none;
|
||||||
|
position: fixed;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
background-color: rgba(0, 0, 0, 0.7);
|
||||||
|
z-index: 50;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
backdrop-filter: blur(2px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.modal.open {
|
||||||
|
display: flex;
|
||||||
|
animation: fade-in 0.2s ease-out;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.badge {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
background: #ccc;
|
||||||
|
border: 2px solid #505050;
|
||||||
|
border-radius: 50%;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 8px;
|
||||||
|
color: white;
|
||||||
|
text-shadow: 1px 1px 0 #000;
|
||||||
|
box-shadow: 0 2px 0 rgba(0,0,0,0.35);
|
||||||
|
}
|
||||||
|
.badge.js { background: #f7df1e; color: #000; text-shadow: none; border-radius: 0; }
|
||||||
|
.badge.go { background: #00add8; }
|
||||||
|
.badge.py { background: #3776ab; border-radius: 4px; }
|
||||||
|
.badge.ts { background: #3178c6; border-radius: 0; }
|
||||||
|
.badge.re { background: #61dafb; color: #000; text-shadow: none; }
|
||||||
|
.badge.db { background: #336791; border-radius: 0 0 12px 12px; }
|
||||||
|
.badge.git { background: #f05032; transform: rotate(45deg); }
|
||||||
|
.badge.sh { background: #000; border: 2px solid #0f0; color: #0f0; text-shadow: none; }
|
||||||
|
|
||||||
|
.theme-grid {
|
||||||
|
display: grid;
|
||||||
|
grid-template-columns: repeat(3, minmax(0, 1fr));
|
||||||
|
gap: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch {
|
||||||
|
position: relative;
|
||||||
|
border: 2px solid #1b1b1b;
|
||||||
|
border-radius: 8px;
|
||||||
|
padding: 12px;
|
||||||
|
color: #111;
|
||||||
|
background: var(--swatch);
|
||||||
|
box-shadow: inset 0 0 0 2px rgba(255,255,255,0.35), 0 3px 0 rgba(0,0,0,0.25);
|
||||||
|
transition: transform 0.2s ease, box-shadow 0.2s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch:hover {
|
||||||
|
transform: translateY(-2px);
|
||||||
|
box-shadow: inset 0 0 0 2px rgba(255,255,255,0.35), 0 6px 0 rgba(0,0,0,0.25);
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch .chip {
|
||||||
|
display: inline-flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 6px;
|
||||||
|
padding: 6px 8px;
|
||||||
|
background: rgba(255,255,255,0.8);
|
||||||
|
border: 1px solid rgba(0,0,0,0.35);
|
||||||
|
border-radius: 999px;
|
||||||
|
font-size: 10px;
|
||||||
|
text-transform: uppercase;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch .dot {
|
||||||
|
width: 10px;
|
||||||
|
height: 10px;
|
||||||
|
border-radius: 999px;
|
||||||
|
background: rgba(0,0,0,0.65);
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-swatch.active {
|
||||||
|
outline: 2px solid #111;
|
||||||
|
outline-offset: 3px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-actions {
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
gap: 10px;
|
||||||
|
margin-top: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.theme-actions .menu-link {
|
||||||
|
border: 2px solid #1b1b1b;
|
||||||
|
padding: 8px 12px;
|
||||||
|
background: #fff7eb;
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes pop-in {
|
||||||
|
from { opacity: 0; transform: translateY(18px) scale(0.98); }
|
||||||
|
to { opacity: 1; transform: translateY(0) scale(1); }
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes blink {
|
||||||
|
0%, 50% { opacity: 0; }
|
||||||
|
51%, 100% { opacity: 1; }
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes fade-in {
|
||||||
|
from { opacity: 0; }
|
||||||
|
to { opacity: 1; }
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes floaty {
|
||||||
|
0%, 100% { transform: translateY(0) translateX(0); }
|
||||||
|
50% { transform: translateY(18px) translateX(12px); }
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<script>
|
||||||
|
|
||||||
|
const savedTheme = localStorage.getItem('pkmn_theme') || 'theme-red';
|
||||||
|
document.documentElement.classList.add(savedTheme);
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
<body class="min-h-screen flex flex-col md:flex-row items-center justify-center p-6 gap-8 overflow-hidden" data-base-classes="min-h-screen flex flex-col md:flex-row items-center justify-center p-6 gap-8 overflow-hidden">
|
||||||
|
|
||||||
|
<div class="flex flex-col md:flex-row items-center justify-center gap-8 w-full max-w-5xl z-10">
|
||||||
|
|
||||||
|
<div class="pkmn-box w-full max-w-sm p-1 flex-shrink-0 card-pop" style="--delay: 50ms;">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] p-4 bg-white min-h-[180px] flex flex-col justify-between">
|
||||||
|
<div class="flex gap-4">
|
||||||
|
<div class="flex-1">
|
||||||
|
<h1 class="text-xl mb-4 pkmn-text-shadow text-zinc-800 pixel">TRAINER CARD</h1>
|
||||||
|
<div class="flex justify-between items-end mb-2">
|
||||||
|
<span class="text-xs text-zinc-500 font-bold">NAME</span>
|
||||||
|
<span class="text-sm font-bold text-zinc-800 tracking-wider">JUHLIN</span>
|
||||||
|
</div>
|
||||||
|
<div class="w-full h-[2px] bg-zinc-800 mb-2"></div>
|
||||||
|
<div class="flex justify-between items-end">
|
||||||
|
<span class="text-xs text-zinc-500 font-bold">XP</span>
|
||||||
|
<span class="text-sm font-bold text-zinc-800 tracking-wider">8092</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="w-24 h-24 bg-[#f8f8f8] border-2 border-[#d0d0d8] rounded flex items-center justify-center overflow-hidden self-start">
|
||||||
|
<img src="https://play.pokemonshowdown.com/sprites/trainers/red.png"
|
||||||
|
alt="Trainer"
|
||||||
|
class="w-full h-full object-contain"
|
||||||
|
style="image-rendering: pixelated; min-height: 96px; min-width: 96px; display: block;">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="mt-6">
|
||||||
|
<span class="text-[10px] text-zinc-400 font-bold">BADGES</span>
|
||||||
|
<div class="flex flex-wrap justify-center gap-2 mt-2 px-1">
|
||||||
|
<div class="badge js" title="JavaScript">JS</div>
|
||||||
|
<div class="badge ts" title="TypeScript">TS</div>
|
||||||
|
<div class="badge py" title="Python">PY</div>
|
||||||
|
<div class="badge go" title="Go">GO</div>
|
||||||
|
<div class="badge re" title="React">RE</div>
|
||||||
|
<div class="badge db" title="SQL">DB</div>
|
||||||
|
<div class="badge git" title="Git">GIT</div>
|
||||||
|
<div class="badge sh" title="Shell">SH</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="pkmn-box w-full max-w-[280px] card-pop" style="--delay: 120ms;">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] bg-white py-2" id="main-menu">
|
||||||
|
<ul class="flex flex-col">
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<button data-action="modal" data-payload="pokedex" class="menu-link w-full text-left px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel">POKEDEX</span>
|
||||||
|
</button>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<button data-action="modal" data-payload="bag" class="menu-link w-full text-left px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel">BAG</span>
|
||||||
|
</button>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="https://blog.juhlin.io" target="_blank" class="menu-link block px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel uppercase">Blog</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="https://github.com/julle" target="_blank" class="menu-link block px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel uppercase">Projects</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="https://linkedin.com/in/juhlin" target="_blank" class="menu-link block px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel uppercase">LinkedIn</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<a href="https://twitter.com/juhlin" target="_blank" class="menu-link block px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel uppercase">Twitter</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<li>
|
||||||
|
<button data-action="modal" data-payload="options" class="menu-link w-full text-left px-4 py-3 text-sm font-bold text-zinc-500 hover:text-black transition-colors flex items-center group">
|
||||||
|
<span class="cursor opacity-0 w-6 text-[var(--theme-primary)] transition-opacity text-lg" style="margin-top:-4px">►</span>
|
||||||
|
<span class="pixel">OPTIONS</span>
|
||||||
|
</button>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div id="modal-pokedex" class="modal">
|
||||||
|
<div class="pkmn-box w-full max-w-2xl bg-white p-1">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] bg-white h-[400px] flex flex-col relative">
|
||||||
|
|
||||||
|
<div class="bg-[var(--theme-primary)] text-white p-2 text-center border-b-4 border-[#d0d0d8]">
|
||||||
|
<h2 class="text-sm pixel">POKEDEX - PROJECTS</h2>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="flex-1 overflow-y-auto p-4 space-y-4">
|
||||||
|
|
||||||
|
<div class="flex gap-4 items-start menu-link p-2 border-2 border-transparent hover:border-[var(--theme-primary)] transition-colors cursor-pointer" data-action="link" onclick="window.open('https://github.com/julle/project-1', '_blank')">
|
||||||
|
<div class="w-16 h-16 bg-zinc-100 border-2 border-zinc-300 flex items-center justify-center text-xs text-zinc-400">IMG</div>
|
||||||
|
<div class="flex-1">
|
||||||
|
<div class="flex justify-between">
|
||||||
|
<h3 class="font-bold text-sm pixel">#001 PROJECT ONE</h3>
|
||||||
|
<span class="text-[10px] bg-zinc-200 px-1 rounded">WEB</span>
|
||||||
|
</div>
|
||||||
|
<p class="text-[10px] mt-2 text-zinc-600 leading-relaxed">A full-stack web application built with React and Go. Features real-time updates.</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="flex gap-4 items-start menu-link p-2 border-2 border-transparent hover:border-[var(--theme-primary)] transition-colors cursor-pointer" data-action="link" onclick="window.open('https://github.com/julle/project-2', '_blank')">
|
||||||
|
<div class="w-16 h-16 bg-zinc-100 border-2 border-zinc-300 flex items-center justify-center text-xs text-zinc-400">IMG</div>
|
||||||
|
<div class="flex-1">
|
||||||
|
<div class="flex justify-between">
|
||||||
|
<h3 class="font-bold text-sm pixel">#002 CLI TOOL</h3>
|
||||||
|
<span class="text-[10px] bg-zinc-200 px-1 rounded">RUST</span>
|
||||||
|
</div>
|
||||||
|
<p class="text-[10px] mt-2 text-zinc-600 leading-relaxed">Fast command line utility for file processing. 10x faster than Python version.</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="p-2 border-t-2 border-[#d0d0d8] text-center">
|
||||||
|
<button data-action="close" class="menu-link text-xs hover:text-[var(--theme-primary)] pixel">[x] CLOSE</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="modal-bag" class="modal">
|
||||||
|
<div class="pkmn-box w-full max-w-md bg-white p-1">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] bg-white p-4">
|
||||||
|
<h2 class="text-sm mb-4 border-b-2 border-zinc-200 pb-2 pixel">ITEM POCKET</h2>
|
||||||
|
<ul class="space-y-2">
|
||||||
|
<li>
|
||||||
|
<a href="mailto:[email protected]" class="menu-link flex justify-between p-2 hover:bg-zinc-100 cursor-pointer">
|
||||||
|
<span class="font-bold text-sm pixel">E-MAIL</span>
|
||||||
|
<span class="text-xs text-zinc-500">x 1</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="#" class="menu-link flex justify-between p-2 hover:bg-zinc-100 cursor-pointer">
|
||||||
|
<span class="font-bold text-sm pixel">RESUME.PDF</span>
|
||||||
|
<span class="text-xs text-zinc-500">x 1</span>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<div class="menu-link flex justify-between p-2 hover:bg-zinc-100 cursor-pointer" data-action="close">
|
||||||
|
<span class="font-bold text-sm pixel">CANCEL</span>
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="modal-options" class="modal">
|
||||||
|
<div class="pkmn-box w-full max-w-sm bg-white p-1">
|
||||||
|
<div class="border-2 border-[#d0d0d8] rounded-[2px] bg-white p-4 text-center">
|
||||||
|
<h2 class="text-sm mb-4 pixel">SELECT VERSION</h2>
|
||||||
|
<p class="text-[10px] text-zinc-500 mb-4">Pick a colorway for the UI.</p>
|
||||||
|
<div class="theme-grid">
|
||||||
|
<button data-action="theme" data-payload="theme-red" class="menu-link theme-swatch" style="--swatch: linear-gradient(135deg, #f83800, #ff7a5c);">
|
||||||
|
<span class="chip pixel"><span class="dot"></span>Fire Red</span>
|
||||||
|
</button>
|
||||||
|
<button data-action="theme" data-payload="theme-green" class="menu-link theme-swatch" style="--swatch: linear-gradient(135deg, #008000, #7ee07e);">
|
||||||
|
<span class="chip pixel"><span class="dot"></span>Leaf Green</span>
|
||||||
|
</button>
|
||||||
|
<button data-action="theme" data-payload="theme-blue" class="menu-link theme-swatch" style="--swatch: linear-gradient(135deg, #0060e0, #6db4ff);">
|
||||||
|
<span class="chip pixel"><span class="dot"></span>Water Blue</span>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
<div class="theme-actions">
|
||||||
|
<button data-action="close" class="menu-link text-xs hover:text-[var(--theme-primary)] pixel">CANCEL</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
lucide.createIcons();
|
||||||
|
|
||||||
|
|
||||||
|
document.addEventListener('DOMContentLoaded', () => {
|
||||||
|
|
||||||
|
|
||||||
|
let context = 'main';
|
||||||
|
let activeIndex = 0;
|
||||||
|
|
||||||
|
|
||||||
|
const mainMenu = document.getElementById('main-menu');
|
||||||
|
const mainLinks = mainMenu.querySelectorAll('.menu-link');
|
||||||
|
|
||||||
|
const modals = {
|
||||||
|
pokedex: document.getElementById('modal-pokedex'),
|
||||||
|
bag: document.getElementById('modal-bag'),
|
||||||
|
options: document.getElementById('modal-options')
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function getActiveLinks() {
|
||||||
|
if (context === 'main') return mainLinks;
|
||||||
|
if (modals[context]) {
|
||||||
|
return modals[context].querySelectorAll('.menu-link');
|
||||||
|
}
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
|
||||||
|
function updateCursor() {
|
||||||
|
const links = getActiveLinks();
|
||||||
|
links.forEach((link, i) => {
|
||||||
|
if (i === activeIndex) {
|
||||||
|
link.classList.add('active');
|
||||||
|
} else {
|
||||||
|
link.classList.remove('active');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function openModal(modalName) {
|
||||||
|
if (!modals[modalName]) return;
|
||||||
|
context = modalName;
|
||||||
|
activeIndex = 0;
|
||||||
|
modals[modalName].classList.add('open');
|
||||||
|
updateCursor();
|
||||||
|
setupMouseListeners();
|
||||||
|
}
|
||||||
|
|
||||||
|
function closeModal() {
|
||||||
|
if (context === 'main') return;
|
||||||
|
modals[context].classList.remove('open');
|
||||||
|
context = 'main';
|
||||||
|
activeIndex = 0;
|
||||||
|
updateCursor();
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleActivation(item) {
|
||||||
|
if (!item) return;
|
||||||
|
|
||||||
|
|
||||||
|
if (item.tagName === 'A' && item.href && item.target === '_blank') {
|
||||||
|
window.open(item.href, '_blank');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
const action = item.dataset.action;
|
||||||
|
const payload = item.dataset.payload;
|
||||||
|
|
||||||
|
if (action === 'modal') {
|
||||||
|
openModal(payload);
|
||||||
|
} else if (action === 'close') {
|
||||||
|
closeModal();
|
||||||
|
} else if (action === 'theme') {
|
||||||
|
setTheme(payload);
|
||||||
|
} else if (action === 'link') {
|
||||||
|
|
||||||
|
const url = item.getAttribute('onclick')?.match(/'([^']+)'/)?.[1];
|
||||||
|
if (url) window.open(url, '_blank');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function setupMouseListeners() {
|
||||||
|
const links = getActiveLinks();
|
||||||
|
links.forEach((link, index) => {
|
||||||
|
|
||||||
|
link.onmouseenter = () => {
|
||||||
|
activeIndex = index;
|
||||||
|
updateCursor();
|
||||||
|
};
|
||||||
|
|
||||||
|
link.onclick = (e) => {
|
||||||
|
e.preventDefault();
|
||||||
|
handleActivation(link);
|
||||||
|
};
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
const themes = ['theme-red', 'theme-green', 'theme-blue'];
|
||||||
|
|
||||||
|
function applyTheme(themeName) {
|
||||||
|
themes.forEach((theme) => {
|
||||||
|
document.documentElement.classList.remove(theme);
|
||||||
|
document.body.classList.remove(theme);
|
||||||
|
});
|
||||||
|
document.documentElement.classList.add(themeName);
|
||||||
|
document.body.classList.add(themeName);
|
||||||
|
}
|
||||||
|
|
||||||
|
function setTheme(themeName) {
|
||||||
|
applyTheme(themeName);
|
||||||
|
localStorage.setItem('pkmn_theme', themeName);
|
||||||
|
closeModal();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
const savedTheme = localStorage.getItem('pkmn_theme');
|
||||||
|
if (savedTheme) {
|
||||||
|
applyTheme(savedTheme);
|
||||||
|
}
|
||||||
|
|
||||||
|
updateCursor();
|
||||||
|
setupMouseListeners();
|
||||||
|
|
||||||
|
|
||||||
|
document.addEventListener('keydown', (e) => {
|
||||||
|
const links = getActiveLinks();
|
||||||
|
|
||||||
|
switch(e.key) {
|
||||||
|
case 'ArrowUp':
|
||||||
|
case 'w':
|
||||||
|
case 'W':
|
||||||
|
e.preventDefault();
|
||||||
|
activeIndex = (activeIndex - 1 + links.length) % links.length;
|
||||||
|
updateCursor();
|
||||||
|
break;
|
||||||
|
case 'ArrowDown':
|
||||||
|
case 's':
|
||||||
|
case 'S':
|
||||||
|
e.preventDefault();
|
||||||
|
activeIndex = (activeIndex + 1) % links.length;
|
||||||
|
updateCursor();
|
||||||
|
break;
|
||||||
|
case 'Enter':
|
||||||
|
case ' ':
|
||||||
|
case 'z':
|
||||||
|
e.preventDefault();
|
||||||
|
handleActivation(links[activeIndex]);
|
||||||
|
break;
|
||||||
|
case 'Escape':
|
||||||
|
case 'x':
|
||||||
|
e.preventDefault();
|
||||||
|
if (context !== 'main') closeModal();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>juhlin.io</title><link>https://juhlin.io/</link><description>Recent content on juhlin.io</description><generator>Hugo</generator><language>en-us</language><atom:link href="https://juhlin.io/index.xml" rel="self" type="application/rss+xml"/></channel></rss>
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" standalone="yes"?><urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml"><url><loc>https://juhlin.io/categories/</loc></url><url><loc>https://juhlin.io/</loc></url><url><loc>https://juhlin.io/tags/</loc></url></urlset>
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Tags on juhlin.io</title><link>https://juhlin.io/tags/</link><description>Recent content in Tags on juhlin.io</description><generator>Hugo</generator><language>en-us</language><atom:link href="https://juhlin.io/tags/index.xml" rel="self" type="application/rss+xml"/></channel></rss>
|
||||||
Reference in New Issue
Block a user