-
Notifications
You must be signed in to change notification settings - Fork 122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add defaultCropType param #4357
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tested locally, works nicely, great work!
Seen on media-api (merged by @dblatcher 8 minutes and 41 seconds ago) Please check your changes! |
Seen on auth, thrall, kahuna (merged by @dblatcher 8 minutes and 46 seconds ago) Please check your changes! |
Seen on cropper, usage (merged by @dblatcher 8 minutes and 56 seconds ago) Please check your changes! |
Seen on collections, leases (merged by @dblatcher 8 minutes and 59 seconds ago) Please check your changes! |
Seen on image-loader (merged by @dblatcher 9 minutes and 6 seconds ago) Please check your changes! |
Seen on metadata-editor (merged by @dblatcher 9 minutes and 14 seconds ago) Please check your changes! |
What does this change?
Adds a
defaultCropType
param to kahuna's search, image and crop pages and validates and stores it in the same way as the existingcropType
param.The
defaultCropType
is used to set what type of crop to initially set the on the crop window. If the param is not set, this will default to 'landscape', (being defined asdefaultCrop
) as currentlyHow should a reviewer test this change?
run locally, open:
https://media.local.dev-gutools.co.uk/search?nonFree=true&defaultCropType=freeform
choose an image, click the 'crop' button
the crop UI should have "freeform" selected instead of "landscape"
How can success be measured?
The purpose is to allow application that use a Grid window to specify the "preferred" crop type, without preventing user selecting other crops.
In particular, the request is for Gallery Articles in composer - when adding images, they should default to freeform (which will start as a full frame crop), but users should be able to select other, existing crops if desired.
Who should look at this?
Tested? Documented?