diff --git a/src/lib/output/themes/default/partials/hierarchy.tsx b/src/lib/output/themes/default/partials/hierarchy.tsx index 3d35c73e0..47a3b11c7 100644 --- a/src/lib/output/themes/default/partials/hierarchy.tsx +++ b/src/lib/output/themes/default/partials/hierarchy.tsx @@ -2,13 +2,20 @@ import type { DefaultThemeRenderContext } from "../DefaultThemeRenderContext"; import { JSX } from "../../../../utils"; import type { DeclarationHierarchy } from "../../../../models"; -export const hierarchy = (context: DefaultThemeRenderContext, props: DeclarationHierarchy) => ( - +export const hierarchy = (context: DefaultThemeRenderContext, props: DeclarationHierarchy | undefined) => ( + <> + {!!props && ( +
+

Hierarchy

+ +
+ )} + ); diff --git a/src/lib/output/themes/default/partials/typeParameters.tsx b/src/lib/output/themes/default/partials/typeParameters.tsx index 558b8e9de..fa4065a41 100644 --- a/src/lib/output/themes/default/partials/typeParameters.tsx +++ b/src/lib/output/themes/default/partials/typeParameters.tsx @@ -4,28 +4,33 @@ import { JSX } from "../../../../utils"; export function typeParameters(context: DefaultThemeRenderContext, typeParameters: TypeParameterReflection[]) { return ( - + <> +
+

Type Parameters

+ +
+ ); } diff --git a/src/lib/output/themes/default/templates/reflection.tsx b/src/lib/output/themes/default/templates/reflection.tsx index 2899e6ae3..183e66df9 100644 --- a/src/lib/output/themes/default/templates/reflection.tsx +++ b/src/lib/output/themes/default/templates/reflection.tsx @@ -16,20 +16,11 @@ export function reflectionTemplate(context: DefaultThemeRenderContext, props: Pa
{context.comment(props.model)}
)} - {hasTypeParameters(props.model) && ( -
-

Type Parameters

- {context.typeParameters(props.model.typeParameters)} -
- )} + {hasTypeParameters(props.model) && <> {context.typeParameters(props.model.typeParameters)} } {props.model instanceof DeclarationReflection && ( <> - {!!props.model.typeHierarchy && ( -
-

Hierarchy

- {context.hierarchy(props.model.typeHierarchy)} -
- )} + {context.hierarchy(props.model.typeHierarchy)} + {!!props.model.implementedTypes && (

Implements