Css experimentation
This commit is contained in:
parent
757e670dbb
commit
37ff3da023
2 changed files with 7 additions and 8 deletions
|
@ -4,8 +4,8 @@ import { LoginContext, ModalContext } from "./Root";
|
|||
export function LoginForm() {
|
||||
const modal_ctx = useContext(ModalContext);
|
||||
const login_ctx = useContext(LoginContext);
|
||||
const [username, setUsername] = createSignal("");
|
||||
const [password, setPassword] = createSignal("");
|
||||
const [username, setUsername] = createSignal<string>("");
|
||||
const [password, setPassword] = createSignal<string>("");
|
||||
const [waiting, setWaiting] = createSignal(false);
|
||||
const [error, setError] = createSignal(false);
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ import { LoginForm } from "./Login";
|
|||
function Menu() {
|
||||
let login_ctx = useContext(LoginContext);
|
||||
return (
|
||||
<ul class="menu menu-horizontal bg-base-200 rounded-box space-x-2">
|
||||
<ul class="menu menu-horizontal bg-base-100 rounded-box space-x-2">
|
||||
<li>
|
||||
<A href="/" end>
|
||||
Home
|
||||
|
@ -31,21 +31,20 @@ export function Navbar() {
|
|||
let login_ctx = useContext(LoginContext);
|
||||
|
||||
return (
|
||||
<div class="navbar bg-base-100 max-w-3xl max-w flex">
|
||||
<div class="navbar text-neutral-content max-w-3xl max-w">
|
||||
<div class="flex-1">
|
||||
<A href={"/"} class="btn btn-ghost normal-case text-xl">
|
||||
FrostByte
|
||||
</A>
|
||||
</div>
|
||||
<div class="">
|
||||
<div class="hidden md:flex">
|
||||
<Menu />
|
||||
</div>
|
||||
<div class="flex-1 justify-end">
|
||||
<div class="flex-1 justify-end hidden md:flex">
|
||||
<A
|
||||
href="#"
|
||||
class="btn btn-ghost normal-case text-sm"
|
||||
onClick={(b) => {
|
||||
b.preventDefault();
|
||||
onClick={() => {
|
||||
if (login_ctx?.token() != "") {
|
||||
localStorage.setItem("token", "");
|
||||
localStorage.setItem("username", "");
|
||||
|
|
Loading…
Reference in a new issue