protected $_addedContents = true;
protected $_tooltip = true;
protected $_extra = true;
+ protected $_stats = true;
protected $_uid = true;
protected $_canContainLinks = false;
$this->addTooltipFields();
$this->addPositionFields();
$this->addExtraFields();
+ $this->addStatsFields();
}
public function addTooltipFields()
public function addBasicSettingsFields()
{
- if ($this->_integration==='multimedia') {
+ if ($this->_integration === 'multimedia') {
$this->addField('inline', MultimediaIntegration::class, __('Intégration'));
- }else if($this->_integration==='webvideo'){
+ } else if ($this->_integration === 'webvideo') {
$this->addField('inline', WebvideoIntegration::class, __('Intégration'));
}
}
}
+ public function addStatsFields()
+ {
+ if ($this->hasField('stats') || !$this->_stats) {
+ return;
+ }
+ $this->addField('header_stats', FormSection::class, __('Statistiques'));
+ $this->addField('stats', Textarea::class, '');
+ }
+
protected function _getHTMLAttributes()
{
return ['class'];
}
$id = 1;
- $base = ['top' => 1, 'left' => 1, 'width' => 1, 'height' => 1, 'to' => '', 'inline' => 'inline', 'page' => 2, 'target' => '_blank', 'extra' => '', 'interactive' => false,'video_service'=>'youtube'];
+ $base = ['top' => 1, 'left' => 1, 'width' => 1, 'height' => 1, 'to' => '', 'inline' => 'inline', 'page' => 2, 'target' => '_blank', 'extra' => '', 'interactive' => false, 'video_service' => 'youtube', 'stats' => ''];
$compiler = new Compiler($fluidbook);
/** @var Link $instances */