UnENVerse 0.84.0
Local-first desktop secrets manager — TypeScript frontend
Loading...
Searching...
No Matches
stack.ts File Reference

Classes

class  YMap
 An ordered map: the descriptor's key order is the file's key order. More...

Functions

function export stackAdapters ()
function export stackAdapter (id:string|null|undefined)
function rawField (chunk:SecretChunk, key:string)
function splitList (s:string)
function truthy (s:string)
 Renders a project of a stack adapter's type to the file it produces.

Variables

import descriptorJson from vault core data stack adapters json
 Stack integrations as data (Phase 38, ADR-0144): the TypeScript half of the interpreter for vault-core/data/stack-adapters.json.
import type { ChunkField, Project, SecretChunk } from './types'
kind __pad0__
secret __pad1__
default __pad2__
choices __pad3__
help __pad4__
label __pad5__
singleton __pad6__
fields __pad7__
export interface StackAdapter
label __pad8__
abbr __pad9__
description __pad10__
file __pad11__
chunks __pad12__
starter __pad13__
name __pad14__
raw __pad15__
 The output is one bare string; with no value the file is empty, not a comment header.
output __pad16__
as __pad17__
fmt __pad18__
keep __pad19__
keep __pad20__
node __pad21__
keep __pad22__
node __pad23__
keep __pad24__
keep __pad25__
node __pad26__
type Node
type Y = string | boolean | number | Y[] | YMap
const ADAPTERS = (descriptorJson as unknown as { adapters: StackAdapter[] }).adapters
function stackChunkSpec(adapter:StackAdapter, type:string) scalar(s:string) interface Ctx
 Same rule as scalar in stack.rs: only plain words are written bare.
chunks __pad27__
resolve __pad28__
cur __pad29__
spec __pad30__

Function Documentation

◆ stackAdapters()

function export stackAdapters ( )

◆ stackAdapter()

function export stackAdapter ( id:string|null| undefined)

◆ rawField()

function rawField ( chunk:SecretChunk,
key:string )

◆ splitList()

function splitList ( s:string)

◆ truthy()

function truthy ( s:string)

Renders a project of a stack adapter's type to the file it produces.

A new, empty chunk of this type with the descriptor's defaults filled in. The chunks a new project of this type starts with.

Variable Documentation

◆ json

import descriptorJson from vault core data stack adapters json

Stack integrations as data (Phase 38, ADR-0144): the TypeScript half of the interpreter for vault-core/data/stack-adapters.json.

Prometheus, Grafana and Homepage are not three exporters here. They are three descriptors, and this file and vault-core/src/stack.rs are two readings of the same grammar, pinned by golden fixtures asserted from both sides (tests/stack.test.ts, unv-cli/tests/stack_parity.rs). Keep the two identical in behaviour: the quoting rule, what counts as empty, the order of keys and groups.

◆ type

import type { ChunkField, Project, SecretChunk } from './types'

◆ __pad0__

kind __pad0__

◆ __pad1__

secret __pad1__

◆ __pad2__

default __pad2__

◆ __pad3__

choices __pad3__

◆ __pad4__

help __pad4__

◆ __pad5__

label __pad5__

◆ __pad6__

singleton __pad6__

◆ __pad7__

fields __pad7__

◆ StackAdapter

export interface StackAdapter
Initial value:
{
id: string

◆ __pad8__

label __pad8__

◆ __pad9__

abbr __pad9__

◆ __pad10__

description __pad10__

◆ __pad11__

file __pad11__

◆ __pad12__

chunks __pad12__

◆ __pad13__

starter __pad13__

◆ __pad14__

name __pad14__

◆ __pad15__

raw __pad15__

The output is one bare string; with no value the file is empty, not a comment header.

◆ __pad16__

output __pad16__

◆ __pad17__

as __pad17__

◆ __pad18__

fmt __pad18__

◆ __pad19__

keep __pad19__

◆ __pad20__

keep __pad20__

◆ __pad21__

node __pad21__

◆ __pad22__

keep __pad22__

◆ __pad23__

node __pad23__

◆ __pad24__

keep __pad24__

◆ __pad25__

keep __pad25__

◆ __pad26__

node __pad26__

◆ Node

type Node
Initial value:
=
| string
| number
| boolean
| null
| FieldNode
| MapNode
| ListNode
| EachNode
| SingletonNode
| GroupNode
| EntryNode
| PairsNode
| WhenNode

◆ Y

type Y = string | boolean | number | Y[] | YMap

◆ ADAPTERS

const ADAPTERS = (descriptorJson as unknown as { adapters: StackAdapter[] }).adapters

◆ Ctx

function stackChunkSpec (adapter: StackAdapter, type: string) scalar (s: string) interface Ctx
Initial value:
{
adapter: StackAdapter
export interface StackAdapter
Definition stack.ts:31

Same rule as scalar in stack.rs: only plain words are written bare.

How a stored value becomes text: (raw, isSecret) => text.

◆ __pad27__

chunks __pad27__

◆ __pad28__

resolve __pad28__

◆ __pad29__

cur __pad29__

◆ __pad30__

spec __pad30__