mirror of
https://github.com/maxgoedjen/secretive.git
synced 2025-04-10 17:47:19 +00:00
Fix sheets.
This commit is contained in:
parent
4c7e8be740
commit
c37d2d715a
@ -43,6 +43,16 @@ struct ContentView<UpdaterType: UpdaterProtocol, AgentStatusCheckerType: AgentSt
|
||||
}
|
||||
}
|
||||
}
|
||||
.sheet(item: $deletingSecret) { secret in
|
||||
if let store = storeList.modifiableStore {
|
||||
DeleteSecretView(secret: secret, store: store) { deleted in
|
||||
deletingSecret = nil
|
||||
if deleted {
|
||||
active = nextDefaultSecret
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -52,16 +62,6 @@ struct ContentView<UpdaterType: UpdaterProtocol, AgentStatusCheckerType: AgentSt
|
||||
active = nextDefaultSecret
|
||||
}
|
||||
.frame(minWidth: 100, idealWidth: 240)
|
||||
.sheet(item: $deletingSecret) { secret in
|
||||
if let store = storeList.modifiableStore {
|
||||
DeleteSecretView(secret: secret, store: store) { deleted in
|
||||
deletingSecret = nil
|
||||
if deleted {
|
||||
active = nextDefaultSecret
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.sheet(isPresented: $showingCreation) {
|
||||
if let store = storeList.modifiableStore {
|
||||
CreateSecretView(store: store, showing: $showingCreation)
|
||||
|
Loading…
Reference in New Issue
Block a user