Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

A time picker allows the user to either insert enter a time manually or set hours and minutes using up /down arrowsand down buttons.

Two time pickers can be used, for start and end times, to allow the user to enter a time range.

Usage & Behavior

General guidelines

  • Note: the user The user’s time format (24 hours or 12 hours with AM/PM indicator) can be set on the preferences by the user in the Preferences window.

Structure

A time picker is a combination Time pickers consist of:

  • Time input field - In the input field, the user can enter a time directly. The time can be directly edited here.

  • Time picker button - clicking the picker . An Icon Button which opens the time picker dropdown.UP/Down arrows - drop-down.

  • Time picker drop-down, which consists of:

    • Hours and minutes fields. Can be directly edited when selected.

    • Up and Down arrows. Clicking those arrows increases

    /decreases the hours/minutes accordingly.Hours/Miutes input fields - the labels holding the hours/minutes becomes an input field when the user selects the hours/minutes in the menu in order to change them
    • or decreases the hours and minutes in increments of 1.

    • AM/PM label

    -
    • . Appears when the user’s time format is set to 12 hours. Clicking this toggles between AM

    /
    • and PM.

States

State

Visual

Regular

Hover

Active

Disabled

Error

Warning

Focused

Focused, Hover

Focused, Active

Focused, Disabled

Interaction

...

The time can be set either via direct input or by using the controls in the time picker drop-down.

Direct input

  • The time picker can have an initial value

    that

    , which the user can

    overwrite

    edit at any time.

  • Open the picker dropdown with one click on the picker button.

  • Close the
  • picker dropdown by clicking outside the frame

    Clicking on the clock icon button will open the picker drop-down.

  • Clicking outside the picker drop-down will close it.

  • Allow the user

    the insert

    to enter dates in loose formats

  • “5:08“ becomes “05:08“

  • “508” becomes “05:08”

    , which should be automatically corrected.

    • 5:08 becomes 05:08

    • 508 becomes 05:08

    • When the user’s time format is set to 12 hours,

      “15

      15:

      08”

      08 becomes

      “03

      03:08

      PM“

      PM.

Menu

  • Click the up/down arrows to move between the hours/

    Clicking on the Up and Down arrows will increase or decrease the hours or minutes accordingly.

  • The iteration is

    cyclic. For example

    cyclical:

    • When the hours

      - when you

      are set

      on “12” hours and click to “up” arrow, you start from “1”.
    • minutes - when you are set on “00” and press the “down” arrow you get “59”.

    • Clicking AM/PM label to 12 (in 12 hour time format) and the up arrow is clicked, the value loops back to 1.

    • When the minutes are set to 00 and the down arrow is clicked, the value changes to 59.

  • Clicking the AM/PM icon toggles between the 2 options.

  • Changing values in the

    popover, updates the input respectively

    drop-down will also update the values in the top input field accordingly.

  • Clicking the hours

    /minutes changes the label into an input field in which

    or minutes will change them into a Text Field, where the user can directly type the required value. When the input field looses focus, the time will be updated in the top input field

    showing the time, is updated

    accordingly.

Validation and Errors

Please refer to Field validation page for more information.

...

A time field with an error will have a red border and an error icon, as displayed below:

Best practices

Use a time picker when:

  • You want the user to select a time or set a time.

  • You want the user to select a time range. In this case, one time picker can be used to set the starting start time and a second one to set the end time.

Don’t use:

  • For any input other than time.

Accessibility Compliance

Unless otherwise specified, see our general compliance information in Fundamentals - Accessibility.

Design

Zeplin Link

Thumbnail

https://zpl.io/adOXdRV



...

New LUX design design

Html macro
sanitizefalse
<link rel="stylesheet" href="https://ux.verint.com/bootstrap-4.0.0/dist/fonts/css/verint_lux.css">
<link rel="stylesheet" href="https://ux.verint.com/bootstrap-4.0.0/dist/css/bootstrap.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://ux.verint.com/bootstrap-4.0.0/dist/js/bootstrap.bundle.js"></script>
<script src="https://ux.verint.com/bootstrap-4.0.0/dist/other/accessibility.js"></script>
<script src="https://ux.verint.com/bootstrap-4.0.0/dist/other/prism.min.js"></script>
<link rel="stylesheet" href="https://ux.verint.com/bootstrap-4.0.0/dist/other/prism-coy.min.css">

