Skip to content

Commit 7331c07

Browse files
committed
Html: added @Property & @method
1 parent bd813cc commit 7331c07

1 file changed

Lines changed: 216 additions & 7 deletions

File tree

src/Utils/Html.php

Lines changed: 216 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,20 +9,229 @@
99

1010
namespace Nette\Utils;
1111

12+
use function is_array;
13+
use is_float;
14+
use is_object;
15+
use is_string;
1216
use Nette;
13-
use function is_array, is_float, is_object, is_string;
1417

1518

1619
/**
1720
* HTML helper.
1821
*
19-
* <code>
20-
* $el = Html::el('a')->href($link)->setText('Nette');
21-
* $el->class = 'myclass';
22-
* echo $el;
22+
* @property string|null $accept
23+
* @property string|null $accesskey
24+
* @property string|null $action
25+
* @property string|null $align
26+
* @property string|null $allow
27+
* @property string|null $alt
28+
* @property bool|null $async
29+
* @property string|null $autocapitalize
30+
* @property string|null $autocomplete
31+
* @property bool|null $autofocus
32+
* @property bool|null $autoplay
33+
* @property string|null $charset
34+
* @property bool|null $checked
35+
* @property string|null $cite
36+
* @property string|null $class
37+
* @property int|null $cols
38+
* @property int|null $colspan
39+
* @property string|null $content
40+
* @property bool|null $contenteditable
41+
* @property bool|null $controls
42+
* @property string|null $coords
43+
* @property string|null $crossorigin
44+
* @property string|null $data
45+
* @property string|null $datetime
46+
* @property string|null $decoding
47+
* @property bool|null $default
48+
* @property bool|null $defer
49+
* @property string|null $dir
50+
* @property string|null $dirname
51+
* @property bool|null $disabled
52+
* @property bool|null $download
53+
* @property string|null $draggable
54+
* @property string|null $dropzone
55+
* @property string|null $enctype
56+
* @property string|null $for
57+
* @property string|null $form
58+
* @property string|null $formaction
59+
* @property string|null $formenctype
60+
* @property string|null $formmethod
61+
* @property bool|null $formnovalidate
62+
* @property string|null $formtarget
63+
* @property string|null $headers
64+
* @property int|null $height
65+
* @property bool|null $hidden
66+
* @property float|null $high
67+
* @property string|null $href
68+
* @property string|null $hreflang
69+
* @property string|null $id
70+
* @property string|null $integrity
71+
* @property string|null $inputmode
72+
* @property bool|null $ismap
73+
* @property string|null $itemprop
74+
* @property string|null $kind
75+
* @property string|null $label
76+
* @property string|null $lang
77+
* @property string|null $list
78+
* @property bool|null $loop
79+
* @property float|null $low
80+
* @property float|null $max
81+
* @property int|null $maxlength
82+
* @property int|null $minlength
83+
* @property string|null $media
84+
* @property string|null $method
85+
* @property float|null $min
86+
* @property bool|null $multiple
87+
* @property bool|null $muted
88+
* @property string|null $name
89+
* @property bool|null $novalidate
90+
* @property bool|null $open
91+
* @property float|null $optimum
92+
* @property string|null $pattern
93+
* @property string|null $ping
94+
* @property string|null $placeholder
95+
* @property string|null $poster
96+
* @property string|null $preload
97+
* @property string|null $radiogroup
98+
* @property bool|null $readonly
99+
* @property string|null $rel
100+
* @property bool|null $required
101+
* @property bool|null $reversed
102+
* @property int|null $rows
103+
* @property int|null $rowspan
104+
* @property string|null $sandbox
105+
* @property string|null $scope
106+
* @property bool|null $selected
107+
* @property string|null $shape
108+
* @property int|null $size
109+
* @property string|null $sizes
110+
* @property string|null $slot
111+
* @property int|null $span
112+
* @property string|null $spellcheck
113+
* @property string|null $src
114+
* @property string|null $srcdoc
115+
* @property string|null $srclang
116+
* @property string|null $srcset
117+
* @property int|null $start
118+
* @property float|null $step
119+
* @property string|null $style
120+
* @property int|null $tabindex
121+
* @property string|null $target
122+
* @property string|null $title
123+
* @property string|null $translate
124+
* @property string|null $type
125+
* @property string|null $usemap
126+
* @property string|null $value
127+
* @property int|null $width
128+
* @property string|null $wrap
23129
*
24-
* echo $el->startTag(), $el->endTag();
25-
* </code>
130+
* @method self accept(?string $val)
131+
* @method self accesskey(?string $val, bool $state = null)
132+
* @method self action(?string $val)
133+
* @method self align(?string $val)
134+
* @method self allow(?string $val, bool $state = null)
135+
* @method self alt(?string $val)
136+
* @method self async(?bool $val)
137+
* @method self autocapitalize(?string $val)
138+
* @method self autocomplete(?string $val)
139+
* @method self autofocus(?bool $val)
140+
* @method self autoplay(?bool $val)
141+
* @method self charset(?string $val)
142+
* @method self checked(?bool $val)
143+
* @method self cite(?string $val)
144+
* @method self class(?string $val, bool $state = null)
145+
* @method self cols(?int $val)
146+
* @method self colspan(?int $val)
147+
* @method self content(?string $val)
148+
* @method self contenteditable(?bool $val)
149+
* @method self controls(?bool $val)
150+
* @method self coords(?string $val)
151+
* @method self crossorigin(?string $val)
152+
* @method self datetime(?string $val)
153+
* @method self decoding(?string $val)
154+
* @method self default(?bool $val)
155+
* @method self defer(?bool $val)
156+
* @method self dir(?string $val)
157+
* @method self dirname(?string $val)
158+
* @method self disabled(?bool $val)
159+
* @method self download(?bool $val)
160+
* @method self draggable(?string $val)
161+
* @method self dropzone(?string $val)
162+
* @method self enctype(?string $val)
163+
* @method self for(?string $val)
164+
* @method self form(?string $val)
165+
* @method self formaction(?string $val)
166+
* @method self formenctype(?string $val)
167+
* @method self formmethod(?string $val)
168+
* @method self formnovalidate(?bool $val)
169+
* @method self formtarget(?string $val)
170+
* @method self headers(?string $val, bool $state = null)
171+
* @method self height(?int $val)
172+
* @method self hidden(?bool $val)
173+
* @method self high(?float $val)
174+
* @method self hreflang(?string $val)
175+
* @method self id(?string $val)
176+
* @method self integrity(?string $val)
177+
* @method self inputmode(?string $val)
178+
* @method self ismap(?bool $val)
179+
* @method self itemprop(?string $val)
180+
* @method self kind(?string $val)
181+
* @method self label(?string $val)
182+
* @method self lang(?string $val)
183+
* @method self list(?string $val)
184+
* @method self loop(?bool $val)
185+
* @method self low(?float $val)
186+
* @method self max(?float $val)
187+
* @method self maxlength(?int $val)
188+
* @method self minlength(?int $val)
189+
* @method self media(?string $val)
190+
* @method self method(?string $val)
191+
* @method self min(?float $val)
192+
* @method self multiple(?bool $val)
193+
* @method self muted(?bool $val)
194+
* @method self name(?string $val)
195+
* @method self novalidate(?bool $val)
196+
* @method self open(?bool $val)
197+
* @method self optimum(?float $val)
198+
* @method self pattern(?string $val)
199+
* @method self ping(?string $val, bool $state = null)
200+
* @method self placeholder(?string $val)
201+
* @method self poster(?string $val)
202+
* @method self preload(?string $val)
203+
* @method self radiogroup(?string $val)
204+
* @method self readonly(?bool $val)
205+
* @method self rel(?string $val)
206+
* @method self required(?bool $val)
207+
* @method self reversed(?bool $val)
208+
* @method self rows(?int $val)
209+
* @method self rowspan(?int $val)
210+
* @method self sandbox(?string $val, bool $state = null)
211+
* @method self scope(?string $val)
212+
* @method self selected(?bool $val)
213+
* @method self shape(?string $val)
214+
* @method self size(?int $val)
215+
* @method self sizes(?string $val)
216+
* @method self slot(?string $val)
217+
* @method self span(?int $val)
218+
* @method self spellcheck(?string $val)
219+
* @method self src(?string $val)
220+
* @method self srcdoc(?string $val)
221+
* @method self srclang(?string $val)
222+
* @method self srcset(?string $val)
223+
* @method self start(?int $val)
224+
* @method self step(?float $val)
225+
* @method self style(?string $property, string $val = null)
226+
* @method self tabindex(?int $val)
227+
* @method self target(?string $val)
228+
* @method self title(?string $val)
229+
* @method self translate(?string $val)
230+
* @method self type(?string $val)
231+
* @method self usemap(?string $val)
232+
* @method self value(?string $val)
233+
* @method self width(?int $val)
234+
* @method self wrap(?string $val)
26235
*/
27236
class Html implements \ArrayAccess, \Countable, \IteratorAggregate, IHtmlString
28237
{

0 commit comments

Comments
 (0)