-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathviews_bootstrap.module
40 lines (35 loc) · 1.69 KB
/
views_bootstrap.module
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<?php
/**
* @file
* Custom functions for Views Bootstrap.
*/
use Drupal\Core\Routing\RouteMatchInterface;
use Drupal\views_bootstrap\ViewsBootstrap;
/**
* Implements hook_help().
*/
function views_bootstrap_help($route_name, RouteMatchInterface $route_match) {
switch ($route_name) {
case 'help.page.views_bootstrap':
$output = '';
$output .= '<h3>' . t('About') . '</h3>';
$output .= '<p>' . t('The <a href="https://www.drupal.org/project/views_bootstrap">Views Bootstrap module</a> adds styles to Views to output the results of a view as several common <a href="http://getbootstrap.com/components/">Twitter Bootstrap</a> components.') . '</p>';
$output .= '<h3>' . t('Uses') . '</h3>';
$output .= '<p>' . t('<a href="http://moduledev.dev/admin/structure/views/add">Create a view</a> using one of the following styles:') . '</p>';
$output .= '<ul>';
$output .= '<li>' . t('<a href="http://getbootstrap.com/css/#grid-example-basic">Grid</a>') . '</li>';
$output .= '<li>' . t('<a href="http://getbootstrap.com/css/#tables">Tables</a>') . '</li>';
$output .= '<li>' . t('<a href="http://getbootstrap.com/components/#media">Media object</a>') . '</li>';
$output .= '<li>' . t('<a href="http://getbootstrap.com/javascript/#collapse-example-accordion">Accordion</a>') . '</li>';
$output .= '<li>' . t('<a href="http://getbootstrap.com/javascript/#carousel">Carousel</a>') . '</li>';
$output .= '<li>' . t('<a href="http://getbootstrap.com/components/#list-group">List group</a>') . '</li>';
$output .= '<ul>';
return $output;
}
}
/**
* {@inheritdoc}
*/
function views_bootstrap_theme() {
return ViewsBootstrap::getThemeHooks();
}