Skip to content

SecureGate overlay not covering BottomSheet / How to close all BottomSheets when locked #61

@dducnv

Description

@dducnv

When SecureGate is locked, any active BottomSheet or Dialog still appears on top of the SecureGate blur/lock screen.
This breaks the expected security behavior because sensitive UI is still visible.

Image
  static Widget _secureGateWraper(Widget child) {
    return SecureGate(
      blurr: 60,
      opacity: 0.8,
      lockedBuilder:
          (context, controller) => LoginMasterPassword(secureApplicationController: controller),
      child: child,
    );
  }

  static Route<dynamic>? onGenerateRoute(RouteSettings settings) {
    Widget screen = _secureGateWraper(_buildScreen(settings.name ?? '', settings.arguments));

    if (Platform.isIOS) {
      return CupertinoPageRoute(builder: (context) => screen, settings: settings);
    }
    return MaterialPageRoute(builder: (context) => screen, settings: settings);
  }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions