@weldsuite/helpdesk-widget-sdk 1.0.13 → 1.0.14

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/angular.js CHANGED
@@ -1310,6 +1310,15 @@ class MessageBroker {
1310
1310
  this.logger = logger.child('[MessageBroker]');
1311
1311
  this.iframeManager = iframeManager;
1312
1312
  this.security = new SecurityManager(config.security, this.logger);
1313
+ // Automatically trust messages from the widget's base URL
1314
+ // The iframes load from api.baseUrl, so we must accept their postMessages
1315
+ try {
1316
+ const widgetOrigin = new URL(config.api.baseUrl).origin;
1317
+ this.security.addAllowedOrigin(widgetOrigin);
1318
+ }
1319
+ catch {
1320
+ // Invalid URL, will rely on configured allowedOrigins
1321
+ }
1313
1322
  this.rateLimiter = new RateLimiter(100, 60000); // 100 messages per minute
1314
1323
  // Bind handlers once for proper cleanup
1315
1324
  this.boundHandleMessage = this.handleMessage.bind(this);
@@ -2245,7 +2254,7 @@ class StateCoordinator {
2245
2254
  }
2246
2255
  }
2247
2256
 
2248
- var version = "1.0.13";
2257
+ var version = "1.0.14";
2249
2258
  var packageJson = {
2250
2259
  version: version};
2251
2260