[6.x] Add explicit thumbnail modes - #19575
Conversation
📚 Storybook previews@craftcms/ui — open Storybook Changed components: resources/js — open Storybook No changed components detected in this Storybook. |
…getthumbhtml # Conflicts: # CHANGELOG.md
|
This PR had conflicts with Claude's response
|
|
This PR had conflicts with Claude's response
|
|
This PR had conflicts with Claude's response
|
…getthumbhtml # Conflicts: # CHANGELOG.md
|
This PR had conflicts with Claude's response
|
Description
Adds an optional
ImageTransformMode $modeargument to core thumbnail APIs, replacing size-dependent cropping with an explicit choice. The mode is passed through custom fields, relations, nested field layouts, asset transforms, and both responsive image URLs.Control panel chips and thumbnail tiles use
Fit, while cards useCrop. Thecraft-thumbnailcomponent supportsfit,crop,stretch, andletterbox, including slotted images and SVGs. Native user photos retain their square crops.