"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[52689],{3905:(e,t,n)=>{n.d(t,{Zo:()=>s,kt:()=>d});var r=n(67294);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var p=r.createContext({}),c=function(e){var t=r.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):a(a({},t),e)),n},s=function(e){var t=c(e.components);return r.createElement(p.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,l=e.originalType,p=e.parentName,s=i(e,["components","mdxType","originalType","parentName"]),m=c(n),d=o,f=m["".concat(p,".").concat(d)]||m[d]||u[d]||l;return n?r.createElement(f,a(a({ref:t},s),{},{components:n})):r.createElement(f,a({ref:t},s))}));function d(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var l=n.length,a=new Array(l);a[0]=m;var i={};for(var p in t)hasOwnProperty.call(t,p)&&(i[p]=t[p]);i.originalType=e,i.mdxType="string"==typeof e?e:o,a[1]=i;for(var c=2;c{n.r(t),n.d(t,{assets:()=>c,contentTitle:()=>i,default:()=>m,frontMatter:()=>a,metadata:()=>p,toc:()=>s});n(67294);var r=n(3905);function o(){return o=Object.assign||function(e){for(var t=1;t=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}const a={sidebar_label:"ElementHandle.boxModel"},i="ElementHandle.boxModel() method",p={unversionedId:"api/puppeteer.elementhandle.boxmodel",id:"version-21.1.1/api/puppeteer.elementhandle.boxmodel",title:"ElementHandle.boxModel() method",description:"This method returns boxes of the element, or null if the element is not visible.",source:"@site/versioned_docs/version-21.1.1/api/puppeteer.elementhandle.boxmodel.md",sourceDirName:"api",slug:"/api/puppeteer.elementhandle.boxmodel",permalink:"/api/puppeteer.elementhandle.boxmodel",draft:!1,tags:[],version:"21.1.1",frontMatter:{sidebar_label:"ElementHandle.boxModel"},sidebar:"api",previous:{title:"ElementHandle.boundingBox",permalink:"/api/puppeteer.elementhandle.boundingbox"},next:{title:"ElementHandle.click",permalink:"/api/puppeteer.elementhandle.click"}},c={},s=[{value:"Signature:",id:"signature",level:4},{value:"Remarks",id:"remarks",level:2}],u={toc:s};function m(e){var{components:t}=e,n=l(e,["components"]);return(0,r.kt)("wrapper",o({},u,n,{components:t,mdxType:"MDXLayout"}),(0,r.kt)("h1",o({},{id:"elementhandleboxmodel-method"}),"ElementHandle.boxModel() method"),(0,r.kt)("p",null,"This method returns boxes of the element, or ",(0,r.kt)("inlineCode",{parentName:"p"},"null")," if the element is not visible."),(0,r.kt)("h4",o({},{id:"signature"}),"Signature:"),(0,r.kt)("pre",null,(0,r.kt)("code",o({parentName:"pre"},{className:"language-typescript"}),"class ElementHandle {\n boxModel(): Promise;\n}\n")),(0,r.kt)("p",null,(0,r.kt)("strong",{parentName:"p"},"Returns:")),(0,r.kt)("p",null,"Promise","<",(0,r.kt)("a",o({parentName:"p"},{href:"/api/puppeteer.boxmodel"}),"BoxModel")," ","|"," null",">"),(0,r.kt)("h2",o({},{id:"remarks"}),"Remarks"),(0,r.kt)("p",null,"Boxes are represented as an array of points; Each Point is an object ",(0,r.kt)("inlineCode",{parentName:"p"},"{x, y}"),". Box points are sorted clock-wise."))}m.isMDXComponent=!0}}]);