# alejandrobujan/tendedero architecture

> Architecture diagram of the GitHub repository alejandrobujan/tendedero, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-12). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/alejandrobujan/tendedero
- Repository: https://github.com/alejandrobujan/tendedero

## Overview

Tendedero is a local macOS menu-bar app that gathers screenshots and screen recordings onto a retractable line. The principal flow is capture or clipboard detection, file discovery, then presenting items for copy, editing, preview, drag-and-drop, or removal. The graph keeps orchestration in AppDelegate and separates capture intake, line state, presentation, and item actions. Some capabilities and their wiring are documented in the README; edges without direct source evidence are omitted. Localization, shortcut handling, and full-screen behavior are included as distinct supporting features.

Main entry points: [`Sources/Tendedero/AppDelegate.swift`](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/AppDelegate.swift) (Menu bar orchestration), [`Sources/Tendedero/Line.swift`](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Line.swift) (Hanging items), [`Sources/Tendedero/LineView.swift`](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/LineView.swift) (Line layout), [`Sources/Tendedero/ScreenshotWatcher.swift`](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/ScreenshotWatcher.swift) (Screenshot watcher)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["App control"]
  node_entry["App startup<br/>[main.swift]"]
  node_delegate["Menu bar orchestration<br/>[AppDelegate.swift]"]
  node_hotkey["Keyboard shortcut<br/>[HotKey.swift]"]
  node_fullscreen["Full-screen detection<br/>[FullScreen.swift]"]
end

subgraph group_intake["Capture intake"]
  node_inbox["Capture settings<br/>[Inbox.swift]"]
  node_screenshots["Screenshot watcher"]
  node_clipboardwatch["Clipboard watcher"]
  node_captureflight["Capture animation"]
end

subgraph group_line["Line presentation"]
  node_line_state["Hanging items<br/>[Line.swift]"]
  node_panel["Screen panel<br/>[LinePanel.swift]"]
  node_lineview["Line layout<br/>[LineView.swift]"]
  node_pegged["Screenshot card<br/>[PeggedView.swift]"]
  node_gestures["Gestures and drag<br/>[GrabArea.swift]"]
end

subgraph group_actions["Item actions"]
  node_markup["Markup editor<br/>[Markup.swift]"]
  node_trim["Recording trim<br/>[Trim.swift]"]
  node_quicklook["Quick Look preview<br/>[QuickLook.swift]"]
end

subgraph group_support["Platform support"]
  node_localization["Localization<br/>[Localization.swift]"]
end

node_user(("Mac user"))
node_macos_capture["macOS capture"]
node_clipboard[("System clipboard")]
node_external_apps["Other apps and folders"]

node_user -->|"launches"| node_entry
node_entry -->|"starts"| node_delegate
node_delegate -->|"starts watchers"| node_screenshots
node_delegate -->|"starts watcher"| node_clipboardwatch
node_delegate -->|"registers shortcut"| node_hotkey
node_delegate -->|"checks visibility"| node_fullscreen
node_delegate -->|"configures mode"| node_inbox
node_inbox -->|"changes settings"| node_macos_capture
node_macos_capture -->|"writes captures"| node_screenshots
node_clipboard -->|"provides images"| node_clipboardwatch
node_screenshots -->|"reports captures"| node_delegate
node_clipboardwatch -->|"reports images"| node_delegate
node_delegate -->|"hangs captures"| node_line_state
node_delegate -->|"controls visibility"| node_panel
node_panel -->|"hosts view"| node_lineview
node_lineview -->|"renders items"| node_line_state
node_lineview -->|"renders cards"| node_pegged
node_pegged -->|"embeds controls"| node_gestures
node_gestures -->|"invokes actions"| node_line_state
node_line_state -->|"opens editor"| node_markup
node_line_state -->|"opens trimmer"| node_trim
node_line_state -->|"opens preview"| node_quicklook
node_markup -.->|"refreshes image"| node_line_state
node_trim -.->|"refreshes recording"| node_line_state
node_line_state -->|"copies or drags"| node_external_apps
node_delegate -.->|"localizes interface"| node_localization
node_delegate -.->|"animates arrival"| node_captureflight

