Skip to content

Commit e02f943

Browse files
committed
Navbar updates
1 parent 1bbecb8 commit e02f943

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

src/app.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,14 @@ export default function App(props) {
3030
return (
3131
<ThemeProvider theme={theme(state.selectedTheme)}>
3232
<Body>
33-
<p className="active-theme">Selected theme: {captilizeString(state.selectedTheme)}</p>
3433
<div className="container">
3534
<Header>
3635
<h1><Link to="/">Using a Local API with React Hooks & Theming</Link></h1>
3736

3837
<ul className="nav justify-content-end">
38+
<li className="nav-item">
39+
Selected theme: {captilizeString(state.selectedTheme)}
40+
</li>
3941
<li className="nav-item">
4042
<Button
4143
onClick={updateTheme}>

src/style.css

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,11 @@ a:hover, a:focus {
3535

3636
}
3737

38-
.active-theme {
38+
.nav {
3939

40-
position: absolute;
41-
right: 15px;
42-
top: 15px;
40+
position: fixed;
41+
top: 0;
42+
right: 0;
43+
padding: 0 15px;
4344

4445
}

0 commit comments

Comments
 (0)