changed snippet picker opotions to use Buttons

using a sheet thats small by default
This commit is contained in:
neon443 committed 2025-08-04 13:06:18 +01:00
1 parent 5a377eb8d9
commit 5f0df4f564
2 files changed
+5 -2

No files matched your search

+3 -2
View File
@@ -22,20 +22,21 @@ struct SnippetPicker: View {
.monospaced()
}
ForEach(hostsManager.snippets) { snip in
Text(snip.name)
.onTapGesture {
Button(snip.name) {
dismiss()
callback?(snip)
}
}
}
.toolbar {
ToolbarItem(placement: .topBarLeading) {
Button() {
dismiss()
} label: {
Image(systemName: "xmark")
}
}
}
.listStyle(.grouped)
}
}
@@ -87,6 +87,8 @@ struct ShellTabView: View {
SnippetPicker(hostsManager: hostsManager) {
container.sessions[selectedID ?? UUID()]?.handler.writeToChannel($0.content)
}
.presentationDragIndicator(.visible)
.presentationDetents([.fraction(0.4), .large])
}
}
.padding(.horizontal, 10)
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.