CSS3 회전 HTML5/CSS3 2016. 7. 29. 14:43
-webkit-transform: rotate(45deg);
-moz-transform: rotate(45deg);
transform: rotate(45deg);


화살표 블릿에 활용

width: 9px;
height: 9px;
margin-top: -6px;
border-top: 2px solid #bebebe;
border-right: 2px solid #bebebe;
-webkit-transform: rotate(45deg);
-moz-transform: rotate(45deg);
transform: rotate(45deg);

'HTML5/CSS3' 카테고리의 다른 글

display:flex  (0) 2016.03.11
select box 디자인 화살표적용 css  (1) 2015.11.12
버튼 width 50%  (0) 2015.06.25
table 없이 table cell 코딩하기  (0) 2015.06.25
말줄임 ellipsis  (0) 2015.06.25
display:flex HTML5/CSS3 2016. 3. 11. 15:21

.cont_wrap {display:flex; display:-webkit-flex; display:-webkit-box; display:-ms-flexbox;}

.cont_wrap .input {display:block; flex:1; -webkit-flex:1; -webkit-box-flex:1; -ms-flex:1;}

.cont_wrap .txt {width:50px;} .cont_wrap .btn {} .cont_wrap .tel {display:block; flex:1; -webkit-flex:1; -webkit-box-flex:1; -ms-flex:1;} .cont_wrap .dash {width:10px;}

<div class="cont_wrap">     <span class="input"><input type="text"></span>     <span class="txt">원</span>     <a href="#" class="btn">쿠폰적용</a> </div>

<div class="cont_wrap">     <input type="text" class="tel">     <span class="dash">-</span>     <input type="text" class="tel">     <span class="dash">-</span><     <input type="text" class="tel"> </div>


화면 사이즈에 따라 input 유동적으로 사이즈 변경된다.


ie 11 이상부터 지원되며,

webkit 추가 해야함.

익스에서 사용시 -ms- 추가하면 ie 10부터 적용됨.


* flex:1 넣은 요소에 display:block; 을 꼭 넣어줘야함.(안드로이드 하위버전을 위해...(화웨이))





'HTML5/CSS3' 카테고리의 다른 글

CSS3 회전  (0) 2016.07.29
select box 디자인 화살표적용 css  (1) 2015.11.12
버튼 width 50%  (0) 2015.06.25
table 없이 table cell 코딩하기  (0) 2015.06.25
말줄임 ellipsis  (0) 2015.06.25
select {
  -webkit-appearance: none;  /* 네이티브 외형 감추기 */
  -moz-appearance: none;
  appearance: none;
  background: url(이미지 경로) no-repeat 95% 50%;  /* 화살표 모양의 이미지 */ 
}

/* IE 10, 11의 네이티브 화살표 숨기기 */
select::-ms-expand { 
  display: none;
}

'HTML5/CSS3' 카테고리의 다른 글

CSS3 회전  (0) 2016.07.29
display:flex  (0) 2016.03.11
버튼 width 50%  (0) 2015.06.25
table 없이 table cell 코딩하기  (0) 2015.06.25
말줄임 ellipsis  (0) 2015.06.25
버튼 width 50% HTML5/CSS3 2015. 6. 25. 13:47
HTML
<div class="btntype">
	<a href="#" class="area" onclick="return false;">취소</a>
	<var class="bar"></var>
	<a href="#" class="area" onclick="return false;">확인</a>
</div>


CSS
.btntype {display: table;}
.btntype .area {display: table-cell; width:50%;}
.btntype .bar {display:block; width:4px;}

'HTML5/CSS3' 카테고리의 다른 글

display:flex  (0) 2016.03.11
select box 디자인 화살표적용 css  (1) 2015.11.12
table 없이 table cell 코딩하기  (0) 2015.06.25
말줄임 ellipsis  (0) 2015.06.25
기기별 디바이스 사이즈  (0) 2013.02.04
HTML
<div class="pdOpt">
	<span class="item">
		<span class="label"><span>브라운 라쿤 트리밍 퀄티드 롱</span></span>
		<span class="color"></span>
		<span class="size">FREE</span>
	</span>
	<span class="item">
		<span class="label"><span>상의</span></span>
		<span class="color"></span>
		<span class="size">45F</span>
	</span>
</div>


