ninegrid2 6.1144.0 → 6.1145.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/dist/bundle.cjs.js +30 -16
- package/dist/bundle.esm.js +30 -16
- package/dist/nx/_nxDiv.js +26 -2
- package/dist/nx/nxButtons.js +1 -7
- package/dist/nx/nxPanel.js +2 -6
- package/dist/nx/nxSplitter.js +1 -1
- package/package.json +1 -1
- package/src/nx/_nxDiv.js +26 -2
- package/src/nx/nxButtons.js +1 -7
- package/src/nx/nxPanel.js +2 -6
- package/src/nx/nxSplitter.js +1 -1
package/dist/bundle.cjs.js
CHANGED
|
@@ -121428,7 +121428,7 @@ class nxSplitter extends HTMLElement {
|
|
|
121428
121428
|
const finalDragBarPos = isHorizontal ? parseFloat(dragBar.style.left) : parseFloat(dragBar.style.top);
|
|
121429
121429
|
const dragOffset = finalDragBarPos - initialSplitterPosInParent;
|
|
121430
121430
|
|
|
121431
|
-
const prevSize = isHorizontal ? prev.getBoundingClientRect().width : prev.getBoundingClientRect().height
|
|
121431
|
+
const prevSize = isHorizontal ? prev.getBoundingClientRect().width : prev.getBoundingClientRect().height;
|
|
121432
121432
|
const nextSize = isHorizontal ? next.getBoundingClientRect().width : next.getBoundingClientRect().height;
|
|
121433
121433
|
|
|
121434
121434
|
let newPrevSize = prevSize + dragOffset;
|
|
@@ -121965,7 +121965,7 @@ customElements.define('nx-layout2', NxLayout2);
|
|
|
121965
121965
|
|
|
121966
121966
|
class nxDiv extends HTMLElement
|
|
121967
121967
|
{
|
|
121968
|
-
originContents
|
|
121968
|
+
originContents;
|
|
121969
121969
|
#isInitialized = false;
|
|
121970
121970
|
|
|
121971
121971
|
constructor () {
|
|
@@ -121983,8 +121983,32 @@ class nxDiv extends HTMLElement
|
|
|
121983
121983
|
return false;
|
|
121984
121984
|
}
|
|
121985
121985
|
|
|
121986
|
+
getData = () => {
|
|
121987
|
+
const jsonData = {};
|
|
121988
|
+
|
|
121989
|
+
this.shadowRoot.querySelectorAll("input, textarea, select, [id], [name]").forEach(el => {
|
|
121990
|
+
const key = el.id || el.name; // id가 있으면 우선, 없으면 name 사용
|
|
121991
|
+
if (!key) return; // id도 name도 없으면 건너뛰기
|
|
121992
|
+
|
|
121993
|
+
const value = (el.tagName === "INPUT" || el.tagName === "TEXTAREA" || el.tagName === "SELECT")
|
|
121994
|
+
? el.value
|
|
121995
|
+
: el.textContent.trim();
|
|
121996
|
+
|
|
121997
|
+
// 중복 키를 대비한 배열 처리
|
|
121998
|
+
if (jsonData[key]) {
|
|
121999
|
+
if (!Array.isArray(jsonData[key])) {
|
|
122000
|
+
jsonData[key] = [jsonData[key]];
|
|
122001
|
+
}
|
|
122002
|
+
jsonData[key].push(value);
|
|
122003
|
+
} else {
|
|
122004
|
+
jsonData[key] = value;
|
|
122005
|
+
}
|
|
122006
|
+
});
|
|
122007
|
+
|
|
122008
|
+
return jsonData;
|
|
122009
|
+
};
|
|
122010
|
+
|
|
121986
122011
|
#init = () => {
|
|
121987
|
-
console.log("super.connectedCallback");
|
|
121988
122012
|
|
|
121989
122013
|
/**
|
|
121990
122014
|
* css style 적용
|
|
@@ -122002,17 +122026,13 @@ class nxDiv extends HTMLElement
|
|
|
122002
122026
|
}
|
|
122003
122027
|
|
|
122004
122028
|
class nxPanel extends nxDiv {
|
|
122005
|
-
|
|
122029
|
+
|
|
122006
122030
|
constructor() {
|
|
122007
122031
|
super();
|
|
122008
122032
|
}
|
|
122009
122033
|
|
|
122010
122034
|
connectedCallback() {
|
|
122011
|
-
if (
|
|
122012
|
-
|
|
122013
|
-
console.log("==========", "child.connectedCallback");
|
|
122014
|
-
|
|
122015
|
-
this.#init();
|
|
122035
|
+
if (super.connectedCallback()) this.#init();
|
|
122016
122036
|
}
|
|
122017
122037
|
|
|
122018
122038
|
#init = () => {
|
|
@@ -122043,19 +122063,13 @@ class nxPanel extends nxDiv {
|
|
|
122043
122063
|
customElements.define("nx-panel", nxPanel);
|
|
122044
122064
|
|
|
122045
122065
|
class nxButtons extends nxDiv {
|
|
122046
|
-
// 1. 초기화 상태를 저장할 플래그를 추가합니다.
|
|
122047
|
-
//#isInitialized = false;
|
|
122048
122066
|
|
|
122049
122067
|
constructor() {
|
|
122050
122068
|
super();
|
|
122051
122069
|
}
|
|
122052
122070
|
|
|
122053
122071
|
connectedCallback() {
|
|
122054
|
-
if (
|
|
122055
|
-
|
|
122056
|
-
console.log("==========", "child.connectedCallback");
|
|
122057
|
-
|
|
122058
|
-
this.#init();
|
|
122072
|
+
if (super.connectedCallback()) this.#init();
|
|
122059
122073
|
};
|
|
122060
122074
|
|
|
122061
122075
|
#init = () => {
|
package/dist/bundle.esm.js
CHANGED
|
@@ -121424,7 +121424,7 @@ class nxSplitter extends HTMLElement {
|
|
|
121424
121424
|
const finalDragBarPos = isHorizontal ? parseFloat(dragBar.style.left) : parseFloat(dragBar.style.top);
|
|
121425
121425
|
const dragOffset = finalDragBarPos - initialSplitterPosInParent;
|
|
121426
121426
|
|
|
121427
|
-
const prevSize = isHorizontal ? prev.getBoundingClientRect().width : prev.getBoundingClientRect().height
|
|
121427
|
+
const prevSize = isHorizontal ? prev.getBoundingClientRect().width : prev.getBoundingClientRect().height;
|
|
121428
121428
|
const nextSize = isHorizontal ? next.getBoundingClientRect().width : next.getBoundingClientRect().height;
|
|
121429
121429
|
|
|
121430
121430
|
let newPrevSize = prevSize + dragOffset;
|
|
@@ -121961,7 +121961,7 @@ customElements.define('nx-layout2', NxLayout2);
|
|
|
121961
121961
|
|
|
121962
121962
|
class nxDiv extends HTMLElement
|
|
121963
121963
|
{
|
|
121964
|
-
originContents
|
|
121964
|
+
originContents;
|
|
121965
121965
|
#isInitialized = false;
|
|
121966
121966
|
|
|
121967
121967
|
constructor () {
|
|
@@ -121979,8 +121979,32 @@ class nxDiv extends HTMLElement
|
|
|
121979
121979
|
return false;
|
|
121980
121980
|
}
|
|
121981
121981
|
|
|
121982
|
+
getData = () => {
|
|
121983
|
+
const jsonData = {};
|
|
121984
|
+
|
|
121985
|
+
this.shadowRoot.querySelectorAll("input, textarea, select, [id], [name]").forEach(el => {
|
|
121986
|
+
const key = el.id || el.name; // id가 있으면 우선, 없으면 name 사용
|
|
121987
|
+
if (!key) return; // id도 name도 없으면 건너뛰기
|
|
121988
|
+
|
|
121989
|
+
const value = (el.tagName === "INPUT" || el.tagName === "TEXTAREA" || el.tagName === "SELECT")
|
|
121990
|
+
? el.value
|
|
121991
|
+
: el.textContent.trim();
|
|
121992
|
+
|
|
121993
|
+
// 중복 키를 대비한 배열 처리
|
|
121994
|
+
if (jsonData[key]) {
|
|
121995
|
+
if (!Array.isArray(jsonData[key])) {
|
|
121996
|
+
jsonData[key] = [jsonData[key]];
|
|
121997
|
+
}
|
|
121998
|
+
jsonData[key].push(value);
|
|
121999
|
+
} else {
|
|
122000
|
+
jsonData[key] = value;
|
|
122001
|
+
}
|
|
122002
|
+
});
|
|
122003
|
+
|
|
122004
|
+
return jsonData;
|
|
122005
|
+
};
|
|
122006
|
+
|
|
121982
122007
|
#init = () => {
|
|
121983
|
-
console.log("super.connectedCallback");
|
|
121984
122008
|
|
|
121985
122009
|
/**
|
|
121986
122010
|
* css style 적용
|
|
@@ -121998,17 +122022,13 @@ class nxDiv extends HTMLElement
|
|
|
121998
122022
|
}
|
|
121999
122023
|
|
|
122000
122024
|
class nxPanel extends nxDiv {
|
|
122001
|
-
|
|
122025
|
+
|
|
122002
122026
|
constructor() {
|
|
122003
122027
|
super();
|
|
122004
122028
|
}
|
|
122005
122029
|
|
|
122006
122030
|
connectedCallback() {
|
|
122007
|
-
if (
|
|
122008
|
-
|
|
122009
|
-
console.log("==========", "child.connectedCallback");
|
|
122010
|
-
|
|
122011
|
-
this.#init();
|
|
122031
|
+
if (super.connectedCallback()) this.#init();
|
|
122012
122032
|
}
|
|
122013
122033
|
|
|
122014
122034
|
#init = () => {
|
|
@@ -122039,19 +122059,13 @@ class nxPanel extends nxDiv {
|
|
|
122039
122059
|
customElements.define("nx-panel", nxPanel);
|
|
122040
122060
|
|
|
122041
122061
|
class nxButtons extends nxDiv {
|
|
122042
|
-
// 1. 초기화 상태를 저장할 플래그를 추가합니다.
|
|
122043
|
-
//#isInitialized = false;
|
|
122044
122062
|
|
|
122045
122063
|
constructor() {
|
|
122046
122064
|
super();
|
|
122047
122065
|
}
|
|
122048
122066
|
|
|
122049
122067
|
connectedCallback() {
|
|
122050
|
-
if (
|
|
122051
|
-
|
|
122052
|
-
console.log("==========", "child.connectedCallback");
|
|
122053
|
-
|
|
122054
|
-
this.#init();
|
|
122068
|
+
if (super.connectedCallback()) this.#init();
|
|
122055
122069
|
};
|
|
122056
122070
|
|
|
122057
122071
|
#init = () => {
|
package/dist/nx/_nxDiv.js
CHANGED
|
@@ -2,7 +2,7 @@ import ninegrid from "../index.js";
|
|
|
2
2
|
|
|
3
3
|
export class nxDiv extends HTMLElement
|
|
4
4
|
{
|
|
5
|
-
originContents
|
|
5
|
+
originContents;
|
|
6
6
|
#isInitialized = false;
|
|
7
7
|
|
|
8
8
|
constructor () {
|
|
@@ -20,8 +20,32 @@ export class nxDiv extends HTMLElement
|
|
|
20
20
|
return false;
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
+
getData = () => {
|
|
24
|
+
const jsonData = {};
|
|
25
|
+
|
|
26
|
+
this.shadowRoot.querySelectorAll("input, textarea, select, [id], [name]").forEach(el => {
|
|
27
|
+
const key = el.id || el.name; // id가 있으면 우선, 없으면 name 사용
|
|
28
|
+
if (!key) return; // id도 name도 없으면 건너뛰기
|
|
29
|
+
|
|
30
|
+
const value = (el.tagName === "INPUT" || el.tagName === "TEXTAREA" || el.tagName === "SELECT")
|
|
31
|
+
? el.value
|
|
32
|
+
: el.textContent.trim();
|
|
33
|
+
|
|
34
|
+
// 중복 키를 대비한 배열 처리
|
|
35
|
+
if (jsonData[key]) {
|
|
36
|
+
if (!Array.isArray(jsonData[key])) {
|
|
37
|
+
jsonData[key] = [jsonData[key]];
|
|
38
|
+
}
|
|
39
|
+
jsonData[key].push(value);
|
|
40
|
+
} else {
|
|
41
|
+
jsonData[key] = value;
|
|
42
|
+
}
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
return jsonData;
|
|
46
|
+
};
|
|
47
|
+
|
|
23
48
|
#init = () => {
|
|
24
|
-
console.log("super.connectedCallback");
|
|
25
49
|
|
|
26
50
|
/**
|
|
27
51
|
* css style 적용
|
package/dist/nx/nxButtons.js
CHANGED
|
@@ -2,19 +2,13 @@ import ninegrid from "../index.js";
|
|
|
2
2
|
import {nxDiv} from "./_nxDiv.js";
|
|
3
3
|
|
|
4
4
|
class nxButtons extends nxDiv {
|
|
5
|
-
// 1. 초기화 상태를 저장할 플래그를 추가합니다.
|
|
6
|
-
//#isInitialized = false;
|
|
7
5
|
|
|
8
6
|
constructor() {
|
|
9
7
|
super();
|
|
10
8
|
}
|
|
11
9
|
|
|
12
10
|
connectedCallback() {
|
|
13
|
-
if (
|
|
14
|
-
|
|
15
|
-
console.log("==========", "child.connectedCallback");
|
|
16
|
-
|
|
17
|
-
this.#init();
|
|
11
|
+
if (super.connectedCallback()) this.#init();
|
|
18
12
|
};
|
|
19
13
|
|
|
20
14
|
#init = () => {
|
package/dist/nx/nxPanel.js
CHANGED
|
@@ -2,17 +2,13 @@ import ninegrid from "../index.js";
|
|
|
2
2
|
import {nxDiv} from "./_nxDiv.js";
|
|
3
3
|
|
|
4
4
|
class nxPanel extends nxDiv {
|
|
5
|
-
|
|
5
|
+
|
|
6
6
|
constructor() {
|
|
7
7
|
super();
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
connectedCallback() {
|
|
11
|
-
if (
|
|
12
|
-
|
|
13
|
-
console.log("==========", "child.connectedCallback");
|
|
14
|
-
|
|
15
|
-
this.#init();
|
|
11
|
+
if (super.connectedCallback()) this.#init();
|
|
16
12
|
}
|
|
17
13
|
|
|
18
14
|
#init = () => {
|
package/dist/nx/nxSplitter.js
CHANGED
|
@@ -128,7 +128,7 @@ class nxSplitter extends HTMLElement {
|
|
|
128
128
|
const finalDragBarPos = isHorizontal ? parseFloat(dragBar.style.left) : parseFloat(dragBar.style.top);
|
|
129
129
|
const dragOffset = finalDragBarPos - initialSplitterPosInParent;
|
|
130
130
|
|
|
131
|
-
const prevSize = isHorizontal ? prev.getBoundingClientRect().width : prev.getBoundingClientRect().height
|
|
131
|
+
const prevSize = isHorizontal ? prev.getBoundingClientRect().width : prev.getBoundingClientRect().height;
|
|
132
132
|
const nextSize = isHorizontal ? next.getBoundingClientRect().width : next.getBoundingClientRect().height;
|
|
133
133
|
|
|
134
134
|
let newPrevSize = prevSize + dragOffset;
|
package/package.json
CHANGED
package/src/nx/_nxDiv.js
CHANGED
|
@@ -2,7 +2,7 @@ import ninegrid from "../index.js";
|
|
|
2
2
|
|
|
3
3
|
export class nxDiv extends HTMLElement
|
|
4
4
|
{
|
|
5
|
-
originContents
|
|
5
|
+
originContents;
|
|
6
6
|
#isInitialized = false;
|
|
7
7
|
|
|
8
8
|
constructor () {
|
|
@@ -20,8 +20,32 @@ export class nxDiv extends HTMLElement
|
|
|
20
20
|
return false;
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
+
getData = () => {
|
|
24
|
+
const jsonData = {};
|
|
25
|
+
|
|
26
|
+
this.shadowRoot.querySelectorAll("input, textarea, select, [id], [name]").forEach(el => {
|
|
27
|
+
const key = el.id || el.name; // id가 있으면 우선, 없으면 name 사용
|
|
28
|
+
if (!key) return; // id도 name도 없으면 건너뛰기
|
|
29
|
+
|
|
30
|
+
const value = (el.tagName === "INPUT" || el.tagName === "TEXTAREA" || el.tagName === "SELECT")
|
|
31
|
+
? el.value
|
|
32
|
+
: el.textContent.trim();
|
|
33
|
+
|
|
34
|
+
// 중복 키를 대비한 배열 처리
|
|
35
|
+
if (jsonData[key]) {
|
|
36
|
+
if (!Array.isArray(jsonData[key])) {
|
|
37
|
+
jsonData[key] = [jsonData[key]];
|
|
38
|
+
}
|
|
39
|
+
jsonData[key].push(value);
|
|
40
|
+
} else {
|
|
41
|
+
jsonData[key] = value;
|
|
42
|
+
}
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
return jsonData;
|
|
46
|
+
};
|
|
47
|
+
|
|
23
48
|
#init = () => {
|
|
24
|
-
console.log("super.connectedCallback");
|
|
25
49
|
|
|
26
50
|
/**
|
|
27
51
|
* css style 적용
|
package/src/nx/nxButtons.js
CHANGED
|
@@ -2,19 +2,13 @@ import ninegrid from "../index.js";
|
|
|
2
2
|
import {nxDiv} from "./_nxDiv.js";
|
|
3
3
|
|
|
4
4
|
class nxButtons extends nxDiv {
|
|
5
|
-
// 1. 초기화 상태를 저장할 플래그를 추가합니다.
|
|
6
|
-
//#isInitialized = false;
|
|
7
5
|
|
|
8
6
|
constructor() {
|
|
9
7
|
super();
|
|
10
8
|
}
|
|
11
9
|
|
|
12
10
|
connectedCallback() {
|
|
13
|
-
if (
|
|
14
|
-
|
|
15
|
-
console.log("==========", "child.connectedCallback");
|
|
16
|
-
|
|
17
|
-
this.#init();
|
|
11
|
+
if (super.connectedCallback()) this.#init();
|
|
18
12
|
};
|
|
19
13
|
|
|
20
14
|
#init = () => {
|
package/src/nx/nxPanel.js
CHANGED
|
@@ -2,17 +2,13 @@ import ninegrid from "../index.js";
|
|
|
2
2
|
import {nxDiv} from "./_nxDiv.js";
|
|
3
3
|
|
|
4
4
|
class nxPanel extends nxDiv {
|
|
5
|
-
|
|
5
|
+
|
|
6
6
|
constructor() {
|
|
7
7
|
super();
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
connectedCallback() {
|
|
11
|
-
if (
|
|
12
|
-
|
|
13
|
-
console.log("==========", "child.connectedCallback");
|
|
14
|
-
|
|
15
|
-
this.#init();
|
|
11
|
+
if (super.connectedCallback()) this.#init();
|
|
16
12
|
}
|
|
17
13
|
|
|
18
14
|
#init = () => {
|
package/src/nx/nxSplitter.js
CHANGED
|
@@ -128,7 +128,7 @@ class nxSplitter extends HTMLElement {
|
|
|
128
128
|
const finalDragBarPos = isHorizontal ? parseFloat(dragBar.style.left) : parseFloat(dragBar.style.top);
|
|
129
129
|
const dragOffset = finalDragBarPos - initialSplitterPosInParent;
|
|
130
130
|
|
|
131
|
-
const prevSize = isHorizontal ? prev.getBoundingClientRect().width : prev.getBoundingClientRect().height
|
|
131
|
+
const prevSize = isHorizontal ? prev.getBoundingClientRect().width : prev.getBoundingClientRect().height;
|
|
132
132
|
const nextSize = isHorizontal ? next.getBoundingClientRect().width : next.getBoundingClientRect().height;
|
|
133
133
|
|
|
134
134
|
let newPrevSize = prevSize + dragOffset;
|