Refine iOS mobile controls and sleep progress

This commit is contained in:
2026-05-21 19:00:55 +02:00
parent 18deb121dc
commit fef6c2407d
2 changed files with 69 additions and 52 deletions
+68 -49
View File
@@ -1001,12 +1001,12 @@ body.page-dashboard .content {
.sleep-phase-bar { .sleep-phase-bar {
position: relative; position: relative;
height: 2.35rem; height: 0.74rem;
margin-top: 1.55rem; margin-top: 1.55rem;
overflow: visible; overflow: visible;
border-radius: 999px; border-radius: 999px;
border: 1px solid rgba(255, 255, 255, 0.14); border: 1px solid rgba(255, 255, 255, 0.16);
background: rgba(255, 255, 255, 0.08); background: rgba(255, 255, 255, 0.16);
} }
.sleep-phase-bar__fill { .sleep-phase-bar__fill {
@@ -1016,15 +1016,15 @@ body.page-dashboard .content {
max-width: 100%; max-width: 100%;
overflow: hidden; overflow: hidden;
border-radius: inherit; border-radius: inherit;
background: linear-gradient(135deg, rgba(90, 188, 242, 0.92), rgba(44, 126, 190, 0.92)); background: linear-gradient(90deg, #64d2ff, #0a84ff);
box-shadow: 0 10px 22px rgba(44, 126, 190, 0.22); box-shadow: 0 0 18px rgba(10, 132, 255, 0.38);
} }
.sleep-phase-bar__target { .sleep-phase-bar__target {
position: absolute; position: absolute;
left: min(var(--sleep-optimal-left, 100%), calc(100% - 2px)); left: min(var(--sleep-optimal-left, 100%), calc(100% - 2px));
top: -1.28rem; top: -0.48rem;
bottom: 0; bottom: -0.48rem;
width: 0; width: 0;
border-left: 2px solid rgba(255, 255, 255, 0.92); border-left: 2px solid rgba(255, 255, 255, 0.92);
filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.45)); filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.45));
@@ -1034,7 +1034,7 @@ body.page-dashboard .content {
.sleep-phase-bar__target span { .sleep-phase-bar__target span {
position: absolute; position: absolute;
top: 0; top: -1.1rem;
left: 0.28rem; left: 0.28rem;
padding: 0.08rem 0.34rem; padding: 0.08rem 0.34rem;
border-radius: 999px; border-radius: 999px;
@@ -1044,6 +1044,16 @@ body.page-dashboard .content {
white-space: nowrap; white-space: nowrap;
} }
.sleep-phase-summary {
display: flex;
justify-content: space-between;
gap: 0.75rem;
margin-top: 0.55rem;
color: rgba(239, 247, 255, 0.64);
font-size: 0.78rem;
font-weight: 650;
}
.sleep-phase-bar__segment { .sleep-phase-bar__segment {
box-sizing: border-box; box-sizing: border-box;
position: relative; position: relative;
@@ -4730,22 +4740,23 @@ input[type="range"] {
.ios-tabbar { .ios-tabbar {
position: fixed; position: fixed;
left: 0.65rem; left: 0;
right: 0.65rem; right: 0;
bottom: max(0.55rem, env(safe-area-inset-bottom)); bottom: 0;
z-index: 120; z-index: 120;
display: grid; display: grid;
grid-template-columns: repeat(4, minmax(0, 1fr)); grid-template-columns: repeat(4, minmax(0, 1fr));
gap: 0.18rem; gap: 0;
min-height: 5rem; min-height: calc(5.05rem + env(safe-area-inset-bottom));
padding: 0.42rem; padding: 0.42rem 0.75rem calc(0.42rem + env(safe-area-inset-bottom));
border: 1px solid rgba(255, 255, 255, 0.34); border: 0;
border-radius: 2.15rem; border-top: 1px solid rgba(255, 255, 255, 0.24);
border-radius: 1.8rem 1.8rem 0 0;
background: background:
radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.34), transparent 38%), radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.34), transparent 38%),
linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.07)), linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.07)),
rgba(13, 22, 35, 0.5); rgba(13, 22, 35, 0.5);
box-shadow: 0 26px 80px rgba(0, 0, 0, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.28), inset 0 -1px 0 rgba(255, 255, 255, 0.08); box-shadow: 0 -18px 70px rgba(0, 0, 0, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.26);
backdrop-filter: blur(38px) saturate(1.8) contrast(1.06); backdrop-filter: blur(38px) saturate(1.8) contrast(1.06);
-webkit-backdrop-filter: blur(38px) saturate(1.8) contrast(1.06); -webkit-backdrop-filter: blur(38px) saturate(1.8) contrast(1.06);
} }
@@ -4754,44 +4765,42 @@ input[type="range"] {
display: grid; display: grid;
place-items: center; place-items: center;
align-content: center; align-content: center;
gap: 0.22rem; gap: 0.18rem;
min-height: 3.55rem; min-height: 3.7rem;
border-radius: 1.45rem; border-radius: 1.25rem;
color: rgba(239, 247, 255, 0.68); color: rgba(239, 247, 255, 0.68);
font-size: 0.72rem; font-size: 0.72rem;
font-weight: 650; font-weight: 590;
text-decoration: none; text-decoration: none;
transition: background 160ms ease, color 160ms ease, transform 160ms ease; transition: background 160ms ease, color 160ms ease, transform 160ms ease;
} }
.ios-tabbar a.active { .ios-tabbar a.active {
background: background: transparent;
radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.3), transparent 52%), color: #64d2ff;
linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.08));
color: #fff;
transform: translateY(-1px); transform: translateY(-1px);
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.24), 0 8px 24px rgba(0, 0, 0, 0.16); box-shadow: none;
} }
.ios-tabbar__icon { .ios-tabbar__icon {
display: grid; display: grid;
place-items: center; place-items: center;
width: 1.48rem; width: 1.6rem;
height: 1.48rem; height: 1.6rem;
border-radius: 0.72rem; border-radius: 0;
background: rgba(255, 255, 255, 0.1); background: transparent;
opacity: 0.96; opacity: 0.96;
} }
.ios-tabbar__icon img { .ios-tabbar__icon img {
width: 1.04rem; width: 1.28rem;
height: 1.04rem; height: 1.28rem;
filter: brightness(0) invert(1); filter: brightness(0) invert(1);
opacity: 0.92; opacity: 0.92;
} }
.ios-tabbar a.active .ios-tabbar__icon { .ios-tabbar a.active .ios-tabbar__icon {
background: rgba(255, 255, 255, 0.18); background: transparent;
} }
body.is-authenticated .content, body.is-authenticated .content,
@@ -4912,32 +4921,44 @@ input[type="range"] {
.timeline-card__time-chip { .timeline-card__time-chip {
position: absolute; position: absolute;
top: 0.85rem; top: 0.9rem;
right: 4.8rem; right: 4.45rem;
left: auto; left: auto;
display: inline-flex; display: inline-flex;
min-height: 2.35rem; min-height: 2.15rem;
padding: 0 0.78rem; padding: 0 0.72rem;
border-radius: 999px; border-radius: 999px;
background: rgba(8, 18, 30, 0.42); background: rgba(20, 20, 26, 0.38);
border: 1px solid rgba(255, 255, 255, 0.16); border: 1px solid rgba(255, 255, 255, 0.16);
color: rgba(255, 255, 255, 0.86); color: rgba(255, 255, 255, 0.86);
} }
.timeline-card__delete, .timeline-card__delete,
.timeline-card--with-image .timeline-card__delete { .timeline-card--with-image .timeline-card__delete {
top: 0.75rem; top: 0.68rem;
right: 0.75rem; right: 0.68rem;
}
.timeline-card__delete .ghost-button {
width: 2.85rem;
height: 2.85rem;
min-width: 2.85rem;
min-height: 2.85rem;
border-radius: 999px;
background: rgba(242, 242, 247, 0.92);
color: rgba(28, 28, 30, 0.86);
font-size: 1.05rem;
font-weight: 560;
} }
.timeline-card--with-image .timeline-card__time-chip { .timeline-card--with-image .timeline-card__time-chip {
top: 1.25rem; top: 1.18rem;
right: 4.9rem; right: 4.7rem;
} }
.timeline-card--with-image .timeline-card__delete { .timeline-card--with-image .timeline-card__delete {
top: 1.05rem; top: 0.95rem;
right: 1.05rem; right: 0.95rem;
} }
.sleep-phase-bar { .sleep-phase-bar {
@@ -4970,7 +4991,7 @@ input[type="range"] {
radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.95), transparent 42%), radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.95), transparent 42%),
linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.48)), linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.48)),
rgba(248, 251, 255, 0.68); rgba(248, 251, 255, 0.68);
box-shadow: 0 24px 64px rgba(78, 105, 130, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.86); box-shadow: 0 -18px 54px rgba(78, 105, 130, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.86);
} }
.ios-tabbar a { .ios-tabbar a {
@@ -4978,10 +4999,8 @@ input[type="range"] {
} }
.ios-tabbar a.active { .ios-tabbar a.active {
background: background: transparent;
radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.92), transparent 55%), color: #007aff;
rgba(20, 148, 222, 0.12);
color: #12304b;
} }
.ios-tabbar__icon { .ios-tabbar__icon {
+1 -3
View File
@@ -224,10 +224,8 @@ $formatBalanceValue = static function (?array $entry) use ($settings): string {
<div class="sleep-phase-bar" aria-label="Schlafdauer" style="--sleep-optimal-left: <?= e((string) $sleepOptimalPercent) ?>%"> <div class="sleep-phase-bar" aria-label="Schlafdauer" style="--sleep-optimal-left: <?= e((string) $sleepOptimalPercent) ?>%">
<span class="sleep-phase-bar__fill" style="width: <?= e((string) $sleepActualPercent) ?>%" aria-hidden="true"></span> <span class="sleep-phase-bar__fill" style="width: <?= e((string) $sleepActualPercent) ?>%" aria-hidden="true"></span>
<span class="sleep-phase-bar__target"><span><?= e(format_duration_hours($optimalSleepHours)) ?></span></span> <span class="sleep-phase-bar__target"><span><?= e(format_duration_hours($optimalSleepHours)) ?></span></span>
<?php if ($sleepPhaseRemainder > 0): ?>
<span class="sleep-phase-bar__rest-label">noch <?= e(format_duration_hours($sleepPhaseRemainder)) ?> bis Skalenende</span>
<?php endif; ?>
</div> </div>
<div class="sleep-phase-summary"><span><?= e(format_duration_hours($sleepActualTotal)) ?></span><span>Ziel <?= e(format_duration_hours($optimalSleepHours)) ?></span></div>
<?php if ($sleepPhaseTotal > 0): ?> <?php if ($sleepPhaseTotal > 0): ?>
<div class="sleep-phase-legend" aria-label="Schlafphasen"> <div class="sleep-phase-legend" aria-label="Schlafphasen">
<?php foreach (['deep' => ['Tief', 'deep'], 'rem' => ['REM', 'rem'], 'core' => ['Kern', 'core']] as $phase => [$label, $class]): ?> <?php foreach (['deep' => ['Tief', 'deep'], 'rem' => ['REM', 'rem'], 'core' => ['Kern', 'core']] as $phase => [$label, $class]): ?>