Commit e17354fe83

e17354fe8333b861f116bce22c38c4b66a3d95d5

parent: f0f77da392

Verified · cmc

cmc <hello@cleberg.net> · 2026-11-25 22:15 UTC

Capture heading, empty backlinks pane, board column widths

The capture window no longer repeats "Capture" under its title; the
line above the templates shows only the keys typed and the day. The
backlinks pane shrinks to one line, "Links to this file: None", when
nothing links to the file or heading. The board's Scheduled and
Deadline columns start at 130 points so dates fit.

Ref #224

Layout: unified · split

Changed files (5)
Sources/Orgstar/BacklinksPane.swift +23 −7 · view
@@ -28,17 +28,33 @@ struct BacklinksPane: View {
28 } 28 }
29 29
30 var body: some View { 30 var body: some View {
31 List { 31 Group {
32 if let failure { 32 if failure == nil, toHeading.isEmpty, toFile.isEmpty {
33 Text(failure).foregroundStyle(.secondary) 33 // Nothing links here: a single line, leaving the column to the outline.
34 HStack {
35 Text("Links to this file").font(.subheadline.weight(.semibold)).foregroundStyle(.secondary)
36 Spacer()
37 Text("None").foregroundStyle(.secondary)
38 }
39 .padding(.horizontal, 12)
40 .padding(.vertical, 6)
41 .frame(maxWidth: .infinity)
42 .background(theme.color("sidebar-background", in: colorScheme) ?? .clear)
34 } else { 43 } else {
35 if let heading { 44 List {
36 Section("Links to \(heading.title.isEmpty ? "(untitled)" : heading.title)") { rows(toHeading) } 45 if let failure {
46 Text(failure).foregroundStyle(.secondary)
47 } else {
48 if let heading {
49 Section("Links to \(heading.title.isEmpty ? "(untitled)" : heading.title)") { rows(toHeading) }
50 }
51 Section("Links to this file") { rows(toFile) }
52 }
37 } 53 }
38 Section("Links to this file") { rows(toFile) } 54 .themedListBackground(theme.color("sidebar-background", in: colorScheme))
55 .frame(height: 200)
39 } 56 }
40 } 57 }
41 .themedListBackground(theme.color("sidebar-background", in: colorScheme))
42 .task(id: Key(path: session.path, heading: heading?.start, title: heading?.title, index: workspace.indexVersion)) { await refresh() } 58 .task(id: Key(path: session.path, heading: heading?.start, title: heading?.title, index: workspace.indexVersion)) { await refresh() }
43 } 59 }
44 60
Sources/Orgstar/BoardView.swift +2 −2 · view
@@ -118,9 +118,9 @@ struct BoardView: View {
118 TableColumn("Tags", value: \.tags) { row in Text(row.tags).foregroundStyle(.secondary).lineLimit(1) } 118 TableColumn("Tags", value: \.tags) { row in Text(row.tags).foregroundStyle(.secondary).lineLimit(1) }
119 .width(min: 60, ideal: 120) 119 .width(min: 60, ideal: 120)
120 TableColumn("Scheduled", value: \.scheduled) { row in Text(row.scheduled).monospacedDigit() } 120 TableColumn("Scheduled", value: \.scheduled) { row in Text(row.scheduled).monospacedDigit() }
121 .width(min: 80, ideal: 110) 121 .width(min: 80, ideal: 130)
122 TableColumn("Deadline", value: \.deadline) { row in Text(row.deadline).monospacedDigit() } 122 TableColumn("Deadline", value: \.deadline) { row in Text(row.deadline).monospacedDigit() }
123 .width(min: 80, ideal: 110) 123 .width(min: 80, ideal: 130)
124 TableColumnForEach(propertyColumns, id: \.self) { key in 124 TableColumnForEach(propertyColumns, id: \.self) { key in
125 TableColumn(key.capitalized) { (row: BoardRow) in Text(row.entry.properties[key] ?? "") } 125 TableColumn(key.capitalized) { (row: BoardRow) in Text(row.entry.properties[key] ?? "") }
126 .width(min: 50, ideal: 80) 126 .width(min: 50, ideal: 80)
Sources/Orgstar/CaptureView.swift +7 −1 · view
@@ -74,8 +74,14 @@ struct CaptureView: View {
74 .keyboardShortcut(.defaultAction) 74 .keyboardShortcut(.defaultAction)
75 } 75 }
76 } else { 76 } else {
77 Text((keys.isEmpty ? "Capture" : "Capture: \(keys)") + (day == nil ? "" : ", scheduled " + captureDate(Date()).formatted(.dateTime.weekday(.abbreviated).day().month(.abbreviated)))) 77 // The window's title says Capture; this line is for the keys typed and the day.
78 if !keys.isEmpty || day != nil {
79 HStack(spacing: 12) {
80 if !keys.isEmpty { Text(verbatim: "[\(keys)]").monospaced() }
81 if day != nil { Text("Scheduled \(captureDate(Date()).formatted(.dateTime.weekday(.abbreviated).day().month(.abbreviated)))") }
82 }
78 .font(.headline) 83 .font(.headline)
84 }
79 ForEach(CaptureTemplates.menu(templates, groups: groups, typed: keys)) { item in 85 ForEach(CaptureTemplates.menu(templates, groups: groups, typed: keys)) { item in
80 Button { 86 Button {
81 switch item { 87 switch item {
docs/manual/guide/08-capture.org +1 −1 · view
@@ -27,7 +27,7 @@ Captures can also arrive from a browser through org-protocol, from Shortcuts, an
27 27
28A capture goes through up to three steps. 28A capture goes through up to three steps.
29 29
301. *Choose a template.* The window lists your templates and groups with their keys and targets. Type a template's key, or click it. For a key of several characters, such as =wb=, each character you type narrows the list, and the header shows the keys so far (=Capture: w=). With a group for =w= (see [[*Template groups][Template groups]]), typing =w= or clicking the group lists what is in it. =Delete= removes the last key typed. The template is chosen as soon as the keys match one. 301. *Choose a template.* The window lists your templates and groups with their keys and targets. Type a template's key, or click it. For a key of several characters, such as =wb=, each character you type narrows the list, and the line above the list shows the keys so far (=[w]=). With a group for =w= (see [[*Template groups][Template groups]]), typing =w= or clicking the group lists what is in it. =Delete= removes the last key typed. The template is chosen as soon as the keys match one.
312. *Answer its questions.* If the template has prompts (=%^{…}=, =%^g=, =%^t= and the others below), they appear as a form, after =Date for tree entry= for a template with =time-prompt=. Leave a field empty for its default. Press Return (Continue) to go on. 312. *Answer its questions.* If the template has prompts (=%^{…}=, =%^g=, =%^t= and the others below), they appear as a form, after =Date for tree entry= for a template with =time-prompt=. Leave a field empty for its default. Press Return (Continue) to go on.
323. *Edit and file.* The filled template appears in an editor, headed with the template's name and target, with the cursor where =%?= was. Press =⌘Return= (File It) to file it, or click Refile… to file it and then move it, as =C-c C-w= (=org-capture-refile=) does. Refile… asks for the target in the main window's echo area, offering the same targets as Refile in the editor (see [[file:04-outlines.org::*Refiling][Refiling]]); it appears for =entry= templates only, as in Org. 323. *Edit and file.* The filled template appears in an editor, headed with the template's name and target, with the cursor where =%?= was. Press =⌘Return= (File It) to file it, or click Refile… to file it and then move it, as =C-c C-w= (=org-capture-refile=) does. Refile… asks for the target in the main window's echo area, offering the same targets as Refile in the editor (see [[file:04-outlines.org::*Refiling][Refiling]]); it appears for =entry= templates only, as in Org.
33 33
docs/manual/guide/09-links.org +2 −1 · view
@@ -300,7 +300,8 @@ has two sections:
300 300
301Each row shows the linking heading, the line the link is on with links shown as they read 301Each row shows the linking heading, the line the link is on with links shown as they read
302and this one in bold, and the file name; a link in the text before a file's first heading is 302and this one in bold, and the file name; a link in the text before a file's first heading is
303listed under the file's name. Click a row to open it. The 303listed under the file's name. Click a row to open it. When nothing links to the file
304or the heading, the pane shrinks to one line, =Links to this file= =None=. The
304pane is shown by default, orgstar remembers whether it is shown, and it updates as 305pane is shown by default, orgstar remembers whether it is shown, and it updates as
305you move the caret and edit. 306you move the caret and edit.
306 307
Keyboard shortcuts

Global

⌘K
Command palette & jump
/
Focus search
?
Show this help
g d
Dashboard
g e
Explore repositories
g n
Notifications

Repository & editor

t
Find file in repository
y
Copy immutable SHA permalink
g c
Code tab
g i
Issues tab
g m
Merge requests tab
g b
Builds tab
⌘↵
Submit active form