Skip to content

Conversation

@jazairi
Copy link
Contributor

@jazairi jazairi commented Dec 10, 2025

Why these changes are being introduced:

UXWS has determined that the 'sticky tab' behavior is frustrating in practice, and would prefer instead that the application identify the current tab based on params.

Relevant ticket(s):

How this addresses that need:

This refactors the set_active_tab method to check for the presence of params[:tab]. If that exists, it uses it as the active tab; if not, it defaults to 'all'.

Side effects of this change:

None.

Developer

Accessibility
  • ANDI or WAVE has been run in accordance to our guide.
  • This PR contains no changes to the view layer.
  • New issues flagged by ANDI or WAVE have been resolved.
  • New issues flagged by ANDI or WAVE have been ticketed (link in the Pull Request details above).
  • No new accessibility issues have been flagged.
New ENV
  • All new ENV is documented in README.
  • All new ENV has been added to Heroku Pipeline, Staging and Prod.
  • ENV has not changed.
Approval beyond code review
  • UXWS/stakeholder approval has been confirmed.
  • UXWS/stakeholder review will be completed retroactively.
  • UXWS/stakeholder review is not needed.
Additional context needed to review

While reviewing, please confirm that the tests for this feature still make sense. I intentionally did not include a regression test to check for the presence of cookies, but I could if that would be useful.

Code Reviewer

Code
  • I have confirmed that the code works as intended.
  • Any CodeClimate issues have been fixed or confirmed as
    added technical debt.
Documentation
  • The commit message is clear and follows our guidelines
    (not just this pull request message).
  • The documentation has been updated or is unnecessary.
  • New dependencies are appropriate or there were no changes.
Testing
  • There are appropriate tests covering any new functionality.
  • No additional test coverage is required.

Why these changes are being introduced:

UXWS has determined that the 'sticky tab' behavior is frustrating in
practice, and would prefer instead that the application identify the
current tab based on params.

Relevant ticket(s):

- [USE-228](https://mitlibraries.atlassian.net/browse/USE-228)

How this addresses that need:

This refactors the `set_active_tab` method to check for the presence of
`params[:tab]`. If that exists, it uses it as the active tab; if not, it
defaults to 'all'.

Side effects of this change:

None.
@jazairi jazairi force-pushed the use-228-revert-tab-cookies branch from 1a2d252 to f3ab61c Compare December 10, 2025 21:40
@jazairi jazairi had a problem deploying to timdex-ui-pi-use-228-re-wbcjiv December 10, 2025 21:41 Failure
@coveralls
Copy link

coveralls commented Dec 10, 2025

Pull Request Test Coverage Report for Build 20114131911

Details

  • 2 of 2 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.004%) to 98.138%

Totals Coverage Status
Change from base Build 20112755264: -0.004%
Covered Lines: 1107
Relevant Lines: 1128

💛 - Coveralls

@matt-bernhardt matt-bernhardt self-assigned this Dec 11, 2025
Copy link
Member

@matt-bernhardt matt-bernhardt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks - this works, and looks like a pretty clean removal.

:shipit:

@jazairi jazairi merged commit 2888060 into main Dec 11, 2025
5 checks passed
@jazairi jazairi deleted the use-228-revert-tab-cookies branch December 11, 2025 22:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants