유튜브 댓글 입력 스타일
https://jsfiddle.net/minsupkr/9w6L5bua/ jQuery
https://jsfiddle.net/minsupkr/9w6L5bua/1/ CSS
html
[code]<div>
<label for="inp">댓글을 입력하세요</label>
<input type="text" id="inp">
</div>[/code]
css
[code]div {position:relative}
div:after {z-index:999;position:absolute;bottom:0;left:50%;width:0;height:0;background:#333;content:'';
-webkit-transition:all 0.2s ease-out;
transition:all 0.2s ease-out
}
.on:after {bottom:-1px;left:0;width:100%;height:2px}
div label {position:absolute;top:0;left:0}
.on label {color:#ccc}
input {width:100%;border:0;border-bottom:1px solid #ccc;background:transparent;outline:0;box-sizing:border-box;-webkit-box-sizing:border-box;-moz-box-sizing:border-box}[/code]
javascript
[code]$(function(){
$("input").on("focus", function(){
$(this).closest("div").addClass("on");
});
$("input").on("blur", function(){
$(this).closest("div").removeClass("on");
});
});[/code]
유튜브 보다가 댓글란이 재밌어 보여서 빠르고 조잡하게 한번 짜봤습니다.
좀 다듬으면 쓸만하지 않을까요... ㅎㅎㅎ;;
팁자료실은 신택스하이라이트가 안 먹는군요.
@리자 @thisgun 멘션도 안 되는군요. ㅎㅎㅎ
게시글 목록
| 번호 | 제목 |
|---|---|
| 3056 | |
| 3055 | |
| 3054 | |
| 3051 | |
| 3050 | |
| 3049 | |
| 3046 | |
| 3045 | |
| 3044 |
HTML
글자 간격 Letter Spacing
|
| 3043 |
CSS
text-indent
|
| 3042 |
CSS
text-transform
|
| 3041 |
CSS
text-decoration
|
| 3040 |
CSS
Text Alignment
|
| 3039 |
CSS
Text Color
|
| 3038 | |
| 3034 |
CSS
Outline Width
|
| 3033 |
CSS
Outline Color
|
| 3032 |
CSS
CSS Outline
|
| 3027 |
CSS
CSS Box Model
|
| 3026 | |
| 3025 | |
| 3024 |
CSS
CSS Padding
|
| 3023 |
CSS
CSS Margins
|
| 3022 | |
| 3021 | |
| 3020 | |
| 3019 |
HTML
HTML <video> 요소
1
|
| 3018 |
HTML
html google map
|
| 3017 |
HTML
SVG와 캔버스의 차이점
|
| 3016 |
HTML
SVG Logo
|
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기