Skip to content

Commit 06b8e04

Browse files
committed
implement LoginandLogout component
1 parent 62f1a53 commit 06b8e04

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

client/src/App.jsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ const socket = io("http://localhost:8000");
77
import Header from "./components/Header";
88
import Toolbar from "./components/Toolbar";
99
import Socials from "./components/Socials";
10+
import LoginAndLogout from "./components/LoginAndLogout";
1011

1112
function App() {
1213
const canvasRef = useRef(null);
@@ -119,7 +120,7 @@ function App() {
119120
<div id="container" style={{ display: "flex" }}>
120121
<div
121122
id="sidebar"
122-
className="flex flex-col w-64 bg-zinc-800"
123+
className="flex flex-col w-64 bg-zinc-800 relative"
123124
ref={sidebarRef}
124125
>
125126
<Header></Header>
@@ -128,6 +129,7 @@ function App() {
128129
<button id="clear" onClick={clearOnClick}>
129130
Clear
130131
</button>
132+
<LoginAndLogout></LoginAndLogout>
131133
</div>
132134
<div className="canvas-container">
133135
<canvas className="canvas" ref={canvasRef}></canvas>

client/src/assets/user-dp.jpg

60.2 KB
Loading
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import UserDP from "../assets/user-dp.jpg";
2+
3+
function LoginAndLogout() {
4+
return (
5+
<div className="flex py-3 rounded-lg justify-around mt-55 bg-gradient-to-r from-indigo-500 from-10% via-sky-500 via-30% to-emerald-500 to-90% w-full items-center bottom-0 absolute">
6+
<h1 className="font-sans text-lg antialiased font-semibold text-white">
7+
Ajeet
8+
</h1>
9+
<img
10+
src={UserDP}
11+
className="rounded-full object-cover h-8 w-8 ml-4"
12+
></img>
13+
</div>
14+
);
15+
}
16+
17+
export default LoginAndLogout;

0 commit comments

Comments
 (0)