-
Notifications
You must be signed in to change notification settings - Fork 0
/
component---src-pages-index-js-2a526a144db5ff180429.js
2 lines (2 loc) · 6.17 KB
/
component---src-pages-index-js-2a526a144db5ff180429.js
1
2
(window.webpackJsonp=window.webpackJsonp||[]).push([[3],{"2PRH":function(e,t,i){e.exports=i.p+"static/jorge-5b0b7cd4b18f46f36f44de5fa7e201b1.png"},RXBc:function(e,t,i){"use strict";i.r(t);i("91GP");var n=i("q1tI"),r=i.n(n),o=i("Bl7J"),s=i("vrFN"),c=i("qKvR");function a(){var e=Object(n.useRef)(null);return Object(n.useEffect)((function(){if(e.current){var t,i,n,r,o=e.current,s=o.getContext("2d");o.width=window.innerWidth,o.height=800;var c=new Array(o.width);for(t=0;t<o.width;t++)for(c[t]=new Array(o.height),i=0;i<o.height;i+=1)10*Math.random()<9.2?c[t][i]=!1:(n=Math.floor(100*Math.random())+150,r=(o.height-i)/o.height*.7,c[t][i]="rgba("+n+","+n+",255,"+r+")");window.requestAnimationFrame((function(){for(s.fillStyle="rgba(0,0,0,1)",s.fillRect(t,i,o.width,o.height),t=0;t<o.width;t+=1)for(i=0;i<o.height;i+=1)c[t][i]&&(s.fillStyle=c[t][i],s.fillRect(t,i,1,1))})),o.style.position="fixed",o.style.top=0,o.style.left=0}}),[]),Object(c.b)("canvas",{ref:e})}i("1gZZ");function l(e){return Object(c.b)("li",{className:"gallery-item"},Object(c.b)("div",{className:"gallery-item-border",style:{backgroundColor:e.color,borderColor:e.color}}),Object(c.b)("a",{onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,className:"gallery-item-content",href:e.href,style:{backgroundColor:e.color,backgroundImage:e.imgVisible?"url("+e.img+")":""}},Object(c.b)("div",{className:"gallery-item-label"},e.label)))}function u(e){var t=e.shipLightsOn,i=(e.shipActive,e.style);return Object(c.b)("svg",{style:i,id:"alien-ship",width:"249",height:"260",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(c.b)("path",{d:"M154.562 12c0 4.4183-14.68 1.5-34.562 1.5-19.882 0-37.4385 2.9183-37.4385-1.5 0-4.41828 16.5562-12 36.4385-12 19.882 0 35.562 7.58172 35.562 12z",fill:"#fff"}),Object(c.b)("g",{className:"ship-bottom"},Object(c.b)("path",{d:"M179 16.5c0 3.5899-26.415 7-59 7-32.5848 0-59-3.4101-59-7 0-3.5898 26.4152-4 59-4 32.585 0 59 .4102 59 4z",fill:"url(#paint0_linear)"}),Object(c.b)("path",{d:"M161.5 19c0 2.8095-16.319 5-42 5-25.6812 0-41-2.1905-41-5 0-2.8094 14.8188-2.5 40.5-2.5 25.681 0 42.5-.3094 42.5 2.5z",fill:"#DFDFDF"})),t&&Object(c.b)(r.a.Fragment,null,Object(c.b)("g",{className:"ship-light",innerstyle:"mix-blend-mode:color",filter:"url(#filter0_f)"},Object(c.b)("path",{d:"M92.9286 20h53.9344L235 246H14L92.9286 20z",fill:"url(#paint1_linear)"})),Object(c.b)("path",{className:"ship-light",d:"M92.9286 20h53.9344L235 246H14L92.9286 20z",fill:"url(#paint2_linear)",fillOpacity:".35"})),Object(c.b)("defs",null,Object(c.b)("linearGradient",{id:"paint0_linear",x1:"120",y1:"10",x2:"120",y2:"23",gradientUnits:"userSpaceOnUse"},Object(c.b)("stop",{stopColor:"#E7E7E7"}),Object(c.b)("stop",{offset:"1",stopColor:"#fff"})),Object(c.b)("linearGradient",{id:"paint1_linear",x1:"124.5",y1:"20",x2:"124.5",y2:"246",gradientUnits:"userSpaceOnUse"},Object(c.b)("stop",{stopColor:"#FAFF00",stopOpacity:".76"}),Object(c.b)("stop",{offset:"1",stopColor:"#BABE00",stopOpacity:"0"})),Object(c.b)("linearGradient",{id:"paint2_linear",x1:"124.5",y1:"20",x2:"124.5",y2:"246",gradientUnits:"userSpaceOnUse"},Object(c.b)("stop",{stopColor:"#FCFF74",stopOpacity:".76"}),Object(c.b)("stop",{offset:"1",stopColor:"#BABE00",stopOpacity:"0"})),Object(c.b)("filter",{id:"filter0_f",x:"0",y:"6",width:"249",height:"254",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},Object(c.b)("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),Object(c.b)("feBlend",{in:"SourceGraphic",in2:"BackgroundImageFix",result:"shape"}),Object(c.b)("feGaussianBlur",{stdDeviation:"7",result:"effect1_foregroundBlur"}))))}var b,f,p=i("2PRH"),h=i.n(p),O=i("TYdL"),d=i.n(O);function g(){return(g=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e}).apply(this,arguments)}var j=[{key:1,label:"Jorge GPS",href:"/jorge_gps",color:"#E18AB3",img:h.a},{key:2,label:"Sound Machine",href:"/soundmachine/",color:"#48b9ce",img:h.a}];t.default=function(){var e=Object(n.useRef)(null),t=Object(n.useState)({shipReady:null,shipActive:!1,shipLightsOn:!1,shipLeftPosition:0,currentEl:null,currentIndex:null}),i=t[0],r=t[1];return Object(n.useEffect)((function(){e.current&&(r((function(e){return Object.assign({},e,{shipReady:!1})})),setTimeout((function(){r((function(e){return Object.assign({},e,{shipReady:!0})}))}),500))}),[]),Object(n.useEffect)((function(){if(i.currentEl){clearTimeout(b),clearTimeout(f);var e=i.currentEl.getBoundingClientRect();r((function(t){return Object.assign({},t,{shipActive:!0,shipLightsOn:!1,shipLeftPosition:e.left})}))}}),[i.currentEl]),Object(n.useEffect)((function(){clearTimeout(f),i.shipActive&&(f=setTimeout((function(){r((function(e){return Object.assign({},e,{shipLightsOn:!0})}))}),2100))}),[i.shipLeftPosition,i.shipActive]),Object(n.useEffect)((function(){i.currentEl||(b=setTimeout((function(){r((function(e){return Object.assign({},e,{shipActive:!1,shipLightsOn:!1,shipLeftPosition:0})}))}),5e3))}),[i.currentEl]),Object(c.b)(o.a,null,Object(c.b)(s.a,{title:"Home"}),Object(c.b)(a,null),Object(c.b)(u,g({},i,{style:{top:e.current?e.current.offsetTop-50:null,transition:i.shipReady?"all 2s ease-in-out 0.1s":"",transform:i.shipActive&&i.shipReady?"translateX("+(i.shipLeftPosition+220)+"px)":""}})),Object(c.b)("div",{className:"centered"},Object(c.b)("div",{className:"hero"},Object(c.b)("img",{className:"hero-img",src:d.a,alt:"Coopeartiva's logo"}),Object(c.b)("h1",{className:"hero-title"},"Cooperativa.tech")),Object(c.b)("p",{className:"lead"},"We’re a group of tech professionals who gather to build cool, exciting stuff."),Object(c.b)("p",{className:"lead"},Object(c.b)("button",{className:"link",onClick:function(){return alert("QUERES FAZ TU!")}},"Perhaps you have an awesome idea to share?")),Object(c.b)("ul",{ref:e,className:"gallery"},j.map((function(e){return Object(c.b)(l,g({onMouseEnter:function(t){return r(Object.assign({},i,{currentIndex:e.key,currentEl:t.target}))},onMouseLeave:function(){return r(Object.assign({},i,{currentEl:null}))}},e,{imgVisible:i.shipLightsOn&&i.currentIndex===e.key}))})))))}},TYdL:function(e,t,i){e.exports=i.p+"static/logo-0c8a7ad4a7e6f63ec7670656f9ef7cd8.svg"}}]);
//# sourceMappingURL=component---src-pages-index-js-2a526a144db5ff180429.js.map