Details
-
Type:
Improvement
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 2.1-Beta
-
Component/s: ACE-Components
-
Labels:None
-
Environment:Tomcat 7.0.12
-
Assignee Priority:P2
Description
Currently the ace:dialog component has a default width of 300 px. Ideally, the dialog should size the height/width based on the dialog content.
This may not be simple or even possible. The width is a number because it is used in all kinds of calculations and situations in the plugin: resizing, positioning, effects, dragging, comparing with minWidth, etc. Allowing "auto" and other units (e.g. in, em, %) may affect a lot of things.
Also, a width of "auto" or other units may not do what you expect across browsers and layouts, especially for an absolute-positioned element that can move around. E.g. in a CSS reference book there's almost half a page explaining the intricacies of "auto". And % is a % of "containing block," (not always the parent) which is again highly inconsistent across browsers and layouts.
Add to this that a jQuery dialog can potentially be detached and re-attached to anywhere else in the DOM tree, making "auto" and other units even more unpredictable.
And, if allowing "auto" and other units were not that complicated, the original author would have done it already.