@braze/web-sdk 4.8.3 → 4.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (153) hide show
  1. package/index.d.ts +2247 -2071
  2. package/package.json +1 -1
  3. package/shared-lib/braze-shared-lib.js +7 -7
  4. package/shared-lib/encoding-utils.js +4 -4
  5. package/shared-lib/event-types.js +23 -22
  6. package/shared-lib/guid.js +7 -7
  7. package/shared-lib/indexed-db-adapter.js +172 -135
  8. package/shared-lib/logger.js +26 -26
  9. package/shared-lib/supported-options.js +14 -13
  10. package/shared-lib/types.js +1 -0
  11. package/src/Card/card-manager-factory.js +1 -1
  12. package/src/Card/card-manager.js +2 -2
  13. package/src/Card/display/card-display.js +5 -4
  14. package/src/Card/models/banner.js +10 -10
  15. package/src/Card/models/captioned-image.js +7 -7
  16. package/src/Card/models/card.js +37 -36
  17. package/src/Card/models/classic-card.js +7 -7
  18. package/src/Card/models/control-card.js +3 -3
  19. package/src/Card/models/image-only.js +32 -0
  20. package/src/Card/models/index.js +1 -0
  21. package/src/Card/util/card-factory.js +16 -16
  22. package/src/ContentCards/content-cards-provider-factory.js +1 -1
  23. package/src/ContentCards/content-cards-provider.js +102 -102
  24. package/src/ContentCards/get-cached-content-cards.js +1 -1
  25. package/src/ContentCards/request-content-cards-refresh.js +1 -1
  26. package/src/ContentCards/subscribe-to-content-cards-updates.js +4 -4
  27. package/src/ContentCards/ui/show-content-cards.js +15 -12
  28. package/src/Core/add-sdk-metadata.js +2 -2
  29. package/src/Core/braze-sdk-metadata.js +1 -1
  30. package/src/Core/change-user.js +1 -1
  31. package/src/Core/device-properties.js +1 -1
  32. package/src/Core/disable-sdk.js +10 -7
  33. package/src/Core/enable-sdk.js +5 -2
  34. package/src/Core/get-device-id.js +9 -7
  35. package/src/Core/get-user.js +1 -1
  36. package/src/Core/handle-braze-action.js +14 -14
  37. package/src/Core/is-disabled.js +1 -1
  38. package/src/Core/log-custom-event.js +4 -4
  39. package/src/Core/log-purchase.js +9 -9
  40. package/src/Core/open-session.js +10 -10
  41. package/src/FeatureFlags/feature-flag-factory.js +5 -3
  42. package/src/FeatureFlags/feature-flag.js +17 -14
  43. package/src/FeatureFlags/feature-flags-provider-factory.js +1 -1
  44. package/src/FeatureFlags/feature-flags-provider.js +56 -43
  45. package/src/FeatureFlags/get-all-feature-flags.js +2 -2
  46. package/src/FeatureFlags/get-feature-flag.js +2 -2
  47. package/src/FeatureFlags/index.js +1 -0
  48. package/src/FeatureFlags/log-feature-flag-impression.js +23 -0
  49. package/src/FeatureFlags/subscribe-to-feature-flags-updates.js +1 -1
  50. package/src/Feed/feed-provider-factory.js +1 -1
  51. package/src/Feed/feed-provider.js +20 -20
  52. package/src/Feed/get-cached-feed.js +1 -1
  53. package/src/Feed/log-feed-displayed.js +1 -1
  54. package/src/Feed/request-feed-refresh.js +1 -1
  55. package/src/Feed/subscribe-to-feed-updates.js +1 -1
  56. package/src/Feed/ui/show-feed.js +13 -10
  57. package/src/InAppMessage/defer-in-app-message.js +13 -0
  58. package/src/InAppMessage/display/get-animation-effect.js +1 -1
  59. package/src/InAppMessage/display/html-message-to-html.js +47 -47
  60. package/src/InAppMessage/display/in-app-message-to-html.js +92 -91
  61. package/src/InAppMessage/display/modal-utils.js +16 -16
  62. package/src/InAppMessage/get-deferred-in-app-message.js +5 -0
  63. package/src/InAppMessage/in-app-message-factory.js +77 -57
  64. package/src/InAppMessage/in-app-message-manager-factory.js +6 -6
  65. package/src/InAppMessage/in-app-message-manager.js +121 -82
  66. package/src/InAppMessage/index.js +2 -0
  67. package/src/InAppMessage/log-in-app-message-button-click.js +17 -9
  68. package/src/InAppMessage/log-in-app-message-click.js +4 -4
  69. package/src/InAppMessage/log-in-app-message-html-click.js +6 -6
  70. package/src/InAppMessage/log-in-app-message-impression.js +3 -3
  71. package/src/InAppMessage/models/full-screen-message.js +65 -29
  72. package/src/InAppMessage/models/html-message.js +32 -13
  73. package/src/InAppMessage/models/in-app-message-button.js +7 -7
  74. package/src/InAppMessage/models/in-app-message.js +203 -134
  75. package/src/InAppMessage/models/modal-message.js +64 -29
  76. package/src/InAppMessage/models/slide-up-message.js +52 -24
  77. package/src/InAppMessage/models/templated-in-app-message.js +8 -8
  78. package/src/InAppMessage/subscribe-to-in-app-message.js +2 -2
  79. package/src/InAppMessage/ui/automatically-show-in-app-messages.js +6 -6
  80. package/src/InAppMessage/ui/show-in-app-message.js +49 -47
  81. package/src/InAppMessage/utils/in-app-message-utils.js +1 -1
  82. package/src/Push/is-push-blocked.js +2 -2
  83. package/src/Push/is-push-permission-granted.js +2 -2
  84. package/src/Push/is-push-supported.js +2 -2
  85. package/src/Push/push-manager-factory.js +19 -19
  86. package/src/Push/push-manager.js +131 -131
  87. package/src/Push/request-push-permission.js +2 -2
  88. package/src/Push/unregister-push.js +2 -2
  89. package/src/Push/utils/push-utils.js +12 -10
  90. package/src/User/user-manager.js +4 -4
  91. package/src/User/user.js +63 -62
  92. package/src/common/base-feed.js +1 -1
  93. package/src/common/constants.js +1 -0
  94. package/src/common/event-logger.js +6 -6
  95. package/src/common/feed-display.js +34 -34
  96. package/src/common/translations.js +33 -33
  97. package/src/l10n/l10n-manager-factory.js +8 -8
  98. package/src/l10n/l10n-manager.js +6 -2
  99. package/src/l10n/types.js +1 -0
  100. package/src/managers/auth-manager.js +29 -29
  101. package/src/managers/braze-instance.js +132 -130
  102. package/src/managers/device-manager.js +22 -22
  103. package/src/managers/network-manager.js +103 -98
  104. package/src/managers/server-config-manager.js +23 -23
  105. package/src/managers/session-manager.js +5 -5
  106. package/src/managers/storage-manager-factory.js +9 -9
  107. package/src/managers/storage-manager.js +134 -131
  108. package/src/managers/subscription-manager.js +7 -7
  109. package/src/models/backend-errors.js +6 -6
  110. package/src/models/braze-event.js +11 -11
  111. package/src/models/braze-sdk-metadata.js +1 -1
  112. package/src/models/device.js +2 -2
  113. package/src/models/identifier.js +1 -1
  114. package/src/models/push-token.js +5 -5
  115. package/src/models/server-config.js +7 -7
  116. package/src/request-controller.js +197 -180
  117. package/src/triggers/models/custom-event-data.js +4 -4
  118. package/src/triggers/models/custom-event-property-data.js +7 -7
  119. package/src/triggers/models/filter-set.js +5 -5
  120. package/src/triggers/models/filter.js +65 -61
  121. package/src/triggers/models/in-app-message-click-data.js +9 -9
  122. package/src/triggers/models/purchase-data.js +4 -4
  123. package/src/triggers/models/purchase-property-data.js +6 -6
  124. package/src/triggers/models/push-click-data.js +6 -6
  125. package/src/triggers/models/trigger-condition.js +52 -56
  126. package/src/triggers/models/trigger-events.js +3 -3
  127. package/src/triggers/models/trigger.js +50 -38
  128. package/src/triggers/triggers-provider-factory.js +10 -6
  129. package/src/triggers/triggers-provider.js +204 -186
  130. package/src/triggers/types.js +1 -0
  131. package/src/ui/js/attach-css.js +5 -4
  132. package/src/ui/js/feed-css.js +5 -5
  133. package/src/ui/js/iam-css.js +5 -5
  134. package/src/util/base-device-parser.js +1 -1
  135. package/src/util/braze-actions.js +35 -30
  136. package/src/util/browser-detector.js +30 -31
  137. package/src/util/client-hints-parser.js +28 -22
  138. package/src/util/code-utils.js +22 -21
  139. package/src/util/color-utils.js +19 -13
  140. package/src/util/component-utils.js +4 -4
  141. package/src/util/date-utils.js +6 -5
  142. package/src/util/device-constants.js +10 -10
  143. package/src/util/dom-utils.js +28 -24
  144. package/src/util/error-utils.js +1 -1
  145. package/src/util/key-codes.js +1 -1
  146. package/src/util/net.js +53 -57
  147. package/src/util/request-header-utils.js +34 -11
  148. package/src/util/string-utils.js +14 -14
  149. package/src/util/types.js +1 -0
  150. package/src/util/url-utils.js +1 -4
  151. package/src/util/user-agent-parser.js +39 -39
  152. package/src/util/validation-utils.js +34 -34
  153. package/src/util/window-utils.js +11 -12
