/* global React */ (function () { const { useState, useRef } = React; const T = window.SC_T; const _FS = 13, _LH = 1.55, _PV = 11, _PH = 13; function Textarea({ value, onChange, placeholder, rows = 7, onKeyDown, lined = false }) { const [focused, setFocused] = useState(false); const overlayRef = useRef(null); const borderStyle = { border: `1px solid ${focused ? T.accent : T.border}`, borderRadius: 10, boxShadow: focused ? `0 0 0 3px ${T.accentSoft}` : 'none', transition: 'border-color .15s ease, box-shadow .15s ease', }; const taProps = { value, placeholder, rows, spellCheck: false, onChange: (e) => onChange(e.target.value), onFocus: () => setFocused(true), onBlur: () => setFocused(false), onKeyDown, }; if (!lined) { return (