mirror of
https://github.com/metabolist/metatext.git
synced 2024-12-25 15:00:28 +00:00
Display pinned state whe modifying
This commit is contained in:
parent
533a1d1830
commit
4142e66862
3 changed files with 5 additions and 1 deletions
|
@ -355,6 +355,8 @@ private extension TableViewController {
|
|||
switch event {
|
||||
case .ignorableOutput:
|
||||
break
|
||||
case .refresh:
|
||||
refreshIfAble()
|
||||
case let .share(url):
|
||||
share(url: url)
|
||||
case let .navigation(navigation):
|
||||
|
|
|
@ -6,6 +6,7 @@ import ServiceLayer
|
|||
|
||||
public enum CollectionItemEvent {
|
||||
case ignorableOutput
|
||||
case refresh
|
||||
case navigation(Navigation)
|
||||
case attachment(AttachmentViewModel, StatusViewModel)
|
||||
case compose(inReplyTo: StatusViewModel?, redraft: Status?)
|
||||
|
|
|
@ -255,7 +255,8 @@ public extension StatusViewModel {
|
|||
func togglePinned() {
|
||||
eventsSubject.send(
|
||||
statusService.togglePinned()
|
||||
.map { _ in .ignorableOutput }
|
||||
.collect()
|
||||
.map { _ in .refresh }
|
||||
.eraseToAnyPublisher())
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue