feat: complete centralized error handling system with documentation

This commit is contained in:
2026-02-11 10:36:08 +05:30
parent 7570ffa3b9
commit 3e212220c7
43 changed files with 1144 additions and 2858 deletions

View File

@@ -180,9 +180,16 @@ class _BillingViewState extends State<BillingView> {
}
if (state.status == BillingStatus.failure) {
WidgetsBinding.instance.addPostFrameCallback((_) {
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(content: Text(translateErrorKey(state.errorMessage!))),
);
});
return Center(
child: Text(
state.errorMessage ?? 'An error occurred',
state.errorMessage != null
? translateErrorKey(state.errorMessage!)
: 'An error occurred',
style: UiTypography.body1r.textError,
),
);