---
url: >-
  https://adk.nht.io/api/@nhtio/adk/batteries/media/contracts/type-aliases/ImageAnnotation.md
description: A primitive rendered by the image annotation operation.
---

# Type Alias: ImageAnnotation

```ts
type ImageAnnotation =
  | {
      color?: string;
      fill?: string;
      height: number;
      strokeWidth?: number;
      type: "rect";
      width: number;
      x: number;
      y: number;
    }
  | {
      color?: string;
      strokeWidth?: number;
      type: "line" | "arrow";
      x1: number;
      x2: number;
      y1: number;
      y2: number;
    }
  | {
      color?: string;
      cx: number;
      cy: number;
      fill?: string;
      rx: number;
      ry: number;
      strokeWidth?: number;
      type: "ellipse";
    }
  | {
      color?: string;
      font?: string;
      size?: number;
      text: string;
      type: "text";
      x: number;
      y: number;
    };
```

Defined in: [src/batteries/media/contracts.ts:337](https://github.com/NHTIO/ADK/blob/v1.20260913.0/src/src/batteries/media/contracts.ts#L337)

A primitive rendered by the image annotation operation.
