Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,14 @@ Widget buildMessageComposerAttachmentReplyPlayground(BuildContext context) {
child: MessageComposerReplyAttachment(
title: const Text('Reply to John Doe'),
subtitle: const Text('We had a great time during our holiday.'),
image: const AssetImage('assets/attachment_image.png'),
trailing: Container(
width: 40,
height: 40,
decoration: BoxDecoration(
borderRadius: BorderRadius.all(context.streamRadius.md),
image: const DecorationImage(image: AssetImage('assets/attachment_image.png'), fit: BoxFit.cover),
),
),
onRemovePressed: () {},
style: style,
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ class MessageComposerReplyAttachment extends StatelessWidget {
super.key,
required this.title,
required this.subtitle,
this.image,
this.trailing,
this.onRemovePressed,
this.style = ReplyStyle.incoming,
});

final Widget title;
final Widget subtitle;
final ImageProvider? image;
final Widget? trailing;
final VoidCallback? onRemovePressed;
final ReplyStyle style;

Expand Down Expand Up @@ -61,16 +61,7 @@ class MessageComposerReplyAttachment extends StatelessWidget {
],
),
),
if (image != null) ...[
Container(
width: 40,
height: 40,
decoration: BoxDecoration(
borderRadius: BorderRadius.all(context.streamRadius.md),
image: DecorationImage(image: image!, fit: BoxFit.cover),
),
),
],
?trailing,
],
),
);
Expand Down
Loading