react-dialogger 1.1.18 → 1.1.20

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.
@@ -674,17 +674,17 @@ var DialogBase = /** @class */ (function (_super) {
674
674
  this._dialogRef.current.focus();
675
675
  if (this._Resizeable) {
676
676
  this._Resizeable.setContainer(this._dialogRef.current);
677
- if (typeof this.props.resizeListener === "function") {
678
- this._resizeListenersStore.push(this.props.resizeListener);
679
- this._Resizeable.onResizeListener(function (width, height) {
680
- // this.props.resizeListener({width, height}, this);
681
- // Butun eklenmis Resize collbackler ayni anda maplenerek cevap veriliyor
682
- _this._resizeListenersStore.map(function (itemCallback) {
683
- // @ts-ignore
684
- itemCallback({ width: width, height: height }, _this);
685
- });
677
+ this._Resizeable.onResizeListener(function (width, height) {
678
+ if (typeof _this.props.resizeListener === "function") {
679
+ _this._resizeListenersStore.push(_this.props.resizeListener);
680
+ }
681
+ // this.props.resizeListener({width, height}, this);
682
+ // Butun eklenmis Resize collbackler ayni anda maplenerek cevap veriliyor
683
+ _this._resizeListenersStore.map(function (itemCallback) {
684
+ // @ts-ignore
685
+ itemCallback({ width: width, height: height }, _this);
686
686
  });
687
- }
687
+ });
688
688
  }
689
689
  }
690
690
  // Initialize SlotsProps
@@ -882,7 +882,14 @@ var DialogBase = /** @class */ (function (_super) {
882
882
  this._dom = document.createElement('div');
883
883
  this._dom.setAttribute('role', 'presentation');
884
884
  this._dom.classList.add('appinsource-dialog-root');
885
- document.body.appendChild(this._dom);
885
+ // Find root element
886
+ var rootElement = document.getElementById('root');
887
+ if (rootElement) {
888
+ rootElement.appendChild(this._dom);
889
+ }
890
+ else {
891
+ document.body.appendChild(this._dom);
892
+ }
886
893
  var root = (0, client_1.createRoot)(this._dom);
887
894
  var props = {
888
895
  ref: this._innerRef,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-dialogger",
3
- "version": "1.1.18",
3
+ "version": "1.1.20",
4
4
  "description": "This package is a continuation of the react-araci package. Due to an error, react-araci was removed, and it has been decided to continue under the new package name react-dialogger",
5
5
  "main": "index.js",
6
6
  "author": "Sueleyman Topaloglu",