Skip to content
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

Focal point doesn't work properly when the preview image for the focal_point widget uses an image style that uses a focal_point image effect #790

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

dipakmdhrm
Copy link
Collaborator

@dipakmdhrm dipakmdhrm commented Jan 28, 2025

Reference: https://www.drupal.org/node/2872960

Update:

  • Added a new 'Focal point preview' image style with simple '480px width scale' effect.
  • Update the Image field focal_point widget in Image media entity to use this image style.
Before After
https://github.com/user-attachments/assets/f6e09d3e-3504-488c-84d1-924ace42257a https://github.com/user-attachments/assets/689fa5b9-29f4-4039-8adb-44d73e69b3b6

Copy link
Member

@AronNovak AronNovak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Do you happen to have a screenshot of the result? Is it ported from a client project? Does it affect all of our projects with Focal Point module installed? 🤔

@dipakmdhrm
Copy link
Collaborator Author

dipakmdhrm commented Jan 28, 2025

Looks good. Do you happen to have a screenshot of the result?

@AronNovak I've attached the before and after video in the PR description.

Is it ported from a client project? Does it affect all of our projects with Focal Point module installed? 🤔

Yes, anything forked from drupal-starter after 2022 October is potentially affected by this.

@dipakmdhrm
Copy link
Collaborator Author

@AronNovak I'm realizing now you meant result of the crop in content.
Here are screenshots:

Focal point Before After
focal_point before after

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants