[英]Chrome is breaking flexbox while Firefox doesn't
Chrome在網站首頁上破壞flexbox CSS時出現問題,而FF沒有。 這是HTML
<div class="intro_container">
<div id="top_text1" class = "intro_items intro_item_1">
....
</div>
<div id="top_text2" class = "intro_items intro_item_1">
....
</div>
</div>
和CSS
div.intro_container {
width: 100%;
background:;
display: flex;
flex-direction: row;
flex-wrap: wrap;
align-items: center;
justify-content: center;
}
div.intro_items {
background: white;
border: .1em solid #000093;
margin: 0.5em;
padding: 3%;
flex: 1 0 40%;
}
任何幫助將是最歡迎的
從我的角度來看,問題不在於瀏覽器或flex屬性問題。
問題在於以下CSS樣式,
div#top_text1 {margin-top: -3%;}
在layout.css文件中的行號:325
因此,只需刪除此CSS樣式,然后添加它即可。...
我遇到了類似的問題...我的頁面在IE,Firefox,Opera和Safari中都可以正常運行...但是在Chrome中,DIV寬度現在“被破壞”了……就在最后一周左右。
檢入Firebug(等)時,我必須將某個DIV設置為比普通像素大一個像素,否則里面的圖片會被“擠出”。
直到明天我都無法到達服務器來實際編輯任何內容,但“檢查元素”顯示這是一種解決方法。 不確定為什么問題會抬起頭來,確切來說-該頁面已經運行了一年多了:-(
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.