use of com.adobe.cq.wcm.core.components.models.datalayer.ComponentData in project aem-core-wcm-components by Adobe-Marketing-Cloud.
the class CarouselImpl method getDataLayerShownItems.
/*
* DataLayerProvider implementation of field getters
*/
@Override
public String[] getDataLayerShownItems() {
String[] shownItems = new String[0];
List<ListItem> items = getItems();
if (!items.isEmpty()) {
ComponentData componentData = items.get(0).getData();
if (componentData != null) {
shownItems = new String[] { componentData.getId() };
}
}
return shownItems;
}
Aggregations