1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6893],{3897:(e,t,n)=>{n.d(t,{A:()=>l,R:()=>c});var a=n(37876),r=n(14232),s=n(51656);let i=null;function c(){return""!==s.xx}let l=function(e){let{onToken:t,onError:n}=e,c=r.useRef(null),l=r.useRef(t),o=r.useRef(n);return l.current=t,o.current=n,r.useEffect(()=>{let e=null,t=!1;return(window.turnstile?Promise.resolve(window.turnstile):(!i&&(i=new Promise((e,t)=>{let n=document.createElement("script");n.src="https://challenges.cloudflare.com/turnstile/v0/api.js?render=explicit",n.async=!0,n.onload=()=>e(window.turnstile),n.onerror=()=>{i=null,t(Error("Turnstile failed to load"))},document.head.appendChild(n)})),i)).then(n=>{!t&&c.current&&(e=n.render(c.current,{sitekey:s.xx,callback:e=>l.current&&l.current(e),"error-callback":()=>o.current&&o.current()}))}).catch(()=>o.current&&o.current()),()=>{if(t=!0,null!==e&&window.turnstile)try{window.turnstile.remove(e)}catch(e){}}},[]),(0,a.jsx)("div",{ref:c})}},19711:(e,t,n)=>{n.d(t,{A:()=>a});function a(){var e=window.location.href.split("/");return e[0]+"//"+e[2]+"/"}},26498:(e,t,n)=>{n.r(t),n.d(t,{default:()=>y});var a=n(14232),r=n(38993),s=n(85664),i=n(51656),c=n(91592),l=n(17945),o=n(60771),u=n(34007),d=n(24931),m=n(30995),h=n(12357),p=n(98331),f=n(94267),v=n(91040);let w=n(81583).PRODUCT_TYPES;var g=n(64472);let y=function(e){let t=(0,s.vc)(l.qv),n=(0,s.lZ)(l.qv),[y,A]=a.useState(!1),b=(0,s.vc)(l.V6),Z=(0,s.lZ)(l.V6),[k,C]=a.useState(!0),S=(0,s.vc)(l.PT);(0,s.lZ)(l.PT);let N=(0,s.vc)(l.Lj);(0,s.lZ)(l.Lj),(0,s.vc)(l.vx),(0,s.lZ)(l.vx),(0,s.lZ)(l._7),(0,s.vc)(l._7);let{setAccessProducts:E}=(()=>{let e=(0,s.vc)(l.PT),t=(0,s.vc)(l.Lj),[n,r]=(0,s.L4)(l.N1);return{setAccessProducts:(0,a.useCallback)(async function(){let a=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(e||t){var s=0,i=!0;if(n&&n.time&&(isNaN(s=Math.abs(new Date-n.time)/36e5)||s<24)&&(i=!1),a&&(i=!0),i){let e=[],t=[];v.A.post("/api/account/products",{kind:"productid"}).then(n=>{if("success"===n.data.status&&n.data.data.length>0){e=n.data.data;for(var a=0;a<w.length;a++)if(w[a].children&&w[a].children.length>0)for(var s=0;s<w[a].children.length;s++)e.includes(w[a].children[s].value)&&t.push(w[a].label+" - "+w[a].children[s].label);else e.includes(w[a].value)&&t.push(w[a].label);r({time:new Date,Ids:e,Labels:t})}else r({time:new Date,Ids:[],Labels:[]})}).catch(()=>{r({time:new Date,Ids:[],Labels:[]})})}}else r({})})}})(),{setCustomProducts:x}=(()=>{let e=(0,s.vc)(l.PT),t=(0,s.vc)(l.Lj),[n,r]=(0,s.L4)(l.MI);return{setCustomProducts:(0,a.useCallback)(async function(){let a=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(e||t){var s=0,i=!0;n&&n.time&&(isNaN(s=Math.abs(new Date-n.time)/36e5)||s<24)&&(i=!1),a&&(i=!0),i&&v.A.post("/api/account/products",{kind:"customproducts"}).then(e=>{"success"===e.data.status&&e.data.data.length>0?r({time:new Date,productTypes:e.data.data}):r({time:new Date,productTypes:[]})}).catch(()=>{r({time:new Date,productTypes:[]})})}else r({})})}})(),[P,z]=a.useState(!1),[I,L]=a.useState(null),{data:Y,status:_}=(0,c.wV)(),D=(0,s.lZ)(l.lZ);(0,a.useEffect)(()=>{k&&"loading"!==_&&(C(!1),(null==Y?void 0:Y.institution)?D(!0):(0,c.Jv)("institutional-ip",{redirect:!1}).catch(()=>{}).finally(()=>D(!0)))},[k,_,Y]);let{setSignOut:R}=(0,g.M)();async function T(e){L(null),z(!1);let t=await (0,c.Jv)("cognito-password",{redirect:!1,username:e.username,password:e.password});if(!t||t.error){let n=(null==t?void 0:t.code)||(null==t?void 0:t.error);"UserNotConfirmedException"===n?(L({username:e.username,password:e.password}),z(!0)):"InvalidParameterException"===n?o.Ay.error({message:"Sign in Error",description:"Usernames can only include letters, numbers, and punctuation marks. Spaces are not allowed.",placement:"topRight",key:"notification"}):o.Ay.error({message:"Sign in Error",description:"Incorrect username or password.",placement:"topRight",key:"notification"});return}Z(!1),o.Ay.success({message:"You have now signed in",placement:"topRight",key:"notificationsignin",duration:1})}async function M(e){return T(e)}
1let[V,j]=a.useState(S),[F,H]=a.useState(N);return(0,a.useEffect)(()=>{S&&V!==S?(E(!0),x(!0)):S&&(E(),x()),j(S)},[S]),(0,a.useEffect)(()=>{N&&F!==N?(E(!0),x(!0)):N&&(E(),x()),H(N)},[N]),(0,r.Y)(a.Fragment,null,(!S||!N)&&(0,r.Y)(u.A,{title:"Sign In",placement:"right",onClose:()=>{n("signin"),Z(!1)},open:b,afterOpenChange:e=>{A(!0===e)},rootClassName:"login-container"},(0,r.Y)("div",{className:"amplify"},"signin"===t&&(0,r.Y)(m.A,{isSignedIn:e=>M(e),changeFormState:e=>n(e),isAccountNotConfirmed:P}),"reset-password"===t&&(0,r.Y)(p.A,{changeFormState:e=>n(e)}),"signup"===t&&(0,r.Y)(h.A,{drawerReady:y,isConfirmed:e=>M(e),changeFormState:e=>n(e),isAccountNotConfirmed:P,accountInfo:I,changeIsAccountNotConfirmed:e=>z(e)}),"true"===i.o$&&"signin"===t&&!N&&(0,r.Y)("div",{className:"sso"},(0,r.Y)("span",{className:"sso-description"},"- or sign in with -"),(0,r.Y)(d.Ay,{size:"large",className:"form-submit-button-sso",type:"link",onClick:function(e){e.preventDefault(),Z(!1),window.location="https://discover-auth.sabinet.co.za"}},(0,r.Y)(f.A,{style:{fontSize:"22px",marginRight:"3px"}}),"Your Institution")))))}},64472:(e,t,n)=>{n.d(t,{M:()=>u});var a=n(14232),r=n(85664),s=n(91592),i=n(17945),c=n(19711),l=n(5130);let o="sabinet_sso_active";"localhost"===window.location.hostname||window.location.hostname;let u=()=>{let e=(0,r.lZ)(i.PT),t=(0,r.lZ)(i.Lj),n=(0,r.lZ)(i.vx),u=(0,r.lZ)(i._7),d=(0,r.lZ)(i.UZ),m=(0,r.lZ)(i.O1),h=(0,r.lZ)(i.FS),p=(0,r.lZ)(i.N1),f=(0,r.lZ)(i.V6);(0,r.lZ)(i.EP);let v=(0,r.lZ)(i.MI),w=(0,r.vc)(i.UG),g=(0,c.A)();return{setSignOut:(0,a.useCallback)(async()=>{try{(()=>{let e=new l.A;e.remove(o,{path:"/",domain:".sabinet.co.za"}),e.remove(o,{path:"/"})})(),h([]),p({}),v({}),f(!1),e(!1),t(!1),n(!1),u(!1),d(!0),m(!1),await new Promise(e=>setTimeout(e,0)),await (0,s.CI)({redirect:!1}),w.productData&&w.productData.is_custom_product&&(window.location=g)}catch(e){}})}}},76684:(e,t,n)=>{n.d(t,{A:()=>c});var a=n(44501),r=n(14232);let s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"}}]},name:"info-circle",theme:"outlined"};var i=n(45522);let c=r.forwardRef(function(e,t){return r.createElement(i.A,(0,a.A)({},e,{ref:t,icon:s}))})},94267:(e,t,n)=>{n.d(t,{A:()=>c});var a=n(44501),r=n(14232);let s={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M894 462c30.9 0 43.8-39.7 18.7-58L530.8 126.2a31.81 31.81 0 00-37.6 0L111.3 404c-25.1 18.2-12.2 58 18.8 58H192v374h-72c-4.4 0-8 3.6-8 8v52c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-52c0-4.4-3.6-8-8-8h-72V462h62zM512 196.7l271.1 197.2H240.9L512 196.7zM264 462h117v374H264V462zm189 0h117v374H453V462zm307 374H642V462h118v374z"}}]},name:"bank",theme:"outlined"};var i=n(45522);let c=r.forwardRef(function(e,t){return r.createElement(i.A,(0,a.A)({},e,{ref:t,icon:s}))})}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.