History

Drop the empty bordered panel for no-auth connections

The connect modal's auth-method panel always rendered a framed box (border, muted fill, padding). With No authentication selected there are no fields to show, so it appeared as an empty bordered rectangle below the method selector. Only apply the frame when the panel has content.

Rhys Sullivan committed 4 months ago

Commit a3b91ad1 parent eb9ed891 file · +6 −1Browse files

Unified · Split

packages/react/src/components/add-account-modal.tsx+6−1
@@ -1452,7 +1452,12 @@ function AddAccountModalView(props: AddAccountModalProps) { · 1451 unmodified lines
1452 {dcrActive ? null : (1452 {dcrActive ? null : (
1453 <TabsContent1453 <TabsContent
1454 value={methodId}1454 value={methodId}
1455 className="mt-0 min-w-0 space-y-5 rounded-md border border-border/60 bg-muted/15 p-4"1455 className={cn(
1456 "mt-0 min-w-0 space-y-5",
1457 // No-auth renders no fields, so skip the framed box that
1458 // would otherwise show up as an empty bordered panel.
1459 isNoAuth ? null : "rounded-md border border-border/60 bg-muted/15 p-4",
1460 )}
1456 >1461 >
1457 {method?.placements && !isEnvMethod && singleInput1462 {method?.placements && !isEnvMethod && singleInput
1458 ? (() => {1463 ? (() => {