Skip to content

Commit 45fb737

Browse files
committed
fix lint, clean up ask-fern loader
1 parent 4567636 commit 45fb737

File tree

4 files changed

+13
-63
lines changed

4 files changed

+13
-63
lines changed
Lines changed: 1 addition & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -1,63 +1,5 @@
11
import { Skeleton } from "@/components/ui/skeleton";
2-
import { cn } from "@/utils/utils";
3-
4-
const BORDER_STYLES = "mb-4 flex w-full flex-col items-center rounded-2xl p-4";
52

63
export default function Loading() {
7-
return (
8-
<div className="flex min-w-0 flex-1 flex-col items-center transition-[flex] duration-500 ease-out">
9-
{/* Page Header Skeleton */}
10-
<div className="mb-4 flex w-full max-w-[1200px] items-center justify-between">
11-
<Skeleton className="h-8 w-32" />
12-
</div>
13-
14-
{/* Main Content Card Skeleton */}
15-
<div className={cn(BORDER_STYLES, "border-gray-0 w-full max-w-[1200px] border")}>
16-
{/* Time Range Selector Skeleton */}
17-
<div className="mb-6 flex w-full items-center justify-between">
18-
<Skeleton className="h-7 w-32" />
19-
<Skeleton className="h-9 w-32" />
20-
</div>
21-
22-
{/* Metrics Cards Skeleton */}
23-
<div className="mb-6 flex w-full gap-6">
24-
{Array.from({ length: 4 }).map((_, i) => (
25-
<div key={i} className="flex flex-1 flex-col items-start">
26-
<Skeleton className="mb-1 h-5 w-20" />
27-
<Skeleton className="h-7 w-16" />
28-
</div>
29-
))}
30-
</div>
31-
32-
{/* Histogram Chart Skeleton */}
33-
<div className="mb-6 w-full overflow-x-auto">
34-
<div className="flex h-[200px] items-end gap-2">
35-
{Array.from({ length: 20 }).map((_, i) => (
36-
<Skeleton
37-
key={i}
38-
className="flex-1"
39-
style={{ height: `${Math.random() * 100 + 50}px` }}
40-
/>
41-
))}
42-
</div>
43-
</div>
44-
45-
{/* Search Bar and Pagination Skeleton */}
46-
<div className="mb-4 flex flex-wrap items-center justify-between gap-2">
47-
<Skeleton className="h-9 w-64" />
48-
<Skeleton className="h-9 w-32" />
49-
</div>
50-
51-
{/* Table Skeleton */}
52-
<div className="flex flex-col gap-2">
53-
{/* Table Header */}
54-
<Skeleton className="h-10 w-full" />
55-
{/* Table Rows */}
56-
{Array.from({ length: 8 }).map((_, i) => (
57-
<Skeleton key={i} className="h-12 w-full" />
58-
))}
59-
</div>
60-
</div>
61-
</div>
62-
);
4+
return <Skeleton className="h-full w-full" />;
635
}

packages/fern-dashboard/src/app/[orgName]/(homepage)/docs/[docsUrl]/search/loading.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,10 @@ function SearchTableSkeleton({ title }: { title: string }) {
3737
</div>
3838
<div className="flex flex-col">
3939
{[...Array(10)].map((_, i) => (
40-
<div key={i} className="border-border flex items-center justify-between border-b px-4 py-3 last:border-b-0">
40+
<div
41+
key={i}
42+
className="border-border flex items-center justify-between border-b px-4 py-3 last:border-b-0"
43+
>
4144
<Skeleton className="h-4 w-48" />
4245
<Skeleton className="h-4 w-16" />
4346
</div>

packages/fern-dashboard/src/app/[orgName]/(homepage)/docs/[docsUrl]/web-analytics/loading.tsx

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,13 +72,18 @@ export default function Loading() {
7272

7373
function TableSkeleton({ title, fullWidth = false }: { title: string; fullWidth?: boolean }) {
7474
return (
75-
<div className={`border-border flex flex-col rounded-lg border bg-white dark:bg-transparent ${fullWidth ? "w-full" : "flex-1"}`}>
75+
<div
76+
className={`border-border flex flex-col rounded-lg border bg-white dark:bg-transparent ${fullWidth ? "w-full" : "flex-1"}`}
77+
>
7678
<div className="border-border flex items-center justify-between border-b px-4 py-3">
7779
<Skeleton className="h-5 w-32">{title}</Skeleton>
7880
</div>
7981
<div className="flex flex-col">
8082
{[...Array(5)].map((_, i) => (
81-
<div key={i} className="border-border flex items-center justify-between border-b px-4 py-3 last:border-b-0">
83+
<div
84+
key={i}
85+
className="border-border flex items-center justify-between border-b px-4 py-3 last:border-b-0"
86+
>
8287
<Skeleton className="h-4 w-40" />
8388
<div className="flex gap-8">
8489
<Skeleton className="h-4 w-16" />

packages/fern-dashboard/src/components/analytics/AnalyticsPageClient.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ export function AnalyticsPageClient({
173173
<div className={ANALYTICS_PAGE_STYLES}>
174174
<AnalyticsPageHeader analyticsBillingEnabled={analyticsBillingEnabled} />
175175
{isLoading ? (
176-
<div className={cn(BORDER_STYLES, "border-gray-0 w-full max-w-[1200px] border")}>
176+
<div className={cn(BORDER_STYLES, "border-border w-full max-w-[1200px] border")}>
177177
<div className="mb-6 flex w-full items-center justify-between">
178178
<Skeleton className="h-7 w-32" />
179179
<Skeleton className="h-9 w-32" />

0 commit comments

Comments
 (0)