<div class="card">
			<div class="card-header">Date Picker <button id="toggleMarkup" type="button" class="btn btn-sm btn-outline-primary btn btn-fixed-width float-right m-0" onclick="$('pre' ).toggle()">Toggle Markup</button></div>
			<div class="card-body">
				<form>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm">Regular</label>
						<div class="col-lg-4">
							<input type="date" class="form-control form-control-sm" placeholder="Guiding Text">
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="date" class="form-control form-control-sm" placeholder="Guiding Text"></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm"></label>
						<div class="col-lg-4">
							<input type="date" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text">
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="date" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text"></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm">Disabled</label>
						<div class="col-lg-4">
							<input type="date" class="form-control form-control-sm" placeholder="Guiding Text" disabled>
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="date" class="form-control form-control-sm" placeholder="Guiding Text" disabled></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm"></label>
						<div class="col-lg-4">
							<input type="date" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text" disabled>
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="date" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text" disabled></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm">Read-Only</label>
						<div class="col-lg-4">
							<input type="date" class="form-control form-control-sm" placeholder="Guiding Text" readonly>
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="date" class="form-control form-control-sm" placeholder="Guiding Text" readonly></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm"></label>
						<div class="col-lg-4">
							<input type="date" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text" readonly>
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="date" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text" readonly></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm">Error</label>
						<div class="col-lg-4">
							<input type="date" class="form-control form-control-sm is-invalid" placeholder="Guiding Text">
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="date" class="form-control form-control-sm is-invalid" placeholder="Guiding Text"></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm"></label>
						<div class="col-lg-4">
							<input type="date" class="form-control form-control-sm is-invalid" placeholder="Guiding Text" value="Filled Text">
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="date" class="form-control form-control-sm is-invalid" placeholder="Guiding Text" value="Filled Text"></script></code></pre>
						</div>
					</div>
				</form>
			</div>
		</div>
		<div class="card">
			<div class="card-header">Time Picker</div>
			<div class="card-body">
				<form>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm">Regular</label>
						<div class="col-lg-4">
							<input type="time" class="form-control form-control-sm" placeholder="Guiding Text">
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="time" class="form-control form-control-sm" placeholder="Guiding Text"></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm"></label>
						<div class="col-lg-4">
							<input type="time" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text">
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="time" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text"></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm">Disabled</label>
						<div class="col-lg-4">
							<input type="time" class="form-control form-control-sm" placeholder="Guiding Text" disabled>
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="time" class="form-control form-control-sm" placeholder="Guiding Text" disabled></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm"></label>
						<div class="col-lg-4">
							<input type="time" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text" disabled>
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="time" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text" disabled></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm">Read-Only</label>
						<div class="col-lg-4">
							<input type="time" class="form-control form-control-sm" placeholder="Guiding Text" readonly>
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="time" class="form-control form-control-sm" placeholder="Guiding Text" readonly></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm"></label>
						<div class="col-lg-4">
							<input type="time" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text" readonly>
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="time" class="form-control form-control-sm" placeholder="Guiding Text" value="Filled Text" readonly></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm">Error</label>
						<div class="col-lg-4">
							<input type="time" class="form-control form-control-sm is-invalid" placeholder="Guiding Text">
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="time" class="form-control form-control-sm is-invalid" placeholder="Guiding Text"></script></code></pre>
						</div>
					</div>
					<div class="form-group row">
						<label for="inputKey" class="col-lg-2 col-form-label col-form-label-sm"></label>
						<div class="col-lg-4">
							<input type="time" class="form-control form-control-sm is-invalid" placeholder="Guiding Text" value="Filled Text">
						</div>
						<div class="col-lg-6">
							<pre class="language-html"><code><script type="prism-html-markup"><input type="time" class="form-control form-control-sm is-invalid" placeholder="Guiding Text" value="Filled Text"></script></code></pre>
						</div>
					</div>
				</form>
			</div>
		</div>

...