Mantis
Publisher: Daniel Ceron ClarosThemes in package: 3
A personalization to my liking of the default Dark+ theme.
A personalization to my liking of the default Dark+ theme.
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 | #6a9955 | italic |
| punctuation.definition.string.begin, punctuation.definition.string.end | #86d17a | — |
| string.quoted.single, string.quoted.double, string.quoted.triple | #a6e3a1 | — |
| punctuation.definition.string.template.begin, punctuation.definition.string.template.end, string.template punctuation.definition.string.begin, string.template punctuation.definition.string.end | #76c76c | — |
| string.template, string.quoted.template | #96d96b | — |
| punctuation.definition.template-expression.begin, punctuation.definition.template-expression.end, punctuation.section.embedded.begin, punctuation.section.embedded.end | #ff8c42 | — |
| meta.template.expression | #e1e5e9 | — |
| constant.character.escape | #66b366 | — |
| string.regexp | #4ec9b0 | — |
| constant.numeric, constant.numeric.decimal, constant.numeric.integer, constant.numeric.float, constant.numeric.hex, constant.numeric.binary, constant.numeric.octal | #79d4fd | — |
| keyword | #ff7b54 | — |
| keyword.control, keyword.control.flow, keyword.control.conditional, keyword.control.loop, keyword.control.return, keyword.control.throw, keyword.control.try, keyword.control.catch, keyword.control.finally | #ff6b35 | — |
| storage.type.function | #ff8c42 | — |
| storage.type | #e94c4c | — |
| storage.modifier | #ff49ad | — |
| keyword.other.new, keyword.operator.new | #ff8c42 | — |
| keyword.control.import, keyword.control.export, keyword.control.from, keyword.control.as, keyword.control.default | #ff54ff | — |
| keyword.operator, keyword.operator.arithmetic, keyword.operator.comparison, keyword.operator.logical, keyword.operator.assignment, punctuation.separator, punctuation.terminator | #d4d4d4 | — |
| keyword.operator.typeof, keyword.operator.instanceof, keyword.operator.in, keyword.operator.of, keyword.operator.delete, keyword.operator.void | #ff8c42 | — |
| storage.type.function.arrow | #ff6b35 | — |
| entity.name.type, support.type, support.class, entity.name.class | #4dd0e1 | — |
| support.type.primitive, support.type.builtin, entity.name.type.ts, entity.name.type.js | #26c6da | — |
| entity.name.type.interface | #00e5ff | — |
| entity.name.type.parameter, meta.type.parameters | #80deea | — |
| entity.name.function, support.function | #ffd54f | — |
| variable.function, meta.function-call | #ffcc02 | — |
| meta.function-call.method | #ffe082 | — |
| variable.other.readwrite, variable.other.object | #7db3d1 | — |
| meta.function.parameters | #a5c9e1 | — |
| variable.parameter | #a5c9e1 | — |
| variable.other.constant, variable.other.enummember | #4fc3f7 | — |
| variable.language, variable.language.this, variable.language.super, constant.language | #ef5350 | italic |
| variable.object.property, support.variable.property | #d4a5e8 | — |
| meta.object-literal.key, string.unquoted.label | #ce93d8 | — |
| support.type.property-name.css | #ba68c8 | — |
| entity.name.tag.tsx, entity.name.tag.jsx | #f48fb1 | — |
| support.class.component.tsx, support.class.component.jsx | #ff4081 | — |
| entity.other.attribute-name.tsx, entity.other.attribute-name.jsx | #ffc1cc | — |
| entity.name.tag.html | #ef5350 | — |
| entity.other.attribute-name.html | #90caf9 | — |
| punctuation.definition.tag.begin, punctuation.definition.tag.end | #8892a0 | — |
| punctuation.definition.block, punctuation.definition.brackets, punctuation.definition.parameters, punctuation.definition.array | #c9d1d9 | — |
| punctuation.decorator, meta.decorator | #e91e63 | — |
| invalid, invalid.illegal | #f44336 | — |
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}!`;
}