saltfish 0.2.55 → 0.2.57

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.
@@ -6973,7 +6973,7 @@ class InteractionManager {
6973
6973
  * @param buttonConfig - The button configuration
6974
6974
  */
6975
6975
  async handleButtonClick(event, buttonConfig) {
6976
- var _a, _b, _c, _d, _e;
6976
+ var _a, _b, _c, _d, _e, _f;
6977
6977
  log(`InteractionManager: Button click detected on button "${buttonConfig.id}"`);
6978
6978
  event.preventDefault();
6979
6979
  event.stopPropagation();
@@ -7030,6 +7030,19 @@ class InteractionManager {
7030
7030
  const updatedStore = useSaltfishStore.getState();
7031
7031
  this.storageManager.setProgress(updatedStore.progress, userId);
7032
7032
  log(`InteractionManager: Saved progress for step ${buttonConfig.action.target} before URL redirect`);
7033
+ if ((_f = currentStore.user) == null ? void 0 : _f.__isAnonymous) {
7034
+ const anonymousData = this.storageManager.getAnonymousUserData();
7035
+ if (anonymousData) {
7036
+ anonymousData.watchedPlaylists = anonymousData.watchedPlaylists || {};
7037
+ anonymousData.watchedPlaylists[currentStore.manifest.id] = {
7038
+ status: "in_progress",
7039
+ currentStepId: buttonConfig.action.target,
7040
+ lastProgressAt: Date.now()
7041
+ };
7042
+ this.storageManager.setAnonymousUserData(anonymousData);
7043
+ log(`InteractionManager: Updated anonymous user watchedPlaylists for step ${buttonConfig.action.target}`);
7044
+ }
7045
+ }
7033
7046
  }
7034
7047
  }
7035
7048
  log(`InteractionManager: Redirecting to ${buttonConfig.action.url}`);
@@ -10349,7 +10362,7 @@ const SaltfishPlayer$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.de
10349
10362
  __proto__: null,
10350
10363
  SaltfishPlayer
10351
10364
  }, Symbol.toStringTag, { value: "Module" }));
10352
- const version = "0.2.55";
10365
+ const version = "0.2.57";
10353
10366
  const packageJson = {
10354
10367
  version
10355
10368
  };