M4: PWA + Mobile-UX – Manifest/Service-Worker + Icons, Auf/Ab-Reorder, FAB, Touch-Targets + Safe-Area, Nav-Entdupidung, Heute-Highlight, Aktions-Trennung (Abhaken vs. Bearbeiten/Löschen), OIDC-Fixes + PWA-Tests
This commit is contained in:
@@ -65,7 +65,8 @@ final class OidcAuthController
|
||||
try {
|
||||
$tokens = $this->oidc->exchangeCode($code);
|
||||
$claims = $this->oidc->verifyIdToken($tokens['id_token']);
|
||||
} catch (\Throwable) {
|
||||
} catch (\Throwable $e) {
|
||||
error_log('OIDC-Callback fehlgeschlagen: ' . $e->getMessage());
|
||||
return new RedirectResponse($this->router->generate('login'));
|
||||
}
|
||||
|
||||
|
||||
@@ -41,7 +41,6 @@ final class OidcClient
|
||||
'client_id' => $this->clientId,
|
||||
'redirect_uri' => $this->redirectUri,
|
||||
'scope' => implode(' ', $this->scopes),
|
||||
'prompt' => 'login',
|
||||
];
|
||||
if ($state !== null && $state !== '') {
|
||||
$q['state'] = $state;
|
||||
@@ -71,7 +70,8 @@ final class OidcClient
|
||||
}
|
||||
|
||||
$resp = $this->httpClient->request('POST', $this->issuer . '/protocol/openid-connect/token', [
|
||||
'json' => $body,
|
||||
'body' => http_build_query($body),
|
||||
'headers' => ['Content-Type' => 'application/x-www-form-urlencoded'],
|
||||
'timeout' => 10,
|
||||
]);
|
||||
$sc = $resp->getStatusCode();
|
||||
@@ -198,10 +198,9 @@ final class OidcClient
|
||||
|
||||
$mod = $this->derInteger($n);
|
||||
$exp = $this->derInteger($e);
|
||||
$rsakey =
|
||||
"\x30" . $this->derLen(strlen($mod) + strlen($exp))
|
||||
. "\x02" . $this->derLen(strlen($mod)) . $mod
|
||||
. "\x02" . $this->derLen(strlen($exp)) . $exp;
|
||||
$modTLV = "\x02" . $this->derLen(strlen($mod)) . $mod;
|
||||
$expTLV = "\x02" . $this->derLen(strlen($exp)) . $exp;
|
||||
$rsakey = "\x30" . $this->derLen(strlen($modTLV) + strlen($expTLV)) . $modTLV . $expTLV;
|
||||
|
||||
// rsaEncryption OID 1.2.840.113549.1.1.1 → DER: 2A 86 48 86 F7 0D 01 01 01
|
||||
$algId = "\x06\x09\x2a\x86\x48\x86\xf7\x0d\x01\x01\x01";
|
||||
|
||||
@@ -78,9 +78,18 @@ final class MahlzeitController extends AbstractController
|
||||
return $this->render('mahlzeiten/tage.html.twig', [
|
||||
'tage' => $this->gruppierenNachTag($mahlzeiten),
|
||||
'total' => \count($mahlzeiten),
|
||||
'heute' => $this->heutigerTag(),
|
||||
]);
|
||||
}
|
||||
|
||||
/** Aktueller Wochentag (Europe/Berlin) als `Wochentag`-Name (z. B. "Di"). */
|
||||
private function heutigerTag(): string
|
||||
{
|
||||
$iso = (int) (new \DateTimeImmutable('now', new \DateTimeZone('Europe/Berlin')))->format('N');
|
||||
|
||||
return Wochentag::cases()[$iso - 1]->name;
|
||||
}
|
||||
|
||||
/**
|
||||
* POST /mahlzeiten/reorder — neue Reihenfolge der Planungsliste (Drag & Drop)
|
||||
* persistieren. Erwartet JSON `{"ids": [3, 1, 2]}` oder das Formularfeld
|
||||
|
||||
@@ -47,7 +47,7 @@ final class ExceptionSubscriber implements EventSubscriberInterface
|
||||
return;
|
||||
}
|
||||
|
||||
if ($e instanceof HttpExceptionInterface && $api) {
|
||||
if ($e instanceof HttpExceptionInterface) {
|
||||
$event->setResponse(
|
||||
$this->render($request, $e->getStatusCode(), $this->shortName(get_class($e)), $e->getMessage(), $wantsJson)
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user