Timeline

Design System - Timeline component

The Checkbox is a simple selection control that allows users to make binary choices, such as selecting or deselecting options. It is commonly used in forms, preference settings, and multi-select scenarios, providing clear visual feedback for user actions.

// Sample code

<Timeline
  additionalElements={[
    <div key="1">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's</div>,
    <Button label="Click on the link" type="button" variation="link"/>,
    <img key="2" alt="Additional Element 2" src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQIGMLufj86aep95KwMzr3U0QShg7oxdAG8gBPJ9ALIFQ&s"/>,
    <img key="3" alt="Additional Element 3" src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQIGMLufj86aep95KwMzr3U0QShg7oxdAG8gBPJ9ALIFQ&s"/>,
    <img key="4" alt="Additional Element 4" src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQIGMLufj86aep95KwMzr3U0QShg7oxdAG8gBPJ9ALIFQ&s"/>,
    <img key="5" alt="Additional Element 5" src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQIGMLufj86aep95KwMzr3U0QShg7oxdAG8gBPJ9ALIFQ&s"/>,
    <img key="6" alt="Additional Element 6" src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQIGMLufj86aep95KwMzr3U0QShg7oxdAG8gBPJ9ALIFQ&s"/>,
    <img key="7" alt="Additional Element 7" src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcQIGMLufj86aep95KwMzr3U0QShg7oxdAG8gBPJ9ALIFQ&s"/>,
    <img key="8" alt="Additional Element 8" src="https://digit.org/wp-content/uploads/2023/06/Digit-Logo-1.png"/>,
    <Button icon="MyLocation" label="Button" type="button"/>,
    <Button icon="MyLocation" isSuffix label="Button" type="button" variation="secondary"/>
  ]}
  initialVisibleAdditionalElementsCount={8}
  label="Inprogress"
  showConnector
  subElements={[
    '26 / 03 / 2024',
    '11:00 PM',
    '26 / 03 / 2024 11:00 PM',
    '26 / 03 / 2024 11:00 PM Mon',
    '+91 **********'
  ]}
  variant="inprogress"
/>

Anatomy


Variants


Checked

The checked state indicates that the user has actively selected the option. It provides clear visual feedback with a filled checkbox, often accompanied by a checkmark. This state should be used when an option is explicitly chosen or enabled by default.

Intermediate The indeterminate state represents a mixed selection, typically used for parent checkboxes in multi-select scenarios. It visually signals that only some child options are selected, rather than all. This state does not appear by direct user interaction but is controlled programmatically to reflect partial selections.

Unchecked

The unchecked state indicates that the option is not selected. It appears as an empty checkbox, providing a clear visual cue that no action has been taken. This is the default state unless specified otherwise.

Properties

Label This property represents the text displayed inside the button. It is a required field and helps users understand the action that the button will trigger. The label should be concise and clear to communicate the button’s purpose effectively.

Disabled The “isDisabled” property disables the button, preventing any user interaction. It also applies a disabled visual style (like graying out the button) to indicate that the button is not active.

Icon The icon property specifies the name of the icon to be rendered inside the button. This helps provide a visual cue along with the button text. The icon placement can be either before or after the label based on the how the “Prefix” and “Suffix” properties are defined.

Size The size property specifies the size of the button. You can choose between "large", "medium", and "small" to adjust the button's height and font size.

Type The type property determines the HTML type attribute for the button, such as "submit", "button", or "actionButton". This is useful for form submission or defining button behavior in HTML forms.

Property Configuration Table

Each design component offers a range of configurable options. These options are intentionally platform-agnostic, allowing implementations to adapt and tailor them to align with the specific requirements of the chosen framework.

Property
Value
Default

label

string

-

subElements

array

-

variant

string

-

viewDetailsLabel

string

-

hideDetailsLabel

string

-

additionalElements

array

-

inline

boolean

-

indivdualElementStyles

object

{}

showConnector

boolean

-

className

string

-

isLastStep

boolean

-

isNextActiveStep

boolean

-

showDefaultValueForDate

boolean

-

isError

boolean

-

initialVisibleAdditionalElementsCount

number

-

Interaction State


Hover State

When a user hovers over the button, a visual cue is added to emphasize interactivity. This is achieved by introducing a subtle line below the button. The line appears as a clean, horizontal underline that complements the button's style, without overwhelming the design. The hover state enhances the button's affordance, guiding users and improving interactivity without altering the button’s primary layout or design.

Mousedown State

The Mouse Down state of the button represents the moment when the user clicks and holds the button. This state provides immediate feedback to the user, confirming that their interaction has been registered. The text label becomes bolder, emphasizing the active interaction

Usage Guide


Use for compact information display

Organise dense or hierarchical content like FAQs, step-by-step instructions

Change log


Date
Number
Notes

Design Checklist


All interactive states

Accessible use of colours

Accessible contrast for text

Accessible contrast for UI components

Keyboard interactions

Last updated

Was this helpful?