react-dialogger 1.1.138 → 1.1.139

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.
Files changed (2) hide show
  1. package/models/Dialog.js +36 -3
  2. package/package.json +1 -1
package/models/Dialog.js CHANGED
@@ -68,15 +68,48 @@ var Dialog = /** @class */ (function () {
68
68
  * UI / Dialog / Form bağlamında alışıldık
69
69
  * */
70
70
  this._headerRef = React.createRef();
71
+ // private highestZ = (throughableOnly: boolean = false): number => {
72
+ //
73
+ // if(this._dialogOptions?.zIndex) {
74
+ // return this._dialogOptions?.zIndex;
75
+ // }
76
+ // // const presentationElements = document.querySelectorAll(`div[data-family="presentation"]${throughableOnly ? ' > div.dialogger-throughable' : ''}`)
77
+ // const presentationElements = document.querySelectorAll(`div[data-family="presentation"]`)
78
+ // let highest = 1201;
79
+ // presentationElements.forEach(element => {
80
+ // if(throughableOnly){
81
+ // const firstDiv = element.querySelector('div:first-child');
82
+ // if (firstDiv?.classList.contains('dialogger-throughable')) {
83
+ // // ✅ İlk div dialogger-throughable class'ına sahip
84
+ // const z = parseInt(window.getComputedStyle(element).zIndex, 10);
85
+ // if (!isNaN(z) && z > highest) {
86
+ // highest = z;
87
+ // }
88
+ // }
89
+ // } else {
90
+ // const z = parseInt(window.getComputedStyle(element).zIndex, 10);
91
+ // if (!isNaN(z) && z > highest) {
92
+ // highest = z;
93
+ // }
94
+ // }
95
+ // });
96
+ // return highest;
97
+ // }
71
98
  this.highestZ = function (throughableOnly) {
72
- var _a, _b;
99
+ var _a;
73
100
  if (throughableOnly === void 0) { throughableOnly = false; }
74
101
  if ((_a = _this._dialogOptions) === null || _a === void 0 ? void 0 : _a.zIndex) {
75
- return (_b = _this._dialogOptions) === null || _b === void 0 ? void 0 : _b.zIndex;
102
+ return _this._dialogOptions.zIndex;
76
103
  }
77
- var presentationElements = document.querySelectorAll("div[data-family=\"presentation\"]".concat(throughableOnly ? ' > div.dialogger-throughable' : ''));
104
+ var presentationElements = document.querySelectorAll('div[data-family="presentation"]');
78
105
  var highest = 1201;
79
106
  presentationElements.forEach(function (element) {
107
+ // throughableOnly → sadece ilk child'ı dialogger-throughable olan presentation'lar
108
+ if (throughableOnly) {
109
+ var firstDiv = element.querySelector('div:first-child');
110
+ if (!(firstDiv === null || firstDiv === void 0 ? void 0 : firstDiv.classList.contains('dialogger-throughable')))
111
+ return;
112
+ }
80
113
  var z = parseInt(window.getComputedStyle(element).zIndex, 10);
81
114
  if (!isNaN(z) && z > highest) {
82
115
  highest = z;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-dialogger",
3
- "version": "1.1.138",
3
+ "version": "1.1.139",
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",