lib/cracked/cracked.js
//prepends macro name to incoming selectors
prepends macro name to incoming selectors
prepends macro name to incoming selectors
function processSelectorForMacro(selector) {
    var selectorArr = selector.split(","),
        prefix = getCurrentMacroNamespace();
    for (var i = 0; i < selectorArr.length; i++) {
        selectorArr[i] = (selectorArr[i].indexOf(prefix) !== -1) ?
            selectorArr[i] : prefix + selectorArr[i];
    }
    return selectorArr.join(",");
}
function processSelectorForMacro ( selector ) { var selectorArr = selector . split ( "," ) , prefix = getCurrentMacroNamespace ( ) ; for ( var i = 0 ; i < selectorArr . length ; i ++ ) { selectorArr [ i ] = ( selectorArr [ i ] . indexOf ( prefix ) !== - 1 ) ? selectorArr [ i ] : prefix + selectorArr [ i ] ; } return selectorArr . join ( "," ) ; }
prepends macro name to incoming selectors
prepends macro name to incoming selectors
//look for the macro namespace in the incoming selector //if its there, do nothing, else add it. //insert the prefix //use a loop to handle comma delimited selectors //re-join the now prefixed selectors and return