VS Code preview Full workbench mockup using this variant's colors and tokenColors.
fetchUser.tssrc/components index.ts README.md
src
components fetchUser.ts Button.tsx Modal.tsx legacy.tsx fetch Config.tsindex.ts renamed.ts staged.ts removed.ts
vendor package.json broken.ts slow.ts tsconfig.json README.md package-lock.json 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
export interface User {
id : string ;
name : string ;
role : "admin" | "member" ;
tags : string [];
}
/**
* Fetch user data by ID
* @ param id
* @ returns User object or null if ID is invalid
*/
export async function fetchUser ( id : string ) : Promise < User | null > {
if ( ! id) {
return null ;
}
const response = await fetch ( `/api/users/ ${ id } ` , {
method : "GET" ,
headers : { Accept : "application/json" },
});
if ( ! response . ok ) {
throw new Error ( `HTTP ${ response . status } ` );
}
return ( await response . json ()) as User ;
}
function greet ( user : User ) : string {
// Simple greeting function that uses the user's name
return `Hello, ${ user . name } !` ;
}
Problems1
Output
Debug Console
Terminal
Ports
✓ fetchUser passed 12 blk
✗ Cannot find name 'user'. error ▲ warning 412 ready localhost
Ln 5, Col 12
Spaces: 2
UTF-8
LF
TypeScript
One Dark Operator Theme
colors Workbench UI color keys from the theme JSON colors map.
key HEX RGB RGBA activityBar.background
#333842 RGB(51, 56, 66) RGBA(51, 56, 66, 1) activityBar.foreground
#D7DAE0 RGB(215, 218, 224) RGBA(215, 218, 224, 1) activityBarBadge.background
#528BFF RGB(82, 139, 255) RGBA(82, 139, 255, 1) activityBarBadge.foreground
#D7DAE0 RGB(215, 218, 224) RGBA(215, 218, 224, 1) button.background
#4D78CC RGB(77, 120, 204) RGBA(77, 120, 204, 1) button.foreground
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) button.hoverBackground
#6087CF RGB(96, 135, 207) RGBA(96, 135, 207, 1) diffEditor.insertedTextBackground
#00809B33 RGB(0, 128, 155) RGBA(0, 128, 155, 0.2) dropdown.background
#43484D RGB(67, 72, 77) RGBA(67, 72, 77, 1) dropdown.border
#181A1F RGB(24, 26, 31) RGBA(24, 26, 31, 1) editor.background
#282C34 RGB(40, 44, 52) RGBA(40, 44, 52, 1) editor.lineHighlightBackground
#2C313A RGB(44, 49, 58) RGBA(44, 49, 58, 1) editor.selectionBackground
#3E4451 RGB(62, 68, 81) RGBA(62, 68, 81, 1) editorCursor.foreground
#528BFF RGB(82, 139, 255) RGBA(82, 139, 255, 1) editorGroup.background
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) editorGroup.border
#181A1F RGB(24, 26, 31) RGBA(24, 26, 31, 1) editorGroupHeader.tabsBackground
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) editorHoverWidget.background
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) editorHoverWidget.border
#181A1F RGB(24, 26, 31) RGBA(24, 26, 31, 1) editorIndentGuide.background
#3C4049 RGB(60, 64, 73) RGBA(60, 64, 73, 1) editorLineNumber.foreground
#636D83 RGB(99, 109, 131) RGBA(99, 109, 131, 1) editorSuggestWidget.background
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) editorSuggestWidget.border
#181A1F RGB(24, 26, 31) RGBA(24, 26, 31, 1) editorSuggestWidget.selectedBackground
#2C313A RGB(44, 49, 58) RGBA(44, 49, 58, 1) editorWhitespace.foreground
#3C4049 RGB(60, 64, 73) RGBA(60, 64, 73, 1) editorWidget.background
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) focusBorder
#528BFF RGB(82, 139, 255) RGBA(82, 139, 255, 1) input.background
#1B1D23 RGB(27, 29, 35) RGBA(27, 29, 35, 1) input.border
#181A1F RGB(24, 26, 31) RGBA(24, 26, 31, 1) list.activeSelectionBackground
#2C313A RGB(44, 49, 58) RGBA(44, 49, 58, 1) list.activeSelectionForeground
#D7DAE0 RGB(215, 218, 224) RGBA(215, 218, 224, 1) list.focusBackground
#2C313A RGB(44, 49, 58) RGBA(44, 49, 58, 1) list.highlightForeground
#D7DAE0 RGB(215, 218, 224) RGBA(215, 218, 224, 1) list.hoverBackground
#2C313A RGB(44, 49, 58) RGBA(44, 49, 58, 1) list.inactiveSelectionBackground
#2C313A RGB(44, 49, 58) RGBA(44, 49, 58, 1) list.inactiveSelectionForeground
#D7DAE0 RGB(215, 218, 224) RGBA(215, 218, 224, 1) pickerGroup.border
#528BFF RGB(82, 139, 255) RGBA(82, 139, 255, 1) scrollbarSlider.activeBackground
#747D9180 RGB(116, 125, 145) RGBA(116, 125, 145, 0.502) scrollbarSlider.background
#4E566680 RGB(78, 86, 102) RGBA(78, 86, 102, 0.502) scrollbarSlider.hoverBackground
#5A637580 RGB(90, 99, 117) RGBA(90, 99, 117, 0.502) sideBar.background
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) sideBarSectionHeader.background
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) statusBar.background
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) statusBar.debuggingForeground
#FFFFFF RGB(255, 255, 255) RGBA(255, 255, 255, 1) statusBar.foreground
#9DA5B4 RGB(157, 165, 180) RGBA(157, 165, 180, 1) statusBar.noFolderBackground
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) statusBarItem.hoverBackground
#2C313A RGB(44, 49, 58) RGBA(44, 49, 58, 1) tab.activeBackground
#282C34 RGB(40, 44, 52) RGBA(40, 44, 52, 1) tab.border
#181A1F RGB(24, 26, 31) RGBA(24, 26, 31, 1) tab.inactiveBackground
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) titleBar.activeBackground
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) titleBar.activeForeground
#9DA5B4 RGB(157, 165, 180) RGBA(157, 165, 180, 1) titleBar.inactiveBackground
#21252B RGB(33, 37, 43) RGBA(33, 37, 43, 1) titleBar.inactiveForeground
#9DA5B4 RGB(157, 165, 180) RGBA(157, 165, 180, 1)
tokenColors Foregrounds this theme assigns to the token scope catalog. A rule with only a font style is skipped, and a longer matching scope wins. Italic and bold rules are not listed — the preview above shows them in the code.
scope HEX RGB RGBA comment
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) comment.block
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) comment.block.documentation
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) comment.line
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) constant
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) constant.character
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) constant.character.escape
#56B6C2 RGB(86, 182, 194) RGBA(86, 182, 194, 1) constant.numeric
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.numeric.integer
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.numeric.float
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.numeric.hex
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.numeric.octal
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) constant.other
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) constant.other.placeholder
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) constant.regexp
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) constant.rgb-value
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) entity
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name.class
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.name.function
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name.method
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name.namespace
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name.section
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name.selector
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.name.tag
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) entity.name.type
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.name.type.enum
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.name.type.interface
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.name.type.struct
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) entity.other
#61AFEF RGB(97, 175, 239) RGBA(97, 175, 239, 1) entity.other.attribute-name
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) entity.other.inherited-class
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) invalid
WHITE — — invalid.deprecated
#523D14 RGB(82, 61, 20) RGBA(82, 61, 20, 1) invalid.illegal
WHITE — — keyword
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) keyword.control
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) keyword.control.flow
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) keyword.operator
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) keyword.operator.new
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) keyword.operator.assignment
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) keyword.operator.arithmetic
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) keyword.operator.logical
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) keyword.other
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) markup
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) markup.bold
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) markup.changed
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) markup.deleted
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) markup.heading
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) markup.inline.raw
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) markup.inserted
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) markup.italic
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) markup.quote
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) markup.raw
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) markup.underline
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) markup.underline.link
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) meta
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) meta.class
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) meta.selector
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) meta.tag
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) punctuation.definition.bracket
#BE5046 RGB(190, 80, 70) RGBA(190, 80, 70, 1) punctuation.definition.comment
#5C6370 RGB(92, 99, 112) RGBA(92, 99, 112, 1) punctuation.definition.string.begin
#BE5046 RGB(190, 80, 70) RGBA(190, 80, 70, 1) punctuation.definition.string.end
#BE5046 RGB(190, 80, 70) RGBA(190, 80, 70, 1) punctuation.separator
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) punctuation.separator.continuation
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) punctuation.terminator
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) storage
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) storage.modifier
#C678DD RGB(198, 120, 221) RGBA(198, 120, 221, 1) storage.type
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) string
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.interpolated
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.other
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted.double
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted.other
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted.single
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.quoted.triple
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.regexp
#56B6C2 RGB(86, 182, 194) RGBA(86, 182, 194, 1) string.template
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) string.unquoted
#98C379 RGB(152, 195, 121) RGBA(152, 195, 121, 1) support
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) support.class
#E5C07B RGB(229, 192, 123) RGBA(229, 192, 123, 1) support.constant
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1) support.function
#56B6C2 RGB(86, 182, 194) RGBA(86, 182, 194, 1) support.type
#56B6C2 RGB(86, 182, 194) RGBA(86, 182, 194, 1) support.type.primitive
#56B6C2 RGB(86, 182, 194) RGBA(86, 182, 194, 1) support.type.property-name
#ABB2BF RGB(171, 178, 191) RGBA(171, 178, 191, 1) support.variable
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable.function
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable.language
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable.name
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable.other
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable.other.constant
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable.other.property
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable.other.readwrite
#E06C75 RGB(224, 108, 117) RGBA(224, 108, 117, 1) variable.parameter
#D19A66 RGB(209, 154, 102) RGBA(209, 154, 102, 1)