19 declare(strict_types=1);
33 class Image implements C\Image\Image
50 public function __construct(
string $type,
string $source,
string $alt)
52 $this->checkArgIsElement(
"type", $type, self::$types,
"image type");
73 $clone->src = $source;
91 $clone->additional_high_res_sources[$min_width_in_pixels] = $source;
109 $clone = clone $this;
127 $this->checkStringOrSignalArg(
"action", $action);
128 $clone = clone $this;
129 if (is_string($action)) {
135 $clone->action =
null;
136 $clone->setTriggeredSignal($action,
"click");
147 if ($this->action !==
null) {
appendTriggeredSignal(C\Signal $signal, string $event)
Append a triggered signal to other signals of the same event.
withTriggeredSignal(C\Signal $signal, string $event)
Add a triggered signal, replacing any other signals registered on the same event. ...
withOnClick(Signal $signal)
trait JavaScriptBindable
Trait for components implementing JavaScriptBindable providing standard implementation.
getTriggeredSignalsFor(string $event)
Get signals that are triggered for a certain event.
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
withAdditionalHighResSource(string $source, int $min_width_in_pixels)
appendOnClick(Signal $signal)
array $additional_high_res_sources
withSource(string $source)
getAdditionalHighResSources()
__construct(string $type, string $source, string $alt)