-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master-ci' into release
- Loading branch information
Showing
12 changed files
with
973 additions
and
773 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,113 +1,111 @@ | ||
<script> nonce = "{{request.csp_nonce}}" | ||
$(document).ready(function () { | ||
$().ready(function () { | ||
$sidebar = $('.sidebar'); | ||
$navbar = $('.navbar'); | ||
$main_panel = $('.main-panel'); | ||
|
||
<script> | ||
$(document).ready(function() { | ||
$().ready(function() { | ||
$sidebar = $('.sidebar'); | ||
$navbar = $('.navbar'); | ||
$main_panel = $('.main-panel'); | ||
$full_page = $('.full-page'); | ||
|
||
$full_page = $('.full-page'); | ||
$sidebar_responsive = $('body > .navbar-collapse'); | ||
sidebar_mini_active = true; | ||
white_color = false; | ||
|
||
$sidebar_responsive = $('body > .navbar-collapse'); | ||
sidebar_mini_active = true; | ||
white_color = false; | ||
window_width = $(window).width(); | ||
|
||
window_width = $(window).width(); | ||
fixed_plugin_open = $('.sidebar .sidebar-wrapper .nav li.active a p').html(); | ||
|
||
fixed_plugin_open = $('.sidebar .sidebar-wrapper .nav li.active a p').html(); | ||
|
||
|
||
$('.fixed-plugin a').click(function (event) { | ||
if ($(this).hasClass('switch-trigger')) { | ||
if (event.stopPropagation) { | ||
event.stopPropagation(); | ||
} else if (window.event) { | ||
window.event.cancelBubble = true; | ||
} | ||
} | ||
}); | ||
|
||
$('.fixed-plugin a').click(function(event) { | ||
if ($(this).hasClass('switch-trigger')) { | ||
if (event.stopPropagation) { | ||
event.stopPropagation(); | ||
} else if (window.event) { | ||
window.event.cancelBubble = true; | ||
} | ||
} | ||
}); | ||
$('.fixed-plugin .background-color span').click(function () { | ||
$(this).siblings().removeClass('active'); | ||
$(this).addClass('active'); | ||
|
||
$('.fixed-plugin .background-color span').click(function() { | ||
$(this).siblings().removeClass('active'); | ||
$(this).addClass('active'); | ||
var new_color = $(this).data('color'); | ||
|
||
var new_color = $(this).data('color'); | ||
if ($sidebar.length != 0) { | ||
$sidebar.attr('data', new_color); | ||
} | ||
|
||
if ($sidebar.length != 0) { | ||
$sidebar.attr('data', new_color); | ||
} | ||
if ($main_panel.length != 0) { | ||
$main_panel.attr('data', new_color); | ||
} | ||
|
||
if ($main_panel.length != 0) { | ||
$main_panel.attr('data', new_color); | ||
} | ||
if ($full_page.length != 0) { | ||
$full_page.attr('filter-color', new_color); | ||
} | ||
|
||
if ($full_page.length != 0) { | ||
$full_page.attr('filter-color', new_color); | ||
} | ||
if ($sidebar_responsive.length != 0) { | ||
$sidebar_responsive.attr('data', new_color); | ||
} | ||
}); | ||
|
||
if ($sidebar_responsive.length != 0) { | ||
$sidebar_responsive.attr('data', new_color); | ||
} | ||
}); | ||
$('.switch-sidebar-mini input').on("switchChange.bootstrapSwitch", function () { | ||
var $btn = $(this); | ||
|
||
$('.switch-sidebar-mini input').on("switchChange.bootstrapSwitch", function() { | ||
var $btn = $(this); | ||
if (sidebar_mini_active == true) { | ||
$('body').removeClass('sidebar-mini'); | ||
sidebar_mini_active = false; | ||
blackDashboard.showSidebarMessage('Sidebar mini deactivated...'); | ||
} else { | ||
$('body').addClass('sidebar-mini'); | ||
sidebar_mini_active = true; | ||
blackDashboard.showSidebarMessage('Sidebar mini activated...'); | ||
} | ||
|
||
if (sidebar_mini_active == true) { | ||
$('body').removeClass('sidebar-mini'); | ||
sidebar_mini_active = false; | ||
blackDashboard.showSidebarMessage('Sidebar mini deactivated...'); | ||
} else { | ||
$('body').addClass('sidebar-mini'); | ||
sidebar_mini_active = true; | ||
blackDashboard.showSidebarMessage('Sidebar mini activated...'); | ||
} | ||
|
||
// we simulate the window Resize so the charts will get updated in realtime. | ||
var simulateWindowResize = setInterval(function() { | ||
window.dispatchEvent(new Event('resize')); | ||
}, 180); | ||
|
||
// we stop the simulation of Window Resize after the animations are completed | ||
setTimeout(function() { | ||
clearInterval(simulateWindowResize); | ||
}, 1000); | ||
}); | ||
// we simulate the window Resize so the charts will get updated in realtime. | ||
var simulateWindowResize = setInterval(function () { | ||
window.dispatchEvent(new Event('resize')); | ||
}, 180); | ||
|
||
$('.switch-change-color input').on("switchChange.bootstrapSwitch", function() { | ||
var $btn = $(this); | ||
// we stop the simulation of Window Resize after the animations are completed | ||
setTimeout(function () { | ||
clearInterval(simulateWindowResize); | ||
}, 1000); | ||
}); | ||
|
||
if (white_color == true) { | ||
$('.switch-change-color input').on("switchChange.bootstrapSwitch", function () { | ||
var $btn = $(this); | ||
|
||
$('body').addClass('change-background'); | ||
setTimeout(function() { | ||
$('body').removeClass('change-background'); | ||
$('body').removeClass('white-content'); | ||
}, 900); | ||
white_color = false; | ||
} else { | ||
if (white_color == true) { | ||
|
||
$('body').addClass('change-background'); | ||
setTimeout(function() { | ||
$('body').removeClass('change-background'); | ||
$('body').addClass('white-content'); | ||
}, 900); | ||
$('body').addClass('change-background'); | ||
setTimeout(function () { | ||
$('body').removeClass('change-background'); | ||
$('body').removeClass('white-content'); | ||
}, 900); | ||
white_color = false; | ||
} else { | ||
|
||
white_color = true; | ||
} | ||
$('body').addClass('change-background'); | ||
setTimeout(function () { | ||
$('body').removeClass('change-background'); | ||
$('body').addClass('white-content'); | ||
}, 900); | ||
|
||
white_color = true; | ||
} | ||
|
||
}); | ||
|
||
$('.light-badge').click(function() { | ||
$('body').addClass('white-content'); | ||
}); | ||
}); | ||
|
||
$('.light-badge').click(function () { | ||
$('body').addClass('white-content'); | ||
}); | ||
|
||
$('.dark-badge').click(function() { | ||
$('body').removeClass('white-content'); | ||
$('.dark-badge').click(function () { | ||
$('body').removeClass('white-content'); | ||
}); | ||
}); | ||
}); | ||
}); | ||
</script> | ||
|
||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.