Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export const ContractOverviewPage: React.FC<ContractOverviewPageProps> = ({
}) => {
return (
<div className="flex flex-col gap-10 lg:flex-row lg:gap-8">
<div className="flex grow flex-col gap-10">
<div className="flex grow flex-col gap-10 overflow-hidden">
<ContractChecklist
isErc721={isErc721}
isErc1155={isErc1155}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ export function LatestEventsUI(props: {
trackingCategory: string;
}) {
const { allEvents, autoUpdate, eventsHref } = props;

return (
<div className="rounded-lg border bg-card">
{/* header */}
Expand Down Expand Up @@ -93,37 +92,50 @@ export function LatestEventsUI(props: {
</TableHeader>

<TableBody>
{allEvents.slice(0, 3).map((transaction) => (
<TableRow key={transaction.transactionHash}>
<TableCell>
<CopyTextButton
textToShow={shortenString(transaction.transactionHash)}
textToCopy={transaction.transactionHash}
tooltip="Copy transaction hash"
copyIconPosition="left"
variant="ghost"
className="-translate-x-2 font-mono"
/>
</TableCell>
<TableCell>
<div className="flex w-max flex-wrap gap-2">
{transaction.events.map((e) => (
<Button
key={e.logIndex + e.address + e.eventName}
variant="outline"
size="sm"
className="h-auto rounded-full py-1"
asChild
>
<Link href={`${eventsHref}?event=${e.eventName}`}>
{e.eventName}
</Link>
</Button>
))}
</div>
</TableCell>
</TableRow>
))}
{allEvents.slice(0, 3).map((transaction) => {
return (
<TableRow key={transaction.transactionHash}>
<TableCell>
<CopyTextButton
textToShow={shortenString(transaction.transactionHash)}
textToCopy={transaction.transactionHash}
tooltip="Copy transaction hash"
copyIconPosition="left"
variant="ghost"
className="-translate-x-2 font-mono"
/>
</TableCell>
<TableCell>
<div className="flex w-max flex-wrap gap-2">
{transaction.events.slice(0, 3).map((e) => (
<Button
key={e.logIndex + e.address + e.eventName}
variant="outline"
size="sm"
className="h-auto rounded-full py-1"
asChild
>
<Link href={`${eventsHref}?event=${e.eventName}`}>
{e.eventName}
</Link>
</Button>
))}

{transaction.events.length > 3 && (
<Button
variant="outline"
size="sm"
className="h-auto rounded-full py-1 hover:bg-transparent"
asChild
>
<div>+ {transaction.events.length - 3}</div>
</Button>
)}
</div>
</TableCell>
</TableRow>
);
})}
</TableBody>
</Table>
</TableContainer>
Expand Down
Loading