Skip to content

Commit 85431e2

Browse files
committed
perf(home): make the monitor chrome match the surrounding sheet
Optimization(zh-Hant): 首頁底部監視器資訊條改成與上方介面一致的排版 Optimization(en-US): the monitor bar on home now sits flush with the sheet above it
1 parent 803e9ef commit 85431e2

1 file changed

Lines changed: 24 additions & 27 deletions

File tree

lib/features/home/presentation/pages/home_page.dart

Lines changed: 24 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -302,33 +302,30 @@ class _HomePageState extends State<HomePage> {
302302
blend: HomeChrome.regionBlend(sheetExtent.value),
303303
dismiss: HomeChrome.regionDismiss(sheetExtent.value),
304304
),
305-
builder: (context, dials, _) => SafeArea(
306-
bottom: false,
307-
child: Column(
308-
mainAxisSize: MainAxisSize.min,
309-
children: [
310-
RegionBar(
311-
blend: dials.blend,
312-
dismiss: dials.dismiss,
313-
skyIsLight: skyIsLightFrom(sky, weatherMode),
314-
),
315-
// Quick link to 強震監視器 — same dials as the
316-
// region bar above it, so the two move as one
317-
// piece of chrome as the sheet rises.
318-
//
319-
// Above the support pill on purpose: this one
320-
// only renders while an alert is active, and an
321-
// alert must not be pushed down the screen by a
322-
// donation prompt. When nothing is happening it
323-
// draws nothing, so the pill sits directly under
324-
// the bar anyway.
325-
HomeMonitorBanner(dismiss: dials.dismiss),
326-
_GoldSupportBar(
327-
blend: dials.blend,
328-
dismiss: dials.dismiss,
329-
),
330-
],
331-
),
305+
builder: (context, dials, _) => Column(
306+
mainAxisSize: MainAxisSize.min,
307+
children: [
308+
RegionBar(
309+
blend: dials.blend,
310+
dismiss: dials.dismiss,
311+
skyIsLight: skyIsLightFrom(sky, weatherMode),
312+
),
313+
// Quick link to 強震監視器 — same dials as the
314+
// region bar above it, so the two move as one
315+
// piece of chrome as the sheet rises.
316+
//
317+
// Above the support pill on purpose: this one
318+
// only renders while an alert is active, and an
319+
// alert must not be pushed down the screen by a
320+
// donation prompt. When nothing is happening it
321+
// draws nothing, so the pill sits directly under
322+
// the bar anyway.
323+
HomeMonitorBanner(dismiss: dials.dismiss),
324+
_GoldSupportBar(
325+
blend: dials.blend,
326+
dismiss: dials.dismiss,
327+
),
328+
],
332329
),
333330
),
334331
),

0 commit comments

Comments
 (0)