@@ -8,8 +8,8 @@ discard block |
||
8 | 8 | |
9 | 9 | class HtmlLabel extends HtmlSemDoubleElement { |
10 | 10 | |
11 | - public function __construct($identifier,$caption="",$tagName="div") { |
|
12 | - parent::__construct($identifier,$tagName); |
|
11 | + public function __construct($identifier, $caption="", $tagName="div") { |
|
12 | + parent::__construct($identifier, $tagName); |
|
13 | 13 | $this->setProperty("class", "ui label"); |
14 | 14 | $this->content=$caption; |
15 | 15 | } |
@@ -18,26 +18,26 @@ discard block |
||
18 | 18 | * @param string $side |
19 | 19 | * @return \Ajax\semantic\html\elements\HtmlLabel |
20 | 20 | */ |
21 | - public function setPointing($side=""){ |
|
22 | - return $this->addToPropertyCtrl("class", $side." pointing",array("right pointing","left pointing"," pointing")); |
|
21 | + public function setPointing($side="") { |
|
22 | + return $this->addToPropertyCtrl("class", $side." pointing", array("right pointing", "left pointing", " pointing")); |
|
23 | 23 | } |
24 | 24 | |
25 | 25 | /** |
26 | 26 | * @param string $side |
27 | 27 | * @return \Ajax\semantic\html\elements\HtmlLabel |
28 | 28 | */ |
29 | - public function toCorner($side="left"){ |
|
30 | - return $this->addToPropertyCtrl("class", $side." corner",array("right corner","left corner")); |
|
29 | + public function toCorner($side="left") { |
|
30 | + return $this->addToPropertyCtrl("class", $side." corner", array("right corner", "left corner")); |
|
31 | 31 | } |
32 | 32 | |
33 | 33 | /** |
34 | 34 | * @return \Ajax\semantic\html\elements\HtmlLabel |
35 | 35 | */ |
36 | - public function asTag(){ |
|
36 | + public function asTag() { |
|
37 | 37 | return $this->addToProperty("class", "tag"); |
38 | 38 | } |
39 | 39 | |
40 | - public function setBasic(){ |
|
40 | + public function setBasic() { |
|
41 | 41 | return $this->addToProperty("class", "basic"); |
42 | 42 | } |
43 | 43 | |
@@ -47,12 +47,12 @@ discard block |
||
47 | 47 | * @param boolean $before |
48 | 48 | * @return \Ajax\semantic\html\elements\HtmlIcon |
49 | 49 | */ |
50 | - public function addIcon($icon,$before=true){ |
|
50 | + public function addIcon($icon, $before=true) { |
|
51 | 51 | $iconO=$icon; |
52 | - if(\is_string($icon)){ |
|
52 | + if (\is_string($icon)) { |
|
53 | 53 | $iconO=new HtmlIcon("icon-".$this->identifier, $icon); |
54 | 54 | } |
55 | - $this->addContent($iconO,$before); |
|
55 | + $this->addContent($iconO, $before); |
|
56 | 56 | return $iconO; |
57 | 57 | } |
58 | 58 | |
@@ -63,17 +63,17 @@ discard block |
||
63 | 63 | * @param string $before |
64 | 64 | * @return \Ajax\semantic\html\elements\HtmlLabel |
65 | 65 | */ |
66 | - public function addImage($src,$alt="",$before=true){ |
|
66 | + public function addImage($src, $alt="", $before=true) { |
|
67 | 67 | $this->addToProperty("class", "image"); |
68 | - return $this->addContent(new HtmlImg("image-".$this->identifier,$src,$alt),$before); |
|
68 | + return $this->addContent(new HtmlImg("image-".$this->identifier, $src, $alt), $before); |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | /** |
72 | 72 | * @param string $detail |
73 | 73 | * @return \Ajax\common\html\HtmlDoubleElement |
74 | 74 | */ |
75 | - public function addDetail($detail){ |
|
76 | - $div=new HtmlDoubleElement("detail-".$this->identifier,$this->tagName); |
|
75 | + public function addDetail($detail) { |
|
76 | + $div=new HtmlDoubleElement("detail-".$this->identifier, $this->tagName); |
|
77 | 77 | $div->setClass("detail"); |
78 | 78 | $div->setContent($detail); |
79 | 79 | $this->addContent($div); |
@@ -2,5 +2,5 @@ |
||
2 | 2 | namespace Ajax\semantic\html\base; |
3 | 3 | use Ajax\common\BaseEnum; |
4 | 4 | abstract class Size extends BaseEnum { |
5 | - const MINI="mini", TINY="tiny", SMALL="small", MEDIUM="",LARGE="large", BIG="big", HUGE="huge", MASSIVE="massive"; |
|
5 | + const MINI="mini", TINY="tiny", SMALL="small", MEDIUM="", LARGE="large", BIG="big", HUGE="huge", MASSIVE="massive"; |
|
6 | 6 | } |
7 | 7 | \ No newline at end of file |
@@ -14,7 +14,7 @@ discard block |
||
14 | 14 | * {@inheritDoc} |
15 | 15 | * @see \Ajax\common\html\HtmlSingleElement::setSize() |
16 | 16 | */ |
17 | - public function setSize($size){ |
|
17 | + public function setSize($size) { |
|
18 | 18 | return $this->addToPropertyCtrl("class", $size, Size::getConstants()); |
19 | 19 | } |
20 | 20 | |
@@ -22,7 +22,7 @@ discard block |
||
22 | 22 | * show it is currently unable to be interacted with |
23 | 23 | * @return \Ajax\semantic\html\elements\HtmlSemDoubleElement |
24 | 24 | */ |
25 | - public function setDisabled(){ |
|
25 | + public function setDisabled() { |
|
26 | 26 | return $this->addToProperty("class", "disabled"); |
27 | 27 | } |
28 | 28 | |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | * @param string $color |
31 | 31 | * @return \Ajax\semantic\html\base\HtmlSemDoubleElement |
32 | 32 | */ |
33 | - public function setColor($color){ |
|
34 | - return $this->addToPropertyCtrl("class", $color,Color::getConstants()); |
|
33 | + public function setColor($color) { |
|
34 | + return $this->addToPropertyCtrl("class", $color, Color::getConstants()); |
|
35 | 35 | } |
36 | 36 | } |
37 | 37 | \ No newline at end of file |