수직그래프

2015. 7. 14. 16:29CSS

  • SUN0%
  • MON20%
  • TUE30%
  • WED40%
  • THU50%
  • FRI60%
  • SAT100%

 

Style

/* UI Object */
.v_graph{padding:20px 0}
.v_graph ul{height:200px;margin:0;padding:0;border:1px solid #ddd;border-top:0;border-right:0;font-size:11px;font-family:Tahoma, Geneva, sans-serif;list-style:none}
.v_graph ul:after{display:block;clear:both;content:""}
.v_graph li{display:inline;float:left;position:relative;width:8%;height:100%;margin:0 3%;text-align:center;white-space:nowrap}
.v_graph .g_term{display:inline-block;position:relative;width:100%;height:20px;margin:0 -100% -20px 0;padding:200px 0 0 0;font-weight:bold;color:#767676;line-height:20px;vertical-align:bottom}
.v_graph .g_bar{display:inline-block;position:relative;width:100%;margin:-1px 0 0 0;border:1px solid #ccc;border-bottom:0;background:#e9e9e9;vertical-align:bottom}
.v_graph .g_bar span{position:absolute;top:-20px;left:0;width:100%;color:#767676}
/* //UI Object */

 

HTML

<div class="v_graph">
 <ul>
 <li><span class="g_term">SUN</span><span class="g_bar" style="height:0%"><span>0%</span></span></li>
 <li><span class="g_term">MON</span><span class="g_bar" style="height:20%"><span>20%</span></span></li>
 <li><span class="g_term">TUE</span><span class="g_bar" style="height:30%"><span>30%</span></span></li>
 <li><span class="g_term">WED</span><span class="g_bar" style="height:40%"><span>40%</span></span></li>
 <li><span class="g_term">THU</span><span class="g_bar" style="height:50%"><span>50%</span></span></li>
 <li><span class="g_term">FRI</span><span class="g_bar" style="height:60%"><span>60%</span></span></li>
 <li><span class="g_term">SAT</span><span class="g_bar" style="height:100%"><span>100%</span></span></li>
 </ul>
</div>

 

출처 : http://nuli.navercorp.com/data/ui_library/src/pattern/etc/jcm//v_graph.html

'CSS' 카테고리의 다른 글

수평 그래프  (0) 2015.07.14
가변폭 3단 컬럼  (0) 2015.03.22
가변폭 2단 컬럼(aside)  (0) 2015.03.22
가변폭 2단 컬럼(snb)  (0) 2015.03.22
IE에서 CSS 버전별 적용  (0) 2014.03.20