Commit 53dc6c6bfd

53dc6c6bfdccaa724b05a834545373663c5cdee0

parent: c4d5cb219a

Verified · cmc

cmc <hello@cleberg.net> · 2026-11-26 04:05 UTC

iOS Export sheet: no empty rows between the groups

Ref #135

Layout: unified · split

Sources/OrgstarMobile/ExportMenu.swift +5 −3 · view
@@ -184,7 +184,7 @@ struct ExportScreen: View {
184 184
185 var body: some View { 185 var body: some View {
186 NavigationStack { 186 NavigationStack {
187 List { ExportItems(path: path, tree: tree, report: report) } 187 List { ExportItems(path: path, tree: tree, report: report, dividers: false) }
188 .navigationTitle("Export") 188 .navigationTitle("Export")
189 .navigationBarTitleDisplayMode(.inline) 189 .navigationBarTitleDisplayMode(.inline)
190 .toolbar { ToolbarItem(placement: .confirmationAction) { Button("Done") { dismiss() } } } 190 .toolbar { ToolbarItem(placement: .confirmationAction) { Button("Done") { dismiss() } } }
@@ -201,6 +201,8 @@ struct ExportItems: View {
201 var report: (String) -> Void = { _ in } 201 var report: (String) -> Void = { _ in }
202 /// Offers the subtree at the caret alone, where there is a caret. 202 /// Offers the subtree at the caret alone, where there is a caret.
203 var exportSubtree: (() -> Void)? 203 var exportSubtree: (() -> Void)?
204 /// Dividers between the groups, as a menu draws them; a list already separates its rows.
205 var dividers = true
204 /// Every file's export settings as kept, so the menu follows a change to this file's. 206 /// Every file's export settings as kept, so the menu follows a change to this file's.
205 @AppStorage(ExportSettings.key) private var kept = Data() 207 @AppStorage(ExportSettings.key) private var kept = Data()
206 208
@@ -226,7 +228,7 @@ struct ExportItems: View {
226 Button("Export Subtree…", systemImage: "list.bullet.indent") { exportSubtree() } 228 Button("Export Subtree…", systemImage: "list.bullet.indent") { exportSubtree() }
227 } 229 }
228 if let calendars = AgendaCalendars(model: model) { 230 if let calendars = AgendaCalendars(model: model) {
229 Divider() 231 if dividers { Divider() }
230 if OrgExport.Format.icalendar.locked { 232 if OrgExport.Format.icalendar.locked {
231 Button("\(String(localized: "Export Agenda Files to iCalendar")) (orgstar+)", systemImage: "calendar") { ProAccess.shared.allows(.export) } 233 Button("\(String(localized: "Export Agenda Files to iCalendar")) (orgstar+)", systemImage: "calendar") { ProAccess.shared.allows(.export) }
232 } else { 234 } else {
@@ -236,7 +238,7 @@ struct ExportItems: View {
236 } 238 }
237 } 239 }
238 } 240 }
239 Divider() 241 if dividers { Divider() }
240 if ProAccess.shared.isUnlocked { 242 if ProAccess.shared.isUnlocked {
241 Button("Copy as Rich Text", systemImage: "doc.on.doc") { report(Self.copy(path: path, text: text, theme: model.theme)) } 243 Button("Copy as Rich Text", systemImage: "doc.on.doc") { report(Self.copy(path: path, text: text, theme: model.theme)) }
242 } else { 244 } else {
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