refactor: 重构前端 UI 组件与后端 AgentScope schemas
This commit is contained in:
@@ -9,21 +9,25 @@ class LinkButton extends StatelessWidget {
|
||||
required this.onTap,
|
||||
this.enabled = true,
|
||||
this.textAlign = TextAlign.center,
|
||||
this.foregroundColor,
|
||||
});
|
||||
|
||||
final String text;
|
||||
final VoidCallback? onTap;
|
||||
final bool enabled;
|
||||
final TextAlign textAlign;
|
||||
final Color? foregroundColor;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final effectiveColor = foregroundColor ?? AppColors.slate500;
|
||||
|
||||
return SizedBox(
|
||||
height: 44,
|
||||
child: TextButton(
|
||||
onPressed: enabled ? onTap : null,
|
||||
style: TextButton.styleFrom(
|
||||
foregroundColor: enabled ? AppColors.slate500 : AppColors.slate300,
|
||||
foregroundColor: enabled ? effectiveColor : AppColors.slate300,
|
||||
padding: const EdgeInsets.symmetric(
|
||||
horizontal: AppSpacing.md,
|
||||
vertical: AppSpacing.sm,
|
||||
|
||||
Reference in New Issue
Block a user