Moving create to a popover.

This commit is contained in:
Max Goedjen 2020-09-22 00:05:45 -07:00
parent 331e4ed0d6
commit 0667fff75c
No known key found for this signature in database
GPG Key ID: E58C21DD77B9B8E8
1 changed files with 6 additions and 5 deletions

View File

@ -23,11 +23,6 @@ struct ContentView<UpdaterType: UpdaterProtocol, AgentStatusCheckerType: AgentSt
NoStoresView()
}
}
.sheet(isPresented: $showingCreation) {
if let modifiable = storeList.modifiableStore {
CreateSecretView(store: modifiable, showing: $showingCreation)
}
}
.frame(minWidth: 640, minHeight: 320)
.toolbar {
updateNotice
@ -83,6 +78,12 @@ extension ContentView {
}, label: {
Image(systemName: "plus")
})
.popover(isPresented: $showingCreation, attachmentAnchor: .point(.bottom), arrowEdge: .bottom) {
if let modifiable = storeList.modifiableStore {
CreateSecretView(store: modifiable, showing: $showingCreation)
}
}
)
}
}