feat: align iOS client safety and consent experience

This commit is contained in:
MingNian
2026-07-29 13:30:34 +08:00
parent 3b5cec10a6
commit 01f4955e0e
11 changed files with 290 additions and 374 deletions

View File

@@ -438,9 +438,9 @@ class _HomePageState extends ConsumerState<HomePage>
child: Column(
mainAxisSize: MainAxisSize.min,
children: [
const SizedBox(height: 8),
const SizedBox(height: 4),
_buildAgentBar(),
const SizedBox(height: 12),
const SizedBox(height: 5),
if (_pickedImagePath != null) _buildImagePreview(),
_buildInputBar(),
],
@@ -490,13 +490,13 @@ class _HomePageState extends ConsumerState<HomePage>
chatProvider.select((state) => state.isStreaming),
);
return Padding(
padding: const EdgeInsets.fromLTRB(12, 0, 12, 10),
padding: const EdgeInsets.fromLTRB(12, 0, 12, 6),
child: Container(
padding: EdgeInsets.fromLTRB(
6,
elderMode ? 7 : 5,
elderMode ? 5 : 3,
6,
elderMode ? 7 : 5,
elderMode ? 5 : 3,
),
decoration: BoxDecoration(
color: Colors.white,
@@ -540,7 +540,7 @@ class _HomePageState extends ConsumerState<HomePage>
isDense: true,
contentPadding: EdgeInsets.symmetric(
horizontal: 4,
vertical: elderMode ? 15 : 12,
vertical: elderMode ? 12 : 9,
),
border: InputBorder.none,
enabledBorder: InputBorder.none,
@@ -971,7 +971,7 @@ class _VoiceHoldSurface extends StatelessWidget {
return Container(
padding: EdgeInsets.symmetric(
horizontal: 4,
vertical: elderMode ? 14 : 11,
vertical: elderMode ? 12 : 9,
),
alignment: Alignment.center,
child: Text(

View File

@@ -1276,7 +1276,6 @@ class ChatMessagesView extends ConsumerWidget {
/// 处理 AI 回复里的 markdown 链接点击:
/// - app://diet → 触发拍照/相册选择,跳到饮食拍照流程
/// - app://report → 跳到报告列表(用户可在那里上传新报告)
/// - app://device → 跳到蓝牙设备页
/// - 其他 app://xxx → 当作 route name 直接跳
static void _handleMarkdownLink(
BuildContext context,
@@ -1296,8 +1295,7 @@ class ChatMessagesView extends ConsumerWidget {
pushRoute(ref, 'reports');
break;
case 'device':
pushRoute(ref, 'devices');
break;
return;
default:
if (uri.host.isNotEmpty) pushRoute(ref, uri.host);
}
@@ -2199,12 +2197,6 @@ final _agentActions = <ActiveAgent, List<_AgentAction>>{
isWide: true,
route: 'trend',
),
_AgentAction(
label: '蓝牙录入',
icon: Icons.bluetooth,
isWide: true,
route: 'devices',
),
],
ActiveAgent.diet: [
_AgentAction(