Hi all users of the croppable image 3 fieldtype.
I'm currently working on the module, or better I'm reworking the module to support webp copys like the core image field does.
Unfortunately this will break backwards compatibility! ?
My questions are, how should we handle this?
Until now the crop variation has this sort of names: basename.ext becomes basename.-suffix.ext
But with the new version, it looks like regular image variation files with a -suffix: basename.ext becomes basename.100x200-suffix.ext
My current thoughts are along that lines:
I create a new named module: CroppableImage4, that supports the same API as the CAI3 version plus an alternative method like getCrop4("suffix"), and I add some checking, when the CAI3 is installed / active, it only hooks the plus method, not the regular one.
What do you think? Any suggestions, ideas, wishes?
And how can we savely update from CAI3 to CAI4, for example with existing websites containing tons of images ❓
PS: Besides that, the new module now supports individual $options as array or selector strings. It generates 0x48 thumbs and webp copies by auto generation and by manually creating a crop. It removes all variations on every changes: changing a single image, changing or removing settings.
It has input fields in modules config for webpAdd and webpQuality, so you can handle it different from the $config->imageSizerSettings, and you now can add individual options with every API call, like with the core image field: $pageimage->getCrop("suffix", $options)->url, or $pageimage->getCrop("suffix", $options)->webp->url. And some more minor tweaks.