{"version":3,"file":"GradientMask.CTF2_ExY.mjs","names":[],"sources":["https:/framerusercontent.com/modules/gEEwP5rT1TsKo76P2PKT/jSZNFFoNrIOTzlr7BFek/GradientMask.js"],"sourcesContent":["// Welcome to Code in Framer\n// Get Started: https://www.framer.com/developers\nimport{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{motion}from\"framer-motion\";/**\n * These annotations control how your component sizes\n * Learn more: https://www.framer.com/developers/#code-components-auto-sizing\n *\n * @framerSupportedLayoutWidth any-prefer-fixed\n * @framerSupportedLayoutHeight any-prefer-fixed\n *\n * @framerIntrinsicWidth 400\n * @framerIntrinsicHeight 400\n */export default function GradientMask(props){const{style,radius,image,isMixed,topLeft,topRight,bottomRight,bottomLeft,children,type,startMask,endMask,transition,animate}=props;const borderRadius=isMixed?`${topLeft}px ${topRight}px ${bottomRight}px ${bottomLeft}px`:`${radius}px`;return /*#__PURE__*/_jsxs(motion.div,{style:{...style,display:\"grid\",alignItems:\"center\",justifyContent:\"center\",overflow:\"visible\",borderRadius,WebkitMaskImage:`linear-gradient(${startMask.direction}deg, rgba(0,0,0,${startMask.startOpacity}) ${startMask.startPosition}%, rgba(0,0,0,${startMask.endOpacity}) ${startMask.endPosition}%)`},transition:transition,animate:{WebkitMaskImage:animate?`linear-gradient(${endMask.direction}deg, rgba(0,0,0,${endMask.startOpacity}) ${endMask.startPosition}%, rgba(0,0,0,${endMask.endOpacity}) ${endMask.endPosition}%)`:`linear-gradient(${startMask.direction}deg, rgba(0,0,0,${startMask.startOpacity}) ${startMask.startPosition}%, rgba(0,0,0,${startMask.endOpacity}) ${startMask.endPosition}%)`},children:[type===\"component\"&&children,type===\"image\"&&/*#__PURE__*/_jsx(\"img\",{style:{width:\"100%\",height:\"100%\",objectFit:\"cover\"},src:(image===null||image===void 0?void 0:image.src)||\"https://images.unsplash.com/photo-1682687218147-9806132dc697?q=80&w=800&auto=format&fit=crop&ixlib=rb-4.0.3&ixid=M3wxMjA3fDF8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D\",srcSet:image===null||image===void 0?void 0:image.srcSet,alt:image===null||image===void 0?void 0:image.alt})]});}addPropertyControls(GradientMask,{animate:{type:ControlType.Boolean,defaultValue:false},startMask:{type:ControlType.Object,controls:{direction:{type:ControlType.Number,title:\"Direction\",defaultValue:180,min:0,max:360,unit:\"deg\",step:1},startPosition:{type:ControlType.Number,title:\"Start Position\",defaultValue:0,min:0,max:100,unit:\"%\",step:1},startOpacity:{type:ControlType.Number,title:\"Start Opacity\",defaultValue:1,min:0,max:1,step:.1},endPosition:{type:ControlType.Number,title:\"End Position\",defaultValue:100,min:0,max:100,unit:\"%\",step:1},endOpacity:{type:ControlType.Number,title:\"End Opacity\",defaultValue:0,min:0,max:1,step:.1}}},endMask:{type:ControlType.Object,hidden(props){return props.animate===false;},controls:{direction:{type:ControlType.Number,title:\"Direction\",defaultValue:0,min:0,max:360,unit:\"deg\",step:1},startPosition:{type:ControlType.Number,title:\"Start Position\",defaultValue:0,min:0,max:100,unit:\"%\",step:1},startOpacity:{type:ControlType.Number,title:\"Start Opacity\",defaultValue:1,min:0,max:1,step:.1},endPosition:{type:ControlType.Number,title:\"End Position\",defaultValue:100,min:0,max:100,unit:\"%\",step:1},endOpacity:{type:ControlType.Number,title:\"End Opacity\",defaultValue:0,min:0,max:1,step:.1}}},transition:{type:ControlType.Transition,hidden(props){return props.animate===false;}},radius:{type:ControlType.FusedNumber,title:\"Radius\",defaultValue:0,toggleKey:\"isMixed\",toggleTitles:[\"All\",\"Individual\"],valueKeys:[\"topLeft\",\"topRight\",\"bottomRight\",\"bottomLeft\"],valueLabels:[\"TL\",\"TR\",\"BR\",\"BL\"],min:0},type:{type:ControlType.Enum,options:[\"image\",\"component\"],optionTitles:[\"Image\",\"Component\"],defaultValue:\"image\",displaySegmentedControl:true,segmentedControlDirection:\"vertical\"},children:{type:ControlType.ComponentInstance,hidden(props){return props.type===\"image\";}},image:{type:ControlType.ResponsiveImage,hidden(props){return props.type===\"component\";}}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"GradientMask\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutWidth\":\"any-prefer-fixed\",\"framerContractVersion\":\"1\",\"framerIntrinsicWidth\":\"400\",\"framerSupportedLayoutHeight\":\"any-prefer-fixed\",\"framerIntrinsicHeight\":\"400\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./GradientMask.map"],"mappings":"oNAWG,SAAwB,EAAa,EAAM,CAAC,GAAK,CAAC,QAAM,SAAO,QAAM,UAAQ,UAAQ,WAAS,cAAY,aAAW,WAAS,OAAK,YAAU,UAAQ,aAAW,WAAS,EAAY,EAAa,EAAQ,GAAG,EAAQ,KAAK,EAAS,KAAK,EAAY,KAAK,EAAW,IAAI,GAAG,EAAO,IAAI,OAAoB,EAAM,EAAO,IAAI,CAAC,MAAM,CAAC,GAAG,EAAM,QAAQ,OAAO,WAAW,SAAS,eAAe,SAAS,SAAS,UAAU,eAAa,gBAAgB,mBAAmB,EAAU,UAAU,kBAAkB,EAAU,aAAa,IAAI,EAAU,cAAc,gBAAgB,EAAU,WAAW,IAAI,EAAU,YAAY,IAAI,CAAY,aAAW,QAAQ,CAAC,gBAAgB,EAAQ,mBAAmB,EAAQ,UAAU,kBAAkB,EAAQ,aAAa,IAAI,EAAQ,cAAc,gBAAgB,EAAQ,WAAW,IAAI,EAAQ,YAAY,IAAI,mBAAmB,EAAU,UAAU,kBAAkB,EAAU,aAAa,IAAI,EAAU,cAAc,gBAAgB,EAAU,WAAW,IAAI,EAAU,YAAY,IAAI,CAAC,SAAS,CAAC,IAAO,aAAa,EAAS,IAAO,SAAsB,EAAK,MAAM,CAAC,MAAM,CAAC,MAAM,OAAO,OAAO,OAAO,UAAU,QAAQ,CAAC,IAAK,GAA0C,KAAM,wKAAwK,OAAO,GAA0C,OAAO,IAAI,GAA0C,IAAI,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