语义UI:带有图标的侧栏始终可见 [英] Semantic-UI: Sidebar with Icons always visible

查看:195
本文介绍了语义UI:带有图标的侧栏始终可见的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想实现一个侧边栏,每个条目都有一个图标沿着它的文本。

I'd like to implement a sidebar, where each entry will have an Icon along to it's text.

在停用状态下,侧边栏应仅显示图标,如果处于激活状态,侧边栏应扩展至其整个宽度,并显示其图标和文本的条目。
就像扩展菜单按钮菜单按钮>,但这是整个侧边栏的行为。

In deactivated state, the sidebar shall display only the icons, wheres in activated state, the sidebar shall expand to its whole width, showing its entries with both icons and text. Just like the menu button in Expanding Menu Button, but this behaviour for the whole sidebar.

这可以使用Semantic UI吗?

Can this be done using Semantic UI?

推荐答案

我前一段时间问过类似的问题,此处,我自己通过修改一些Semantic-UI的源代码来设法解决它。

I have asked a similar question a while ago here, and I managed to solve it myself, by modifying some of Semantic-UI's source code.

不幸的是,这些修改过于广泛,无法直接发布这个答案,所以我创建了一个github回购示例,其中包含一个示例此处。希望它有帮助。由于来自Semantic-UI的源代码已被修改,所以正常的侧边栏可能会有问题。

Unfortunately, the modifications were too extensive to post them directly in this answer, so I have created a github repo with an example here. Hopefully it helps. Due to the fact that the source code from Semantic-UI was modified, normal sidebars will probably be buggy.

这篇关于语义UI:带有图标的侧栏始终可见的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