From e183f9ddce4d3e71f186715a5c997ea55503852b Mon Sep 17 00:00:00 2001 From: Thigazhezhilan J Date: Wed, 1 Apr 2026 23:46:21 +0530 Subject: [PATCH] Improve mobile layout across landing and portfolio pages --- src/components/chat/ChatButton.tsx | 8 +- src/components/chat/ChatWidget.tsx | 2 +- .../landing/BrokerConnectDialog.tsx | 4 +- src/components/landing/FinalCTA.tsx | 10 +-- src/components/landing/HeroSection.tsx | 58 ++++++++----- src/components/landing/HowItWorks.tsx | 16 ++-- src/components/landing/Navigation.tsx | 32 +++++--- src/components/landing/PerformanceChart.tsx | 26 +++--- src/components/landing/PortfolioSection.tsx | 69 +++++++++------- src/components/landing/StrategiesSection.tsx | 10 +-- .../landing/StrategySelectorModal.tsx | 10 +-- src/pages/PaperPortfolio.tsx | 81 ++++++++++--------- 12 files changed, 185 insertions(+), 141 deletions(-) diff --git a/src/components/chat/ChatButton.tsx b/src/components/chat/ChatButton.tsx index b0595272..f238230b 100644 --- a/src/components/chat/ChatButton.tsx +++ b/src/components/chat/ChatButton.tsx @@ -8,11 +8,11 @@ type ChatButtonProps = { export default function ChatButton({ open, onToggle }: ChatButtonProps) { return ( -
+
Need help? @@ -20,7 +20,7 @@ export default function ChatButton({ open, onToggle }: ChatButtonProps) { whileHover={{ scale: 1.05 }} whileTap={{ scale: 0.96 }} onClick={onToggle} - className="relative flex h-14 w-14 items-center justify-center rounded-full bg-gradient-to-br from-sky-500 to-cyan-400 text-white shadow-xl" + className="relative flex h-12 w-12 items-center justify-center rounded-full bg-gradient-to-br from-sky-500 to-cyan-400 text-white shadow-xl sm:h-14 sm:w-14" aria-label={open ? "Close chat" : "Open chat"} > - +
); diff --git a/src/components/chat/ChatWidget.tsx b/src/components/chat/ChatWidget.tsx index e0e69d84..1e289493 100644 --- a/src/components/chat/ChatWidget.tsx +++ b/src/components/chat/ChatWidget.tsx @@ -91,7 +91,7 @@ export default function ChatWidget() { animate={{ opacity: 1, y: 0, scale: 1 }} exit={{ opacity: 0, y: 20, scale: 0.98 }} transition={{ duration: 0.25, ease: "easeOut" }} - className="fixed bottom-6 right-4 top-20 z-[60] w-[372px] max-w-[calc(100vw-2rem)]" + className="fixed bottom-20 left-3 right-3 z-[60] h-[min(68vh,32rem)] sm:bottom-6 sm:left-auto sm:right-4 sm:top-20 sm:h-auto sm:w-[372px] sm:max-w-[calc(100vw-2rem)]" >
diff --git a/src/components/landing/BrokerConnectDialog.tsx b/src/components/landing/BrokerConnectDialog.tsx index 746bf8ba..1ca8f5d6 100644 --- a/src/components/landing/BrokerConnectDialog.tsx +++ b/src/components/landing/BrokerConnectDialog.tsx @@ -22,6 +22,7 @@ type BrokerConnectDialogProps = { layout?: "desktop" | "mobile"; open?: boolean; onOpenChange?: (open: boolean) => void; + triggerClassName?: string; }; type SessionUser = Pick; @@ -48,6 +49,7 @@ export default function BrokerConnectDialog({ layout = "desktop", open, onOpenChange, + triggerClassName: triggerClassNameProp, }: BrokerConnectDialogProps) { const [connectOpenInternal, setConnectOpenInternal] = useState(false); const isControlled = open !== undefined; @@ -243,7 +245,7 @@ export default function BrokerConnectDialog({