@blackbaud/auth-client
Advanced tools
Comparing version 2.27.0 to 2.28.0
@@ -1,1 +0,1 @@ | ||
window.BBAuthClient=function(e){var t={};function n(o){if(t[o])return t[o].exports;var i=t[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(o,i,function(t){return e[t]}.bind(null,i));return o},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=9)}([function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(6)),o(n(7))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i="https://signin.blackbaud.com/signin/",s="https://host.nxt.blackbaud.com/errors/",r=encodeURIComponent;function a(e){let t=`${i}?redirectUrl=${r(location.href)}`;return e&&(t+="&inactivity=1"),t}t.BBAuthNavigator=class{static navigate(e,t){t?location.replace(e):location.href=e}static redirectToSignin(e){let t=a();e&&(t+="&"+function(e){const t=[];for(const n in e)e.hasOwnProperty(n)&&t.push(`${r(n)}=${r(e[n])}`);return t.join("&")}(e)),this.navigate(t)}static redirectToSignoutForInactivity(){const e=a(!0),t=`${i}sign-out?redirectUrl=${r(e)}`;this.navigate(t)}static redirectToError(e){let t,n;switch(e){case o.BBAuthTokenErrorCode.InvalidEnvironment:n="invalid_env",t="security";break;default:t="broken"}let i=`${s}${t}?source=auth-client&url=${r(location.href)}`;n&&(i+=`&code=${r(n)}`),this.navigate(i)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o={"bbk12.com":"https://sts-sso.bbk12.com","blackbaudfaith.com":"https://sts.blackbaudfaith.com","donorcentral.com":"https://sts-dc.donorcentral.com","mycampus-app.com":"https://sts-sso.mycampus-app.com","myschoolapp.com":"https://sts-sso.myschoolapp.com","myschoolautomation.com":"https://sts-sso.myschoolautomation.com","myschooldemo.com":"https://sts-sso.myschooldemo.com","myschooltraining.com":"https://sts-sso.myschooltraining.com"},i="https://s21aidntoken00blkbapp01.nxt.blackbaud.com";class s{static getRegisteredDomain(){for(const e of Object.keys(o)){const t=`.${e}`;if(this.CURRENT_DOMAIN===e||this.CURRENT_DOMAIN.substr(-t.length)===t)return e}}static getSTSDomain(){const e=this.getRegisteredDomain();return o[e]||i}}s.CURRENT_DOMAIN=window.location.hostname,t.BBAuthDomain=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.BBAuthDomUtility=class{static addCss(e){const t=document.createElement("style");return t.appendChild(document.createTextNode(e)),document.head.appendChild(t),t}static addIframe(e,t,n){const o=document.createElement("iframe");return o.className=t,o.title=n,o.src=e,this.addElToBodyTop(o),o}static removeCss(e){this.removeEl(e,document.head)}static removeEl(e,t=document.body){t.contains(e)&&t.removeChild(e)}static addElToBodyTop(e){const t=document.body;t.firstChild?t.insertBefore(e,t.firstChild):t.appendChild(e)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o="https://host.nxt.blackbaud.com";function i(e,t){if(e.origin===o){const n=e.data;return!!n&&n.source===t}return!1}t.BBAuthInterop=class{static postOmnibarMessage(e,t,n){t.source="auth-client",e.contentWindow.postMessage(t,n||o)}static messageIsFromOmnibar(e){return i(e,"skyux-spa-omnibar")}static messageIsFromToastContainer(e){return i(e,"skyux-spa-omnibar-toast-container")}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i=n(2),s=n(1);function r(e,t,n,o){return(o||void 0===o&&n)&&((e=e||{})[t]=n),e}function a(e,t,n,i,s){let a;return a=r(a,"environment_id",n),a=r(a,"legal_entity_id",s),a=r(a,"permission_scope",i,!(!n&&!s||!i)),new Promise((n,i)=>{!function(e,t,n,i,s){const r=new XMLHttpRequest;r.onreadystatechange=()=>{if(4===r.readyState)switch(r.status){case 0:s({code:o.BBAuthTokenErrorCode.Offline,message:"The user is offline."});break;case 200:i(r.responseText);break;case 401:s({code:o.BBAuthTokenErrorCode.NotLoggedIn,message:"The user is not logged in."});break;case 403:s({code:o.BBAuthTokenErrorCode.InvalidEnvironment,message:"The user is not a member of the specified environment."});break;default:r.status>=400&&s({code:o.BBAuthTokenErrorCode.Unspecified,message:"An unknown error occurred."})}},r.open("POST",e,!0),r.setRequestHeader(t.name,t.value),r.setRequestHeader("Accept","application/json"),r.setRequestHeader("Content-Type","application/json"),r.withCredentials=!0,n?r.send(JSON.stringify(n)):r.send()}(e,{name:"X-CSRF",value:t},a,e=>{const t=e?JSON.parse(e):void 0;n(t)},i)})}t.BBCsrfXhr=class{static request(e,t,n,r,c,d,u){return!c||r||d?new Promise((l,m)=>{new Promise((e,t)=>{u?e({csrf_token:"token_needed"}):a(i.BBAuthDomain.getSTSDomain()+"/session/csrf","token_needed").then(e).catch(t)}).then(t=>a(e,t.csrf_token,r,c,d)).then(l).catch(e=>{if(n||e.code===o.BBAuthTokenErrorCode.Offline)m(e);else switch(e.code){case o.BBAuthTokenErrorCode.NotLoggedIn:s.BBAuthNavigator.redirectToSignin(t);break;default:s.BBAuthNavigator.redirectToError(e.code)}})}):Promise.reject({code:o.BBAuthTokenErrorCode.PermissionScopeNoEnvironment,message:"You must also specify an environment or legal entity when specifying a permission scope."})}static requestWithToken(e,t){return new Promise((n,o)=>{const i=new XMLHttpRequest;i.onreadystatechange=()=>{if(4===i.readyState)switch(i.status){case 200:n(JSON.parse(i.responseText));break;default:o()}},i.open("GET",e,!0),i.setRequestHeader("Authorization","Bearer "+t),i.setRequestHeader("Accept","application/json"),i.send()})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(10),i=/1bb:\/\/([a-z]{3})-([a-z0-9]{5})(-[a-z]{4}[0-9]{2})?\/(.*)/;class s{static getUrl(e,t){const n=i.exec(e);let o=e,s=t?t.zone:void 0;return s&&(s=s.replace("-","")),n&&(n[3]&&(s=n[3].substring(1)),o=`https://${n[1]}-${s}.app.blackbaud.net/${n[2]}/${n[4]}`),Promise.resolve(o)}static getToken(e){return s.getTokenInternal(e)}static clearTokenCache(){s.tokenCache={}}static getTokenInternal(e){e=e||{};const{forceNewToken:t,disableRedirect:n}=e;if(s.mock)return Promise.resolve("mock_access_token_auth-client@blackbaud.com");const i=function(e){const{envId:t,permissionScope:n,leId:o}=e;return"token|"+(o||"-")+"|"+(t||"-")+"|"+(n||"-")}(e),r=s.tokenCache[i]=s.tokenCache[i]||{},a=(new Date).valueOf();return!t&&r.lastToken&&r.expirationTime&&r.expirationTime-a>6e4?Promise.resolve(r.lastToken):(r.pendingLookupPromise||(r.pendingLookupPromise=o.BBAuthTokenIntegration.getToken(n,e.envId,e.permissionScope,e.leId).then(e=>(r.expirationTime=(new Date).valueOf()+1e3*e.expires_in,r.lastToken=e.access_token,r.pendingLookupPromise=null,r.lastToken)).catch(e=>{throw r.pendingLookupPromise=null,e})),r.pendingLookupPromise)}}s.mock=!1,s.tokenCache={},t.BBAuth=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.Unspecified=0]="Unspecified",e[e.NotLoggedIn=1]="NotLoggedIn",e[e.InvalidEnvironment=2]="InvalidEnvironment",e[e.PermissionScopeNoEnvironment=3]="PermissionScopeNoEnvironment",e[e.Offline=4]="Offline"}(t.BBAuthTokenErrorCode||(t.BBAuthTokenErrorCode={}))},function(e,t,n){"use strict";function o(e){const t=e.split("."),n=[];for(const e of t){const t=parseInt(e,10)||0;n.push(t)}return n}Object.defineProperty(t,"__esModule",{value:!0});class i{static registerScript(e){return new Promise((t,n)=>{const o=document.createElement("script");o.onload=t,o.onerror=n,o.src=e,document.body.appendChild(o)})}static smartRegisterScript(e,t,n){return n&&function(e,t){const n=o(e),i=o(t);for(let e=0;e<n.length;e++)if(e<i.length){if(i[e]>n[e])return!0;if(i[e]<n[e])return!1}return!0}(t,n)?Promise.resolve():i.registerScript(e)}}t.BBOmnibarScriptLoader=i},function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(0)),o(n(12)),o(n(14))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(5),i=n(11),s=n(2);t.BBAuthTokenIntegration=class{static getToken(e,t,n,r){return void 0!==s.BBAuthDomain.getRegisteredDomain()||this.hostNameEndsWith("blackbaud.com")?o.BBCsrfXhr.request(s.BBAuthDomain.getSTSDomain()+"/oauth2/token",void 0,e,t,n,r,!0):i.BBAuthCrossDomainIframe.getToken({disableRedirect:e,envId:t,leId:r,permissionScope:n})}static hostNameEndsWith(e){return this.getLocationHostname().substr(-e.length)===e}static getLocationHostname(){return window.location.hostname}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(3),i=n(1),s=n(7),r="https://s21aidntoken00blkbapp01.nxt.blackbaud.com/Iframes/CrossDomainAuthFrame.html",a="security-token-svc",c="auth-client";class d{static reset(){this.requestCounter=0,this.tokenRequests={},this.iframeReadyPromise=new Promise(e=>this.iframeReadyResolve=e),this.listenerSetup=!1}static TARGET_ORIGIN(){return this.TARGETORIGIN}static getOrMakeIframe(){return d.iframeEl=document.getElementById("auth-cross-domain-iframe"),d.iframeEl||(d.iframeEl=o.BBAuthDomUtility.addIframe(r,"auth-cross-domain-iframe",""),d.iframeEl.id="auth-cross-domain-iframe",d.iframeEl.hidden=!0),d.iframeEl}static getToken(e){return this.setupListenersForIframe(),this.getTokenFromIframe(this.getOrMakeIframe(),e)}static setupListenersForIframe(){this.listenerSetup||(window.addEventListener("message",e=>{const t=e.data,n=t.requestId,o=this.tokenRequests[n];if(t.source===a||t.origin===this.TARGET_ORIGIN())switch(t.messageType){case"ready":this.iframeReadyResolve(!0);break;case"error":this.handleErrorMessage(t.value,o.reject,o.args.disableRedirect);break;case"getToken":const e={access_token:t.value,expires_in:0};o.resolve(e)}}),this.listenerSetup=!0)}static getTokenFromIframe(e,t){return new Promise((n,o)=>{const i=this.requestCounter++;d.tokenRequests[i]={args:t,reject:o,resolve:n},d.iframeReadyPromise.then(()=>{e.contentWindow.postMessage({messageType:"getToken",requestId:i,source:c,value:t},d.TARGET_ORIGIN())})})}static handleErrorMessage(e,t,n){if(n)t(e);else switch(e.code){case s.BBAuthTokenErrorCode.Offline:t(e);break;case s.BBAuthTokenErrorCode.NotLoggedIn:i.BBAuthNavigator.redirectToSignin(void 0);break;default:i.BBAuthNavigator.redirectToError(e.code)}}}d.listenerSetup=!1,d.iframeReadyPromise=new Promise(e=>d.iframeReadyResolve=e),d.tokenRequests={},d.requestCounter=0,d.TARGETORIGIN="https://s21aidntoken00blkbapp01.nxt.blackbaud.com",t.BBAuthCrossDomainIframe=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(n(13))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i=n(4),s=n(5),r=n(3),a=n(1);function c(e,t,n,s){let a,c;function d(){r.BBAuthDomUtility.removeEl(c),r.BBAuthDomUtility.removeCss(a),c=a=void 0,window.removeEventListener("message",l)}function l(r){if(!i.BBAuthInterop.messageIsFromOmnibar(r))return;const a=r.data;switch(a.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),i.BBAuthInterop.postOmnibarMessage(c,{contextDestinations:t,messageType:"context-provide"});break;case"get-token":u=a.tokenRequestId,l=a.disableRedirect,o.BBAuth.getToken({disableRedirect:l}).then(e=>{i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:u})},e=>{i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:u})});break;case"welcome-cancel":d(),s({reason:"canceled"});break;case"welcome-environment-selected":d(),setTimeout(()=>{e.envId=a.envId,n(e)},10)}var u,l}a=r.BBAuthDomUtility.addCss("\n.sky-omnibar-welcome-iframe {\n background-color: #fff;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n"),function(){const t=u.url+"?hosted=1&svcid="+encodeURIComponent(e.svcId)+"&url="+encodeURIComponent(e.url);c=r.BBAuthDomUtility.addIframe(t,"sky-omnibar-welcome-iframe","Welcome")}(),window.addEventListener("message",l)}function d(){a.BBAuthNavigator.redirectToError(o.BBAuthTokenErrorCode.InvalidEnvironment)}class u{static ensureContext(e){const{envId:t,envIdRequired:n,leId:i,leIdRequired:r,svcId:a}=e;return!t&&n||!i&&r?new Promise((t,n)=>{a?o.BBAuth.getToken().then(o=>{let i="https://s21anavnavaf00blkbapp01.sky.blackbaud.com/user/destinations?svcid="+encodeURIComponent(a);e.url&&(i+="&referringurl="+encodeURIComponent(e.url)),s.BBCsrfXhr.requestWithToken(i,o).then(o=>{const i=o&&o.items,s=i&&i.length;1===s?(e.url=i[0].url,t(e)):s>1?c(e,o,t,n):d()})}):d()}):Promise.resolve(e)}}u.url="https://host.nxt.blackbaud.com/omnibar/welcome",t.BBContextProvider=u},function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(15)),o(n(26)),o(n(27))},function(e,t,n){"use strict";var o=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(i,s){function r(e){try{c(o.next(e))}catch(e){s(e)}}function a(e){try{c(o.throw(e))}catch(e){s(e)}}function c(e){e.done?i(e.value):new n((function(t){t(e.value)})).then(r,a)}c((o=o.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const i=n(16),s=n(0),r=n(4),a=n(1),c=n(3),d=n(19),u=n(23),l=n(24),m=n(25),h="sky-omnibar-iframe-expanded",p="sky-omnibar-loading";let f,b,v,g,B,y,k,I,T,A,w;function O(){g=c.BBAuthDomUtility.addIframe(B.url||"https://host.nxt.blackbaud.com/omnibar/",`sky-omnibar-iframe ${p}`,"Navigation")}function E(){const e=document.location.href;r.BBAuthInterop.postOmnibarMessage(g,{href:e,messageType:"location-change"}),m.BBOmnibarToastContainer.updateUrl(e)}function _(){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"push-notifications-open"})}function N(){I||(I=!0,D.pushNotificationsEnabled().then(e=>{e?m.BBOmnibarToastContainer.init({envId:B.envId,leId:B.leId,navigateCallback:M,navigateUrlCallback:x,openMenuCallback:_,svcId:B.svcId,url:document.location.href}).then(()=>{l.BBOmnibarPushNotifications.connect(B.leId,B.envId,e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"push-notifications-update",pushNotifications:e}),m.BBOmnibarToastContainer.showNewNotifications(e),T=e&&e.notifications&&e.notifications.filter(e=>!e.isRead).length,L()})}):I=!1}))}function R(){function e(e){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"refresh-user",token:e}),e?N():I&&(m.BBOmnibarToastContainer.destroy(),l.BBOmnibarPushNotifications.disconnect(),I=!1)}s.BBAuth.clearTokenCache(),s.BBAuth.getToken({disableRedirect:!0,forceNewToken:!0}).then(e).catch(()=>e(void 0))}function C(){u.BBOmnibarUserActivityPrompt.show({sessionRenewCallback:()=>{d.BBOmnibarUserActivity.userRenewedSession()}})}function S(){u.BBOmnibarUserActivityPrompt.hide()}function P(){d.BBOmnibarUserActivity.startTracking(R,C,S,B.allowAnonymous,y)}function M(e){const t=B.nav;t&&t.beforeNavCallback&&!1===t.beforeNavCallback(e)||a.BBAuthNavigator.navigate(e.url)}function x(e){a.BBAuthNavigator.navigate(e)}function U(e){if(!r.BBAuthInterop.messageIsFromOmnibar(e))return;const t=e.data,n=B.nav;switch(t.messageType){case"ready":r.BBAuthInterop.postOmnibarMessage(g,{messageType:"host-ready"}),function(){const e=history.pushState,t=history.replaceState;history.pushState=function(){const t=e.apply(history,arguments);return E(),t},history.replaceState=function(){const e=t.apply(history,arguments);return E(),e}}(),r.BBAuthInterop.postOmnibarMessage(g,{compactNavOnly:B.compactNavOnly,enableHelp:B.enableHelp,envId:B.envId,hideResourceLinks:B.hideResourceLinks,leId:B.leId,localNavItems:n&&n.localNavItems,localNotifications:!!B.notifications,localSearch:!!B.onSearch,messageType:"nav-ready",navVersion:B.navVersion,services:n&&n.services,svcId:B.svcId,theme:B.theme}),function(){const e=B.notifications;e&&e.onReady({updateNotifications:e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"notifications-update",notifications:e})}})}(),N(),E(),k();break;case"display-ready":b.classList.remove(p),g.classList.remove(p);break;case"expand":g.classList.add(h);break;case"collapse":g.classList.remove(h);break;case"navigate-url":x(t.url);break;case"navigate":M(t.navItem);break;case"search":c=t.searchArgs,B.onSearch&&B.onSearch(c).then(e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"search-results",results:e})});break;case"get-token":i=t.tokenRequestId,a=t.disableRedirect,s.BBAuth.getToken({disableRedirect:a}).then(e=>{P(),r.BBAuthInterop.postOmnibarMessage(g,{messageType:"token",token:e,tokenRequestId:i})},e=>{P(),r.BBAuthInterop.postOmnibarMessage(g,{messageType:"token-fail",reason:e,tokenRequestId:i})});break;case"help-open":!function(){const e=window.BBHELP;e&&e.HelpWidget.open()}();break;case"notification-read":!function(e){const t=B.notifications;t&&t.onNotificationRead&&t.onNotificationRead(e)}(t.notification);break;case"push-notifications-change":o=t.notifications,l.BBOmnibarPushNotifications.updateNotifications(o);break;case"session-renew":d.BBOmnibarUserActivity.userRenewedSession();break;case"environment-update":!function(e){const t="sky-omnibar-environment-visible",n=document.body.classList;e=e||"",f.innerText=e,e?n.add(t):n.remove(t)}(t.name);break;case"legacy-keep-alive-url-change":y=t.url,P();break;case"selected-service-update":A=t.serviceName,L()}var o,i,a,c}function L(){if(w){const e=w.slice();A&&e.push(A);let t=e.join(" - ");T&&(t=`(${T}) ${t}`),document.title=t}}class D{static load(e){return B=B=e,y=B.legacyKeepAliveUrl,new Promise(e=>{k=e,function(){let e="background: linear-gradient(to right, #71bf44 0, #31b986 50%, #00b2ec 100%);",t="#4d5259";const n=B.theme;if(n){const o=n.accent;t=n.backgroundColor||t,!1===o?e="display: none;":o&&o.color&&(e=`background-color: ${o.color};`)}v=c.BBAuthDomUtility.addCss(`\nbody {\n margin-top: 50px;\n}\n\n#bb-help-container {\n padding-top: 1px;\n}\n\n.sky-omnibar-iframe,\n.sky-omnibar-placeholder {\n border: none;\n height: 50px;\n width: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n z-index: 1000;\n}\n\n.sky-omnibar-placeholder {\n background-color: ${t};\n display: none;\n}\n\n.sky-omnibar-placeholder-accent {\n height: 5px;\n ${e}\n}\n\n.sky-omnibar-placeholder.${p} {\n display: block;\n}\n\n.sky-omnibar-iframe.${p} {\n visibility: hidden;\n}\n\n.${h} {\n height: 100%;\n}\n\n.sky-omnibar-environment {\n background-color: #e1e1e3;\n color: #282b31;\n font-family: "Blackbaud Sans", "Open Sans", "Helvetica Neue", Arial, sans-serif;\n font-size: 12px;\n font-weight: 400;\n height: 0;\n line-height: 24px;\n overflow: hidden;\n padding: 0 15px;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.sky-omnibar-environment-visible .sky-omnibar-environment {\n height: 24px;\n}\n`)}(),(b=document.createElement("div")).className=`sky-omnibar-placeholder ${p}`,b.innerHTML='<div class="sky-omnibar-placeholder-accent"></div>',document.body.appendChild(b),(f=document.createElement("div")).className="sky-omnibar-environment",c.BBAuthDomUtility.addElToBodyTop(f),O(),window.addEventListener("message",U)})}static update(e){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"update",updateArgs:e})}static setTitle(e){w=e&&e.titleParts,L()}static pushNotificationsEnabled(){return o(this,void 0,void 0,(function*(){return B?s.BBAuth.getToken({disableRedirect:!0,envId:B.envId,leId:B.leId,permissionScope:"Notifications"}).then(e=>{let t=i(e)["1bb.entitlements"];return!!t&&(t=Array.isArray(t)?t:[t]).indexOf("notif")>-1}).catch(()=>!1):Promise.resolve(!1)}))}static destroy(){m.BBOmnibarToastContainer.destroy(),l.BBOmnibarPushNotifications.disconnect(),c.BBAuthDomUtility.removeEl(b),c.BBAuthDomUtility.removeEl(g),c.BBAuthDomUtility.removeEl(f),c.BBAuthDomUtility.removeCss(v),window.removeEventListener("message",U),B=v=b=g=f=k=I=T=w=A=void 0}}t.BBOmnibar=D},function(e,t,n){"use strict";var o=n(17);function i(e){this.message=e}i.prototype=new Error,i.prototype.name="InvalidTokenError",e.exports=function(e,t){if("string"!=typeof e)throw new i("Invalid token specified");var n=!0===(t=t||{}).header?0:1;try{return JSON.parse(o(e.split(".")[n]))}catch(e){throw new i("Invalid token specified: "+e.message)}},e.exports.InvalidTokenError=i},function(e,t,n){var o=n(18);e.exports=function(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(o(e).replace(/(.)/g,(function(e,t){var n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(t)}catch(e){return o(t)}}},function(e,t){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function o(e){this.message=e}o.prototype=new Error,o.prototype.name="InvalidCharacterError",e.exports="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var t=String(e).replace(/=+$/,"");if(t.length%4==1)throw new o("'atob' failed: The string to be decoded is not correctly encoded.");for(var i,s,r=0,a=0,c="";s=t.charAt(a++);~s&&(i=r%4?64*i+s:s,r++%4)?c+=String.fromCharCode(255&i>>(-2*r&6)):0)s=n.indexOf(s);return c}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(2),i=n(5),s=n(20),r=n(21),a=n(22),c=n(1);let d,u,l,m,h,p,f,b,v,g,B,y,k,I,T="";function A(){b=Date.now()}function w(e){e.clientX===u&&e.clientY===l||(u=e.clientX,l=e.clientY,A())}function O(){const e=Date.now();(!v||e-v>R.MIN_RENEWAL_RETRY)&&(v=e,i.BBCsrfXhr.request(o.BBAuthDomain.getSTSDomain()+"/session/renew",{inactivity:1}).catch(()=>void 0))}function E(){f=!0,p()}function _(){f=!1,A(),m()}function N(){I?c.BBAuthNavigator.navigate(I):c.BBAuthNavigator.redirectToSignoutForInactivity()}class R{static startTracking(e,t,n,o,i){d&&o===B&&i===y||(R.stopTracking(),h=e,p=t,m=n,B=o,y=i,document.addEventListener("keypress",A),document.addEventListener("mousemove",w),B||O(),g=setInterval(()=>{r.BBOmnibarUserSessionExpiration.getSessionExpiration(T,k,B).then(e=>{d&&s.BBOmnibarUserActivityProcessor.process({allowAnonymous:B,closeInactivityPrompt:_,expirationDate:e,inactivityPromptDuration:R.INACTIVITY_PROMPT_DURATION,isShowingInactivityPrompt:f,lastActivity:b,maxSessionAge:R.MAX_SESSION_AGE,minRenewalAge:R.MIN_RENEWAL_AGE,redirectForInactivity:N,renewSession:O,showInactivityPrompt:E})})},R.ACTIVITY_TIMER_INTERVAL),a.BBOmnibarUserSessionWatcher.start(o,i,h,e=>{k=e.legacyTtl,T=e.refreshId,I=e.legacySigninUrl}),d=!0)}static userRenewedSession(){_(),O()}static stopTracking(){a.BBOmnibarUserSessionWatcher.stop(),r.BBOmnibarUserSessionExpiration.reset(),document.removeEventListener("keypress",A),document.removeEventListener("mousemove",w),g&&(clearInterval(g),g=void 0),d=u=l=b=v=f=h=p=m=B=y=void 0}}R.ACTIVITY_TIMER_INTERVAL=1e3,R.MIN_RENEWAL_RETRY=6e4,R.INACTIVITY_PROMPT_DURATION=12e4,R.MIN_RENEWAL_AGE=3e5,R.MAX_SESSION_AGE=54e5,t.BBOmnibarUserActivity=R},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.BBOmnibarUserActivityProcessor=class{static process(e){const{allowAnonymous:t,closeInactivityPrompt:n,expirationDate:o,inactivityPromptDuration:i,isShowingInactivityPrompt:s,lastActivity:r,maxSessionAge:a,minRenewalAge:c,redirectForInactivity:d,renewSession:u,showInactivityPrompt:l}=e,m=Date.now();if(null===o)return;!t&&m>o&&d();const h=o-i,p=o-a+c;s?m<h&&n():r>p?u():!t&&m>h&&l()}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(2),i=n(5);let s;t.BBOmnibarUserSessionExpiration=class{static getSessionExpiration(e,t,n){const r=function(e,t){if(s&&s.refreshId===e&&s.allowAnonymous===t)return s.promise;const n=new Promise((e,n)=>{i.BBCsrfXhr.request(o.BBAuthDomain.getSTSDomain()+"/session/ttl",void 0,t).then(t=>{const n=null===t?null:Date.now()+1e3*t;e(n)},()=>{e(null)})});return s={allowAnonymous:t,promise:n,refreshId:e},n}(e,n);return new Promise((e,n)=>{r.then(n=>{let o;if(null===n)o=null;else if("number"==typeof t){const e=Date.now()+t;o=Math.min(n,e)}else o=n;e(o)})})}static reset(){s=void 0}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(4),i=n(1),s=n(2);let r,a,c,d,u,l,m,h,p={};function f(e){if(e){const t=e.split("://");return`${t[0]}://${t[1].split("/")[0]}`}}function b(e,t){const n=document.createElement("iframe");return n.className=e,n.width="0",n.height="0",n.frameBorder="0",n.src=t,n.tabIndex=-1,n.setAttribute("aria-hidden","true"),document.body.appendChild(n),n}function v(e){if("string"==typeof e.data){let t;try{t=JSON.parse(e.data)}catch(e){return}if("session_change"===t.messageType){const e=t.message,n=e&&e.sessionId,s=e&&e.refreshId;n||u||(h?i.BBAuthNavigator.navigate(h):i.BBAuthNavigator.redirectToSignin()),void 0!==p.refreshId&&s!==p.refreshId&&function(e){m&&o.BBAuthInterop.postOmnibarMessage(m,e,f(a))}({messageType:"session-refresh"}),void 0!==p.sessionId&&n!==p.sessionId&&c(),p.refreshId=s,p.sessionId=n,d(p)}}}function g(e){switch(e.origin){case B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN:v(e);break;case f(a):!function(e){const t=e.data;switch(t.messageType){case"ready":p.legacyTtl=t.ttl,h=t.signinUrl,d(p)}}(e)}}class B{static start(e,t,n,o){r&&e===u&&t===a||(B.stop(),u=e,c=n,a=t,d=o,function(){const e=B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN+"/SessionWatcher.html?origin="+encodeURIComponent(location.origin);l=b("sky-omnibar-iframe-session-watcher",e)}(),a&&(m=b("sky-omnibar-iframe-legacy-keep-alive",a)),window.addEventListener("message",g,!1),r=!0)}static stop(){window.removeEventListener("message",g,!1),l&&(document.body.removeChild(l),l=void 0),m&&(document.body.removeChild(m),m=void 0),p={},r=u=c=a=h=d=void 0}}B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN=s.BBAuthDomain.getSTSDomain(),t.BBOmnibarUserSessionWatcher=B},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(3),i=n(4);let s,r,a;function c(e){if(!i.BBAuthInterop.messageIsFromOmnibar(e))return;switch(e.data.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(r,{messageType:"host-ready"}),r.classList.add("sky-omnibar-inactivity-iframe-ready");break;case"session-renew":a()}}class d{static show(e){this.hide(),a=e.sessionRenewCallback,s=o.BBAuthDomUtility.addCss("\n .sky-omnibar-inactivity-iframe {\n background-color: transparent;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 100000;\n visibility: hidden;\n }\n\n .sky-omnibar-inactivity-iframe-ready {\n visibility: visible;\n }\n "),function(){const e=d.url;r=o.BBAuthDomUtility.addIframe(e,"sky-omnibar-inactivity-iframe","Inactivity Prompt")}(),window.addEventListener("message",c)}static hide(){r&&(o.BBAuthDomUtility.removeEl(r),o.BBAuthDomUtility.removeCss(s),r=s=a=void 0,window.removeEventListener("message",c))}}d.url="https://host.nxt.blackbaud.com/omnibar/inactivity",t.BBOmnibarUserActivityPrompt=d},function(e,t,n){"use strict";var o=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(i,s){function r(e){try{c(o.next(e))}catch(e){s(e)}}function a(e){try{c(o.throw(e))}catch(e){s(e)}}function c(e){e.done?i(e.value):new n((function(t){t(e.value)})).then(r,a)}c((o=o.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const i=n(0),s=n(8);let r;class a{static connect(e,t,n){return o(this,void 0,void 0,(function*(){return r||(r=window.BBNotificationsClient?Promise.resolve():s.BBOmnibarScriptLoader.registerScript(this.NOTIFICATIONS_CLIENT_URL)),r.then(()=>{BBNotificationsClient.BBNotifications.init({tokenCallback:()=>i.BBAuth.getToken({disableRedirect:!0,envId:t,leId:e})}),BBNotificationsClient.BBNotifications.addListener(n)})}))}static disconnect(){return o(this,void 0,void 0,(function*(){return r?r.then(()=>{BBNotificationsClient.BBNotifications.destroy(),r=void 0}):Promise.resolve()}))}static updateNotifications(e){BBNotificationsClient.BBNotifications.updateNotifications(e)}}a.NOTIFICATIONS_CLIENT_URL="https://sky.blackbaudcdn.net/static/notifications-client/1/notifications-client.global.min.js",t.BBOmnibarPushNotifications=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(6),i=n(3),s=n(4),r="sky-omnibar-toast-container",a=`${r}-ready`,c=`${r}-empty`,d=20;let u,l,m,h,p,f;function b(e){const t=document.querySelector(e);return t?t.getBoundingClientRect().height:0}function v(){l&&s.BBAuthInterop.postOmnibarMessage(l,{href:f,messageType:"location-change"})}function g(e){if(!s.BBAuthInterop.messageIsFromToastContainer(e))return;const t=e.data;switch(t.messageType){case"toast-ready":s.BBAuthInterop.postOmnibarMessage(l,{messageType:"host-ready"}),s.BBAuthInterop.postOmnibarMessage(l,{envId:p.envId,leId:p.leId,messageType:"nav-ready",svcId:p.svcId}),v(),l.classList.add(a),h();break;case"get-token":n=t.tokenRequestId,i=t.disableRedirect,o.BBAuth.getToken({disableRedirect:i}).then(e=>{s.BBAuthInterop.postOmnibarMessage(l,{messageType:"token",token:e,tokenRequestId:n})},e=>{s.BBAuthInterop.postOmnibarMessage(l,{messageType:"token-fail",reason:e,tokenRequestId:n})});break;case"navigate-url":p.navigateUrlCallback(t.url);break;case"navigate":p.navigateCallback(t.navItem);break;case"toast-container-change":t.height>0?(l.style.height=t.height+"px",l.style.top=b(".sky-omnibar-iframe")+b(".sky-omnibar-environment")+d+"px",l.classList.remove(c)):l.classList.add(c);break;case"push-notifications-open":p.openMenuCallback()}var n,i}class B{static init(e){return p=e,f=e.url,m||(m=new Promise(e=>{h=e,l||(u=i.BBAuthDomUtility.addCss(`\n.${r} {\n border: none;\n display: none;\n position: fixed;\n right: 0px;\n height: 0px;\n width: 300px;\n /* z-index is 1 less than omnibar so menus will display over top the toast container */\n z-index: 999;\n}\n\n.${a} {\n display: block;\n}\n\n.${c} {\n visibility: hidden;\n}\n`),(l=document.createElement("iframe")).src=B.CONTAINER_URL,l.className=`${r} ${c}`,l.title="Toast container",document.body.appendChild(l),window.addEventListener("message",g))})),m}static showNewNotifications(e){s.BBAuthInterop.postOmnibarMessage(l,{messageType:"push-notifications-update",pushNotifications:e})}static updateUrl(e){f=e,v()}static destroy(){u&&i.BBAuthDomUtility.removeCss(u),l&&i.BBAuthDomUtility.removeEl(l),f=l=p=m=h=u=void 0,window.removeEventListener("message",g)}}B.CONTAINER_URL="https://host.nxt.blackbaud.com/omnibar/toast",t.BBOmnibarToastContainer=B},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(8);function i(){return window.jQuery}t.BBOmnibarLegacy=class{static load(e){return new Promise(t=>{const n=i(),s=n&&n.fn&&n.fn.jquery;o.BBOmnibarScriptLoader.smartRegisterScript("https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.js","2.1.0",s).then(()=>o.BBOmnibarScriptLoader.registerScript("https://cdnjs.cloudflare.com/ajax/libs/easyXDM/2.4.17.1/easyXDM.min.js")).then(()=>o.BBOmnibarScriptLoader.registerScript("https://signin.blackbaud.com/Omnibar.min.js")).then(()=>{document.body.classList.add("bb-omnibar-height-padding");const n=document.createElement("div");n.setAttribute("data-omnibar-el",""),document.body.appendChild(n),(e=e||{})["z-index"]=1e3,e.afterLoad=t,e.menuEl&&(e.menuEl=i()(e.menuEl)),BBAUTH.Omnibar.load(n,e)})})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0})}]); | ||
window.BBAuthClient=function(e){var t={};function n(o){if(t[o])return t[o].exports;var i=t[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(o,i,function(t){return e[t]}.bind(null,i));return o},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=9)}([function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(6)),o(n(7))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i="https://signin.blackbaud.com/signin/",s="https://host.nxt.blackbaud.com/errors/",r=encodeURIComponent;function a(e){let t=`${i}?redirectUrl=${r(location.href)}`;return e&&(t+="&inactivity=1"),t}t.BBAuthNavigator=class{static navigate(e,t){t?location.replace(e):location.href=e}static redirectToSignin(e){let t=a();e&&(t+="&"+function(e){const t=[];for(const n in e)e.hasOwnProperty(n)&&t.push(`${r(n)}=${r(e[n])}`);return t.join("&")}(e)),this.navigate(t)}static redirectToSignoutForInactivity(){const e=a(!0),t=`${i}sign-out?redirectUrl=${r(e)}`;this.navigate(t)}static redirectToError(e){let t,n;switch(e){case o.BBAuthTokenErrorCode.InvalidEnvironment:n="invalid_env",t="security";break;default:t="broken"}let i=`${s}${t}?source=auth-client&url=${r(location.href)}`;n&&(i+=`&code=${r(n)}`),this.navigate(i)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o={"bbk12.com":"https://sts-sso.bbk12.com","blackbaudfaith.com":"https://sts.blackbaudfaith.com","blackbaudhosting.com":"https://sts.blackbaudhosting.com","donorcentral.com":"https://sts-dc.donorcentral.com","etapestry.com":"https://sts.etapestry.com","mycampus-app.com":"https://sts-sso.mycampus-app.com","myschoolapp.com":"https://sts-sso.myschoolapp.com","myschoolautomation.com":"https://sts-sso.myschoolautomation.com","myschooldemo.com":"https://sts-sso.myschooldemo.com","myschooltraining.com":"https://sts-sso.myschooltraining.com"},i="https://s21aidntoken00blkbapp01.nxt.blackbaud.com";class s{static getRegisteredDomain(){for(const e of Object.keys(o)){const t=`.${e}`;if(this.CURRENT_DOMAIN===e||this.CURRENT_DOMAIN.substr(-t.length)===t)return e}}static getSTSDomain(){const e=this.getRegisteredDomain();return o[e]||i}}s.CURRENT_DOMAIN=window.location.hostname,t.BBAuthDomain=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.BBAuthDomUtility=class{static addCss(e){const t=document.createElement("style");return t.appendChild(document.createTextNode(e)),document.head.appendChild(t),t}static addIframe(e,t,n){const o=document.createElement("iframe");return o.className=t,o.title=n,o.src=e,this.addElToBodyTop(o),o}static removeCss(e){this.removeEl(e,document.head)}static removeEl(e,t=document.body){t.contains(e)&&t.removeChild(e)}static addElToBodyTop(e){const t=document.body;t.firstChild?t.insertBefore(e,t.firstChild):t.appendChild(e)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o="https://host.nxt.blackbaud.com";function i(e,t){if(e.origin===o){const n=e.data;return!!n&&n.source===t}return!1}t.BBAuthInterop=class{static postOmnibarMessage(e,t,n){t.source="auth-client",e.contentWindow.postMessage(t,n||o)}static messageIsFromOmnibar(e){return i(e,"skyux-spa-omnibar")}static messageIsFromToastContainer(e){return i(e,"skyux-spa-omnibar-toast-container")}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i=n(2),s=n(1);function r(e,t,n,o){return(o||void 0===o&&n)&&((e=e||{})[t]=n),e}function a(e,t,n,i,s){let a;return a=r(a,"environment_id",n),a=r(a,"legal_entity_id",s),a=r(a,"permission_scope",i,!(!n&&!s||!i)),new Promise((n,i)=>{!function(e,t,n,i,s){const r=new XMLHttpRequest;r.onreadystatechange=()=>{if(4===r.readyState)switch(r.status){case 0:s({code:o.BBAuthTokenErrorCode.Offline,message:"The user is offline."});break;case 200:i(r.responseText);break;case 401:s({code:o.BBAuthTokenErrorCode.NotLoggedIn,message:"The user is not logged in."});break;case 403:s({code:o.BBAuthTokenErrorCode.InvalidEnvironment,message:"The user is not a member of the specified environment."});break;default:r.status>=400&&s({code:o.BBAuthTokenErrorCode.Unspecified,message:"An unknown error occurred."})}},r.open("POST",e,!0),r.setRequestHeader(t.name,t.value),r.setRequestHeader("Accept","application/json"),r.setRequestHeader("Content-Type","application/json"),r.withCredentials=!0,n?r.send(JSON.stringify(n)):r.send()}(e,{name:"X-CSRF",value:t},a,e=>{const t=e?JSON.parse(e):void 0;n(t)},i)})}t.BBCsrfXhr=class{static request(e,t,n,r,c,d,u){return!c||r||d?new Promise((l,m)=>{new Promise((e,t)=>{u?e({csrf_token:"token_needed"}):a(i.BBAuthDomain.getSTSDomain()+"/session/csrf","token_needed").then(e).catch(t)}).then(t=>a(e,t.csrf_token,r,c,d)).then(l).catch(e=>{if(n||e.code===o.BBAuthTokenErrorCode.Offline)m(e);else switch(e.code){case o.BBAuthTokenErrorCode.NotLoggedIn:s.BBAuthNavigator.redirectToSignin(t);break;default:s.BBAuthNavigator.redirectToError(e.code)}})}):Promise.reject({code:o.BBAuthTokenErrorCode.PermissionScopeNoEnvironment,message:"You must also specify an environment or legal entity when specifying a permission scope."})}static requestWithToken(e,t){return new Promise((n,o)=>{const i=new XMLHttpRequest;i.onreadystatechange=()=>{if(4===i.readyState)switch(i.status){case 200:n(JSON.parse(i.responseText));break;default:o()}},i.open("GET",e,!0),i.setRequestHeader("Authorization","Bearer "+t),i.setRequestHeader("Accept","application/json"),i.send()})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(10),i=/1bb:\/\/([a-z]{3})-([a-z0-9]{5})(-[a-z]{4}[0-9]{2})?\/(.*)/;class s{static getUrl(e,t){const n=i.exec(e);let o=e,s=t?t.zone:void 0;return s&&(s=s.replace("-","")),n&&(n[3]&&(s=n[3].substring(1)),o=`https://${n[1]}-${s}.app.blackbaud.net/${n[2]}/${n[4]}`),Promise.resolve(o)}static getToken(e){return s.getTokenInternal(e)}static clearTokenCache(){s.tokenCache={}}static getTokenInternal(e){e=e||{};const{forceNewToken:t,disableRedirect:n}=e;if(s.mock)return Promise.resolve("mock_access_token_auth-client@blackbaud.com");const i=function(e){const{envId:t,permissionScope:n,leId:o}=e;return"token|"+(o||"-")+"|"+(t||"-")+"|"+(n||"-")}(e),r=s.tokenCache[i]=s.tokenCache[i]||{},a=(new Date).valueOf();return!t&&r.lastToken&&r.expirationTime&&r.expirationTime-a>6e4?Promise.resolve(r.lastToken):(r.pendingLookupPromise||(r.pendingLookupPromise=o.BBAuthTokenIntegration.getToken(n,e.envId,e.permissionScope,e.leId).then(e=>(r.expirationTime=(new Date).valueOf()+1e3*e.expires_in,r.lastToken=e.access_token,r.pendingLookupPromise=null,r.lastToken)).catch(e=>{throw r.pendingLookupPromise=null,e})),r.pendingLookupPromise)}}s.mock=!1,s.tokenCache={},t.BBAuth=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.Unspecified=0]="Unspecified",e[e.NotLoggedIn=1]="NotLoggedIn",e[e.InvalidEnvironment=2]="InvalidEnvironment",e[e.PermissionScopeNoEnvironment=3]="PermissionScopeNoEnvironment",e[e.Offline=4]="Offline"}(t.BBAuthTokenErrorCode||(t.BBAuthTokenErrorCode={}))},function(e,t,n){"use strict";function o(e){const t=e.split("."),n=[];for(const e of t){const t=parseInt(e,10)||0;n.push(t)}return n}Object.defineProperty(t,"__esModule",{value:!0});class i{static registerScript(e){return new Promise((t,n)=>{const o=document.createElement("script");o.onload=t,o.onerror=n,o.src=e,document.body.appendChild(o)})}static smartRegisterScript(e,t,n){return n&&function(e,t){const n=o(e),i=o(t);for(let e=0;e<n.length;e++)if(e<i.length){if(i[e]>n[e])return!0;if(i[e]<n[e])return!1}return!0}(t,n)?Promise.resolve():i.registerScript(e)}}t.BBOmnibarScriptLoader=i},function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(0)),o(n(12)),o(n(14))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(5),i=n(11),s=n(2);t.BBAuthTokenIntegration=class{static getToken(e,t,n,r){return void 0!==s.BBAuthDomain.getRegisteredDomain()||this.hostNameEndsWith("blackbaud.com")?o.BBCsrfXhr.request(s.BBAuthDomain.getSTSDomain()+"/oauth2/token",void 0,e,t,n,r,!0):i.BBAuthCrossDomainIframe.getToken({disableRedirect:e,envId:t,leId:r,permissionScope:n})}static hostNameEndsWith(e){return this.getLocationHostname().substr(-e.length)===e}static getLocationHostname(){return window.location.hostname}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(3),i=n(1),s=n(7),r="https://s21aidntoken00blkbapp01.nxt.blackbaud.com/Iframes/CrossDomainAuthFrame.html",a="security-token-svc",c="auth-client";class d{static reset(){this.requestCounter=0,this.tokenRequests={},this.iframeReadyPromise=new Promise(e=>this.iframeReadyResolve=e),this.listenerSetup=!1}static TARGET_ORIGIN(){return this.TARGETORIGIN}static getOrMakeIframe(){return d.iframeEl=document.getElementById("auth-cross-domain-iframe"),d.iframeEl||(d.iframeEl=o.BBAuthDomUtility.addIframe(r,"auth-cross-domain-iframe",""),d.iframeEl.id="auth-cross-domain-iframe",d.iframeEl.hidden=!0),d.iframeEl}static getToken(e){return this.setupListenersForIframe(),this.getTokenFromIframe(this.getOrMakeIframe(),e)}static setupListenersForIframe(){this.listenerSetup||(window.addEventListener("message",e=>{const t=e.data,n=t.requestId,o=this.tokenRequests[n];if(t.source===a||t.origin===this.TARGET_ORIGIN())switch(t.messageType){case"ready":this.iframeReadyResolve(!0);break;case"error":this.handleErrorMessage(t.value,o.reject,o.args.disableRedirect);break;case"getToken":const e={access_token:t.value,expires_in:0};o.resolve(e)}}),this.listenerSetup=!0)}static getTokenFromIframe(e,t){return new Promise((n,o)=>{const i=this.requestCounter++;d.tokenRequests[i]={args:t,reject:o,resolve:n},d.iframeReadyPromise.then(()=>{e.contentWindow.postMessage({messageType:"getToken",requestId:i,source:c,value:t},d.TARGET_ORIGIN())})})}static handleErrorMessage(e,t,n){if(n)t(e);else switch(e.code){case s.BBAuthTokenErrorCode.Offline:t(e);break;case s.BBAuthTokenErrorCode.NotLoggedIn:i.BBAuthNavigator.redirectToSignin(void 0);break;default:i.BBAuthNavigator.redirectToError(e.code)}}}d.listenerSetup=!1,d.iframeReadyPromise=new Promise(e=>d.iframeReadyResolve=e),d.tokenRequests={},d.requestCounter=0,d.TARGETORIGIN="https://s21aidntoken00blkbapp01.nxt.blackbaud.com",t.BBAuthCrossDomainIframe=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(n(13))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i=n(4),s=n(5),r=n(3),a=n(1);function c(e,t,n,s){let a,c;function d(){r.BBAuthDomUtility.removeEl(c),r.BBAuthDomUtility.removeCss(a),c=a=void 0,window.removeEventListener("message",l)}function l(r){if(!i.BBAuthInterop.messageIsFromOmnibar(r))return;const a=r.data;switch(a.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),i.BBAuthInterop.postOmnibarMessage(c,{contextDestinations:t,messageType:"context-provide"});break;case"get-token":u=a.tokenRequestId,l=a.disableRedirect,o.BBAuth.getToken({disableRedirect:l}).then(e=>{i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:u})},e=>{i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:u})});break;case"welcome-cancel":d(),s({reason:"canceled"});break;case"welcome-environment-selected":d(),setTimeout(()=>{e.envId=a.envId,n(e)},10)}var u,l}a=r.BBAuthDomUtility.addCss("\n.sky-omnibar-welcome-iframe {\n background-color: #fff;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n"),function(){const t=u.url+"?hosted=1&svcid="+encodeURIComponent(e.svcId)+"&url="+encodeURIComponent(e.url);c=r.BBAuthDomUtility.addIframe(t,"sky-omnibar-welcome-iframe","Welcome")}(),window.addEventListener("message",l)}function d(){a.BBAuthNavigator.redirectToError(o.BBAuthTokenErrorCode.InvalidEnvironment)}class u{static ensureContext(e){const{envId:t,envIdRequired:n,leId:i,leIdRequired:r,svcId:a}=e;return!t&&n||!i&&r?new Promise((t,n)=>{a?o.BBAuth.getToken().then(o=>{let i="https://s21anavnavaf00blkbapp01.sky.blackbaud.com/user/destinations?svcid="+encodeURIComponent(a);e.url&&(i+="&referringurl="+encodeURIComponent(e.url)),s.BBCsrfXhr.requestWithToken(i,o).then(o=>{const i=o&&o.items,s=i&&i.length;1===s?(e.url=i[0].url,t(e)):s>1?c(e,o,t,n):d()})}):d()}):Promise.resolve(e)}}u.url="https://host.nxt.blackbaud.com/omnibar/welcome",t.BBContextProvider=u},function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(15)),o(n(26)),o(n(27))},function(e,t,n){"use strict";var o=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(i,s){function r(e){try{c(o.next(e))}catch(e){s(e)}}function a(e){try{c(o.throw(e))}catch(e){s(e)}}function c(e){e.done?i(e.value):new n((function(t){t(e.value)})).then(r,a)}c((o=o.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const i=n(16),s=n(0),r=n(4),a=n(1),c=n(3),d=n(19),u=n(23),l=n(24),m=n(25),h="sky-omnibar-iframe-expanded",p="sky-omnibar-loading";let f,b,v,g,B,y,k,I,T,A,w;function O(){g=c.BBAuthDomUtility.addIframe(B.url||"https://host.nxt.blackbaud.com/omnibar/",`sky-omnibar-iframe ${p}`,"Navigation")}function E(){const e=document.location.href;r.BBAuthInterop.postOmnibarMessage(g,{href:e,messageType:"location-change"}),m.BBOmnibarToastContainer.updateUrl(e)}function _(){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"push-notifications-open"})}function N(){I||(I=!0,D.pushNotificationsEnabled().then(e=>{e?m.BBOmnibarToastContainer.init({envId:B.envId,leId:B.leId,navigateCallback:M,navigateUrlCallback:x,openMenuCallback:_,svcId:B.svcId,url:document.location.href}).then(()=>{l.BBOmnibarPushNotifications.connect(B.leId,B.envId,e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"push-notifications-update",pushNotifications:e}),m.BBOmnibarToastContainer.showNewNotifications(e),T=e&&e.notifications&&e.notifications.filter(e=>!e.isRead).length,L()})}):I=!1}))}function R(){function e(e){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"refresh-user",token:e}),e?N():I&&(m.BBOmnibarToastContainer.destroy(),l.BBOmnibarPushNotifications.disconnect(),I=!1)}s.BBAuth.clearTokenCache(),s.BBAuth.getToken({disableRedirect:!0,forceNewToken:!0}).then(e).catch(()=>e(void 0))}function C(){u.BBOmnibarUserActivityPrompt.show({sessionRenewCallback:()=>{d.BBOmnibarUserActivity.userRenewedSession()}})}function S(){u.BBOmnibarUserActivityPrompt.hide()}function P(){d.BBOmnibarUserActivity.startTracking(R,C,S,B.allowAnonymous,y)}function M(e){const t=B.nav;t&&t.beforeNavCallback&&!1===t.beforeNavCallback(e)||a.BBAuthNavigator.navigate(e.url)}function x(e){a.BBAuthNavigator.navigate(e)}function U(e){if(!r.BBAuthInterop.messageIsFromOmnibar(e))return;const t=e.data,n=B.nav;switch(t.messageType){case"ready":r.BBAuthInterop.postOmnibarMessage(g,{messageType:"host-ready"}),function(){const e=history.pushState,t=history.replaceState;history.pushState=function(){const t=e.apply(history,arguments);return E(),t},history.replaceState=function(){const e=t.apply(history,arguments);return E(),e}}(),r.BBAuthInterop.postOmnibarMessage(g,{compactNavOnly:B.compactNavOnly,enableHelp:B.enableHelp,envId:B.envId,hideResourceLinks:B.hideResourceLinks,leId:B.leId,localNavItems:n&&n.localNavItems,localNotifications:!!B.notifications,localSearch:!!B.onSearch,messageType:"nav-ready",navVersion:B.navVersion,services:n&&n.services,svcId:B.svcId,theme:B.theme}),function(){const e=B.notifications;e&&e.onReady({updateNotifications:e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"notifications-update",notifications:e})}})}(),N(),E(),k();break;case"display-ready":b.classList.remove(p),g.classList.remove(p);break;case"expand":g.classList.add(h);break;case"collapse":g.classList.remove(h);break;case"navigate-url":x(t.url);break;case"navigate":M(t.navItem);break;case"search":c=t.searchArgs,B.onSearch&&B.onSearch(c).then(e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"search-results",results:e})});break;case"get-token":i=t.tokenRequestId,a=t.disableRedirect,s.BBAuth.getToken({disableRedirect:a}).then(e=>{P(),r.BBAuthInterop.postOmnibarMessage(g,{messageType:"token",token:e,tokenRequestId:i})},e=>{P(),r.BBAuthInterop.postOmnibarMessage(g,{messageType:"token-fail",reason:e,tokenRequestId:i})});break;case"help-open":!function(){const e=window.BBHELP;e&&e.HelpWidget.open()}();break;case"notification-read":!function(e){const t=B.notifications;t&&t.onNotificationRead&&t.onNotificationRead(e)}(t.notification);break;case"push-notifications-change":o=t.notifications,l.BBOmnibarPushNotifications.updateNotifications(o);break;case"session-renew":d.BBOmnibarUserActivity.userRenewedSession();break;case"environment-update":!function(e){const t="sky-omnibar-environment-visible",n=document.body.classList;e=e||"",f.innerText=e,e?n.add(t):n.remove(t)}(t.name);break;case"legacy-keep-alive-url-change":y=t.url,P();break;case"selected-service-update":A=t.serviceName,L()}var o,i,a,c}function L(){if(w){const e=w.slice();A&&e.push(A);let t=e.join(" - ");T&&(t=`(${T}) ${t}`),document.title=t}}class D{static load(e){return B=B=e,y=B.legacyKeepAliveUrl,new Promise(e=>{k=e,function(){let e="background: linear-gradient(to right, #71bf44 0, #31b986 50%, #00b2ec 100%);",t="#4d5259";const n=B.theme;if(n){const o=n.accent;t=n.backgroundColor||t,!1===o?e="display: none;":o&&o.color&&(e=`background-color: ${o.color};`)}v=c.BBAuthDomUtility.addCss(`\nbody {\n margin-top: 50px;\n}\n\n#bb-help-container {\n padding-top: 1px;\n}\n\n.sky-omnibar-iframe,\n.sky-omnibar-placeholder {\n border: none;\n height: 50px;\n width: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n z-index: 1000;\n}\n\n.sky-omnibar-placeholder {\n background-color: ${t};\n display: none;\n}\n\n.sky-omnibar-placeholder-accent {\n height: 5px;\n ${e}\n}\n\n.sky-omnibar-placeholder.${p} {\n display: block;\n}\n\n.sky-omnibar-iframe.${p} {\n visibility: hidden;\n}\n\n.${h} {\n height: 100%;\n}\n\n.sky-omnibar-environment {\n background-color: #e1e1e3;\n color: #282b31;\n font-family: "Blackbaud Sans", "Open Sans", "Helvetica Neue", Arial, sans-serif;\n font-size: 12px;\n font-weight: 400;\n height: 0;\n line-height: 24px;\n overflow: hidden;\n padding: 0 15px;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.sky-omnibar-environment-visible .sky-omnibar-environment {\n height: 24px;\n}\n`)}(),(b=document.createElement("div")).className=`sky-omnibar-placeholder ${p}`,b.innerHTML='<div class="sky-omnibar-placeholder-accent"></div>',document.body.appendChild(b),(f=document.createElement("div")).className="sky-omnibar-environment",c.BBAuthDomUtility.addElToBodyTop(f),O(),window.addEventListener("message",U)})}static update(e){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"update",updateArgs:e})}static setTitle(e){w=e&&e.titleParts,L()}static pushNotificationsEnabled(){return o(this,void 0,void 0,(function*(){return B?s.BBAuth.getToken({disableRedirect:!0,envId:B.envId,leId:B.leId,permissionScope:"Notifications"}).then(e=>{let t=i(e)["1bb.entitlements"];return!!t&&(t=Array.isArray(t)?t:[t]).indexOf("notif")>-1}).catch(()=>!1):Promise.resolve(!1)}))}static destroy(){m.BBOmnibarToastContainer.destroy(),l.BBOmnibarPushNotifications.disconnect(),c.BBAuthDomUtility.removeEl(b),c.BBAuthDomUtility.removeEl(g),c.BBAuthDomUtility.removeEl(f),c.BBAuthDomUtility.removeCss(v),window.removeEventListener("message",U),B=v=b=g=f=k=I=T=w=A=void 0}}t.BBOmnibar=D},function(e,t,n){"use strict";var o=n(17);function i(e){this.message=e}i.prototype=new Error,i.prototype.name="InvalidTokenError",e.exports=function(e,t){if("string"!=typeof e)throw new i("Invalid token specified");var n=!0===(t=t||{}).header?0:1;try{return JSON.parse(o(e.split(".")[n]))}catch(e){throw new i("Invalid token specified: "+e.message)}},e.exports.InvalidTokenError=i},function(e,t,n){var o=n(18);e.exports=function(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(o(e).replace(/(.)/g,(function(e,t){var n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(t)}catch(e){return o(t)}}},function(e,t){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function o(e){this.message=e}o.prototype=new Error,o.prototype.name="InvalidCharacterError",e.exports="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var t=String(e).replace(/=+$/,"");if(t.length%4==1)throw new o("'atob' failed: The string to be decoded is not correctly encoded.");for(var i,s,r=0,a=0,c="";s=t.charAt(a++);~s&&(i=r%4?64*i+s:s,r++%4)?c+=String.fromCharCode(255&i>>(-2*r&6)):0)s=n.indexOf(s);return c}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(2),i=n(5),s=n(20),r=n(21),a=n(22),c=n(1);let d,u,l,m,h,p,f,b,v,g,B,y,k,I,T="";function A(){b=Date.now()}function w(e){e.clientX===u&&e.clientY===l||(u=e.clientX,l=e.clientY,A())}function O(){const e=Date.now();(!v||e-v>R.MIN_RENEWAL_RETRY)&&(v=e,i.BBCsrfXhr.request(o.BBAuthDomain.getSTSDomain()+"/session/renew",{inactivity:1}).catch(()=>void 0))}function E(){f=!0,p()}function _(){f=!1,A(),m()}function N(){I?c.BBAuthNavigator.navigate(I):c.BBAuthNavigator.redirectToSignoutForInactivity()}class R{static startTracking(e,t,n,o,i){d&&o===B&&i===y||(R.stopTracking(),h=e,p=t,m=n,B=o,y=i,document.addEventListener("keypress",A),document.addEventListener("mousemove",w),B||O(),g=setInterval(()=>{r.BBOmnibarUserSessionExpiration.getSessionExpiration(T,k,B).then(e=>{d&&s.BBOmnibarUserActivityProcessor.process({allowAnonymous:B,closeInactivityPrompt:_,expirationDate:e,inactivityPromptDuration:R.INACTIVITY_PROMPT_DURATION,isShowingInactivityPrompt:f,lastActivity:b,maxSessionAge:R.MAX_SESSION_AGE,minRenewalAge:R.MIN_RENEWAL_AGE,redirectForInactivity:N,renewSession:O,showInactivityPrompt:E})})},R.ACTIVITY_TIMER_INTERVAL),a.BBOmnibarUserSessionWatcher.start(o,i,h,e=>{k=e.legacyTtl,T=e.refreshId,I=e.legacySigninUrl}),d=!0)}static userRenewedSession(){_(),O()}static stopTracking(){a.BBOmnibarUserSessionWatcher.stop(),r.BBOmnibarUserSessionExpiration.reset(),document.removeEventListener("keypress",A),document.removeEventListener("mousemove",w),g&&(clearInterval(g),g=void 0),d=u=l=b=v=f=h=p=m=B=y=void 0}}R.ACTIVITY_TIMER_INTERVAL=1e3,R.MIN_RENEWAL_RETRY=6e4,R.INACTIVITY_PROMPT_DURATION=12e4,R.MIN_RENEWAL_AGE=3e5,R.MAX_SESSION_AGE=54e5,t.BBOmnibarUserActivity=R},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.BBOmnibarUserActivityProcessor=class{static process(e){const{allowAnonymous:t,closeInactivityPrompt:n,expirationDate:o,inactivityPromptDuration:i,isShowingInactivityPrompt:s,lastActivity:r,maxSessionAge:a,minRenewalAge:c,redirectForInactivity:d,renewSession:u,showInactivityPrompt:l}=e,m=Date.now();if(null===o)return;!t&&m>o&&d();const h=o-i,p=o-a+c;s?m<h&&n():r>p?u():!t&&m>h&&l()}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(2),i=n(5);let s;t.BBOmnibarUserSessionExpiration=class{static getSessionExpiration(e,t,n){const r=function(e,t){if(s&&s.refreshId===e&&s.allowAnonymous===t)return s.promise;const n=new Promise((e,n)=>{i.BBCsrfXhr.request(o.BBAuthDomain.getSTSDomain()+"/session/ttl",void 0,t).then(t=>{const n=null===t?null:Date.now()+1e3*t;e(n)},()=>{e(null)})});return s={allowAnonymous:t,promise:n,refreshId:e},n}(e,n);return new Promise((e,n)=>{r.then(n=>{let o;if(null===n)o=null;else if("number"==typeof t){const e=Date.now()+t;o=Math.min(n,e)}else o=n;e(o)})})}static reset(){s=void 0}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(4),i=n(1),s=n(2);let r,a,c,d,u,l,m,h,p={};function f(e){if(e){const t=e.split("://");return`${t[0]}://${t[1].split("/")[0]}`}}function b(e,t){const n=document.createElement("iframe");return n.className=e,n.width="0",n.height="0",n.frameBorder="0",n.src=t,n.tabIndex=-1,n.setAttribute("aria-hidden","true"),document.body.appendChild(n),n}function v(e){if("string"==typeof e.data){let t;try{t=JSON.parse(e.data)}catch(e){return}if("session_change"===t.messageType){const e=t.message,n=e&&e.sessionId,s=e&&e.refreshId;n||u||(h?i.BBAuthNavigator.navigate(h):i.BBAuthNavigator.redirectToSignin()),void 0!==p.refreshId&&s!==p.refreshId&&function(e){m&&o.BBAuthInterop.postOmnibarMessage(m,e,f(a))}({messageType:"session-refresh"}),void 0!==p.sessionId&&n!==p.sessionId&&c(),p.refreshId=s,p.sessionId=n,d(p)}}}function g(e){switch(e.origin){case B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN:v(e);break;case f(a):!function(e){const t=e.data;switch(t.messageType){case"ready":p.legacyTtl=t.ttl,h=t.signinUrl,d(p)}}(e)}}class B{static start(e,t,n,o){r&&e===u&&t===a||(B.stop(),u=e,c=n,a=t,d=o,function(){const e=B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN+"/SessionWatcher.html?origin="+encodeURIComponent(location.origin);l=b("sky-omnibar-iframe-session-watcher",e)}(),a&&(m=b("sky-omnibar-iframe-legacy-keep-alive",a)),window.addEventListener("message",g,!1),r=!0)}static stop(){window.removeEventListener("message",g,!1),l&&(document.body.removeChild(l),l=void 0),m&&(document.body.removeChild(m),m=void 0),p={},r=u=c=a=h=d=void 0}}B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN=s.BBAuthDomain.getSTSDomain(),t.BBOmnibarUserSessionWatcher=B},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(3),i=n(4);let s,r,a;function c(e){if(!i.BBAuthInterop.messageIsFromOmnibar(e))return;switch(e.data.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(r,{messageType:"host-ready"}),r.classList.add("sky-omnibar-inactivity-iframe-ready");break;case"session-renew":a()}}class d{static show(e){this.hide(),a=e.sessionRenewCallback,s=o.BBAuthDomUtility.addCss("\n .sky-omnibar-inactivity-iframe {\n background-color: transparent;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 100000;\n visibility: hidden;\n }\n\n .sky-omnibar-inactivity-iframe-ready {\n visibility: visible;\n }\n "),function(){const e=d.url;r=o.BBAuthDomUtility.addIframe(e,"sky-omnibar-inactivity-iframe","Inactivity Prompt")}(),window.addEventListener("message",c)}static hide(){r&&(o.BBAuthDomUtility.removeEl(r),o.BBAuthDomUtility.removeCss(s),r=s=a=void 0,window.removeEventListener("message",c))}}d.url="https://host.nxt.blackbaud.com/omnibar/inactivity",t.BBOmnibarUserActivityPrompt=d},function(e,t,n){"use strict";var o=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(i,s){function r(e){try{c(o.next(e))}catch(e){s(e)}}function a(e){try{c(o.throw(e))}catch(e){s(e)}}function c(e){e.done?i(e.value):new n((function(t){t(e.value)})).then(r,a)}c((o=o.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const i=n(0),s=n(8);let r;class a{static connect(e,t,n){return o(this,void 0,void 0,(function*(){return r||(r=window.BBNotificationsClient?Promise.resolve():s.BBOmnibarScriptLoader.registerScript(this.NOTIFICATIONS_CLIENT_URL)),r.then(()=>{BBNotificationsClient.BBNotifications.init({tokenCallback:()=>i.BBAuth.getToken({disableRedirect:!0,envId:t,leId:e})}),BBNotificationsClient.BBNotifications.addListener(n)})}))}static disconnect(){return o(this,void 0,void 0,(function*(){return r?r.then(()=>{BBNotificationsClient.BBNotifications.destroy(),r=void 0}):Promise.resolve()}))}static updateNotifications(e){BBNotificationsClient.BBNotifications.updateNotifications(e)}}a.NOTIFICATIONS_CLIENT_URL="https://sky.blackbaudcdn.net/static/notifications-client/1/notifications-client.global.min.js",t.BBOmnibarPushNotifications=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(6),i=n(3),s=n(4),r="sky-omnibar-toast-container",a=`${r}-ready`,c=`${r}-empty`,d=20;let u,l,m,h,p,f;function b(e){const t=document.querySelector(e);return t?t.getBoundingClientRect().height:0}function v(){l&&s.BBAuthInterop.postOmnibarMessage(l,{href:f,messageType:"location-change"})}function g(e){if(!s.BBAuthInterop.messageIsFromToastContainer(e))return;const t=e.data;switch(t.messageType){case"toast-ready":s.BBAuthInterop.postOmnibarMessage(l,{messageType:"host-ready"}),s.BBAuthInterop.postOmnibarMessage(l,{envId:p.envId,leId:p.leId,messageType:"nav-ready",svcId:p.svcId}),v(),l.classList.add(a),h();break;case"get-token":n=t.tokenRequestId,i=t.disableRedirect,o.BBAuth.getToken({disableRedirect:i}).then(e=>{s.BBAuthInterop.postOmnibarMessage(l,{messageType:"token",token:e,tokenRequestId:n})},e=>{s.BBAuthInterop.postOmnibarMessage(l,{messageType:"token-fail",reason:e,tokenRequestId:n})});break;case"navigate-url":p.navigateUrlCallback(t.url);break;case"navigate":p.navigateCallback(t.navItem);break;case"toast-container-change":t.height>0?(l.style.height=t.height+"px",l.style.top=b(".sky-omnibar-iframe")+b(".sky-omnibar-environment")+d+"px",l.classList.remove(c)):l.classList.add(c);break;case"push-notifications-open":p.openMenuCallback()}var n,i}class B{static init(e){return p=e,f=e.url,m||(m=new Promise(e=>{h=e,l||(u=i.BBAuthDomUtility.addCss(`\n.${r} {\n border: none;\n display: none;\n position: fixed;\n right: 0px;\n height: 0px;\n width: 300px;\n /* z-index is 1 less than omnibar so menus will display over top the toast container */\n z-index: 999;\n}\n\n.${a} {\n display: block;\n}\n\n.${c} {\n visibility: hidden;\n}\n`),(l=document.createElement("iframe")).src=B.CONTAINER_URL,l.className=`${r} ${c}`,l.title="Toast container",document.body.appendChild(l),window.addEventListener("message",g))})),m}static showNewNotifications(e){s.BBAuthInterop.postOmnibarMessage(l,{messageType:"push-notifications-update",pushNotifications:e})}static updateUrl(e){f=e,v()}static destroy(){u&&i.BBAuthDomUtility.removeCss(u),l&&i.BBAuthDomUtility.removeEl(l),f=l=p=m=h=u=void 0,window.removeEventListener("message",g)}}B.CONTAINER_URL="https://host.nxt.blackbaud.com/omnibar/toast",t.BBOmnibarToastContainer=B},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(8);function i(){return window.jQuery}t.BBOmnibarLegacy=class{static load(e){return new Promise(t=>{const n=i(),s=n&&n.fn&&n.fn.jquery;o.BBOmnibarScriptLoader.smartRegisterScript("https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.js","2.1.0",s).then(()=>o.BBOmnibarScriptLoader.registerScript("https://cdnjs.cloudflare.com/ajax/libs/easyXDM/2.4.17.1/easyXDM.min.js")).then(()=>o.BBOmnibarScriptLoader.registerScript("https://signin.blackbaud.com/Omnibar.min.js")).then(()=>{document.body.classList.add("bb-omnibar-height-padding");const n=document.createElement("div");n.setAttribute("data-omnibar-el",""),document.body.appendChild(n),(e=e||{})["z-index"]=1e3,e.afterLoad=t,e.menuEl&&(e.menuEl=i()(e.menuEl)),BBAUTH.Omnibar.load(n,e)})})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0})}]); |
@@ -1,1 +0,1 @@ | ||
window.BBAuthClient=function(e){var n={};function t(o){if(n[o])return n[o].exports;var i=n[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,t),i.l=!0,i.exports}return t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:o})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(t.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var i in e)t.d(o,i,function(n){return e[n]}.bind(null,i));return o},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="",t(t.s=9)}([function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(6)),o(t(7))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i="https://signin.blackbaud.com/signin/",r=encodeURIComponent;function a(e){var n=i+"?redirectUrl="+r(location.href);return e&&(n+="&inactivity=1"),n}var s=function(){function e(){}return e.navigate=function(e,n){n?location.replace(e):location.href=e},e.redirectToSignin=function(e){var n=a();e&&(n+="&"+function(e){var n=[];for(var t in e)e.hasOwnProperty(t)&&n.push(r(t)+"="+r(e[t]));return n.join("&")}(e)),this.navigate(n)},e.redirectToSignoutForInactivity=function(){var e=a(!0),n=i+"sign-out?redirectUrl="+r(e);this.navigate(n)},e.redirectToError=function(e){var n,t;switch(e){case o.BBAuthTokenErrorCode.InvalidEnvironment:t="invalid_env",n="security";break;default:n="broken"}var i="https://host.nxt.blackbaud.com/errors/"+n+"?source=auth-client&url="+r(location.href);t&&(i+="&code="+r(t)),this.navigate(i)},e}();n.BBAuthNavigator=s},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o={"bbk12.com":"https://sts-sso.bbk12.com","blackbaudfaith.com":"https://sts.blackbaudfaith.com","donorcentral.com":"https://sts-dc.donorcentral.com","mycampus-app.com":"https://sts-sso.mycampus-app.com","myschoolapp.com":"https://sts-sso.myschoolapp.com","myschoolautomation.com":"https://sts-sso.myschoolautomation.com","myschooldemo.com":"https://sts-sso.myschooldemo.com","myschooltraining.com":"https://sts-sso.myschooltraining.com"},i=function(){function e(){}return e.getRegisteredDomain=function(){for(var e=0,n=Object.keys(o);e<n.length;e++){var t=n[e],i="."+t;if(this.CURRENT_DOMAIN===t||this.CURRENT_DOMAIN.substr(-i.length)===i)return t}},e.getSTSDomain=function(){var e=this.getRegisteredDomain();return o[e]||"https://s21aidntoken00blkbapp01.nxt.blackbaud.com"},e.CURRENT_DOMAIN=window.location.hostname,e}();n.BBAuthDomain=i},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){}return e.addCss=function(e){var n=document.createElement("style");return n.appendChild(document.createTextNode(e)),document.head.appendChild(n),n},e.addIframe=function(e,n,t){var o=document.createElement("iframe");return o.className=n,o.title=t,o.src=e,this.addElToBodyTop(o),o},e.removeCss=function(e){this.removeEl(e,document.head)},e.removeEl=function(e,n){void 0===n&&(n=document.body),n.contains(e)&&n.removeChild(e)},e.addElToBodyTop=function(e){var n=document.body;n.firstChild?n.insertBefore(e,n.firstChild):n.appendChild(e)},e}();n.BBAuthDomUtility=o},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o="https://host.nxt.blackbaud.com";function i(e,n){if(e.origin===o){var t=e.data;return!!t&&t.source===n}return!1}var r=function(){function e(){}return e.postOmnibarMessage=function(e,n,t){n.source="auth-client",e.contentWindow.postMessage(n,t||o)},e.messageIsFromOmnibar=function(e){return i(e,"skyux-spa-omnibar")},e.messageIsFromToastContainer=function(e){return i(e,"skyux-spa-omnibar-toast-container")},e}();n.BBAuthInterop=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i=t(2),r=t(1);function a(e,n,t,o){return(o||void 0===o&&t)&&((e=e||{})[n]=t),e}function s(e,n,t,i,r){var s;return s=a(s,"environment_id",t),s=a(s,"legal_entity_id",r),s=a(s,"permission_scope",i,!(!t&&!r||!i)),new Promise((function(t,i){!function(e,n,t,i,r){var a=new XMLHttpRequest;a.onreadystatechange=function(){if(4===a.readyState)switch(a.status){case 0:r({code:o.BBAuthTokenErrorCode.Offline,message:"The user is offline."});break;case 200:i(a.responseText);break;case 401:r({code:o.BBAuthTokenErrorCode.NotLoggedIn,message:"The user is not logged in."});break;case 403:r({code:o.BBAuthTokenErrorCode.InvalidEnvironment,message:"The user is not a member of the specified environment."});break;default:a.status>=400&&r({code:o.BBAuthTokenErrorCode.Unspecified,message:"An unknown error occurred."})}},a.open("POST",e,!0),a.setRequestHeader(n.name,n.value),a.setRequestHeader("Accept","application/json"),a.setRequestHeader("Content-Type","application/json"),a.withCredentials=!0,t?a.send(JSON.stringify(t)):a.send()}(e,{name:"X-CSRF",value:n},s,(function(e){var n=e?JSON.parse(e):void 0;t(n)}),i)}))}var c=function(){function e(){}return e.request=function(e,n,t,a,c,u,d){return!c||a||u?new Promise((function(l,f){new Promise((function(e,n){d?e({csrf_token:"token_needed"}):s(i.BBAuthDomain.getSTSDomain()+"/session/csrf","token_needed").then(e).catch(n)})).then((function(n){return s(e,n.csrf_token,a,c,u)})).then(l).catch((function(e){if(t||e.code===o.BBAuthTokenErrorCode.Offline)f(e);else switch(e.code){case o.BBAuthTokenErrorCode.NotLoggedIn:r.BBAuthNavigator.redirectToSignin(n);break;default:r.BBAuthNavigator.redirectToError(e.code)}}))})):Promise.reject({code:o.BBAuthTokenErrorCode.PermissionScopeNoEnvironment,message:"You must also specify an environment or legal entity when specifying a permission scope."})},e.requestWithToken=function(e,n){return new Promise((function(t,o){var i=new XMLHttpRequest;i.onreadystatechange=function(){if(4===i.readyState)switch(i.status){case 200:t(JSON.parse(i.responseText));break;default:o()}},i.open("GET",e,!0),i.setRequestHeader("Authorization","Bearer "+n),i.setRequestHeader("Accept","application/json"),i.send()}))},e}();n.BBCsrfXhr=c},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(10),i=/1bb:\/\/([a-z]{3})-([a-z0-9]{5})(-[a-z]{4}[0-9]{2})?\/(.*)/;var r=function(){function e(){}return e.getUrl=function(e,n){var t=i.exec(e),o=e,r=n?n.zone:void 0;return r&&(r=r.replace("-","")),t&&(t[3]&&(r=t[3].substring(1)),o="https://"+t[1]+"-"+r+".app.blackbaud.net/"+t[2]+"/"+t[4]),Promise.resolve(o)},e.getToken=function(n){return e.getTokenInternal(n)},e.clearTokenCache=function(){e.tokenCache={}},e.getTokenInternal=function(n){var t=(n=n||{}).forceNewToken,i=n.disableRedirect;if(e.mock)return Promise.resolve("mock_access_token_auth-client@blackbaud.com");var r=function(e){var n=e.envId,t=e.permissionScope;return"token|"+(e.leId||"-")+"|"+(n||"-")+"|"+(t||"-")}(n),a=e.tokenCache[r]=e.tokenCache[r]||{},s=(new Date).valueOf();return!t&&a.lastToken&&a.expirationTime&&a.expirationTime-s>6e4?Promise.resolve(a.lastToken):(a.pendingLookupPromise||(a.pendingLookupPromise=o.BBAuthTokenIntegration.getToken(i,n.envId,n.permissionScope,n.leId).then((function(e){return a.expirationTime=(new Date).valueOf()+1e3*e.expires_in,a.lastToken=e.access_token,a.pendingLookupPromise=null,a.lastToken})).catch((function(e){throw a.pendingLookupPromise=null,e}))),a.pendingLookupPromise)},e.mock=!1,e.tokenCache={},e}();n.BBAuth=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),function(e){e[e.Unspecified=0]="Unspecified",e[e.NotLoggedIn=1]="NotLoggedIn",e[e.InvalidEnvironment=2]="InvalidEnvironment",e[e.PermissionScopeNoEnvironment=3]="PermissionScopeNoEnvironment",e[e.Offline=4]="Offline"}(n.BBAuthTokenErrorCode||(n.BBAuthTokenErrorCode={}))},function(e,n,t){"use strict";function o(e){for(var n=[],t=0,o=e.split(".");t<o.length;t++){var i=o[t],r=parseInt(i,10)||0;n.push(r)}return n}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(){}return e.registerScript=function(e){return new Promise((function(n,t){var o=document.createElement("script");o.onload=n,o.onerror=t,o.src=e,document.body.appendChild(o)}))},e.smartRegisterScript=function(n,t,i){return i&&function(e,n){for(var t=o(e),i=o(n),r=0;r<t.length;r++)if(r<i.length){if(i[r]>t[r])return!0;if(i[r]<t[r])return!1}return!0}(t,i)?Promise.resolve():e.registerScript(n)},e}();n.BBOmnibarScriptLoader=i},function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(0)),o(t(12)),o(t(14))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(5),i=t(11),r=t(2),a=function(){function e(){}return e.getToken=function(e,n,t,a){return void 0!==r.BBAuthDomain.getRegisteredDomain()||this.hostNameEndsWith("blackbaud.com")?o.BBCsrfXhr.request(r.BBAuthDomain.getSTSDomain()+"/oauth2/token",void 0,e,n,t,a,!0):i.BBAuthCrossDomainIframe.getToken({disableRedirect:e,envId:n,leId:a,permissionScope:t})},e.hostNameEndsWith=function(e){return this.getLocationHostname().substr(-e.length)===e},e.getLocationHostname=function(){return window.location.hostname},e}();n.BBAuthTokenIntegration=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(3),i=t(1),r=t(7),a=function(){function e(){}return e.reset=function(){var e=this;this.requestCounter=0,this.tokenRequests={},this.iframeReadyPromise=new Promise((function(n){return e.iframeReadyResolve=n})),this.listenerSetup=!1},e.TARGET_ORIGIN=function(){return this.TARGETORIGIN},e.getOrMakeIframe=function(){return e.iframeEl=document.getElementById("auth-cross-domain-iframe"),e.iframeEl||(e.iframeEl=o.BBAuthDomUtility.addIframe("https://s21aidntoken00blkbapp01.nxt.blackbaud.com/Iframes/CrossDomainAuthFrame.html","auth-cross-domain-iframe",""),e.iframeEl.id="auth-cross-domain-iframe",e.iframeEl.hidden=!0),e.iframeEl},e.getToken=function(e){return this.setupListenersForIframe(),this.getTokenFromIframe(this.getOrMakeIframe(),e)},e.setupListenersForIframe=function(){var e=this;this.listenerSetup||(window.addEventListener("message",(function(n){var t=n.data,o=t.requestId,i=e.tokenRequests[o];if("security-token-svc"===t.source||t.origin===e.TARGET_ORIGIN())switch(t.messageType){case"ready":e.iframeReadyResolve(!0);break;case"error":e.handleErrorMessage(t.value,i.reject,i.args.disableRedirect);break;case"getToken":var r={access_token:t.value,expires_in:0};i.resolve(r)}})),this.listenerSetup=!0)},e.getTokenFromIframe=function(n,t){var o=this;return new Promise((function(i,r){var a=o.requestCounter++;e.tokenRequests[a]={args:t,reject:r,resolve:i},e.iframeReadyPromise.then((function(){n.contentWindow.postMessage({messageType:"getToken",requestId:a,source:"auth-client",value:t},e.TARGET_ORIGIN())}))}))},e.handleErrorMessage=function(e,n,t){if(t)n(e);else switch(e.code){case r.BBAuthTokenErrorCode.Offline:n(e);break;case r.BBAuthTokenErrorCode.NotLoggedIn:i.BBAuthNavigator.redirectToSignin(void 0);break;default:i.BBAuthNavigator.redirectToError(e.code)}},e.listenerSetup=!1,e.iframeReadyPromise=new Promise((function(n){return e.iframeReadyResolve=n})),e.tokenRequests={},e.requestCounter=0,e.TARGETORIGIN="https://s21aidntoken00blkbapp01.nxt.blackbaud.com",e}();n.BBAuthCrossDomainIframe=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),function(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}(t(13))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i=t(4),r=t(5),a=t(3),s=t(1);function c(e,n,t,r){var s,c,u;function l(){a.BBAuthDomUtility.removeEl(c),a.BBAuthDomUtility.removeCss(s),c=s=void 0,window.removeEventListener("message",f)}function f(a){if(i.BBAuthInterop.messageIsFromOmnibar(a)){var s,u,d=a.data;switch(d.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),i.BBAuthInterop.postOmnibarMessage(c,{contextDestinations:n,messageType:"context-provide"});break;case"get-token":s=d.tokenRequestId,u=d.disableRedirect,o.BBAuth.getToken({disableRedirect:u}).then((function(e){i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:s})}),(function(e){i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:s})}));break;case"welcome-cancel":l(),r({reason:"canceled"});break;case"welcome-environment-selected":l(),setTimeout((function(){e.envId=d.envId,t(e)}),10)}}}s=a.BBAuthDomUtility.addCss("\n.sky-omnibar-welcome-iframe {\n background-color: #fff;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n"),u=d.url+"?hosted=1&svcid="+encodeURIComponent(e.svcId)+"&url="+encodeURIComponent(e.url),c=a.BBAuthDomUtility.addIframe(u,"sky-omnibar-welcome-iframe","Welcome"),window.addEventListener("message",f)}function u(){s.BBAuthNavigator.redirectToError(o.BBAuthTokenErrorCode.InvalidEnvironment)}var d=function(){function e(){}return e.ensureContext=function(e){var n=e.envId,t=e.envIdRequired,i=e.leId,a=e.leIdRequired,s=e.svcId;return!n&&t||!i&&a?new Promise((function(n,t){s?o.BBAuth.getToken().then((function(o){var i="https://s21anavnavaf00blkbapp01.sky.blackbaud.com/user/destinations?svcid="+encodeURIComponent(s);e.url&&(i+="&referringurl="+encodeURIComponent(e.url)),r.BBCsrfXhr.requestWithToken(i,o).then((function(o){var i=o&&o.items,r=i&&i.length;1===r?(e.url=i[0].url,n(e)):r>1?c(e,o,n,t):u()}))})):u()})):Promise.resolve(e)},e.url="https://host.nxt.blackbaud.com/omnibar/welcome",e}();n.BBContextProvider=d},function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(15)),o(t(26)),o(t(27))},function(e,n,t){"use strict";var o=this&&this.__awaiter||function(e,n,t,o){return new(t||(t=Promise))((function(i,r){function a(e){try{c(o.next(e))}catch(e){r(e)}}function s(e){try{c(o.throw(e))}catch(e){r(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((o=o.apply(e,n||[])).next())}))},i=this&&this.__generator||function(e,n){var t,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===r[0]||2===r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=n.call(e,a)}catch(e){r=[6,e],o=0}finally{t=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}};Object.defineProperty(n,"__esModule",{value:!0});var r,a,s,c,u,d,l,f,m,h,p,v=t(16),b=t(0),y=t(4),g=t(1),B=t(3),k=t(19),I=t(23),T=t(24),w=t(25),A="sky-omnibar-iframe-expanded",O="sky-omnibar-loading";function E(){c=B.BBAuthDomUtility.addIframe(u.url||"https://host.nxt.blackbaud.com/omnibar/","sky-omnibar-iframe "+O,"Navigation")}function _(){var e=document.location.href;y.BBAuthInterop.postOmnibarMessage(c,{href:e,messageType:"location-change"}),w.BBOmnibarToastContainer.updateUrl(e)}function N(){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"push-notifications-open"})}function R(){f||(f=!0,j.pushNotificationsEnabled().then((function(e){e?w.BBOmnibarToastContainer.init({envId:u.envId,leId:u.leId,navigateCallback:M,navigateUrlCallback:U,openMenuCallback:N,svcId:u.svcId,url:document.location.href}).then((function(){T.BBOmnibarPushNotifications.connect(u.leId,u.envId,(function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"push-notifications-update",pushNotifications:e}),w.BBOmnibarToastContainer.showNewNotifications(e),m=e&&e.notifications&&e.notifications.filter((function(e){return!e.isRead})).length,D()}))})):f=!1})))}function C(){function e(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"refresh-user",token:e}),e?R():f&&(w.BBOmnibarToastContainer.destroy(),T.BBOmnibarPushNotifications.disconnect(),f=!1)}b.BBAuth.clearTokenCache(),b.BBAuth.getToken({disableRedirect:!0,forceNewToken:!0}).then(e).catch((function(){return e(void 0)}))}function S(){I.BBOmnibarUserActivityPrompt.show({sessionRenewCallback:function(){k.BBOmnibarUserActivity.userRenewedSession()}})}function P(){I.BBOmnibarUserActivityPrompt.hide()}function x(){k.BBOmnibarUserActivity.startTracking(C,S,P,u.allowAnonymous,d)}function M(e){var n=u.nav;n&&n.beforeNavCallback&&!1===n.beforeNavCallback(e)||g.BBAuthNavigator.navigate(e.url)}function U(e){g.BBAuthNavigator.navigate(e)}function L(e){if(y.BBAuthInterop.messageIsFromOmnibar(e)){var n,t,o,i,s,f,m,p,v,g,B,I=e.data,w=u.nav;switch(I.messageType){case"ready":y.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),g=history.pushState,B=history.replaceState,history.pushState=function(){var e=g.apply(history,arguments);return _(),e},history.replaceState=function(){var e=B.apply(history,arguments);return _(),e},y.BBAuthInterop.postOmnibarMessage(c,{compactNavOnly:u.compactNavOnly,enableHelp:u.enableHelp,envId:u.envId,hideResourceLinks:u.hideResourceLinks,leId:u.leId,localNavItems:w&&w.localNavItems,localNotifications:!!u.notifications,localSearch:!!u.onSearch,messageType:"nav-ready",navVersion:u.navVersion,services:w&&w.services,svcId:u.svcId,theme:u.theme}),(v=u.notifications)&&v.onReady({updateNotifications:function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"notifications-update",notifications:e})}}),R(),_(),l();break;case"display-ready":a.classList.remove(O),c.classList.remove(O);break;case"expand":c.classList.add(A);break;case"collapse":c.classList.remove(A);break;case"navigate-url":U(I.url);break;case"navigate":M(I.navItem);break;case"search":p=I.searchArgs,u.onSearch&&u.onSearch(p).then((function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"search-results",results:e})}));break;case"get-token":f=I.tokenRequestId,m=I.disableRedirect,b.BBAuth.getToken({disableRedirect:m}).then((function(e){x(),y.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:f})}),(function(e){x(),y.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:f})}));break;case"help-open":(s=window.BBHELP)&&s.HelpWidget.open();break;case"notification-read":!function(e){var n=u.notifications;n&&n.onNotificationRead&&n.onNotificationRead(e)}(I.notification);break;case"push-notifications-change":i=I.notifications,T.BBOmnibarPushNotifications.updateNotifications(i);break;case"session-renew":k.BBOmnibarUserActivity.userRenewedSession();break;case"environment-update":n=I.name,t="sky-omnibar-environment-visible",o=document.body.classList,n=n||"",r.innerText=n,n?o.add(t):o.remove(t);break;case"legacy-keep-alive-url-change":d=I.url,x();break;case"selected-service-update":h=I.serviceName,D()}}}function D(){if(p){var e=p.slice();h&&e.push(h);var n=e.join(" - ");m&&(n="("+m+") "+n),document.title=n}}var j=function(){function e(){}return e.load=function(e){return u=u=e,d=u.legacyKeepAliveUrl,new Promise((function(e){l=e,function(){var e="background: linear-gradient(to right, #71bf44 0, #31b986 50%, #00b2ec 100%);",n="#4d5259",t=u.theme;if(t){var o=t.accent;n=t.backgroundColor||n,!1===o?e="display: none;":o&&o.color&&(e="background-color: "+o.color+";")}s=B.BBAuthDomUtility.addCss("\nbody {\n margin-top: 50px;\n}\n\n#bb-help-container {\n padding-top: 1px;\n}\n\n.sky-omnibar-iframe,\n.sky-omnibar-placeholder {\n border: none;\n height: 50px;\n width: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n z-index: 1000;\n}\n\n.sky-omnibar-placeholder {\n background-color: "+n+";\n display: none;\n}\n\n.sky-omnibar-placeholder-accent {\n height: 5px;\n "+e+"\n}\n\n.sky-omnibar-placeholder."+O+" {\n display: block;\n}\n\n.sky-omnibar-iframe."+O+" {\n visibility: hidden;\n}\n\n."+A+' {\n height: 100%;\n}\n\n.sky-omnibar-environment {\n background-color: #e1e1e3;\n color: #282b31;\n font-family: "Blackbaud Sans", "Open Sans", "Helvetica Neue", Arial, sans-serif;\n font-size: 12px;\n font-weight: 400;\n height: 0;\n line-height: 24px;\n overflow: hidden;\n padding: 0 15px;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.sky-omnibar-environment-visible .sky-omnibar-environment {\n height: 24px;\n}\n')}(),(a=document.createElement("div")).className="sky-omnibar-placeholder "+O,a.innerHTML='<div class="sky-omnibar-placeholder-accent"></div>',document.body.appendChild(a),(r=document.createElement("div")).className="sky-omnibar-environment",B.BBAuthDomUtility.addElToBodyTop(r),E(),window.addEventListener("message",L)}))},e.update=function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"update",updateArgs:e})},e.setTitle=function(e){p=e&&e.titleParts,D()},e.pushNotificationsEnabled=function(){return o(this,void 0,void 0,(function(){return i(this,(function(e){return u?[2,b.BBAuth.getToken({disableRedirect:!0,envId:u.envId,leId:u.leId,permissionScope:"Notifications"}).then((function(e){var n=v(e)["1bb.entitlements"];return!!n&&(n=Array.isArray(n)?n:[n]).indexOf("notif")>-1})).catch((function(){return!1}))]:[2,Promise.resolve(!1)]}))}))},e.destroy=function(){w.BBOmnibarToastContainer.destroy(),T.BBOmnibarPushNotifications.disconnect(),B.BBAuthDomUtility.removeEl(a),B.BBAuthDomUtility.removeEl(c),B.BBAuthDomUtility.removeEl(r),B.BBAuthDomUtility.removeCss(s),window.removeEventListener("message",L),u=s=a=c=r=l=f=m=p=h=void 0},e}();n.BBOmnibar=j},function(e,n,t){"use strict";var o=t(17);function i(e){this.message=e}i.prototype=new Error,i.prototype.name="InvalidTokenError",e.exports=function(e,n){if("string"!=typeof e)throw new i("Invalid token specified");var t=!0===(n=n||{}).header?0:1;try{return JSON.parse(o(e.split(".")[t]))}catch(e){throw new i("Invalid token specified: "+e.message)}},e.exports.InvalidTokenError=i},function(e,n,t){var o=t(18);e.exports=function(e){var n=e.replace(/-/g,"+").replace(/_/g,"/");switch(n.length%4){case 0:break;case 2:n+="==";break;case 3:n+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(o(e).replace(/(.)/g,(function(e,n){var t=n.charCodeAt(0).toString(16).toUpperCase();return t.length<2&&(t="0"+t),"%"+t})))}(n)}catch(e){return o(n)}}},function(e,n){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function o(e){this.message=e}o.prototype=new Error,o.prototype.name="InvalidCharacterError",e.exports="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var n=String(e).replace(/=+$/,"");if(n.length%4==1)throw new o("'atob' failed: The string to be decoded is not correctly encoded.");for(var i,r,a=0,s=0,c="";r=n.charAt(s++);~r&&(i=a%4?64*i+r:r,a++%4)?c+=String.fromCharCode(255&i>>(-2*a&6)):0)r=t.indexOf(r);return c}},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u,d,l,f,m,h,p,v,b=t(2),y=t(5),g=t(20),B=t(21),k=t(22),I=t(1),T="";function w(){d=Date.now()}function A(e){e.clientX===i&&e.clientY===r||(i=e.clientX,r=e.clientY,w())}function O(){var e=Date.now();(!l||e-l>C.MIN_RENEWAL_RETRY)&&(l=e,y.BBCsrfXhr.request(b.BBAuthDomain.getSTSDomain()+"/session/renew",{inactivity:1}).catch((function(){})))}function E(){u=!0,c()}function _(){u=!1,w(),a()}function N(){v?I.BBAuthNavigator.navigate(v):I.BBAuthNavigator.redirectToSignoutForInactivity()}function R(){m||O(),f=setInterval((function(){B.BBOmnibarUserSessionExpiration.getSessionExpiration(T,p,m).then((function(e){o&&g.BBOmnibarUserActivityProcessor.process({allowAnonymous:m,closeInactivityPrompt:_,expirationDate:e,inactivityPromptDuration:C.INACTIVITY_PROMPT_DURATION,isShowingInactivityPrompt:u,lastActivity:d,maxSessionAge:C.MAX_SESSION_AGE,minRenewalAge:C.MIN_RENEWAL_AGE,redirectForInactivity:N,renewSession:O,showInactivityPrompt:E})}))}),C.ACTIVITY_TIMER_INTERVAL)}var C=function(){function e(){}return e.startTracking=function(n,t,i,r,u){o&&r===m&&u===h||(e.stopTracking(),s=n,c=t,a=i,m=r,h=u,document.addEventListener("keypress",w),document.addEventListener("mousemove",A),R(),k.BBOmnibarUserSessionWatcher.start(r,u,s,(function(e){p=e.legacyTtl,T=e.refreshId,v=e.legacySigninUrl})),o=!0)},e.userRenewedSession=function(){_(),O()},e.stopTracking=function(){k.BBOmnibarUserSessionWatcher.stop(),B.BBOmnibarUserSessionExpiration.reset(),document.removeEventListener("keypress",w),document.removeEventListener("mousemove",A),f&&(clearInterval(f),f=void 0),o=i=r=d=l=u=s=c=a=m=h=void 0},e.ACTIVITY_TIMER_INTERVAL=1e3,e.MIN_RENEWAL_RETRY=6e4,e.INACTIVITY_PROMPT_DURATION=12e4,e.MIN_RENEWAL_AGE=3e5,e.MAX_SESSION_AGE=54e5,e}();n.BBOmnibarUserActivity=C},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){}return e.process=function(e){var n=e.allowAnonymous,t=e.closeInactivityPrompt,o=e.expirationDate,i=e.inactivityPromptDuration,r=e.isShowingInactivityPrompt,a=e.lastActivity,s=e.maxSessionAge,c=e.minRenewalAge,u=e.redirectForInactivity,d=e.renewSession,l=e.showInactivityPrompt,f=Date.now();if(null!==o){!n&&f>o&&u();var m=o-i,h=o-s+c;r?f<m&&t():a>h?d():!n&&f>m&&l()}},e}();n.BBOmnibarUserActivityProcessor=o},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i=t(2),r=t(5);var a=function(){function e(){}return e.getSessionExpiration=function(e,n,t){var a=function(e,n){if(o&&o.refreshId===e&&o.allowAnonymous===n)return o.promise;var t=new Promise((function(e,t){r.BBCsrfXhr.request(i.BBAuthDomain.getSTSDomain()+"/session/ttl",void 0,n).then((function(n){var t=null===n?null:Date.now()+1e3*n;e(t)}),(function(){e(null)}))}));return o={allowAnonymous:n,promise:t,refreshId:e},t}(e,t);return new Promise((function(e,t){a.then((function(t){var o;if(null===t)o=null;else if("number"==typeof n){var i=Date.now()+n;o=Math.min(t,i)}else o=t;e(o)}))}))},e.reset=function(){o=void 0},e}();n.BBOmnibarUserSessionExpiration=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u,d,l=t(4),f=t(1),m=t(2),h={};function p(e){if(e){var n=e.split("://");return n[0]+"://"+n[1].split("/")[0]}}function v(e,n){var t=document.createElement("iframe");return t.className=e,t.width="0",t.height="0",t.frameBorder="0",t.src=n,t.tabIndex=-1,t.setAttribute("aria-hidden","true"),document.body.appendChild(t),t}function b(){var e=B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN+"/SessionWatcher.html?origin="+encodeURIComponent(location.origin);c=v("sky-omnibar-iframe-session-watcher",e)}function y(e){if("string"==typeof e.data){var n=void 0;try{n=JSON.parse(e.data)}catch(e){return}if("session_change"===n.messageType){var t=n.message,o=t&&t.sessionId,c=t&&t.refreshId;o||s||(d?f.BBAuthNavigator.navigate(d):f.BBAuthNavigator.redirectToSignin()),void 0!==h.refreshId&&c!==h.refreshId&&function(e){u&&l.BBAuthInterop.postOmnibarMessage(u,e,p(i))}({messageType:"session-refresh"}),void 0!==h.sessionId&&o!==h.sessionId&&r(),h.refreshId=c,h.sessionId=o,a(h)}}}function g(e){switch(e.origin){case B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN:y(e);break;case p(i):!function(e){var n=e.data;switch(n.messageType){case"ready":h.legacyTtl=n.ttl,d=n.signinUrl,a(h)}}(e)}}var B=function(){function e(){}return e.start=function(n,t,c,d){o&&n===s&&t===i||(e.stop(),s=n,r=c,i=t,a=d,b(),i&&(u=v("sky-omnibar-iframe-legacy-keep-alive",i)),window.addEventListener("message",g,!1),o=!0)},e.stop=function(){window.removeEventListener("message",g,!1),c&&(document.body.removeChild(c),c=void 0),u&&(document.body.removeChild(u),u=void 0),h={},o=s=r=i=d=a=void 0},e.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN=m.BBAuthDomain.getSTSDomain(),e}();n.BBOmnibarUserSessionWatcher=B},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a=t(3),s=t(4);function c(e){if(s.BBAuthInterop.messageIsFromOmnibar(e))switch(e.data.messageType){case"ready":s.BBAuthInterop.postOmnibarMessage(i,{messageType:"host-ready"}),i.classList.add("sky-omnibar-inactivity-iframe-ready");break;case"session-renew":r()}}var u=function(){function e(){}return e.show=function(n){var t;this.hide(),r=n.sessionRenewCallback,o=a.BBAuthDomUtility.addCss("\n .sky-omnibar-inactivity-iframe {\n background-color: transparent;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 100000;\n visibility: hidden;\n }\n\n .sky-omnibar-inactivity-iframe-ready {\n visibility: visible;\n }\n "),t=e.url,i=a.BBAuthDomUtility.addIframe(t,"sky-omnibar-inactivity-iframe","Inactivity Prompt"),window.addEventListener("message",c)},e.hide=function(){i&&(a.BBAuthDomUtility.removeEl(i),a.BBAuthDomUtility.removeCss(o),i=o=r=void 0,window.removeEventListener("message",c))},e.url="https://host.nxt.blackbaud.com/omnibar/inactivity",e}();n.BBOmnibarUserActivityPrompt=u},function(e,n,t){"use strict";var o=this&&this.__awaiter||function(e,n,t,o){return new(t||(t=Promise))((function(i,r){function a(e){try{c(o.next(e))}catch(e){r(e)}}function s(e){try{c(o.throw(e))}catch(e){r(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((o=o.apply(e,n||[])).next())}))},i=this&&this.__generator||function(e,n){var t,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===r[0]||2===r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=n.call(e,a)}catch(e){r=[6,e],o=0}finally{t=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}};Object.defineProperty(n,"__esModule",{value:!0});var r,a=t(0),s=t(8),c=function(){function e(){}return e.connect=function(e,n,t){return o(this,void 0,void 0,(function(){return i(this,(function(o){return r||(r=window.BBNotificationsClient?Promise.resolve():s.BBOmnibarScriptLoader.registerScript(this.NOTIFICATIONS_CLIENT_URL)),[2,r.then((function(){BBNotificationsClient.BBNotifications.init({tokenCallback:function(){return a.BBAuth.getToken({disableRedirect:!0,envId:n,leId:e})}}),BBNotificationsClient.BBNotifications.addListener(t)}))]}))}))},e.disconnect=function(){return o(this,void 0,void 0,(function(){return i(this,(function(e){return r?[2,r.then((function(){BBNotificationsClient.BBNotifications.destroy(),r=void 0}))]:[2,Promise.resolve()]}))}))},e.updateNotifications=function(e){BBNotificationsClient.BBNotifications.updateNotifications(e)},e.NOTIFICATIONS_CLIENT_URL="https://sky.blackbaudcdn.net/static/notifications-client/1/notifications-client.global.min.js",e}();n.BBOmnibarPushNotifications=c},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u=t(6),d=t(3),l=t(4),f="sky-omnibar-toast-container",m=f+"-ready",h=f+"-empty",p=20;function v(){return i||(o=d.BBAuthDomUtility.addCss("\n."+f+" {\n border: none;\n display: none;\n position: fixed;\n right: 0px;\n height: 0px;\n width: 300px;\n /* z-index is 1 less than omnibar so menus will display over top the toast container */\n z-index: 999;\n}\n\n."+m+" {\n display: block;\n}\n\n."+h+" {\n visibility: hidden;\n}\n"),(i=document.createElement("iframe")).src=B.CONTAINER_URL,i.className=f+" "+h,i.title="Toast container",document.body.appendChild(i),window.addEventListener("message",g)),i}function b(e){var n=document.querySelector(e);return n?n.getBoundingClientRect().height:0}function y(){i&&l.BBAuthInterop.postOmnibarMessage(i,{href:c,messageType:"location-change"})}function g(e){if(l.BBAuthInterop.messageIsFromToastContainer(e)){var n,t,o=e.data;switch(o.messageType){case"toast-ready":l.BBAuthInterop.postOmnibarMessage(i,{messageType:"host-ready"}),l.BBAuthInterop.postOmnibarMessage(i,{envId:s.envId,leId:s.leId,messageType:"nav-ready",svcId:s.svcId}),y(),i.classList.add(m),a();break;case"get-token":n=o.tokenRequestId,t=o.disableRedirect,u.BBAuth.getToken({disableRedirect:t}).then((function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"token",token:e,tokenRequestId:n})}),(function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"token-fail",reason:e,tokenRequestId:n})}));break;case"navigate-url":s.navigateUrlCallback(o.url);break;case"navigate":s.navigateCallback(o.navItem);break;case"toast-container-change":o.height>0?(i.style.height=o.height+"px",i.style.top=b(".sky-omnibar-iframe")+b(".sky-omnibar-environment")+p+"px",i.classList.remove(h)):i.classList.add(h);break;case"push-notifications-open":s.openMenuCallback()}}}var B=function(){function e(){}return e.init=function(e){return s=e,c=e.url,r||(r=new Promise((function(e){a=e,v()}))),r},e.showNewNotifications=function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"push-notifications-update",pushNotifications:e})},e.updateUrl=function(e){c=e,y()},e.destroy=function(){o&&d.BBAuthDomUtility.removeCss(o),i&&d.BBAuthDomUtility.removeEl(i),c=i=s=r=a=o=void 0,window.removeEventListener("message",g)},e.CONTAINER_URL="https://host.nxt.blackbaud.com/omnibar/toast",e}();n.BBOmnibarToastContainer=B},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(8);function i(){return window.jQuery}var r=function(){function e(){}return e.load=function(e){return new Promise((function(n){var t=i(),r=t&&t.fn&&t.fn.jquery;o.BBOmnibarScriptLoader.smartRegisterScript("https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.js","2.1.0",r).then((function(){return o.BBOmnibarScriptLoader.registerScript("https://cdnjs.cloudflare.com/ajax/libs/easyXDM/2.4.17.1/easyXDM.min.js")})).then((function(){return o.BBOmnibarScriptLoader.registerScript("https://signin.blackbaud.com/Omnibar.min.js")})).then((function(){document.body.classList.add("bb-omnibar-height-padding");var t=document.createElement("div");t.setAttribute("data-omnibar-el",""),document.body.appendChild(t),(e=e||{})["z-index"]=1e3,e.afterLoad=n,e.menuEl&&(e.menuEl=i()(e.menuEl)),BBAUTH.Omnibar.load(t,e)}))}))},e}();n.BBOmnibarLegacy=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0})}]); | ||
window.BBAuthClient=function(e){var n={};function t(o){if(n[o])return n[o].exports;var i=n[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,t),i.l=!0,i.exports}return t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:o})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(t.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var i in e)t.d(o,i,function(n){return e[n]}.bind(null,i));return o},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="",t(t.s=9)}([function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(6)),o(t(7))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i="https://signin.blackbaud.com/signin/",r=encodeURIComponent;function a(e){var n=i+"?redirectUrl="+r(location.href);return e&&(n+="&inactivity=1"),n}var s=function(){function e(){}return e.navigate=function(e,n){n?location.replace(e):location.href=e},e.redirectToSignin=function(e){var n=a();e&&(n+="&"+function(e){var n=[];for(var t in e)e.hasOwnProperty(t)&&n.push(r(t)+"="+r(e[t]));return n.join("&")}(e)),this.navigate(n)},e.redirectToSignoutForInactivity=function(){var e=a(!0),n=i+"sign-out?redirectUrl="+r(e);this.navigate(n)},e.redirectToError=function(e){var n,t;switch(e){case o.BBAuthTokenErrorCode.InvalidEnvironment:t="invalid_env",n="security";break;default:n="broken"}var i="https://host.nxt.blackbaud.com/errors/"+n+"?source=auth-client&url="+r(location.href);t&&(i+="&code="+r(t)),this.navigate(i)},e}();n.BBAuthNavigator=s},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o={"bbk12.com":"https://sts-sso.bbk12.com","blackbaudfaith.com":"https://sts.blackbaudfaith.com","blackbaudhosting.com":"https://sts.blackbaudhosting.com","donorcentral.com":"https://sts-dc.donorcentral.com","etapestry.com":"https://sts.etapestry.com","mycampus-app.com":"https://sts-sso.mycampus-app.com","myschoolapp.com":"https://sts-sso.myschoolapp.com","myschoolautomation.com":"https://sts-sso.myschoolautomation.com","myschooldemo.com":"https://sts-sso.myschooldemo.com","myschooltraining.com":"https://sts-sso.myschooltraining.com"},i=function(){function e(){}return e.getRegisteredDomain=function(){for(var e=0,n=Object.keys(o);e<n.length;e++){var t=n[e],i="."+t;if(this.CURRENT_DOMAIN===t||this.CURRENT_DOMAIN.substr(-i.length)===i)return t}},e.getSTSDomain=function(){var e=this.getRegisteredDomain();return o[e]||"https://s21aidntoken00blkbapp01.nxt.blackbaud.com"},e.CURRENT_DOMAIN=window.location.hostname,e}();n.BBAuthDomain=i},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){}return e.addCss=function(e){var n=document.createElement("style");return n.appendChild(document.createTextNode(e)),document.head.appendChild(n),n},e.addIframe=function(e,n,t){var o=document.createElement("iframe");return o.className=n,o.title=t,o.src=e,this.addElToBodyTop(o),o},e.removeCss=function(e){this.removeEl(e,document.head)},e.removeEl=function(e,n){void 0===n&&(n=document.body),n.contains(e)&&n.removeChild(e)},e.addElToBodyTop=function(e){var n=document.body;n.firstChild?n.insertBefore(e,n.firstChild):n.appendChild(e)},e}();n.BBAuthDomUtility=o},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o="https://host.nxt.blackbaud.com";function i(e,n){if(e.origin===o){var t=e.data;return!!t&&t.source===n}return!1}var r=function(){function e(){}return e.postOmnibarMessage=function(e,n,t){n.source="auth-client",e.contentWindow.postMessage(n,t||o)},e.messageIsFromOmnibar=function(e){return i(e,"skyux-spa-omnibar")},e.messageIsFromToastContainer=function(e){return i(e,"skyux-spa-omnibar-toast-container")},e}();n.BBAuthInterop=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i=t(2),r=t(1);function a(e,n,t,o){return(o||void 0===o&&t)&&((e=e||{})[n]=t),e}function s(e,n,t,i,r){var s;return s=a(s,"environment_id",t),s=a(s,"legal_entity_id",r),s=a(s,"permission_scope",i,!(!t&&!r||!i)),new Promise((function(t,i){!function(e,n,t,i,r){var a=new XMLHttpRequest;a.onreadystatechange=function(){if(4===a.readyState)switch(a.status){case 0:r({code:o.BBAuthTokenErrorCode.Offline,message:"The user is offline."});break;case 200:i(a.responseText);break;case 401:r({code:o.BBAuthTokenErrorCode.NotLoggedIn,message:"The user is not logged in."});break;case 403:r({code:o.BBAuthTokenErrorCode.InvalidEnvironment,message:"The user is not a member of the specified environment."});break;default:a.status>=400&&r({code:o.BBAuthTokenErrorCode.Unspecified,message:"An unknown error occurred."})}},a.open("POST",e,!0),a.setRequestHeader(n.name,n.value),a.setRequestHeader("Accept","application/json"),a.setRequestHeader("Content-Type","application/json"),a.withCredentials=!0,t?a.send(JSON.stringify(t)):a.send()}(e,{name:"X-CSRF",value:n},s,(function(e){var n=e?JSON.parse(e):void 0;t(n)}),i)}))}var c=function(){function e(){}return e.request=function(e,n,t,a,c,u,d){return!c||a||u?new Promise((function(l,f){new Promise((function(e,n){d?e({csrf_token:"token_needed"}):s(i.BBAuthDomain.getSTSDomain()+"/session/csrf","token_needed").then(e).catch(n)})).then((function(n){return s(e,n.csrf_token,a,c,u)})).then(l).catch((function(e){if(t||e.code===o.BBAuthTokenErrorCode.Offline)f(e);else switch(e.code){case o.BBAuthTokenErrorCode.NotLoggedIn:r.BBAuthNavigator.redirectToSignin(n);break;default:r.BBAuthNavigator.redirectToError(e.code)}}))})):Promise.reject({code:o.BBAuthTokenErrorCode.PermissionScopeNoEnvironment,message:"You must also specify an environment or legal entity when specifying a permission scope."})},e.requestWithToken=function(e,n){return new Promise((function(t,o){var i=new XMLHttpRequest;i.onreadystatechange=function(){if(4===i.readyState)switch(i.status){case 200:t(JSON.parse(i.responseText));break;default:o()}},i.open("GET",e,!0),i.setRequestHeader("Authorization","Bearer "+n),i.setRequestHeader("Accept","application/json"),i.send()}))},e}();n.BBCsrfXhr=c},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(10),i=/1bb:\/\/([a-z]{3})-([a-z0-9]{5})(-[a-z]{4}[0-9]{2})?\/(.*)/;var r=function(){function e(){}return e.getUrl=function(e,n){var t=i.exec(e),o=e,r=n?n.zone:void 0;return r&&(r=r.replace("-","")),t&&(t[3]&&(r=t[3].substring(1)),o="https://"+t[1]+"-"+r+".app.blackbaud.net/"+t[2]+"/"+t[4]),Promise.resolve(o)},e.getToken=function(n){return e.getTokenInternal(n)},e.clearTokenCache=function(){e.tokenCache={}},e.getTokenInternal=function(n){var t=(n=n||{}).forceNewToken,i=n.disableRedirect;if(e.mock)return Promise.resolve("mock_access_token_auth-client@blackbaud.com");var r=function(e){var n=e.envId,t=e.permissionScope;return"token|"+(e.leId||"-")+"|"+(n||"-")+"|"+(t||"-")}(n),a=e.tokenCache[r]=e.tokenCache[r]||{},s=(new Date).valueOf();return!t&&a.lastToken&&a.expirationTime&&a.expirationTime-s>6e4?Promise.resolve(a.lastToken):(a.pendingLookupPromise||(a.pendingLookupPromise=o.BBAuthTokenIntegration.getToken(i,n.envId,n.permissionScope,n.leId).then((function(e){return a.expirationTime=(new Date).valueOf()+1e3*e.expires_in,a.lastToken=e.access_token,a.pendingLookupPromise=null,a.lastToken})).catch((function(e){throw a.pendingLookupPromise=null,e}))),a.pendingLookupPromise)},e.mock=!1,e.tokenCache={},e}();n.BBAuth=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),function(e){e[e.Unspecified=0]="Unspecified",e[e.NotLoggedIn=1]="NotLoggedIn",e[e.InvalidEnvironment=2]="InvalidEnvironment",e[e.PermissionScopeNoEnvironment=3]="PermissionScopeNoEnvironment",e[e.Offline=4]="Offline"}(n.BBAuthTokenErrorCode||(n.BBAuthTokenErrorCode={}))},function(e,n,t){"use strict";function o(e){for(var n=[],t=0,o=e.split(".");t<o.length;t++){var i=o[t],r=parseInt(i,10)||0;n.push(r)}return n}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(){}return e.registerScript=function(e){return new Promise((function(n,t){var o=document.createElement("script");o.onload=n,o.onerror=t,o.src=e,document.body.appendChild(o)}))},e.smartRegisterScript=function(n,t,i){return i&&function(e,n){for(var t=o(e),i=o(n),r=0;r<t.length;r++)if(r<i.length){if(i[r]>t[r])return!0;if(i[r]<t[r])return!1}return!0}(t,i)?Promise.resolve():e.registerScript(n)},e}();n.BBOmnibarScriptLoader=i},function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(0)),o(t(12)),o(t(14))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(5),i=t(11),r=t(2),a=function(){function e(){}return e.getToken=function(e,n,t,a){return void 0!==r.BBAuthDomain.getRegisteredDomain()||this.hostNameEndsWith("blackbaud.com")?o.BBCsrfXhr.request(r.BBAuthDomain.getSTSDomain()+"/oauth2/token",void 0,e,n,t,a,!0):i.BBAuthCrossDomainIframe.getToken({disableRedirect:e,envId:n,leId:a,permissionScope:t})},e.hostNameEndsWith=function(e){return this.getLocationHostname().substr(-e.length)===e},e.getLocationHostname=function(){return window.location.hostname},e}();n.BBAuthTokenIntegration=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(3),i=t(1),r=t(7),a=function(){function e(){}return e.reset=function(){var e=this;this.requestCounter=0,this.tokenRequests={},this.iframeReadyPromise=new Promise((function(n){return e.iframeReadyResolve=n})),this.listenerSetup=!1},e.TARGET_ORIGIN=function(){return this.TARGETORIGIN},e.getOrMakeIframe=function(){return e.iframeEl=document.getElementById("auth-cross-domain-iframe"),e.iframeEl||(e.iframeEl=o.BBAuthDomUtility.addIframe("https://s21aidntoken00blkbapp01.nxt.blackbaud.com/Iframes/CrossDomainAuthFrame.html","auth-cross-domain-iframe",""),e.iframeEl.id="auth-cross-domain-iframe",e.iframeEl.hidden=!0),e.iframeEl},e.getToken=function(e){return this.setupListenersForIframe(),this.getTokenFromIframe(this.getOrMakeIframe(),e)},e.setupListenersForIframe=function(){var e=this;this.listenerSetup||(window.addEventListener("message",(function(n){var t=n.data,o=t.requestId,i=e.tokenRequests[o];if("security-token-svc"===t.source||t.origin===e.TARGET_ORIGIN())switch(t.messageType){case"ready":e.iframeReadyResolve(!0);break;case"error":e.handleErrorMessage(t.value,i.reject,i.args.disableRedirect);break;case"getToken":var r={access_token:t.value,expires_in:0};i.resolve(r)}})),this.listenerSetup=!0)},e.getTokenFromIframe=function(n,t){var o=this;return new Promise((function(i,r){var a=o.requestCounter++;e.tokenRequests[a]={args:t,reject:r,resolve:i},e.iframeReadyPromise.then((function(){n.contentWindow.postMessage({messageType:"getToken",requestId:a,source:"auth-client",value:t},e.TARGET_ORIGIN())}))}))},e.handleErrorMessage=function(e,n,t){if(t)n(e);else switch(e.code){case r.BBAuthTokenErrorCode.Offline:n(e);break;case r.BBAuthTokenErrorCode.NotLoggedIn:i.BBAuthNavigator.redirectToSignin(void 0);break;default:i.BBAuthNavigator.redirectToError(e.code)}},e.listenerSetup=!1,e.iframeReadyPromise=new Promise((function(n){return e.iframeReadyResolve=n})),e.tokenRequests={},e.requestCounter=0,e.TARGETORIGIN="https://s21aidntoken00blkbapp01.nxt.blackbaud.com",e}();n.BBAuthCrossDomainIframe=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),function(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}(t(13))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i=t(4),r=t(5),a=t(3),s=t(1);function c(e,n,t,r){var s,c,u;function l(){a.BBAuthDomUtility.removeEl(c),a.BBAuthDomUtility.removeCss(s),c=s=void 0,window.removeEventListener("message",f)}function f(a){if(i.BBAuthInterop.messageIsFromOmnibar(a)){var s,u,d=a.data;switch(d.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),i.BBAuthInterop.postOmnibarMessage(c,{contextDestinations:n,messageType:"context-provide"});break;case"get-token":s=d.tokenRequestId,u=d.disableRedirect,o.BBAuth.getToken({disableRedirect:u}).then((function(e){i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:s})}),(function(e){i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:s})}));break;case"welcome-cancel":l(),r({reason:"canceled"});break;case"welcome-environment-selected":l(),setTimeout((function(){e.envId=d.envId,t(e)}),10)}}}s=a.BBAuthDomUtility.addCss("\n.sky-omnibar-welcome-iframe {\n background-color: #fff;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n"),u=d.url+"?hosted=1&svcid="+encodeURIComponent(e.svcId)+"&url="+encodeURIComponent(e.url),c=a.BBAuthDomUtility.addIframe(u,"sky-omnibar-welcome-iframe","Welcome"),window.addEventListener("message",f)}function u(){s.BBAuthNavigator.redirectToError(o.BBAuthTokenErrorCode.InvalidEnvironment)}var d=function(){function e(){}return e.ensureContext=function(e){var n=e.envId,t=e.envIdRequired,i=e.leId,a=e.leIdRequired,s=e.svcId;return!n&&t||!i&&a?new Promise((function(n,t){s?o.BBAuth.getToken().then((function(o){var i="https://s21anavnavaf00blkbapp01.sky.blackbaud.com/user/destinations?svcid="+encodeURIComponent(s);e.url&&(i+="&referringurl="+encodeURIComponent(e.url)),r.BBCsrfXhr.requestWithToken(i,o).then((function(o){var i=o&&o.items,r=i&&i.length;1===r?(e.url=i[0].url,n(e)):r>1?c(e,o,n,t):u()}))})):u()})):Promise.resolve(e)},e.url="https://host.nxt.blackbaud.com/omnibar/welcome",e}();n.BBContextProvider=d},function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(15)),o(t(26)),o(t(27))},function(e,n,t){"use strict";var o=this&&this.__awaiter||function(e,n,t,o){return new(t||(t=Promise))((function(i,r){function a(e){try{c(o.next(e))}catch(e){r(e)}}function s(e){try{c(o.throw(e))}catch(e){r(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((o=o.apply(e,n||[])).next())}))},i=this&&this.__generator||function(e,n){var t,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===r[0]||2===r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=n.call(e,a)}catch(e){r=[6,e],o=0}finally{t=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}};Object.defineProperty(n,"__esModule",{value:!0});var r,a,s,c,u,d,l,f,m,h,p,v=t(16),b=t(0),y=t(4),g=t(1),B=t(3),k=t(19),I=t(23),T=t(24),w=t(25),A="sky-omnibar-iframe-expanded",O="sky-omnibar-loading";function E(){c=B.BBAuthDomUtility.addIframe(u.url||"https://host.nxt.blackbaud.com/omnibar/","sky-omnibar-iframe "+O,"Navigation")}function _(){var e=document.location.href;y.BBAuthInterop.postOmnibarMessage(c,{href:e,messageType:"location-change"}),w.BBOmnibarToastContainer.updateUrl(e)}function N(){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"push-notifications-open"})}function R(){f||(f=!0,j.pushNotificationsEnabled().then((function(e){e?w.BBOmnibarToastContainer.init({envId:u.envId,leId:u.leId,navigateCallback:M,navigateUrlCallback:U,openMenuCallback:N,svcId:u.svcId,url:document.location.href}).then((function(){T.BBOmnibarPushNotifications.connect(u.leId,u.envId,(function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"push-notifications-update",pushNotifications:e}),w.BBOmnibarToastContainer.showNewNotifications(e),m=e&&e.notifications&&e.notifications.filter((function(e){return!e.isRead})).length,D()}))})):f=!1})))}function C(){function e(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"refresh-user",token:e}),e?R():f&&(w.BBOmnibarToastContainer.destroy(),T.BBOmnibarPushNotifications.disconnect(),f=!1)}b.BBAuth.clearTokenCache(),b.BBAuth.getToken({disableRedirect:!0,forceNewToken:!0}).then(e).catch((function(){return e(void 0)}))}function S(){I.BBOmnibarUserActivityPrompt.show({sessionRenewCallback:function(){k.BBOmnibarUserActivity.userRenewedSession()}})}function P(){I.BBOmnibarUserActivityPrompt.hide()}function x(){k.BBOmnibarUserActivity.startTracking(C,S,P,u.allowAnonymous,d)}function M(e){var n=u.nav;n&&n.beforeNavCallback&&!1===n.beforeNavCallback(e)||g.BBAuthNavigator.navigate(e.url)}function U(e){g.BBAuthNavigator.navigate(e)}function L(e){if(y.BBAuthInterop.messageIsFromOmnibar(e)){var n,t,o,i,s,f,m,p,v,g,B,I=e.data,w=u.nav;switch(I.messageType){case"ready":y.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),g=history.pushState,B=history.replaceState,history.pushState=function(){var e=g.apply(history,arguments);return _(),e},history.replaceState=function(){var e=B.apply(history,arguments);return _(),e},y.BBAuthInterop.postOmnibarMessage(c,{compactNavOnly:u.compactNavOnly,enableHelp:u.enableHelp,envId:u.envId,hideResourceLinks:u.hideResourceLinks,leId:u.leId,localNavItems:w&&w.localNavItems,localNotifications:!!u.notifications,localSearch:!!u.onSearch,messageType:"nav-ready",navVersion:u.navVersion,services:w&&w.services,svcId:u.svcId,theme:u.theme}),(v=u.notifications)&&v.onReady({updateNotifications:function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"notifications-update",notifications:e})}}),R(),_(),l();break;case"display-ready":a.classList.remove(O),c.classList.remove(O);break;case"expand":c.classList.add(A);break;case"collapse":c.classList.remove(A);break;case"navigate-url":U(I.url);break;case"navigate":M(I.navItem);break;case"search":p=I.searchArgs,u.onSearch&&u.onSearch(p).then((function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"search-results",results:e})}));break;case"get-token":f=I.tokenRequestId,m=I.disableRedirect,b.BBAuth.getToken({disableRedirect:m}).then((function(e){x(),y.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:f})}),(function(e){x(),y.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:f})}));break;case"help-open":(s=window.BBHELP)&&s.HelpWidget.open();break;case"notification-read":!function(e){var n=u.notifications;n&&n.onNotificationRead&&n.onNotificationRead(e)}(I.notification);break;case"push-notifications-change":i=I.notifications,T.BBOmnibarPushNotifications.updateNotifications(i);break;case"session-renew":k.BBOmnibarUserActivity.userRenewedSession();break;case"environment-update":n=I.name,t="sky-omnibar-environment-visible",o=document.body.classList,n=n||"",r.innerText=n,n?o.add(t):o.remove(t);break;case"legacy-keep-alive-url-change":d=I.url,x();break;case"selected-service-update":h=I.serviceName,D()}}}function D(){if(p){var e=p.slice();h&&e.push(h);var n=e.join(" - ");m&&(n="("+m+") "+n),document.title=n}}var j=function(){function e(){}return e.load=function(e){return u=u=e,d=u.legacyKeepAliveUrl,new Promise((function(e){l=e,function(){var e="background: linear-gradient(to right, #71bf44 0, #31b986 50%, #00b2ec 100%);",n="#4d5259",t=u.theme;if(t){var o=t.accent;n=t.backgroundColor||n,!1===o?e="display: none;":o&&o.color&&(e="background-color: "+o.color+";")}s=B.BBAuthDomUtility.addCss("\nbody {\n margin-top: 50px;\n}\n\n#bb-help-container {\n padding-top: 1px;\n}\n\n.sky-omnibar-iframe,\n.sky-omnibar-placeholder {\n border: none;\n height: 50px;\n width: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n z-index: 1000;\n}\n\n.sky-omnibar-placeholder {\n background-color: "+n+";\n display: none;\n}\n\n.sky-omnibar-placeholder-accent {\n height: 5px;\n "+e+"\n}\n\n.sky-omnibar-placeholder."+O+" {\n display: block;\n}\n\n.sky-omnibar-iframe."+O+" {\n visibility: hidden;\n}\n\n."+A+' {\n height: 100%;\n}\n\n.sky-omnibar-environment {\n background-color: #e1e1e3;\n color: #282b31;\n font-family: "Blackbaud Sans", "Open Sans", "Helvetica Neue", Arial, sans-serif;\n font-size: 12px;\n font-weight: 400;\n height: 0;\n line-height: 24px;\n overflow: hidden;\n padding: 0 15px;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.sky-omnibar-environment-visible .sky-omnibar-environment {\n height: 24px;\n}\n')}(),(a=document.createElement("div")).className="sky-omnibar-placeholder "+O,a.innerHTML='<div class="sky-omnibar-placeholder-accent"></div>',document.body.appendChild(a),(r=document.createElement("div")).className="sky-omnibar-environment",B.BBAuthDomUtility.addElToBodyTop(r),E(),window.addEventListener("message",L)}))},e.update=function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"update",updateArgs:e})},e.setTitle=function(e){p=e&&e.titleParts,D()},e.pushNotificationsEnabled=function(){return o(this,void 0,void 0,(function(){return i(this,(function(e){return u?[2,b.BBAuth.getToken({disableRedirect:!0,envId:u.envId,leId:u.leId,permissionScope:"Notifications"}).then((function(e){var n=v(e)["1bb.entitlements"];return!!n&&(n=Array.isArray(n)?n:[n]).indexOf("notif")>-1})).catch((function(){return!1}))]:[2,Promise.resolve(!1)]}))}))},e.destroy=function(){w.BBOmnibarToastContainer.destroy(),T.BBOmnibarPushNotifications.disconnect(),B.BBAuthDomUtility.removeEl(a),B.BBAuthDomUtility.removeEl(c),B.BBAuthDomUtility.removeEl(r),B.BBAuthDomUtility.removeCss(s),window.removeEventListener("message",L),u=s=a=c=r=l=f=m=p=h=void 0},e}();n.BBOmnibar=j},function(e,n,t){"use strict";var o=t(17);function i(e){this.message=e}i.prototype=new Error,i.prototype.name="InvalidTokenError",e.exports=function(e,n){if("string"!=typeof e)throw new i("Invalid token specified");var t=!0===(n=n||{}).header?0:1;try{return JSON.parse(o(e.split(".")[t]))}catch(e){throw new i("Invalid token specified: "+e.message)}},e.exports.InvalidTokenError=i},function(e,n,t){var o=t(18);e.exports=function(e){var n=e.replace(/-/g,"+").replace(/_/g,"/");switch(n.length%4){case 0:break;case 2:n+="==";break;case 3:n+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(o(e).replace(/(.)/g,(function(e,n){var t=n.charCodeAt(0).toString(16).toUpperCase();return t.length<2&&(t="0"+t),"%"+t})))}(n)}catch(e){return o(n)}}},function(e,n){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function o(e){this.message=e}o.prototype=new Error,o.prototype.name="InvalidCharacterError",e.exports="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var n=String(e).replace(/=+$/,"");if(n.length%4==1)throw new o("'atob' failed: The string to be decoded is not correctly encoded.");for(var i,r,a=0,s=0,c="";r=n.charAt(s++);~r&&(i=a%4?64*i+r:r,a++%4)?c+=String.fromCharCode(255&i>>(-2*a&6)):0)r=t.indexOf(r);return c}},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u,d,l,f,m,h,p,v,b=t(2),y=t(5),g=t(20),B=t(21),k=t(22),I=t(1),T="";function w(){d=Date.now()}function A(e){e.clientX===i&&e.clientY===r||(i=e.clientX,r=e.clientY,w())}function O(){var e=Date.now();(!l||e-l>C.MIN_RENEWAL_RETRY)&&(l=e,y.BBCsrfXhr.request(b.BBAuthDomain.getSTSDomain()+"/session/renew",{inactivity:1}).catch((function(){})))}function E(){u=!0,c()}function _(){u=!1,w(),a()}function N(){v?I.BBAuthNavigator.navigate(v):I.BBAuthNavigator.redirectToSignoutForInactivity()}function R(){m||O(),f=setInterval((function(){B.BBOmnibarUserSessionExpiration.getSessionExpiration(T,p,m).then((function(e){o&&g.BBOmnibarUserActivityProcessor.process({allowAnonymous:m,closeInactivityPrompt:_,expirationDate:e,inactivityPromptDuration:C.INACTIVITY_PROMPT_DURATION,isShowingInactivityPrompt:u,lastActivity:d,maxSessionAge:C.MAX_SESSION_AGE,minRenewalAge:C.MIN_RENEWAL_AGE,redirectForInactivity:N,renewSession:O,showInactivityPrompt:E})}))}),C.ACTIVITY_TIMER_INTERVAL)}var C=function(){function e(){}return e.startTracking=function(n,t,i,r,u){o&&r===m&&u===h||(e.stopTracking(),s=n,c=t,a=i,m=r,h=u,document.addEventListener("keypress",w),document.addEventListener("mousemove",A),R(),k.BBOmnibarUserSessionWatcher.start(r,u,s,(function(e){p=e.legacyTtl,T=e.refreshId,v=e.legacySigninUrl})),o=!0)},e.userRenewedSession=function(){_(),O()},e.stopTracking=function(){k.BBOmnibarUserSessionWatcher.stop(),B.BBOmnibarUserSessionExpiration.reset(),document.removeEventListener("keypress",w),document.removeEventListener("mousemove",A),f&&(clearInterval(f),f=void 0),o=i=r=d=l=u=s=c=a=m=h=void 0},e.ACTIVITY_TIMER_INTERVAL=1e3,e.MIN_RENEWAL_RETRY=6e4,e.INACTIVITY_PROMPT_DURATION=12e4,e.MIN_RENEWAL_AGE=3e5,e.MAX_SESSION_AGE=54e5,e}();n.BBOmnibarUserActivity=C},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){}return e.process=function(e){var n=e.allowAnonymous,t=e.closeInactivityPrompt,o=e.expirationDate,i=e.inactivityPromptDuration,r=e.isShowingInactivityPrompt,a=e.lastActivity,s=e.maxSessionAge,c=e.minRenewalAge,u=e.redirectForInactivity,d=e.renewSession,l=e.showInactivityPrompt,f=Date.now();if(null!==o){!n&&f>o&&u();var m=o-i,h=o-s+c;r?f<m&&t():a>h?d():!n&&f>m&&l()}},e}();n.BBOmnibarUserActivityProcessor=o},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i=t(2),r=t(5);var a=function(){function e(){}return e.getSessionExpiration=function(e,n,t){var a=function(e,n){if(o&&o.refreshId===e&&o.allowAnonymous===n)return o.promise;var t=new Promise((function(e,t){r.BBCsrfXhr.request(i.BBAuthDomain.getSTSDomain()+"/session/ttl",void 0,n).then((function(n){var t=null===n?null:Date.now()+1e3*n;e(t)}),(function(){e(null)}))}));return o={allowAnonymous:n,promise:t,refreshId:e},t}(e,t);return new Promise((function(e,t){a.then((function(t){var o;if(null===t)o=null;else if("number"==typeof n){var i=Date.now()+n;o=Math.min(t,i)}else o=t;e(o)}))}))},e.reset=function(){o=void 0},e}();n.BBOmnibarUserSessionExpiration=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u,d,l=t(4),f=t(1),m=t(2),h={};function p(e){if(e){var n=e.split("://");return n[0]+"://"+n[1].split("/")[0]}}function v(e,n){var t=document.createElement("iframe");return t.className=e,t.width="0",t.height="0",t.frameBorder="0",t.src=n,t.tabIndex=-1,t.setAttribute("aria-hidden","true"),document.body.appendChild(t),t}function b(){var e=B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN+"/SessionWatcher.html?origin="+encodeURIComponent(location.origin);c=v("sky-omnibar-iframe-session-watcher",e)}function y(e){if("string"==typeof e.data){var n=void 0;try{n=JSON.parse(e.data)}catch(e){return}if("session_change"===n.messageType){var t=n.message,o=t&&t.sessionId,c=t&&t.refreshId;o||s||(d?f.BBAuthNavigator.navigate(d):f.BBAuthNavigator.redirectToSignin()),void 0!==h.refreshId&&c!==h.refreshId&&function(e){u&&l.BBAuthInterop.postOmnibarMessage(u,e,p(i))}({messageType:"session-refresh"}),void 0!==h.sessionId&&o!==h.sessionId&&r(),h.refreshId=c,h.sessionId=o,a(h)}}}function g(e){switch(e.origin){case B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN:y(e);break;case p(i):!function(e){var n=e.data;switch(n.messageType){case"ready":h.legacyTtl=n.ttl,d=n.signinUrl,a(h)}}(e)}}var B=function(){function e(){}return e.start=function(n,t,c,d){o&&n===s&&t===i||(e.stop(),s=n,r=c,i=t,a=d,b(),i&&(u=v("sky-omnibar-iframe-legacy-keep-alive",i)),window.addEventListener("message",g,!1),o=!0)},e.stop=function(){window.removeEventListener("message",g,!1),c&&(document.body.removeChild(c),c=void 0),u&&(document.body.removeChild(u),u=void 0),h={},o=s=r=i=d=a=void 0},e.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN=m.BBAuthDomain.getSTSDomain(),e}();n.BBOmnibarUserSessionWatcher=B},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a=t(3),s=t(4);function c(e){if(s.BBAuthInterop.messageIsFromOmnibar(e))switch(e.data.messageType){case"ready":s.BBAuthInterop.postOmnibarMessage(i,{messageType:"host-ready"}),i.classList.add("sky-omnibar-inactivity-iframe-ready");break;case"session-renew":r()}}var u=function(){function e(){}return e.show=function(n){var t;this.hide(),r=n.sessionRenewCallback,o=a.BBAuthDomUtility.addCss("\n .sky-omnibar-inactivity-iframe {\n background-color: transparent;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 100000;\n visibility: hidden;\n }\n\n .sky-omnibar-inactivity-iframe-ready {\n visibility: visible;\n }\n "),t=e.url,i=a.BBAuthDomUtility.addIframe(t,"sky-omnibar-inactivity-iframe","Inactivity Prompt"),window.addEventListener("message",c)},e.hide=function(){i&&(a.BBAuthDomUtility.removeEl(i),a.BBAuthDomUtility.removeCss(o),i=o=r=void 0,window.removeEventListener("message",c))},e.url="https://host.nxt.blackbaud.com/omnibar/inactivity",e}();n.BBOmnibarUserActivityPrompt=u},function(e,n,t){"use strict";var o=this&&this.__awaiter||function(e,n,t,o){return new(t||(t=Promise))((function(i,r){function a(e){try{c(o.next(e))}catch(e){r(e)}}function s(e){try{c(o.throw(e))}catch(e){r(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((o=o.apply(e,n||[])).next())}))},i=this&&this.__generator||function(e,n){var t,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===r[0]||2===r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=n.call(e,a)}catch(e){r=[6,e],o=0}finally{t=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}};Object.defineProperty(n,"__esModule",{value:!0});var r,a=t(0),s=t(8),c=function(){function e(){}return e.connect=function(e,n,t){return o(this,void 0,void 0,(function(){return i(this,(function(o){return r||(r=window.BBNotificationsClient?Promise.resolve():s.BBOmnibarScriptLoader.registerScript(this.NOTIFICATIONS_CLIENT_URL)),[2,r.then((function(){BBNotificationsClient.BBNotifications.init({tokenCallback:function(){return a.BBAuth.getToken({disableRedirect:!0,envId:n,leId:e})}}),BBNotificationsClient.BBNotifications.addListener(t)}))]}))}))},e.disconnect=function(){return o(this,void 0,void 0,(function(){return i(this,(function(e){return r?[2,r.then((function(){BBNotificationsClient.BBNotifications.destroy(),r=void 0}))]:[2,Promise.resolve()]}))}))},e.updateNotifications=function(e){BBNotificationsClient.BBNotifications.updateNotifications(e)},e.NOTIFICATIONS_CLIENT_URL="https://sky.blackbaudcdn.net/static/notifications-client/1/notifications-client.global.min.js",e}();n.BBOmnibarPushNotifications=c},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u=t(6),d=t(3),l=t(4),f="sky-omnibar-toast-container",m=f+"-ready",h=f+"-empty",p=20;function v(){return i||(o=d.BBAuthDomUtility.addCss("\n."+f+" {\n border: none;\n display: none;\n position: fixed;\n right: 0px;\n height: 0px;\n width: 300px;\n /* z-index is 1 less than omnibar so menus will display over top the toast container */\n z-index: 999;\n}\n\n."+m+" {\n display: block;\n}\n\n."+h+" {\n visibility: hidden;\n}\n"),(i=document.createElement("iframe")).src=B.CONTAINER_URL,i.className=f+" "+h,i.title="Toast container",document.body.appendChild(i),window.addEventListener("message",g)),i}function b(e){var n=document.querySelector(e);return n?n.getBoundingClientRect().height:0}function y(){i&&l.BBAuthInterop.postOmnibarMessage(i,{href:c,messageType:"location-change"})}function g(e){if(l.BBAuthInterop.messageIsFromToastContainer(e)){var n,t,o=e.data;switch(o.messageType){case"toast-ready":l.BBAuthInterop.postOmnibarMessage(i,{messageType:"host-ready"}),l.BBAuthInterop.postOmnibarMessage(i,{envId:s.envId,leId:s.leId,messageType:"nav-ready",svcId:s.svcId}),y(),i.classList.add(m),a();break;case"get-token":n=o.tokenRequestId,t=o.disableRedirect,u.BBAuth.getToken({disableRedirect:t}).then((function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"token",token:e,tokenRequestId:n})}),(function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"token-fail",reason:e,tokenRequestId:n})}));break;case"navigate-url":s.navigateUrlCallback(o.url);break;case"navigate":s.navigateCallback(o.navItem);break;case"toast-container-change":o.height>0?(i.style.height=o.height+"px",i.style.top=b(".sky-omnibar-iframe")+b(".sky-omnibar-environment")+p+"px",i.classList.remove(h)):i.classList.add(h);break;case"push-notifications-open":s.openMenuCallback()}}}var B=function(){function e(){}return e.init=function(e){return s=e,c=e.url,r||(r=new Promise((function(e){a=e,v()}))),r},e.showNewNotifications=function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"push-notifications-update",pushNotifications:e})},e.updateUrl=function(e){c=e,y()},e.destroy=function(){o&&d.BBAuthDomUtility.removeCss(o),i&&d.BBAuthDomUtility.removeEl(i),c=i=s=r=a=o=void 0,window.removeEventListener("message",g)},e.CONTAINER_URL="https://host.nxt.blackbaud.com/omnibar/toast",e}();n.BBOmnibarToastContainer=B},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(8);function i(){return window.jQuery}var r=function(){function e(){}return e.load=function(e){return new Promise((function(n){var t=i(),r=t&&t.fn&&t.fn.jquery;o.BBOmnibarScriptLoader.smartRegisterScript("https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.js","2.1.0",r).then((function(){return o.BBOmnibarScriptLoader.registerScript("https://cdnjs.cloudflare.com/ajax/libs/easyXDM/2.4.17.1/easyXDM.min.js")})).then((function(){return o.BBOmnibarScriptLoader.registerScript("https://signin.blackbaud.com/Omnibar.min.js")})).then((function(){document.body.classList.add("bb-omnibar-height-padding");var t=document.createElement("div");t.setAttribute("data-omnibar-el",""),document.body.appendChild(t),(e=e||{})["z-index"]=1e3,e.afterLoad=n,e.menuEl&&(e.menuEl=i()(e.menuEl)),BBAUTH.Omnibar.load(t,e)}))}))},e}();n.BBOmnibarLegacy=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0})}]); |
@@ -1,1 +0,1 @@ | ||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.BBAuthClient=t():e.BBAuthClient=t()}(window,(function(){return function(e){var t={};function n(o){if(t[o])return t[o].exports;var i=t[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(o,i,function(t){return e[t]}.bind(null,i));return o},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=9)}([function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(6)),o(n(7))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i="https://signin.blackbaud.com/signin/",s="https://host.nxt.blackbaud.com/errors/",r=encodeURIComponent;function a(e){let t=`${i}?redirectUrl=${r(location.href)}`;return e&&(t+="&inactivity=1"),t}t.BBAuthNavigator=class{static navigate(e,t){t?location.replace(e):location.href=e}static redirectToSignin(e){let t=a();e&&(t+="&"+function(e){const t=[];for(const n in e)e.hasOwnProperty(n)&&t.push(`${r(n)}=${r(e[n])}`);return t.join("&")}(e)),this.navigate(t)}static redirectToSignoutForInactivity(){const e=a(!0),t=`${i}sign-out?redirectUrl=${r(e)}`;this.navigate(t)}static redirectToError(e){let t,n;switch(e){case o.BBAuthTokenErrorCode.InvalidEnvironment:n="invalid_env",t="security";break;default:t="broken"}let i=`${s}${t}?source=auth-client&url=${r(location.href)}`;n&&(i+=`&code=${r(n)}`),this.navigate(i)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o={"bbk12.com":"https://sts-sso.bbk12.com","blackbaudfaith.com":"https://sts.blackbaudfaith.com","donorcentral.com":"https://sts-dc.donorcentral.com","mycampus-app.com":"https://sts-sso.mycampus-app.com","myschoolapp.com":"https://sts-sso.myschoolapp.com","myschoolautomation.com":"https://sts-sso.myschoolautomation.com","myschooldemo.com":"https://sts-sso.myschooldemo.com","myschooltraining.com":"https://sts-sso.myschooltraining.com"},i="https://s21aidntoken00blkbapp01.nxt.blackbaud.com";class s{static getRegisteredDomain(){for(const e of Object.keys(o)){const t=`.${e}`;if(this.CURRENT_DOMAIN===e||this.CURRENT_DOMAIN.substr(-t.length)===t)return e}}static getSTSDomain(){const e=this.getRegisteredDomain();return o[e]||i}}s.CURRENT_DOMAIN=window.location.hostname,t.BBAuthDomain=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.BBAuthDomUtility=class{static addCss(e){const t=document.createElement("style");return t.appendChild(document.createTextNode(e)),document.head.appendChild(t),t}static addIframe(e,t,n){const o=document.createElement("iframe");return o.className=t,o.title=n,o.src=e,this.addElToBodyTop(o),o}static removeCss(e){this.removeEl(e,document.head)}static removeEl(e,t=document.body){t.contains(e)&&t.removeChild(e)}static addElToBodyTop(e){const t=document.body;t.firstChild?t.insertBefore(e,t.firstChild):t.appendChild(e)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o="https://host.nxt.blackbaud.com";function i(e,t){if(e.origin===o){const n=e.data;return!!n&&n.source===t}return!1}t.BBAuthInterop=class{static postOmnibarMessage(e,t,n){t.source="auth-client",e.contentWindow.postMessage(t,n||o)}static messageIsFromOmnibar(e){return i(e,"skyux-spa-omnibar")}static messageIsFromToastContainer(e){return i(e,"skyux-spa-omnibar-toast-container")}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i=n(2),s=n(1);function r(e,t,n,o){return(o||void 0===o&&n)&&((e=e||{})[t]=n),e}function a(e,t,n,i,s){let a;return a=r(a,"environment_id",n),a=r(a,"legal_entity_id",s),a=r(a,"permission_scope",i,!(!n&&!s||!i)),new Promise((n,i)=>{!function(e,t,n,i,s){const r=new XMLHttpRequest;r.onreadystatechange=()=>{if(4===r.readyState)switch(r.status){case 0:s({code:o.BBAuthTokenErrorCode.Offline,message:"The user is offline."});break;case 200:i(r.responseText);break;case 401:s({code:o.BBAuthTokenErrorCode.NotLoggedIn,message:"The user is not logged in."});break;case 403:s({code:o.BBAuthTokenErrorCode.InvalidEnvironment,message:"The user is not a member of the specified environment."});break;default:r.status>=400&&s({code:o.BBAuthTokenErrorCode.Unspecified,message:"An unknown error occurred."})}},r.open("POST",e,!0),r.setRequestHeader(t.name,t.value),r.setRequestHeader("Accept","application/json"),r.setRequestHeader("Content-Type","application/json"),r.withCredentials=!0,n?r.send(JSON.stringify(n)):r.send()}(e,{name:"X-CSRF",value:t},a,e=>{const t=e?JSON.parse(e):void 0;n(t)},i)})}t.BBCsrfXhr=class{static request(e,t,n,r,c,d,u){return!c||r||d?new Promise((l,m)=>{new Promise((e,t)=>{u?e({csrf_token:"token_needed"}):a(i.BBAuthDomain.getSTSDomain()+"/session/csrf","token_needed").then(e).catch(t)}).then(t=>a(e,t.csrf_token,r,c,d)).then(l).catch(e=>{if(n||e.code===o.BBAuthTokenErrorCode.Offline)m(e);else switch(e.code){case o.BBAuthTokenErrorCode.NotLoggedIn:s.BBAuthNavigator.redirectToSignin(t);break;default:s.BBAuthNavigator.redirectToError(e.code)}})}):Promise.reject({code:o.BBAuthTokenErrorCode.PermissionScopeNoEnvironment,message:"You must also specify an environment or legal entity when specifying a permission scope."})}static requestWithToken(e,t){return new Promise((n,o)=>{const i=new XMLHttpRequest;i.onreadystatechange=()=>{if(4===i.readyState)switch(i.status){case 200:n(JSON.parse(i.responseText));break;default:o()}},i.open("GET",e,!0),i.setRequestHeader("Authorization","Bearer "+t),i.setRequestHeader("Accept","application/json"),i.send()})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(10),i=/1bb:\/\/([a-z]{3})-([a-z0-9]{5})(-[a-z]{4}[0-9]{2})?\/(.*)/;class s{static getUrl(e,t){const n=i.exec(e);let o=e,s=t?t.zone:void 0;return s&&(s=s.replace("-","")),n&&(n[3]&&(s=n[3].substring(1)),o=`https://${n[1]}-${s}.app.blackbaud.net/${n[2]}/${n[4]}`),Promise.resolve(o)}static getToken(e){return s.getTokenInternal(e)}static clearTokenCache(){s.tokenCache={}}static getTokenInternal(e){e=e||{};const{forceNewToken:t,disableRedirect:n}=e;if(s.mock)return Promise.resolve("mock_access_token_auth-client@blackbaud.com");const i=function(e){const{envId:t,permissionScope:n,leId:o}=e;return"token|"+(o||"-")+"|"+(t||"-")+"|"+(n||"-")}(e),r=s.tokenCache[i]=s.tokenCache[i]||{},a=(new Date).valueOf();return!t&&r.lastToken&&r.expirationTime&&r.expirationTime-a>6e4?Promise.resolve(r.lastToken):(r.pendingLookupPromise||(r.pendingLookupPromise=o.BBAuthTokenIntegration.getToken(n,e.envId,e.permissionScope,e.leId).then(e=>(r.expirationTime=(new Date).valueOf()+1e3*e.expires_in,r.lastToken=e.access_token,r.pendingLookupPromise=null,r.lastToken)).catch(e=>{throw r.pendingLookupPromise=null,e})),r.pendingLookupPromise)}}s.mock=!1,s.tokenCache={},t.BBAuth=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.Unspecified=0]="Unspecified",e[e.NotLoggedIn=1]="NotLoggedIn",e[e.InvalidEnvironment=2]="InvalidEnvironment",e[e.PermissionScopeNoEnvironment=3]="PermissionScopeNoEnvironment",e[e.Offline=4]="Offline"}(t.BBAuthTokenErrorCode||(t.BBAuthTokenErrorCode={}))},function(e,t,n){"use strict";function o(e){const t=e.split("."),n=[];for(const e of t){const t=parseInt(e,10)||0;n.push(t)}return n}Object.defineProperty(t,"__esModule",{value:!0});class i{static registerScript(e){return new Promise((t,n)=>{const o=document.createElement("script");o.onload=t,o.onerror=n,o.src=e,document.body.appendChild(o)})}static smartRegisterScript(e,t,n){return n&&function(e,t){const n=o(e),i=o(t);for(let e=0;e<n.length;e++)if(e<i.length){if(i[e]>n[e])return!0;if(i[e]<n[e])return!1}return!0}(t,n)?Promise.resolve():i.registerScript(e)}}t.BBOmnibarScriptLoader=i},function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(0)),o(n(12)),o(n(14))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(5),i=n(11),s=n(2);t.BBAuthTokenIntegration=class{static getToken(e,t,n,r){return void 0!==s.BBAuthDomain.getRegisteredDomain()||this.hostNameEndsWith("blackbaud.com")?o.BBCsrfXhr.request(s.BBAuthDomain.getSTSDomain()+"/oauth2/token",void 0,e,t,n,r,!0):i.BBAuthCrossDomainIframe.getToken({disableRedirect:e,envId:t,leId:r,permissionScope:n})}static hostNameEndsWith(e){return this.getLocationHostname().substr(-e.length)===e}static getLocationHostname(){return window.location.hostname}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(3),i=n(1),s=n(7),r="https://s21aidntoken00blkbapp01.nxt.blackbaud.com/Iframes/CrossDomainAuthFrame.html",a="security-token-svc",c="auth-client";class d{static reset(){this.requestCounter=0,this.tokenRequests={},this.iframeReadyPromise=new Promise(e=>this.iframeReadyResolve=e),this.listenerSetup=!1}static TARGET_ORIGIN(){return this.TARGETORIGIN}static getOrMakeIframe(){return d.iframeEl=document.getElementById("auth-cross-domain-iframe"),d.iframeEl||(d.iframeEl=o.BBAuthDomUtility.addIframe(r,"auth-cross-domain-iframe",""),d.iframeEl.id="auth-cross-domain-iframe",d.iframeEl.hidden=!0),d.iframeEl}static getToken(e){return this.setupListenersForIframe(),this.getTokenFromIframe(this.getOrMakeIframe(),e)}static setupListenersForIframe(){this.listenerSetup||(window.addEventListener("message",e=>{const t=e.data,n=t.requestId,o=this.tokenRequests[n];if(t.source===a||t.origin===this.TARGET_ORIGIN())switch(t.messageType){case"ready":this.iframeReadyResolve(!0);break;case"error":this.handleErrorMessage(t.value,o.reject,o.args.disableRedirect);break;case"getToken":const e={access_token:t.value,expires_in:0};o.resolve(e)}}),this.listenerSetup=!0)}static getTokenFromIframe(e,t){return new Promise((n,o)=>{const i=this.requestCounter++;d.tokenRequests[i]={args:t,reject:o,resolve:n},d.iframeReadyPromise.then(()=>{e.contentWindow.postMessage({messageType:"getToken",requestId:i,source:c,value:t},d.TARGET_ORIGIN())})})}static handleErrorMessage(e,t,n){if(n)t(e);else switch(e.code){case s.BBAuthTokenErrorCode.Offline:t(e);break;case s.BBAuthTokenErrorCode.NotLoggedIn:i.BBAuthNavigator.redirectToSignin(void 0);break;default:i.BBAuthNavigator.redirectToError(e.code)}}}d.listenerSetup=!1,d.iframeReadyPromise=new Promise(e=>d.iframeReadyResolve=e),d.tokenRequests={},d.requestCounter=0,d.TARGETORIGIN="https://s21aidntoken00blkbapp01.nxt.blackbaud.com",t.BBAuthCrossDomainIframe=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(n(13))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i=n(4),s=n(5),r=n(3),a=n(1);function c(e,t,n,s){let a,c;function d(){r.BBAuthDomUtility.removeEl(c),r.BBAuthDomUtility.removeCss(a),c=a=void 0,window.removeEventListener("message",l)}function l(r){if(!i.BBAuthInterop.messageIsFromOmnibar(r))return;const a=r.data;switch(a.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),i.BBAuthInterop.postOmnibarMessage(c,{contextDestinations:t,messageType:"context-provide"});break;case"get-token":u=a.tokenRequestId,l=a.disableRedirect,o.BBAuth.getToken({disableRedirect:l}).then(e=>{i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:u})},e=>{i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:u})});break;case"welcome-cancel":d(),s({reason:"canceled"});break;case"welcome-environment-selected":d(),setTimeout(()=>{e.envId=a.envId,n(e)},10)}var u,l}a=r.BBAuthDomUtility.addCss("\n.sky-omnibar-welcome-iframe {\n background-color: #fff;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n"),function(){const t=u.url+"?hosted=1&svcid="+encodeURIComponent(e.svcId)+"&url="+encodeURIComponent(e.url);c=r.BBAuthDomUtility.addIframe(t,"sky-omnibar-welcome-iframe","Welcome")}(),window.addEventListener("message",l)}function d(){a.BBAuthNavigator.redirectToError(o.BBAuthTokenErrorCode.InvalidEnvironment)}class u{static ensureContext(e){const{envId:t,envIdRequired:n,leId:i,leIdRequired:r,svcId:a}=e;return!t&&n||!i&&r?new Promise((t,n)=>{a?o.BBAuth.getToken().then(o=>{let i="https://s21anavnavaf00blkbapp01.sky.blackbaud.com/user/destinations?svcid="+encodeURIComponent(a);e.url&&(i+="&referringurl="+encodeURIComponent(e.url)),s.BBCsrfXhr.requestWithToken(i,o).then(o=>{const i=o&&o.items,s=i&&i.length;1===s?(e.url=i[0].url,t(e)):s>1?c(e,o,t,n):d()})}):d()}):Promise.resolve(e)}}u.url="https://host.nxt.blackbaud.com/omnibar/welcome",t.BBContextProvider=u},function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(15)),o(n(26)),o(n(27))},function(e,t,n){"use strict";var o=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(i,s){function r(e){try{c(o.next(e))}catch(e){s(e)}}function a(e){try{c(o.throw(e))}catch(e){s(e)}}function c(e){e.done?i(e.value):new n((function(t){t(e.value)})).then(r,a)}c((o=o.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const i=n(16),s=n(0),r=n(4),a=n(1),c=n(3),d=n(19),u=n(23),l=n(24),m=n(25),p="sky-omnibar-iframe-expanded",h="sky-omnibar-loading";let f,b,v,g,B,y,k,I,T,A,w;function O(){g=c.BBAuthDomUtility.addIframe(B.url||"https://host.nxt.blackbaud.com/omnibar/",`sky-omnibar-iframe ${h}`,"Navigation")}function E(){const e=document.location.href;r.BBAuthInterop.postOmnibarMessage(g,{href:e,messageType:"location-change"}),m.BBOmnibarToastContainer.updateUrl(e)}function _(){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"push-notifications-open"})}function N(){I||(I=!0,D.pushNotificationsEnabled().then(e=>{e?m.BBOmnibarToastContainer.init({envId:B.envId,leId:B.leId,navigateCallback:x,navigateUrlCallback:M,openMenuCallback:_,svcId:B.svcId,url:document.location.href}).then(()=>{l.BBOmnibarPushNotifications.connect(B.leId,B.envId,e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"push-notifications-update",pushNotifications:e}),m.BBOmnibarToastContainer.showNewNotifications(e),T=e&&e.notifications&&e.notifications.filter(e=>!e.isRead).length,L()})}):I=!1}))}function C(){function e(e){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"refresh-user",token:e}),e?N():I&&(m.BBOmnibarToastContainer.destroy(),l.BBOmnibarPushNotifications.disconnect(),I=!1)}s.BBAuth.clearTokenCache(),s.BBAuth.getToken({disableRedirect:!0,forceNewToken:!0}).then(e).catch(()=>e(void 0))}function R(){u.BBOmnibarUserActivityPrompt.show({sessionRenewCallback:()=>{d.BBOmnibarUserActivity.userRenewedSession()}})}function S(){u.BBOmnibarUserActivityPrompt.hide()}function P(){d.BBOmnibarUserActivity.startTracking(C,R,S,B.allowAnonymous,y)}function x(e){const t=B.nav;t&&t.beforeNavCallback&&!1===t.beforeNavCallback(e)||a.BBAuthNavigator.navigate(e.url)}function M(e){a.BBAuthNavigator.navigate(e)}function U(e){if(!r.BBAuthInterop.messageIsFromOmnibar(e))return;const t=e.data,n=B.nav;switch(t.messageType){case"ready":r.BBAuthInterop.postOmnibarMessage(g,{messageType:"host-ready"}),function(){const e=history.pushState,t=history.replaceState;history.pushState=function(){const t=e.apply(history,arguments);return E(),t},history.replaceState=function(){const e=t.apply(history,arguments);return E(),e}}(),r.BBAuthInterop.postOmnibarMessage(g,{compactNavOnly:B.compactNavOnly,enableHelp:B.enableHelp,envId:B.envId,hideResourceLinks:B.hideResourceLinks,leId:B.leId,localNavItems:n&&n.localNavItems,localNotifications:!!B.notifications,localSearch:!!B.onSearch,messageType:"nav-ready",navVersion:B.navVersion,services:n&&n.services,svcId:B.svcId,theme:B.theme}),function(){const e=B.notifications;e&&e.onReady({updateNotifications:e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"notifications-update",notifications:e})}})}(),N(),E(),k();break;case"display-ready":b.classList.remove(h),g.classList.remove(h);break;case"expand":g.classList.add(p);break;case"collapse":g.classList.remove(p);break;case"navigate-url":M(t.url);break;case"navigate":x(t.navItem);break;case"search":c=t.searchArgs,B.onSearch&&B.onSearch(c).then(e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"search-results",results:e})});break;case"get-token":i=t.tokenRequestId,a=t.disableRedirect,s.BBAuth.getToken({disableRedirect:a}).then(e=>{P(),r.BBAuthInterop.postOmnibarMessage(g,{messageType:"token",token:e,tokenRequestId:i})},e=>{P(),r.BBAuthInterop.postOmnibarMessage(g,{messageType:"token-fail",reason:e,tokenRequestId:i})});break;case"help-open":!function(){const e=window.BBHELP;e&&e.HelpWidget.open()}();break;case"notification-read":!function(e){const t=B.notifications;t&&t.onNotificationRead&&t.onNotificationRead(e)}(t.notification);break;case"push-notifications-change":o=t.notifications,l.BBOmnibarPushNotifications.updateNotifications(o);break;case"session-renew":d.BBOmnibarUserActivity.userRenewedSession();break;case"environment-update":!function(e){const t="sky-omnibar-environment-visible",n=document.body.classList;e=e||"",f.innerText=e,e?n.add(t):n.remove(t)}(t.name);break;case"legacy-keep-alive-url-change":y=t.url,P();break;case"selected-service-update":A=t.serviceName,L()}var o,i,a,c}function L(){if(w){const e=w.slice();A&&e.push(A);let t=e.join(" - ");T&&(t=`(${T}) ${t}`),document.title=t}}class D{static load(e){return B=B=e,y=B.legacyKeepAliveUrl,new Promise(e=>{k=e,function(){let e="background: linear-gradient(to right, #71bf44 0, #31b986 50%, #00b2ec 100%);",t="#4d5259";const n=B.theme;if(n){const o=n.accent;t=n.backgroundColor||t,!1===o?e="display: none;":o&&o.color&&(e=`background-color: ${o.color};`)}v=c.BBAuthDomUtility.addCss(`\nbody {\n margin-top: 50px;\n}\n\n#bb-help-container {\n padding-top: 1px;\n}\n\n.sky-omnibar-iframe,\n.sky-omnibar-placeholder {\n border: none;\n height: 50px;\n width: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n z-index: 1000;\n}\n\n.sky-omnibar-placeholder {\n background-color: ${t};\n display: none;\n}\n\n.sky-omnibar-placeholder-accent {\n height: 5px;\n ${e}\n}\n\n.sky-omnibar-placeholder.${h} {\n display: block;\n}\n\n.sky-omnibar-iframe.${h} {\n visibility: hidden;\n}\n\n.${p} {\n height: 100%;\n}\n\n.sky-omnibar-environment {\n background-color: #e1e1e3;\n color: #282b31;\n font-family: "Blackbaud Sans", "Open Sans", "Helvetica Neue", Arial, sans-serif;\n font-size: 12px;\n font-weight: 400;\n height: 0;\n line-height: 24px;\n overflow: hidden;\n padding: 0 15px;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.sky-omnibar-environment-visible .sky-omnibar-environment {\n height: 24px;\n}\n`)}(),(b=document.createElement("div")).className=`sky-omnibar-placeholder ${h}`,b.innerHTML='<div class="sky-omnibar-placeholder-accent"></div>',document.body.appendChild(b),(f=document.createElement("div")).className="sky-omnibar-environment",c.BBAuthDomUtility.addElToBodyTop(f),O(),window.addEventListener("message",U)})}static update(e){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"update",updateArgs:e})}static setTitle(e){w=e&&e.titleParts,L()}static pushNotificationsEnabled(){return o(this,void 0,void 0,(function*(){return B?s.BBAuth.getToken({disableRedirect:!0,envId:B.envId,leId:B.leId,permissionScope:"Notifications"}).then(e=>{let t=i(e)["1bb.entitlements"];return!!t&&(t=Array.isArray(t)?t:[t]).indexOf("notif")>-1}).catch(()=>!1):Promise.resolve(!1)}))}static destroy(){m.BBOmnibarToastContainer.destroy(),l.BBOmnibarPushNotifications.disconnect(),c.BBAuthDomUtility.removeEl(b),c.BBAuthDomUtility.removeEl(g),c.BBAuthDomUtility.removeEl(f),c.BBAuthDomUtility.removeCss(v),window.removeEventListener("message",U),B=v=b=g=f=k=I=T=w=A=void 0}}t.BBOmnibar=D},function(e,t,n){"use strict";var o=n(17);function i(e){this.message=e}i.prototype=new Error,i.prototype.name="InvalidTokenError",e.exports=function(e,t){if("string"!=typeof e)throw new i("Invalid token specified");var n=!0===(t=t||{}).header?0:1;try{return JSON.parse(o(e.split(".")[n]))}catch(e){throw new i("Invalid token specified: "+e.message)}},e.exports.InvalidTokenError=i},function(e,t,n){var o=n(18);e.exports=function(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(o(e).replace(/(.)/g,(function(e,t){var n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(t)}catch(e){return o(t)}}},function(e,t){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function o(e){this.message=e}o.prototype=new Error,o.prototype.name="InvalidCharacterError",e.exports="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var t=String(e).replace(/=+$/,"");if(t.length%4==1)throw new o("'atob' failed: The string to be decoded is not correctly encoded.");for(var i,s,r=0,a=0,c="";s=t.charAt(a++);~s&&(i=r%4?64*i+s:s,r++%4)?c+=String.fromCharCode(255&i>>(-2*r&6)):0)s=n.indexOf(s);return c}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(2),i=n(5),s=n(20),r=n(21),a=n(22),c=n(1);let d,u,l,m,p,h,f,b,v,g,B,y,k,I,T="";function A(){b=Date.now()}function w(e){e.clientX===u&&e.clientY===l||(u=e.clientX,l=e.clientY,A())}function O(){const e=Date.now();(!v||e-v>C.MIN_RENEWAL_RETRY)&&(v=e,i.BBCsrfXhr.request(o.BBAuthDomain.getSTSDomain()+"/session/renew",{inactivity:1}).catch(()=>void 0))}function E(){f=!0,h()}function _(){f=!1,A(),m()}function N(){I?c.BBAuthNavigator.navigate(I):c.BBAuthNavigator.redirectToSignoutForInactivity()}class C{static startTracking(e,t,n,o,i){d&&o===B&&i===y||(C.stopTracking(),p=e,h=t,m=n,B=o,y=i,document.addEventListener("keypress",A),document.addEventListener("mousemove",w),B||O(),g=setInterval(()=>{r.BBOmnibarUserSessionExpiration.getSessionExpiration(T,k,B).then(e=>{d&&s.BBOmnibarUserActivityProcessor.process({allowAnonymous:B,closeInactivityPrompt:_,expirationDate:e,inactivityPromptDuration:C.INACTIVITY_PROMPT_DURATION,isShowingInactivityPrompt:f,lastActivity:b,maxSessionAge:C.MAX_SESSION_AGE,minRenewalAge:C.MIN_RENEWAL_AGE,redirectForInactivity:N,renewSession:O,showInactivityPrompt:E})})},C.ACTIVITY_TIMER_INTERVAL),a.BBOmnibarUserSessionWatcher.start(o,i,p,e=>{k=e.legacyTtl,T=e.refreshId,I=e.legacySigninUrl}),d=!0)}static userRenewedSession(){_(),O()}static stopTracking(){a.BBOmnibarUserSessionWatcher.stop(),r.BBOmnibarUserSessionExpiration.reset(),document.removeEventListener("keypress",A),document.removeEventListener("mousemove",w),g&&(clearInterval(g),g=void 0),d=u=l=b=v=f=p=h=m=B=y=void 0}}C.ACTIVITY_TIMER_INTERVAL=1e3,C.MIN_RENEWAL_RETRY=6e4,C.INACTIVITY_PROMPT_DURATION=12e4,C.MIN_RENEWAL_AGE=3e5,C.MAX_SESSION_AGE=54e5,t.BBOmnibarUserActivity=C},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.BBOmnibarUserActivityProcessor=class{static process(e){const{allowAnonymous:t,closeInactivityPrompt:n,expirationDate:o,inactivityPromptDuration:i,isShowingInactivityPrompt:s,lastActivity:r,maxSessionAge:a,minRenewalAge:c,redirectForInactivity:d,renewSession:u,showInactivityPrompt:l}=e,m=Date.now();if(null===o)return;!t&&m>o&&d();const p=o-i,h=o-a+c;s?m<p&&n():r>h?u():!t&&m>p&&l()}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(2),i=n(5);let s;t.BBOmnibarUserSessionExpiration=class{static getSessionExpiration(e,t,n){const r=function(e,t){if(s&&s.refreshId===e&&s.allowAnonymous===t)return s.promise;const n=new Promise((e,n)=>{i.BBCsrfXhr.request(o.BBAuthDomain.getSTSDomain()+"/session/ttl",void 0,t).then(t=>{const n=null===t?null:Date.now()+1e3*t;e(n)},()=>{e(null)})});return s={allowAnonymous:t,promise:n,refreshId:e},n}(e,n);return new Promise((e,n)=>{r.then(n=>{let o;if(null===n)o=null;else if("number"==typeof t){const e=Date.now()+t;o=Math.min(n,e)}else o=n;e(o)})})}static reset(){s=void 0}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(4),i=n(1),s=n(2);let r,a,c,d,u,l,m,p,h={};function f(e){if(e){const t=e.split("://");return`${t[0]}://${t[1].split("/")[0]}`}}function b(e,t){const n=document.createElement("iframe");return n.className=e,n.width="0",n.height="0",n.frameBorder="0",n.src=t,n.tabIndex=-1,n.setAttribute("aria-hidden","true"),document.body.appendChild(n),n}function v(e){if("string"==typeof e.data){let t;try{t=JSON.parse(e.data)}catch(e){return}if("session_change"===t.messageType){const e=t.message,n=e&&e.sessionId,s=e&&e.refreshId;n||u||(p?i.BBAuthNavigator.navigate(p):i.BBAuthNavigator.redirectToSignin()),void 0!==h.refreshId&&s!==h.refreshId&&function(e){m&&o.BBAuthInterop.postOmnibarMessage(m,e,f(a))}({messageType:"session-refresh"}),void 0!==h.sessionId&&n!==h.sessionId&&c(),h.refreshId=s,h.sessionId=n,d(h)}}}function g(e){switch(e.origin){case B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN:v(e);break;case f(a):!function(e){const t=e.data;switch(t.messageType){case"ready":h.legacyTtl=t.ttl,p=t.signinUrl,d(h)}}(e)}}class B{static start(e,t,n,o){r&&e===u&&t===a||(B.stop(),u=e,c=n,a=t,d=o,function(){const e=B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN+"/SessionWatcher.html?origin="+encodeURIComponent(location.origin);l=b("sky-omnibar-iframe-session-watcher",e)}(),a&&(m=b("sky-omnibar-iframe-legacy-keep-alive",a)),window.addEventListener("message",g,!1),r=!0)}static stop(){window.removeEventListener("message",g,!1),l&&(document.body.removeChild(l),l=void 0),m&&(document.body.removeChild(m),m=void 0),h={},r=u=c=a=p=d=void 0}}B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN=s.BBAuthDomain.getSTSDomain(),t.BBOmnibarUserSessionWatcher=B},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(3),i=n(4);let s,r,a;function c(e){if(!i.BBAuthInterop.messageIsFromOmnibar(e))return;switch(e.data.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(r,{messageType:"host-ready"}),r.classList.add("sky-omnibar-inactivity-iframe-ready");break;case"session-renew":a()}}class d{static show(e){this.hide(),a=e.sessionRenewCallback,s=o.BBAuthDomUtility.addCss("\n .sky-omnibar-inactivity-iframe {\n background-color: transparent;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 100000;\n visibility: hidden;\n }\n\n .sky-omnibar-inactivity-iframe-ready {\n visibility: visible;\n }\n "),function(){const e=d.url;r=o.BBAuthDomUtility.addIframe(e,"sky-omnibar-inactivity-iframe","Inactivity Prompt")}(),window.addEventListener("message",c)}static hide(){r&&(o.BBAuthDomUtility.removeEl(r),o.BBAuthDomUtility.removeCss(s),r=s=a=void 0,window.removeEventListener("message",c))}}d.url="https://host.nxt.blackbaud.com/omnibar/inactivity",t.BBOmnibarUserActivityPrompt=d},function(e,t,n){"use strict";var o=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(i,s){function r(e){try{c(o.next(e))}catch(e){s(e)}}function a(e){try{c(o.throw(e))}catch(e){s(e)}}function c(e){e.done?i(e.value):new n((function(t){t(e.value)})).then(r,a)}c((o=o.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const i=n(0),s=n(8);let r;class a{static connect(e,t,n){return o(this,void 0,void 0,(function*(){return r||(r=window.BBNotificationsClient?Promise.resolve():s.BBOmnibarScriptLoader.registerScript(this.NOTIFICATIONS_CLIENT_URL)),r.then(()=>{BBNotificationsClient.BBNotifications.init({tokenCallback:()=>i.BBAuth.getToken({disableRedirect:!0,envId:t,leId:e})}),BBNotificationsClient.BBNotifications.addListener(n)})}))}static disconnect(){return o(this,void 0,void 0,(function*(){return r?r.then(()=>{BBNotificationsClient.BBNotifications.destroy(),r=void 0}):Promise.resolve()}))}static updateNotifications(e){BBNotificationsClient.BBNotifications.updateNotifications(e)}}a.NOTIFICATIONS_CLIENT_URL="https://sky.blackbaudcdn.net/static/notifications-client/1/notifications-client.global.min.js",t.BBOmnibarPushNotifications=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(6),i=n(3),s=n(4),r="sky-omnibar-toast-container",a=`${r}-ready`,c=`${r}-empty`,d=20;let u,l,m,p,h,f;function b(e){const t=document.querySelector(e);return t?t.getBoundingClientRect().height:0}function v(){l&&s.BBAuthInterop.postOmnibarMessage(l,{href:f,messageType:"location-change"})}function g(e){if(!s.BBAuthInterop.messageIsFromToastContainer(e))return;const t=e.data;switch(t.messageType){case"toast-ready":s.BBAuthInterop.postOmnibarMessage(l,{messageType:"host-ready"}),s.BBAuthInterop.postOmnibarMessage(l,{envId:h.envId,leId:h.leId,messageType:"nav-ready",svcId:h.svcId}),v(),l.classList.add(a),p();break;case"get-token":n=t.tokenRequestId,i=t.disableRedirect,o.BBAuth.getToken({disableRedirect:i}).then(e=>{s.BBAuthInterop.postOmnibarMessage(l,{messageType:"token",token:e,tokenRequestId:n})},e=>{s.BBAuthInterop.postOmnibarMessage(l,{messageType:"token-fail",reason:e,tokenRequestId:n})});break;case"navigate-url":h.navigateUrlCallback(t.url);break;case"navigate":h.navigateCallback(t.navItem);break;case"toast-container-change":t.height>0?(l.style.height=t.height+"px",l.style.top=b(".sky-omnibar-iframe")+b(".sky-omnibar-environment")+d+"px",l.classList.remove(c)):l.classList.add(c);break;case"push-notifications-open":h.openMenuCallback()}var n,i}class B{static init(e){return h=e,f=e.url,m||(m=new Promise(e=>{p=e,l||(u=i.BBAuthDomUtility.addCss(`\n.${r} {\n border: none;\n display: none;\n position: fixed;\n right: 0px;\n height: 0px;\n width: 300px;\n /* z-index is 1 less than omnibar so menus will display over top the toast container */\n z-index: 999;\n}\n\n.${a} {\n display: block;\n}\n\n.${c} {\n visibility: hidden;\n}\n`),(l=document.createElement("iframe")).src=B.CONTAINER_URL,l.className=`${r} ${c}`,l.title="Toast container",document.body.appendChild(l),window.addEventListener("message",g))})),m}static showNewNotifications(e){s.BBAuthInterop.postOmnibarMessage(l,{messageType:"push-notifications-update",pushNotifications:e})}static updateUrl(e){f=e,v()}static destroy(){u&&i.BBAuthDomUtility.removeCss(u),l&&i.BBAuthDomUtility.removeEl(l),f=l=h=m=p=u=void 0,window.removeEventListener("message",g)}}B.CONTAINER_URL="https://host.nxt.blackbaud.com/omnibar/toast",t.BBOmnibarToastContainer=B},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(8);function i(){return window.jQuery}t.BBOmnibarLegacy=class{static load(e){return new Promise(t=>{const n=i(),s=n&&n.fn&&n.fn.jquery;o.BBOmnibarScriptLoader.smartRegisterScript("https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.js","2.1.0",s).then(()=>o.BBOmnibarScriptLoader.registerScript("https://cdnjs.cloudflare.com/ajax/libs/easyXDM/2.4.17.1/easyXDM.min.js")).then(()=>o.BBOmnibarScriptLoader.registerScript("https://signin.blackbaud.com/Omnibar.min.js")).then(()=>{document.body.classList.add("bb-omnibar-height-padding");const n=document.createElement("div");n.setAttribute("data-omnibar-el",""),document.body.appendChild(n),(e=e||{})["z-index"]=1e3,e.afterLoad=t,e.menuEl&&(e.menuEl=i()(e.menuEl)),BBAUTH.Omnibar.load(n,e)})})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0})}])})); | ||
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.BBAuthClient=t():e.BBAuthClient=t()}(window,(function(){return function(e){var t={};function n(o){if(t[o])return t[o].exports;var i=t[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(o,i,function(t){return e[t]}.bind(null,i));return o},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=9)}([function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(6)),o(n(7))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i="https://signin.blackbaud.com/signin/",s="https://host.nxt.blackbaud.com/errors/",r=encodeURIComponent;function a(e){let t=`${i}?redirectUrl=${r(location.href)}`;return e&&(t+="&inactivity=1"),t}t.BBAuthNavigator=class{static navigate(e,t){t?location.replace(e):location.href=e}static redirectToSignin(e){let t=a();e&&(t+="&"+function(e){const t=[];for(const n in e)e.hasOwnProperty(n)&&t.push(`${r(n)}=${r(e[n])}`);return t.join("&")}(e)),this.navigate(t)}static redirectToSignoutForInactivity(){const e=a(!0),t=`${i}sign-out?redirectUrl=${r(e)}`;this.navigate(t)}static redirectToError(e){let t,n;switch(e){case o.BBAuthTokenErrorCode.InvalidEnvironment:n="invalid_env",t="security";break;default:t="broken"}let i=`${s}${t}?source=auth-client&url=${r(location.href)}`;n&&(i+=`&code=${r(n)}`),this.navigate(i)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o={"bbk12.com":"https://sts-sso.bbk12.com","blackbaudfaith.com":"https://sts.blackbaudfaith.com","blackbaudhosting.com":"https://sts.blackbaudhosting.com","donorcentral.com":"https://sts-dc.donorcentral.com","etapestry.com":"https://sts.etapestry.com","mycampus-app.com":"https://sts-sso.mycampus-app.com","myschoolapp.com":"https://sts-sso.myschoolapp.com","myschoolautomation.com":"https://sts-sso.myschoolautomation.com","myschooldemo.com":"https://sts-sso.myschooldemo.com","myschooltraining.com":"https://sts-sso.myschooltraining.com"},i="https://s21aidntoken00blkbapp01.nxt.blackbaud.com";class s{static getRegisteredDomain(){for(const e of Object.keys(o)){const t=`.${e}`;if(this.CURRENT_DOMAIN===e||this.CURRENT_DOMAIN.substr(-t.length)===t)return e}}static getSTSDomain(){const e=this.getRegisteredDomain();return o[e]||i}}s.CURRENT_DOMAIN=window.location.hostname,t.BBAuthDomain=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.BBAuthDomUtility=class{static addCss(e){const t=document.createElement("style");return t.appendChild(document.createTextNode(e)),document.head.appendChild(t),t}static addIframe(e,t,n){const o=document.createElement("iframe");return o.className=t,o.title=n,o.src=e,this.addElToBodyTop(o),o}static removeCss(e){this.removeEl(e,document.head)}static removeEl(e,t=document.body){t.contains(e)&&t.removeChild(e)}static addElToBodyTop(e){const t=document.body;t.firstChild?t.insertBefore(e,t.firstChild):t.appendChild(e)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o="https://host.nxt.blackbaud.com";function i(e,t){if(e.origin===o){const n=e.data;return!!n&&n.source===t}return!1}t.BBAuthInterop=class{static postOmnibarMessage(e,t,n){t.source="auth-client",e.contentWindow.postMessage(t,n||o)}static messageIsFromOmnibar(e){return i(e,"skyux-spa-omnibar")}static messageIsFromToastContainer(e){return i(e,"skyux-spa-omnibar-toast-container")}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i=n(2),s=n(1);function r(e,t,n,o){return(o||void 0===o&&n)&&((e=e||{})[t]=n),e}function a(e,t,n,i,s){let a;return a=r(a,"environment_id",n),a=r(a,"legal_entity_id",s),a=r(a,"permission_scope",i,!(!n&&!s||!i)),new Promise((n,i)=>{!function(e,t,n,i,s){const r=new XMLHttpRequest;r.onreadystatechange=()=>{if(4===r.readyState)switch(r.status){case 0:s({code:o.BBAuthTokenErrorCode.Offline,message:"The user is offline."});break;case 200:i(r.responseText);break;case 401:s({code:o.BBAuthTokenErrorCode.NotLoggedIn,message:"The user is not logged in."});break;case 403:s({code:o.BBAuthTokenErrorCode.InvalidEnvironment,message:"The user is not a member of the specified environment."});break;default:r.status>=400&&s({code:o.BBAuthTokenErrorCode.Unspecified,message:"An unknown error occurred."})}},r.open("POST",e,!0),r.setRequestHeader(t.name,t.value),r.setRequestHeader("Accept","application/json"),r.setRequestHeader("Content-Type","application/json"),r.withCredentials=!0,n?r.send(JSON.stringify(n)):r.send()}(e,{name:"X-CSRF",value:t},a,e=>{const t=e?JSON.parse(e):void 0;n(t)},i)})}t.BBCsrfXhr=class{static request(e,t,n,r,c,d,u){return!c||r||d?new Promise((l,m)=>{new Promise((e,t)=>{u?e({csrf_token:"token_needed"}):a(i.BBAuthDomain.getSTSDomain()+"/session/csrf","token_needed").then(e).catch(t)}).then(t=>a(e,t.csrf_token,r,c,d)).then(l).catch(e=>{if(n||e.code===o.BBAuthTokenErrorCode.Offline)m(e);else switch(e.code){case o.BBAuthTokenErrorCode.NotLoggedIn:s.BBAuthNavigator.redirectToSignin(t);break;default:s.BBAuthNavigator.redirectToError(e.code)}})}):Promise.reject({code:o.BBAuthTokenErrorCode.PermissionScopeNoEnvironment,message:"You must also specify an environment or legal entity when specifying a permission scope."})}static requestWithToken(e,t){return new Promise((n,o)=>{const i=new XMLHttpRequest;i.onreadystatechange=()=>{if(4===i.readyState)switch(i.status){case 200:n(JSON.parse(i.responseText));break;default:o()}},i.open("GET",e,!0),i.setRequestHeader("Authorization","Bearer "+t),i.setRequestHeader("Accept","application/json"),i.send()})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(10),i=/1bb:\/\/([a-z]{3})-([a-z0-9]{5})(-[a-z]{4}[0-9]{2})?\/(.*)/;class s{static getUrl(e,t){const n=i.exec(e);let o=e,s=t?t.zone:void 0;return s&&(s=s.replace("-","")),n&&(n[3]&&(s=n[3].substring(1)),o=`https://${n[1]}-${s}.app.blackbaud.net/${n[2]}/${n[4]}`),Promise.resolve(o)}static getToken(e){return s.getTokenInternal(e)}static clearTokenCache(){s.tokenCache={}}static getTokenInternal(e){e=e||{};const{forceNewToken:t,disableRedirect:n}=e;if(s.mock)return Promise.resolve("mock_access_token_auth-client@blackbaud.com");const i=function(e){const{envId:t,permissionScope:n,leId:o}=e;return"token|"+(o||"-")+"|"+(t||"-")+"|"+(n||"-")}(e),r=s.tokenCache[i]=s.tokenCache[i]||{},a=(new Date).valueOf();return!t&&r.lastToken&&r.expirationTime&&r.expirationTime-a>6e4?Promise.resolve(r.lastToken):(r.pendingLookupPromise||(r.pendingLookupPromise=o.BBAuthTokenIntegration.getToken(n,e.envId,e.permissionScope,e.leId).then(e=>(r.expirationTime=(new Date).valueOf()+1e3*e.expires_in,r.lastToken=e.access_token,r.pendingLookupPromise=null,r.lastToken)).catch(e=>{throw r.pendingLookupPromise=null,e})),r.pendingLookupPromise)}}s.mock=!1,s.tokenCache={},t.BBAuth=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.Unspecified=0]="Unspecified",e[e.NotLoggedIn=1]="NotLoggedIn",e[e.InvalidEnvironment=2]="InvalidEnvironment",e[e.PermissionScopeNoEnvironment=3]="PermissionScopeNoEnvironment",e[e.Offline=4]="Offline"}(t.BBAuthTokenErrorCode||(t.BBAuthTokenErrorCode={}))},function(e,t,n){"use strict";function o(e){const t=e.split("."),n=[];for(const e of t){const t=parseInt(e,10)||0;n.push(t)}return n}Object.defineProperty(t,"__esModule",{value:!0});class i{static registerScript(e){return new Promise((t,n)=>{const o=document.createElement("script");o.onload=t,o.onerror=n,o.src=e,document.body.appendChild(o)})}static smartRegisterScript(e,t,n){return n&&function(e,t){const n=o(e),i=o(t);for(let e=0;e<n.length;e++)if(e<i.length){if(i[e]>n[e])return!0;if(i[e]<n[e])return!1}return!0}(t,n)?Promise.resolve():i.registerScript(e)}}t.BBOmnibarScriptLoader=i},function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(0)),o(n(12)),o(n(14))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(5),i=n(11),s=n(2);t.BBAuthTokenIntegration=class{static getToken(e,t,n,r){return void 0!==s.BBAuthDomain.getRegisteredDomain()||this.hostNameEndsWith("blackbaud.com")?o.BBCsrfXhr.request(s.BBAuthDomain.getSTSDomain()+"/oauth2/token",void 0,e,t,n,r,!0):i.BBAuthCrossDomainIframe.getToken({disableRedirect:e,envId:t,leId:r,permissionScope:n})}static hostNameEndsWith(e){return this.getLocationHostname().substr(-e.length)===e}static getLocationHostname(){return window.location.hostname}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(3),i=n(1),s=n(7),r="https://s21aidntoken00blkbapp01.nxt.blackbaud.com/Iframes/CrossDomainAuthFrame.html",a="security-token-svc",c="auth-client";class d{static reset(){this.requestCounter=0,this.tokenRequests={},this.iframeReadyPromise=new Promise(e=>this.iframeReadyResolve=e),this.listenerSetup=!1}static TARGET_ORIGIN(){return this.TARGETORIGIN}static getOrMakeIframe(){return d.iframeEl=document.getElementById("auth-cross-domain-iframe"),d.iframeEl||(d.iframeEl=o.BBAuthDomUtility.addIframe(r,"auth-cross-domain-iframe",""),d.iframeEl.id="auth-cross-domain-iframe",d.iframeEl.hidden=!0),d.iframeEl}static getToken(e){return this.setupListenersForIframe(),this.getTokenFromIframe(this.getOrMakeIframe(),e)}static setupListenersForIframe(){this.listenerSetup||(window.addEventListener("message",e=>{const t=e.data,n=t.requestId,o=this.tokenRequests[n];if(t.source===a||t.origin===this.TARGET_ORIGIN())switch(t.messageType){case"ready":this.iframeReadyResolve(!0);break;case"error":this.handleErrorMessage(t.value,o.reject,o.args.disableRedirect);break;case"getToken":const e={access_token:t.value,expires_in:0};o.resolve(e)}}),this.listenerSetup=!0)}static getTokenFromIframe(e,t){return new Promise((n,o)=>{const i=this.requestCounter++;d.tokenRequests[i]={args:t,reject:o,resolve:n},d.iframeReadyPromise.then(()=>{e.contentWindow.postMessage({messageType:"getToken",requestId:i,source:c,value:t},d.TARGET_ORIGIN())})})}static handleErrorMessage(e,t,n){if(n)t(e);else switch(e.code){case s.BBAuthTokenErrorCode.Offline:t(e);break;case s.BBAuthTokenErrorCode.NotLoggedIn:i.BBAuthNavigator.redirectToSignin(void 0);break;default:i.BBAuthNavigator.redirectToError(e.code)}}}d.listenerSetup=!1,d.iframeReadyPromise=new Promise(e=>d.iframeReadyResolve=e),d.tokenRequests={},d.requestCounter=0,d.TARGETORIGIN="https://s21aidntoken00blkbapp01.nxt.blackbaud.com",t.BBAuthCrossDomainIframe=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(n(13))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(0),i=n(4),s=n(5),r=n(3),a=n(1);function c(e,t,n,s){let a,c;function d(){r.BBAuthDomUtility.removeEl(c),r.BBAuthDomUtility.removeCss(a),c=a=void 0,window.removeEventListener("message",l)}function l(r){if(!i.BBAuthInterop.messageIsFromOmnibar(r))return;const a=r.data;switch(a.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),i.BBAuthInterop.postOmnibarMessage(c,{contextDestinations:t,messageType:"context-provide"});break;case"get-token":u=a.tokenRequestId,l=a.disableRedirect,o.BBAuth.getToken({disableRedirect:l}).then(e=>{i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:u})},e=>{i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:u})});break;case"welcome-cancel":d(),s({reason:"canceled"});break;case"welcome-environment-selected":d(),setTimeout(()=>{e.envId=a.envId,n(e)},10)}var u,l}a=r.BBAuthDomUtility.addCss("\n.sky-omnibar-welcome-iframe {\n background-color: #fff;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n"),function(){const t=u.url+"?hosted=1&svcid="+encodeURIComponent(e.svcId)+"&url="+encodeURIComponent(e.url);c=r.BBAuthDomUtility.addIframe(t,"sky-omnibar-welcome-iframe","Welcome")}(),window.addEventListener("message",l)}function d(){a.BBAuthNavigator.redirectToError(o.BBAuthTokenErrorCode.InvalidEnvironment)}class u{static ensureContext(e){const{envId:t,envIdRequired:n,leId:i,leIdRequired:r,svcId:a}=e;return!t&&n||!i&&r?new Promise((t,n)=>{a?o.BBAuth.getToken().then(o=>{let i="https://s21anavnavaf00blkbapp01.sky.blackbaud.com/user/destinations?svcid="+encodeURIComponent(a);e.url&&(i+="&referringurl="+encodeURIComponent(e.url)),s.BBCsrfXhr.requestWithToken(i,o).then(o=>{const i=o&&o.items,s=i&&i.length;1===s?(e.url=i[0].url,t(e)):s>1?c(e,o,t,n):d()})}):d()}):Promise.resolve(e)}}u.url="https://host.nxt.blackbaud.com/omnibar/welcome",t.BBContextProvider=u},function(e,t,n){"use strict";function o(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),o(n(15)),o(n(26)),o(n(27))},function(e,t,n){"use strict";var o=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(i,s){function r(e){try{c(o.next(e))}catch(e){s(e)}}function a(e){try{c(o.throw(e))}catch(e){s(e)}}function c(e){e.done?i(e.value):new n((function(t){t(e.value)})).then(r,a)}c((o=o.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const i=n(16),s=n(0),r=n(4),a=n(1),c=n(3),d=n(19),u=n(23),l=n(24),m=n(25),p="sky-omnibar-iframe-expanded",h="sky-omnibar-loading";let f,b,v,g,B,y,k,I,T,A,w;function O(){g=c.BBAuthDomUtility.addIframe(B.url||"https://host.nxt.blackbaud.com/omnibar/",`sky-omnibar-iframe ${h}`,"Navigation")}function E(){const e=document.location.href;r.BBAuthInterop.postOmnibarMessage(g,{href:e,messageType:"location-change"}),m.BBOmnibarToastContainer.updateUrl(e)}function _(){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"push-notifications-open"})}function N(){I||(I=!0,D.pushNotificationsEnabled().then(e=>{e?m.BBOmnibarToastContainer.init({envId:B.envId,leId:B.leId,navigateCallback:x,navigateUrlCallback:M,openMenuCallback:_,svcId:B.svcId,url:document.location.href}).then(()=>{l.BBOmnibarPushNotifications.connect(B.leId,B.envId,e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"push-notifications-update",pushNotifications:e}),m.BBOmnibarToastContainer.showNewNotifications(e),T=e&&e.notifications&&e.notifications.filter(e=>!e.isRead).length,L()})}):I=!1}))}function C(){function e(e){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"refresh-user",token:e}),e?N():I&&(m.BBOmnibarToastContainer.destroy(),l.BBOmnibarPushNotifications.disconnect(),I=!1)}s.BBAuth.clearTokenCache(),s.BBAuth.getToken({disableRedirect:!0,forceNewToken:!0}).then(e).catch(()=>e(void 0))}function R(){u.BBOmnibarUserActivityPrompt.show({sessionRenewCallback:()=>{d.BBOmnibarUserActivity.userRenewedSession()}})}function S(){u.BBOmnibarUserActivityPrompt.hide()}function P(){d.BBOmnibarUserActivity.startTracking(C,R,S,B.allowAnonymous,y)}function x(e){const t=B.nav;t&&t.beforeNavCallback&&!1===t.beforeNavCallback(e)||a.BBAuthNavigator.navigate(e.url)}function M(e){a.BBAuthNavigator.navigate(e)}function U(e){if(!r.BBAuthInterop.messageIsFromOmnibar(e))return;const t=e.data,n=B.nav;switch(t.messageType){case"ready":r.BBAuthInterop.postOmnibarMessage(g,{messageType:"host-ready"}),function(){const e=history.pushState,t=history.replaceState;history.pushState=function(){const t=e.apply(history,arguments);return E(),t},history.replaceState=function(){const e=t.apply(history,arguments);return E(),e}}(),r.BBAuthInterop.postOmnibarMessage(g,{compactNavOnly:B.compactNavOnly,enableHelp:B.enableHelp,envId:B.envId,hideResourceLinks:B.hideResourceLinks,leId:B.leId,localNavItems:n&&n.localNavItems,localNotifications:!!B.notifications,localSearch:!!B.onSearch,messageType:"nav-ready",navVersion:B.navVersion,services:n&&n.services,svcId:B.svcId,theme:B.theme}),function(){const e=B.notifications;e&&e.onReady({updateNotifications:e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"notifications-update",notifications:e})}})}(),N(),E(),k();break;case"display-ready":b.classList.remove(h),g.classList.remove(h);break;case"expand":g.classList.add(p);break;case"collapse":g.classList.remove(p);break;case"navigate-url":M(t.url);break;case"navigate":x(t.navItem);break;case"search":c=t.searchArgs,B.onSearch&&B.onSearch(c).then(e=>{r.BBAuthInterop.postOmnibarMessage(g,{messageType:"search-results",results:e})});break;case"get-token":i=t.tokenRequestId,a=t.disableRedirect,s.BBAuth.getToken({disableRedirect:a}).then(e=>{P(),r.BBAuthInterop.postOmnibarMessage(g,{messageType:"token",token:e,tokenRequestId:i})},e=>{P(),r.BBAuthInterop.postOmnibarMessage(g,{messageType:"token-fail",reason:e,tokenRequestId:i})});break;case"help-open":!function(){const e=window.BBHELP;e&&e.HelpWidget.open()}();break;case"notification-read":!function(e){const t=B.notifications;t&&t.onNotificationRead&&t.onNotificationRead(e)}(t.notification);break;case"push-notifications-change":o=t.notifications,l.BBOmnibarPushNotifications.updateNotifications(o);break;case"session-renew":d.BBOmnibarUserActivity.userRenewedSession();break;case"environment-update":!function(e){const t="sky-omnibar-environment-visible",n=document.body.classList;e=e||"",f.innerText=e,e?n.add(t):n.remove(t)}(t.name);break;case"legacy-keep-alive-url-change":y=t.url,P();break;case"selected-service-update":A=t.serviceName,L()}var o,i,a,c}function L(){if(w){const e=w.slice();A&&e.push(A);let t=e.join(" - ");T&&(t=`(${T}) ${t}`),document.title=t}}class D{static load(e){return B=B=e,y=B.legacyKeepAliveUrl,new Promise(e=>{k=e,function(){let e="background: linear-gradient(to right, #71bf44 0, #31b986 50%, #00b2ec 100%);",t="#4d5259";const n=B.theme;if(n){const o=n.accent;t=n.backgroundColor||t,!1===o?e="display: none;":o&&o.color&&(e=`background-color: ${o.color};`)}v=c.BBAuthDomUtility.addCss(`\nbody {\n margin-top: 50px;\n}\n\n#bb-help-container {\n padding-top: 1px;\n}\n\n.sky-omnibar-iframe,\n.sky-omnibar-placeholder {\n border: none;\n height: 50px;\n width: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n z-index: 1000;\n}\n\n.sky-omnibar-placeholder {\n background-color: ${t};\n display: none;\n}\n\n.sky-omnibar-placeholder-accent {\n height: 5px;\n ${e}\n}\n\n.sky-omnibar-placeholder.${h} {\n display: block;\n}\n\n.sky-omnibar-iframe.${h} {\n visibility: hidden;\n}\n\n.${p} {\n height: 100%;\n}\n\n.sky-omnibar-environment {\n background-color: #e1e1e3;\n color: #282b31;\n font-family: "Blackbaud Sans", "Open Sans", "Helvetica Neue", Arial, sans-serif;\n font-size: 12px;\n font-weight: 400;\n height: 0;\n line-height: 24px;\n overflow: hidden;\n padding: 0 15px;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.sky-omnibar-environment-visible .sky-omnibar-environment {\n height: 24px;\n}\n`)}(),(b=document.createElement("div")).className=`sky-omnibar-placeholder ${h}`,b.innerHTML='<div class="sky-omnibar-placeholder-accent"></div>',document.body.appendChild(b),(f=document.createElement("div")).className="sky-omnibar-environment",c.BBAuthDomUtility.addElToBodyTop(f),O(),window.addEventListener("message",U)})}static update(e){r.BBAuthInterop.postOmnibarMessage(g,{messageType:"update",updateArgs:e})}static setTitle(e){w=e&&e.titleParts,L()}static pushNotificationsEnabled(){return o(this,void 0,void 0,(function*(){return B?s.BBAuth.getToken({disableRedirect:!0,envId:B.envId,leId:B.leId,permissionScope:"Notifications"}).then(e=>{let t=i(e)["1bb.entitlements"];return!!t&&(t=Array.isArray(t)?t:[t]).indexOf("notif")>-1}).catch(()=>!1):Promise.resolve(!1)}))}static destroy(){m.BBOmnibarToastContainer.destroy(),l.BBOmnibarPushNotifications.disconnect(),c.BBAuthDomUtility.removeEl(b),c.BBAuthDomUtility.removeEl(g),c.BBAuthDomUtility.removeEl(f),c.BBAuthDomUtility.removeCss(v),window.removeEventListener("message",U),B=v=b=g=f=k=I=T=w=A=void 0}}t.BBOmnibar=D},function(e,t,n){"use strict";var o=n(17);function i(e){this.message=e}i.prototype=new Error,i.prototype.name="InvalidTokenError",e.exports=function(e,t){if("string"!=typeof e)throw new i("Invalid token specified");var n=!0===(t=t||{}).header?0:1;try{return JSON.parse(o(e.split(".")[n]))}catch(e){throw new i("Invalid token specified: "+e.message)}},e.exports.InvalidTokenError=i},function(e,t,n){var o=n(18);e.exports=function(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(o(e).replace(/(.)/g,(function(e,t){var n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(t)}catch(e){return o(t)}}},function(e,t){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function o(e){this.message=e}o.prototype=new Error,o.prototype.name="InvalidCharacterError",e.exports="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var t=String(e).replace(/=+$/,"");if(t.length%4==1)throw new o("'atob' failed: The string to be decoded is not correctly encoded.");for(var i,s,r=0,a=0,c="";s=t.charAt(a++);~s&&(i=r%4?64*i+s:s,r++%4)?c+=String.fromCharCode(255&i>>(-2*r&6)):0)s=n.indexOf(s);return c}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(2),i=n(5),s=n(20),r=n(21),a=n(22),c=n(1);let d,u,l,m,p,h,f,b,v,g,B,y,k,I,T="";function A(){b=Date.now()}function w(e){e.clientX===u&&e.clientY===l||(u=e.clientX,l=e.clientY,A())}function O(){const e=Date.now();(!v||e-v>C.MIN_RENEWAL_RETRY)&&(v=e,i.BBCsrfXhr.request(o.BBAuthDomain.getSTSDomain()+"/session/renew",{inactivity:1}).catch(()=>void 0))}function E(){f=!0,h()}function _(){f=!1,A(),m()}function N(){I?c.BBAuthNavigator.navigate(I):c.BBAuthNavigator.redirectToSignoutForInactivity()}class C{static startTracking(e,t,n,o,i){d&&o===B&&i===y||(C.stopTracking(),p=e,h=t,m=n,B=o,y=i,document.addEventListener("keypress",A),document.addEventListener("mousemove",w),B||O(),g=setInterval(()=>{r.BBOmnibarUserSessionExpiration.getSessionExpiration(T,k,B).then(e=>{d&&s.BBOmnibarUserActivityProcessor.process({allowAnonymous:B,closeInactivityPrompt:_,expirationDate:e,inactivityPromptDuration:C.INACTIVITY_PROMPT_DURATION,isShowingInactivityPrompt:f,lastActivity:b,maxSessionAge:C.MAX_SESSION_AGE,minRenewalAge:C.MIN_RENEWAL_AGE,redirectForInactivity:N,renewSession:O,showInactivityPrompt:E})})},C.ACTIVITY_TIMER_INTERVAL),a.BBOmnibarUserSessionWatcher.start(o,i,p,e=>{k=e.legacyTtl,T=e.refreshId,I=e.legacySigninUrl}),d=!0)}static userRenewedSession(){_(),O()}static stopTracking(){a.BBOmnibarUserSessionWatcher.stop(),r.BBOmnibarUserSessionExpiration.reset(),document.removeEventListener("keypress",A),document.removeEventListener("mousemove",w),g&&(clearInterval(g),g=void 0),d=u=l=b=v=f=p=h=m=B=y=void 0}}C.ACTIVITY_TIMER_INTERVAL=1e3,C.MIN_RENEWAL_RETRY=6e4,C.INACTIVITY_PROMPT_DURATION=12e4,C.MIN_RENEWAL_AGE=3e5,C.MAX_SESSION_AGE=54e5,t.BBOmnibarUserActivity=C},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.BBOmnibarUserActivityProcessor=class{static process(e){const{allowAnonymous:t,closeInactivityPrompt:n,expirationDate:o,inactivityPromptDuration:i,isShowingInactivityPrompt:s,lastActivity:r,maxSessionAge:a,minRenewalAge:c,redirectForInactivity:d,renewSession:u,showInactivityPrompt:l}=e,m=Date.now();if(null===o)return;!t&&m>o&&d();const p=o-i,h=o-a+c;s?m<p&&n():r>h?u():!t&&m>p&&l()}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(2),i=n(5);let s;t.BBOmnibarUserSessionExpiration=class{static getSessionExpiration(e,t,n){const r=function(e,t){if(s&&s.refreshId===e&&s.allowAnonymous===t)return s.promise;const n=new Promise((e,n)=>{i.BBCsrfXhr.request(o.BBAuthDomain.getSTSDomain()+"/session/ttl",void 0,t).then(t=>{const n=null===t?null:Date.now()+1e3*t;e(n)},()=>{e(null)})});return s={allowAnonymous:t,promise:n,refreshId:e},n}(e,n);return new Promise((e,n)=>{r.then(n=>{let o;if(null===n)o=null;else if("number"==typeof t){const e=Date.now()+t;o=Math.min(n,e)}else o=n;e(o)})})}static reset(){s=void 0}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(4),i=n(1),s=n(2);let r,a,c,d,u,l,m,p,h={};function f(e){if(e){const t=e.split("://");return`${t[0]}://${t[1].split("/")[0]}`}}function b(e,t){const n=document.createElement("iframe");return n.className=e,n.width="0",n.height="0",n.frameBorder="0",n.src=t,n.tabIndex=-1,n.setAttribute("aria-hidden","true"),document.body.appendChild(n),n}function v(e){if("string"==typeof e.data){let t;try{t=JSON.parse(e.data)}catch(e){return}if("session_change"===t.messageType){const e=t.message,n=e&&e.sessionId,s=e&&e.refreshId;n||u||(p?i.BBAuthNavigator.navigate(p):i.BBAuthNavigator.redirectToSignin()),void 0!==h.refreshId&&s!==h.refreshId&&function(e){m&&o.BBAuthInterop.postOmnibarMessage(m,e,f(a))}({messageType:"session-refresh"}),void 0!==h.sessionId&&n!==h.sessionId&&c(),h.refreshId=s,h.sessionId=n,d(h)}}}function g(e){switch(e.origin){case B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN:v(e);break;case f(a):!function(e){const t=e.data;switch(t.messageType){case"ready":h.legacyTtl=t.ttl,p=t.signinUrl,d(h)}}(e)}}class B{static start(e,t,n,o){r&&e===u&&t===a||(B.stop(),u=e,c=n,a=t,d=o,function(){const e=B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN+"/SessionWatcher.html?origin="+encodeURIComponent(location.origin);l=b("sky-omnibar-iframe-session-watcher",e)}(),a&&(m=b("sky-omnibar-iframe-legacy-keep-alive",a)),window.addEventListener("message",g,!1),r=!0)}static stop(){window.removeEventListener("message",g,!1),l&&(document.body.removeChild(l),l=void 0),m&&(document.body.removeChild(m),m=void 0),h={},r=u=c=a=p=d=void 0}}B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN=s.BBAuthDomain.getSTSDomain(),t.BBOmnibarUserSessionWatcher=B},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(3),i=n(4);let s,r,a;function c(e){if(!i.BBAuthInterop.messageIsFromOmnibar(e))return;switch(e.data.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(r,{messageType:"host-ready"}),r.classList.add("sky-omnibar-inactivity-iframe-ready");break;case"session-renew":a()}}class d{static show(e){this.hide(),a=e.sessionRenewCallback,s=o.BBAuthDomUtility.addCss("\n .sky-omnibar-inactivity-iframe {\n background-color: transparent;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 100000;\n visibility: hidden;\n }\n\n .sky-omnibar-inactivity-iframe-ready {\n visibility: visible;\n }\n "),function(){const e=d.url;r=o.BBAuthDomUtility.addIframe(e,"sky-omnibar-inactivity-iframe","Inactivity Prompt")}(),window.addEventListener("message",c)}static hide(){r&&(o.BBAuthDomUtility.removeEl(r),o.BBAuthDomUtility.removeCss(s),r=s=a=void 0,window.removeEventListener("message",c))}}d.url="https://host.nxt.blackbaud.com/omnibar/inactivity",t.BBOmnibarUserActivityPrompt=d},function(e,t,n){"use strict";var o=this&&this.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(i,s){function r(e){try{c(o.next(e))}catch(e){s(e)}}function a(e){try{c(o.throw(e))}catch(e){s(e)}}function c(e){e.done?i(e.value):new n((function(t){t(e.value)})).then(r,a)}c((o=o.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const i=n(0),s=n(8);let r;class a{static connect(e,t,n){return o(this,void 0,void 0,(function*(){return r||(r=window.BBNotificationsClient?Promise.resolve():s.BBOmnibarScriptLoader.registerScript(this.NOTIFICATIONS_CLIENT_URL)),r.then(()=>{BBNotificationsClient.BBNotifications.init({tokenCallback:()=>i.BBAuth.getToken({disableRedirect:!0,envId:t,leId:e})}),BBNotificationsClient.BBNotifications.addListener(n)})}))}static disconnect(){return o(this,void 0,void 0,(function*(){return r?r.then(()=>{BBNotificationsClient.BBNotifications.destroy(),r=void 0}):Promise.resolve()}))}static updateNotifications(e){BBNotificationsClient.BBNotifications.updateNotifications(e)}}a.NOTIFICATIONS_CLIENT_URL="https://sky.blackbaudcdn.net/static/notifications-client/1/notifications-client.global.min.js",t.BBOmnibarPushNotifications=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(6),i=n(3),s=n(4),r="sky-omnibar-toast-container",a=`${r}-ready`,c=`${r}-empty`,d=20;let u,l,m,p,h,f;function b(e){const t=document.querySelector(e);return t?t.getBoundingClientRect().height:0}function v(){l&&s.BBAuthInterop.postOmnibarMessage(l,{href:f,messageType:"location-change"})}function g(e){if(!s.BBAuthInterop.messageIsFromToastContainer(e))return;const t=e.data;switch(t.messageType){case"toast-ready":s.BBAuthInterop.postOmnibarMessage(l,{messageType:"host-ready"}),s.BBAuthInterop.postOmnibarMessage(l,{envId:h.envId,leId:h.leId,messageType:"nav-ready",svcId:h.svcId}),v(),l.classList.add(a),p();break;case"get-token":n=t.tokenRequestId,i=t.disableRedirect,o.BBAuth.getToken({disableRedirect:i}).then(e=>{s.BBAuthInterop.postOmnibarMessage(l,{messageType:"token",token:e,tokenRequestId:n})},e=>{s.BBAuthInterop.postOmnibarMessage(l,{messageType:"token-fail",reason:e,tokenRequestId:n})});break;case"navigate-url":h.navigateUrlCallback(t.url);break;case"navigate":h.navigateCallback(t.navItem);break;case"toast-container-change":t.height>0?(l.style.height=t.height+"px",l.style.top=b(".sky-omnibar-iframe")+b(".sky-omnibar-environment")+d+"px",l.classList.remove(c)):l.classList.add(c);break;case"push-notifications-open":h.openMenuCallback()}var n,i}class B{static init(e){return h=e,f=e.url,m||(m=new Promise(e=>{p=e,l||(u=i.BBAuthDomUtility.addCss(`\n.${r} {\n border: none;\n display: none;\n position: fixed;\n right: 0px;\n height: 0px;\n width: 300px;\n /* z-index is 1 less than omnibar so menus will display over top the toast container */\n z-index: 999;\n}\n\n.${a} {\n display: block;\n}\n\n.${c} {\n visibility: hidden;\n}\n`),(l=document.createElement("iframe")).src=B.CONTAINER_URL,l.className=`${r} ${c}`,l.title="Toast container",document.body.appendChild(l),window.addEventListener("message",g))})),m}static showNewNotifications(e){s.BBAuthInterop.postOmnibarMessage(l,{messageType:"push-notifications-update",pushNotifications:e})}static updateUrl(e){f=e,v()}static destroy(){u&&i.BBAuthDomUtility.removeCss(u),l&&i.BBAuthDomUtility.removeEl(l),f=l=h=m=p=u=void 0,window.removeEventListener("message",g)}}B.CONTAINER_URL="https://host.nxt.blackbaud.com/omnibar/toast",t.BBOmnibarToastContainer=B},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const o=n(8);function i(){return window.jQuery}t.BBOmnibarLegacy=class{static load(e){return new Promise(t=>{const n=i(),s=n&&n.fn&&n.fn.jquery;o.BBOmnibarScriptLoader.smartRegisterScript("https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.js","2.1.0",s).then(()=>o.BBOmnibarScriptLoader.registerScript("https://cdnjs.cloudflare.com/ajax/libs/easyXDM/2.4.17.1/easyXDM.min.js")).then(()=>o.BBOmnibarScriptLoader.registerScript("https://signin.blackbaud.com/Omnibar.min.js")).then(()=>{document.body.classList.add("bb-omnibar-height-padding");const n=document.createElement("div");n.setAttribute("data-omnibar-el",""),document.body.appendChild(n),(e=e||{})["z-index"]=1e3,e.afterLoad=t,e.menuEl&&(e.menuEl=i()(e.menuEl)),BBAUTH.Omnibar.load(n,e)})})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0})}])})); |
@@ -1,1 +0,1 @@ | ||
!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.BBAuthClient=n():e.BBAuthClient=n()}(window,(function(){return function(e){var n={};function t(o){if(n[o])return n[o].exports;var i=n[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,t),i.l=!0,i.exports}return t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:o})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(t.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var i in e)t.d(o,i,function(n){return e[n]}.bind(null,i));return o},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="",t(t.s=9)}([function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(6)),o(t(7))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i="https://signin.blackbaud.com/signin/",r=encodeURIComponent;function a(e){var n=i+"?redirectUrl="+r(location.href);return e&&(n+="&inactivity=1"),n}var s=function(){function e(){}return e.navigate=function(e,n){n?location.replace(e):location.href=e},e.redirectToSignin=function(e){var n=a();e&&(n+="&"+function(e){var n=[];for(var t in e)e.hasOwnProperty(t)&&n.push(r(t)+"="+r(e[t]));return n.join("&")}(e)),this.navigate(n)},e.redirectToSignoutForInactivity=function(){var e=a(!0),n=i+"sign-out?redirectUrl="+r(e);this.navigate(n)},e.redirectToError=function(e){var n,t;switch(e){case o.BBAuthTokenErrorCode.InvalidEnvironment:t="invalid_env",n="security";break;default:n="broken"}var i="https://host.nxt.blackbaud.com/errors/"+n+"?source=auth-client&url="+r(location.href);t&&(i+="&code="+r(t)),this.navigate(i)},e}();n.BBAuthNavigator=s},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o={"bbk12.com":"https://sts-sso.bbk12.com","blackbaudfaith.com":"https://sts.blackbaudfaith.com","donorcentral.com":"https://sts-dc.donorcentral.com","mycampus-app.com":"https://sts-sso.mycampus-app.com","myschoolapp.com":"https://sts-sso.myschoolapp.com","myschoolautomation.com":"https://sts-sso.myschoolautomation.com","myschooldemo.com":"https://sts-sso.myschooldemo.com","myschooltraining.com":"https://sts-sso.myschooltraining.com"},i=function(){function e(){}return e.getRegisteredDomain=function(){for(var e=0,n=Object.keys(o);e<n.length;e++){var t=n[e],i="."+t;if(this.CURRENT_DOMAIN===t||this.CURRENT_DOMAIN.substr(-i.length)===i)return t}},e.getSTSDomain=function(){var e=this.getRegisteredDomain();return o[e]||"https://s21aidntoken00blkbapp01.nxt.blackbaud.com"},e.CURRENT_DOMAIN=window.location.hostname,e}();n.BBAuthDomain=i},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){}return e.addCss=function(e){var n=document.createElement("style");return n.appendChild(document.createTextNode(e)),document.head.appendChild(n),n},e.addIframe=function(e,n,t){var o=document.createElement("iframe");return o.className=n,o.title=t,o.src=e,this.addElToBodyTop(o),o},e.removeCss=function(e){this.removeEl(e,document.head)},e.removeEl=function(e,n){void 0===n&&(n=document.body),n.contains(e)&&n.removeChild(e)},e.addElToBodyTop=function(e){var n=document.body;n.firstChild?n.insertBefore(e,n.firstChild):n.appendChild(e)},e}();n.BBAuthDomUtility=o},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o="https://host.nxt.blackbaud.com";function i(e,n){if(e.origin===o){var t=e.data;return!!t&&t.source===n}return!1}var r=function(){function e(){}return e.postOmnibarMessage=function(e,n,t){n.source="auth-client",e.contentWindow.postMessage(n,t||o)},e.messageIsFromOmnibar=function(e){return i(e,"skyux-spa-omnibar")},e.messageIsFromToastContainer=function(e){return i(e,"skyux-spa-omnibar-toast-container")},e}();n.BBAuthInterop=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i=t(2),r=t(1);function a(e,n,t,o){return(o||void 0===o&&t)&&((e=e||{})[n]=t),e}function s(e,n,t,i,r){var s;return s=a(s,"environment_id",t),s=a(s,"legal_entity_id",r),s=a(s,"permission_scope",i,!(!t&&!r||!i)),new Promise((function(t,i){!function(e,n,t,i,r){var a=new XMLHttpRequest;a.onreadystatechange=function(){if(4===a.readyState)switch(a.status){case 0:r({code:o.BBAuthTokenErrorCode.Offline,message:"The user is offline."});break;case 200:i(a.responseText);break;case 401:r({code:o.BBAuthTokenErrorCode.NotLoggedIn,message:"The user is not logged in."});break;case 403:r({code:o.BBAuthTokenErrorCode.InvalidEnvironment,message:"The user is not a member of the specified environment."});break;default:a.status>=400&&r({code:o.BBAuthTokenErrorCode.Unspecified,message:"An unknown error occurred."})}},a.open("POST",e,!0),a.setRequestHeader(n.name,n.value),a.setRequestHeader("Accept","application/json"),a.setRequestHeader("Content-Type","application/json"),a.withCredentials=!0,t?a.send(JSON.stringify(t)):a.send()}(e,{name:"X-CSRF",value:n},s,(function(e){var n=e?JSON.parse(e):void 0;t(n)}),i)}))}var c=function(){function e(){}return e.request=function(e,n,t,a,c,u,d){return!c||a||u?new Promise((function(l,f){new Promise((function(e,n){d?e({csrf_token:"token_needed"}):s(i.BBAuthDomain.getSTSDomain()+"/session/csrf","token_needed").then(e).catch(n)})).then((function(n){return s(e,n.csrf_token,a,c,u)})).then(l).catch((function(e){if(t||e.code===o.BBAuthTokenErrorCode.Offline)f(e);else switch(e.code){case o.BBAuthTokenErrorCode.NotLoggedIn:r.BBAuthNavigator.redirectToSignin(n);break;default:r.BBAuthNavigator.redirectToError(e.code)}}))})):Promise.reject({code:o.BBAuthTokenErrorCode.PermissionScopeNoEnvironment,message:"You must also specify an environment or legal entity when specifying a permission scope."})},e.requestWithToken=function(e,n){return new Promise((function(t,o){var i=new XMLHttpRequest;i.onreadystatechange=function(){if(4===i.readyState)switch(i.status){case 200:t(JSON.parse(i.responseText));break;default:o()}},i.open("GET",e,!0),i.setRequestHeader("Authorization","Bearer "+n),i.setRequestHeader("Accept","application/json"),i.send()}))},e}();n.BBCsrfXhr=c},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(10),i=/1bb:\/\/([a-z]{3})-([a-z0-9]{5})(-[a-z]{4}[0-9]{2})?\/(.*)/;var r=function(){function e(){}return e.getUrl=function(e,n){var t=i.exec(e),o=e,r=n?n.zone:void 0;return r&&(r=r.replace("-","")),t&&(t[3]&&(r=t[3].substring(1)),o="https://"+t[1]+"-"+r+".app.blackbaud.net/"+t[2]+"/"+t[4]),Promise.resolve(o)},e.getToken=function(n){return e.getTokenInternal(n)},e.clearTokenCache=function(){e.tokenCache={}},e.getTokenInternal=function(n){var t=(n=n||{}).forceNewToken,i=n.disableRedirect;if(e.mock)return Promise.resolve("mock_access_token_auth-client@blackbaud.com");var r=function(e){var n=e.envId,t=e.permissionScope;return"token|"+(e.leId||"-")+"|"+(n||"-")+"|"+(t||"-")}(n),a=e.tokenCache[r]=e.tokenCache[r]||{},s=(new Date).valueOf();return!t&&a.lastToken&&a.expirationTime&&a.expirationTime-s>6e4?Promise.resolve(a.lastToken):(a.pendingLookupPromise||(a.pendingLookupPromise=o.BBAuthTokenIntegration.getToken(i,n.envId,n.permissionScope,n.leId).then((function(e){return a.expirationTime=(new Date).valueOf()+1e3*e.expires_in,a.lastToken=e.access_token,a.pendingLookupPromise=null,a.lastToken})).catch((function(e){throw a.pendingLookupPromise=null,e}))),a.pendingLookupPromise)},e.mock=!1,e.tokenCache={},e}();n.BBAuth=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),function(e){e[e.Unspecified=0]="Unspecified",e[e.NotLoggedIn=1]="NotLoggedIn",e[e.InvalidEnvironment=2]="InvalidEnvironment",e[e.PermissionScopeNoEnvironment=3]="PermissionScopeNoEnvironment",e[e.Offline=4]="Offline"}(n.BBAuthTokenErrorCode||(n.BBAuthTokenErrorCode={}))},function(e,n,t){"use strict";function o(e){for(var n=[],t=0,o=e.split(".");t<o.length;t++){var i=o[t],r=parseInt(i,10)||0;n.push(r)}return n}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(){}return e.registerScript=function(e){return new Promise((function(n,t){var o=document.createElement("script");o.onload=n,o.onerror=t,o.src=e,document.body.appendChild(o)}))},e.smartRegisterScript=function(n,t,i){return i&&function(e,n){for(var t=o(e),i=o(n),r=0;r<t.length;r++)if(r<i.length){if(i[r]>t[r])return!0;if(i[r]<t[r])return!1}return!0}(t,i)?Promise.resolve():e.registerScript(n)},e}();n.BBOmnibarScriptLoader=i},function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(0)),o(t(12)),o(t(14))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(5),i=t(11),r=t(2),a=function(){function e(){}return e.getToken=function(e,n,t,a){return void 0!==r.BBAuthDomain.getRegisteredDomain()||this.hostNameEndsWith("blackbaud.com")?o.BBCsrfXhr.request(r.BBAuthDomain.getSTSDomain()+"/oauth2/token",void 0,e,n,t,a,!0):i.BBAuthCrossDomainIframe.getToken({disableRedirect:e,envId:n,leId:a,permissionScope:t})},e.hostNameEndsWith=function(e){return this.getLocationHostname().substr(-e.length)===e},e.getLocationHostname=function(){return window.location.hostname},e}();n.BBAuthTokenIntegration=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(3),i=t(1),r=t(7),a=function(){function e(){}return e.reset=function(){var e=this;this.requestCounter=0,this.tokenRequests={},this.iframeReadyPromise=new Promise((function(n){return e.iframeReadyResolve=n})),this.listenerSetup=!1},e.TARGET_ORIGIN=function(){return this.TARGETORIGIN},e.getOrMakeIframe=function(){return e.iframeEl=document.getElementById("auth-cross-domain-iframe"),e.iframeEl||(e.iframeEl=o.BBAuthDomUtility.addIframe("https://s21aidntoken00blkbapp01.nxt.blackbaud.com/Iframes/CrossDomainAuthFrame.html","auth-cross-domain-iframe",""),e.iframeEl.id="auth-cross-domain-iframe",e.iframeEl.hidden=!0),e.iframeEl},e.getToken=function(e){return this.setupListenersForIframe(),this.getTokenFromIframe(this.getOrMakeIframe(),e)},e.setupListenersForIframe=function(){var e=this;this.listenerSetup||(window.addEventListener("message",(function(n){var t=n.data,o=t.requestId,i=e.tokenRequests[o];if("security-token-svc"===t.source||t.origin===e.TARGET_ORIGIN())switch(t.messageType){case"ready":e.iframeReadyResolve(!0);break;case"error":e.handleErrorMessage(t.value,i.reject,i.args.disableRedirect);break;case"getToken":var r={access_token:t.value,expires_in:0};i.resolve(r)}})),this.listenerSetup=!0)},e.getTokenFromIframe=function(n,t){var o=this;return new Promise((function(i,r){var a=o.requestCounter++;e.tokenRequests[a]={args:t,reject:r,resolve:i},e.iframeReadyPromise.then((function(){n.contentWindow.postMessage({messageType:"getToken",requestId:a,source:"auth-client",value:t},e.TARGET_ORIGIN())}))}))},e.handleErrorMessage=function(e,n,t){if(t)n(e);else switch(e.code){case r.BBAuthTokenErrorCode.Offline:n(e);break;case r.BBAuthTokenErrorCode.NotLoggedIn:i.BBAuthNavigator.redirectToSignin(void 0);break;default:i.BBAuthNavigator.redirectToError(e.code)}},e.listenerSetup=!1,e.iframeReadyPromise=new Promise((function(n){return e.iframeReadyResolve=n})),e.tokenRequests={},e.requestCounter=0,e.TARGETORIGIN="https://s21aidntoken00blkbapp01.nxt.blackbaud.com",e}();n.BBAuthCrossDomainIframe=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),function(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}(t(13))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i=t(4),r=t(5),a=t(3),s=t(1);function c(e,n,t,r){var s,c,u;function l(){a.BBAuthDomUtility.removeEl(c),a.BBAuthDomUtility.removeCss(s),c=s=void 0,window.removeEventListener("message",f)}function f(a){if(i.BBAuthInterop.messageIsFromOmnibar(a)){var s,u,d=a.data;switch(d.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),i.BBAuthInterop.postOmnibarMessage(c,{contextDestinations:n,messageType:"context-provide"});break;case"get-token":s=d.tokenRequestId,u=d.disableRedirect,o.BBAuth.getToken({disableRedirect:u}).then((function(e){i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:s})}),(function(e){i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:s})}));break;case"welcome-cancel":l(),r({reason:"canceled"});break;case"welcome-environment-selected":l(),setTimeout((function(){e.envId=d.envId,t(e)}),10)}}}s=a.BBAuthDomUtility.addCss("\n.sky-omnibar-welcome-iframe {\n background-color: #fff;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n"),u=d.url+"?hosted=1&svcid="+encodeURIComponent(e.svcId)+"&url="+encodeURIComponent(e.url),c=a.BBAuthDomUtility.addIframe(u,"sky-omnibar-welcome-iframe","Welcome"),window.addEventListener("message",f)}function u(){s.BBAuthNavigator.redirectToError(o.BBAuthTokenErrorCode.InvalidEnvironment)}var d=function(){function e(){}return e.ensureContext=function(e){var n=e.envId,t=e.envIdRequired,i=e.leId,a=e.leIdRequired,s=e.svcId;return!n&&t||!i&&a?new Promise((function(n,t){s?o.BBAuth.getToken().then((function(o){var i="https://s21anavnavaf00blkbapp01.sky.blackbaud.com/user/destinations?svcid="+encodeURIComponent(s);e.url&&(i+="&referringurl="+encodeURIComponent(e.url)),r.BBCsrfXhr.requestWithToken(i,o).then((function(o){var i=o&&o.items,r=i&&i.length;1===r?(e.url=i[0].url,n(e)):r>1?c(e,o,n,t):u()}))})):u()})):Promise.resolve(e)},e.url="https://host.nxt.blackbaud.com/omnibar/welcome",e}();n.BBContextProvider=d},function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(15)),o(t(26)),o(t(27))},function(e,n,t){"use strict";var o=this&&this.__awaiter||function(e,n,t,o){return new(t||(t=Promise))((function(i,r){function a(e){try{c(o.next(e))}catch(e){r(e)}}function s(e){try{c(o.throw(e))}catch(e){r(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((o=o.apply(e,n||[])).next())}))},i=this&&this.__generator||function(e,n){var t,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===r[0]||2===r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=n.call(e,a)}catch(e){r=[6,e],o=0}finally{t=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}};Object.defineProperty(n,"__esModule",{value:!0});var r,a,s,c,u,d,l,f,m,p,h,v=t(16),b=t(0),y=t(4),g=t(1),B=t(3),k=t(19),I=t(23),T=t(24),w=t(25),A="sky-omnibar-iframe-expanded",O="sky-omnibar-loading";function E(){c=B.BBAuthDomUtility.addIframe(u.url||"https://host.nxt.blackbaud.com/omnibar/","sky-omnibar-iframe "+O,"Navigation")}function _(){var e=document.location.href;y.BBAuthInterop.postOmnibarMessage(c,{href:e,messageType:"location-change"}),w.BBOmnibarToastContainer.updateUrl(e)}function N(){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"push-notifications-open"})}function C(){f||(f=!0,j.pushNotificationsEnabled().then((function(e){e?w.BBOmnibarToastContainer.init({envId:u.envId,leId:u.leId,navigateCallback:M,navigateUrlCallback:U,openMenuCallback:N,svcId:u.svcId,url:document.location.href}).then((function(){T.BBOmnibarPushNotifications.connect(u.leId,u.envId,(function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"push-notifications-update",pushNotifications:e}),w.BBOmnibarToastContainer.showNewNotifications(e),m=e&&e.notifications&&e.notifications.filter((function(e){return!e.isRead})).length,D()}))})):f=!1})))}function R(){function e(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"refresh-user",token:e}),e?C():f&&(w.BBOmnibarToastContainer.destroy(),T.BBOmnibarPushNotifications.disconnect(),f=!1)}b.BBAuth.clearTokenCache(),b.BBAuth.getToken({disableRedirect:!0,forceNewToken:!0}).then(e).catch((function(){return e(void 0)}))}function S(){I.BBOmnibarUserActivityPrompt.show({sessionRenewCallback:function(){k.BBOmnibarUserActivity.userRenewedSession()}})}function P(){I.BBOmnibarUserActivityPrompt.hide()}function x(){k.BBOmnibarUserActivity.startTracking(R,S,P,u.allowAnonymous,d)}function M(e){var n=u.nav;n&&n.beforeNavCallback&&!1===n.beforeNavCallback(e)||g.BBAuthNavigator.navigate(e.url)}function U(e){g.BBAuthNavigator.navigate(e)}function L(e){if(y.BBAuthInterop.messageIsFromOmnibar(e)){var n,t,o,i,s,f,m,h,v,g,B,I=e.data,w=u.nav;switch(I.messageType){case"ready":y.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),g=history.pushState,B=history.replaceState,history.pushState=function(){var e=g.apply(history,arguments);return _(),e},history.replaceState=function(){var e=B.apply(history,arguments);return _(),e},y.BBAuthInterop.postOmnibarMessage(c,{compactNavOnly:u.compactNavOnly,enableHelp:u.enableHelp,envId:u.envId,hideResourceLinks:u.hideResourceLinks,leId:u.leId,localNavItems:w&&w.localNavItems,localNotifications:!!u.notifications,localSearch:!!u.onSearch,messageType:"nav-ready",navVersion:u.navVersion,services:w&&w.services,svcId:u.svcId,theme:u.theme}),(v=u.notifications)&&v.onReady({updateNotifications:function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"notifications-update",notifications:e})}}),C(),_(),l();break;case"display-ready":a.classList.remove(O),c.classList.remove(O);break;case"expand":c.classList.add(A);break;case"collapse":c.classList.remove(A);break;case"navigate-url":U(I.url);break;case"navigate":M(I.navItem);break;case"search":h=I.searchArgs,u.onSearch&&u.onSearch(h).then((function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"search-results",results:e})}));break;case"get-token":f=I.tokenRequestId,m=I.disableRedirect,b.BBAuth.getToken({disableRedirect:m}).then((function(e){x(),y.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:f})}),(function(e){x(),y.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:f})}));break;case"help-open":(s=window.BBHELP)&&s.HelpWidget.open();break;case"notification-read":!function(e){var n=u.notifications;n&&n.onNotificationRead&&n.onNotificationRead(e)}(I.notification);break;case"push-notifications-change":i=I.notifications,T.BBOmnibarPushNotifications.updateNotifications(i);break;case"session-renew":k.BBOmnibarUserActivity.userRenewedSession();break;case"environment-update":n=I.name,t="sky-omnibar-environment-visible",o=document.body.classList,n=n||"",r.innerText=n,n?o.add(t):o.remove(t);break;case"legacy-keep-alive-url-change":d=I.url,x();break;case"selected-service-update":p=I.serviceName,D()}}}function D(){if(h){var e=h.slice();p&&e.push(p);var n=e.join(" - ");m&&(n="("+m+") "+n),document.title=n}}var j=function(){function e(){}return e.load=function(e){return u=u=e,d=u.legacyKeepAliveUrl,new Promise((function(e){l=e,function(){var e="background: linear-gradient(to right, #71bf44 0, #31b986 50%, #00b2ec 100%);",n="#4d5259",t=u.theme;if(t){var o=t.accent;n=t.backgroundColor||n,!1===o?e="display: none;":o&&o.color&&(e="background-color: "+o.color+";")}s=B.BBAuthDomUtility.addCss("\nbody {\n margin-top: 50px;\n}\n\n#bb-help-container {\n padding-top: 1px;\n}\n\n.sky-omnibar-iframe,\n.sky-omnibar-placeholder {\n border: none;\n height: 50px;\n width: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n z-index: 1000;\n}\n\n.sky-omnibar-placeholder {\n background-color: "+n+";\n display: none;\n}\n\n.sky-omnibar-placeholder-accent {\n height: 5px;\n "+e+"\n}\n\n.sky-omnibar-placeholder."+O+" {\n display: block;\n}\n\n.sky-omnibar-iframe."+O+" {\n visibility: hidden;\n}\n\n."+A+' {\n height: 100%;\n}\n\n.sky-omnibar-environment {\n background-color: #e1e1e3;\n color: #282b31;\n font-family: "Blackbaud Sans", "Open Sans", "Helvetica Neue", Arial, sans-serif;\n font-size: 12px;\n font-weight: 400;\n height: 0;\n line-height: 24px;\n overflow: hidden;\n padding: 0 15px;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.sky-omnibar-environment-visible .sky-omnibar-environment {\n height: 24px;\n}\n')}(),(a=document.createElement("div")).className="sky-omnibar-placeholder "+O,a.innerHTML='<div class="sky-omnibar-placeholder-accent"></div>',document.body.appendChild(a),(r=document.createElement("div")).className="sky-omnibar-environment",B.BBAuthDomUtility.addElToBodyTop(r),E(),window.addEventListener("message",L)}))},e.update=function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"update",updateArgs:e})},e.setTitle=function(e){h=e&&e.titleParts,D()},e.pushNotificationsEnabled=function(){return o(this,void 0,void 0,(function(){return i(this,(function(e){return u?[2,b.BBAuth.getToken({disableRedirect:!0,envId:u.envId,leId:u.leId,permissionScope:"Notifications"}).then((function(e){var n=v(e)["1bb.entitlements"];return!!n&&(n=Array.isArray(n)?n:[n]).indexOf("notif")>-1})).catch((function(){return!1}))]:[2,Promise.resolve(!1)]}))}))},e.destroy=function(){w.BBOmnibarToastContainer.destroy(),T.BBOmnibarPushNotifications.disconnect(),B.BBAuthDomUtility.removeEl(a),B.BBAuthDomUtility.removeEl(c),B.BBAuthDomUtility.removeEl(r),B.BBAuthDomUtility.removeCss(s),window.removeEventListener("message",L),u=s=a=c=r=l=f=m=h=p=void 0},e}();n.BBOmnibar=j},function(e,n,t){"use strict";var o=t(17);function i(e){this.message=e}i.prototype=new Error,i.prototype.name="InvalidTokenError",e.exports=function(e,n){if("string"!=typeof e)throw new i("Invalid token specified");var t=!0===(n=n||{}).header?0:1;try{return JSON.parse(o(e.split(".")[t]))}catch(e){throw new i("Invalid token specified: "+e.message)}},e.exports.InvalidTokenError=i},function(e,n,t){var o=t(18);e.exports=function(e){var n=e.replace(/-/g,"+").replace(/_/g,"/");switch(n.length%4){case 0:break;case 2:n+="==";break;case 3:n+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(o(e).replace(/(.)/g,(function(e,n){var t=n.charCodeAt(0).toString(16).toUpperCase();return t.length<2&&(t="0"+t),"%"+t})))}(n)}catch(e){return o(n)}}},function(e,n){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function o(e){this.message=e}o.prototype=new Error,o.prototype.name="InvalidCharacterError",e.exports="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var n=String(e).replace(/=+$/,"");if(n.length%4==1)throw new o("'atob' failed: The string to be decoded is not correctly encoded.");for(var i,r,a=0,s=0,c="";r=n.charAt(s++);~r&&(i=a%4?64*i+r:r,a++%4)?c+=String.fromCharCode(255&i>>(-2*a&6)):0)r=t.indexOf(r);return c}},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u,d,l,f,m,p,h,v,b=t(2),y=t(5),g=t(20),B=t(21),k=t(22),I=t(1),T="";function w(){d=Date.now()}function A(e){e.clientX===i&&e.clientY===r||(i=e.clientX,r=e.clientY,w())}function O(){var e=Date.now();(!l||e-l>R.MIN_RENEWAL_RETRY)&&(l=e,y.BBCsrfXhr.request(b.BBAuthDomain.getSTSDomain()+"/session/renew",{inactivity:1}).catch((function(){})))}function E(){u=!0,c()}function _(){u=!1,w(),a()}function N(){v?I.BBAuthNavigator.navigate(v):I.BBAuthNavigator.redirectToSignoutForInactivity()}function C(){m||O(),f=setInterval((function(){B.BBOmnibarUserSessionExpiration.getSessionExpiration(T,h,m).then((function(e){o&&g.BBOmnibarUserActivityProcessor.process({allowAnonymous:m,closeInactivityPrompt:_,expirationDate:e,inactivityPromptDuration:R.INACTIVITY_PROMPT_DURATION,isShowingInactivityPrompt:u,lastActivity:d,maxSessionAge:R.MAX_SESSION_AGE,minRenewalAge:R.MIN_RENEWAL_AGE,redirectForInactivity:N,renewSession:O,showInactivityPrompt:E})}))}),R.ACTIVITY_TIMER_INTERVAL)}var R=function(){function e(){}return e.startTracking=function(n,t,i,r,u){o&&r===m&&u===p||(e.stopTracking(),s=n,c=t,a=i,m=r,p=u,document.addEventListener("keypress",w),document.addEventListener("mousemove",A),C(),k.BBOmnibarUserSessionWatcher.start(r,u,s,(function(e){h=e.legacyTtl,T=e.refreshId,v=e.legacySigninUrl})),o=!0)},e.userRenewedSession=function(){_(),O()},e.stopTracking=function(){k.BBOmnibarUserSessionWatcher.stop(),B.BBOmnibarUserSessionExpiration.reset(),document.removeEventListener("keypress",w),document.removeEventListener("mousemove",A),f&&(clearInterval(f),f=void 0),o=i=r=d=l=u=s=c=a=m=p=void 0},e.ACTIVITY_TIMER_INTERVAL=1e3,e.MIN_RENEWAL_RETRY=6e4,e.INACTIVITY_PROMPT_DURATION=12e4,e.MIN_RENEWAL_AGE=3e5,e.MAX_SESSION_AGE=54e5,e}();n.BBOmnibarUserActivity=R},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){}return e.process=function(e){var n=e.allowAnonymous,t=e.closeInactivityPrompt,o=e.expirationDate,i=e.inactivityPromptDuration,r=e.isShowingInactivityPrompt,a=e.lastActivity,s=e.maxSessionAge,c=e.minRenewalAge,u=e.redirectForInactivity,d=e.renewSession,l=e.showInactivityPrompt,f=Date.now();if(null!==o){!n&&f>o&&u();var m=o-i,p=o-s+c;r?f<m&&t():a>p?d():!n&&f>m&&l()}},e}();n.BBOmnibarUserActivityProcessor=o},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i=t(2),r=t(5);var a=function(){function e(){}return e.getSessionExpiration=function(e,n,t){var a=function(e,n){if(o&&o.refreshId===e&&o.allowAnonymous===n)return o.promise;var t=new Promise((function(e,t){r.BBCsrfXhr.request(i.BBAuthDomain.getSTSDomain()+"/session/ttl",void 0,n).then((function(n){var t=null===n?null:Date.now()+1e3*n;e(t)}),(function(){e(null)}))}));return o={allowAnonymous:n,promise:t,refreshId:e},t}(e,t);return new Promise((function(e,t){a.then((function(t){var o;if(null===t)o=null;else if("number"==typeof n){var i=Date.now()+n;o=Math.min(t,i)}else o=t;e(o)}))}))},e.reset=function(){o=void 0},e}();n.BBOmnibarUserSessionExpiration=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u,d,l=t(4),f=t(1),m=t(2),p={};function h(e){if(e){var n=e.split("://");return n[0]+"://"+n[1].split("/")[0]}}function v(e,n){var t=document.createElement("iframe");return t.className=e,t.width="0",t.height="0",t.frameBorder="0",t.src=n,t.tabIndex=-1,t.setAttribute("aria-hidden","true"),document.body.appendChild(t),t}function b(){var e=B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN+"/SessionWatcher.html?origin="+encodeURIComponent(location.origin);c=v("sky-omnibar-iframe-session-watcher",e)}function y(e){if("string"==typeof e.data){var n=void 0;try{n=JSON.parse(e.data)}catch(e){return}if("session_change"===n.messageType){var t=n.message,o=t&&t.sessionId,c=t&&t.refreshId;o||s||(d?f.BBAuthNavigator.navigate(d):f.BBAuthNavigator.redirectToSignin()),void 0!==p.refreshId&&c!==p.refreshId&&function(e){u&&l.BBAuthInterop.postOmnibarMessage(u,e,h(i))}({messageType:"session-refresh"}),void 0!==p.sessionId&&o!==p.sessionId&&r(),p.refreshId=c,p.sessionId=o,a(p)}}}function g(e){switch(e.origin){case B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN:y(e);break;case h(i):!function(e){var n=e.data;switch(n.messageType){case"ready":p.legacyTtl=n.ttl,d=n.signinUrl,a(p)}}(e)}}var B=function(){function e(){}return e.start=function(n,t,c,d){o&&n===s&&t===i||(e.stop(),s=n,r=c,i=t,a=d,b(),i&&(u=v("sky-omnibar-iframe-legacy-keep-alive",i)),window.addEventListener("message",g,!1),o=!0)},e.stop=function(){window.removeEventListener("message",g,!1),c&&(document.body.removeChild(c),c=void 0),u&&(document.body.removeChild(u),u=void 0),p={},o=s=r=i=d=a=void 0},e.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN=m.BBAuthDomain.getSTSDomain(),e}();n.BBOmnibarUserSessionWatcher=B},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a=t(3),s=t(4);function c(e){if(s.BBAuthInterop.messageIsFromOmnibar(e))switch(e.data.messageType){case"ready":s.BBAuthInterop.postOmnibarMessage(i,{messageType:"host-ready"}),i.classList.add("sky-omnibar-inactivity-iframe-ready");break;case"session-renew":r()}}var u=function(){function e(){}return e.show=function(n){var t;this.hide(),r=n.sessionRenewCallback,o=a.BBAuthDomUtility.addCss("\n .sky-omnibar-inactivity-iframe {\n background-color: transparent;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 100000;\n visibility: hidden;\n }\n\n .sky-omnibar-inactivity-iframe-ready {\n visibility: visible;\n }\n "),t=e.url,i=a.BBAuthDomUtility.addIframe(t,"sky-omnibar-inactivity-iframe","Inactivity Prompt"),window.addEventListener("message",c)},e.hide=function(){i&&(a.BBAuthDomUtility.removeEl(i),a.BBAuthDomUtility.removeCss(o),i=o=r=void 0,window.removeEventListener("message",c))},e.url="https://host.nxt.blackbaud.com/omnibar/inactivity",e}();n.BBOmnibarUserActivityPrompt=u},function(e,n,t){"use strict";var o=this&&this.__awaiter||function(e,n,t,o){return new(t||(t=Promise))((function(i,r){function a(e){try{c(o.next(e))}catch(e){r(e)}}function s(e){try{c(o.throw(e))}catch(e){r(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((o=o.apply(e,n||[])).next())}))},i=this&&this.__generator||function(e,n){var t,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===r[0]||2===r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=n.call(e,a)}catch(e){r=[6,e],o=0}finally{t=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}};Object.defineProperty(n,"__esModule",{value:!0});var r,a=t(0),s=t(8),c=function(){function e(){}return e.connect=function(e,n,t){return o(this,void 0,void 0,(function(){return i(this,(function(o){return r||(r=window.BBNotificationsClient?Promise.resolve():s.BBOmnibarScriptLoader.registerScript(this.NOTIFICATIONS_CLIENT_URL)),[2,r.then((function(){BBNotificationsClient.BBNotifications.init({tokenCallback:function(){return a.BBAuth.getToken({disableRedirect:!0,envId:n,leId:e})}}),BBNotificationsClient.BBNotifications.addListener(t)}))]}))}))},e.disconnect=function(){return o(this,void 0,void 0,(function(){return i(this,(function(e){return r?[2,r.then((function(){BBNotificationsClient.BBNotifications.destroy(),r=void 0}))]:[2,Promise.resolve()]}))}))},e.updateNotifications=function(e){BBNotificationsClient.BBNotifications.updateNotifications(e)},e.NOTIFICATIONS_CLIENT_URL="https://sky.blackbaudcdn.net/static/notifications-client/1/notifications-client.global.min.js",e}();n.BBOmnibarPushNotifications=c},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u=t(6),d=t(3),l=t(4),f="sky-omnibar-toast-container",m=f+"-ready",p=f+"-empty",h=20;function v(){return i||(o=d.BBAuthDomUtility.addCss("\n."+f+" {\n border: none;\n display: none;\n position: fixed;\n right: 0px;\n height: 0px;\n width: 300px;\n /* z-index is 1 less than omnibar so menus will display over top the toast container */\n z-index: 999;\n}\n\n."+m+" {\n display: block;\n}\n\n."+p+" {\n visibility: hidden;\n}\n"),(i=document.createElement("iframe")).src=B.CONTAINER_URL,i.className=f+" "+p,i.title="Toast container",document.body.appendChild(i),window.addEventListener("message",g)),i}function b(e){var n=document.querySelector(e);return n?n.getBoundingClientRect().height:0}function y(){i&&l.BBAuthInterop.postOmnibarMessage(i,{href:c,messageType:"location-change"})}function g(e){if(l.BBAuthInterop.messageIsFromToastContainer(e)){var n,t,o=e.data;switch(o.messageType){case"toast-ready":l.BBAuthInterop.postOmnibarMessage(i,{messageType:"host-ready"}),l.BBAuthInterop.postOmnibarMessage(i,{envId:s.envId,leId:s.leId,messageType:"nav-ready",svcId:s.svcId}),y(),i.classList.add(m),a();break;case"get-token":n=o.tokenRequestId,t=o.disableRedirect,u.BBAuth.getToken({disableRedirect:t}).then((function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"token",token:e,tokenRequestId:n})}),(function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"token-fail",reason:e,tokenRequestId:n})}));break;case"navigate-url":s.navigateUrlCallback(o.url);break;case"navigate":s.navigateCallback(o.navItem);break;case"toast-container-change":o.height>0?(i.style.height=o.height+"px",i.style.top=b(".sky-omnibar-iframe")+b(".sky-omnibar-environment")+h+"px",i.classList.remove(p)):i.classList.add(p);break;case"push-notifications-open":s.openMenuCallback()}}}var B=function(){function e(){}return e.init=function(e){return s=e,c=e.url,r||(r=new Promise((function(e){a=e,v()}))),r},e.showNewNotifications=function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"push-notifications-update",pushNotifications:e})},e.updateUrl=function(e){c=e,y()},e.destroy=function(){o&&d.BBAuthDomUtility.removeCss(o),i&&d.BBAuthDomUtility.removeEl(i),c=i=s=r=a=o=void 0,window.removeEventListener("message",g)},e.CONTAINER_URL="https://host.nxt.blackbaud.com/omnibar/toast",e}();n.BBOmnibarToastContainer=B},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(8);function i(){return window.jQuery}var r=function(){function e(){}return e.load=function(e){return new Promise((function(n){var t=i(),r=t&&t.fn&&t.fn.jquery;o.BBOmnibarScriptLoader.smartRegisterScript("https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.js","2.1.0",r).then((function(){return o.BBOmnibarScriptLoader.registerScript("https://cdnjs.cloudflare.com/ajax/libs/easyXDM/2.4.17.1/easyXDM.min.js")})).then((function(){return o.BBOmnibarScriptLoader.registerScript("https://signin.blackbaud.com/Omnibar.min.js")})).then((function(){document.body.classList.add("bb-omnibar-height-padding");var t=document.createElement("div");t.setAttribute("data-omnibar-el",""),document.body.appendChild(t),(e=e||{})["z-index"]=1e3,e.afterLoad=n,e.menuEl&&(e.menuEl=i()(e.menuEl)),BBAUTH.Omnibar.load(t,e)}))}))},e}();n.BBOmnibarLegacy=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0})}])})); | ||
!function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.BBAuthClient=n():e.BBAuthClient=n()}(window,(function(){return function(e){var n={};function t(o){if(n[o])return n[o].exports;var i=n[o]={i:o,l:!1,exports:{}};return e[o].call(i.exports,i,i.exports,t),i.l=!0,i.exports}return t.m=e,t.c=n,t.d=function(e,n,o){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:o})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(t.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var i in e)t.d(o,i,function(n){return e[n]}.bind(null,i));return o},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="",t(t.s=9)}([function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(6)),o(t(7))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i="https://signin.blackbaud.com/signin/",r=encodeURIComponent;function a(e){var n=i+"?redirectUrl="+r(location.href);return e&&(n+="&inactivity=1"),n}var s=function(){function e(){}return e.navigate=function(e,n){n?location.replace(e):location.href=e},e.redirectToSignin=function(e){var n=a();e&&(n+="&"+function(e){var n=[];for(var t in e)e.hasOwnProperty(t)&&n.push(r(t)+"="+r(e[t]));return n.join("&")}(e)),this.navigate(n)},e.redirectToSignoutForInactivity=function(){var e=a(!0),n=i+"sign-out?redirectUrl="+r(e);this.navigate(n)},e.redirectToError=function(e){var n,t;switch(e){case o.BBAuthTokenErrorCode.InvalidEnvironment:t="invalid_env",n="security";break;default:n="broken"}var i="https://host.nxt.blackbaud.com/errors/"+n+"?source=auth-client&url="+r(location.href);t&&(i+="&code="+r(t)),this.navigate(i)},e}();n.BBAuthNavigator=s},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o={"bbk12.com":"https://sts-sso.bbk12.com","blackbaudfaith.com":"https://sts.blackbaudfaith.com","blackbaudhosting.com":"https://sts.blackbaudhosting.com","donorcentral.com":"https://sts-dc.donorcentral.com","etapestry.com":"https://sts.etapestry.com","mycampus-app.com":"https://sts-sso.mycampus-app.com","myschoolapp.com":"https://sts-sso.myschoolapp.com","myschoolautomation.com":"https://sts-sso.myschoolautomation.com","myschooldemo.com":"https://sts-sso.myschooldemo.com","myschooltraining.com":"https://sts-sso.myschooltraining.com"},i=function(){function e(){}return e.getRegisteredDomain=function(){for(var e=0,n=Object.keys(o);e<n.length;e++){var t=n[e],i="."+t;if(this.CURRENT_DOMAIN===t||this.CURRENT_DOMAIN.substr(-i.length)===i)return t}},e.getSTSDomain=function(){var e=this.getRegisteredDomain();return o[e]||"https://s21aidntoken00blkbapp01.nxt.blackbaud.com"},e.CURRENT_DOMAIN=window.location.hostname,e}();n.BBAuthDomain=i},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){}return e.addCss=function(e){var n=document.createElement("style");return n.appendChild(document.createTextNode(e)),document.head.appendChild(n),n},e.addIframe=function(e,n,t){var o=document.createElement("iframe");return o.className=n,o.title=t,o.src=e,this.addElToBodyTop(o),o},e.removeCss=function(e){this.removeEl(e,document.head)},e.removeEl=function(e,n){void 0===n&&(n=document.body),n.contains(e)&&n.removeChild(e)},e.addElToBodyTop=function(e){var n=document.body;n.firstChild?n.insertBefore(e,n.firstChild):n.appendChild(e)},e}();n.BBAuthDomUtility=o},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o="https://host.nxt.blackbaud.com";function i(e,n){if(e.origin===o){var t=e.data;return!!t&&t.source===n}return!1}var r=function(){function e(){}return e.postOmnibarMessage=function(e,n,t){n.source="auth-client",e.contentWindow.postMessage(n,t||o)},e.messageIsFromOmnibar=function(e){return i(e,"skyux-spa-omnibar")},e.messageIsFromToastContainer=function(e){return i(e,"skyux-spa-omnibar-toast-container")},e}();n.BBAuthInterop=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i=t(2),r=t(1);function a(e,n,t,o){return(o||void 0===o&&t)&&((e=e||{})[n]=t),e}function s(e,n,t,i,r){var s;return s=a(s,"environment_id",t),s=a(s,"legal_entity_id",r),s=a(s,"permission_scope",i,!(!t&&!r||!i)),new Promise((function(t,i){!function(e,n,t,i,r){var a=new XMLHttpRequest;a.onreadystatechange=function(){if(4===a.readyState)switch(a.status){case 0:r({code:o.BBAuthTokenErrorCode.Offline,message:"The user is offline."});break;case 200:i(a.responseText);break;case 401:r({code:o.BBAuthTokenErrorCode.NotLoggedIn,message:"The user is not logged in."});break;case 403:r({code:o.BBAuthTokenErrorCode.InvalidEnvironment,message:"The user is not a member of the specified environment."});break;default:a.status>=400&&r({code:o.BBAuthTokenErrorCode.Unspecified,message:"An unknown error occurred."})}},a.open("POST",e,!0),a.setRequestHeader(n.name,n.value),a.setRequestHeader("Accept","application/json"),a.setRequestHeader("Content-Type","application/json"),a.withCredentials=!0,t?a.send(JSON.stringify(t)):a.send()}(e,{name:"X-CSRF",value:n},s,(function(e){var n=e?JSON.parse(e):void 0;t(n)}),i)}))}var c=function(){function e(){}return e.request=function(e,n,t,a,c,u,d){return!c||a||u?new Promise((function(l,f){new Promise((function(e,n){d?e({csrf_token:"token_needed"}):s(i.BBAuthDomain.getSTSDomain()+"/session/csrf","token_needed").then(e).catch(n)})).then((function(n){return s(e,n.csrf_token,a,c,u)})).then(l).catch((function(e){if(t||e.code===o.BBAuthTokenErrorCode.Offline)f(e);else switch(e.code){case o.BBAuthTokenErrorCode.NotLoggedIn:r.BBAuthNavigator.redirectToSignin(n);break;default:r.BBAuthNavigator.redirectToError(e.code)}}))})):Promise.reject({code:o.BBAuthTokenErrorCode.PermissionScopeNoEnvironment,message:"You must also specify an environment or legal entity when specifying a permission scope."})},e.requestWithToken=function(e,n){return new Promise((function(t,o){var i=new XMLHttpRequest;i.onreadystatechange=function(){if(4===i.readyState)switch(i.status){case 200:t(JSON.parse(i.responseText));break;default:o()}},i.open("GET",e,!0),i.setRequestHeader("Authorization","Bearer "+n),i.setRequestHeader("Accept","application/json"),i.send()}))},e}();n.BBCsrfXhr=c},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(10),i=/1bb:\/\/([a-z]{3})-([a-z0-9]{5})(-[a-z]{4}[0-9]{2})?\/(.*)/;var r=function(){function e(){}return e.getUrl=function(e,n){var t=i.exec(e),o=e,r=n?n.zone:void 0;return r&&(r=r.replace("-","")),t&&(t[3]&&(r=t[3].substring(1)),o="https://"+t[1]+"-"+r+".app.blackbaud.net/"+t[2]+"/"+t[4]),Promise.resolve(o)},e.getToken=function(n){return e.getTokenInternal(n)},e.clearTokenCache=function(){e.tokenCache={}},e.getTokenInternal=function(n){var t=(n=n||{}).forceNewToken,i=n.disableRedirect;if(e.mock)return Promise.resolve("mock_access_token_auth-client@blackbaud.com");var r=function(e){var n=e.envId,t=e.permissionScope;return"token|"+(e.leId||"-")+"|"+(n||"-")+"|"+(t||"-")}(n),a=e.tokenCache[r]=e.tokenCache[r]||{},s=(new Date).valueOf();return!t&&a.lastToken&&a.expirationTime&&a.expirationTime-s>6e4?Promise.resolve(a.lastToken):(a.pendingLookupPromise||(a.pendingLookupPromise=o.BBAuthTokenIntegration.getToken(i,n.envId,n.permissionScope,n.leId).then((function(e){return a.expirationTime=(new Date).valueOf()+1e3*e.expires_in,a.lastToken=e.access_token,a.pendingLookupPromise=null,a.lastToken})).catch((function(e){throw a.pendingLookupPromise=null,e}))),a.pendingLookupPromise)},e.mock=!1,e.tokenCache={},e}();n.BBAuth=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),function(e){e[e.Unspecified=0]="Unspecified",e[e.NotLoggedIn=1]="NotLoggedIn",e[e.InvalidEnvironment=2]="InvalidEnvironment",e[e.PermissionScopeNoEnvironment=3]="PermissionScopeNoEnvironment",e[e.Offline=4]="Offline"}(n.BBAuthTokenErrorCode||(n.BBAuthTokenErrorCode={}))},function(e,n,t){"use strict";function o(e){for(var n=[],t=0,o=e.split(".");t<o.length;t++){var i=o[t],r=parseInt(i,10)||0;n.push(r)}return n}Object.defineProperty(n,"__esModule",{value:!0});var i=function(){function e(){}return e.registerScript=function(e){return new Promise((function(n,t){var o=document.createElement("script");o.onload=n,o.onerror=t,o.src=e,document.body.appendChild(o)}))},e.smartRegisterScript=function(n,t,i){return i&&function(e,n){for(var t=o(e),i=o(n),r=0;r<t.length;r++)if(r<i.length){if(i[r]>t[r])return!0;if(i[r]<t[r])return!1}return!0}(t,i)?Promise.resolve():e.registerScript(n)},e}();n.BBOmnibarScriptLoader=i},function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(0)),o(t(12)),o(t(14))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(5),i=t(11),r=t(2),a=function(){function e(){}return e.getToken=function(e,n,t,a){return void 0!==r.BBAuthDomain.getRegisteredDomain()||this.hostNameEndsWith("blackbaud.com")?o.BBCsrfXhr.request(r.BBAuthDomain.getSTSDomain()+"/oauth2/token",void 0,e,n,t,a,!0):i.BBAuthCrossDomainIframe.getToken({disableRedirect:e,envId:n,leId:a,permissionScope:t})},e.hostNameEndsWith=function(e){return this.getLocationHostname().substr(-e.length)===e},e.getLocationHostname=function(){return window.location.hostname},e}();n.BBAuthTokenIntegration=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(3),i=t(1),r=t(7),a=function(){function e(){}return e.reset=function(){var e=this;this.requestCounter=0,this.tokenRequests={},this.iframeReadyPromise=new Promise((function(n){return e.iframeReadyResolve=n})),this.listenerSetup=!1},e.TARGET_ORIGIN=function(){return this.TARGETORIGIN},e.getOrMakeIframe=function(){return e.iframeEl=document.getElementById("auth-cross-domain-iframe"),e.iframeEl||(e.iframeEl=o.BBAuthDomUtility.addIframe("https://s21aidntoken00blkbapp01.nxt.blackbaud.com/Iframes/CrossDomainAuthFrame.html","auth-cross-domain-iframe",""),e.iframeEl.id="auth-cross-domain-iframe",e.iframeEl.hidden=!0),e.iframeEl},e.getToken=function(e){return this.setupListenersForIframe(),this.getTokenFromIframe(this.getOrMakeIframe(),e)},e.setupListenersForIframe=function(){var e=this;this.listenerSetup||(window.addEventListener("message",(function(n){var t=n.data,o=t.requestId,i=e.tokenRequests[o];if("security-token-svc"===t.source||t.origin===e.TARGET_ORIGIN())switch(t.messageType){case"ready":e.iframeReadyResolve(!0);break;case"error":e.handleErrorMessage(t.value,i.reject,i.args.disableRedirect);break;case"getToken":var r={access_token:t.value,expires_in:0};i.resolve(r)}})),this.listenerSetup=!0)},e.getTokenFromIframe=function(n,t){var o=this;return new Promise((function(i,r){var a=o.requestCounter++;e.tokenRequests[a]={args:t,reject:r,resolve:i},e.iframeReadyPromise.then((function(){n.contentWindow.postMessage({messageType:"getToken",requestId:a,source:"auth-client",value:t},e.TARGET_ORIGIN())}))}))},e.handleErrorMessage=function(e,n,t){if(t)n(e);else switch(e.code){case r.BBAuthTokenErrorCode.Offline:n(e);break;case r.BBAuthTokenErrorCode.NotLoggedIn:i.BBAuthNavigator.redirectToSignin(void 0);break;default:i.BBAuthNavigator.redirectToError(e.code)}},e.listenerSetup=!1,e.iframeReadyPromise=new Promise((function(n){return e.iframeReadyResolve=n})),e.tokenRequests={},e.requestCounter=0,e.TARGETORIGIN="https://s21aidntoken00blkbapp01.nxt.blackbaud.com",e}();n.BBAuthCrossDomainIframe=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),function(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}(t(13))},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(0),i=t(4),r=t(5),a=t(3),s=t(1);function c(e,n,t,r){var s,c,u;function l(){a.BBAuthDomUtility.removeEl(c),a.BBAuthDomUtility.removeCss(s),c=s=void 0,window.removeEventListener("message",f)}function f(a){if(i.BBAuthInterop.messageIsFromOmnibar(a)){var s,u,d=a.data;switch(d.messageType){case"ready":i.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),i.BBAuthInterop.postOmnibarMessage(c,{contextDestinations:n,messageType:"context-provide"});break;case"get-token":s=d.tokenRequestId,u=d.disableRedirect,o.BBAuth.getToken({disableRedirect:u}).then((function(e){i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:s})}),(function(e){i.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:s})}));break;case"welcome-cancel":l(),r({reason:"canceled"});break;case"welcome-environment-selected":l(),setTimeout((function(){e.envId=d.envId,t(e)}),10)}}}s=a.BBAuthDomUtility.addCss("\n.sky-omnibar-welcome-iframe {\n background-color: #fff;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 10000;\n}\n"),u=d.url+"?hosted=1&svcid="+encodeURIComponent(e.svcId)+"&url="+encodeURIComponent(e.url),c=a.BBAuthDomUtility.addIframe(u,"sky-omnibar-welcome-iframe","Welcome"),window.addEventListener("message",f)}function u(){s.BBAuthNavigator.redirectToError(o.BBAuthTokenErrorCode.InvalidEnvironment)}var d=function(){function e(){}return e.ensureContext=function(e){var n=e.envId,t=e.envIdRequired,i=e.leId,a=e.leIdRequired,s=e.svcId;return!n&&t||!i&&a?new Promise((function(n,t){s?o.BBAuth.getToken().then((function(o){var i="https://s21anavnavaf00blkbapp01.sky.blackbaud.com/user/destinations?svcid="+encodeURIComponent(s);e.url&&(i+="&referringurl="+encodeURIComponent(e.url)),r.BBCsrfXhr.requestWithToken(i,o).then((function(o){var i=o&&o.items,r=i&&i.length;1===r?(e.url=i[0].url,n(e)):r>1?c(e,o,n,t):u()}))})):u()})):Promise.resolve(e)},e.url="https://host.nxt.blackbaud.com/omnibar/welcome",e}();n.BBContextProvider=d},function(e,n,t){"use strict";function o(e){for(var t in e)n.hasOwnProperty(t)||(n[t]=e[t])}Object.defineProperty(n,"__esModule",{value:!0}),o(t(15)),o(t(26)),o(t(27))},function(e,n,t){"use strict";var o=this&&this.__awaiter||function(e,n,t,o){return new(t||(t=Promise))((function(i,r){function a(e){try{c(o.next(e))}catch(e){r(e)}}function s(e){try{c(o.throw(e))}catch(e){r(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((o=o.apply(e,n||[])).next())}))},i=this&&this.__generator||function(e,n){var t,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===r[0]||2===r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=n.call(e,a)}catch(e){r=[6,e],o=0}finally{t=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}};Object.defineProperty(n,"__esModule",{value:!0});var r,a,s,c,u,d,l,f,m,p,h,v=t(16),b=t(0),y=t(4),g=t(1),B=t(3),k=t(19),I=t(23),T=t(24),w=t(25),A="sky-omnibar-iframe-expanded",O="sky-omnibar-loading";function E(){c=B.BBAuthDomUtility.addIframe(u.url||"https://host.nxt.blackbaud.com/omnibar/","sky-omnibar-iframe "+O,"Navigation")}function _(){var e=document.location.href;y.BBAuthInterop.postOmnibarMessage(c,{href:e,messageType:"location-change"}),w.BBOmnibarToastContainer.updateUrl(e)}function N(){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"push-notifications-open"})}function C(){f||(f=!0,j.pushNotificationsEnabled().then((function(e){e?w.BBOmnibarToastContainer.init({envId:u.envId,leId:u.leId,navigateCallback:M,navigateUrlCallback:U,openMenuCallback:N,svcId:u.svcId,url:document.location.href}).then((function(){T.BBOmnibarPushNotifications.connect(u.leId,u.envId,(function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"push-notifications-update",pushNotifications:e}),w.BBOmnibarToastContainer.showNewNotifications(e),m=e&&e.notifications&&e.notifications.filter((function(e){return!e.isRead})).length,D()}))})):f=!1})))}function R(){function e(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"refresh-user",token:e}),e?C():f&&(w.BBOmnibarToastContainer.destroy(),T.BBOmnibarPushNotifications.disconnect(),f=!1)}b.BBAuth.clearTokenCache(),b.BBAuth.getToken({disableRedirect:!0,forceNewToken:!0}).then(e).catch((function(){return e(void 0)}))}function S(){I.BBOmnibarUserActivityPrompt.show({sessionRenewCallback:function(){k.BBOmnibarUserActivity.userRenewedSession()}})}function P(){I.BBOmnibarUserActivityPrompt.hide()}function x(){k.BBOmnibarUserActivity.startTracking(R,S,P,u.allowAnonymous,d)}function M(e){var n=u.nav;n&&n.beforeNavCallback&&!1===n.beforeNavCallback(e)||g.BBAuthNavigator.navigate(e.url)}function U(e){g.BBAuthNavigator.navigate(e)}function L(e){if(y.BBAuthInterop.messageIsFromOmnibar(e)){var n,t,o,i,s,f,m,h,v,g,B,I=e.data,w=u.nav;switch(I.messageType){case"ready":y.BBAuthInterop.postOmnibarMessage(c,{messageType:"host-ready"}),g=history.pushState,B=history.replaceState,history.pushState=function(){var e=g.apply(history,arguments);return _(),e},history.replaceState=function(){var e=B.apply(history,arguments);return _(),e},y.BBAuthInterop.postOmnibarMessage(c,{compactNavOnly:u.compactNavOnly,enableHelp:u.enableHelp,envId:u.envId,hideResourceLinks:u.hideResourceLinks,leId:u.leId,localNavItems:w&&w.localNavItems,localNotifications:!!u.notifications,localSearch:!!u.onSearch,messageType:"nav-ready",navVersion:u.navVersion,services:w&&w.services,svcId:u.svcId,theme:u.theme}),(v=u.notifications)&&v.onReady({updateNotifications:function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"notifications-update",notifications:e})}}),C(),_(),l();break;case"display-ready":a.classList.remove(O),c.classList.remove(O);break;case"expand":c.classList.add(A);break;case"collapse":c.classList.remove(A);break;case"navigate-url":U(I.url);break;case"navigate":M(I.navItem);break;case"search":h=I.searchArgs,u.onSearch&&u.onSearch(h).then((function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"search-results",results:e})}));break;case"get-token":f=I.tokenRequestId,m=I.disableRedirect,b.BBAuth.getToken({disableRedirect:m}).then((function(e){x(),y.BBAuthInterop.postOmnibarMessage(c,{messageType:"token",token:e,tokenRequestId:f})}),(function(e){x(),y.BBAuthInterop.postOmnibarMessage(c,{messageType:"token-fail",reason:e,tokenRequestId:f})}));break;case"help-open":(s=window.BBHELP)&&s.HelpWidget.open();break;case"notification-read":!function(e){var n=u.notifications;n&&n.onNotificationRead&&n.onNotificationRead(e)}(I.notification);break;case"push-notifications-change":i=I.notifications,T.BBOmnibarPushNotifications.updateNotifications(i);break;case"session-renew":k.BBOmnibarUserActivity.userRenewedSession();break;case"environment-update":n=I.name,t="sky-omnibar-environment-visible",o=document.body.classList,n=n||"",r.innerText=n,n?o.add(t):o.remove(t);break;case"legacy-keep-alive-url-change":d=I.url,x();break;case"selected-service-update":p=I.serviceName,D()}}}function D(){if(h){var e=h.slice();p&&e.push(p);var n=e.join(" - ");m&&(n="("+m+") "+n),document.title=n}}var j=function(){function e(){}return e.load=function(e){return u=u=e,d=u.legacyKeepAliveUrl,new Promise((function(e){l=e,function(){var e="background: linear-gradient(to right, #71bf44 0, #31b986 50%, #00b2ec 100%);",n="#4d5259",t=u.theme;if(t){var o=t.accent;n=t.backgroundColor||n,!1===o?e="display: none;":o&&o.color&&(e="background-color: "+o.color+";")}s=B.BBAuthDomUtility.addCss("\nbody {\n margin-top: 50px;\n}\n\n#bb-help-container {\n padding-top: 1px;\n}\n\n.sky-omnibar-iframe,\n.sky-omnibar-placeholder {\n border: none;\n height: 50px;\n width: 100%;\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n z-index: 1000;\n}\n\n.sky-omnibar-placeholder {\n background-color: "+n+";\n display: none;\n}\n\n.sky-omnibar-placeholder-accent {\n height: 5px;\n "+e+"\n}\n\n.sky-omnibar-placeholder."+O+" {\n display: block;\n}\n\n.sky-omnibar-iframe."+O+" {\n visibility: hidden;\n}\n\n."+A+' {\n height: 100%;\n}\n\n.sky-omnibar-environment {\n background-color: #e1e1e3;\n color: #282b31;\n font-family: "Blackbaud Sans", "Open Sans", "Helvetica Neue", Arial, sans-serif;\n font-size: 12px;\n font-weight: 400;\n height: 0;\n line-height: 24px;\n overflow: hidden;\n padding: 0 15px;\n text-align: right;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.sky-omnibar-environment-visible .sky-omnibar-environment {\n height: 24px;\n}\n')}(),(a=document.createElement("div")).className="sky-omnibar-placeholder "+O,a.innerHTML='<div class="sky-omnibar-placeholder-accent"></div>',document.body.appendChild(a),(r=document.createElement("div")).className="sky-omnibar-environment",B.BBAuthDomUtility.addElToBodyTop(r),E(),window.addEventListener("message",L)}))},e.update=function(e){y.BBAuthInterop.postOmnibarMessage(c,{messageType:"update",updateArgs:e})},e.setTitle=function(e){h=e&&e.titleParts,D()},e.pushNotificationsEnabled=function(){return o(this,void 0,void 0,(function(){return i(this,(function(e){return u?[2,b.BBAuth.getToken({disableRedirect:!0,envId:u.envId,leId:u.leId,permissionScope:"Notifications"}).then((function(e){var n=v(e)["1bb.entitlements"];return!!n&&(n=Array.isArray(n)?n:[n]).indexOf("notif")>-1})).catch((function(){return!1}))]:[2,Promise.resolve(!1)]}))}))},e.destroy=function(){w.BBOmnibarToastContainer.destroy(),T.BBOmnibarPushNotifications.disconnect(),B.BBAuthDomUtility.removeEl(a),B.BBAuthDomUtility.removeEl(c),B.BBAuthDomUtility.removeEl(r),B.BBAuthDomUtility.removeCss(s),window.removeEventListener("message",L),u=s=a=c=r=l=f=m=h=p=void 0},e}();n.BBOmnibar=j},function(e,n,t){"use strict";var o=t(17);function i(e){this.message=e}i.prototype=new Error,i.prototype.name="InvalidTokenError",e.exports=function(e,n){if("string"!=typeof e)throw new i("Invalid token specified");var t=!0===(n=n||{}).header?0:1;try{return JSON.parse(o(e.split(".")[t]))}catch(e){throw new i("Invalid token specified: "+e.message)}},e.exports.InvalidTokenError=i},function(e,n,t){var o=t(18);e.exports=function(e){var n=e.replace(/-/g,"+").replace(/_/g,"/");switch(n.length%4){case 0:break;case 2:n+="==";break;case 3:n+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(o(e).replace(/(.)/g,(function(e,n){var t=n.charCodeAt(0).toString(16).toUpperCase();return t.length<2&&(t="0"+t),"%"+t})))}(n)}catch(e){return o(n)}}},function(e,n){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";function o(e){this.message=e}o.prototype=new Error,o.prototype.name="InvalidCharacterError",e.exports="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var n=String(e).replace(/=+$/,"");if(n.length%4==1)throw new o("'atob' failed: The string to be decoded is not correctly encoded.");for(var i,r,a=0,s=0,c="";r=n.charAt(s++);~r&&(i=a%4?64*i+r:r,a++%4)?c+=String.fromCharCode(255&i>>(-2*a&6)):0)r=t.indexOf(r);return c}},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u,d,l,f,m,p,h,v,b=t(2),y=t(5),g=t(20),B=t(21),k=t(22),I=t(1),T="";function w(){d=Date.now()}function A(e){e.clientX===i&&e.clientY===r||(i=e.clientX,r=e.clientY,w())}function O(){var e=Date.now();(!l||e-l>R.MIN_RENEWAL_RETRY)&&(l=e,y.BBCsrfXhr.request(b.BBAuthDomain.getSTSDomain()+"/session/renew",{inactivity:1}).catch((function(){})))}function E(){u=!0,c()}function _(){u=!1,w(),a()}function N(){v?I.BBAuthNavigator.navigate(v):I.BBAuthNavigator.redirectToSignoutForInactivity()}function C(){m||O(),f=setInterval((function(){B.BBOmnibarUserSessionExpiration.getSessionExpiration(T,h,m).then((function(e){o&&g.BBOmnibarUserActivityProcessor.process({allowAnonymous:m,closeInactivityPrompt:_,expirationDate:e,inactivityPromptDuration:R.INACTIVITY_PROMPT_DURATION,isShowingInactivityPrompt:u,lastActivity:d,maxSessionAge:R.MAX_SESSION_AGE,minRenewalAge:R.MIN_RENEWAL_AGE,redirectForInactivity:N,renewSession:O,showInactivityPrompt:E})}))}),R.ACTIVITY_TIMER_INTERVAL)}var R=function(){function e(){}return e.startTracking=function(n,t,i,r,u){o&&r===m&&u===p||(e.stopTracking(),s=n,c=t,a=i,m=r,p=u,document.addEventListener("keypress",w),document.addEventListener("mousemove",A),C(),k.BBOmnibarUserSessionWatcher.start(r,u,s,(function(e){h=e.legacyTtl,T=e.refreshId,v=e.legacySigninUrl})),o=!0)},e.userRenewedSession=function(){_(),O()},e.stopTracking=function(){k.BBOmnibarUserSessionWatcher.stop(),B.BBOmnibarUserSessionExpiration.reset(),document.removeEventListener("keypress",w),document.removeEventListener("mousemove",A),f&&(clearInterval(f),f=void 0),o=i=r=d=l=u=s=c=a=m=p=void 0},e.ACTIVITY_TIMER_INTERVAL=1e3,e.MIN_RENEWAL_RETRY=6e4,e.INACTIVITY_PROMPT_DURATION=12e4,e.MIN_RENEWAL_AGE=3e5,e.MAX_SESSION_AGE=54e5,e}();n.BBOmnibarUserActivity=R},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=function(){function e(){}return e.process=function(e){var n=e.allowAnonymous,t=e.closeInactivityPrompt,o=e.expirationDate,i=e.inactivityPromptDuration,r=e.isShowingInactivityPrompt,a=e.lastActivity,s=e.maxSessionAge,c=e.minRenewalAge,u=e.redirectForInactivity,d=e.renewSession,l=e.showInactivityPrompt,f=Date.now();if(null!==o){!n&&f>o&&u();var m=o-i,p=o-s+c;r?f<m&&t():a>p?d():!n&&f>m&&l()}},e}();n.BBOmnibarUserActivityProcessor=o},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i=t(2),r=t(5);var a=function(){function e(){}return e.getSessionExpiration=function(e,n,t){var a=function(e,n){if(o&&o.refreshId===e&&o.allowAnonymous===n)return o.promise;var t=new Promise((function(e,t){r.BBCsrfXhr.request(i.BBAuthDomain.getSTSDomain()+"/session/ttl",void 0,n).then((function(n){var t=null===n?null:Date.now()+1e3*n;e(t)}),(function(){e(null)}))}));return o={allowAnonymous:n,promise:t,refreshId:e},t}(e,t);return new Promise((function(e,t){a.then((function(t){var o;if(null===t)o=null;else if("number"==typeof n){var i=Date.now()+n;o=Math.min(t,i)}else o=t;e(o)}))}))},e.reset=function(){o=void 0},e}();n.BBOmnibarUserSessionExpiration=a},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u,d,l=t(4),f=t(1),m=t(2),p={};function h(e){if(e){var n=e.split("://");return n[0]+"://"+n[1].split("/")[0]}}function v(e,n){var t=document.createElement("iframe");return t.className=e,t.width="0",t.height="0",t.frameBorder="0",t.src=n,t.tabIndex=-1,t.setAttribute("aria-hidden","true"),document.body.appendChild(t),t}function b(){var e=B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN+"/SessionWatcher.html?origin="+encodeURIComponent(location.origin);c=v("sky-omnibar-iframe-session-watcher",e)}function y(e){if("string"==typeof e.data){var n=void 0;try{n=JSON.parse(e.data)}catch(e){return}if("session_change"===n.messageType){var t=n.message,o=t&&t.sessionId,c=t&&t.refreshId;o||s||(d?f.BBAuthNavigator.navigate(d):f.BBAuthNavigator.redirectToSignin()),void 0!==p.refreshId&&c!==p.refreshId&&function(e){u&&l.BBAuthInterop.postOmnibarMessage(u,e,h(i))}({messageType:"session-refresh"}),void 0!==p.sessionId&&o!==p.sessionId&&r(),p.refreshId=c,p.sessionId=o,a(p)}}}function g(e){switch(e.origin){case B.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN:y(e);break;case h(i):!function(e){var n=e.data;switch(n.messageType){case"ready":p.legacyTtl=n.ttl,d=n.signinUrl,a(p)}}(e)}}var B=function(){function e(){}return e.start=function(n,t,c,d){o&&n===s&&t===i||(e.stop(),s=n,r=c,i=t,a=d,b(),i&&(u=v("sky-omnibar-iframe-legacy-keep-alive",i)),window.addEventListener("message",g,!1),o=!0)},e.stop=function(){window.removeEventListener("message",g,!1),c&&(document.body.removeChild(c),c=void 0),u&&(document.body.removeChild(u),u=void 0),p={},o=s=r=i=d=a=void 0},e.IDENTITY_SECURITY_TOKEN_SERVICE_ORIGIN=m.BBAuthDomain.getSTSDomain(),e}();n.BBOmnibarUserSessionWatcher=B},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a=t(3),s=t(4);function c(e){if(s.BBAuthInterop.messageIsFromOmnibar(e))switch(e.data.messageType){case"ready":s.BBAuthInterop.postOmnibarMessage(i,{messageType:"host-ready"}),i.classList.add("sky-omnibar-inactivity-iframe-ready");break;case"session-renew":r()}}var u=function(){function e(){}return e.show=function(n){var t;this.hide(),r=n.sessionRenewCallback,o=a.BBAuthDomUtility.addCss("\n .sky-omnibar-inactivity-iframe {\n background-color: transparent;\n border: none;\n position: fixed;\n top: 0;\n left: 0;\n height: 100%;\n width: 100%;\n z-index: 100000;\n visibility: hidden;\n }\n\n .sky-omnibar-inactivity-iframe-ready {\n visibility: visible;\n }\n "),t=e.url,i=a.BBAuthDomUtility.addIframe(t,"sky-omnibar-inactivity-iframe","Inactivity Prompt"),window.addEventListener("message",c)},e.hide=function(){i&&(a.BBAuthDomUtility.removeEl(i),a.BBAuthDomUtility.removeCss(o),i=o=r=void 0,window.removeEventListener("message",c))},e.url="https://host.nxt.blackbaud.com/omnibar/inactivity",e}();n.BBOmnibarUserActivityPrompt=u},function(e,n,t){"use strict";var o=this&&this.__awaiter||function(e,n,t,o){return new(t||(t=Promise))((function(i,r){function a(e){try{c(o.next(e))}catch(e){r(e)}}function s(e){try{c(o.throw(e))}catch(e){r(e)}}function c(e){e.done?i(e.value):new t((function(n){n(e.value)})).then(a,s)}c((o=o.apply(e,n||[])).next())}))},i=this&&this.__generator||function(e,n){var t,o,i,r,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function s(r){return function(s){return function(r){if(t)throw new TypeError("Generator is already executing.");for(;a;)try{if(t=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return a.label++,{value:r[1],done:!1};case 5:a.label++,o=r[1],r=[0];continue;case 7:r=a.ops.pop(),a.trys.pop();continue;default:if(!(i=(i=a.trys).length>0&&i[i.length-1])&&(6===r[0]||2===r[0])){a=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){a.label=r[1];break}if(6===r[0]&&a.label<i[1]){a.label=i[1],i=r;break}if(i&&a.label<i[2]){a.label=i[2],a.ops.push(r);break}i[2]&&a.ops.pop(),a.trys.pop();continue}r=n.call(e,a)}catch(e){r=[6,e],o=0}finally{t=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,s])}}};Object.defineProperty(n,"__esModule",{value:!0});var r,a=t(0),s=t(8),c=function(){function e(){}return e.connect=function(e,n,t){return o(this,void 0,void 0,(function(){return i(this,(function(o){return r||(r=window.BBNotificationsClient?Promise.resolve():s.BBOmnibarScriptLoader.registerScript(this.NOTIFICATIONS_CLIENT_URL)),[2,r.then((function(){BBNotificationsClient.BBNotifications.init({tokenCallback:function(){return a.BBAuth.getToken({disableRedirect:!0,envId:n,leId:e})}}),BBNotificationsClient.BBNotifications.addListener(t)}))]}))}))},e.disconnect=function(){return o(this,void 0,void 0,(function(){return i(this,(function(e){return r?[2,r.then((function(){BBNotificationsClient.BBNotifications.destroy(),r=void 0}))]:[2,Promise.resolve()]}))}))},e.updateNotifications=function(e){BBNotificationsClient.BBNotifications.updateNotifications(e)},e.NOTIFICATIONS_CLIENT_URL="https://sky.blackbaudcdn.net/static/notifications-client/1/notifications-client.global.min.js",e}();n.BBOmnibarPushNotifications=c},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o,i,r,a,s,c,u=t(6),d=t(3),l=t(4),f="sky-omnibar-toast-container",m=f+"-ready",p=f+"-empty",h=20;function v(){return i||(o=d.BBAuthDomUtility.addCss("\n."+f+" {\n border: none;\n display: none;\n position: fixed;\n right: 0px;\n height: 0px;\n width: 300px;\n /* z-index is 1 less than omnibar so menus will display over top the toast container */\n z-index: 999;\n}\n\n."+m+" {\n display: block;\n}\n\n."+p+" {\n visibility: hidden;\n}\n"),(i=document.createElement("iframe")).src=B.CONTAINER_URL,i.className=f+" "+p,i.title="Toast container",document.body.appendChild(i),window.addEventListener("message",g)),i}function b(e){var n=document.querySelector(e);return n?n.getBoundingClientRect().height:0}function y(){i&&l.BBAuthInterop.postOmnibarMessage(i,{href:c,messageType:"location-change"})}function g(e){if(l.BBAuthInterop.messageIsFromToastContainer(e)){var n,t,o=e.data;switch(o.messageType){case"toast-ready":l.BBAuthInterop.postOmnibarMessage(i,{messageType:"host-ready"}),l.BBAuthInterop.postOmnibarMessage(i,{envId:s.envId,leId:s.leId,messageType:"nav-ready",svcId:s.svcId}),y(),i.classList.add(m),a();break;case"get-token":n=o.tokenRequestId,t=o.disableRedirect,u.BBAuth.getToken({disableRedirect:t}).then((function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"token",token:e,tokenRequestId:n})}),(function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"token-fail",reason:e,tokenRequestId:n})}));break;case"navigate-url":s.navigateUrlCallback(o.url);break;case"navigate":s.navigateCallback(o.navItem);break;case"toast-container-change":o.height>0?(i.style.height=o.height+"px",i.style.top=b(".sky-omnibar-iframe")+b(".sky-omnibar-environment")+h+"px",i.classList.remove(p)):i.classList.add(p);break;case"push-notifications-open":s.openMenuCallback()}}}var B=function(){function e(){}return e.init=function(e){return s=e,c=e.url,r||(r=new Promise((function(e){a=e,v()}))),r},e.showNewNotifications=function(e){l.BBAuthInterop.postOmnibarMessage(i,{messageType:"push-notifications-update",pushNotifications:e})},e.updateUrl=function(e){c=e,y()},e.destroy=function(){o&&d.BBAuthDomUtility.removeCss(o),i&&d.BBAuthDomUtility.removeEl(i),c=i=s=r=a=o=void 0,window.removeEventListener("message",g)},e.CONTAINER_URL="https://host.nxt.blackbaud.com/omnibar/toast",e}();n.BBOmnibarToastContainer=B},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var o=t(8);function i(){return window.jQuery}var r=function(){function e(){}return e.load=function(e){return new Promise((function(n){var t=i(),r=t&&t.fn&&t.fn.jquery;o.BBOmnibarScriptLoader.smartRegisterScript("https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.0/jquery.js","2.1.0",r).then((function(){return o.BBOmnibarScriptLoader.registerScript("https://cdnjs.cloudflare.com/ajax/libs/easyXDM/2.4.17.1/easyXDM.min.js")})).then((function(){return o.BBOmnibarScriptLoader.registerScript("https://signin.blackbaud.com/Omnibar.min.js")})).then((function(){document.body.classList.add("bb-omnibar-height-padding");var t=document.createElement("div");t.setAttribute("data-omnibar-el",""),document.body.appendChild(t),(e=e||{})["z-index"]=1e3,e.afterLoad=n,e.menuEl&&(e.menuEl=i()(e.menuEl)),BBAUTH.Omnibar.load(t,e)}))}))},e}();n.BBOmnibarLegacy=r},function(e,n,t){"use strict";Object.defineProperty(n,"__esModule",{value:!0})}])})); |
@@ -0,1 +1,5 @@ | ||
# 2.28.0 (2020-07-10) | ||
- Added additional domain to the auth domain whitelist. [#148](https://github.com/blackbaud/auth-client/pull/148) (Thanks @Blackbaud-VeehaKhanna) | ||
# 2.27.0 (2020-07-01) | ||
@@ -2,0 +6,0 @@ |
{ | ||
"name": "@blackbaud/auth-client", | ||
"version": "2.27.0", | ||
"version": "2.28.0", | ||
"description": "Provides methods for obtaining an authentication token from the Blackbaud authentication service.", | ||
@@ -5,0 +5,0 @@ "main": "dist/bundles/auth-client.umd.js", |
@@ -6,3 +6,5 @@ "use strict"; | ||
'blackbaudfaith.com': 'https://sts.blackbaudfaith.com', | ||
'blackbaudhosting.com': 'https://sts.blackbaudhosting.com', | ||
'donorcentral.com': 'https://sts-dc.donorcentral.com', | ||
'etapestry.com': 'https://sts.etapestry.com', | ||
'mycampus-app.com': 'https://sts-sso.mycampus-app.com', | ||
@@ -9,0 +11,0 @@ 'myschoolapp.com': 'https://sts-sso.myschoolapp.com', |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
674796
11356