2015-02-06 3 views
0

스타일을 추가 한 Google 차트로 만든 테이블이 있습니다. 문제는 내 padding 스타일이 Google의 스타일 시트 스타일보다 우선 순위가 낮다는 것입니다.CSS Google 차트를 변경하지 마십시오

.google-visualization-table-table *{}은 무엇입니까? 그거 어디서 났어?

사진의 가치는 천 단어입니다. > 여기

http://i.stack.imgur.com/bfhkY.jpg 코드뿐만 아니라입니다 :

.google-visualization-table-table) { 
    margin: 0; 
    vertical-align: middle; 
    padding: 2px; 
} 

// and my style code: 
.tableHeaderCell { 
    border: 0; 
    color: #fff; 
    font-weight: bold; 
    white-space: nowrap; 
    padding: 0.75em 1.5em; // this is the line of code that doesnt overwrite the pre-existing padding of 2px; 
} 

HTML : <td class="tableHeaderCell google-visualization-table-sorthdr"></td>

+0

사진은 imgur가 차단 된 직장 네트워크가 아닌 사람들에게 수천 단어의 가치가 있습니다. 어쨌든 설명해주십시오. 또한, "어디서?"라고 물으면 우연히 몇 마디하는 것처럼 보입니다. 두 번째 단락에. –

답변

0

당신이 할 수있는 다음을 수행하여 항상 !important을 추가하여 .google-visualization-table-table 코드를 덮어 씁니다.

.tableHeaderCell { 
    //other css styles here; 
    padding: 0.75em 1.5em !important; 
} 
1

이 때문에 CSS 규칙의 우선 순위, 난 당신이 시도해야한다고 생각 :

.google-vizualisation-table-table .tableHeaderCell{ 
    padding: 0.75em 1.5em; 
} 
관련 문제