BankPaymentRequestCard class
Incoming money-request card with accept or decline actions.
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatelessWidget
- BankPaymentRequestCard
Constructors
- BankPaymentRequestCard({required String requesterId, required String requesterName, required Money amount, required DateTime requestedAt, required VoidCallback onAccept, required VoidCallback onDecline, Key? key, String? requesterAvatarUrl, String? note, EdgeInsetsGeometry? padding, BorderRadius? radius, Color? backgroundColor, double? elevation, Widget? leading, TextStyle? titleStyle, TextStyle? subtitleStyle, TextStyle? amountStyle, TextStyle? noteStyle, TextStyle? timestampStyle, String requestsLabel = 'requests', String acceptLabel = 'Accept', String declineLabel = 'Decline', Color? acceptColor, String timestampFormatter(DateTime requestedAt)?, String? semanticLabel})
-
const
Properties
- acceptColor → Color?
-
Overrides the accept button background. Defaults to BankTokens.success.
final
- acceptLabel → String
-
Label of the accept button. Defaults to
'Accept'.final - amount → Money
-
final
- amountStyle → TextStyle?
-
Merged over the amount style (BankTokens.labelLarge in warning).
final
- backgroundColor → Color?
-
Overrides the card background color. Defaults to the theme surface.
final
- declineLabel → String
-
Label of the decline button. Defaults to
'Decline'.final - elevation → double?
-
Overrides the card elevation. Defaults to the theme elevationLow.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- leading → Widget?
-
Replaces the requester avatar. Defaults to a CircleAvatar built from
requesterAvatarUrl or the requester's initial.
final
- note → String?
-
final
- noteStyle → TextStyle?
-
Merged over the note style (BankTokens.bodySmall in onSurfaceVariant).
final
- onAccept → VoidCallback
-
final
- onDecline → VoidCallback
-
final
- padding → EdgeInsetsGeometry?
-
Overrides the card content padding. Defaults to
EdgeInsets.all(BankTokens.space4).final - radius → BorderRadius?
-
Overrides the card corner radius. Defaults to the theme cardRadius.
final
- requestedAt → DateTime
-
final
- requesterAvatarUrl → String?
-
final
- requesterId → String
-
final
- requesterName → String
-
final
- requestsLabel → String
-
Connector word between the requester name and the amount.
Defaults to
'requests'.final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- semanticLabel → String?
-
When non-null, wraps the card in a Semantics label. Defaults to no
extra semantics node.
final
- subtitleStyle → TextStyle?
-
Merged over the connector text style
(BankTokens.bodyMedium in onSurfaceVariant).
final
- timestampFormatter → String Function(DateTime requestedAt)?
-
Replaces the built-in relative "time ago" formatting of requestedAt.
Defaults to the built-in English formatter.
final
- timestampStyle → TextStyle?
-
Merged over the timestamp style
(BankTokens.bodySmall in onSurfaceVariant).
final
- titleStyle → TextStyle?
-
Merged over the requester name style
(BankTokens.labelLarge in onSurface).
final
Methods
-
build(
BuildContext context) → Widget -
Describes the part of the user interface represented by this widget.
override
-
createElement(
) → StatelessElement -
Creates a StatelessElement to manage this widget's location in the tree.
inherited
-
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