May Theme
Publisher: MayrinkThemes in package: 1
A theme to fill your eyes ;)
A theme to fill your eyes ;)
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 |
|---|---|---|
| — | #50514Fff | — |
| emphasis | — | italic |
| strong, markup.heading.markdown, markup.bold.markdown | — | bold |
| markup.italic.markdown | — | italic |
| comment, markup.fenced_code, markup.inline | #6a737d | — |
| storage.modifier, support.function.node, punctuation.separator.key-value, punctuation.definition.template-expression | #d73a49 | — |
| keyword.operator.accessor, meta.group.braces.round.function.arguments, meta.template.expression | #24292eff | — |
| entity.name.type, entity.other.inherited-class, meta.function-call, entity.other.attribute-name, entity.name.function | #6f42c1 | — |
| entity.name.tag, string.regexp, string.interpolated, string.template, keyword.other.template | #22863a | — |
| token.info-token | #316bcd | — |
| token.warn-token | #cd9731 | — |
| token.error-token | #cd3131 | — |
| token.debug-token | #800080 | — |
| comment | #C8D0BF | — |
| support.type.property-name, constant.other.color.rgb-value.hex.css, meta.instance.constructor, constant.other.object.key.js, constant.numeric, variable.other.class, meta.property-name, meta.property-value, support, string.other.link.description.markdown | #E27A3F | — |
| storage.type, keyword.control.module, string.quoted.double.js, string.quoted.double.html, constant.language, variable.language.this, keyword.control.at-rule.include.scss, keyword.other.important.scss, support.type.property-name.json, entity.other.attribute-name.class.jade, meta.at-rule.fontface, keyword.operator.new.js, punctuation.quasi.element | #DF5A49 | — |
| variable.other.readwrite, entity.other.attribute-name, meta.property-value.css, keyword.other.unit.css, keyword.other.unit.px.css, keyword.other.unit.em.css, keyword.other.unit.rem.css, keyword.other.unit.vw.css, keyword.other.unit.vh.css, keyword.other.unit.percentage.css, constant.numeric.css, variable.scss, string.quasi.js, variable.other.constant | #EFC94C | — |
| entity.name.function, meta.group.braces.round.function.arguments.js, entity.name.tag, punctuation.definition.tag, support.type.property-name.css, punctuation.definition.tag.end.html, punctuation.definition.tag.begin.html, punctuation.definition.parameters.begin.js, punctuation.definition.parameters.end.js, meta.brace.curly.js, support.function.url.css, punctuation.section.function.begin.bracket.round.css, punctuation.section.function.end.bracket.round.css, punctuation.definition.parameters.begin.bracket.round.scss, punctuation.definition.parameters.end.bracket.round.scss, variable.control.import.include.jade, variable.other.object.js, support.type.object.console.js, support.function.console.js, keyword.control.flow, meta.link.inline.markdown | #334D5C | — |
| meta.function-call, entity.name.class.js, text.html.basic, text, meta.class.body.js, string.quoted.single, string.quoted.double.json, support.function.misc.scss, support.constant.property-value.css, variable.parameter.function | #45B29D | — |
| keyword.control.conditional, meta.function-call.with-arguments.js, entity.other.attribute-name.html, comment, entity.other.attribute-name.jsx, entity.name.function.method.js, constant.other.object.key.js, keyword.control.at-rule.include.scss, support.type.property-name.json, meta.at-rule.fontface, keyword.control.at-rule.import.scss, string.quoted.single.scss, string.quoted.jade, variable.control.import.include.jade, support.function.console.js, entity.other.attribute-name.class.css, punctuation.dollar.js, meta.function-call.method.without-arguments.js, meta.function-call.with-arguments.js | — | italic |
| variable.language.this, keyword.operator.new.js, keyword.control.flow | — | italic 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}!`;
}