OneBusAway / onebusaway-ios

OneBusAway for iOS, written in Swift.
Other
74 stars 31 forks source link

Show an Alert Controller when tapping on a service alert #700

Closed aaronbrethorst closed 7 months ago

aaronbrethorst commented 7 months ago

Compare the iOS and Android screenshots of the service alert below. In the iOS case, you only get the collection view cell text. Tapping on the collection view cell will bring you to the service alert's target URL. In the Android case, there's an interstitial alert that can show you more text.

I think the proper way of resolving this is to display an alert style UIAlertController when the service alert is tapped. The alert will have two buttons: "Dismiss" and "Read More". Tapping dismiss closes the alert. Tapping "Read More" pushes an SFSafariViewController onto the stack with the service alert's URL target.

original-FFAEFF63-BF77-4321-B63E-600874B39FC5

Screenshot_20231208-084702

ualch9 commented 7 months ago

I'd prefer having the sheet try to show the alert text instead of using an Alert, so the text can be selected. Plus, some agencies will provide an entire webpage worth of text in the body that might not look nice squished into an alert.