forked from ZuzaluSoftwareBuilder/ZuzaluCityOS
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Feat/milestone trustful zuzalu d app interface #18
Open
heronlancellot
wants to merge
140
commits into
main
Choose a base branch
from
feat/milestone-trustful-zuzalu-dApp-interface
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
140 commits
Select commit
Hold shift + click to select a range
60ca27c
feat: add trustful-context
heronlancellot 7393c2d
feat: add getUserRole & update Role interface
heronlancellot b4ffd17
feat: add railway-trustful into .env
heronlancellot 14d4e21
update: throw new error getUserRole
heronlancellot 3c95c23
Merge pull request #1 from heronlancellot/feat/create-context-trustful
heronlancellot 3875c05
feat: add capitalizeFirstLetter utils
heronlancellot bc4aa58
feat: add new type to Role ( No_Role ) && add spaceId enabled for tru…
heronlancellot d4074c0
feat: add TrustfulIcon
heronlancellot 359727f
feat: add trustful-page
heronlancellot 608e38b
update: application space-Id constant
heronlancellot 0b36d0c
feat: add address into dependence array
heronlancellot a87c421
Merge pull request #2 from heronlancellot/feat/welcome-text-role
heronlancellot e91051c
feat: add give-badge section into reputation badge
heronlancellot 0b8eb12
refactor: unused code
heronlancellot 128113d
fix: remove unused structure
heronlancellot 2a4ff0a
refactor: unused code
heronlancellot 7bf89cd
update: give-badge
heronlancellot 54bc546
fix: remove unused code
heronlancellot 3f0881c
Merge pull request #4 from heronlancellot/feat/give-badge
heronlancellot d9e5860
fea: add share page
heronlancellot e27aec3
Merge pull request #5 from heronlancellot/feat/share
heronlancellot 9bb134f
update: constants addressess
heronlancellot c221e4f
update: schemas name & variables & add new my-badges components
heronlancellot ab56c95
update: my-badges
heronlancellot 36c8734
Merge pull request #6 from heronlancellot/feat/my-badges
heronlancellot 257a148
feat: add my-badge details
heronlancellot 2373735
Merge pull request #7 from heronlancellot/feat/my-badge-details
heronlancellot 22ff5e3
feat: add smart-contract functions
heronlancellot a401eb4
update: icons with calendarTimeIcon
heronlancellot 3f158f2
Merge pull request #8 from heronlancellot/feat/smart-contract-functions
heronlancellot 92584e0
fix(qrcode): correctly set query parameter value in input field
hawkjr97 987ded9
feat: add admin section
heronlancellot 94fd7a5
update villager bytes32
heronlancellot 4996654
refactor: code improvement
heronlancellot 55af5d2
update: reveokeRole
heronlancellot 79a1791
feat: add admin-icon
heronlancellot 76588da
update: index trustful service
heronlancellot 882c8a2
update: abi & constants
heronlancellot 5bbd13e
update: attest function
heronlancellot 322f5fd
fix: attest & remove gasLimit
heronlancellot 9f9de7e
Merge pull request #9 from hawkjr97/fix/shared-qrcode
heronlancellot d3ddbc2
Merge branch 'feat/milestone-trustful-zuzalu-dApp-interface' into fea…
heronlancellot 8c90558
update: service smart-contract calls
heronlancellot 72e16c4
feat: add new folder backend & smart-contracts service folder to mana…
heronlancellot df52d02
update: footer-navbar
heronlancellot ca76c20
update: dropdown-menu-admin
heronlancellot ed6372c
Merge pull request #10 from heronlancellot/feat/component-admin
heronlancellot aea2234
feat: add api calls backend
heronlancellot e4e36a5
update contract addressess & villager options
heronlancellot 4f310b0
fix: userRole & getUserRole error
heronlancellot a3d7afb
update: dropdown-menu-admin
heronlancellot 6afc149
fix: ui options admin-dropdown
heronlancellot 202a6af
fix: comment checkout footer
heronlancellot 3d46541
feat: add new functinos & update settings
heronlancellot 3e776b6
update: service backend calls
heronlancellot cb8cfdb
update: dropdown-menu-admin
heronlancellot 2fde866
fix: remove old contract zuzalu
heronlancellot b750877
Merge pull request #11 from heronlancellot/feat/service-api-backend-f…
heronlancellot 608dd93
feat: add events footer
heronlancellot 115506f
feat: add new pages trustful events - session
heronlancellot 66d9360
feat: add services & create event card
heronlancellot 95d3d52
update: backend-service functions
heronlancellot 2d5b6cd
feat: add new pages & update data & calls
heronlancellot c369c0e
fix: error attest-response
heronlancellot a1404de
update: api-call-service & remove unused files
heronlancellot e10fce7
refactor: implement new style
hawkjr97 fdb0405
Merge pull request #1 from hawkjr97/feat/add-new-pages-fluxe-ui-user
heronlancellot 3794d65
Merge branch 'feat/add-new-pages-fluxe-ui-user' of https://github.com…
heronlancellot 8d9f584
fix: integration create event
hawkjr97 3d02d1a
Merge pull request #2 from hawkjr97/feat/add-new-pages-fluxe-ui-user
heronlancellot ec50c74
Merge pull request #12 from heronlancellot/feat/add-new-pages-fluxe-u…
heronlancellot 23e8e06
refactor: implement new theme provider
hawkjr97 d2ae6aa
Merge pull request #14 from hawkjr97/refactor/dapp-style-badges
heronlancellot 5bea4ee
fix: select text color
heronlancellot a5382c0
fix: style
heronlancellot c14a454
fix: createEvent type
heronlancellot 10d03e1
update: create-event inputs
heronlancellot 4fca0b5
fix: remove unused code
heronlancellot 39ca8bd
fix: create-session
heronlancellot 2ff09a1
fix: duplicated revoke-role
heronlancellot a302ac0
feat: add create-session
heronlancellot 070d73f
fix: dropdown only with creat session
heronlancellot 2335846
update events session
heronlancellot 83ae9fa
feat: add card-sessions
heronlancellot 87fc8ac
update: get-sessions & fix useEffect order
heronlancellot 14caad2
update: dropdown-session details
heronlancellot 409d211
update: dropdown-session-details import
heronlancellot 2c87c18
Merge pull request #15 from heronlancellot/feat/application-improvements
heronlancellot b7653c5
update:card-sessions
heronlancellot 112a106
update:card-sessions-details order
heronlancellot 3f07b6f
feat:add badge special
heronlancellot 1a5203c
feat:add badge special
heronlancellot a47811d
feat:add badge special
heronlancellot ee3fdb9
fix: correctly fetch and display badges in dropdown based on user rol…
hawkjr97 4355bfd
Merge pull request #3 from hawkjr97/fix/badge-special
heronlancellot a18639c
Merge pull request #16 from heronlancellot/fix/badge-special
heronlancellot b18e9d5
fix: remove all console.log
heronlancellot ddd3516
feat: add home-icon
heronlancellot 6e16cb0
refactor: unused code & update imports & refactor variable names
heronlancellot 855589c
Merge pull request #17 from heronlancellot/feat/milestone-trustful-zu…
heronlancellot 6f6956c
Update .env.example
heronlancellot 96718fc
update: action-options
heronlancellot cd776da
Update theme/lib/chakra-ui.ts
heronlancellot 306b12b
Update app/spaces/[spaceid]/trustful/share/components/index.ts
heronlancellot bd9bc95
fix: remove use-ens-data
heronlancellot f954ebf
Merge branch 'blockful-io:feat/milestone-trustful-zuzalu-dApp-interfa…
heronlancellot 37547d8
Update app/spaces/[spaceid]/trustful/service/backend/getAllEventsBySp…
heronlancellot dff3e62
Update app/spaces/[spaceid]/trustful/service/smart-contract/cannotRep…
heronlancellot 64ab8e1
update: dropdown-menu-admin
heronlancellot be52da9
Merge branch 'blockful-io:feat/milestone-trustful-zuzalu-dApp-interfa…
heronlancellot 8466ff3
fix: variable improvement
heronlancellot 47659ee
Merge branch 'feat/milestone-trustful-zuzalu-dApp-interface' of https…
heronlancellot ca27563
Merge pull request #19 from heronlancellot/feat/milestone-trustful-zu…
heronlancellot d01061e
update: the-footer-navbar
heronlancellot 8093584
fix: path undefined
heronlancellot 2a5dbd3
update: admin-section footer
heronlancellot d2d63af
fix: unused code
heronlancellot eb9240f
refactor: remove unused code
heronlancellot 0e448a6
fix: remove fetch-ens-data
heronlancellot 27c6b02
update: dropdown-events
heronlancellot 18672b6
Merge branch 'blockful-io:feat/milestone-trustful-zuzalu-dApp-interfa…
heronlancellot db9d97d
Merge pull request #20 from heronlancellot/feat/milestone-trustful-zu…
heronlancellot f01fc3e
update: events style
heronlancellot 768689b
update session style
heronlancellot 9eeaea9
update session style dropdown
heronlancellot f763196
Merge branch 'feat/milestone-trustful-zuzalu-dApp-interface' of https…
heronlancellot be7bde8
Merge pull request #21 from heronlancellot/feat/milestone-trustful-zu…
heronlancellot 6b1f4f4
Merge branch 'main' into feat/milestone-trustful-zuzalu-dApp-interface
heronlancellot abdf290
Merge pull request #23 from heronlancellot/feat/milestone-trustful-zu…
heronlancellot 62d996e
update: spaceid correctly
heronlancellot 2c12c18
update: correctly zero-address bytes32 - givebadge
heronlancellot 6282825
Merge branch 'feat/milestone-trustful-zuzalu-dApp-interface' of https…
heronlancellot 8f5ae3f
update: spaceid-url-share-link
heronlancellot 8a1a64c
Merge pull request #24 from heronlancellot/feat/milestone-trustful-zu…
heronlancellot c3590a6
fix: improve layout responsiveness and styling adjustments
hawkjr97 6aa48d5
Merge pull request #1 from hawkjr97/refactor/dapp-style-badge-details
hawkjr97 c47e5a9
refactor: improve toast design
hawkjr97 535f336
update:trustful-context
heronlancellot ce01a47
Merge pull request #5 from hawkjr97/refactor/toast
heronlancellot a441d32
Merge pull request #25 from heronlancellot/feat/milestone-trustful-zu…
heronlancellot File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
45 changes: 45 additions & 0 deletions
45
app/spaces/[spaceid]/trustful/admin/components/AdminSection.tsx
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,45 @@ | ||
'use client'; | ||
|
||
/* eslint-disable react-hooks/exhaustive-deps */ | ||
import { useEffect } from 'react'; | ||
import { useParams, useRouter } from 'next/navigation'; | ||
import { useAccount } from 'wagmi'; | ||
import toast from 'react-hot-toast'; | ||
import { DropdownMenuAdmin } from '@/app/spaces/[spaceid]/trustful/admin/components'; | ||
import { Box, ChakraProvider } from '@chakra-ui/react'; | ||
import { TheFooterNavbar } from '@/app/spaces/[spaceid]/trustful/components'; | ||
import chakraTheme from '@/theme/lib/chakra-ui'; | ||
|
||
export const AdminSection = () => { | ||
const { address, chain } = useAccount(); | ||
const { push } = useRouter(); | ||
const params = useParams(); | ||
|
||
const actualURL = `/spaces/${params.spaceid}/trustful`; | ||
|
||
// const { villagerAttestationCount } = useContext(WalletContext); | ||
const villagerAttestationCount = Number(1); | ||
|
||
useEffect(() => { | ||
if (villagerAttestationCount === 0) { | ||
heronlancellot marked this conversation as resolved.
Show resolved
Hide resolved
|
||
toast.error( | ||
<span className="flex flex-col"> | ||
<strong>You have not checked in.</strong>{' '} | ||
<p>Please check-in first.</p> | ||
</span>, | ||
); | ||
push('/pre-checkin'); | ||
} | ||
}, [villagerAttestationCount]); | ||
|
||
return ( | ||
<div> | ||
<ChakraProvider theme={chakraTheme}> | ||
<DropdownMenuAdmin /> | ||
</ChakraProvider> | ||
<Box className="fixed bottom-0 left-1/2 transform -translate-x-1/2 w-full items-center"> | ||
<TheFooterNavbar /> | ||
</Box> | ||
</div> | ||
); | ||
}; |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to be an open TODO