src/console/simpleyui.js
function(node, att, style) {
        style = style || node.style;
        var CUSTOM_STYLES = Y_DOM.CUSTOM_STYLES,
            val = '';

        if (style) {
            if (att in CUSTOM_STYLES) {
                if (CUSTOM_STYLES[att].get) {
                    return CUSTOM_STYLES[att].get(node, att, style); // NOTE: return
                } else if (typeof CUSTOM_STYLES[att] === 'string') {
                    att = CUSTOM_STYLES[att];
                }
            }
            val = style[att];
            if (val === '') { // TODO: is empty string sufficient?
                val = Y_DOM[GET_COMPUTED_STYLE](node, att);
            }
        }

        return val;
    }
function(node, att, style) {
        style = style || node.style;
        var CUSTOM_STYLES = Y_DOM.CUSTOM_STYLES,
            val = '';

        if (style) {
            if (att in CUSTOM_STYLES) {
                if (CUSTOM_STYLES[att].get) {
                    return CUSTOM_STYLES[att].get(node, att, style); // NOTE: return
                } else if (typeof CUSTOM_STYLES[att] === 'string') {
                    att = CUSTOM_STYLES[att];
                }
            }
            val = style[att];
            if (val === '') { // TODO: is empty string sufficient?
                val = Y_DOM[GET_COMPUTED_STYLE](node, att);
            }
        }

        return val;
    }
function ( node , att , style ) { style = style || node . style ; var CUSTOM_STYLES = Y_DOM . CUSTOM_STYLES , val = '' ; if ( style ) { if ( att in CUSTOM_STYLES ) { if ( CUSTOM_STYLES [ att ] . get ) { return CUSTOM_STYLES [ att ] . get ( node , att , style ) ; // NOTE: return } else if ( typeof CUSTOM_STYLES [ att ] === 'string' ) { att = CUSTOM_STYLES [ att ] ; } } val = style [ att ] ; if ( val === '' ) { // TODO: is empty string sufficient? val = Y_DOM [ GET_COMPUTED_STYLE ] ( node , att ) ; } } return val ; }
Returns the current style value for the given property.
@method getStyle
@param {HTMLElement} An HTMLElement to get the style from.
@param {String} att The style property to get.
Returns the current style value for the given property .