add: generalized css classes and added a dark mode

This commit is contained in:
Lukian 2025-04-27 00:29:26 +02:00
parent 9806fc3b3c
commit 4ca8a21477
28 changed files with 101 additions and 297 deletions

View file

@ -4,8 +4,6 @@ import { Channels, User } from "../types"
import axios from "axios"
import TopBar from "../components/TopBar"
import "../styles/ChannelsPage.css"
export default function ChannelsPage({socket}: {socket: WebSocket}) {
const [channels, setChannels] = useState<Channels>();
const [search, setSearch] = useState<string>("");
@ -64,9 +62,9 @@ export default function ChannelsPage({socket}: {socket: WebSocket}) {
if (!channels) {
return (
<div className="channels-page">
<div className="forum-page">
<TopBar user={user} />
<div className="channels-page-channels">
<div className="forum-section">
<h2>Channels</h2>
<p>Loading...</p>
</div>
@ -75,9 +73,9 @@ export default function ChannelsPage({socket}: {socket: WebSocket}) {
}
return (
<div className="channels-page">
<div className="forum-page">
<TopBar user={user} />
<div className="channels-page-channels">
<div className="forum-section">
<h2>Channels</h2>
<Link to="/create-channel">Create channel</Link>
<input