refactor: migrate to go_router navigation

This commit is contained in:
cogwheel0
2025-09-22 14:36:43 +05:30
parent 462bf4cde2
commit 66a28958ed
11 changed files with 468 additions and 410 deletions

View File

@@ -4,6 +4,7 @@ import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_animate/flutter_animate.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:go_router/go_router.dart';
import '../../../core/models/server_config.dart';
import '../../../core/providers/app_providers.dart';
@@ -136,10 +137,7 @@ class _AuthenticationPageState extends ConsumerState<AuthenticationPage> {
DebugLogger.auth('Navigating to chat page');
// Navigate directly to chat page on successful authentication
Navigator.of(context).pushNamedAndRemoveUntil(
Routes.chat,
(route) => false, // Remove all previous routes
);
context.go(Routes.chat);
}
});