@yamada-ui/react
Version:
React UI components of the Yamada, by the Yamada, for the Yamada built with React and Emotion
30 lines (29 loc) • 928 B
TypeScript
import { HTMLProps, PropGetter } from "../../core/components/index.types.js";
import "../../core/index.js";
import { UseAutosizeProps } from "./use-autosize.js";
import { ForwardedRef } from "react";
//#region src/components/textarea/use-textarea.d.ts
interface UseTextareaProps extends HTMLProps<"textarea">, Omit<UseAutosizeProps, "disabled" | "ref"> {
/**
* If `true`, the Textarea height auto-adjusts to text height.
*/
autosize?: boolean;
/**
* Ref to a resize function.
*/
resizeRef?: ForwardedRef<() => void>;
}
declare const useTextarea: ({
autosize,
maxRows,
minRows,
resizeRef,
...rest
}?: UseTextareaProps) => {
getTextareaProps: PropGetter<"textarea", undefined, undefined>;
onResizeTextarea: () => void;
};
type UseTextareaReturn = ReturnType<typeof useTextarea>;
//#endregion
export { UseTextareaProps, UseTextareaReturn, useTextarea };
//# sourceMappingURL=use-textarea.d.ts.map