You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've made a dialog draggable but I want to ensure it can't go off-screen aka outside the viewport. Based on the bounds description it sounded like I could say body (we force body it viewport height/width) but that makes the dialog stop moving entirely.
Edit: Pending an answer as to why the selector/parent bounds value does nothing, I've had to use the object value to control distances to the edge of the viewport.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I've made a dialog draggable but I want to ensure it can't go off-screen aka outside the viewport. Based on the
bounds
description it sounded like I could saybody
(we force body it viewport height/width) but that makes the dialog stop moving entirely.Is there a way to achieve this?
Edit: Pending an answer as to why the selector/parent
bounds
value does nothing, I've had to use the object value to control distances to the edge of the viewport.Beta Was this translation helpful? Give feedback.
All reactions