Fully renamed socket to ttp
This commit is contained in:
parent
7ebe028629
commit
76ca664298
13 changed files with 55 additions and 42 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import { useSocket } from "@tensamin/ttp/context";
|
||||
import { useTTP } from "@tensamin/ttp/context";
|
||||
import {
|
||||
createContext,
|
||||
useContext,
|
||||
|
|
@ -31,7 +31,7 @@ export default function ConversationProvider(props: { children: ReactNode }) {
|
|||
);
|
||||
const [communities, setCommunities] = useState<Community[] | null>(null);
|
||||
|
||||
const { send } = useSocket();
|
||||
const { send } = useTTP();
|
||||
|
||||
useEffect(() => {
|
||||
let active = true;
|
||||
|
|
|
|||
|
|
@ -148,7 +148,7 @@ export default function Screen(props: { children: React.ReactNode }) {
|
|||
return () => {
|
||||
active = false;
|
||||
};
|
||||
}, [load, location.pathname]);
|
||||
}, [load, location.pathname, userId]);
|
||||
|
||||
if (error !== "" && errorDescription !== "") {
|
||||
return <ErrorScreen error={error} description={errorDescription} />;
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import {
|
|||
} from "@tensamin/ui/cmp/dialog";
|
||||
import z from "zod";
|
||||
import { toast } from "@tensamin/shared/log";
|
||||
import { useSocket } from "@tensamin/ttp/context";
|
||||
import { useTTP } from "@tensamin/ttp/context";
|
||||
import { useState } from "react";
|
||||
import { Loader2 } from "lucide-react";
|
||||
|
||||
|
|
@ -27,7 +27,7 @@ export default function Page() {
|
|||
|
||||
// Add Conversation Button Component
|
||||
function AddConversationButton() {
|
||||
const { send } = useSocket();
|
||||
const { send } = useTTP();
|
||||
const [loading, setLoading] = useState(false);
|
||||
|
||||
function submit(username: string | null) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue