avtc-pi-settings-ui 1.0.12 → 1.0.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +16 -12
  2. package/package.json +5 -3
package/README.md CHANGED
@@ -50,18 +50,6 @@ The settings modal queues behind other open dialogs (instead of stealing keyboar
50
50
 
51
51
  Without ui-components the settings modal still works — it just opens immediately rather than queuing.
52
52
 
53
- ## Public API
54
-
55
- | Export | Purpose |
56
- |---|---|
57
- | `registerSettingsCommand(pi, schema, opts)` | Register the `/<name>:settings` command + modal; returns the settings handle you read from at runtime |
58
- | `settingsFilePaths(name)` | Global + project file paths for `<name>`'s settings — `~/.pi/agent/<name>-settings.json` and `<cwd>/.pi/<name>-settings.json` (spread into the schema) |
59
- | `SettingSchema`, `SettingsSchema` | Define your settings and tabs |
60
- | `StorageLevel`, `SettingsHandle`, `RegisterSettingsOptions` | Types: storage levels (`session`/`project`/`global`), the returned handle, the options bag |
61
- | `PresetsSource`, `PresetPair`, `PresetElement`, `PresetValue` | Author `presets`: full pairs or bare values (string/number/boolean/null) |
62
- | `registerTypeDefinition`, `TypeDefinition`, `TypeContext` | Register custom types (7 built-ins ship pre-registered) |
63
- | `formatHumanDuration` | Human form of a duration |
64
-
65
53
  ## Usage
66
54
 
67
55
  ```ts
@@ -96,6 +84,18 @@ const settings = registerSettingsCommand(pi, schema, {
96
84
  settings.getSettings();
97
85
  ```
98
86
 
87
+ ## Public API
88
+
89
+ | Export | Purpose |
90
+ |---|---|
91
+ | `registerSettingsCommand(pi, schema, opts)` | Register the `/<name>:settings` command + modal; returns the settings handle you read from at runtime |
92
+ | `settingsFilePaths(name)` | Global + project file paths for `<name>`'s settings — `~/.pi/agent/<name>-settings.json` and `<cwd>/.pi/<name>-settings.json` (spread into the schema) |
93
+ | `SettingSchema`, `SettingsSchema` | Define your settings and tabs |
94
+ | `StorageLevel`, `SettingsHandle`, `RegisterSettingsOptions` | Types: storage levels (`session`/`project`/`global`), the returned handle, the options bag |
95
+ | `PresetsSource`, `PresetPair`, `PresetElement`, `PresetValue` | Author `presets`: full pairs or bare values (string/number/boolean/null) |
96
+ | `registerTypeDefinition`, `TypeDefinition`, `TypeContext` | Register custom types (7 built-ins ship pre-registered) |
97
+ | `formatHumanDuration` | Human form of a duration |
98
+
99
99
  ## Setting types
100
100
 
101
101
  Every setting has a `type` resolved through a first-class `TypeDefinition` registry. Seven built-ins ship out of the box:
@@ -124,6 +124,10 @@ Choose your storage levels via `storageLevels` on `registerSettingsCommand` (def
124
124
 
125
125
  **How edits save:** with a single file level (`global` or `project`), each edit writes straight to that file, so every pi instance reads the same on-disk truth. With multiple levels (or `session`), edits are held as a draft until you press a save key — `Ctrl+S` saves project, `Ctrl+D` saves global (each only when its level is enabled).
126
126
 
127
+ ## Claude Code port
128
+
129
+ A Claude Code (mods) port of this library lives in [`claude/README.md`](claude/README.md).
130
+
127
131
  ## Full suite
128
132
 
129
133
  Check out the full suite of related extensions, [avtc-pi](https://github.com/avtc/avtc-pi) — deterministic feature development, subagent delegation, working-memory, behavioral learning, parallel-work guardrails, durable decisions, notifications, and more.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "avtc-pi-settings-ui",
3
- "version": "1.0.12",
3
+ "version": "1.0.13",
4
4
  "description": "A schema-driven settings UI for pi extensions — define your settings, get a tabbed modal, a /<name>:settings command, and layered persistence.",
5
5
  "type": "module",
6
6
  "main": "./index.ts",
@@ -18,9 +18,11 @@
18
18
  "typecheck": "tsc --noEmit --incremental --tsBuildInfoFile node_modules/.cache/tsc.tsbuildinfo",
19
19
  "test:unit": "node scripts/test-low-priority.cjs vitest run",
20
20
  "test:watch": "node scripts/test-low-priority.cjs vitest",
21
- "test": "node scripts/test-low-priority.cjs \"node scripts/run-parallel.cjs \"npm run lint:optional-params :: npm run lint:bare-literals :: npm run lint:design-refs :: npm run lint:bundled-imports :: npm run lint:as-never :: npm run lint :: npm run typecheck :: npm run knip :: npm run dupes\" && vitest run\"",
21
+ "test": "node scripts/test-low-priority.cjs \"node scripts/run-parallel.cjs \"npm run lint:optional-params :: npm run lint:bare-literals :: npm run lint:design-refs :: npm run lint:bundled-imports :: npm run lint:as-never :: npm run lint :: npm run typecheck :: npm run typecheck:claude :: npm run build:claude :: npm run knip :: npm run dupes\" && vitest run\"",
22
22
  "dupes": "jscpd src/ --exit-code --threshold 0.01",
23
- "lint:as-never": "node scripts/no-as-never.cjs src/ tests/ index.ts"
23
+ "lint:as-never": "node scripts/no-as-never.cjs src/ tests/ index.ts",
24
+ "typecheck:claude": "tsc -p claude/tsconfig.json",
25
+ "build:claude": "tsc -p claude/tsconfig.build.json"
24
26
  },
25
27
  "dependencies": {
26
28
  "avtc-pi-logger": "^1.0.3",