X-Git-Url: http://git.ieval.ro/?a=blobdiff_plain;f=js%2F90-custom.js;h=d847fc12092dc8dcd444e7929088dc02993e59e9;hb=936ea404e1a7a3fe795a8114969d54df64d8a84a;hp=923ebaf324b8dc02ab62fe64e67658df7753c566;hpb=514a5a0e5b47b39e45b2d1730777372e5ead529d;p=plack-app-gruntmaster.git diff --git a/js/90-custom.js b/js/90-custom.js index 923ebaf..d847fc1 100644 --- a/js/90-custom.js +++ b/js/90-custom.js @@ -1,8 +1,17 @@ (function(){ 'use strict'; function set_style(name){ - $('#stylesheet').attr("href", "/css/" + name); + $('#stylesheet').attr("href", "/css/" + name + ".css"); localStorage.setItem("theme", name); + if(name == 'slate' || name == 'cyborg') + $('.logo').addClass('logo-dark'); + else + $('.logo').removeClass('logo-dark'); + } + + var theme = localStorage.getItem("theme"); + if(theme) { + set_style(theme); } $( document ).ready(function() { @@ -31,10 +40,7 @@ content.wrapInner('
').append('