Skip to content
This repository has been archived by the owner on Mar 11, 2024. It is now read-only.

Preview Thumbnails are not thumbs but original images #62

Closed
moritzebeling opened this issue Jan 29, 2021 · 1 comment · Fixed by #64
Closed

Preview Thumbnails are not thumbs but original images #62

moritzebeling opened this issue Jan 29, 2021 · 1 comment · Fixed by #64

Comments

@moritzebeling
Copy link

The pagetable section seems to not show a small thumbnail but the original image instead. Can this be? It occurred to me in 2 completely separate installations, both running the current Kirby and current plugin version. This makes the backend very slow. It happens on my Apache web host and locally, while the thumbnails for the regular page sections get delivered as usual.

It looks like the thumbnail image gets selected here:
https://github.com/sylvainjule/kirby-pagetable/blob/master/lib/pagetable.php#L200
using the panelImage()method:

$thumb = ['width' => 100, 'height' => 100];
$image = $item->panelImage($this->image, $thumb);

When I look at the definition of that method
https://github.com/getkirby/kirby/blob/3.5.1/src/Cms/ModelWithContent.php#L388
it apparently takes only one argument:

function panelImage( string|array|false|null $settings = null): ?array

Can this somehow cause for the section to show not the usual 72x72 thumbnail, but the original image instead?

I played a little bit to try different inputs in that $settings-thing, but I couldn’t manage to get the desired result.

Can someone reproduce the problem? Or am I the only one? ;)

@moritzebeling moritzebeling changed the title Preview Thumbnails Preview Thumbnails are not thumbs but original images Jan 29, 2021
@s3ththompson
Copy link
Contributor

Came here to post the same issue! Looks like this issue came up before (looking at commit logs) but I can confirm that a fresh install of the latest version of pagetable is still loading original images.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants