From d86df67a3cd4ff4862a3e7f3788e8869d9a2c5ca Mon Sep 17 00:00:00 2001 From: "Builder.io" Date: Mon, 10 Nov 2025 05:14:56 +0000 Subject: [PATCH] Import modal and render directly cgen-679bfed0e3504c838887b222e6d2fdde --- client/components/ArmSwitcher.tsx | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/client/components/ArmSwitcher.tsx b/client/components/ArmSwitcher.tsx index f4e0800d..640d460d 100644 --- a/client/components/ArmSwitcher.tsx +++ b/client/components/ArmSwitcher.tsx @@ -1,6 +1,7 @@ import { useState, useEffect } from "react"; import { useNavigate } from "react-router-dom"; import { Zap, X } from "lucide-react"; +import ArmSwitcherModal from "./ArmSwitcherModal"; interface Arm { id: string; @@ -167,19 +168,7 @@ export default function ArmSwitcher() { {/* Modal for mobile fullscreen arm switching */} - {/* Lazy import via component file to keep code organized */} - {isModalOpen && ( - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore - dynamic import handled at build time - require("./ArmSwitcherModal").default ? ( - // If the module is available, render it - //@ts-expect-error - React.createElement(require("./ArmSwitcherModal").default, { - isOpen: isModalOpen, - onClose: () => setIsModalOpen(false), - }) - ) : null - )} + setIsModalOpen(false)} /> ); }