Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BW] Add examples of how to present messaging view modally #32

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

zendesk-benabu
Copy link
Contributor

Description

This pull request includes several examples of modally presenting the messaging view controller in existing targer.
It also adds a new button to present the messaging view controller modally in the SwiftUI integration.

Improvements to presentation of messaging view controller:

Added commented-out alternative code to present the messaging view controller using modal presentation in:

  • ClickableLinks/MainViewController.swift,
  • HelloWorld/MainViewController.swift,
  • JWTAuth/MainViewController.swift,
  • Metadata/MainViewController.swift,
  • PushNotifications/MainViewController.swift,
  • VisitorPath/MainViewController.swift

SwiftUI integration updates:

  • SwiftUIIntegration/ContentView.swift: Added a new state variable isPresentingMessagingModally and a button to present the messaging view controller modally. Updated the navigation view style and added a sheet presentation for the messaging view.
  • SwiftUIIntegration/MessagingView.swift: Updated the MessagingView and ViewControllerWrapper to support modal presentation by adding an isModal parameter and handling the modal presentation logic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant