ILIAS  release_9 Revision v9.13-25-g2c18ec4c24f
GlyphRendererFactory.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
22 
26 
28 {
29  public const USE_BUTTON_CONTEXT_FOR = [
30  'BulkyButton',
31  'BulkyLink'
32  ];
33 
34  public function getRendererInContext(Component\Component $component, array $contexts): ComponentRenderer
35  {
36  if (count(array_intersect(self::USE_BUTTON_CONTEXT_FOR, $contexts)) > 0) {
37  return new ButtonContextRenderer(
38  $this->ui_factory,
39  $this->tpl_factory,
40  $this->lng,
41  $this->js_binding,
42  $this->refinery,
43  $this->image_path_resolver,
44  $this->data_factory,
45  $this->help_text_retriever,
46  $this->upload_limit_resolver
47  );
48  }
49  return new Renderer(
50  $this->ui_factory,
51  $this->tpl_factory,
52  $this->lng,
53  $this->js_binding,
54  $this->refinery,
55  $this->image_path_resolver,
56  $this->data_factory,
57  $this->help_text_retriever,
58  $this->upload_limit_resolver
59  );
60  }
61 }
An entity that renders components to a string output.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
getRendererInContext(Component\Component $component, array $contexts)