mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-15 03:12:41 +01:00
43 lines
765 B
PHP
43 lines
765 B
PHP
|
<?php
|
||
|
|
||
|
final class PhabricatorTextAreaEditField
|
||
|
extends PhabricatorEditField {
|
||
|
|
||
|
private $monospaced;
|
||
|
private $height;
|
||
|
|
||
|
public function setMonospaced($monospaced) {
|
||
|
$this->monospaced = $monospaced;
|
||
|
return $this;
|
||
|
}
|
||
|
|
||
|
public function getMonospaced() {
|
||
|
return $this->monospaced;
|
||
|
}
|
||
|
|
||
|
public function setHeight($height) {
|
||
|
$this->height = $height;
|
||
|
return $this;
|
||
|
}
|
||
|
|
||
|
public function getHeight() {
|
||
|
return $this->height;
|
||
|
}
|
||
|
|
||
|
protected function newControl() {
|
||
|
$control = new AphrontFormTextAreaControl();
|
||
|
|
||
|
if ($this->getMonospaced()) {
|
||
|
$control->setCustomClass('PhabricatorMonospaced');
|
||
|
}
|
||
|
|
||
|
$height = $this->getHeight();
|
||
|
if ($height) {
|
||
|
$control->setHeight($height);
|
||
|
}
|
||
|
|
||
|
return $control;
|
||
|
}
|
||
|
|
||
|
}
|