#16394 closed defect (fixed)
height: 100% broken for children of StackContainer
Reported by: | ben hockey | Owned by: | bill |
---|---|---|---|
Priority: | undecided | Milestone: | 1.9 |
Component: | Dijit | Version: | 1.8.1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
r29904 introduces an extra div around children of StackContainer?. this breaks previous layouts where the child had styling of height: 100%;
. i've attached a test case where this happens.
Attachments (2)
Change History (18)
Changed 8 years ago by
Attachment: | 16394.html added |
---|
comment:1 Changed 8 years ago by
comment:2 Changed 8 years ago by
aargh! height: 100%;
doesn't work unless it's only applied to the wrapper of the currently selected child because otherwise the "hidden" wrappers still have height: 100%
.
comment:3 Changed 8 years ago by
using _hideChild
and _showChild
we can apply and remove height: 100%;
to page._wrapper
- this seems to be working for me.
comment:4 Changed 8 years ago by
Owner: | changed from bill to ben hockey |
---|---|
Status: | new → pending |
I see... yes it requires users to change their custom CSS, but what do you suggest?
comment:5 Changed 8 years ago by
PS: why are you setting height: 100% on a StackContainer child. Isn't it StackContainer's job to set the height on its children?
Changed 8 years ago by
Attachment: | 16394.diff added |
---|
comment:6 Changed 8 years ago by
Status: | pending → new |
---|
Attachment (16394.diff) added by ticket reporter.
comment:7 Changed 8 years ago by
Replying to bill:
PS: why are you setting height: 100% on a StackContainer child. Isn't it StackContainer's job to set the height on its children?
i find that CSS does (or did) a pretty good job setting the height ;)
StackContainer? won't set the height if the child does not have a resize
method and the CSS did everything i needed - with less code.
anyhow, what i'm suggesting is in the patch i've attached.
comment:8 Changed 8 years ago by
Owner: | changed from ben hockey to bill |
---|---|
Status: | new → assigned |
comment:9 Changed 8 years ago by
OK. Perhaps StackContainer should be showing/hiding the wrapper node, instead of the child widget. In that case you could keep your old CSS.
comment:10 Changed 8 years ago by
i had thought of it showing and hiding the wrapper but that still won't do it (unless you also somehow set the height of the wrapper to 100%) because the wrapper needs to expand to the height of the container so that the domNode of the child widget can expand to the same height.
comment:11 Changed 8 years ago by
Well, you could set the height of the wrapper to 100% yourself, in CSS, similar to what you've been doing all along. My point was that the wrapper's height doesn't need to be changed dynamically; it can stay at 100% whether or not the pane is selected.
comment:15 Changed 8 years ago by
Milestone: | tbd → 1.9 |
---|
applying
height: 100%;
to that wrapper node fixes this problem. i wonder if that is the correct solution for this.