<commit_before><!doctype html>
<html>
<head>
  <meta charset="utf-8">
  <title>Plugin Example - Wavesurfer Plugin for Video.js</title>

  <link href="../node_modules/video.js/dist/video-js.min.css" rel="stylesheet">
  <link href="../dist/css/videojs.wavesurfer.css" rel="stylesheet">

  <script src="../node_modules/video.js/dist/video.min.js"></script>
  <script src="../node_modules/wavesurfer.js/dist/wavesurfer.min.js"></script>
  <script src="../node_modules/wavesurfer.js/dist/plugin/wavesurfer.cursor.min.js"></script>

  <script src="../dist/videojs.wavesurfer.js"></script>

  <script src="safari-workaround.js"></script>

  <style>
  /* change player background color */
  #myAudio {
      background-color: #FFEEFF;
  }
  </style>

</head>
<body>

<audio id="myAudio" class="video-js vjs-default-skin"></audio>

<script>
var player;
var options = {
    controls: true,
    autoplay: false,
    fluid: false,
    loop: false,
    width: 600,
    height: 300,
    plugins: {
        wavesurfer: {
            src: 'media/hal.wav',
            msDisplayMax: 10,
            debug: true,
            waveColor: 'grey',
            progressColor: 'black',
            cursorColor: 'black',
            hideScrollbar: true,
            plugins: [
                WaveSurfer.cursor.create({
                    hideOnBlur: true
                })
            ]
        }
    }
};

if (isSafari) {
    // add start button for safari
    addStartButton();
} else {
    // other browsers
    createPlayer();
}

function createPlayer(event) {
    if (isSafari) {
        if (event) {
            // hide button on safari
            event.target.style.display = 'none';
        }
        updateContext(options);
    }

    // create player
    player = videojs('myAudio', options, function() {
        // print version information at startup
        var msg = 'Using video.js '+ videojs.VERSION +
            ' with videojs-wavesurfer ' +
            videojs.getPluginVersion('wavesurfer') +
            ' and wavesurfer.js ' + WaveSurfer.VERSION;<commit_msg>plugin example: display cursor time<commit_after><!doctype html>
<html>
<head>
  <meta charset="utf-8">
  <title>Plugin Example - Wavesurfer Plugin for Video.js</title>

  <link href="../node_modules/video.js/dist/video-js.min.css" rel="stylesheet">
  <link href="../dist/css/videojs.wavesurfer.css" rel="stylesheet">

  <script src="../node_modules/video.js/dist/video.min.js"></script>
  <script src="../node_modules/wavesurfer.js/dist/wavesurfer.min.js"></script>
  <script src="../node_modules/wavesurfer.js/dist/plugin/wavesurfer.cursor.min.js"></script>

  <script src="../dist/videojs.wavesurfer.js"></script>

  <script src="safari-workaround.js"></script>

  <style>
  /* change player background color */
  #myAudio {
      background-color: #FFEEFF;
  }
  </style>

</head>
<body>

<audio id="myAudio" class="video-js vjs-default-skin"></audio>

<script>
var player;
var options = {
    controls: true,
    autoplay: false,
    fluid: false,
    loop: false,
    width: 600,
    height: 300,
    plugins: {
        wavesurfer: {
            src: 'media/hal.wav',
            msDisplayMax: 10,
            debug: true,
            waveColor: 'grey',
            progressColor: 'black',
            cursorColor: 'black',
            hideScrollbar: true,
            plugins: [
                WaveSurfer.cursor.create({
                    hideOnBlur: true,
                    showTime: true,
                    opacity: 1,
                    customShowTimeStyle: {
                        'background-color': '#000',
                        color: '#fff',
                        padding: '2px',
                        'font-size': '10px'
                    }
                })
            ]
        }
    }
};

if (isSafari) {
    // add start button for safari
    addStartButton();
} else {
    // other browsers
    createPlayer();
}

function createPlayer(event) {
    if (isSafari) {
        if (event) {
            // hide button on safari
            event.target.style.display = 'none';
        }
        updateContext(options);
    }

    // create player
    player = videojs('myAudio', options, function() {
        // print version information at startup
        var msg = 'Using video.js '+ videojs.VERSION +
            ' with videojs-wavesurfer ' +
            videojs.getPluginVersion('wavesurfer') +
            ' and wavesurfer.js ' + WaveSurfer.VERSION;
{'fraction_non_alphanumeric': 0.14295347269049224, 'fraction_numerical': 0.005619240278714317, 'mean_word_length': 1.9785809906291834, 'pattern_counts': {'":': 0, '<': 53, '<?xml version=': 0, '>': 53, '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': '4501666', 'n_tokens_mistral': 1423, 'n_tokens_neox': 1343, 'n_words': 270}