@@ -10,42 +10,21 @@ import TableHead from "@material-ui/core/TableHead"
10
10
import TableRow from "@material-ui/core/TableRow"
11
11
import Fab from "@material-ui/core/Fab"
12
12
import AddIcon from "@material-ui/icons/Add"
13
+ import AssignmentIcon from "@material-ui/icons/Assignment"
13
14
import { observer } from "mobx-react-lite"
14
15
15
- import { makeStyles } from "@material-ui/core/styles"
16
- import Popover from "@material-ui/core/Popover"
17
-
18
- const useStyles = makeStyles ( theme => ( {
19
- typography : {
20
- padding : theme . spacing ( 2 ) ,
21
- } ,
22
- } ) )
23
-
24
16
const ParticipantsList = observer ( ( ) => {
25
- const classes = useStyles ( )
26
17
const rootStore = useContext ( rootStoreContext )
27
18
const participantsStore = rootStore . ParticipantStore
28
19
const [ isLoading , setIsLoading ] = useState ( false )
29
20
30
- const [ anchorEl , setAnchorEl ] = React . useState ( null )
31
21
// useEffect is a hook that gets called after every render/re-render. Empty array second argument prevents it from running again.
32
22
useEffect ( ( ) => {
33
23
setIsLoading ( true )
34
24
participantsStore . getParticipants ( )
35
25
setIsLoading ( false )
36
26
} , [ ] )
37
27
38
- const handleClick = event => {
39
- setAnchorEl ( event . currentTarget )
40
- }
41
-
42
- const handleClose = ( ) => {
43
- setAnchorEl ( null )
44
- }
45
-
46
- const open = Boolean ( anchorEl )
47
- const id = open ? "simple-popover" : undefined
48
-
49
28
return (
50
29
< Fragment >
51
30
{ isLoading ? (
@@ -87,7 +66,7 @@ const ParticipantsList = observer(() => {
87
66
< Typography > Race</ Typography >
88
67
</ TableCell >
89
68
< TableCell >
90
- < Typography > Add </ Typography >
69
+ < Typography > Participant Details </ Typography >
91
70
</ TableCell >
92
71
</ TableRow >
93
72
</ TableHead >
@@ -116,38 +95,11 @@ const ParticipantsList = observer(() => {
116
95
< Typography > Race</ Typography >
117
96
</ TableCell >
118
97
< TableCell >
119
- < Fab
120
- color = "primary"
121
- size = "small"
122
- aria-label = "add"
123
- onClick = { handleClick }
124
- >
125
- < AddIcon />
126
- </ Fab >
127
- < Popover
128
- id = { id }
129
- open = { open }
130
- anchorEl = { anchorEl }
131
- onClose = { handleClose }
132
- anchorOrigin = { {
133
- vertical : "bottom" ,
134
- horizontal : "center" ,
135
- } }
136
- transformOrigin = { {
137
- vertical : "top" ,
138
- horizontal : "center" ,
139
- } }
140
- >
141
- < Typography className = { classes . typography } >
142
- Step
143
- </ Typography >
144
- < Typography className = { classes . typography } >
145
- Case Management
146
- </ Typography >
147
- < Typography className = { classes . typography } >
148
- Legal
149
- </ Typography >
150
- </ Popover >
98
+ < Link to = "/participantInfo" >
99
+ < Fab color = "primary" size = "small" aria-label = "add" >
100
+ < AssignmentIcon />
101
+ </ Fab >
102
+ </ Link >
151
103
</ TableCell >
152
104
</ TableRow >
153
105
) ) }
0 commit comments