Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add package.json #114

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 16 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# BlockUI - Page or element overlay
# BlockUI - Page or element overlay [![NPM version][npm-image]][npm-url]

### NOTE: This is a fork from the official version, for publishing on npm. See https://github.com/malsup/blockui/pull/114

## Getting Started
Download either the [production version][min] or the [development version][max] of BlockUI.
Expand All @@ -8,21 +10,21 @@ Download either the [production version][min] or the [development version][max]

In your web page:

<pre>
&lt;!-- include jQuery -->
&lt;script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js">&lt;/script>
&lt;!-- include BlockUI -->
&lt;script src="http://path/to/your/copy/of/jquery.blockUI.js">&lt;/script>
&lt;script>
// invoke blockUI as needed -->
```html
<!-- include jQuery -->
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.js"></script>
<!-- include BlockUI -->
<script src="http://path/to/your/copy/of/jquery.blockUI.js"></script>
<script>
// invoke blockUI as needed
$(document).on('click', '#myButton', function() {
$.blockUI();
});
>&lt;/script>
</pre>
</script>
```

## Documentation, Demos and FAQ
Everything you need to know can be found here:
Everything you need to know can be found here:
[http://jquery.malsup.com/block/](http://jquery.malsup.com/block/)


Expand All @@ -36,3 +38,6 @@ You may use either license. The MIT license is recommended for most projects be
If the GPL suits your project better you are also free to use the plugin under that license.

You do not have to do anything special to choose one license or the other and you don't have to notify anyone which license you are using. You are free to use the BlockUI plugin in commercial projects as long as the copyright header is left intact.

[npm-url]: https://www.npmjs.com/package/block-ui/
[npm-image]: http://img.shields.io/npm/v/block-ui.svg
7 changes: 6 additions & 1 deletion jquery.blockUI.js
Original file line number Diff line number Diff line change
Expand Up @@ -611,9 +611,14 @@


/*global define:true */
if (typeof define === 'function' && define.amd && define.amd.jQuery) {
if (typeof define === 'function' && define.amd) {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Official" UMD-wrapper for jquery plugins (https://github.com/umdjs/umd/blob/master/jqueryPluginCommonjs.js)

// AMD. Register as an anonymous module.
define(['jquery'], setup);
} else if (typeof exports === 'object') {
// Node/CommonJS
setup(require('jquery'));
} else {
// Browser globals
setup(jQuery);
}

Expand Down
39 changes: 39 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"name": "block-ui",
"description": "Simulate synchronous ajax by blocking - not locking - the UI. This plugin lets you block user interaction with the page or with a specific element on the page. Also great at displaying modal dialogs.",
"version": "2.70.0",
"author": "M. Alsup (http://jquery.malsup.com)",
"bugs": {
"url": "https://github.com/malsup/blockui/issues"
},
"dependencies": {
"jquery": ">=1.7.x"
},
"homepage": "http://jquery.malsup.com/block/",
"keywords": [
"block",
"dialog",
"ecosystem:jquery",
"jquery-plugin",
"modal",
"overlay"
],
"license": [
{
"type": "MIT",
"url": "http://malsup.github.com/mit-license.txt"
},
{
"type": "GPL",
"url": "http://malsup.github.com/gpl-license-v2.txt"
}
],
"main": "jquery.blockUI.js",
"repository": {
"type": "git",
"url": "https://github.com/malsup/blockui.git"
},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
}
}