Files
oh-my-opencode/dist/plugin/types.d.ts
T
2026-03-14 04:56:50 +00:00

19 lines
775 B
TypeScript

import type { Plugin, ToolDefinition } from "@opencode-ai/plugin";
export type PluginContext = Parameters<Plugin>[0];
export type PluginInstance = Awaited<ReturnType<Plugin>>;
type ChatHeadersHook = PluginInstance extends {
"chat.headers"?: infer T;
} ? T : (input: unknown, output: unknown) => Promise<void>;
export type PluginInterface = Omit<PluginInstance, "experimental.session.compacting" | "chat.headers"> & {
"chat.headers"?: ChatHeadersHook;
};
export type ToolsRecord = Record<string, ToolDefinition>;
export type TmuxConfig = {
enabled: boolean;
layout: "main-horizontal" | "main-vertical" | "tiled" | "even-horizontal" | "even-vertical";
main_pane_size: number;
main_pane_min_width: number;
agent_pane_min_width: number;
};
export {};