2016-09-28 2 views
0
에 색상을 유지할 수 없습니다

내 테이블이있는 버그가 있습니다 오버 플로우 (스크롤)가있는 셀은 셀의 색을 유지하는 데 문제가있는 것 같습니다. 뭔가 이상하게 느껴질 수 있습니다. 색상이 표 아래에 있습니다 ("Légende"버튼이있는 곳).세포가 태블릿

내 CSS의 일부 :

table { 
    table-layout: fixed; 
    width: 100%; 
} 

table tr td{ 
    overflow: scroll; 
    overflow-y: hidden; 
    overflow-x: auto; 
    white-space: nowrap; 
} 

td::-webkit-scrollbar-thumb { 
    -webkit-border-radius: 2px; 
    -webkit-box-shadow: inset 0 0 2px rgba(0,0,0,0.5); 
    background: transparent; 
} 

td::-webkit-scrollbar-thumb:window-inactive { 
    background: rgba(255,255,255,0.3); 
} 

td::-webkit-scrollbar-track { 
    background: transparent; 
    border: 0; 
} 

::-webkit-scrollbar-corner { 
    background: transparent; 
} 

::-webkit-scrollbar { 
    width: 8px; 
    height: 8px; 
} 

::-webkit-scrollbar-thumb:hover { 
    background: #838383; 
} 

::-webkit-scrollbar-thumb:active { 
    background: #6a6a6a; 
} 

tr { 
    background-color: rgb(xx, xx, xx); 
    display: tabl-row; 
} 

이 (크롬을 사용하여, 태블릿) 나는 작은 화면에이기 때문에 내 CSS에 문제가 있거나 버그인지는 알고있다. 노트북 화면에는 문제가 없습니다 (Chrome도 마찬가지입니다).

답변

1

오버 플로우 스크롤을 td 태그에 직접 적용 할 수 없습니다. 따라서 td 태그 안에 설정된 overflow : scroll 속성을 사용하여 블록 수준 div를 중첩합니다. 이처럼 :

<td><div style="overflow:scroll;">Content</div></td> 

당신은 당신이 맞다이 Similar problem here

+0

를 참조 할 수 있습니다, 나는 TD 태그 내부의 사업부가 필요합니다. 더 이상 버그가 없습니다! 고맙습니다. –