Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
Metabase
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Engineering Digital Service
Metabase
Commits
e586ff93
Commit
e586ff93
authored
7 years ago
by
Kyle Doherty
Committed by
GitHub
7 years ago
Browse files
Options
Downloads
Patches
Plain Diff
put nav on a diet (#6122)
parent
0d80e73f
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
frontend/src/metabase/css/admin.css
+0
-7
0 additions, 7 deletions
frontend/src/metabase/css/admin.css
frontend/src/metabase/nav/containers/Navbar.jsx
+7
-12
7 additions, 12 deletions
frontend/src/metabase/nav/containers/Navbar.jsx
with
7 additions
and
19 deletions
frontend/src/metabase/css/admin.css
+
0
−
7
View file @
e586ff93
...
...
@@ -7,18 +7,11 @@
}
.AdminNav
{
padding-top
:
1.825em
;
padding-bottom
:
1.825em
;
background
:
var
(
--admin-nav-bg-color
);
color
:
#fff
;
font-size
:
0.85rem
;
}
.AdminGear
{
margin-top
:
0.25em
;
margin-right
:
0.5em
;
}
.AdminNav
.NavItem
{
color
:
var
(
--admin-nav-item-text-color
);
}
...
...
This diff is collapsed.
Click to expand it.
frontend/src/metabase/nav/containers/Navbar.jsx
+
7
−
12
View file @
e586ff93
...
...
@@ -65,27 +65,22 @@ const MainNavLink = ({ to, name, eventName }) =>
@
connect
(
mapStateToProps
,
mapDispatchToProps
)
export
default
class
Navbar
extends
Component
{
static
propTypes
=
{
className
:
PropTypes
.
string
,
context
:
PropTypes
.
string
.
isRequired
,
path
:
PropTypes
.
string
.
isRequired
,
user
:
PropTypes
.
object
};
constructor
(
props
,
context
)
{
super
(
props
,
context
);
}
isActive
(
path
)
{
return
this
.
props
.
path
.
startsWith
(
path
);
}
renderAdminNav
()
{
return
(
<
nav
className
=
{
cx
(
"
Nav AdminNav
"
,
this
.
props
.
className
)
}
>
<
div
className
=
"
wrapper
flex align-center"
>
<
nav
className
=
{
cx
(
"
Nav AdminNav
sm-py1
"
)
}
>
<
div
className
=
"
sm-pl4
flex align-center
pr1
"
>
<
div
className
=
"NavTitle flex align-center"
>
<
Icon
name
=
{
'
gear
'
}
className
=
"AdminGear"
size
=
{
22
}
></
Icon
>
<
span
className
=
"NavItem-text ml1 hide sm-show text-bold"
>
Metabase Admin
Panel
</
span
>
<
span
className
=
"NavItem-text ml1 hide sm-show text-bold"
>
Metabase Admin
</
span
>
</
div
>
<
ul
className
=
"sm-ml4 flex flex-full text-strong"
>
...
...
@@ -104,7 +99,7 @@ export default class Navbar extends Component {
renderEmptyNav
()
{
return
(
<
nav
className
=
{
cx
(
"
Nav
py2
sm-py1
xl-py3
relative
"
,
this
.
props
.
className
)
}
>
<
nav
className
=
"Nav sm-py1 relative"
>
<
ul
className
=
"wrapper flex align-center"
>
<
li
>
<
Link
to
=
"/"
data-metabase-event
=
{
"
Navbar;Logo
"
}
className
=
"NavItem cursor-pointer flex align-center"
>
...
...
@@ -118,8 +113,8 @@ export default class Navbar extends Component {
renderMainNav
()
{
return
(
<
nav
className
=
{
cx
(
"
Nav relative bg-brand sm-py
2 sm-py1 xl-py3
"
,
this
.
props
.
className
)
}
>
<
ul
className
=
"
ml2
sm-pl4 pr1 flex align-center"
>
<
nav
className
=
"Nav relative bg-brand sm-py
1"
>
<
ul
className
=
"sm-pl4 pr1 flex align-center"
>
<
li
>
<
Link
to
=
"/"
data-metabase-event
=
{
"
Navbar;Logo
"
}
className
=
"NavItem cursor-pointer text-white flex align-center my1 transition-background p1"
>
<
LogoIcon
dark
=
{
true
}
></
LogoIcon
>
...
...
@@ -151,7 +146,7 @@ export default class Navbar extends Component {
}
render
()
{
le
t
{
context
,
user
}
=
this
.
props
;
cons
t
{
context
,
user
}
=
this
.
props
;
if
(
!
user
)
return
null
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment