publ-echo-test 0.0.48 → 0.0.49
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.
@@ -55,6 +55,7 @@ var Resizable = function (_a) {
|
|
55
55
|
var extendedHeightRef = useRef(null);
|
56
56
|
var shouldShrinkRef = useRef(false);
|
57
57
|
var minWidth = useRef(0);
|
58
|
+
var minHeight = useRef(props.height);
|
58
59
|
useEffect(function () {
|
59
60
|
var _a;
|
60
61
|
if (!autoResize) {
|
@@ -74,12 +75,16 @@ var Resizable = function (_a) {
|
|
74
75
|
return;
|
75
76
|
}
|
76
77
|
var target = (_a = placeholder.children[0].children[0].children[0]) !== null && _a !== void 0 ? _a : placeholder.children[0].children[0];
|
78
|
+
if (target.clientHeight) {
|
79
|
+
minHeight.current = target.clientHeight;
|
80
|
+
}
|
81
|
+
// target.clientHeight -> 실제 "노드"의 height. (gridItem아닌)
|
77
82
|
if (target.clientHeight > elementRef.current.clientHeight) {
|
78
83
|
extendedHeightRef.current = target.clientHeight;
|
79
84
|
shouldShrinkRef.current = true;
|
80
85
|
}
|
81
86
|
else {
|
82
|
-
|
87
|
+
extendedHeightRef.current = null;
|
83
88
|
}
|
84
89
|
if (shouldShrinkRef.current && (target.clientHeight < elementRef.current.clientHeight)) {
|
85
90
|
extendedHeightRef.current = target.clientHeight;
|
@@ -218,6 +223,9 @@ var Resizable = function (_a) {
|
|
218
223
|
}
|
219
224
|
// width = Math.max(width, minWidth.current);
|
220
225
|
// const isOverMin = calcWH()
|
226
|
+
if (minHeight.current) {
|
227
|
+
height = Math.max(minHeight.current, height);
|
228
|
+
}
|
221
229
|
if (extendedHeightRef.current) {
|
222
230
|
height = extendedHeightRef.current;
|
223
231
|
handleAxis = removeNorthHandle(handleAxis);
|