mirror of
https://github.com/vector-im/element-ios.git
synced 2024-09-29 07:42:40 +00:00
LiveLocationSharingViewerViewState: Add location sharing ended flag.
This commit is contained in:
parent
7cfcced8c1
commit
e86e419d8a
1 changed files with 10 additions and 1 deletions
|
@ -38,7 +38,7 @@ struct LiveLocationSharingViewerViewState: BindableState {
|
|||
var annotations: [UserLocationAnnotation]
|
||||
|
||||
/// Map annotation to focus on
|
||||
var highlightedAnnotation: UserLocationAnnotation?
|
||||
var highlightedAnnotation: LocationAnnotation?
|
||||
|
||||
/// Live location list items
|
||||
var listItemsViewData: [LiveLocationListItemViewData]
|
||||
|
@ -49,6 +49,15 @@ struct LiveLocationSharingViewerViewState: BindableState {
|
|||
!showLoadingIndicator
|
||||
}
|
||||
|
||||
/// True to indicate that everybody stopped to share live location sharing in the room
|
||||
var isAllLocationSharingEnded: Bool {
|
||||
return listItemsViewData.isEmpty
|
||||
}
|
||||
|
||||
var isBottomSheetVisible: Bool {
|
||||
return isAllLocationSharingEnded == false
|
||||
}
|
||||
|
||||
let errorSubject = PassthroughSubject<LocationSharingViewError, Never>()
|
||||
|
||||
var bindings = LocationSharingViewStateBindings()
|
||||
|
|
Loading…
Reference in a new issue