diff --git a/src/Chat/Chat.tsx b/src/Chat/Chat.tsx index 1aa884a..1d50239 100644 --- a/src/Chat/Chat.tsx +++ b/src/Chat/Chat.tsx @@ -13,6 +13,10 @@ import strings from "../Intl/strings.json"; import { LangContext } from "../context"; import { connectionAddress, endpoints } from "../consts"; const Chat = ({ user }: { user: string }): React.ReactElement => { + const encryptMessage = (plaintext: string) => { + const ciphertext = plaintext; + return ciphertext; + } const lang = useContext(LangContext); const chatPage = strings[lang].chat; const [messages, setMessages] = useState([]); @@ -78,7 +82,7 @@ const Chat = ({ user }: { user: string }): React.ReactElement => { type: MessageType.MESSAGE, fromUserId: user, toUserId: "everyone", - content: entryElement.value, + content: encryptMessage(entryElement.value), timeMillis: Date.now(), }; console.log( diff --git a/src/Sidebar/Sidebar.tsx b/src/Sidebar/Sidebar.tsx index ea5dfed..ef154c3 100644 --- a/src/Sidebar/Sidebar.tsx +++ b/src/Sidebar/Sidebar.tsx @@ -1,4 +1,3 @@ -import { useState } from "react"; import "./Sidebar.css"; import { SidebarMenu } from "./Components/SidebarMenu"; export const Sidebar = ({