phpMv -UI toolkit 2.4.12
jQuery, jQuery UI, Twitter Bootstrap and Semantic-UI library for php & php MVC Frameworks
Loading...
Searching...
No Matches
HtmlLabelGroups.php
Go to the documentation of this file.
1<?php
2
4
9
17
18 public function __construct($identifier,$labels=array(), $attributes=array()) {
19 parent::__construct($identifier, "div", "ui labels");
20 $this->_states=\array_merge(Size::getConstants(),Color::getConstants(),["tag","circular"]);
21 $this->addItems($labels);
22 $this->setStates($attributes);
23 }
24
25 protected function createItem($value) {
26 $caption=$value;
27 $icon=NULL;
28 $tagName="div";
29 if (\is_array($value)) {
30 $caption=JArray::getValue($value, "caption", 0);
31 $icon=JArray::getValue($value, "icon", 1);
32 $tagName=JArray::getValue($value, "tagName", 2);
33 }
34 $labelO=new HtmlLabel("label-" . $this->identifier, $caption,$icon,$tagName);
35 return $labelO;
36 }
37
38 protected function createCondition($value) {
39 return ($value instanceof HtmlLabel) === false;
40 }
41
42}
Base class for Semantic Html collections.
__construct($identifier, $labels=array(), $attributes=array())
Semantic Label component.
Definition HtmlLabel.php:20