语言表达能力有限,直接上图。我想做的效果就是左侧是导航标题,右侧是对应的内容条目。
但是右侧内容条目数目不固定,因此对应的高度也不固定。这效果看似简单,但本人半天没想出来,苦读一天文档,终于找到解决方案(angularjs写的)。
.itemGroup {
position: relative;
}
.itemGroupTitle {
text-align: center;
color: white;
font-weight: bold;
position: static;
}
.itemGroupTitle1 {
position: absolute;
width: inherit;
height: 100%;
}
.itemGroupTitle2 {
position: absolute;
top: 0;
right: 0;
left: 0;
bottom: 0;
margin: auto;
width: 140px;
height: 20px;
}
{{item.GroupName}}>
{{keytype.KeyTypeName}}