mirror of
https://github.com/hanzo-apps/dash.git
synced 2026-11-02 22:04:28 +00:00
1 line
11 KiB
JavaScript
1 line
11 KiB
JavaScript
(window.webpackJsonp_N_E=window.webpackJsonp_N_E||[]).push([[10],{"5sJl":function(e,t,r){"use strict";var a=r("TqRt");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=a(r("q1tI")),c=(0,a(r("8/g6")).default)(n.default.createElement("path",{d:"M2.01 21L23 12 2.01 3 2 10l15 2-15 2z"}),"Send");t.default=c},"8/g6":function(e,t,r){"use strict";var a=r("TqRt");Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var r=c.default.memo(c.default.forwardRef((function(t,r){return c.default.createElement(o.default,(0,n.default)({ref:r},t),e)})));0;return r.muiName=o.default.muiName,r};var n=a(r("pVnL")),c=a(r("q1tI")),o=a(r("UJJ5"))},Dpg8:function(e,t,r){"use strict";var a=r("TqRt");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=a(r("q1tI")),c=(0,a(r("8/g6")).default)(n.default.createElement("path",{d:"M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z"}),"ArrowUpward");t.default=c},LYUY:function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var a=r("wx14"),n=r("q1tI"),c=r.n(n),o=r("HR5l");function i(e,t){var r=c.a.memo(c.a.forwardRef((function(t,r){return c.a.createElement(o.a,Object(a.a)({ref:r},t),e)})));return r.muiName=o.a.muiName,r}},"O+Dh":function(e,t,r){"use strict";var a=r("q1tI"),n=r.n(a),c=r("LYUY");t.a=Object(c.a)(n.a.createElement("path",{d:"M18 17H6v-2h12v2zm0-4H6v-2h12v2zm0-4H6V7h12v2zM3 22l1.5-1.5L6 22l1.5-1.5L9 22l1.5-1.5L12 22l1.5-1.5L15 22l1.5-1.5L18 22l1.5-1.5L21 22V2l-1.5 1.5L18 2l-1.5 1.5L15 2l-1.5 1.5L12 2l-1.5 1.5L9 2 7.5 3.5 6 2 4.5 3.5 3 2v20z"}),"Receipt")},YFqc:function(e,t,r){e.exports=r("cTJO")},agMo:function(e,t,r){"use strict";r.d(t,"a",(function(){return w})),r.d(t,"b",(function(){return T})),r.d(t,"c",(function(){return U}));var a=r("nKUr"),n=r("IIOH"),c=r("eD//"),o=r("tVbE"),i=r("56Ss"),s=r("IsqK"),l=r("R/WZ"),d=r("q1tI"),u=r.n(d),h=r("LYUY"),f=Object(h.a)(u.a.createElement("path",{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"}),"Poll"),j=Object(h.a)(u.a.createElement("path",{d:"M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.33 0-7 1.17-7 3.5V19h14v-2.5c0-2.33-4.67-3.5-7-3.5zm8 0c-.29 0-.62.02-.97.05 1.16.84 1.97 1.97 1.97 3.45V19h6v-2.5c0-2.33-4.67-3.5-7-3.5z"}),"Group"),p=Object(h.a)(u.a.createElement("path",{d:"M17.21 9l-4.38-6.56c-.19-.28-.51-.42-.83-.42-.32 0-.64.14-.83.43L6.79 9H2c-.55 0-1 .45-1 1 0 .09.01.18.04.27l2.54 9.27c.23.84 1 1.46 1.92 1.46h13c.92 0 1.69-.62 1.93-1.46l2.54-9.27L23 10c0-.55-.45-1-1-1h-4.79zM9 9l3-4.4L15 9H9zm3 8c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2z"}),"ShoppingBasket"),m=r("O+Dh"),b=Object(h.a)(u.a.createElement("path",{d:"M4 8h4V4H4v4zm6 12h4v-4h-4v4zm-6 0h4v-4H4v4zm0-6h4v-4H4v4zm6 0h4v-4h-4v4zm6-10v4h4V4h-4zm-6 4h4V4h-4v4zm6 6h4v-4h-4v4zm0 6h4v-4h-4v4z"}),"Apps"),g=r("aoTL"),v=r("qMEs"),O=r("f4ym"),x=Object(l.a)((function(e){return{listIcon:{margin:0,minWidth:"initial",marginRight:e.spacing(1)},toolbar:e.mixins.toolbar,drawer:{width:200,flexShrink:0},drawerPaper:{width:200,paddingTop:"64px"},rotated:{transform:"rotate(-45deg)"},marginTop:{marginTop:e.spacing(1)}}})),w=Object(g.a)((function(){var e=x();return Object(v.useStore)().credentialStore.isLoggedIn?Object(a.jsx)(n.a,{variant:"permanent",className:e.drawer,classes:{paper:e.drawerPaper},children:Object(a.jsxs)(c.a,{className:e.marginTop,children:[Object(a.jsxs)(o.a,{children:[Object(a.jsx)(i.a,{className:e.listIcon,children:Object(a.jsx)(O.a,{href:"/dash",color:"textPrimary",children:Object(a.jsx)(f,{})})}),Object(a.jsx)(s.a,{children:Object(a.jsx)(O.a,{href:"/dash",color:"textPrimary",children:"Overview"})})]}),Object(a.jsxs)(o.a,{children:[Object(a.jsx)(i.a,{className:e.listIcon,children:Object(a.jsx)(O.a,{href:"/dash/users",color:"textPrimary",children:Object(a.jsx)(j,{})})}),Object(a.jsx)(s.a,{children:Object(a.jsx)(O.a,{href:"/dash/users",color:"textPrimary",children:"Users"})})]}),Object(a.jsxs)(o.a,{children:[Object(a.jsx)(i.a,{className:e.listIcon,children:Object(a.jsx)(O.a,{href:"/dash/products",color:"textPrimary",children:Object(a.jsx)(p,{})})}),Object(a.jsx)(s.a,{children:Object(a.jsx)(O.a,{href:"/dash/products",color:"textPrimary",children:"Products"})})]}),Object(a.jsxs)(o.a,{children:[Object(a.jsx)(i.a,{className:e.listIcon,children:Object(a.jsx)(O.a,{href:"/dash/orders",color:"textPrimary",children:Object(a.jsx)(m.a,{})})}),Object(a.jsx)(s.a,{children:Object(a.jsx)(O.a,{href:"/dash/orders",color:"textPrimary",children:"Orders"})})]}),Object(a.jsxs)(o.a,{children:[Object(a.jsx)(i.a,{className:e.listIcon,children:Object(a.jsx)(O.a,{href:"/dash/integrations",color:"textPrimary",children:Object(a.jsx)(b,{})})}),Object(a.jsx)(s.a,{children:Object(a.jsx)(O.a,{href:"/dash/integrations",color:"textPrimary",children:"Integrations"})})]})]})}):null})),L=r("lO0E"),y=(r("mQs5"),r("Dpg8"),r("5sJl"),r("nOHt")),z=r.n(y),I=(Object(l.a)((function(e){return{flex1:{flex:1,textAlign:"center",padding:e.spacing(2)},noPadding:{padding:0},rotated:{transform:"rotate(-45deg)",position:"relative",left:"3px"},blockLink:{display:"block"}}})),r("rePB")),N=r("bXiM"),E=r("ofer"),M=r("PsDL"),R=r("gd/W"),P=r("jjAL"),H=r("wClv"),k=Object(h.a)(u.a.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 3c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm0 14.2c-2.5 0-4.71-1.28-6-3.22.03-1.99 4-3.08 6-3.08 1.99 0 5.97 1.09 6 3.08-1.29 1.94-3.5 3.22-6 3.22z"}),"AccountCircle"),q=Object(l.a)((function(e){return{root:{zIndex:e.zIndex.drawer+1,color:"#FFF"},toolbar:{padding:0,paddingLeft:e.spacing(2),justifyContent:"space-between"},logoImg:{maxHeight:36},textField:{marginLeft:e.spacing(),marginRight:e.spacing()},flex0:{flex:0,color:"#FFF"},search:Object(I.a)({flexGrow:1,position:"relative",borderRadius:e.shape.borderRadius,backgroundColor:Object(H.fade)(e.palette.common.white,.15),"&:hover":{backgroundColor:Object(H.fade)(e.palette.common.white,.25)},marginRight:e.spacing(2),marginLeft:0,width:"100%"},e.breakpoints.up("sm"),{marginLeft:e.spacing(3),width:"auto"}),searchIcon:{width:e.spacing(9),height:"100%",position:"absolute",pointerEvents:"none",display:"flex",alignItems:"center",justifyContent:"center",padding:0},inputRoot:{color:"inherit",width:"100%"},inputInput:Object(I.a)({paddingTop:e.spacing(),paddingRight:e.spacing(),paddingBottom:e.spacing(),paddingLeft:e.spacing(10),transition:e.transitions.create("width"),width:"100%"},e.breakpoints.up("md"),{width:200}),columns:{}}})),T=function(){var e=q(),t=Object(v.useStore)().credentialStore,r=Object(d.useState)(null),n=r[0],c=r[1],o=t.org,i=t.user,s=!!n;return Object(a.jsx)(N.a,{className:e.root,position:"fixed",color:"primary",children:Object(a.jsxs)(L.a,{className:e.toolbar,children:[Object(a.jsx)(O.a,{className:e.columns,href:"/",children:Object(a.jsx)("img",{src:"/_next/static/assets/images/logo.a9378e7c1bf3b4cf6d7c74b32d771ccb.svg",className:e.logoImg,alt:"logo"})}),Object(a.jsx)(E.a,{variant:"h5",children:o?o.name:""}),Object(a.jsx)(M.a,{className:e.flex0,onClick:function(e){c(e.currentTarget)},children:Object(a.jsx)(k,{style:{fontSize:"36px"}})}),Object(a.jsxs)(R.a,{id:"menu-appbar",anchorEl:n,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"bottom",horizontal:"right"},open:s,onClose:function(){c(null)},children:[Object(a.jsx)(P.a,{children:Object(a.jsx)(E.a,{variant:"body1",children:"Hi, ".concat(i?i.firstName:"UKNOWN")})}),Object(a.jsx)(P.a,{onClick:function(){t.logout(),c(null),z.a.push("/")},children:Object(a.jsx)(E.a,{variant:"body1",children:"Logout"})})]})]})})},_=r("wx14"),C=r("Ff2n"),S=r("kfFl"),V=r("de8u"),F=Object(l.a)((function(e){return{dialog:{padding:e.spacing(2)},progress:{marginLeft:"auto",marginRight:"auto",marginTop:e.spacing(1)}}})),U=function(e){var t=e.open,r=e.title,n=Object(C.a)(e,["open","title"]),c=F();return Object(a.jsx)("div",Object(_.a)({},n,{children:Object(a.jsx)(S.a,{open:t,children:Object(a.jsxs)("div",{className:c.dialog,children:[Object(a.jsx)(E.a,{children:r}),Object(a.jsx)(V.a,{className:c.progress,color:"primary"})]})})}))}},cTJO:function(e,t,r){"use strict";var a=r("J4zp"),n=r("284h");t.__esModule=!0,t.default=void 0;var c,o=n(r("q1tI")),i=r("elyg"),s=r("nOHt"),l=new Map,d=window.IntersectionObserver,u={};var h=function(e,t){var r=c||(d?c=new d((function(e){e.forEach((function(e){if(l.has(e.target)){var t=l.get(e.target);(e.isIntersecting||e.intersectionRatio>0)&&(c.unobserve(e.target),l.delete(e.target),t())}}))}),{rootMargin:"200px"}):void 0);return r?(r.observe(e),l.set(e,t),function(){try{r.unobserve(e)}catch(t){console.error(t)}l.delete(e)}):function(){}};function f(e,t,r,a){(0,i.isLocalURL)(t)&&(e.prefetch(t,r,a).catch((function(e){0})),u[t+"%"+r]=!0)}var j=function(e){var t=!1!==e.prefetch,r=o.default.useState(),n=a(r,2),c=n[0],l=n[1],j=(0,s.useRouter)(),p=j&&j.pathname||"/",m=o.default.useMemo((function(){var t=(0,i.resolveHref)(p,e.href,!0),r=a(t,2),n=r[0],c=r[1];return{href:n,as:e.as?(0,i.resolveHref)(p,e.as):c||n}}),[p,e.href,e.as]),b=m.href,g=m.as;o.default.useEffect((function(){if(t&&d&&c&&c.tagName&&(0,i.isLocalURL)(b)&&!u[b+"%"+g])return h(c,(function(){f(j,b,g)}))}),[t,c,b,g,j]);var v=e.children,O=e.replace,x=e.shallow,w=e.scroll,L=e.locale;"string"===typeof v&&(v=o.default.createElement("a",null,v));var y=o.Children.only(v),z={ref:function(e){e&&l(e),y&&"object"===typeof y&&y.ref&&("function"===typeof y.ref?y.ref(e):"object"===typeof y.ref&&(y.ref.current=e))},onClick:function(e){y.props&&"function"===typeof y.props.onClick&&y.props.onClick(e),e.defaultPrevented||function(e,t,r,a,n,c,o,s){("A"!==e.currentTarget.nodeName||!function(e){var t=e.currentTarget.target;return t&&"_self"!==t||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||e.nativeEvent&&2===e.nativeEvent.which}(e)&&(0,i.isLocalURL)(r))&&(e.preventDefault(),null==o&&(o=a.indexOf("#")<0),t[n?"replace":"push"](r,a,{shallow:c,locale:s}).then((function(e){e&&o&&(window.scrollTo(0,0),document.body.focus())})))}(e,j,b,g,O,x,w,L)}};return t&&(z.onMouseEnter=function(e){(0,i.isLocalURL)(b)&&(y.props&&"function"===typeof y.props.onMouseEnter&&y.props.onMouseEnter(e),f(j,b,g,{priority:!0}))}),(e.passHref||"a"===y.type&&!("href"in y.props))&&(z.href=(0,i.addBasePath)((0,i.addLocale)(g,"undefined"!==typeof L?L:j&&j.locale,j&&j.defaultLocale))),o.default.cloneElement(y,z)};t.default=j},f4ym:function(e,t,r){"use strict";var a=r("Ff2n"),n=r("nKUr"),c=r("hlie"),o=r("R/WZ"),i=r("YFqc"),s=r.n(i),l=(r("q1tI"),Object(o.a)((function(){return{root:{cursor:"pointer"}}})));t.a=function(e){var t=e.href,r=Object(a.a)(e,["href"]),o=l(),i=r.className,d=r.hrefAs,u=r.children,h=r.target,f=r.color;return Object(n.jsx)(n.Fragment,{children:t&&"/"===t[0]&&!h?Object(n.jsx)(s.a,{href:t,as:d,children:Object(n.jsx)(c.a,{color:f,className:"".concat(o.root," ").concat(i),children:u})}):Object(n.jsx)(c.a,{href:t,target:h,rel:h?"noopener":"",color:f,className:"".concat(o.root," ").concat(i),children:u})})}},mQs5:function(e,t,r){"use strict";var a=r("TqRt");Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=a(r("q1tI")),c=(0,a(r("8/g6")).default)(n.default.createElement("path",{d:"M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z"}),"ArrowDownward");t.default=c}}]); |