검색결과 리스트
글
///// JavaScript (자바스크립트)
///// CSS (씨에스에스)
- transition
body{
transition: width 2s, height 2s, background-color 2s, transform 2s;
}
CSS 트랜지션 사용하기
https://developer.mozilla.org/ko/docs/Web/CSS/CSS_Transitions/Using_CSS_transitions
- transition 적용이 안될 때
- window.getComputedStyle(el)
//객체 생성
var el = doument.createElement('div');
el.style.background = 'white';
el.style.transition = 'background-color 2s';
//객체 붙이면서 transition 효과 적용하기
document.body.appendChild(el);
window.getComputedStyle(el).background;
el.style.background = 'black';
- for IE
if (!window.getComputedStyle) {
window.getComputedStyle = function(element) {
return element.currentStyle;
}
}
Trigger CSS transition on appended element
http://stackoverflow.com/questions/24148403/trigger-css-transition-on-appended-element
JavaScript Window getComputedStyle() Method
http://www.w3schools.com/jsref/jsref_getcomputedstyle.asp
IE 하위 버전을 위한 getComputedStyle()
http://blog.naver.com/hwpyky/140162681852
///// Trigger Parent Frame
- JQuery
$('#x',parent.document.body).
///// getBoundingClientRect()
- Element.getBoundingClientRect()
- FrameElement.getBoundingClientRect()
///// 프레임(frame)까지 고려해서 해당 객체의 위치 얻기
How to get the position of an iframe relative to the top window's viewport?
http://stackoverflow.com/questions/9675445/how-to-get-the-position-of-an-iframe-relative-to-the-top-windows-viewport
///// 해당 요소의 document 얻기
var doc = element.ownerDocument;
var win = doc.defaultView || doc.parentWindow;
Get reference of window object from a dom element
http://stackoverflow.com/questions/16010204/get-reference-of-window-object-from-a-dom-element
'LANGUAGE > HTML & CSS & JS' 카테고리의 다른 글
[JavaScript] Context Path (0) | 2017.01.03 |
---|---|
[JavaScript] 현재 가장 높은 수치의 z-index는? (0) | 2016.12.03 |
[Internet Explorer Test] IE 테스트하기 (2) | 2016.08.21 |
[JavaScript] control other iframe (iframe 제어하기) (0) | 2016.08.18 |
[Javascript] Clipboard (클립보드) (1) | 2016.07.05 |