@@ -3,7 +3,7 @@ import e from "../managers/braze-instance.js";
3
3
  import Feed from "./feed.js";
4
4
  import {
5
5
  newCardFromFeedJson as ht,
6
- newCardFromSerializedValue as R
6
+ newCardFromSerializedValue as R,
7
7
  } from "../Card/util/card-factory.js";
8
8
  import { rehydrateDateAfterJsonization as w } from "../util/date-utils.js";
9
9
  import { STORAGE_KEYS as i } from "../managers/storage-manager.js";
@@ -12,26 +12,26 @@ export default class re extends y {
12
12
  constructor(t, s) {
13
13
  super(),
14
14
  (this.u = t),
15
- (this.Ci = s),
15
+ (this.ki = s),
16
16
  (this.cards = []),
17
- (this.Ui = null),
17
+ (this.Ai = null),
18
18
  (this.u = t),
19
- (this.Ci = s),
19
+ (this.ki = s),
20
20
  (this.yt = new E()),
21
21
  e.jt(this.yt),
22
22
  this.Lt();
23
23
  }
24
24
  Lt() {
25
25
  let t = [];
26
- this.u && (t = this.u.v(i.k.ki) || []);
26
+ this.u && (t = this.u.v(i.k.Bi) || []);
27
27
  const s = [];
28
28
  for (let i = 0; i < t.length; i++) {
29
29
  const e = R(t[i]);
30
30
  null != e && s.push(e);
31
31
  }
32
- (this.cards = s), this.u && (this.Ui = w(this.u.v(i.k.Ai)));
32
+ (this.cards = s), this.u && (this.Ai = w(this.u.v(i.k.Ei)));
33
33
  }
34
- Bi(t) {
34
+ Gi(t) {
35
35
  const s = [];
36
36
  let e = null,
37
37
  r = {};
@@ -47,23 +47,23 @@ export default class re extends y {
47
47
  }
48
48
  (this.cards = s),
49
49
  this.Rs(),
50
- (this.Ui = new Date()),
51
- this.u && (this.u.D(i.k.L, h), this.u.D(i.k.Ai, this.Ui));
50
+ (this.Ai = new Date()),
51
+ this.u && (this.u.D(i.k.L, h), this.u.D(i.k.Ei, this.Ai));
52
52
  }
53
53
  Rs() {
54
54
  if (!this.u) return;
55
55
  const t = [];
56
56
  for (let s = 0; s < this.cards.length; s++) t.push(this.cards[s].ss());
57
- this.u.D(i.k.ki, t);
57
+ this.u.D(i.k.Bi, t);
58
58
  }
59
59
  Ts(t) {
60
60
  null != t &&
61
61
  t.feed &&
62
62
  (this.Lt(),
63
- this.Bi(t.feed),
64
- this.yt.Et(new Feed(this.cards.slice(), this.Ui)));
63
+ this.Gi(t.feed),
64
+ this.yt.Et(new Feed(this.cards.slice(), this.Ai)));
65
65
  }
66
- Ei() {
66
+ Hi() {
67
67
  this.Lt();
68
68
  const t = [],
69
69
  s = new Date();
@@ -72,19 +72,19 @@ export default class re extends y {
72
72
  let r = !0;
73
73
  null != e && (r = e >= s), r && t.push(this.cards[i]);
74
74
  }
75
- return new Feed(t, this.Ui);
75
+ return new Feed(t, this.Ai);
76
76
  }
77
- Es() {
78
- this.Ci && this.Ci.requestFeedRefresh();
77
+ Ms() {
78
+ this.ki && this.ki.requestFeedRefresh();
79
79
  }
80
- hi(t) {
80
+ ri(t) {
81
81
  return this.yt.lt(t);
82
82
  }
83
83
  clearData(t) {
84
84
  null == t && (t = !1),
85
85
  (this.cards = []),
86
- (this.Ui = null),
87
- t && this.u && (this.u.ri(i.k.ki), this.u.ri(i.k.Ai)),
88
- this.yt.Et(new Feed(this.cards.slice(), this.Ui));
86
+ (this.Ai = null),
87
+ t && this.u && (this.u.ni(i.k.Bi), this.u.ni(i.k.Ei)),
88
+ this.yt.Et(new Feed(this.cards.slice(), this.Ai));
89
89
  }
90
90
  }
@@ -1,5 +1,5 @@
1
1
  import e from "../managers/braze-instance.js";
2
2
  import ie from "./feed-provider-factory.js";
3
3
  export function getCachedFeed() {
4
- if (e.rr()) return ie.er().Ei();
4
+ if (e.rr()) return ie.er().Hi();
5
5
  }
@@ -3,5 +3,5 @@ import r from "../../shared-lib/braze-shared-lib.js";
3
3
  export function logFeedDisplayed() {
4
4
  if (!e.rr()) return;
5
5
  const i = e.ar();
6
- return i ? i.qr(r.Cr.Ar).O : void 0;
6
+ return i ? i.qr(r.Cr.Br).O : void 0;
7
7
  }
@@ -1,5 +1,5 @@
1
1
  import e from "../managers/braze-instance.js";
2
2
  import ie from "./feed-provider-factory.js";
3
3
  export function requestFeedRefresh() {
4
- if (e.rr()) return ie.er().Es();
4
+ if (e.rr()) return ie.er().Ms();
5
5
  }
@@ -1,5 +1,5 @@
1
1
  import e from "../managers/braze-instance.js";
2
2
  import ie from "./feed-provider-factory.js";
3
3
  export function subscribeToFeedUpdates(r) {
4
- if (e.rr()) return ie.er().hi(r);
4
+ if (e.rr()) return ie.er().ri(r);
5
5
  }
@@ -6,7 +6,7 @@ import {
6
6
  LAST_REQUESTED_REFRESH_DATA_ATTRIBUTE as M,
7
7
  refreshFeed as $,
8
8
  registerFeedSubscriptionId as A,
9
- updateFeedCards as B
9
+ updateFeedCards as B,
10
10
  } from "../../common/feed-display.js";
11
11
  import { Feed, logFeedDisplayed, subscribeToFeedUpdates } from "../index.js";
12
12
  import ie from "../feed-provider-factory.js";
@@ -36,7 +36,7 @@ export function showFeed(t, n, o) {
36
36
  let a,
37
37
  f = !1;
38
38
  null == n
39
- ? ((a = ie.er().Ei()),
39
+ ? ((a = ie.er().Hi()),
40
40
  B(a, s(a.cards, o), a.lastUpdated, null, i),
41
41
  (f = !0))
42
42
  : (a = new Feed(s(n, o), new Date()));
@@ -45,11 +45,11 @@ export function showFeed(t, n, o) {
45
45
  (null == a.lastUpdated ||
46
46
  new Date().valueOf() - a.lastUpdated.valueOf() > Feed.mr) &&
47
47
  (r.j.info(
48
- `Cached feed was older than max TTL of ${Feed.mr} ms, requesting an update from the server.`
48
+ `Cached feed was older than max TTL of ${Feed.mr} ms, requesting an update from the server.`,
49
49
  ),
50
50
  $(a, u));
51
51
  const e = new Date().valueOf(),
52
- t = subscribeToFeedUpdates(function(t) {
52
+ t = subscribeToFeedUpdates(function (t) {
53
53
  const n = u.querySelectorAll(".ab-refresh-button")[0];
54
54
  if (null != n) {
55
55
  let t = 500;
@@ -59,22 +59,25 @@ export function showFeed(t, n, o) {
59
59
  const e = parseInt(o);
60
60
  isNaN(e) || (t -= new Date().valueOf() - e);
61
61
  }
62
- setTimeout(function() {
63
- n.className = n.className.replace(/fa-spin/g, "");
64
- }, Math.max(t, 0));
62
+ setTimeout(
63
+ function () {
64
+ n.className = n.className.replace(/fa-spin/g, "");
65
+ },
66
+ Math.max(t, 0),
67
+ );
65
68
  }
66
69
  B(a, s(t.cards, o), t.lastUpdated, u, i);
67
70
  });
68
71
  A(t, u);
69
72
  }
70
- const d = e => {
73
+ const d = (e) => {
71
74
  const t = e.querySelectorAll(".ab-feed");
72
75
  let n = null;
73
76
  for (let o = 0; o < t.length; o++) t[o].parentNode === e && (n = t[o]);
74
77
  null != n
75
78
  ? (k(n), n.parentNode && n.parentNode.replaceChild(u, n))
76
79
  : e.appendChild(u),
77
- setTimeout(function() {
80
+ setTimeout(function () {
78
81
  u.className = u.className.replace("ab-hide", "ab-show");
79
82
  }, 0),
80
83
  l && u.focus(),
@@ -87,7 +90,7 @@ export function showFeed(t, n, o) {
87
90
  ? d(t)
88
91
  : (window.onload =
89
92
  ((m = window.onload),
90
- function() {
93
+ function () {
91
94
  "function" == typeof m && m(new Event("oldLoad")), d(document.body);
92
95
  }));
93
96
  }
@@ -0,0 +1,13 @@
1
+ import InAppMessage from "./models/in-app-message.js";
2
+ import e from "../managers/braze-instance.js";
3
+ import ControlMessage from "./models/control-message.js";
4
+ import r from "../../shared-lib/braze-shared-lib.js";
5
+ import se from "./in-app-message-manager-factory.js";
6
+ export function deferInAppMessage(s) {
7
+ if (e.rr())
8
+ return s instanceof ControlMessage
9
+ ? (r.j.info("Not deferring since this is a ControlMessage."), !1)
10
+ : s instanceof InAppMessage
11
+ ? se.m().he(s)
12
+ : (r.j.info("Not an instance of InAppMessage, ignoring."), !1);
13
+ }
@@ -2,7 +2,7 @@ import FullScreenMessage from "../models/full-screen-message.js";
2
2
  import HtmlMessage from "../models/html-message.js";
3
3
  import ModalMessage from "../models/modal-message.js";
4
4
  import SlideUpMessage from "../models/slide-up-message.js";
5
- export default function se(e) {
5
+ export default function me(e) {
6
6
  let s = "";
7
7
  return (
8
8
  e.animateIn && (s += " ab-animate-in"),
@@ -14,10 +14,10 @@ export default function at(t, o, n, s, i, u) {
14
14
  const c = document.createElement("iframe");
15
15
  c.setAttribute("title", "Modal Message"),
16
16
  i && (c.style.zIndex = (i + 1).toString());
17
- const a = e => {
17
+ const a = (e) => {
18
18
  const o = e.getAttribute("href"),
19
19
  r = e.onclick;
20
- return n => {
20
+ return (n) => {
21
21
  if (null != r && "function" == typeof r && !1 === r.bind(e)(n)) return;
22
22
  let i = ct(o).abButtonId;
23
23
  if (
@@ -31,7 +31,7 @@ export default function at(t, o, n, s, i, u) {
31
31
  a = () => {
32
32
  logInAppMessageHtmlClick(t, i, o), Z.openUri(o, u, n);
33
33
  };
34
- u ? a() : t.he(c, a);
34
+ u ? a() : t.ye(c, a);
35
35
  } else logInAppMessageHtmlClick(t, i, o || void 0);
36
36
  return n.stopPropagation(), !1;
37
37
  };
@@ -42,7 +42,7 @@ export default function at(t, o, n, s, i, u) {
42
42
  if (n) {
43
43
  const o = `${n[1]}.setAttribute("nonce", "${e}")`;
44
44
  return `${t.slice(0, n.index + n[0].length)};${o};${t.slice(
45
- n.index + n[0].length
45
+ n.index + n[0].length,
46
46
  )}`;
47
47
  }
48
48
  return null;
@@ -59,7 +59,7 @@ export default function at(t, o, n, s, i, u) {
59
59
  o[t].setAttribute("nonce", u),
60
60
  (o[t].innerHTML = o[t].innerHTML.replace(
61
61
  /<style>/g,
62
- `<style nonce='${u}'>`
62
+ `<style nonce='${u}'>`,
63
63
  ));
64
64
  const e = m(o[t].innerHTML, u, "script");
65
65
  e && (o[t].innerHTML = e);
@@ -71,10 +71,10 @@ export default function at(t, o, n, s, i, u) {
71
71
  i.focus(), i.document.write(s ? s.innerHTML : t.message || "");
72
72
  const l = i.document.getElementsByTagName("head")[0];
73
73
  if (null != l) {
74
- if ((ut(l), t.ye())) {
74
+ if ((ut(l), t.Ae())) {
75
75
  const e = document.createElement("style");
76
76
  (e.innerHTML = t.css || ""),
77
- (e.id = t.Ae() || ""),
77
+ (e.id = t.Ce() || ""),
78
78
  null != u && e.setAttribute("nonce", u),
79
79
  l.appendChild(e);
80
80
  }
@@ -84,77 +84,77 @@ export default function at(t, o, n, s, i, u) {
84
84
  const f = i.document.getElementsByTagName("title");
85
85
  f && f.length > 0 && c.setAttribute("title", f[0].textContent || "");
86
86
  const d = {
87
- closeMessage: function() {
88
- t.he(c);
87
+ closeMessage: function () {
88
+ t.ye(c);
89
89
  },
90
- logClick: function() {
90
+ logClick: function () {
91
91
  logInAppMessageHtmlClick(t, ...arguments);
92
92
  },
93
93
  display: {},
94
- web: {}
94
+ web: {},
95
95
  },
96
- requestPushPermission = function() {
97
- return function() {
96
+ requestPushPermission = function () {
97
+ return function () {
98
98
  const t = arguments;
99
- import("../../Push/request-push-permission.js").then(o => {
100
- e.ue()
99
+ import("../../Push/request-push-permission.js").then((o) => {
100
+ e.fe()
101
101
  ? o.requestPushPermission(...Array.prototype.slice.call(t))
102
102
  : r.j.error(P);
103
103
  });
104
104
  };
105
105
  },
106
106
  p = {
107
- requestImmediateDataFlush: function() {
107
+ requestImmediateDataFlush: function () {
108
108
  const t = arguments;
109
109
  import("../../Core/request-immediate-data-flush.js").then(
110
110
  ({ requestImmediateDataFlush: requestImmediateDataFlush }) => {
111
- e.ue()
111
+ e.fe()
112
112
  ? requestImmediateDataFlush(...Array.prototype.slice.call(t))
113
113
  : r.j.error(P);
114
- }
114
+ },
115
115
  );
116
116
  },
117
- logCustomEvent: function() {
117
+ logCustomEvent: function () {
118
118
  const t = arguments;
119
119
  import("../../Core/log-custom-event.js").then(
120
120
  ({ logCustomEvent: logCustomEvent }) => {
121
- if (!e.ue()) return void r.j.error(P);
121
+ if (!e.fe()) return void r.j.error(P);
122
122
  logCustomEvent(...Array.prototype.slice.call(t));
123
- }
123
+ },
124
124
  );
125
125
  },
126
- logPurchase: function() {
126
+ logPurchase: function () {
127
127
  const t = arguments;
128
128
  import("../../Core/log-purchase.js").then(
129
129
  ({ logPurchase: logPurchase }) => {
130
- if (!e.ue()) return void r.j.error(P);
130
+ if (!e.fe()) return void r.j.error(P);
131
131
  logPurchase(...Array.prototype.slice.call(t));
132
- }
132
+ },
133
133
  );
134
134
  },
135
- unregisterPush: function() {
135
+ unregisterPush: function () {
136
136
  const t = arguments;
137
137
  import("../../Push/unregister-push.js").then(
138
138
  ({ unregisterPush: unregisterPush }) => {
139
- e.ue()
139
+ e.fe()
140
140
  ? unregisterPush(...Array.prototype.slice.call(t))
141
141
  : r.j.error(P);
142
- }
142
+ },
143
143
  );
144
144
  },
145
145
  requestPushPermission: requestPushPermission(),
146
- changeUser: function() {
146
+ changeUser: function () {
147
147
  const t = arguments;
148
148
  import("../../Core/change-user.js").then(
149
149
  ({ changeUser: changeUser }) => {
150
- if (!e.ue()) return void r.j.error(P);
150
+ if (!e.fe()) return void r.j.error(P);
151
151
  changeUser(...Array.prototype.slice.call(t));
152
- }
152
+ },
153
153
  );
154
- }
154
+ },
155
155
  },
156
- h = function(t) {
157
- return function() {
156
+ h = function (t) {
157
+ return function () {
158
158
  p[t](...Array.prototype.slice.call(arguments));
159
159
  };
160
160
  };
@@ -178,24 +178,24 @@ export default function at(t, o, n, s, i, u) {
178
178
  "incrementCustomUserAttribute",
179
179
  "setCustomLocationAttribute",
180
180
  "addToSubscriptionGroup",
181
- "removeFromSubscriptionGroup"
181
+ "removeFromSubscriptionGroup",
182
182
  ],
183
- g = function(t) {
184
- return function() {
183
+ g = function (t) {
184
+ return function () {
185
185
  const e = ee();
186
186
  e && e[t](...Array.prototype.slice.call(arguments));
187
187
  };
188
188
  },
189
189
  y = {};
190
190
  for (let t = 0; t < b.length; t++) y[b[t]] = g(b[t]);
191
- d.getUser = function() {
191
+ d.getUser = function () {
192
192
  return y;
193
193
  };
194
194
  const A = { showFeed: o },
195
- j = function(e) {
196
- return function() {
195
+ j = function (e) {
196
+ return function () {
197
197
  const o = arguments;
198
- t.he(c, function() {
198
+ t.ye(c, function () {
199
199
  A[e](...Array.prototype.slice.call(o));
200
200
  });
201
201
  };
@@ -203,15 +203,15 @@ export default function at(t, o, n, s, i, u) {
203
203
  C = d.display;
204
204
  for (const t of oo(A)) C[t] = j(t);
205
205
  const v = { registerAppboyPushMessages: requestPushPermission() },
206
- w = function(t) {
207
- return function() {
206
+ w = function (t) {
207
+ return function () {
208
208
  v[t](...Array.prototype.slice.call(arguments));
209
209
  };
210
210
  },
211
211
  E = d.web;
212
212
  for (const t of oo(v)) E[t] = w(t);
213
213
  if (
214
- ((i.appboyBridge = d), (i.brazeBridge = d), t.Ce !== InAppMessage.Ee.Pe)
214
+ ((i.appboyBridge = d), (i.brazeBridge = d), t.Pe !== InAppMessage.qe.Ee)
215
215
  ) {
216
216
  const t = i.document.getElementsByTagName("a");
217
217
  for (let e = 0; e < t.length; e++) t[e].onclick = a(t[e]);
@@ -220,7 +220,7 @@ export default function at(t, o, n, s, i, u) {
220
220
  }
221
221
  const $ = i.document.body;
222
222
  if (null != $) {
223
- t.$e() && ($.id = t.htmlId || "");
223
+ t.Ne() && ($.id = t.htmlId || "");
224
224
  const e = document.createElement("hidden");
225
225
  (e.onclick = d.closeMessage),
226
226
  (e.className = "ab-programmatic-close-button"),
@@ -233,12 +233,12 @@ export default function at(t, o, n, s, i, u) {
233
233
  }),
234
234
  (c.className =
235
235
  "ab-in-app-message ab-start-hidden ab-html-message ab-modal-interactions"),
236
- V.OS === W.fe)
236
+ V.OS === W.de)
237
237
  ) {
238
238
  const e = document.createElement("div");
239
239
  return (
240
- (e.className = "ab-ios-scroll-wrapper"), e.appendChild(c), (t.qe = e), e
240
+ (e.className = "ab-ios-scroll-wrapper"), e.appendChild(c), (t.Me = e), e
241
241
  );
242
242
  }
243
- return (t.qe = c), c;
243
+ return (t.Me = c), c;
244
244
  }