@aivex/ui 1.2.0-dev.6 → 1.2.0-dev.8
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/components/Textarea/Textarea.d.ts +7 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +38 -19
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -2,6 +2,12 @@ import type { ReactNode, Ref, TextareaHTMLAttributes } from "react";
|
|
|
2
2
|
export interface TextareaProps extends Omit<TextareaHTMLAttributes<HTMLTextAreaElement>, "size"> {
|
|
3
3
|
size?: "sm" | "md";
|
|
4
4
|
label?: string;
|
|
5
|
+
/**
|
|
6
|
+
* 글자수 카운터용 소프트 리밋. 값이 있으면 인풋 우하단(텍스트 아래)에 `현재 / 최대` 카운터를
|
|
7
|
+
* 표시하고, 초과해도 입력을 막지 않고 에러로 경고만 한다.
|
|
8
|
+
* (카운터/디자인 없이 입력만 하드컷하려면 네이티브 maxLength 를 그대로 사용하면 된다.)
|
|
9
|
+
*/
|
|
10
|
+
maxCount?: number;
|
|
5
11
|
/** 인풋 하단 도움말 텍스트 */
|
|
6
12
|
helperText?: string;
|
|
7
13
|
error?: boolean;
|
|
@@ -15,5 +21,5 @@ export interface TextareaProps extends Omit<TextareaHTMLAttributes<HTMLTextAreaE
|
|
|
15
21
|
endContent?: ReactNode;
|
|
16
22
|
ref?: Ref<HTMLTextAreaElement>;
|
|
17
23
|
}
|
|
18
|
-
declare function Textarea({ className, label, helperText, error, disabled, size, minHeight, fixedHeight, startContent, endContent, id, ref, onFocus, onBlur, ...props }: TextareaProps): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
declare function Textarea({ className, label, helperText, error, disabled, size, minHeight, fixedHeight, startContent, endContent, id, ref, onFocus, onBlur, maxCount, value, defaultValue, onChange, ...props }: TextareaProps): import("react/jsx-runtime").JSX.Element;
|
|
19
25
|
export { Textarea };
|