Fix hiding too much from the tree

This commit is contained in:
Misode
2022-02-26 22:24:12 +01:00
parent b5ddb9666b
commit 9f49736ae9

View File

@@ -288,7 +288,6 @@ const renderHtml: RenderHook = {
const context = cPath.getContext().join('.')
if (hiddenFields.includes(context)) return null
const [cPrefix, cSuffix, cBody] = child.hook(this, cPath, value[key], lang, version, states, newCtx)
if (!cPrefix && !cSuffix && !((cBody?.props?.children?.length ?? 0) > 0)) return null
const isFlattened = child.type(cPath) === 'object' && flattenedFields.includes(context)
const isInlined = inlineFields.includes(context)
if (isFlattened || isInlined) {