-
Notifications
You must be signed in to change notification settings - Fork 0
/
media_video_micromodal.module
55 lines (49 loc) · 1.02 KB
/
media_video_micromodal.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?php
/**
* @file
* Contains media_video_micromodal.module.
*/
use Drupal\Core\Routing\RouteMatchInterface;
/*
* @todo
* play image?
* x to close
* esc not working on close
*
* best way to include library
* isApplicable = video bundle
*
* CSS
* container width
*
*
*/
/**
* Implements hook_help().
*/
function media_video_micromodal_help($route_name, RouteMatchInterface $route_match) {
switch ($route_name) {
// Main module help for the media_video_micromodal module.
case 'help.page.media_video_micromodal':
$output = '';
$output .= '<h3>' . t('About') . '</h3>';
$output .= '<p>' . t('Displays media in a modal using micromodal.js.') . '</p>';
return $output;
default:
}
}
/**
* Implements hook_theme().
*/
function media_video_micromodal_theme() {
return [
'media_video_micromodal' => [
'render element' => 'children',
'variables' => [
'modal_id' => NULL,
'thumbnail_url' => NULL,
'iframe_src' => NULL,
],
],
];
}