#452 ✓resolved
Mathieu Simard

addClass on Selectable adds class only to the ul

Reported by Mathieu Simard | January 21st, 2011 @ 11:23 PM

I try to position the selectable but the class is only added to the child ul and not the parent div.
Therefore, it is not possible to position it properly.

Comments and changes to this ticket

  • MadRabbit

    MadRabbit January 23rd, 2011 @ 06:35 PM

    Hi Mathieu,

    When you deal with a single-option selectables and want to alter the whole thing, it will be simpler if you refer to the object.container property. I could re-tunnel all the dom methods to that property, but it might get confusing and ambiguous, because selectables handle both multiple and single-option cases and it makes sense when the actual object represents the list of options.

    Try it like that

    var selectable = new Selectable({mutliple:false});
    
    selectable.container.addClass('trololo');
    

    Btw, do you know that all UI widgets have their own classes? You could alter them directly in your css without adding any new ones.

  • Mathieu Simard

    Mathieu Simard January 24th, 2011 @ 05:33 PM

    I know I can modify the rui-selectable-container class.
    But my actual goal is to position two different selectables using two distinct css classes.
    At the moment I had just wrapped them in a div to which I added the positioning class.

    I'll add it to the container now that I know.

  • MadRabbit

    MadRabbit January 24th, 2011 @ 05:55 PM

    • State changed from “new” to “resolved”

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

RightJS Core Tickets

Shared Ticket Bins

People watching this ticket

Pages