Problem with UL/LI styling

About the template and stylesheet - and changing the menu
Tata
Posts: 3601
Joined: Tue May 20, 2008 5:34 am
Location: Slovakia
Contact:

Re: Problem with UL/LI styling

Post by Tata » Thu Feb 05, 2015 4:06 pm

vertical-align: middle makes also no change
CMSimple.sk
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.

cmb
Posts: 14227
Joined: Tue Jun 21, 2011 11:04 am
Location: Bingen, RLP, DE
Contact:

Re: Problem with UL/LI styling

Post by cmb » Thu Feb 05, 2015 4:39 pm

Works fine now: http://164xh.cmsimple.sk/ (you may have to refresh the website/purge the browser cache).
Christoph M. Becker – Plugins for CMSimple_XH

Tata
Posts: 3601
Joined: Tue May 20, 2008 5:34 am
Location: Slovakia
Contact:

Re: Problem with UL/LI styling

Post by Tata » Thu Feb 05, 2015 4:44 pm

Even after clearing the cache, the menu items (the circles) change to vertical elipses when reducing the width of the browser, instead of flowing to new row.
CMSimple.sk
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.

cmb
Posts: 14227
Joined: Tue Jun 21, 2011 11:04 am
Location: Bingen, RLP, DE
Contact:

Re: Problem with UL/LI styling

Post by cmb » Thu Feb 05, 2015 5:01 pm

Tata wrote:Even after clearing the cache, the menu items (the circles) change to vertical elipses when reducing the width of the browser, instead of flowing to new row.
Ah, I understand now -- sorry for the confusion. The problem is display:table-row resp. table-cell which let the menu work like at table; i.e. it's becomes narrower if there's not enough room.

You can get around that by displaying the <li>s as inline-block. However, that makes it hard to center vertically, so you can let the <a>s display as table-cell; then vertical-align will be recognized. However, you need to set the width and the height on the <a>s instead of the <li>s.

I've made the mentioned modifications -- might be a starting point.
Christoph M. Becker – Plugins for CMSimple_XH

Post Reply