-
Notifications
You must be signed in to change notification settings - Fork 0
Image file conventions
During generation, images are regenerated at multiple sizes and aspect ratios to allow for performant and flexible display in the site. These sizes are determined by the ./data/images/sizes.json file. This file provides a name for a size, and specifies width (or w) and, optionally, height (or h). If no height is specified, the same value as width is used.
Files will only be reduced and cropped and will not be enlarged if they are smaller than the size specified. With this in mind image files follow certain conventions to ensure a good starting point. These conventions aren't strictly necessary but the dimensions do give a nice crisp baseline.
All album cover files are stores in the /data/images/album-artwork folder. This is the case regardless of whether they're used in reviews, articles, or any other type of content. Album artwork goes in the album artwork folder.
Album artwork image files should be:
- 1000px by 1000px
- JPG format
- Compressed at TinyJPG or some such place
This keeps the images sharp and the file sizes modest.
The file name format goes album-name-artist-name.jpg. For example, the album artwork file of The Downward Spiral by Nine Inch Nails is the-downward-spiral-nine-inch-nails.jpg. This is handy both for tidiness and finding files for other purposes (social media, newsletters, and so on).
All articles have a featured image. They may or may not be shown on the article itself but will always appear on the homepage, section directories (e.g. audioxide.com/articles), and tag listings. These files are stored in the /data/images/article-images folder.
Article featured image files should be:
- 1500px wide by 1000px high
- JPG format
- Compressed at TinyJPG or some such place
There is not a strict naming convention for featured images. It could be the slug of the article or something more descriptive of the content of the image itself. Do what seems most sensible in the moment.
Though not strictly necessary it's generally best for the focal point of the image to be in the middle third. This is because on related post listings featured images are square, so the sides of article featured images are cropped out.