refactor: The PageScrollList component supports two generic parameters

This commit is contained in:
zhaoying
2026-01-29 15:57:52 +08:00
parent 9c3e0b5541
commit 4fe32b7dbc
4 changed files with 31 additions and 29 deletions

View File

@@ -58,13 +58,12 @@ const ApiKeyManagement: React.FC = () => {
</Button>
</div>
<PageScrollList
<PageScrollList<ApiKey, { is_active: boolean; type: string }>
ref={scrollListRef}
url={getApiKeyListUrl}
query={{ is_active: true, type: 'service' }}
column={2}
renderItem={(item: Record<string, unknown>) => {
let apiKeyItem = item as unknown as ApiKey
renderItem={(apiKeyItem) => {
return (
<RbCard
title={apiKeyItem.name}