<commit_before>var hljs = window.hljs;
var demoCode = $('#demo-code');
var toggleBox = $('#toggle-box');

var frameSet = $('#frameset');

frameSet.on('load', function () {
    setShowCode($(this).get(0));
});

toggleBox.on('click', 'button', function () {
    var el = $(this);
    toggleBox.find('.active').removeClass('active');
    el.addClass('active');
    frameSet.attr('src', el.data('target'));
});

function setShowCode(iframe) {
    demoCode.text(iframe.contentDocument.getElementById('show-code').innerHTML);
    hljs.highlightBlock(demoCode.get(0));
}

$(document).ready(function () {
    $('.hamburger-menu').click(function (e) {
        document.body.className = -1 !== document.body.className.indexOf("open-menu") ? "closed-menu" : "open-menu";
    });

    var str = '';
    $("#functions h4").each(function (index, element) {
        str += '<li><a class="item" href="#' + element.id + '">' + element.innerText + '</a></li>'
    });
    $("#function-tree").html(str);

    str = '';
    $(".options-content h4").each(function (index, element) {
        str += '<li><a class="item" href="#' + element.id + '">' + element.innerText + '</a></li>'
    });
    $("#options-param-tree").html(str);

    str = '';
    $("#method-static h4").each(function (index, element) {
        str += '<li><a class="item" href="#' + element.id + '">' + element.innerText + '</a></li>'
    });
    $("#method-static-tree").html(str);

    str = '';
    $("#method-example h4").each(function (index, element) {
        str += '<li><a class="item" href="#' + element.id + '">' + element.innerText + '</a></li>'
    });
    $("#method-example-tree").html(str);

    $(".tree").each(function (index, element) {
        if ($(this).next(".node").length > 0) {
            $(this).addClass("ceng_close");
        }
    });

    $('.item').click(function (e) {
        document.body.className = -1 !== document.body.className.indexOf("open-menu") ? "closed-menu" : "open-menu";
    });

    $(".tree").click(function (e) {
        var ul = $(this).next(".node");
        if (ul.css("display") == "none") {
            ul.slideDown();
            $(this).addClass("ceng_open");
            ul.find(".ceng_close").removeClass("ceng_open");
        }
        else {
            ul.slideUp();
            $(this).removeClass("ceng_open");
            ul.find(".node").slideUp();
            ul.find(".ceng_close").removeClass("ceng_open");
        }
    });
});<commit_msg>header index<commit_after>var hljs = window.hljs;
var demoCode = $('#demo-code');
var toggleBox = $('#toggle-box');

var frameSet = $('#frameset');

frameSet.on('load', function () {
    setShowCode($(this).get(0));
});

toggleBox.on('click', 'button', function () {
    var el = $(this);
    toggleBox.find('.active').removeClass('active');
    el.addClass('active');
    frameSet.attr('src', el.data('target'));
});

function setShowCode(iframe) {
    demoCode.text(iframe.contentDocument.getElementById('show-code').innerHTML);
    hljs.highlightBlock(demoCode.get(0));
}

$(document).ready(function () {
    $('.hamburger-menu').click(function (e) {
        document.body.className = -1 !== document.body.className.indexOf("open-menu") ? "closed-menu" : "open-menu";
    });

    var str = '';
    $("#functions h4").each(function (index, element) {
        str += '<li><a class="item" href="#' + element.attr('id') + '">' + element.innerText + '</a></li>'
    });
    $("#function-tree").html(str);

    str = '';
    $(".options-content h4").each(function (index, element) {
        str += '<li><a class="item" href="#' + element.attr('id') + '">' + element.innerText + '</a></li>'
    });
    $("#options-param-tree").html(str);

    str = '';
    $("#method-static h4").each(function (index, element) {
        str += '<li><a class="item" href="#' + element.attr('id') + '">' + element.innerText + '</a></li>'
    });
    $("#method-static-tree").html(str);

    str = '';
    $("#method-example h4").each(function (index, element) {
        str += '<li><a class="item" href="#' + element.attr('id') + '">' + element.innerText + '</a></li>'
    });
    $("#method-example-tree").html(str);

    $(".tree").each(function (index, element) {
        if ($(this).next(".node").length > 0) {
            $(this).addClass("ceng_close");
        }
    });

    $('.item').click(function (e) {
        document.body.className = -1 !== document.body.className.indexOf("open-menu") ? "closed-menu" : "open-menu";
    });

    $(".tree").click(function (e) {
        var ul = $(this).next(".node");
        if (ul.css("display") == "none") {
            ul.slideDown();
            $(this).addClass("ceng_open");
            ul.find(".ceng_close").removeClass("ceng_open");
        }
        else {
            ul.slideUp();
            $(this).removeClass("ceng_open");
            ul.find(".node").slideUp();
            ul.find(".ceng_close").removeClass("ceng_open");
        }
    });
});
{'fraction_non_alphanumeric': 0.24611032531824611, 'fraction_numerical': 0.003637098403717923, 'mean_word_length': 2.8732394366197185, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 37, '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': '7623568', 'n_tokens_mistral': 1596, 'n_tokens_neox': 1585, 'n_words': 241}