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

feat(sidebar): added padding and border to sidebar #5221

Merged
merged 3 commits into from Mar 14, 2023

Conversation

mattnolting
Copy link
Contributor

closes #5131

@patternfly-build
Copy link

patternfly-build commented Nov 7, 2022

Copy link
Contributor

@mcoker mcoker left a comment

Choose a reason for hiding this comment

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

The padding looks great. The border is triggering unnecessary scroll in all directions because of the negative offset applied based on the gutter size.

I think there are a handful of ways to handle this, and mentioned some offline. AFAIK this isn't a pressing issue (I opened it), and I think it might be worth reconsidering the approach and doing so with v5 since I think we'll likely change the gutter system anyways and probably need to rework this anyways. The same goes for the padding, potentially. WDYT @mcarrano, do you see a need to get this in for v4 (or some part of it - like the padding and/or border between panel and content), or would it be ok to defer to v5?

src/patternfly/components/Sidebar/examples/Sidebar.md Outdated Show resolved Hide resolved
@srambach
Copy link
Member

I'm still seeing a phantom scrollbar I think?

2022-12-20_13-10-47.mp4

Copy link
Member

@srambach srambach left a comment

Choose a reason for hiding this comment

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

Examples look good now 👍

Comment on lines 187 to 189
&.pf-m-padding {
padding: var(--pf-c-sidebar__content--PaddingTop) var(--pf-c-sidebar__content--PaddingRight) var(--pf-c-sidebar__content--PaddingBottom) var(--pf-c-sidebar__content--PaddingLeft);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

These vars and the .pf-m-padding vars for __panel should probably be set to 0 by default, then the .pf-m-padding declares those vars like --sidebar__content--PaddingTop: var(--sidebar__content--m-padding--PaddingTop)?

Comment on lines 144 to 154
&::before {
display: var(--pf-c-sidebar__main--before--Display);
}

&.pf-m-border::before {
flex: 0 0 var(--pf-c-sidebar__main--m-border--before--BorderWidth);
align-self: stretch;
order: var(--pf-c-sidebar__main--m-border--before--Order);
content: "";
background-color: var(--pf-c-sidebar__main--m-border--before--BorderColor);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Could you move display into the second selector?

src/patternfly/components/Sidebar/sidebar.scss Outdated Show resolved Hide resolved
@mattnolting mattnolting force-pushed the feat-sidebar-5131 branch 2 times, most recently from 1c21660 to df9e909 Compare March 8, 2023 19:45
@srambach srambach merged commit 7196275 into patternfly:v5 Mar 14, 2023
@patternfly-build
Copy link

🎉 This PR is included in version 5.0.0-alpha.30 🎉

The release is available on:

Your semantic-release bot 📦🚀

mattnolting added a commit to mattnolting/patternfly that referenced this pull request May 18, 2023
* feat(sidebar): added padding and border to sidebar

* feat(sidebar): rebased, updated hbs template

* feat(sidebar): updated padding mods
mattnolting added a commit to mattnolting/patternfly that referenced this pull request Dec 12, 2023
* feat(sidebar): added padding and border to sidebar

* feat(sidebar): rebased, updated hbs template

* feat(sidebar): updated padding mods
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Sidebar - panel/content should support padding
6 participants