LG-3711: Migrate ad hoc alerts to USWDS alert partial#4418
Conversation
In further testing, this didn't prove to be a problem after all. The initial worry was the difference in how we consider paths between... identity-idp/app/decorators/service_provider_session_decorator.rb Lines 126 to 127 in 97fe583 But it appears that by the time the view is rendered, the |
2604788 to
48ba7c5
Compare
|
Updates:
|
|
Fortunately the failing tests related to outdated selectors in ec77b7f2a clued me into a regression I'd accidentally introduced, where previously we relied on the decorator's Updated in 313f1c4e0. It also prompted me to figure out why my changes to |
|
I was having some trouble with tests in the previous implementation having the monkey-patch at I might very well be missing something obvious about load order / auto-loading / monkey-patching. Happy to adjust if I am, or if there might be a better place to put these files than creating a new directory. |
**Why**: Consolidate to single, consistent alert styling
**Why**: Only option to customize the rendered markup of alert to support nested alert tags
**Why**: Unused
**Why**: Autoload interop
**Why**: So next developer understands what's up
**Why**: From `generate_custom_alert`, easier to understand
**Why**: Broke with refactoring to sp_alert to avoid sp_msg. Since sp_msg was otherwise unused, absorb behavior into custom_alert as single source of (interpolated) message text.
**Why**: My own self-assurance that I'm not breaking things
**Why**: Allow base class to be defined for extension in tests
3cb35f4 to
55f0a4d
Compare

Related: LG-3711
Previously: #4375
Why: Consolidate to single, consistent alert styling.
I've had this branch sitting locally for some time, initially as an exploration of effort involved in migrating the remainder of ad-hoc alert usage.
A few notable findings:
alert-thumbdoesn't map directly to any equivalent design system variant, but I assume it should be eliminated in favor ofusa-alert--success.Following the logic, there may be an issue prior to these changes where SP custom alert texts may not be showing correctly in non-English locales. Needs more investigation.Edit: See LG-3711: Migrate ad hoc alerts to USWDS alert partial #4418 (comment).Not included here (yet): Simple Form may require more work to customize, since with the current configuration it assumes a particular alert markup which is not aligned to the USWDS alertsidentity-idp/config/initializers/simple_form.rb
Lines 6 to 7 in b72d615