lark
lark copied to clipboard
supports to build multi-line rich text
supports to build multi-line rich text (or say multi-segment rich text in a single post) by using NewLine() method, instead of using \n in a TextTag to start a new line.
See discuss on #42
The new method and function looks good to me. But I have one question. May I ask why we should switch to [][]PostElem? I have no idea about this because it has not been updated so far.
When NewLine() is called, a new []PostElem will be append to the buf.Content which is type of [][]PostElem, and then when Render() is called, the buf.Content will be directly set to the Content field of the PostBody.
https://open.feishu.cn/document/ukTMukTMukTM/uMDMxEjLzATMx4yMwETM How to use sdk to implement this official multi-line rich text example