Skip to content

FormMessage ​

Text hint/error dùng bởi FormField (cũng dùng độc lập được).

ts
import { FormMessage } from "@minap/ui";

Examples ​

Mẫu sống trong Preview; chọn View code khi cần copy.

Usage ​

tsx
import { FormMessage } from "@minap/ui";

export function Example() {
  return (
    <>
      <FormMessage tone="hint">Hint message</FormMessage>
      <FormMessage tone="error" role="alert">
        Error message
      </FormMessage>
    </>
  );
}

Props / API ​

Prop / APITypeDefaultNotes
tone"hint" | "error""hint"
idstring—Cho aria-describedby
rolestring—Dùng alert cho lỗi

Behavior ​

  • Khác FormMessage của @minap/ui/form (RHF)

MINAP UI — Soft Periwinkle light, Mobile-First