Drupal core comes with 4 image styles:

  • Large (480×480)
  • Media Library thumbnail (220×220)
  • Medium (220×220)
  • Thumbnail (100×100

This issue is to create a new image style called "wide" or "full" or something else (we're currently calling it "hero" in Olivero). The image would need to be scaled down to 1090px or larger.

This is to support the design of the new Olivero theme (#3111409: Add new Olivero frontend theme to Drupal 9.1 core as beta).

Olivero article screenshot

The image style is currently bundled with Olivero, but that won't be acceptable for core because if you uninstall Olivero and then attempt to reinstall it, it will fail because the image style already exists. See #3125491: Errors after installing / uninstalling / reinstalling Olivero.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mherchel created an issue. See original summary.

mherchel’s picture

Issue summary: View changes
larowlan’s picture

Issue tags: +Novice
asmita26’s picture

Assigned: Unassigned » asmita26
asmita26’s picture

Created a new image style in drupal core named as "Wide(1090)" which styles image to 1090px wide and scale effect so that it doesn't conflict with Olivero theme.

asmita26’s picture

Assigned: asmita26 » Unassigned
Status: Active » Needs review
ambuj_gupta’s picture

Assigned: Unassigned » ambuj_gupta

Status: Needs review » Needs work

The last submitted patch, 5: 3153009-5.patch, failed testing. View results

ambuj_gupta’s picture

Assigned: ambuj_gupta » Unassigned
Status: Needs work » Reviewed & tested by the community
FileSize
328.37 KB
589.91 KB

Testing Steps: This require fresh drupal Install
1. Download Drupal
2. Add the patch file to "/core/modules/image/config/install"
3. Install Drupal and login with an admin
4. Go to "/admin/config/media/image-styles". And check the image styles.
5. Install the OIivaro theme and set it as default.
5. Create a Content Type with two Image fields having different Image Style: Hero and Wide.
6. Create the node of the content type.
7. Uninstall the Oliver Theme. And check.
8. Re-Intall the Olivero Theme. And check.

Testing Results:
Tested by Applying the patch #5. And it's working as expected without any conflict with the Olivero Theme.

hansa11’s picture

Thank you @asmita26 for your contribution.

I have reviewed your patch and it works fine for me.

larowlan’s picture

Status: Reviewed & tested by the community » Needs work

There's some failing tests here

himanshu_sindhwani’s picture

Assigned: Unassigned » himanshu_sindhwani

I will try to create the patch passing the test cases.

himanshu_sindhwani’s picture

Assigned: himanshu_sindhwani » Unassigned
Status: Needs work » Needs review
FileSize
3.39 KB

Tried to fix the failing test cases.

himanshu_sindhwani’s picture

The previous patch failed to apply. Here is a new patch with fix.

ambuj_gupta’s picture

Assigned: Unassigned » ambuj_gupta
himanshu_sindhwani’s picture

hi @ambuj_gupta, It's good to unassign the issue if it is taking more time. Please check the policy here: https://www.drupal.org/node/2172049 . Moreover the doc mentions the issue should not be assigned when in needs review state. Since an issue is open to any number of reviewers.

ambuj_gupta’s picture

Assigned: ambuj_gupta » Unassigned
Status: Needs review » Reviewed & tested by the community
FileSize
253.77 KB
186.29 KB

Tested and Verified by applying patch #14. And it's working as expected without any conflict with the Olivero Theme.

mherchel’s picture

Looked at the code, and everything looks great to me. Thanks!

  • larowlan committed ed4655e on 9.1.x
    Issue #3153009 by himanshu_sindhwani, asmita26, ambuj_gupta, mherchel:...
larowlan’s picture

Status: Reviewed & tested by the community » Fixed

Committed ed4655e and pushed to 9.1.x. Thanks!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

mherchel’s picture

Kristen Pol’s picture

Thanks for finding that @mherchel!

Adding the issue to the related issues field. I closed out the related issue as duplicate. This issue is already closed but, otherwise, I would ask the committers to consider issue credits for participants in the other issue as it's older. :)

xjm’s picture

Issue tags: +9.1.0 highlights