@@ 23-28 (lines=6) @@ | ||
20 | $this->asMiniAvatar($image); |
|
21 | } |
|
22 | ||
23 | public function setDescription($description){ |
|
24 | $descO=new HtmlDoubleElement("desc-".$this->identifier,"span"); |
|
25 | $descO->setClass("description"); |
|
26 | $descO->setContent($description); |
|
27 | return $this->addContent($descO,true); |
|
28 | } |
|
29 | ||
30 | public function setData($value){ |
|
31 | $this->setProperty("data-value", $value); |
|
@@ 44-50 (lines=7) @@ | ||
41 | * @param string $image the image src |
|
42 | * @return \Ajax\common\html\html5\HtmlImg |
|
43 | */ |
|
44 | public function asMiniAvatar($image){ |
|
45 | $this->tagName="div"; |
|
46 | $img=new HtmlImg("image-".$this->identifier,$image); |
|
47 | $img->setClass("ui mini avatar image"); |
|
48 | $this->addContent($img,true); |
|
49 | return $img; |
|
50 | } |
|
51 | ||
52 | public function asSearchInput($placeholder=NULL,$icon=NULL){ |
|
53 | $this->setClass("ui icon search input"); |
@@ 68-74 (lines=7) @@ | ||
65 | * @param string $detail |
|
66 | * @return \Ajax\common\html\HtmlDoubleElement |
|
67 | */ |
|
68 | public function addDetail($detail){ |
|
69 | $div=new HtmlDoubleElement("detail-".$this->identifier,$this->tagName); |
|
70 | $div->setClass("detail"); |
|
71 | $div->setContent($detail); |
|
72 | $this->addContent($div); |
|
73 | return $div; |
|
74 | } |
|
75 | } |