fix:对比原型增加功能交互
This commit is contained in:
@@ -3,6 +3,8 @@ import 'package:go_router/go_router.dart';
|
||||
import 'package:hooks_riverpod/hooks_riverpod.dart';
|
||||
import 'package:shadcn_ui/shadcn_ui.dart';
|
||||
|
||||
import '../../data/providers.dart';
|
||||
import '../../data/state/app_interaction_state.dart';
|
||||
import '../../routing/app_routes.dart';
|
||||
import '../../theme/app_icons.dart';
|
||||
import '../../theme/theme_controller.dart';
|
||||
@@ -88,13 +90,23 @@ class SettingsPage extends ConsumerWidget {
|
||||
_LinkTile(
|
||||
icon: Icons.description_outlined,
|
||||
title: '用户协议',
|
||||
onTap: () => showOutboundSheet(context, title: '用户协议'),
|
||||
onTap: () => _showOutbound(
|
||||
context,
|
||||
ref,
|
||||
'settings_user_agreement',
|
||||
'用户协议',
|
||||
),
|
||||
),
|
||||
const Divider(height: 1, thickness: 1),
|
||||
_LinkTile(
|
||||
icon: Icons.privacy_tip_outlined,
|
||||
title: '隐私政策',
|
||||
onTap: () => showOutboundSheet(context, title: '隐私政策'),
|
||||
onTap: () => _showOutbound(
|
||||
context,
|
||||
ref,
|
||||
'settings_privacy_policy',
|
||||
'隐私政策',
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
@@ -130,6 +142,21 @@ class SettingsPage extends ConsumerWidget {
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
void _showOutbound(
|
||||
BuildContext context,
|
||||
WidgetRef ref,
|
||||
String scene,
|
||||
String title,
|
||||
) {
|
||||
showOutboundSheet(
|
||||
context,
|
||||
title: title,
|
||||
onConfirm: () => ref
|
||||
.read(outboundRepositoryProvider)
|
||||
.recordOutbound(OutboundEvent(scene: scene)),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
class _ThemeModeTile extends StatelessWidget {
|
||||
|
||||
Reference in New Issue
Block a user