import TeX from "@matejmazur/react-katex"; import {Coefs} from "../src/coefs"; import styles from "../src/css/styles.module.css"; export interface Props { title: String; isPost: boolean; coefs: Coefs; setCoefs: (coefs: Coefs) => void; } export const CoefEditor = ({title, isPost, coefs, setCoefs}: Props) => { return (

{title}

{isPost ? \alpha : 'a'}: {coefs.a}

setCoefs({...coefs, a: Number(e.currentTarget.value)})}/>

{isPost ? \beta : 'b'}: {coefs.b}

setCoefs({...coefs, b: Number(e.currentTarget.value)})}/>

{isPost ? \gamma : 'c'}: {coefs.c}

setCoefs({...coefs, c: Number(e.currentTarget.value)})}/>

{isPost ? \delta : 'd'}: {coefs.d}

setCoefs({...coefs, d: Number(e.currentTarget.value)})}/>

{isPost ? \epsilon : 'e'}: {coefs.e}

setCoefs({...coefs, e: Number(e.currentTarget.value)})}/>

{isPost ? \zeta : 'f'}: {coefs.f}

setCoefs({...coefs, f: Number(e.currentTarget.value)})}/>
) }