<commit_before>define(['today/views/CardView', 'hbs!today/templates/park_and_rides'], function(CardView, prTemplate) {
    var RiversCard = CardView.extend({
        weight: 70,
        manage: true,
        id: 'pr_status',
        attributes: {'class': 'today'},
        serialize: function() {
            return this.model.toJSON();
        },
        template: prTemplate,
        afterRender: function() {
            var services = this.model.get('park_and_rides');
            for(var pr in services) {
                var park = services[pr];
                if (park.unavailable) {
                    new JustGage({
                        id: "pr-" + park.identifier,
                        value: 0,
                        min: 0,
                        max: 100,
                        title: park.name.split("Park")[0].trim(),
                        label: "NO INFORMATION",
                        hideValue: true,
                        hideMinMax: true,
                        counter: false
                    });
                } else {
                    new JustGage({
                        id: "pr-" + park.identifier,
                        value: park.percentage,
                        min: 0,
                        max: 100,
                        title: park.name.split("Park")[0].trim(),
                        label: park.spaces + " available",
                        hideValue: true,
                        hideMinMax: true,
                        counter: false,
                        levelColors: ["#a9d70b", "#f9c802", "#ff0000"]
                    });
                }
            }
        }
    });
    return RiversCard;
});<commit_msg>Park and Rides card: attempt to make colors more explicit for availability (TRELLO#273)<commit_after>define(['today/views/CardView', 'hbs!today/templates/park_and_rides'], function(CardView, prTemplate) {
    var RiversCard = CardView.extend({
        weight: 70,
        manage: true,
        id: 'pr_status',
        attributes: {'class': 'today'},
        serialize: function() {
            return this.model.toJSON();
        },
        template: prTemplate,
        afterRender: function() {
            var services = this.model.get('park_and_rides');
            for(var pr in services) {
                var park = services[pr];
                if (park.unavailable) {
                    new JustGage({
                        id: "pr-" + park.identifier,
                        value: 0,
                        min: 0,
                        max: 100,
                        title: park.name.split("Park")[0].trim(),
                        label: "NO INFORMATION",
                        hideValue: true,
                        hideMinMax: true,
                        counter: false
                    });
                } else {
                    new JustGage({
                        id: "pr-" + park.identifier,
                        value: park.percentage,
                        min: 0,
                        max: 100,
                        title: park.name.split("Park")[0].trim(),
                        label: park.spaces + " available",
                        hideValue: true,
                        hideMinMax: true,
                        counter: false,
                        levelColors: ["#a9d70b", "#a9d70b", "#a9d70b", "#a9d70b", "#a9d70b", "#f9c802", "#ff0000"]
                    });
                }
            }
        }
    });
    return RiversCard;
});
{'fraction_non_alphanumeric': 0.11262798634812286, 'fraction_numerical': 0.017918088737201365, 'mean_word_length': 1.0201033888569788, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '955135', 'n_tokens_mistral': 942, 'n_tokens_neox': 832, 'n_words': 190}