From aa0d23e966d4fd34ebadc38793f0f006aa70004f Mon Sep 17 00:00:00 2001 From: MananTank Date: Fri, 26 Sep 2025 20:10:28 +0000 Subject: [PATCH] SDK: Fix Embed widget container size, Dashboard: Fix Bridge embed UI width (#8136) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ## PR-Codex overview This PR focuses on fixing the embed container size across various components in the `thirdweb` and `dashboard` applications, ensuring better layout and responsiveness. ### Detailed summary - Updated `maxWidth` in `ConnectEmbed` to `100%` and adjusted `width` based on `modalSize`. - Removed redundant `layout: "centered"` parameter in `ConnectEmbed` story. - Simplified `UniversalBridgeEmbed` structure by removing unnecessary wrapping `div`. - Added `min-w-0` class to `BuyAndSwapEmbed` and `GridPatternEmbedContainer` for better responsiveness. - Adjusted layout classes in `GridPatternEmbedContainer` for improved alignment. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` ## Summary by CodeRabbit - Bug Fixes - Fixed embed container sizing in the Connect Wallet modal to respect modal width and prevent viewport overflow. - Resolved overflow and min-width issues in embed containers for smoother responsive behavior. - Style - Updated Bridge page layout to display components side-by-side on larger screens. - Improved responsive rounding and overflow handling around embed containers for cleaner visuals. - Chores - Updated thirdweb dependency to the latest patch release. --- .changeset/social-showers-see.md | 5 +++++ .../src/@/components/blocks/BuyAndSwapEmbed.tsx | 2 +- .../blocks/grid-pattern-embed-container.tsx | 4 ++-- .../components/client/UniversalBridgeEmbed.tsx | 14 ++++++-------- apps/dashboard/src/app/bridge/page.tsx | 2 +- .../web/ui/ConnectWallet/Modal/ConnectEmbed.tsx | 5 ++--- .../thirdweb/src/stories/ConnectEmbed.stories.tsx | 3 --- 7 files changed, 17 insertions(+), 18 deletions(-) create mode 100644 .changeset/social-showers-see.md diff --git a/.changeset/social-showers-see.md b/.changeset/social-showers-see.md new file mode 100644 index 00000000000..28e2cdb3dd4 --- /dev/null +++ b/.changeset/social-showers-see.md @@ -0,0 +1,5 @@ +--- +"thirdweb": patch +--- + +Fix Embed container size diff --git a/apps/dashboard/src/@/components/blocks/BuyAndSwapEmbed.tsx b/apps/dashboard/src/@/components/blocks/BuyAndSwapEmbed.tsx index af61737726e..0a9bdaaa705 100644 --- a/apps/dashboard/src/@/components/blocks/BuyAndSwapEmbed.tsx +++ b/apps/dashboard/src/@/components/blocks/BuyAndSwapEmbed.tsx @@ -67,7 +67,7 @@ export function BuyAndSwapEmbed(props: { }, [props.pageType]); return ( -
+
+
-
{props.children}
+
{props.children}
); } diff --git a/apps/dashboard/src/app/bridge/components/client/UniversalBridgeEmbed.tsx b/apps/dashboard/src/app/bridge/components/client/UniversalBridgeEmbed.tsx index dfddd41f669..9e4aa425588 100644 --- a/apps/dashboard/src/app/bridge/components/client/UniversalBridgeEmbed.tsx +++ b/apps/dashboard/src/app/bridge/components/client/UniversalBridgeEmbed.tsx @@ -16,13 +16,11 @@ export function UniversalBridgeEmbed({ const chain = useV5DashboardChain(chainId || 1); return ( -
- -
+ ); } diff --git a/apps/dashboard/src/app/bridge/page.tsx b/apps/dashboard/src/app/bridge/page.tsx index a6474efda9a..b59ebbaa298 100644 --- a/apps/dashboard/src/app/bridge/page.tsx +++ b/apps/dashboard/src/app/bridge/page.tsx @@ -54,7 +54,7 @@ export default async function BridgePage({
-
+
= { title: "Connect/ConnectEmbed", - parameters: { - layout: "centered", - }, decorators: [ (Story) => { return (