This commit is contained in:
Benjamin Toby
2024-12-05 08:03:33 +01:00
parent 9686a22c96
commit 3ffd2d6777
821 changed files with 3251 additions and 91996 deletions
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2197],{45160:function(t,n,c){"use strict";var e=c(64836);n.Z=void 0;var r=e(c(64938)),u=c(85893),o=(0,r.default)([(0,u.jsx)("path",{d:"M4 16.5c0 .83.67 1.5 1.5 1.5h9c.83 0 1.5-.67 1.5-1.5V13H4v3.5zm6-2.5c.83 0 1.5.67 1.5 1.5S10.83 17 10 17s-1.5-.67-1.5-1.5S9.17 14 10 14zM4.43 6H11c0-.33.03-.66.08-.98-3.37-.1-5.75.21-6.65.98z",opacity:".3"},"0"),(0,u.jsx)("path",{d:"M4 11V8h7.29C11.1 7.37 11 6.7 11 6H4.43c.9-.77 3.28-1.08 6.65-.98.1-.7.3-1.37.59-1.99C2.97 2.67 2 5.02 2 7v9.5C2 18.43 3.57 20 5.5 20L4 21v1h12v-1l-1.5-1c1.93 0 3.5-1.57 3.5-3.5V13c-1.91 0-3.63-.76-4.89-2H4zm12 5.5c0 .83-.67 1.5-1.5 1.5h-9c-.83 0-1.5-.67-1.5-1.5V13h12v3.5z"},"1"),(0,u.jsx)("circle",{cx:"10",cy:"15.5",r:"1.5"},"2"),(0,u.jsx)("path",{d:"M18 1c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm.5 8h-1V8h1v1zm0-2h-1V3h1v4z"},"3")],"RailwayAlertTwoTone");n.Z=o},58671:function(t,n,c){(window.__NEXT_P=window.__NEXT_P||[]).push(["/404",function(){return c(40790)}])},9922:function(t,n,c){"use strict";c.d(n,{Z:function(){return r}});var e=c(86729);function r(t){var n=t.setUser,c=localStorage.getItem("user");if(c)try{return void n(JSON.parse(c))}catch(r){return void n({})}(0,e.Z)("/api/clientSideAuth",{method:"post",body:{}},!0).then((function(t){var c=t.user?t.user:{};n(c),localStorage.setItem("user",JSON.stringify(c))})).catch((function(t){console.log(t)}))}},40790:function(t,n,c){"use strict";c.r(n),c.d(n,{default:function(){return r}});c(828),c(85893);var e=c(67294);c(56217),c(24097),c(9922),c(45160);function r(t){return e.useEffect((function(){window.location.href="https://datasquirel.com"}),[]),null}}},function(t){t.O(0,[9774,2888,179],(function(){return n=58671,t(t.s=n);var n}));var n=t.O();_N_E=n}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2336],{28213:(t,e,c)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/404",function(){return c(35562)}])},62900:(t,e,c)=>{"use strict";c.d(e,{A:()=>s});var r=c(23698);function s(t){let{setUser:e}=t,c=localStorage.getItem("user");if(c)try{e(JSON.parse(c));return}catch(t){e({});return}(0,r.A)("/api/clientSideAuth",{method:"post",body:{}},!0).then(t=>{let c=t.user?t.user:{};e(c),localStorage.setItem("user",JSON.stringify(c))}).catch(t=>{console.log(t)})}},79518:(t,e,c)=>{"use strict";var r=c(24994);e.A=void 0;var s=r(c(44888)),a=c(74848);e.A=(0,s.default)([(0,a.jsx)("path",{d:"M4 16.5c0 .83.67 1.5 1.5 1.5h9c.83 0 1.5-.67 1.5-1.5V13H4zm6-2.5c.83 0 1.5.67 1.5 1.5S10.83 17 10 17s-1.5-.67-1.5-1.5S9.17 14 10 14M4.43 6H11c0-.33.03-.66.08-.98-3.37-.1-5.75.21-6.65.98",opacity:".3"},"0"),(0,a.jsx)("path",{d:"M4 11V8h7.29C11.1 7.37 11 6.7 11 6H4.43c.9-.77 3.28-1.08 6.65-.98.1-.7.3-1.37.59-1.99C2.97 2.67 2 5.02 2 7v9.5C2 18.43 3.57 20 5.5 20L4 21v1h12v-1l-1.5-1c1.93 0 3.5-1.57 3.5-3.5V13c-1.91 0-3.63-.76-4.89-2zm12 5.5c0 .83-.67 1.5-1.5 1.5h-9c-.83 0-1.5-.67-1.5-1.5V13h12z"},"1"),(0,a.jsx)("circle",{cx:"10",cy:"15.5",r:"1.5"},"2"),(0,a.jsx)("path",{d:"M18 1c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5m.5 8h-1V8h1zm0-2h-1V3h1z"},"3")],"RailwayAlertTwoTone")},35562:(t,e,c)=>{"use strict";c.r(e),c.d(e,{default:()=>s}),c(74848);var r=c(96540);function s(t){return r.useEffect(()=>{window.location.href="https://datasquirel.com"},[]),null}c(93444),c(96411),c(62900),c(79518)}},t=>{var e=e=>t(t.s=e);t.O(0,[636,6593,8792],()=>e(28213)),_N_E=t.O()}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[421],{65450:(t,e,r)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/500",function(){return r(39499)}])},62900:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});var u=r(23698);function n(t){let{setUser:e}=t,r=localStorage.getItem("user");if(r)try{e(JSON.parse(r));return}catch(t){e({});return}(0,u.A)("/api/clientSideAuth",{method:"post",body:{}},!0).then(t=>{let r=t.user?t.user:{};e(r),localStorage.setItem("user",JSON.stringify(r))}).catch(t=>{console.log(t)})}},39499:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n}),r(74848);var u=r(96540);function n(t){return u.useEffect(()=>{window.location.href="https://datasquirel.com"},[]),null}r(93444),r(96411),r(62900),r(23698)}},t=>{var e=e=>t(t.s=e);t.O(0,[636,6593,8792],()=>e(65450)),_N_E=t.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8573],{97163:function(t,n,e){(window.__NEXT_P=window.__NEXT_P||[]).push(["/500",function(){return e(95494)}])},9922:function(t,n,e){"use strict";e.d(n,{Z:function(){return u}});var r=e(86729);function u(t){var n=t.setUser,e=localStorage.getItem("user");if(e)try{return void n(JSON.parse(e))}catch(u){return void n({})}(0,r.Z)("/api/clientSideAuth",{method:"post",body:{}},!0).then((function(t){var e=t.user?t.user:{};n(e),localStorage.setItem("user",JSON.stringify(e))})).catch((function(t){console.log(t)}))}},95494:function(t,n,e){"use strict";e.r(n),e.d(n,{default:function(){return u}});e(828),e(85893);var r=e(67294);e(56217),e(24097),e(9922),e(86729);function u(t){return r.useEffect((function(){window.location.href="https://datasquirel.com"}),[]),null}}},function(t){t.O(0,[9774,2888,179],(function(){return n=97163,t(t.s=n);var n}));var n=t.O();_N_E=n}]);
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2731],{56194:(_,n,e)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/_error",function(){return e(33709)}])}},_=>{var n=n=>_(_.s=n);_.O(0,[636,6593,8792],()=>n(56194)),_N_E=_.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4820],{81981:function(n,_,u){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_error",function(){return u(89185)}])}},function(n){n.O(0,[9774,2888,179],(function(){return _=81981,n(n.s=_);var _}));var _=n.O();_N_E=_}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4239],{99482:(t,e,n)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/about",function(){return n(61918)}])},61918:(t,e,n)=>{"use strict";n.r(e),n.d(e,{HomepageContext:()=>o,default:()=>a}),n(74848);var u=n(96540);n(93444),n(96411),n(62900),n(42361),n(26659),n(96869);let o=u.createContext({});function a(t){return u.useEffect(()=>{window.location.href="https://datasquirel.com/about"},[]),null}}},t=>{var e=e=>t(t.s=e);t.O(0,[9654,636,6593,8792],()=>e(99482)),_N_E=t.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2521],{26515:function(n,t,u){(window.__NEXT_P=window.__NEXT_P||[]).push(["/about",function(){return u(82939)}])},82939:function(n,t,u){"use strict";u.r(t),u.d(t,{HomepageContext:function(){return o},default:function(){return r}});u(828),u(85893);var e=u(67294);u(56217);u(24097),u(9922),u(47335),u(73987),u(40662);var o=e.createContext({});function r(n){return e.useEffect((function(){window.location.href="https://datasquirel.com/about"}),[]),null}}},function(n){n.O(0,[3935,9774,2888,179],(function(){return t=26515,n(n.s=t);var t}));var t=n.O();_N_E=t}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6309],{39943:(e,t,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin",function(){return a(76902)}])},76902:(e,t,a)=>{"use strict";a.r(t),a.d(t,{DashboardContext:()=>l,__N_SSP:()=>i,default:()=>_});var r=a(74848),s=a(96540),n=a(51187),u=a(75849),d=a(47652),i=!0;let l=s.createContext({});function _(e){let{user:t,databases:a,metrics:i}=e,_=(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("title",{children:"User Dashboard | Datasquirel"}),(0,r.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),[o,c]=s.useState(null);return(0,r.jsx)(n.A,{head:_,user:t,children:(0,r.jsxs)(l.Provider,{value:{user:t,databases:a,targetDatabase:o,setTargetDatabase:c,metrics:i},children:[(0,r.jsx)(u.A,{}),(0,r.jsx)(d.A,{targetDatabase:o})]})})}}},e=>{var t=t=>e(e.s=t);e.O(0,[9799,8866,7538,820,636,6593,8792],()=>t(39943)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6964],{37953:function(e,t,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin",function(){return a(21174)}])},21174:function(e,t,a){"use strict";a.r(t),a.d(t,{DashboardContext:function(){return _},__N_SSP:function(){return d},default:function(){return l}});var n=a(828),r=a(85893),s=a(67294),u=a(54858),i=a(37359),c=a(85012),o={},d=!0,_=s.createContext(o);function l(e){var t=e.user,a=e.databases,o=e.metrics,d=(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("title",{children:"User Dashboard | Datasquirel"}),(0,r.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),l=s.useState(null),f=(0,n.Z)(l,2),h=f[0],b=f[1];return(0,r.jsx)(u.Z,{head:d,user:t,children:(0,r.jsxs)(_.Provider,{value:{user:t,databases:a,targetDatabase:h,setTargetDatabase:b,metrics:o},children:[(0,r.jsx)(i.Z,{}),(0,r.jsx)(c.Z,{targetDatabase:h})]})})}}},function(e){e.O(0,[9365,3181,5667,9774,2888,179],(function(){return t=37953,e(e.s=t);var t}));var t=e.O();_N_E=t}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4135],{61243:function(n,_,u){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]",function(){return u(41457)}])}},function(n){n.O(0,[9365,3181,5667,9774,2888,179],(function(){return _=61243,n(n.s=_);var _}));var _=n.O();_N_E=_}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[531],{18295:(_,n,u)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]",function(){return u(55436)}])}},_=>{var n=n=>_(_.s=n);_.O(0,[9799,8866,7538,820,636,6593,8792],()=>n(18295)),_N_E=_.O()}]);
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[133],{74166:function(n,_,u){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/databases",function(){return u(2109)}])}},function(n){n.O(0,[9365,3181,9774,2888,179],(function(){return _=74166,n(n.s=_);var _}));var _=n.O();_N_E=_}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2564],{19107:(_,n,s)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/databases",function(){return s(98471)}])}},_=>{var n=n=>_(_.s=n);_.O(0,[9799,8866,7538,636,6593,8792],()=>n(19107)),_N_E=_.O()}]);
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5926],{97385:function(e,t,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/databases/[single]/users/add-user",function(){return a(14437)}])},14437:function(e,t,a){"use strict";a.r(t),a.d(t,{AddNewDbUserContext:function(){return p},__N_SSP:function(){return h},default:function(){return _}});var s=a(85893),n=a(67294),r=a(54858),d=a(828),i=a(424),u=a(61781),l=a(86729),o=a(95264),c=a(81926);function m(e){var t=n.useContext(p),r=t.user,m=t.database,f=(t.table,t.query,t.confirmedDelegetedUser,a(19169),(0,d.Z)(n.useState("invitation"),2)),b=(f[0],f[1],(0,d.Z)(n.useState(!1),2)),h=b[0],_=b[1],x=(0,d.Z)(n.useState(!1),2),v=(x[0],x[1],(0,d.Z)(n.useState(["Edit"]),2)),g=(v[0],v[1],(0,d.Z)(n.useState(m.db_slug),2)),j=g[0],w=(g[1],(0,d.Z)(n.useState(null),2)),N=(w[0],w[1],(0,d.Z)(n.useState(null),2)),Z=N[0],U=N[1],y=(0,d.Z)(n.useState([]),2),D=(y[0],y[1],(0,d.Z)(n.useState([]),2));D[0],D[1];return(0,s.jsxs)(n.Fragment,{children:[(0,s.jsxs)("div",{className:"flex-col items-start gap-0 w-full",children:[(0,s.jsx)("div",{className:"w-full justify-between flex-wrap",children:(0,s.jsxs)("div",{children:[(0,s.jsx)(u.Z,{}),(0,s.jsxs)("h1",{className:"text-3xl m-0",children:["Add A New User to ",m.db_name]})]})}),(0,s.jsx)(i.Z,{user:r})]}),(0,s.jsxs)("section",{className:"paper",children:[h&&(0,s.jsx)(o.Z,{}),(0,s.jsxs)("form",{onSubmit:function(e){e.preventDefault(),_(!0);var t=e.target,a=Array.from(t),s={};a.forEach((function(e){var t,a;(null===(t=e.nodeName)||void 0===t?void 0:t.match(/button/i))||e.name&&(null===(a=e.value)||void 0===a?void 0:a.match(/./))&&(s[e.name]=e.value)}));var n={payload:s,dbFullName:m.db_full_name,dbId:m.id};(0,l.Z)("/api/addDbUser",{method:"post",body:n},!0).then((function(e){e.success?Z?(Z.imageName="".concat(j,"-user-").concat(e.newUserId),Z.mimeType="jpeg",delete Z.imageBase64Full,(0,l.Z)("/api/addUserMedia",{method:"post",body:{media:[Z],folder:j.replace(/_/g,"-"),type:"image"}},!0).then((function(t){(0,l.Z)("/api/updateDbUser",{method:"post",body:{dbFullName:m.db_full_name,payload:{id:e.newUserId,image:t.mediaData[0].media_url,image_thumbnail:t.mediaData[0].media_thumbnail_url}}},!0).then((function(e){e.success&&(window.location.pathname="/admin/".concat(null===r||void 0===r?void 0:r.id,"/databases/").concat(m.db_slug,"/users")),setTimeout((function(){_(!1)}),500)}))}))):window.location.pathname="/admin/".concat(null===r||void 0===r?void 0:r.id,"/databases/").concat(m.db_slug,"/users"):setTimeout((function(){_(!1)}),500)}))},className:"w-full flex flex-col items-stretch gap-4",children:[(0,s.jsx)(c.Z,{user:r,targetDb:m.db_full_name,database:m,userImage:Z,setUserImage:U}),(0,s.jsx)("button",{children:"Add User"})]})]})]})}var f=a(4423),b={},h=!0,p=n.createContext(b);function _(e){var t=e.user,a=e.database,n=e.table,d=e.query,i=e.confirmedDelegetedUser,u=(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("title",{children:"Users | Datasquirel"}),(0,s.jsx)("meta",{name:"description",content:"Welcome to your data app"})]});return(0,s.jsx)(r.Z,{head:u,user:t,extraHeaderContent:(0,s.jsx)(f.Z,{database:a,query:d,confirmedDelegetedUser:i,user:t}),children:(0,s.jsx)(p.Provider,{value:{user:t,database:a,table:n,query:d,confirmedDelegetedUser:i},children:(0,s.jsx)(m,{})})})}},19169:function(e){"use strict";e.exports=JSON.parse('["Edit Tables","Update Entries","Create Table","Delete Entries","Delete Tables"]')}},function(e){e.O(0,[9365,194,7901,2870,9719,9774,2888,179],(function(){return t=97385,e(e.s=t);var t}));var t=e.O();_N_E=t}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9718],{80370:(e,a,n)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/databases/add-database",function(){return n(87810)}])},99862:(e,a,n)=>{"use strict";n.d(a,{A:()=>t});var l=n(74848);n(96540);var s=n(86625);function t(){return(0,l.jsx)("button",{className:"outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full",onClick:e=>{window.history.back()},children:(0,l.jsx)(s.A,{color:"inherit",className:"opacity-50 text-black",fontSize:"small"})})}},45165:(e,a,n)=>{"use strict";n.d(a,{Ay:()=>c,PB:()=>i,fs:()=>o});var l=n(74848),s=n(76897),t=n(96540);function c(e){let{children:a,title:n,data:c,fullPage:i,wrapperClasses:d,closePopupDispatch:r,wrapperStyle:u,noContainer:p}=e;return i?(0,l.jsxs)("div",{className:"popup-bg overflow-hidden "+(d||""),"data-popupid":n||null,style:u,children:[p?(0,l.jsx)(t.Fragment,{children:a}):(0,l.jsx)("div",{className:"relative w-full h-full z-50","data-data":c?JSON.stringify(c):"",children:a}),(0,l.jsx)("button",{className:"popup-cancel-button fixed outlined gray",onClick:e=>{o(),r&&r()},children:(0,l.jsx)(s.A,{color:"white",size:20})}),(0,l.jsx)("div",{className:"popup-canceller",onClick:e=>{o(),r&&r()}})]}):(0,l.jsxs)("div",{className:"popup-bg","data-popupid":n||null,children:[p?(0,l.jsx)(t.Fragment,{children:a}):(0,l.jsxs)("div",{className:"popup-content-container minimal-scrollbars","data-data":c?JSON.stringify(c):"",children:[a,(0,l.jsx)("button",{className:"outlined gray popup-cancel-button",onClick:e=>{o(),r&&r()},children:(0,l.jsx)("span",{className:"font-normal",children:"✖"})})]}),p&&(0,l.jsx)("button",{className:"gray popup-cancel-button",onClick:e=>{o(),r&&r()},children:(0,l.jsx)("span",{className:"font-normal",children:"✖"})}),(0,l.jsx)("div",{className:"popup-canceller",onClick:e=>{o(),r&&r()}})]})}function i(e,a){let n=document.querySelector("[data-popupid='".concat(e,"']"));n&&(n.style.display="flex",a&&a(n))}function o(e){document.querySelectorAll("[data-popupid]").forEach(e=>{e.style.display="none"}),e&&e()}},94909:(e,a,n)=>{"use strict";n.d(a,{A:()=>l});let l=(0,n(95737).A)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]])}},e=>{var a=a=>e(e.s=a);e.O(0,[1570,9799,5414,5160,3293,636,6593,8792],()=>a(80370)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3316],{42065:function(n,t,a){"use strict";var e=a(64836);t.Z=void 0;var c=e(a(64938)),i=a(85893),l=(0,c.default)((0,i.jsx)("path",{d:"M16.62 2.99c-.49-.49-1.28-.49-1.77 0L6.54 11.3c-.39.39-.39 1.02 0 1.41l8.31 8.31c.49.49 1.28.49 1.77 0s.49-1.28 0-1.77L9.38 12l7.25-7.25c.48-.48.48-1.28-.01-1.76z"}),"ArrowBackIosRounded");t.Z=l},35826:function(n,t,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/databases/add-database",function(){return a(96706)}])},61781:function(n,t,a){"use strict";a.d(t,{Z:function(){return i}});var e=a(85893),c=(a(67294),a(42065));function i(){return(0,e.jsx)("button",{className:"outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full",onClick:function(n){window.history.back()},children:(0,e.jsx)(c.Z,{color:"inherit",className:"opacity-50 text-black",fontSize:"small"})})}},25472:function(n,t,a){"use strict";a.d(t,{Mw:function(){return o},ZP:function(){return l},j4:function(){return s}});var e=a(85893),c=a(41352),i=a(67294);function l(n){var t=n.children,a=n.title,l=n.data,o=n.fullPage,r=n.wrapperClasses,u=n.closePopupDispatch,d=n.wrapperStyle,p=n.noContainer;return o?(0,e.jsxs)("div",{className:"popup-bg overflow-hidden "+(r||""),"data-popupid":a||null,style:d,children:[p?(0,e.jsx)(i.Fragment,{children:t}):(0,e.jsx)("div",{className:"relative w-full h-full z-50","data-data":l?JSON.stringify(l):"",children:t}),(0,e.jsx)("button",{className:"popup-cancel-button fixed outlined gray",onClick:function(n){s(),u&&u()},children:(0,e.jsx)(c.Z,{color:"white",size:20})}),(0,e.jsx)("div",{className:"popup-canceller",onClick:function(n){s(),u&&u()}})]}):(0,e.jsxs)("div",{className:"popup-bg","data-popupid":a||null,children:[p?(0,e.jsx)(i.Fragment,{children:t}):(0,e.jsxs)("div",{className:"popup-content-container minimal-scrollbars","data-data":l?JSON.stringify(l):"",children:[t,(0,e.jsx)("button",{className:"outlined gray popup-cancel-button",onClick:function(n){s(),u&&u()},children:(0,e.jsx)("span",{className:"font-normal",children:"\u2716"})})]}),p&&(0,e.jsx)("button",{className:"gray popup-cancel-button",onClick:function(n){s(),u&&u()},children:(0,e.jsx)("span",{className:"font-normal",children:"\u2716"})}),(0,e.jsx)("div",{className:"popup-canceller",onClick:function(n){s(),u&&u()}})]})}function o(n,t){var a=document.querySelector("[data-popupid='".concat(n,"']"));a&&(a.style.display="flex",t&&t(a))}function s(n){document.querySelectorAll("[data-popupid]").forEach((function(n){n.style.display="none"})),n&&n()}}},function(n){n.O(0,[3662,9365,7901,9967,8887,9774,2888,179],(function(){return t=35826,n(n.s=t);var t}));var t=n.O();_N_E=t}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3400],{62999:function(e,s,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/media",function(){return t(58333)}])},58333:function(e,s,t){"use strict";t.r(s),t.d(s,{MediaContext:function(){return M},__N_SSP:function(){return _},default:function(){return v}});var a=t(828),n=t(85893),i=t(67294),r=t(54858),d=t(424),l=t(25472),o=t(97946),c=t(17244),u=t(45449);function x(e){var s,t=i.useContext(M),a=t.media,r=t.setTargetMedia,x=t.user,m=t.folders,j=t.staticHost;return(0,n.jsxs)(i.Fragment,{children:[(0,n.jsxs)("div",{className:"flex-col items-start gap-0 w-full",children:[(0,n.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,n.jsx)("h1",{className:"text-3xl m-0",children:"Media"}),(0,n.jsxs)(u.Z,{children:[(0,n.jsxs)("button",{className:"flex items-center gap-2",onClick:function(e){(0,l.Mw)("choose-media-type-popoup")},children:[(0,n.jsx)("span",{className:"symbol",children:"+"}),(0,n.jsx)("span",{children:"Add Media"})]}),(0,n.jsxs)("button",{className:"flex items-center gap-2 outlined gray",onClick:function(e){(0,l.Mw)("add-folder-popoup")},children:[(0,n.jsx)("span",{className:"symbol",children:"+"}),(0,n.jsx)("span",{children:"Add Folder"})]})]})]}),(0,n.jsx)(d.Z,{user:x})]}),(null===x||void 0===x||null===(s=x.verification_status)||void 0===s?void 0:s.toString().match(/1/))?(0,n.jsxs)(i.Fragment,{children:[(0,n.jsx)(c.Z,{media:a,setTargetMedia:r,folders:m,staticHost:j,user:x}),a&&a[0]&&(0,n.jsxs)("a",{className:"border-dotted border-slate-400 border-2 px-4 py-3 w-full rounded flex items-center hover:border-primary/50 gap-2 cursor-pointer justify-center",onClick:function(e){(0,l.Mw)("choose-media-type-popoup")},children:[(0,n.jsx)("span",{className:"symbol",children:"+"}),(0,n.jsx)("span",{className:"",children:"Add Media"})]})]}):(0,n.jsx)(o.Z,{})]})}var m=t(73770),j=t(94891),p=t(1347),f=t(81597),h=t(98916),w=t(62588),N=t(95264),g=t(37525),Z={},_=!0,M=i.createContext(Z);function v(e){var s=e.user,t=e.media,d=e.folders,l=e.staticHost,o=(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("title",{children:"User Dashboard | Datasquirel"}),(0,n.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),c=(0,a.Z)(i.useState(null),2),u=c[0],Z=c[1],_=(0,a.Z)(i.useState(null),2),v=_[0],b=_[1],y=(0,a.Z)(i.useState(null),2),C=y[0],F=y[1],S=(0,a.Z)(i.useState(!1),2),k=S[0],T=S[1],E=(0,a.Z)(i.useState(null),2),H=E[0],P=E[1];return(0,n.jsx)(r.Z,{head:o,user:s,children:(0,n.jsxs)(M.Provider,{value:{user:s,media:t,targetMedia:H,setTargetMedia:P,folders:d,staticHost:l},children:[k&&(0,n.jsx)(N.Z,{screen:!0,title:"Processing Files ..."}),(0,n.jsx)(x,{}),(0,n.jsx)(m.Z,{setNewMedia:Z,setLoading:T}),(0,n.jsx)(h.Z,{setNewFile:b,setLoading:T}),(0,n.jsx)(g.Z,{setNewVideo:F,setLoading:T}),(0,n.jsx)(j.Z,{newMedia:u,setNewMedia:Z,newFile:v,setNewFile:b,newVideo:C,setNewVideo:F}),(0,n.jsx)(p.Z,{targetMedia:H,setTargetMedia:P,staticHost:l,media:t}),(0,n.jsx)(f.Z,{}),(0,n.jsx)(w.Z,{user:s})]})})}}},function(e){e.O(0,[9365,4156,9774,2888,179],(function(){return s=62999,e(e.s=s);var s}));var s=e.O();_N_E=s}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9326],{54299:(e,s,t)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/media",function(){return t(26636)}])},26636:(e,s,t)=>{"use strict";t.r(s),t.d(s,{MediaContext:()=>g,__N_SSP:()=>_,default:()=>A});var a=t(74848),i=t(96540),l=t(51187),r=t(4709),n=t(45165),d=t(55624),o=t(53301),c=t(60557);function u(e){var s;let{media:t,setTargetMedia:l,user:u,folders:x,staticHost:j}=i.useContext(g);return(0,a.jsxs)(i.Fragment,{children:[(0,a.jsxs)("div",{className:"flex-col items-start gap-0 w-full",children:[(0,a.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,a.jsx)("h1",{className:"text-3xl m-0",children:"Media"}),(0,a.jsxs)(c.A,{children:[(0,a.jsxs)("button",{className:"flex items-center gap-2",onClick:e=>{(0,n.PB)("choose-media-type-popoup")},children:[(0,a.jsx)("span",{className:"symbol",children:"+"}),(0,a.jsx)("span",{children:"Add Media"})]}),(0,a.jsxs)("button",{className:"flex items-center gap-2 outlined gray",onClick:e=>{(0,n.PB)("add-folder-popoup")},children:[(0,a.jsx)("span",{className:"symbol",children:"+"}),(0,a.jsx)("span",{children:"Add Folder"})]})]})]}),(0,a.jsx)(r.A,{user:u})]}),(null==u?void 0:null===(s=u.verification_status)||void 0===s?void 0:s.toString().match(/1/))?(0,a.jsxs)(i.Fragment,{children:[(0,a.jsx)(o.A,{media:t,setTargetMedia:l,folders:x,staticHost:j,user:u}),t&&t[0]&&(0,a.jsxs)("a",{className:"border-dotted border-slate-400 border-2 px-4 py-3 w-full rounded flex items-center hover:border-primary/50 gap-2 cursor-pointer justify-center",onClick:e=>{(0,n.PB)("choose-media-type-popoup")},children:[(0,a.jsx)("span",{className:"symbol",children:"+"}),(0,a.jsx)("span",{className:"",children:"Add Media"})]})]}):(0,a.jsx)(d.A,{})]})}var x=t(67764),j=t(45332),p=t(84003),m=t(5531),h=t(11493),N=t(65001),w=t(620),f=t(22154),_=!0;let g=i.createContext({});function A(e){let{user:s,media:t,folders:r,staticHost:n}=e,d=(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("title",{children:"User Dashboard | Datasquirel"}),(0,a.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),[o,c]=i.useState(null),[_,A]=i.useState(null),[b,v]=i.useState(null),[y,M]=i.useState(!1),[C,F]=i.useState(null);return(0,a.jsx)(l.A,{head:d,user:s,children:(0,a.jsxs)(g.Provider,{value:{user:s,media:t,targetMedia:C,setTargetMedia:F,folders:r,staticHost:n},children:[y&&(0,a.jsx)(w.A,{screen:!0,title:"Processing Files ..."}),(0,a.jsx)(u,{}),(0,a.jsx)(x.A,{setNewMedia:c,setLoading:M}),(0,a.jsx)(h.A,{setNewFile:A,setLoading:M}),(0,a.jsx)(f.A,{setNewVideo:v,setLoading:M}),(0,a.jsx)(j.A,{newMedia:o,setNewMedia:c,newFile:_,setNewFile:A,newVideo:b,setNewVideo:v}),(0,a.jsx)(p.A,{targetMedia:C,setTargetMedia:F,staticHost:n,media:t}),(0,a.jsx)(m.A,{}),(0,a.jsx)(N.A,{user:s})]})})}}},e=>{var s=s=>e(e.s=s);e.O(0,[9799,4750,636,6593,8792],()=>s(54299)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2759],{42065:function(e,s,t){"use strict";var r=t(64836);s.Z=void 0;var n=r(t(64938)),i=t(85893),a=(0,n.default)((0,i.jsx)("path",{d:"M16.62 2.99c-.49-.49-1.28-.49-1.77 0L6.54 11.3c-.39.39-.39 1.02 0 1.41l8.31 8.31c.49.49 1.28.49 1.77 0s.49-1.28 0-1.77L9.38 12l7.25-7.25c.48-.48.48-1.28-.01-1.76z"}),"ArrowBackIosRounded");s.Z=a},22139:function(e,s,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/media/[...folder]",function(){return t(73947)}])},61781:function(e,s,t){"use strict";t.d(s,{Z:function(){return i}});var r=t(85893),n=(t(67294),t(42065));function i(){return(0,r.jsx)("button",{className:"outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full",onClick:function(e){window.history.back()},children:(0,r.jsx)(n.Z,{color:"inherit",className:"opacity-50 text-black",fontSize:"small"})})}},73947:function(e,s,t){"use strict";t.r(s),t.d(s,{MediaContext:function(){return b},__N_SSP:function(){return _},default:function(){return M}});var r=t(828),n=t(85893),i=t(67294),a=t(54858),l=t(73770),o=t(94891),d=t(1347),c=t(81597),u=t(61781),f=t(424),x=t(25472),j=t(97946),m=t(17244),p=t(45449),h=t(30212);function w(e){var s,t=i.useContext(b),r=t.media,a=t.setTargetMedia,l=t.user,o=t.folders,d=t.query,c=t.staticHost,w=t.folder;return(0,n.jsxs)(i.Fragment,{children:[(0,n.jsxs)("div",{className:"flex-col items-start gap-0 w-full",children:[(0,n.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,n.jsxs)("div",{children:[(0,n.jsx)(u.Z,{}),(0,n.jsx)(h.Z,{className:"opacity-40"}),(0,n.jsx)("h1",{className:"text-3xl m-0",children:d.folder[d.folder.length-1]})]}),(0,n.jsxs)(p.Z,{children:[(0,n.jsxs)("button",{className:"flex items-center gap-2",onClick:function(e){(0,x.Mw)("choose-media-type-popoup")},children:[(0,n.jsx)("span",{className:"symbol",children:"+"}),(0,n.jsx)("span",{children:"Add Media"})]}),(0,n.jsxs)("button",{className:"flex items-center gap-2 outlined gray",onClick:function(e){(0,x.Mw)("add-folder-popoup",(function(e){var s;null===(s=null===e||void 0===e?void 0:e.querySelector("input"))||void 0===s||s.focus()}))},children:[(0,n.jsx)("span",{className:"symbol",children:"+"}),(0,n.jsx)("span",{children:"Add Folder"})]})]})]}),(0,n.jsx)(f.Z,{user:l})]}),(null===l||void 0===l||null===(s=l.verification_status)||void 0===s?void 0:s.toString().match(/1/))?(0,n.jsxs)(i.Fragment,{children:[(0,n.jsx)(m.Z,{media:r,setTargetMedia:a,folders:o,folder:w,staticHost:c,user:l}),r&&r[0]&&(0,n.jsxs)("a",{className:"border-dotted border-slate-400 border-2 px-4 py-3 w-full rounded flex items-center hover:border-primary/50 gap-2 cursor-pointer justify-center",onClick:function(e){(0,x.Mw)("choose-media-type-popoup")},children:[(0,n.jsx)("span",{className:"symbol",children:"+"}),(0,n.jsx)("span",{className:"",children:"Add Media"})]})]}):(0,n.jsx)(j.Z,{})]})}var N=t(98916),v=t(62588),Z=t(95264),g=t(37525),y={},_=!0,b=i.createContext(y);function M(e){var s=e.user,t=e.media,u=e.folders,f=e.query,x=e.staticHost,j=e.folderNameFull,m=(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("title",{children:"User Dashboard | Datasquirel"}),(0,n.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),p=(0,r.Z)(i.useState(null),2),h=p[0],y=p[1],_=(0,r.Z)(i.useState(null),2),M=_[0],k=_[1],S=(0,r.Z)(i.useState(null),2),C=S[0],F=S[1],T=(0,r.Z)(i.useState(!1),2),q=T[0],E=T[1],H=(0,r.Z)(i.useState(null),2),L=H[0],P=H[1];return(0,n.jsx)(a.Z,{head:m,user:s,children:(0,n.jsxs)(b.Provider,{value:{user:s,media:t,targetMedia:L,setTargetMedia:P,folders:u,query:f,staticHost:x,folder:j},children:[q&&(0,n.jsx)(Z.Z,{screen:!0,title:"Processing Files ..."}),(0,n.jsx)(w,{}),(0,n.jsx)(l.Z,{setNewMedia:y,setLoading:E}),(0,n.jsx)(N.Z,{setNewFile:k,setLoading:E}),(0,n.jsx)(g.Z,{setNewVideo:F,setLoading:E}),(0,n.jsx)(o.Z,{newMedia:h,setNewMedia:y,newFile:M,setNewFile:k,folder:j,newVideo:C,setNewVideo:F}),(0,n.jsx)(d.Z,{targetMedia:L,staticHost:x,setTargetMedia:P,media:t}),(0,n.jsx)(c.Z,{folder:j}),(0,n.jsx)(v.Z,{user:s})]})})}}},function(e){e.O(0,[9365,4156,9774,2888,179],(function(){return s=22139,e(e.s=s);var s}));var s=e.O();_N_E=s}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[431],{99186:(e,s,t)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/media/[...folder]",function(){return t(52691)}])},99862:(e,s,t)=>{"use strict";t.d(s,{A:()=>r});var a=t(74848);t(96540);var l=t(86625);function r(){return(0,a.jsx)("button",{className:"outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full",onClick:e=>{window.history.back()},children:(0,a.jsx)(l.A,{color:"inherit",className:"opacity-50 text-black",fontSize:"small"})})}},86625:(e,s,t)=>{"use strict";var a=t(24994);s.A=void 0;var l=a(t(44888)),r=t(74848);s.A=(0,l.default)((0,r.jsx)("path",{d:"M16.62 2.99c-.49-.49-1.28-.49-1.77 0L6.54 11.3c-.39.39-.39 1.02 0 1.41l8.31 8.31c.49.49 1.28.49 1.77 0s.49-1.28 0-1.77L9.38 12l7.25-7.25c.48-.48.48-1.28-.01-1.76"}),"ArrowBackIosRounded")},52691:(e,s,t)=>{"use strict";t.r(s),t.d(s,{MediaContext:()=>y,__N_SSP:()=>g,default:()=>_});var a=t(74848),l=t(96540),r=t(51187),i=t(67764),n=t(45332),d=t(84003),o=t(5531),c=t(99862),u=t(4709),x=t(45165),j=t(55624),p=t(53301),h=t(60557),m=t(96228);function f(e){var s;let{media:t,setTargetMedia:r,user:i,folders:n,query:d,staticHost:o,folder:f}=l.useContext(y);return(0,a.jsxs)(l.Fragment,{children:[(0,a.jsxs)("div",{className:"flex-col items-start gap-0 w-full",children:[(0,a.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)(c.A,{}),(0,a.jsx)(m.A,{className:"opacity-40"}),(0,a.jsx)("h1",{className:"text-3xl m-0",children:d.folder[d.folder.length-1]})]}),(0,a.jsxs)(h.A,{children:[(0,a.jsxs)("button",{className:"flex items-center gap-2",onClick:e=>{(0,x.PB)("choose-media-type-popoup")},children:[(0,a.jsx)("span",{className:"symbol",children:"+"}),(0,a.jsx)("span",{children:"Add Media"})]}),(0,a.jsxs)("button",{className:"flex items-center gap-2 outlined gray",onClick:e=>{(0,x.PB)("add-folder-popoup",e=>{var s;null==e||null===(s=e.querySelector("input"))||void 0===s||s.focus()})},children:[(0,a.jsx)("span",{className:"symbol",children:"+"}),(0,a.jsx)("span",{children:"Add Folder"})]})]})]}),(0,a.jsx)(u.A,{user:i})]}),(null==i?void 0:null===(s=i.verification_status)||void 0===s?void 0:s.toString().match(/1/))?(0,a.jsxs)(l.Fragment,{children:[(0,a.jsx)(p.A,{media:t,setTargetMedia:r,folders:n,folder:f,staticHost:o,user:i}),t&&t[0]&&(0,a.jsxs)("a",{className:"border-dotted border-slate-400 border-2 px-4 py-3 w-full rounded flex items-center hover:border-primary/50 gap-2 cursor-pointer justify-center",onClick:e=>{(0,x.PB)("choose-media-type-popoup")},children:[(0,a.jsx)("span",{className:"symbol",children:"+"}),(0,a.jsx)("span",{className:"",children:"Add Media"})]})]}):(0,a.jsx)(j.A,{})]})}var N=t(11493),w=t(65001),A=t(620),v=t(22154),g=!0;let y=l.createContext({});function _(e){let{user:s,media:t,folders:c,query:u,staticHost:x,folderNameFull:j}=e,p=(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("title",{children:"User Dashboard | Datasquirel"}),(0,a.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),[h,m]=l.useState(null),[g,_]=l.useState(null),[b,k]=l.useState(null),[M,S]=l.useState(!1),[C,F]=l.useState(null);return(0,a.jsx)(r.A,{head:p,user:s,children:(0,a.jsxs)(y.Provider,{value:{user:s,media:t,targetMedia:C,setTargetMedia:F,folders:c,query:u,staticHost:x,folder:j},children:[M&&(0,a.jsx)(A.A,{screen:!0,title:"Processing Files ..."}),(0,a.jsx)(f,{}),(0,a.jsx)(i.A,{setNewMedia:m,setLoading:S}),(0,a.jsx)(N.A,{setNewFile:_,setLoading:S}),(0,a.jsx)(v.A,{setNewVideo:k,setLoading:S}),(0,a.jsx)(n.A,{newMedia:h,setNewMedia:m,newFile:g,setNewFile:_,folder:j,newVideo:b,setNewVideo:k}),(0,a.jsx)(d.A,{targetMedia:C,staticHost:x,setTargetMedia:F,media:t}),(0,a.jsx)(o.A,{folder:j}),(0,a.jsx)(w.A,{user:s})]})})}}},e=>{var s=s=>e(e.s=s);e.O(0,[9799,4750,636,6593,8792],()=>s(99186)),_N_E=e.O()}]);
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3681],{63367:(e,s,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/users/databases",function(){return a(34222)}])},99862:(e,s,a)=>{"use strict";a.d(s,{A:()=>r});var l=a(74848);a(96540);var t=a(86625);function r(){return(0,l.jsx)("button",{className:"outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full",onClick:e=>{window.history.back()},children:(0,l.jsx)(t.A,{color:"inherit",className:"opacity-50 text-black",fontSize:"small"})})}},45165:(e,s,a)=>{"use strict";a.d(s,{Ay:()=>n,PB:()=>c,fs:()=>i});var l=a(74848),t=a(76897),r=a(96540);function n(e){let{children:s,title:a,data:n,fullPage:c,wrapperClasses:d,closePopupDispatch:o,wrapperStyle:u,noContainer:p}=e;return c?(0,l.jsxs)("div",{className:"popup-bg overflow-hidden "+(d||""),"data-popupid":a||null,style:u,children:[p?(0,l.jsx)(r.Fragment,{children:s}):(0,l.jsx)("div",{className:"relative w-full h-full z-50","data-data":n?JSON.stringify(n):"",children:s}),(0,l.jsx)("button",{className:"popup-cancel-button fixed outlined gray",onClick:e=>{i(),o&&o()},children:(0,l.jsx)(t.A,{color:"white",size:20})}),(0,l.jsx)("div",{className:"popup-canceller",onClick:e=>{i(),o&&o()}})]}):(0,l.jsxs)("div",{className:"popup-bg","data-popupid":a||null,children:[p?(0,l.jsx)(r.Fragment,{children:s}):(0,l.jsxs)("div",{className:"popup-content-container minimal-scrollbars","data-data":n?JSON.stringify(n):"",children:[s,(0,l.jsx)("button",{className:"outlined gray popup-cancel-button",onClick:e=>{i(),o&&o()},children:(0,l.jsx)("span",{className:"font-normal",children:"✖"})})]}),p&&(0,l.jsx)("button",{className:"gray popup-cancel-button",onClick:e=>{i(),o&&o()},children:(0,l.jsx)("span",{className:"font-normal",children:"✖"})}),(0,l.jsx)("div",{className:"popup-canceller",onClick:e=>{i(),o&&o()}})]})}function c(e,s){let a=document.querySelector("[data-popupid='".concat(e,"']"));a&&(a.style.display="flex",s&&s(a))}function i(e){document.querySelectorAll("[data-popupid]").forEach(e=>{e.style.display="none"}),e&&e()}},86625:(e,s,a)=>{"use strict";var l=a(24994);s.A=void 0;var t=l(a(44888)),r=a(74848);s.A=(0,t.default)((0,r.jsx)("path",{d:"M16.62 2.99c-.49-.49-1.28-.49-1.77 0L6.54 11.3c-.39.39-.39 1.02 0 1.41l8.31 8.31c.49.49 1.28.49 1.77 0s.49-1.28 0-1.77L9.38 12l7.25-7.25c.48-.48.48-1.28-.01-1.76"}),"ArrowBackIosRounded")},94909:(e,s,a)=>{"use strict";a.d(s,{A:()=>l});let l=(0,a(95737).A)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]])},34222:(e,s,a)=>{"use strict";a.r(s),a.d(s,{AllDatabasesUsersContext:()=>p,__N_SSP:()=>u,default:()=>x});var l=a(74848),t=a(96540),r=a(51187),n=a(80443),c=a(4709);function i(e){let{databases:s,user:a}=e;return(0,l.jsx)(t.Fragment,{children:(0,l.jsxs)("section",{className:"p-4 items-start gap-4 overflow-visible",children:[(0,l.jsx)("h2",{className:"text-xl m-0",children:"Database Users"}),(0,l.jsx)("div",{className:"flex flex-wrap gap-6",children:s&&s[0]?s.map((e,s)=>(0,l.jsxs)("a",{href:"/admin/".concat(null==a?void 0:a.id,"/users/databases/").concat(e.db_slug),className:"border border-slate-200 border-solid rounded px-6 py-4 hover:border-primary flex items-center gap-2",children:[(0,l.jsx)("img",{src:e.db_image,className:"w-8 h-8 rounded-full object-cover",alt:""}),e.db_name]},s+1)):(0,l.jsx)("span",{children:"No Databases Yet"})})]})})}var d=a(99862);function o(e){let{databases:s,user:a}=t.useContext(p);return(0,l.jsxs)(t.Fragment,{children:[(0,l.jsxs)("div",{className:"flex-col items-start gap-0 w-full",children:[(0,l.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,l.jsxs)("div",{children:[(0,l.jsx)(d.A,{}),(0,l.jsx)("h1",{className:"text-3xl m-0",children:"All Databases Users"})]}),(0,l.jsxs)("a",{href:"/admin/".concat(null==a?void 0:a.id,"/users/add-user"),className:"flex items-center gap-2 whitespace-normal button",children:[(0,l.jsx)("span",{className:"symbol",children:"+"}),(0,l.jsx)("span",{children:"Add New User"})]})]}),(0,l.jsx)(c.A,{user:a})]}),(0,l.jsx)(i,{databases:s,user:a})]})}var u=!0;let p=t.createContext({});function x(e){let{user:s,users:a,databases:c}=e,i=(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("title",{children:"Users | Datasquirel"}),(0,l.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),[d,u]=t.useState(null),[x,m]=t.useState(null);return(0,l.jsx)(r.A,{head:i,user:s,children:(0,l.jsxs)(p.Provider,{value:{user:s,users:a,targetUser:x,setTargetUser:m,databases:c},children:[(0,l.jsx)(o,{}),(0,l.jsx)(n.A,{targetUser:x,user:s,setTargetUser:m})]})})}}},e=>{var s=s=>e(e.s=s);e.O(0,[9799,6946,636,6593,8792],()=>s(63367)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9334],{42065:function(e,s,a){"use strict";var n=a(64836);s.Z=void 0;var t=n(a(64938)),r=a(85893),l=(0,t.default)((0,r.jsx)("path",{d:"M16.62 2.99c-.49-.49-1.28-.49-1.77 0L6.54 11.3c-.39.39-.39 1.02 0 1.41l8.31 8.31c.49.49 1.28.49 1.77 0s.49-1.28 0-1.77L9.38 12l7.25-7.25c.48-.48.48-1.28-.01-1.76z"}),"ArrowBackIosRounded");s.Z=l},69594:function(e,s,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/[user_id]/users/databases",function(){return a(23666)}])},61781:function(e,s,a){"use strict";a.d(s,{Z:function(){return r}});var n=a(85893),t=(a(67294),a(42065));function r(){return(0,n.jsx)("button",{className:"outlined gray p-2 w-9 h-9 flex items-center justify-center rounded-full",onClick:function(e){window.history.back()},children:(0,n.jsx)(t.Z,{color:"inherit",className:"opacity-50 text-black",fontSize:"small"})})}},25472:function(e,s,a){"use strict";a.d(s,{Mw:function(){return c},ZP:function(){return l},j4:function(){return i}});var n=a(85893),t=a(41352),r=a(67294);function l(e){var s=e.children,a=e.title,l=e.data,c=e.fullPage,o=e.wrapperClasses,u=e.closePopupDispatch,d=e.wrapperStyle,p=e.noContainer;return c?(0,n.jsxs)("div",{className:"popup-bg overflow-hidden "+(o||""),"data-popupid":a||null,style:d,children:[p?(0,n.jsx)(r.Fragment,{children:s}):(0,n.jsx)("div",{className:"relative w-full h-full z-50","data-data":l?JSON.stringify(l):"",children:s}),(0,n.jsx)("button",{className:"popup-cancel-button fixed outlined gray",onClick:function(e){i(),u&&u()},children:(0,n.jsx)(t.Z,{color:"white",size:20})}),(0,n.jsx)("div",{className:"popup-canceller",onClick:function(e){i(),u&&u()}})]}):(0,n.jsxs)("div",{className:"popup-bg","data-popupid":a||null,children:[p?(0,n.jsx)(r.Fragment,{children:s}):(0,n.jsxs)("div",{className:"popup-content-container minimal-scrollbars","data-data":l?JSON.stringify(l):"",children:[s,(0,n.jsx)("button",{className:"outlined gray popup-cancel-button",onClick:function(e){i(),u&&u()},children:(0,n.jsx)("span",{className:"font-normal",children:"\u2716"})})]}),p&&(0,n.jsx)("button",{className:"gray popup-cancel-button",onClick:function(e){i(),u&&u()},children:(0,n.jsx)("span",{className:"font-normal",children:"\u2716"})}),(0,n.jsx)("div",{className:"popup-canceller",onClick:function(e){i(),u&&u()}})]})}function c(e,s){var a=document.querySelector("[data-popupid='".concat(e,"']"));a&&(a.style.display="flex",s&&s(a))}function i(e){document.querySelectorAll("[data-popupid]").forEach((function(e){e.style.display="none"})),e&&e()}},23666:function(e,s,a){"use strict";a.r(s),a.d(s,{AllDatabasesUsersContext:function(){return x},__N_SSP:function(){return f},default:function(){return m}});var n=a(828),t=a(85893),r=a(67294),l=a(54858),c=a(9417),i=a(424);function o(e){var s=e.databases,a=e.user;return(0,t.jsx)(r.Fragment,{children:(0,t.jsxs)("section",{className:"p-4 items-start gap-4 overflow-visible",children:[(0,t.jsx)("h2",{className:"text-xl m-0",children:"Database Users"}),(0,t.jsx)("div",{className:"flex flex-wrap gap-6",children:s&&s[0]?s.map((function(e,s){return(0,t.jsxs)("a",{href:"/admin/".concat(null===a||void 0===a?void 0:a.id,"/users/databases/").concat(e.db_slug),className:"border border-slate-200 border-solid rounded px-6 py-4 hover:border-primary flex items-center gap-2",children:[(0,t.jsx)("img",{src:e.db_image,className:"w-8 h-8 rounded-full object-cover",alt:""}),e.db_name]},s+1)})):(0,t.jsx)("span",{children:"No Databases Yet"})})]})})}var u=a(61781);function d(e){var s=r.useContext(x),a=s.databases,n=s.user;return(0,t.jsxs)(r.Fragment,{children:[(0,t.jsxs)("div",{className:"flex-col items-start gap-0 w-full",children:[(0,t.jsxs)("div",{className:"w-full justify-between flex-wrap",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(u.Z,{}),(0,t.jsx)("h1",{className:"text-3xl m-0",children:"All Databases Users"})]}),(0,t.jsxs)("a",{href:"/admin/".concat(null===n||void 0===n?void 0:n.id,"/users/add-user"),className:"flex items-center gap-2 whitespace-normal button",children:[(0,t.jsx)("span",{className:"symbol",children:"+"}),(0,t.jsx)("span",{children:"Add New User"})]})]}),(0,t.jsx)(i.Z,{user:n})]}),(0,t.jsx)(o,{databases:a,user:n})]})}var p={},f=!0,x=r.createContext(p);function m(e){var s=e.user,a=e.users,i=e.databases,o=(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("title",{children:"Users | Datasquirel"}),(0,t.jsx)("meta",{name:"description",content:"Welcome to your data app"})]}),u=(0,n.Z)(r.useState(null),2),p=(u[0],u[1],(0,n.Z)(r.useState(null),2)),f=p[0],m=p[1];return(0,t.jsx)(l.Z,{head:o,user:s,children:(0,t.jsxs)(x.Provider,{value:{user:s,users:a,targetUser:f,setTargetUser:m,databases:i},children:[(0,t.jsx)(d,{}),(0,t.jsx)(c.Z,{targetUser:f,user:s,setTargetUser:m})]})})}}},function(e){e.O(0,[9365,5949,9774,2888,179],(function(){return s=69594,e(e.s=s);var s}));var s=e.O();_N_E=s}]);
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9892],{26669:(n,u,e)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/blog",function(){return e(27031)}])},27031:(n,u,e)=>{"use strict";e.r(u),e.d(u,{default:()=>_}),e(74848);var t=e(96540);function _(){return t.useEffect(()=>{window.location.href="https://datasquirel.com"},[]),null}e(96411),e(93444)}},n=>{var u=u=>n(n.s=u);n.O(0,[636,6593,8792],()=>u(26669)),_N_E=n.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9195],{46055:function(n,u,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/blog",function(){return t(51384)}])},51384:function(n,u,t){"use strict";t.r(u),t.d(u,{default:function(){return r}});t(85893);var o=t(67294);t(24097);t(56217);function r(){return o.useEffect((function(){window.location.href="https://datasquirel.com"}),[]),null}}},function(n){n.O(0,[9774,2888,179],(function(){return u=46055,n(n.s=u);var u}));var u=n.O();_N_E=u}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9335],{78367:function(n,t,e){(window.__NEXT_P=window.__NEXT_P||[]).push(["/contact",function(){return e(9144)}])},97037:function(n,t,e){"use strict";e.d(t,{Z:function(){return s}});var r=e(85893);e(67294);function s(n){var t=n.message;return(0,r.jsxs)("div",{className:"p-2 bg-orange-50 w-full justify-center rounded text-sm text-orange-700 border border-orange-400 border-solid",children:[(0,r.jsx)("img",{src:"/images/warning.png",alt:"Warning Image Icon",width:22,className:"-my-2"}),(0,r.jsx)("span",{children:t})]})}},82186:function(n,t,e){"use strict";e.d(t,{Z:function(){return s}});var r=e(85893);e(67294);function s(n){var t=n.message,e=n.className;return(0,r.jsxs)("div",{className:"info green"+(e?" "+e:""),children:[(0,r.jsx)("img",{src:"/images/checkmark.svg",alt:"Warning Image Icon",width:22,className:"-my-2"}),(0,r.jsx)("span",{children:t})]})}},9922:function(n,t,e){"use strict";e.d(t,{Z:function(){return s}});var r=e(86729);function s(n){var t=n.setUser,e=localStorage.getItem("user");if(e)try{return void t(JSON.parse(e))}catch(s){return void t({})}(0,r.Z)("/api/clientSideAuth",{method:"post",body:{}},!0).then((function(n){var e=n.user?n.user:{};t(e),localStorage.setItem("user",JSON.stringify(e))})).catch((function(n){console.log(n)}))}},9144:function(n,t,e){"use strict";e.r(t),e.d(t,{HomepageContext:function(){return c},default:function(){return a}});e(828),e(85893);var r=e(67294);e(56217),e(24097),e(9922);e(86729),e(97037),e(82186),e(95264);var s={},c=r.createContext(s);function a(n){return r.useEffect((function(){window.location.href="https://datasquirel.com/contact"}),[]),null}}},function(n){n.O(0,[9774,2888,179],(function(){return t=78367,n(n.s=t);var t}));var t=n.O();_N_E=t}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1364],{410:(e,t,r)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/contact",function(){return r(38020)}])},41696:(e,t,r)=>{"use strict";r.d(t,{A:()=>s});var n=r(74848);function s(e){let{message:t}=e;return(0,n.jsxs)("div",{className:"p-2 bg-orange-50 w-full justify-center rounded text-sm text-orange-700 border border-orange-400 border-solid",children:[(0,n.jsx)("img",{src:"/images/warning.png",alt:"Warning Image Icon",width:22,className:"-my-2"}),(0,n.jsx)("span",{children:t})]})}r(96540)},70385:(e,t,r)=>{"use strict";r.d(t,{A:()=>s});var n=r(74848);function s(e){let{message:t,className:r}=e;return(0,n.jsxs)("div",{className:"info green"+(r?" "+r:""),children:[(0,n.jsx)("img",{src:"/images/checkmark.svg",alt:"Warning Image Icon",width:22,className:"-my-2"}),(0,n.jsx)("span",{children:t})]})}r(96540)},62900:(e,t,r)=>{"use strict";r.d(t,{A:()=>s});var n=r(23698);function s(e){let{setUser:t}=e,r=localStorage.getItem("user");if(r)try{t(JSON.parse(r));return}catch(e){t({});return}(0,n.A)("/api/clientSideAuth",{method:"post",body:{}},!0).then(e=>{let r=e.user?e.user:{};t(r),localStorage.setItem("user",JSON.stringify(r))}).catch(e=>{console.log(e)})}},38020:(e,t,r)=>{"use strict";r.r(t),r.d(t,{HomepageContext:()=>s,default:()=>a}),r(74848);var n=r(96540);r(93444),r(96411),r(62900),r(23698),r(41696),r(70385),r(620);let s=n.createContext({});function a(e){return n.useEffect(()=>{window.location.href="https://datasquirel.com/contact"},[]),null}}},e=>{var t=t=>e(e.s=t);e.O(0,[636,6593,8792],()=>t(410)),_N_E=e.O()}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8810],{29222:(e,t,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/create-account",function(){return a(57029)}])},87291:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var s=a(74848);a(96540);var i=a(620);function n(){return(0,s.jsx)("div",{className:"flex flex-col gap-4 items-center justify-center w-full h-screen p-6 bg-slate-100",children:(0,s.jsxs)("div",{className:"flex flex-col items-center justify-center gap-4 px-6 py-20 bg-white rounded shadow-sm max-w-2xl w-full",children:[(0,s.jsx)("img",{src:"/images/logo-icon-alt-2.webp",alt:"Datasquirel Logo",width:60}),(0,s.jsx)("div",{className:"w-10 h-10 flex flex-col items-center justify-center",children:(0,s.jsx)(i.A,{width:"25px",position:"relative"})})]})})}},57029:(e,t,a)=>{"use strict";a.r(t),a.d(t,{CreateAccountContext:()=>x,__N_SSP:()=>d,default:()=>m});var s=a(74848),i=a(96540),n=a(93444),l=a(96411),r=a(84147);function c(e){let{query:t,invitingUser:a}=i.useContext(x);return(0,s.jsxs)("section",{className:"flex-col items-center lg:items-center gap-20 p-0",children:[(0,s.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-80 dark:opacity-10 z-0"}),(0,s.jsxs)("div",{className:"w-full lg:w-1/2 max-w-6xl gap-4 flex-col items-center px-4 py-10 bg-white dark:bg-slate-900 relative z-10",children:[(null==a?void 0:a.first_name)&&(0,s.jsxs)("span",{className:"text-xs bg-emerald-100 rounded-full px-4 py-1 mb-4",children:["You have been invited by"," ",(0,s.jsxs)("b",{children:[a.first_name," ",a.last_name," (",a.email,")"]})," ","to manage an account. Please create an account to gain access."]}),(0,s.jsx)("h1",{className:"m-0 text-center text-2xl",children:"Create An Account"}),(0,s.jsx)(r.A,{query:t})]})]})}a(61638),a(620);var o=a(23698),u=a(87291),d=!0;let x=i.createContext({});function m(e){var t;let a="Create Account | Datasquirel",r="Create a FREE account and start storing data.",d=(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("title",{children:a}),(0,s.jsx)("meta",{name:"description",content:r}),(0,s.jsx)(l.A,{pageTitle:a,pageDescription:r,pagePathname:"/"})]}),[m,h]=i.useState(null);return(i.useEffect(()=>{var t;(null===(t=e.query)||void 0===t?void 0:t.invite)&&!e.isAuthCookie&&setTimeout(()=>{(0,o.A)("/api/addAdminUserUser",{method:"POST",body:{query:e.query}},!0).then(t=>{var a;window.location.pathname="/admin/".concat(null===(a=e.user)||void 0===a?void 0:a.id,"/users")})},1e3)},[]),null===(t=e.query)||void 0===t?void 0:t.invite)?(0,s.jsx)(u.A,{}):(0,s.jsx)(n.A,{head:d,children:(0,s.jsx)(x.Provider,{value:{user:m,query:e.query,invitingUser:e.invitingUser},children:(0,s.jsx)("main",{children:(0,s.jsx)(c,{})})})})}}},e=>{var t=t=>e(e.s=t);e.O(0,[9907,4147,636,6593,8792],()=>t(29222)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7398],{93125:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/create-account",function(){return n(18214)}])},26478:function(e,t,n){"use strict";n.d(t,{Z:function(){return s}});var i=n(85893),a=(n(67294),n(95264));function s(){return(0,i.jsx)("div",{className:"flex flex-col gap-4 items-center justify-center w-full h-screen p-6 bg-slate-100",children:(0,i.jsxs)("div",{className:"flex flex-col items-center justify-center gap-4 px-6 py-20 bg-white rounded shadow-sm max-w-2xl w-full",children:[(0,i.jsx)("img",{src:"/images/logo-icon-alt-2.webp",alt:"Datasquirel Logo",width:60}),(0,i.jsx)("div",{className:"w-10 h-10 flex flex-col items-center justify-center",children:(0,i.jsx)(a.Z,{width:"25px",position:"relative"})})]})})}},18214:function(e,t,n){"use strict";n.r(t),n.d(t,{CreateAccountContext:function(){return m},__N_SSP:function(){return f},default:function(){return h}});var i=n(828),a=n(85893),s=n(67294),r=n(56217),c=n(24097),l=n(65114);function o(e){var t=s.useContext(m),n=t.query,i=t.invitingUser;return(0,a.jsxs)("section",{className:"flex-col items-center lg:items-center gap-20 p-0",children:[(0,a.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-80 dark:opacity-10 z-0"}),(0,a.jsxs)("div",{className:"w-full lg:w-1/2 max-w-6xl gap-4 flex-col items-center px-4 py-10 bg-white dark:bg-slate-900 relative z-10",children:[(null===i||void 0===i?void 0:i.first_name)&&(0,a.jsxs)("span",{className:"text-xs bg-emerald-100 rounded-full px-4 py-1 mb-4",children:["You have been invited by"," ",(0,a.jsxs)("b",{children:[i.first_name," ",i.last_name," (",i.email,")"]})," ","to manage an account. Please create an account to gain access."]}),(0,a.jsx)("h1",{className:"m-0 text-center text-2xl",children:"Create An Account"}),(0,a.jsx)(l.Z,{query:n})]})]})}n(64017),n(95264);var u=n(86729),d=n(26478),x={},f=!0,m=s.createContext(x);function h(e){var t,n="Create Account | Datasquirel",l="Create a FREE account and start storing data.",x=(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("title",{children:n}),(0,a.jsx)("meta",{name:"description",content:l}),(0,a.jsx)(c.Z,{pageTitle:n,pageDescription:l,pagePathname:"/"})]}),f=(0,i.Z)(s.useState(null),2),h=f[0];f[1];return s.useEffect((function(){var t;(null===(t=e.query)||void 0===t?void 0:t.invite)&&!e.isAuthCookie&&setTimeout((function(){(0,u.Z)("/api/addAdminUserUser",{method:"POST",body:{query:e.query}},!0).then((function(t){var n;window.location.pathname="/admin/".concat(null===(n=e.user)||void 0===n?void 0:n.id,"/users")}))}),1e3)}),[]),(null===(t=e.query)||void 0===t?void 0:t.invite)?(0,a.jsx)(d.Z,{}):(0,a.jsx)(r.Z,{head:x,children:(0,a.jsx)(m.Provider,{value:{user:h,query:e.query,invitingUser:e.invitingUser},children:(0,a.jsx)("main",{children:(0,a.jsx)(o,{})})})})}}},function(e){e.O(0,[8374,5114,9774,2888,179],(function(){return t=93125,e(e.s=t);var t}));var t=e.O();_N_E=t}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7797],{26347:(e,t,s)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs",function(){return s(92022)}])},34540:(e,t,s)=>{"use strict";s.d(t,{A:()=>r});var l=s(74848),a=s(96540);function r(e){let{pages:t}=e;if(!t||!t[0])return null;let s=null==t?void 0:t.filter(e=>1==e.level);return a.useEffect(()=>{let e=document.querySelectorAll("aside a");e&&e[0]&&e.forEach(e=>{e.pathname===window.location.pathname&&e.classList.add("active")})},[]),(0,l.jsxs)("aside",{className:"w-full lg:w-80 p-10 bg-slate-100 dark:bg-slate-800 sticky top-0 overflow-y-auto max-h-max lg:max-h-screen transition-all",children:[(0,l.jsx)("span",{className:"text-2xl m-0 mb-4 text-left font-semibold",children:"Docs"}),(0,l.jsx)("ul",{className:"pl-4 gap-4 flex flex-col items-start",children:function e(s,a){return s.map((s,r)=>{let c="".concat(a,"/").concat(s.slug),i=t.filter(e=>2==e.level&&e.parent_id==s.id);return(0,l.jsxs)("li",{children:[(0,l.jsx)("a",{href:c,className:(null==s?void 0:s.level)==1?"font-semibold":"text-slate-600",children:s.title}),i&&i[0]&&(0,l.jsx)("ul",{className:"pl-4 gap-2 flex flex-col items-start text-sm mt-2",children:e(i,c)})]},r)})}(s,"/docs")})]})}},62900:(e,t,s)=>{"use strict";s.d(t,{A:()=>a});var l=s(23698);function a(e){let{setUser:t}=e,s=localStorage.getItem("user");if(s)try{t(JSON.parse(s));return}catch(e){t({});return}(0,l.A)("/api/clientSideAuth",{method:"post",body:{}},!0).then(e=>{let s=e.user?e.user:{};t(s),localStorage.setItem("user",JSON.stringify(s))}).catch(e=>{console.log(e)})}},92022:(e,t,s)=>{"use strict";s.r(t),s.d(t,{__N_SSP:()=>x,default:()=>f});var l=s(74848),a=s(96540),r=s(93444),c=s(96411),i=s(62900),n=s(34540);function o(e){return(0,l.jsxs)("section",{className:"py-14",children:[(0,l.jsx)("div",{className:"w-full gap-10 justify-between flex-col lg:flex-row relative z-10",children:(0,l.jsxs)("div",{className:"flex-col items-center lg:items-start max-w-lg text-center lg:text-left",style:{minWidth:"45%"},children:[(0,l.jsx)("h1",{className:"text-2xl m-0 leading-tight",children:"Documentation"}),(0,l.jsx)("span",{className:"font-normal",children:"Learn the ins and outs of datasquirel."})]})}),(0,l.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-5 z-0"})]})}var d=s(62027);function u(e){let{title:t,description:s,url:a}=e;return(0,l.jsxs)("a",{href:a,className:"card",children:[(0,l.jsxs)("div",{className:"flex-col items-start",children:[(0,l.jsx)("span",{className:"text-2xl font-semibold",children:t}),(0,l.jsx)("span",{className:"max-w-md text-slate-600",children:s})]}),(0,l.jsx)(d.A,{size:20})]})}function m(e){return(0,l.jsx)("section",{className:"py-14",children:(0,l.jsxs)("div",{className:"grid grid-cols-1 sl:grid-cols-2 gap-4 w-full items-stretch",children:[(0,l.jsx)(u,{title:"Quick Start Guide",description:"Get Started.",url:"/docs/quick-start"}),(0,l.jsx)(u,{title:"GUI Reference",description:"Learn how to complete basic data tasks from your dashboard",url:"/docs/gui-reference"}),(0,l.jsx)(u,{title:"API Reference",description:"Interact with your database from a backend server using REST API",url:"/docs/api-reference"})]})})}var x=!0;function f(e){let{pages:t,targetPage:s}=e,d="".concat(s.title," | Datasquirel docs"),u=s.description,x=(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("title",{children:d}),(0,l.jsx)("meta",{name:"description",content:u}),(0,l.jsx)(c.A,{pageTitle:d,pageDescription:u,pagePathname:"/"})]}),[f,h]=a.useState(null);return a.useEffect(()=>{(0,i.A)({setUser:h})},[]),(0,l.jsx)(r.A,{head:x,user:f,children:(0,l.jsxs)("div",{className:"items-stretch w-full gap-0 flex-col-reverse lg:flex-row",children:[(0,l.jsx)(n.A,{pages:t}),(0,l.jsxs)("main",{children:[(0,l.jsx)(o,{}),(0,l.jsx)(m,{})]})]})})}}},e=>{var t=t=>e(e.s=t);e.O(0,[636,6593,8792],()=>t(26347)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3172],{34475:function(e,t,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs",function(){return s(1732)}])},26e3:function(e,t,s){"use strict";s.d(t,{Z:function(){return r}});var n=s(85893),a=s(67294);function r(e){var t=e.pages;if(!t||!t[0])return null;var s=null===t||void 0===t?void 0:t.filter((function(e){return 1==e.level}));return a.useEffect((function(){var e=document.querySelectorAll("aside a");e&&e[0]&&e.forEach((function(e){e.pathname===window.location.pathname&&e.classList.add("active")}))}),[]),(0,n.jsxs)("aside",{className:"w-full lg:w-80 p-10 bg-slate-100 dark:bg-slate-800 sticky top-0 overflow-y-auto max-h-max lg:max-h-screen transition-all",children:[(0,n.jsx)("span",{className:"text-2xl m-0 mb-4 text-left font-semibold",children:"Docs"}),(0,n.jsx)("ul",{className:"pl-4 gap-4 flex flex-col items-start",children:function e(s,a){return s.map((function(s,r){var l="".concat(a,"/").concat(s.slug),i=t.filter((function(e){return 2==e.level&&e.parent_id==s.id}));return(0,n.jsxs)("li",{children:[(0,n.jsx)("a",{href:l,className:1==(null===s||void 0===s?void 0:s.level)?"font-semibold":"text-slate-600",children:s.title}),i&&i[0]&&(0,n.jsx)("ul",{className:"pl-4 gap-2 flex flex-col items-start text-sm mt-2",children:e(i,l)})]},r)}))}(s,"/docs")})]})}},9922:function(e,t,s){"use strict";s.d(t,{Z:function(){return a}});var n=s(86729);function a(e){var t=e.setUser,s=localStorage.getItem("user");if(s)try{return void t(JSON.parse(s))}catch(a){return void t({})}(0,n.Z)("/api/clientSideAuth",{method:"post",body:{}},!0).then((function(e){var s=e.user?e.user:{};t(s),localStorage.setItem("user",JSON.stringify(s))})).catch((function(e){console.log(e)}))}},1732:function(e,t,s){"use strict";s.r(t),s.d(t,{__N_SSP:function(){return x},default:function(){return h}});var n=s(828),a=s(85893),r=s(67294),l=s(56217),i=s(24097),c=s(9922),o=s(26e3);function u(e){return(0,a.jsxs)("section",{className:"py-14",children:[(0,a.jsx)("div",{className:"w-full gap-10 justify-between flex-col lg:flex-row relative z-10",children:(0,a.jsxs)("div",{className:"flex-col items-center lg:items-start max-w-lg text-center lg:text-left",style:{minWidth:"45%"},children:[(0,a.jsx)("h1",{className:"text-2xl m-0 leading-tight",children:"Documentation"}),(0,a.jsx)("span",{className:"font-normal",children:"Learn the ins and outs of datasquirel."})]})}),(0,a.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-5 z-0"})]})}var d=s(8971);function f(e){var t=e.title,s=e.description,n=e.url;return(0,a.jsxs)("a",{href:n,className:"card",children:[(0,a.jsxs)("div",{className:"flex-col items-start",children:[(0,a.jsx)("span",{className:"text-2xl font-semibold",children:t}),(0,a.jsx)("span",{className:"max-w-md text-slate-600",children:s})]}),(0,a.jsx)(d.Z,{size:20})]})}function m(e){return(0,a.jsx)("section",{className:"py-14",children:(0,a.jsxs)("div",{className:"grid grid-cols-1 sl:grid-cols-2 gap-4 w-full items-stretch",children:[(0,a.jsx)(f,{title:"Quick Start Guide",description:"Get Started.",url:"/docs/quick-start"}),(0,a.jsx)(f,{title:"GUI Reference",description:"Learn how to complete basic data tasks from your dashboard",url:"/docs/gui-reference"}),(0,a.jsx)(f,{title:"API Reference",description:"Interact with your database from a backend server using REST API",url:"/docs/api-reference"})]})})}var x=!0;function h(e){var t=e.pages,s=e.targetPage,d="".concat(s.title," | Datasquirel docs"),f=s.description,x=(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("title",{children:d}),(0,a.jsx)("meta",{name:"description",content:f}),(0,a.jsx)(i.Z,{pageTitle:d,pageDescription:f,pagePathname:"/"})]}),h=(0,n.Z)(r.useState(null),2),p=h[0],g=h[1];return r.useEffect((function(){(0,c.Z)({setUser:g})}),[]),(0,a.jsx)(l.Z,{head:x,user:p,children:(0,a.jsxs)("div",{className:"items-stretch w-full gap-0 flex-col-reverse lg:flex-row",children:[(0,a.jsx)(o.Z,{pages:t}),(0,a.jsxs)("main",{children:[(0,a.jsx)(u,{}),(0,a.jsx)(m,{})]})]})})}}},function(e){e.O(0,[9774,2888,179],(function(){return t=34475,e(e.s=t);var t}));var t=e.O();_N_E=t}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3749],{67455:function(t,e,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs/[page]",function(){return n(10203)}])},26e3:function(t,e,n){"use strict";n.d(e,{Z:function(){return l}});var s=n(85893),a=n(67294);function l(t){var e=t.pages;if(!e||!e[0])return null;var n=null===e||void 0===e?void 0:e.filter((function(t){return 1==t.level}));return a.useEffect((function(){var t=document.querySelectorAll("aside a");t&&t[0]&&t.forEach((function(t){t.pathname===window.location.pathname&&t.classList.add("active")}))}),[]),(0,s.jsxs)("aside",{className:"w-full lg:w-80 p-10 bg-slate-100 dark:bg-slate-800 sticky top-0 overflow-y-auto max-h-max lg:max-h-screen transition-all",children:[(0,s.jsx)("span",{className:"text-2xl m-0 mb-4 text-left font-semibold",children:"Docs"}),(0,s.jsx)("ul",{className:"pl-4 gap-4 flex flex-col items-start",children:function t(n,a){return n.map((function(n,l){var r="".concat(a,"/").concat(n.slug),i=e.filter((function(t){return 2==t.level&&t.parent_id==n.id}));return(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:r,className:1==(null===n||void 0===n?void 0:n.level)?"font-semibold":"text-slate-600",children:n.title}),i&&i[0]&&(0,s.jsx)("ul",{className:"pl-4 gap-2 flex flex-col items-start text-sm mt-2",children:t(i,r)})]},l)}))}(n,"/docs")})]})}},99350:function(t,e,n){"use strict";n.d(e,{Z:function(){return a}});var s=n(85893);n(67294);function a(t){var e=t.title,n=t.description;return(0,s.jsxs)("section",{className:"py-14",children:[(0,s.jsx)("div",{className:"w-full gap-10 justify-between items-start flex-col lg:flex-row relative z-10",children:(0,s.jsxs)("div",{className:"flex-col items-start max-w-[740px] text-left",style:{minWidth:"45%"},children:[(0,s.jsx)("h1",{className:"m-0 leading-tight",children:e}),(0,s.jsx)("span",{className:"font-normal text-xl -my-4",dangerouslySetInnerHTML:{__html:n}})]})}),(0,s.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-5 z-0"})]})}},9922:function(t,e,n){"use strict";n.d(e,{Z:function(){return a}});var s=n(86729);function a(t){var e=t.setUser,n=localStorage.getItem("user");if(n)try{return void e(JSON.parse(n))}catch(a){return void e({})}(0,s.Z)("/api/clientSideAuth",{method:"post",body:{}},!0).then((function(t){var n=t.user?t.user:{};e(n),localStorage.setItem("user",JSON.stringify(n))})).catch((function(t){console.log(t)}))}},10203:function(t,e,n){"use strict";n.r(e),n.d(e,{__N_SSG:function(){return l},default:function(){return r}});n(828);var s=n(85893),a=n(67294),l=(n(56217),n(24097),n(9922),n(26e3),n(99350),!0);function r(t){t.pages,t.targetPage;return a.useEffect((function(){window.location.href="https://datasquirel.com/docs/getting-started"}),[]),(0,s.jsx)(a.Fragment,{})}}},function(t){t.O(0,[9774,2888,179],(function(){return e=67455,t(t.s=e);var e}));var e=t.O();_N_E=e}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5151],{5439:(e,t,l)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs/[page]",function(){return l(34052)}])},34540:(e,t,l)=>{"use strict";l.d(t,{A:()=>r});var s=l(74848),a=l(96540);function r(e){let{pages:t}=e;if(!t||!t[0])return null;let l=null==t?void 0:t.filter(e=>1==e.level);return a.useEffect(()=>{let e=document.querySelectorAll("aside a");e&&e[0]&&e.forEach(e=>{e.pathname===window.location.pathname&&e.classList.add("active")})},[]),(0,s.jsxs)("aside",{className:"w-full lg:w-80 p-10 bg-slate-100 dark:bg-slate-800 sticky top-0 overflow-y-auto max-h-max lg:max-h-screen transition-all",children:[(0,s.jsx)("span",{className:"text-2xl m-0 mb-4 text-left font-semibold",children:"Docs"}),(0,s.jsx)("ul",{className:"pl-4 gap-4 flex flex-col items-start",children:function e(l,a){return l.map((l,r)=>{let c="".concat(a,"/").concat(l.slug),n=t.filter(e=>2==e.level&&e.parent_id==l.id);return(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:c,className:(null==l?void 0:l.level)==1?"font-semibold":"text-slate-600",children:l.title}),n&&n[0]&&(0,s.jsx)("ul",{className:"pl-4 gap-2 flex flex-col items-start text-sm mt-2",children:e(n,c)})]},r)})}(l,"/docs")})]})}},85674:(e,t,l)=>{"use strict";l.d(t,{A:()=>a});var s=l(74848);function a(e){let{title:t,description:l}=e;return(0,s.jsxs)("section",{className:"py-14",children:[(0,s.jsx)("div",{className:"w-full gap-10 justify-between items-start flex-col lg:flex-row relative z-10",children:(0,s.jsxs)("div",{className:"flex-col items-start max-w-[740px] text-left",style:{minWidth:"45%"},children:[(0,s.jsx)("h1",{className:"m-0 leading-tight",children:t}),(0,s.jsx)("span",{className:"font-normal text-xl -my-4",dangerouslySetInnerHTML:{__html:l}})]})}),(0,s.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-5 z-0"})]})}l(96540)},62900:(e,t,l)=>{"use strict";l.d(t,{A:()=>a});var s=l(23698);function a(e){let{setUser:t}=e,l=localStorage.getItem("user");if(l)try{t(JSON.parse(l));return}catch(e){t({});return}(0,s.A)("/api/clientSideAuth",{method:"post",body:{}},!0).then(e=>{let l=e.user?e.user:{};t(l),localStorage.setItem("user",JSON.stringify(l))}).catch(e=>{console.log(e)})}},34052:(e,t,l)=>{"use strict";l.r(t),l.d(t,{__N_SSG:()=>r,default:()=>c});var s=l(74848),a=l(96540);l(93444),l(96411),l(62900),l(34540),l(85674);var r=!0;function c(e){let{pages:t,targetPage:l}=e;return a.useEffect(()=>{window.location.href="https://datasquirel.com/docs/getting-started"},[]),(0,s.jsx)(a.Fragment,{})}}},e=>{var t=t=>e(e.s=t);e.O(0,[636,6593,8792],()=>t(5439)),_N_E=e.O()}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1980],{54233:(e,t,l)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs/[page]/[sub-page]",function(){return l(77881)}])},34540:(e,t,l)=>{"use strict";l.d(t,{A:()=>r});var s=l(74848),a=l(96540);function r(e){let{pages:t}=e;if(!t||!t[0])return null;let l=null==t?void 0:t.filter(e=>1==e.level);return a.useEffect(()=>{let e=document.querySelectorAll("aside a");e&&e[0]&&e.forEach(e=>{e.pathname===window.location.pathname&&e.classList.add("active")})},[]),(0,s.jsxs)("aside",{className:"w-full lg:w-80 p-10 bg-slate-100 dark:bg-slate-800 sticky top-0 overflow-y-auto max-h-max lg:max-h-screen transition-all",children:[(0,s.jsx)("span",{className:"text-2xl m-0 mb-4 text-left font-semibold",children:"Docs"}),(0,s.jsx)("ul",{className:"pl-4 gap-4 flex flex-col items-start",children:function e(l,a){return l.map((l,r)=>{let c="".concat(a,"/").concat(l.slug),n=t.filter(e=>2==e.level&&e.parent_id==l.id);return(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:c,className:(null==l?void 0:l.level)==1?"font-semibold":"text-slate-600",children:l.title}),n&&n[0]&&(0,s.jsx)("ul",{className:"pl-4 gap-2 flex flex-col items-start text-sm mt-2",children:e(n,c)})]},r)})}(l,"/docs")})]})}},85674:(e,t,l)=>{"use strict";l.d(t,{A:()=>a});var s=l(74848);function a(e){let{title:t,description:l}=e;return(0,s.jsxs)("section",{className:"py-14",children:[(0,s.jsx)("div",{className:"w-full gap-10 justify-between items-start flex-col lg:flex-row relative z-10",children:(0,s.jsxs)("div",{className:"flex-col items-start max-w-[740px] text-left",style:{minWidth:"45%"},children:[(0,s.jsx)("h1",{className:"m-0 leading-tight",children:t}),(0,s.jsx)("span",{className:"font-normal text-xl -my-4",dangerouslySetInnerHTML:{__html:l}})]})}),(0,s.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-5 z-0"})]})}l(96540)},62900:(e,t,l)=>{"use strict";l.d(t,{A:()=>a});var s=l(23698);function a(e){let{setUser:t}=e,l=localStorage.getItem("user");if(l)try{t(JSON.parse(l));return}catch(e){t({});return}(0,s.A)("/api/clientSideAuth",{method:"post",body:{}},!0).then(e=>{let l=e.user?e.user:{};t(l),localStorage.setItem("user",JSON.stringify(l))}).catch(e=>{console.log(e)})}},77881:(e,t,l)=>{"use strict";l.r(t),l.d(t,{__N_SSG:()=>a,default:()=>r}),l(74848);var s=l(96540);l(93444),l(96411),l(62900),l(34540),l(85674);var a=!0;function r(e){let{pages:t,targetPage:l}=e;return s.useEffect(()=>{window.location.href="https://datasquirel.com/docs/getting-started"},[]),null}}},e=>{var t=t=>e(e.s=t);e.O(0,[636,6593,8792],()=>t(54233)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4656],{84477:function(t,e,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs/[page]/[sub-page]",function(){return n(50629)}])},26e3:function(t,e,n){"use strict";n.d(e,{Z:function(){return a}});var s=n(85893),l=n(67294);function a(t){var e=t.pages;if(!e||!e[0])return null;var n=null===e||void 0===e?void 0:e.filter((function(t){return 1==t.level}));return l.useEffect((function(){var t=document.querySelectorAll("aside a");t&&t[0]&&t.forEach((function(t){t.pathname===window.location.pathname&&t.classList.add("active")}))}),[]),(0,s.jsxs)("aside",{className:"w-full lg:w-80 p-10 bg-slate-100 dark:bg-slate-800 sticky top-0 overflow-y-auto max-h-max lg:max-h-screen transition-all",children:[(0,s.jsx)("span",{className:"text-2xl m-0 mb-4 text-left font-semibold",children:"Docs"}),(0,s.jsx)("ul",{className:"pl-4 gap-4 flex flex-col items-start",children:function t(n,l){return n.map((function(n,a){var r="".concat(l,"/").concat(n.slug),i=e.filter((function(t){return 2==t.level&&t.parent_id==n.id}));return(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:r,className:1==(null===n||void 0===n?void 0:n.level)?"font-semibold":"text-slate-600",children:n.title}),i&&i[0]&&(0,s.jsx)("ul",{className:"pl-4 gap-2 flex flex-col items-start text-sm mt-2",children:t(i,r)})]},a)}))}(n,"/docs")})]})}},99350:function(t,e,n){"use strict";n.d(e,{Z:function(){return l}});var s=n(85893);n(67294);function l(t){var e=t.title,n=t.description;return(0,s.jsxs)("section",{className:"py-14",children:[(0,s.jsx)("div",{className:"w-full gap-10 justify-between items-start flex-col lg:flex-row relative z-10",children:(0,s.jsxs)("div",{className:"flex-col items-start max-w-[740px] text-left",style:{minWidth:"45%"},children:[(0,s.jsx)("h1",{className:"m-0 leading-tight",children:e}),(0,s.jsx)("span",{className:"font-normal text-xl -my-4",dangerouslySetInnerHTML:{__html:n}})]})}),(0,s.jsx)("img",{src:"/images/grid.webp",alt:"Dotted image background",className:"absolute top-0 left-0 w-full h-full object-cover opacity-5 z-0"})]})}},9922:function(t,e,n){"use strict";n.d(e,{Z:function(){return l}});var s=n(86729);function l(t){var e=t.setUser,n=localStorage.getItem("user");if(n)try{return void e(JSON.parse(n))}catch(l){return void e({})}(0,s.Z)("/api/clientSideAuth",{method:"post",body:{}},!0).then((function(t){var n=t.user?t.user:{};e(n),localStorage.setItem("user",JSON.stringify(n))})).catch((function(t){console.log(t)}))}},50629:function(t,e,n){"use strict";n.r(e),n.d(e,{__N_SSG:function(){return l},default:function(){return a}});n(828),n(85893);var s=n(67294),l=(n(56217),n(24097),n(9922),n(26e3),n(99350),!0);function a(t){t.pages,t.targetPage;return s.useEffect((function(){window.location.href="https://datasquirel.com/docs/getting-started"}),[]),null}}},function(t){t.O(0,[9774,2888,179],(function(){return e=84477,t(t.s=e);var e}));var e=t.O();_N_E=e}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3540],{89104:(e,n,t)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/docs/test",function(){return t(62763)}])},62763:(e,n,t)=>{"use strict";t.r(n),t.d(n,{default:()=>l});var r=t(74848),s=t(96540);let c=s.createContext({});function o(e){let n=s.useContext(c);return s.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function u(e){let n={code:"code",h1:"h1",pre:"pre",...o(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h1,{children:"Test Page"}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-shell",children:"rsync /test /dest\n"})})]})}function l(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},{wrapper:n}={...o(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(u,{...e})}):u(e)}}},e=>{var n=n=>e(e.s=n);e.O(0,[636,6593,8792],()=>n(89104)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4772],{8558:function(e,n,i){(window.__NEXT_P=window.__NEXT_P||[]).push(["/email-verification",function(){return i(85004)}])},85004:function(e,n,i){"use strict";i.r(n),i.d(n,{__N_SSP:function(){return o},default:function(){return d}});var s=i(828),t=i(85893),a=i(67294),l=(i(9008),i(95264)),c=i(86729),r=i(56217),o=!0;function d(e){var n=e.user,i=e.verified,o=(0,s.Z)(a.useState(!1),2),d=o[0],u=o[1],m=(0,s.Z)(a.useState(null),2),f=m[0],h=m[1];return i?(a.useEffect((function(){try{setTimeout((function(){window.location.pathname="/admin"}),2e3)}catch(e){(0,c.Z)("/api/admin/clientError",{method:"post",body:{component:"email-verification/index-page-component/lines-72-74",message:e.message,user:n}}),window.location.pathname="/logout"}}),[]),(0,t.jsx)(r.Z,{head:(0,t.jsxs)(a.Fragment,{children:[(0,t.jsx)("title",{children:"Verify Email Address"}),(0,t.jsx)("meta",{name:"description",content:"Verify your email address"})]}),user:n,children:(0,t.jsx)("main",{className:"flex items-center justify-center w-full p-8",children:(0,t.jsx)("div",{className:"login-block gap-2",children:(0,t.jsxs)("div",{className:"flex items-center gap-4",children:[(0,t.jsx)("img",{src:"/images/checkmark.svg",alt:"check-mark",width:30}),(0,t.jsx)("span",{className:"text-xl",children:"Email Verification Successfull!"})]})})})})):(0,t.jsx)(a.Fragment,{children:(0,t.jsx)(r.Z,{head:(0,t.jsxs)(a.Fragment,{children:[(0,t.jsx)("title",{children:"Verify Email Address"}),(0,t.jsx)("meta",{name:"description",content:"Verify your email address"})]}),user:n,children:(0,t.jsx)("main",{className:"flex flex-col items-center p-8 justify-center w-full",children:(0,t.jsxs)("div",{className:"login-block gap-2 flex-col max-w-lg",children:[f&&(0,t.jsx)("div",{className:f.class+" w-full rounded py-2 px-4 flex justify-center",children:f.msg}),d&&(0,t.jsx)(l.Z,{position:"absolute"}),(0,t.jsx)("h1",{className:"text-2xl m-0 ",children:"Verify Email Address"}),(0,t.jsx)("span",{children:"Please click the button below to send verification link"}),(0,t.jsx)("button",{className:"w-full",onClick:function(e){e.preventDefault(),u(!0),(0,c.Z)("/api/sendEmailVerificationLink").then((function(e){u(!1),e.success&&h({msg:"Email Sent. Please check mailbox",class:"bg-emerald-100"})}))},children:(0,t.jsx)("span",{children:"Send Verification Link"})}),(0,t.jsx)("button",{className:"w-full outlined",onClick:function(e){window.history.back()},children:(0,t.jsx)("span",{children:"Go Back"})})]})})})})}}},function(e){e.O(0,[9774,2888,179],(function(){return n=8558,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6712],{87869:(e,s,i)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/email-verification",function(){return i(68581)}])},68581:(e,s,i)=>{"use strict";i.r(s),i.d(s,{__N_SSP:()=>r,default:()=>d});var n=i(74848),l=i(96540);i(13368);var a=i(620),c=i(23698),t=i(93444),r=!0;function d(e){let{user:s,verified:i}=e,[r,d]=l.useState(!1),[o,m]=l.useState(null);return i?(l.useEffect(()=>{try{setTimeout(()=>{window.location.pathname="/admin"},2e3)}catch(e){(0,c.A)("/api/admin/clientError",{method:"post",body:{component:"email-verification/index-page-component/lines-72-74",message:e.message,user:s}}),window.location.pathname="/logout"}},[]),(0,n.jsx)(t.A,{head:(0,n.jsxs)(l.Fragment,{children:[(0,n.jsx)("title",{children:"Verify Email Address"}),(0,n.jsx)("meta",{name:"description",content:"Verify your email address"})]}),user:s,children:(0,n.jsx)("main",{className:"flex items-center justify-center w-full p-8",children:(0,n.jsx)("div",{className:"login-block gap-2",children:(0,n.jsxs)("div",{className:"flex items-center gap-4",children:[(0,n.jsx)("img",{src:"/images/checkmark.svg",alt:"check-mark",width:30}),(0,n.jsx)("span",{className:"text-xl",children:"Email Verification Successfull!"})]})})})})):(0,n.jsx)(l.Fragment,{children:(0,n.jsx)(t.A,{head:(0,n.jsxs)(l.Fragment,{children:[(0,n.jsx)("title",{children:"Verify Email Address"}),(0,n.jsx)("meta",{name:"description",content:"Verify your email address"})]}),user:s,children:(0,n.jsx)("main",{className:"flex flex-col items-center p-8 justify-center w-full",children:(0,n.jsxs)("div",{className:"login-block gap-2 flex-col max-w-lg",children:[o&&(0,n.jsx)("div",{className:o.class+" w-full rounded py-2 px-4 flex justify-center",children:o.msg}),r&&(0,n.jsx)(a.A,{position:"absolute"}),(0,n.jsx)("h1",{className:"text-2xl m-0 ",children:"Verify Email Address"}),(0,n.jsx)("span",{children:"Please click the button below to send verification link"}),(0,n.jsx)("button",{className:"w-full",onClick:function(e){e.preventDefault(),d(!0),(0,c.A)("/api/sendEmailVerificationLink").then(e=>{d(!1),e.success&&m({msg:"Email Sent. Please check mailbox",class:"bg-emerald-100"})})},children:(0,n.jsx)("span",{children:"Send Verification Link"})}),(0,n.jsx)("button",{className:"w-full outlined",onClick:e=>{window.history.back()},children:(0,n.jsx)("span",{children:"Go Back"})})]})})})})}}},e=>{var s=s=>e(e.s=s);e.O(0,[636,6593,8792],()=>s(87869)),_N_E=e.O()}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3332],{23792:(e,t,a)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/",function(){return a(64393)}])},35681:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(74848),i=a(96540),h=a(51105),o=a(87220);function s(e){let{content:t,language:a,style:s,showCopy:c}=e,[d,l]=i.useState(!1),n=()=>{l(!0)},y=(e,t)=>{"clickaway"!==t&&l(!1)},p=(0,r.jsx)(i.Fragment,{children:(0,r.jsx)("button",{className:"outlined gray",style:{border:"none",padding:"2px",width:"20px",height:"20px",color:"white"},onClick:y,children:"✖"})}),x={};return(0,r.jsxs)("pre",{className:"language-".concat(a||"javascript"," w-auto overflow-hidden skip-js code-block relative max-w-4xl flex items-center justify-center"),style:s?{...s,...x}:x,children:[(0,r.jsx)("code",{className:"w-auto px-10",style:{wordBreak:"break-all"},children:t}),(0,r.jsx)("button",{className:"outlined copy-code "+(c?"relative show":" absolute right-2 z-20 hover:opacity-50"),style:{padding:"2px",border:"none"},onClick:e=>{navigator.clipboard.writeText(t).then(()=>{n()})},children:(0,r.jsx)(o.A,{className:"text-white",size:20})}),(0,r.jsx)(h.A,{open:d,autoHideDuration:2e3,onClose:y,children:(0,r.jsxs)("div",{className:"h-full text-white px-4 py-2 justify-between rounded",style:{maxWidth:"250px",width:"250px",backgroundColor:"#0b8862"},children:[(0,r.jsx)("span",{children:"Code Copied!"}),p]})})]})}},50094:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(74848);function i(e){let{src:t,alt:a,className:i,fadeHeight:h,width:o,height:s,opacity:c}=e;return(0,r.jsxs)("div",{className:"overflow-hidden z-0"+(i?" "+i:""),children:[(0,r.jsx)("img",{src:t,alt:a,className:"w-full h-full object-cover",width:o,height:s}),(0,r.jsx)("div",{className:"fade-side",style:{height:h}})]})}a(96540)},87220:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});let r=(0,a(95737).A)("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]])},2894:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});let r=(0,a(95737).A)("FileKey2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v6",key:"rc0qvx"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["circle",{cx:"4",cy:"16",r:"2",key:"1ehqvc"}],["path",{d:"m10 10-4.5 4.5",key:"7fwrp6"}],["path",{d:"m9 11 1 1",key:"wa6s5q"}]])},18190:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});let r=(0,a(95737).A)("Sheet",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["line",{x1:"3",x2:"21",y1:"9",y2:"9",key:"1vqk6q"}],["line",{x1:"3",x2:"21",y1:"15",y2:"15",key:"o2sbyz"}],["line",{x1:"9",x2:"9",y1:"9",y2:"21",key:"1ib60c"}],["line",{x1:"15",x2:"15",y1:"9",y2:"21",key:"1n26ft"}]])},64393:(e,t,a)=>{"use strict";a.r(t),a.d(t,{HomepageContext:()=>h,default:()=>o}),a(74848);var r=a(96540);a(93444),a(96411),a(62900),a(42361),a(26659),a(96869),a(47512),a(57457),a(50094),a(35681);var i=a(95737);(0,i.A)("SquareGanttChart",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 8h7",key:"kbo1nt"}],["path",{d:"M8 12h6",key:"ikassy"}],["path",{d:"M11 16h5",key:"oq65wt"}]]),(0,i.A)("CopyCheck",[["path",{d:"m12 15 2 2 4-4",key:"2c609p"}],["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]),a(18190),(0,i.A)("EarthLock",[["path",{d:"M7 3.34V5a3 3 0 0 0 3 3",key:"w732o8"}],["path",{d:"M11 21.95V18a2 2 0 0 0-2-2 2 2 0 0 1-2-2v-1a2 2 0 0 0-2-2H2.05",key:"f02343"}],["path",{d:"M21.54 15H17a2 2 0 0 0-2 2v4.54",key:"1djwo0"}],["path",{d:"M12 2a10 10 0 1 0 9.54 13",key:"zjsr6q"}],["path",{d:"M20 6V4a2 2 0 1 0-4 0v2",key:"1of5e8"}],["rect",{width:"8",height:"5",x:"14",y:"6",rx:"1",key:"1fmf51"}]]),a(2894),(0,i.A)("FolderOutput",[["path",{d:"M2 7.5V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H4a2 2 0 0 1-2-1.5",key:"1yk7aj"}],["path",{d:"M2 13h10",key:"pgb2dq"}],["path",{d:"m5 10-3 3 3 3",key:"1r8ie0"}]]);let h=r.createContext({});function o(){r.useEffect(()=>{window.location.replace("/login")},[])}},47512:e=>{e.exports={hero_section_wrapper:"Home_hero_section_wrapper__rAO8W",hero_image:"Home_hero_image__qie3Q",hero_image_alt:"Home_hero_image_alt__Bl1L4",hero_text_section:"Home_hero_text_section__tNqS5"}}},e=>{var t=t=>e(e.s=t);e.O(0,[7623,1105,9654,636,6593,8792],()=>t(23792)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5405],{3848:function(e,t,a){"use strict";a.d(t,{Z:function(){return r}});const r=(0,a(45711).Z)("FileKey2",[["path",{d:"M4 22h14a2 2 0 0 0 2-2V7l-5-5H6a2 2 0 0 0-2 2v6",key:"rc0qvx"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["circle",{cx:"4",cy:"16",r:"2",key:"1ehqvc"}],["path",{d:"m10 10-4.5 4.5",key:"7fwrp6"}],["path",{d:"m9 11 1 1",key:"wa6s5q"}]])},10312:function(e,t,a){"use strict";a.d(t,{Z:function(){return r}});const r=(0,a(45711).Z)("Sheet",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["line",{x1:"3",x2:"21",y1:"9",y2:"9",key:"1vqk6q"}],["line",{x1:"3",x2:"21",y1:"15",y2:"15",key:"o2sbyz"}],["line",{x1:"9",x2:"9",y1:"9",y2:"21",key:"1ib60c"}],["line",{x1:"15",x2:"15",y1:"9",y2:"21",key:"1n26ft"}]])},45728:function(e,t,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/",function(){return a(51810)}])},44598:function(e,t,a){"use strict";a.d(t,{Z:function(){return n}});var r=a(85893);a(67294);function n(e){var t=e.src,a=e.alt,n=e.className,h=e.fadeHeight,i=e.width,c=e.height;e.opacity;return(0,r.jsxs)("div",{className:"overflow-hidden z-0"+(n?" "+n:""),children:[(0,r.jsx)("img",{src:t,alt:a,className:"w-full h-full object-cover",width:i,height:c}),(0,r.jsx)("div",{className:"fade-side",style:{height:h}})]})}},51810:function(e,t,a){"use strict";a.r(t),a.d(t,{HomepageContext:function(){return i},default:function(){return c}});a(828),a(85893);var r=a(67294);a(56217),a(24097),a(9922),a(47335),a(73987),a(40662),a(4703),a(31356),a(44598);var n=a(45711);(0,n.Z)("SquareGanttChart",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 8h7",key:"kbo1nt"}],["path",{d:"M8 12h6",key:"ikassy"}],["path",{d:"M11 16h5",key:"oq65wt"}]]),(0,n.Z)("CopyCheck",[["path",{d:"m12 15 2 2 4-4",key:"2c609p"}],["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);a(10312);(0,n.Z)("EarthLock",[["path",{d:"M7 3.34V5a3 3 0 0 0 3 3",key:"w732o8"}],["path",{d:"M11 21.95V18a2 2 0 0 0-2-2 2 2 0 0 1-2-2v-1a2 2 0 0 0-2-2H2.05",key:"f02343"}],["path",{d:"M21.54 15H17a2 2 0 0 0-2 2v4.54",key:"1djwo0"}],["path",{d:"M12 2a10 10 0 1 0 9.54 13",key:"zjsr6q"}],["path",{d:"M20 6V4a2 2 0 1 0-4 0v2",key:"1of5e8"}],["rect",{width:"8",height:"5",x:"14",y:"6",rx:"1",key:"1fmf51"}]]);a(3848);(0,n.Z)("FolderOutput",[["path",{d:"M2 7.5V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H4a2 2 0 0 1-2-1.5",key:"1yk7aj"}],["path",{d:"M2 13h10",key:"pgb2dq"}],["path",{d:"m5 10-3 3 3 3",key:"1r8ie0"}]]);var h={},i=r.createContext(h);function c(){r.useEffect((function(){window.location.replace("/login")}),[])}},4703:function(e){e.exports={hero_section_wrapper:"Home_hero_section_wrapper__IkH4Z",hero_image:"Home_hero_image__UVLPw",hero_image_alt:"Home_hero_image_alt__zrhLF",hero_text_section:"Home_hero_text_section__kUQbt"}}},function(e){e.O(0,[3935,9774,2888,179],(function(){return t=45728,e(e.s=t);var t}));var t=e.O();_N_E=t}]);
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[676],{86774:(e,s,r)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/login",function(){return r(74742)}])},87291:(e,s,r)=>{"use strict";r.d(s,{A:()=>l});var t=r(74848);r(96540);var a=r(620);function l(){return(0,t.jsx)("div",{className:"flex flex-col gap-4 items-center justify-center w-full h-screen p-6 bg-slate-100",children:(0,t.jsxs)("div",{className:"flex flex-col items-center justify-center gap-4 px-6 py-20 bg-white rounded shadow-sm max-w-2xl w-full",children:[(0,t.jsx)("img",{src:"/images/logo-icon-alt-2.webp",alt:"Datasquirel Logo",width:60}),(0,t.jsx)("div",{className:"w-10 h-10 flex flex-col items-center justify-center",children:(0,t.jsx)(a.A,{width:"25px",position:"relative"})})]})})}},74742:(e,s,r)=>{"use strict";r.r(s),r.d(s,{__N_SSP:()=>p,default:()=>w});var t=r(74848),a=r(96540),l=r(13368),n=r.n(l),i=r(43586),o=r(23698);async function c(e){let{e:s,setAlert:r,setLoading:t,query:a}=e;s.preventDefault(),t(!0);let l=s.target["email-or-username-input"],n=s.target.password;if((null==l?void 0:l.value)===""&&(null==n?void 0:n.value)===""){l.classList.add("warning"),n.classList.add("warning"),r("No Email or Password Provided"),t(!1);return}if((null==n?void 0:n.value)===""){r(!1),n.classList.add("warning"),r(!0),t(!1);return}l.classList.remove("warning"),n.classList.remove("warning"),r(!1);let c={email:l.value,password:n.value,query:a};(0,o.A)("/api/loginUser",{method:"post",body:c}).then(async e=>{console.log(e),e.user&&e.user.auth?(localStorage.setItem("userid",e.user.userid),localStorage.setItem("csrf",e.user.csrf_k),localStorage.setItem("user",JSON.stringify(e.userPayload)),(0,i.A)().then(()=>{window.location.reload()})):(r(e.msg),t(!1))})}var u=r(620),d=r(29907);let m=a.createContext({});function x(e){let{user:s,query:r}=e,[l,n]=(0,a.useState)(null),[i,o]=(0,a.useState)(!1);return(0,t.jsxs)(m.Provider,{value:{loading:i,setLoading:o,alert:l,setAlert:n,user:s},children:[(0,t.jsx)(d.A,{user:s,userType:"admin",setLoading:o}),(0,t.jsxs)("div",{className:"w-full justify-center relative",children:[(0,t.jsx)("span",{className:"bg-white dark:bg-slate-800 px-3 relative z-10",children:"OR"}),(0,t.jsx)("hr",{className:"absolute"})]}),(0,t.jsxs)("div",{className:"w-full flex-col items-stretch gap-4",children:[i&&(0,t.jsx)(u.A,{}),l&&(0,t.jsx)("div",{className:"p-2 justify-center text-sm border border-solid border-orange-400 rounded bg-orange-50",children:l}),(0,t.jsxs)("form",{className:"flex flex-col gap-2 w-full",onSubmit:e=>{c({e,setAlert:n,setLoading:o,query:r})},children:[(0,t.jsx)("input",{type:"text",name:"email-or-username-input",id:"email-or-username-input",placeholder:"Email or username",defaultValue:(null==r?void 0:r.email)?r.email:"",required:!0,onInput:e=>{l&&n(!1)}}),(0,t.jsx)("input",{type:"password",name:"password",id:"password-input",placeholder:"Password",required:!0,onInput:e=>{l&&n(!1)}}),(0,t.jsx)("button",{type:"submit",children:"Login"})]}),(0,t.jsx)("div",{className:"flex flex-col items-center w-full mb-2",children:(0,t.jsx)("a",{href:"/send-password-reset-link",className:"text-secondary font-semibold",children:"Forgot Password?"})}),(0,t.jsxs)("div",{className:"flex items-center gap-2 justify-center w-full mb-2 flex-wrap",children:[(0,t.jsx)("span",{children:"Dont have an account yet?"}),(0,t.jsx)("a",{href:"/create-account",className:"text-secondary font-semibold",children:"Register Now"})]}),(0,t.jsxs)("div",{className:"justify-center text-sm text-secondary",children:[(0,t.jsx)("a",{href:"/terms",className:"text-secondary",children:"Terms and Conditions"}),(0,t.jsx)("a",{href:"/privacy",className:"text-secondary",children:"Privacy Policy"})]})]})]})}var f=r(61638),h=r(87291),p=!0;function w(e){return(a.useEffect(()=>{setTimeout(()=>{e.query.invite&&e.user&&(window.location.pathname="/create-account")},1e3),e.query.invite||localStorage.setItem("user","{}")},[]),e.query.invite&&e.user)?(0,t.jsx)(h.A,{}):(0,t.jsxs)(a.Fragment,{children:[(0,t.jsxs)(n(),{children:[(0,t.jsx)("title",{children:"Login to your account"}),(0,t.jsx)("meta",{name:"description",content:"Login to your account"})]}),(0,t.jsx)("main",{className:"w-screen h-screen flex items-center justify-center p-4 md:p-8",children:(0,t.jsxs)("div",{className:"card col items-center no-hover max-w-md w-full bg-white p-4 sm:p-6 overflow-auto minimal-scrollbars",style:{maxHeight:"calc(100vh - 40px)"},children:[(0,t.jsx)(f.A,{}),(0,t.jsx)("hr",{}),(0,t.jsx)("h3",{className:"m-0 text-lg font-semibold",children:"Login to your account"}),(0,t.jsx)(x,{user:e.user,query:e.query})]})})]})}}},e=>{var s=s=>e(e.s=s);e.O(0,[9907,636,6593,8792],()=>s(86774)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[765],{60233:function(e,n,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/logout",function(){return t(51780)}])},29137:function(e,n,t){"use strict";t.d(n,{Z:function(){return i}});var o=t(47568),r=t(97582);function i(){return s.apply(this,arguments)}function s(){return(s=(0,o.Z)((function(){var e,n;return(0,r.__generator)(this,(function(t){switch(t.label){case 0:return t.trys.push([0,4,,5]),[4,caches.keys()];case 1:return(e=t.sent())[0]?[4,Promise.all(e.map((function(e){return caches.delete(e)})))]:[3,3];case 2:t.sent(),t.label=3;case 3:return[3,5];case 4:return n=t.sent(),console.log("Error in clearing cache =>",n.message),[3,5];case 5:return[2]}}))}))).apply(this,arguments)}},51780:function(e,n,t){"use strict";t.r(n),t.d(n,{__N_SSP:function(){return d},default:function(){return f}});var o=t(47568),r=t(97582),i=t(85893),s=t(67294),c=t(9008),a=t.n(c),l=t(86729),u=t(29137),g=t(95264),d=!0;function f(e){var n=e.user,t=e.query,c=(0,i.jsxs)(s.Fragment,{children:[(0,i.jsx)("title",{children:"Loging Out | Datasquirel"}),(0,i.jsx)("meta",{name:"description",content:"Login you out"}),(0,i.jsx)("script",{src:"https://accounts.google.com/gsi/client"}),(0,i.jsx)("script",{src:"https://connect.facebook.net/en_US/sdk.js",crossOrigin:"anonymous"})]});return s.useEffect((function(){localStorage.setItem("user","{}"),localStorage.removeItem("csrf")}),[]),s.useEffect((function(){var e=function(){var e,o;return(null===t||void 0===t?void 0:t.invite)&&(null===t||void 0===t?void 0:t.login)?window.location.href="/login"+window.location.search:(null===t||void 0===t?void 0:t.login)||(null===(e=localStorage.getItem("logoutParadigm"))||void 0===e?void 0:e.match(/reset/))?window.location.href="/login":((null===n||void 0===n||null===(o=n.social_platform)||void 0===o?void 0:o.match(/google/))&&localStorage.setItem("google_prompt_skipped","logout"),void(window.location.pathname="/"))};(0,l.Z)("/api/logoutUser").then(function(){var t=(0,o.Z)((function(t){var o,i;return(0,r.__generator)(this,(function(t){switch(t.label){case 0:return[4,(0,u.Z)()];case 1:return t.sent(),[4,navigator.serviceWorker.getRegistrations()];case 2:o=t.sent(),i=0,t.label=3;case 3:return i<o.length?[4,o[i].unregister()]:[3,6];case 4:t.sent(),t.label=5;case 5:return i++,[3,3];case 6:try{FB.init({appId:"",cookie:!0,xfbml:!0,version:"v13.0"}),FB.getLoginStatus((function(t){var o;t.authResponse?FB.logout((function(n){e()})):(google.accounts.id.initialize({client_id:""}),(null===n||void 0===n||null===(o=n.social_platform)||void 0===o?void 0:o.match(/google/))&&n.social_id?(google.accounts.id.revoke(),google.accounts.id.revoke(n.social_id,(function(n){console.log(n.error),e()}))):e())}))}catch(r){(0,l.Z)("/api/admin/clientError",{method:"post",body:{component:"logout-page-component/lines-111-142",message:r.message,user:n}})}return[2]}}))}));return function(e){return t.apply(this,arguments)}}())}),[]),(0,i.jsxs)(s.Fragment,{children:[(0,i.jsx)(a(),{children:c}),(0,i.jsx)("main",{className:"w-screen h-screen flex items-center justify-center p-4 md:p-8",children:(0,i.jsxs)("div",{className:"card max-w-md flex-col items-center bg-white p-6 rounded border border-slate-200 border-solid",children:[(0,i.jsxs)("a",{href:"/",className:"flex items-center gap-2",children:[(0,i.jsx)("img",{src:"/images/logo-icon-alt-2.png",alt:"Logo Icon",width:37}),(0,i.jsx)("span",{className:"font-bold text-2xl",children:"Datasquirel"})]}),(0,i.jsx)("h3",{className:"text-lg m-0 mt-4 text-slate-400",children:"Logging out"}),(0,i.jsx)(g.Z,{position:"relative",width:"20px"})]})})]})}}},function(e){e.O(0,[9774,2888,179],(function(){return n=60233,e(e.s=n);var n}));var n=e.O();_N_E=n}]);
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7122],{9282:(e,o,t)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/logout",function(){return t(20238)}])},43586:(e,o,t)=>{"use strict";async function i(){try{let e=await caches.keys();e[0]&&await Promise.all(e.map(e=>caches.delete(e)))}catch(e){console.log("Error in clearing cache =>",e.message)}}t.d(o,{A:()=>i})},20238:(e,o,t)=>{"use strict";t.r(o),t.d(o,{__N_SSP:()=>g,default:()=>d});var i=t(74848),s=t(96540),l=t(13368),n=t.n(l),a=t(23698),c=t(43586),r=t(620),g=!0;function d(e){let{user:o,query:t}=e,l=(0,i.jsxs)(s.Fragment,{children:[(0,i.jsx)("title",{children:"Loging Out | Datasquirel"}),(0,i.jsx)("meta",{name:"description",content:"Login you out"}),(0,i.jsx)("script",{src:"https://accounts.google.com/gsi/client"}),(0,i.jsx)("script",{src:"https://connect.facebook.net/en_US/sdk.js",crossOrigin:"anonymous"})]});return s.useEffect(()=>{localStorage.setItem("user","{}"),localStorage.removeItem("csrf")},[]),s.useEffect(()=>{function e(){var e,i;return(null==t?void 0:t.invite)&&(null==t?void 0:t.login)?window.location.href="/login"+window.location.search:(null==t?void 0:t.login)||(null===(e=localStorage.getItem("logoutParadigm"))||void 0===e?void 0:e.match(/reset/))?window.location.href="/login":void((null==o?void 0:null===(i=o.social_platform)||void 0===i?void 0:i.match(/google/))&&localStorage.setItem("google_prompt_skipped","logout"),window.location.pathname="/")}(0,a.A)("/api/logoutUser").then(async t=>{await (0,c.A)();let i=await navigator.serviceWorker.getRegistrations();for(let e=0;e<i.length;e++){let o=i[e];await o.unregister()}try{FB.init({appId:"",cookie:!0,xfbml:!0,version:"v13.0"}),FB.getLoginStatus(t=>{if(t.authResponse)FB.logout(o=>{e()});else{var i;google.accounts.id.initialize({client_id:""}),(null==o?void 0:null===(i=o.social_platform)||void 0===i?void 0:i.match(/google/))&&o.social_id?(google.accounts.id.revoke(),google.accounts.id.revoke(o.social_id,o=>{console.log(o.error),e()})):e()}})}catch(e){(0,a.A)("/api/admin/clientError",{method:"post",body:{component:"logout-page-component/lines-111-142",message:e.message,user:o}})}})},[]),(0,i.jsxs)(s.Fragment,{children:[(0,i.jsx)(n(),{children:l}),(0,i.jsx)("main",{className:"w-screen h-screen flex items-center justify-center p-4 md:p-8",children:(0,i.jsxs)("div",{className:"card max-w-md flex-col items-center bg-white p-6 rounded border border-slate-200 border-solid",children:[(0,i.jsxs)("a",{href:"/",className:"flex items-center gap-2",children:[(0,i.jsx)("img",{src:"/images/logo-icon-alt-2.png",alt:"Logo Icon",width:37}),(0,i.jsx)("span",{className:"font-bold text-2xl",children:"Datasquirel"})]}),(0,i.jsx)("h3",{className:"text-lg m-0 mt-4 text-slate-400",children:"Logging out"}),(0,i.jsx)(r.A,{position:"relative",width:"20px"})]})})]})}}},e=>{var o=o=>e(e.s=o);e.O(0,[636,6593,8792],()=>o(9282)),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9939],{32543:function(t,n,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/pricing",function(){return r(46497)}])},9922:function(t,n,r){"use strict";r.d(n,{Z:function(){return u}});var e=r(86729);function u(t){var n=t.setUser,r=localStorage.getItem("user");if(r)try{return void n(JSON.parse(r))}catch(u){return void n({})}(0,e.Z)("/api/clientSideAuth",{method:"post",body:{}},!0).then((function(t){var r=t.user?t.user:{};n(r),localStorage.setItem("user",JSON.stringify(r))})).catch((function(t){console.log(t)}))}},46497:function(t,n,r){"use strict";r.r(n),r.d(n,{PricingContext:function(){return i},default:function(){return o}});r(828),r(85893);var e=r(67294);r(56217),r(24097),r(9922);var u={},i=e.createContext(u);function o(t){return e.useEffect((function(){window.location.href="https://datasquirel.com/pricing"}),[]),null}}},function(t){t.O(0,[9774,2888,179],(function(){return n=32543,t(t.s=n);var n}));var n=t.O();_N_E=n}]);
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long

Some files were not shown because too many files have changed in this diff Show More