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

How to set left sidebar is minimized as default #145

Closed
ngoctai opened this Issue Jan 10, 2019 · 6 comments

Comments

Projects
None yet
3 participants
@ngoctai
Copy link

ngoctai commented Jan 10, 2019

Hi all,
I want to show left sidebar minimized as default. I have tried to add minimized props to AppSidebar element as bellow <AppSidebar fixed minimized>. When i reload page i see it looks good but when i hover the mouse on it, it doesn't show child's menu level.
It's behavior isn't the same when i click on AppSidebarMinimizer element two times (that way works perfectly)

Thank all.

@nithinkashyapn

This comment has been minimized.

Copy link

nithinkashyapn commented Feb 21, 2019

Hey,

In public/index.html

Make body as this i.e., add the following class to it.

<body class="sidebar-minimized">
.
.
.
</body>

- Nithin

@xidedix xidedix added the bug label Feb 21, 2019

@xidedix xidedix self-assigned this Feb 21, 2019

xidedix added a commit to coreui/coreui-react that referenced this issue Feb 21, 2019

fix(Sidebar): How to set left sidebar is minimized as default
*How to set left sidebar is minimized as default* [#145](coreui/coreui-free-react-admin-template#145)
- refactor(Layout): LayoutHelper germ
- refactor(Sidabar): use static methods from `LayoutHelper`
- refactor(SidabarMinimizer): use static methods from `LayoutHelper`
@xidedix

This comment has been minimized.

Copy link
Collaborator

xidedix commented Feb 21, 2019

Hi @ngoctai, @nithinkashyapn - thanks for pointing this out!

Please update:

  • @coreui/coreui to 2.1.7
  • @coreui/react to 2.1.4
<AppSidebar fixed minimized>
...
</AppSidebar>

From now on minimized should work as expected.

Let us know if this helps.

xidedix added a commit that referenced this issue Feb 21, 2019

Ship v2.1.4
- maintenance release: fixes #151 #145
- dependencies update

@xidedix xidedix referenced this issue Feb 21, 2019

Merged

v2.1.4 #152

@nithinkashyapn

This comment has been minimized.

Copy link

nithinkashyapn commented Feb 22, 2019

Thank you.

@xidedix xidedix closed this Feb 25, 2019

@ngoctai

This comment has been minimized.

Copy link
Author

ngoctai commented Mar 2, 2019

<body class="sidebar-minimized">...</body>

<AppSidebar fixed minimized> ..</AppSidebar>

Thank you, need to add 2 things for this work.

@xidedix

This comment has been minimized.

Copy link
Collaborator

xidedix commented Mar 2, 2019

Hi @ngoctai, thanks for follow-up

it's intended to work without manual adding class sidebar-minimized to body.
what's your browser name/version?

@ngoctai

This comment has been minimized.

Copy link
Author

ngoctai commented Mar 2, 2019

Hi @ngoctai, thanks for follow-up

it's intended to work without manual adding class sidebar-minimized to body.
what's your browser name/version?

Yes, you're right. That is my mistake, after clean cache that works perfectly as you said. Thanks a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.