Skip to content
Documentation

TimeInput

Input time in hours and minutes format

Overview
Miru dashboard in a light theme

The TimeInput component accepts numeric time values in hours and minutes.

Importing the TimeInput Component

To use the TimeInput component in our app, we need to import it from our styled components. Here’s how we can import it:

import { TimeInput } from "StyledComponents";

default timeinput

Using the TimeInput Component

The TimeInput component can be used with various props to control its appearance. Here are some examples of how we can use it:

<TimeInput
  className="h-8 w-20 rounded-sm bg-muted p-1 text-sm
  onTimeChange={() => ()}
/>
<TimeInput
  className="h-8 w-20 rounded-sm bg-muted p-1 text-sm placeholder:text-muted-foreground"
  initTime={duration}
  name="timeInput"
  onTimeChange={handleDurationChange}
/>

TimeInput Component Props

NameDescriptionDefault Value
initTimeProvide the initial time value for the input string""
disabledTo set input as disabled boolfalse
onTimeChangeTo specify the action to be triggered on changing of the input value func-
placeholderProvide the input placeholder value string"HH:MM"
classNameTo provide external classnames to input string""
nameProvide the name for the input string""
Try Miru

Read it once. Run it for real.

The docs explain the workflow. Miru gives you the actual timer, invoice, reports, and payment flow without another pile of tools.

Overview
Miru dashboard in a light theme
Workspace Miru