File tree Expand file tree Collapse file tree 4 files changed +31
-12
lines changed Expand file tree Collapse file tree 4 files changed +31
-12
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,6 @@ import SearchBar from '../atoms/SearchBar'
6
6
import WordWithLine from '../atoms/WordWithLine'
7
7
import GroupDmCard from '../molecules/GroupDmCard'
8
8
import UserDmCard from '../molecules/UserDmCard'
9
- import Sidebar from './NavSidebar'
10
9
11
10
const DirectMessages = ( ) => {
12
11
return (
@@ -17,7 +16,6 @@ const DirectMessages = () => {
17
16
borderBottomRightRadius = "45px"
18
17
direction = "row"
19
18
>
20
- < Sidebar />
21
19
< Flex w = "100%" justifyContent = "center" direction = "row" >
22
20
< Flex w = "85%" paddingY = "30px" direction = "column" >
23
21
< Text fontSize = "25px" color = "white" >
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ export default function DisplayNavAndPage({
12
12
return (
13
13
< Stack spacing = { 4 } direction = "row" width = "calc(100% - 20px)" >
14
14
< Box marginRight = "25px" >
15
- < NavSidebar />
15
+ < NavSidebar active = "dm" />
16
16
</ Box >
17
17
< Stack spacing = { 8 } marginTop = "15px" width = "100%" >
18
18
{ children }
Original file line number Diff line number Diff line change @@ -15,7 +15,11 @@ import { Link } from 'react-router-dom'
15
15
16
16
import { commonShadow } from '../common'
17
17
18
- export default function Sidebar ( ) {
18
+ interface navProps {
19
+ active : string
20
+ }
21
+
22
+ export default function Sidebar ( props : navProps ) {
19
23
return (
20
24
< Flex
21
25
direction = "column"
@@ -87,37 +91,54 @@ export default function Sidebar() {
87
91
>
88
92
< Link to = "/chat" >
89
93
< FontAwesomeIcon
90
- color = "# 979797"
94
+ color = { props . active === 'dm' ? '#fff' : '# 979797' }
91
95
size = "lg"
92
96
cursor = "pointer"
93
97
icon = { faComment }
98
+ style = {
99
+ props . active === 'dm'
100
+ ? { filter : 'drop-shadow(0px 0px 10px #4F80E2)' }
101
+ : { }
102
+ }
94
103
/>
95
104
</ Link >
96
-
97
105
< Link to = "/explore" >
98
106
< FontAwesomeIcon
99
- color = "# 979797"
107
+ color = { props . active === 'explore' ? '#fff' : '# 979797' }
100
108
size = "lg"
101
109
cursor = "pointer"
102
110
icon = { faCompass }
111
+ style = {
112
+ props . active === 'explore'
113
+ ? { filter : 'drop-shadow(0px 0px 10px #4F80E2)' }
114
+ : { }
115
+ }
103
116
/>
104
117
</ Link >
105
-
106
118
< Link to = "/users" >
107
119
< FontAwesomeIcon
108
- color = "# 979797"
120
+ color = { props . active === 'friends' ? '#fff' : '# 979797' }
109
121
size = "lg"
110
122
cursor = "pointer"
111
123
icon = { faUsers }
124
+ style = {
125
+ props . active === 'friends'
126
+ ? { filter : 'drop-shadow(0px 0px 10px #4F80E2)' }
127
+ : { }
128
+ }
112
129
/>
113
130
</ Link >
114
-
115
131
< Link to = "/community" >
116
132
< FontAwesomeIcon
117
- color = "# 979797"
133
+ color = { props . active === 'communities' ? '#fff' : '# 979797' }
118
134
size = "lg"
119
135
cursor = "pointer"
120
136
icon = { faGlobeAmericas }
137
+ style = {
138
+ props . active === 'communities'
139
+ ? { filter : 'drop-shadow(0px 0px 10px #4F80E2)' }
140
+ : { }
141
+ }
121
142
/>
122
143
</ Link >
123
144
</ Flex >
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ export default function Home(): JSX.Element {
12
12
return (
13
13
< Stack spacing = { 4 } direction = "row" width = "100%" >
14
14
< Box marginRight = "25px" >
15
- < NavSidebar />
15
+ < NavSidebar active = "dm" />
16
16
</ Box >
17
17
< Stack spacing = { 8 } marginTop = "15px" marginRight = "15px" width = "100%" >
18
18
< FindInterface />
You can’t perform that action at this time.
0 commit comments