225 lines
8.2 KiB
Dart
225 lines
8.2 KiB
Dart
import 'package:flutter/material.dart';
|
|
import '../colors/app_colors.dart';
|
|
|
|
import '../colors/app_gradients.dart';
|
|
import '../strings/curiosidade_strings.dart';
|
|
import '../widgets/entrance.dart';
|
|
import '../widgets/liquid_waves_background.dart';
|
|
import '../widgets/tap_bounce.dart';
|
|
|
|
class CuriosidadeScreen extends StatelessWidget {
|
|
const CuriosidadeScreen({super.key});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Scaffold(
|
|
appBar: PreferredSize(
|
|
preferredSize: const Size.fromHeight(kToolbarHeight),
|
|
child: Container(
|
|
decoration: const BoxDecoration(gradient: kAppBarGradient),
|
|
child: AppBar(
|
|
backgroundColor: Colors.transparent,
|
|
foregroundColor: Colors.white,
|
|
surfaceTintColor: Colors.transparent,
|
|
elevation: 0,
|
|
scrolledUnderElevation: 0,
|
|
title: const Text(
|
|
CuriosidadeStrings.pageTitle,
|
|
style: TextStyle(fontWeight: FontWeight.w900),
|
|
),
|
|
),
|
|
),
|
|
),
|
|
body: Stack(
|
|
clipBehavior: Clip.none,
|
|
children: [
|
|
Positioned.fill(child: Container(color: AppColors.background)),
|
|
const LiquidWavesBackground(),
|
|
SafeArea(
|
|
child: Align(
|
|
alignment: Alignment.topCenter,
|
|
child: ConstrainedBox(
|
|
constraints: const BoxConstraints(maxWidth: 560),
|
|
child: ListView(
|
|
padding: const EdgeInsets.fromLTRB(16, 16, 16, 16),
|
|
children: [
|
|
FadeSlideIn(
|
|
child: TapBounce(
|
|
scale: 0.97,
|
|
child: _CuriosityTopicTile(
|
|
title: CuriosidadeStrings.topicXTitle,
|
|
description: CuriosidadeStrings.topicXDescription,
|
|
),
|
|
),
|
|
),
|
|
const SizedBox(height: 12),
|
|
FadeSlideIn(
|
|
delay: const Duration(milliseconds: 60),
|
|
child: const TapBounce(
|
|
scale: 0.97,
|
|
child: _CuriosityTopicTile(
|
|
title: CuriosidadeStrings.topicYTitle,
|
|
description: CuriosidadeStrings.contentComingSoon,
|
|
),
|
|
),
|
|
),
|
|
const SizedBox(height: 12),
|
|
FadeSlideIn(
|
|
delay: const Duration(milliseconds: 120),
|
|
child: const TapBounce(
|
|
scale: 0.97,
|
|
child: _CuriosityTopicTile(
|
|
title: CuriosidadeStrings.topicZTitle,
|
|
description: CuriosidadeStrings.contentComingSoon,
|
|
),
|
|
),
|
|
),
|
|
const SizedBox(height: 12),
|
|
FadeSlideIn(
|
|
delay: const Duration(milliseconds: 180),
|
|
child: const TapBounce(
|
|
scale: 0.97,
|
|
child: _CuriosityTopicTile(
|
|
title: CuriosidadeStrings.topicUTitle,
|
|
description: CuriosidadeStrings.contentComingSoon,
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
);
|
|
}
|
|
}
|
|
|
|
class _CuriosityTopicTile extends StatelessWidget {
|
|
const _CuriosityTopicTile({required this.title, required this.description});
|
|
|
|
final String title;
|
|
final String description;
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Material(
|
|
color: Colors.white.withValues(alpha: 0.82),
|
|
borderRadius: BorderRadius.circular(18),
|
|
elevation: 8,
|
|
shadowColor: Colors.black.withValues(alpha: 0.10),
|
|
child: InkWell(
|
|
borderRadius: BorderRadius.circular(18),
|
|
onTap: () {
|
|
showModalBottomSheet<void>(
|
|
context: context,
|
|
showDragHandle: true,
|
|
backgroundColor: AppColors.pinkBackground,
|
|
shape: const RoundedRectangleBorder(
|
|
borderRadius: BorderRadius.vertical(top: Radius.circular(24)),
|
|
),
|
|
builder: (ctx) {
|
|
return SafeArea(
|
|
child: Padding(
|
|
padding: const EdgeInsets.fromLTRB(18, 6, 18, 18),
|
|
child: Column(
|
|
mainAxisSize: MainAxisSize.min,
|
|
crossAxisAlignment: CrossAxisAlignment.stretch,
|
|
children: [
|
|
Text(
|
|
title,
|
|
textAlign: TextAlign.center,
|
|
style: const TextStyle(
|
|
fontSize: 18,
|
|
fontWeight: FontWeight.w900,
|
|
color: AppColors.pink,
|
|
),
|
|
),
|
|
const SizedBox(height: 10),
|
|
Container(
|
|
padding: const EdgeInsets.all(14),
|
|
decoration: BoxDecoration(
|
|
color: Colors.white.withValues(alpha: 0.82),
|
|
borderRadius: BorderRadius.circular(16),
|
|
border: Border.all(
|
|
color: Colors.black.withValues(alpha: 0.08),
|
|
),
|
|
),
|
|
child: Text(
|
|
description,
|
|
style: TextStyle(
|
|
color: Colors.black.withValues(alpha: 0.72),
|
|
fontWeight: FontWeight.w600,
|
|
height: 1.25,
|
|
),
|
|
),
|
|
),
|
|
const SizedBox(height: 14),
|
|
TapBounce(
|
|
child: ClipRRect(
|
|
borderRadius: BorderRadius.circular(999),
|
|
child: DecoratedBox(
|
|
decoration: const BoxDecoration(
|
|
gradient: kGreenButtonGradient,
|
|
),
|
|
child: SizedBox(
|
|
height: 44,
|
|
child: FilledButton(
|
|
style: FilledButton.styleFrom(
|
|
backgroundColor: Colors.transparent,
|
|
foregroundColor: Colors.white,
|
|
shape: const StadiumBorder(),
|
|
textStyle: const TextStyle(
|
|
fontWeight: FontWeight.w900,
|
|
),
|
|
),
|
|
onPressed: () => Navigator.of(ctx).pop(),
|
|
child: const Text(CuriosidadeStrings.close),
|
|
),
|
|
),
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
);
|
|
},
|
|
);
|
|
},
|
|
child: Padding(
|
|
padding: const EdgeInsets.fromLTRB(16, 18, 16, 18),
|
|
child: Row(
|
|
children: [
|
|
Container(
|
|
width: 36,
|
|
height: 36,
|
|
decoration: BoxDecoration(
|
|
color: AppColors.pink.withValues(alpha: 0.12),
|
|
borderRadius: BorderRadius.circular(12),
|
|
),
|
|
child: const Icon(
|
|
Icons.lightbulb_rounded,
|
|
color: AppColors.pink,
|
|
),
|
|
),
|
|
const SizedBox(width: 12),
|
|
Expanded(
|
|
child: Text(
|
|
title,
|
|
style: const TextStyle(
|
|
fontWeight: FontWeight.w900,
|
|
color: AppColors.teal,
|
|
),
|
|
),
|
|
),
|
|
const Icon(Icons.chevron_right_rounded, color: Colors.black54),
|
|
],
|
|
),
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|