{"version":3,"file":"GridOverlay.Cpu0eHcF.mjs","names":[],"sources":["https:/framerusercontent.com/modules/N61TCsdtarknrqPqJOZp/y0U1gh2gTdogBVDZaY9m/GridOverlay.js"],"sourcesContent":["// Grid overlay component for spacing and alignment, similar to Figma's layout grid\n// Allows customization of grid size, color, and opacity\n// Use this component to maintain consistent spacing in your designs\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";/**\n * @framerSupportedLayoutWidth fixed\n * @framerSupportedLayoutHeight fixed\n */export default function GridOverlay(props){const{numberOfColumns=12,gridColor=\"#0099FF\",gridOpacity=.3,showGrid=true,lineThickness=1,offsetX=0,paddingMargins=0}=props;if(!showGrid)return null;// Calculate grid size based on number of columns and viewport width\nconst gridSize=`calc((100% - ${paddingMargins*2}px) / ${numberOfColumns})`;const getGridPattern=()=>{return`\n<svg width=\"100\" height=\"100\" xmlns=\"http://www.w3.org/2000/svg\">\n<line x1=\"0\" y1=\"0\" x2=\"0\" y2=\"100\" stroke=\"${gridColor}\" stroke-width=\"${lineThickness}\"/>\n</svg>\n`;};const gridPattern=getGridPattern();const encodedPattern=encodeURIComponent(gridPattern);return /*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",top:0,left:0,width:\"100%\",height:\"100%\",pointerEvents:\"none\",backgroundImage:`url(\"data:image/svg+xml,${encodedPattern}\")`,backgroundSize:`${gridSize} 100%`,backgroundPosition:`${offsetX+paddingMargins}px 0px`,backgroundRepeat:\"repeat\",opacity:gridOpacity,zIndex:9999}});}addPropertyControls(GridOverlay,{showGrid:{type:ControlType.Boolean,title:\"Show Grid\",defaultValue:true,enabledTitle:\"Visible\",disabledTitle:\"Hidden\"},numberOfColumns:{type:ControlType.Number,title:\"Columns\",defaultValue:12,min:1,max:24,step:1},lineThickness:{type:ControlType.Number,title:\"Thickness\",defaultValue:1,min:.5,max:5,step:.5,unit:\"px\"},gridColor:{type:ControlType.Color,title:\"Grid Color\",defaultValue:\"#FF0000\"},gridOpacity:{type:ControlType.Number,title:\"Opacity\",defaultValue:.3,min:0,max:1,step:.05},offsetX:{type:ControlType.Number,title:\"Offset X\",defaultValue:0,min:-100,max:100,step:1,unit:\"px\"},paddingMargins:{type:ControlType.Number,title:\"Padding/Margins\",defaultValue:0,min:0,max:500,step:1,unit:\"px\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"GridOverlay\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"fixed\",\"framerSupportedLayoutHeight\":\"fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./GridOverlay.map"],"mappings":"4JAMG,SAAwB,EAAY,EAAM,CAAC,GAAK,CAAC,kBAAgB,GAAG,YAAU,UAAU,cAAY,GAAG,WAAS,GAAK,gBAAc,EAAE,UAAQ,EAAE,iBAAe,GAAG,EAAM,GAAG,CAAC,EAAS,OAAO,KAC9L,IAAM,EAAS,gBAAgB,EAAe,EAAE,QAAQ,EAAgB,GAI9D,EAJiG;;8CAE7D,EAAU,kBAAkB,EAAc;;EAEI,OAAoB,EAAK,MAAM,CAAC,MAAM,CAAC,SAAS,WAAW,IAAI,EAAE,KAAK,EAAE,MAAM,OAAO,OAAO,OAAO,cAAc,OAAO,gBAAgB,2BAAxK,mBAAmB,CAA6L,EAAE,IAAI,eAAe,GAAG,EAAS,OAAO,mBAAmB,GAAG,EAAQ,EAAe,QAAQ,iBAAiB,SAAS,QAAQ,EAAY,OAAO,IAAI,CAAC,CAAC,CAAE,iBAR5X,IAAoD,EAQyU,EAAoB,EAAY,CAAC,SAAS,CAAC,KAAK,EAAY,QAAQ,MAAM,YAAY,aAAa,GAAK,aAAa,UAAU,cAAc,QAAQ,EAAE,gBAAgB,CAAC,KAAK,EAAY,OAAO,MAAM,UAAU,aAAa,GAAG,IAAI,EAAE,IAAI,GAAG,KAAK,CAAC,EAAE,cAAc,CAAC,KAAK,EAAY,O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