Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Fix: Sidebar nav bugs#1447

Merged
benhalverson merged 16 commits into
nodejs:mainfrom
kunaljain0212:sidebarNav
Jun 20, 2021
Merged

Fix: Sidebar nav bugs#1447
benhalverson merged 16 commits into
nodejs:mainfrom
kunaljain0212:sidebarNav

Conversation

@kunaljain0212

Copy link
Copy Markdown
Contributor

Description

  1. Fixed the navigation issue for about tab.
  2. Added a fixed with to sidenav keeping the responsiveness in mind.
  3. Fixed the height issue for sidenav

To discuss:
The className of <main> tag was not consistent across different pages of the tab because of which it was causing spacing issues and also when I tried to decrease the width to check for responsiveness of the website the article section was overlapping with the sidenav. To overcome that I gave all the <main> tags a consistent className of "grid-container", now that issues is fixed. I am attaching images for reference.

Before:
image

After:
image

Related Issues

Fixes #1446

@kunaljain0212

Copy link
Copy Markdown
Contributor Author

/preview

@github-actions

Copy link
Copy Markdown

Please find a preview at: https://staging.nodejs.dev/1447/

Comment thread src/styles/about.scss Outdated
@rodion-arr

Copy link
Copy Markdown
Contributor

There is no way close about sidebar on mobile:

Screenshot 2021-06-18 at 11 35 37

@kunaljain0212

Copy link
Copy Markdown
Contributor Author

Thankyou for the review @rodion-arr . I have fixed both the issues, could you please review them once. Seems like the width of sidenav was changing because of different classNames of <main> tag. Since now they are consistent width: auto is working fine. Also the position of nav in responsive view from top had a slight error because of which the button was hidden now it is visible.

@kunaljain0212

Copy link
Copy Markdown
Contributor Author

/preview

@benhalverson benhalverson added the create-preview Generate preview on staging.nodejs.dev label Jun 18, 2021
@github-actions github-actions Bot removed the create-preview Generate preview on staging.nodejs.dev label Jun 18, 2021
@github-actions

Copy link
Copy Markdown

Please find a preview at: https://staging.nodejs.dev/1447/

@manishprivet manishprivet left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

It seems like the package-lock.json was modified while you did npm install. We are already using dependabot for updating dependencies in lockfile, so can you please revert this.

Also, it seems like you need to update the snapshots for the tests to pass.

Thanks

Comment thread src/styles/learn.scss Outdated
@nodejs nodejs deleted a comment from github-actions Bot Jun 18, 2021
@codecov-commenter

codecov-commenter commented Jun 18, 2021

Copy link
Copy Markdown

Codecov Report

Merging #1447 (311b315) into main (8d49750) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #1447   +/-   ##
=======================================
  Coverage   85.98%   85.98%           
=======================================
  Files          73       73           
  Lines         792      792           
  Branches      216      216           
=======================================
  Hits          681      681           
  Misses        111      111           
Impacted Files Coverage Δ
src/components/AboutPageSideNavBar/index.tsx 90.90% <ø> (ø)
src/pages/about.tsx 100.00% <ø> (ø)
src/pages/governance.tsx 100.00% <ø> (ø)
src/pages/privacy.tsx 100.00% <ø> (ø)
src/pages/releases.tsx 100.00% <ø> (ø)
src/pages/resources.tsx 100.00% <ø> (ø)
src/pages/security.tsx 100.00% <ø> (ø)
src/pages/trademark.tsx 100.00% <ø> (ø)
src/pages/working-groups.tsx 100.00% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8d49750...311b315. Read the comment docs.

@manishprivet manishprivet added the create-preview Generate preview on staging.nodejs.dev label Jun 18, 2021
@github-actions github-actions Bot removed the create-preview Generate preview on staging.nodejs.dev label Jun 18, 2021
@github-actions

Copy link
Copy Markdown

Please find a preview at: https://staging.nodejs.dev/1447/

@kunaljain0212

Copy link
Copy Markdown
Contributor Author

Added sidenav bar to releases page as well, as mentioned in the updated description of the issue #1447

@manishprivet manishprivet added the create-preview Generate preview on staging.nodejs.dev label Jun 18, 2021
@github-actions github-actions Bot removed the create-preview Generate preview on staging.nodejs.dev label Jun 18, 2021
@github-actions

Copy link
Copy Markdown

Please find a preview at: https://staging.nodejs.dev/1447/

@manishprivet manishprivet added the create-preview Generate preview on staging.nodejs.dev label Jun 19, 2021
@github-actions github-actions Bot removed the create-preview Generate preview on staging.nodejs.dev label Jun 19, 2021
@github-actions

Copy link
Copy Markdown

Please find a preview at: https://staging.nodejs.dev/1447/

@manishprivet

Copy link
Copy Markdown
Member

LGTM

@manishprivet

manishprivet commented Jun 19, 2021

Copy link
Copy Markdown
Member

@benhalverson The mobile menu, is that supposed to be like the learn page, or this is fine for now?

@benhalverson benhalverson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think it's ok for now. Ideally it should match the /learn mobile menu.

@manishprivet

Copy link
Copy Markdown
Member

I think we should wait for #1297 to be merged so that this PR finishes the about page once and for all

Comment thread src/styles/learn.scss
Comment thread src/styles/learn.scss
overflow-y: scroll;
position: fixed;
top: var(--nav-height);
top: calc(var(--nav-height) * 2);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think you can remove this now 🙂

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Right, removing it.

Comment thread src/styles/learn.scss
/* Needed since overflow: none will disable position: sticky on children */
clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
background-color: var(--color-fill-side-nav);
height: calc(100vh - var(--nav-height));

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

These changes are seemingly breaking the /learn page on mobile (https://staging.nodejs.dev/1447/learn)

image

Can you keep the styling changes limited to about.scss only

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

#1448 is taking care of the style issues

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The cross button is not visible in the deployed version (https://nodejs.dev/learn), which restricts the user from closing the sidenav in mobile view.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

#1448 handled that as well.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Great, thanks.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Here the pending thing, is you need to revert these lines to their original state.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Reverted back the above-mentioned changes and changes for extender class as both of these are being handled in #1448

@benhalverson benhalverson added the create-preview Generate preview on staging.nodejs.dev label Jun 20, 2021
@github-actions github-actions Bot removed the create-preview Generate preview on staging.nodejs.dev label Jun 20, 2021
@github-actions

Copy link
Copy Markdown

Please find a preview at: https://staging.nodejs.dev/1447/

@benhalverson benhalverson merged commit 2e5c834 into nodejs:main Jun 20, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: About page sidebar nav

6 participants