# configuration/strings/figure.strings.ts

> 73 lines of code and 18 definitions.

Tree: GovLab Docs
Language: typescript
Layer: product
Canonical: https://banes-lab.com/anatomy/docs#file-docs-configuration-strings-figure-strings-ts
Source text: https://banes-lab.com/source/docs/configuration/strings/figure.strings.ts.txt

Listed in [configuration/strings](https://banes-lab.com/api/source/docs/configuration/strings.md), after [configuration/strings/drift.strings.ts](https://banes-lab.com/source/docs/configuration/strings/drift.strings.ts.md) and before [configuration/strings/finding.strings.ts](https://banes-lab.com/source/docs/configuration/strings/finding.strings.ts.md).

## Definitions

- `dataFlowTitle` (lexical_declaration, line 42, exported)
- `lifecycleTitle` (lexical_declaration, line 50, exported)
- `typeRelationshipTitle` (lexical_declaration, line 66, exported)
- `moreNodes` (lexical_declaration, line 74, exported)
- `chartsHeading` (lexical_declaration, line 78, exported)
- `legendLine` (lexical_declaration, line 82, exported)
- `KIND_LEGEND` (lexical_declaration, line 1, exported)
- `DIAGRAM_TITLES` (lexical_declaration, line 11, exported)
- `DIAGRAM_LEGENDS` (lexical_declaration, line 22, exported)
- `DIAGRAM_DESCRIPTIONS` (lexical_declaration, line 31, exported)
- `flowTitle` (lexical_declaration, line 46, exported)
- `orchestrationTitle` (lexical_declaration, line 54, exported)
- `stateTitle` (lexical_declaration, line 58, exported)
- `structureTitle` (lexical_declaration, line 62, exported)
- `truncationNote` (lexical_declaration, line 70, exported)
- `SOURCES_SUMMARY` (lexical_declaration, line 86, exported)
- `SOURCES_TABLE_HEAD` (lexical_declaration, line 88, exported)
- `SOURCES_CLOSE` (lexical_declaration, line 90, exported)

## Contained in

- [configuration/strings](https://banes-lab.com/anatomy/docs/folder-docs-configuration-strings.md)

## Used by

- [core/formatters/figure.formatter.ts](https://banes-lab.com/source/docs/core/formatters/figure.formatter.ts.md)
- [core/plugins/diagram.definition.plugin.ts](https://banes-lab.com/source/docs/core/plugins/diagram.definition.plugin.ts.md)
- [core/plugins/diagram.dependency.plugin.ts](https://banes-lab.com/source/docs/core/plugins/diagram.dependency.plugin.ts.md)
- [core/plugins/diagram.invocation.plugin.ts](https://banes-lab.com/source/docs/core/plugins/diagram.invocation.plugin.ts.md)
- [core/plugins/diagram.shell.plugin.ts](https://banes-lab.com/source/docs/core/plugins/diagram.shell.plugin.ts.md)

## Linked from

- [core/formatters](https://banes-lab.com/anatomy/docs/folder-docs-core-formatters.md)
- [core/plugins](https://banes-lab.com/anatomy/docs/folder-docs-core-plugins.md)

## Source

```typescript
export const KIND_LEGEND: readonly string[] = [
    "green = entry/factory",
    "amber = collaborator",
    "red = decision/gate",
    "blue = hook",
    "purple = registry/store",
    "gray = method",
    "solid arrow = call, thick = hook, dotted = teardown/data",
];

export const DIAGRAM_TITLES = {
    dataFlow: "Data flow",
    dependency: "Dependencies",
    flow: "Logical flow",
    lifecycle: "Lifecycle (npm scripts)",
    sequence: "Orchestration",
    state: "Lifecycle",
    structure: "Structure",
    typeRelationship: "Type relationships",
} as const;

export const DIAGRAM_LEGENDS = {
    dataFlow: "dotted arrow = construction / data dependency",
    dependency: ["dotted arrow = @govlab sibling dependency"],
    lifecycle: ["green = npm script", "amber = tool", "purple = file", "arrow = runs"],
    sequence: ["numbered = call order", "async arrow -) = an awaited call from the entry to a collaborator"],
    state: ["[*] = initial state", "arrow = a transition in the detected transition table"],
    typeRelationship: ["<|.. = extends/implements", "o-- = has-a (property type)", "..> = uses (type alias)"],
} as const;

export const DIAGRAM_DESCRIPTIONS = {
    dataFlow: "construction and data-flow dependency wiring resolved from source",
    flow: "entry to exit call flow with branches, hooks, and teardown",
    lifecycle: "how npm scripts compose the run, build, dev, and test lifecycle",
    sequence: "ordered awaited collaborator calls from the entry",
    state: "states and transitions detected from the status union and transition table",
    structure: "factory, collaborators, and registries",
    typeRelationship:
        "exported type relationships resolved from source: realization = extends/implements, aggregation = has-a, dependency = uses",
} as const;

export const dataFlowTitle = function dataFlowTitle(module: string): string {
    return `${module} data flow`;
};

export const flowTitle = function flowTitle(module: string, caption: string): string {
    return `${module} flow: ${caption}`;
};

export const lifecycleTitle = function lifecycleTitle(module: string): string {
    return `${module} npm-script lifecycle`;
};

export const orchestrationTitle = function orchestrationTitle(module: string): string {
    return `${module} orchestration`;
};

export const stateTitle = function stateTitle(module: string): string {
    return `${module} lifecycle`;
};

export const structureTitle = function structureTitle(module: string): string {
    return `${module} structure`;
};

export const typeRelationshipTitle = function typeRelationshipTitle(module: string): string {
    return `${module} type relationships`;
};

export const truncationNote = function truncationNote(budget: number, total: number): string {
    return `showing ${budget} of ${total} data edges (budget)`;
};

export const moreNodes = function moreNodes(count: number): string {
    return `plus ${count} more`;
};

export const chartsHeading = function chartsHeading(module: string): string {
    return `# ${module} — architecture charts`;
};

export const legendLine = function legendLine(legend: readonly string[]): string {
    return `Legend: ${legend.join(" - ")}`;
};

export const SOURCES_SUMMARY = "<details><summary>Node sources</summary>";

export const SOURCES_TABLE_HEAD: readonly string[] = ["| Node | Source |", "| --- | --- |"];

export const SOURCES_CLOSE = "</details>";
```
