Chapter One
Publisher: nenetsThemes in package: 1
A cozy light theme with soft paper tones and pink touches.
A cozy light theme with soft paper tones and pink touches.
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 |
|---|---|---|
| variable, variable.other.readwrite, variable.other.constant, variable.other.object, variable.parameter, punctuation.decorator, meta.decorator.ts meta.brace.round.ts, punctuation.separator.key-value.ts, meta.object-literal.key, meta.object-literal.key.ts, support.type.property-name, variable.other.object.property.ts, punctuation, punctuation.definition, punctuation.separator, meta.brace, punctuation.terminator.statement.ts | #000000 | — |
| keyword.control, keyword.operator, keyword.other, storage.modifier.ts, storage.type, storage.type.function.ts, keyword.control.import, keyword.control.export, keyword.control.from, keyword.operator.expression.typeof.ts, variable.language.this.ts, keyword.operator.optional.ts, keyword.operator.logical.ts, keyword.operator.new.ts, keyword.operator.new.tsx, new.expr.ts, entity.other.attribute-name.jsx, entity.other.attribute-name.tsx | #6A7680 | — |
| entity.name.type.interface, entity.name.type, entity.name.type.class, support.type.primitive.ts, entity.name.function, support.function, meta.class.ts meta.method.declaration.ts entity.name.function.ts, meta.decorator.ts meta.function-call.ts entity.name.function.ts, entity.name.tag.jsx, entity.name.tag.tsx, support.class.component.tsx, support.class.component.jsx, constant.numeric | #E91E63 | — |
| string, string.quoted.single, string.quoted.double, string.quoted.single.ts, string.quoted.single.tsx, string.quoted.double.tsx, string.template, string.template.tsx, string.quoted.template, punctuation.definition.string.begin.ts, punctuation.definition.string.end.ts, punctuation.definition.string.template.end.tsx, constant.other.symbol, constant.character.escape, string.regexp | #0076c5 | — |
| comment, punctuation.definition.comment | #CC7740 | — |
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}!`;
}