-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Zoom Out: Disable zooming out when Distraction Free mode is activated #67028
base: trunk
Are you sure you want to change the base?
Zoom Out: Disable zooming out when Distraction Free mode is activated #67028
Conversation
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. |
…rs and update Toolbar to hide zoom out under distraction-free
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.
Thank you, @yogeshbhutkar!
Users can enable distraction-free mode through the Options dropdown, Commands and Keyboard shortcuts. The fix in the MoreMenu
component only covers one case.
I think it would be better to update the toggleDistractionFree
store action. I pushed similar fix in #66262, you can use it as example.
P.S. Let's also update the PR title/description to better reflect recent changes.
Thanks for the PR! Just like Distraction free mode, there is a shortcut for zoom out mode. When zoom out mode is enabled via the keyboard shortcut, it is better to disable Distraction free mode. |
…d reset distraction free mode on zoom out
Hi @Mamaduka, thanks for taking the time to suggest changes. I've refactored the action to reset the zoom when distraction-free mode is activated. This also enabled the changes to be seamlessly integrated with the keyboard shortcuts. |
Hi @t-hamano, thanks for taking the time to suggest changes. I've incorporated the change where when the user uses the keyboard shortcut to enable zoom out state and if distraction mode is enabled, then this action will, in turn, disable the distraction-free mode and enable the zoomed-out state. |
Fixes: #67025
What?
The Zoom Out and Distraction Free Mode features currently have conflicting behaviors. When Distraction Free Mode is enabled, users can still zoom out and add patterns, which undermines the purpose of Distraction Free Mode.
This pull request addresses the issue by resolving these conflicting behaviors to maintain the intended functionality of Distraction Free Mode.
The following are the fixes made in this PR:
Why?
The PR ensures Distraction Free Mode functions as intended by preventing disruptive actions like zooming out and adding patterns, preserving focus, and enhancing user experience.
How?
toggleDistractionFree()
function to include resetting the zoom level.Testing Instructions
Screenshots or screencast ( Updated )
zoom-out-new-720p.mov