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

DSD-1852: SubNav Menu Component #1697

Merged
merged 111 commits into from
Nov 25, 2024
Merged

Conversation

gonuguntla
Copy link
Collaborator

@gonuguntla gonuguntla commented Nov 5, 2024

Fixes JIRA ticket (https://newyorkpubliclibrary.atlassian.net/browse/DSD-1852)

This PR does the following:

  • Implemented subnav

How has this been tested?

  • local Storybook

Accessibility concerns or updates

Accessibility Checklist

  • Checked Storybook's "Accessibility" tab for color contrast and other issues.
  • The feature works with keyboard inputs including tabbing back and forward and pressing space, enter, arrow, and esc keys.
  • For hidden text or when aria-live is used, a screenreader was used to verify the text is read.
  • For features that involve UI updates and focusing on DOM refs, focus management was reviewed.
  • The feature works when the page is zoomed in to 200% and 400%.

Open Questions

Checklist:

  • I have updated the Storybook documentation and changelog accordingly.
  • I have added relevant accessibility documentation for this pull request.
  • All new and existing tests passed.

Front End Review:

  • Review the Vercel preview deployment once it is ready.

Copy link

vercel bot commented Nov 5, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
nypl-design-system ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 25, 2024 5:27pm

@gonuguntla gonuguntla changed the title SubNav Menu Component DSD-1852 SubNav Menu Component Nov 5, 2024
@gonuguntla gonuguntla changed the title DSD-1852 SubNav Menu Component DSD-1852: SubNav Menu Component Nov 5, 2024
Copy link
Member

@EdwinGuzman EdwinGuzman left a comment

Choose a reason for hiding this comment

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

This looks good to me, thanks for working on this and making all the updates.

Copy link
Collaborator

@7emansell 7emansell left a comment

Choose a reason for hiding this comment

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

Quick question about the colors but otherwise looks and works great! Is there already a place where we're planning to use this?

import List from "../List/List";
import useScrollFadeStyles from "../../hooks/useScrollFadeStyles";

export const actionBackgroundColorsArray = [
Copy link
Collaborator

Choose a reason for hiding this comment

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

Both arrays of colors are already declared in Banner– could they live in one place now that two components are using them?

Copy link
Collaborator

Choose a reason for hiding this comment

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

@7emansell Yes, that is the eventual goal, but for now, we are continuing to use unique data objects in the separate components.

Copy link
Collaborator

@bigfishdesign13 bigfishdesign13 left a comment

Choose a reason for hiding this comment

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

Just one minor addition to the story for the hook, but otherwise, it looks good.

inline
noStyling
>
<>
Copy link
Collaborator

Choose a reason for hiding this comment

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

This can be removed.

Link
</SubNavLink>
</li>
</>
Copy link
Collaborator

Choose a reason for hiding this comment

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

This can be removed.

</li>
</>
</List>
{showRightFade && <Box sx={styles.fadeEffect} />}
Copy link
Collaborator

Choose a reason for hiding this comment

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

@deepikagonuguntla Can you also include a code example showing the styles?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Ok

@bigfishdesign13 bigfishdesign13 added Changes Requested Pull requests where changes have been requested in peer review. and removed Needs Review Pull requests that are ready for peer review. labels Nov 22, 2024
@oliviawongnyc
Copy link
Collaborator

Screen.Recording.2024-11-22.at.1.58.46.PM.mov

Just wondering - is the height of the component meant to grow as the screen shrinks? @deepikagonuguntla

@bigfishdesign13
Copy link
Collaborator

Screen.Recording.2024-11-22.at.1.58.46.PM.mov
Just wondering - is the height of the component meant to grow as the screen shrinks? @deepikagonuguntla

@oliviawongnyc Yes. There are two things happening when it hits the mobile viewport. First, the overall padding within the component jumps from 8px to 16px. Second, the buttons increase in height from 32px to 44px for mobile a11y compliance.

@oliviawongnyc
Copy link
Collaborator

Screen.Recording.2024-11-22.at.1.58.46.PM.mov
Just wondering - is the height of the component meant to grow as the screen shrinks? @deepikagonuguntla

@oliviawongnyc Yes. There are two things happening when it hits the mobile viewport. First, the overall padding within the component jumps from 8px to 16px. Second, the buttons increase in height from 32px to 44px for mobile a11y compliance.

I see, thanks, Marty!

Copy link
Collaborator

@bigfishdesign13 bigfishdesign13 left a comment

Choose a reason for hiding this comment

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

Looks good!

@bigfishdesign13 bigfishdesign13 added Ship It Pull requests that have been reviewed and approved. and removed Changes Requested Pull requests where changes have been requested in peer review. labels Nov 25, 2024
@bigfishdesign13 bigfishdesign13 merged commit 5043b6a into development Nov 25, 2024
5 checks passed
@bigfishdesign13 bigfishdesign13 deleted the DSD-1852/sub-nav-menu branch November 25, 2024 17:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Ship It Pull requests that have been reviewed and approved.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants