-
Notifications
You must be signed in to change notification settings - Fork 4
/
Comment.php
45 lines (41 loc) · 967 Bytes
/
Comment.php
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
<?php
/**
* Comment
*
* This file is part of Grav Shortcodes plugin.
*
* Dual licensed under the MIT or GPL Version 3 licenses, see LICENSE.
* http://benjamin-regler.de/license/
*/
namespace Grav\Plugin\Shortcodes\Shortcodes;
use RocketTheme\Toolbox\Event\Event;
use Grav\Plugin\Shortcodes\Shortcode;
/**
* Comment
*
* Comment allows you to use comments and annotations in a markdown
* document without being outputted to the user.
*/
class Comment extends Shortcode
{
/**
* Get informations about the shortcode.
*
* @return array An associative array needed to register the shortcode.
*/
public function getShortcode()
{
return ['name' => 'comment', 'type' => 'block'];
}
/**
* Execute shortcode.
*
* @param Event $event An event object.
* @return string|null Return modified contents.
*/
public function execute(Event $event)
{
// Empty (ignore all body content)
return '';
}
}