Text in a flex container doesn't wrap in IE11

后端 未结 12 2253
自闭症患者
自闭症患者 2020-11-22 05:23

Consider the following snippet:

12条回答
  •  庸人自扰
    2020-11-22 05:34

    Hi for me I had to apply the 100% width to its grandparent element. Not its child element(s).

    .grandparent {
        float:left;
        clear: both;
        width:100%; //fix for IE11 text overflow
    }
    
    .parent {
        display: flex;
        border: 1px solid red;
        align-items: center;
    }
    
    .child {
        border: 1px solid blue;
    }
    

提交回复
热议问题