<commit_before>YUI.add('grid-model', function (Y) {

    'use strict';

    var exported   = Y.Env._exported,
        rework     = Y.config.global.rework,
        pureGrids  = exported['rework-pure-grids'];

    Y.GridModel = Y.Base.create('grid-model', Y.Model, [], {

        initializer: function (cfg) {
            console.log(cfg);
            var mq = new Y.MqModelList({
                items: cfg.mediaQueries
            });
            this.set('mediaQueries', mq);
        },

        stringify: function () {

            var o = this.toJSON(),
                mq = this.get('mediaQueries');

            delete o.mediaQueries;
            delete o.id;

            Y.Object.each(o, function (val, key) {
                if (!val) {
                    delete o[key];
                }
            });

            mq.each(function (val) {
                o[val.get('id')] = val.get('mq');
            });
            return Y.QueryString.stringify(o);
        },

        generate: function () {
            var mediaQueries = this.get('mediaQueries'),
                css = '';
            css += rework('').use(pureGrids.units(this.get('cols'), {
                mediaQueries: mediaQueries.toObject(),
                selectorPrefix: this.get('prefix') || '.pure-u-'
            })).toString();

            return css;
        }

    }, {
        ATTRS: {
            cols: {
                setter: function (val) {
                    return parseInt(val, 10);
                },

                validator: function (val) {
                    //no value is fine
                    if (!val || (val <= app.start.limits.cols.max
                        && val >= app.start.limits.cols.min)) {
                        return true;<commit_msg>add indentation<commit_after>YUI.add('grid-model', function (Y) {

    'use strict';

    var exported   = Y.Env._exported,
        rework     = Y.config.global.rework,
        pureGrids  = exported['rework-pure-grids'];

    Y.GridModel = Y.Base.create('grid-model', Y.Model, [], {

        initializer: function (cfg) {
            console.log(cfg);
            var mq = new Y.MqModelList({
                items: cfg.mediaQueries
            });
            this.set('mediaQueries', mq);
        },

        stringify: function () {

            var o = this.toJSON(),
                mq = this.get('mediaQueries');

            delete o.mediaQueries;
            delete o.id;

            Y.Object.each(o, function (val, key) {
                if (!val) {
                    delete o[key];
                }
            });

            mq.each(function (val) {
                o[val.get('id')] = val.get('mq');
            });
            return Y.QueryString.stringify(o);
        },

        generate: function () {
            var mediaQueries = this.get('mediaQueries'),
                css = '';
            css += rework('').use(pureGrids.units(this.get('cols'), {
                mediaQueries: mediaQueries.toObject(),
                selectorPrefix: this.get('prefix') || '.pure-u-'
            })).toString({indent: '    '});;

            return css;
        }

    }, {
        ATTRS: {
            cols: {
                setter: function (val) {
                    return parseInt(val, 10);
                },

                validator: function (val) {
                    //no value is fine
                    if (!val || (val <= app.start.limits.cols.max
                        && val >= app.start.limits.cols.min)) {
                        return true;
{'fraction_non_alphanumeric': 0.14063823778593618, 'fraction_numerical': 0.0011296243998870376, 'mean_word_length': 1.206853582554517, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1982425', 'n_tokens_mistral': 1040, 'n_tokens_neox': 954, 'n_words': 182}