Some checks are pending
E2E / Playwright e2e (push) Waiting to run
- Introduced new components for managing admin settings, including AdminListControls, AdminSettingsCard, and TechBrandSelectLabel. - Implemented dynamic loading for admin settings sections to optimize performance. - Enhanced the layout of various admin settings sections for better user experience. - Updated the AiAssistantSection to include LLM provider management and improved model selection. - Refactored authentication settings to streamline configuration and improve accessibility.
36 lines
801 B
TypeScript
36 lines
801 B
TypeScript
"use client"
|
|
|
|
import { Icon } from "@iconify/react"
|
|
import { techBrandIcon } from "@/lib/admin-settings/tech-brand-icons"
|
|
import { cn } from "@/lib/utils"
|
|
|
|
export function TechBrandSelectLabel({
|
|
brand,
|
|
icon,
|
|
children,
|
|
className,
|
|
iconClassName,
|
|
suffix,
|
|
}: {
|
|
brand?: string
|
|
icon?: string
|
|
children: React.ReactNode
|
|
className?: string
|
|
iconClassName?: string
|
|
suffix?: React.ReactNode
|
|
}) {
|
|
const resolved = icon ?? (brand ? techBrandIcon(brand) : undefined)
|
|
|
|
return (
|
|
<span className={cn("inline-flex min-w-0 items-center gap-2", className)}>
|
|
{resolved ? (
|
|
<Icon icon={resolved} className={cn("size-4 shrink-0", iconClassName)} aria-hidden />
|
|
) : null}
|
|
<span className="truncate">
|
|
{children}
|
|
{suffix}
|
|
</span>
|
|
</span>
|
|
)
|
|
}
|