How do I assign custom classes to YUI3 plugin/widget objects

Posted by Akshar Prabhu Desai on Stack Overflow See other posts from Stack Overflow or by Akshar Prabhu Desai
Published on 2011-04-01T05:47:28Z Indexed on 2011/06/25 0:22 UTC
Read the original article Hit count: 289

Filed under:
|
|

Consider the following code.

var overlay = new Y.Overlay({
                    id:'tooltip-tag',
                    bodyContent:"Loading.....",
                    xy:[e.target.getX(),e.target.getY()+30]
                });

The overlay gets the id as given in attributes. But what if I want to add a class ?

IS there something like:

var overlay = new Y.Overlay({
                    **class:'tooltip-tag'**,
                    bodyContent:"Loading.....",
                    xy:[e.target.getX(),e.target.getY()+30]
                });

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about css