| 1 |
jQuery(document).ready(function($) { |
| 2 |
//* Vertical table |
| 3 |
$('.tab-nav li:first').addClass('select'); |
| 4 |
$('.tab-panels>div').hide().filter(':first').show(); |
| 5 |
$('.tab-nav a').click(function(){ |
| 6 |
$('.tab-panels>div').hide().filter(this.hash).show(); |
| 7 |
$('.tab-nav li').removeClass('select'); |
| 8 |
$(this).parent().addClass('select'); |
| 9 |
return (false); |
| 10 |
}) |
| 11 |
|
| 12 |
var menu_menu = $('#menu').val(); |
| 13 |
var tooltip_position = $('#tooltip_position').val(); |
| 14 |
|
| 15 |
$('[name="param[menu]"] [value="'+menu_menu+'"]').attr("selected", "selected"); |
| 16 |
$('[name="param[tooltip_position]"] [value="'+tooltip_position+'"]').attr("selected", "selected"); |
| 17 |
|
| 18 |
var i = 1; |
| 19 |
while (i <= 5) { |
| 20 |
var menu = $('#item_icon_'+i).val(); |
| 21 |
$("#font_icon_"+i+" [value='"+menu+"']").attr("selected", "selected"); |
| 22 |
|
| 23 |
$('#font_icon_'+i).fontIconPicker({ |
| 24 |
theme: 'fip-darkgrey', |
| 25 |
emptyIcon: false, |
| 26 |
allCategoryText: 'Show all' |
| 27 |
}); |
| 28 |
item_tooltip(i); |
| 29 |
i++; |
| 30 |
} |
| 31 |
|
| 32 |
var menu_icon = $('#menu_icon').val(); |
| 33 |
$("#font_icon [value='"+menu_icon+"']").attr("selected", "selected"); |
| 34 |
|
| 35 |
$('#font_icon').fontIconPicker({ |
| 36 |
theme: 'fip-darkgrey', |
| 37 |
emptyIcon: false, |
| 38 |
allCategoryText: 'Show all' |
| 39 |
}); |
| 40 |
|
| 41 |
$('#select_icon').fontIconPicker({ |
| 42 |
theme: 'fip-darkgrey', |
| 43 |
emptyIcon: true, |
| 44 |
allCategoryText: 'Show all' |
| 45 |
}); |
| 46 |
|
| 47 |
menuicon(); |
| 48 |
|
| 49 |
}); |
| 50 |
|
| 51 |
function item_tooltip(item){ |
| 52 |
if (jQuery('[name="param[item_tooltip_include]['+item+']"]').is(':checked')){ |
| 53 |
jQuery('.item_tooltip_'+item).css('display', ''); |
| 54 |
} |
| 55 |
else { |
| 56 |
jQuery('.item_tooltip_'+item).css('display', 'none'); |
| 57 |
} |
| 58 |
|
| 59 |
} |
| 60 |
|
| 61 |
function menuicon(){ |
| 62 |
var icon = jQuery('#select_icon').val(); |
| 63 |
var position = jQuery('#icon_position').val(); |
| 64 |
jQuery('#icon_class').text(icon+position); |
| 65 |
} |
| 66 |
|