click node_entry "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/main.swift"
click node_delegate "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/AppDelegate.swift"
click node_hotkey "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/HotKey.swift"
click node_fullscreen "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/FullScreen.swift"
click node_inbox "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Inbox.swift"
click node_screenshots "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/ScreenshotWatcher.swift"
click node_clipboardwatch "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/ClipboardWatcher.swift"
click node_captureflight "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/CaptureFlight.swift"
click node_line_state "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Line.swift"
click node_panel "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/LinePanel.swift"
click node_lineview "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/LineView.swift"
click node_pegged "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/PeggedView.swift"
click node_gestures "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/GrabArea.swift"
click node_markup "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Markup.swift"
click node_trim "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Trim.swift"
click node_quicklook "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/QuickLook.swift"
click node_localization "https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Localization.swift"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_entry,node_delegate,node_hotkey,node_fullscreen,node_user toneBlue
class node_inbox,node_screenshots,node_clipboardwatch,node_captureflight,node_clipboard toneAmber
class node_line_state,node_panel,node_lineview,node_pegged,node_gestures toneMint
class node_markup,node_trim,node_quicklook toneRose
class node_localization,node_macos_capture,node_external_apps toneIndigo
```

## Components

### App control

- [App startup](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/main.swift): `Sources/Tendedero/main.swift`
- [Menu bar orchestration](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/AppDelegate.swift): `Sources/Tendedero/AppDelegate.swift`
- [Keyboard shortcut](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/HotKey.swift): `Sources/Tendedero/HotKey.swift`
- [Full-screen detection](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/FullScreen.swift): `Sources/Tendedero/FullScreen.swift`

### Capture intake

- [Capture settings](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Inbox.swift): `Sources/Tendedero/Inbox.swift`
- [Screenshot watcher](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/ScreenshotWatcher.swift): `Sources/Tendedero/ScreenshotWatcher.swift`
- [Clipboard watcher](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/ClipboardWatcher.swift): `Sources/Tendedero/ClipboardWatcher.swift`
- [Capture animation](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/CaptureFlight.swift): `Sources/Tendedero/CaptureFlight.swift`

### Line presentation

- [Hanging items](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Line.swift): `Sources/Tendedero/Line.swift`
- [Screen panel](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/LinePanel.swift): `Sources/Tendedero/LinePanel.swift`
- [Line layout](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/LineView.swift): `Sources/Tendedero/LineView.swift`
- [Screenshot card](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/PeggedView.swift): `Sources/Tendedero/PeggedView.swift`
- [Gestures and drag](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/GrabArea.swift): `Sources/Tendedero/GrabArea.swift`

### Item actions

- [Markup editor](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Markup.swift): `Sources/Tendedero/Markup.swift`
- [Recording trim](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Trim.swift): `Sources/Tendedero/Trim.swift`
- [Quick Look preview](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/QuickLook.swift): `Sources/Tendedero/QuickLook.swift`

### Platform support

- [Localization](https://github.com/alejandrobujan/tendedero/blob/main/Sources/Tendedero/Localization.swift): `Sources/Tendedero/Localization.swift`

### Other components

- **Mac user**
- **macOS capture**
- **System clipboard**
- **Other apps and folders**

## Connections

- Mac user → App startup: launches (evidence: `Sources/Tendedero/main.swift`)
- App startup → Menu bar orchestration: starts (evidence: `Sources/Tendedero/main.swift`)
- Menu bar orchestration → Screenshot watcher: starts watchers (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Menu bar orchestration → Clipboard watcher: starts watcher (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Menu bar orchestration → Keyboard shortcut: registers shortcut (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Menu bar orchestration → Full-screen detection: checks visibility (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Menu bar orchestration → Capture settings: configures mode (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Capture settings → macOS capture: changes settings (evidence: `Sources/Tendedero/Inbox.swift`)
- macOS capture → Screenshot watcher: writes captures (evidence: `Sources/Tendedero/ScreenshotWatcher.swift`)
- System clipboard → Clipboard watcher: provides images (evidence: `Sources/Tendedero/ClipboardWatcher.swift`)
- Screenshot watcher → Menu bar orchestration: reports captures (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Clipboard watcher → Menu bar orchestration: reports images (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Menu bar orchestration → Hanging items: hangs captures (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Menu bar orchestration → Screen panel: controls visibility (evidence: `Sources/Tendedero/AppDelegate.swift`)
- Screen panel → Line layout: hosts view (evidence: `Sources/Tendedero/LinePanel.swift`)
- Line layout → Hanging items: renders items (evidence: `Sources/Tendedero/LineView.swift`)
- Line layout → Screenshot card: renders cards (evidence: `Sources/Tendedero/LineView.swift`)
- Screenshot card → Gestures and drag: embeds controls (evidence: `Sources/Tendedero/PeggedView.swift`)
- Gestures and drag → Hanging items: invokes actions (evidence: `Sources/Tendedero/GrabArea.swift`)
- Hanging items → Markup editor: opens editor (evidence: `Sources/Tendedero/Line.swift`)
- Hanging items → Recording trim: opens trimmer (evidence: `Sources/Tendedero/Line.swift`)
- Hanging items → Quick Look preview: opens preview (evidence: `Sources/Tendedero/Line.swift`)
- Markup editor → Hanging items: refreshes image (evidence: `Sources/Tendedero/Line.swift`)
- Recording trim → Hanging items: refreshes recording (evidence: `Sources/Tendedero/Line.swift`)
- Hanging items → Other apps and folders: copies or drags (evidence: `Sources/Tendedero/Line.swift`)
- Menu bar orchestration → Localization: localizes interface
- Menu bar orchestration → Capture animation: animates arrival (evidence: `Sources/Tendedero/AppDelegate.swift`)
