Danilo M. [Wed, 15 Apr 2026 20:56:55 +0000 (22:56 +0200)]
Document video, quote, and actions shortcodes in SHORTCODES.md
- Add comprehensive Video shortcode documentation with parameters and examples
- Document page bundle video resolution for automatic URL generation
- Add browser compatibility notes for WebM, MP4, and Ogg formats
- Document Quote shortcode with source attribution and optional links
- Document Actions shortcode for download buttons and CTAs
- Update Future Shortcodes section to reflect implemented features
Danilo M. [Wed, 15 Apr 2026 20:55:05 +0000 (22:55 +0200)]
Resolve page bundle video paths using Resources API
- Use .Page.Resources.GetMatch to resolve video files in page bundles
- For videos in the same directory as index.md, use src="filename.webm"
- Template automatically resolves to correct permalink (/articles/slug/filename.webm)
- Falls back to literal path if resource not found (for external URLs)
Danilo M. [Wed, 15 Apr 2026 20:41:41 +0000 (22:41 +0200)]
Allow custom sizing in image shortcode
- Move w-full h-auto into default class parameter instead of hardcoding
- Users can now override sizing with custom class parameter
- Default still applies w-full h-auto if no class specified
- Update SHORTCODES.md documentation with sizing examples
- Add CSS class reference tables for common sizing patterns
Danilo M. [Wed, 15 Apr 2026 20:25:01 +0000 (22:25 +0200)]
Resolve page bundle image paths correctly
- Use Hugo Resources API to resolve image paths for page bundles
- For images in the same directory as index.md, use image = "filename.jpg"
- Template automatically resolves to correct permalink (/articles/slug/filename.jpg)
- Falls back to literal image path if resource not found (for external URLs)
Danilo M. [Wed, 15 Apr 2026 20:21:22 +0000 (22:21 +0200)]
Fix article list template to display articles without pinned parameter
- Handle undefined .Params.pinned gracefully by checking for nil/"" values
- This allows articles without explicit pinned param to appear in regular posts section
- Added check: if where clause returns no unpinned posts, search for nil/empty params
- Articles test index now has proper TOML frontmatter with title
Danilo M. [Wed, 15 Apr 2026 20:14:02 +0000 (22:14 +0200)]
Add thumbnail support to article listings
- Add 'image' front matter parameter for article thumbnails
- Redesign article-list-item.html as semantic article card:
- Large thumbnail (aspect-video, object-cover) at top if image is present
- Title linked to article page
- Publication date and type badge
- Excerpt (from .Description or .Summary with plainify)
- "Read more" CTA button with arrow icon and hover animation
- Increase list container width (max-w-2xl → max-w-3xl) and spacing (space-y-2 → space-y-6)
- Thumbnail image has subtle scale-up hover effect
- Arrow icon animates on hover
- All three clickable elements (.image, title, CTA) link to article
Danilo M. [Wed, 15 Apr 2026 20:05:38 +0000 (22:05 +0200)]
Implement taxonomy system for tags and categories
- Enable tags and categories taxonomies in hugo.toml
- Create taxonomy/list.html for archive pages (/tags, /categories)
- Create taxonomy/term.html for individual term pages (/tags/example)
- Add quote shortcode for quote-type articles
- Both templates reuse article-list-item partial for consistent styling
Danilo M. [Wed, 15 Apr 2026 19:48:54 +0000 (21:48 +0200)]
Fix theme toggle icon to always sync with actual page theme
Replace Alpine.js conditional rendering with plain JavaScript that:
- Reads the actual theme class from the html element on page load
- Updates icon visibility based on the real DOM state, not internal state
- Handles navigation correctly since it checks the current class every time
This fixes the issue where navigating between pages caused the icon to
become out of sync with the actual theme being displayed.
Danilo M. [Wed, 15 Apr 2026 19:46:40 +0000 (21:46 +0200)]
Fix theme toggle icon state sync on page navigation
The Alpine.js state was reading from localStorage instead of the actual
class on the html element, causing the icon to be out of sync with the
actual theme. Now we initialize the Alpine state by checking the current
html classList, which is set by the page-load script in baseof.html.
Danilo M. [Wed, 15 Apr 2026 19:42:04 +0000 (21:42 +0200)]
Fix design system compliance: CSS variables, accessibility, and theme system
Core CSS improvements:
- Add --surface-rgb, --type-* (tech, life, quote, link, photo) custom properties
- Add --type-* semantic color classes for article badges
- Convert article badges from inline styles to CSS variable system
- Add prefers-color-scheme light fallback for no-JS users
- Add prefers-reduced-motion support to respect user accessibility settings
- Replace *:focus with *:focus-visible (keyboard-only outlines)
- Add clamp() fluid typography for hero-title and section-title
- Refactor container rules to mobile-first with 1060px breakpoint
Theme & Icon fixes:
- Fix theme toggle icon display with Alpine.js (was broken with Tailwind dark: classes)
- Add aria-hidden="true" to icon elements
- Update header with proper ARIA attributes on menu toggle
Accessibility enhancements:
- Add skip-to-main-content link in baseof.html
- Update hamburger menu with aria-expanded, aria-controls, aria-hidden
- Implement focus trap (Tab loops) within mobile menu
- Return focus to trigger button on menu close
- Add menu open/close state management with proper ARIA
Semantic HTML:
- Wrap article pages in <article> element (articles/single.html, _default/single.html)
- Fix quote article to use --type-quote border color instead of generic accent
Image optimization:
- Add loading="lazy" to profile image in index.html
- Add loading="lazy" to featured image in photo.html
Template fixes:
- Remove broken os.Getenv "THEME" runtime check from article-list-item.html
- Replace inline color styles with semantic .type-* classes
- Add 1060px lg: breakpoint to tailwind.config.js
Danilo M. [Wed, 15 Apr 2026 19:18:40 +0000 (21:18 +0200)]
Complete multilingual theme implementation with language-aware menus
- Refactor hugo.toml to define menus separately for each language using pageRef
- Simplify header and hamburger-menu templates to use Hugo-native language handling
- Update content structure with proper language prefix organization
- Remove JavaScript language-switcher in favor of Hugo's native approach
- Add new layout templates for /is/ section with list view
- Update HANDOFF.md with current implementation status
- Rebuild minified CSS with updated template changes
Danilo M. [Wed, 15 Apr 2026 15:50:16 +0000 (17:50 +0200)]
Fix gravatar shortcode and about page ref links
- Fix gravatar.html: replace trim() with strings.TrimSpace()
- Fix about pages: replace {{< ref "legal" >}} with relative path ../legal
- Both English and Italian about pages now build without errors
Danilo M. [Wed, 15 Apr 2026 15:46:10 +0000 (17:46 +0200)]
Fix contact form shortcode: rename from contact-form.html to contact.html
Problem: Hugo v0.160 doesn't find shortcode as 'contact_form' when filename is contact-form.html
Solution: Rename to contact.html so shortcode is {{< contact >}}
- Rename shortcodes/contact-form.html → contact.html
- Update contact pages to use {{< contact >}} shortcode
- Remove unused dict initialization line from contact shortcode
- Contact form now works on both English and Italian contact pages
Danilo M. [Wed, 15 Apr 2026 15:43:32 +0000 (17:43 +0200)]
Extract contact form JavaScript to separate file and remove shortcode from contact pages
- Move contact form Alpine.js logic to assets/js/contact-form.js
- Simplify contact-form.html shortcode by removing inline script
- Load contact-form.js in baseof.html after Alpine.js
- Temporarily remove {{< contact_form >}} shortcode from contact pages
(shortcode parsing issue to investigate later)
- Contact pages now display with placeholder text
Danilo M. [Wed, 15 Apr 2026 15:39:02 +0000 (17:39 +0200)]
Remove unnecessary type field from static pages
The 'type' field is unused for static pages. Hugo automatically sets
the type based on directory structure. The 'type' custom parameter is
only used for articles (Life, Photo, Link, Quote, Tech).
Danilo M. [Wed, 15 Apr 2026 15:33:26 +0000 (17:33 +0200)]
Fix language switcher to preserve current page path
- Update language switcher to translate current page path instead of redirecting to root
- When switching languages, preserve the page you're on (e.g., /articles/ → /it/articles/)
- Works for both desktop header and mobile hamburger menu
- Uses Hugo's string functions to manipulate URL paths
Danilo M. [Wed, 15 Apr 2026 15:31:52 +0000 (17:31 +0200)]
Add language toggle to desktop header
- Add language switcher (IT/EN) visible on desktop only
- Language buttons show in header next to theme toggle
- Current language highlighted with accent background
- Mobile still uses hamburger menu for language toggle
- Responsive design: hidden on mobile (md:hidden), visible on desktop
Danilo M. [Wed, 15 Apr 2026 15:30:01 +0000 (17:30 +0200)]
Remove Alpine.js dependency from menu toggle, use vanilla JavaScript
- Replace Alpine.js directives (@click, x-ref) with vanilla JS
- Update hamburger-menu.html to use id selectors instead of x-ref
- Rewrite menu.js to work without Alpine.js
- Menu now opens/closes on click with proper event handling
- Language toggle now accessible in hamburger menu
Danilo M. [Wed, 15 Apr 2026 15:25:14 +0000 (17:25 +0200)]
Fix Hugo v0.160 compatibility: remove os.Getenv and fix template syntax
- Remove os.Getenv("THEME") call that violates security policy
- Use CSS variables and data attributes for theme-aware badge colors
- Update theme-toggle.js to update badge colors on theme switch
- Fix .LastMod → .Lastmod (correct API)
- Fix template syntax for date comparison in article-header.html
Danilo M. [Wed, 15 Apr 2026 14:38:12 +0000 (16:38 +0200)]
Fix shortcode location: move from shortcodes/ to layouts/shortcodes/
Hugo v0.156.0+ requires shortcodes to be in layouts/shortcodes/ directory.
Moved all shortcodes (gravatar, image, gallery, contact-form) to correct location.
Danilo M. [Wed, 15 Apr 2026 14:18:41 +0000 (16:18 +0200)]
Set up Tailwind CSS build pipeline and bilingual homepage content
- Install and configure Tailwind CSS with tailwind.config.js
- Create npm scripts for building Tailwind (build/watch)
- Add .gitignore to exclude node_modules and build artifacts
- Create bilingual homepage content (content/it/_index.md, content/en/_index.md)
- Update baseof.html to use compiled main.min.css
- Fix .ByDate deprecation in list.html template (use sort function)
- Fix main.css pre element to support rgba with opacity
- Homepage now displays with full dark/light theme styling