Skip to content

Commit

Permalink
fixed sidebar location/default open (#42)
Browse files Browse the repository at this point in the history
  • Loading branch information
davidagud authored Sep 3, 2020
1 parent bcd34cc commit 07fef81
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
8 changes: 8 additions & 0 deletions app/assets/javascripts/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,14 @@ $(window).resize(function () {
}

});

$(window).on('load', function() {
if ($(window).width() < 1000) {
$('#sidebar-main').addClass('main_collapsed').removeClass('not-collapsed');
$(".main-content").removeClass('open');
}
});

$(window).resize(function () {

if ($(window).width() >= 992) {
Expand Down
1 change: 0 additions & 1 deletion app/assets/stylesheets/metadata-template.css
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,6 @@
}

.not-collapsed {
position: fixed;
top: 0;
bottom: 0;
left: 0;
Expand Down

0 comments on commit 07fef81

Please sign in to comment.