feat #609: Add Live Activity support for transit arrival/departure monitor…#1106
Open
prince-0408 wants to merge 1 commit intoOneBusAway:mainfrom
Open
Conversation
…ing (OneBusAway#609) Implements iOS Live Activity support to allow users to track transit arrivals/departures in real-time from the Lock Screen and Dynamic Island. ## What's New ### Core Live Activity Infrastructure - Add TransitArrivalAttributes (OBAKitCore/LiveActivity/) defining the ActivityAttributes for Live Activities, including arrival time, route info, stop name, and headsign - Add LiveActivityManager (OBAKit/LiveActivity/) to handle starting, updating, and stopping Live Activities via ActivityKit - Add LiveActivityDurationPicker (OBAKit/LiveActivity/) — a UI picker letting users choose how long the Live Activity runs (5 min, 15 min, 30 min, 1 hr, 2 hr, 4 hr, 8 hr), defaulting to 1 hour; selection is persisted so it is pre-selected next time - Add LiveActivityListItem (OBAKit/LiveActivity/) — a list row item for starting/stopping a Live Activity from the Stop page ### Widget Extension - Add TransitLiveActivityWidget (OBAWidget/LiveActivity/) implementing the Lock Screen and Dynamic Island UI for the Live Activity - Register the new widget in OBAWidgetBundle ### Stop Page Integration - Add StopViewController+LiveActivity.swift extension wiring up the Live Activity list item into the Stop page, displayed below the map and above service alerts (as specified in issue OneBusAway#609) - Update StopViewController.swift to include the Live Activity section and refresh it alongside arrival data - Update StopArrivalItem to expose data needed by the Live Activity ### Bookmarks Integration - Update BookmarksViewController to surface a 'Start Live Activity' option on long-press / swipe actions on bookmark cells, matching the UI flow described in issue OneBusAway#609 ### Project Configuration - Update Apps/KiedyBus/project.yml, Apps/OneBusAway/project.yml, and OBAWidget/project.yml to include the new LiveActivity source files and the ActivityKit capability - Add OneBusAway logo image assets ### Application Bootstrap - Update Application.swift to initialise LiveActivityManager and wire it into the app lifecycle Closes OneBusAway#609
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request: Add Live Activity Support for Transit Arrival/Departure Monitoring
Closes #609
Summary
This PR implements full iOS Live Activity support using Apple's ActivityKit framework, allowing users to track real-time transit arrivals and departures from the Lock Screen and Dynamic Island — without opening the app.
Files Changed
iOS Version Requirement
All Live Activity code is guarded with
@available(iOS 16.2, *)and#available(iOS 16.2, *)checks. The feature is silently unavailable on older OS versions — no UI is shown and no crashes occur.Simulator.Screen.Recording.-.iPhone.17.Pro.-.2026-03-15.at.22.39.54.mov
Screen.Recording.2026-03-15.at.10.53.47.PM.mov
Screen.Recording.2026-03-15.at.10.58.02.PM.mov
Screen.Recording.2026-03-15.at.10.58.50.PM.mov