feat: global thumbnail aspect ratio configuration

- Add thumbnailAspectRatio site parameter (default '1.5')
- Use decimal values instead of fractions for Hugo compatibility
- Sanitize user input to extract only numeric characters
- Apply to article cards, related cards, and term cards
- Update both source and compiled CSS

Closes #2839
This commit is contained in:
jin-li committed 2026-03-29 14:27:09 +02:00
1 parent faea1bb046
commit a308a86365
6 files changed
+22 -7

No files matched your search

+2
View File
@@ -29,6 +29,8 @@ disableTextInHeader = false
# defaultFeaturedImage = "IMAGE.jpg" # used as default for featured images in all articles
# defaultSocialImage = "/android-chrome-512x512.png" # used as default for social media sharing (Open Graph and Twitter)
hotlinkFeatureImage = false
# Thumbnail aspect ratio as a number (e.g., "1.5", "1.0", "1.777")
# thumbnailAspectRatio = "1.5"
# imagePosition = "50% 50%"
# highlightCurrentMenuArea = true