KH Theme Pack
Publisher: Ed MoralesThemes in package: 2
Subtle fantasy-inspired dark themes for VS Code: Gold and Silver variants with accessibility-minded contrast.
Subtle fantasy-inspired dark themes for VS Code: Gold and Silver variants with accessibility-minded contrast.
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 |
|---|---|---|
| comment, punctuation.definition.comment | #786F86 | italic |
| comment.block.documentation, comment.documentation | #8C7DA1 | italic |
| keyword, keyword.control, keyword.control.flow, keyword.operator.word, storage, storage.modifier, storage.type | #E8C15F | bold |
| keyword.operator, punctuation.separator, punctuation.terminator | #C9954D | — |
| entity.name.function, entity.name.function.member, support.function, support.function.builtin, meta.function-call, variable.function | #93BCFF | — |
| string, string.template, punctuation.definition.string | #9AE7C2 | — |
| constant.numeric, constant.language.boolean, constant.language.null, constant.character.escape, constant.other.symbol | #63DFFF | bold |
| entity.name.type, entity.name.type.class, entity.name.type.interface, entity.name.type.enum, entity.name.namespace, support.type, support.class, support.constant | #E4D19B | — |
| entity.name.tag, entity.other.attribute-name, support.type.property-name, meta.object-literal.key | #EABB6F | — |
| variable, meta.definition.variable | #EFE6D3 | — |
| variable.other.property, variable.object.property, variable.other.constant | #B69B66 | — |
| variable.parameter, meta.parameter.object-pattern | #F2C873 | — |
| constant.language, constant.other, variable.language | #EEB455 | — |
| invalid, invalid.illegal | #FF6B7A | bold |
| markup.bold, markup.heading | #E8C15F | bold |
| markup.italic | #CDB98C | italic |
| markup.inline.raw, markup.fenced_code.block | #8CF0C8 | — |
| punctuation.section.embedded, punctuation.definition.template-expression | #C9954D | — |
| punctuation.bracket, punctuation.definition.tag | #B6A88B | — |
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}!`;
}