DOM

settings_applicationsEventTarget  >   settings_applicationsNode  >   settings_applicationsElement  >   settings_applicationsHTMLElement  >   settings_applications[[Prototype]]

DOM

Editing
  • account_tree
  • bug_report

ElementoffsetParent

가장 가까운 상대적 기준 상위 요소를 참조한다.

설명

요소의 상위 요소를 탐색하면서 위치에 대한 상대적 기준의 대상이 되는 요소를 찾는다. 상대적인 대상이 되는 상위 요소의 조건은 position 속성이 static이 아닌 경우이다. 만약에 존재하지 않는다면 body 요소를 참조한다.

다음과 같은 경우는 null 값을 갖는다.

  • 요소 또는 상위 요소의 display 속성 값이 none으로 설정된 경우
  • 요소의 position 속성이 fixed 인 경우
  • 요소가 body이거나 html인 경우

구문

형식
htmlElement.offsetParent
상대적 기준인 상위 요소를 참조한다.

속성 명세

명세
분류설명
writableno

버전 명세

지원 웹브라우저