1 | <?php |
||
26 | class FontAwesomeTwigExtension extends AbstractFontAwesomeTwigExtension implements IconRendererInterface { |
||
27 | |||
28 | /** |
||
29 | * Service name. |
||
30 | * |
||
31 | * @var string |
||
32 | */ |
||
33 | const SERVICE_NAME = "webeweb.core.twig.extension.plugin.font_awesome"; |
||
34 | |||
35 | /** |
||
36 | * Constructor. |
||
37 | * |
||
38 | * @param Twig_Environment $twigEnvironment The wig environment. |
||
39 | */ |
||
40 | public function __construct(Twig_Environment $twigEnvironment) { |
||
43 | |||
44 | /** |
||
45 | * Displays a Font Awesome icon. |
||
46 | * |
||
47 | * @param array $args The arguments. |
||
48 | * @return string Returns the Font Awesome icon. |
||
49 | */ |
||
50 | public function fontAwesomeIconFunction(array $args = []) { |
||
53 | |||
54 | /** |
||
55 | * Displays a Font Awesome list. |
||
56 | * |
||
57 | * @param array|string $items The items. |
||
58 | * @return string Returns the Font Awesome list. |
||
59 | */ |
||
60 | public function fontAwesomeListFilter($items) { |
||
63 | |||
64 | /** |
||
65 | * Displays a Font Awesome list icon. |
||
66 | * |
||
67 | * @param string $icon The icon. |
||
68 | * @param string $content The content. |
||
69 | * @return string Returns the Font Awesome list icon. |
||
70 | */ |
||
71 | public function fontAwesomeListIconFilter($icon, $content) { |
||
74 | |||
75 | /** |
||
76 | * Get the Twig filters. |
||
77 | * |
||
78 | * @return Twig_SimpleFilter[] Returns the Twig filters. |
||
79 | */ |
||
80 | public function getFilters() { |
||
86 | |||
87 | /** |
||
88 | * Get the Twig functions. |
||
89 | * |
||
90 | * @return array Returns the Twig functions. |
||
91 | */ |
||
92 | public function getFunctions() { |
||
97 | |||
98 | /** |
||
99 | * {@inheritdoc} |
||
100 | */ |
||
101 | public function renderIcon($name, $style) { |
||
104 | |||
105 | } |
||
106 |