2015-06-05 17:57:01 +00:00
|
|
|
// Remove body class for any previous theme, re-add current one
|
2015-06-05 19:50:36 +00:00
|
|
|
$('body').removeClass('<%= Gitlab::Themes.body_classes %>')
|
2015-06-05 19:53:57 +00:00
|
|
|
$('body').addClass('<%= user_application_theme %>')
|
2015-06-10 21:08:10 +00:00
|
|
|
|
2015-10-05 15:22:47 +00:00
|
|
|
// Toggle container-fluid class
|
2015-10-05 16:09:05 +00:00
|
|
|
if ('<%= current_user.layout %>' === 'fluid') {
|
2015-10-05 15:22:47 +00:00
|
|
|
$('.content-wrapper').find('.container-fluid').removeClass('container-limited')
|
|
|
|
} else {
|
|
|
|
$('.content-wrapper').find('.container-fluid').addClass('container-limited')
|
|
|
|
}
|
|
|
|
|
2015-06-10 21:08:10 +00:00
|
|
|
// Re-enable the "Save" button
|
|
|
|
$('input[type=submit]').enable()
|
|
|
|
|
|
|
|
// Show the notice flash message
|
2015-06-05 22:01:45 +00:00
|
|
|
new Flash('<%= flash.discard(:notice) %>', 'notice')
|