diff --git a/packages/foundry/script/DeployDemo.s.sol b/packages/foundry/script/DeployDemo.s.sol index 4876f94..e1f70a6 100644 --- a/packages/foundry/script/DeployDemo.s.sol +++ b/packages/foundry/script/DeployDemo.s.sol @@ -17,7 +17,7 @@ import {ReputationFaucet} from "../contracts/Reputation/ReputationFaucet.sol"; contract DeployDemoScript is ScaffoldETHDeploy { error InvalidPrivateKey(string); - address controller = 0x4161f8A8DfF60aEdB63baFb7d5843b0988393eC9; //replace with burner or other address from wallet! + address controller = 0x778992593f3EA5d47b4Ff19e0347609b98b236D9; //replace with burner or other address from wallet! function run() external { uint256 deployerPrivateKey = setupLocalhostEnv(); diff --git a/packages/nextjs/app/rep-tokens-demo/_components/RepTokensDemo.tsx b/packages/nextjs/app/rep-tokens-demo/_components/RepTokensDemo.tsx index 23a5fd0..1490ed6 100644 --- a/packages/nextjs/app/rep-tokens-demo/_components/RepTokensDemo.tsx +++ b/packages/nextjs/app/rep-tokens-demo/_components/RepTokensDemo.tsx @@ -49,7 +49,7 @@ export function RepTokensDemo() { return ( <> -
+

Faucet

- - - + + + - +

Single Card

@@ -88,20 +84,13 @@ export function RepTokensDemo() { - - - - - + + + + + diff --git a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedAddressCard.tsx b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedAddressCard.tsx index 00af3e7..1b61025 100644 --- a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedAddressCard.tsx +++ b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedAddressCard.tsx @@ -1,22 +1,14 @@ -import { Color } from "./Stylized"; import { Address } from "~~/components/scaffold-eth"; type AddressCardProps = { address: string; - color?: Color; - textColor?: Color; isGroup?: boolean; }; -export const StylizedAddressCard = ({ - address, - color = "slate", - textColor = "black", - isGroup = false, -}: AddressCardProps) => { +export const StylizedAddressCard = ({ address, isGroup = false }: AddressCardProps) => { return ( -
-
+
+
); }; diff --git a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedBalanceCard.tsx b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedBalanceCard.tsx index 0b43bde..639bfbd 100644 --- a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedBalanceCard.tsx +++ b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedBalanceCard.tsx @@ -1,16 +1,13 @@ -import { Color } from "./Stylized"; - type BalanceProps = { value: number; - color?: Color; isOverlay?: boolean; size?: "xs" | "sm" | "base" | "lg" | "xl" | "2xl" | "3xl"; }; const normalSizeMap = { - xs: "2xl", - sm: "4xl", - base: "4xl", + xs: "text-2xl", + sm: "text-4xl", + base: "text-4xl", lg: 9, xl: 10, "2xl": 12, @@ -18,9 +15,9 @@ const normalSizeMap = { }; const overlaidSizeMap = { - xs: "2xl", - sm: "4xl", - base: "9xl", + xs: "text-2xl", + sm: "text-4xl", + base: "text-9xl", lg: 9, xl: 10, "2xl": 12, @@ -37,16 +34,16 @@ const overlaidCardSizeMap = { "3xl": "", }; -export const StylizedBalanceCard = ({ value, color = "slate", isOverlay, size = "base" }: BalanceProps) => { +export const StylizedBalanceCard = ({ value, isOverlay, size = "base" }: BalanceProps) => { let cardClasses; let textClasses; if (isOverlay) { - cardClasses = `absolute ${overlaidCardSizeMap[size]} items-center justify-center`; - textClasses = `text-${overlaidSizeMap[size]} mx-auto text-center text-black`; + cardClasses = `absolute ${overlaidCardSizeMap[size]} items-center justify-center bg-base-300 bg-opacity-75`; + textClasses = `${overlaidSizeMap[size]} mx-auto text-center`; } else { - cardClasses = `rounded-lg bg-${color}-300`; - textClasses = `text-${normalSizeMap[size]} mx-auto text-center text-black`; + cardClasses = `rounded-lg bg-base-300`; + textClasses = `${normalSizeMap[size]} mx-auto text-center`; } return ( diff --git a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedImageCard.tsx b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedImageCard.tsx index d6f2737..eb73d45 100644 --- a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedImageCard.tsx +++ b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedImageCard.tsx @@ -29,15 +29,14 @@ const cardSizeMap = { "3xl": 15, }; -export const StylizedImageCard = ({ - src, - alt = "Token Image", - size = "base", - color = "slate", -}: ImageCardPropsInternal) => { +export const StylizedImageCard = ({ src, alt = "Token Image", size = "base" }: ImageCardPropsInternal) => { return ( -
- {alt} +
+ {src ? ( + {alt} + ) : ( + <> + )}
); }; diff --git a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedStringCard.tsx b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedStringCard.tsx index cab9b33..94d0732 100644 --- a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedStringCard.tsx +++ b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedStringCard.tsx @@ -1,22 +1,19 @@ -import { Color } from "./Stylized"; - type StringProps = { value: string; - color?: Color; type?: "default" | "bold"; }; -export const StylizedStringCard = ({ value, color = "slate", type = "default" }: StringProps) => { +export const StylizedStringCard = ({ value, type = "default" }: StringProps) => { let textClassName; if (type === "default") { - textClassName = "text-black text-1xl mx-auto text-center break-words"; + textClassName = "text-base-content text-1xl mx-auto text-center break-words"; } else if (type === "bold") { - textClassName = "text-black text-1xl mx-auto text-center break-all object-center font-bold"; + textClassName = "text-base-content text-1xl mx-auto text-center break-all object-center font-bold"; } return ( -
+

{value}

); diff --git a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedTokenCard.tsx b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedTokenCard.tsx index 2bbdb8e..ea65aec 100644 --- a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedTokenCard.tsx +++ b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedTokenCard.tsx @@ -1,9 +1,6 @@ -import { Color } from "./Stylized"; - export type Size = "xs" | "sm" | "base" | "lg" | "xl" | "2xl" | "3xl"; export interface TokenCardInternalProps { - color?: Color; size?: Size; children?: React.ReactNode; } @@ -18,8 +15,8 @@ const sizeMap = { "3xl": "", }; -export const StylizedTokenCard = ({ color = "slate", size = "base", children }: TokenCardInternalProps) => { +export const StylizedTokenCard = ({ size = "base", children }: TokenCardInternalProps) => { "rounded-lg bg-slate-600 px-1 py-1 relative w-20"; - return
{children}
; + return
{children}
; }; diff --git a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedTokenGroupCard.tsx b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedTokenGroupCard.tsx index 8969f07..2704c00 100644 --- a/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedTokenGroupCard.tsx +++ b/packages/nextjs/components/rep-tokens/cards/stylized-cards/StylizedTokenGroupCard.tsx @@ -1,5 +1,4 @@ import { BalanceImageOverlay } from "./BalanceImageOverlay"; -import { Color } from "./Stylized"; import { StylizedAddressCard } from "./StylizedAddressCard"; import { StylizedBalanceCard } from "~~/components/rep-tokens/cards/stylized-cards/StylizedBalanceCard"; import { StylizedImageCard } from "~~/components/rep-tokens/cards/stylized-cards/StylizedImageCard"; @@ -9,7 +8,6 @@ import { StylizedTokenCard } from "~~/components/rep-tokens/cards/stylized-cards export interface TokenCardInternalProps { tokens: any[]; components?: ReputationComponent[]; - color?: Color; isBalanceOverlayed?: boolean; size?: "xs" | "sm" | "base" | "lg" | "xl" | "2xl" | "3xl"; children?: React.ReactNode; @@ -47,7 +45,6 @@ export const StylizedTokenGroupCard = ({ "IsRedeemable", "MaxMintAmountPerTx", ], - color = "slate", isBalanceOverlayed, children, size = "base", @@ -142,9 +139,9 @@ export const StylizedTokenGroupCard = ({ } return ( -
+
{children} -
{output}
+
{output}
); }; diff --git a/packages/nextjs/components/scaffold-eth/Address.tsx b/packages/nextjs/components/scaffold-eth/Address.tsx index fc89a15..1c1ad60 100644 --- a/packages/nextjs/components/scaffold-eth/Address.tsx +++ b/packages/nextjs/components/scaffold-eth/Address.tsx @@ -2,7 +2,6 @@ import { useEffect, useState } from "react"; import Link from "next/link"; -import { Color } from "../rep-tokens/cards/stylized-cards/Stylized"; import { CopyToClipboard } from "react-copy-to-clipboard"; import { Address as AddressType, getAddress, isAddress } from "viem"; import { hardhat } from "viem/chains"; @@ -17,7 +16,6 @@ type AddressProps = { disableAddressLink?: boolean; format?: "short" | "long"; size?: "xs" | "sm" | "base" | "lg" | "xl" | "2xl" | "3xl"; - textColor?: Color; }; const blockieSizeMap = { @@ -33,7 +31,7 @@ const blockieSizeMap = { /** * Displays an address (or ENS) with a Blockie image and option to copy address. */ -export const Address = ({ address, disableAddressLink, format, size = "base", textColor = "white" }: AddressProps) => { +export const Address = ({ address, disableAddressLink, format, size = "base" }: AddressProps) => { const [ens, setEns] = useState(); const [ensAvatar, setEnsAvatar] = useState(); const [addressCopied, setAddressCopied] = useState(false); @@ -97,14 +95,14 @@ export const Address = ({ address, disableAddressLink, format, size = "base", te />
{disableAddressLink ? ( - {displayAddress} + {displayAddress} ) : targetNetwork.id === hardhat.id ? ( - + {displayAddress} ) : (