pfListView
patternfly.views
Component for rendering a list view.
Pass a customScope object containing any scope variables/functions you need to access from the transcluded source, access these
via 'customScope' in your transcluded hmtl.
If using expanding rows, use a list-expanded-content element containing expandable content for each row. Item data can be accessed inside list-expanded-content by using $parent.item.property. For each item in the items array, the expansion can be disabled by setting disableRowExpansion to true on the item.
<pf-list-view items="{array}" config="{object}" action-buttons="{array}" enable-button-for-item-fn="{function (action, item))}" menu-actions="{array}" hide-menu-for-item-fn="{function (item))}" menu-class-for-item-fn="{function (item))}" update-menu-action-for-item-fn="{function (action, item))}" custom-scope="{object}"> </pf-list-view>
Param | Type | Details |
---|---|---|
items | array | Array of items to display in the list view. If an item in the array has a 'rowClass' field, the value of this field will be used as a class specified on the row (list-group-item). |
config | object | Configuration settings for the list view:
|
actionButtons | array | List of action buttons in each row
|
enableButtonForItemFn | function (action, item) | function(action, item) Used to enabled/disable an action button based on the current item |
menuActions | array | List of actions for dropdown menu in each row
|
hideMenuForItemFn | function (item) | function(item) Used to hide all menu actions for a particular item |
menuClassForItemFn | function (item) | function(item) Used to specify a class for an item's dropdown kebab |
updateMenuActionForItemFn | function (action, item) | function(action, item) Used to update a menu action based on the current item |
customScope | object | Object containing any variables/functions used by the transcluded html, access via customScope. |