@contember/react-utils
Advanced tools
Comparing version 2.0.0-alpha.19 to 2.0.0-alpha.20
@@ -1,5 +0,7 @@ | ||
import { px } from "@contember/utilities"; | ||
import { useCallback, useLayoutEffect } from "react"; | ||
import { unwrapRefValue } from "./unwrapRefValue.js"; | ||
import { useOnElementResize } from "./useOnElementResize.js"; | ||
function px(value) { | ||
return typeof value === "number" && !(isNaN(value) || value === Infinity || value === -Infinity) ? value + "px" : ""; | ||
} | ||
const useAutoHeightTextArea = (textAreaRef, value, minRows, maxRows) => { | ||
@@ -6,0 +8,0 @@ const measure = useCallback(async (ref, minRows2, maxRows2) => { |
@@ -1,5 +0,7 @@ | ||
import { px } from "@contember/utilities"; | ||
import { useCallback, useLayoutEffect } from "react"; | ||
import { unwrapRefValue } from "./unwrapRefValue.js"; | ||
import { useOnElementResize } from "./useOnElementResize.js"; | ||
function px(value) { | ||
return typeof value === "number" && !(isNaN(value) || value === Infinity || value === -Infinity) ? value + "px" : ""; | ||
} | ||
const useAutoHeightTextArea = (textAreaRef, value, minRows, maxRows) => { | ||
@@ -6,0 +8,0 @@ const measure = useCallback(async (ref, minRows2, maxRows2) => { |
{ | ||
"name": "@contember/react-utils", | ||
"license": "Apache-2.0", | ||
"version": "2.0.0-alpha.19", | ||
"version": "2.0.0-alpha.20", | ||
"type": "module", | ||
@@ -34,5 +34,4 @@ "sideEffects": false, | ||
"dependencies": { | ||
"@contember/utilities": "2.0.0-alpha.19", | ||
"fast-deep-equal": "^3.1.3" | ||
} | ||
} |
@@ -1,2 +0,1 @@ | ||
import { px } from '@contember/utilities' | ||
import { useCallback, useLayoutEffect } from 'react' | ||
@@ -6,2 +5,6 @@ import { RefObjectOrElement, unwrapRefValue } from './unwrapRefValue' | ||
function px<V extends number | false | null | undefined>(value?: V): string { | ||
return typeof value === 'number' && !(isNaN(value) || value === Infinity || value === -Infinity) ? value + 'px' : '' | ||
} | ||
export const useAutoHeightTextArea = ( | ||
@@ -8,0 +11,0 @@ textAreaRef: RefObjectOrElement<HTMLTextAreaElement>, |
@@ -10,4 +10,3 @@ { | ||
"references": [ | ||
{ "path": "../../utilities/src" } | ||
] | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2
4598
404066
- Removed@contember/utilities@2.0.0-alpha.19
- Removed@contember/utilities@2.0.0-alpha.19(transitive)