Update StatusRowContextMenu to include a "Copy Text" option (#36)

* Add option to re-hide spoiler content after expanding

Uses the same logic as the "Show more" button, but in reverse. This allows a user to hide the content that they expanded.

* Use .toggle() method instead of multiple if statements

* Update StatusRowContextMenu to have Copy Text option

* Update pasteboard string to contain rawText status
This commit is contained in:
Tyler Baker 2023-01-07 11:56:24 -05:00 committed by GitHub
parent 12fc8cd475
commit f9f6ffc71e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -49,6 +49,12 @@ struct StatusRowContextMenu: View {
Label("View in Browser", systemImage: "safari")
}
}
Button {
UIPasteboard.general.string = viewModel.status.content.asRawText
} label: {
Label("Copy Text", systemImage: "doc.on.doc")
}
if account.account?.id == viewModel.status.account.id {
Section("Your post") {