WIP
This commit is contained in:
parent
95d1bfae6b
commit
e5c1a26d20
|
@ -6,6 +6,7 @@ import { Charity } from '../../../common/charity'
|
||||||
import { useCharityTxns } from '../../hooks/use-charity-txns'
|
import { useCharityTxns } from '../../hooks/use-charity-txns'
|
||||||
import { manaToUSD } from '../../pages/charity/[charitySlug]'
|
import { manaToUSD } from '../../pages/charity/[charitySlug]'
|
||||||
import { Row } from '../layout/row'
|
import { Row } from '../layout/row'
|
||||||
|
import { TagsList } from '../tags-list'
|
||||||
|
|
||||||
export function CharityCard(props: { charity: Charity }) {
|
export function CharityCard(props: { charity: Charity }) {
|
||||||
const { name, slug, photo, preview, id, tags } = props.charity
|
const { name, slug, photo, preview, id, tags } = props.charity
|
||||||
|
@ -41,6 +42,11 @@ export function CharityCard(props: { charity: Charity }) {
|
||||||
<span>raised</span>
|
<span>raised</span>
|
||||||
</Row>
|
</Row>
|
||||||
)}
|
)}
|
||||||
|
<TagsList
|
||||||
|
tags={tags.filter((tag) => tag !== 'Featured')}
|
||||||
|
noLabel
|
||||||
|
noLink
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</Link>
|
</Link>
|
||||||
|
|
|
@ -1,11 +1,16 @@
|
||||||
import _ from 'lodash'
|
import _ from 'lodash'
|
||||||
import { useState, useMemo } from 'react'
|
import { useState, useMemo } from 'react'
|
||||||
import { charities, Charity as CharityType } from '../../../common/charity'
|
import {
|
||||||
|
charities,
|
||||||
|
Charity as CharityType,
|
||||||
|
mainTags,
|
||||||
|
} from '../../../common/charity'
|
||||||
import { CharityCard } from '../../components/charity/charity-card'
|
import { CharityCard } from '../../components/charity/charity-card'
|
||||||
import { Col } from '../../components/layout/col'
|
import { Col } from '../../components/layout/col'
|
||||||
import { Spacer } from '../../components/layout/spacer'
|
import { Spacer } from '../../components/layout/spacer'
|
||||||
import { Page } from '../../components/page'
|
import { Page } from '../../components/page'
|
||||||
import { SiteLink } from '../../components/site-link'
|
import { SiteLink } from '../../components/site-link'
|
||||||
|
import { TagsList } from '../../components/tags-list'
|
||||||
import { Title } from '../../components/title'
|
import { Title } from '../../components/title'
|
||||||
import { getAllCharityTxns } from '../../lib/firebase/txns'
|
import { getAllCharityTxns } from '../../lib/firebase/txns'
|
||||||
|
|
||||||
|
@ -65,6 +70,8 @@ export default function Charity(props: {
|
||||||
placeholder="Search charities"
|
placeholder="Search charities"
|
||||||
className="input input-bordered mb-6 w-full"
|
className="input input-bordered mb-6 w-full"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
<TagsList tags={mainTags as unknown as string[]} noLink />
|
||||||
</Col>
|
</Col>
|
||||||
<div className="grid max-w-xl grid-flow-row grid-cols-1 gap-4 lg:max-w-full lg:grid-cols-2 xl:grid-cols-3">
|
<div className="grid max-w-xl grid-flow-row grid-cols-1 gap-4 lg:max-w-full lg:grid-cols-2 xl:grid-cols-3">
|
||||||
{filterCharities.map((charity) => (
|
{filterCharities.map((charity) => (
|
||||||
|
|
Loading…
Reference in New Issue
Block a user