"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[60036],{3905:(e,t,n)=>{n.d(t,{Zo:()=>u,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 i=r.createContext({}),c=function(e){var t=r.useContext(i),n=t;return e&&(n="function"==typeof e?e(t):a(a({},t),e)),n},u=function(e){var t=c(e.components);return r.createElement(i.Provider,{value:t},e.children)},s={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,i=e.parentName,u=p(e,["components","mdxType","originalType","parentName"]),m=c(n),d=o,f=m["".concat(i,".").concat(d)]||m[d]||s[d]||l;return n?r.createElement(f,a(a({ref:t},u),{},{components:n})):r.createElement(f,a({ref:t},u))}));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 p={};for(var i in t)hasOwnProperty.call(t,i)&&(p[i]=t[i]);p.originalType=e,p.mdxType="string"==typeof e?e:o,a[1]=p;for(var c=2;c{n.r(t),n.d(t,{assets:()=>c,contentTitle:()=>p,default:()=>m,frontMatter:()=>a,metadata:()=>i,toc:()=>u});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"},p="ElementHandle.boxModel() method",i={unversionedId:"api/puppeteer.elementhandle.boxmodel",id:"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/../docs/api/puppeteer.elementhandle.boxmodel.md",sourceDirName:"api",slug:"/api/puppeteer.elementhandle.boxmodel",permalink:"/next/api/puppeteer.elementhandle.boxmodel",draft:!1,tags:[],version:"current",frontMatter:{sidebar_label:"ElementHandle.boxModel"},sidebar:"sidebar",previous:{title:"ElementHandle.boundingBox",permalink:"/next/api/puppeteer.elementhandle.boundingbox"},next:{title:"ElementHandle.click",permalink:"/next/api/puppeteer.elementhandle.click"}},c={},u=[{value:"Remarks",id:"remarks",level:2}],s={toc:u};function m(e){var{components:t}=e,n=l(e,["components"]);return(0,r.kt)("wrapper",o({},s,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)("p",null,(0,r.kt)("strong",{parentName:"p"},"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:"/next/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}}]);