Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EREGCSC-2585 -- Update display of resources on site homepage #1458

Merged
merged 10 commits into from
Nov 4, 2024

Conversation

PhilR8
Copy link
Contributor

@PhilR8 PhilR8 commented Oct 28, 2024

Resolves EREGCSC-2585

Description

Updates the Recent Guidance/Rules tabs on the homepage.

This pull request changes:

  • Removes descriptive label text from Recent Guidance tab and tweaks the text in the Recent Rules tab
    • Updated text in the Recent Rules tab should be "Includes 42 CFR 400, 430-460, 483, 600; 45 CFR 95, 155-156"
  • Increases number of items displayed to five for each tab
    • This is accomplished by increasing the pageSize argument from 3 to 5
  • For Recent Rules tab: increases the number of title lines shown from three to nine to match settings in the reader view sidebar
    • This is accomplished by updating the itemTitleLineLimit injection key that is provided to all descendant components
  • For Recent Guidance tab: adds Subject Chips to each result item that, when clicked, takes the user to the /subjects page with the clicked subject selected
    • This behavior should exactly mimic the behavior on the /search page when you click a Subject Chip
    • This is accomplished by re-using the SubjectChips.vue component that is also used in the /search and /subjects page
  • Adds Cypress end to end tests where appropriate

Steps to manually verify this change:

  1. Green check marks
  2. Visit experimental deployment
  3. Ensure that Subject Chips appear under each result item in the Recent Subregulatory Guidance tab
  4. When you click a Subject Chip, ensure that you are taken to the /subjects page with the correct subject selected on load
  5. Ensure that each tab (Recent Subregulatory Guidance/Recent Rules) has five result items
    • Note that Recent Rules list items may also have nested children
  6. Ensure that the title text for each Recent Rules list item can have up to nine lines of text before the text-overflow: ellipsis style rule is applied
    • This style rule is respected for all widths, so if you narrow your browser window size, the title label should still max out at nine lines
  7. Ensure that the Recent Subregulatory Guidance tab doesn't have any label text
  8. Ensure that Recent Rules tab has the following label text:
    • "Includes 42 CFR 400, 430-460, 483, 600; 45 CFR 95, 155-156"

Copy link

✨ See the Django Site in action

Copy link

✨ See the Django Site in action

Copy link

✨ See the Django Site in action

Copy link

✨ See the Django Site in action

Copy link

✨ See the Django Site in action

@PhilR8 PhilR8 marked this pull request as ready for review October 30, 2024 11:13
@PhilR8 PhilR8 requested a review from cgodwin1 as a code owner October 30, 2024 11:13
@PhilR8 PhilR8 added the Needs Review This PR needs a code review label Oct 30, 2024
@@ -216,7 +216,7 @@ export default [
description: "SMDLs, SHOs, CIBs, FAQs, SMM",
id: 4,
is_fr_link_category: false,
name: "Subregulatory Test Guidance",
name: "Subregulatory Guidance",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This was too clever by half and was screwing up the homepage tests. We need this to be Subregulatory Guidance in order to fetch the data from this fixture for the Recent Guidance tab

Copy link

✨ See the Django Site in action

Copy link
Contributor

@cgodwin1 cgodwin1 left a comment

Choose a reason for hiding this comment

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

LGTM!

@cgodwin1 cgodwin1 added Approved and removed Needs Review This PR needs a code review labels Nov 1, 2024
@PhilR8 PhilR8 merged commit 646f9bd into main Nov 4, 2024
20 checks passed
@PhilR8 PhilR8 deleted the 2585-homepage-rsrcs-display branch November 4, 2024 17:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants