Cannot replace image file / colorspace changing on JPG

Two issues I ran into last night -

1 - I have a Instagram-like blog, basically each post is an image, and only one image. In the blueprint , the image file section is set to require 1 minimum/1 maximum - each post must have an image, and only one. When trying to replace the image that I had loaded, Kirby would not allow me to replace a .png with say, a .jpg, or vice versa - Kirby would only allow the same image type. It would also not allow me to delete the image in order to load a new one, which forced me to delete the entire post and start from scratch.

2 - One section of the site is an index, where the images from the blog are cropped by Kirby so that they are a bit smaller; this worked fine until this evening, when a new post had an image that was noticeably cooler in tint in the cropped image that it was in the correct, uncropped JPG. Worked around this by uploading a PNG to replace it (see #1 above)…

Not sure if I’m doing something wrong here or if it’s a quirk. I’ve done workarounds in the meantime but would like to understand what’s happening, and if it’s my error or a bug of some kind.

Which thumb driver are you using and which Kirby 3 version?

Since 3.6.1, color profiles should be preserved on jpeg images when using ImageMagick as the thumb driver(thumbs | Kirby CMS). You can read more about the background why this doesn’t work for png’s in this issue thread: Keep icc color profiles by fabianmichael · Pull Request #3649 · getkirby/kirby · GitHub

As regards your first issue, I’d suggest you use a files field instead of a section, so that you can upload more images but only select one out of the uploaded ones.

This is on Kirby I haven’t explicitly set the thumbs driver, so it should be GD Lib.

I’ll take another stab at the blueprints with a files field, thanks!