XPX Extension
Publisher: InfocosmeThemes in package: 4
Language support for xpx
Language support for xpx
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 |
|---|---|---|
| meta.embedded, source.groovy.embedded, string meta.image.inline.markdown | #F8F8F2 | — |
| comment | #88846F | — |
| string | #E6DB74 | — |
| punctuation.definition.template-expression, punctuation.section.embedded | #F92672 | — |
| meta.template.expression | #F8F8F2 | — |
| constant.numeric | #AE81FF | — |
| constant.language | #AE81FF | — |
| constant.character, constant.other | #AE81FF | — |
| variable | #F8F8F2 | |
| keyword | #F92672 | — |
| storage | #F92672 | |
| storage.type | #66D9EF | italic |
| entity.name.type, entity.name.class, entity.name.namespace, entity.name.scope-resolution | #A6E22E | underline |
| entity.other.inherited-class | #A6E22E | italic underline |
| entity.name.function | #A6E22E | |
| variable.parameter | #FD971F | italic |
| entity.name.tag | #F92672 | |
| entity.other.attribute-name | #A6E22E | |
| support.function | #66D9EF | |
| support.constant | #66D9EF | |
| support.type, support.class | #66D9EF | italic |
| support.other.variable | — | |
| invalid | #F44747 | |
| invalid.deprecated | #F44747 | — |
| meta.structure.dictionary.json string.quoted.double.json | #CFCFC2 | — |
| meta.diff, meta.diff.header | #75715E | — |
| markup.deleted | #F92672 | — |
| markup.inserted | #A6E22E | — |
| markup.changed | #E6DB74 | — |
| constant.numeric.line-number.find-in-files - match | #AE81FFA0 | — |
| entity.name.filename.find-in-files | #E6DB74 | — |
| markup.quote | #F92672 | — |
| markup.list | #E6DB74 | — |
| markup.bold, markup.italic | #66D9EF | — |
| markup.inline.raw | #FD971F | |
| markup.heading | #A6E22E | — |
| markup.heading.setext | #A6E22E | bold |
| markup.heading.markdown | — | bold |
| markup.quote.markdown | #75715E | italic |
| markup.bold.markdown | — | bold |
| string.other.link.title.markdown,string.other.link.description.markdown | #AE81FF | — |
| markup.underline.link.markdown,markup.underline.link.image.markdown | #E6DB74 | — |
| markup.italic.markdown | — | italic |
| markup.strikethrough | — | strikethrough |
| markup.list.unnumbered.markdown, markup.list.numbered.markdown | #F8F8F2 | — |
| punctuation.definition.list.begin.markdown | #A6E22E | — |
| token.info-token | #6796E6 | — |
| token.warn-token | #CD9731 | — |
| token.error-token | #F44747 | — |
| token.debug-token | #B267E6 | — |
| variable.language | #FD971F | — |
| entity.name.tag.html | #5F7EC6 | bold |
| entity.other.attribute-name.html | #1A50CD | italic |
| string.quoted.single.xpx, string.quoted.double.html | #C9D2E6 | — |
| meta.tag.structure.form.start.html entity.name.tag.html, meta.tag.structure.form.end.html entity.name.tag.html, meta.tag.structure.label.start.html entity.name.tag.html, meta.tag.structure.label.end.html entity.name.tag.html, meta.tag.structure.fieldset.start.html entity.name.tag.html, meta.tag.structure.fieldset.end.html entity.name.tag.html, meta.tag.structure.legend.start.html entity.name.tag.html, meta.tag.structure.legend.end.html entity.name.tag.html, meta.tag.structure.datalist.start.html entity.name.tag.html, meta.tag.structure.datalist.end.html entity.name.tag.html, meta.tag.structure.input.void.html entity.name.tag.html, meta.tag.other.input.html entity.name.tag.html, meta.tag.structure.output.start.html entity.name.tag.html, meta.tag.structure.output.end.html entity.name.tag.html, meta.tag.structure.select.start.html entity.name.tag.html, meta.tag.structure.select.end.html entity.name.tag.html, meta.tag.structure.optgroup.start.html entity.name.tag.html, meta.tag.structure.optgroup.end.html entity.name.tag.html, meta.tag.structure.option.start.html entity.name.tag.html, meta.tag.structure.option.end.html entity.name.tag.html, meta.tag.structure.textarea.start.html entity.name.tag.html, meta.tag.structure.textarea.end.html entity.name.tag.html, meta.tag.structure.button.start.html entity.name.tag.html, meta.tag.structure.button.end.html entity.name.tag.html | #FF8C1F | bold |
| meta.tag.structure.form.start.html entity.other.attribute-name.html, meta.tag.structure.label.start.html entity.other.attribute-name.html, meta.tag.structure.fieldset.start.html entity.other.attribute-name.html, meta.tag.structure.legend.start.html entity.other.attribute-name.html, meta.tag.structure.datalist.start.html entity.other.attribute-name.html, meta.tag.structure.input.void.html entity.other.attribute-name.html, meta.tag.structure.output.start.html entity.other.attribute-name.html, meta.tag.structure.select.start.html entity.other.attribute-name.html, meta.tag.structure.optgroup.start.html entity.other.attribute-name.html, meta.tag.structure.option.start.html entity.other.attribute-name.html, meta.tag.structure.textarea.start.html entity.other.attribute-name.html, meta.tag.structure.button.start.html entity.other.attribute-name.html | #F77800 | italic |
| meta.tag.structure.form.start.html string.quoted.double.html, meta.tag.structure.label.start.html string.quoted.double.html, meta.tag.structure.fieldset.start.html string.quoted.double.html, meta.tag.structure.legend.start.html string.quoted.double.html, meta.tag.structure.datalist.start.html string.quoted.double.html, meta.tag.structure.input.void.html string.quoted.double.html, meta.tag.structure.output.start.html string.quoted.double.html, meta.tag.structure.select.start.html string.quoted.double.html, meta.tag.structure.optgroup.start.html string.quoted.double.html, meta.tag.structure.option.start.html string.quoted.double.html, meta.tag.structure.textarea.start.html string.quoted.double.html, meta.tag.structure.button.start.html string.quoted.double.html | #FFC893 | — |
| variable.other.xpx | #FFD300 | — |
| variable.other.secondaire.xpx | #ffae00 | bold |
| block_tag_name_xpx | #D4D4D4 | — |
| keyword.block.xpx, entity.name.tag.js | #7CD42E | bold |
| entity.other.attribute-name.xpx | #4EA500 | italic |
| entity.other.attribute-name.value.xpx string.quoted.double.html, entity.other.attribute-name.name.xpx string.quoted.double.html, entity.other.attribute-name.expr.xpx string.quoted.double.html, entity.other.attribute-name.token.xpx string.quoted.double.html, entity.other.attribute-name.path.xpx string.quoted.double.html, entity.other.attribute-name.abs.xpx string.quoted.double.html, entity.other.attribute-name.addpage.xpx string.quoted.double.html, entity.other.attribute-name.align.xpx string.quoted.double.html, entity.other.attribute-name.array.xpx string.quoted.double.html, entity.other.attribute-name.bgcolor.xpx string.quoted.double.html, entity.other.attribute-name.bit.xpx string.quoted.double.html, entity.other.attribute-name.bitoff.xpx string.quoted.double.html, entity.other.attribute-name.biton.xpx string.quoted.double.html, entity.other.attribute-name.border.xpx string.quoted.double.html, entity.other.attribute-name.by.xpx string.quoted.double.html, entity.other.attribute-name.calc.xpx string.quoted.double.html, entity.other.attribute-name.charset.xpx string.quoted.double.html, entity.other.attribute-name.chartohexa.xpx string.quoted.double.html, entity.other.attribute-name.close.xpx string.quoted.double.html, entity.other.attribute-name.exist.xpx string.quoted.double.html, entity.other.attribute-name.create.xpx string.quoted.double.html, entity.other.attribute-name.datetime.xpx string.quoted.double.html, entity.other.attribute-name.decode64.xpx string.quoted.double.html, entity.other.attribute-name.encode64.xpx string.quoted.double.html, entity.other.attribute-name.exec.xpx string.quoted.double.html, entity.other.attribute-name.exist.xpx string.quoted.double.html, entity.other.attribute-name.expr.xpx string.quoted.double.html, entity.other.attribute-name.font.xpx string.quoted.double.html, entity.other.attribute-name.global.xpx string.quoted.double.html, entity.other.attribute-name.htmltotext.xpx string.quoted.double.html, entity.other.attribute-name.keycode.xpx string.quoted.double.html, entity.other.attribute-name.len.xpx string.quoted.double.html, entity.other.attribute-name.local.xpx string.quoted.double.html, entity.other.attribute-name.lowcase.xpx string.quoted.double.html, entity.other.attribute-name.ltrim.xpx string.quoted.double.html, entity.other.attribute-name.maxrows.xpx string.quoted.double.html, entity.other.attribute-name.mode.xpx string.quoted.double.html, entity.other.attribute-name.money.xpx string.quoted.double.html, entity.other.attribute-name.name.xpx string.quoted.double.html, entity.other.attribute-name.noaccent.xpx string.quoted.double.html, entity.other.attribute-name.option.xpx string.quoted.double.html, entity.other.attribute-name.open.xpx string.quoted.double.html, entity.other.attribute-name.padding.xpx string.quoted.double.html, entity.other.attribute-name.path.xpx string.quoted.double.html, entity.other.attribute-name.rand.xpx string.quoted.double.html, entity.other.attribute-name.read.xpx string.quoted.double.html, entity.other.attribute-name.rect.xpx string.quoted.double.html, entity.other.attribute-name.replace.xpx string.quoted.double.html, entity.other.attribute-name.rotate.xpx string.quoted.double.html, entity.other.attribute-name.rtrim.xpx string.quoted.double.html, entity.other.attribute-name.strcode.xpx string.quoted.double.html, entity.other.attribute-name.strdecode.xpx string.quoted.double.html, entity.other.attribute-name.strscape.xpx string.quoted.double.html, entity.other.attribute-name.trim.xpx string.quoted.double.html, entity.other.attribute-name.upcase.xpx string.quoted.double.html, entity.other.attribute-name.urlcode.xpx string.quoted.double.html, entity.other.attribute-name.value.xpx string.quoted.double.html, entity.other.attribute-name.version.xpx string.quoted.double.html, entity.other.attribute-name.xmlcode.xpx string.quoted.double.html | #BEEA96 | — |
| valid.text.xpx | #17a438 | bold |
| debug.keyword.block.xpx | #369ce0 | bold |
| debug.sql.exec.xpx | #01d3fd | bold |
| debug.line.numeric.xpx | #4EC9B0 | bold |
| debug.comment.block.xpx | #6A9955 | bold |
| debug.sql.exec.catch.begin.xpx, debug.sql.exec.catch.end.xpx, debug.sql.severity.xpx | #ff8800d3 | bold |
| constant.character.keyword-sql.xpx | #8B5DC8 | — |
| meta.tag.other.sql.html string.quoted.double.html | #baa6d4 | — |
| entity.name.function.sql.xpx | #c871e8 | — |
| punctuation.separator.key-value.html | #D4D4D4 | — |
| comment.todo.xpx | #FF8C00 | — |
| comment.info.xpx | #3498DB | — |
| comment.danger.xpx | #FF2D00 | — |
| comment.deprecated.xpx | #474747 | strikethrough |
| comment.atparam.xpx | #569CD6 | — |
| comment.typesparam.xpx | #9CDCFE | — |
| comment.title.xpx | — | bold underline |
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}!`;
}