Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,11 @@ A native macOS Markdown viewer built with [Tauri v2](https://v2.tauri.app/). Bro
- **Relative link navigation** — Click `.md` links to navigate between documents
- **Dark mode** — Follows macOS system appearance, toggleable manually
- **Session persistence** — Remembers your last opened folder across launches
- **Multiple windows** — Open a second folder side by side in its own window (Cmd+N for an empty window, Shift+Cmd+N to pick a folder). Each window keeps its own document, outline and search
- **Open single files** — Open `.md` files directly via CLI, Finder "Open With", or drag & drop
- **PDF export** — Export the current document as PDF with native rendering
- **CLI support** — Open a folder or file directly: `mdv ~/docs` or `mdv ~/docs/README.md`
- **Native menu** — Cmd+O to open a folder, standard macOS app menu
- **Native menu** — Cmd+O to open a file, Shift+Cmd+O for a folder, standard macOS app menu

### Markdown Rendering

Expand Down
33 changes: 33 additions & 0 deletions docs/guide/features.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,39 @@ Open any folder and navigate its directory tree via the sidebar. The sidebar sho

A breadcrumb bar at the top shows your current location and lets you navigate back to parent directories.

## Multiple Windows

Two folders can be read side by side, each in its own window:

- **File › New Window** (`Cmd+N`) opens an empty window on the welcome screen.
- **File › Open Folder in New Window…** (`Shift+Cmd+N`) picks a folder and opens
it in a new window, leaving the current window untouched.

The **Window** menu lists every open window and switches to the one you pick
(the active one is checked). Each window is named after the document it shows —
or its folder when no document is open yet — so the list stays readable.

It also carries the usual macOS window commands:

- **Minimize**, **Zoom**, **Enter Full Screen**
- **Fill** — the window takes the whole screen minus menu bar and Dock
- **Center** — keeps the size, centers the window on its screen
- **Move & Resize** — halves (Left, Right, Top, Bottom), quarters, and **Return
to Previous Size**, which undoes a run of arrangements in one step
- **Bring All to Front** — raises every window, keeping the active one in front

These act on the frontmost window and use the screen it currently sits on. They
have no keyboard shortcuts on purpose: macOS already binds Control-Option-arrows
to its own window tiling, which keeps working alongside them.

Windows are fully independent — document, outline, search state and scroll
position are per window. Menu commands and their shortcuts (Find, Print, Export
as PDF, Open Recent, Toggle Dark Mode…) act on the frontmost window only.
The recent-files list is shared (the native "Open Recent" submenu is app-wide).
Preferences (theme, fonts, language) are stored once for the app and applied
when a window opens, so changing them updates the window you changed them in and
every window opened afterwards.

## Markdown Rendering

Full GitHub-Flavored Markdown (GFM) support including:
Expand Down
12 changes: 11 additions & 1 deletion docs/reference/keyboard-shortcuts.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,19 @@

| Shortcut | Action |
|---|---|
| **Cmd+O** | Open folder |
| **Cmd+O** | Open file |
| **Shift+Cmd+O** | Open folder |
| **Cmd+N** | New window (welcome screen) |
| **Shift+Cmd+N** | Open a folder in a new window |
| **Cmd+M** | Minimize the current window |
| **Cmd+W** | Close the current window |
| **Cmd+Q** | Quit application |

Windows are independent: each one keeps its own document, outline, search and
scroll position. Menu commands (Find, Print, Export as PDF, Open Recent…) always
apply to the frontmost window. The **Window** menu lists the open windows and
switches to the one you select.

## Overlays

| Shortcut | Action |
Expand Down
1 change: 1 addition & 0 deletions src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ font-kit = "0.14"

[target.'cfg(target_os = "macos")'.dependencies]
objc2 = "0.6"
objc2-app-kit = { version = "0.3", features = ["NSScreen"] }
objc2-foundation = { version = "0.3", features = ["NSData", "NSError", "NSString"] }
objc2-web-kit = { version = "0.3", features = ["WKWebView", "WKPDFConfiguration", "block2", "objc2-app-kit"] }
block2 = "0.6"
2 changes: 1 addition & 1 deletion src-tauri/capabilities/default.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"$schema": "../gen/schemas/desktop-schema.json",
"identifier": "default",
"description": "Default permissions for the app",
"windows": ["main"],
"windows": ["main", "viewer-*"],
"permissions": [
"core:default",
"core:window:allow-start-dragging",
Expand Down
Loading
Loading