Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions ui/app/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -390,6 +390,11 @@ div.content-container:has(.no-border-parent) #trial-notification-banner {
@apply rounded-sm!;
}

/* Ensure toasts remain clickable above modal overlays (radix react-remove-scroll) */
[data-sonner-toaster] {
pointer-events: auto !important;
}

/* Move Sonner toast close button to top-right */
[data-sonner-toaster][dir="ltr"],
[data-sonner-toaster] {
Expand Down
10 changes: 4 additions & 6 deletions ui/app/workspace/routing-rules/views/routingRuleSheet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
* Create/Edit form for routing rules
*/

import { RbacOperation, RbacResource, useRbac } from "@enterprise/lib";
import { Button } from "@/components/ui/button";
import { ComboboxSelect } from "@/components/ui/combobox";
import { Input } from "@/components/ui/input";
Expand All @@ -30,7 +29,8 @@ import {
} from "@/lib/types/routingRules";
import { validateRateLimitAndBudgetRules, validateRoutingRules } from "@/lib/utils/celConverterRouting";
import { normalizeRoutingRuleGroupQuery } from "@/lib/utils/routingRuleGroupQuery";
import { Plus, Save, Trash2, X } from "lucide-react";
import { RbacOperation, RbacResource, useRbac } from "@enterprise/lib";
import { Plus, Trash2, X } from "lucide-react";
import { lazy, Suspense, useCallback, useEffect, useState } from "react";
import { useForm } from "react-hook-form";
import { RuleGroupType } from "react-querybuilder";
Expand Down Expand Up @@ -273,8 +273,8 @@ export function RoutingRuleSheet({ open, onOpenChange, editingRule, onSuccess }:
</SheetDescription>
</SheetHeader>

<form onSubmit={handleSubmit(onSubmit)}>
<div className="flex flex-col gap-6 px-8 pb-6">
<form onSubmit={handleSubmit(onSubmit)} className="flex flex-col grow">
<div className="flex flex-col gap-6 px-8 pb-6 grow">
{/* Rule Name */}
<div className="space-y-3">
<Label htmlFor="name">
Expand Down Expand Up @@ -584,11 +584,9 @@ export function RoutingRuleSheet({ open, onOpenChange, editingRule, onSuccess }:
{/* Action Buttons */}
<div className="bg-card sticky bottom-0 flex justify-end gap-3 border-t px-8 py-4">
<Button type="button" variant="outline" onClick={handleCancel} disabled={isLoading}>
<X className="h-4 w-4" />
Cancel
</Button>
<Button type="submit" disabled={isLoading || !hasRequiredAccess}>
<Save className="h-4 w-4" />
{isEditing ? "Update Rule" : "Save Rule"}
</Button>
</div>
Expand Down
2 changes: 1 addition & 1 deletion ui/app/workspace/virtual-keys/views/virtualKeySheet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1013,7 +1013,7 @@ export default function VirtualKeySheet({
onSubmit={form.handleSubmit(onSubmit)}
className="flex h-full flex-col gap-6"
>
<div className="space-y-4 px-8">
<div className="space-y-4 px-8 grow">
{isManagedByProfile && (
<Alert variant="info">
<Lock className="h-4 w-4" />
Expand Down
20 changes: 10 additions & 10 deletions ui/app/workspace/virtual-keys/views/virtualKeysTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -659,8 +659,8 @@ export default function VirtualKeysTable({
</AlertDialogContent>
</AlertDialog>

<div className="space-y-4">
<div className="flex items-center justify-between">
<div className="flex min-h-0 w-full grow flex-col gap-4 overflow-hidden">
<div className="flex shrink-0 items-center justify-between">
<div>
<h2 className="text-lg font-semibold">Virtual Keys</h2>
<p className="text-muted-foreground text-sm">Manage virtual keys, their permissions, budgets, and rate limits.</p>
Expand Down Expand Up @@ -689,7 +689,7 @@ export default function VirtualKeysTable({
</div>

{/* Toolbar: Search + Filters */}
<div className="flex items-center gap-3">
<div className="flex shrink-0 items-center gap-3">
<div className="relative max-w-sm flex-1">
<Search className="text-muted-foreground absolute top-1/2 left-3 h-4 w-4 -translate-y-1/2" />
<Input
Expand Down Expand Up @@ -720,9 +720,9 @@ export default function VirtualKeysTable({
/>
</div>

<div className="rounded-sm border">
<Table className="w-full min-w-[1528px] table-fixed" data-testid="vk-table">
<TableHeader>
<div className="min-h-0 grow overflow-hidden rounded-sm border">
<Table containerClassName="h-full overflow-auto" className="w-full min-w-[1528px] table-fixed" data-testid="vk-table">
<TableHeader className="bg-muted sticky top-0 z-20">
Comment thread
impoiler marked this conversation as resolved.
<TableRow>
<TableHead className="w-[48px]">
<Checkbox
Expand All @@ -744,7 +744,7 @@ export default function VirtualKeysTable({
<TableHead className="w-[120px]">
<SortableHeader column="status" label="Status" />
</TableHead>
<TableHead className={`bg-muted sticky right-0 z-10 w-[56px] text-right ${PIN_SHADOW_RIGHT}`}></TableHead>
<TableHead className={`bg-muted sticky right-0 z-30 w-[56px] text-right ${PIN_SHADOW_RIGHT}`}></TableHead>
</TableRow>
</TableHeader>
<TableBody>
Expand Down Expand Up @@ -824,7 +824,7 @@ export default function VirtualKeysTable({
<VKActiveSwitch vk={vk} hasUpdateAccess={hasUpdateAccess} onToggle={handleToggleActive} />
</TableCell>
<TableCell
className={`group-hover:bg-muted dark:bg-card dark:group-hover:bg-muted sticky right-0 z-10 bg-white text-right ${PIN_SHADOW_RIGHT}`}
className={`group-hover:bg-muted dark:bg-card dark:group-hover:bg-muted sticky right-0 z-20 bg-white text-right ${PIN_SHADOW_RIGHT}`}
onClick={(e) => e.stopPropagation()}
>
<VKActionsMenu
Expand All @@ -846,8 +846,8 @@ export default function VirtualKeysTable({

{/* Pagination */}
{totalCount > 0 && (
<div className="flex items-center justify-between px-2">
<p className="text-muted-foreground text-sm">
<div className="flex shrink-0 items-center justify-between px-2 text-xs">
<p className="text-muted-foreground">
Showing {offset + 1}-{Math.min(offset + limit, totalCount)} of {totalCount}
</p>
<div className="flex gap-2">
Expand Down
Loading