-
+
{conversationCosts.totals.prompt.tokenCount}t
${Math.abs(conversationCosts.totals.prompt.usd).toFixed(6)}
@@ -45,20 +33,7 @@ export default function CostBar({ conversationCosts, showCostBar }: CostBarProps
-
+
{conversationCosts.totals.completion.tokenCount}t
${Math.abs(conversationCosts.totals.completion.usd).toFixed(6)}
diff --git a/client/src/components/Chat/Messages/ui/MessageRender.tsx b/client/src/components/Chat/Messages/ui/MessageRender.tsx
index c67b652e30..876675689b 100644
--- a/client/src/components/Chat/Messages/ui/MessageRender.tsx
+++ b/client/src/components/Chat/Messages/ui/MessageRender.tsx
@@ -1,5 +1,6 @@
import React, { useCallback, useMemo, memo } from 'react';
import { useRecoilValue } from 'recoil';
+import { ArrowIcon } from '@librechat/client';
import { type TMessage, TConversationCosts } from 'librechat-data-provider';
import type { TMessageProps, TMessageIcon } from '~/common';
import MessageContent from '~/components/Chat/Messages/Content/MessageContent';
@@ -178,35 +179,9 @@ const MessageRender = memo(
{perMessageCost.tokenCount > 0 && (
{perMessageCost.tokenType === 'prompt' ? (
-
+
) : (
-
+
)}
{perMessageCost.tokenCount}t
diff --git a/client/src/components/Messages/ContentRender.tsx b/client/src/components/Messages/ContentRender.tsx
index 3a5d880a74..045a39da85 100644
--- a/client/src/components/Messages/ContentRender.tsx
+++ b/client/src/components/Messages/ContentRender.tsx
@@ -1,4 +1,5 @@
import { useRecoilValue } from 'recoil';
+import { ArrowIcon } from '@librechat/client';
import { useCallback, useMemo, memo } from 'react';
import type { TMessage, TMessageContentParts, TConversationCosts } from 'librechat-data-provider';
import type { TMessageProps, TMessageIcon } from '~/common';
@@ -64,7 +65,6 @@ const ContentRender = memo(
});
const maximizeChatSpace = useRecoilValue(store.maximizeChatSpace);
const fontSize = useRecoilValue(store.fontSize);
- const convoId = conversation?.conversationId ?? '';
const perMessageCost = useMemo(() => {
if (!costs || !costs.perMessage || !msg?.messageId) {
@@ -176,35 +176,9 @@ const ContentRender = memo(
{perMessageCost.tokenCount > 0 && (
{perMessageCost.tokenType === 'prompt' ? (
-
+
) : (
-
+
)}
{perMessageCost.tokenCount}t
diff --git a/packages/client/src/svgs/ArrowIcon.tsx b/packages/client/src/svgs/ArrowIcon.tsx
new file mode 100644
index 0000000000..7307065a64
--- /dev/null
+++ b/packages/client/src/svgs/ArrowIcon.tsx
@@ -0,0 +1,42 @@
+interface ArrowIconProps {
+ direction: 'up' | 'down';
+ className?: string;
+}
+
+export default function ArrowIcon({ direction, className = 'inline' }: ArrowIconProps) {
+ if (direction === 'up') {
+ return (
+
+ );
+ }
+
+ return (
+
+ );
+}
diff --git a/packages/client/src/svgs/index.ts b/packages/client/src/svgs/index.ts
index 13a5a1cc0a..2bec1fac36 100644
--- a/packages/client/src/svgs/index.ts
+++ b/packages/client/src/svgs/index.ts
@@ -1,4 +1,5 @@
export { default as ArchiveIcon } from './ArchiveIcon';
+export { default as ArrowIcon } from './ArrowIcon';
export { default as Blocks } from './Blocks';
export { default as Plugin } from './Plugin';
export { default as GPTIcon } from './GPTIcon';