19declare(strict_types=1);
24use ILIAS\UI\Implementation\Component\ComponentHelper;
62 public \ILIAS\Language\Language
$lng;
73 public function render(
Component $component, DefaultRenderer $default_renderer): string
76 $text = $component->text;
77 $component = $component->withAdditionalOnLoadCode(
function (
$id) use ($text) {
78 return "id:$text.$id content:$text";
82 return $component->text;
92 $binder = $component->getOnLoadCode();
93 $this->js_binding->addOnLoadCode($binder(
"id"));
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Builds a Color from either hex- or rgb values.
__construct(string $text)
bindOnloadCode(\ILIAS\UI\Component\JavaScriptBindable $component)
registerResources(ResourceRegistry $registry)
Announce resources this renderer requires.
__construct(Factory $ui_factory, TemplateFactory $tpl_factory, \ILIAS\Language\Language $lng, JavaScriptBinding $js_binding)
JavaScriptBinding $js_binding
render(Component $component, DefaultRenderer $default_renderer)
TemplateFactory $tpl_factory
ILIAS Language Language $lng
__construct(string $text)
A component is the most general form of an entity in the UI.
Interface to be extended by components that have the possibility to bind to Javascript.
This is how the factory for UI elements looks.
An entity that renders components to a string output.
Provides methods to interface with javascript.
Registry for resources required by rendered output like Javascript or CSS.
register(string $name)
Add a dependency.
Interface for a factory that provides templates.
An entity that renders components to a string output.
trait JavaScriptBindable
Trait for components implementing JavaScriptBindable providing standard implementation.
Interface Observer \BackgroundTasks Contains several chained tasks and infos about them.