offUntil<T> method
Navigates off until a page that satisfies the given predicate is found.
This method searches for a page in the navigation stack starting from the current one and navigates backward until it finds a page that satisfies the given predicate. Once the predicate condition is met, it stops navigation and returns the result.
Implementation
Future<T?> offUntil<T>(
Widget Function() page,
bool Function(GetPage) predicate, [
Object? arguments,
String? id,
]) {
// Delegate the navigation operation to the appropriate delegate based on the provided ID
return searchDelegate(id).offUntil(
page,
predicate,
arguments,
);
}