diff options
Diffstat (limited to 'ui/commands.go')
-rw-r--r-- | ui/commands.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/commands.go b/ui/commands.go index 0feda29..50aedd2 100644 --- a/ui/commands.go +++ b/ui/commands.go @@ -20,6 +20,7 @@ import ( "encoding/json" "fmt" "maunium.net/go/mautrix" + "maunium.net/go/mautrix/format" "strings" "unicode" @@ -79,7 +80,7 @@ func cmdRainbow(cmd *Command) { color := rainbow.GetInterpolatedColorFor(float64(i) / float64(len(text))).Hex() fmt.Fprintf(&html, "<font color=\"%s\">%c</font>", color, char) } - tempMessage := cmd.Room.NewTempMessage("m.text", html.String()) + tempMessage := cmd.Room.NewTempMessage("m.text", format.HTMLToText(html.String())) go cmd.MainView.sendTempMessage(cmd.Room, tempMessage, html.String()) cmd.UI.Render() } |