-
Notifications
You must be signed in to change notification settings - Fork 83
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
Dialog no longer resizes automatically after dragging. #436
Comments
The issue appears to be caused by setting web-components/packages/dialog/src/vaadin-dialog-draggable-mixin.js Lines 95 to 97 in 8569a89
Note: the same logic is also executed when resizing starts: web-components/packages/dialog/src/vaadin-dialog-resizable-mixin.js Lines 179 to 181 in 8569a89
|
As a workaround, it's possible to use this to ensure the above code never runs: dialog.$.overlay.$.overlay.style.position = 'absolute'; However, if header or footer is provided, dragging either of them will also resize dialog in this case 🙈 |
Not locking in the width when starting dragging can have some interesting side effects if the dialog has a max width: Bildschirmaufnahme.2022-10-14.um.18.55.53.mp4That seems to be because the max-width is applied on the parent element of the element that is actually being dragged, which also adds a margin that the dragged element tries to respect. |
Would it be possible to fix the size only for the duration of the drag? |
For extra details please check vaadin/flow-components#4083 as well |
First of all, I'm using the Java API in case that makes a difference.
I have a dialog with a details area that I can show and hide (using setVisible of Component/Element). Usually the dialog resizes (and recenters) accordingly on its own. But after dragging the dialog the size seems to be fixed and a scrollbar appears instead of increasing the dialog's size.
The text was updated successfully, but these errors were encountered: