<commit_before>/*
Entry point for the whole project. Any jQuery extensions should
be registered here.
*/

// Import npm module dependencies
import "./vendor.js";

import "./utils/array-extensions.js";

import { preferences } from "./utils/preference-manager.js";
import { VerifyRequirements } from "./utils/requirements.js";
import { AnnotatorVideoPlayer } from "./video-player/video-player.js";
import { VideoAnnotator } from "./annotator/annotator.js";

//console.log(css);

console.log($.fn);

//Start running when the window finishes loading
window.addEventListener('load', function(){
    VerifyRequirements();
});

$.fn.annotate = function(serverURL, tagsURL) {
    // Error out early if "this" is not a video
    if($(this).prop('tagName').toLowerCase() != "video"){
        console.error("Cannot wrap a non-video element!");
        return;
    }

    preferences.GetJSON((data) => {
        //console.log(data);
    });
    
    // Wrap self with custom video player
    let player = new AnnotatorVideoPlayer($(this));
    player.$container.on("OnVideoReady", ()=>{
        // Add annotator once video has loaded
        let annotator = new VideoAnnotator(player, serverURL, tagsURL);
    });

};<commit_msg>Disable preferences module<commit_after>/*
Entry point for the whole project. Any jQuery extensions should
be registered here.
*/

// Import npm module dependencies
import "./vendor.js";

import "./utils/array-extensions.js";

import { preferences } from "./utils/preference-manager.js";
import { VerifyRequirements } from "./utils/requirements.js";
import { AnnotatorVideoPlayer } from "./video-player/video-player.js";
import { VideoAnnotator } from "./annotator/annotator.js";

//console.log(css);

console.log($.fn);

//Start running when the window finishes loading
window.addEventListener('load', function(){
    VerifyRequirements();
});

$.fn.annotate = function(serverURL, tagsURL) {
    // Error out early if "this" is not a video
    if($(this).prop('tagName').toLowerCase() != "video"){
        console.error("Cannot wrap a non-video element!");
        return;
    }

    // preferences.GetJSON((data) => {
    //     //console.log(data);
    // });
    
    // Wrap self with custom video player
    let player = new AnnotatorVideoPlayer($(this));
    player.$container.on("OnVideoReady", ()=>{
        // Add annotator once video has loaded
        let annotator = new VideoAnnotator(player, serverURL, tagsURL);
    });

};
{'fraction_non_alphanumeric': 0.15065146579804561, 'fraction_numerical': 0.0, 'mean_word_length': 3.403225806451613, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, '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': '5747650', 'n_tokens_mistral': 703, 'n_tokens_neox': 699, 'n_words': 192}