Add dev env indicator to navigation

This commit is contained in:
Andreas Nedbal 2023-01-11 21:48:15 +01:00 committed by Andreas Nedbal
parent e1ec0590ae
commit 8e915e1c0a
4 changed files with 21 additions and 2 deletions

View File

@ -110,6 +110,7 @@ $unicodeRangeValues in Lexend.$unicodeMap {
"components/inbox-actions", "components/inbox-actions",
"components/inbox-entry", "components/inbox-entry",
"components/mobile-nav", "components/mobile-nav",
"components/navbar",
"components/notifications", "components/notifications",
"components/profile", "components/profile",
"components/push-settings", "components/push-settings",

View File

@ -0,0 +1,18 @@
.navbar-dev {
&:before {
@extend .progress-bar-striped;
@extend .bg-warning;
content: "";
position: absolute;
bottom: 0;
height: 4px;
width: 100%;
background-size: 4px 4px;
@include media-breakpoint-up('md') {
bottom: unset;
top: 0;
}
}
}

View File

@ -1,4 +1,4 @@
%nav.navbar.navbar-themed.navbar-expand-lg.bg-primary.fixed-top.d-lg-block.d-none.d-print-none{ role: :navigation } %nav.navbar.navbar-themed.navbar-expand-lg.bg-primary.fixed-top.d-lg-block.d-none.d-print-none{ class: Rails.env.development? ? "navbar-dev" : "", role: :navigation }
.container .container
%a.navbar-brand{ href: '/', title: APP_CONFIG["site_name"] } %a.navbar-brand{ href: '/', title: APP_CONFIG["site_name"] }
- if APP_CONFIG["use_svg_logo"] - if APP_CONFIG["use_svg_logo"]

View File

@ -1,5 +1,5 @@
- notifications_icon = notification_count.nil? ? 'bell-o' : 'bell' - notifications_icon = notification_count.nil? ? 'bell-o' : 'bell'
%nav.navbar.navbar-themed.bg-primary.fixed-bottom.d-lg-none.d-block.d-print-none#rs-mobile-nav{ role: :navigation } %nav.navbar.navbar-themed.bg-primary.fixed-bottom.d-lg-none.d-block.d-print-none#rs-mobile-nav{ class: Rails.env.development? ? "navbar-dev" : "", role: :navigation }
.container .container
%ul.nav.navbar-nav.navbar-icon-row %ul.nav.navbar-nav.navbar-icon-row
= nav_entry t("navigation.timeline"), root_path, icon: 'home', icon_only: true = nav_entry t("navigation.timeline"), root_path, icon: 'home', icon_only: true