mirror of
https://github.com/simstudioai/sim.git
synced 2026-04-06 03:00:16 -04:00
improvement(settings): add search bar to skeleton loading states
Skeletons now include the search bar (and action button where applicable) so the layout matches the final component 1:1. Eliminates layout shift when the dynamic chunk loads — search bar area is already reserved by the skeleton.
This commit is contained in:
@@ -23,9 +23,15 @@ export function ApiKeySkeleton() {
|
||||
*/
|
||||
export function ApiKeysSkeleton() {
|
||||
return (
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<ApiKeySkeleton />
|
||||
<ApiKeySkeleton />
|
||||
<div className='flex h-full flex-col gap-[18px]'>
|
||||
<div className='flex items-center gap-[8px]'>
|
||||
<Skeleton className='h-[30px] flex-1 rounded-[8px]' />
|
||||
<Skeleton className='h-[30px] w-[80px] rounded-[6px]' />
|
||||
</div>
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<ApiKeySkeleton />
|
||||
<ApiKeySkeleton />
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -23,10 +23,16 @@ export function BYOKKeySkeleton() {
|
||||
*/
|
||||
export function BYOKSkeleton() {
|
||||
return (
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<BYOKKeySkeleton />
|
||||
<BYOKKeySkeleton />
|
||||
<BYOKKeySkeleton />
|
||||
<div className='flex h-full flex-col gap-[18px]'>
|
||||
<div className='flex items-center gap-[8px]'>
|
||||
<Skeleton className='h-[30px] flex-1 rounded-[8px]' />
|
||||
</div>
|
||||
<Skeleton className='h-[14px] w-[280px]' />
|
||||
<div className='flex flex-col gap-[8px]'>
|
||||
<BYOKKeySkeleton />
|
||||
<BYOKKeySkeleton />
|
||||
<BYOKKeySkeleton />
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -6,6 +6,10 @@ import { Skeleton } from '@/components/emcn'
|
||||
export function CredentialSetsSkeleton() {
|
||||
return (
|
||||
<div className='flex h-full flex-col gap-[18px]'>
|
||||
<div className='flex items-center gap-[8px]'>
|
||||
<Skeleton className='h-[30px] flex-1 rounded-[8px]' />
|
||||
<Skeleton className='h-[30px] w-[80px] rounded-[6px]' />
|
||||
</div>
|
||||
<div className='flex flex-col gap-[8px]'>
|
||||
<Skeleton className='h-[14px] w-[100px]' />
|
||||
<div className='flex items-center justify-between'>
|
||||
|
||||
@@ -23,10 +23,16 @@ export function CredentialSkeleton() {
|
||||
*/
|
||||
export function CredentialsSkeleton() {
|
||||
return (
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<CredentialSkeleton />
|
||||
<CredentialSkeleton />
|
||||
<CredentialSkeleton />
|
||||
<div className='flex h-full flex-col gap-[18px]'>
|
||||
<div className='flex items-center gap-[8px]'>
|
||||
<Skeleton className='h-[30px] flex-1 rounded-[8px]' />
|
||||
<Skeleton className='h-[30px] w-[64px] rounded-[6px]' />
|
||||
</div>
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<CredentialSkeleton />
|
||||
<CredentialSkeleton />
|
||||
<CredentialSkeleton />
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -23,10 +23,16 @@ export function CustomToolSkeleton() {
|
||||
*/
|
||||
export function CustomToolsSkeleton() {
|
||||
return (
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<CustomToolSkeleton />
|
||||
<CustomToolSkeleton />
|
||||
<CustomToolSkeleton />
|
||||
<div className='flex h-full flex-col gap-[18px]'>
|
||||
<div className='flex items-center gap-[8px]'>
|
||||
<Skeleton className='h-[30px] flex-1 rounded-[8px]' />
|
||||
<Skeleton className='h-[30px] w-[64px] rounded-[6px]' />
|
||||
</div>
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<CustomToolSkeleton />
|
||||
<CustomToolSkeleton />
|
||||
<CustomToolSkeleton />
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Skeleton } from '@/components/ui'
|
||||
import { Skeleton } from '@/components/emcn'
|
||||
|
||||
/**
|
||||
* Skeleton loader for MCP server list items.
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import { Skeleton } from '@/components/emcn'
|
||||
import { McpServerSkeleton } from '@/app/workspace/[workspaceId]/settings/components/mcp/components/mcp-server-skeleton/mcp-server-skeleton'
|
||||
|
||||
/**
|
||||
@@ -5,10 +6,16 @@ import { McpServerSkeleton } from '@/app/workspace/[workspaceId]/settings/compon
|
||||
*/
|
||||
export function McpSkeleton() {
|
||||
return (
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<McpServerSkeleton />
|
||||
<McpServerSkeleton />
|
||||
<McpServerSkeleton />
|
||||
<div className='flex h-full flex-col gap-[18px]'>
|
||||
<div className='flex items-center gap-[8px]'>
|
||||
<Skeleton className='h-[30px] flex-1 rounded-[8px]' />
|
||||
<Skeleton className='h-[30px] w-[64px] rounded-[6px]' />
|
||||
</div>
|
||||
<div className='flex flex-col gap-[12px]'>
|
||||
<McpServerSkeleton />
|
||||
<McpServerSkeleton />
|
||||
<McpServerSkeleton />
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user