1 | <?php |
||
26 | class BadgeTwigExtension extends AbstractBadgeTwigExtension { |
||
27 | |||
28 | /** |
||
29 | * Service name. |
||
30 | * |
||
31 | * @var string |
||
32 | */ |
||
33 | const SERVICE_NAME = "wbw.bootstrap.twig.extension.component.badge"; |
||
34 | |||
35 | /** |
||
36 | * Displays a Bootstrap badge "danger". |
||
37 | * |
||
38 | * @param array $args The arguments. |
||
39 | * @return string Returns the Bootstrap badge "danger". |
||
40 | */ |
||
41 | public function bootstrapBadgeDangerFunction(array $args = []) { |
||
44 | |||
45 | /** |
||
46 | * Displays a Bootstrap badge "dark". |
||
47 | * |
||
48 | * @param array $args The arguments. |
||
49 | * @return string Returns the Bootstrap badge "dark". |
||
50 | */ |
||
51 | public function bootstrapBadgeDarkFunction(array $args = []) { |
||
54 | |||
55 | /** |
||
56 | * Displays a Bootstrap badge. |
||
57 | * |
||
58 | * @param array $args The arguments. |
||
59 | * @return string Returns the Bootstrap badge. |
||
60 | */ |
||
61 | public function bootstrapBadgeFunction(array $args = []) { |
||
64 | |||
65 | /** |
||
66 | * Displays a Bootstrap badge "info". |
||
67 | * |
||
68 | * @param array $args The arguments. |
||
69 | * @return string Returns the Bootstrap badge "info". |
||
70 | */ |
||
71 | public function bootstrapBadgeInfoFunction(array $args = []) { |
||
74 | |||
75 | /** |
||
76 | * Displays a Bootstrap badge "light". |
||
77 | * |
||
78 | * @param array $args The arguments. |
||
79 | * @return string Returns the Bootstrap badge "light". |
||
80 | */ |
||
81 | public function bootstrapBadgeLightFunction(array $args = []) { |
||
84 | |||
85 | /** |
||
86 | * Transforms a Bootstrap badge into an anchor. |
||
87 | * |
||
88 | * @param string $button The button. |
||
89 | * @param string $href The href attribute. |
||
90 | * @param string $target The target attribute. |
||
91 | * @return string Returns the Bootstrap badge transformed into an anchor. |
||
92 | */ |
||
93 | public function bootstrapBadgeLinkFilter($button, $href = self::DEFAULT_HREF, $target = null) { |
||
100 | |||
101 | /** |
||
102 | * Displays a Bootstrap badge "primary". |
||
103 | * |
||
104 | * @param array $args The arguments. |
||
105 | * @return string Returns the Bootstrap badge "primary". |
||
106 | */ |
||
107 | public function bootstrapBadgePrimaryFunction(array $args = []) { |
||
110 | |||
111 | /** |
||
112 | * Displays a Bootstrap badge "secondary". |
||
113 | * |
||
114 | * @param array $args The arguments. |
||
115 | * @return string Returns the Bootstrap badge "secondary". |
||
116 | */ |
||
117 | public function bootstrapBadgeSecondaryFunction(array $args = []) { |
||
120 | |||
121 | /** |
||
122 | * Displays a Bootstrap badge "success". |
||
123 | * |
||
124 | * @param array $args The arguments. |
||
125 | * @return string Returns the Bootstrap badge "success". |
||
126 | */ |
||
127 | public function bootstrapBadgeSuccessFunction(array $args = []) { |
||
130 | |||
131 | /** |
||
132 | * Displays a Bootstrap badge "warning". |
||
133 | * |
||
134 | * @param array $args The arguments. |
||
135 | * @return string Returns the Bootstrap badge "warning". |
||
136 | */ |
||
137 | public function bootstrapBadgeWarningFunction(array $args = []) { |
||
140 | |||
141 | /** |
||
142 | * Get the Twig filters. |
||
143 | * |
||
144 | * @return TwigFilter[] Returns the Twig filters. |
||
145 | */ |
||
146 | public function getFilters() { |
||
152 | |||
153 | /** |
||
154 | * Get the Twig functions. |
||
155 | * |
||
156 | * @return TwigFunction[] Returns the Twig functions. |
||
157 | */ |
||
158 | public function getFunctions() { |
||
164 | |||
165 | /** |
||
166 | * Get the Twig functions. |
||
167 | * |
||
168 | * @return TwigFunction[] Returns the Twig functions. |
||
169 | */ |
||
170 | public function getFunctions3() { |
||
176 | |||
177 | /** |
||
178 | * Get the Twig functions. |
||
179 | * |
||
180 | * @return TwigFunction[] Returns the Twig functions. |
||
181 | */ |
||
182 | public function getFunctions4() { |
||
209 | } |
||
210 |