How? - Nested divs where outer box resizes per the inner box

This forum is for all Flare issues related to styles, stylesheets and XML.
Post Reply
keuler
Propeller Head
Posts: 63
Joined: Sun Sep 20, 2009 2:54 pm

How? - Nested divs where outer box resizes per the inner box

Post by keuler »

All-

I'm attempting to implement a simple nested div setup such that when the inner box grows in height, the containing box does too.

I'm experimenting with a set of divs to format notes, where:

1) The outer box contains a note icon on the top left, and
2) The inner box butts up against the right wall of the outer box (clearing the icon).

I'm trying to make the bottom of the outer box move down/up as text is added/removed from the inner box. However, tests show than the inner box will simply expand below the outer box's lower border as text is added (to the inner box).

(Note that I'm familiar with the technique per Mike Hamilton's Webinar in which you have a single div for formatting notes, then simply put the icon in the left margin. However, I'm interested in using the nested method (if it works) so I can using existing paragraph formats (which have almost no left margin) that I use in table cells. )

I'm a total newbie, so perhaps there's a Flare feature than handles this elegantly, if regular CSS won't.

Thanks much!
Lydia
Sr. Propeller Head
Posts: 373
Joined: Tue Apr 23, 2013 3:19 am
Location: The Netherlands, Amsterdam Area

Re: How? - Nested divs where outer box resizes per the inner

Post by Lydia »

Hi, can you check out this post/thread?
viewtopic.php?f=6&t=20644&p=106917#p106966
I explained there how I use outer/inner divs to style my notes. The p tag is used in there, see the example. You can use your own p classes then.
BTW - I don't get why your outer div would not resize with the inner div. Unless you fixed the height somewhere. If that is the case, remove the height setting. If you want the div to have a minimum height, you can set that, but do not limit the actual height.

Hope this helps, Lydia.
Using Flare 10.2 and Flare 11 on Win 7
keuler
Propeller Head
Posts: 63
Joined: Sun Sep 20, 2009 2:54 pm

Re: How? - Nested divs where outer box resizes per the inner

Post by keuler »

Thx Lydia. I'll check out your link soon.
Post Reply