2017-08-24 67 views
0

我使用的是引導儀表板由Creative Tim,並試圖將一個下拉列表添加到表格單元格作爲典型的自舉右對齊的指針一個指針下拉列表中,這是很好又漂亮,可是左對齊:CSS在下拉

enter image description here

如何轉變風格this指針,因此它是右對齊?

enter image description here

,但我無法重現它的導航面板外:在頁面頂部看到下拉菜單 -

的風格確實存在這種行爲。

我在這裏上傳有問題的網頁(也有很多款式有上傳到的jsfiddle): http://fredapps.s3.amazonaws.com/light-bootstrap-dashboard-pro/examples/tables/regular2.html

+0

無法訪問此鏈接,訪問被拒絕。 – Johannes

回答

0

他似乎做它his live preview的方法就是通過CSS。所以如果我是你,我會去看看那裏,看看你們有什麼不同。我的屏幕截圖顯示:before僞元素,請確保您也看到了:after

enter image description here

0

頂部導航風格將覆蓋:before:afterleft值。

的默認樣式是這樣的:

.dropdown-menu:before { 
    border-bottom: 11px solid rgba(0, 0, 0, 0.2); 
    border-left: 11px solid transparent; 
    border-right: 11px solid transparent; 
    content: ""; 
    display: inline-block; 
    position: absolute; 
    left: 12px; 
    top: -11px; 
} 

.dropdown-menu:after { 
    border-bottom: 11px solid #FFFFFF; 
    border-left: 11px solid transparent; 
    border-right: 11px solid transparent; 
    content: ""; 
    display: inline-block; 
    position: absolute; 
    left: 12px; 
    top: -10px; 
} 

更新他們:

... { 
    left: auto; 
    right: 12px; 
}