From 3d3a9c0dfb0b8cd1e2a4ea91e7fa99be740375a4 Mon Sep 17 00:00:00 2001 From: Eunjae Lee Date: Mon, 3 Mar 2025 16:42:38 +0100 Subject: [PATCH] fix: use portal for DataTableSelectionBar (#19672) --- .../data-table/components/DataTableSelectionBar.tsx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/features/data-table/components/DataTableSelectionBar.tsx b/packages/features/data-table/components/DataTableSelectionBar.tsx index fb25fea261..4f0c530b93 100644 --- a/packages/features/data-table/components/DataTableSelectionBar.tsx +++ b/packages/features/data-table/components/DataTableSelectionBar.tsx @@ -2,6 +2,7 @@ import type { Table } from "@tanstack/react-table"; import { forwardRef } from "react"; +import { createPortal } from "react-dom"; import { classNames } from "@calcom/lib"; import { Button, Icon } from "@calcom/ui"; @@ -47,17 +48,18 @@ const Root = forwardRef< React.HTMLAttributes & { showSelectionCount?: boolean } >(({ children, ...props }, ref) => { const { className, style, ...rest } = props; - return ( + return createPortal(
{children} -
+ , + document.body ); });