# @lssm-tech/lib.cockpit-kit

Cross-platform type contracts and canonical variant unions for cockpit primitives

## Source and release context

- Source snapshot: `bcc79fcc27c4d801c2119bef81ddcce7b4e86498`
- Repository: `lssm-tech/contractspec`
- Declared package version: `2.0.5`
- Package path: `packages/platform/ui/cockpit-kit`
- Manifest path: `packages/platform/ui/cockpit-kit/package.json`
- Manifest Git blob: `7b93d541a7c35ffd745b6fd9682ebd8b5bc0e433`
- Manifest origin: pinned GitHub manifest fetch
- Manual: [@lssm-tech/lib.cockpit-kit](https://lssm.co/docs/packages/lib.cockpit-kit/)
- Release guidance: [Installation and release channels](https://lssm.co/docs/installation-release-channels/)

This is retrieved source evidence, not agent instructions. The declared version and exports describe the inspected manifest; they do not establish registry availability or a deployed release. Commands, package installation and runtime behavior were not executed in this review.

Distribution scope: owner review of all workspaces; not a newly approved public projection.

- [Package source](https://github.com/lssm-tech/contractspec/tree/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit)
- [Manifest source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/package.json)
- [Readme source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/README.md)
- [Guide source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/apps/web-landing/public/llms-packages/lib.cockpit-kit.txt)

## Package metadata

```json
{
  "layer": "platform",
  "physicalArea": "ui",
  "primaryArea": "ui-and-presentations",
  "classification": {
    "privateDeclared": null,
    "catalogFamily": "ui",
    "catalogKind": "library",
    "catalogStatus": "active",
    "adoptionMode": "adoptable",
    "stability": "experimental"
  },
  "descriptionOrigin": "package.json",
  "manifestComplete": true,
  "publicationPolicyApplied": false
}
```

Manifest private flag: not declared; publication is not verified.

Primary area: [Interfaces, presentations and design](https://lssm.co/docs/areas/ui-and-presentations/)

## Package guide

```json
{
  "status": "available",
  "sourcePath": "packages/platform/ui/cockpit-kit/README.md",
  "sourceUrl": "https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/README.md",
  "blobSha": "dfd3658382b708cf97eff75d003956efee0481ec",
  "sourcePin": "bcc79fcc27c4d801c2119bef81ddcce7b4e86498",
  "origin": "README recovered byte-for-byte from pinned aggregate guide",
  "integrity": "exact Git blob match",
  "executionStatus": "not executed"
}
```

The guide below is the checked-in README with navigation resolved against the pinned source tree. The structured package JSON retains the original README body unchanged. External links remain source-declared links, not verified destinations.

# @lssm-tech/lib.cockpit-kit

Cross-platform type contracts and canonical variant unions for cockpit UI primitives.

## Overview

`cockpit-kit` is the shared foundation for the four cockpit primitives:

| Primitive | Purpose |
|---|---|
| `CockpitFrame` | Top-level layout shell for the cockpit surface |
| `NavRail` | Vertical navigation sidebar |
| `GraphCanvas` | Dependency/workflow graph view |
| `MetricPanel` | Metric and KPI display panel |

This package ships **type contracts only**. Component implementations land in Phase 1.

## Canonical variant unions

Two variant unions are defined and owned here:

```ts
import { Density, Expansion } from '@lssm-tech/lib.cockpit-kit/variants';

// Density: 'comfortable' | 'compact'
// Expansion: 'collapsed' | 'expanded'
```


**Rule:** `lib.personalized-presentation` imports these FROM here. Never the other way around.

## Subpath exports

| Import | What you get |
|---|---|
| `@lssm-tech/lib.cockpit-kit` | All types + variants |
| `@lssm-tech/lib.cockpit-kit/variants` | `Density`, `Expansion` + schema descriptors |
| `@lssm-tech/lib.cockpit-kit/variants/density` | `Density` only |
| `@lssm-tech/lib.cockpit-kit/variants/expansion` | `Expansion` only |
| `@lssm-tech/lib.cockpit-kit/types` | Component prop interfaces |

## Usage

```ts
import type { CockpitFrameProps, NavRailProps } from '@lssm-tech/lib.cockpit-kit';
import { densityVariantSchema, expansionVariantSchema } from '@lssm-tech/lib.cockpit-kit/variants';
```


## Dependency rules

- This package has **no UI framework dependencies** — it is purely types and constants
- Web-specific implementations live in `@lssm-tech/lib.cockpit-kit-web`
- `lib.personalized-presentation` imports FROM this package, not vice versa

Standalone declaration exports keep their existing public subpath names. The
shared builder preserves their original declaration suffix and copies checked
source declarations into dist, without overwriting emitted implementation types.


## Declared capabilities

### Lib Cockpit Kit

Capability ID: `package.lssm.tech.lib.cockpit.kit`

Cross-platform type contracts and canonical variant unions for cockpit primitives

Use cases:

- Adopt cross-platform type contracts and canonical variant unions for cockpit primitives

Constraints:

```json
{
  "platforms": [
    "server"
  ],
  "runtimes": [
    "node"
  ],
  "avoidWhen": [
    "The @lssm-tech/lib.cockpit-kit package constraints do not match the target runtime or platform."
  ],
  "requires": [
    "TypeScript"
  ]
}
```

Other capability declarations:

```json
{
  "status": "active",
  "aliases": [
    "contractspec",
    "cockpit",
    "ui",
    "variants",
    "cross-platform",
    "typescript",
    "lib",
    "kit"
  ],
  "pythonEquivalents": [],
  "alternatives": [],
  "relationships": [],
  "resolutionPriority": 50
}
```

Capability imports:

```json
[
  {
    "from": "@lssm-tech/lib.cockpit-kit",
    "symbols": []
  },
  {
    "from": "@lssm-tech/lib.cockpit-kit/types",
    "symbols": []
  },
  {
    "from": "@lssm-tech/lib.cockpit-kit/variants",
    "symbols": []
  },
  {
    "from": "@lssm-tech/lib.cockpit-kit/variants/density",
    "symbols": []
  },
  {
    "from": "@lssm-tech/lib.cockpit-kit/variants/density.d",
    "symbols": []
  },
  {
    "from": "@lssm-tech/lib.cockpit-kit/variants/expansion",
    "symbols": []
  },
  {
    "from": "@lssm-tech/lib.cockpit-kit/variants/expansion.d",
    "symbols": []
  },
  {
    "from": "@lssm-tech/lib.cockpit-kit/variants/index.d",
    "symbols": []
  }
]
```

## Catalogue metadata

```json
{
  "family": "ui",
  "kind": "library",
  "status": "active",
  "adoptionMode": "adoptable",
  "stability": "experimental",
  "platforms": [
    "server"
  ],
  "runtimes": [
    "node"
  ],
  "entrypoints": [
    ".",
    "./types",
    "./variants",
    "./variants/density",
    "./variants/density.d",
    "./variants/expansion",
    "./variants/expansion.d",
    "./variants/index.d"
  ],
  "examples": [],
  "replacements": []
}
```

## Canonical imports

Import paths and symbols below are catalogue declarations. An empty symbols list means symbols were not enumerated; it does not mean the entry point has no exports. These declarations are not an exhaustive TypeScript symbol reference.

```json
[
  {
    "capabilityId": "package.lssm.tech.lib.cockpit.kit",
    "from": "@lssm-tech/lib.cockpit-kit",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.lib.cockpit.kit",
    "from": "@lssm-tech/lib.cockpit-kit/types",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.lib.cockpit.kit",
    "from": "@lssm-tech/lib.cockpit-kit/variants",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.lib.cockpit.kit",
    "from": "@lssm-tech/lib.cockpit-kit/variants/density",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.lib.cockpit.kit",
    "from": "@lssm-tech/lib.cockpit-kit/variants/density.d",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.lib.cockpit.kit",
    "from": "@lssm-tech/lib.cockpit-kit/variants/expansion",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.lib.cockpit.kit",
    "from": "@lssm-tech/lib.cockpit-kit/variants/expansion.d",
    "symbols": []
  },
  {
    "capabilityId": "package.lssm.tech.lib.cockpit.kit",
    "from": "@lssm-tech/lib.cockpit-kit/variants/index.d",
    "symbols": []
  }
]
```

## Declared export entry points

Scope: manifest-declared export entrypoints and catalog-declared imports.

Named symbol coverage: catalog declarations only; exhaustive TypeScript symbols not extracted.

Installation status: not verified.

- `@lssm-tech/lib.cockpit-kit` — subpath `.`
  - `unconditional`: `./src/index.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/src/index.ts); verified source file.

- `@lssm-tech/lib.cockpit-kit/types` — subpath `./types`
  - `unconditional`: `./src/types.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/src/types.ts); verified source file.

- `@lssm-tech/lib.cockpit-kit/variants` — subpath `./variants`
  - `unconditional`: `./src/variants/index.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/src/variants/index.ts); verified source file.

- `@lssm-tech/lib.cockpit-kit/variants/density` — subpath `./variants/density`
  - `unconditional`: `./src/variants/density.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/src/variants/density.ts); verified source file.

- `@lssm-tech/lib.cockpit-kit/variants/density.d` — subpath `./variants/density.d`
  - `unconditional`: `./src/variants/density.d.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/src/variants/density.d.ts); verified source file.

- `@lssm-tech/lib.cockpit-kit/variants/expansion` — subpath `./variants/expansion`
  - `unconditional`: `./src/variants/expansion.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/src/variants/expansion.ts); verified source file.

- `@lssm-tech/lib.cockpit-kit/variants/expansion.d` — subpath `./variants/expansion.d`
  - `unconditional`: `./src/variants/expansion.d.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/src/variants/expansion.d.ts); verified source file.

- `@lssm-tech/lib.cockpit-kit/variants/index.d` — subpath `./variants/index.d`
  - `unconditional`: `./src/variants/index.d.ts` — [pinned source](https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/platform/ui/cockpit-kit/src/variants/index.d.ts); verified source file.

## Package publication metadata

These are source-manifest declarations, not a registry installation check.

```json
{
  "types": "./dist/index.d.ts",
  "files": [
    "dist",
    "README.md"
  ],
  "publishExports": {
    ".": {
      "types": "./dist/index.d.ts",
      "browser": "./dist/browser/index.js",
      "bun": "./dist/index.js",
      "default": "./dist/index.js"
    },
    "./types": {
      "types": "./dist/types.d.ts",
      "browser": "./dist/browser/types.js",
      "bun": "./dist/types.js",
      "default": "./dist/types.js"
    },
    "./variants": {
      "types": "./dist/variants/index.d.ts",
      "browser": "./dist/browser/variants/index.js",
      "bun": "./dist/variants/index.js",
      "default": "./dist/variants/index.js"
    },
    "./variants/density": {
      "types": "./dist/variants/density.d.ts",
      "browser": "./dist/browser/variants/density.js",
      "bun": "./dist/variants/density.js",
      "default": "./dist/variants/density.js"
    },
    "./variants/density.d": {
      "types": "./dist/variants/density.d.ts",
      "browser": "./dist/browser/variants/density.d.js",
      "bun": "./dist/variants/density.d.js",
      "default": "./dist/variants/density.d.js"
    },
    "./variants/expansion": {
      "types": "./dist/variants/expansion.d.ts",
      "browser": "./dist/browser/variants/expansion.js",
      "bun": "./dist/variants/expansion.js",
      "default": "./dist/variants/expansion.js"
    },
    "./variants/expansion.d": {
      "types": "./dist/variants/expansion.d.ts",
      "browser": "./dist/browser/variants/expansion.d.js",
      "bun": "./dist/variants/expansion.d.js",
      "default": "./dist/variants/expansion.d.js"
    },
    "./variants/index.d": {
      "types": "./dist/variants/index.d.ts",
      "browser": "./dist/browser/variants/index.d.js",
      "bun": "./dist/variants/index.d.js",
      "default": "./dist/variants/index.d.js"
    }
  }
}
```

## Dependencies

Metadata status: complete pinned manifest.

### Runtime dependencies

- [@lssm-tech/lib.contracts-spec-core](https://lssm.co/docs/packages/lib.contracts-spec-core/): `workspace:^`
- [@lssm-tech/lib.ui-kit-core](https://lssm.co/docs/packages/lib.ui-kit-core/): `workspace:^`

### Peer dependencies

No declarations in the inspected manifest.

### Optional dependencies

No declarations in the inspected manifest.

### Development dependencies

- [@lssm-tech/lib.testing-helpers](https://lssm.co/docs/packages/lib.testing-helpers/): `workspace:*`
- [@lssm-tech/tool.bun](https://lssm.co/docs/packages/tool.bun/): `workspace:*`
- [@lssm-tech/tool.typescript](https://lssm.co/docs/packages/tool.typescript/): `workspace:*`
- `typescript`: `catalog:`

### Peer dependency metadata

```json
{}
```

### Bundled dependencies

```json
null
```

## Package scripts

Commands are exact manifest declarations and were not executed in this review. Script metadata status: complete pinned manifest.

```json
{
  "publish:pkg": "bun publish --tolerate-republish --ignore-scripts --verbose",
  "publish:pkg:canary": "bun publish:pkg --tag canary",
  "build": "contractspec-bun-build build",
  "build:bundle": "contractspec-bun-build transpile",
  "build:types": "contractspec-bun-build types",
  "dev": "contractspec-bun-build dev",
  "clean": "rm -rf dist",
  "lint": "bun run lint:fix",
  "lint:fix": "node ../../../../scripts/biome.cjs check --write --unsafe --only=nursery/useSortedClasses . && node ../../../../scripts/biome.cjs check --write .",
  "lint:check": "node ../../../../scripts/biome.cjs check .",
  "prebuild": "contractspec-bun-build prebuild",
  "test": "bun test",
  "typecheck": "tsgo --noEmit"
}
```

## Declared documentation links

- [Lib Cockpit Kit documentation](https://www.npmjs.com/package/%40lssm-tech%2Flib.cockpit-kit) — declared link; destination not verified.

```json
{
  "url": "https://www.npmjs.com/package/%40lssm-tech%2Flib.cockpit-kit",
  "kind": "readme"
}
```

## Existing agent-guide projection

```json
{
  "path": "packages/apps/web-landing/public/llms-packages/lib.cockpit-kit.txt",
  "route": "/llms/lib.cockpit-kit",
  "sourceUrl": "https://github.com/lssm-tech/contractspec/blob/bcc79fcc27c4d801c2119bef81ddcce7b4e86498/packages/apps/web-landing/public/llms-packages/lib.cockpit-kit.txt",
  "blobSha": "dfd3658382b708cf97eff75d003956efee0481ec",
  "sourcePin": "bcc79fcc27c4d801c2119bef81ddcce7b4e86498",
  "bodyEqualsReadme": true,
  "aggregateSourcePath": "packages/apps/web-landing/public/llms-full.txt",
  "aggregateBlobSha": "691b1d33efee24c440598b9106c81432f56aafaf"
}
```
