Barrierefreiheit und mobile Darstellung
- Kontrast: gedämpfter Text war mit 3,1:1 unter WCAG AA, jetzt 4,9:1 (hell) bzw. 6,4:1 (dunkel) - Sprungmarke „Zum Inhalt springen" in Admin-Shell und Voucher-Seite - aria-label für alle reinen Icon-Schaltflächen (Theme, Menü, Abmelden, Zeilenaktionen), aria-current auf dem aktiven Navigationspunkt, role="group" für den Sprachumschalter - 194 dekorative Icons mit aria-hidden versehen, damit Screenreader sie nicht vorlesen - Toast-Container als aria-live-Bereich ausgezeichnet - prefers-reduced-motion schaltet Animationen und Übergänge ab Tabellen (Benutzer, Vouchers, Profile, Audit-Log, Dashboard, API-Keys) werden unter 720 px zu Karten: die Spaltenüberschrift steht per data-label vor dem Wert, statt horizontal zu scrollen. Datums- und Zeitformat in der Voucher-Liste folgen jetzt der gewählten Sprache statt fest de-DE. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
parent
850a04d628
commit
7f1d93debd
21 changed files with 716 additions and 632 deletions
|
|
@ -71,7 +71,7 @@ foreach (['voucher_created', 'voucher_bulk', 'user_login', 'user_logout', 'user_
|
|||
|
||||
<!-- Filter -->
|
||||
<div class="card" style="margin-bottom: 20px;">
|
||||
<div class="card-header"><span class="card-title"><i class="fas fa-filter"></i> <?= __('audit_filter') ?></span></div>
|
||||
<div class="card-header"><span class="card-title"><i class="fas fa-filter" aria-hidden="true"></i> <?= __('audit_filter') ?></span></div>
|
||||
<div style="padding: 20px 25px;">
|
||||
<form method="get" class="filter-bar">
|
||||
<div>
|
||||
|
|
@ -96,8 +96,8 @@ foreach (['voucher_created', 'voucher_bulk', 'user_login', 'user_logout', 'user_
|
|||
<?php endforeach; ?>
|
||||
</select>
|
||||
</div>
|
||||
<button type="submit" class="btn btn-primary btn-small"><i class="fas fa-search"></i> Filtern</button>
|
||||
<a href="audit_log.php" class="btn btn-secondary btn-small"><i class="fas fa-times"></i> Zurücksetzen</a>
|
||||
<button type="submit" class="btn btn-primary btn-small"><i class="fas fa-search" aria-hidden="true"></i> Filtern</button>
|
||||
<a href="audit_log.php" class="btn btn-secondary btn-small"><i class="fas fa-times" aria-hidden="true"></i> Zurücksetzen</a>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -105,15 +105,15 @@ foreach (['voucher_created', 'voucher_bulk', 'user_login', 'user_logout', 'user_
|
|||
<!-- Log-Tabelle -->
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<span class="card-title"><i class="fas fa-history"></i> <?= __('audit_title') ?></span>
|
||||
<span class="card-title"><i class="fas fa-history" aria-hidden="true"></i> <?= __('audit_title') ?></span>
|
||||
<span style="font-size:13px;color:var(--text-muted);"><?= number_format($total) ?> Einträge</span>
|
||||
</div>
|
||||
<?php if (empty($logs)): ?>
|
||||
<div class="empty-state"><i class="fas fa-history"></i><p><?= __('audit_none') ?></p></div>
|
||||
<div class="empty-state"><i class="fas fa-history" aria-hidden="true"></i><p><?= __('audit_none') ?></p></div>
|
||||
<?php else: ?>
|
||||
<div style="overflow-x:auto;">
|
||||
<div class="table-container">
|
||||
<table class="table">
|
||||
<table class="table table-stack">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><?= __('audit_time') ?></th>
|
||||
|
|
@ -127,34 +127,34 @@ foreach (['voucher_created', 'voucher_bulk', 'user_login', 'user_logout', 'user_
|
|||
<tbody>
|
||||
<?php foreach ($logs as $log): ?>
|
||||
<tr>
|
||||
<td style="white-space:nowrap;color:var(--text-muted);">
|
||||
<td data-label="<?= __('audit_time') ?>" style="white-space:nowrap;color:var(--text-muted);">
|
||||
<?= date('d.m.Y', strtotime($log['created_at'])) ?><br>
|
||||
<small><?= date('H:i:s', strtotime($log['created_at'])) ?></small>
|
||||
</td>
|
||||
<td>
|
||||
<td data-label="<?= __('audit_action') ?>">
|
||||
<span class="action-chip">
|
||||
<?= htmlspecialchars($actionLabels[$log['action']] ?? $log['action']) ?>
|
||||
</span>
|
||||
</td>
|
||||
<td>
|
||||
<td data-label="<?= __('audit_user') ?>">
|
||||
<?php if ($log['user_name']): ?>
|
||||
<strong style="font-size:13px;"><?= htmlspecialchars($log['user_name']) ?></strong><br>
|
||||
<small style="color:var(--text-muted);"><?= htmlspecialchars($log['user_email'] ?? '') ?></small>
|
||||
<?php else: ?>
|
||||
<em style="color:var(--text-muted);">System/Anonym</em>
|
||||
<em style="color:var(--text-muted);"><?= __('audit_system_anon') ?></em>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td style="color:var(--text-secondary);">
|
||||
<td data-label="<?= __('audit_entity') ?>" style="color:var(--text-secondary);">
|
||||
<?php if ($log['entity_type']): ?>
|
||||
<code style="font-size:11px;"><?= htmlspecialchars($log['entity_type']) ?>:<?= htmlspecialchars($log['entity_id'] ?? '') ?></code>
|
||||
<?php else: ?>
|
||||
<span style="color:var(--text-muted);">-</span>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td class="details-cell" title="<?= htmlspecialchars($log['details'] ?? '') ?>">
|
||||
<td class="details-cell" data-label="<?= __('audit_details') ?>" title="<?= htmlspecialchars($log['details'] ?? '') ?>">
|
||||
<?= htmlspecialchars(mb_strimwidth($log['details'] ?? '-', 0, 80, '…')) ?>
|
||||
</td>
|
||||
<td class="ip-cell"><?= htmlspecialchars($log['ip_address'] ?? '-') ?></td>
|
||||
<td class="ip-cell" data-label="<?= __('audit_ip') ?>"><?= htmlspecialchars($log['ip_address'] ?? '-') ?></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
|
|
@ -169,13 +169,13 @@ foreach (['voucher_created', 'voucher_bulk', 'user_login', 'user_logout', 'user_
|
|||
<?php
|
||||
$baseUrl = '?' . http_build_query(array_filter(['action' => $filterAction, 'user_id' => $filterUser]));
|
||||
if ($page > 1): ?>
|
||||
<a href="<?= $baseUrl ?>&page=<?= $page - 1 ?>" class="page-btn"><i class="fas fa-chevron-left"></i></a>
|
||||
<a href="<?= $baseUrl ?>&page=<?= $page - 1 ?>" class="page-btn"><i class="fas fa-chevron-left" aria-hidden="true"></i></a>
|
||||
<?php endif;
|
||||
for ($p = max(1, $page - 2); $p <= min($pages, $page + 2); $p++): ?>
|
||||
<a href="<?= $baseUrl ?>&page=<?= $p ?>" class="page-btn <?= $p === $page ? 'active' : '' ?>"><?= $p ?></a>
|
||||
<?php endfor;
|
||||
if ($page < $pages): ?>
|
||||
<a href="<?= $baseUrl ?>&page=<?= $page + 1 ?>" class="page-btn"><i class="fas fa-chevron-right"></i></a>
|
||||
<a href="<?= $baseUrl ?>&page=<?= $page + 1 ?>" class="page-btn"><i class="fas fa-chevron-right" aria-hidden="true"></i></a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue