refactor: use ToolContent

This commit is contained in:
Ibrahima G. Coulibaly
2025-03-09 01:22:23 +00:00
parent a279c442ec
commit 8661fabe7d
8 changed files with 151 additions and 134 deletions

View File

@@ -25,7 +25,7 @@ interface ToolContentProps<T, I> extends ToolComponentProps {
// Tool info (optional)
toolInfo?: {
title: string;
description: string;
description?: string;
};
// Input value to pass to the compute function
@@ -66,7 +66,7 @@ export default function ToolContent<T extends FormikValues, I>({
validationSchema={validationSchema}
/>
{toolInfo && (
{toolInfo && toolInfo.title && toolInfo.description && (
<ToolInfo title={toolInfo.title} description={toolInfo.description} />
)}