WriteFeedbackScreen class

Screen widget for collecting user feedback.

This widget provides a customizable interface for users to submit feedback when they've indicated they want to provide improvement suggestions.

The screen manages the feedback submission state and handles success/failure scenarios through the provided callbacks.

Features:

  • Loading state management during feedback submission
  • Success callback handling
  • Integration with FeedbackRepository for data persistence
  • BLoC pattern for state management

Example:

WriteFeedbackScreen(
  builder: (context, isLoading, onSend) {
    return YourFeedbackForm(
      isLoading: isLoading,
      onSubmit: (feedbackData) => onSend(feedbackData),
    );
  },
  onFinalSuccessCallback: (context) async {
    // Show success message
    Navigator.pop(context);
  },
)
Inheritance

Constructors

WriteFeedbackScreen({Key? key, required WriteFeedbackPageBuilder builder, required Future<void> onFinalSuccessCallback(BuildContext context)?, required Future<void> onPopCallback(BuildContext context), String? userEmail})
Creates a WriteFeedbackScreen.
const

Properties

builder → WriteFeedbackPageBuilder
Builder function for creating the feedback collection UI.
final
hashCode → int
The hash code for this object.
no setterinherited
key → Key?
Controls how one widget replaces another widget in the tree.
finalinherited
onFinalSuccessCallback → Future<void> Function(BuildContext context)?
Callback executed when feedback is successfully submitted.
final
onPopCallback → Future<void> Function(BuildContext context)
Callback executed when navigation should go back. Used for closing the feedback screen after successful submission.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
userEmail → String?
Optional user email to be used for feedback submission.
final

Methods

createElement() → StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() → State<WriteFeedbackScreen>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() → List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) → String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String
Returns a one-line detailed description of the object.
inherited
toStringShort() → String
A short, textual description of this widget.
inherited

Operators

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