Monochai
Publisher: 381181295Themes in package: 2
Simple monochrome themes
Simple monochrome themes
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 |
|---|---|---|
| variable.parameter.function | #515151 | — |
| comment, punctuation.definition.comment | #c3c3c3 | — |
| punctuation.definition.string, punctuation.definition.variable, punctuation.definition.parameters, punctuation.definition.array | #515151 | — |
| none | #515151 | — |
| keyword.operator | #515151 | — |
| keyword | #8f8f8f | — |
| variable | #8b8b8b | — |
| entity.name.function, meta.require, support.function.any-method | #999999 | — |
| support.class, entity.name.class, entity.name.type.class | #686868 | — |
| meta.class | #191919 | — |
| keyword.other.special-method | #999999 | — |
| storage | #8f8f8f | — |
| support.function | #7d7d7d | — |
| storage.type | #6e6e6e | italic |
| storage.modifier, storage.type.modifier | #6e6e6e | italic |
| entity.other.inherited-class | #747474 | italic |
| variable.language | #515151 | italic |
| string, constant.other.symbol | #747474 | — |
| constant.numeric | #6e6e6e | — |
| none | #6e6e6e | — |
| none | #6e6e6e | — |
| constant | #6e6e6e | — |
| entity.name.tag | #8b8b8b | — |
| entity.other.attribute-name | #6e6e6e | — |
| entity.other.attribute-name.id, punctuation.definition.entity | #999999 | — |
| meta.selector | #8f8f8f | — |
| none | #6e6e6e | — |
| markup.heading punctuation.definition.heading, entity.name.section | #999999 | |
| keyword.other.unit | #6e6e6e | — |
| markup.bold, punctuation.definition.bold | #686868 | bold |
| comment markup.bold | #686868 | bold italic |
| markup.italic, punctuation.definition.italic | #8f8f8f | italic |
| comment markup.underline | #6e6e6e | underline italic |
| markup.underline | #6e6e6e | underline |
| storage.type.class.jsdoc | #6e6e6e | italic underline |
| variable.parameter.js | #515151 | italic |
| markup.quote | #6e6e6e | italic |
| storage | #8f8f8f | — |
| storage.type | #6e6e6e | italic |
| storage.modifier, storage.type.modifier | #6e6e6e | italic |
| markup.raw.inline | #747474 | — |
| variable.parameter.function | #515151 | italic |
| meta.link | #6e6e6e | — |
| markup.list | #8b8b8b | — |
| markup.quote | #6e6e6e | — |
| meta.separator | #515151 | — |
| markup.inserted | #747474 | — |
| markup.deleted | #8b8b8b | — |
| markup.changed | #8f8f8f | — |
| entity.other.attribute-name | #6e6e6e | italic |
| string.regexp | #7d7d7d | — |
| constant.character.escape | #7d7d7d | — |
| punctuation.section.embedded, variable.interpolation | #8f8f8f | — |
| invalid.illegal | #191919 | italic underline |
| invalid.broken | #ebebeb | — |
| invalid.deprecated | #191919 | italic underline |
| invalid.unimplemented | #191919 | — |
| entity.other.inherited-class | #747474 | italic |
| variable.language | #515151 | italic |
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}!`;
}