@syntrologie/runtime-sdk 2.8.0-canary.178 → 2.8.0-canary.179

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.
@@ -82,6 +82,8 @@ export declare class SyntroCanvasOverlay extends LitElement {
82
82
  isMobileMode: boolean;
83
83
  private _notifications;
84
84
  private _surfaceUnsub;
85
+ private _toggleCooldown;
86
+ private _toggleCooldownTimer;
85
87
  /** Prev-state map: entry.id → last evaluated boolean */
86
88
  private _notifyPrevState;
87
89
  /** Unsubscribe for the EventBus notify-watcher subscription */
package/dist/index.js CHANGED
@@ -9084,6 +9084,9 @@ var SyntroCanvasOverlay = class extends LitElement7 {
9084
9084
  // ---- Controllers -------------------------------------------------------
9085
9085
  __publicField(this, "_notifications");
9086
9086
  __publicField(this, "_surfaceUnsub", null);
9087
+ // ---- Toggle guard -------------------------------------------------------
9088
+ __publicField(this, "_toggleCooldown", false);
9089
+ __publicField(this, "_toggleCooldownTimer", null);
9087
9090
  // ---- NotifyWatcher state -----------------------------------------------
9088
9091
  /** Prev-state map: entry.id → last evaluated boolean */
9089
9092
  __publicField(this, "_notifyPrevState", /* @__PURE__ */ new Map());
@@ -9110,6 +9113,10 @@ var SyntroCanvasOverlay = class extends LitElement7 {
9110
9113
  this._stopNotifyWatcher();
9111
9114
  (_a3 = this._surfaceUnsub) == null ? void 0 : _a3.call(this);
9112
9115
  this._surfaceUnsub = null;
9116
+ if (this._toggleCooldownTimer !== null) {
9117
+ clearTimeout(this._toggleCooldownTimer);
9118
+ this._toggleCooldownTimer = null;
9119
+ }
9113
9120
  }
9114
9121
  _subscribeSurface() {
9115
9122
  var _a3;
@@ -9223,7 +9230,14 @@ var SyntroCanvasOverlay = class extends LitElement7 {
9223
9230
  }
9224
9231
  _toggle() {
9225
9232
  var _a3, _b;
9233
+ if (this._toggleCooldown) return;
9226
9234
  const next = !this.isOpen;
9235
+ this.isOpen = next;
9236
+ this._toggleCooldown = true;
9237
+ this._toggleCooldownTimer = setTimeout(() => {
9238
+ this._toggleCooldown = false;
9239
+ this._toggleCooldownTimer = null;
9240
+ }, 300);
9227
9241
  if (next) {
9228
9242
  (_a3 = this.telemetry) == null ? void 0 : _a3.trackCanvasOpened("overlay");
9229
9243
  } else {
@@ -9533,7 +9547,7 @@ function error(prefix, message, data) {
9533
9547
  }
9534
9548
 
9535
9549
  // src/version.ts
9536
- var SDK_VERSION = "2.8.0-canary.178";
9550
+ var SDK_VERSION = "2.8.0-canary.179";
9537
9551
 
9538
9552
  // src/types.ts
9539
9553
  var SDK_SCHEMA_VERSION = "2.0";