ITADN

Accurately represent Matrix messages containing newlines in Slack

#61Pull Requestredgoat650 创建于 2024-09-30
R
redgoat650commented
Newlines don't seem to be replicated correctly in slack when sent from matrix as text. Set the `PreserveWhitespace` field in the format `Context` to preserve newlines as expected. Without this field, all `"\n"`s are stripped from the text during parsing, resulting in some odd-looking messages in slack. Before: (matrix) ![newline-matrix-before](https://github.com/user-attachments/assets/f54a68c7-4265-4eff-8259-0fc57e9849d0) (slack) ![newline-slack-before](https://github.com/user-attachments/assets/c5073a8e-a370-4809-891f-c70576afa447) After: (matrix) ![newline-matrix-after](https://github.com/user-attachments/assets/eedfd449-401e-4e36-8f1c-d189c620384d) (slack) ![newline-slack-after](https://github.com/user-attachments/assets/be41be18-9e7e-4a8d-bf8f-8a8195a23a11)
合并状态:未合并 关闭于 2024-09-30 2 条评论