2015-02-12 32 views
0

我使用的哲基爾CMS這哪裏是CSS「浮動:左」獲得,從 - 傑基爾

頭的基本結構

<div class="top"> 

</div> 


<div class="header-wrapper"> 

    <div class="header-left"><img src="/assets/images/lawmen1.png" alt="Law and Lawson Attorney at Law Lawyers City State"></div> 
    <div class="header-right"> 
    <ul> 
     <li><i class="fa fa-location-arrow fa-2x"></i>250 W. Main Street Suite 2510<br>City, State 90210</li> 
     <li><i class="fa fa-mobile fa-2x"></i>(555) 555-555</li> 
     <li><i class="fa fa-fax fa-2x"></i>(555) 555-5555</li> 
    </ul> 
    </div> 

</div> 

這裏是CSS

@import '1-tools/-tools-index'; 


.top{ 
    width:100%; 
    height: 30px; 
    background-color: #1A1A1A; 
} 


.header-wrapper{ 

    @include outer-container; 
    padding-bottom: 2.5em; 


    .header-left{ 
    @include span-columns(4); 
    height: 200px; 
    img{ 
     display:block; 
     margin: 0 auto; 
     padding: 2.8em; 
     height:285px; 
     width:325px; 
    } 
    } 

    .header-right{ 
    margin-top:2.5em; 
    height: 200px; 

    @include span-columns(8); 
    ul{ 
     li{ 
     font-family: Garamond; 
     color: grey-color-dark; 
     font-size: 1.1em; 
     } 
    } 

    i{ 
     padding:0.2em; 
     height: 50px; 
     width:50px; 
     color: #d3bc5f; 
    } 
    } 
} 

enter image description here

所以,你可以看到,我沒有刻意在使用float: left css。

但是,您可以檢查該傑基爾已經產生float: left在main.scss

是,我在使用這個影響的CSS語法元素的截圖中看到?如 。 。

<div class = "outside"> 
<div class = "left"></div> 
<div class = "right"></div> 
</div 

.outside { 
.left { 

} 
.right { 

} 
} 

可以像這樣嵌套CSS嗎?

+0

它可能通過提供您所使用的包括。 – sevenseacat 2015-02-12 06:36:55

回答

2

這來自_sass/1-tools/neat/grid/_span-columns.scss文件。 通過閱讀我們知道我們可以做一個去除float和顯示屬性table-cell商務部:

@include span-columns(8, 'table');