File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -477,7 +477,7 @@ function PureBlock({
477
477
} ) }
478
478
>
479
479
{ isDocumentsFetching && ! block . content ? (
480
- < DocumentSkeleton />
480
+ < DocumentSkeleton blockKind = { block . kind } />
481
481
) : block . kind === 'code' ? (
482
482
< CodeEditor
483
483
content = {
Original file line number Diff line number Diff line change 1
1
'use client' ;
2
2
3
- export const DocumentSkeleton = ( ) => {
4
- return (
3
+ import { BlockKind } from './block' ;
4
+
5
+ export const DocumentSkeleton = ( { blockKind } : { blockKind : BlockKind } ) => {
6
+ return blockKind === 'image' ? (
7
+ < div className = "flex flex-col gap-4 w-full justify-center items-center h-[calc(100dvh-60px)]" >
8
+ < div className = "animate-pulse rounded-lg bg-muted-foreground/20 size-96" />
9
+ </ div >
10
+ ) : (
5
11
< div className = "flex flex-col gap-4 w-full" >
6
12
< div className = "animate-pulse rounded-lg h-12 bg-muted-foreground/20 w-1/2" />
7
13
< div className = "animate-pulse rounded-lg h-5 bg-muted-foreground/20 w-full" />
You can’t perform that action at this time.
0 commit comments