1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 11:42:56 +08:00

Merge pull request #19746 from bastianpedersen/beatmap-comments-image-not-visible

Make `CommentMarkdownTextFlowContainer` render images
This commit is contained in:
Dean Herbert 2022-08-15 00:02:03 +09:00 committed by GitHub
commit 0d3cda3329
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,7 +4,6 @@
#nullable disable
using Markdig.Syntax;
using Markdig.Syntax.Inlines;
using osu.Framework.Graphics.Containers.Markdown;
using osu.Game.Graphics.Containers.Markdown;
@ -12,16 +11,8 @@ namespace osu.Game.Overlays.Comments
{
public class CommentMarkdownContainer : OsuMarkdownContainer
{
public override MarkdownTextFlowContainer CreateTextFlow() => new CommentMarkdownTextFlowContainer();
protected override MarkdownHeading CreateHeading(HeadingBlock headingBlock) => new CommentMarkdownHeading(headingBlock);
private class CommentMarkdownTextFlowContainer : OsuMarkdownTextFlowContainer
{
// Don't render image in comment for now
protected override void AddImage(LinkInline linkInline) { }
}
private class CommentMarkdownHeading : OsuMarkdownHeading
{
public CommentMarkdownHeading(HeadingBlock headingBlock)