feat(ui): add emoji picker with FlatList virtualization and improve input components
- Add full emoji picker with virtualized FlatList to CreatePostScreen and PostDetailScreen - Add autoExpand prop to PostMentionInput for XHS-style content area - Improve mention item styling with @ icon and hint text - Fix HomeScreen tab switching race condition with requestAnimationFrame - Fix PostRepository pagination to prefer cursor over page parameter - Fix user store imports to use explicit UserManager path - Refactor useCurrentUser hook to use sessionStore directly
This commit is contained in:
@@ -241,11 +241,12 @@ export class PostRepository implements IPostRepository {
|
||||
try {
|
||||
const queryParams: Record<string, any> = {};
|
||||
|
||||
if (params?.page !== undefined) queryParams.page = params.page;
|
||||
if (params?.pageSize) queryParams.page_size = params.pageSize;
|
||||
// 支持 cursor 参数:空字符串也传递,用于启动 cursor 模式
|
||||
// cursor 与 page 互斥:cursor 存在(含空字符串)时走游标分页,否则走页码分页
|
||||
if (params?.cursor !== undefined && params?.cursor !== null) {
|
||||
queryParams.cursor = params.cursor;
|
||||
} else if (params?.page !== undefined) {
|
||||
queryParams.page = params.page;
|
||||
}
|
||||
if (params?.post_type) queryParams.tab = params.post_type;
|
||||
if (params?.channelId) queryParams.channel_id = params.channelId;
|
||||
|
||||
Reference in New Issue
Block a user