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

Fix resize-handle visability for vertical layout (mobile) #15010

Conversation

light-and-ray
Copy link
Contributor

@light-and-ray light-and-ray commented Feb 23, 2024

Description

  • a simple description of what you're trying to accomplish
  • a summary of changes in code
  • which issues it fixes, if any

Screenshots/videos:

Before:
Screenshot 2024-02-23 at 18-40-52 Stable Diffusion
After:
Screenshot 2024-02-23 at 18-41-29 Stable Diffusion

Before:
Screenshot 2024-02-23 at 18-24-45 Stable Diffusion
After:
Screenshot 2024-02-23 at 18-25-34 Stable Diffusion

Checklist:

@AUTOMATIC1111
Copy link
Owner

Shouldn't that be inside the if block? And the handle should be referred to as R.handle instead of parent.querySelector('.resize-handle').

@light-and-ray
Copy link
Contributor Author

R.handle can be null if resize window and don't touch resize handle. And how you see it inside if block? We don't need to check grid template for that and also we need to have this if-else inside displayResizeHandle

@light-and-ray
Copy link
Contributor Author

The name displayResizeHandle looks like it shouldn't change anything, I agree. But it already changes style and opacity, maybe it should be renamed

And also maybe I should remove R.handle at all, and init new parent's field inside setup function

@AUTOMATIC1111
Copy link
Owner

Like this:

            if (R.handle != null) {
                R.handle.style.display = "none";
                R.handle.style.opacity = '0';
            }

@light-and-ray
Copy link
Contributor Author

As I thought, it doesn't work. Also R is global for every parent, it contains handle which is being resized right now

I updated PR, check it. I think it's better now

@AUTOMATIC1111 AUTOMATIC1111 merged commit ca0308b into AUTOMATIC1111:dev Feb 26, 2024
3 checks passed
@light-and-ray light-and-ray deleted the fix_resize-handle_for_vertical_layout branch February 26, 2024 09:53
AUTOMATIC1111 added a commit that referenced this pull request Mar 2, 2024
…rtical_layout

Fix resize-handle visability for vertical layout (mobile)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants