19 declare(strict_types=1);
39 $label = $this->
txt(
"user_avatar");
46 $tpl = $this->
getTemplate(
'tpl.avatar_letter.html',
true,
true);
47 $tpl->setVariable(
'ARIA_LABEL', $label);
48 $tpl->setVariable(
'MODE',
'letter');
49 $tpl->setVariable(
'TEXT', $component->getAbbreviation());
50 $tpl->setVariable(
'COLOR', (
string) $component->getBackgroundColorVariant());
52 $tpl = $this->
getTemplate(
'tpl.avatar_picture.html',
true,
true);
53 $tpl->setVariable(
'ARIA_LABEL', $label);
54 $tpl->setVariable(
'MODE',
'picture');
convertSpecialCharacters(string $value)
txt(string $id)
Get a text from the language file.
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
getTemplate(string $name, bool $purge_unfilled_vars, bool $purge_unused_blocks)
Get template of component this renderer is made for.
cannotHandleComponent(Component $component)
This method MUST be called by derived component renderers, if.
render(Component $component, Renderer $default_renderer)
Render the component if possible and delegate additional rendering to the default_renderer.
Base class for all component renderers.