Bangladesh

Plate input

Metro or district, class letter, six digits, and the plate drawn in Bangla as on the car.

Value: DHAKA METRO-GA 12-3456

Import#

Everything comes from the package root. The example above uses:

your-component.tsx
import { FormField, PlateInput } from "@waveinno/ui";

Props#

Read from the source of this version, so they match the code exactly.

<PlateInput>

src/components/ui/plate-input.tsx
PropTypeDefaultDescription
valuestring—
defaultValuestring""
onValueChange(plate: string, parts: PlateParts & { valid: boolean }) => void—
previewbooleantrueDraw the plate next to the fields. Default true.
plateScript"bn" | "latin""bn"
stateInputState"default"
disabledboolean—
classNamestring—

<FormField>

src/components/ui/form-field.tsx
PropTypeDefaultDescription
labelReact.ReactNode—
htmlForstring—The control's id, so clicking the label focuses it.
requiredboolean—
hintReact.ReactNode—
errorReact.ReactNode—
warningReact.ReactNode—
successReact.ReactNode—
count{ value: number; max: number }—Character counter, e.g. { value: note.length, max: 240 }.
classNamestring—
childrenrequiredReact.ReactNode—

Install#

If the project does not have the package yet, add it, then follow the setup for Next.js or Vite once.

$ npm install @waveinno/ui