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

Supersubs auto width #54

Closed
waynebrantley opened this issue Apr 12, 2013 · 7 comments
Closed

Supersubs auto width #54

waynebrantley opened this issue Apr 12, 2013 · 7 comments

Comments

@waynebrantley
Copy link

I read that you removed the use for supersubs by making a css adjustment.

I have a vertical menu - and use supersubs to also autosize the FIRST LEVEL of the menu.

Is there some similar css change that can be made to make the first level not wrap and be the correct width without using supersubs?

@joeldbirch
Copy link
Owner

I can't check this right now, but it should work. At the top of superfish-vertical.css, simply replace the width rule with min-width. Or, you could just keep using supersubs.js v0.3b if you prefer. Hope this helps.

@joeldbirch
Copy link
Owner

Note that the min-width solution may not work if you didn't originally create your menu from v1.6.x+ CSS.

@joeldbirch
Copy link
Owner

I tested this and found it needed a smidgen more CSS for it to work. Here is a Gist of the final superfish-vertical.css file you will need to achieve the effect.

@waynebrantley
Copy link
Author

This worked GREAT. Suggest you update source to be like that!

@joeldbirch
Copy link
Owner

Excellent. But with regard to adding this as the default, I imagine the much more common scenario to be that a vertical menu needs to fit nicely within a sidebar rather than determine its own width. Do you disagree?

@waynebrantley
Copy link
Author

Humm....perhaps you are correct. I let mine determine its own width - so the sidebar can vary in size a bit. (normally a small amount). Perhaps then - adding an additional class that can be used to get this behavior - I would think others might want/need, but you know best!

joeldbirch added a commit that referenced this issue Apr 13, 2013
…termined by their widest top-level item (as per Supersubs). As discussed at #54.
@joeldbirch
Copy link
Owner

Thanks, I just released v1.7 and added a bit of code to superfish-vertical.css that, when uncommented, will provide this functionality. Cheers.

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

2 participants