/** * dsh-edit-approval — browser half. * * Two jobs: * * 1. **Approval-panel enhancement** — rebuilds the panel's diff headline as * red/green per-line blocks (the reason is plain text, so per-line colouring * is impossible without this), adds a disclosure button for tall diffs, and * restores focus to the composer once the approval resolves. * 2. **The bundle's configuration card** on its page in the sidebar's Plugins panel, carrying the two * master switches (see `./settings-card.tsx`). * * Pure DOM injection: no new page, no new popup — the panel's stable data * attribute is the only anchor. All side effects are registered as one * `ctx.effect`, so plugin unload / HMR tears them down. * * The bash feature needs NO panel enhancement: the diff colouring, collapse * button, and focus restore are panel-level and apply to every approval — * multi-line commands already get `pre-wrap` and long ones the collapse. * * Context typing: `ctx.locale` and `ctx.configForms` come from their own * packages' module augmentation. `ctx.slots` does NOT — the package that used * to declare it (`@deepseek-ai/dsh-client-runtime`) is gone in DSH 0.1.7, and * the renderer that provides the service ships first-party only. The registry * is read through the small structural face below, so this half never depends * on a first-party client package's internals. * * @module dsh-edit-approval/client */ import type { Context } from '@deepseek-ai/cordis'; /** Stable plugin name. */ export declare const name = "dsh-edit-approval/client"; /** * Required services: the slot registry (the config card), the locale service * (every string), and the per-entry configuration forms. * * `configForms` is a module-level inject rather than an optional child: the * configuration card is half this plugin's surface, and the web profile always * composes `ui-settings`. */ export declare const inject: string[]; /** * Mount the browser half: inject the plugin's styles, register the * configuration card, and observe approval panels to enhance them. Disposal * unwinds everything. * * @param ctx - client root context carrying `slots`, `locale`, `configForms`. */ export declare function apply(ctx: Context): void;