DialogService class

Service for managing dialogs, bottom sheets, and overlays

Inheritance

Constructors

DialogService.new({bool enableDebugMode = kDebugMode})

Properties

enableDebugMode bool
finalinherited
hashCode int
The hash code for this object.
no setterinherited
isInitialized bool
Gets whether this service has been initialized
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

dispose() Future<void>
Disposes of the service and cleans up resources
inherited
hideLoading() → void
Hides the loading dialog
initialize(Map<String, dynamic> config) Future<void>
Initializes the service with the provided configuration
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onDispose() Future<void>
Override this method to implement service-specific cleanup
override
onInitialize(Map<String, dynamic> config) Future<void>
Override this method to implement service-specific initialization
override
removeAllOverlays() → void
Removes all overlays
removeOverlay() → void
Removes an overlay
show<T>({required Widget content, String? title, List<DialogAction>? actions, bool barrierDismissible = true, DialogType type = DialogType.normal}) Future<T?>
Shows a dialog with custom content
showAlert({required String message, String? title, String confirmText = 'OK'}) Future<void>
Shows a simple alert dialog
showBottomSheet<T>({required Widget content, bool isDismissible = true, bool enableDrag = true, double? height, Color? backgroundColor, ShapeBorder? shape}) Future<T?>
Shows a bottom sheet
showConfirm({required String message, String? title, String confirmText = 'Confirm', String cancelText = 'Cancel'}) Future<bool>
Shows a confirmation dialog
showInput({String? title, String? hint, String? initialValue, String confirmText = 'OK', String cancelText = 'Cancel', TextInputType keyboardType = TextInputType.text, int? maxLines = 1}) Future<String?>
Shows an input dialog
showLoading({String? message, bool barrierDismissible = false}) → void
Shows a loading dialog
showOverlay({required WidgetBuilder builder, bool opaque = false, bool maintainState = false}) → void
Shows a custom overlay
showSnackbar({required String message, SnackbarType type = SnackbarType.info, Duration duration = const Duration(seconds: 4), SnackBarAction? action}) → void
Shows a snackbar
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

no setter