Ticket #5301 (closed feature: wontfix)
Dialog: Add a numeric string to dialog width option
| Reported by: | shadetyler | Owned by: | |
|---|---|---|---|
| Priority: | minor | Milestone: | 1.10.0 |
| Component: | ui.dialog | Version: | 1.7.2 |
| Keywords: | Cc: | ||
| Blocking: | Blocked by: |
Description
Please add a parseInt method to the numeric parameter of the width option in the dialog widget.
Change History
comment:2 follow-up: ↓ 3 Changed 18 months ago by M.Gaetan89
Adding parseInt() will break width: 'auto' (which actually work).
comment:3 in reply to: ↑ 2 Changed 18 months ago by scott.gonzalez
Replying to M.Gaetan89:
Adding parseInt() will break width: 'auto' (which actually work).
Width: "auto" is not supported. Even in the case of height, where "auto" is supported, it's very easy to not use parseInt() when the value is auto.
comment:5 Changed 7 months ago by petersendidit
- Status changed from new to open
- Summary changed from Add a numeric string to dialog width option to Dialog: Add a numeric string to dialog width option
comment:7 Changed 6 months ago by scott.gonzalez
I've always been against this, but somehow Richard convinced us at the redesign meeting that we should allow this. I'm still for closing as wontfix, for the same reasons as always. The API is clear, passing "5" instead of 5 should have undefined behavior. Also, saying that we support a string means extra documentation that need to clearly explain that we don't support any units, because people will certainly start doing: height: "300px" and at some point we'll get a bug report that height: "10em" fails.
I asked mikesherov if there were any APIs in core that accepts strings but forced pixel values, and I don't think he came up with any. We should double check, but if that's the case, then I think we should close this.

