UI Code
UI Code
📱 Screen 1 — splash_screen.dart
import 'package:flutter/[Link]';
@override
State<SplashScreen> createState() => _SplashScreenState();
}
@override
void initState() {
[Link]();
_logoCtrl = AnimationController(
vsync: this,
duration: const Duration(milliseconds: 800),
);
_textCtrl = AnimationController(
vsync: this,
duration: const Duration(milliseconds: 600),
);
_logoCtrl.forward();
[Link](const Duration(milliseconds: 500), () {
_textCtrl.forward();
});
@override
void dispose() {
_logoCtrl.dispose();
_textCtrl.dispose();
[Link]();
}
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const accentColor = Color(0xFF3B82F6);
const bgColor = Color(0xFFF8F7FC);
return Scaffold(
backgroundColor: bgColor,
body: Stack(
children: [
// Background Orb 1
Positioned(
top: [Link](context).[Link] * 0.18,
left: -70,
child: Container(
width: 280,
height: 280,
decoration: BoxDecoration(
shape: [Link],
color: [Link](0.12),
),
),
),
// Background Orb 2
Positioned(
bottom: [Link](context).[Link] * 0.18,
right: -50,
child: Container(
width: 220,
height: 220,
decoration: BoxDecoration(
shape: [Link],
color: [Link](0.12),
),
),
),
// Center Content
Center(
child: Column(
mainAxisAlignment: [Link],
children: [
// Logo
AnimatedBuilder(
animation: _logoCtrl,
builder: (_, child) => [Link](
angle: _logoRotate.value,
child: [Link](
scale: _logoScale.value,
child: child,
),
),
child: Container(
width: 112,
height: 112,
decoration: BoxDecoration(
borderRadius: [Link](28),
gradient: const LinearGradient(
colors: [primaryColor, accentColor],
begin: [Link],
end: [Link],
),
boxShadow: [
BoxShadow(
color: [Link](0.35),
blurRadius: 30,
offset: const Offset(0, 12),
),
],
),
child: const Center(
child: Text(
'P+',
style: TextStyle(
color: [Link],
fontSize: 42,
fontWeight: [Link],
),
),
),
),
),
const SizedBox(height: 32),
// App Name
FadeTransition(
opacity: _textOpacity,
child: SlideTransition(
position: _textSlide,
child: ShaderMask(
shaderCallback: (bounds) => const LinearGradient(
colors: [primaryColor, accentColor],
).createShader(bounds),
child: const Text(
'PriorityPlus',
style: TextStyle(
fontSize: 36,
fontWeight: [Link],
color: [Link],
letterSpacing: -0.5,
),
),
),
),
),
const SizedBox(height: 8),
// Subtitle
FadeTransition(
opacity: _textOpacity,
child: const Text(
'AI TASK PRIORITY PREDICTOR',
style: TextStyle(
fontSize: 11,
letterSpacing: 2.5,
color: Colors.black38,
fontWeight: FontWeight.w500,
),
),
),
const SizedBox(height: 48),
// Animated Loading Dots
_LoadingDots(),
],
),
),
],
),
);
}
}
@override
void initState() {
[Link]();
_ctrls = [Link](
3,
(i) => AnimationController(
vsync: this,
duration: const Duration(milliseconds: 800),
),
);
_anims = _ctrls
.map((c) => Tween<double>(begin: 0, end: -10).animate(
CurvedAnimation(parent: c, curve: [Link]),
))
.toList();
@override
void dispose() {
for (var c in _ctrls) [Link]();
[Link]();
}
@override
Widget build(BuildContext context) {
return Row(
mainAxisAlignment: [Link],
children: [Link](3, (i) {
return AnimatedBuilder(
animation: _anims[i],
builder: (_, __) => [Link](
offset: Offset(0, _anims[i].value),
child: Container(
width: 8,
height: 8,
margin: const [Link](horizontal: 4),
decoration: const BoxDecoration(
shape: [Link],
color: Color(0xFF7C3AED),
),
),
),
);
}),
);
}
}
📱 Screen 2 — task_input_screen.dart
import 'package:flutter/[Link]';
@override
State<TaskInputScreen> createState() => _TaskInputScreenState();
}
void _predict() {
final task = _ctrl.[Link]();
if ([Link]) return;
[Link](context).pushNamed('/result', arguments: task);
}
@override
void dispose() {
_ctrl.dispose();
[Link]();
}
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const accentColor = Color(0xFF3B82F6);
const bgColor = Color(0xFFF8F7FC);
const cardColor = [Link];
const foreground = Color(0xFF14101F);
const muted = Colors.black38;
return Scaffold(
backgroundColor: bgColor,
body: SafeArea(
child: SingleChildScrollView(
child: Column(
crossAxisAlignment: [Link],
children: [
// ── Hero Section ──
Container(
width: [Link],
decoration: const BoxDecoration(
gradient: LinearGradient(
colors: [
Color(0x107C3AED),
[Link],
Color(0x103B82F6),
],
begin: [Link],
end: [Link],
),
),
padding: const [Link](20, 24, 20, 24),
child: Column(
crossAxisAlignment: [Link],
children: [
// Logo + Title Row
Row(
children: [
Container(
width: 44,
height: 44,
decoration: BoxDecoration(
borderRadius: [Link](12),
gradient: const LinearGradient(
colors: [primaryColor, accentColor],
),
boxShadow: [
BoxShadow(
color: [Link](0.3),
blurRadius: 12,
offset: const Offset(0, 4),
),
],
),
child: const Center(
child: Text(
'P+',
style: TextStyle(
color: [Link],
fontSize: 16,
fontWeight: [Link],
),
),
),
),
const SizedBox(width: 12),
Column(
crossAxisAlignment: [Link],
children: [
ShaderMask(
shaderCallback: (b) => const LinearGradient(
colors: [primaryColor, accentColor],
).createShader(b),
child: const Text(
'PriorityPlus',
style: TextStyle(
fontSize: 18,
fontWeight: [Link],
color: [Link],
),
),
),
const Text(
'AI PRIORITY PREDICTOR',
style: TextStyle(
fontSize: 9,
letterSpacing: 1.5,
color: muted,
),
),
],
),
],
),
const SizedBox(height: 28),
// Heading
const Text(
"What's on your",
style: TextStyle(
fontSize: 30,
fontWeight: [Link],
color: foreground,
height: 1.3,
),
),
ShaderMask(
shaderCallback: (b) => const LinearGradient(
colors: [primaryColor, accentColor],
).createShader(b),
child: const Text(
'mind today?',
style: TextStyle(
fontSize: 30,
fontWeight: [Link],
color: [Link],
),
),
),
const SizedBox(height: 10),
const Text(
'Enter your task and let AI predict its priority level instantly.',
style: TextStyle(
fontSize: 13,
color: muted,
height: 1.6,
),
),
],
),
),
// ── Input Card ──
Padding(
padding: const [Link](horizontal: 20),
child: Container(
decoration: BoxDecoration(
color: cardColor,
borderRadius: [Link](24),
boxShadow: [
BoxShadow(
color: [Link](0.07),
blurRadius: 24,
offset: const Offset(0, 8),
),
],
),
padding: const [Link](20),
child: Column(
crossAxisAlignment: [Link],
children: [
const Text(
'DESCRIBE YOUR TASK',
style: TextStyle(
fontSize: 10,
letterSpacing: 1.2,
fontWeight: FontWeight.w600,
color: muted,
),
),
const SizedBox(height: 10),
// TextField
Container(
decoration: BoxDecoration(
color: const Color(0xFFF1EEF9),
borderRadius: [Link](16),
),
child: TextField(
controller: _ctrl,
maxLines: 5,
style: const TextStyle(
fontSize: 13,
color: foreground,
),
decoration: const InputDecoration(
hintText:
'e.g. Complete the quarterly report for the client meeting
tomorrow...',
hintStyle: TextStyle(
color: muted,
fontSize: 13,
),
border: [Link],
contentPadding: [Link](16),
),
),
),
const SizedBox(height: 16),
// Predict Button
SizedBox(
width: [Link],
height: 56,
child: DecoratedBox(
decoration: BoxDecoration(
gradient: const LinearGradient(
colors: [primaryColor, accentColor],
),
borderRadius: [Link](16),
boxShadow: [
BoxShadow(
color: [Link](0.3),
blurRadius: 16,
offset: const Offset(0, 6),
),
],
),
child: ElevatedButton(
onPressed: _predict,
style: [Link](
backgroundColor: [Link],
shadowColor: [Link],
shape: RoundedRectangleBorder(
borderRadius: [Link](16),
),
),
child: const Row(
mainAxisAlignment: [Link],
children: [
Icon(Icons.auto_awesome_rounded,
color: [Link], size: 20),
SizedBox(width: 8),
Text(
'Predict Priority',
style: TextStyle(
color: [Link],
fontSize: 16,
fontWeight: [Link],
),
),
SizedBox(width: 8),
Icon(Icons.arrow_forward_rounded,
color: [Link], size: 18),
],
),
),
),
),
],
),
),
),
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const muted = Colors.black38;
return Container(
color: const Color(0xFFF8F7FC),
padding: const [Link](16, 0, 16, 16),
child: Container(
height: 64,
decoration: BoxDecoration(
color: [Link],
borderRadius: [Link](20),
border: [Link](color: [Link](0.05)),
boxShadow: [
BoxShadow(
color: [Link](0.07),
blurRadius: 20,
offset: const Offset(0, 4),
),
],
),
child: Row(
children: [
_NavItem(
icon: Icons.checklist_rounded,
label: 'Tasks',
isActive: currentIndex == 0,
onTap: () {},
),
_NavItem(
icon: Icons.settings_rounded,
label: 'Settings',
isActive: currentIndex == 1,
onTap: () => [Link](context).pushNamed('/settings'),
),
],
),
),
);
}
}
const _NavItem({
required [Link],
required [Link],
required [Link],
required [Link],
});
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const muted = Colors.black38;
return Expanded(
child: GestureDetector(
onTap: onTap,
behavior: [Link],
child: AnimatedContainer(
duration: const Duration(milliseconds: 200),
margin: const [Link](6),
decoration: BoxDecoration(
color: isActive
? [Link](0.1)
: [Link],
borderRadius: [Link](14),
),
child: Column(
mainAxisAlignment: [Link],
children: [
Icon(icon,
color: isActive ? primaryColor : muted, size: 22),
const SizedBox(height: 2),
Text(
label,
style: TextStyle(
fontSize: 11,
fontWeight:
isActive ? [Link] : [Link],
color: isActive ? primaryColor : muted,
),
),
],
),
),
),
);
}
}
📱 Screen 3 — result_screen.dart
import 'package:flutter/[Link]';
@override
State<ResultScreen> createState() => _ResultScreenState();
}
@override
void initState() {
[Link]();
_predict();
}
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const accentColor = Color(0xFF3B82F6);
const bgColor = Color(0xFFF8F7FC);
const cardColor = [Link];
const foreground = Color(0xFF14101F);
const muted = Colors.black38;
return Scaffold(
backgroundColor: bgColor,
body: SafeArea(
child: SingleChildScrollView(
padding: const [Link](20, 24, 20, 24),
child: Column(
crossAxisAlignment: [Link],
children: [
// ── Header ──
Row(
children: [
GestureDetector(
onTap: () => [Link](context).pop(),
child: Container(
width: 40,
height: 40,
decoration: BoxDecoration(
color: cardColor,
borderRadius: [Link](12),
border: [Link](
color: [Link](0.06)),
),
child: const Icon(Icons.arrow_back_rounded,
color: foreground, size: 20),
),
),
const SizedBox(width: 12),
const Column(
crossAxisAlignment: [Link],
children: [
Text(
'Analysis Result',
style: TextStyle(
fontSize: 18,
fontWeight: [Link],
color: foreground,
),
),
Text(
'AI Priority Prediction',
style: TextStyle(fontSize: 11, color: muted),
),
],
),
],
),
const SizedBox(height: 24),
// ── Loading State ──
if (_loading)
Center(
child: Padding(
padding: const [Link](vertical: 80),
child: Column(
children: [
Container(
width: 80,
height: 80,
decoration: BoxDecoration(
borderRadius: [Link](24),
gradient: const LinearGradient(
colors: [primaryColor, accentColor],
),
boxShadow: [
BoxShadow(
color: [Link](0.4),
blurRadius: 24,
offset: const Offset(0, 8),
),
],
),
child: const Icon(Icons.auto_awesome_rounded,
color: [Link], size: 36),
),
const SizedBox(height: 20),
const Text(
'Analyzing your task...',
style: TextStyle(fontSize: 13, color: muted),
),
const SizedBox(height: 16),
const CircularProgressIndicator(
color: primaryColor,
strokeWidth: 2,
),
],
),
),
),
// ── Result State ──
if (!_loading && _result != null) ...[
// Priority Hero Card
_PriorityCard(result: _result!),
const SizedBox(height: 16),
// Task Card
_TaskCard(
task: [Link],
priority: _result!['priority'],
reason: _result!['reason'],
),
const SizedBox(height: 16),
// Tips Card
_TipsCard(tips: List<String>.from(_result!['tips'])),
const SizedBox(height: 20),
// Action Buttons
Row(
children: [
Expanded(
child: [Link](
onPressed: _predict,
icon: const Icon(Icons.refresh_rounded, size: 18),
label: const Text('Re-analyze'),
style: [Link](
foregroundColor: foreground,
side: BorderSide(
color: [Link](0.15)),
minimumSize: const Size(0, 50),
shape: RoundedRectangleBorder(
borderRadius: [Link](16),
),
),
),
),
const SizedBox(width: 12),
Expanded(
child: DecoratedBox(
decoration: BoxDecoration(
gradient: const LinearGradient(
colors: [primaryColor, accentColor],
),
borderRadius: [Link](16),
),
child: ElevatedButton(
onPressed: () => [Link](context).pop(),
style: [Link](
backgroundColor: [Link],
shadowColor: [Link],
minimumSize: const Size(0, 50),
shape: RoundedRectangleBorder(
borderRadius: [Link](16),
),
),
child: const Text(
'New Task',
style: TextStyle(
color: [Link],
fontWeight: [Link],
),
),
),
),
),
],
),
],
const SizedBox(height: 80),
],
),
),
),
bottomNavigationBar: _BottomNav(currentIndex: 0),
);
}
}
@override
Widget build(BuildContext context) {
final priority = result['priority'] as String;
final urgency = (result['urgency_score'] as num).toDouble();
return Container(
width: [Link],
decoration: BoxDecoration(
color: [Link],
borderRadius: [Link](24),
boxShadow: [
BoxShadow(
color: [Link](0.12),
blurRadius: 20,
offset: const Offset(0, 6),
),
],
),
padding: const [Link](24),
child: Column(
children: [
Text(emoji, style: const TextStyle(fontSize: 48)),
const SizedBox(height: 8),
ShaderMask(
shaderCallback: (b) =>
LinearGradient(colors: gradient).createShader(b),
child: Text(
'$priority Priority',
style: const TextStyle(
fontSize: 28,
fontWeight: [Link],
color: [Link],
),
),
),
const SizedBox(height: 20),
Row(
mainAxisAlignment: [Link],
children: [
const Text('Urgency Score',
style: TextStyle(fontSize: 11, color: Colors.black38)),
Text(
'${result['urgency_score'].toInt()}/100',
style: const TextStyle(
fontSize: 11,
fontWeight: [Link],
color: Color(0xFF14101F),
),
),
],
),
const SizedBox(height: 8),
ClipRRect(
borderRadius: [Link](8),
child: TweenAnimationBuilder<double>(
tween: Tween(begin: 0, end: urgency / 100),
duration: const Duration(milliseconds: 1000),
curve: [Link],
builder: (_, val, __) => LinearProgressIndicator(
value: val,
minHeight: 10,
backgroundColor: [Link](0.07),
valueColor: AlwaysStoppedAnimation<Color>(color),
),
),
),
],
),
);
}
}
// ── Task Card ──
class _TaskCard extends StatelessWidget {
final String task, priority, reason;
const _TaskCard(
{required [Link], required [Link], required [Link]});
@override
Widget build(BuildContext context) {
final Map<String, Color> pColors = {
'High': const Color(0xFFEF4444),
'Medium': const Color(0xFFF59E0B),
'Low': const Color(0xFF10B981),
};
final color = pColors[priority] ?? const Color(0xFFF59E0B);
return Container(
decoration: BoxDecoration(
color: [Link](0.08),
borderRadius: [Link](20),
border: [Link](color: [Link](0.2)),
),
padding: const [Link](20),
child: Column(
crossAxisAlignment: [Link],
children: [
Row(
crossAxisAlignment: [Link],
children: [
Expanded(
child: Text(
task,
style: const TextStyle(
fontSize: 14,
fontWeight: FontWeight.w500,
color: Color(0xFF14101F),
height: 1.5,
),
),
),
const SizedBox(width: 8),
Container(
padding:
const [Link](horizontal: 12, vertical: 4),
decoration: BoxDecoration(
color: [Link](0.1),
borderRadius: [Link](20),
border: [Link](color: [Link](0.3)),
),
child: Text(
priority,
style: TextStyle(
fontSize: 11,
fontWeight: [Link],
color: color,
),
),
),
],
),
const SizedBox(height: 10),
Row(
crossAxisAlignment: [Link],
children: [
const Icon(Icons.auto_awesome_rounded,
color: Color(0xFF7C3AED), size: 14),
const SizedBox(width: 6),
Expanded(
child: Text(
reason,
style: const TextStyle(
fontSize: 12,
color: Colors.black45,
height: 1.5,
),
),
),
],
),
],
),
);
}
}
// ── Tips Card ──
class _TipsCard extends StatelessWidget {
final List<String> tips;
const _TipsCard({required [Link]});
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
return Container(
decoration: BoxDecoration(
color: [Link],
borderRadius: [Link](24),
),
padding: const [Link](20),
child: Column(
crossAxisAlignment: [Link],
children: [
const Row(
children: [
Icon(Icons.auto_awesome_rounded,
color: primaryColor, size: 16),
SizedBox(width: 8),
Text(
'AI Tips',
style: TextStyle(
fontSize: 14,
fontWeight: [Link],
color: Color(0xFF14101F),
),
),
],
),
const SizedBox(height: 12),
...[Link]([Link], (i) {
return Padding(
padding: const [Link](bottom: 10),
child: Row(
crossAxisAlignment: [Link],
children: [
Container(
width: 24,
height: 24,
decoration: BoxDecoration(
color: [Link](0.1),
borderRadius: [Link](8),
),
child: Center(
child: Text(
'${i + 1}',
style: const TextStyle(
fontSize: 11,
fontWeight: [Link],
color: primaryColor,
),
),
),
),
const SizedBox(width: 10),
Expanded(
child: Text(
tips[i],
style: const TextStyle(
fontSize: 12,
color: Colors.black45,
height: 1.5,
),
),
),
],
),
);
}),
],
),
);
}
}
// ── Bottom Nav ──
class _BottomNav extends StatelessWidget {
final int currentIndex;
const _BottomNav({required [Link]});
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const muted = Colors.black38;
return Container(
color: const Color(0xFFF8F7FC),
padding: const [Link](16, 0, 16, 16),
child: Container(
height: 64,
decoration: BoxDecoration(
color: [Link],
borderRadius: [Link](20),
border: [Link](color: [Link](0.05)),
boxShadow: [
BoxShadow(
color: [Link](0.07),
blurRadius: 20,
offset: const Offset(0, 4),
),
],
),
child: Row(
children: [
_Item(
icon: Icons.checklist_rounded,
label: 'Tasks',
isActive: currentIndex == 0,
onTap: () => [Link](context).pop(),
),
_Item(
icon: Icons.settings_rounded,
label: 'Settings',
isActive: currentIndex == 1,
onTap: () => [Link](context).pushNamed('/settings'),
),
],
),
),
);
}
}
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const muted = Colors.black38;
return Expanded(
child: GestureDetector(
onTap: onTap,
behavior: [Link],
child: AnimatedContainer(
duration: const Duration(milliseconds: 200),
margin: const [Link](6),
decoration: BoxDecoration(
color: isActive
? [Link](0.1)
: [Link],
borderRadius: [Link](14),
),
child: Column(
mainAxisAlignment: [Link],
children: [
Icon(icon,
color: isActive ? primaryColor : muted, size: 22),
const SizedBox(height: 2),
Text(label,
style: TextStyle(
fontSize: 11,
fontWeight:
isActive ? [Link] : [Link],
color: isActive ? primaryColor : muted,
)),
],
),
),
),
);
}
}
📱 Screen 4 — settings_screen.dart
import 'package:flutter/[Link]';
@override
State<SettingsScreen> createState() => _SettingsScreenState();
}
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const accentColor = Color(0xFF3B82F6);
const bgColor = Color(0xFFF8F7FC);
const cardColor = [Link];
const foreground = Color(0xFF14101F);
const muted = Colors.black38;
return Scaffold(
backgroundColor: bgColor,
body: SafeArea(
child: SingleChildScrollView(
padding: const [Link](20, 24, 20, 24),
child: Column(
crossAxisAlignment: [Link],
children: [
// ── Header ──
const Text(
'Settings',
style: TextStyle(
fontSize: 22,
fontWeight: [Link],
color: foreground,
),
),
const SizedBox(height: 4),
const Text(
'Customize your experience',
style: TextStyle(fontSize: 13, color: muted),
),
const SizedBox(height: 20),
// ── Appearance Card ──
_card(
child: Column(
crossAxisAlignment: [Link],
children: [
const Text(
'APPEARANCE',
style: TextStyle(
fontSize: 10,
letterSpacing: 1.2,
fontWeight: FontWeight.w600,
color: muted,
),
),
const SizedBox(height: 16),
Row(
children: [
Container(
width: 40,
height: 40,
decoration: BoxDecoration(
color: [Link](0.1),
borderRadius: [Link](12),
),
child: Icon(
_darkMode
? Icons.nightlight_round
: Icons.wb_sunny_rounded,
color: primaryColor,
size: 20,
),
),
const SizedBox(width: 12),
Expanded(
child: Column(
crossAxisAlignment: [Link],
children: [
const Text(
'Dark Mode',
style: TextStyle(
fontSize: 14,
color: foreground,
fontWeight: FontWeight.w500,
),
),
Text(
_darkMode
? 'Dark theme active'
: 'Light theme active',
style: const TextStyle(
fontSize: 11, color: muted),
),
],
),
),
Switch(
value: _darkMode,
onChanged: (val) =>
setState(() => _darkMode = val),
activeColor: primaryColor,
),
],
),
],
),
),
const SizedBox(height: 16),
// ── Support Card ──
_card(
child: Column(
crossAxisAlignment: [Link],
children: [
const Text(
'SUPPORT',
style: TextStyle(
fontSize: 10,
letterSpacing: 1.2,
fontWeight: FontWeight.w600,
color: muted,
),
),
const SizedBox(height: 8),
...[
{
'icon': Icons.help_outline_rounded,
'label': 'Help & FAQ',
'isFaq': true
},
{
'icon': Icons.shield_outlined,
'label': 'Privacy Policy',
'isFaq': false
},
{
'icon': Icons.star_outline_rounded,
'label': 'Rate the App',
'isFaq': false
},
{
'icon': Icons.chat_bubble_outline_rounded,
'label': 'Send Feedback',
'isFaq': false
},
].map((item) {
return InkWell(
onTap: (item['isFaq'] == true)
? () => _showFaqSheet(context)
: null,
borderRadius: [Link](12),
child: Padding(
padding: const [Link](vertical: 6),
child: Row(
children: [
Container(
width: 36,
height: 36,
decoration: BoxDecoration(
color: [Link](0.1),
borderRadius: [Link](10),
),
child: Icon(
item['icon'] as IconData,
color: primaryColor,
size: 18,
),
),
const SizedBox(width: 12),
Expanded(
child: Text(
item['label'] as String,
style: const TextStyle(
fontSize: 13, color: foreground),
),
),
const Icon(Icons.chevron_right_rounded,
color: muted, size: 18),
],
),
),
);
}).toList(),
],
),
),
const SizedBox(height: 20),
// ── Credits ──
Center(
child: Column(
children: [
ShaderMask(
shaderCallback: (b) => const LinearGradient(
colors: [primaryColor, accentColor],
).createShader(b),
child: const Text(
'Powered by AI Technology',
style: TextStyle(
fontSize: 11,
fontWeight: FontWeight.w600,
color: [Link],
),
),
),
const SizedBox(height: 4),
const Text(
'Made with ❤️ by PriorityPlus Team',
style: TextStyle(fontSize: 10, color: muted),
),
],
),
),
const SizedBox(height: 80),
],
),
),
),
bottomNavigationBar: _BottomNav(currentIndex: 1),
);
}
showModalBottomSheet(
context: context,
isScrollControlled: true,
backgroundColor: [Link],
builder: (_) {
return StatefulBuilder(builder: (ctx, setS) {
return Container(
constraints: BoxConstraints(
maxHeight: [Link](context).[Link] * 0.8,
),
decoration: const BoxDecoration(
color: [Link],
borderRadius:
[Link](top: [Link](24)),
),
child: Column(
children: [
Container(
width: 40,
height: 4,
margin: const [Link](vertical: 12),
decoration: BoxDecoration(
color: Colors.black12,
borderRadius: [Link](2),
),
),
const Padding(
padding: [Link](20, 0, 20, 16),
child: Row(
children: [
Icon(Icons.help_outline_rounded,
color: primaryColor, size: 20),
SizedBox(width: 8),
Text(
'Help & FAQ',
style: TextStyle(
fontSize: 18,
fontWeight: [Link],
color: foreground,
),
),
],
),
),
const Divider(height: 1),
Expanded(
child: [Link](
padding: const [Link](16),
itemCount: _faqs.length,
itemBuilder: (_, i) {
final isExp = _expandedFaq == i;
return GestureDetector(
onTap: () =>
setS(() => _expandedFaq = isExp ? null : i),
child: Container(
margin: const [Link](bottom: 10),
decoration: BoxDecoration(
color: [Link](0.03),
borderRadius: [Link](16),
),
padding: const [Link](16),
child: Column(
crossAxisAlignment: [Link],
children: [
Row(
children: [
Expanded(
child: Text(
_faqs[i]['q']!,
style: const TextStyle(
fontSize: 13,
fontWeight: FontWeight.w500,
color: foreground,
),
),
),
Icon(
isExp
? Icons.expand_less_rounded
: Icons.chevron_right_rounded,
color: muted,
size: 18,
),
],
),
if (isExp) ...[
const SizedBox(height: 8),
Text(
_faqs[i]['a']!,
style: const TextStyle(
fontSize: 12,
color: muted,
height: 1.5,
),
),
],
],
),
),
);
},
),
),
],
),
);
});
},
);
}
}
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const muted = Colors.black38;
return Container(
color: const Color(0xFFF8F7FC),
padding: const [Link](16, 0, 16, 16),
child: Container(
height: 64,
decoration: BoxDecoration(
color: [Link],
borderRadius: [Link](20),
border: [Link](color: [Link](0.05)),
boxShadow: [
BoxShadow(
color: [Link](0.07),
blurRadius: 20,
offset: const Offset(0, 4),
),
],
),
child: Row(
children: [
_Item(
icon: Icons.checklist_rounded,
label: 'Tasks',
isActive: currentIndex == 0,
onTap: () => [Link](context).pop(),
),
_Item(
icon: Icons.settings_rounded,
label: 'Settings',
isActive: currentIndex == 1,
onTap: () {},
),
],
),
),
);
}
}
@override
Widget build(BuildContext context) {
const primaryColor = Color(0xFF7C3AED);
const muted = Colors.black38;
return Expanded(
child: GestureDetector(
onTap: onTap,
behavior: [Link],
child: AnimatedContainer(
duration: const Duration(milliseconds: 200),
margin: const [Link](6),
decoration: BoxDecoration(
color: isActive
? [Link](0.1)
: [Link],
borderRadius: [Link](14),
),
child: Column(
mainAxisAlignment: [Link],
children: [
Icon(icon,
color: isActive ? primaryColor : muted, size: 22),
const SizedBox(height: 2),
Text(label,
style: TextStyle(
fontSize: 11,
fontWeight:
isActive ? [Link] : [Link],
color: isActive ? primaryColor : muted,
)),
],
),
),
),
);
}
}
📁 Folder Structure
lib/
├── [Link] ← Routes setup
├── splash_screen.dart ← Screen 1
├── task_input_screen.dart ← Screen 2
├── result_screen.dart ← Screen 3
└── settings_screen.dart ← Screen 4
[Link] (Routes)
import 'package:flutter/[Link]';
import 'splash_screen.dart';
import 'task_input_screen.dart';
import 'result_screen.dart';
import 'settings_screen.dart';
void main() => runApp(const PriorityPlusApp());
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'PriorityPlus',
debugShowCheckedModeBanner: false,
theme: ThemeData(
useMaterial3: true,
fontFamily: 'Inter',
colorScheme: [Link](seedColor: const Color(0xFF7C3AED)),
),
initialRoute: '/',
routes: {
'/': (_) => const SplashScreen(),
'/home': (_) => const TaskInputScreen(),
'/settings': (_) => const SettingsScreen(),
},
onGenerateRoute: (settings) {
if ([Link] == '/result') {
final task = [Link] as String;
return MaterialPageRoute(
builder: (_) => ResultScreen(task: task),
);
}
return null;
},
);
}
}