Note: Application logic should not interact with the component's properties or invoke its methods until the BusyContext indicates that the component is ready for interaction.
Slots
JET components that allow child content support slots. Please see the slots section of the JET component overview doc for more information on allowed slot content and slot types.
-
Default
-
The
defaultslot accepts a default text.Example
<oj-list-item-layout> <div> <oj-bind-text value="default"> </div> </oj-list-item-layout> -
action
-
The
actionslot for adding either one primary action or one or more secondary actions.Example
<oj-list-item-layout> <div slot="action"> <oj-button>Edit </div> </oj-list-item-layout> -
leading
-
The
leadingslot is used for adding a leading visual next to the selector. Start slot can be an image, avatar or initials.Example
<oj-list-item-layout> <oj-avatar slot='leading' role="img" size="xs" initials='[[item.data.initials]]' src="[[item.data.image]]" :aria-label="[['Avatar of ' + item.data.name]]" :title="[['Avatar of ' + item.data.name]]"> </oj-avatar> </oj-list-item-layout> -
metadata
-
The
metadatafor adding extra trailing information. Examples of metadata are author, date etc.Example
<oj-list-item-layout> <div slot="metadata"> <oj-bind-text value="metadata"> </div> </oj-list-item-layout> -
overline
-
The
overlineslot is for adding a overline text above the default text.Example
<oj-list-item-layout> <div slot="overline"> <oj-bind-text value="overline"> </div> </oj-list-item-layout> -
secondary
-
The
secondaryslot is for adding a secondary text below the default text.Example
<oj-list-item-layout> <div slot="secondary"> <oj-bind-text value="secondary"> </div> </oj-list-item-layout> -
selector
-
The
selectorslot can accept a oj-selector component and is optional.Example
<oj-list-item-layout> <oj-selector slot='selector' selected-keys='{{selectorSelectedItems}}' key='[[item.data.id]]'> </oj-selector> </oj-list-item-layout> -
tertiary
-
The
tertiaryslot is for adding a tertiary text below the secondary text.Example
<oj-list-item-layout> <div slot="tertiary"> <oj-bind-text value="tertiary"> </div> </oj-list-item-layout> -
trailing
-
The
trailingslot is used for adding a trailing visual.Example
<oj-list-item-layout> <oj-avatar slot='trailing' role="img" size="xs" initials='[[item.data.initials]]' src="[[item.data.image]]" :aria-label="[['Avatar of ' + item.data.name]]" :title="[['Avatar of ' + item.data.name]]"> </oj-avatar> </oj-list-item-layout>
Methods
-
getProperty(property) : {any}
-
Retrieves a value for a property or a single subproperty for complex properties.
Parameters:
Name Type Description propertystring The property name to get. Supports dot notation for subproperty access. Returns:
- Type
- any
-
setProperties(properties) : {void}
-
Performs a batch set of properties.
Parameters:
Name Type Description propertiesObject An object containing the property and value pairs to set. Returns:
- Type
- void
-
setProperty(property, value) : {void}
-
Sets a property or a single subproperty for complex properties and notifies the component of the change, triggering a [property]Changed event.
Parameters:
Name Type Description propertystring The property name to set. Supports dot notation for subproperty access. valueany The new value to set the property to. Returns:
- Type
- void