From 353b3aba1db6775300f70ce942e397eb07874ca3 Mon Sep 17 00:00:00 2001 From: Ethan Piliavin Date: Thu, 15 May 2014 22:19:31 +0300 Subject: [PATCH] Added latest version of jquery-noty (2.2.2) --- ajax/libs/jquery-noty/2.2.2/jquery.noty.js | 488 +++++++ ajax/libs/jquery-noty/2.2.2/layouts/bottom.js | 34 + .../jquery-noty/2.2.2/layouts/bottomCenter.js | 41 + .../jquery-noty/2.2.2/layouts/bottomLeft.js | 43 + .../jquery-noty/2.2.2/layouts/bottomRight.js | 43 + ajax/libs/jquery-noty/2.2.2/layouts/center.js | 56 + .../jquery-noty/2.2.2/layouts/centerLeft.js | 61 + .../jquery-noty/2.2.2/layouts/centerRight.js | 61 + ajax/libs/jquery-noty/2.2.2/layouts/inline.js | 31 + ajax/libs/jquery-noty/2.2.2/layouts/top.js | 34 + .../jquery-noty/2.2.2/layouts/topCenter.js | 41 + .../libs/jquery-noty/2.2.2/layouts/topLeft.js | 43 + .../jquery-noty/2.2.2/layouts/topRight.js | 43 + .../2.2.2/packaged/jquery.noty.packaged.js | 1180 +++++++++++++++++ .../packaged/jquery.noty.packaged.min.js | 1 + ajax/libs/jquery-noty/2.2.2/promise.js | 432 ++++++ ajax/libs/jquery-noty/2.2.2/themes/default.js | 156 +++ ajax/libs/jquery-noty/package.json | 3 +- 18 files changed, 2789 insertions(+), 2 deletions(-) create mode 100644 ajax/libs/jquery-noty/2.2.2/jquery.noty.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/bottom.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/bottomCenter.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/bottomLeft.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/bottomRight.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/center.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/centerLeft.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/centerRight.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/inline.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/top.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/topCenter.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/topLeft.js create mode 100644 ajax/libs/jquery-noty/2.2.2/layouts/topRight.js create mode 100644 ajax/libs/jquery-noty/2.2.2/packaged/jquery.noty.packaged.js create mode 100644 ajax/libs/jquery-noty/2.2.2/packaged/jquery.noty.packaged.min.js create mode 100644 ajax/libs/jquery-noty/2.2.2/promise.js create mode 100644 ajax/libs/jquery-noty/2.2.2/themes/default.js diff --git a/ajax/libs/jquery-noty/2.2.2/jquery.noty.js b/ajax/libs/jquery-noty/2.2.2/jquery.noty.js new file mode 100644 index 000000000..6d1e202d4 --- /dev/null +++ b/ajax/libs/jquery-noty/2.2.2/jquery.noty.js @@ -0,0 +1,488 @@ +/** + * noty - jQuery Notification Plugin v2.2.2 + * Contributors: https://github.com/needim/noty/graphs/contributors + * + * Examples and Documentation - http://needim.github.com/noty/ + * + * Licensed under the MIT licenses: + * http://www.opensource.org/licenses/mit-license.php + * + **/ + +if (typeof Object.create !== 'function') { + Object.create = function (o) { + function F() { + } + + F.prototype = o; + return new F(); + }; +} + +(function ($) { + + var NotyObject = { + + init:function (options) { + + // Mix in the passed in options with the default options + this.options = $.extend({}, $.noty.defaults, options); + + this.options.layout = (this.options.custom) ? $.noty.layouts['inline'] : $.noty.layouts[this.options.layout]; + + if ($.noty.themes[this.options.theme]) + this.options.theme = $.noty.themes[this.options.theme]; + else + options.themeClassName = this.options.theme; + + delete options.layout; + delete options.theme; + + this.options = $.extend({}, this.options, this.options.layout.options); + this.options.id = 'noty_' + (new Date().getTime() * Math.floor(Math.random() * 1000000)); + + this.options = $.extend({}, this.options, options); + + // Build the noty dom initial structure + this._build(); + + // return this so we can chain/use the bridge with less code. + return this; + }, // end init + + _build:function () { + + // Generating noty bar + var $bar = $('
').attr('id', this.options.id); + $bar.append(this.options.template).find('.noty_text').html(this.options.text); + + this.$bar = (this.options.layout.parent.object !== null) ? $(this.options.layout.parent.object).css(this.options.layout.parent.css).append($bar) : $bar; + + if (this.options.themeClassName) + this.$bar.addClass(this.options.themeClassName).addClass('noty_container_type_' + this.options.type); + + // Set buttons if available + if (this.options.buttons) { + + // If we have button disable closeWith & timeout options + this.options.closeWith = []; + this.options.timeout = false; + + var $buttons = $('
').addClass('noty_buttons'); + + (this.options.layout.parent.object !== null) ? this.$bar.find('.noty_bar').append($buttons) : this.$bar.append($buttons); + + var self = this; + + $.each(this.options.buttons, function (i, button) { + var $button = $('