NightShell
Publisher: OverlordThemes in package: 1
A deep-ocean dark theme with warm syntax colors and navy shadows by Anupam
A deep-ocean dark theme with warm syntax colors and navy shadows by Anupam
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, comment.line, comment.block, comment.block.documentation | #546e7a | italic |
| keyword, keyword.control, keyword.control.flow, storage.type, storage.modifier | #c792ea | bold |
| keyword.operator, punctuation.accessor | #89ddff | — |
| entity.name.function, support.function, meta.function-call.generic | #82aaff | — |
| entity.name.type, entity.name.class, support.class, support.type | #ffcb6b | — |
| string, string.quoted, string.template | #c3e88d | — |
| constant.numeric, constant.language, constant.character | #f78c6c | — |
| variable, variable.other, source | #eeffff | — |
| variable.parameter | #f78c6c | — |
| variable.other.local | #ff5370 | — |
| variable.language, support.variable | #c792ea | — |
| entity.name.tag | #f07178 | — |
| entity.other.attribute-name | #c792ea | — |
| punctuation, punctuation.definition, punctuation.separator, punctuation.terminator | #89ddff | — |
| entity.name.module, support.module | #c3e88d | — |
| meta.decorator, punctuation.decorator | #82aaff | italic |
| constant.language.boolean | #c792ea | — |
| constant.language.null, constant.language.undefined | #546e7a | — |
| string.regexp | #89ddff | — |
| support.function.builtin.shell | #c792ea | — |
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}!`;
}