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

Change side bar color and fix side bar 100% height #60

Open
pavvvan opened this issue Apr 23, 2020 · 4 comments
Open

Change side bar color and fix side bar 100% height #60

pavvvan opened this issue Apr 23, 2020 · 4 comments

Comments

@pavvvan
Copy link

pavvvan commented Apr 23, 2020

No description provided.

@pedrohba1
Copy link

pedrohba1 commented Jun 1, 2020

Changing the color is simple:

import SideNav from "@trendmicro/react-sidenav";

const StyledSideNav = styled(SideNav)`
    background-color: #0057c3;
`;

The bar out-of-the-box works for 100% height for me, do you have a picture to show what you mean?

@pedrohba1
Copy link

I actually found out your problem, of the 100% height. try adding this inside you SideNav component:

   style={{
                        position: "fixed",
                    }}

this will fix the navbar to the right, and then the user can scrooll the page and it will always show it in same place. It is no 100% height but it works for desktop at least

@moezlaarif
Copy link

Changing the color is simple:

import SideNav from "@trendmicro/react-sidenav";

const StyledSideNav = styled(SideNav)`
    background-color: #0057c3;
`;

The bar out-of-the-box works for 100% height for me, do you have a picture to show what you mean?

`render() {

const { expanded} = this.state;

const StyledSideNav = styled(SideNav)`
background-color: #808080;

`;

return (

(
        <SideNav StyledSideNav={StyledSideNav}

`
Should it bi like this ? it didn't wordk for me ?

@christrt9
Copy link

I also cannot change the background. Do you find the solution?
version: react-sidenav: "^4.0.6"

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

No branches or pull requests

4 participants