{"version":3,"sources":["kendo.notification.js"],"names":["f","define","$","undefined","kendo","window","Widget","ui","proxy","extend","setTimeout","CLICK","SHOW","HIDE","KNOTIFICATION","KICLOSE","KHIDING","INFO","SUCCESS","WARNING","ERROR","TOP","LEFT","BOTTOM","RIGHT","UP","NS","WRAPPER","TEMPLATE","SAFE_TEMPLATE","replace","Notification","init","element","options","that","this","fn","call","appendTo","is","hide","_compileTemplates","templates","_guid","guid","_isRtl","support","isRtl","_compileStacking","stacking","position","top","left","notify","events","name","pinned","bottom","right","hideOnClick","button","allowHideAfter","autoHideAfter","width","height","animation","open","effects","duration","close","kendoTemplate","template","_compiled","each","key","value","type","templateId","html","_defaultCompiled","_safeCompiled","_getCompiled","safe","defaultCompiled","origin","paddings","paddingTop","paddingRight","paddingBottom","paddingLeft","horizontalAlignment","_popupOrigin","_popupPosition","_popupPaddings","_attachPopupEvents","popup","attachClick","target","on","_hidePopup","closeIcon","attachDelay","isNaN","bind","find","_showPopup","wrapper","openPopup","x","y","last","Popup","anchor","document","body","modal","collision","_triggerHide","deactivate","e","sender","off","destroy","addClass","css","margin","zIndex","_togglePin","pin","win","sign","parseInt","scrollTop","scrollLeft","_attachStaticEvents","_hideStatic","_showStatic","insertionMethod","kendoAnimate","complete","remove","trigger","angular","elements","show","content","args","defaultArgs","isFunction","typeIcon","isPlainObject","toggleClass","attr","append","data","dataItem","showText","info","success","warning","error","openedNotifications","getNotifications","idx","guidElements","children","setOptions","newOptions","plugin","jQuery","amd","a1","a2","a3"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;CAwBC,SAAUA,EAAGC,QACVA,OAAO,sBACH,aACA,eACDD,IACL,WAoWE,MAnVC,UAAUE,EAAGC,GAAb,GACOC,GAAQC,OAAOD,MAAOE,EAASF,EAAMG,GAAGD,OAAQE,EAAQN,EAAEM,MAAOC,EAASP,EAAEO,OAAQC,EAAaL,OAAOK,WAAYC,EAAQ,QAASC,EAAO,OAAQC,EAAO,OAAQC,EAAgB,iBAAkBC,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AAIC,IACrEA,GAAMD","file":"kendo.notification.min.js","sourcesContent":["/*!\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n*/\n(function (f, define) {\n define('kendo.notification', [\n 'kendo.core',\n 'kendo.popup'\n ], f);\n}(function () {\n var __meta__ = {\n id: 'notification',\n name: 'Notification',\n category: 'web',\n description: 'The Notification widget displays user alerts.',\n depends: [\n 'core',\n 'popup'\n ],\n features: [{\n id: 'notification-fx',\n name: 'Animation',\n description: 'Support for animation',\n depends: ['fx']\n }]\n };\n (function ($, undefined) {\n var kendo = window.kendo, Widget = kendo.ui.Widget, proxy = $.proxy, extend = $.extend, setTimeout = window.setTimeout, CLICK = 'click', SHOW = 'show', HIDE = 'hide', KNOTIFICATION = 'k-notification', KICLOSE = '.k-notification-wrap .k-i-close', KHIDING = 'k-hiding', INFO = 'info', SUCCESS = 'success', WARNING = 'warning', ERROR = 'error', TOP = 'top', LEFT = 'left', BOTTOM = 'bottom', RIGHT = 'right', UP = 'up', NS = '.kendoNotification', WRAPPER = '
', TEMPLATE = '
' + '' + '#=content#' + '' + '
', SAFE_TEMPLATE = TEMPLATE.replace('#=content#', '#:content#');\n var Notification = Widget.extend({\n init: function (element, options) {\n var that = this;\n Widget.fn.init.call(that, element, options);\n options = that.options;\n if (!options.appendTo || !$(options.appendTo).is(element)) {\n that.element.hide();\n }\n that._compileTemplates(options.templates);\n that._guid = '_' + kendo.guid();\n that._isRtl = kendo.support.isRtl(element);\n that._compileStacking(options.stacking, options.position.top, options.position.left);\n kendo.notify(that);\n },\n events: [\n SHOW,\n HIDE\n ],\n options: {\n name: 'Notification',\n position: {\n pinned: true,\n top: null,\n left: null,\n bottom: 20,\n right: 20\n },\n stacking: 'default',\n hideOnClick: true,\n button: false,\n allowHideAfter: 0,\n autoHideAfter: 5000,\n appendTo: null,\n width: null,\n height: null,\n templates: [],\n animation: {\n open: {\n effects: 'fade:in',\n duration: 300\n },\n close: {\n effects: 'fade:out',\n duration: 600,\n hide: true\n }\n }\n },\n _compileTemplates: function (templates) {\n var that = this;\n var kendoTemplate = kendo.template;\n that._compiled = {};\n $.each(templates, function (key, value) {\n that._compiled[value.type] = kendoTemplate(value.template || $('#' + value.templateId).html());\n });\n that._defaultCompiled = kendoTemplate(TEMPLATE);\n that._safeCompiled = kendoTemplate(SAFE_TEMPLATE);\n },\n _getCompiled: function (type, safe) {\n var defaultCompiled = safe ? this._safeCompiled : this._defaultCompiled;\n return type ? this._compiled[type] || defaultCompiled : defaultCompiled;\n },\n _compileStacking: function (stacking, top, left) {\n var that = this, paddings = {\n paddingTop: 0,\n paddingRight: 0,\n paddingBottom: 0,\n paddingLeft: 0\n }, horizontalAlignment = left !== null ? LEFT : RIGHT, origin, position;\n switch (stacking) {\n case 'down':\n origin = BOTTOM + ' ' + horizontalAlignment;\n position = TOP + ' ' + horizontalAlignment;\n delete paddings.paddingBottom;\n break;\n case RIGHT:\n origin = TOP + ' ' + RIGHT;\n position = TOP + ' ' + LEFT;\n delete paddings.paddingRight;\n break;\n case LEFT:\n origin = TOP + ' ' + LEFT;\n position = TOP + ' ' + RIGHT;\n delete paddings.paddingLeft;\n break;\n case UP:\n origin = TOP + ' ' + horizontalAlignment;\n position = BOTTOM + ' ' + horizontalAlignment;\n delete paddings.paddingTop;\n break;\n default:\n if (top !== null) {\n origin = BOTTOM + ' ' + horizontalAlignment;\n position = TOP + ' ' + horizontalAlignment;\n delete paddings.paddingBottom;\n } else {\n origin = TOP + ' ' + horizontalAlignment;\n position = BOTTOM + ' ' + horizontalAlignment;\n delete paddings.paddingTop;\n }\n break;\n }\n that._popupOrigin = origin;\n that._popupPosition = position;\n that._popupPaddings = paddings;\n },\n _attachPopupEvents: function (options, popup) {\n var that = this, allowHideAfter = options.allowHideAfter, attachDelay = !isNaN(allowHideAfter) && allowHideAfter > 0, closeIcon;\n function attachClick(target) {\n target.on(CLICK + NS, function () {\n that._hidePopup(popup);\n });\n }\n if (options.hideOnClick) {\n popup.bind('activate', function () {\n if (attachDelay) {\n setTimeout(function () {\n attachClick(popup.element);\n }, allowHideAfter);\n } else {\n attachClick(popup.element);\n }\n });\n } else if (options.button) {\n closeIcon = popup.element.find(KICLOSE);\n if (attachDelay) {\n setTimeout(function () {\n attachClick(closeIcon);\n }, allowHideAfter);\n } else {\n attachClick(closeIcon);\n }\n }\n },\n _showPopup: function (wrapper, options) {\n var that = this, autoHideAfter = options.autoHideAfter, x = options.position.left, y = options.position.top, popup, openPopup;\n openPopup = $('.' + that._guid + ':not(.' + KHIDING + ')').last();\n popup = new kendo.ui.Popup(wrapper, {\n anchor: openPopup[0] ? openPopup : document.body,\n origin: that._popupOrigin,\n position: that._popupPosition,\n animation: options.animation,\n modal: true,\n collision: '',\n isRtl: that._isRtl,\n close: function () {\n that._triggerHide(this.element);\n },\n deactivate: function (e) {\n e.sender.element.off(NS);\n e.sender.element.find(KICLOSE).off(NS);\n e.sender.destroy();\n }\n });\n that._attachPopupEvents(options, popup);\n if (openPopup[0]) {\n popup.open();\n } else {\n if (x === null) {\n x = $(window).width() - wrapper.width() - options.position.right;\n }\n if (y === null) {\n y = $(window).height() - wrapper.height() - options.position.bottom;\n }\n popup.open(x, y);\n }\n popup.wrapper.addClass(that._guid).css(extend({\n margin: 0,\n zIndex: 10050\n }, that._popupPaddings));\n if (options.position.pinned) {\n popup.wrapper.css('position', 'fixed');\n if (openPopup[0]) {\n that._togglePin(popup.wrapper, true);\n }\n } else if (!openPopup[0]) {\n that._togglePin(popup.wrapper, false);\n }\n if (autoHideAfter > 0) {\n setTimeout(function () {\n that._hidePopup(popup);\n }, autoHideAfter);\n }\n },\n _hidePopup: function (popup) {\n popup.wrapper.addClass(KHIDING);\n popup.close();\n },\n _togglePin: function (wrapper, pin) {\n var win = $(window), sign = pin ? -1 : 1;\n wrapper.css({\n top: parseInt(wrapper.css(TOP), 10) + sign * win.scrollTop(),\n left: parseInt(wrapper.css(LEFT), 10) + sign * win.scrollLeft()\n });\n },\n _attachStaticEvents: function (options, wrapper) {\n var that = this, allowHideAfter = options.allowHideAfter, attachDelay = !isNaN(allowHideAfter) && allowHideAfter > 0;\n function attachClick(target) {\n target.on(CLICK + NS, proxy(that._hideStatic, that, wrapper));\n }\n if (options.hideOnClick) {\n if (attachDelay) {\n setTimeout(function () {\n attachClick(wrapper);\n }, allowHideAfter);\n } else {\n attachClick(wrapper);\n }\n } else if (options.button) {\n if (attachDelay) {\n setTimeout(function () {\n attachClick(wrapper.find(KICLOSE));\n }, allowHideAfter);\n } else {\n attachClick(wrapper.find(KICLOSE));\n }\n }\n },\n _showStatic: function (wrapper, options) {\n var that = this, autoHideAfter = options.autoHideAfter, animation = options.animation, insertionMethod = options.stacking == UP || options.stacking == LEFT ? 'prependTo' : 'appendTo';\n wrapper.addClass(that._guid)[insertionMethod](options.appendTo).hide().kendoAnimate(animation.open || false);\n that._attachStaticEvents(options, wrapper);\n if (autoHideAfter > 0) {\n setTimeout(function () {\n that._hideStatic(wrapper);\n }, autoHideAfter);\n }\n },\n _hideStatic: function (wrapper) {\n wrapper.kendoAnimate(extend(this.options.animation.close || false, {\n complete: function () {\n wrapper.off(NS).find(KICLOSE).off(NS);\n wrapper.remove();\n }\n }));\n this._triggerHide(wrapper);\n },\n _triggerHide: function (element) {\n this.trigger(HIDE, { element: element });\n this.angular('cleanup', function () {\n return { elements: element };\n });\n },\n show: function (content, type, safe) {\n var that = this, options = that.options, wrapper = $(WRAPPER), args, defaultArgs;\n if (!type) {\n type = INFO;\n }\n if (content !== null && content !== undefined && content !== '') {\n if (kendo.isFunction(content)) {\n content = content();\n }\n defaultArgs = {\n typeIcon: type,\n content: ''\n };\n if ($.isPlainObject(content)) {\n args = extend(defaultArgs, content);\n } else {\n args = extend(defaultArgs, { content: content });\n }\n wrapper.addClass(KNOTIFICATION + '-' + type).toggleClass(KNOTIFICATION + '-button', options.button).attr('data-role', 'alert').css({\n width: options.width,\n height: options.height\n }).append(that._getCompiled(type, safe)(args));\n that.angular('compile', function () {\n return {\n elements: wrapper,\n data: [{ dataItem: args }]\n };\n });\n if ($(options.appendTo)[0]) {\n that._showStatic(wrapper, options);\n } else {\n that._showPopup(wrapper, options);\n }\n that.trigger(SHOW, { element: wrapper });\n }\n return that;\n },\n showText: function (content, type) {\n this.show(content, type, true);\n },\n info: function (content) {\n return this.show(content, INFO);\n },\n success: function (content) {\n return this.show(content, SUCCESS);\n },\n warning: function (content) {\n return this.show(content, WARNING);\n },\n error: function (content) {\n return this.show(content, ERROR);\n },\n hide: function () {\n var that = this, openedNotifications = that.getNotifications();\n if (that.options.appendTo) {\n openedNotifications.each(function (idx, element) {\n that._hideStatic($(element));\n });\n } else {\n openedNotifications.each(function (idx, element) {\n var popup = $(element).data('kendoPopup');\n if (popup) {\n that._hidePopup(popup);\n }\n });\n }\n return that;\n },\n getNotifications: function () {\n var that = this, guidElements = $('.' + that._guid + ':not(.' + KHIDING + ')');\n if (that.options.appendTo) {\n return guidElements;\n } else {\n return guidElements.children('.' + KNOTIFICATION);\n }\n },\n setOptions: function (newOptions) {\n var that = this, options;\n Widget.fn.setOptions.call(that, newOptions);\n options = that.options;\n if (newOptions.templates !== undefined) {\n that._compileTemplates(options.templates);\n }\n if (newOptions.stacking !== undefined || newOptions.position !== undefined) {\n that._compileStacking(options.stacking, options.position.top, options.position.left);\n }\n },\n destroy: function () {\n Widget.fn.destroy.call(this);\n this.getNotifications().off(NS).find(KICLOSE).off(NS);\n }\n });\n kendo.ui.plugin(Notification);\n }(window.kendo.jQuery));\n return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n (a3 || a2)();\n}));"]}