diff options
author | Parker <contact@pkrm.dev> | 2024-11-16 00:28:25 -0600 |
---|---|---|
committer | Parker <contact@pkrm.dev> | 2024-11-16 00:28:25 -0600 |
commit | 76b9da8bd3d51300c00eed45aef43db1c595d71f (patch) | |
tree | 9a54f5099e2e02de8c02cf83350d50bcf08789f0 | |
parent | 4d69b23c90048e22d3886a25637ff643a3c0239e (diff) |
Smaller log text + transform date
-rw-r--r-- | app/src/components/Dashboard.tsx | 12 | ||||
-rw-r--r-- | app/src/styles/Dashboard.module.css | 1 |
2 files changed, 11 insertions, 2 deletions
diff --git a/app/src/components/Dashboard.tsx b/app/src/components/Dashboard.tsx index d2bca9e..d699efb 100644 --- a/app/src/components/Dashboard.tsx +++ b/app/src/components/Dashboard.tsx @@ -175,7 +175,7 @@ function Dashboard() { {logs.filter((log) => log.link === link.link).length || 0} </td> <td>{link.redirect_link}</td> - <td>{link.expire_date}</td> + <td>{new Date(link.expire_date).toLocaleDateString()}</td> </tr> {/* Conditionally render logs for this link */} @@ -199,7 +199,15 @@ function Dashboard() { .map((log, index, filteredLogs) => ( <tr key={log.id}> <td>{filteredLogs.length - index}</td> - <td>{log.timestamp}</td> + <td> + {new Date( + log.timestamp + ).toLocaleTimeString() + + ', ' + + new Date( + log.timestamp + ).toLocaleDateString()} + </td> <td>{log.ip}</td> <td>{log.location}</td> <td>{log.isp}</td> diff --git a/app/src/styles/Dashboard.module.css b/app/src/styles/Dashboard.module.css index bfc852e..fbc1d6d 100644 --- a/app/src/styles/Dashboard.module.css +++ b/app/src/styles/Dashboard.module.css @@ -87,6 +87,7 @@ table td { .logTableRow table td { background-color: #3b4148; padding: 10px; + font-size: 17px; } .logTableRow table tr { |