fallen-dev
Publisher: Marcelo CarvalhoThemes in package: 4
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 | #6F7378 | — |
| comment.block | #434349 | — |
| comment.block.documentation, comment.line.documentation | #85898E | italic |
| keyword, storage.type, storage.modifier | #B9414B | — |
| keyword.operator, punctuation.accessor | #BA091E | — |
| string, string.quoted, string.template | #685D5D | — |
| constant.character.escape, constant.character | #71262F | — |
| invalid.illegal, invalid.deprecated | #BC4512 | — |
| constant.numeric | #FFCA80 | bold |
| constant.language, constant.other | #B16B6B | — |
| entity.name.function, support.function | #2E708A | — |
| meta.function-call entity.name.function, variable.function | #2E708A | — |
| entity.name.type.class, support.class | #961D2B | — |
| entity.name.type.interface | #85898e | — |
| entity.name.type, support.type, support.type.primitive | #85898e | — |
| variable.other.readwrite, variable.other.local | #A9A9A9 | — |
| variable.other.property, variable.other.member, meta.object-literal.key | #961D2B | — |
| variable.parameter | #B16B6B | — |
| variable.other.constant, variable.other.enummember | #71262F | — |
| storage.type.annotation, entity.name.type.annotation, punctuation.definition.annotation | #4D3860 | — |
| entity.name.tag, punctuation.definition.tag | #B9414B | — |
| entity.other.attribute-name | #961D2B | — |
| string.quoted.double.html, string.quoted.double.xml | #961D2B | italic |
| support.type.property-name.json, string.json support.type.property-name | #961D2B | — |
| string.regexp | #685D5D | — |
| markup.heading, entity.name.section | #B9414B | bold |
| markup.bold | #d6d7d9 | bold |
| markup.italic | #d6d7d9 | italic |
| markup.underline.link, string.other.link | #BA091E | underline |
| markup.inserted | #3A7460 | — |
| markup.deleted | #BC4512 | — |
| markup.changed | #C1A875 | — |
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}!`;
}