CSS
.pdOpt {display:table; width:auto; margin-top:8px;}
.pdOpt .item {display:table-row;}
.pdOpt .item > span {display: table-cell;}


'HTML5/CSS3' 카테고리의 다른 글

select box 디자인 화살표적용 css  (1) 2015.11.12
버튼 width 50%  (0) 2015.06.25
말줄임 ellipsis  (0) 2015.06.25
기기별 디바이스 사이즈  (0) 2013.02.04
HTML5 시작전 챙겨야할 것들  (0) 2012.09.13
말줄임 ellipsis HTML5/CSS3 2015. 6. 25. 13:24
한줄 글자수 제한
.text {
    width:100px; /* %도 가능함 */
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
}


- Block레벨 테그에서만 적용이 됩니다.
- overflow:hidden : 넓이가 70px를 넒어서는 내용에 대해서는 보이지 않게 처리함
- text-overflow:ellipsis : 글자가 넓이 70px를 넘을 경우 생략부호를 표시함
- white-space:nowrap : 공백문자가 있는 경우 줄바꿈하지 않고 한줄로 나오게 처리함 (\A로 줄바꿈가능)

- 테이블에 % 말줄임 사용시 테이블 틀어지는 문제는 table에 table-layout:fixed; 추가 해준다.


여러줄 글자수 제한


.text {
      display: -webkit-box;
      display: -ms-flexbox;
      display: box;
      margin-top:1px;
      max-height:80px;
      overflow:hidden;
      vertical-align:top;
      text-overflow: ellipsis;
      word-break:break-all;
      -webkit-box-orient:vertical;
      -webkit-line-clamp:3
  }


'HTML5/CSS3' 카테고리의 다른 글

select box 디자인 화살표적용 css  (1) 2015.11.12
버튼 width 50%  (0) 2015.06.25
table 없이 table cell 코딩하기  (0) 2015.06.25
기기별 디바이스 사이즈  (0) 2013.02.04
HTML5 시작전 챙겨야할 것들  (0) 2012.09.13

1) 구형 스마트폰
갤s 480*800
갤2 480*800
아이폰3 320*480

2) 최근 스마트폰
갤놋1 800*1280
갤놋2 720*1280
갤3 720*1280
옵뷰1 768*1024
옵뷰2 768*1024
옵g 768*1280
베가R3 720*1280
아이폰4 640*960
아이폰5 640*1136

3) 태블릿
아이패드 시리즈 768*1024
갤탭7 600*1024
갤탭7.7 800*1280
갤탭10.1 800*1280

'HTML5/CSS3' 카테고리의 다른 글

select box 디자인 화살표적용 css  (1) 2015.11.12
버튼 width 50%  (0) 2015.06.25
table 없이 table cell 코딩하기  (0) 2015.06.25
말줄임 ellipsis  (0) 2015.06.25
HTML5 시작전 챙겨야할 것들  (0) 2012.09.13

HTML5에서 새로 생긴 엘리먼트들은 IE에서 인식을 못하는데,
이러한 요소를 인식시키기 위해 아래의 javascript와 CSS를 넣어줘야한다.

head에 넣을 소스

<!--[if lt IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<script src="respond.min.js"></script> <!-- IE6~8 미디어쿼리 해석 시켜줌 -->

respond.min.js 내려받기: respond.min.js

추가로 CSS에서 새로 추가된 요소를 block level 요소로 인식될 수 있도록 선언해 주고,
각 디바이스별 미디어쿼리 넣는다.

CSS 소스

rticle, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section {
   display:block;
}

/* 데스크탑용 CSS는 이곳에 작성 */

/* 미디어쿼리  : 태블릿용 1024px */
@media only screen and (max-width: 1024px) {
	body .row {width: 90%;}
}
/* 미디어쿼리 : 모바일용 767px */
@media only screen and (max-width: 767px){
    body {font-size: 16px;}
}

참고 사이트: http://helloworld.naver.com/helloworld/81480

'HTML5/CSS3' 카테고리의 다른 글

select box 디자인 화살표적용 css  (1) 2015.11.12
버튼 width 50%  (0) 2015.06.25
table 없이 table cell 코딩하기  (0) 2015.06.25
말줄임 ellipsis  (0) 2015.06.25
기기별 디바이스 사이즈  (0) 2013.02.04