fix: weibo 内容缺失 (#5034)

This commit is contained in:
simoin
2020-06-23 19:20:13 +08:00
committed by GitHub
parent c6e2f891e2
commit 4c8a0d843b
+2 -2
View File
@@ -4,10 +4,10 @@ const weiboUtils = {
format: (status) => {
// 长文章的处理
let temp = (status.longText && status.longText.longTextContent.replace(/\n/g, '<br>')) || status.text || '';
// 去掉外部链接的图标
temp = temp.replace(/<span class=["|']url-icon["|']>.*?网页链接<\/span>/g, '网页链接');
// 表情图标转换为文字
temp = temp.replace(/<span class="url-icon"><img.*?alt="?(.*?)"? .*?\/><\/span>/g, '$1');
// 去掉外部链接的图标
temp = temp.replace(/<span class=["|']url-icon["|']>.*?<\/span><span class="surl-text">(.*?)<\/span>/g, '$1');
// 去掉乱七八糟的图标
temp = temp.replace(/<span class=["|']url-icon["|']>(.*?)<\/span>/g, '');
// 去掉全文