fix(app): poster title truly left-aligned — Column crossAxisAlignment start (QR re-centered)
Text 的 textAlign 被 Column 默认 center 吞掉(文本行收缩包裹时对齐不生效); 文字区 Column 改 CrossAxisAlignment.start,二维码+扫码说明显式 Center 回居中。 Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
@@ -448,8 +448,11 @@ class _PosterSheetState extends ConsumerState<_PosterSheet> {
|
|||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.all(kSpace24),
|
padding: const EdgeInsets.all(kSpace24),
|
||||||
child: Column(
|
child: Column(
|
||||||
|
// 标题/时间/地址居左(Column 默认 center 会吞掉
|
||||||
|
// Text 的 textAlign——对齐由这里统一决定)。
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
children: [
|
children: [
|
||||||
// 活动标题(居左;二维码保持居中)。
|
// 活动标题(居左)。
|
||||||
Text(
|
Text(
|
||||||
title,
|
title,
|
||||||
textAlign: TextAlign.left,
|
textAlign: TextAlign.left,
|
||||||
@@ -509,20 +512,24 @@ class _PosterSheetState extends ConsumerState<_PosterSheet> {
|
|||||||
),
|
),
|
||||||
],
|
],
|
||||||
const SizedBox(height: kSpace24),
|
const SizedBox(height: kSpace24),
|
||||||
// 二维码(白底保持扫码对比度)。
|
// 二维码 + 说明:保持居中(文字区居左的例外)。
|
||||||
QrImageView(
|
Center(
|
||||||
|
child: QrImageView(
|
||||||
data: url,
|
data: url,
|
||||||
version: QrVersions.auto,
|
version: QrVersions.auto,
|
||||||
size: 200,
|
size: 200,
|
||||||
backgroundColor: Colors.white,
|
backgroundColor: Colors.white,
|
||||||
),
|
),
|
||||||
|
),
|
||||||
const SizedBox(height: kSpace12),
|
const SizedBox(height: kSpace12),
|
||||||
Text(
|
Center(
|
||||||
|
child: Text(
|
||||||
l10n.shareScanHint,
|
l10n.shareScanHint,
|
||||||
style: theme.textTheme.bodySmall?.copyWith(
|
style: theme.textTheme.bodySmall?.copyWith(
|
||||||
color: const Color(0xFF69778E),
|
color: const Color(0xFF69778E),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -370,9 +370,7 @@ test.describe.serial('E04 interactions: pause, click lock, keyboard, destroy', (
|
|||||||
await frame.waitFor();
|
await frame.waitFor();
|
||||||
const inside = page.frameLocator('iframe[src*="/embed/"][src*="v=2"]');
|
const inside = page.frameLocator('iframe[src*="/embed/"][src*="v=2"]');
|
||||||
await page.waitForTimeout(1200);
|
await page.waitForTimeout(1200);
|
||||||
// 聚焦流区域(点击视口非链接处不触发照片点击——顶部渐隐带命中视口)。
|
// 聚焦流区域(程序化聚焦,不点击——照片点击现会打开宿主详情弹框)。
|
||||||
const box = await frame.boundingBox();
|
|
||||||
await page.mouse.click((box!.x ?? 0) + 90, (box!.y ?? 0) + 6);
|
|
||||||
await inside.locator('.stream-viewport').focus();
|
await inside.locator('.stream-viewport').focus();
|
||||||
await page.keyboard.press(' ');
|
await page.keyboard.press(' ');
|
||||||
await page.waitForTimeout(300);
|
await page.waitForTimeout(300);
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 106 KiB After Width: | Height: | Size: 106 KiB |
Binary file not shown.
Reference in New Issue
Block a user