diff --git a/src/background/messageListeners/user.ts b/src/background/messageListeners/user.ts
index 64a31bf9..42ef5f13 100644
--- a/src/background/messageListeners/user.ts
+++ b/src/background/messageListeners/user.ts
@@ -1,5 +1,6 @@
import type { APIMAP } from '../utils'
import { AHS } from '../utils'
+import API from '../msg.define'
const API_USER: APIMAP = {
// https://github.com/SocialSisterYi/bilibili-API-collect/blob/e379d904c2753fa30e9083f59016f07e89d19467/docs/login/login_info.md#%E5%AF%BC%E8%88%AA%E6%A0%8F%E7%94%A8%E6%88%B7%E4%BF%A1%E6%81%AF
@@ -17,6 +18,21 @@ const API_USER: APIMAP = {
},
afterHandle: AHS.J_D,
},
+ // https://github.com/SocialSisterYi/bilibili-API-collect/blob/ed9ac01b6769430aa3f12ad02c2ed337a96924eb/docs/user/relation.md#操作用户关系
+ [API.USER.RELATION_MODIFY]: {
+ url: 'https://api.bilibili.com/x/relation/modify',
+ _fetch: {
+ method: 'post',
+ },
+ params: {
+ // access_key: '', // app only
+ fid: '',
+ act: 1,
+ re_src: 11,
+ },
+ afterHandle: AHS.J_D,
+ },
+
}
export default API_USER
diff --git a/src/background/msg.define.ts b/src/background/msg.define.ts
index 29b3e7ae..318fbd94 100644
--- a/src/background/msg.define.ts
+++ b/src/background/msg.define.ts
@@ -47,6 +47,7 @@ enum SEARCH {
enum USER {
GET_USER_INFO = 'getUserInfo',
GET_USER_STAT = 'getUserStat',
+ RELATION_MODIFY = 'relationModify',
}
enum VIDEO {
GET_RECOMMEND_VIDEOS = 'getRecommendVideos',
diff --git a/src/components/VideoCard/VideoCard.vue b/src/components/VideoCard/VideoCard.vue
index 5ee96bb1..c3d2e2fc 100644
--- a/src/components/VideoCard/VideoCard.vue
+++ b/src/components/VideoCard/VideoCard.vue
@@ -29,7 +29,7 @@ interface Props {
/** If you want to show preview video, you should set the cid value */
cid?: number
epid?: number
- isFollowed?: boolean
+ followed?: boolean
horizontal?: boolean
tag?: string
rank?: number
@@ -326,16 +326,28 @@ function handleUndo() {
+