@apocaliss92/nodedreame 1.4.0 → 1.5.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.
package/dist/index.cjs CHANGED
@@ -2908,6 +2908,23 @@ var VacuumDevice = class _VacuumDevice extends BaseDevice {
2908
2908
  if (filename === null) return null;
2909
2909
  return this.getMap({ filename, ...opts });
2910
2910
  }
2911
+ /**
2912
+ * Seed {@link mapFilename} from the CLOUD SHADOW (the last value the robot
2913
+ * pushed for siid 6 piid 3) WITHOUT waking it — so a docked/idle robot can
2914
+ * surface its LAST cleaning map without a fresh clean. Emits the usual
2915
+ * `propertyChanged`/`stateChanged` (so a map-watching consumer re-renders) and
2916
+ * returns the resolved {@link mapFilename} (null when the model has no map or
2917
+ * the shadow carries no map path yet).
2918
+ *
2919
+ * NOTE: the shadow holds the last LIVE-PATH filename; its OSS blob may have
2920
+ * expired, in which case a follow-up {@link fetchLatestMap} rejects — treat
2921
+ * that as "no saved map available".
2922
+ */
2923
+ async refreshSavedMapFilename() {
2924
+ if (!this.#caps.canMap) return null;
2925
+ await this.refreshCachedProperties([VACUUM_PROP.MAP_PATH]);
2926
+ return this.mapFilename;
2927
+ }
2911
2928
  /**
2912
2929
  * The current room/segment id, derived from the most-recently-decoded map's
2913
2930
  * active-segment set (`sa`). `null` when no map has been fetched or no