-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Notes: spotlight block when clicking add/view notes #72870
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
Conversation
| const unselectThread = () => { | ||
| setShowCommentBoard( false ); | ||
| blockElement?.focus(); | ||
| toggleBlockSpotlight( clientId, false ); | ||
| }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the process that occurs when adding a new note is canceled. The process for removing the spotlight state was missing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we also want to disable spotlight and call toggleBlockSpotlight onBlur event as well, since we're also closing the form on that event.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice catch! Fixed in eabafcd
5abd98c700cdf4218eae89bff3f9b995.mp4
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
|
Size Change: +18 B (0%) Total Size: 2.38 MB
ℹ️ View Unchanged
|
Mamaduka
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, @t-hamano!
* Notes: spotlight block when clicking add/view notes * Disable spotlight on blur Co-authored-by: t-hamano <[email protected]> Co-authored-by: Mamaduka <[email protected]> Co-authored-by: desrosj <[email protected]>
|
I just cherry-picked this PR to the wp/6.9 branch to get it included in the next release: 94e708d |
Closes #72861
What?
This PR spotlights (makes all blocks except the selected one semi-transparent) the block when the "View notes" or "Add notes" button is clicked.
Why?
To match the visual effect when a note is clicked directly. The block should be spotlighted when the note is opened and focused.
Testing Instructions
Add note
View note
Screenshots or screencast
d94a31c6591e1b7d2387ea7074b77f9f.mp4