From 4af45c68cc06d635edafc98c1ec3fbee2760a17c Mon Sep 17 00:00:00 2001 From: Tom Moor Date: Mon, 30 Oct 2023 22:16:38 -0400 Subject: [PATCH] Remove unused InputRich component --- app/components/InputRich.tsx | 63 ------------------------------------ 1 file changed, 63 deletions(-) delete mode 100644 app/components/InputRich.tsx diff --git a/app/components/InputRich.tsx b/app/components/InputRich.tsx deleted file mode 100644 index d4ec3f1e3..000000000 --- a/app/components/InputRich.tsx +++ /dev/null @@ -1,63 +0,0 @@ -import { observer } from "mobx-react"; -import * as React from "react"; -import { Trans } from "react-i18next"; -import styled from "styled-components"; -import Editor from "~/components/Editor"; -import { LabelText, Outline } from "~/components/Input"; -import Text from "~/components/Text"; - -type Props = { - label: string; - minHeight?: number; - maxHeight?: number; - readOnly?: boolean; -}; - -function InputRich({ label, minHeight, maxHeight, ...rest }: Props) { - const [focused, setFocused] = React.useState(false); - const handleBlur = React.useCallback(() => { - setFocused(false); - }, []); - const handleFocus = React.useCallback(() => { - setFocused(true); - }, []); - - return ( - <> - {label} - - - Loading editor… - - } - > - - - - - ); -} - -const StyledOutline = styled(Outline)<{ - minHeight?: number; - maxHeight?: number; - focused?: boolean; -}>` - display: block; - padding: 8px 12px; - min-height: ${({ minHeight }) => (minHeight ? `${minHeight}px` : "0")}; - max-height: ${({ maxHeight }) => (maxHeight ? `${maxHeight}px` : "auto")}; - overflow-y: auto; - - > * { - display: block; - } -`; - -export default observer(InputRich);