xwp / unsplash-wp

GNU General Public License v2.0
9 stars 3 forks source link

Image Block conflict when using Jetpack and Unsplash #198

Closed postphotos closed 4 years ago

postphotos commented 4 years ago

Bug Description

Both Unsplash and Jetpack override the default Image Block experience.

Here's what Jetpack's integration looks like:

Screen Shot 2020-07-27 at 11 44 08 AM

And Unsplash's:

Screen Shot 2020-07-27 at 11 52 59 AM

We need to make sure these play nicely together.

Expected Behaviour

Steps to reproduce

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Screenshots

Additional context


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

Implementation brief

QA testing instructions

Demo

Changelog entry

derekherman commented 4 years ago

@postphotos Did you test that they don't work together?

postphotos commented 4 years ago

Correct @derekherman - this is screenshots from a test site.

Something about the way we're interacting with the image block is overriding the Media Library to show a menu (with Pexels and Google Photos.) When Jetpack is activated, it should continue to show their integration. Deactivating Unsplash restores this.

I think it's probably a bug with Jetpack and not Unsplash... but filing here for someone to investigate.

ravichdev commented 4 years ago

This a tricky one because of the way plugins can filter the MediaUpload component. Due to an earlier featured image issue with AMP/Unsplash plugin we bumped the priority of our filter to 20, Jetpack plugin is using the same filter to add the Button dropdown but with a lower priority of 11 and we end up overriding their changes. I've pushed up a fix and opened a PR for now. Will also open an issue in the Jetpack repo to increase their priority to something like 100

ravichdev commented 4 years ago

Issue #16668 opened in the Jetpack repo to increase the priority. cc @postphotos