mirror of
https://github.com/badlogic/pi-mono.git
synced 2026-11-06 23:44:36 +00:00
* feat(coding-agent): publish configuration schemas * fix(coding-agent): preserve config schema metadata * fix(coding-agent): align schemas with public contracts * fix(ai): place compatibility schema with providers * fix(ai,coding-agent): align configuration schema contracts * fix(ai): reuse session affinity schema * docs(coding-agent): document strict theme validation * fix(ai,coding-agent): align runtime and generated schemas * fix(ai,coding-agent): centralize configuration schema contracts * fix(ai,coding-agent): preserve schema validation contracts * fix(coding-agent): validate keybinding schema grammar * fix(ai,coding-agent): refine configuration schemas * fix(ai,tui,coding-agent): align schemas with runtime behavior * fix(tui): normalize shifted symbol keybindings * fix(ai): preserve compatibility auto-detection
21 lines
612 B
TypeScript
21 lines
612 B
TypeScript
import { type TSchema, Type } from "typebox";
|
|
import { KeybindingValueSchema, keybindingValueSchema } from "./key-id-schema.ts";
|
|
import { KEYBINDINGS } from "./keybindings.ts";
|
|
|
|
export { KeybindingValueSchema } from "./key-id-schema.ts";
|
|
|
|
const properties: Record<string, TSchema> = {
|
|
$schema: Type.Optional(Type.String()),
|
|
};
|
|
|
|
for (const [id, definition] of Object.entries(KEYBINDINGS)) {
|
|
properties[id] = Type.Optional(
|
|
keybindingValueSchema({
|
|
description: definition.description,
|
|
}),
|
|
);
|
|
}
|
|
|
|
export const KeybindingsSchema = Type.Object(properties, {
|
|
additionalProperties: KeybindingValueSchema,
|
|
});
|