]>
iEval git - gruntmaster-page.git/blob - js/90-themes.js
3 function set_style(name
){
4 $('link[rel~="stylesheet"]').prop('disabled', true);
5 $('link[title="' + name
+ '"]').prop('disabled', false);
6 localStorage
.setItem("theme", name
);
11 function add_themelink(theme
, text
) {
12 var link
= $('<a role="button">' + text
+ '</a>');
13 link
.appendTo(selector
.find('ul')).wrap('<li>').on('click', function () { set_style(theme
) });
16 $( document
).ready(function() {
17 selector
= $('<div>Themes: <ul class="list-inline"></ul></div>');
18 add_themelink('cyborg', 'Black');
19 add_themelink('slate', 'Grey');
20 add_themelink('readable', 'White');
21 $('#sidebar').prepend(selector
);
24 var theme
= localStorage
.getItem("theme");
26 if(theme
== "cerulean" || theme
== "cosmo")
This page took 0.043871 seconds and 4 git commands to generate.