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
feat[FX-3173]: Modernize /categories page #8379
Conversation
a349e5e
to
98c4e9c
Compare
return ( | ||
<SwiperRail {...props} display="block" position="relative" left={left} /> | ||
) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dzucconi - you might be able to advise here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait what's this doing? We should just skip all the sticky stuff here; which should simplify things. I can take a closer look on Monday though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just pushed up some updated code - from the designs, this rail should be stuck to the top on scroll
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So yeah; I wouldn't use a Swiper here at all. Just use HorizontalOverflow
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ping on those docs @dzucconi https://palette.artsy.net/elements/horizontaloverflow/ 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool, that definitely reduces code and complexity. Q for you @dzucconi - the scrollbar appears on HorizontalOverflow, and it seems like it shouldn't based on this line. When I inspect the bar, I actually don't see any scrollbar-width
property set in the CSS (I would expect to see it on Viewport
):
Any idea what might be up here? IMO this shouldn't block this PR, but would be nice to sort out.
96253b6
to
ed8a2f9
Compare
const { geneFamiliesConnection } = props | ||
const geneFamilies = extractNodes(geneFamiliesConnection) | ||
const { mobile, desktop } = useNavBarHeight() | ||
const isMobile = useMatchMedia(themeProps.mediaQueries.xs) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We'll want to avoid this as it's not SSR friendly
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So nice to see this hacky hackathon hack grow up and become a real app
I checked this out locally to take it for a spin and one thing confused me though — I couldn't seem to horizontally swipe the pill navigation. Just me?
ed8a2f9
to
a4db972
Compare
a4db972
to
3ba6beb
Compare
62327e1
to
3b41d13
Compare
Evened out that spacing and updated the screenshots! |
Regarding the scrollbar: I'm a little puzzled by this myself. I haven't looked into it much yet. Just ignore for now and I'll track down the root cause. |
🚢 |
Looking great, gonna merge this 🚢 |
Included in this PR:
Before:
Big/zoomed out browser width
Small screen
After:
Big/zoomed out window, top
Big/zoomed out window, scrolled + stuck
Small screen, top
Small screen, scrolled + stuck