import * as React from "bloatless-react"; import { Chat } from "../../Model/chatModel"; import { closeChatView } from "../../Model/model"; import { translation } from "../../translations"; export function ChatOptionModal(chat: Chat, isPresented: React.State) { function closeModal() { isPresented.value = false; } function deleteChat() { chat.deleteSelf(); closeModal(); closeChatView(); } const shouldShowKey = new React.State(false); const inputType = React.createProxyState([shouldShowKey], () => shouldShowKey.value == true ? "text" : "password" ); const secondaryChannelConverter: React.StateItemConverter = ( secondaryChannel ) => { function remove() { chat.removeSecondaryChannel(secondaryChannel); } return (
{secondaryChannel}
); }; return ( ); }