refactor(frontend): EmptyState + LoadingSkeleton primitives; unified ThoughtForm replaces PostThoughtForm and ReplyForm

This commit is contained in:
2026-05-15 20:01:00 +02:00
parent dadfe04934
commit d450a1d8d8
10 changed files with 203 additions and 253 deletions

View File

@@ -16,6 +16,7 @@ export async function generateMetadata({
: "Search for people and thoughts on Thoughts",
};
}
import { EmptyState } from "@/components/empty-state";
import { UserListCard } from "@/components/user-list-card";
import { RemoteUserCard } from "@/components/remote-user-card";
import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs";
@@ -67,9 +68,7 @@ export default async function SearchPage({ searchParams }: SearchPageProps) {
<RemoteUserCard actor={remoteActor} />
</div>
) : (
<p className="text-center text-muted-foreground pt-8">
No user found at {query}
</p>
<EmptyState message={`No user found at ${query}`} />
)
) : results ? (
<Tabs defaultValue="thoughts" className="w-full">
@@ -92,9 +91,7 @@ export default async function SearchPage({ searchParams }: SearchPageProps) {
</TabsContent>
</Tabs>
) : (
<p className="text-center text-muted-foreground pt-8">
No results found or an error occurred.
</p>
<EmptyState message="No results found or an error occurred." />
)}
</main>
</div>