agent-afk 5.19.3 → 5.19.4

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.
@@ -10,6 +10,7 @@ export interface CommitModeInput {
10
10
  committedBand: string[];
11
11
  committedBandBottomRow: number;
12
12
  committedBandPaintedRows: number;
13
+ geometryStale: boolean;
13
14
  }
14
15
  export interface CommitMode {
15
16
  fitsAboveFrame: boolean;
@@ -0,0 +1,17 @@
1
+ export interface BandReflowResult {
2
+ rows: string[];
3
+ paintedRows: number;
4
+ }
5
+ export declare function reflowBandSplit(band: readonly string[], paintedRows: number, width: number): BandReflowResult;
6
+ export interface BandReflowCache {
7
+ readonly band: readonly string[];
8
+ readonly paintedRows: number;
9
+ readonly width: number;
10
+ }
11
+ export interface BandReflowHost {
12
+ committedBand: string[];
13
+ committedBandPaintedRows: number;
14
+ bandReflowCache: BandReflowCache | null;
15
+ }
16
+ export declare function reflowCommittedBandToWidth(self: BandReflowHost, width: number): void;
17
+ export declare function withAutowrapDisabled(stream: NodeJS.WriteStream, paint: () => void): void;
@@ -1,4 +1,5 @@
1
1
  import type { LogUpdateFn, CompositorScrollRegionGuard } from './terminal-compositor.types.js';
2
+ import { type BandReflowCache } from './terminal-compositor.band-reflow.js';
2
3
  export interface CommittedBandHost {
3
4
  repaint(): void;
4
5
  debugLog(stage: string, extra?: Record<string, unknown>): void;
@@ -6,6 +7,7 @@ export interface CommittedBandHost {
6
7
  committedBandTopRow: number;
7
8
  committedBandBottomRow: number;
8
9
  committedBandPaintedRows: number;
10
+ bandReflowCache: BandReflowCache | null;
9
11
  committing: boolean;
10
12
  commitInFlight: boolean;
11
13
  hasCommitted: boolean;
@@ -13,6 +15,7 @@ export interface CommittedBandHost {
13
15
  top: number;
14
16
  bottom: number;
15
17
  } | null;
18
+ bandGeometryStale: boolean;
16
19
  anchorRow: number | undefined;
17
20
  armed: boolean;
18
21
  logUpdate: LogUpdateFn | null;
@@ -6,6 +6,7 @@ import { SpinnerController } from './input/spinner.js';
6
6
  import { CaretBlinkController } from './input/caret-blink.js';
7
7
  import type { StdinClaimHandle } from './input/stdin-claim.js';
8
8
  import { type CompositorInputMode, type CompositorScrollRegionGuard, type KeyInfo, type LogUpdateFn, type PickerController, type SubmissionPayload, type TerminalCompositorOptions, type SuggestEngine, type SuggestContext } from './terminal-compositor.types.js';
9
+ import type { BandReflowCache } from './terminal-compositor.band-reflow.js';
9
10
  export type { CompositorInputMode, CompositorScrollRegionGuard, PickerController, SubmissionPayload, SuggestContext, SuggestEngine, TerminalCompositorOptions, };
10
11
  export declare class TerminalCompositor {
11
12
  readonly stdout: NodeJS.WriteStream;
@@ -58,11 +59,13 @@ export declare class TerminalCompositor {
58
59
  committedBandTopRow: number;
59
60
  committedBandBottomRow: number;
60
61
  committedBandPaintedRows: number;
62
+ bandReflowCache: BandReflowCache | null;
61
63
  lastKnownRows: number;
62
64
  pendingResizeErase: {
63
65
  top: number;
64
66
  bottom: number;
65
67
  } | null;
68
+ bandGeometryStale: boolean;
66
69
  commitInFlight: boolean;
67
70
  private readonly debugCompositor;
68
71
  readonly ghostEngine: SuggestEngine | undefined;
@@ -1,6 +1,7 @@
1
1
  import { type ImageAttachment } from './input/attachments.js';
2
2
  import type { SpinnerController } from './input/spinner.js';
3
3
  import type { CompositorInputMode, CompositorScrollRegionGuard, LogUpdateFn, PickerController } from './terminal-compositor.types.js';
4
+ import { type BandReflowCache } from './terminal-compositor.band-reflow.js';
4
5
  export interface FrameHost {
5
6
  flushResizeGhostErase(): void;
6
7
  renderInputLine(): string;
@@ -23,6 +24,7 @@ export interface FrameHost {
23
24
  committedBandTopRow: number;
24
25
  committedBandBottomRow: number;
25
26
  committedBandPaintedRows: number;
27
+ bandReflowCache: BandReflowCache | null;
26
28
  hasCommitted: boolean;
27
29
  anchorRow: number | undefined;
28
30
  lastKnownRows: number;
@@ -33,6 +33,7 @@ export interface LifecycleHost {
33
33
  readonly committedBand: string[];
34
34
  readonly committedBandTopRow: number;
35
35
  readonly committedBandPaintedRows: number;
36
+ bandGeometryStale: boolean;
36
37
  }
37
38
  export declare function suspendInput(self: LifecycleHost): void;
38
39
  export declare function resumeInput(self: LifecycleHost): void;
@@ -20,6 +20,7 @@ export interface ResetStateHost {
20
20
  top: number;
21
21
  bottom: number;
22
22
  } | null;
23
+ bandGeometryStale: boolean;
23
24
  lastKnownRows: number;
24
25
  pickerController: PickerController | null;
25
26
  inputMode: CompositorInputMode;