Skip to content

Build your personal knowledge base with Trilium Notes

chore(llm): improve tool card slightly

Elian Doran073873c33ca8
diff --git a/apps/client/src/widgets/type_widgets/llm_chat/ToolCallCard.css b/apps/client/src/widgets/type_widgets/llm_chat/ToolCallCard.css
index 0d95e00e44..9379de99fa 100644
--- a/apps/client/src/widgets/type_widgets/llm_chat/ToolCallCard.css
+++ b/apps/client/src/widgets/type_widgets/llm_chat/ToolCallCard.css
@@ -55,17 +55,13 @@
color: var(--main-text-color);
}
-.llm-chat-tool-call-input,
-.llm-chat-tool-call-result {
- margin-top: 0.5rem;
-}
-
.llm-chat-tool-call-input strong,
.llm-chat-tool-call-result strong {
display: block;
font-size: 0.75rem;
color: var(--muted-text-color);
margin-bottom: 0.25rem;
+ text-transform: uppercase;
}
.llm-chat-tool-call pre {
@@ -176,9 +172,9 @@
}
.llm-chat-tool-call-table td {
- padding: 0.25rem 0.5rem;
+ padding: 0.25rem 0;
+ padding-right: 0.75rem;
vertical-align: top;
- border-bottom: 1px solid var(--main-border-color);
}
.llm-chat-tool-call-table tr:last-child td {
@@ -188,6 +184,7 @@
.llm-chat-tool-call-table-key {
font-weight: 600;
white-space: nowrap;
+ width: 0;
color: var(--muted-text-color);
}
diff --git a/apps/client/src/widgets/type_widgets/llm_chat/ToolCallCard.tsx b/apps/client/src/widgets/type_widgets/llm_chat/ToolCallCard.tsx
index 5962fa74ff..31ddfbf1ac 100644
--- a/apps/client/src/widgets/type_widgets/llm_chat/ToolCallCard.tsx
+++ b/apps/client/src/widgets/type_widgets/llm_chat/ToolCallCard.tsx
@@ -171,12 +171,12 @@ export default function ToolCallCard({ toolCall }: { toolCall: ToolCall }) {
</summary>
<div className="llm-chat-tool-call-inline-body">
<div className="llm-chat-tool-call-input">
- <strong>{t("llm_chat.input")}:</strong>
+ <strong>{t("llm_chat.input")}</strong>
<KeyValueTable data={toolCall.input} />
</div>
{toolCall.result && (
<div className={`llm-chat-tool-call-result ${toolCall.isError ? "llm-chat-tool-call-result-error" : ""}`}>
- <strong>{toolCall.isError ? t("llm_chat.error") : t("llm_chat.result")}:</strong>
+ <strong>{toolCall.isError ? t("llm_chat.error") : t("llm_chat.result")}</strong>
<KeyValueTable data={toolCall.result} />
</div>
)}