Introduction to Augenblick
Relevant source files
The following files were used as context for generating this wiki page:
Augenblick is a desktop note-taking application designed with a unique philosophy: notes are temporary by default. Built using the Tauri framework with a Rust backend and a React frontend, the application automates the lifecycle of digital clutter by expiring inactive notes after a configurable period. It targets users who struggle with "untitled document" sprawl, particularly those with ADHD, by enforcing a system where information must be intentionally pinned or saved externally to be preserved.
Sources: README.md:1-12, plans/migration.md:5-10
The system architecture follows a modern desktop application pattern, leveraging Tauri's security-focused bridge between high-performance Rust logic and a responsive React UI. Key functionalities include a Tiptap-based Markdown editor, a local SQLite database for metadata, and a background "auto-sweeper" that manages the transition of notes from an active state to the trash and eventual permanent deletion.
Sources: README.md:55-61, plans/migration.inventory.md:154-159
Core Product Philosophy and Features
Augenblick's primary utility revolves around its auto-expiry mechanism and the distinction between "Drafts" and "Saved" notes.
Key Features
| Feature | Description |
|---|---|
| Auto-Expiring Notes | Notes move to trash after a period of inactivity (default 7 days, configurable from 6 hours to 30 days). |
| Draft vs Saved | Drafts are stored within the app's internal data directory; Saved notes are persisted to external user-defined paths. |
| Pinning | Users can pin up to 5 important notes to exempt them from the auto-expiry logic. |
| Visual Expiry Ring | A color-coded UI indicator showing the time remaining before a note is moved to trash. |
| Trash Retention | A secondary buffer where deleted notes reside for a set duration (e.g., 30 days) before final deletion. |
Sources: README.md:15-30, plans/migration.inventory.md:162-171
System Architecture
The application utilizes a multi-layered architecture separating the presentation, business logic, and persistence layers.
Component Relationship Diagram
This diagram illustrates how the React frontend interacts with the Tauri core and the filesystem via the Rust backend.
Backend Infrastructure (Rust/Tauri)
The backend manages sensitive operations including database transactions, filesystem management for drafts, and security-scoped bookmarks for macOS.
- SQLite Database: Stores metadata such as titles, previews, file paths, storage types, and timestamps (
created_at,last_interaction). - Auto-Sweeper: A background thread running every 60 seconds that identifies and processes expired notes based on user settings.
- IPC Commands: Exposes functions like
note_create,note_save_as, andnotes_reorderto the frontend.
Sources: plans/migration.inventory.md:15-30, plans/migration.inventory.md:154-158, src-tauri/src/notes/write.rs:18-40
Frontend Architecture (React)
The frontend is built with React 19 and utilizes Zustand for state management.
- Notes Store: Manages the active note list, selected note ID, and debounced autosave timers.
- App Shell: Handles the layout, including a draggable sidebar (width 200-400px) and the main editor pane.
- Tiptap Editor: A Markdown editor providing GFM support, task lists, and syntax highlighting.
Sources: package.json:28-55, plans/migration.md:35-50, src/App.tsx:290-310
Note Lifecycle and Persistence
Notes transition through distinct states based on user interaction and the passage of time.
State Transition Diagram
The following sequence shows how a note progresses from creation to deletion.
Note Metadata Schema
Metadata is stored in the notes table with the following structure:
| Field | Type | Description |
|---|---|---|
id | TEXT | Primary Key (UUID). |
storage | TEXT | Either "draft" or "saved". |
file_path | TEXT | Path to the .md file on disk. |
bookmark | BLOB | Security-scoped bookmark for macOS file access. |
last_interaction | INTEGER | Timestamp of the last edit or selection (ms epoch). |
is_pinned | INTEGER | Boolean flag (0 or 1). |
Sources: plans/migration.inventory.md:18-35, src-tauri/src/notes/write.rs:24-38
Configuration and Technical Stack
Augenblick is built with modern web and system technologies, configured for cross-platform desktop use.
Tech Stack Summary
- Framework: Tauri 2 (Rust)
- Frontend UI: React 19, Tailwind CSS v4, shadcn/ui
- State Management: Zustand
- Editor: Tiptap (Markdown)
- Database: SQLite (via
rusqlite) - Build Tools: Bun, Vite
Sources: README.md:55-61, package.json:1-60
Window and Security Configuration
The application is configured with a custom title bar and specific security policies.
"app": {
"windows": [
{
"title": "Augenblick",
"width": 800,
"height": 600,
"hiddenTitle": true,
"titleBarStyle": "Overlay"
}
],
"security": {
"csp": "default-src 'self' asset:; img-src 'self' asset: data: blob: https:; ..."
}
}
Sources: src-tauri/tauri.conf.json:15-30
Conclusion
Augenblick serves as a specialized tool for ephemeral note-taking. By combining the safety of a Rust-based backend with the flexibility of a React frontend, it provides a stable environment for drafting ideas while proactively managing data retention to prevent digital overload. The system's architecture ensures that user data is handled securely through explicit "Save As" flows while maintaining a low-friction "Draft" experience.
Sources: README.md:5-12, plans/migration.md:5-15