mirror of
https://github.com/BerriAI/litellm.git
synced 2026-10-04 02:31:27 +00:00
fix(ui): collapse toolsetColumns params into options object to satisfy max-params
This commit is contained in:
parent
dff009460e
commit
c233d094cf
1 changed files with 9 additions and 8 deletions
|
|
@ -289,13 +289,14 @@ function CreateToolsetModal({ open, onClose, onSave, accessToken, initialToolset
|
|||
);
|
||||
}
|
||||
|
||||
function toolsetColumns(
|
||||
t: TFunction,
|
||||
isAdmin: boolean,
|
||||
onEdit: (toolset: MCPToolset) => void,
|
||||
onDelete: (id: string) => void,
|
||||
proxyBaseUrl: string,
|
||||
): ColumnDef<MCPToolset>[] {
|
||||
function toolsetColumns(opts: {
|
||||
t: TFunction;
|
||||
isAdmin: boolean;
|
||||
onEdit: (toolset: MCPToolset) => void;
|
||||
onDelete: (id: string) => void;
|
||||
proxyBaseUrl: string;
|
||||
}): ColumnDef<MCPToolset>[] {
|
||||
const { t, isAdmin, onEdit, onDelete, proxyBaseUrl } = opts;
|
||||
return [
|
||||
{
|
||||
header: t("mcpTools.mCPToolsetsTab.colToolsetId"),
|
||||
|
|
@ -485,7 +486,7 @@ export function MCPToolsetsTab({ accessToken, userRole }: MCPToolsetsTabProps) {
|
|||
};
|
||||
|
||||
const proxyBaseUrl = getProxyBaseUrl();
|
||||
const columns = toolsetColumns(t, isAdmin, setEditToolset, setDeleteId, proxyBaseUrl);
|
||||
const columns = toolsetColumns({ t, isAdmin, onEdit: setEditToolset, onDelete: setDeleteId, proxyBaseUrl });
|
||||
|
||||
return (
|
||||
<div className="mt-4">
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue