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

WIP: Show sibling inserter on hover #24372

Closed
wants to merge 6 commits into from

Conversation

kirilzh
Copy link
Contributor

@kirilzh kirilzh commented Aug 5, 2020

Description

Addresses: #22867

What I'm trying to do is detect over which block-id the mouse is hovering, find its index and then show two sibling inserters on the bottom and top respectively. I'm stuck however on handling blocks that have nested blocks in them. In such cases the event.target is the innermost element and I haven't found an elegant solution to the problem. :(

Screen-Recording-2020-07-31-at-1

How has this been tested?

Screenshots

Types of changes

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.
  • My code has proper inline documentation.
  • I've included developer documentation if appropriate.
  • I've updated all React Native files affected by any refactorings/renamings in this PR.

@youknowriad youknowriad added the Needs Design Feedback Needs general design feedback. label Aug 5, 2020
@youknowriad
Copy link
Contributor

I think we've been slowly removing things from "hover" because of the distraction it can create when writing and moving the mouse. This PR seems to go a bit in the other direction, I want to make sure this is intended.

@kirilzh kirilzh requested review from ellatrix and removed request for shaunandrews and MichaelArestad August 5, 2020 14:44
@ZebulanStanphill ZebulanStanphill added the Needs Accessibility Feedback Need input from accessibility label Aug 5, 2020
@jasmussen
Copy link
Contributor

Hello, thank you for the PR!

I would agree with Riad above, that we've been going back and forth on this one. The reason being the tension between the block editor being a place to create layouts, and the block editor being a place to write. When the sibling inserter appears immediately on hover as shown in this PR, it is incredibly easy to get to. But it also gets in the way of just writing when that's what you want.

I understand the high level goal of #22867, and believe there is a great deal of improvement to be made to how the sibling inserter appears (we need to find the balance between it being there when you need it and not when you don't), but I do worry this goes too far in the other direction making it overwhelming.

Is there a way the balanced can be pulled back again, and the delay being reintroduced if tuned?

@MichaelArestad
Copy link
Contributor

Is there a way the balanced can be pulled back again, and the delay being reintroduced if tuned?

I would second this. Adding a slight delay will make it less distracting.

@paaljoachim
Copy link
Contributor

I also think we should have the blue line have a smaller width. Perhaps it should also be a little thinner.

@paaljoachim
Copy link
Contributor

@kirilzh Kiril told me that he is not working on Gutenberg any longer. This also means that someone else will need to either take over this PR, or that we need to close it.

Base automatically changed from master to trunk March 1, 2021 15:43
@youknowriad
Copy link
Contributor

Closing this PR as there has been a lot iterations on this over time. Thanks all for your efforts.

@kirilzh kirilzh deleted the add/sibling-hover branch April 26, 2024 07:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Accessibility Feedback Need input from accessibility
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants