@orbit-software/sdk 1.87.14 → 1.87.15

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.
package/dist/esm/sdk.d.ts CHANGED
@@ -15,7 +15,7 @@ declare global {
15
15
  Adsgram: {
16
16
  init: (options: AdsgramInitOptions) => AdsgramController;
17
17
  };
18
- showGiga: () => Promise<void>;
18
+ showGiga: (placementId?: string | null, transactionId?: string | null) => Promise<void>;
19
19
  }
20
20
  }
21
21
  declare global {
package/dist/esm/sdk.mjs CHANGED
@@ -38,7 +38,7 @@ function promisify(e) {
38
38
  };
39
39
  }
40
40
  promisify.argumentNames = "__ES6-PROMISIFY--CUSTOM-ARGUMENTS__", promisify.Promise = void 0;
41
- const version = "1.87.13";
41
+ const version = "1.87.15";
42
42
  function getDefaultExportFromCjs$3(e) {
43
43
  return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
44
44
  }
@@ -20131,7 +20131,7 @@ var Rr, j0, Removable = (j0 = class {
20131
20131
  clearGcTimeout() {
20132
20132
  J(this, Rr) && (timeoutManager.clearTimeout(J(this, Rr)), Pe(this, Rr, void 0));
20133
20133
  }
20134
- }, Rr = new WeakMap(), j0), define_process_env_default$3 = { NODE_ENV: '"production"', version: '"1.87.13"' }, Ir, Ur, Jt, Mr, jt, $r, Or, Zt, or, B0, Query = (B0 = class extends Removable {
20134
+ }, Rr = new WeakMap(), j0), define_process_env_default$3 = { NODE_ENV: '"production"', version: '"1.87.15"' }, Ir, Ur, Jt, Mr, jt, $r, Or, Zt, or, B0, Query = (B0 = class extends Removable {
20135
20135
  constructor(t) {
20136
20136
  super();
20137
20137
  Je(this, Zt);
@@ -37628,7 +37628,7 @@ function delay(e, { signal: t } = {}) {
37628
37628
  t == null || t.addEventListener("abort", o, { once: !0 });
37629
37629
  });
37630
37630
  }
37631
- var define_process_env_default$2 = { NODE_ENV: '"production"', version: '"1.87.13"' }, win;
37631
+ var define_process_env_default$2 = { NODE_ENV: '"production"', version: '"1.87.15"' }, win;
37632
37632
  if (typeof window > "u") {
37633
37633
  var loc = {
37634
37634
  hostname: ""
@@ -52863,7 +52863,7 @@ const balance$4 = "Balance", topUp$4 = "Top Up", ads$4 = "Ads", adsOn$4 = "On",
52863
52863
  topUpModal,
52864
52864
  inventoryModal
52865
52865
  };
52866
- var define_process_env_default$1 = { NODE_ENV: '"production"', version: '"1.87.13"' };
52866
+ var define_process_env_default$1 = { NODE_ENV: '"production"', version: '"1.87.15"' };
52867
52867
  const resources = {
52868
52868
  en: {
52869
52869
  translation: en
@@ -53315,33 +53315,39 @@ async function initGigapubAds(e) {
53315
53315
  });
53316
53316
  }
53317
53317
  async function showGigapubAd(e) {
53318
+ const t = crypto.randomUUID();
53318
53319
  return !window.showGiga || typeof window.showGiga != "function" ? e ? (console.log("Gigapub: showGiga not available, using fallback."), mixpanel.track("ad_show_fallback", {
53319
53320
  message: "Gigapub showGiga function not available, using fallback.",
53320
53321
  ...getBaseAnalyticsParams(),
53321
- ad_type: "gigapub"
53322
+ ad_type: "gigapub",
53323
+ transaction_id: t
53322
53324
  }), await e()) : (mixpanel.track("ad_show_error", {
53323
53325
  message: "Gigapub showGiga function not available",
53324
53326
  error_type: "function_unavailable",
53325
53327
  ...getBaseAnalyticsParams(),
53326
- ad_type: "gigapub"
53327
- }), !1) : new Promise((t) => {
53328
+ ad_type: "gigapub",
53329
+ transaction_id: t
53330
+ }), !1) : new Promise((s) => {
53328
53331
  mixpanel.track("ad_show_started", {
53329
53332
  ...getBaseAnalyticsParams(),
53330
- ad_type: "gigapub"
53331
- }), window.showGiga().then(() => {
53333
+ ad_type: "gigapub",
53334
+ transaction_id: t
53335
+ }), console.log("Gigapub: showing ad with transaction ID:", t), window.showGiga(null, t).then(() => {
53332
53336
  console.log("Gigapub ad finished successfully."), mixpanel.track("ad_show_success", {
53333
53337
  ...getBaseAnalyticsParams(),
53334
- ad_type: "gigapub"
53335
- }), t(!0);
53336
- }).catch((s) => {
53337
- console.error("Gigapub ad error", s), mixpanel.track("ad_show_error", {
53338
+ ad_type: "gigapub",
53339
+ transaction_id: t
53340
+ }), s(!0);
53341
+ }).catch((i) => {
53342
+ console.error("Gigapub ad error", i), mixpanel.track("ad_show_error", {
53338
53343
  message: "Gigapub ad failed or was skipped",
53339
53344
  error_type: "exception",
53340
- error: s == null ? void 0 : s.toString(),
53341
- error_message: (s == null ? void 0 : s.message) || "Unknown error",
53345
+ error: i == null ? void 0 : i.toString(),
53346
+ error_message: (i == null ? void 0 : i.message) || "Unknown error",
53342
53347
  ...getBaseAnalyticsParams(),
53343
- ad_type: "gigapub"
53344
- }), t(!1);
53348
+ ad_type: "gigapub",
53349
+ transaction_id: t
53350
+ }), s(!1);
53345
53351
  });
53346
53352
  });
53347
53353
  }
@@ -53701,7 +53707,7 @@ function throttleLeading(e, t) {
53701
53707
  return a - s >= t ? (s = a, e.apply(this, i)) : (console.log(`Function is throttled. Next call available in ${t - (a - s)}ms`), Promise.resolve(!1));
53702
53708
  };
53703
53709
  }
53704
- var define_process_env_default = { NODE_ENV: '"production"', version: '"1.87.13"' };
53710
+ var define_process_env_default = { NODE_ENV: '"production"', version: '"1.87.15"' };
53705
53711
  ensureViewportMetaTag();
53706
53712
  initSentry();
53707
53713
  const CloudStorageGetItem = promisify(WebApp.CloudStorage.getItem), CloudStorageSetItem = promisify(WebApp.CloudStorage.setItem), CloudStorageRemoveItem = promisify(WebApp.CloudStorage.removeItem), BASE_URL = "https://app.portalapp.games/sdk", G_MEASUREMENT_ID = "G-4RMXVE2K75", BANNER_HEIGHT = 60, bannerManager = new BannerManager({