Dark Light Theme
Publisher: Alan RuizThemes 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 |
|---|---|---|
| entity.name.tag.html, entity.name.tag.other.html, keyword.control, markup.strike, punctuation.definition.interpolation.begin.bracket.curly.scss, punctuation.definition.interpolation.end.bracket.curly.scss, string constant.other.placeholder, variable | — | — |
| text.html.markdown meta.dummy.line-break | — | — |
| entity.name.method.js, tag.decorator.js entity.name.tag.js, tag.decorator.js punctuation.definition.tag.js | #429BDB | |
| source.js constant.other.object.key.js string.unquoted.label.js | #303030 | |
| entity.name.type.module.js, storage.type.js, string.other.link.title.markdown, variable.other.object.js, variable.other.property.js, variable.other.readwrite.js | #FFFFFF | |
| markup.underline | #429BDB | underline |
| storage.type.function.python, entity.name.function, entity.name.tag.block.any.html, keyword.other.special-method, markup.bold, markup.bold.markdown, markup.fenced_code.block.markdown, markup.inline.raw.string.markdown, markup.italic.markdown, meta.class-method.js entity.name.function.js, meta.function-call.generic.python, source.sass keyword.control, string.quoted.double.html, string.quoted.double.json, variable.function, variable.function.constructor, variable.other.constant.js, variable.other.object.property.js | #429BDB | — |
| entity.name.function | #FF8583 | — |
| entity.name.tag, markup.deleted.git_gutter, markup.quote punctuation.definition.blockquote.markdown, markup.table, meta.tag.sgml, punctuation.definition.list_item.markdown, string.other.link, support.other.variable, text.html.markdown, text.html.markdown markup.inline.raw.markdown punctuation.definition.raw.markdown | #303030 | — |
| comment.line.number-sign.python, punctuation.definition.comment.python | #81b88b | — |
| constant.numeric, constant.escape, constant.language, constant.other.php, constant.other.reference.link.markdown, entity.name, entity.other.attribute-name, entity.other.attribute-name.html, invalid.deprecated, keyword.other, keyword.other.unit, markup.changed, markup.changed.git_gutter, markup.raw.block, meta.use.php, punctuation.separator.key-value.html, source.css support.type.property-name, source.less support.type.property-name, source.postcss support.type.property-name, source.sass support.type.property-name, source.scss support.type.property-name, source.stylus support.type.property-name, storage.modifier, storage.type.function.lambda.python, string.other.link.description.title.markdown, support.class, support.orther.namespace.use.php, support.other.namespace.php, support.type, support.type.sys-types, text.html.markdown markup.inline.raw.markdown, token.warn-token, variable.parameter.js, variable.parameter.keyframe-list.css | #81b88b | — |
| constant.other.color, entity.name.tag.reference.scss, keyword.control, keyword.other.substitution, keyword.other.template, punctuation.definition.tag, punctuation.definition.tag.html, punctuation.section.embedded, punctuation.separator.inheritance.php | #429BDB | — |
| comment.block.html, comment.line.double-slash.js, comment.line.scss, punctuation.definition.comment.html, punctuation.definition.comment.js, punctuation.definition.comment.scss, punctuation.definition.tag.begin.html, punctuation.definition.tag.end.html | #6D6F7C | — |
| support.function | #EBCA46 | — |
| meta.separator | #A7A8AF | — |
| token.debug-token | #C4CBFF | — |
| markup.inserted | #C800BE | — |
| source.scss keyword.control, token.error-token | #FF8583 | — |
| constant.character.escape, constant.character.format.placeholder.other.python, punctuation.definition.string.begin.python, punctuation.definition.string.end.python, storage.type, string | #FF8583 | — |
| constant.character, constant.other.color, constant.other.key, constant.other.symbol, entity.name.module.js, entity.name.section.markdown, entity.name.tag.css, entity.other.attribute-name.class, entity.other.attribute-name.id, entity.other.attribute-name.html, entity.other.attribute-name.pseudo-class, entity.other.inherited-class, invalid, invalid.illegal, keyword, keyword.control.at-rule, keyword.control.conditional.js, keyword.control.operator, keyword.operator.assignment.js, keyword.other.unit, markdown.heading, markup.deleted, markup.heading, markup.heading | markup.heading entity.name, markup.heading.markdown punctuation.definition.heading.markdown, markup.inserted.git_gutter, meta.group.braces.curly constant.other.object.key.js string.unquoted.label.js, meta.object-literal.key, punctuation.definition, punctuation.definition.binding-pattern.object.js, punctuation.definition.entity.css, punctuation.definition.markdown, punctuation.definition.raw.markdown, punctuation.definition.string.begin.html, punctuation.definition.string.begin.js, punctuation.definition.string.end.html, punctuation.definition.string.end.js, punctuation.separator.comma.js, punctuation.terminator.rule.css, string.quoted.single.js, string.quoted.single.scss, string.regexp, storage.type.function.js, support.constant, support.type, support.type.property-name.json, text.html.derivative, token.info-token, variable.import.parameter.js, variable.language.fenced.markdown, variable.other.class.js, variable.parameter, variable.parameter.function.language.special | #FFFFFF | — |
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}!`;
}