"Bash(git commit *)",
"Bash(ls -la *.toml)",
"Bash(find *)",
- "Bash(ls *)"
+ "Bash(ls *)",
+ "WebFetch(domain:gohugo.io)"
]
}
}
Who this is for:
- You are Danilo (danix), building a Hugo theme for danix.xyz. You've completed a comprehensive 32-task implementation across 8 phases with Claude Code assistance, creating a bilingual (Italian/English), configuration-driven hacker-themed portfolio/blog site. The theme is now production-ready.
+ You are Danilo (danix), building a Hugo theme for danix.xyz - a bilingual (Italian/English) hacker-themed portfolio/blog site. You've completed the multilingual setup and are now finalizing the language switching mechanism and menu navigation.
What we covered:
- You completed all 32 implementation tasks organized into 8 phases: Phase 1 scaffolded the theme directory and configuration (3 tasks), Phase 2 created base templates for layout structure (4 tasks), Phase 3 built styling and JavaScript functionality (5 tasks including CSS with dark/light themes and menu/theme toggle scripts), Phase 4 created internationalization files for Italian and English (2 tasks with 40 key translation pairs each), Phase 5 developed page templates for landing page, article lists, and single articles (4 tasks), Phase 6 created 5 article type-specific templates (Life, Photo, Link, Quote, Tech) plus a dispatcher (6 tasks), Phase 7 built 4 reusable shortcodes (Gravatar, Image, Gallery, Contact Form) plus a PHP placeholder (4 tasks), and Phase 8 finalized documentation (2 tasks creating SHORTCODES.md with 283
- lines and updating AGENTS.md with 444 lines of content management guide).
+ The session focused on fixing the language switcher to maintain language context when navigating between pages. You identified that the menu links weren't respecting the current language, so clicking a menu item on an Italian page would take you to the English version. We analyzed
+ two solutions: a JavaScript workaround (hacky) versus Hugo's native language-specific menu configuration (idiomatic). We chose Option 1, refactoring the hugo.toml to define menus separately for each language using pageRef, which allows Hugo to automatically handle language prefixes. We removed the JavaScript files and updated the templates to access the language-aware menus.
What was confirmed:
- The complete theme architecture is documented in CLAUDE.md (35 lines) with Slackware-style philosophy instructions. The design specification and 32-task implementation plan were previously created and saved. All 52 feature/fix commits were made with proper messages. The theme includes 50+ files: multiple layout templates, 3 JavaScript files for theme/menu/language functionality, 2 CSS files (main.css with Tailwind and theme variables, chroma-custom.css for syntax highlighting), 4 shortcodes, Italian and English i18n files with identical key structures, responsive design targeting WCAG 2.1 AA accessibility, and comprehensive documentation. The theme supports 5 article types, dark/light theme switching with localStorage persistence, bilingual navigation, Feather Icons integration, Alpine.js for interactivity, and Tailwind CSS styling.
+ The language-specific menus are now fully functional. Italian pages display menu links with /it/ prefix (e.g., /it/articles/, /it/is/, /it/is/here/, /it/is/legal/) and Italian text (Articoli, Chi Sono, Contatti, Privacy). English pages display unprefixed links (e.g., /articles/, /is/, /is/here/, /is/legal/) with English text (Articles, About, Contact, Privacy). The language switcher buttons work correctly on both language versions. Hugo builds without errors. The desktop menu is hidden on mobile (hidden md:flex class) and visible on medium screens and above. The hamburger/mobile menu works on all viewports.
Still in progress:
- Nothing was left open in this session. All 32 tasks were completed and committed.
+ Nothing was left open in this session.
Next steps:
- In the next session, you should implement the contact.php backend to handle form submissions (email sending, validation, honeypot), create sample content bundles in Italian and English to populate the theme with articles, configure DNS to point danix.xyz to your hosting, deploy the Hugo theme to production, test the bilingual navigation end-to-end to verify language switching works correctly, conduct a performance review using Lighthouse and PageSpeed audits, and set up SEO infrastructure (sitemap.xml, robots.txt, meta tags). You may also want to create a final git tag for version 1.0 and generate a theme README if not already done.
\ No newline at end of file
+ Hard refresh your browser to clear any cached files, then test the language switching and menu navigation thoroughly on both Italian and English pages using a desktop-width viewport to see the top menu. Once verified everything works as expected in the browser, commit all changes to git. The modified files are hugo.toml (new language-specific menu structure), header.html and hamburger-menu.html (simplified template logic), baseof.html (removed language-switcher.js script tag), and two JavaScript files have been deleted. Update your HANDOFF.md file to document the final architecture if needed.
\ No newline at end of file
description: "Portfolio and blog by Danilo Macrì"
---
+{{< gravatar email="danix@danix.xyz" class="mx-auto w-32 h-32 rounded-full object-cover" >}}
+
Welcome to danix.xyz, my name is Danilo but you can call me danix.
-Here I write about stuff I find interesting. On this site you may read about WordPress, Hugo, bash, Slackware, and lots of other things. Feel free to have a look and take what you like.
\ No newline at end of file
+> Here I write about stuff I find interesting. On this site you may read about WordPress, Hugo, bash, Slackware, and lots of other things. Feel free to have a look and take what you like.
\ No newline at end of file
I deeply dislike sharing readers data with other companies so you can be sure that I don't collect any data from my readers. I've setup hugo not to track my readers and to instruct other sites referenced on my pages to do so as well.
-Read more about [my Privacy Policy](../legal "Privacy Policy here at danix.xyz").
+Read more about [my Privacy Policy](legal/ "Privacy Policy here at danix.xyz").
description: "Portfolio e blog di Danilo Macrì"
---
+{{< gravatar email="danix@danix.xyz" class="mx-auto w-32 h-32 rounded-full object-cover" >}}
+
Benvenuto su danix.xyz, io sono Danilo, ma puoi chiamarmi danix.
-Su queste pagine scrivo di tutto ciò che trovo interessante. Potrai leggere articoli riguardanti WordPress, Hugo, bash, Slackware, e molte altre cose. Dai pure un'occhiata e prendi ciò che più ti piace.
\ No newline at end of file
+> Su queste pagine scrivo di tutto ciò che trovo interessante. Potrai leggere articoli riguardanti WordPress, Hugo, bash, Slackware, e molte altre cose. Dai pure un'occhiata e prendi ciò che più ti piace.
\ No newline at end of file
--- /dev/null
++++
+title = "cos'è danix.xyz"
+author = "Danilo M."
+draft = false
+date = "2009-06-01T22:04:43+00:00"
++++
+
+{{< gravatar email="danixland@gmail.com" class="image right circle" size=250 >}}
+
+Benvenuto su danix.xyz, mi chiamo Danilo ma puoi chiamarmi danix.
+
+Cos'è questo sito web? Beh, **danix.xyz** è il mio sito web personale, qui puoi leggere di tutto ciò che trovo interessante, troverai il codice che scrivo, plugin o temi WordPress, script php o bash che utilizzo sui miei sistemi e programmi che trovo interessanti.
+
+Uso questo sito web per tenere traccia di tutti gli snippet di codice che tendo a dimenticare, considero questo sito web come il mio blocco note (nella speranza che possa rivelarsi utile a qualcun altro).
+
+Odio profondamente condividere i dati dei lettori con altre aziende, quindi puoi essere sicuro che non raccolgo alcun dato dai miei lettori. Ho configurato hugo in modo che non tenga traccia dei miei lettori e istruisce altri siti a cui faccio riferimento sulle mie pagine a fare lo stesso.
+
+Leggi di più sulla [mia Informativa sulla Privacy](legal/ "Informativa sulla Privacy qui su danix.xyz").
date = "2023-02-28T18:12:43+01:00"
+++
-Mi piacerebbe sentire da te. Per favore, compila il modulo sottostante.
+Sentiti libero di contattarmi.
{{< contact >}}
+++ /dev/null
-+++
-title = "about danix.xyz"
-author = "Danilo M."
-draft = false
-date = "2009-06-01T22:04:43+00:00"
-+++
-
-{{< gravatar email="danixland@gmail.com" class="image right circle" size=250 >}}
-
-Welcome to danix.xyz, my name is Danilo but you can call me danix.
-
-What is this website? Well, **danix.xyz** is my personal website, in here you can read about everything I find interesting, you'll find the code I write, WordPress plugins or themes, php or bash scripts that I use on my systems, and programs that I find interesting.
-
-I use this website to keep track of all the snippets of code that I tend to forget, I consider this website like my notepad (in the hope that it can turn useful to somebody else).
-
-I deeply dislike sharing readers data with other companies so you can be sure that I don't collect any data from my readers. I've setup hugo not to track my readers and to instruct other sites referenced on my pages to do so as well.
-
-Read more about [my Privacy Policy](../legal "Privacy Policy here at danix.xyz").
+++
-title = "Privacy Policy"
+title = "Informativa sulla Privacy"
date = "2021-06-16T16:22:25+02:00"
draft = false
+++
-This website is **danix's ramblings**, the place where I, Danilo 'danix' M. share my thoughts about computers, GNU/Linux and life in general.
+Questo sito web è **i pensieri di danix**, il luogo dove io, Danilo ‘danix’ M., condivido i miei pensieri su computer, GNU/Linux e la vita in generale.
-The URL where you can reach this website is <https://danix.xyz>.
+L’URL dove puoi raggiungere questo sito web è <https://danix.xyz>.
-In this privacy statement I will inform you about how this website handles personal data. This privacy statement does not apply to websites that are linked to or from these pages.
+In questa informativa sulla privacy ti informerò su come questo sito web gestisce i dati personali. Questa informativa sulla privacy non si applica ai siti web che sono collegati a o da queste pagine.
-By using this website you agree to the following privacy statement and also to collect and / or use of your information by me as described below.
+Utilizzando questo sito web, accetti la seguente informativa sulla privacy e la raccolta e/o l’uso delle tue informazioni da parte mia come descritto di seguito.
-I reserve the right to change this statement at any time without prior notice.
+Mi riservo il diritto di modificare questa dichiarazione in qualsiasi momento senza preavviso.
-## Active Collection of Informations
+## Raccolta Attiva di Informazioni
-On the contact page of this website you will be asked for a specific purpose for your name, email address or other non-confidential information. Your answer to these questions is on a completely voluntary basis. This information is collected for the purpose of replying to your inquiries and to improve the information to you, the user. Further information can also be used for spam filtering by automated systems
+Nella pagina dei contatti di questo sito web ti verrà chiesto il tuo nome, indirizzo email o altre informazioni non confidenziali per uno scopo specifico. La tua risposta a queste domande è su base completamente volontaria. Queste informazioni vengono raccolte al fine di rispondere alle tue domande e migliorare le informazioni per te, l’utente. Le informazioni ulteriori possono essere utilizzate anche per il filtraggio dello spam da parte di sistemi automatizzati.
-I may use this data, for example, to notify you about new posts via email if you decide to be informed, or you could fill up the form when leaving a message and the informations you leave will be used to better identify you as the sender.
+Posso utilizzare questi dati, ad esempio, per notificarti i nuovi articoli via email se decidi di essere informato, oppure puoi compilare il modulo quando lasci un messaggio e le informazioni che lasci verranno utilizzate per identificarti meglio come mittente.
-Since the collection of informations is on a voluntary basis, you can avoid leaving any _Personally Identifiable information_ (PII) and the site will not collect any from you.
+Poiché la raccolta di informazioni è su base volontaria, puoi evitare di lasciare informazioni _Personally Identifiable information_ (PII) e il sito non ne raccoglierà alcuna da te.
-## Passive Collection of Informations
+## Raccolta Passiva di Informazioni
-I do not collect domain data for the purpose of analysis on site through any external services. The web server that is running this website stores IP addresses in a log file but these are not connected to any _PII_, The only use I have for this information is to block potential hackers from breaking into the system.
+Non raccolgo dati di dominio a scopo di analisi sul sito attraverso servizi esterni. Il server web che esegue questo sito web memorizza gli indirizzi IP in un file di log ma questi non sono collegati a nessun _PII_. L’unico uso che ho per queste informazioni è bloccare potenziali hacker dal tentare di violare il sistema.
-## Comments
+## Commenti
-Comments are disabled on this website, the only way to interact with me is by submitting a message through the contact form.
+I commenti sono disabilitati su questo sito web. L’unico modo per interagire con me è inviare un messaggio tramite il modulo di contatto.
-## Who I share your data with
+## Con chi condivido i tuoi dati
-**I don't sell your data to anyone, nor I exchange it for services or any other good. Your privacy is my major concern.**
+**Non vendo i tuoi dati a nessuno, né li scambio per servizi o altri beni. La tua privacy è la mia principale preoccupazione.**
-## How long your data is retained
+## Per quanto tempo vengono conservati i tuoi dati
-I will keep a copy of the messages I receive for as long as it is required in order for me to reply to such messages.
+Manterrò una copia dei messaggi che ricevo per il tempo necessario per rispondere a tali messaggi.
-## Cookies
+## Cookie
-Pages on this site don't use “cookies”. Cookies are small text files that are dependent on the personal settings on your browser and are automatically placed on a user’s computer. These text files are used for registration to the websites and to suit your needs on your next visit. Cookies can not read data on your computer's hard drive.
+Le pagine su questo sito non utilizzano “cookie”. I cookie sono piccoli file di testo che dipendono dalle impostazioni personali del tuo browser e vengono automaticamente posizionati sul computer di un utente. Questi file di testo vengono utilizzati per la registrazione ai siti web e per adattare le tue esigenze alla tua prossima visita. I cookie non possono leggere i dati sul disco rigido del tuo computer.
-Being browser dependent, you can change your browser settings to automatically accept or refuse cookies.
+Essendo dipendenti dal browser, puoi modificare le impostazioni del tuo browser per accettare o rifiutare automaticamente i cookie.
+## Come disabilitare i cookie dei servizi di terze parti
-## How to disable third party services cookies
-
-While I don't use either of these services for data tracking, you might find content from these sites embedded on these pages. By following the links below you'll be able to disable cookies specific to those platforms.
+Sebbene non utilizzi nessuno di questi servizi per il tracciamento dei dati, potresti trovare contenuti da questi siti incorporati in queste pagine. Seguendo i link di seguito sarai in grado di disabilitare i cookie specifici di quelle piattaforme.
* [Google][2]
* [Facebook][3]
# Hugo Pipes
[minify]
- minifyOutput = true
+ minifyOutput = false
disableXML = false
# Languages
weight = 1
[languages.it.params]
locale = "it_IT"
+ siteDescription = "Blatero di varie cose."
+
+ # Italian menu with language-aware links
+ [[languages.it.menus.main]]
+ identifier = "articles"
+ pageRef = "/articles"
+ name = "articles"
+ weight = 1
+
+ [[languages.it.menus.main]]
+ identifier = "about"
+ pageRef = "/is"
+ name = "about"
+ weight = 2
+
+ [[languages.it.menus.main]]
+ identifier = "contact"
+ pageRef = "/is/here"
+ name = "here"
+ weight = 3
+
+ [[languages.it.menus.main]]
+ identifier = "legal"
+ pageRef = "/is/legal"
+ name = "legal"
+ weight = 4
[languages.en]
languageName = "EN"
weight = 2
[languages.en.params]
locale = "en_US"
+ siteDescription = "I ramble about stuff."
-# Main menu
-[[menus.main]]
- name = "articles"
- url = "/articles/"
- weight = 1
+ # English menu with language-aware links
+ [[languages.en.menus.main]]
+ identifier = "articles"
+ pageRef = "/articles"
+ name = "articles"
+ weight = 1
-[[menus.main]]
- name = "about"
- url = "/is/"
- weight = 2
+ [[languages.en.menus.main]]
+ identifier = "about"
+ pageRef = "/is"
+ name = "about"
+ weight = 2
-[[menus.main]]
- name = "contact"
- url = "/is/here/"
- weight = 3
+ [[languages.en.menus.main]]
+ identifier = "contact"
+ pageRef = "/is/here"
+ name = "here"
+ weight = 3
-[[menus.main]]
- name = "legal"
- url = "/is/legal/"
- weight = 4
+ [[languages.en.menus.main]]
+ identifier = "legal"
+ pageRef = "/is/legal"
+ name = "legal"
+ weight = 4
# Theme parameters
[params]
siteName = "danix.xyz"
- siteDescription = "Portfolio and blog"
author = "Danilo Macrì"
email = "danix@danix.xyz"
--accent2: #10b981;
--accent-glow: rgba(147, 51, 234, 0.1);
--text: #1f2937;
- --text-dim: #6b7280;
+ --text-dim: #374151;
--muted: #d1d5db;
}
}
}
+/* Prose overrides for light theme */
+html.theme-light .prose,
+html.theme-light .prose-invert {
+ color: var(--text);
+}
+
+html.theme-light .prose a,
+html.theme-light .prose-invert a {
+ color: var(--accent);
+}
+
+html.theme-light .prose strong,
+html.theme-light .prose-invert strong {
+ color: var(--text);
+}
+
+html.theme-light .prose code,
+html.theme-light .prose-invert code {
+ color: var(--accent2);
+}
+
+html.theme-light .prose pre,
+html.theme-light .prose-invert pre {
+ background-color: var(--surface);
+ color: var(--text);
+}
+
+html.theme-light .prose h1,
+html.theme-light .prose h2,
+html.theme-light .prose h3,
+html.theme-light .prose h4,
+html.theme-light .prose h5,
+html.theme-light .prose h6,
+html.theme-light .prose-invert h1,
+html.theme-light .prose-invert h2,
+html.theme-light .prose-invert h3,
+html.theme-light .prose-invert h4,
+html.theme-light .prose-invert h5,
+html.theme-light .prose-invert h6 {
+ color: var(--text);
+}
+
+html.theme-light .prose blockquote,
+html.theme-light .prose-invert blockquote {
+ color: var(--text);
+ border-left-color: var(--accent);
+}
+
/* Responsive utilities */
@media (max-width: 768px) {
.sm\:container {
order: 9999;
}
-.mx-6 {
- margin-left: 1.5rem;
- margin-right: 1.5rem;
-}
-
.mx-auto {
margin-left: auto;
margin-right: auto;
flex: 1 1 0%;
}
+.flex-shrink-0 {
+ flex-shrink: 0;
+}
+
.translate-x-full {
--tw-translate-x: 100%;
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
line-height: 1.25rem;
}
+.text-xl {
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+}
+
.text-xs {
font-size: 0.75rem;
line-height: 1rem;
--accent2: #10b981;
--accent-glow: rgba(147, 51, 234, 0.1);
--text: #1f2937;
- --text-dim: #6b7280;
+ --text-dim: #374151;
--muted: #d1d5db;
}
+/* Prose overrides for light theme */
+
+html.theme-light .prose,
+html.theme-light .prose-invert {
+ color: var(--text);
+}
+
+html.theme-light .prose a,
+html.theme-light .prose-invert a {
+ color: var(--accent);
+}
+
+html.theme-light .prose strong,
+html.theme-light .prose-invert strong {
+ color: var(--text);
+}
+
+html.theme-light .prose code,
+html.theme-light .prose-invert code {
+ color: var(--accent2);
+}
+
+html.theme-light .prose pre,
+html.theme-light .prose-invert pre {
+ background-color: var(--surface);
+ color: var(--text);
+}
+
+html.theme-light .prose h1,
+html.theme-light .prose h2,
+html.theme-light .prose h3,
+html.theme-light .prose h4,
+html.theme-light .prose h5,
+html.theme-light .prose h6,
+html.theme-light .prose-invert h1,
+html.theme-light .prose-invert h2,
+html.theme-light .prose-invert h3,
+html.theme-light .prose-invert h4,
+html.theme-light .prose-invert h5,
+html.theme-light .prose-invert h6 {
+ color: var(--text);
+}
+
+html.theme-light .prose blockquote,
+html.theme-light .prose-invert blockquote {
+ color: var(--text);
+ border-left-color: var(--accent);
+}
+
/* Responsive utilities */
@media (max-width: 768px) {
color: var(--accent);
}
+.hover\:opacity-80:hover {
+ opacity: 0.8;
+}
+
.hover\:opacity-90:hover {
opacity: 0.9;
}
grid-column: span 2 / span 2;
}
+ .md\:inline {
+ display: inline;
+ }
+
.md\:flex {
display: flex;
}
+++ /dev/null
-document.addEventListener('DOMContentLoaded', function() {
- // Get all language switcher elements
- const langSwitchers = document.querySelectorAll('[data-lang-switch]');
-
- if (!langSwitchers || langSwitchers.length === 0) {
- return;
- }
-
- // Add click event listener to each language switcher
- langSwitchers.forEach(function(switcher) {
- switcher.addEventListener('click', function(e) {
- e.preventDefault();
-
- // Get the language code from the data attribute
- const langCode = this.getAttribute('data-lang-switch');
-
- // Store the language preference in localStorage
- localStorage.setItem('preferred-language', langCode);
-
- // Navigate to the language-specific URL
- window.location.href = this.href;
- });
- });
-});
<meta property="og:site_name" content="{{ .Site.Title }}">
<title>{{ .Title }}{{ if ne .Title .Site.Title }} — {{ .Site.Title }}{{ end }}</title>
+ <!-- Favicon -->
+ <link rel="icon" type="image/png" href="/images/fav.png">
+
<!-- Fonts -->
<link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@400;500;600;700&family=JetBrains+Mono:wght@400;600&family=Oxanium:wght@400;600;700&display=swap" rel="stylesheet">
{{ $menuScript := resources.Get "js/menu.js" | minify }}
<script src="{{ $menuScript.RelPermalink }}"></script>
- <!-- Language switcher script -->
- {{ $langScript := resources.Get "js/language-switcher.js" | minify }}
- <script src="{{ $langScript.RelPermalink }}"></script>
-
<!-- Contact form script -->
{{ $contactScript := resources.Get "js/contact-form.js" | minify }}
<script src="{{ $contactScript.RelPermalink }}"></script>
<div class="border-t border-border pt-8">
<h3 class="text-lg font-semibold text-accent mb-4">{{ i18n "tags" }}</h3>
<div class="flex flex-wrap gap-2">
+ {{ $lang := .Lang }}
{{ range .Params.tags }}
+ {{ $tagUrl := printf "/tags/%s/" (. | urlize) }}
+ {{ if eq $lang "it" }}
+ {{ $tagUrl = printf "/it/tags/%s/" (. | urlize) }}
+ {{ end }}
<a
- href="/tags/{{ . | urlize }}/"
+ href="{{ $tagUrl }}"
class="inline-flex items-center px-3 py-1 border border-border/30 rounded hover:border-accent/50 hover:text-accent transition-colors text-sm"
>
{{ . }}
<div class="border-t border-border pt-8">
<h3 class="text-lg font-semibold text-accent mb-4">{{ i18n "tags" }}</h3>
<div class="flex flex-wrap gap-2">
+ {{ $lang := .Lang }}
{{ range .Params.tags }}
+ {{ $tagUrl := printf "/tags/%s/" (. | urlize) }}
+ {{ if eq $lang "it" }}
+ {{ $tagUrl = printf "/it/tags/%s/" (. | urlize) }}
+ {{ end }}
<a
- href="/tags/{{ . | urlize }}/"
+ href="{{ $tagUrl }}"
class="inline-flex items-center px-3 py-1 border border-border/30 rounded hover:border-accent/50 hover:text-accent transition-colors text-sm"
>
{{ . }}
{{ define "main" }}
<section class="min-h-[calc(100vh-200px)] flex items-center justify-center px-4 py-12">
- <div class="max-w-2xl w-full">
+ <div class="max-w-4xl w-full">
<!-- Profile Image (optional) -->
{{ if .Params.image }}
<div class="flex justify-center mb-8">
{{ end }}
<!-- Author Name -->
- <h1 class="text-4xl md:text-5xl font-bold text-accent text-center mb-4">
+<!-- <h1 class="text-4xl md:text-5xl font-bold text-accent text-center mb-4">
{{ .Site.Params.author }}
</h1>
-
+ -->
<!-- Bio (from page content) -->
- <div class="text-lg text-text-dim text-center mb-8 leading-relaxed prose prose-invert max-w-none">
+ <div class="text-xl text-text-dim text-center mb-8 leading-relaxed prose prose-invert max-w-none">
{{ .Content }}
</div>
<!-- Call-to-Action Buttons -->
<div class="flex flex-col sm:flex-row gap-4 justify-center">
+ {{ $lang := .Lang }}
+ {{ $articlesUrl := "/articles/" }}
+ {{ $contactUrl := "/is/here/" }}
+ {{ if eq $lang "it" }}
+ {{ $articlesUrl = "/it/articles/" }}
+ {{ $contactUrl = "/it/is/here/" }}
+ {{ end }}
+
<!-- Articles Button -->
<a
- href="/articles/"
+ href="{{ $articlesUrl }}"
class="px-8 py-3 bg-accent text-white rounded font-semibold hover:opacity-90 transition-opacity text-center"
>
{{ i18n "articles" }}
<!-- Contact Button -->
<a
- href="/is/here/"
+ href="{{ $contactUrl }}"
class="px-8 py-3 border-2 border-accent text-accent rounded font-semibold hover:bg-accent/10 transition-colors text-center"
>
{{ i18n "contact" }}
--- /dev/null
+{{ define "main" }}
+<div class="mx-auto px-4 py-12">
+ <div class="grid md:grid-cols-3 gap-8">
+ <!-- Article section -->
+ <div class="md:col-span-2">
+ <!-- Article header -->
+ {{ partial "article-header.html" . }}
+
+ <!-- Article content -->
+ <div class="prose prose-invert max-w-none mb-12">
+ {{ .Content }}
+ </div>
+ </div>
+
+ <!-- Sidebar -->
+ {{ partial "sidebar.html" . }}
+ </div>
+</div>
+{{ end }}
{{ end }}
</nav>
- <!-- Divider -->
- <div class="border-t border-border/30 mx-6"></div>
-
<!-- Language switcher -->
<div class="p-6">
<div class="text-sm text-text-dim mb-3">{{ i18n "language" }}</div>
{{ end }}
{{ end }}
<a
- data-lang-switch="{{ $langCode }}"
href="{{ $url }}"
class="flex-1 py-2 px-3 text-center rounded transition-colors {{ if $current }}bg-accent text-white{{ else }}bg-surface hover:bg-surface/80{{ end }}"
>
</div>
</div>
- <!-- Theme toggle -->
- <div class="p-6 border-t border-border/30">
- <button
- id="theme-toggle"
- @click="closeMenu()"
- class="w-full py-3 px-4 bg-surface hover:bg-surface/80 rounded flex items-center justify-center gap-2 transition-colors"
- >
- <i data-feather="moon" class="w-4 h-4"></i>
- <span>{{ i18n "toggleTheme" }}</span>
- </button>
- </div>
</div>
</div>
<header class="sticky top-0 z-50 bg-bg2/92 backdrop-blur border-b border-border">
<nav class="container mx-auto px-4 py-4 flex items-center justify-between">
- <!-- Logo -->
- <a href="{{ .Site.BaseURL }}" class="font-bold text-lg text-accent font-oxanium">
- danix
+ <!-- Logo and Site Name -->
+ <a href="{{ .Site.BaseURL }}" class="flex items-center gap-2 hover:opacity-80 transition-opacity">
+ <img src="/images/lampD.png" alt="Logo" style="width: 40px; height: 40px; max-width: none;" class="flex-shrink-0">
+ <span class="hidden md:inline font-bold text-lg text-accent font-oxanium">danix.xyz</span>
</a>
<!-- Desktop menu (hidden on mobile) -->