appboy-web-sdk v3.5.0 -> v3.5.1 (#905)

This commit is contained in:
nobody 2022-03-25 06:07:27 +01:00
parent e705c86fd0
commit 3f280c3135
No known key found for this signature in database
GPG Key ID: 8F6DE3D614FCFD7A
4 changed files with 10 additions and 9 deletions

View File

@ -1716,7 +1716,7 @@ https://cdn.jsdelivr.net/g/algoliasearch@3(algoliasearchLite.min.js),algoliasear
https://cdn.jsdelivr.net/npm/anchor-js@3.2.2/anchor.min.js
https://cdn.jsdelivr.net/npm/anchor-js@4.3.1/anchor.min.js
https://cdn.jsdelivr.net/npm/angular-stripe-checkout@5.1.0/angular-stripe-checkout.min.js
https://cdn.jsdelivr.net/npm/appboy-web-sdk@3.5.0/appboy.min.js
https://cdn.jsdelivr.net/npm/appboy-web-sdk@3.5.1/appboy.min.js
https://cdn.jsdelivr.net/npm/chart.js@3.7.1/dist/chart.min.js
https://cdn.jsdelivr.net/npm/docsify-themeable@0.8.6/dist/css/theme-defaults.css
https://cdn.jsdelivr.net/npm/docsify-themeable@0.8.6/dist/css/theme-simple.css

View File

@ -122,7 +122,7 @@ targets.setLastVersion = function (type, version) {
if (type.startsWith('/angular-material/1.') || type.startsWith('/angular-material/0.')) return '1.2.4';
if (type.startsWith('/angular-translate/2.')) return '2.19.0';
if (type.startsWith('/aos/2.')) return '2.3.4';
if (type.startsWith('/appboy-web-sdk/3.')) return '3.5.0';
if (type.startsWith('/appboy-web-sdk/3.')) return '3.5.1';
if (type.startsWith('/asciinema-player/2.')) return '2.6.1';
if (type.startsWith('/axios/0.')) return '0.26.1';
if (type.startsWith('/backbone.js/0.')) return '0.9.10';

View File

@ -29,6 +29,7 @@
<ul>
<li>font-awesome v6.1.0 -> v6.1.1 (<a href="https://codeberg.org/nobody/LocalCDN/issues/903">#903</a>)</li>
<li>jquery-migrate v3.3.2 -> v3.4.0 (<a href="https://codeberg.org/nobody/LocalCDN/issues/904">#904</a>)</li>
<li>appboy-web-sdk v3.5.0 -> v3.5.1 (<a href="https://codeberg.org/nobody/LocalCDN/issues/905">#905</a>)</li>
</ul>
</div>
<div id="generator-section">

View File

@ -1,8 +1,8 @@
/*
* Braze Web SDK v3.5.0
* Braze Web SDK v3.5.1
* (c) Braze, Inc. 2022 - http://braze.com
* License available at https://github.com/Appboy/appboy-web-sdk/blob/master/LICENSE
* Compiled on 2022-02-02
* Compiled on 2022-03-24
*/
(function(){(function(b,a){if("function"===typeof define&&define.amd)define([],a);else if("object"===typeof module&&module.exports){var e = a();module.exports=e;module.exports.default=e}else if(b.appboy){var d=a(),c;for(c in d)b.appboy[c]=d[c]}else b.appboy=a()})("undefined"!==typeof self?self:this,function(){var appboyInterface={};var p;function aa(a){var b=0;return function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}}}function ba(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterator];return b?b.call(a):{next:aa(a)}}var ca="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},da="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(a==Array.prototype||a==Object.prototype)return a;a[b]=c.value;return a};
function ea(a){a=["object"==typeof globalThis&&globalThis,a,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var b=0;b<a.length;++b){var c=a[b];if(c&&c.Math==Math)return c}throw Error("Cannot find global object");}var fa=ea(this);function ha(a,b){if(b)a:{var c=fa;a=a.split(".");for(var d=0;d<a.length-1;d++){var e=a[d];if(!(e in c))break a;c=c[e]}a=a[a.length-1];d=c[a];b=b(d);b!=d&&null!=b&&da(c,a,{configurable:!0,writable:!0,value:b})}}var ia;
@ -25,7 +25,7 @@ typeof d&&d())},d):"function"===typeof d&&d()}function va(a,b,c){sa(a)&&ta(a,fun
function wa(a,b,c){sa(a)&&ta(a,function(d){if(d.objectStoreNames.contains(b)){var e=d.transaction([b],"readwrite").objectStore(b);d=e.openCursor();var f=[];d.onerror=function(){0<f.length?(a.F.info("Cursor closed midway through for "+b+" on indexedDB "+a.C.P),c(f)):a.F.error("Could not open cursor for "+b+" on indexedDB "+a.C.P)};d.onsuccess=function(g){var h=g.target.result;null!=h?(null!=h.value&&null!=h.key&&(e["delete"](h.key).onsuccess=function(){f.push(h.value)}),h.continue()):0<f.length&&c(f)}}else a.F.error("Could not retrieve objects from "+
b+" on indexedDB "+a.C.P+" - "+b+" is not a valid objectStore")})}
qa.prototype.clearData=function(){if(!sa(this))return!1;var a=[],b;for(b in this.C.G)this.C.G.hasOwnProperty(b)&&this.C.G[b]!==this.C.G.xb&&a.push(this.C.G[b]);var c=this;return ta(this,function(d){d=d.transaction(a,"readwrite");for(var e=0;e<a.length;e++)d.objectStore(a[e]).clear().onerror=function(){c.F.error("Could not clear "+this.source.name+" on indexedDB "+c.C.P)};d.onerror=function(){c.F.error("Could not clear object stores on indexedDB "+c.C.P)}})};var xa={Gd:function(a){if(void 0!==a||void 0===xa.Ea)xa.Ea=!!a;xa.He||(xa.He=!0)},Jb:function(){xa.He=!1;xa.Ea=void 0;xa.F=void 0},Td:function(a){"function"!==typeof a?xa.info("Ignoring setLogger call since logger is not a function"):(xa.Gd(),xa.F=a)},Yd:function(){xa.Gd();xa.Ea?(console.log("Disabling Appboy logging"),xa.Ea=!1):(console.log("Enabled Appboy logging"),xa.Ea=!0)},info:function(a){xa.Ea&&(a="Appboy: "+a,null!=xa.F?xa.F(a):console.log(a))},warn:function(a){xa.Ea&&(a="Appboy SDK Warning: "+
a+" (v3.5.0)",null!=xa.F?xa.F(a):console.warn(a))},error:function(a){xa.Ea&&(a="Appboy SDK Error: "+a+" (v3.5.0)",null!=xa.F?xa.F(a):console.error(a))}};var z={CustomEvent:"ce",eg:"p",sg:"pc",$h:"ca",fg:"i",Yc:"ie",Jf:"cci",Lf:"ccic",Hf:"ccc",If:"ccd",ve:"ss",yg:"se",dg:"si",ke:"sc",je:"sbc",cg:"sfe",Mf:"iec",lg:"lr",Df:"uae",Gf:"ci",Ff:"cc",jg:"lcaa",kg:"lcar",Of:"inc",Nf:"add",Pf:"rem",Qf:"set",zg:"sgu"},ya={$f:"feed_displayed",Kf:"content_cards_displayed"},za={ba:{P:"AppboyServiceWorkerAsyncStorage",VERSION:6,G:{Rf:"data",oe:"pushClicks",gd:"pushSubscribed",Yh:"fallbackDevice",Ef:"cardUpdates",xb:"optOut",me:"pendingData",qe:"sdkAuthenticationSignature"},
a+" (v3.5.1)",null!=xa.F?xa.F(a):console.warn(a))},error:function(a){xa.Ea&&(a="Appboy SDK Error: "+a+" (v3.5.1)",null!=xa.F?xa.F(a):console.error(a))}};var z={CustomEvent:"ce",eg:"p",sg:"pc",$h:"ca",fg:"i",Yc:"ie",Jf:"cci",Lf:"ccic",Hf:"ccc",If:"ccd",ve:"ss",yg:"se",dg:"si",ke:"sc",je:"sbc",cg:"sfe",Mf:"iec",lg:"lr",Df:"uae",Gf:"ci",Ff:"cc",jg:"lcaa",kg:"lcar",Of:"inc",Nf:"add",Pf:"rem",Qf:"set",zg:"sgu"},ya={$f:"feed_displayed",Kf:"content_cards_displayed"},za={ba:{P:"AppboyServiceWorkerAsyncStorage",VERSION:6,G:{Rf:"data",oe:"pushClicks",gd:"pushSubscribed",Yh:"fallbackDevice",Ef:"cardUpdates",xb:"optOut",me:"pendingData",qe:"sdkAuthenticationSignature"},
kb:1}},x=xa,C={Af:"allowCrawlerActivity",Rc:"baseUrl",ng:"noCookies",ee:"devicePropertyAllowlist",Vc:"devicePropertyWhitelist",Wf:"disablePushTokenMaintenance",Yf:"enableLogging",Zf:"enableSdkAuthentication",mg:"manageServiceWorkerExternally",ag:"minimumIntervalBetweenTriggerActionsInSeconds",xg:"sessionTimeoutInSeconds",Cf:"appVersion",wg:"serviceWorkerLocation",ug:"safariWebsitePushId",cd:"localization",be:"contentSecurityNonce",fe:"enableHtmlInAppMessages",Zd:"allowUserSuppliedJavascript",bg:"inAppMessageZIndex",
pg:"openInAppMessagesInNewTab",qg:"openNewsFeedCardsInNewTab",tg:"requireExplicitInAppMessageDismissal",Xf:"doNotLoadFontAwesome",re:"sdkFlavor",$c:"language",og:"openCardsInNewTab"};function Aa(a,b,c,d){a=Ba(a);return-1===a.indexOf(b)?(x.error(c+" Valid values from "+d+' are "'+a.join('"/"')+'".'),!1):!0}function Ca(a){return Array.isArray?Array.isArray(a):"[object Array]"===Object.prototype.toString.call(a)}function Da(a){return"[object Date]"===Object.prototype.toString.call(a)}function Ea(a){return"[object Object]"===Object.prototype.toString.call(a)}
function Fa(a){null==a&&(a=[]);for(var b=[],c=arguments.length,d=0,e=a.length;d<e;d++){var f=a[d];if(-1===b.indexOf(f)){var g;for(g=1;g<c&&-1!==arguments[g].indexOf(f);g++);g===c&&b.push(f)}}return b}function Ga(a){var b=[],c;for(c in a)a.hasOwnProperty(c)&&b.push(c);return b}function Ba(a){var b=[],c;for(c in a)a.hasOwnProperty(c)&&void 0!==a[c]&&b.push(a[c]);return b}
@ -210,7 +210,7 @@ c)):q&&Ca(q)?ef(d,h,g,l,b,c):null==m?(x.info("No push subscription creation date
g)})},function(){var g="Permission for push notifications was ignored.";d.Ka()&&(g+=" The browser has automatically blocked further permission requests for a period (probably 1 week).");x.info(g);"function"===typeof c&&c(!0)},function(){x.info("Permission for push notifications was denied.");"function"===typeof c&&c(!1)})}}else this.vd&&(null==a||""===a?x.error("You must supply the safariWebsitePushId argument in order to use registerAppboyPushMessages on Safari"):(e=window.safari.pushNotification.permission(a),
jf(this,a,e,b,c)));else x.info(this.ed)};
p.unsubscribe=function(a,b){var c=this;this.qa()?this.vc?navigator.serviceWorker.getRegistration().then(function(d){d&&d.pushManager.getSubscription().then(function(e){e&&(c.Fa.Sb(!0),e.unsubscribe().then(function(f){f?(x.info("Device successfully unsubscribed from push."),"function"===typeof a&&a()):(x.error("Failed to unsubscribe device from push."),"function"===typeof b&&b());c.rd||(d.unregister(),x.info("Service worker successfully unregistered."))}).catch(function(f){x.error("Push unsubscription error: "+f);
"function"===typeof b&&b()}))}).catch(function(e){x.error("Error unsubscribing from push: "+e);"function"===typeof b&&b()})}):this.vd&&(this.Fa.Sb(!0),x.info("Device unsubscribed from push."),"function"===typeof a&&a()):x.info(this.ed)};function Je(a,b,c,d,e,f,g){this.Nb=a||0;this.cf=b||[];this.Ve=c||[];this.mf=d||[];this.Ld=e;if(null==e||""===e)this.Ld=null;this.ra=f||null;this.Hb=g||{}}Je.prototype.A=function(){return{s:"3.5.0",l:this.Nb,e:this.cf,a:this.Ve,p:this.mf,m:this.Ld,v:this.ra,c:this.Hb}};function mf(a){this.b=a;this.xd=new Nb;this.Ae=new Nb;this.uc=null}function Ie(a){if(null==a.uc){var b=S(a.b,M.te);if(null!=b){var c=b.l;"3.5.0"!==b.s&&(c=0);b=new Je(c,b.e,b.a,b.p,b.m,b.v,b.c)}else b=new Je;a.uc=b}return a.uc}function lf(a,b){b=Ob(a.xd,b);a.Be&&a.xd.N(a.Be);a.Be=b}function nf(a,b){Ob(a.Ae,b)}function ib(a,b){return-1!==Ie(a).Ve.indexOf(b)};function of(a,b,c,d){this.b=a;this.f=b;this.J=c;this.Cb=1E3;d=parseFloat(d);isNaN(d)&&(d=1800);d<this.Cb/1E3&&(x.info("Specified session timeout of "+d+"s is too small, using the minimum session timeout of "+this.Cb/1E3+"s instead."),d=this.Cb/1E3);this.Lg=d}function Te(a,b,c){return new E(a.f.o(),z.yg,b,c.ia,{d:Ia(b-c.Ib)})}of.prototype.Kb=function(){var a=zb(this.b,Cb.Ta);return null==a?null:a.ia};
"function"===typeof b&&b()}))}).catch(function(e){x.error("Error unsubscribing from push: "+e);"function"===typeof b&&b()})}):this.vd&&(this.Fa.Sb(!0),x.info("Device unsubscribed from push."),"function"===typeof a&&a()):x.info(this.ed)};function Je(a,b,c,d,e,f,g){this.Nb=a||0;this.cf=b||[];this.Ve=c||[];this.mf=d||[];this.Ld=e;if(null==e||""===e)this.Ld=null;this.ra=f||null;this.Hb=g||{}}Je.prototype.A=function(){return{s:"3.5.1",l:this.Nb,e:this.cf,a:this.Ve,p:this.mf,m:this.Ld,v:this.ra,c:this.Hb}};function mf(a){this.b=a;this.xd=new Nb;this.Ae=new Nb;this.uc=null}function Ie(a){if(null==a.uc){var b=S(a.b,M.te);if(null!=b){var c=b.l;"3.5.1"!==b.s&&(c=0);b=new Je(c,b.e,b.a,b.p,b.m,b.v,b.c)}else b=new Je;a.uc=b}return a.uc}function lf(a,b){b=Ob(a.xd,b);a.Be&&a.xd.N(a.Be);a.Be=b}function nf(a,b){Ob(a.Ae,b)}function ib(a,b){return-1!==Ie(a).Ve.indexOf(b)};function of(a,b,c,d){this.b=a;this.f=b;this.J=c;this.Cb=1E3;d=parseFloat(d);isNaN(d)&&(d=1800);d<this.Cb/1E3&&(x.info("Specified session timeout of "+d+"s is too small, using the minimum session timeout of "+this.Cb/1E3+"s instead."),d=this.Cb/1E3);this.Lg=d}function Te(a,b,c){return new E(a.f.o(),z.yg,b,c.ia,{d:Ia(b-c.Ib)})}of.prototype.Kb=function(){var a=zb(this.b,Cb.Ta);return null==a?null:a.ia};
function He(a){var b=(new Date).valueOf(),c=Ie(a.J).Ld,d=S(a.b,M.hc);if(null!=d&&null==c)return!1;(c=null==d||b-d>1E3*c)&&O(a.b,M.hc,b);return c}
function ab(a){var b=(new Date).valueOf(),c=b+1E3*a.Lg,d=zb(a.b,Cb.Ta);if(null==d||(b-d.Ib<a.Cb?0:d.Cd<b)){var e="Generating session start event with time "+b;if(null!=d){var f=d.Ob;f-d.Ib<a.Cb&&(f=d.Ib+a.ai);d=Te(a,f,d);null==d||bb(a.b,[d]);e+=" (old session ended "+f+")"}e+=". Will expire "+c.valueOf();x.info(e);c=new Oa(pa.Ia(),c);e=new E(a.f.o(),z.ve,b,c.ia);null==e||bb(a.b,[e]);xb(a.b,Cb.Ta,c);null==S(a.b,M.hc)&&O(a.b,M.hc,b);return c.ia}d.Ob=b;d.Cd=c;xb(a.b,Cb.Ta,d);return d.ia};function pf(a,b){var c=!1;try{if(localStorage&&localStorage.getItem)try{localStorage.setItem(M.jd,!0),localStorage.getItem(M.jd)&&(localStorage.removeItem(M.jd),c=!0)}catch(e){if(("QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0<localStorage.length)c=!0;else throw e;}}catch(e){x.info("Local Storage not supported!")}var d=navigator.cookieEnabled||"cookie"in document&&(0<document.cookie.length||-1<(document.cookie="test").indexOf.call(document.cookie,"test"));b=new Mb(a,d&&!b,
c);return new wb(b,c?new Hb(a):new Lb)};function qf(a,b){this.J=a;this.b=b}qf.prototype.o=function(){var a=zb(this.b,Cb.lc);if(null==a)return null;var b=a.ia,c=Pa(b);if(997<c){for(;997<c;)b=b.slice(0,b.length-1),c=Pa(b);a.ia=b;xb(this.b,Cb.lc,a)}return b};qf.prototype.Sd=function(a,b){if(ib(this.J,a))return x.info('Custom Attribute "'+a+'" is blocklisted, ignoring.'),!1;var c={};c[a]=b;return cb(this,"custom",c)};function cb(a,b,c){return Fb(a.b,a.o(),b,c)}
@ -237,13 +237,13 @@ switch(b.type){case ve.Xc:var l=Ec(b.data);if(null==l){x.error("Could not parse
Bf.prototype.pa=function(a,b,c){var d=this;if(Aa(de,a,"Cannot fire trigger action.","TriggerEvents"))if(0<this.H.lb)x.info("Trigger sync is currently in progress, awaiting sync completion before firing trigger event."),this.oc.push(arguments);else{(S(this.b,M.md)||0)>this.wd?Cf(this):Ef(this);for(var e=(new Date).valueOf(),f=e-this.Ba,g=!0,h=!0,l=[],k=0;k<this.T.length;k++){var m=this.T[k],q=e+1E3*m.ab;if((null==m.Ca||m.Rb!==se&&q-m.Ca>=1E3*m.Rb)&&(null==m.startTime||m.startTime<=e)&&(null==m.endTime||
m.endTime>=e)){for(var v=!1,t=0;t<m.ob.length;t++)if(fe(m.ob[t],a,b)){v=!0;break}v&&(g=!1,Hf(this,m,q,a)&&(h=!1,l.push(m)))}}if(g)x.info("Trigger event "+a+" did not match any trigger conditions.");else if(h)x.info("Ignoring "+a+" trigger event because a trigger was displayed "+f/1E3+"s ago.");else{l.sort(function(r,F){return r.priority-F.priority});var w=l.pop();null!=w&&(x.info("Firing "+w.type+" trigger action "+w.id+" from trigger event "+a+"."),Gf(this,w,e,a,c,l),0===w.ab?Ff(this,w,e,a,c,l):
this.na.push(setTimeout(function(){Ff(d,w,e,a,c,l)},1E3*w.ab)))}}};Bf.prototype.$a=function(a){this.T=[];Bb(this.b,M.kd);if(!a){this.oc=[];this.Ba=null;this.Y={};this.L={};for(a=0;a<this.na.length;a++)clearTimeout(this.na[a]);this.na=[];Bb(this.b,M.ad);Bb(this.b,M.fc);Bb(this.b,M.zb);Bb(this.b,M.hg);Bb(this.b,M.gg);Bb(this.b,M.ig)}};Bf.prototype.clearData=function(){this.T=[];this.Ba=null;this.Y={};this.L={};for(var a=0;a<this.na.length;a++)clearTimeout(this.na[a]);this.na=[]};
function Hf(a,b,c,d){if(null==a.Ba)return!0;if(d===de.V)return x.info("Ignoring minimum interval between trigger because it is a test type."),!0;b=b.kf;null==b&&(b=a.Ig);return c-a.Ba>=1E3*b}function Gf(a,b,c,d,e,f){Ef(a);a.L[b.id]=a.L[b.id]||[];var g={};g.Ec=c;g.wf=d;var h;null!=e&&(h=e.A());g.yd=h;c=[];for(d=0;d<f.length;d++)c.push(f[d].id);g.Dd=c;a.L[b.id].push(g);O(a.b,M.zb,a.L)};var If={GOOGLE_TAG_MANAGER:"gg",MPARTICLE:"mp",SEGMENT:"sg",TEALIUM:"tl",MANUAL:"manu",NPM:"npm",CDN:"wcd"};J.BrazeSdkMetadata=If;"undefined"===typeof console&&(window.console={log:function(){}});var Jf=window.Element.prototype;"function"!==typeof Jf.matches&&(Jf.matches=Jf.msMatchesSelector||Jf.mozMatchesSelector||Jf.webkitMatchesSelector||function(a){a=(this.document||this.ownerDocument).querySelectorAll(a);for(var b=0;a[b]&&a[b]!==this;)++b;return!!a[b]});
function Hf(a,b,c,d){if(null==a.Ba)return!0;if(d===de.V)return x.info("Ignoring minimum interval between trigger because it is a test type."),!0;b=b.kf;null==b&&(b=a.Ig);return c-a.Ba>=1E3*b}function Gf(a,b,c,d,e,f){Ef(a);a.L[b.id]=a.L[b.id]||[];var g={};g.Ec=c;g.wf=d;var h;null!=e&&(h=e.A());g.yd=h;c=[];for(d=0;d<f.length;d++)c.push(f[d].id);g.Dd=c;a.L[b.id].push(g);O(a.b,M.zb,a.L)};var If={GOOGLE_TAG_MANAGER:"gg",MPARTICLE:"mp",SEGMENT:"sg",TEALIUM:"tl",MANUAL:"manu",NPM:"npm",CDN:"wcd",SHOPIFY:"shp"};J.BrazeSdkMetadata=If;"undefined"===typeof console&&(window.console={log:function(){}});var Jf=window.Element.prototype;"function"!==typeof Jf.matches&&(Jf.matches=Jf.msMatchesSelector||Jf.mozMatchesSelector||Jf.webkitMatchesSelector||function(a){a=(this.document||this.ownerDocument).querySelectorAll(a);for(var b=0;a[b]&&a[b]!==this;)++b;return!!a[b]});
Element.prototype.closest||(Element.prototype.closest=function(a){var b=this;if(!document.documentElement.contains(b))return null;do{if(b.matches(a))return b;b=b.parentElement||b.parentNode}while(null!==b&&1===b.nodeType);return null});
if("function"!==typeof window.CustomEvent){var Kf=function(a,b){b=b||{bubbles:!1,cancelable:!1,detail:null};var c=document.createEvent("CustomEvent");c.initCustomEvent(a,b.bubbles,b.cancelable,b.detail);return c};Kf.prototype=window.Event.prototype;window.CustomEvent=Kf};var Lf;"object"===typeof module&&module.exports?Lf=module.exports:(window.appboy||(window.appboy={}),Lf=window.appboy);var Mf=Lf;var X=new function(a){function b(n,u,y){n="The '"+n+"' "+u+" is deprecated.";y&&(n+=" Please use '"+y+"' instead.");x.warn(n)}function c(){x.Jb();V&&(Pb(L),L.K(),w.clearData(!1),w=null,D.clearData(!1),D=null,t.K(),t=null,G.K(),G=null,r.K(),r=null,q.K(),q=null,k.Jb(),H=k=null,af(A),m=f=h=A=null,I=[],l=null);Q=V=!1}function d(){if(Q)return!1;if(!V)throw Error("Appboy must be initialized before calling methods.");return!0}var e={Ug:function(n,u,y){return new rf(n,u,y)},Wg:function(n,u){return new Ze(n,
u)},$g:function(n,u,y,B,P,R,Y,Db,Xa,Rf){null==P&&(P={});var Ee=new qf(Xa,Y),Sf=new of(Y,Ee,Xa,P[C.xg]);return new ye(n,y,B,P[C.Cf],u,Sf,Db,Ee,Xa,Y,R,Rf)},Bc:function(){return new Nb},Xg:function(n,u){return new yf(n,u)},Vg:function(n,u,y,B){return new tf(n,u,y,B)},ah:function(n,u,y,B){return new Bf(n,u,y,B)},Zg:function(n,u,y,B,P,R,Y){null==P&&(P={});return new cf(n,u,y,B+"/safari/"+u,P[C.wg],P[C.ug],R,P[C.mg],P[C.Wf],Y)},Yg:function(n){return new $e(n)}};null==a&&(a=e);var f,g,h,l,k,m,q,v,t,w,r,
F,D,G,H,A,N=new Nb,L=new Nb,I=[],V=!1,Q=!1;return{Oh:function(n){return Ob(N,n)},Nh:function(n){return Ob(L,n)},Hd:function(n,u){if(V)return x.info("Braze has already been initialized with an API key."),!0;x.Gd(null!=u&&u[C.Yf]);if(null==n||""===n||"string"!==typeof n)return x.error("Braze requires a valid API key to be initialized."),!1;f=n;h=u||{};if(vb.lh&&!h[C.Af])return x.info("Ignoring activity from crawler bot "+navigator.userAgent),Q=!0,!1;g=u=pf(n,h[C.ng]||!1);var y=new Ib(null,!0);if(y.Z("ab.optOut"))return x.info("Ignoring all activity due to previous opt out"),
y.store("ab.optOut","This-cookie-will-expire-in-"+Jb(y)),Q=!0,!1;y=ba(Ga(h));for(var B=y.next();!B.done;B=y.next())B=B.value,-1===Ba(C).indexOf(B)&&x.warn("Ignoring unknown initialization option '"+B+"'.");y=["mparticle","wordpress","tealium"];null!=h[C.re]&&(B=h[C.re],-1!==y.indexOf(B)?l=B:x.error("Invalid sdk flavor passed: "+B));var P=[];t=a.Bc();I.push(t);w=a.Xg(t,u);P.push(w);G=a.Bc();I.push(G);y=h[C.Rc];if(null==y||""===y||"string"!==typeof y)return x.error("Braze requires a valid SDK Endpoint to be initialized. Please set the 'baseUrl' initialization option to the value of your SDK Endpoint."),
!1;y=y.replace(/(\.[a-z]+)[^\.]*$/i,"$1/api/v3");0!==y.indexOf("http")&&(y="https://"+y);B=h[C.ee]||h[C.Vc];h[C.Vc]&&b(C.Vc,"initialization option",C.ee);if(null!=B)if(Ca(B)){for(var R=[],Y=0;Y<B.length;Y++)Aa(Xe,B[Y],"devicePropertyAllowlist contained an invalid value.","DeviceProperties")&&R.push(B[Y]);B=R}else x.error("devicePropertyAllowlist must be an array. Defaulting to all properties."),B=null;v=a.Wg(u,B);B=new mf(u);q=a.Bc();m=a.Ug(u,h[C.Zf],q);I.push(q);k=a.$g(f,y,"3.5.0",l,h,
!1;y=y.replace(/(\.[a-z]+)[^\.]*$/i,"$1/api/v3");0!==y.indexOf("http")&&(y="https://"+y);B=h[C.ee]||h[C.Vc];h[C.Vc]&&b(C.Vc,"initialization option",C.ee);if(null!=B)if(Ca(B)){for(var R=[],Y=0;Y<B.length;Y++)Aa(Xe,B[Y],"devicePropertyAllowlist contained an invalid value.","DeviceProperties")&&R.push(B[Y]);B=R}else x.error("devicePropertyAllowlist must be an array. Defaulting to all properties."),B=null;v=a.Wg(u,B);B=new mf(u);q=a.Bc();m=a.Ug(u,h[C.Zf],q);I.push(q);k=a.$g(f,y,"3.5.1",l,h,
function(Db){if(V)for(var Xa=0;Xa<P.length;Xa++)P[Xa].Lb(Db)},u,v,B,m);R=h[C.ag];null==R&&(R=30);D=a.ah(R,G,u,k);P.push(D);R=!0===h[C.Zd]||!0===h[C.fe];null!=h.enableHtmlInAppMessages&&b("enableHtmlInAppMessages","initialization option","allowUserSuppliedJavascript");r=a.Bc();I.push(r);F=a.Vg(r,k,u,B,R);P.push(F);nf(B,function(){F.Na()});Se(k,function(){F.Na()});k.Hd();H=a.Zg(k.rb(),f,v,y,h,B,u);A=a.Yg(k.rb());u="Initialized ";h&&h[C.Rc]&&(u+='for the Braze backend at "'+h[C.Rc]+'" ');x.info(u+('with API key "'+
n+'".'));n=vb.language;u=!1;h&&(h[C.$c]&&(b(C.$c,"initialization option",C.cd),n=h[C.$c],u=!0),h[C.cd]&&(n=h[C.cd],u=!0));td(n,u);Pb(N,h);return V=!0},Jb:function(){x.info("Destroying appboy instance");g=null;c()},gh:function(n){d()&&(null==n&&x.error("getDeviceId must be supplied with a callback. e.g., appboy.getDeviceId(function(deviceId) {console.log('the device id is ' + deviceId)})"),"function"===typeof n&&n(Be(v).id))},Yd:function(){x.Yd()},Td:function(n){x.Td(n)},Lc:function(){if(d()){k.Lc(H);
var n=za.ba,u=new qa(n);ua(u,n.G.oe,function(y,B){function P(){D.pa(de.ne,[Y],Db)}var R=B.lastClick,Y=B.trackingString;x.info("Firing push click trigger from "+Y+" push click at "+R);var Db=We(k,R,Y);Ue(k,P,P);va(u,n.G.oe,y)});wa(u,n.G.Ef,function(y){xf(F,y)});wa(u,n.G.me,function(y){var B=k;y=ba(y);for(var P=y.next();!P.done;P=y.next())if(P=P.value,P.api_key!==B.$){var R=za.ba;(new qa(R)).setItem(R.G.me,pa.Ia(),P)}else De(B,P)})}},$a:function(n,u){if(d())if(null==n||0===n.length||n!==n)x.error("changeUser requires a non-empty userId.");
@ -262,7 +262,7 @@ u.next())if(!Aa(If,y.value,"sdkMetadata contained an invalid value.","BrazeSdkMe
Z.initialize=X.Hd;Z.destroy=X.Jb;Z.getDeviceId=X.gh;Z.toggleAppboyLogging=X.Yd;Z.setLogger=X.Td;Z.openSession=X.Lc;Z.changeUser=X.$a;Z.getUser=X.rb;Z.requestImmediateDataFlush=X.tb;Z.requestFeedRefresh=X.Nc;Z.getCachedFeed=X.Fc;Z.subscribeToFeedUpdates=X.uf;Z.requestContentCardsRefresh=X.Na;Z.getCachedContentCards=X.pb;Z.subscribeToContentCardsUpdates=X.tf;Z.logCardImpressions=X.Ma;Z.logCardClick=X.La;Z.logCardDismissal=X.Hc;Z.logFeedDisplayed=X.jf;Z.logContentCardsDisplayed=X.hf;
Z.logInAppMessageImpression=X.Qb;Z.logInAppMessageClick=X.Jc;Z.logInAppMessageButtonClick=X.Ic;Z.logInAppMessageHtmlClick=X.Pb;Z.subscribeToNewInAppMessages=X.Ph;Z.subscribeToInAppMessage=X.vf;Z.removeSubscription=X.N;Z.removeAllSubscriptions=X.K;Z.logCustomEvent=X.Jd;Z.logPurchase=X.Kd;Z.isPushSupported=X.qa;Z.isPushBlocked=X.Ka;Z.isPushGranted=X.Id;Z.isPushPermissionGranted=X.Mb;Z.registerAppboyPushMessages=X.ph;Z.unregisterAppboyPushMessages=X.Uh;Z.setSdkAuthenticationSignature=X.Tb;
Z.subscribeToSdkAuthenticationFailures=X.Xd;Z.trackLocation=X.Sh;Z.addSdkMetadata=X.zd;Z.stopWebTracking=X.Mh;Z.disableSDK=X.bh;Z.resumeWebTracking=X.vh;Z.enableSDK=X.dh;Z.wipeData=X.Xh;Z.isDisabled=X.mh;for(var Of in Z)"object"===typeof appboyInterface?appboyInterface[Of]=Z[Of]:Mf[Of]=Z[Of];var Pf="object"===typeof appboyInterface?appboyInterface:Mf,Qf=new function(a,b){var c=!1,d=!1,e=!1,f=!1,g=null,h=null,l=null,k=null;a.Oh(function(m){function q(t){if(27===t.keyCode&&!e&&0<document.querySelectorAll(".ab-modal-interactions").length){t=document.getElementsByClassName("ab-html-message");for(var w=!1,r=0;r<t.length;r++){var F=t[r].contentWindow.document.getElementsByClassName("ab-programmatic-close-button")[0];null!=F&&(Ub(F),w=!0)}w||(t=document.querySelectorAll(".ab-modal-interactions > .ab-close-button")[0],
null!=t&&Ub(t))}}c=m[C.pg]||!1;d=m[C.og]||m[C.qg]||!1;e=m[C.tg]||!1;f=m[C.fe]||!1;!0===m[C.Zd]&&(f=!0);g=null;l=m[C.be]||null;k=m[C.bg]||null;m[C.Xf]||null!==document.querySelector('link[rel=stylesheet][href="https://use.fontawesome.com/7f85a56ba4.css"]')||(m=document.createElement("link"),m.setAttribute("rel","stylesheet"),m.setAttribute("href","https://use.fontawesome.com/7f85a56ba4.css"),document.getElementsByTagName("head")[0].appendChild(m));m="ab-css-definitions-"+"3.5.0".replace(/\./g,
null!=t&&Ub(t))}}c=m[C.pg]||!1;d=m[C.og]||m[C.qg]||!1;e=m[C.tg]||!1;f=m[C.fe]||!1;!0===m[C.Zd]&&(f=!0);g=null;l=m[C.be]||null;k=m[C.bg]||null;m[C.Xf]||null!==document.querySelector('link[rel=stylesheet][href="https://use.fontawesome.com/7f85a56ba4.css"]')||(m=document.createElement("link"),m.setAttribute("rel","stylesheet"),m.setAttribute("href","https://use.fontawesome.com/7f85a56ba4.css"),document.getElementsByTagName("head")[0].appendChild(m));m="ab-css-definitions-"+"3.5.1".replace(/\./g,
"-");if(null==document.getElementById(m)){var v=document.createElement("style");v.innerHTML=qd.$e;v.id=m;null!=l&&v.setAttribute("nonce",l);document.getElementsByTagName("head")[0].appendChild(v)}e||(document.addEventListener("keydown",q,!1),a.Nh(function(){document.removeEventListener("keydown",q)}))});return{Tg:function(){null==g&&(g=a.vf(function(m){a.display.sf(m)}));return g},sf:function(m,q,v){if(null==m)return!1;if(m instanceof Fc)return x.info("User received control for a multivariate test, logging to Braze servers."),
a.Qb(m),!0;if(!(m instanceof W))return!1;var t=m instanceof Qc;if(t&&!m.Th&&!f)return x.error('HTML in-app messages are disabled. Use the "allowUserSuppliedJavascript" option for appboy.initialize to enable these messages.'),a.M(m,dd.ge),!1;null==q&&(q=document.body);if(m.Ja()&&0<q.querySelectorAll(".ab-modal-interactions").length)return x.info("Cannot show in-app message '"+m.message+"' because another message is being shown."),a.M(m,dd.Bf),!1;if(bc.nh()){var w=bc.hh();if(w===bc.Sa.jc&&m.orientation===
Zc||w===bc.Sa.Zc&&"PORTRAIT"===m.orientation)return x.info("Not showing "+("PORTRAIT"===m.orientation?"portrait":"landscape")+" in-app message '"+m.message+"' because the screen is currently "+(w===bc.Sa.jc?"portrait":"landscape")),a.M(m,dd.rg),!1}if(!f){w=!1;if(m.buttons&&0<m.buttons.length)for(var r=m.buttons,F=0;F<r.length;F++)r[F].clickAction===$c&&(w=sd(r[F].uri));else m.clickAction===$c&&(w=sd(m.uri));if(w)return x.error('Javascript click actions are disabled. Use the "allowUserSuppliedJavascript" option for appboy.initialize to enable these actions.'),