-
Notifications
You must be signed in to change notification settings - Fork 275
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
fix(Switcher): change width and border-bottom #372
fix(Switcher): change width and border-bottom #372
Conversation
This pull request is automatically deployed with Now. Latest deployment for this branch: https://gatsby-theme-carbon-git-fork-abbeyhrt-357-fix-switcher-px-off.carbon-design-system.now.sh |
@@ -3,14 +3,14 @@ | |||
z-index: 10000; | |||
position: fixed; | |||
right: 0; | |||
top: 48px; | |||
top: 47px; |
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.
Usually if we get into pixel nudging like this, there's a better solution somewhere. Doing this approach means we don't get the border-top like we want.
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.
Ah that makes sense! Made the change!
height: 100%; | ||
width: 16rem; | ||
background-color: $ui-05; | ||
border-left: 1px solid $inverse-02; | ||
transform: translateX(16rem); | ||
overflow-y: hidden; | ||
border-bottom: 1px solid transparent; | ||
border-bottom: 1px solid $inverse-02; |
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.
Try leaving the top
rule at 48px and just removing this border-bottom rule all together. That way the border will just appear instantly once the open
class gets applied.
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.
LGTM! Thanks!
Closes #357
48px
to47px
tp remove the 1px overhangTesting: check that the Switcher is no longer 1 px off and that the border matches the rest of the nav bar