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

refactor: Copy and refactor nav #107

Merged
merged 7 commits into from
Dec 11, 2024
Merged

Conversation

soniaklimas
Copy link
Contributor

I want to merge this change because it copies nav from fashion branch and refactores it.

Pull Request Checklist

  • Test the changes locally to ensure they work as expected.
  • Document the testing process and results in the pull request description. (Screen recording, screenshot etc)
  • Include new tests for any new functionality or significant changes.
  • Ensure that tests cover edge cases and potential failure points.
  • Document the impact of the changes on the system, including potential risks and benefits.
  • Provide a rollback plan in case the changes introduce critical issues.
  • Update documentation to reflect any changes in functionality.

@soniaklimas soniaklimas added the WIP label Dec 8, 2024
@soniaklimas soniaklimas self-assigned this Dec 8, 2024
Copy link

vercel bot commented Dec 8, 2024

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

Name Status Preview Comments Updated (UTC)
nimara-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 11, 2024 10:37am
nimara-ecommerce ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 11, 2024 10:37am

apps/storefront/src/lib/helpers.ts Show resolved Hide resolved
apps/storefront/src/components/mobile-navigation.tsx Outdated Show resolved Hide resolved
apps/storefront/src/components/mobile-navigation.tsx Outdated Show resolved Hide resolved
apps/storefront/src/components/mobile-navigation.tsx Outdated Show resolved Hide resolved
child.collection_slug ? { slug: child.collection_slug } : null,
child.page_slug ? { slug: child.page_slug } : null,
) ||
"#",
Copy link
Collaborator

Choose a reason for hiding this comment

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

why #?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It needs to be string to use it as a href in Link, but url from cms can be null.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yeah but all of the elements in the menu should be links so if someone won't set links via CMS the storefront should be notified so either make URLs as required fields in types or make a condition item.url && <Link. Setting the hash as the link value when it wasn't set in CMS doesn't seem right to me. The empty hash will navigate to the top of the page and be weirdly visible in URL

@soniaklimas soniaklimas merged commit 8c1daf7 into develop Dec 11, 2024
4 checks passed
@soniaklimas soniaklimas deleted the MS-864-copy-and-refactor-nav branch December 11, 2024 10:42
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.

2 participants