mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
update scheduled tasks page
This commit is contained in:
parent
f73a917448
commit
1ac9bfe5aa
65 changed files with 8424 additions and 48 deletions
80
dashboard-ui/bower_components/doc-ready/doc-ready.js
vendored
Normal file
80
dashboard-ui/bower_components/doc-ready/doc-ready.js
vendored
Normal file
|
@ -0,0 +1,80 @@
|
|||
/*!
|
||||
* docReady v1.0.4
|
||||
* Cross browser DOMContentLoaded event emitter
|
||||
* MIT license
|
||||
*/
|
||||
|
||||
/*jshint browser: true, strict: true, undef: true, unused: true*/
|
||||
/*global define: false, require: false, module: false */
|
||||
|
||||
( function( window ) {
|
||||
|
||||
'use strict';
|
||||
|
||||
var document = window.document;
|
||||
// collection of functions to be triggered on ready
|
||||
var queue = [];
|
||||
|
||||
function docReady( fn ) {
|
||||
// throw out non-functions
|
||||
if ( typeof fn !== 'function' ) {
|
||||
return;
|
||||
}
|
||||
|
||||
if ( docReady.isReady ) {
|
||||
// ready now, hit it
|
||||
fn();
|
||||
} else {
|
||||
// queue function when ready
|
||||
queue.push( fn );
|
||||
}
|
||||
}
|
||||
|
||||
docReady.isReady = false;
|
||||
|
||||
// triggered on various doc ready events
|
||||
function onReady( event ) {
|
||||
// bail if already triggered or IE8 document is not ready just yet
|
||||
var isIE8NotReady = event.type === 'readystatechange' && document.readyState !== 'complete';
|
||||
if ( docReady.isReady || isIE8NotReady ) {
|
||||
return;
|
||||
}
|
||||
|
||||
trigger();
|
||||
}
|
||||
|
||||
function trigger() {
|
||||
docReady.isReady = true;
|
||||
// process queue
|
||||
for ( var i=0, len = queue.length; i < len; i++ ) {
|
||||
var fn = queue[i];
|
||||
fn();
|
||||
}
|
||||
}
|
||||
|
||||
function defineDocReady( eventie ) {
|
||||
// trigger ready if page is ready
|
||||
if ( document.readyState === 'complete' ) {
|
||||
trigger();
|
||||
} else {
|
||||
// listen for events
|
||||
eventie.bind( document, 'DOMContentLoaded', onReady );
|
||||
eventie.bind( document, 'readystatechange', onReady );
|
||||
eventie.bind( window, 'load', onReady );
|
||||
}
|
||||
|
||||
return docReady;
|
||||
}
|
||||
|
||||
// transport
|
||||
if ( typeof define === 'function' && define.amd ) {
|
||||
// AMD
|
||||
define( [ 'eventie/eventie' ], defineDocReady );
|
||||
} else if ( typeof exports === 'object' ) {
|
||||
module.exports = defineDocReady( require('eventie') );
|
||||
} else {
|
||||
// browser global
|
||||
window.docReady = defineDocReady( window.eventie );
|
||||
}
|
||||
|
||||
})( window );
|
Loading…
Add table
Add a link
Reference in a new issue