Skip to content

Commit 638671e

Browse files
committed
place theme picker on the right, redo header
1 parent f7673f5 commit 638671e

File tree

7 files changed

+25
-37
lines changed

7 files changed

+25
-37
lines changed

css/style.css

Lines changed: 13 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
@import "/css/z-index.css";
33

44
body {
5-
margin: 0px;
6-
background-color: var(--background-color);
7-
/* font Arial, fall back on Helvetica */
8-
font-family: Arial, Helvetica, sans-serif;
9-
color: var(--text-color-he);
5+
margin: 0px;
6+
background-color: var(--background-color);
7+
/* font Arial, fall back on Helvetica */
8+
font-family: Arial, Helvetica, sans-serif;
9+
color: var(--text-color-he);
1010
}
1111

1212
/* HEADER */
@@ -25,16 +25,14 @@ header {
2525

2626
/* inner header div, where home button / title and navbar are */
2727
header .inner-header {
28-
/* place contents within 76% of the width of the page */
29-
margin: 0 15% 0 12%;
3028
/* needed in this element, so dropdown menu can appear outside header */
3129
overflow: hidden;
3230
}
3331

3432
/* navigation bar to the right of logo */
35-
header .inner-header nav.navbar {
33+
header nav.navbar {
3634
/* float bar to the right */
37-
float: right;
35+
float: left;
3836
}
3937

4038
/* The dropdown container, containing the navbar link as well as all sublinks */
@@ -49,7 +47,7 @@ header .dropdown {
4947
display: none;
5048
/* place just below navbar link*/
5149
position: absolute;
52-
top: 60px;
50+
top: 54px;
5351
background-color: var(--background-color-e2);
5452
color: var(--text-color-me);
5553
/* extend border of navbar links, to encompass top of .dropdown-content */
@@ -67,7 +65,7 @@ header .dropdown {
6765
/* header logo: #header-logo */
6866
/* navbar links: .navbar > a and .navbar .dropdown > a */
6967
/* dropdown content links: .dropdown-contents > a */
70-
header div.inner-header a {
68+
header a {
7169
text-align: center;
7270
padding: 12px 12px;
7371
/* remove underline usual in links */
@@ -82,6 +80,7 @@ header #header-logo {
8280
font-weight: bold;
8381
/* float left so links group side by side starting on the left */
8482
float: left;
83+
margin: 0px 45% 0px 2%;
8584
}
8685

8786
/* navbar links */
@@ -147,7 +146,7 @@ header .navbar .dropdown:hover > a.active {
147146

148147
/* theme picker container */
149148
header div#theme-picker {
150-
float: left;
149+
float: right;
151150
overflow: hidden;
152151
}
153152

@@ -163,8 +162,6 @@ header div#theme-picker button.theme-button {
163162
font-size: 18px;
164163
/* remove standard button border */
165164
border: 0px;
166-
border-bottom: 3px solid var(--background-color-e1);
167-
border-top: 3px solid var(--background-color-e1);
168165
/* opposite colors */
169166
background-color: var(--background-color-e1);
170167
color: var(--text-color-me);
@@ -180,15 +177,13 @@ header div#theme-picker div.theme-options {
180177
display: none;
181178
/* place just below navbar link*/
182179
position: absolute;
183-
top: 60px;
184-
/* right: 0px; */
180+
top: 54px;
181+
right: 0px;
185182
background-color: var(--background-color-e2);
186183
}
187184

188185
header div#theme-picker:hover button.theme-button {
189186
background-color: var(--background-color-e2);
190-
border-bottom: 3px solid var(--background-color-e2);
191-
border-top: 3px solid var(--background-color-e2);
192187
}
193188

194189
/* show theme options on hover */

index.html

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818

1919
<header>
2020
<div class="inner-header">
21+
2122
<a href="/" id="header-logo">Pedro Ângelo</a>
2223

2324
<nav class="navbar">
@@ -27,10 +28,10 @@
2728
<a href="/pages/about-me/curriculum-vitae">curriculum vitae</a>
2829
</nav>
2930
</div>
30-
3131
<a href="/pages/research">research</a>
3232
<a href="/pages/teaching">teaching</a>
3333
<a href="/pages/contact">contact</a>
34+
</nav>
3435

3536
<div id="theme-picker">
3637
<button class="theme-button">
@@ -42,11 +43,8 @@
4243
<button class="pick-theme pick-light" onclick="switchToTheme('light')"><span class="theme-icon material-symbols-outlined">brightness_high</span>light</button>
4344
<button class="pick-theme pick-dark" onclick="switchToTheme('dark')"><span class="theme-icon material-symbols-outlined">brightness_4</span>dark</button>
4445
</div>
45-
46-
4746
</div>
4847

49-
</nav>
5048
</div>
5149
</header>
5250

pages/about-me/curriculum-vitae/index.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818

1919
<header>
2020
<div class="inner-header">
21+
2122
<a href="/" id="header-logo">Pedro Ângelo</a>
2223

2324
<nav class="navbar">
@@ -27,10 +28,10 @@
2728
<a href="/pages/about-me/curriculum-vitae" class="active">curriculum vitae</a>
2829
</nav>
2930
</div>
30-
3131
<a href="/pages/research">research</a>
3232
<a href="/pages/teaching">teaching</a>
3333
<a href="/pages/contact">contact</a>
34+
</nav>
3435

3536
<div id="theme-picker">
3637
<button class="theme-button">
@@ -42,10 +43,8 @@
4243
<button class="pick-theme pick-light" onclick="switchToTheme('light')"><span class="theme-icon material-symbols-outlined">brightness_high</span>light</button>
4344
<button class="pick-theme pick-dark" onclick="switchToTheme('dark')"><span class="theme-icon material-symbols-outlined">brightness_4</span>dark</button>
4445
</div>
45-
4646
</div>
4747

48-
</nav>
4948
</div>
5049
</header>
5150

pages/about-me/index.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818

1919
<header>
2020
<div class="inner-header">
21+
2122
<a href="/" id="header-logo">Pedro Ângelo</a>
2223

2324
<nav class="navbar">
@@ -27,10 +28,10 @@
2728
<a href="/pages/about-me/curriculum-vitae">curriculum vitae</a>
2829
</nav>
2930
</div>
30-
3131
<a href="/pages/research">research</a>
3232
<a href="/pages/teaching">teaching</a>
3333
<a href="/pages/contact">contact</a>
34+
</nav>
3435

3536
<div id="theme-picker">
3637
<button class="theme-button">
@@ -42,10 +43,8 @@
4243
<button class="pick-theme pick-light" onclick="switchToTheme('light')"><span class="theme-icon material-symbols-outlined">brightness_high</span>light</button>
4344
<button class="pick-theme pick-dark" onclick="switchToTheme('dark')"><span class="theme-icon material-symbols-outlined">brightness_4</span>dark</button>
4445
</div>
45-
4646
</div>
4747

48-
</nav>
4948
</div>
5049
</header>
5150

pages/contact/index.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818

1919
<header>
2020
<div class="inner-header">
21+
2122
<a href="/" id="header-logo">Pedro Ângelo</a>
2223

2324
<nav class="navbar">
@@ -27,10 +28,10 @@
2728
<a href="/pages/about-me/curriculum-vitae">curriculum vitae</a>
2829
</nav>
2930
</div>
30-
3131
<a href="/pages/research">research</a>
3232
<a href="/pages/teaching">teaching</a>
3333
<a href="/pages/contact" class="active">contact</a>
34+
</nav>
3435

3536
<div id="theme-picker">
3637
<button class="theme-button">
@@ -42,10 +43,8 @@
4243
<button class="pick-theme pick-light" onclick="switchToTheme('light')"><span class="theme-icon material-symbols-outlined">brightness_high</span>light</button>
4344
<button class="pick-theme pick-dark" onclick="switchToTheme('dark')"><span class="theme-icon material-symbols-outlined">brightness_4</span>dark</button>
4445
</div>
45-
4646
</div>
4747

48-
</nav>
4948
</div>
5049
</header>
5150

pages/research/index.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919

2020
<header>
2121
<div class="inner-header">
22+
2223
<a href="/" id="header-logo">Pedro Ângelo</a>
2324

2425
<nav class="navbar">
@@ -28,10 +29,10 @@
2829
<a href="/pages/about-me/curriculum-vitae">curriculum vitae</a>
2930
</nav>
3031
</div>
31-
3232
<a href="/pages/research" class="active">research</a>
3333
<a href="/pages/teaching">teaching</a>
3434
<a href="/pages/contact">contact</a>
35+
</nav>
3536

3637
<div id="theme-picker">
3738
<button class="theme-button">
@@ -43,10 +44,8 @@
4344
<button class="pick-theme pick-light" onclick="switchToTheme('light')"><span class="theme-icon material-symbols-outlined">brightness_high</span>light</button>
4445
<button class="pick-theme pick-dark" onclick="switchToTheme('dark')"><span class="theme-icon material-symbols-outlined">brightness_4</span>dark</button>
4546
</div>
46-
4747
</div>
4848

49-
</nav>
5049
</div>
5150
</header>
5251

pages/teaching/index.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818

1919
<header>
2020
<div class="inner-header">
21+
2122
<a href="/" id="header-logo">Pedro Ângelo</a>
2223

2324
<nav class="navbar">
@@ -27,10 +28,10 @@
2728
<a href="/pages/about-me/curriculum-vitae">curriculum vitae</a>
2829
</nav>
2930
</div>
30-
3131
<a href="/pages/research">research</a>
3232
<a href="/pages/teaching" class="active">teaching</a>
3333
<a href="/pages/contact">contact</a>
34+
</nav>
3435

3536
<div id="theme-picker">
3637
<button class="theme-button">
@@ -42,10 +43,8 @@
4243
<button class="pick-theme pick-light" onclick="switchToTheme('light')"><span class="theme-icon material-symbols-outlined">brightness_high</span>light</button>
4344
<button class="pick-theme pick-dark" onclick="switchToTheme('dark')"><span class="theme-icon material-symbols-outlined">brightness_4</span>dark</button>
4445
</div>
45-
4646
</div>
4747

48-
</nav>
4948
</div>
5049
</header>
5150

0 commit comments

Comments
 (0)