change terms

This commit is contained in:
miloschwartz 2025-04-25 17:13:20 -04:00
parent c3dbc64a58
commit 80d76befc9
No known key found for this signature in database
5 changed files with 32 additions and 15 deletions

View file

@ -238,8 +238,11 @@ export default function GeneralPage() {
); );
}} }}
/> />
<Badge className="ml-2"> <Badge
Enterprise variant="outlinePrimary"
className="ml-2"
>
Professional
</Badge> </Badge>
</div> </div>
<span className="text-sm text-muted-foreground"> <span className="text-sm text-muted-foreground">

View file

@ -198,8 +198,11 @@ export default function Page() {
); );
}} }}
/> />
<Badge className="ml-2"> <Badge
Enterprise variant="outlinePrimary"
className="ml-2"
>
Professional
</Badge> </Badge>
</div> </div>
<span className="text-sm text-muted-foreground"> <span className="text-sm text-muted-foreground">

View file

@ -68,7 +68,7 @@ export const orgNavItems: SidebarNavItem[] = [
title: "API Keys", title: "API Keys",
href: "/{orgId}/settings/api-keys", href: "/{orgId}/settings/api-keys",
icon: <KeyRound className="h-4 w-4" />, icon: <KeyRound className="h-4 w-4" />,
showEnterprise: true showProfessional: true
}, },
{ {
title: "Settings", title: "Settings",
@ -87,7 +87,7 @@ export const adminNavItems: SidebarNavItem[] = [
title: "API Keys", title: "API Keys",
href: "/{orgId}/settings/api-keys", href: "/{orgId}/settings/api-keys",
icon: <KeyRound className="h-4 w-4" />, icon: <KeyRound className="h-4 w-4" />,
showEnterprise: true showProfessional: true
}, },
{ {
title: "Identity Providers", title: "Identity Providers",

View file

@ -14,7 +14,7 @@ export interface SidebarNavItem {
icon?: React.ReactNode; icon?: React.ReactNode;
children?: SidebarNavItem[]; children?: SidebarNavItem[];
autoExpand?: boolean; autoExpand?: boolean;
showEnterprise?: boolean; showProfessional?: boolean;
} }
export interface SidebarNavProps extends React.HTMLAttributes<HTMLElement> { export interface SidebarNavProps extends React.HTMLAttributes<HTMLElement> {
@ -98,8 +98,8 @@ export function SidebarNav({
const hasChildren = item.children && item.children.length > 0; const hasChildren = item.children && item.children.length > 0;
const isExpanded = expandedItems.has(hydratedHref); const isExpanded = expandedItems.has(hydratedHref);
const indent = level * 28; // Base indent for each level const indent = level * 28; // Base indent for each level
const isEnterprise = item.showEnterprise; const isProfessional = item.showProfessional;
const isDisabled = disabled || isEnterprise; const isDisabled = disabled || isProfessional;
return ( return (
<div key={hydratedHref}> <div key={hydratedHref}>
@ -114,7 +114,7 @@ export function SidebarNav({
)} )}
> >
<Link <Link
href={isEnterprise ? "#" : hydratedHref} href={isProfessional ? "#" : hydratedHref}
className={cn( className={cn(
"flex items-center w-full px-3 py-2", "flex items-center w-full px-3 py-2",
isActive isActive
@ -132,15 +132,25 @@ export function SidebarNav({
tabIndex={isDisabled ? -1 : undefined} tabIndex={isDisabled ? -1 : undefined}
aria-disabled={isDisabled} aria-disabled={isDisabled}
> >
<div className={cn("flex items-center", isDisabled && "opacity-60")}> <div
className={cn(
"flex items-center",
isDisabled && "opacity-60"
)}
>
{item.icon && ( {item.icon && (
<span className="mr-3">{item.icon}</span> <span className="mr-3">
{item.icon}
</span>
)} )}
{item.title} {item.title}
</div> </div>
{isEnterprise && ( {isProfessional && (
<Badge className="ml-2"> <Badge
Enterprise variant="outlinePrimary"
className="ml-2"
>
Professional
</Badge> </Badge>
)} )}
</Link> </Link>

View file

@ -10,6 +10,7 @@ const badgeVariants = cva(
variant: { variant: {
default: default:
"border-transparent bg-primary text-primary-foreground", "border-transparent bg-primary text-primary-foreground",
outlinePrimary: "border-transparent bg-transparent border-primary text-primary",
secondary: secondary:
"border-transparent bg-secondary text-secondary-foreground", "border-transparent bg-secondary text-secondary-foreground",
destructive: destructive: