You are here

function content_browser_views_data_alter in Content Browser 8

Implements hook_views_data_alter().

File

./content_browser.views.inc, line 11
Provide custom views data for rendering content previews.

Code

function content_browser_views_data_alter(&$data) {

  // For now only support Nodes, eventually loop through all known Content
  // Entity types.
  $data['node']['content_browser_preview'] = [
    'title' => t('Content Browser Preview'),
    'help' => t('Displays a rendered preview of the content.'),
    'field' => [
      'id' => 'content_browser_preview',
    ],
  ];
}