@@ -22,19 +22,19 @@ function Chat({ id, users, mh }) {
2222 router . push ( `/chat/${ id } ` ) ;
2323 } ;
2424
25- const openMenu = ( e ) => {
26- var x = e . clientX - e . target . offsetLeft + 10 ;
27- var y = e . clientY - e . target . offsetTop + 10 ;
28- // console.log(e.target);
29- const menu = document . querySelector ( '.mc' ) ;
30- menu . style . bottom = `${ y } px` ;
31- menu . style . left = `${ x } px` ;
32- if ( menu . style . display === 'none' ) {
33- menu . style . display = 'flex' ;
34- } else {
35- menu . style . display = 'none' ;
36- }
37- } ;
25+ // const openMenu = (e) => {
26+ // var x = e.clientX - e.target.offsetLeft + 10;
27+ // var y = e.clientY - e.target.offsetTop + 10;
28+ // // console.log(e.target);
29+ // const menu = document.querySelector('.mc');
30+ // menu.style.bottom = `${y}px`;
31+ // menu.style.left = `${x}px`;
32+ // if (menu.style.display === 'none') {
33+ // menu.style.display = 'flex';
34+ // } else {
35+ // menu.style.display = 'none';
36+ // }
37+ // };
3838
3939 const userChatRef = db
4040 . collection ( 'users' )
@@ -67,8 +67,8 @@ function Chat({ id, users, mh }) {
6767 fontSize : 25 ,
6868 opacity : '0.6' ,
6969 } }
70- onClick = { ( e ) => openMenu ( e ) }
7170 />
71+ { /* onClick={(e) => openMenu(e)} */ }
7272 </ ArrowContainer >
7373
7474 < MenuContainer className = "mc" >
0 commit comments