GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — claude-code-source-code/src/components/EffortIndicator.ts at main · unsignedcpp/claude-code-source-code

Expand file tree

/

EffortIndicator.ts

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
42 lines (40 loc) · 1.1 KB
/

EffortIndicator.ts

Copy path

File metadata and controls

42 lines (40 loc) · 1.1 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
import {
EFFORT_HIGH,
EFFORT_LOW,
EFFORT_MAX,
EFFORT_MEDIUM,
} from '../constants/figures.js'
import {
type EffortLevel,
type EffortValue,
getDisplayedEffortLevel,
modelSupportsEffort,
} from '../utils/effort.js'
/**
* Build the text for the effort-changed notification, e.g. "◐ medium · /effort".
* Returns undefined if the model doesn't support effort.
*/
export function getEffortNotificationText(
effortValue: EffortValue | undefined,
model: string,
): string | undefined {
if (!modelSupportsEffort(model)) return undefined
const level = getDisplayedEffortLevel(model, effortValue)
return `${effortLevelToSymbol(level)} ${level} · /effort`
}
export function effortLevelToSymbol(level: EffortLevel): string {
switch (level) {
case 'low':
return EFFORT_LOW
case 'medium':
return EFFORT_MEDIUM
case 'high':
return EFFORT_HIGH
case 'max':
return EFFORT_MAX
default:
// Defensive: level can originate from remote config. If an unknown
// value slips through, render the high symbol rather than undefined.
return EFFORT_HIGH
}
}
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.