Charson Theme
Publisher: Richson SimbabureThemes in package: 2
Beautiful dark themes with inline diagnostics, semantic highlighting, and modern UI - Charson Dark & Charson Ember
Beautiful dark themes with inline diagnostics, semantic highlighting, and modern UI - Charson Dark & Charson Ember
Full workbench mockup using this variant's colors and tokenColors.
Loading...
Workbench UI color keys from the theme JSON colors map.
TextMate scopes and font styles (syntax highlighting rules).
| scope | foreground | fontStyle |
|---|---|---|
| Default text | #c9b99a | — |
| comment, punctuation.definition.comment | #6a5535 | italic |
| string, string.quoted, string.template, punctuation.definition.string | #c8a86a | — |
| string.quoted.docstring, string.documentation | #7aafc4 | — |
| string.template meta.embedded, punctuation.definition.template-expression, meta.template.expression | #e87a20 | — |
| constant.numeric | #ffcc55 | — |
| constant.language, constant.character, constant.other | #c45a10 | — |
| constant.language.boolean, constant.language.null, constant.language.undefined | #c45a10 | italic |
| variable, variable.other | #c9b99a | — |
| variable.language, variable.language.this, variable.language.self | #e87a20 | italic |
| variable.other.property, variable.other.object.property | #b8956a | — |
| variable.parameter, meta.function.parameters variable, meta.parameters variable | #9a7a4a | italic |
| keyword | #e87a20 | italic |
| keyword.control, keyword.control.flow, keyword.control.conditional, keyword.control.loop, keyword.control.import, keyword.control.export, keyword.control.from, keyword.control.as | #e87a20 | italic |
| keyword.operator, keyword.operator.logical, keyword.operator.comparison, keyword.operator.assignment | #7a5535 | — |
| keyword.operator.new | #c45a10 | italic |
| storage.type, storage.type.function, storage.type.class | #c45a10 | bold italic |
| storage.modifier | #b87a40 | italic |
| entity.name.function, meta.function entity.name.function | #d4a060 | bold |
| meta.function-call, support.function, meta.function-call entity.name.function | #d4a060 | — |
| entity.name.type, entity.name.class, support.type, support.class, entity.other.inherited-class, entity.name.type.interface | #7aafc4 | italic |
| meta.type.annotation entity.name.type, meta.type entity.name.type, meta.return.type, meta.type.parameters, support.type.primitive, storage.type.primitive | #5a9ab5 | italic |
| variable.other.constant | #d4a060 | bold |
| meta.object-literal.key, support.type.property-name, string.unquoted | #b8956a | — |
| meta.brace.curly, meta.brace.round, meta.brace.square, punctuation.section, punctuation.definition.block | #7a5535 | — |
| punctuation.separator, punctuation.accessor, meta.delimiter, punctuation.terminator | #5a4028 | — |
| entity.name.tag | #c45a10 | bold |
| punctuation.definition.tag | #e87a20 | — |
| entity.other.attribute-name | #9a7a4a | italic |
| entity.other.attribute-name.class.css, entity.name.tag.css, entity.other.attribute-name.id.css | #d4a060 | — |
| support.type.property-name.css, meta.property-name.css | #b8956a | — |
| support.constant.property-value.css, keyword.other.unit.css, constant.numeric.css | #ffcc55 | — |
| support.type.property-name.json, entity.name.tag.yaml, support.type.property-name.toml | #b8956a | — |
| string.regexp | #8a5a3a | — |
| constant.character.escape | #e87a20 | — |
| entity.name.function.decorator.python, meta.function.decorator.python | #e87a20 | italic |
| variable.parameter.function.language.special.self.python, variable.language.special.self.python | #e87a20 | italic bold |
| storage.type.type.ts, storage.type.type.tsx, storage.type.interface.ts, storage.type.interface.tsx | #b87a40 | italic |
| markup.heading, entity.name.section | #e87a20 | bold |
| markup.bold | #d4a060 | bold |
| markup.italic | #c8a86a | italic |
| markup.inline.raw, markup.fenced_code.block, markup.raw.inline | #b8956a | — |
| markup.underline.link | #7aafc4 | underline |
| markup.inserted, diff.inserted | #5a8a5a | — |
| markup.deleted, diff.deleted | #c04040 | — |
| markup.changed, diff.changed | #b87a20 | — |
| invalid | #c04040 | italic underline |
| invalid.deprecated | #7a5535 | italic underline |
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}!`;
}