lib/carto/functions.js
function (val) {
        var color, mode;
        if (arguments.length > 1) color = arguments[1];
        if (arguments.length > 2) mode = arguments[2];

        return {
            is: 'tag',
            val: val,
            color: color,
            mode: mode,
            toString: function(env) {
                var attr = {};

                _.set(attr, 'value', val.ev(env).toString());
                if (color) {
                    _.set(attr, 'color', color.ev(env).toString());
                }
                if (mode) {
                    _.set(attr, 'mode', mode.ev(env).toString());
                }
                return {
                    '_name': 'stop',
                    '_attributes': attr
                };
            }
        };
    }
function (val) {
        var color, mode;
        if (arguments.length > 1) color = arguments[1];
        if (arguments.length > 2) mode = arguments[2];

        return {
            is: 'tag',
            val: val,
            color: color,
            mode: mode,
            toString: function(env) {
                var attr = {};

                _.set(attr, 'value', val.ev(env).toString());
                if (color) {
                    _.set(attr, 'color', color.ev(env).toString());
                }
                if (mode) {
                    _.set(attr, 'mode', mode.ev(env).toString());
                }
                return {
                    '_name': 'stop',
                    '_attributes': attr
                };
            }
        };
    }
function ( val ) { var color , mode ; if ( arguments . length > 1 ) color = arguments [ 1 ] ; if ( arguments . length > 2 ) mode = arguments [ 2 ] ; return { is : 'tag' , val : val , color : color , mode : mode , toString : function ( env ) { var attr = { } ; _ . set ( attr , 'value' , val . ev ( env ) . toString ( ) ) ; if ( color ) { _ . set ( attr , 'color' , color . ev ( env ) . toString ( ) ) ; } if ( mode ) { _ . set ( attr , 'mode' , mode . ev ( env ) . toString ( ) ) ; } return { '_name' : 'stop' , '_attributes' : attr } ; } } ; }
Only require val
Only require val