Fix useRef initial value for React 19 compatibility
Some checks failed
CI / go-lint (push) Has been skipped
CI / python-lint (push) Has been skipped
CI / nodejs-lint (push) Has been skipped
CI / test-go-school (push) Successful in 39s
CI / test-go-edu-search (push) Successful in 31s
CI / test-python-klausur (push) Failing after 2m33s
CI / test-python-agent-core (push) Successful in 22s
CI / test-nodejs-website (push) Successful in 26s

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Benjamin Admin
2026-04-29 16:04:43 +02:00
parent 52a15b24fe
commit a44d360cbc

View File

@@ -58,7 +58,7 @@ export default function UnitBuilder({
const [manualTarget, setManualTarget] = useState('') const [manualTarget, setManualTarget] = useState('')
const [suggestions, setSuggestions] = useState<{ source_text: string; target_text: string; pos?: string }[]>([]) const [suggestions, setSuggestions] = useState<{ source_text: string; target_text: string; pos?: string }[]>([])
const [isLookingUp, setIsLookingUp] = useState(false) const [isLookingUp, setIsLookingUp] = useState(false)
const debounceRef = useRef<ReturnType<typeof setTimeout>>() const debounceRef = useRef<ReturnType<typeof setTimeout>>(null)
// Auto-suggest translation when typing in source field // Auto-suggest translation when typing in source field
useEffect(() => { useEffect(() => {