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

Media Replace Flow: Don't show the URL option unless there is a handler #19063

Merged
merged 1 commit into from Dec 18, 2019

Conversation

scruffian
Copy link
Contributor

Description

In the site logo block we want to use the MediaReplaceFlow component, but we don't want to offer the URL option. This change ensures that the "Insert From URL" option only shows when a onSelectURL handler is passed. This is what we do in MediaPlaceholder

How has this been tested?

  • Use the site logo branch ( Full Site Editing: Add a Site Logo block #18811)
  • Then apply this change on top
  • Check that the site logo block doesn't have an "Insert From URL" option
  • Check that the image block still has a "Insert From URL" option

Screenshots

Types of changes

Bug fix (non-breaking change which fixes an issue)

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.

@draganescu draganescu merged commit 993bfe0 into WordPress:master Dec 18, 2019
@youknowriad youknowriad added this to the Gutenberg 7.2 milestone Jan 6, 2020
@scruffian scruffian deleted the update/media-replace-flow branch January 16, 2020 15:00
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.

None yet

3 participants