Class-Less Alert Extension
taufik-nurrohman opened this issue · comments
Remove class names from the generated alert HTML markup and replace it with attribute role="alert"
. Default alert markup don’t have to care with the alert type. It’s up to the layout maker. It can be made specific via .\lot\layout\alert.php
file by iterating over the array output of alert()
:
<?php foreach (alert() as $v): ?>
<p class="alert alert-<?= $v[2]['type']; ?>" role="alert">
<?= $v[1]; ?>
</p>
<?php endforeach; ?>
Reference: https://www.w3.org/TR/wai-aria-1.1/#alert
Related: #174