Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
115 commits
Select commit Hold shift + click to select a range
cd0eb3b
update config: update config of wallet.pay.brussels to include sessio…
SajeeTechi Apr 16, 2025
a67faec
remove deprecated env
SajeeTechi Apr 16, 2025
2be1e56
auth page with email signin option
SajeeTechi Apr 16, 2025
b4de95a
install shadcn form
SajeeTechi Apr 16, 2025
0e06349
email form
SajeeTechi Apr 16, 2025
4117d2a
update @citizenwallet/sdk
SajeeTechi Apr 16, 2025
2bb5f05
util functions for cw session
SajeeTechi Apr 16, 2025
aa87382
email form submission action
SajeeTechi Apr 16, 2025
89826fa
base url of cw session project
SajeeTechi Apr 16, 2025
0bd0a9c
rename env
SajeeTechi Apr 16, 2025
06fc7a5
remove logs
SajeeTechi Apr 16, 2025
13e968e
- submit email form to get challenge
SajeeTechi Apr 16, 2025
ff47beb
shadcn input otp
SajeeTechi Apr 17, 2025
45d8515
minor
SajeeTechi Apr 17, 2025
94ac9f6
disable email field when submitting
SajeeTechi Apr 17, 2025
f96e3cc
otp input page and form
SajeeTechi Apr 17, 2025
2e95671
minor
SajeeTechi Apr 17, 2025
8e55478
prettier formatting config
SajeeTechi Apr 17, 2025
9b17a78
prettier format code
SajeeTechi Apr 17, 2025
c41ad21
back navigation from /signin/email/otp
SajeeTechi Apr 17, 2025
e1c087b
zustand state for session
SajeeTechi Apr 17, 2025
02134f9
local storage keys
SajeeTechi Apr 17, 2025
0d5bb34
use function from cw sdk to await for tx success
SajeeTechi Apr 17, 2025
c444d15
save variables in state and get account address
SajeeTechi Apr 17, 2025
b47a9a4
modify accessing session state
SajeeTechi Apr 17, 2025
ab40db2
submit otp form
SajeeTechi Apr 17, 2025
f47e141
navigate to /address after session confirm success
SajeeTechi Apr 17, 2025
62182ed
'isSessionExpired' function
SajeeTechi Apr 20, 2025
9f87520
comments
SajeeTechi Apr 20, 2025
13fe1f1
fix build errors
SajeeTechi Apr 20, 2025
2496bb9
prettier formatting
SajeeTechi Apr 20, 2025
984342c
Merge pull request #10 from citizenwallet/feature/auth-selection-email
SajeeTechi Apr 20, 2025
d90e441
passkey compatibility check
SajeeTechi Apr 20, 2025
4fe243d
env for passkeys
SajeeTechi Apr 20, 2025
7b597c6
integrate passkey registration and authentication
SajeeTechi Apr 21, 2025
c501792
new local storage keys
SajeeTechi Apr 23, 2025
84dc85b
- signin with passkey and create account address
SajeeTechi Apr 23, 2025
51b866a
prettier format
SajeeTechi Apr 23, 2025
240fca9
Merge pull request #11 from citizenwallet/feature/auth-selection-passkey
SajeeTechi Apr 23, 2025
2cb5a39
router replace
SajeeTechi Apr 25, 2025
1dd7a12
lowercase keys of local storage
SajeeTechi Apr 25, 2025
916754e
offer signin with local account
SajeeTechi Apr 25, 2025
2ea2ff6
prettier format
SajeeTechi Apr 25, 2025
385317f
Merge pull request #12 from citizenwallet/feature-auth-selection/loca…
SajeeTechi Apr 25, 2025
889a35b
move signin to root
SajeeTechi Apr 25, 2025
9c8b57a
hook to determine account address and auth method
SajeeTechi Apr 25, 2025
7522ff3
offer sign-in options in root
SajeeTechi Apr 25, 2025
c45ae89
hook to determine signin-in method and account address
SajeeTechi Apr 28, 2025
d8d8889
deeplink signin with v3 local format
SajeeTechi Apr 28, 2025
2b507d9
prettier formatting
SajeeTechi Apr 28, 2025
22d77f1
Merge pull request #13 from citizenwallet/feature-auth-selection/move…
SajeeTechi Apr 28, 2025
e098a5b
eval read-only mode for local sign-in
SajeeTechi Apr 28, 2025
58f5e6a
remove wallet container
SajeeTechi Apr 28, 2025
bf7367f
remove dev tools middleware
SajeeTechi Apr 28, 2025
a48d8a4
re-initialise session store
SajeeTechi Apr 28, 2025
a9f73f8
-reinit session store
SajeeTechi Apr 28, 2025
a549597
eval session expiration for email and passkey signins
SajeeTechi Apr 28, 2025
f1948d9
redirect logic
SajeeTechi Apr 28, 2025
2b55e7c
prettier formatting
SajeeTechi Apr 28, 2025
d811da1
Merge pull request #14 from citizenwallet/feature-auth-selection/eval…
SajeeTechi Apr 28, 2025
1797d68
remove unnecessary
SajeeTechi Apr 28, 2025
873b039
page to signout of auth method
SajeeTechi Apr 29, 2025
c4fa464
corection
SajeeTechi Apr 29, 2025
6ef831f
delete key function
SajeeTechi Apr 29, 2025
0936bef
correction
SajeeTechi Apr 29, 2025
d1c909e
signout for auth methods email and passkeys
SajeeTechi Apr 29, 2025
3bec07f
logout of local account
SajeeTechi Apr 29, 2025
f73af20
prettier format
SajeeTechi Apr 29, 2025
27c95f2
Merge pull request #15 from citizenwallet/feature-auth-selection/logout
SajeeTechi Apr 29, 2025
ff77f5d
remove signout page
SajeeTechi Apr 29, 2025
80ed4d8
relocate signout to '/profile/[address]'
SajeeTechi Apr 29, 2025
3bdb192
edit styling of signout button
SajeeTechi Apr 29, 2025
e46799c
Merge pull request #16 from citizenwallet/feature-auth-selection/relo…
SajeeTechi Apr 29, 2025
6a8774b
disable send button when send is in progress
SajeeTechi Apr 29, 2025
b107229
todo
SajeeTechi Apr 29, 2025
1240d64
todo
SajeeTechi Apr 29, 2025
b1d5878
resolve account address from 0x or username
SajeeTechi Apr 29, 2025
208f783
local account for session based and local accounts
SajeeTechi Apr 29, 2025
e53802f
server action to resolve account address from username or ENS domain
SajeeTechi Apr 29, 2025
23ac6b9
Merge pull request #17 from citizenwallet/feature-auth-selection/reso…
SajeeTechi Apr 29, 2025
d881153
root loading state
SajeeTechi Apr 29, 2025
5a12d99
clear state on signout
SajeeTechi Apr 29, 2025
5f77f34
use session util functions from sdk
SajeeTechi May 5, 2025
93e01df
prettier format
SajeeTechi May 5, 2025
3c370ec
Merge branch 'main' into feature/auth-selection
SajeeTechi May 5, 2025
e4db34d
prettier format
SajeeTechi May 5, 2025
02b2f0c
adapt change of generateConnectionMessage in local signin
SajeeTechi May 7, 2025
d9dc6ee
TODO
SajeeTechi May 7, 2025
c591ae6
new key for storage
SajeeTechi May 7, 2025
51db1c9
remove log
SajeeTechi May 7, 2025
61a6005
bugfix infinite render
SajeeTechi May 7, 2025
b6cc609
save deeplink to handle later
SajeeTechi May 7, 2025
01a603a
handle deeplink on mount
SajeeTechi May 7, 2025
cd8768b
restore communities.local from main
SajeeTechi May 7, 2025
d2f9710
test for parsing QR code and data
SajeeTechi May 7, 2025
1b94f58
handle sendTo QR for on deeplink
SajeeTechi May 7, 2025
ae9d09c
add session manager to some configs
SajeeTechi May 8, 2025
b7b76ae
update community configs with session manager info
SajeeTechi May 8, 2025
dd6bd2b
update package @citizenwallet/sdk
SajeeTechi May 8, 2025
80a42f7
refactor(auth): make relying party ID dynamic based on origin domain
SajeeTechi May 20, 2025
21781ce
feat(auth): local account signout UX
SajeeTechi May 22, 2025
fb31941
bugfix: voucher URLs were making local accounts on deeplink
SajeeTechi May 23, 2025
1eec3e4
bump communities with cw-safe paymasters
kevtechi May 26, 2025
6208e99
replace importing namespace
SajeeTechi May 26, 2025
1dc23d2
move test file to js-sdk
SajeeTechi May 26, 2025
85ffd8c
replace useState with state store attributes
SajeeTechi May 26, 2025
7d221de
evaluate auth session in session store
SajeeTechi May 27, 2025
69fc84c
state attributes for evaluating auth session
SajeeTechi May 27, 2025
01dcbc3
evaluate auth session and return early if possible
SajeeTechi May 27, 2025
8e8a613
use session action to eval auth session
SajeeTechi May 27, 2025
bfad420
use session action to eval auth session
SajeeTechi May 27, 2025
03ba515
use session action to eval auth session
SajeeTechi May 27, 2025
3a3147b
deprecate sign-in hook
SajeeTechi May 27, 2025
b9d33ae
backup modal only visible to local account type
SajeeTechi Jun 4, 2025
04514a0
create local account url correctly
SajeeTechi Jun 4, 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
12 changes: 12 additions & 0 deletions . prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"semi": true,
"trailingComma": "es5",
"singleQuote": true,
"tabWidth": 2,
"useTabs": false,
"printWidth": 100,
"bracketSpacing": true,
"arrowParens": "always",
"endOfLine": "lf",
"plugins": ["prettier-plugin-tailwindcss"]
}
3 changes: 2 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ NEXT_PUBLIC_REOWN_PROJECT_ID="x"
# Gnosis Scan
NEXT_PUBLIC_GNOSIS_SCAN_API_KEY='x'

NEXT_PUBLIC_APP_BASE_URL='https://gratitude.citizenwallet.xyz'
# CW Session
NEXT_PUBLIC_CW_SESSION_API_BASE_URL=''
11 changes: 11 additions & 0 deletions .github/workflows/. prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Ignore artifacts:
.next
build
dist
node_modules
coverage
public

# Ignore files:
*.log
.env*
87 changes: 58 additions & 29 deletions community.json
Original file line number Diff line number Diff line change
@@ -1,30 +1,43 @@
{
"community": {
"name": "Breadchain Community Token",
"description": "BREAD is a digital community token and solidarity primitive developed by Breadchain Cooperative that generates yield for post-capitalist organizations",
"url": "https://breadchain.xyz/",
"alias": "bread",
"logo": "https://bread.citizenwallet.xyz/uploads/logo.svg",
"name": "Brussels Pay",
"description": "A community for the city of Brussels",
"url": "https://pay.brussels",
"alias": "wallet.pay.brussels",
"logo": "https://assets.citizenwallet.xyz/wallet-config/_images/wallet.pay.brussels.png",
"custom_domain": "wallet.pay.brussels",
"hidden": false,
"theme": {
"primary": "#4a90e2"
},
"profile": {
"address": "0x6b3a1f4277391526413F583c23D5B9EF4d2fE986",
"address": "0x56Cc38bDa01bE6eC6D854513C995f6621Ee71229",
"chain_id": 100
},
"primary_token": {
"address": "0xa555d5344f6fb6c65da19e403cb4c1ec4a1a5ee3",
"address": "0x5815E61eF72c9E6107b5c5A05FD121F334f7a7f1",
"chain_id": 100
},
"primary_account_factory": {
"address": "0x940Cbb155161dc0C4aade27a4826a16Ed8ca0cb2",
"chain_id": 100
},
"primary_card_manager": {
"address": "0xBA861e2DABd8316cf11Ae7CdA101d110CF581f28",
"chain_id": 100
},
"primary_session_manager": {
"address": "0xE2F3DC3E638113b9496060349e5332963d9C1152",
"chain_id": 100
}
},
"tokens": {
"100:0xa555d5344f6fb6c65da19e403cb4c1ec4a1a5ee3": {
"100:0x5815E61eF72c9E6107b5c5A05FD121F334f7a7f1": {
"standard": "erc20",
"name": "Breadchain Community Token",
"address": "0xa555d5344f6fb6c65da19e403cb4c1ec4a1a5ee3",
"symbol": "BREAD",
"decimals": 18,
"name": "pay.brussels",
"address": "0x5815E61eF72c9E6107b5c5A05FD121F334f7a7f1",
"symbol": "EURb",
"decimals": 6,
"chain_id": 100
}
},
Expand All @@ -33,27 +46,48 @@
"name": "Gnosis Explorer"
},
"accounts": {
"100:0xAE76B1C6818c1DD81E20ccefD3e72B773068ABc9": {
"100:0xBABCf159c4e3186cf48e4a48bC0AeC17CF9d90FE": {
"chain_id": 100,
"entrypoint_address": "0xcA0a75EF803a364C83c5EAE7Eb889aE7419c9dF2",
"paymaster_address": "0xbE2Cb3358aa14621134e923B68b8429315368E32",
"account_factory_address": "0xAE76B1C6818c1DD81E20ccefD3e72B773068ABc9",
"entrypoint_address": "0xAAEb9DC18aDadae9b3aE7ec2b47842565A81113f",
"paymaster_address": "0xcA1B9EC1117340818C1c1fdd1B48Ea79E57C140F",
"account_factory_address": "0xBABCf159c4e3186cf48e4a48bC0AeC17CF9d90FE",
"paymaster_type": "cw"
},
"100:0x940Cbb155161dc0C4aade27a4826a16Ed8ca0cb2": {
"chain_id": 100,
"entrypoint_address": "0x7079253c0358eF9Fd87E16488299Ef6e06F403B6",
"paymaster_address": "0x5C41F1114AB13aF5d66bac485924D03556d0cd51",
"paymaster_address": "0xE69C843898E21C0E95eA7DD310cD850AAc0aB897",
"account_factory_address": "0x940Cbb155161dc0C4aade27a4826a16Ed8ca0cb2",
"paymaster_type": "cw-safe"
}
},
"cards": {
"100:0x1EaF6B6A6967608aF6c77224f087b042095891EB": {
"chain_id": 100,
"address": "0x1EaF6B6A6967608aF6c77224f087b042095891EB",
"type": "classic"
},
"100:0xBA861e2DABd8316cf11Ae7CdA101d110CF581f28": {
"chain_id": 100,
"instance_id": "brussels-pay",
"address": "0xBA861e2DABd8316cf11Ae7CdA101d110CF581f28",
"type": "safe"
}
},
"sessions": {
"100:0xE2F3DC3E638113b9496060349e5332963d9C1152": {
"chain_id": 100,
"module_address": "0xE2F3DC3E638113b9496060349e5332963d9C1152",
"factory_address": "0xEd0cD3886b84369A0e29Db9a4480ADF5051c76C9",
"provider_address": "0xF3004A1690f97Cf5d307eDc5958a7F76b62f9FC9"
}
},
"chains": {
"100": {
"id": 100,
"node": {
"url": "https://100.engine.citizenwallet.xyz",
"ws_url": "wss://100.engine.citizenwallet.xyz"
"url": "https://engine.pay.brussels",
"ws_url": "wss://engine.pay.brussels"
}
}
},
Expand All @@ -63,17 +97,12 @@
"plugins": [
{
"name": "Top Up",
"icon": "https://bread.citizenwallet.xyz/uploads/logo.svg",
"url": "https://topup.citizenspring.earth/bread",
"action": "topup"
},
{
"name": "Market",
"icon": "https://bread.citizenwallet.xyz/uploads/logo.svg",
"url": "https://marketplace.citizenwallet.xyz/bread",
"launch_mode": "webview"
"icon": "https://assets.citizenwallet.xyz/wallet-config/_images/wallet.pay.brussels.png",
"url": "https://checkout.pay.brussels/topup",
"action": "topup",
"signature": true
}
],
"config_location": "https://config.internal.citizenwallet.xyz/v4/bread.citizenwallet.xyz.json",
"config_location": "https://wallet.pay.brussels/config/community.json",
"version": 4
}
2 changes: 1 addition & 1 deletion components.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@
"components": "@/components",
"utils": "@/lib/utils"
}
}
}
Loading