SheenChatBubble class

A message: text in a bubble (mine in the accent at the end, theirs muted at the start), or any child such as a SheenShareCard, with the sender's name above it in groups and reactions under it.

Reacting works the way people expect from Instagram: a double tap (onDoubleTap, usually "like with ❤️") pops a heart over the message, a small heart button beside it (onReact) and a long press (onHold) open the emoji row, which showSheenReactionBar places right above the message.

Inheritance

Constructors

SheenChatBubble({Key? key, String? text, Widget? child, bool mine = false, String? author, String? footer, Widget? reactions, VoidCallback? onHold, VoidCallback? onDoubleTap, ValueChanged<Rect>? onReact})
A message with text, or with child instead.
const

Properties

author → String?
The sender's name, shown above in group chats.
final
child → Widget?
Content other than text (a shared song); replaces the bubble.
final
A small line under the message ("Seen").
final
hashCode → int
The hash code for this object.
no setterinherited
key → Key?
Controls how one widget replaces another widget in the tree.
finalinherited
mine → bool
Whether I sent it.
final
onDoubleTap → VoidCallback?
A double tap: a quick like. A heart pops over the message.
final
onHold → VoidCallback?
A long press: open the reaction bar. Without it a long press does what the heart button does (onReact).
final
onReact → ValueChanged<Rect>?
The heart button beside the message was tapped; gets where the message is on screen (for showSheenReactionBar). Without it there is no button.
final
reactions → Widget?
Reactions under the message, usually a SheenReactions.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
text → String?
The message text.
final

Methods

createElement() → StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() → State<SheenChatBubble>
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