ninegrid2 6.708.0 → 6.710.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.
@@ -121149,9 +121149,11 @@ class nxSplitter extends HTMLElement {
121149
121149
  : prev.offsetHeight + next.offsetHeight;
121150
121150
 
121151
121151
  // prev 기준 상대 거리 (드래그 거리)
121152
+ const dragRect = dragBar.getBoundingClientRect();
121153
+
121152
121154
  const delta = this.#mode === "h"
121153
- ? e.clientX - prev.getBoundingClientRect().left
121154
- : e.clientY - prev.getBoundingClientRect().top;
121155
+ ? dragRect.left - prev.offsetLeft
121156
+ : dragRect.top - prev.offsetTop;
121155
121157
 
121156
121158
  prev.style.flex = "none";
121157
121159
  next.style.flex = "none";
@@ -121166,11 +121168,6 @@ class nxSplitter extends HTMLElement {
121166
121168
  }
121167
121169
  };
121168
121170
 
121169
-
121170
-
121171
-
121172
-
121173
-
121174
121171
  window.addEventListener("mousemove", onMove);
121175
121172
  window.addEventListener("mouseup", onUp);
121176
121173
  };
@@ -121145,9 +121145,11 @@ class nxSplitter extends HTMLElement {
121145
121145
  : prev.offsetHeight + next.offsetHeight;
121146
121146
 
121147
121147
  // prev 기준 상대 거리 (드래그 거리)
121148
+ const dragRect = dragBar.getBoundingClientRect();
121149
+
121148
121150
  const delta = this.#mode === "h"
121149
- ? e.clientX - prev.getBoundingClientRect().left
121150
- : e.clientY - prev.getBoundingClientRect().top;
121151
+ ? dragRect.left - prev.offsetLeft
121152
+ : dragRect.top - prev.offsetTop;
121151
121153
 
121152
121154
  prev.style.flex = "none";
121153
121155
  next.style.flex = "none";
@@ -121162,11 +121164,6 @@ class nxSplitter extends HTMLElement {
121162
121164
  }
121163
121165
  };
121164
121166
 
121165
-
121166
-
121167
-
121168
-
121169
-
121170
121167
  window.addEventListener("mousemove", onMove);
121171
121168
  window.addEventListener("mouseup", onUp);
121172
121169
  };
@@ -104,9 +104,11 @@ class nxSplitter extends HTMLElement {
104
104
  : prev.offsetHeight + next.offsetHeight;
105
105
 
106
106
  // prev 기준 상대 거리 (드래그 거리)
107
+ const dragRect = dragBar.getBoundingClientRect();
108
+
107
109
  const delta = this.#mode === "h"
108
- ? e.clientX - prev.getBoundingClientRect().left
109
- : e.clientY - prev.getBoundingClientRect().top;
110
+ ? dragRect.left - prev.offsetLeft
111
+ : dragRect.top - prev.offsetTop;
110
112
 
111
113
  prev.style.flex = "none";
112
114
  next.style.flex = "none";
@@ -121,11 +123,6 @@ class nxSplitter extends HTMLElement {
121
123
  }
122
124
  };
123
125
 
124
-
125
-
126
-
127
-
128
-
129
126
  window.addEventListener("mousemove", onMove);
130
127
  window.addEventListener("mouseup", onUp);
131
128
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ninegrid2",
3
3
  "type": "module",
4
- "version": "6.708.0",
4
+ "version": "6.710.0",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "exports": {
@@ -104,9 +104,11 @@ class nxSplitter extends HTMLElement {
104
104
  : prev.offsetHeight + next.offsetHeight;
105
105
 
106
106
  // prev 기준 상대 거리 (드래그 거리)
107
+ const dragRect = dragBar.getBoundingClientRect();
108
+
107
109
  const delta = this.#mode === "h"
108
- ? e.clientX - prev.getBoundingClientRect().left
109
- : e.clientY - prev.getBoundingClientRect().top;
110
+ ? dragRect.left - prev.offsetLeft
111
+ : dragRect.top - prev.offsetTop;
110
112
 
111
113
  prev.style.flex = "none";
112
114
  next.style.flex = "none";
@@ -121,11 +123,6 @@ class nxSplitter extends HTMLElement {
121
123
  }
122
124
  };
123
125
 
124
-
125
-
126
-
127
-
128
-
129
126
  window.addEventListener("mousemove", onMove);
130
127
  window.addEventListener("mouseup", onUp);
131
128
  };