debian-mirror-gitlab/app/views/profiles/preferences/update.js.erb

17 lines
581 B
Text
Raw Normal View History

2015-09-11 14:41:01 +05:30
// Remove body class for any previous theme, re-add current one
$('body').removeClass('<%= Gitlab::Themes.body_classes %>')
$('body').addClass('<%= user_application_theme %>')
2015-10-24 18:46:33 +05:30
// Toggle container-fluid class
if ('<%= current_user.layout %>' === 'fluid') {
$('.content-wrapper').find('.container-fluid').removeClass('container-limited')
} else {
$('.content-wrapper').find('.container-fluid').addClass('container-limited')
}
2015-09-11 14:41:01 +05:30
// Re-enable the "Save" button
$('input[type=submit]').enable()
// Show the notice flash message
new Flash('<%= flash.discard(:notice) %>', 'notice')