colorscheme for code view
This commit is contained in:
parent
139a332293
commit
3aee553523
4 changed files with 80 additions and 3 deletions
|
@ -15,4 +15,12 @@ module ProjectsHelper
|
|||
rescue
|
||||
nil
|
||||
end
|
||||
|
||||
def switch_colorscheme_link(opts)
|
||||
if cookies[:colorschema].blank?
|
||||
link_to_function "paint it black!", "$.cookie('colorschema','black'); window.location.reload()", opts
|
||||
else
|
||||
link_to_function "paint it white!", "$.cookie('colorschema',''); window.location.reload()", opts
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue