fix: 正确处理“我追的合集 / 收藏夹”中的收藏夹条目,以及一些样式、文本调整 (#553)
This commit is contained in:
@@ -1,5 +1,16 @@
|
||||
import { clsx, type ClassValue } from 'clsx';
|
||||
import { twMerge } from 'tailwind-merge';
|
||||
import type { Followed } from './types';
|
||||
|
||||
export function getFollowedKey(followed: Followed): number {
|
||||
if (followed.type == 'favorite') {
|
||||
return followed.fid;
|
||||
} else if (followed.type == 'collection') {
|
||||
return followed.sid;
|
||||
} else {
|
||||
return followed.mid;
|
||||
}
|
||||
}
|
||||
|
||||
export function cn(...inputs: ClassValue[]) {
|
||||
return twMerge(clsx(inputs));
|
||||
|
||||
Reference in New Issue
Block a user