diff --git a/packages/ui/src/components/instance/instance-shell2.tsx b/packages/ui/src/components/instance/instance-shell2.tsx index e92b6676..5c09f786 100644 --- a/packages/ui/src/components/instance/instance-shell2.tsx +++ b/packages/ui/src/components/instance/instance-shell2.tsx @@ -923,7 +923,6 @@ const InstanceShell2: Component = (props) => { {(activeSession) => ( <> -
= (props) => { return (
-
-
- - - - - - - (rightPinned() ? unpinRightDrawer() : pinRightDrawer())} - > - {rightPinned() ? : } - - -
-
- - {t("instanceShell.rightPanel.title")} - +
+
+
+ + + + + + + (rightPinned() ? unpinRightDrawer() : pinRightDrawer())} + > + {rightPinned() ? : } + + +
+
+ + {t("instanceShell.rightPanel.title")} + +
+ + {(activeSession) => ( + + )} +
= (props) => { const { t } = useI18n() @@ -31,26 +31,16 @@ const ContextUsagePanel: Component = (props) => { const inputTokens = createMemo(() => info().inputTokens ?? 0) const outputTokens = createMemo(() => info().outputTokens ?? 0) - const actualUsageTokens = createMemo(() => info().actualUsageTokens ?? 0) - const availableTokens = createMemo(() => info().contextAvailableTokens) - const outputLimit = createMemo(() => info().modelOutputLimit ?? 0) const costValue = createMemo(() => { const value = info().isSubscriptionModel ? 0 : info().cost return value > 0 ? value : 0 }) - - const formatTokenValue = (value: number | null | undefined) => { - if (value === null || value === undefined) return t("contextUsagePanel.unavailable") - return formatTokenTotal(value) - } - const costDisplay = createMemo(() => `$${costValue().toFixed(2)}`) return ( -
+
-
{t("contextUsagePanel.headings.tokens")}
{t("contextUsagePanel.labels.input")} {formatTokenTotal(inputTokens())} @@ -64,18 +54,6 @@ const ContextUsagePanel: Component = (props) => { {costDisplay()}
- -
-
{t("contextUsagePanel.headings.context")}
-
- {t("contextUsagePanel.labels.used")} - {formatTokenTotal(actualUsageTokens())} -
-
- {t("contextUsagePanel.labels.available")} - {formatTokenValue(availableTokens())} -
-
) }