Open notes editor in a NavigationView

This commit is contained in:
Jackson Harper
2023-04-07 22:38:29 +08:00
parent 1aa49346cb
commit 4c5c47c746

View File

@ -181,19 +181,21 @@
noteSection
}
.sheet(isPresented: $showAnnotationModal) {
HighlightAnnotationSheet(
annotation: $annotation,
onSave: {
onSaveAnnotation(annotation)
showAnnotationModal = false
hasHighlightMutations = true
},
onCancel: {
showAnnotationModal = false
},
errorAlertMessage: $errorAlertMessage,
showErrorAlertMessage: $showErrorAlertMessage
)
NavigationView {
HighlightAnnotationSheet(
annotation: $annotation,
onSave: {
onSaveAnnotation(annotation)
showAnnotationModal = false
hasHighlightMutations = true
},
onCancel: {
showAnnotationModal = false
},
errorAlertMessage: $errorAlertMessage,
showErrorAlertMessage: $showErrorAlertMessage
)
}
}
.formSheet(isPresented: $showShareView) {
ShareSheet(activityItems: [viewModel.highlightAsMarkdown(item: self.highlightParams)])