Skip to content

Commit 0297411

Browse files
committed
[TOOL-4856] Engine Server wallets table UI adjustment, Fix Vault Portal Link (#7419)
<!-- ## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes" If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000): ## Notes for the reviewer Anything important to call out? Be sure to also clarify these in your comments. ## How to test Unit tests, playground, etc. --> <!-- start pr-codex --> --- ## PR-Codex overview This PR primarily focuses on enhancing the user interface in the dashboard by improving the handling of server wallets and updating the link for the Vault. ### Detailed summary - Updated the `href` in the `Link` component to point to `https://portal.thirdweb.com/vault` and added a "Learn more about Vault" text. - Refactored the rendering logic for wallets: - Removed the conditional rendering for "No server wallets found" and replaced it with a new div that displays this message when there are no wallets. - Streamlined the mapping of `wallets` to display each wallet's details within a `TableRow`. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex --> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Bug Fixes** - Improved the display of the "No server wallets found" message, which now appears below the wallets table instead of inside it for better clarity. - **Style** - Updated the "Learn more about Vault" link to display clear link text and corrected its URL for improved user navigation. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
1 parent b5114df commit 0297411

File tree

2 files changed

+33
-33
lines changed

2 files changed

+33
-33
lines changed

apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/transactions/analytics/ftux.client.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,10 +128,12 @@ function CreateVaultAccountStep(props: {
128128
/>
129129
<Button asChild variant="outline">
130130
<Link
131-
href="https://portal.thirdweb.com/engine/vault"
131+
href="https://portal.thirdweb.com/vault"
132132
rel="noopener noreferrer"
133133
target="_blank"
134-
></Link>
134+
>
135+
Learn more about Vault
136+
</Link>
135137
</Button>
136138
</div>
137139
);

apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/transactions/server-wallets/wallet-table/wallet-table-ui.client.tsx

Lines changed: 29 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -102,41 +102,39 @@ export function ServerWalletsTableUI({
102102
</TableRow>
103103
</TableHeader>
104104
<TableBody>
105-
{wallets.length === 0 ? (
106-
<TableRow>
107-
<TableCell className="text-center" colSpan={3}>
108-
No server wallets found
105+
{wallets.map((wallet) => (
106+
<TableRow className="hover:bg-accent/50" key={wallet.id}>
107+
<TableCell>
108+
{showSigners ? (
109+
<WalletAddress address={wallet.address} client={client} />
110+
) : (
111+
<SmartAccountCell client={client} wallet={wallet} />
112+
)}
113+
</TableCell>
114+
<TableCell>{wallet.metadata.label || "none"}</TableCell>
115+
<TableCell className="text-right">
116+
<WalletDateCell date={wallet.createdAt} />
117+
</TableCell>
118+
<TableCell className="text-right">
119+
<WalletDateCell date={wallet.updatedAt} />
120+
</TableCell>
121+
<TableCell className="flex justify-end">
122+
<SendTestTransaction
123+
project={project}
124+
teamSlug={teamSlug}
125+
wallet={wallet}
126+
/>
109127
</TableCell>
110128
</TableRow>
111-
) : (
112-
wallets.map((wallet) => (
113-
<TableRow className="hover:bg-accent/50" key={wallet.id}>
114-
<TableCell>
115-
{showSigners ? (
116-
<WalletAddress address={wallet.address} client={client} />
117-
) : (
118-
<SmartAccountCell client={client} wallet={wallet} />
119-
)}
120-
</TableCell>
121-
<TableCell>{wallet.metadata.label || "none"}</TableCell>
122-
<TableCell className="text-right">
123-
<WalletDateCell date={wallet.createdAt} />
124-
</TableCell>
125-
<TableCell className="text-right">
126-
<WalletDateCell date={wallet.updatedAt} />
127-
</TableCell>
128-
<TableCell className="flex justify-end">
129-
<SendTestTransaction
130-
project={project}
131-
teamSlug={teamSlug}
132-
wallet={wallet}
133-
/>
134-
</TableCell>
135-
</TableRow>
136-
))
137-
)}
129+
))}
138130
</TableBody>
139131
</Table>
132+
133+
{wallets.length === 0 && (
134+
<div className="py-20 flex items-center justify-center px-4 text-center">
135+
No server wallets found
136+
</div>
137+
)}
140138
</TableContainer>
141139

142140
{totalPages > 1 && (

0 commit comments

Comments
 (0)