3 final class PHUILeftRightView
extends AphrontTagView
{
7 private $verticalAlign;
9 const ALIGN_TOP
= 'top';
10 const ALIGN_MIDDLE
= 'middle';
11 const ALIGN_BOTTOM
= 'bottom';
13 public function setLeft($left) {
18 public function setRight($right) {
19 $this->right
= $right;
23 public function setVerticalAlign($align) {
24 $this->verticalAlign
= $align;
28 protected function getTagAttributes() {
29 require_celerity_resource('phui-left-right-css');
32 $classes[] = 'phui-left-right-view';
34 if ($this->verticalAlign
) {
35 $classes[] = 'phui-lr-view-'.$this->verticalAlign
;
38 return array('class' => implode(' ', $classes));
41 protected function getTagName() {
45 protected function getTagContent() {
46 $left = phutil_tag_div('phui-left-view', $this->left
);
47 $right = phutil_tag_div('phui-right-view', $this->right
);
49 return phutil_tag_div('phui-lr-container', array($left, $right));