
jquery.blockUI.js
About this file
Refer to jQuery blockUI's documentation.
Code Issues
- On line 15, unnecessary semicolon is detected. JavaScript will more or less let you put semicolons after any statement without complaining. While not technically an error, extra semicolons can be a source of confusion when reading code. This is automatically fixable using the --fix flag on the command line.
Code Check Report
15:1 error Unnecessary semicolon no-extra-semi 15:2 error Move the invocation into the parens that contain the function wrap-iife 90:32 error Expected '===' and instead saw '==' eqeqeq 176:60 error Script URL is a form of eval no-script-url 250:3 warning Function 'install' has a complexity of 73 complexity 252:19 error Expected '===' and instead saw '==' eqeqeq 274:26 error Expected '!==' and instead saw '!=' eqeqeq 375:20 warning Function has a complexity of 12 complexity 457:3 warning Function 'remove' has a complexity of 10 complexity 459:19 error Expected '===' and instead saw '==' eqeqeq 504:3 warning Function 'reset' has a complexity of 7 complexity 528:30 error Expected '===' and instead saw '==' eqeqeq 538:3 warning Function 'bind' has a complexity of 11 complexity 539:18 error Expected '===' and instead saw '==' eqeqeq 564:3 warning Function 'handler' has a complexity of 13 complexity 566:55 error Expected '===' and instead saw '==' eqeqeq ✖ 16 problems (10 errors, 6 warnings) 4 errors and 0 warnings potentially fixable with the `--fix` option.
Documentation drawn from source code
/*!
* jQuery blockUI plugin
* Version 2.70.0-2014.11.23
* Requires jQuery v1.7 or later
*
* Copyright (c) 2007-2013 M. Alsup
* Dual licensed under the MIT and GPL licenses:
*
* Thanks to Amir-Hossein Sobhi for some excellent contributions!
*/
;(function() {
/*jshint eqeqeq:false curly:false latedef:false */
function setup($) {
var noOp = $.noop || function() {};
$.blockUI = function(opts) { install(window, opts); };
$.unblockUI = function(opts) { remove(window, opts); };
$.growlUI = function(title, message, timeout, onClose) {
var callBlock = function(opts) {
$m.mouseover(function() {
}).mouseout(function() {
$.fn.block = function(opts) {
this.each(function() {
return this.each(function() {
$.fn.unblock = function(opts) {
return this.each(function() {
/*jshint scripturl:true */
function install(el, opts) {
if (!opts.theme /*&& (!opts.applyPlatformOpacityRules)*/)
$.each(layers, function() {
$.each(layers, function(i,o) {
var to = setTimeout(function() {
function remove(el, opts) {
els.stop().fadeOut(opts.fadeOut, function() {
function reset(els,data,opts,el) {
els.each(function(i,o) {
if (typeof opts.onUnblock == 'function')
function bind(b, el, opts) {
function handler(e) {
setTimeout(function(){focus(back);},10);
function focus(back) {
function center(el, x, y) {
function sz(el, p) {
/*global define:true */
if (typeof define === 'function' && define.amd && define.amd.jQuery) {