Grapes Theme
Publisher: Félix GiraultThemes in package: 1
A calm and clutter-free theme for VSCode
A calm and clutter-free theme for VSCode
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 |
|---|---|---|
| Defaults | #f2f4f6 | — |
| source,meta.block,text,variable,support.other.variable,constant.character,constant.other,variable.parameter,meta.import,variable.other.readwrite.alias,variable.other.property,support.variable.property.dom,meta.method.body.java,variable.parameter.function.swift | #f2f4f6 | — |
| meta.brace,punctuation,punctuation.section.embedded.end,comment,constant.character.escape,keyword.operator.class,keyword.operator.access.dot.rust,meta.parameter-clause.swift | #7b8ea2 | — |
| punctuation.section.array | #9c9bdd | — |
| constant.other,constant.numeric,variable.other.constant,support.constant.core,support.constant.property-value,meta.property-value,constant.language,support.variable.dom,constant.keyword.clojure,support.constant.swift | #8cd6d8 | — |
| entity.name.function,support.function,source.sql | #c6c5eb | — |
| storage.type,entity.name.type,support.class.builtin,meta.type_params,meta.type.annotation,support.type.primitive,support.type.builtin,support.class,support.type.core,meta.class,keyword.other.type,meta.function.parameters.php,support.type.swift | #86b0de | — |
| variable.language.this,variable.language.super,variable.parameter.function.language.special.self.python,variable.language.special.self.python | #7b8ea2 | bold |
| meta.type.parameters | #d3807d | — |
| storage.type.js,storage.type.ts,storage.type.type.ts,keyword,storage.modifier,storage.type.function,storage.type.class,storage.type.rust,storage.type.struct.swift,storage.type.extension.swift | #9c9bdd | italic |
| meta.object-literal.key,meta.structure.dictionary,support.type.property-name,support.type.vendored.property-name,entity.other.attribute-name | #bd9bdd | — |
| string,string.regexp,constant.other.character-class,meta.attribute-selector | #a6d37d | — |
| punctuation.definition.string,constant.character.escape | #57862d | — |
| entity.name.tag,support.class.component.js,entity.other.attribute-name.id.css,entity.other.attribute-name.class.css | #86b0de | bold |
| keyword.operator,support.variable.object,keyword.control.anchor.regexp,entity.name.operator.cpp | #d3807d | normal |
| markup.heading | #86b0de | — |
| markup.underline.link,beginning.punctuation.definition,punctuation.definition.string.begin.markdown,punctuation.definition.string.end.markdown | #7b8ea2 | — |
| string.other.link.title.markdown | #bd9bdd | — |
| markup.bold.markdown | — | bold |
| markup.italic.markdown | — | 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}!`;
}