-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: adds a help tooltip to each field in the block details page * chore: add changeset * Update .changeset/olive-ligers-watch.md Co-authored-by: 0xelessar.eth <[email protected]> * feat: replace SVG icon with Heroicons InformationCircleIcon in InfoField component * Update apps/web/src/pages/block/[id].tsx Co-authored-by: 0xelessar.eth <[email protected]> * Update apps/web/src/pages/block/[id].tsx Co-authored-by: 0xelessar.eth <[email protected]> * Update apps/web/src/pages/block/[id].tsx Co-authored-by: 0xelessar.eth <[email protected]> * Update apps/web/src/pages/block/[id].tsx Co-authored-by: 0xelessar.eth <[email protected]> * Update apps/web/src/pages/block/[id].tsx Co-authored-by: 0xelessar.eth <[email protected]> * Update apps/web/src/pages/block/[id].tsx Co-authored-by: 0xelessar.eth <[email protected]> * Refactor InfoField and InfoGrid components to accept ReactNode for descriptions and add helpText support in InfoGrid * Update apps/web/src/pages/block/[id].tsx Co-authored-by: Pablo Castellano <[email protected]> * Update apps/web/src/pages/block/[id].tsx Co-authored-by: Pablo Castellano <[email protected]> * Update apps/web/src/pages/block/[id].tsx Co-authored-by: Pablo Castellano <[email protected]> * Update apps/web/src/pages/block/[id].tsx Co-authored-by: Pablo Castellano <[email protected]> * Update helpText for Blob Gas Used to include target blob gas value --------- Co-authored-by: 0xelessar.eth <[email protected]> Co-authored-by: Pablo Castellano <[email protected]>
- Loading branch information
1 parent
0703ea2
commit a0f594f
Showing
4 changed files
with
61 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@blobscan/web": minor | ||
--- | ||
|
||
Added a help tooltip to each field in the block details page |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import type { FC, ReactNode } from "react"; | ||
import { InformationCircleIcon } from "@heroicons/react/24/solid"; | ||
|
||
import { Tooltip, TooltipContent, TooltipTrigger } from "~/components/Tooltip"; | ||
|
||
type InfoFieldProps = { | ||
children: ReactNode; | ||
description: ReactNode; | ||
}; | ||
|
||
export const InfoField: FC<InfoFieldProps> = ({ children, description }) => { | ||
return ( | ||
<div className="flex flex-row items-center gap-2"> | ||
<Tooltip> | ||
<TooltipContent className="max-w-[240px]">{description}</TooltipContent> | ||
<TooltipTrigger> | ||
<InformationCircleIcon className="h-4 w-4 opacity-80" /> | ||
</TooltipTrigger> | ||
</Tooltip> | ||
{children} | ||
</div> | ||
); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters