Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions components/ILIAS/UI/src/Component/Modal/RoundTrip.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@
use ILIAS\UI\Component\Button;
use ILIAS\UI\Component\Component;
use ILIAS\UI\Component\ReplaceSignal;
use ILIAS\UI\Component\Input\Container\Form\Standard;
use ILIAS\UI\Component\Input\Container\Container;

/**
* @package ILIAS\UI\Component\Modal
*/
interface RoundTrip extends Modal, Standard
interface RoundTrip extends Modal, Container
{
/**
* Get the title of the modal
Expand Down Expand Up @@ -66,6 +66,11 @@ public function withActionButtons(array $buttons): RoundTrip;
*/
public function withCancelButtonLabel(string $label): RoundTrip;

/**
* Get a modal like this with the provided submit button string.
*/
public function withSubmitLabel(string $label): self;

/**
* Get the signal to replace the content of this modal.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -191,13 +191,6 @@ public function getReplaceSignal(): ReplaceSignal
return $this->modal->getReplaceSignal();
}

public function withAdditionalFormAction(string $action, string $label): static
{
$clone = clone $this;
$clone->modal = $clone->modal->withAdditionalFormAction($action, $label);
return $clone;
}

public function getPostURL(): string
{
return $this->modal->getPostURL();
Expand Down Expand Up @@ -230,7 +223,7 @@ public function withRequest(ServerRequestInterface $request): self
public function withInput(InputData $input_data): self
{
$clone = clone $this;
$clone->modal = $clone->modal->withInput($request);
$clone->modal = $clone->modal->withInput($input_data);
return $clone;
}

Expand Down Expand Up @@ -281,20 +274,4 @@ public function withDedicatedName(string $dedicated_name): self
{
return $this;
}

/**
* @inheritdoc
*/
public function getPromptButtons(): array
{
return $this->buttons;
}

/**
* @inheritdoc
*/
public function getPromptTitle(): string
{
return $this->type;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -216,13 +216,6 @@ public function getError(): ?string
return $this->form->getError();
}

public function withAdditionalFormAction(string $action, string $label): static
{
$clone = clone $this;
$clone->form = $clone->form->withAdditionalFormAction($action, $label);
return $clone;
}

/**
* @inheritDoc
*/
Expand Down Expand Up @@ -261,20 +254,4 @@ public function withDedicatedName(string $dedicated_name): self
{
return $this;
}

/**
* @inheritdoc
*/
public function getPromptButtons(): array
{
return $this->buttons;
}

/**
* @inheritdoc
*/
public function getPromptTitle(): string
{
return $this->type;
}
}
Loading