Closed ElastiCourse closed 2 months ago
Actually, that's the expected behavior.
In single post view, vibrant.min.js is loaded, however it's not used.
It's used for related post cards.
Unless you have a static background color set in content/categories/category-name/_index.md it will be a plain white background color.
That's how it works. Otherwise, the browser would have to download category images just to calculate the dominant color, without displaying the image. That's a waste of bandwidth.
What happened?
First off, Thanks Jimmy for the recent theme update and fixing deprecated commands in the code.
I love the idea of node-vibrant. I expect it to find the dominant color of an image and sets it as the background color of each post's categories. There are two issues I'm currently seeing with the current implementation:
color.ts
and referenced inmain.ts
doesn't seem to be working at all. The actual background colors for categories is randomly selected from 5 hardcoded colors configured invariables.scss
$defaultTagBackgrounds: #8ea885, #df7988, #0177b8, #ffb900, #6b69d6;
vibrant.min.js
is loaded, however it's not used. I would love too see the categories colored in single post view as well. Unless you have a static background color set incontent/categories/category-name/_index.md
it will be a plain white background color.I've done some additional testing but seen no difference:
TIA
Hugo version
0.131extended
Theme version
3.27
What browsers are you seeing the problem on?
Chrome
More information about the browser
Chrome 128
Relevant log output
Link to Minimal Reproducible Example
Content List