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

Projects #292

Merged
merged 28 commits into from
Jan 8, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
41585a3
Adjusted styling
namedotget Dec 31, 2024
8c0b0e4
Refactor
namedotget Dec 31, 2024
c5b888b
Added note w/ hat tree links
namedotget Dec 31, 2024
5b31d2f
Started adding project pages, wip
namedotget Dec 31, 2024
47ea56c
wip
namedotget Jan 3, 2025
0b5a32f
Refactor section card
namedotget Jan 3, 2025
ba77419
Started implementing new design for /rewards
namedotget Jan 3, 2025
d625553
wip
namedotget Jan 6, 2025
11624f2
Merged ng-retro
namedotget Jan 6, 2025
63778bb
Refactor
namedotget Jan 6, 2025
2369db2
Added and updated abis
namedotget Jan 6, 2025
145a159
Added project data to useProjectData
namedotget Jan 6, 2025
1af7f25
Added assets'
namedotget Jan 6, 2025
7125345
Adjusted project profile and projects page, added project data
namedotget Jan 6, 2025
5790697
Fixed input unfocus bug
namedotget Jan 7, 2025
5fe73ac
Added project addresses for sepolia
namedotget Jan 7, 2025
d13264b
Refactored to pull project data from tableland entry rather than nft
namedotget Jan 7, 2025
cf97900
Removed unused import
namedotget Jan 7, 2025
cf9fdf0
Retroactive Rewards
namedotget Jan 7, 2025
312f731
Removed outline on focus for Search
namedotget Jan 7, 2025
c6d5913
Added isActive check for projects
namedotget Jan 7, 2025
0c785ce
Added project hat tree id for sepolia
namedotget Jan 7, 2025
4b15204
Added isActive check for project data
namedotget Jan 7, 2025
2bf76ac
Reconfigured project pages to use a tableland entry instead of an NFT
namedotget Jan 7, 2025
f98695c
Merged main
namedotget Jan 7, 2025
1fdd5d8
Added isActive check
namedotget Jan 8, 2025
d1e8b98
Added redirect for /projects => /project
namedotget Jan 8, 2025
dbab4fc
Changed 'Inactive' tab label to 'Past'
namedotget Jan 8, 2025
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 ui/components/layout/Search.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default function Search({ input, setInput }: any) {
<div id="input-field-container" className="">
<Frame noPadding marginBottom="0px">
<input
className="w-full rounded-sm px-4 pt-2 pb-4 bg-dark-cool text-white placeholder:text-grey"
className="w-full rounded-sm px-4 pt-2 pb-4 bg-dark-cool text-white placeholder:text-grey outline-none"
onChange={({ target }) => setInput(target.value)}
value={input}
type="text"
Expand Down
2 changes: 1 addition & 1 deletion ui/components/project/ProjectCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const ProjectCardContent = memo(
return (
<div
id="card-container"
className="animate-fadeIn flex flex-col gap-2 relative bg-dark-cool w-full h-full"
className="animate-fadeIn p-4 flex flex-col gap-2 relative bg-dark-cool w-full h-full rounded-2xl"
>
<div className="flex justify-between">
<h1 className="font-GoodTimes">{project?.name || ''}</h1>
Expand Down
11 changes: 9 additions & 2 deletions ui/const/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -194,13 +194,20 @@ export const TEAM_DISCOUNTLIST_ADDRESSES: Index = {
sepolia: '',
}

//Sepolia Hat Tree : https://app.hatsprotocol.xyz/trees/11155111/386
//Arbitrum Hat Tree : https://app.hatsprotocol.xyz/trees/42161/42
//Citzens & Teams Sepolia Hat Tree : https://app.hatsprotocol.xyz/trees/11155111/386
//Citizens & Teams Arbitrum Hat Tree : https://app.hatsprotocol.xyz/trees/42161/42
export const MOONDAO_HAT_TREE_IDS: Index = {
arbitrum: '0x0000002a',
sepolia: '0x00000182',
}

//Projects Sepolia Hat Tree : https://app.hatsprotocol.xyz/trees/11155111/729
//ProjectsArbitrum Hat Tree :
export const PROJECT_HAT_TREE_IDS: Index = {
arbitrum: '',
sepolia: '0x000002d9',
}

export const JOBS_TABLE_ADDRESSES: Index = {
arbitrum: '0x94e225DDe1b3E5f861222ca2055739BA12730bd4',
sepolia: '0x5b26100ae7F244f6805D724A019927E137978659',
Expand Down
6 changes: 5 additions & 1 deletion ui/lib/project/useProjectData.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ export default function useProjectData(
[project?.id || '']
)

const isActive = useMemo(() => {
return project?.active === 1
}, [project])

const totalBudget = useMemo(() => {
let budget = 0
if (nanceProposal?.actions && nanceProposal.actions.length > 0) {
Expand Down Expand Up @@ -91,7 +95,6 @@ export default function useProjectData(
useEffect(() => {
async function getHatTreeId() {
const hatTreeId = await hatsContract.call('getTopHatDomain', [adminHatId])

setHatTreeId(hatTreeId)
}
if (hatsContract && adminHatId) getHatTreeId()
Expand All @@ -100,6 +103,7 @@ export default function useProjectData(
return {
...project,
isManager,
isActive,
hatTreeId,
adminHatId,
managerHatId,
Expand Down
7 changes: 6 additions & 1 deletion ui/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -212,12 +212,17 @@ module.exports = nextTranslate({
source: '/propose',
destination: '/submit?tag=proposal',
permanent: true,
},
},
{
source: '/teams',
destination: '/network?tab=teams',
permanent: true,
},
{
source: '/projects',
destination: '/project',
permanent: true,
},
]
},
webpack: (config, { isServer }) => {
Expand Down
Loading
Loading