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

Do not show the block settings menu if selected block is invalid #12209

Closed
wants to merge 2 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/editor/src/components/block-toolbar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ function BlockToolbar( { blockClientIds, isValid, mode } ) {
<BlockSwitcher clientIds={ blockClientIds } />
<BlockControls.Slot />
<BlockFormatControls.Slot />
<BlockSettingsMenu clientIds={ blockClientIds } />
</Fragment>
) }
<BlockSettingsMenu clientIds={ blockClientIds } />
Copy link
Member Author

Choose a reason for hiding this comment

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

I'm not sure why it wasn't considered before to hide this if the block is invalid, so I'd want some perspective on the potential implications of this.

Copy link
Member Author

@oandregal oandregal Nov 22, 2018

Choose a reason for hiding this comment

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

I've learned why this is a bad idea. This is what would happen:

peek 2018-11-22 11-19

</div>
);
}
Expand Down