Fix invitation wrapping
continuous-integration/drone/pr Build is passing
Details
continuous-integration/drone/pr Build is passing
Details
This commit is contained in:
parent
22eb994c52
commit
f3d713cfcc
|
@ -63,15 +63,15 @@ class InvitationBubbleState extends State<InvitationBubble> {
|
||||||
if (fromMe) {
|
if (fromMe) {
|
||||||
wdgDecorations = MessageBubbleDecoration(ackd: Provider.of<MessageState>(context).ackd, errored: Provider.of<MessageState>(context).error, fromMe: fromMe, prettyDate: prettyDate);
|
wdgDecorations = MessageBubbleDecoration(ackd: Provider.of<MessageState>(context).ackd, errored: Provider.of<MessageState>(context).error, fromMe: fromMe, prettyDate: prettyDate);
|
||||||
} else if (isAccepted) {
|
} else if (isAccepted) {
|
||||||
wdgDecorations = Text("Accepted!");
|
wdgDecorations = Text("Accepted!" + '\u202F');
|
||||||
} else if (this.rejected) {
|
} else if (this.rejected) {
|
||||||
wdgDecorations = Text("Rejected.");
|
wdgDecorations = Text("Rejected." + '\u202F');
|
||||||
} else {
|
} else {
|
||||||
wdgDecorations = Center(
|
wdgDecorations = Center(
|
||||||
widthFactor: 1,
|
widthFactor: 1,
|
||||||
child: Row(children: [
|
child: Wrap(children: [
|
||||||
Padding(padding: EdgeInsets.all(5), child: TextButton(child: Text("Reject"), onPressed: _btnReject)),
|
Padding(padding: EdgeInsets.all(5), child: TextButton(child: Text("Reject" + '\u202F'), onPressed: _btnReject)),
|
||||||
Padding(padding: EdgeInsets.all(5), child: TextButton(child: Text("Accept"), onPressed: _btnAccept)),
|
Padding(padding: EdgeInsets.all(5), child: TextButton(child: Text("Accept" + '\u202F'), onPressed: _btnAccept)),
|
||||||
]));
|
]));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -95,8 +95,8 @@ class InvitationBubbleState extends State<InvitationBubble> {
|
||||||
widthFactor: 1.0,
|
widthFactor: 1.0,
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: EdgeInsets.all(9.0),
|
padding: EdgeInsets.all(9.0),
|
||||||
child: Row(mainAxisSize: MainAxisSize.min, children: [
|
child: Wrap(runAlignment: WrapAlignment.spaceEvenly, alignment: WrapAlignment.spaceEvenly, runSpacing: 1.0, crossAxisAlignment: WrapCrossAlignment.center, children: [
|
||||||
Center(widthFactor: 1, child: Padding(padding: EdgeInsets.all(4), child: Icon(CwtchIcons.send_invite, size: 32))),
|
Center(widthFactor: 1, child: Padding(padding: EdgeInsets.all(10.0), child: Icon(CwtchIcons.send_invite, size: 32))),
|
||||||
Center(
|
Center(
|
||||||
widthFactor: 1.0,
|
widthFactor: 1.0,
|
||||||
child: Column(
|
child: Column(
|
||||||
|
@ -129,53 +129,49 @@ class InvitationBubbleState extends State<InvitationBubble> {
|
||||||
|
|
||||||
// Construct an invite chrome for the sender
|
// Construct an invite chrome for the sender
|
||||||
Widget senderInviteChrome(String chrome, String targetName, String myKey) {
|
Widget senderInviteChrome(String chrome, String targetName, String myKey) {
|
||||||
return Center(
|
return Wrap(children: [
|
||||||
widthFactor: 1,
|
SelectableText(
|
||||||
child: Row(children: [
|
chrome + '\u202F',
|
||||||
SelectableText(
|
style: TextStyle(
|
||||||
chrome,
|
color: Provider.of<Settings>(context).theme.messageFromMeTextColor(),
|
||||||
focusNode: _focus,
|
),
|
||||||
style: TextStyle(
|
textAlign: TextAlign.left,
|
||||||
color: Provider.of<Settings>(context).theme.messageFromMeTextColor(),
|
maxLines: 2,
|
||||||
),
|
textWidthBasis: TextWidthBasis.longestLine,
|
||||||
textAlign: TextAlign.left,
|
),
|
||||||
textWidthBasis: TextWidthBasis.longestLine,
|
SelectableText(
|
||||||
),
|
targetName + '\u202F',
|
||||||
SelectableText(
|
key: Key(myKey),
|
||||||
targetName + '\u202F',
|
style: TextStyle(
|
||||||
key: Key(myKey),
|
color: Provider.of<Settings>(context).theme.messageFromMeTextColor(),
|
||||||
focusNode: _focus,
|
),
|
||||||
style: TextStyle(
|
textAlign: TextAlign.left,
|
||||||
color: Provider.of<Settings>(context).theme.messageFromMeTextColor(),
|
maxLines: 2,
|
||||||
),
|
textWidthBasis: TextWidthBasis.longestLine,
|
||||||
textAlign: TextAlign.left,
|
)
|
||||||
textWidthBasis: TextWidthBasis.longestLine,
|
]);
|
||||||
)
|
|
||||||
]));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Construct an invite chrome
|
// Construct an invite chrome
|
||||||
Widget inviteChrome(String chrome, String targetName, String targetId, String myKey) {
|
Widget inviteChrome(String chrome, String targetName, String targetId, String myKey) {
|
||||||
return Center(
|
return Wrap(children: [
|
||||||
widthFactor: 1,
|
SelectableText(
|
||||||
child: Row(children: [
|
chrome + '\u202F',
|
||||||
SelectableText(
|
style: TextStyle(
|
||||||
chrome,
|
color: Provider.of<Settings>(context).theme.messageFromOtherTextColor(),
|
||||||
focusNode: _focus,
|
),
|
||||||
style: TextStyle(
|
textAlign: TextAlign.left,
|
||||||
color: Provider.of<Settings>(context).theme.messageFromOtherTextColor(),
|
textWidthBasis: TextWidthBasis.longestLine,
|
||||||
),
|
maxLines: 2,
|
||||||
textAlign: TextAlign.left,
|
),
|
||||||
textWidthBasis: TextWidthBasis.longestLine,
|
SelectableText(
|
||||||
),
|
targetName + '\u202F',
|
||||||
SelectableText(
|
key: Key(myKey),
|
||||||
targetName,
|
style: TextStyle(color: Provider.of<Settings>(context).theme.messageFromOtherTextColor()),
|
||||||
key: Key(myKey),
|
textAlign: TextAlign.left,
|
||||||
focusNode: _focus,
|
maxLines: 2,
|
||||||
style: TextStyle(color: Provider.of<Settings>(context).theme.messageFromOtherTextColor()),
|
textWidthBasis: TextWidthBasis.longestLine,
|
||||||
textAlign: TextAlign.left,
|
)
|
||||||
textWidthBasis: TextWidthBasis.longestLine,
|
]);
|
||||||
)
|
|
||||||
]));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue