File tree Expand file tree Collapse file tree 3 files changed +66
-3
lines changed Expand file tree Collapse file tree 3 files changed +66
-3
lines changed Original file line number Diff line number Diff line change
1
+ @import " /src/theme/colors.scss" ;
2
+
3
+ .header {
4
+ position : fixed ;
5
+ width : 100vw ;
6
+ height : 68px ;
7
+ background : $theme-accent ;
8
+ top : 0 ;
9
+ left : 0 ;
10
+ display : flex ;
11
+ justify-content : flex-end ;
12
+ align-items : center ;
13
+
14
+ div , nav {
15
+ flex : 1 0 ;
16
+ }
17
+
18
+ div {
19
+ padding-left : 25px ;
20
+ span {
21
+ font-size : 18px ;
22
+ font-weight : bold ;
23
+ color : $accent-accent-dark ;
24
+ }
25
+ }
26
+
27
+ nav {
28
+ display : flex ;
29
+ justify-content : flex-end ;
30
+ padding-right : 25px ;
31
+ }
32
+
33
+ ul {
34
+ list-style : none ;
35
+ padding : 0 ;
36
+ li {
37
+ float : left ;
38
+ a {
39
+ display : inline-block ;
40
+ text-transform : uppercase ;
41
+ text-decoration : none ;
42
+ padding : 12px 20px ;
43
+ border : 1px transparent ;
44
+ border-radius : 8px ;
45
+ font-weight : bold ;
46
+ font-size : 14px ;
47
+ -webkit-transition : all 0.2s ease-in-out ;
48
+ -moz-transition : all 0.2s ease-in-out ;
49
+ transition : all 0.2s ease-in-out ;
50
+ & :hover {
51
+ background : $accent-accent-dark ;
52
+ color : $white ;
53
+ }
54
+ }
55
+ }
56
+ }
57
+ }
Original file line number Diff line number Diff line change 1
1
import React from "react" ;
2
2
import { Link } from "react-router-dom" ;
3
+ import styles from "./Header.module.scss" ;
3
4
4
5
// Define a header component that renders a navigation bar with links
5
6
const Header : React . FC = ( ) => {
6
7
// Return the JSX element for the header component
7
8
return (
8
- < header >
9
+ < header className = { styles . header } >
10
+ < div className = { styles . navbarBrand } >
11
+ < span > CRA Boilerplate</ span >
12
+ </ div >
9
13
< nav >
10
14
< ul >
11
15
< li >
Original file line number Diff line number Diff line change 1
- $theme-link-color : #ff5733 ;
2
- $theme-link-color-dark : #fe3e13 ;
1
+ $theme-accent : #D4ADFC ;
2
+ $accent-accent-dark : #5C469C ;
3
+ $theme-link-color : #1D267D ;
4
+ $theme-link-color-dark : #0C134F ;
3
5
$white : #ffffff ;
You can’t perform that action at this time.
0 commit comments