Documentation
Kitchen Sink documentation of style: 'Delos' of skin: 'ILIAS'
Standard
Description
- Purpose
- Standard Interruptive items represent objects that can generally be identified by a title.
- Composition
- A Standard Interruptive item is composed of an Id, title, description and an icon.
Rules
- Usage
- A standard interruptive item MUST have a title.
- A standard interruptive item SHOULD have an icon representing the affected object.
- A standard interruptive item MAY have a description which helps to further identify the object. If an Interruptive modal displays multiple standard items having the the same title, the description MUST be used in order to distinguish these objects from each other.
- If a standard interruptive item represents an ILIAS object, e.g. a course, then the Id, title, description and icon of the item MUST correspond to the Id, title, description and icon from the ILIAS object.
Example 1: Base
<?php declare(strict_types=1); namespace ILIAS\UI\examples\Modal\InterruptiveItem\Standard; function base() { global $DIC; $factory = $DIC->ui()->factory(); $renderer = $DIC->ui()->renderer(); $message = 'Here you see some standard interruptive items:'; $icon = $factory->image()->standard('./templates/default/images/standard/icon_crs.svg', ''); $modal = $factory->modal()->interruptive('My Title', $message, "#") ->withAffectedItems(array( $factory->modal()->interruptiveItem()->standard( '10', 'Title of the Item', $icon, 'Note, this item is currently only to be used in interruptive Modal.' ), $factory->modal()->interruptiveItem()->standard( '20', 'Title of the other Item', $icon, 'And another one.' ) )); $button = $factory->button()->standard('Show some standard interruptive items', '') ->withOnClick($modal->getShowSignal()); return $renderer->render([$button, $modal]); }
Relations
- Parents
- UIComponent
- Modal
- Interruptive Item