Spect
Publisher: Hazeq Bin MohsinThemes in package: 7
✨ Professional icon pack and color theme for a better development experience ✨
✨ Professional icon pack and color theme for a better development experience ✨
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 | #476639 | italic |
| string, string.quoted, meta.string | #fc9867 | — |
| string.template, string.template variable | #de9876 | — |
| punctuation.definition.string.begin, punctuation.definition.string.end | #fc986788 | — |
| string.regexp, constant.character.escape | #a5d6ff | — |
| constant.other.symbol | #de9876 | — |
| keyword.control, keyword, storage.type, storage.modifier, storage | #da95f0 | — |
| keyword.controlpanel | #ff7b72 | — |
| entity.name.function, support.function, entity.name.method | #dbd09e | — |
| meta.function-call, variable.function, meta.function-call.generic | #dbd09e | — |
| variable.parameter, meta.parameter | #c9d1d9 | — |
| support.function, support.macro | #dbd09e | — |
| variable, variable.other, meta.definition.variable | #b3e4ff | — |
| variable.member | #b3e4ff | — |
| variable.language | #79c0ff | italic |
| variable.parameter.function | #c9d1d9 | — |
| variable.other.constant, variable.other.readwrite | #79c0ff | — |
| entity.name.type, entity.name.class, support.type, support.class, entity.name.type.class | #00cfa5 | — |
| entity.other.inherited-class | #00cfa5 | italic |
| support.type, support.class | #00cfa5 | — |
| constant.numeric | #b5cea8 | — |
| constant.language | #b5cea8 | — |
| constant.language.boolean, constant.language.null | #569cd6 | — |
| keyword.operator, punctuation.accessor | #d4d4d4 | — |
| punctuation.separator, punctuation.terminator | #8b949e | — |
| punctuation.section | #8b949e | — |
| punctuation, meta.brace, meta.delimiter | #8b949e | — |
| punctuation.definition.template-expression | #c586c0 | — |
| punctuation.section.embedded | #c586c0 | — |
| meta.embedded | #f4f4f4 | — |
| entity.name.tag, meta.tag.sgml | #58a6ff | — |
| punctuation.definition.tag.begin, punctuation.definition.tag.end, punctuation.definition.tag | #75757588 | — |
| entity.name.tag.html, entity.name.tag.xml | #569cd6 | — |
| entity.other.attribute-name, meta.attribute | #bedaeb | — |
| support.class.component | #00cfa5 | — |
| meta.decorator variable.other, meta.decorator punctuation.decorator, storage.type.annotation, entity.name.function.decorator | #d2a8ff | — |
| entity.name.import, entity.name.package | #9cdcfe | — |
| entity.other.attribute-name.class, entity.other.attribute-name.id | #ffa657 | — |
| entity.other.attribute-name.pseudo-class | #79c0ff | — |
| source.css entity.name.tag, source.scss entity.name.tag, source.sass entity.name.tag, source.less entity.name.tag | #bababa | — |
| support.type.property-name.css, support.type.property-name | #79c0ff | — |
| support.constant.property-value | #a5d6ff | — |
| source.css support.type, source.scss support.type, source.sass support.type, source.less support.type | #8b949e | — |
| markup.heading, markup.heading punctuation.definition.heading, markup.heading entity.name | #58a6ff | bold |
| markup.bold | — | bold |
| markup.italic, emphasis | — | italic |
| markup.italic markup.bold, markup.bold markup.italic | — | bold italic |
| markup.underline | — | underline |
| markup.inline.raw, markup.raw | #d18762 | — |
| markup.raw.block | #d18762 | — |
| markup.quote | #8b949e | italic |
| meta.separator | #8b949e | bold |
| markup.list punctuation.definition.list.begin | #58a6ff | — |
| markup.strike | #8b949e | — |
| markup.table | #79c0ff | — |
| markup.strong | — | bold |
| support.type.property-name.json, string.quoted.key.json | #79c0ff | — |
| meta.diff, meta.diff.header | #8b949e | — |
| markup.inserted | #b8d663 | — |
| markup.deleted | #F14C4C | — |
| markup.changed | #d29922 | — |
| invalid, invalid.deprecated | #F14C4C | strikethrough |
| constant.numeric.line-number.find-in-files | #484f58 | — |
| constant.numeric.line-number.match | #d29922 | — |
| entity.name.filename.find-in-files | #9cdcfe | — |
| message.error | #F14C4C | — |
| markup.underline.link, string.other.link | #58a6ff | underline |
| source, text | #f4f4f4 | — |
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}!`;
}