<commit_before><!DOCTYPE html>
<html><head>
    <meta http-equiv="Content-type" content="text/html; charset=utf-8">
    <title>Arcadia tests</title>
    
    <script src="http://js.othermedia.com/helium.js" type="text/javascript"></script>
    
    <script type="text/javascript">
        Helium.use('yui', '2.7.0');
        Helium.use('ojay', 'master');
    </script>
    
    <script src="./packages.js" type="text/javascript"></script>
    
    <style type="text/css" media="screen">
        html, body {margin:0; border:none; padding:0; overflow:hidden; font-family:Helvetica, Arial, sans-serif; font-size:12px;}
        #gallery {height:500px; overflow:hidden;}
        .item {float:left;}
        .description-wrapper {display:none; background:#000; color:#fff;}
        .description-toggle {padding:10px; text-align:right; cursor:pointer;}
        .description {padding:0 10px 20px 10px;}
        .current .description-wrapper {display:block;}
        .clear:after {}
        .thumbnail {float:left;}
        .arcadia-play-button, .arcadia-next-previous span {position:absolute; padding:10px; border:1px solid #fff; background:#000; color:#fff; cursor:pointer; font-family:'Times New Roman', Times, serif; font-size:18px; font-style:italic;}
        .arcadia-play-button {position:absolute; bottom:50px; left:50px;}
        .arcadia-next-previous span {top:240px;}
    </style>
</head><body>
    
    <div id="gallery"></div>
    
    <script type="text/javascript">
    require('Ojay.HTTP', 'Arcadia', function() {
        
        Ojay.HTTP.GET('images.json', {}, {
            onSuccess: function(response) {
                Arcadia.Controls.Next.define('reposition', function() {
                    var next    = this.getNext(),
                        prev    = this.getPrevious(),
                        gallery = this.getGallery(),
                        offset  = gallery.getCentre().getWidth(),
                        centre  = (gallery.getHTML().getWidth() + offset) / 2;
                    
                    prev.setStyle({right: Math.ceil(centre) + 'px'});
                    next.setStyle({left: Math.floor(centre) + 'px'});
                });
                
                var json    = response.parseJSON(),
                    gallery = new Arcadia('#gallery', json),
                    
                    thumbs  = gallery.addControls(Arcadia.Controls.Thubmnails),
                    thtml   = thumbs.getHTML(),
                    
                    play    = gallery.addControls(Arcadia.Controls.Play),
                    phtml   = play.getHTML(),
                    
                    next    = gallery.addControls(Arcadia.Controls.Next),
                    nhtml   = next.getHTML();
                
                gallery.getHTML().insert(thtml, 'after');
                thtml.setStyle({height: '200px'});
                
                gallery.getHTML().insert(phtml, 'bottom');
                
                gallery.getHTML().insert(nhtml, 'bottom');
                next.reposition();
                Ojay(window).on('resize', next.reposition, next);
            }
        });
    });
    </script>
    
</body></html><commit_msg>Make the test thumbnails scrollable.<commit_after><!DOCTYPE html>
<html><head>
    <meta http-equiv="Content-type" content="text/html; charset=utf-8">
    <title>Arcadia tests</title>
    
    <script src="http://js.othermedia.com/helium.js" type="text/javascript"></script>
    
    <script type="text/javascript">
        Helium.use('yui', '2.7.0');
        Helium.use('ojay', 'master');
    </script>
    
    <script src="./packages.js" type="text/javascript"></script>
    
    <style type="text/css" media="screen">
        html, body {margin:0; border:none; padding:0; overflow:hidden; font-family:Helvetica, Arial, sans-serif; font-size:12px;}
        #gallery {height:500px; overflow:hidden;}
        .item {float:left;}
        .description-wrapper {display:none; background:#000; color:#fff;}
        .description-toggle {padding:10px; text-align:right; cursor:pointer;}
        .description {padding:0 10px 20px 10px;}
        .current .description-wrapper {display:block;}
        .clear:after {}
        .thumbnail {float:left;}
        .arcadia-play-button, .arcadia-next-previous span {position:absolute; padding:10px; border:1px solid #fff; background:#000; color:#fff; cursor:pointer; font-family:'Times New Roman', Times, serif; font-size:18px; font-style:italic;}
        .arcadia-play-button {position:absolute; bottom:50px; left:50px;}
        .arcadia-next-previous span {top:240px;}
        #thumbnails {height:215px; overflow-x:scroll; overflow-y:hidden;}
    </style>
</head><body>
    
    <div id="gallery"></div>
    
    <div id="thumbnails"></div>
    
    <script type="text/javascript">
    require('Ojay', 'Ojay.HTTP', 'Arcadia', function() {
        
        Ojay.HTTP.GET('images.json', {}, {
            onSuccess: function(response) {
                Arcadia.Controls.Next.define('reposition', function() {
                    var next    = this.getNext(),
                        prev    = this.getPrevious(),
                        gallery = this.getGallery(),
                        offset  = gallery.getCentre().getWidth(),
                        centre  = (gallery.getHTML().getWidth() + offset) / 2;
                    
                    prev.setStyle({right: Math.ceil(centre) + 'px'});
                    next.setStyle({left: Math.floor(centre) + 'px'});
                });
                
                var json    = response.parseJSON(),
                    gallery = new Arcadia('#gallery', json),
                    
                    thumbs  = gallery.addControls(Arcadia.Controls.Thubmnails),
                    thtml   = thumbs.getHTML(),
                    
                    play    = gallery.addControls(Arcadia.Controls.Play),
                    phtml   = play.getHTML(),
                    
                    next    = gallery.addControls(Arcadia.Controls.Next),
                    nhtml   = next.getHTML();
                
                Ojay('#thumbnails').insert(thtml);
                var twidth = thtml.children('.thumbnail').reduce(function(w, t) { return w + t.getWidth(); }, 0);
                thtml.setStyle({height: '200px', width: twidth + 'px'});
                
                gallery.getHTML().insert(phtml, 'bottom');
                
                gallery.getHTML().insert(nhtml, 'bottom');
                next.reposition();
                Ojay(window).on('resize', next.reposition, next);
            }
        });
    });
    </script>
    
</body></html>
{'fraction_non_alphanumeric': 0.149466726753793, 'fraction_numerical': 0.013219167793300285, 'mean_word_length': 1.827176220806794, 'pattern_counts': {'":': 0, '<': 49, '<?xml version=': 0, '>': 49, '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': '714934', 'n_tokens_mistral': 2000, 'n_tokens_neox': 1861, 'n_words': 320}