Rework store

This commit is contained in:
Aslan 2026-01-02 00:14:11 +01:00
parent ef526cd2db
commit 8881070cac
9 changed files with 119 additions and 122 deletions

View file

@ -1,36 +1,13 @@
import type { Component } from "solid-js";
import { dispatch } from "../../store/state";
import { UserActionTypes } from "../../store/user";
import { AuthActionTypes } from "../../store/auth";
const MessageBar: Component = () => {
const onRefresh = () => {
dispatch({
type: AuthActionTypes.FETCH_REFRESH_START,
});
};
const onSend = () => {
dispatch({
type: UserActionTypes.FETCH_LOGGED_USER_ID_START,
});
};
return (
<div class="absolute w-full bottom-0 p-4 z-10">
<div class="bg-stone-800/25 backdrop-blur-lg h-16 shadow-bar p-2 flex flex-row gap-2 rounded-full">
<label class="bg-stone-800/50 backdrop-blur-lg input w-full h-full rounded-full focus:border-none outline-none">
<input type="text" placeholder="Send a message..." />
</label>
<button
class="bg-black/50 backdrop-blur-lg btn btn-neutral h-full rounded-full"
onClick={onRefresh}
>
Refresh test
</button>
<button
class="bg-black/50 backdrop-blur-lg btn btn-neutral h-full rounded-full"
onClick={onSend}
>
<button class="bg-black/50 backdrop-blur-lg btn btn-neutral h-full rounded-full">
Send
</button>
</div>