From 7503e470aaf2e6a62da2e4453ac7926b3904a328 Mon Sep 17 00:00:00 2001 From: Badri-Vishal Date: Wed, 4 Dec 2024 19:23:58 +0530 Subject: [PATCH 1/3] fixes/replaced-Clear-button-with-reset-filters-button --- .../app/(app)/ratelimits/[namespaceId]/logs/filter.tsx | 5 ++++- .../app/(app)/ratelimits/[namespaceId]/logs/page.tsx | 4 +--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/filter.tsx b/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/filter.tsx index fe6a1d3fe2..40a6c23dac 100644 --- a/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/filter.tsx +++ b/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/filter.tsx @@ -109,11 +109,14 @@ export const Filters: React.FC = () => { className="flex items-center h-8 gap-2 bg-background-subtle" onClick={() => { setIdentifierVisible(false); + setSuccessVisible(false); + setSuccess(null); + setTimeRangeVisible(false); setIdentifier(null); startTransition(() => {}); }} > - Clear + Reset Filters ) : null} diff --git a/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx b/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx index c3e2ebf7f3..454cbeb8d5 100644 --- a/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx +++ b/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx @@ -136,9 +136,7 @@ const AuditLogTable: React.FC<{ No events matched these filters, try changing them.{" "} - - - + ) : ( From 02c3bee6f87c39cba41733addcff578ecfa991d8 Mon Sep 17 00:00:00 2001 From: Badri-Vishal Date: Thu, 5 Dec 2024 01:29:00 +0530 Subject: [PATCH 2/3] fix:wrapped-the-whole-function-in-startTransition-function --- .../ratelimits/[namespaceId]/logs/filter.tsx | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/filter.tsx b/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/filter.tsx index 40a6c23dac..8f3a240d16 100644 --- a/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/filter.tsx +++ b/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/filter.tsx @@ -108,12 +108,15 @@ export const Filters: React.FC = () => { size="sm" className="flex items-center h-8 gap-2 bg-background-subtle" onClick={() => { - setIdentifierVisible(false); - setSuccessVisible(false); - setSuccess(null); - setTimeRangeVisible(false); - setIdentifier(null); - startTransition(() => {}); + startTransition(() => { + setIdentifierVisible(false); + setSuccessVisible(false); + setSuccess(null); + setTimeRangeVisible(false); + setIdentifier(null); + setAfter(null); + setBefore(null); + }); }} > Reset Filters From a3f39db9b1d374e92ecc44aa110df66a87011d8e Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Thu, 5 Dec 2024 07:24:34 +0000 Subject: [PATCH 3/3] [autofix.ci] apply automated fixes --- .../dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx | 3 --- 1 file changed, 3 deletions(-) diff --git a/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx b/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx index 454cbeb8d5..a0555b1f6e 100644 --- a/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx +++ b/apps/dashboard/app/(app)/ratelimits/[namespaceId]/logs/page.tsx @@ -5,7 +5,6 @@ import { notFound } from "next/navigation"; import { EmptyPlaceholder } from "@/components/dashboard/empty-placeholder"; import { Loading } from "@/components/dashboard/loading"; import { Badge } from "@/components/ui/badge"; -import { Button } from "@/components/ui/button"; import { Table, TableBody, @@ -16,7 +15,6 @@ import { } from "@/components/ui/table"; import { clickhouse } from "@/lib/clickhouse"; import { Box, Check, X } from "lucide-react"; -import Link from "next/link"; import { parseAsArrayOf, parseAsBoolean, parseAsIsoDateTime, parseAsString } from "nuqs/server"; import { Suspense } from "react"; import { Filters } from "./filter"; @@ -136,7 +134,6 @@ const AuditLogTable: React.FC<{ No events matched these filters, try changing them.{" "} - ) : (