【问题标题】:How do i vertically center that sidemenu in the left?我如何垂直居中左侧的侧边菜单?
【发布时间】:2021-05-19 13:52:03
【问题描述】:

我试图将此侧边菜单垂直居中在左侧,但我做不到。帮助?可能带有柔性显示

#side-menu {
background-color: white;
position: absolute;
right: -40px;
border-radius: 25px;
padding: 10px;
padding-right: 30px;
margin: 20px;
display: flex;
flex-direction: column;
align-items: center;
}

https://imgur.com/a/xjaeHZ3

【问题讨论】:

    标签: html css vue.js


    【解决方案1】:

    尝试使用 justify-content 来做到这一点。在使用 flex 时,它会发挥您所寻求的魔力。

    Justify-content: center
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2019-04-22
      • 2017-09-28
      • 1970-01-01
      • 2014-12-17
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多