dull-pine
Publisher: alejandro9frescasThemes in package: 1
pastel rose pine
pastel rose pine
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 |
|---|---|---|
| source.js, source.ts, punctuation, keyword.operator, cast.expr.ts, punctuation.definition.tag, punctuation.separator.inheritance.php, punctuation.definition.tag.html, punctuation.definition.tag.begin.html, punctuation.definition.tag.end.html, punctuation.section.embedded, keyword.other.template, keyword.other.substitution, keyword.operator.type.annotation.ts, punctuation.definition.parameter.end.ts, storage.type.function.arrow, meta.brace.round, meta.brace.square | #919191 | — |
| comment, punctuation.definition.comment | #cccccc90 | — |
| keyword.operator.new, entity.other.attribute-name, source.json meta.structure.dictionary.json support.type.property-name.json | #A5A2B8 | — |
| variable, variable.other.constant, string constant.other.placeholder, meta.object-literaly.key, meta.object.member, meta.var.expr.ts, meta.function, markup.table, markup.raw.block.fenced.markdown, variable.language.fenced.markdown, punctuation.section.class.end, entity.name.label.ts, meta.tag | #c5c5c5 | — |
| constant.language, string, punctuation.definition.string.end, punctuation.definition.string.begin, constant.numeric, constant.other.symbol, constant.other.key, entity.other.inherited-class, markup.heading, markup.inserted.git_gutter, meta.group.braces.curly constant.other.object.key.js string.unquoted.label.js, meta.import, meta.var-single-variable.expr.ts, constant.other.color | #d6b88d | — |
| variable.language.this.ts, variable.language.super, constant.language.null, constant.language.undefined, constant.language.boolean.false, constant.language.boolean.true | #DF6C7F | bold |
| support.constant, constant.character, constant.escape, variable.parameter, keyword.other.unit, keyword.other, markup.changed.git_gutter | #b2a0c7 | — |
| property, interface, enum, support.type, support.class, support.other.namespace.use.php, meta.use.php, support.other.namespace.php, support.type.sys-types, entity.name.type.instance.jsdoc, entity.name.type.ts, entity.other.attribute-name.class, source.sass keyword.control, string.other.link.title.markdown | #B2CCD6 | — |
| support.type.primitive.ts | #B2CCD6 | bold |
| variable.defaultLibrary, markup.deleted, markup.italic, entity.name.module.js, variable.import.parameter.js, variable.other.class.js | #DF6C7F | — |
| entity.name.function | #ca9f9d | — |
| markup.inserted | #a2b18c | — |
| keyword, storage.type, storage.modifier, punctuation.definition.block.tag.jsdoc, entity.name.tag | #76848f | — |
| *url*, *link*, *uri* | — | underline |
| text.html.basic entity.other.attribute-name.html, text.html.basic entity.other.attribute-name, tag.decorator.js entity.name.tag.js, tag.decorator.js punctuation.definition.tag.js, markup.quote | #B2CCD6 | italic |
| markup.bold, markup.bold string, markup.bold markup.italic, markup.italic markup.bold, markup.quote markup.bold, markup.bold markup.italic string, markup.italic markup.bold string, markup.quote markup.bold string, meta.separator | #DF6C7F | bold |
| markup.underline | #F78C6C | underline |
| invalid, invalid.illegal | #FF5370 | — |
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}!`;
}