@cognigy/webchat 3.45.0 → 3.46.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/OSS_LICENSES.txt CHANGED
@@ -1,4 +1,4 @@
1
- Created on 29-06-2026 at 09:05:35
1
+ Created on 02-07-2026 at 12:40:42
2
2
 
3
3
  {
4
4
  "@babel/code-frame@7.29.0": {
@@ -170,7 +170,7 @@ Created on 29-06-2026 at 09:05:35
170
170
  "licenseFile": "node_modules/@cognigy/socket-client/LICENSE",
171
171
  "copyright": "Copyright (c) 2019 Cognigy GmbH"
172
172
  },
173
- "@cognigy/webchat@3.45.0": {
173
+ "@cognigy/webchat@3.46.0": {
174
174
  "licenses": "MIT*",
175
175
  "repository": "https://github.com/Cognigy/Webchat",
176
176
  "publisher": "Cognigy GmbH",
@@ -1,7 +1,7 @@
1
1
  /*!
2
- * webchat.esm.js v3.45.0
3
- * https://github.com/Cognigy/Webchat/tree/v3.45.0
4
- * https://github.com/Cognigy/Webchat/tree/v3.45.0/OSS_LICENSES.txt
2
+ * webchat.esm.js v3.46.0
3
+ * https://github.com/Cognigy/Webchat/tree/v3.46.0
4
+ * https://github.com/Cognigy/Webchat/tree/v3.46.0/OSS_LICENSES.txt
5
5
  */
6
6
  import * as __WEBPACK_EXTERNAL_MODULE_react__ from "react";
7
7
  import * as __WEBPACK_EXTERNAL_MODULE_react_dom_7dac9eee__ from "react-dom";
@@ -38088,6 +38088,25 @@ class WebchatUI extends react__WEBPACK_IMPORTED_MODULE_0__["default"].PureCompon
38088
38088
  }
38089
38089
  }
38090
38090
  };
38091
+
38092
+ /**
38093
+ * The webchat window (#webchatWindow) is a fixed-size flex shell with `overflow: hidden`; its
38094
+ * children (header, chat log, input) manage their own scrolling. Safari/WebKit, however, still
38095
+ * scrolls an `overflow: hidden` ancestor to bring a newly focused element into view — so during
38096
+ * (reverse) keyboard navigation it nudges the whole window by a few pixels, shifting the header
38097
+ * up and clipping the layout. Nothing else resets it, so the broken offset sticks (AB#105695).
38098
+ * Snap the window back to its origin whenever it is scrolled. This is browser- and message-type
38099
+ * agnostic and never interferes with the inner scroll containers.
38100
+ */
38101
+ handleWebchatWindowScroll = event => {
38102
+ // Only act on the window's own scroll, never on a descendant scroll container that might
38103
+ // surface here. React 18 does not bubble synthetic scroll events, but this keeps the
38104
+ // target-only intent explicit and resilient to any future change in event delegation.
38105
+ if (event.target !== event.currentTarget) return;
38106
+ const el = event.currentTarget;
38107
+ if (el.scrollTop !== 0) el.scrollTop = 0;
38108
+ if (el.scrollLeft !== 0) el.scrollLeft = 0;
38109
+ };
38091
38110
  handleSendRating = ({
38092
38111
  rating,
38093
38112
  comment,
@@ -38338,6 +38357,7 @@ class WebchatUI extends react__WEBPACK_IMPORTED_MODULE_0__["default"].PureCompon
38338
38357
  className: "webchat",
38339
38358
  id: "webchatWindow",
38340
38359
  ref: this.webchatWindowRef,
38360
+ onScroll: this.handleWebchatWindowScroll,
38341
38361
  chatWindowWidth: this.props.config.settings.layout.chatWindowWidth
38342
38362
  }), !fullscreenMessage ? this.renderRegularLayout(isInforming) : this.renderFullscreenMessageLayout(), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__["default"].createElement(_presentational_DisconnectOverlay__WEBPACK_IMPORTED_MODULE_20__/* ["default"] */ .A, {
38343
38363
  isOpen: showDisconnectOverlay,