Miam's Dark Theme
Publisher: Miam'sThemes in package: 1
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 |
|---|---|---|
| — | #F8F8F2 | — |
| comment | #75715E | italic |
| string | #ffff79 | — |
| punctuation.definition.template-expression, punctuation.section.embedded.coffee | #F92672 | — |
| meta.object-literal.key.js | #40d8ef | — |
| meta.object.member.js, meta.objectliteral.js, meta.object.member.js, meta.objectliteral.js, meta.object.member.js, meta.objectliteral.js | #ffffff | — |
| constant.numeric | #AE81FF | — |
| support.type.property-name.css, meta.property-name.scss, meta.property-list.scss, source.css.scss | #ffffff | — |
| support.constant.property-value.css, support.function.misc.scss | #52e2fc | — |
| constant.numeric.css | #a970f9 | — |
| keyword.other.unit.css, keyword.other.unit.px.css, keyword.other.unit.vh.css, keyword.other.unit.vw.css, keyword.other.unit.percentage.css, keyword.other.unit.percentage.scss, keyword.other.unit.vw.scss, keyword.other.unit.vh.scss, meta.property-value.scss | #fb7aa9 | — |
| constant.language | #AE81FF | — |
| constant.character, constant.other | #AE81FF | — |
| variable | #d3d3d3 | |
| keyword | #fb8be1 | — |
| storage | #ffffff | |
| keyword.control.flow.js | #fb536f | |
| storage.type | #00ffd5 | italic |
| entity.name.type, entity.name.class | #A6E22E | underline |
| variable.other, variable.js, punctuation.separator.variable | #ffffff | italic |
| entity.other.inherited-class | #A6E22E | italic underline |
| entity.name.function | #fb8be1 | italic |
| variable.other.object.js | #a4ff59 | italic |
| variable.parameter, keyword.operator.spread | #FD971F | italic |
| entity.name.tag | #f926b6 | |
| entity.other.attribute-name | #88ff39 | |
| support.function | #66D9EF | italic |
| support.constant | #66D9EF | |
| support.type, support.class | #66D9EF | italic |
| support.other.variable | — | |
| invalid | #F8F8F0 | |
| invalid.deprecated | #F8F8F0 | — |
| meta.structure.dictionary.json string.quoted.double.json | #CFCFC2 | — |
| meta.diff, meta.diff.header | #75715E | — |
| markup.deleted | #F92672 | — |
| markup.inserted | #A6E22E | — |
| markup.changed | #E6DB74 | — |
| constant.numeric.line-number.find-in-files - match | #AE81FFA0 | — |
| entity.name.filename.find-in-files | #E6DB74 | — |
| markup.quote | #F92672 | — |
| markup.list | #E6DB74 | — |
| markup.bold, markup.italic | #66D9EF | — |
| markup.inline.raw | #FD971F | |
| markup.heading | #A6E22E | — |
| markup.heading.setext | #A6E22E | |
| token.info-token | #6796e6 | — |
| token.warn-token | #cd9731 | — |
| token.error-token | #f44747 | — |
| token.debug-token | #b267e6 | — |
| variable.language | #FD971F | — |
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}!`;
}