Fix:Optimize metadata and optimize the empty state style of the agent page. (#12960)

### What problem does this PR solve?
Fix:Optimize metadata and optimize the empty state style of the agent
page.

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
chanx
2026-02-03 11:43:44 +08:00
committed by GitHub
parent fafaaa26c3
commit 25bb2e1616
7 changed files with 68 additions and 34 deletions

View File

@ -60,8 +60,12 @@ export function BulkOperateBar({
}}
>
<Button
variant={'ghost'}
variant={!isDeleteItem(x.id) ? 'ghost' : 'delete'}
onClick={isDeleteItem(x.id) ? () => {} : x.onClick}
className={cn({
['text-state-error border border-state-error bg-state-error/5']:
isDeleteItem(x.id),
})}
>
{x.icon} {x.label}
</Button>

View File

@ -78,8 +78,9 @@ export const EmptyAppCard = (props: {
className?: string;
isSearch?: boolean;
size?: 'small' | 'large';
children?: React.ReactNode;
}) => {
const { type, showIcon, className, isSearch } = props;
const { type, showIcon, className, isSearch, children } = props;
let defaultClass = '';
let style = {};
switch (props.size) {
@ -96,20 +97,17 @@ export const EmptyAppCard = (props: {
break;
}
return (
<div
className=" cursor-pointer "
onClick={isSearch ? undefined : props.onClick}
>
<div onClick={isSearch ? undefined : props.onClick}>
<EmptyCard
icon={showIcon ? EmptyCardData[type].icon : undefined}
title={
isSearch ? EmptyCardData[type].notFound : EmptyCardData[type].title
}
className={className}
className={cn('cursor-pointer ', className)}
style={style}
// description={EmptyCardData[type].description}
>
{!isSearch && (
{!isSearch && !children && (
<div
className={cn(
defaultClass,
@ -119,6 +117,7 @@ export const EmptyAppCard = (props: {
<Plus size={24} />
</div>
)}
{children}
</EmptyCard>
</div>
);