Improve this doc View source

pfViewUtils
service in module patternfly.views

Description

A utility constant to return view objects used for Dashboard, Card, Table, List, and Topology view switcher types.

Example

$scope.viewsConfig = {
  views: [pfViewUtils.getListView(), pfViewUtils.getCardView(), pfViewUtils.getTableView()]
};
Each getXxxxView() returns an object:

  • .id - (String) Unique id for the view, used for comparisons
  • .title - (String) Optional title, uses as a tooltip for the view selector
  • .iconClass - (String) Icon class to use for the view selector
Please see pfToolbar for use in Toolbar View Switcher