I believe the output of a Repeatable is wrapped in div tag. I use the following code to generate a div tag.

   - type: Repeatable
     nested_name: appointments
     counter_name: appointment_count
     attributes:
       class: ShawnTest
       id: appointment_count
     elements:

This outputs:
<div class="ShawnTest" id="appointment_count">

This is wrapped around all of the elements in the Repeatable block.

Thanks for the tip about the first-child. I tested it, but couldn't get it to work. I will have to read up on it.

Carl Franks wrote:
2009/3/26 Ascii King <t...@swattermatter.com>:
I apologize for asking this twice, but I have not yet solved it.
Is it possible to specify a different characteristic for the first record in
a repeatable? I would like the class in the first repeatable block to be
different from the rest of the class tags. Something like a
first_record_attributes option or the header in a table.

There's nothing that would currently achieve this.

Can you use the "first-child" CSS pseudo-selector?
It's supported in IE7+ and every other browser.

Currently, the output of a Repeatable isn't wrapped in a containing
div, but I don't think it would break anything to change that.
Then you could do:

    .repeatable div:first-child { }

Any help?

I'd be a little worried that if a first_rep_attributes() were added,
there'd soon be calls for:
    last_rep_attributes(),
    odd_rep_attributes(),
    even_rep_attributes()...
And where would it stop? ;)

Carl

_______________________________________________
HTML-FormFu mailing list
HTML-FormFu@lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/html-formfu


_______________________________________________
HTML-FormFu mailing list
HTML-FormFu@lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/html-formfu

Reply via email to