(window.webpackJsonp=window.webpackJsonp||[]).push([[0],{149:function(e,t,a){e.exports=a.p+"static/media/crafting.cd9d349b.jpg"},343:function(e,t,a){e.exports=a.p+"static/media/powered-by-stripe.552f9814.svg"},348:function(e,t,a){e.exports=a.p+"static/media/arduino-uno.48c33893.jpg"},350:function(e,t,a){e.exports=a.p+"static/media/robotics.6b7226af.jpg"},351:function(e,t,a){e.exports=a.p+"static/media/UseYourFavoriteSoftware.c9fb2685.svg"},352:function(e,t,a){e.exports=a.p+"static/media/sparks.21d4d115.jpg"},359:function(e,t,a){e.exports=a(915)},367:function(e,t,a){},369:function(e,t,a){},373:function(e,t,a){},732:function(e,t,a){},743:function(e,t,a){},786:function(e,t,a){},791:function(e,t,a){},793:function(e,t,a){},795:function(e,t,a){},814:function(e,t,a){},817:function(e,t,a){},819:function(e,t,a){},821:function(e,t,a){},823:function(e,t,a){},908:function(e,t,a){},910:function(e,t,a){},915:function(e,t,a){"use strict";a.r(t);var n=a(0),r=a.n(n),i=a(44),o=a.n(i),s=(a(367),a(222)),l=a(3),c=a(4),u=a(6),m=a(5),d=a(7),h=(a(369),a(328)),p=a.n(h),f=a(920),b=function(e){function t(){return Object(l.a)(this,t),Object(u.a)(this,Object(m.a)(t).apply(this,arguments))}return Object(d.a)(t,e),Object(c.a)(t,[{key:"componentDidUpdate",value:function(e){this.props.location!==e.location&&window.scrollTo(0,0)}},{key:"render",value:function(){return this.props.children}}]),t}(n.Component),y=Object(f.a)(b),E=a(337),g=a.n(E),v=a(338),w=a.n(v),O=a(32),C=a.n(O),k=a(916),S=(a(373),function(e){function t(){return Object(l.a)(this,t),Object(u.a)(this,Object(m.a)(t).apply(this,arguments))}return Object(d.a)(t,e),Object(c.a)(t,[{key:"render",value:function(){return r.a.createElement("div",{className:"title-container"},r.a.createElement(k.a,{to:"/",className:"penumbra"},"PENUMBRA"),r.a.createElement(k.a,{to:"/",className:"cuts"},"cuts"))}}]),t}(n.Component)),j=a(30),T=a(34),P=a(63),I=a(332),A=a(333),N=a(334),L=a.n(N),R="http://localhost:53312/api/",M="pk_test_yP5ftDPg2WKGohPTSG81rMVr",F=a(219);function x(e){return parseFloat(Math.round(100*e)/100).toFixed(2)}var D="REQUEST_QUOTE";var U="RECEIVE_QUOTE";var W=L()(function(e,t){return fetch(R+"quotes",{method:"POST",headers:{"Content-Type":"application/json"},mode:"cors",cache:"no-cache",body:JSON.stringify({fileSubmissionId:e,stockMaterialId:t})}).then(function(e){return e.json()})},{promise:!0,maxAge:6e4});function q(e,t){return function(a){if(""===e||""===t)return Promise.resolve();a({type:D}),W(e,t).then(function(e){return a({type:U,quote:e})}).catch(console.error)}}var V="REQUEST_FILE_SUBMISSION";function Y(){return{type:V}}var _="RECEIVE_FILE_SUBMISSION";function H(e){return Object(j.a)({type:_},e)}function z(e){return function(t){return Promise.all([function(e){return new Promise(function(t,a){var n=new FileReader;n.onload=function(){var a=n.result.replace("data:;","data:".concat(e.extension,";"));t(a)},n.onerror=a,n.readAsDataURL(e)})}(e),function(e){return new Promise(function(t,a){var n=new FileReader;n.onload=function(){var e=n.result,a=Object(F.parseString)(e),r=Object(F.toSVG)(a).replace('stroke-width="0.1%"','stroke-width="1%"');t(r)},n.onerror=a,n.readAsBinaryString(e)})}(e)]).then(function(e){return t(Y()),a=e[0],n=e[1],new Promise(function(e){fetch(R+"files",{method:"POST",headers:{"Content-Type":"application/json;"},mode:"cors",cache:"no-cache",body:JSON.stringify({fileData:a,filePreview:n})}).then(function(e){return e.json()}).then(function(t){e({id:t.id,width:x(t.widthIn),height:x(t.heightIn),cutLength:x(t.cutLengthIn),preview:t.previewImage})})});var a,n}).then(function(e){return t(H(e))}).catch(console.error)}}function B(){return function(e){return e(Y()),fetch(R+"files/",{method:"GET",headers:{"Content-Type":"application/json"},mode:"cors",cache:"no-cache"}).then(function(e){return e.json()}).then(function(e){return{id:e.id,width:x(e.widthIn),height:x(e.heightIn),cutLength:x(e.cutLengthIn),preview:e.previewImage}}).then(function(t){return e(H(t))}).catch(console.error)}}var Q="SET_STOCK_MATERIAL";var G="REQUEST_STOCK_MATERIALS";var K="RECEIVE_STOCK_MATERIALS";function J(e){return function(t){return t(function(e){return{type:G,materialTypeId:e}}(e)),fetch(R+"stockmaterials?materialTypeId="+e).then(function(e){return e.json()}).then(function(e){return t({type:K,stockMaterials:e})}).catch(console.error)}}var X="SET_MATERIAL_TYPE";var $="REQUEST_MATERIAL_TYPES";var Z="RECEIVE_MATERIAL_TYPES";function ee(){return function(e){return e({type:$}),fetch(R+"materialtypes").then(function(e){return e.json()}).then(function(t){return e({type:Z,materialTypes:t})}).catch(console.error)}}var te="REQUEST_STATES";var ae="RECEIVE_STATES";function ne(){return function(e){return e({type:te}),fetch(R+"states").then(function(e){return e.json()}).then(function(t){return e({type:ae,states:t})}).catch(console.error)}}var re="SET_QUANTITY";var ie="BACK_STEP";var oe="NEXT_STEP";var se="SET_ADDRESS_FIELD";var le="REQUEST_PAYMENT_TOKEN";var ce="RECEIVE_PAYMENT_TOKEN";var ue="REQUEST_PLACE_ORDER";var me="RECEIVE_PLACE_ORDER";function de(e){return function(t){return t({type:le}),window.stripe.createToken().then(function(a){var n=a.token;t(function(e){return{type:ce,paymentToken:e.id}}(n)),e.paymentToken=n.id}).then(function(){return t({type:ue})}).then(function(){return fetch(R+"orders",{method:"POST",headers:{"Content-Type":"application/json"},mode:"cors",cache:"no-cache",body:JSON.stringify(e)})}).then(function(e){return e.json()}).then(function(e){return t({type:me,orderDetails:e})}).catch(console.error)}}var he="HIDE_ORDER_CONFIRMATION";var pe={step:0,fileSubmissionId:"",filePreviewImage:"",fileWidth:"",fileHeight:"",materialTypeId:"",materialTypes:[],stockMaterialId:"",stockMaterials:[],quantity:1,quote:null,firstName:"",lastName:"",addressLine1:"",addressLine2:"",city:"",zipCode:"",stateId:"",states:[],paymentToken:"",placedOrderId:null,displayOrderConfirmation:!1},fe=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:pe,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case X:return Object.assign({},e,{materialTypeId:t.id});case $:return Object.assign({},e,{isFetchingMaterialTypes:!0});case Z:return Object.assign({},e,{isFetchingMaterialTypes:!1,materialTypes:t.materialTypes});case Q:return Object.assign({},e,{stockMaterialId:t.id});case G:return Object.assign({},e,{isFetchingStockMaterials:!0});case K:return Object.assign({},e,{isFetchingStockMaterials:!1,stockMaterials:t.stockMaterials});case re:return Object.assign({},e,{quantity:t.quantity});case V:return Object.assign({},e,{isSubmittingFile:!0});case _:return Object.assign({},e,{isSubmittingFile:!1,fileSubmissionId:t.id,fileWidth:t.width,fileHeight:t.height,filePreviewImage:t.preview});case D:return Object.assign({},e,{isFetchingQuote:!0});case U:return Object.assign({},e,{isFetchingQuote:!1,quote:t.quote});case ie:return Object.assign({},e,{step:e.step-1});case oe:return Object.assign({},e,{step:e.step+1});case se:var a={};return a[t.key]=t.val,Object.assign({},e,a);case te:return Object.assign({},e,{isFetchingStates:!0});case ae:return Object.assign({},e,{isFetchingStates:!1,states:t.states});case le:return Object.assign({},e,{isFetchingPaymentToken:!0});case ce:return Object.assign({},e,{isFetchingPaymentToken:!1,paymentToken:t.paymentToken});case ue:return Object.assign({},e,{isFetchingPaymentToken:!0});case me:return Object.assign({},pe,{placedOrderId:t.orderDetails.id,displayOrderConfirmation:!0});case he:return Object.assign({},pe,{displayOrderConfirmation:!1});default:return e}},be="SET_EMAIL";var ye="DISMISS_THANKS";var Ee="REQUEST_SUBSCRIBE";var ge="RECEIVE_SUBSCRIBE";function ve(e){return function(t){t(function(e){return{type:Ee,email:e}}(e)),fetch(R+"subscription",{method:"POST",headers:{"Content-Type":"application/json;"},mode:"cors",cache:"no-cache",body:JSON.stringify(e)}).then(function(){return t(function(e){return{type:ge,email:e}}(e))}).catch(console.error)}}var we={isRequesting:!1,email:"",thanksVisible:!1},Oe=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:we,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case be:return Object.assign({},e,{email:t.email});case Ee:return Object.assign({},e,{isRequesting:!0});case ge:return Object.assign({},{isRequesting:!1,email:"",thanksVisible:!0});case ye:return Object.assign({},e,{thanksVisible:!1});default:return e}},Ce=a(335);var ke="REQUEST_BLOG_POST";var Se="RECEIVE_BLOG_POST";function je(e){return function(t){t({type:ke}),fetch("/blog/".concat(e,"/post.md"),{method:"GET",headers:{"Content-Type":"text/markdown; charset=UTF-8"},mode:"cors"}).then(function(e){return e.text()}).then(function(e){return t=e,(a=Object(Ce.a)(t)).content=a.__content,a.__content=void 0,a;var t,a}).then(function(e){return t(function(e){return{type:Se,blog:e}}(e))}).catch(console.error)}}var Te={isLoading:!1,blog:null},Pe=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Te,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case ke:return{isLoading:!0};case Se:return Object.assign({},e,Object(j.a)({isLoading:!1},t.blog));default:return e}},Ie={token:"",profile:{}},Ae=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Ie,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case We:return e;case qe:return Object.assign({},e,{token:t.token});case Ve:return Object.assign({},e,{profile:t.profile});default:return e}},Ne=Object(P.c)({order:fe,mailingList:Oe,blog:Pe,authentication:Ae}),Le=Object(A.createLogger)();var Re,Me,Fe=(Me=window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__||P.d,Object(P.e)(Ne,Re,Me(Object(P.a)(I.a,Le)))),xe=a(216),De=new(a.n(xe).a)("YwFWl6L1LnIAS9uyopjflLp83tEfoUuE","dronebuildertools.auth0.com");De.on("authenticated",function(e){var t;Fe.dispatch((t=e.accessToken,{type:qe,token:t})),De.getUserInfo(e.accessToken,function(t,a){t?console.error(t):(Fe.dispatch(function(e){return{type:Ve,profile:e}}(a)),localStorage.setItem("accessToken",e.accessToken),localStorage.setItem("profile",JSON.stringify(a)))})});var Ue=De,We="SHOW_LOCK";var qe="RECEIVE_TOKEN";var Ve="RECEIVE_PROFILE";function Ye(){return Ue.show(),{type:We}}var _e="LOGOUT";var He=function(e){function t(){return Object(l.a)(this,t),Object(u.a)(this,Object(m.a)(t).apply(this,arguments))}return Object(d.a)(t,e),Object(c.a)(t,[{key:"render",value:function(){var e=this,t=r.a.createElement(C.a,{color:"inherit",onClick:function(){return e.props.authenticate()}},"Log In"),a=r.a.createElement(C.a,{color:"inherit",onClick:function(){return e.props.logout()}},"Log Out");return this.props.token.length>0?a:t}}]),t}(n.Component),ze=Object(T.b)(function(e){return Object(j.a)({},e.authentication)},function(e){return{authenticate:function(){return e(Ye())},logout:function(){return e((Ue.logout({returnTo:window.location.href}),{type:_e}))}}})(He),Be=(a(732),function(e){function t(){var e;return Object(l.a)(this,t),(e=Object(u.a)(this,Object(m.a)(t).call(this))).hideHeader=function(){return!1===e.state.scrolledUp&&"/"===window.location.pathname},e.state={scrolledUp:!1},e}return Object(d.a)(t,e),Object(c.a)(t,[{key:"componentDidMount",value:function(){var e=this;window.onscroll=function(){window.scrollY>10?e.setState({scrolledUp:!0}):e.state.showHeader&&e.setState({scrolledUp:!1})}}},{key:"render",value:function(){return r.a.createElement(g.a,{position:"sticky",color:"primary",className:this.hideHeader()?"hiddenToolbar":""},r.a.createElement(w.a,null,r.a.createElement(S,null),r.a.createElement("nav",null,r.a.createElement(C.a,{component:k.a,to:"/blog/laser-cut-fall-crafting-ideas",color:"inherit"},"Blog"),r.a.createElement(ze,null))))}}]),t}(n.Component)),Qe=a(146),Ge=a.n(Qe),Ke=a(147),Je=a.n(Ke),Xe=a(148),$e=a.n(Xe),Ze=a(339),et=a.n(Ze),tt=a(342),at=a.n(tt),nt=a(340),rt=a.n(nt),it=a(341),ot=a.n(it),st=function(e){function t(){return Object(l.a)(this,t),Object(u.a)(this,Object(m.a)(t).apply(this,arguments))}return Object(d.a)(t,e),Object(c.a)(t,[{key:"render",value:function(){return r.a.createElement(C.a,{id:"use-sample-file",size:"small","aria-label":"Use Sample",onClick:this.props.onClick},r.a.createElement(ot.a,{style:{marginRight:3}}),"Use Sample File")}}]),t}(n.Component),lt=(a(743),function(e){function t(){var e,a;Object(l.a)(this,t);for(var n=arguments.length,r=new Array(n),i=0;i=t}):null}),jt=Object(wt.createSelector)([St,kt],function(e,t){return e&&t?Ot(e.pricePerUnit*t,2):null}),Tt=Object(T.b)(function(e){return Object(j.a)({subtotal:jt(e)},e.order)},function(e){return{onMaterialTypeChanged:function(t){return e(function(e){return function(t){return t({type:X,id:e}),t(J(e))}}(t))},onStockMaterialChanged:function(t){return e(function(e){return{type:Q,id:e}}(t))},fetchMaterialTypes:function(){return e(ee())}}})(vt),Pt=a(45),It=a.n(Pt),At=function(e){function t(){var e,a;Object(l.a)(this,t);for(var n=arguments.length,r=new Array(n),i=0;i=n&&(a+=" selected"),r.a.createElement("div",{className:a,key:t.id,onClick:e.selectQuantity.bind(e,t.minimumQuantity)},r.a.createElement("div",{className:"price-label"},t.minimumQuantity,"-",t.maximumQuantity,"\xa0 pcs"),r.a.createElement("div",{className:"price-amount"},Ct(t.pricePerUnit)),r.a.createElement("div",{className:"price-label"},"each"))});return r.a.createElement("div",null,r.a.createElement(ft.a,{margin:"normal",fullWidth:!0},r.a.createElement(Lt.a,{filled:!0,style:{fontSize:16,transform:"translate(0, 1.5px) scale(0.75)",transformOrigin:"top left"}},"Pricing Options"),r.a.createElement("div",{className:"prices"},i)),r.a.createElement(ft.a,{margin:"normal",fullWidth:!0},r.a.createElement(Lt.a,{filled:!0,style:{fontSize:16,transform:"translate(0, 1.5px) scale(0.75)",transformOrigin:"top left",marginBottom:".5em"}},"Order Total"),r.a.createElement("span",{className:"total"},Ct(this.props.subtotal)),r.a.createElement("span",{className:"subtle"},"includes S&H and tax.")))}}]),t}(n.Component)),Mt=function(e){function t(){return Object(l.a)(this,t),Object(u.a)(this,Object(m.a)(t).apply(this,arguments))}return Object(d.a)(t,e),Object(c.a)(t,[{key:"componentDidMount",value:function(){var e=this.props;(0,e.fetchQuote)(e.fileSubmissionId,e.stockMaterialId)}},{key:"render",value:function(){return r.a.createElement("div",null,r.a.createElement(At,{onSelected:this.props.onQuantityChanged,quantity:this.props.quantity}),r.a.createElement(Rt,{quote:this.props.quote,onQuantitySelected:this.props.onQuantityChanged,quantity:this.props.quantity,subtotal:this.props.subtotal}))}}]),t}(n.Component),Ft=Object(T.b)(function(e){return Object(j.a)({subtotal:jt(e)},e.order)},function(e){return{onQuantityChanged:function(t){return e({type:re,quantity:t})},fetchQuote:function(t,a){return e(q(t,a))}}})(Mt),xt=a(59),Dt=function(e){function t(){var e,a;Object(l.a)(this,t);for(var n=arguments.length,r=new Array(n),i=0;i