diff --git a/litellm/proxy/_experimental/out/assets/audit-logs-preview.png.png b/litellm/proxy/_experimental/out/assets/audit-logs-preview.png.png new file mode 100644 index 0000000000..4e97c291d2 Binary files /dev/null and b/litellm/proxy/_experimental/out/assets/audit-logs-preview.png.png differ diff --git a/litellm/proxy/_experimental/out/audit-logs-preview.png b/litellm/proxy/_experimental/out/audit-logs-preview.png deleted file mode 100644 index ce55441842..0000000000 Binary files a/litellm/proxy/_experimental/out/audit-logs-preview.png and /dev/null differ diff --git a/litellm/proxy/common_utils/html_forms/ui_login.py b/litellm/proxy/common_utils/html_forms/ui_login.py index a3b839bbf2..5b95b280f2 100644 --- a/litellm/proxy/common_utils/html_forms/ui_login.py +++ b/litellm/proxy/common_utils/html_forms/ui_login.py @@ -129,8 +129,19 @@ html_form = f""" margin-bottom: 20px; }} - .toggle-password input {{ - margin-right: 6px; + .toggle-password input[type="checkbox"] {{ + margin-right: 8px; + margin-bottom: 0; + vertical-align: middle; + width: 16px; + height: 16px; + }} + + .toggle-password label {{ + margin-bottom: 0; + font-size: 14px; + cursor: pointer; + line-height: 1; }} input[type="submit"] {{ diff --git a/ui/litellm-dashboard/out/assets/audit-logs-preview.png.png b/ui/litellm-dashboard/out/assets/audit-logs-preview.png.png new file mode 100644 index 0000000000..4e97c291d2 Binary files /dev/null and b/ui/litellm-dashboard/out/assets/audit-logs-preview.png.png differ diff --git a/ui/litellm-dashboard/out/audit-logs-preview.png b/ui/litellm-dashboard/out/audit-logs-preview.png deleted file mode 100644 index ce55441842..0000000000 Binary files a/ui/litellm-dashboard/out/audit-logs-preview.png and /dev/null differ diff --git a/ui/litellm-dashboard/public/assets/audit-logs-preview.png b/ui/litellm-dashboard/public/assets/audit-logs-preview.png new file mode 100644 index 0000000000..4e97c291d2 Binary files /dev/null and b/ui/litellm-dashboard/public/assets/audit-logs-preview.png differ diff --git a/ui/litellm-dashboard/public/audit-logs-preview.png b/ui/litellm-dashboard/public/audit-logs-preview.png deleted file mode 100644 index ce55441842..0000000000 Binary files a/ui/litellm-dashboard/public/audit-logs-preview.png and /dev/null differ diff --git a/ui/litellm-dashboard/src/components/common_components/PremiumLoggingSettings.tsx b/ui/litellm-dashboard/src/components/common_components/PremiumLoggingSettings.tsx new file mode 100644 index 0000000000..b9dd9cebf2 --- /dev/null +++ b/ui/litellm-dashboard/src/components/common_components/PremiumLoggingSettings.tsx @@ -0,0 +1,44 @@ +import React from 'react'; +import { Text } from "@tremor/react"; +import LoggingSettings from "../team/LoggingSettings"; + +interface PremiumLoggingSettingsProps { + value: any[]; + onChange: (settings: any[]) => void; + premiumUser?: boolean; +} + +export function PremiumLoggingSettings({ + value, + onChange, + premiumUser = false +}: PremiumLoggingSettingsProps) { + if (!premiumUser) { + return ( +
+
+
+ ✨ langfuse-logging +
+
+ ✨ datadog-logging +
+
+
+ + Setting Key/Team logging settings is a LiteLLM Enterprise feature. Global Logging Settings are available for all free users. Get a trial key here. + +
+
+ ); + } + + return ( + + ); +} + +export default PremiumLoggingSettings; \ No newline at end of file diff --git a/ui/litellm-dashboard/src/components/create_key_button.tsx b/ui/litellm-dashboard/src/components/create_key_button.tsx index 554d2f6c6d..9165de6515 100644 --- a/ui/litellm-dashboard/src/components/create_key_button.tsx +++ b/ui/litellm-dashboard/src/components/create_key_button.tsx @@ -40,7 +40,7 @@ import { Team } from "./key_team_helpers/key_list"; import TeamDropdown from "./common_components/team_dropdown"; import { InfoCircleOutlined } from '@ant-design/icons'; import { Tooltip } from 'antd'; -import LoggingSettings from "./team/LoggingSettings"; +import PremiumLoggingSettings from "./common_components/PremiumLoggingSettings"; import Createuser from "./create_user_button"; import debounce from 'lodash/debounce'; import { rolesWithWriteAccess } from '../utils/roles'; @@ -512,7 +512,7 @@ const CreateKey: React.FC = ({ {isFormDisabled && (
- Please select a team to continue configuring your API key. + Please select a team to continue configuring your API key. If you do not see any teams, please contact your Proxy Admin to either provide you with access to models or to add you to a team.
)} @@ -822,7 +822,11 @@ const CreateKey: React.FC = ({
- +
diff --git a/ui/litellm-dashboard/src/components/team/LoggingSettings.tsx b/ui/litellm-dashboard/src/components/team/LoggingSettings.tsx index 7627819a0c..32e45b9ee2 100644 --- a/ui/litellm-dashboard/src/components/team/LoggingSettings.tsx +++ b/ui/litellm-dashboard/src/components/team/LoggingSettings.tsx @@ -3,7 +3,7 @@ import React, { useState } from 'react'; import { Form, Select, Space, Tooltip, Divider } from 'antd'; import { InfoCircleOutlined } from '@ant-design/icons'; -import { Button, Card } from '@tremor/react'; +import { Button, Card, TextInput } from '@tremor/react'; import { PlusIcon, TrashIcon, CogIcon } from '@heroicons/react/outline'; import { callbackInfo, Callbacks, callback_map } from '../callback_info_helpers'; @@ -111,9 +111,8 @@ const LoggingSettings: React.FC = ({ value = [], onChange )} - updateCallbackVar(configIndex, paramName, e.target.value)} diff --git a/ui/litellm-dashboard/src/components/teams.tsx b/ui/litellm-dashboard/src/components/teams.tsx index 5d6afbebe5..92458fcc2b 100644 --- a/ui/litellm-dashboard/src/components/teams.tsx +++ b/ui/litellm-dashboard/src/components/teams.tsx @@ -60,7 +60,7 @@ import AvailableTeamsPanel from "@/components/team/available_teams"; import VectorStoreSelector from "./vector_store_management/VectorStoreSelector"; import PremiumVectorStoreSelector from "./common_components/PremiumVectorStoreSelector"; import PremiumMCPSelector from "./common_components/PremiumMCPSelector"; -import LoggingSettings from "./team/LoggingSettings"; +import PremiumLoggingSettings from "./common_components/PremiumLoggingSettings"; import type { KeyResponse, Team } from "./key_team_helpers/key_list"; import { formatNumberWithCommas } from "../utils/dataUtils"; @@ -1178,9 +1178,10 @@ const Teams: React.FC = ({
-
diff --git a/ui/litellm-dashboard/src/components/view_logs/audit_logs.tsx b/ui/litellm-dashboard/src/components/view_logs/audit_logs.tsx index 35159c25ec..dd25304073 100644 --- a/ui/litellm-dashboard/src/components/view_logs/audit_logs.tsx +++ b/ui/litellm-dashboard/src/components/view_logs/audit_logs.tsx @@ -18,6 +18,11 @@ interface AuditLogsProps { allTeams: Team[]; } + +const asset_logos_folder = '../ui/assets/'; +export const auditLogsPreviewImg = `${asset_logos_folder}audit-logs-preview.png`; + + export default function AuditLogs({ userID, userRole, @@ -402,16 +407,19 @@ export default function AuditLogs({ Here's a preview of what Audit Logs offer: Audit Logs Preview { + console.error('Failed to load audit logs preview image'); + (e.target as HTMLImageElement).style.display = 'none'; + }} /> ); diff --git a/ui/litellm-dashboard/src/components/view_logs/columns.tsx b/ui/litellm-dashboard/src/components/view_logs/columns.tsx index 3b462fa7e1..b6ac00402b 100644 --- a/ui/litellm-dashboard/src/components/view_logs/columns.tsx +++ b/ui/litellm-dashboard/src/components/view_logs/columns.tsx @@ -163,7 +163,7 @@ export const columns: ColumnDef[] = [ ), }, { - header: "Duration", + header: "Duration (s)", accessorKey: "duration", cell: (info: any) => (