fix: remove nih ras banner from the anvil data explorer (#4940) - #4941
Merged
Conversation
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Removes the now-stale NIH RAS announcement banner from the AnVIL CMG dev configuration while keeping the shared Announcements wrapper (and its session-timeout/system/indexing banners) intact.
Changes:
- Deleted the NIH RAS banner component (
RAS) and removed its usage from the AnVIL CMG dev announcements config. - Made
generalAnnouncementoptional onAnnouncementsso the wrapper can render with no “general” banner content.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| site-config/anvil-cmg/dev/announcements/announcements.tsx | Stops passing the removed RAS banner as generalAnnouncement while keeping the Announcements wrapper configured. |
| app/components/common/Banner/components/Announcements/announcements.tsx | Makes generalAnnouncement optional so the component can render nothing when no general banner is provided. |
| app/components/anvil/banner/RAS/ras.tsx | Removes the stale RAS banner component entirely. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
NoopDog
approved these changes
Aug 21, 2026
NoopDog
left a comment
Collaborator
There was a problem hiding this comment.
Reviewed the full diff plus surrounding call sites — no correctness findings.
- Deletion is clean:
RAShad exactly one importer (site-config/anvil-cmg/dev/announcements/announcements.tsx), removed in the same diff. Remainingrashits in the authentication configs are the OAuth provider URLs, correctly untouched. - Dropping
propsis safe —ComponentConfig.propsis optional andComponentCreatorspreads it. - No empty-chrome regression:
HeaderrendersAnnouncementswith no wrapper spacer, the config array is still one element, andgeneralAnnouncementis the finalelsebranch soundefinedrenders nothing. Session-timeout/system-unavailable/indexing branches are hook-driven and unaffected. - Propagates to prod as described —
prod,tempdev, andcc-devinherit the header viamakeConfigfromsite-config/anvil-cmg/dev/config.ts.
Non-blocking nit (already flagged by the author): announcements.tsx no longer contains JSX and could be renamed to .ts, matching site-config/hca-dcp/ma-dev/layout/announcements.ts.
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.
Closes #4940
What changed
app/components/anvil/banner/RAS/ras.tsx.RASimport and thegeneralAnnouncementprop fromsite-config/anvil-cmg/dev/announcements/announcements.tsx. The config entry itself stays, so theAnnouncementswrapper keeps rendering (prod inherits this viamakeConfiginsite-config/anvil-cmg/prod/config.ts, so no prod change was needed).generalAnnouncementoptional on theAnnouncementscomponent. It was the only caller, so after this change a required prop would have had zero callers — the optional type now reflects reality.The
Announcementswrapper is untouched otherwise: it still renders the session-timeout, system-unavailable and indexing banners, which are driven by its own hooks rather than by props.Why
The banner announced an eRA Commons → Login.gov/ID.me transition deadline of March 25, 2026, which has passed, so the notice is stale.
How verified
The load-bearing check was grepping the built artifact: the RAS banner text is absent from
out/, while the session-timeout and indexing banner strings are still shipped — confirming the wrapper survived rather than being removed along with the announcement.tsc --noEmitclean; prettier and eslint clean on both changed files.npm run build-cc-dev:anvil-cmgsucceeded through postbuild.npm run test:anvil-cmg: 132 passed (chromium/firefox/webkit) against a fresh build of this branch.RASreferences remain inapp/,site-config/,e2e/or__tests__/;C.Announcementshad exactly one consumer andgeneralAnnouncementexactly one caller, both accounted for.Notes for the reviewer
site-config/anvil-cmg/dev/announcements/announcements.tsxnow contains no JSX, so its.tsxextension is no longer warranted — the comparablesite-config/hca-dcp/ma-dev/layout/announcements.tsis already.ts. Left as-is to keep this diff to the ticket's scope; happy to rename if preferred.🤖 Generated with Claude Code