Are there any plans to give you the ability to dynamically size a dock via script?
I have 3 different sidebar views docked (collapsed, hover, expanded) to get it the work the way I want. But that ended up creating a few other problems for me - when my hover state sidebar is displayed, the right padding on every page needs to be dynamic since that will need to be adjusted since the default collapsed view dock is no longer there. I'm still not happy with the end result because it creates an unnecessary animation for each page.
There are no plans to provide dynamic sizes for Docked views at this time.
For the layout you’re describing and exhibiting in that attachment, I would recommend you create the Page/View with a View Canvas. This would allow you to set relative positioning for the “central” view based on the expansion state of the “docked” view, while still making use of a transition animation.
I found a way to use a single docked view as a collapsable and expandable sidebar and I want to make sure I’m not overlooking anything that may create issues?
I’m overwriting the fixed width of .docked-view-left. .docked-view-left { width: auto !important; }
Created a few empty styles in the designer and assigned each to different containers in my sidebar. I added my CSS to my custom theme to style the sidebar and used pseudo-elements to trigger width transitions and several other things (I didn’t like the accordion animation so I just made my own).
Hi Matt,
Thank you very much for your insights and guidance.
I just want to provide more details of the setup which works for me (in the case where there are people wondering)
First, I override the fixed with of the left dock (e.g., light.css)
.docked-view-left { width: auto !important; }
Secondly, I need to add 'minWidth' property to the view configured for the left dock.
Thirdly, to expand/collapse the left dock, I need to change the 'minWidth' accordingly (e.g., using messages in Perspective)
As you can see, depending on the screen resolution the project is viewed on, the content is not getting pushed, I want the top docked view to have an automatic height and be able to push the content automatically as well.
In the second image you can see that there is no problem, but in the first image you can see how the top docked view is on the content and is not pushing it.