Improve user feedback on the Profile > Design page
- Header changes immediately without a page reload - Lets the user know that we actually saved their setting when changed
This commit is contained in:
parent
0046409970
commit
30a66c065a
7 changed files with 73 additions and 12 deletions
9
app/views/profile/update.js.erb
Normal file
9
app/views/profile/update.js.erb
Normal file
|
@ -0,0 +1,9 @@
|
|||
// Remove body class for any previous theme, re-add current one
|
||||
$('body').removeClass('ui_basic ui_mars ui_modern ui_gray ui_color')
|
||||
$('body').addClass('<%= app_theme %>')
|
||||
|
||||
// Re-render the header to reflect the new theme
|
||||
$('header').html('<%= escape_javascript(render("layouts/head_panel", title: "Profile")) %>')
|
||||
|
||||
// Re-initialize header tooltips
|
||||
$('.has_bottom_tooltip').tooltip({placement: 'bottom'})
|
Loading…
Add table
Add a link
Reference in a new issue