Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show askAmount on my-grants page #80

Merged
merged 2 commits into from
Mar 15, 2024
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
2 changes: 1 addition & 1 deletion packages/nextjs/app/admin/_components/GrantReview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export const GrantReview = ({ grant, selected, toggleSelection }: GrantReviewPro
const completeActionDisableToolTip = isCompleteActionDisabled && `Please switch to chain: ${grant.txChainId}`;

return (
<div className="border border-4 rounded-lg p-4 my-4">
<div className="border-4 rounded-lg p-4 my-4">
<div className="flex justify-between mb-2">
<div className="font-bold flex flex-col gap-1 lg:gap-2 lg:flex-row items-baseline">
<h1 className="text-lg m-0">{grant.title}</h1>
Expand Down
11 changes: 9 additions & 2 deletions packages/nextjs/app/my-grants/page.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"use client";

import { useState } from "react";
import Image from "next/image";
import { SubmitModal } from "./_components/SubmitModal";
import { NextPage } from "next";
import useSWR from "swr";
Expand Down Expand Up @@ -35,11 +36,17 @@ const MyGrants: NextPage = () => {
{builderGrants?.length === 0 && <p>No grants found</p>}
{builderGrants?.map(grant => (
<div key={grant.id} className="border p-4 my-4">
<h3 className="font-bold">
<h3 className="text-lg m-0 font-bold">
{grant.title}
<span className="text-sm text-gray-500 ml-2">({grant.id})</span>
</h3>
<p>{grant.description}</p>
<div className="flex mb-2 items-center">
<Image src="/assets/eth-completed-grant.png" alt="ETH Icon" width={10} height={10} />
<span className="ml-1 tooltip" data-tip="Total amount of the grant">
{grant.askAmount} ETH
</span>
</div>
<p className="m-0">{grant.description}</p>
<p className={`badge ${badgeBgColor[grant.status]}`}>{grant.status}</p>
{grant.status === PROPOSAL_STATUS.APPROVED && (
<button onClick={() => openModal(grant)} className="btn btn-primary float-right">
Expand Down
Loading