fix: 适配手机端搜索入口与底部 Sheet 面板

顶栏改为可伸展搜索 pill,面板改为自底部滑出并优化筛选条与触控布局。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-27 23:39:32 +08:00
parent 55b1831da2
commit f559fc4c4b
3 changed files with 211 additions and 9 deletions

View File

@@ -147,11 +147,14 @@ export default function PostSearchPanel({
)}
onOpenAutoFocus={(e) => e.preventDefault()}
>
{isMobile && <div className="post-search-panel__handle" aria-hidden />}
<DialogHeader className="post-search-panel__header">
<DialogTitle></DialogTitle>
<DialogDescription className="post-search-panel__desc">
</DialogDescription>
{!isMobile && (
<DialogDescription className="post-search-panel__desc">
</DialogDescription>
)}
</DialogHeader>
<div className="post-search-panel__body">
@@ -282,10 +285,11 @@ export default function PostSearchPanel({
)}
</div>
<div className="post-search-panel__footer">
<div className={cn('post-search-panel__footer', isMobile && 'post-search-panel__footer--mobile')}>
<Button
type="button"
variant="outline"
className={isMobile ? 'post-search-panel__btn' : undefined}
onClick={() => {
setKeyword('');
setAuthor('');
@@ -296,7 +300,7 @@ export default function PostSearchPanel({
>
</Button>
<Button type="button" onClick={handleSubmit}>
<Button type="button" className={isMobile ? 'post-search-panel__btn' : undefined} onClick={handleSubmit}>
</Button>
</div>