[EPAC-691]: Royal Assent tracker — Home card, Became Law filter, follow-bill notifications#800
Open
riddim-developer-bot[bot] wants to merge 1 commit into
Conversation
…ow-bill notifications Adds the iOS slice that closes the legislative loop when a bill becomes law: - TrackRoyalAssent use case + RecentLawQueryPort surface bills that received Royal Assent in the last 30 days, sorted most recent first. - NotifyFollowedBillRoyalAssent use case + RoyalAssentNotificationPort schedule a local user notification when a followed bill transitions to Royal Assent during a backend bill refresh. UNUserNotificationCenter stays behind LiveRoyalAssentNotificationAdapter. - Bill gains royalAssentDate, summary, and sponsorProfileURL parsed from the existing LEGISinfo adapter (no new wire format on iOS). - HomeFeedView adds a "Recently Became Law" section backed by RecentlyBecameLawCard. Each row links into BillDetailView, surfaces the sponsor as a MemberProfileView link when the local SwiftData store has the MP, falls back to a Parliament.ca sponsor link otherwise, and links out to LEGISinfo. - BillsView accepts an initialTab argument so the home "See laws" link deep-links into the Became Law filter. - BillFollowStore triggers the notification path when refresh data shows a followed bill flipped to Royal Assent. - Use case catalog gains TrackRoyalAssent and NotifyFollowedBillRoyalAssent entries with current implementation pointers. Release-Note: New "Recently Became Law" card on the Home feed, a "Became Law" filter in the Bills tab, and a notification when a bill you follow receives Royal Assent.
Contributor
Author
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.
Summary
Implements the iOS slice of EPAC-691. Closes the legislative loop when a bill becomes law:
MemberProfileViewwhen the MP is in the local SwiftData store, falling back to a Parliament.ca sponsor link), LEGISinfo summary subtitle, and a LEGISinfo link.UNUserNotificationCenterbehindRoyalAssentNotificationPortso the use case stays free of platform notification APIs.Clean Architecture additions (per the issue's Clean Architecture Shape):
TrackRoyalAssent,NotifyFollowedBillRoyalAssentRecentLawQueryPort,RoyalAssentNotificationPortRoyalAssentNotificationLiveRoyalAssentNotificationAdapterRecentlyBecameLawCard, BillsViewbecameLawfilter tabBillnow carriesroyalAssentDate,summary, andsponsorProfileURL, parsed from the existing LEGISinfo adapter (no new wire format on iOS).Use case catalog updated with both new use cases and their adapter pointers.
Test plan
TrackRoyalAssentTests— filters to last 30 days and sorts most recent first.NotifyFollowedBillRoyalAssentTests— emits a properly formatted notification through the port.SnapshotTests.testRecentlyBecameLawCard— pixel snapshot of the new home card.--strictclean on changed files (71 pre-existing violations unrelated to this change).pr-buildbecause the local build database was contended between concurrent agent sessions. New use case + view layer compiled cleanly in intermediate builds before the rebase (TrackRoyalAssent.d/NotifyFollowedBillRoyalAssent.dpresent in DerivedData).Release-Note: New "Recently Became Law" card on the Home feed, a "Became Law" filter in the Bills tab, and a notification when a bill you follow receives Royal Assent.