Components

A basic input field for user text entry.

Installation

npm install @mijn-ui/react-input

Usage

import { Input } from "@mijn-ui/react-input"
<Input />

Examples

Variants

Default

Underline

Danger

Disabled

Input with Icon

Input With Floating Label

Input Floating Label with Icon


API Reference

Standard element attributes are forwarded to the underlying component in addition to the props below.

PropTypeDefaultDescription
variant"default" | "underline" | "danger""default"Visual style of the input.
startIconReactNodeElement rendered at the start of the input.
endIconReactNodeElement rendered at the end of the input.
disabledbooleanfalseDisable the input.
unstyledbooleanfalseOpt out of the default styles to fully customize the component.
classNamesobjectOverride classes per slot (see Style Slots below).
classNamestringAdditional classes for the root element.

Input Style Slots

Slot NameTargeted ComponentPurpose
baseInputStyles the input component.
wrapperInputStyles the wrapper around the input field.
startIconInputStyles the icon displayed before the input.
endIconInputStyles the icon displayed after the input.
labelInputStyles the input label.