@devries-cameron20 / t3code-1 / commits / c3608512f0
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

fix(web): center usage models without a breakdown bar (#21247)

Co-authored-by: Julius Marminge <julius0216@outlook.com>

Afonso Ferreira committed Oct 20, 2026 at 05:16 UTC c3608512f0fc453152fc18190a26a0ef83bac7b5
1 file changed +16 -13
apps/web/src/components/usage/UsagePage.tsx
+16 -13
@@ -946,6 +946,7 @@ function UsageOverview({
946 breakdownModels.map((model, index) => {
947 const key = `${model.provider}:${model.model}`;
948 const value = metric === "tokens" ? model.totalTokens : model.costUsd;
949 + const hasBar = value > 0 && breakdownPeak > 0;
950 const share = modelShare(model, metric === "tokens" ? "tokens" : "cost");
951 const rowFigures = figureClass(loadingProviders.has(model.provider));
952 return (
@@ -958,23 +959,25 @@ function UsageOverview({
959 <button
960 type="button"
961 onClick={() => onSelectModel(key)}
961 - className="flex items-center gap-2 text-left text-foreground outline-none after:absolute after:inset-0"
962 + className={cn(
963 + "flex items-center gap-2 text-left text-foreground outline-none after:absolute after:inset-0",
964 + !hasBar && "py-1",
965 + )}
966 >
967 <ProviderMark provider={model.provider} className="size-3.5" />
968 {model.model}
969 </button>
966 - <div aria-hidden className={cn("mt-1.5 h-0.5 max-w-48", rowFigures)}>
967 - <div
968 - className="h-full rounded-full"
969 - style={{
970 - width:
971 - value > 0 && breakdownPeak > 0
972 - ? `max(0.5rem, ${(value / breakdownPeak) * 100}%)`
973 - : 0,
974 - backgroundColor: PROVIDER_PRESENTATION[model.provider].color,
975 - }}
976 - />
977 - </div>
970 + {hasBar ? (
971 + <div aria-hidden className={cn("mt-1.5 h-0.5 max-w-48", rowFigures)}>
972 + <div
973 + className="h-full rounded-full"
974 + style={{
975 + width: `max(0.5rem, ${(value / breakdownPeak) * 100}%)`,
976 + backgroundColor: PROVIDER_PRESENTATION[model.provider].color,
977 + }}
978 + />
979 + </div>
980 + ) : null}
981 </td>
982 <td className={cn("py-2.5 pl-6 text-foreground", rowFigures)}>
983 {isModelCostUnknown(model) ? (