Base Attributes

All Whisper Components contain certain Attributes to help identify and style the component.

WhisperComponents are the individual elements, whether visible or not, that build up the UI of a Whisper in Olive Helps. While each type of component produces something different, they all have some attributes in common with each other, as described below:

type WhisperComponent {
    id?: string;
    type: WhisperComponentType;
    key?: string;
    layout?: LayoutOptions;
}

Descriptions

  • id (Optional):

    • id of the component

    • Used to maintain object state across Whisper Updates

    • undefined by default

  • type:

    • The type of component that the configuration object is creating. WhisperComponentType. Enumerations that includes Button, CheckBox, Markdown and etc.

    • This is automatically inferred when using JSX Whispers

  • key (Optional):

    • The key is used to maintain the object state across Whisper Updates

    • The component's key must be unique among its sibling components.

    • undefined by default

  • layout (Optional):

    • Defined LayoutOptions. Provides a way to configure the spacing and space occupied by individual components.

    • undefined by default.

    • Note: Some component types may have their own default styling.

Last updated