Add show_page and show_file, and let file tools reach any path
This commit is contained in:
@@ -509,7 +509,7 @@ private struct Attachments: View {
|
||||
let path = a.path ?? ""
|
||||
let root = (store.findTask(taskId)?.worktreePath ?? "") + "/"
|
||||
let rel = path.hasPrefix(root) ? String(path.dropFirst(root.count)) : path
|
||||
if isPage(rel) && !rel.hasPrefix("/") {
|
||||
if isPage(rel) {
|
||||
Button(path) {
|
||||
store.openFile(taskId, rel)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user