fix: html/markdown formatting in chat#2446
Conversation
ac31b86 to
26aee74
Compare
26aee74 to
a604d78
Compare
|
Should this still be a draft? What needs changes to make this a final version? I would love for html messages to be fixed |
JAicewizard
left a comment
There was a problem hiding this comment.
Mostly small issues. Also don't know what the style guides are here, so best to ask krille for that
| textColor: textColor, | ||
| ); | ||
| case CuteEventContent.eventType: | ||
| case MessageTypes.Image: |
There was a problem hiding this comment.
Are these spaces/tabs correct? looks like a formatting issue
| color: activeChat | ||
| ? theme.colorScheme.onSecondaryContainer | ||
| : theme.colorScheme.onSurface, |
There was a problem hiding this comment.
Looks like this is just a random styling change, idk what the rules are in regards to adding this in PRs
| final double? width; | ||
| final double? height; | ||
| final double? aspectRatio; |
There was a problem hiding this comment.
Instead of making them nullable, you could set them in the constructor. That way you have the behavior of a default value like before, while allowing the arguments to be null
| if (aspectRatio != null) { | ||
| placeholder = AspectRatio(aspectRatio: aspectRatio!, child: placeholder); | ||
| } |
There was a problem hiding this comment.
The placeholder is already wrapped in an AspectRatio indirectly in build. Is this necessary?
| if (aspectRatio != null) { | ||
| image = AspectRatio(aspectRatio: aspectRatio!, child: image); | ||
| } |
There was a problem hiding this comment.
Why do we need this? The MxcImage should always already be the correct aspect ratio right?
| width: width, | ||
| height: height, |
There was a problem hiding this comment.
Probably forgot the default width/height here
Edit: still need to make some more fixes, dont merge this
This is essentially 2 in 1 as the linux build wasn't working (maybe just my system?).
I'll be doing a local build with the last fixes I've done over the week just to ensure its all working right together.
The markdown/html rendering in the chat was making a minced mess of formatting, fonts and icons. So I've updated to something more robust.
Fixed:
Upgraded:
flutter_secure_storageto v10.0.0.matrixSDK to v4.1.0 and other dependencies.Thank you so much for your contribution to FluffyChat ❤️❤️❤️
Pull Request has been tested on: