import FloatingGlassPanel from './FloatingGlassPanel'; import { ImageWave } from '@/components/ui/ImageWave'; import { RoleEntity } from '@/app/service/domain/Entities'; interface CharacterLibrarySelectorProps { isLoading: boolean; isReplaceLibraryOpen: boolean; setIsReplaceLibraryOpen: (open: boolean) => void; onSelect: (index: number) => void; /** 用户角色库数据 */ userRoleLibrary: RoleEntity[]; } export function CharacterLibrarySelector({ isLoading, isReplaceLibraryOpen, setIsReplaceLibraryOpen, onSelect, userRoleLibrary = [] }: CharacterLibrarySelectorProps) { if (isLoading) { return ( setIsReplaceLibraryOpen(false)} > Loading... ); } // 如果没有数据,显示空状态 if (userRoleLibrary.length === 0) { return ( setIsReplaceLibraryOpen(false)} > No character library data ); } return ( setIsReplaceLibraryOpen(false)} > {/* 内容 */} role.imageUrl)} containerWidth="90vw" containerHeight="calc(var(--index) * 15)" itemWidth="calc(var(--index) * 2)" itemHeight="calc(var(--index) * 12)" gap="0.1rem" autoAnimate={true} autoAnimateInterval={100} onClick={(index) => { onSelect(index); }} /> ); }
Loading...
No character library data