(feat): remove homepage dev buttons
(fix): some call related bugs (qol): update todo
This commit is contained in:
parent
4f82b9c85b
commit
28a3d72fad
8 changed files with 175 additions and 29 deletions
|
|
@ -33,8 +33,6 @@ export default function Navbar({ forMobile }: { forMobile: boolean }) {
|
|||
|
||||
const isMobile = useIsMobile();
|
||||
|
||||
const [selectOpen, setSelectOpen] = useState(false);
|
||||
|
||||
const [userInfoOpen, setUserInfoOpen] = useState(false);
|
||||
|
||||
return (
|
||||
|
|
@ -86,7 +84,9 @@ export default function Navbar({ forMobile }: { forMobile: boolean }) {
|
|||
textDecorationLine: "none",
|
||||
}}
|
||||
>
|
||||
<p className="font-medium text-[1.07rem]">{user?.display}</p>
|
||||
<p className="font-medium text-[1.07rem]">
|
||||
{user?.display}
|
||||
</p>
|
||||
</Button>
|
||||
}
|
||||
/>
|
||||
|
|
@ -131,15 +131,20 @@ export default function Navbar({ forMobile }: { forMobile: boolean }) {
|
|||
</Button>
|
||||
) : (
|
||||
<>
|
||||
<Button
|
||||
onClick={() => setSelectOpen((prev) => !prev)}
|
||||
className="w-9! h-9! aspect-square rounded-lg"
|
||||
>
|
||||
<Phone />
|
||||
</Button>
|
||||
<Select onOpenChange={setSelectOpen} open={selectOpen}>
|
||||
<SelectTrigger hidden />
|
||||
<SelectContent>
|
||||
<Select>
|
||||
<SelectTrigger
|
||||
// eslint-disable-next-line
|
||||
render={({ className, ...props }) => (
|
||||
<Button
|
||||
{...props}
|
||||
className="w-9! h-9! aspect-square rounded-lg px-0! flex! justify-center!"
|
||||
variant="default"
|
||||
>
|
||||
<Phone />
|
||||
</Button>
|
||||
)}
|
||||
/>
|
||||
<SelectContent className="p-1">
|
||||
{currentCalls.map((call) => (
|
||||
<SelectItem
|
||||
value={call.call_id}
|
||||
|
|
|
|||
|
|
@ -15,27 +15,16 @@ import { useTTP } from "@tensamin/ttp";
|
|||
import { useState } from "react";
|
||||
import { Loader2 } from "lucide-react";
|
||||
import { isTauri } from "@tauri-apps/api/core";
|
||||
import { useStorage } from "@tensamin/storage/context";
|
||||
import { useSession } from "@tensamin/storage/session";
|
||||
|
||||
// The page
|
||||
export default function Page() {
|
||||
const { clear } = useStorage();
|
||||
const isMobile = useIsMobile();
|
||||
|
||||
return (
|
||||
<div className={`px-3 flex gap-2 ${!(isTauri() && isMobile) && "pt-3"}`}>
|
||||
<AddConversationButton />
|
||||
<Button disabled>Add Community</Button>
|
||||
<Button variant="outline" onClick={() => location.reload()}>
|
||||
Reload
|
||||
</Button>
|
||||
<Button
|
||||
variant="destructive"
|
||||
onClick={() => clear().then(() => location.reload())}
|
||||
>
|
||||
Logout
|
||||
</Button>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue