-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: brands icons and stk template (#37)
* feat: added brands logic * feat: added brand icons for lido and etherfi * feat: added stk logic * fix: added usds asset
- Loading branch information
Showing
73 changed files
with
717 additions
and
288 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
"use client"; | ||
|
||
import { githubIconsPath } from "@bgd-labs/react-web3-icons/dist/constants"; | ||
import { | ||
IconInfoIcons, | ||
IconVariant, | ||
} from "@bgd-labs/react-web3-icons/dist/utils"; | ||
import { useState } from "react"; | ||
|
||
import { IconCard } from "@/components/IconCard"; | ||
import { BrandIcon } from "@/components/Web3Icons/BrandIcon"; | ||
|
||
export const BrandIconCard = ({ | ||
name, | ||
icons, | ||
}: { | ||
name: string; | ||
icons: IconInfoIcons; | ||
}) => { | ||
const [variant, setVariant] = useState(IconVariant.Full); | ||
return ( | ||
<IconCard | ||
svgPath={`${githubIconsPath}/${icons[variant]}`} | ||
name={name} | ||
subName={""} | ||
fileName={name} | ||
setActiveType={setVariant} | ||
activeType={variant} | ||
> | ||
<BrandIcon addressOrName={name} mono={variant === IconVariant.Mono} /> | ||
</IconCard> | ||
); | ||
}; |
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,34 @@ | ||
"use client"; | ||
|
||
import { BrandIcon as BI } from "@bgd-labs/react-web3-icons"; | ||
import { ExternalComponentBaseProps } from "@bgd-labs/react-web3-icons/dist/utils/index"; | ||
|
||
import { cn } from "@/utils/cn"; | ||
|
||
interface BrandIconProps extends ExternalComponentBaseProps { | ||
addressOrName: string; | ||
} | ||
/** | ||
* Renders a wallet icon specified by walletName. | ||
*/ | ||
export const BrandIcon = ({ | ||
addressOrName, | ||
className, | ||
...props | ||
}: BrandIconProps) => { | ||
return ( | ||
<BI | ||
addressOrName={addressOrName} | ||
className={cn("size-[70px]", className)} | ||
loader={ | ||
<div | ||
className={cn( | ||
"size-[70px] animate-pulse rounded-full bg-brand-300", | ||
className, | ||
)} | ||
/> | ||
} | ||
{...props} | ||
/> | ||
); | ||
}; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.