ILIAS  release_9 Revision v9.13-25-g2c18ec4c24f
ILIAS\LegalDocuments\Table\DocumentModal Class Reference
+ Collaboration diagram for ILIAS\LegalDocuments\Table\DocumentModal:

Public Member Functions

 __construct (private readonly UIServices $ui, private readonly Closure $content_as_component)
 
 create (DocumentContent $content)
 

Detailed Description

Definition at line 29 of file DocumentModal.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\LegalDocuments\Table\DocumentModal::__construct ( private readonly UIServices  $ui,
private readonly Closure  $content_as_component 
)
Parameters
Closure(CriterionContent)Component $content_as_component

Definition at line 34 of file DocumentModal.php.

37  {
38  }

Member Function Documentation

◆ create()

ILIAS\LegalDocuments\Table\DocumentModal::create ( DocumentContent  $content)
Returns
list<Component>

Definition at line 43 of file DocumentModal.php.

References ILIAS\LegalDocuments\Value\DocumentContent\title(), and ILIAS\Repository\ui().

43  : array
44  {
45  $modal = $this->ui->factory()->modal()->lightbox([
46  $this->ui->factory()->modal()->lightboxTextPage(
47  $this->ui->renderer()->render(($this->content_as_component)($content)),
48  $content->title()
49  )
50  ]);
51 
52  $link = $this->ui->factory()->button()->shy($content->title(), '')->withOnClick(
53  $modal->getShowSignal()
54  );
55 
56  return [$link, $modal];
57  }
+ Here is the call graph for this function:

The documentation for this class was generated from the following file: