Public declaration syntax from forge-ts/packages/forge-identity/src/glyph.ts Original source SHA-256: 62728b9e8735f5b4c30a9751f0e6a835ad733f5b56f8606b4f13b35326dac02c Function bodies and constant values are omitted. This is not the complete implementation. Source line 28 export interface GlyphColor { /** Red channel (0-255). */ readonly r: number; /** Green channel (0-255). */ readonly g: number; /** Blue channel (0-255). */ readonly b: number; } Source line 45 export function glyphColorRgb(r: number, g: number, b: number): GlyphColor; Source line 55 export function glyphColorToHex(c: GlyphColor): string; Source line 70 export function glyphColorLerp( a: GlyphColor, b: GlyphColor, t: number, ): GlyphColor; Source line 101 export interface GlyphPalette { /** Primary identity color. */ readonly primary: GlyphColor; /** Secondary identity color (hue-offset from primary). */ readonly secondary: GlyphColor; /** Accent color for kind region and highlights. */ readonly accent: GlyphColor; /** Background color (dark, desaturated primary). */ readonly background: GlyphColor; } Source line 127 export const GlyphEntityKind /* type inferred in source */; Source line 136 export type GlyphEntityKind = (typeof GlyphEntityKind)[keyof typeof GlyphEntityKind]; Source line 144 export function parseGlyphEntityKind(s: string): GlyphEntityKind | undefined; Source line 160 export function glyphEntityKindAsU8(kind: GlyphEntityKind): number; Source line 177 export function glyphEntityKindFromU8(v: number): GlyphEntityKind | undefined; Source line 195 export interface GlyphDescriptor { /** The agent's DID string (e.g. `did:oas:l1fe:agent:data-analyst`). */ readonly did: string; /** The entity kind that determines the kind-region visual motif. */ readonly kind: GlyphEntityKind; /** Optional human-readable label rendered below the glyph. */ readonly label?: string; } Source line 207 export const GlyphRenderTarget /* type inferred in source */; Source line 215 export type GlyphRenderTarget = (typeof GlyphRenderTarget)[keyof typeof GlyphRenderTarget]; Source line 221 export interface GlyphRenderOptions { /** The render target (Web or Terminal). */ readonly target: GlyphRenderTarget; /** Desired width in pixels (Web) or columns (Terminal). */ readonly width?: number; /** Desired height in pixels (Web) or rows (Terminal). */ readonly height?: number; /** Optional background color override. */ readonly colorOverride?: GlyphColor; } Source line 235 export const GlyphRenderFormat /* type inferred in source */; Source line 244 export type GlyphRenderFormat = (typeof GlyphRenderFormat)[keyof typeof GlyphRenderFormat]; Source line 250 export interface GlyphRenderResult { /** The output format. */ readonly format: GlyphRenderFormat; /** The rendered data as a string (SVG, ANSI, etc.). */ readonly data: string; /** Width of the rendered output. */ readonly width: number; /** Height of the rendered output. */ readonly height: number; } Source line 283 export async function derivePaletteFromDid( did: string, kind: GlyphEntityKind, ): Promise; Source line 304 export function derivePaletteFromDidSync( did: string, kind: GlyphEntityKind, ): GlyphPalette; Source line 374 export function renderGlyph( descriptor: GlyphDescriptor, options: GlyphRenderOptions, ): GlyphRenderResult;