-
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
Scale the zoom out mode to fit available space #59342
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. |
Size Change: +88 B (0%) Total Size: 1.71 MB
ℹ️ View Unchanged
|
3b549fa
to
ebe6adc
Compare
54743ad
to
c77ed37
Compare
@@ -0,0 +1,20 @@ | |||
const clamp = ( lowerlimit, x, upperlimit ) => { |
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.
What is x?
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 looks great, lets bring it in
When there's a small area available to scale the editor, we want to have the editor larger. This implements a smooth sloped clamped scale to scale the zoomed out editor to better fit its available space. We moved the scale calculation inside of the iframe components so when this is used within the edit post and other packages, they won't need to implement their own scaling.
355276f
to
02e2f90
Compare
When there's a small area available to scale the editor, we want to have the editor larger. This implements a smooth sloped clamped scale to scale the zoomed out editor to better fit its available space.
We moved the scale calculation inside of the iframe components so when this is used within the edit post and other packages, they won't need to implement their own scaling.
part of #59336
What?
Why?
How?
Testing Instructions
Testing Instructions for Keyboard
Screenshots or screencast