2014-12-03 34 views
0

我只是測試了Polymer tutorial(請參閱HTML/CSS等教程頁),而我這個保證金不解:聚合物教程項目中的怪異邊距 - 如何去除?

enter image description here

正如你所看到的,到了「所有的左「 - 選項卡,有一個藍色的邊緣。在Firefox和Firebug的它看起來像這樣:

enter image description here

似乎有兩個部分在左邊(也可能是正確的),其中有某種形式的緩衝區。我一直無法找到該空間來自哪裏,因此無法將其刪除。

我已經嘗試設置填充,邊距爲零,並通過FireFox刪除的東西,讓它消失,但我還沒有找到它。

任何人都知道嗎?

+0

你可以發佈代碼在你的問題,並添加jsfiddle的問題?沒有任何代碼就無法提供幫助。 – Stefan 2014-12-03 11:46:01

回答

0

首先填充來自這裏(的index.html):

core-toolbar .toolbar-tools { 
    height: 64px; 
    padding: 0 8px; /* <--- */ 
    pointer-events: none; 
    position: relative; 
} 

比利潤率從這裏:

paper-tab .tab-content { 
    height: 100%; 
    margin: 0 12px; /* <--- */ 
    transition: opacity 0.1s cubic-bezier(0.4, 0, 1, 1) 0s, color 0.1s cubic-bezier(0.4, 0, 1, 1) 0s; 
} 

如果刪除margin和padding和額外設置:

paper-tabs { 
    height: 64px; 
} 

菜單項將佔用藍色標題區的全部高度。

+0

你在哪裏可以找到這些CSS類?什麼文件?我沒有看到它在任何index.html,我檢查\組件\核心工具欄\核心toolbar.html,\組件\核心工具欄\ index.html,\完成\ index.html和\ starter \ index.html? – Ted 2014-12-04 16:55:06

+0

所有這些都在我們正在查看的文件內部,在html內部。最後,這很重要嗎?爲了消除它們,只需重寫(這是問題)。認爲它是'step-1/index.html'。 – skobaljic 2014-12-04 23:10:24