1 | <?php namespace Arcanesoft\Core\Helpers\UI; |
||
14 | class Label |
||
15 | { |
||
16 | /* ----------------------------------------------------------------- |
||
17 | | Main Methods |
||
18 | | ----------------------------------------------------------------- |
||
19 | */ |
||
20 | /** |
||
21 | * Generate active icon label. |
||
22 | * |
||
23 | * @param bool $active |
||
24 | * @param array $options |
||
25 | * @param bool $withTooltip |
||
26 | * |
||
27 | * @return \Illuminate\Support\HtmlString |
||
28 | */ |
||
29 | 6 | public static function activeIcon($active, array $options = [], $withTooltip = true) |
|
53 | |||
54 | /** |
||
55 | * Generate active status label. |
||
56 | * |
||
57 | * @param bool $active |
||
58 | * @param array $options |
||
59 | * |
||
60 | * @return \Illuminate\Support\HtmlString |
||
61 | */ |
||
62 | public static function activeStatus($active, array $options = []) |
||
80 | |||
81 | /** |
||
82 | * Generate count label. |
||
83 | * |
||
84 | * @param int|float $count |
||
85 | * @param array $options |
||
86 | * |
||
87 | * @return \Illuminate\Support\HtmlString |
||
88 | */ |
||
89 | 9 | public static function count($count, array $options = []) { |
|
102 | |||
103 | /** |
||
104 | * Generate locked icon label. |
||
105 | * |
||
106 | * @param bool $locked |
||
107 | * @param array $options |
||
108 | * @param bool $withTooltip |
||
109 | * |
||
110 | * @return \Illuminate\Support\HtmlString |
||
111 | */ |
||
112 | 6 | public static function lockedIcon($locked, array $options = [], $withTooltip = true) |
|
136 | |||
137 | /** |
||
138 | * Generate locked status label. |
||
139 | * |
||
140 | * @param bool $locked |
||
141 | * @param array $options |
||
142 | * @param bool $withIcon |
||
143 | * |
||
144 | * @return \Illuminate\Support\HtmlString |
||
145 | */ |
||
146 | 6 | public static function lockedStatus($locked, array $options = [], $withIcon = true) |
|
170 | |||
171 | /** |
||
172 | * Generate trashed icon label. |
||
173 | * |
||
174 | * @param array $options |
||
175 | * @return \Illuminate\Support\HtmlString |
||
176 | */ |
||
177 | 6 | public static function trashedStatus(array $options = [], $withIcon = true) |
|
189 | |||
190 | /* ----------------------------------------------------------------- |
||
191 | | Other Methods |
||
192 | | ----------------------------------------------------------------- |
||
193 | */ |
||
194 | /** |
||
195 | * Generate the label. |
||
196 | * |
||
197 | * @param mixed $value |
||
198 | * @param array $attributes |
||
199 | * |
||
200 | * @return \Illuminate\Support\HtmlString |
||
201 | */ |
||
202 | 33 | protected static function generate($value, array $attributes = []) |
|
208 | |||
209 | /** |
||
210 | * Generate the label with tooltip. |
||
211 | * |
||
212 | * @param string $value |
||
213 | * @param string $title |
||
214 | * @param array $attributes |
||
215 | * |
||
216 | * @return \Illuminate\Support\HtmlString |
||
217 | */ |
||
218 | 6 | protected static function generateWithTooltip($value, $title, array $attributes = []) |
|
225 | |||
226 | /** |
||
227 | * Generate the label with icon & text as value. |
||
228 | * |
||
229 | * @param string $value |
||
230 | * @param string $icon |
||
231 | * @param array $attributes |
||
232 | * |
||
233 | * @return \Illuminate\Support\HtmlString |
||
234 | */ |
||
235 | 6 | protected static function generateWithIcon($value, $icon, array $attributes = []) |
|
239 | |||
240 | /** |
||
241 | * Generate icon tag. |
||
242 | * |
||
243 | * @param string $class |
||
244 | * |
||
245 | * @return string |
||
246 | */ |
||
247 | 18 | protected static function generateIcon($class) |
|
251 | } |
||
252 |