8.2 Image helper / block png output bug?

Permalink
I have a custom block with 2 image upload fields. Outputs a background with logo overlay.
Within the view I use this code.
if($fIDC){
   $file = File::getByID($fIDC);
   $image = \Core::make('html/image', array($file));
   $tag = $image->getTag();
}
echo $tag;

This code generates (thumbs) jpg's in a picture element instead of the original file extension (.png)

Concrete V5.7 generates the correct extension.
Bug or something different/changed in v8.2?

-> This also happens with the image block when using a png.
-> Setting the thumbnail generate (jpg/png) Dashboard option makes no difference

---- update for svg output ----
Piece of code copied from image block, but still outputs .jpg instead of .png
if($fIDC){
   $file = File::getByID($fIDC);
   if ($file->getTypeObject()->isSVG()) {
        $tag = new \HtmlObject\Image();
        $tag->src($file->getRelativePath());
        $tag->addClass('ccm-svg');
   }else{
      $image = \Core::make('html/image', array($file));
      $tag = $image->getTag();
   }
}

c5dragon
 
barkingtuna replied on at Permalink Reply
barkingtuna
This is an ongoing issue... thumbnail caching, and it was reported in the Bug Tracker.https://www.concrete5.org/developers/bugs/8-2-0/cached-thumbnails-ar...
c5dragon replied on at Permalink Reply
c5dragon
Don't think this is the same.
c5dragon replied on at Permalink Reply
c5dragon
Reproduced on a clean install of 8.2 (image block)
- dashboard/system/files/thumbnails -> options -> Automatic / GD library
- Placed image block on page with a png image. ( < 400px)
- Output is the picture element with original img png path with the png extension
- dashboard/system/files/thumbnails -> Added new thumbnail sizes/breaks 768/992/1230
- Output is the picture element with the thumbnail versions but with jpg extension

The jpg's are transparent so I guess this only added the wrong extension.
pixelsnbeards replied on at Permalink Reply
I have this exact same issue. Tested the clean install with no thumbnail breakpoints and the file keeps the original extension.

This is a very very bad bug and should be fixed asap. Workaround would be greatly appreciated as the .jpg extensions bug out in IE11<.

I can only think of commenting out the thumbnail breakpoints in page_theme.php but that shouldn't be the solution.
mlocati replied on at Permalink Reply
mlocati
If / when the core team acceptshttps://github.com/concrete5/concrete5/pull/5900... , this issue should be fixed (feedback is welcome)