@websolutespa/bom-mixer-hooks 1.8.9 → 1.8.10
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/CHANGELOG.md
CHANGED
package/dist/index.js
CHANGED
|
@@ -291,8 +291,8 @@ var import_react3 = require("react");
|
|
|
291
291
|
function useAutosizeTextArea(textAreaRef, value) {
|
|
292
292
|
(0, import_react3.useEffect)(() => {
|
|
293
293
|
if (textAreaRef) {
|
|
294
|
-
textAreaRef.style.
|
|
295
|
-
textAreaRef.style.
|
|
294
|
+
textAreaRef.style.minHeight = "0px";
|
|
295
|
+
textAreaRef.style.minHeight = textAreaRef.scrollHeight + "px";
|
|
296
296
|
}
|
|
297
297
|
}, [textAreaRef, value]);
|
|
298
298
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -144,8 +144,8 @@ import { useEffect as useEffect2 } from "react";
|
|
|
144
144
|
function useAutosizeTextArea(textAreaRef, value) {
|
|
145
145
|
useEffect2(() => {
|
|
146
146
|
if (textAreaRef) {
|
|
147
|
-
textAreaRef.style.
|
|
148
|
-
textAreaRef.style.
|
|
147
|
+
textAreaRef.style.minHeight = "0px";
|
|
148
|
+
textAreaRef.style.minHeight = textAreaRef.scrollHeight + "px";
|
|
149
149
|
}
|
|
150
150
|
}, [textAreaRef, value]);
|
|
151
151
|
}
|
package/package.json
CHANGED
|
@@ -6,8 +6,8 @@ export function useAutosizeTextArea(
|
|
|
6
6
|
) {
|
|
7
7
|
useEffect(() => {
|
|
8
8
|
if (textAreaRef) {
|
|
9
|
-
textAreaRef.style.
|
|
10
|
-
textAreaRef.style.
|
|
9
|
+
textAreaRef.style.minHeight = '0px';
|
|
10
|
+
textAreaRef.style.minHeight = textAreaRef.scrollHeight + 'px';
|
|
11
11
|
}
|
|
12
12
|
}, [textAreaRef, value]);
|
|
13
13
|
}
|