app: wrap provider data in Map to avoid store (#28765)

This commit is contained in:
Brendan Allan 2026-05-22 12:23:16 +08:00 committed by GitHub
commit 1f0390cfbb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
18 changed files with 80 additions and 55 deletions

View file

@ -52,7 +52,7 @@ export function SessionContextUsage(props: SessionContextUsageProps) {
}),
)
const metrics = createMemo(() => getSessionContextMetrics(messages(), providers.all()))
const metrics = createMemo(() => getSessionContextMetrics(messages(), [...providers.all().values()]))
const context = createMemo(() => metrics().context)
const cost = createMemo(() => {
return usd().format(metrics().totalCost)