From bc6b521f65e35cd710d3907e456f8f10051662c1 Mon Sep 17 00:00:00 2001 From: papsl Date: Sun, 26 Aug 2012 19:05:56 +0300 Subject: [PATCH] Update js/miniNotification.js Added optional image on close button. --- js/miniNotification.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/js/miniNotification.js b/js/miniNotification.js index b05f735..01cfdb4 100644 --- a/js/miniNotification.js +++ b/js/miniNotification.js @@ -18,6 +18,7 @@ closeButton: false, closeButtonText: 'close', closeButtonClass: 'close', + closeButtonImage: '', hideOnClick: true, onLoad: function() {}, onVisible: function() {}, @@ -68,6 +69,12 @@ 'class': _this.getSetting('closeButtonClass'), 'html': _this.getSetting('closeButtonText') }); + if(_this.getSetting('closeButtonImage')){ + var $closeImage = $('', { + 'src': _this.getSetting('closeButtonImage') + }); + $closeButton.append($closeImage); + } _this.$element.children().append($closeButton); return $closeButton.bind('click', function() { return _this.hide();