Merge remote-tracking branch 'origin/develop' into components

# Conflicts:
#	apps/mobile_app/lib/navigation/app_router.dart
#	apps/mobile_app/pubspec.yaml
#	modules/auth/lib/src/device_sign_up/add_kid_screen.dart
#	modules/auth/lib/src/login/presentation/link_phone_screen.dart
#	modules/auth/lib/src/login/presentation/login_screen.dart
#	modules/auth/lib/src/login/presentation/phone_code_screen.dart
#	modules/auth/lib/src/onboarding/presentation/welcome_screen.dart
#	modules/auth/lib/src/recover_password/presentation/new_password_screen.dart
#	modules/auth/lib/src/sign_up/signup_screen.dart
#	modules/home/lib/src/presentation/deposit_screen.dart
#	modules/home/lib/src/presentation/home_screen.dart
#	modules/home/lib/src/presentation/wage_screen.dart
#	modules/notifications/lib/src/core/activity_list.dart
#	packages/design_system/lib/design_system.dart
This commit is contained in:
2025-12-03 16:24:04 +01:00
108 changed files with 2049 additions and 2832 deletions

View File

@@ -4,29 +4,35 @@ import 'package:home/src/presentation/wallet_management_layout.dart';
import 'package:sf_shared/sf_shared.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
class WageScreen extends ConsumerWidget {
class WageScreen extends ConsumerStatefulWidget {
final Kid kid;
WageScreen({super.key, required this.kid});
const WageScreen({super.key, required this.kid});
String frequence = "weekly";
var conditions = {
"weeklyLimits": false,
"incidences": false,
"holidays": false,
@override
ConsumerState<WageScreen> createState() => _WageScreenState();
}
class _WageScreenState extends ConsumerState<WageScreen> {
String frequence = 'weekly';
final Map<String, bool> conditions = {
'weeklyLimits': false,
'incidences': false,
'holidays': false,
};
@override
Widget build(BuildContext context, WidgetRef ref) {
Widget build(BuildContext context) {
final theme = ref.watch(themePortProvider);
return WalletManagementLayout(
kid: kid,
kid: widget.kid,
footer: Container(
padding: EdgeInsets.all(20),
padding: const EdgeInsets.all(20),
decoration: BoxDecoration(
color: theme.getColorFor(ThemeCode.backgroundPrimary),
borderRadius: BorderRadius.only(
borderRadius: const BorderRadius.only(
topLeft: Radius.circular(20),
topRight: Radius.circular(20),
),
@@ -39,7 +45,7 @@ class WageScreen extends ConsumerWidget {
text: "Activar paga automática",
color: theme.getColorFor(ThemeCode.buttonPrimary)
),
TextButton(onPressed: () => {}, child: Text("Cancelar")),
TextButton(onPressed: () {}, child: const Text('Cancelar')),
],
),
),
@@ -47,14 +53,14 @@ class WageScreen extends ConsumerWidget {
Container(
decoration: BoxDecoration(
color: theme.getColorFor(ThemeCode.backgroundPrimary),
borderRadius: BorderRadius.all(Radius.circular(20)),
borderRadius: const BorderRadius.all(Radius.circular(20)),
),
padding: EdgeInsets.all(10),
padding: const EdgeInsets.all(10),
child: Column(
spacing: 10,
children: [
Align(alignment: Alignment.topLeft,
child: Text(
child: const Text(
"Paga automática",
style: TextStyle(fontWeight: FontWeight.w500, fontSize: 20),
),
@@ -64,61 +70,62 @@ class WageScreen extends ConsumerWidget {
label: "Cantidad",
hint: "0€",
),
Text("Saldo total disponible después: 30 €"),
const Text('Saldo total disponible después: 30 €'),
],
),
),
Container(
decoration: BoxDecoration(
color: theme.getColorFor(ThemeCode.backgroundPrimary),
borderRadius: BorderRadius.all(Radius.circular(20)),
borderRadius: const BorderRadius.all(Radius.circular(20)),
),
padding: EdgeInsets.all(24),
padding: const EdgeInsets.all(24),
child: Column(
spacing: 10,
children: [
Align(alignment: Alignment.topLeft,
child: Text(
child: const Text(
"Frecuencia",
style: TextStyle(fontWeight: FontWeight.bold, fontSize: 20),
)
),
Align(alignment: Alignment.topLeft,
child: Text("Cuándo se envía el dinero"),
child: const Text("Cuándo se envía el dinero"),
),
CheckboxListTile(
contentPadding: EdgeInsets.zero,
title: Text('Semanal'),
title: const Text('Semanal'),
controlAffinity: ListTileControlAffinity.leading,
value: frequence == "weekly",
onChanged: (value) {
// setState(() {
// frequence = "weekly";
// });
value: frequence == 'weekly',
onChanged: (_) {
setState(() {
frequence = 'weekly';
});
},
activeColor: theme.getColorFor(ThemeCode.buttonPrimary),
),
CheckboxListTile(
contentPadding: EdgeInsets.zero,
title: Text('Cada dos semanas'),
title: const Text('Cada dos semanas'),
controlAffinity: ListTileControlAffinity.leading,
value: frequence == "biweekly",
onChanged: (value) {
// setState(() {
// frequence = "biweekly";
// });
value: frequence == 'biweekly',
onChanged: (_) {
setState(() {
frequence = 'biweekly';
});
},
activeColor: theme.getColorFor(ThemeCode.buttonPrimary),
),
CheckboxListTile(
contentPadding: EdgeInsets.zero,
title: Text('Mensual'),
title: const Text('Mensual'),
controlAffinity: ListTileControlAffinity.leading,
value: frequence == "monthly",
onChanged: (value) {
// setState(() {
// frequence = "monthly";
// });
value: frequence == 'monthly',
onChanged: (_) {
setState(() {
frequence = 'monthly';
});
},
activeColor: theme.getColorFor(ThemeCode.buttonPrimary),
),
@@ -150,64 +157,67 @@ class WageScreen extends ConsumerWidget {
"Escribir mensaje a ${kid.name} del motivo del ingreso",
hint: "Escribe tu mensaje",
),
Align(
const Align(
alignment: Alignment.topLeft,
child: Text("Máximo 150 caracteres"),
child: Text('Máximo 150 caracteres'),
),
],
),
),
Container(
decoration: BoxDecoration(
color: theme.getColorFor(ThemeCode.backgroundPrimary),
borderRadius: BorderRadius.all(Radius.circular(20)),
borderRadius: const BorderRadius.all(Radius.circular(20)),
),
padding: EdgeInsets.all(24),
padding: const EdgeInsets.all(24),
child: Column(
spacing: 10,
children: [
Align(alignment: Alignment.topLeft,
const Align(alignment: Alignment.topLeft,
child: Text(
"Condiciones",
style: TextStyle(fontWeight: FontWeight.bold, fontSize: 20),
),
),
Align(alignment: Alignment.topLeft,
const Align(alignment: Alignment.topLeft,
child: Text("Este dato aparecerá en el reloj del peque"),
),
CheckboxListTile(
contentPadding: EdgeInsets.zero,
title: Text('Sólo si cumple límites semanales'),
title: const Text('Sólo si cumple límites semanales'),
controlAffinity: ListTileControlAffinity.leading,
value: conditions["weeklyLimits"],
onChanged: (value) {
// setState(() {
// conditions["weeklyLimits"] = !conditions["weeklyLimits"]!;
// });
value: conditions['weeklyLimits'],
onChanged: (_) {
setState(() {
conditions['weeklyLimits'] =
!(conditions['weeklyLimits'] ?? false);
});
},
activeColor: theme.getColorFor(ThemeCode.buttonPrimary),
),
CheckboxListTile(
contentPadding: EdgeInsets.zero,
title: Text('Sólo si no ha tenido incidencias'),
title: const Text('Sólo si no ha tenido incidencias'),
controlAffinity: ListTileControlAffinity.leading,
value: conditions["incidences"],
onChanged: (value) {
// setState(() {
// conditions["incidences"] = !conditions["incidences"]!;
// });
value: conditions['incidences'],
onChanged: (_) {
setState(() {
conditions['incidences'] =
!(conditions['incidences'] ?? false);
});
},
activeColor: theme.getColorFor(ThemeCode.buttonPrimary),
),
CheckboxListTile(
contentPadding: EdgeInsets.zero,
title: Text('Pausar durante vacaciones'),
title: const Text('Pausar durante vacaciones'),
controlAffinity: ListTileControlAffinity.leading,
value: conditions["holidays"],
onChanged: (value) {
// setState(() {
// conditions["holidays"] = !conditions["holidays"]!;
// });
value: conditions['holidays'],
onChanged: (_) {
setState(() {
conditions['holidays'] = !(conditions['holidays'] ?? false);
});
},
activeColor: theme.getColorFor(ThemeCode.buttonPrimary),
),