Npro Dark
Publisher: ninoc-devThemes in package: 1
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, comment.block.documentation, comment.block.javadoc | #636874 | italic |
| string, string.quoted, string.template, string.quoted.single, string.quoted.double, string.quoted.triple, string.quoted.double.json | #7dd68b | — |
| punctuation.definition.template-expression.begin, punctuation.definition.template-expression.end, punctuation.section.embedded, constant.character.format.placeholder.other.python | #f76e6e | — |
| constant.character.escape | #41d5c2 | — |
| keyword, keyword.control, keyword.control.flow, keyword.control.import, keyword.control.export, keyword.control.from, keyword.control.conditional, keyword.control.loop, keyword.control.trycatch, keyword.operator.new, keyword.operator.expression, keyword.operator.expression.typeof, keyword.operator.expression.instanceof, keyword.operator.expression.of, keyword.operator.expression.in, keyword.operator.expression.void, keyword.operator.expression.delete, storage, storage.type, storage.modifier, storage.type.function, storage.type.class, storage.type.interface, storage.type.enum, storage.type.type | #f76e6e | — |
| constant.language, constant.language.boolean, constant.language.null, constant.language.undefined | #f76e6e | — |
| variable.language, variable.language.this, variable.language.self, variable.language.super | #f76e6e | italic |
| entity.name.function, meta.function-call entity.name.function, support.function, support.function.magic.python | #6aafff | — |
| entity.name.type, entity.name.type.class, entity.name.type.interface, entity.name.type.enum, entity.name.type.struct, entity.name.type.type, entity.name.type.parameter, support.type, support.class, entity.other.inherited-class, entity.name.namespace, entity.name.module, entity.name.type.module | #d09cf7 | — |
| variable.other.constant, variable.other.enummember, support.constant | #d09cf7 | — |
| constant.numeric, constant.numeric.integer, constant.numeric.float, constant.numeric.hex, constant.numeric.octal, constant.numeric.binary | #f0b45a | — |
| string.regexp, constant.other.character-class.regexp, keyword.operator.quantifier.regexp, keyword.operator.or.regexp, punctuation.definition.group.regexp, punctuation.definition.character-class.regexp | #41d5c2 | — |
| variable, variable.other, variable.other.readwrite, variable.other.object, variable.parameter, meta.parameter, variable.other.property, support.variable.property, variable.other.object.property, support.variable | #bcbec4 | — |
| keyword.operator, keyword.operator.assignment, keyword.operator.arithmetic, keyword.operator.comparison, keyword.operator.logical, keyword.operator.ternary, keyword.operator.spread, keyword.operator.rest, keyword.operator.type | #bcbec4 | — |
| punctuation, punctuation.definition.block, punctuation.definition.parameters, punctuation.definition.arguments, punctuation.separator, punctuation.terminator, punctuation.accessor, meta.brace.round, meta.brace.square, meta.brace.curly | #bcbec4 | — |
| meta.decorator, meta.decorator entity.name.function, punctuation.decorator, meta.annotation, storage.type.annotation, meta.function.decorator.python, entity.name.function.decorator.python, meta.attribute.rust | #d4c44e | — |
| entity.name.tag, punctuation.definition.tag, punctuation.definition.tag.begin, punctuation.definition.tag.end | #f76e6e | — |
| entity.other.attribute-name, entity.other.attribute-name.html | #bcbec4 | — |
| support.class.component, entity.name.tag support.class.component | #d09cf7 | — |
| entity.name.tag.css, entity.other.attribute-name.class.css, entity.other.attribute-name.id.css, entity.other.attribute-name.pseudo-class.css, entity.other.attribute-name.pseudo-element.css | #f76e6e | — |
| support.type.property-name.css, support.type.vendored.property-name.css, meta.property-name.css | #bcbec4 | — |
| support.constant.property-value.css, support.constant.font-name.css, support.constant.media.css | #bcbec4 | — |
| keyword.other.unit.css, constant.other.color.rgb-value.css, support.constant.color.css | #41d5c2 | — |
| keyword.control.at-rule.css, keyword.control.at-rule.media.css, keyword.control.at-rule.import.css | #f76e6e | — |
| variable.scss, variable.other.less | #bcbec4 | — |
| support.type.property-name.json | #d09cf7 | — |
| entity.name.tag.yaml, support.type.property-name.yaml | #f76e6e | — |
| entity.name.type.anchor.yaml, variable.other.alias.yaml, keyword.control.flow.block-scalar.yaml | #41d5c2 | — |
| heading.1.markdown entity.name, heading.2.markdown entity.name, heading.3.markdown entity.name, heading.4.markdown entity.name, heading.5.markdown entity.name, heading.6.markdown entity.name, markup.heading, markup.heading.setext, punctuation.definition.heading.markdown | #f76e6e | bold |
| markup.bold | — | bold |
| markup.italic | — | italic |
| markup.inline.raw, markup.fenced_code.block | #7dd68b | — |
| markup.underline.link, markup.underline.link.markdown | #6aafff | — |
| string.other.link.title.markdown, string.other.link.description.markdown | #6aafff | — |
| punctuation.definition.list.begin.markdown, markup.list.numbered.markdown, markup.list.unnumbered.markdown | #f76e6e | — |
| markup.quote.markdown | #636874 | italic |
| entity.name.import.go | #7dd68b | — |
| entity.name.type.lifetime.rust, storage.modifier.lifetime.rust, punctuation.definition.lifetime.rust | #41d5c2 | — |
| entity.name.function.macro.rust, support.macro.rust | #6aafff | bold |
| markup.inserted | #7dd68b | — |
| markup.deleted | #f76e6e | — |
| markup.changed | #6aafff | — |
| invalid, invalid.illegal | #f75464 | — |
| invalid.deprecated | #f0b45a | strikethrough |
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}!`;
}