<commit_before>/**
 * options:
 *  - $: jQuery
 */

var
CardBuilder = function(options) {
var $ = options.$
    ;
    
    return {
        get: function(card) {
            var domCard,
                sign,
                inner,
                value,
                extraClass;
                
            //set value and extra class if needed
            switch (card.value) {
                case 'block':
                    value = 'ø';
                    extraClass = 'block';
                    break;
                case 'reverse':
                    value = '⟲';
                    extraClass = 'reverse';
                    break;
                case '+2':
                    value = '+2';
                    extraClass = 'plustwo';
                    break;                    
                case 'colorpick':
                    value = 'CP';
                    extraClass = 'colorpick';
                    break;
                case '+4':
                    value = '+4';
                    extraClass = 'plusfour';
                    break;
                default:
                    value = card.value;
                    break;
            }
                
            domCard = $('<div class="card card-'+card.color+'"/>');
            //domCard.addClass('card-'+card.color);
            if (extraClass) {
                domCard.addClass('card-'+extraClass);
            }
            
            sign = $('<span class="card-topleft-sign"/>');
            sign.text(value);
            
            inner = $('<div class="card-inner"/>');
            if (card.value != 'colorpick') {
                inner.text(value);
            }
            
            domCard.append(sign).append(inner);
            
            return domCard;
        },
        
        getBackside: function() {           
            return $('<div class="card card-backside"/>').append(
                $('<div class="card-inner"/>').text('UNO')
            );
        }
    };
};<commit_msg>CardBuilder provides information about card dimensions<commit_after>/**
 * options:
 *  - $: jQuery
 */

var
CardBuilder = function(options) {
var $ = options.$,
    cardWidth = 148;
    cardHeight = 208;
    ;
    
    return {
        get: function(card) {
            var domCard,
                sign,
                inner,
                value,
                extraClass;
                
            //set value and extra class if needed
            switch (card.value) {
                case 'block':
                    value = 'ø';
                    extraClass = 'block';
                    break;
                case 'reverse':
                    value = '⟲';
                    extraClass = 'reverse';
                    break;
                case '+2':
                    value = '+2';
                    extraClass = 'plustwo';
                    break;                    
                case 'colorpick':
                    value = 'CP';
                    extraClass = 'colorpick';
                    break;
                case '+4':
                    value = '+4';
                    extraClass = 'plusfour';
                    break;
                default:
                    value = card.value;
                    break;
            }
                
            domCard = $('<div class="card card-'+card.color+'"/>');
            //domCard.addClass('card-'+card.color);
            if (extraClass) {
                domCard.addClass('card-'+extraClass);
            }
            
            sign = $('<span class="card-topleft-sign"/>');
            sign.text(value);
            
            inner = $('<div class="card-inner"/>');
            if (card.value != 'colorpick') {
                inner.text(value);
            }
            
            domCard.append(sign).append(inner);
            
            return domCard;
        },
        
        getBackside: function() {           
            return $('<div class="card card-backside"/>').append(
                $('<div class="card-inner"/>').text('UNO')
            );
        },
        
        getCardWidth: function() {
            return cardWidth;
        },
        
        getCardHeight: function () {
            return cardHeight;
        }
    };
};
{'fraction_non_alphanumeric': 0.12086632510479739, 'fraction_numerical': 0.0032603632976245926, 'mean_word_length': 0.8633405639913232, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, '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': '6946199', 'n_tokens_mistral': 1070, 'n_tokens_neox': 995, 'n_words': 207}