From 0ceb334988d742bf55e827d3cbb0697654076a7b Mon Sep 17 00:00:00 2001 From: Nixevol Date: Thu, 19 Nov 2026 15:56:22 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=89=93=E5=8D=A1=E8=AE=B0=E5=BD=95?= =?UTF-8?q?=E6=94=B9=E7=94=A8=20ListView?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ui/app.slint | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/ui/app.slint b/ui/app.slint index ffcd112..360b873 100644 --- a/ui/app.slint +++ b/ui/app.slint @@ -1,3 +1,5 @@ +import { ListView } from "std-widgets.slint"; + export struct DayRow { date: string, mark: string, @@ -176,19 +178,12 @@ export component MainWindow inherits Window { } } - if root.error == "" && root.days.length > 0: Flickable { - width: 100%; + if root.error == "" && root.days.length > 0: ListView { vertical-stretch: 1; - content-height: list.preferred-height; - list := VerticalLayout { - width: 100%; + for day in root.days: VerticalLayout { alignment: start; - for day in root.days: VerticalLayout { - width: 100%; - alignment: start; - DayBlock { day: day; } - Hairline {} - } + DayBlock { day: day; } + Hairline {} } } }