Skip to content

Commit

Permalink
Merge pull request #2334 from sparc-request/yw-navbar-ui-improvement
Browse files Browse the repository at this point in the history
(SPARC NavBar) UI Improvement Needed for Narrow Screens
  • Loading branch information
Stuart-Johnson committed May 12, 2020
2 parents 4c1659f + 1b4d67d commit 93dd20e
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion app/assets/stylesheets/custom/bootstrap-custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -658,7 +658,7 @@ nav.navbar {
padding: 1rem 1.5rem !important;
border-right: 0 !important;
border-bottom: 1px solid theme-color-level('light', 1);
justify-content: right;
justify-content: left;
}
}

Expand Down
2 changes: 1 addition & 1 deletion app/assets/stylesheets/navbar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ nav#siteNav {

.profile {
.notification-badge {
top: 2px;
right: 10px;
position: relative;
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions app/views/layouts/_navbar.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@
.navbar-nav.mr-auto
- Setting.get_value("navbar_links").each do |identifier, data|
= navbar_link(identifier, data, @highlighted_link)
%button.btn.btn-primary.navbar-toggler.p-0.border-0.text-light{ type: 'button', data: { toggle: 'collapse', target: '#navbarLinks' }, aria: { controls: 'navbarLinks', expanded: 'false', label: t('layout.navigation.toggle') } }
= icon('fas', 'bars fa-2x')
.navbar-nav#navbarUtilities
- if Setting.get_value('use_news_feed')
= render 'layouts/news'
- if Setting.get_value('use_google_calendar')
= render 'layouts/events'
= render 'layouts/profile'
= render 'layouts/help'
%button.btn.btn-primary.navbar-toggler.p-0.border-0.text-light{ type: 'button', data: { toggle: 'collapse', target: '#navbarLinks' }, aria: { controls: 'navbarLinks', expanded: 'false', label: t('layout.navigation.toggle') } }
= icon('fas', 'bars fa-2x')
7 changes: 4 additions & 3 deletions app/views/layouts/_profile.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@
- if current_user
.nav-item.dropdown.no-caret.profile
= link_to 'javascript:void(0)', class: 'nav-link dropdown-toggle', id: 'profileDropdown', role: 'button', aria: { haspopup: 'true', expanded: 'false' } do
= icon('fas', 'user-circle fa-2x')
- if current_user.unread_notification_count > 0
%span.badge.badge-pill.badge-c.badge-danger.notification-badge  
.d-flex.justify-content-center
= icon('fas', 'user-circle fa-2x')
- if current_user.unread_notification_count > 0
%span.badge.badge-pill.badge-c.badge-danger.notification-badge  
.dropdown-menu.dropdown-menu-xl-right{ aria: { labelledby: 'profileDropdown' } }
= link_to 'javascript:void(0)', class: 'dropdown-header d-flex text-secondary' do
= icon('fas', 'user-circle fa-3x mr-2')
Expand Down

0 comments on commit 93dd20e

Please sign in to comment.