Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
The dropdown select for new effects in ImageStyleEditForm sort effects by id. This results in weird sequence if you have contrib effects installed.
Proposed resolution
Sort the effects in the dropdown by label instead.
Before patch:
After patch:
Remaining tasks
review patch
User interface changes
More readable list of effects in the dropdown.
API changes
None
Data model changes
None
Comment | File | Size | Author |
---|---|---|---|
#17 | interdiff_13-17.txt | 744 bytes | mondrake |
#17 | 2654150-17.patch | 1.87 KB | mondrake |
Comments
Comment #2
mondrakeComment #3
mondrakeComment #4
mondrakeComment #8
bander2 CreditAttribution: bander2 as a volunteer commentedPatch not applying to 8.3.x-dev.
Comment #9
bander2 CreditAttribution: bander2 as a volunteer commentedComment #10
pritish.kumar CreditAttribution: pritish.kumar at OpenSense Labs commentedProviding the Reroll
Comment #11
pritish.kumar CreditAttribution: pritish.kumar at OpenSense Labs commentedComment #12
bander2 CreditAttribution: bander2 as a volunteer commentedLooks good.
Comment #13
cilefen CreditAttribution: cilefen commentedWe require tests for bugs in most cases. Here is one.
Comment #15
mondrakeLet's get this in then?
Comment #16
Wim Leerslgtm
Although I wonder why the string casting is necessary here.
Comment #17
mondrake@Wim Leers re
I think I remember there was a problem passing TranslatableMarkup objects instead of strings to the
strcasecmp
method when I first developed the patch in #2 in Jan 2016, but I cannot reproduce it now. Removing the explicit casting.Comment #18
katzillaTested at #drupalsprintberlin against 8.4.x and it works.
Comment #19
Wim LeersLooks perfect now!
Comment #21
mondrakeCannot understand #20
Comment #22
catchCommitted/pushed to 8.4.x, thanks!
Comment #25
rajeevku CreditAttribution: rajeevku commentedIt isn't displaying image styles provided by contrib module , i am using AMP and not getting image style 'AMP Image'.??