Removed extraneous icons

Font Awesomed AddSeries
Font Awesomed gritter
This commit is contained in:
Mark McDowall 2012-10-11 10:25:31 -07:00
parent 6ffb99f84f
commit a3d4b7ed82
36 changed files with 50 additions and 37 deletions

View file

@ -16,7 +16,7 @@
$.gritter.add({
title: data.Title,
text: data.Text,
image: '../../content/images/success.png',
icon: 'icon-info-sign',
class_name: 'gritter-success'
});
}
@ -24,7 +24,7 @@
$.gritter.add({
title: data.Title,
text: data.Text,
image: '../../content/images/error.png',
icon: 'icon-minus-sign',
class_name: 'gritter-fail',
time: 10000
});
@ -40,7 +40,7 @@
$.gritter.add({
title: 'Request failed',
text: 'Url: ' + this.url + '<br/>Error: ' + thrownError,
image: '../../content/images/error.png',
icon: 'icon-minus-sign',
class_name: 'gritter-fail',
time: 10000
});

View file

@ -33,7 +33,7 @@ $(".addExistingButton").live('click', function () {
$.gritter.add({
title: 'Failed',
text: 'Invalid Series Information for \'' + path + '\'',
image: '../../content/images/error.png',
icon: 'icon-minus-sign',
class_name: 'gritter-fail'
});
@ -76,8 +76,8 @@ $(".start-date-master").live('change', function () {
//RootDir
//Delete RootDir
$('#rootDirs .actionButton img').live('click', function (image) {
var path = $(image.target).attr('id');
$(document).on('click', '.delete-root', function () {
var path = $(this).attr('data-path');
$.ajax({
type: "POST",

View file

@ -103,6 +103,7 @@
var user = params.title,
text = params.text,
image = params.image || '',
icon = params.icon || '',
sticky = params.sticky || false,
item_class = params.class_name || '',
position = $.gritter.options.position,
@ -127,13 +128,22 @@
this._custom_timer = time_alive;
}
var image_str = (image != '') ? '<img src="' + image + '" class="gritter-image" />' : '',
class_name = (image != '') ? 'gritter-with-image' : 'gritter-without-image';
var image_str = (image != '') ? '<img src="' + image + '" class="gritter-image" />' : '';
var icon_str = (icon != '') ? '<i class="' + icon + ' gritter-icon"></i>' : '';
var class_name = (image != ''|| icon != '') ? 'gritter-with-image' : 'gritter-without-image';
var iconImage = '';
if (image_str != '')
iconImage = image_str;
if (icon_str != '')
iconImage = icon_str;
// String replacements on the template
tmp = this._str_replace(
['[[username]]', '[[text]]', '[[close]]', '[[image]]', '[[number]]', '[[class_name]]', '[[item_class]]'],
[user, text, this._tpl_close, image_str, this._item_count, class_name, item_class], tmp
[user, text, this._tpl_close, iconImage, this._item_count, class_name, item_class], tmp
);
this['_before_open_' + number]();