1- import { Box , Flex , Text } from '@zoralabs/zord'
1+ import { Box , Flex , Grid , Text } from '@zoralabs/zord'
22import HtmlReactParser from 'html-react-parser'
33import { getFetchableUrl } from 'ipfs-service'
44import Image from 'next/legacy/image'
@@ -11,19 +11,22 @@ import { CHAIN } from 'src/constants/network'
1111import SWR_KEYS from 'src/constants/swrKeys'
1212import { metadataAbi , tokenAbi } from 'src/data/contract/abis'
1313import { sdk } from 'src/data/graphql/client'
14+ import { useLayoutStore } from 'src/stores'
1415import { about , daoDescription , daoInfo , daoName } from 'src/styles/About.css'
1516import { unpackOptionalArray } from 'src/utils/helpers'
1617import { formatCryptoVal } from 'src/utils/numbers'
1718
1819import { useDaoStore } from '../../stores'
1920import { parseContractURI } from '../../utils'
2021import { ExternalLinks } from './ExternalLinks'
22+ import { Founder } from './Founder'
2123import { Statistic } from './Statistic'
2224
2325export const About : React . FC = ( ) => {
2426 const {
2527 addresses : { token, treasury, metadata } ,
2628 } = useDaoStore ( )
29+ const { isMobile } = useLayoutStore ( )
2730
2831 const tokenContractParams = {
2932 abi : tokenAbi ,
@@ -38,16 +41,15 @@ export const About: React.FC = () => {
3841 contracts : [
3942 { ...tokenContractParams , functionName : 'name' } ,
4043 { ...tokenContractParams , functionName : 'totalSupply' } ,
44+ { ...tokenContractParams , functionName : 'getFounders' } ,
4145 { ...metadataContractParams , functionName : 'contractImage' } ,
4246 { ...metadataContractParams , functionName : 'description' } ,
4347 { ...metadataContractParams , functionName : 'contractURI' } ,
4448 ] ,
4549 } )
4650
47- const [ name , totalSupply , daoImage , description , contractURI ] = unpackOptionalArray (
48- contractData ,
49- 5
50- )
51+ const [ name , totalSupply , founders , daoImage , description , contractURI ] =
52+ unpackOptionalArray ( contractData , 6 )
5153 const parsedContractURI = parseContractURI ( contractURI )
5254
5355 const { data : balance } = useBalance ( { address : treasury as Address } )
@@ -133,6 +135,19 @@ export const About: React.FC = () => {
133135 >
134136 < ExternalLinks links = { { website : parsedContractURI ?. external_url } } />
135137 </ Box >
138+
139+ { typeof founders !== 'undefined' && founders . length > 0 ? (
140+ < >
141+ < Text variant = "heading-xs" mt = "x16" style = { { fontWeight : 800 } } >
142+ Founders
143+ </ Text >
144+ < Grid columns = { isMobile ? 1 : 2 } mt = "x6" gap = "x4" >
145+ { founders . map ( ( founder ) => (
146+ < Founder { ...founder } />
147+ ) ) }
148+ </ Grid >
149+ </ >
150+ ) : null }
136151 </ Box >
137152 )
138153}
0 commit comments