collection-cover

This commit is contained in:
tangly1024.com
2023-02-13 14:43:14 +08:00
parent 51aae492f4
commit c23e7e202d
2 changed files with 3 additions and 3 deletions

View File

@@ -4,7 +4,7 @@
* @param {*} value
* @returns
*/
const mapImgUrl = (img, block) => {
const mapImgUrl = (img, block, type = 'block') => {
let ret = null
if (!img) {
return ret
@@ -19,7 +19,7 @@ const mapImgUrl = (img, block) => {
// notion永久图床地址
if (!ret && img.indexOf('secure.notion-static.com') > 0) {
ret = 'https://www.notion.so/image/' + encodeURIComponent(img) + '?table=block&id=' + block.id
ret = 'https://www.notion.so/image/' + encodeURIComponent(img) + '?table=' + type + '&id=' + block.id
}
// 剩余的是第三方图片url或emoji