ft-paper
Publisher: Camille HodoulThemes in package: 1
Light theme generated from the ft-paper palette of camillehdl.dev.
Light theme generated from the ft-paper palette of camillehdl.dev.
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 | #6b6259 | italic |
| comment.block.documentation storage.type, comment.block.documentation entity.name.type, storage.type.class.jsdoc | #6b6259 | bold italic |
| string, punctuation.definition.string, string.quoted.docstring | #00733a | — |
| constant.character.escape, constant.other.placeholder, punctuation.definition.template-expression, punctuation.section.embedded | #990f3d | — |
| string.regexp | #0d7680 | — |
| constant.numeric, constant.language, support.constant, constant.other.color, keyword.other.unit, constant.other.enum, variable.other.enummember | #99521f | — |
| variable, variable.other, variable.other.readwrite | #262a33 | — |
| variable.parameter, meta.parameter | #4a4f59 | — |
| variable.other.property, variable.other.object.property, support.variable.property, meta.object-literal.key, support.type.property-name, entity.name.tag.yaml, entity.name.tag.toml | #4a4f59 | — |
| variable.language, support.variable.dom | #990f3d | — |
| entity.name.function, meta.function-call entity.name.function, support.function, entity.name.method | #0f5499 | — |
| support.function.builtin, support.function.magic, support.function.console | #0f5499 | italic |
| keyword, keyword.control, storage.type, storage.modifier, keyword.other, keyword.operator.new, keyword.operator.expression, keyword.operator.word, keyword.operator.logical.python, entity.name.label | #593380 | — |
| keyword.control.import, keyword.control.export, keyword.control.from, keyword.control.as, keyword.other.import, keyword.other.use, keyword.control.directive, meta.preprocessor, entity.name.function.preprocessor, entity.name.function.macro, support.function.macro | #990f3d | — |
| keyword.control.exception, keyword.control.trycatch, keyword.control.throw | #cc0000 | — |
| keyword.operator, punctuation.accessor | #4a4f59 | — |
| entity.name.type, entity.name.class, entity.name.namespace, entity.name.module, entity.other.inherited-class, support.type, support.class, entity.name.type.module, storage.type.primitive | #0d7680 | — |
| support.type.primitive, support.type.builtin, support.class.builtin | #0d7680 | italic |
| meta.decorator, entity.name.function.decorator, punctuation.decorator, storage.type.annotation, meta.attribute, entity.name.function.attribute | #990f3d | — |
| punctuation, meta.brace, punctuation.separator, punctuation.terminator | #6b6259 | — |
| entity.name.tag, support.class.component | #593380 | — |
| entity.other.attribute-name | #0f5499 | — |
| punctuation.definition.tag | #6b6259 | — |
| invalid, invalid.illegal | #cc0000 | — |
| invalid.deprecated | #99521f | strikethrough |
| markup.heading, heading.1.markdown, heading.2.markdown, heading.1.markdown entity.name.section, heading.2.markdown entity.name.section | #990f3d | bold |
| heading.3.markdown, heading.3.markdown entity.name.section | #0f5499 | bold |
| heading.4.markdown, heading.4.markdown entity.name.section | #0f5499 | |
| heading.5.markdown, heading.6.markdown, heading.5.markdown entity.name.section, heading.6.markdown entity.name.section | #0d7680 | |
| markup.bold | #262a33 | bold |
| markup.italic | — | italic |
| markup.strikethrough | — | strikethrough |
| markup.underline.link, markup.link, string.other.link, meta.link.inline.markdown, constant.other.reference.link | #0f5499 | — |
| markup.underline.link | #0f5499 | underline |
| markup.inline.raw, markup.inline.raw.string.markdown, markup.fenced_code.block.markdown, markup.raw | #4a4f59 | — |
| markup.quote | #4a4f59 | italic |
| punctuation.definition.list.begin.markdown, beginning.punctuation.definition.list.markdown, punctuation.definition.list | #990f3d | — |
| markup.inserted, punctuation.definition.inserted | #00733a | — |
| markup.deleted, punctuation.definition.deleted | #cc0000 | — |
| markup.changed, punctuation.definition.changed | #0f5499 | — |
| meta.diff.header, meta.diff.range, meta.diff.index | #6b6259 | — |
| meta.diff.header.from-file, meta.diff.header.to-file | #262a33 | bold |
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}!`;
}