public function __construct(Page $page, array $attrs, $slotname) { parent::__construct($page, $attrs, $slotname); if (isset($this->attrs['target_page_id'])) { $this->targetPage = PageFacade::find($this->attrs['target_page_id']); } }
public function __construct(Page $page, array $attrs, $slotname, $editable = true) { parent::__construct($page, $attrs, $slotname, $editable); if (isset($attrs['asset_id'])) { $this->asset = AssetFacade::find($this->attrs['asset_id']); } }
public function __construct(Page $page, array $attrs, $slotname, $editable) { parent::__construct($page, $attrs, $slotname, $editable); if (isset($this->attrs['slides'])) { foreach ($this->attrs['slides'] as &$slide) { $slide = new Slideshow\Slide($slide); } } }
public function __construct(Page $page, array $attrs, $slotname) { parent::__construct($page, $attrs, $slotname); if (isset($this->attrs['links'])) { foreach ($this->attrs['links'] as &$link) { $link = new Linkset\Link($link); } } }
public function getPlaceholderText() { $placeholder = parent::getPlaceholderText(); return $this->allowFormatting ? "<p>{$placeholder}</p>" : $placeholder; }
public function __construct(Page $page, array $attrs, $slotname) { parent::__construct($page, $attrs, $slotname); $this->params = isset($attrs['params']) ? $this->cleanData((array) $attrs['params']) : []; }