fix:UI对齐demo

This commit is contained in:
jingyun
2026-06-18 18:08:29 +08:00
parent f42ad566e0
commit 2d7523f901
14 changed files with 1613 additions and 355 deletions
@@ -52,7 +52,10 @@ class NewsDetailPage extends ConsumerWidget {
Row(
children: [
Container(
padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 3),
padding: const EdgeInsets.symmetric(
horizontal: 8,
vertical: 3,
),
decoration: BoxDecoration(
color: item.metal.color.withValues(alpha: 0.12),
borderRadius: BorderRadius.circular(999),
@@ -69,14 +72,21 @@ class NewsDetailPage extends ConsumerWidget {
const SizedBox(width: 8),
Text(
'${item.source} · ${_timeLabel(item.publishedAt)}',
style: TextStyle(fontSize: 12, color: cs.mutedForeground),
style: TextStyle(
fontSize: 12,
color: cs.mutedForeground,
),
),
],
),
const SizedBox(height: 12),
Text(
item.title,
style: const TextStyle(fontSize: 18, fontWeight: FontWeight.w700, height: 1.4),
style: const TextStyle(
fontSize: 18,
fontWeight: FontWeight.w700,
height: 1.4,
),
),
const SizedBox(height: 12),
for (final paragraph in item.body) ...[
@@ -90,10 +100,6 @@ class NewsDetailPage extends ConsumerWidget {
),
const SizedBox(height: 12),
],
Text(
'本资讯为原型示意内容,信息整理 · 非投资建议。',
style: TextStyle(fontSize: 12, color: cs.mutedForeground, height: 1.5),
),
],
),
),