PineScript Helper
Publisher: salbert11Themes in package: 15
Language support for Pine Script V5 with Syntax Highlighting & Snippets
Language support for Pine Script V5 with Syntax Highlighting & Snippets
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 |
|---|---|---|
| — | #bbbbbbff | — |
| comment, string.comment | #5c6370 | italic |
| string | #e5c07b | — |
| punctuation.definition.template-expression.begin.js,punctuation.definition.template-expression.end.js,punctuation.definition.template-expression.begin.ts,punctuation.definition.template-expression.end.ts | #c678dd | — |
| string.template.js | #e5c07b | — |
| meta.template.expression.js | #abb2bf | — |
| constant.numeric | #c678dd | — |
| string.embedded.begin, string.embedded.end | #c678dd | — |
| string.embedded | #98c379 | — |
| constant.language | #56b6c2 | — |
| constant.character, constant.other | #56b6c2 | — |
| variable.language | #e06c75 | — |
| variable.readwrite, variable.readwrite.other.block | #61afef | — |
| keyword, keyword.operator.logical, keyword.operator.constructor | #e06c75 | — |
| keyword.operator | #e06c75 | — |
| storage | #e06c75 | — |
| storage.type | #56b6c2 | — |
| entity.name.class, entity.name.module, entity.name.type, storage.identifier, support.class | #61afef | — |
| variable.other.object | #61afef | — |
| variable.other.property, variable.other.block | #abb2bf | — |
| entity.other.inherited-class | #98c379 | — |
| entity.name.function, support.function | #98c379 | — |
| variable.parameter | #d19a66 | italic |
| entity.name.function-call | #abb2bf | — |
| function.support.builtin, function.support.core | #98c379 | — |
| entity.name.tag, entity.name.tag.class.js, entity.name.tag.class.jsx | #e06c75 | — |
| entity.name.tag.class, entity.name.tag.id | #56b6c2 | — |
| entity.other.attribute-name | #98c379 | — |
| support.constant | #56b6c2 | — |
| support.type, support.variable | #56b6c2 | — |
| support.dictionary.json | #56b6c2 | — |
| support.type.property-name.css, support.type.property-name.scss, support.type.property-name.less, support.type.property-name.sass | #abb2bf | — |
| support.constant.css, support.constant.scss, support.constant.less, support.constant.sass | #98c379 | — |
| variable.css, variable.scss, variable.less, variable.sass | #56b6c2 | — |
| variable.css.string, variable.scss.string, variable.less.string, variable.sass.string | #e5c07b | — |
| unit.css, unit.scss, unit.less, unit.sass | #c678dd | — |
| function.css, function.scss, function.less, function.sass | #56b6c2 | — |
| support.other.variable | — | |
| invalid | #F8F8F0 | — |
| invalid.deprecated | #F8F8F0 | — |
| structure.dictionary.property-name.json | #56b6c2 | — |
| string.detected-link | #61afef | — |
| meta.diff, meta.diff.header | #75715E | — |
| markup.deleted | #c678dd | — |
| markup.inserted | #e5c07b | — |
| markup.changed | #e5c07b | — |
| constant.numeric.line-number.find-in-files - match | #56b6c2A0 | — |
| entity.name.filename.find-in-files | #e5c07b | — |
| markup.italic, markup.italic.markdown | — | italic |
| punctuation.definition.italic.markdown | #696969 | none |
| markup.underline.link.markdown | #61afef | — |
| markup.bold.markdown | — | bold |
| punctuation.definition.bold.markdown | #696969 | none |
| markup.heading.markdown | #e06c75 | bold |
| punctuation.definition.heading.markdown | #696969 | none |
| markup.quote.markdown | #98c379 | — |
| meta.separator.markdown | #c678dd | bold |
| markup.raw.inline.markdown, markup.raw.block.markdown | #56b6c2 | — |
| punctuation.definition.list_item.markdown | #ffffff | bold |
| token.info-token | #6796e6 | — |
| token.warn-token | #cd9731 | — |
| token.error-token | #f44747 | — |
| token.debug-token | #b267e6 | — |
| punctuation.definition.string.begin.ps, punctuation.definition.string.end.ps, constant.character.escaped.ps, string.quoted.double.ps, string.quoted.single.ps | #388e3c | |
| meta.other.ps | #787b86 | bold |
| keyword.control.import.ps, keyword.control.export.ps, keyword.control.as.ps | #42bba6 | |
| punctuation.separator.ps, entity.name.type.class.ps, constant.numeric.ps | #5b9cf6 | |
| support.type.primitive.entity.ps, punctuation.accessor.entity.ps, entity.name.function.ps | #3178f4 | |
| keyword.operator.new.ps | #3178f4 | |
| variable.other.readwrite.ps, punctuation.accessor.ps | #d1d4dc | |
| support.constant.ps, support.constant.property.ps, constant.language.boolean.true.ps, constant.language.boolean.false.ps, constant.numeric.decimal.hex.ps, punctuation.accessor.constant.ps | #f57b7f | |
| support.function.ps, support.function.property.ps, punctuation.accessor.function.ps, keyword.operator.new.support.ps | #5b9cf6 | |
| constant.numeric.decimal.ps | #f57f17 | |
| storage.type.class.ps | #5b9cf6 | |
| support.type.primitive.ps | #42bba6 | bold |
| storage.type.function.ps, storage.type.type.ps, storage.type.ps | #42bba6 | |
| keyword.operator.word.ps, keyword.control.conditional.ps, keyword.control.switch.ps, keyword.control.loop.ps, storage.type.function.arrow.ps, keyword.operator.ternary.ps | #42bba6 | |
| punctuation.separator.comma.ps | #42bba6 | |
| meta.brace.round.ps, meta.brace.square.ps | #d1d4dc | |
| constant.character.format.placeholder.other.ps, punctuation.separator.comma.placeholder.ps, constant.numeric.decimal.placeholder.ps, variable.parameter.placeholder.ps | #388e3c | |
| keyword.operator.assignment.ps | #42bba6 | |
| keyword.operator.assignment.compound.ps, keyword.operator.arithmetic.ps, keyword.operator.relational.ps, keyword.operator.comparison.ps | #42bba6 | |
| punctuation.definition.generic.begin.ps, punctuation.definition.generic.end.ps | #d1d4dc | |
| punctuation.definition.annotation.ps | #787b86 | |
| variable.parameter.ps | #d1d4dc | |
| support.type.primitive.import.ps, punctuation.accessor.import.ps, keyword.operator.new.import.ps, entity.name.namespace.ps | #b968c7 | |
| comment.line.double-slash.ps, meta.annotation.ps, meta.numeric.ps, meta.assignment.ps, meta.section.embedded.other.ps | #787b86 | |
| meta.annotation.identifier.ps | #787b86 | bold |
TypeScript sample highlighted with this variant's colors and tokenColors.
Loading...
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}!`;
}
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}!`;
}