Update the SDK and Element Call. (#4522)

* Update the SDK and Element Call.

Additionally fix a bug where there was no way to navigate out of a call link after hanging up.

* Remove the temporary parameters.
This commit is contained in:
Doug
2025-09-18 18:24:24 +01:00
committed by GitHub
parent 2eaad89c0f
commit ab41783c4d
7 changed files with 32 additions and 15 deletions
@@ -16,10 +16,16 @@ struct CallScreen: View {
@ObservedObject var context: CallScreenViewModel.Context
var body: some View {
content
.frame(maxWidth: .infinity, maxHeight: .infinity)
.background(Color.compound.bgCanvasDefault.ignoresSafeArea())
.alert(item: $context.alertInfo)
NavigationStack {
content
.frame(maxWidth: .infinity, maxHeight: .infinity)
.background(Color.compound.bgCanvasDefault.ignoresSafeArea())
.navigationBarTitleDisplayMode(.inline)
.toolbar(context.viewState.isGenericCallLink ? .visible : .hidden, for: .navigationBar)
.toolbar { toolbar }
}
.alert(item: $context.alertInfo)
.preferredColorScheme(context.viewState.isGenericCallLink ? .dark : nil)
}
@ViewBuilder
@@ -33,6 +39,15 @@ struct CallScreen: View {
.ignoresSafeArea(edges: .bottom)
}
}
var toolbar: some ToolbarContent {
ToolbarItem(placement: .cancellationAction) {
Button { context.send(viewAction: .navigateBack) } label: {
Image(systemSymbol: .chevronBackward)
.fontWeight(.semibold)
}
}
}
}
private struct CallView: UIViewRepresentable {