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

Images & Gallery placeholder opens media library if switching from text #1652

Closed
jasmussen opened this issue Jul 3, 2017 · 5 comments
Closed
Labels
[Feature] Blocks Overall functionality of blocks [Type] Bug An existing feature does not function as intended

Comments

@jasmussen
Copy link
Contributor

Steps to reproduce:

  1. Insert an image block
  2. Click the "close" button so that a placeholder gets inserted
  3. Switch to text mode
  4. Switch back to visual mode

Notice how the media library gets loaded as soon as the placeholder is initialized. You can also do this if you save the post, then return back to edit it later.

@jasmussen jasmussen added [Feature] Blocks Overall functionality of blocks [Type] Bug An existing feature does not function as intended labels Jul 3, 2017
@youknowriad
Copy link
Contributor

Not sure how to solve this without adding a new prop to the block's edit function. Maybe an isNew flag stating that a block has just been inserted without any change. cc @aduth

@jasmussen
Copy link
Contributor Author

Right now in master, whenever I load the post content, the media library pops up because there's a gallery placeholder.

Seeing as the "get the media library on insert" is very much an insert related action, would it make sense to attach an extra action to the inserter? Or does that not make sense?

@westonruter
Copy link
Member

I can reproduce this in the demo content. I access the demo page and immediately the media library opens even though I didn't click anything.

@aduth
Copy link
Member

aduth commented Jul 7, 2017

This should be fixed by #1784 ? @westonruter can you check whether you have latest master pulled?

@westonruter
Copy link
Member

Indeed. The demo is fixed on master now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Blocks Overall functionality of blocks [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

No branches or pull requests

4 participants