diff --git a/src/app/components/generator/McdocRenderer.tsx b/src/app/components/generator/McdocRenderer.tsx
index 222f44d4..c382bfa0 100644
--- a/src/app/components/generator/McdocRenderer.tsx
+++ b/src/app/components/generator/McdocRenderer.tsx
@@ -9,6 +9,7 @@ import { simplify } from '@spyglassmc/mcdoc/lib/runtime/checker/index.js'
import { getValues } from '@spyglassmc/mcdoc/lib/runtime/completer/index.js'
import { useCallback, useMemo } from 'preact/hooks'
import { useLocale } from '../../contexts/Locale.jsx'
+import { useFocus } from '../../hooks/useFocus.js'
import { generateColor, hexId } from '../../Utils.js'
import { Octicon } from '../Octicon.jsx'
@@ -22,14 +23,17 @@ interface Props {
ctx: McdocContext
}
export function McdocRoot({ node, makeEdit, ctx } : Props) {
+ const { locale } = useLocale()
const type = node?.typeDef ?? { kind: 'unsafe' }
- if (type.kind === 'struct') {
+ if (type.kind === 'struct' && JsonObjectNode.is(node)) {
return