Skip to content

Commit 049c47f

Browse files
committed
fix: Cursor 사용량 모델 라벨 축약
1 parent 3640561 commit 049c47f

9 files changed

Lines changed: 33 additions & 19 deletions

File tree

‎docs/reference/cursor-usage-tracking.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ Cursor's two included model pools are named `buckets` (not Session/Weekly labels
2626
| Orca field | Cursor source |
2727
|------------|----------------|
2828
| `monthly` | always `null` |
29-
| `buckets` | wire names `Auto` ← `autoPercentUsed`, `API` ← `apiPercentUsed`, `On-demand` ← `onDemand.used / limit` when enabled; UI shows `Cursor Models` and `Other Models` |
29+
| `buckets` | wire names `Auto` ← `autoPercentUsed`, `API` ← `apiPercentUsed`, `On-demand` ← `onDemand.used / limit` when enabled; UI shows `Cursor` and `Other` |
3030
| `session` / `weekly` | always `null` |
3131
| Reset | `billingCycleEnd` |
3232
| Auth label | cached email, `/api/auth/me`, or membership type |

‎src/renderer/src/components/settings/CursorAccountsSection.tsx‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ export function CursorAccountsSection(): React.JSX.Element {
176176
)}
177177
description={translate(
178178
'auto.components.settings.CursorAccountsSection.b7e2d9f0a3',
179-
'Cursor Models, Other Models, and on-demand usage from the Cursor dashboard.'
179+
'Cursor, Other, and on-demand usage from the Cursor dashboard.'
180180
)}
181181
keywords={['cursor', 'usage', 'subscription', 'plan', 'models', 'on-demand']}
182182
>
@@ -185,7 +185,7 @@ export function CursorAccountsSection(): React.JSX.Element {
185185
<Badge variant="secondary" className="tabular-nums">
186186
{translate(
187187
'auto.components.settings.CursorAccountsSection.e4f1c8d2b0',
188-
'Cursor Models {{pct}}%',
188+
'Cursor {{pct}}%',
189189
{ pct: String(Math.round(cursorModelsBucket.usedPercent)) }
190190
)}
191191
</Badge>
@@ -194,7 +194,7 @@ export function CursorAccountsSection(): React.JSX.Element {
194194
<Badge variant="secondary" className="tabular-nums">
195195
{translate(
196196
'auto.components.settings.CursorAccountsSection.f3a2d9e1c7',
197-
'Other Models {{pct}}%',
197+
'Other {{pct}}%',
198198
{ pct: String(Math.round(otherModelsBucket.usedPercent)) }
199199
)}
200200
</Badge>

‎src/renderer/src/components/stats/CursorUsagePane.test.tsx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,9 +113,9 @@ describe('CursorUsagePane', () => {
113113
render(<CursorUsagePane />)
114114

115115
expect(screen.getByTestId('cursor-usage-pane')).toBeInTheDocument()
116-
expect(screen.getByText('Cursor Models')).toBeInTheDocument()
116+
expect(screen.getByText('Cursor')).toBeInTheDocument()
117117
expect(screen.getByText('45%')).toBeInTheDocument()
118-
expect(screen.getByText('Other Models')).toBeInTheDocument()
118+
expect(screen.getByText('Other')).toBeInTheDocument()
119119
expect(screen.getByText('30%')).toBeInTheDocument()
120120
expect(screen.getByText('On-demand')).toBeInTheDocument()
121121
expect(screen.getByText('20%')).toBeInTheDocument()

‎src/renderer/src/components/stats/CursorUsagePane.tsx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,12 @@ export function CursorUsagePane(): React.JSX.Element {
133133

134134
<div className="grid gap-3 md:grid-cols-2 xl:grid-cols-4">
135135
<StatCard
136-
label={translate('auto.components.stats.CursorUsagePane.a8b9c0d1e2', 'Cursor Models')}
136+
label={translate('auto.components.stats.CursorUsagePane.a8b9c0d1e2', 'Cursor')}
137137
value={cursorModelsPercent !== null ? `${cursorModelsPercent}%` : '—'}
138138
icon={<Sparkles className="size-4" />}
139139
/>
140140
<StatCard
141-
label={translate('auto.components.stats.CursorUsagePane.b9c0d1e2f3', 'Other Models')}
141+
label={translate('auto.components.stats.CursorUsagePane.b9c0d1e2f3', 'Other')}
142142
value={otherModelsPercent !== null ? `${otherModelsPercent}%` : '—'}
143143
icon={<Sparkles className="size-4" />}
144144
/>

‎src/renderer/src/components/status-bar/provider-segment-monthly-window.test.tsx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,9 +203,9 @@ describe('ProviderSegment monthly window', () => {
203203
<ProviderSegment p={limits} compact={false} display="used" mode="verbose" />
204204
)
205205

206-
expect(markup).toContain('Cursor Models')
206+
expect(markup).toContain('Cursor')
207207
expect(markup).toContain('45% used')
208-
expect(markup).toContain('Other Models')
208+
expect(markup).toContain('Other')
209209
expect(markup).toContain('30% used')
210210
})
211211
})

‎src/renderer/src/components/status-bar/tooltip.test.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -352,8 +352,8 @@ describe('getWindowSections', () => {
352352
status: 'ok'
353353
}
354354
expect(getWindowSections(p)).toEqual([
355-
{ label: 'Cursor Models', window: p.buckets![0] },
356-
{ label: 'Other Models', window: p.buckets![1] }
355+
{ label: 'Cursor', window: p.buckets![0] },
356+
{ label: 'Other', window: p.buckets![1] }
357357
])
358358
})
359359

‎src/renderer/src/i18n/locales/en.json‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4085,8 +4085,8 @@
40854085
"d8e9f0a1b2": " • {{value0}}",
40864086
"e9f0a1b2c3": "Refresh Cursor usage",
40874087
"f0a1b2c3d4": "Refresh",
4088-
"a8b9c0d1e2": "Cursor Models",
4089-
"b9c0d1e2f3": "Other Models",
4088+
"a8b9c0d1e2": "Cursor",
4089+
"b9c0d1e2f3": "Other",
40904090
"c0d1e2f3a4": "On-demand",
40914091
"b2c3d4e5f6": "Billing period reset",
40924092
"c3d4e5f6a7": "Cursor account settings"
@@ -10602,10 +10602,10 @@
1060210602
"f6a7b8c9d0": "Open Cursor and sign in, then click Refresh usage here.",
1060310603
"3325d996cb": "Refresh usage",
1060410604
"a8f3e2c1b4": "Plan usage",
10605-
"b7e2d9f0a3": "Cursor Models, Other Models, and on-demand usage from the Cursor dashboard.",
10605+
"b7e2d9f0a3": "Cursor, Other, and on-demand usage from the Cursor dashboard.",
1060610606
"c6d1a8f4e2": "Resets {{when}}",
10607-
"e4f1c8d2b0": "Cursor Models {{pct}}%",
10608-
"f3a2d9e1c7": "Other Models {{pct}}%",
10607+
"e4f1c8d2b0": "Cursor {{pct}}%",
10608+
"f3a2d9e1c7": "Other {{pct}}%",
1060910609
"0a1b2c3d4e": "On-demand {{pct}}%"
1061010610
},
1061110611
"AppearanceWindowSidebarSection": {
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
import { describe, expect, it } from 'vitest'
2+
import { getUsageBucketDisplayName } from './cursor-usage-buckets'
3+
4+
describe('getUsageBucketDisplayName', () => {
5+
it('uses compact Cursor labels', () => {
6+
expect(getUsageBucketDisplayName('cursor', 'Auto')).toBe('Cursor')
7+
expect(getUsageBucketDisplayName('cursor', 'API')).toBe('Other')
8+
})
9+
10+
it('preserves unknown bucket labels', () => {
11+
expect(getUsageBucketDisplayName('cursor', 'On-demand')).toBe('On-demand')
12+
expect(getUsageBucketDisplayName('gemini', 'Pro')).toBe('Pro')
13+
})
14+
})

‎src/shared/cursor-usage-buckets.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ export function getUsageBucketDisplayName(
1212
return bucketName
1313
}
1414
if (bucketName === CURSOR_MODELS_BUCKET_NAME) {
15-
return 'Cursor Models'
15+
return 'Cursor'
1616
}
1717
if (bucketName === OTHER_MODELS_BUCKET_NAME) {
18-
return 'Other Models'
18+
return 'Other'
1919
}
2020
return bucketName
2121
}

0 commit comments

Comments
 (0)