!! ~CollapseBox

~CollapseBox is an extension of [Collapsable Lists|BrushedTemplateCollapse]
and included in the [BrushedTemplate].\\
It provides collapsable boxes : when closed only the title of the box is visible; 
when opened the complete box becomes visible. A open/close icon will be shown
at the right edge of the box, indicating the status of the box.

This is very convenient for info in pages like 
LeftMenu, LeftMenuFooter, your <username>Favorites, and so on.

--[DF|DirkFrederickx], Nov 05, Jul 06

! Usage

{{{
  %%collapsebox
  ! Title of the box
  Here is the body of the box
  * item 1
  * item 2
  %%
}}}

Reality check:

%%collapsebox
! Title of the box
Here is the body of the box
* item 1
* item 2
%%

When you can append ''-closed'', the box will be rendered closed by default (Jul 06)
{{{
  %%collapsebox-closed
  ! Title of the box
  I should be closed buy default
  %%
}}}

Reality check: (nok on jspwiki.org)
%%collapsebox-closed
! Title of the box
I should be closed buy default
%%

! Implementation

See [BrushedTemplateCollapse]

After the js has processed the html, following structure is rendered, which should give
you enough freedom for css hacking.
When you click the ''collapseOpen'' button, the css-style changes to ''collapseClose''.
{{{
  <div class="collapsebox">
    <h3>Some title<div class="collapseOpen">&laquo;</div></h3>
    <div class="collapsebody">
      ... rest of the box
    </div>
  </div>
}}}


Back to [BrushedTemplate]