Sha256: cde33e4fedde06aeca6e0ff028edaf4e8e08680b63af54de6540360d5cbabb2d

Contents?: true

Size: 1.22 KB

Versions: 30

Compression:

Stored size: 1.22 KB

Contents

<%#

Given a list of pairs, renders a [jQuery-UI accordion](jqueryui.com/demos/accordion).

### Example

    <accordion-list with="&[['header 1', 'body 1'], ['header 2', 'body 2']]"/>

### Attributes

All attributes supported by jQuery-UI accordion are passed through.

- sortable:  if true, drag and drop sorting is allowed, although changes are not persistent

 %>
<def tag="accordion-list" attrs="sortable">
  <% options, attrs = attributes.partition_hash(['disabled', 'active', 'animated', 'autoHeight', 'clearStyle', 'collapsible', 'event', 'fillSpace', 'header', 'icons', 'navigation'])
     events, html_attrs = attrs.partition_hash(['navigationFilter', 'create', 'change', 'changestart'])
     add_classes!(html_attrs, "accordion-list")
     add_data_rapid!(html_attrs, "accordion", :options => options, :events => events, :sortable => sortable)
     %>
  <div merge-attrs="&html_attrs">
    <repeat>
      <div class="hjq-accordion-element">
        <do:first>
          <h3 param="header-wrapper">
            <a param="header" href="#"><view/></a>
          </h3>
        </do:first>
        <do:last>
          <div param="default">
            <view param/>
          </div>
        </do:last>
      </div>
    </repeat>
  </div>
</def>

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
hobo_jquery_ui-2.0.0.pre6 taglibs/accordion-list.dryml
hobo_jquery_ui-2.0.0.pre5 taglibs/accordion-list.dryml
hobo_jquery_ui-2.0.0.pre4 taglibs/accordion-list.dryml
hobo_jquery_ui-2.0.0.pre3 taglibs/accordion-list.dryml
hobo_jquery_ui-2.0.0.pre2 taglibs/accordion-list.dryml
hobo_jquery_ui-2.0.0.pre1 taglibs/accordion-list.dryml
hobo_jquery_ui-1.4.0.pre8 taglibs/accordion-list.dryml
hobo_jquery_ui-1.4.0.pre7 taglibs/accordion-list.dryml
hobo_jquery_ui-1.4.0.pre6 taglibs/accordion-list.dryml
hobo_jquery_ui-1.4.0.pre5 taglibs/accordion-list.dryml