Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
e5b815e
revamp(1/7): design tokens & POH NEW palette
madhurMongia Jul 9, 2026
e8ae9e5
revamp(1/7): design-system icons & logos
madhurMongia Jul 9, 2026
c3f5b53
fix: tolerate partial subgraph outages in getMyData
madhurMongia Jul 9, 2026
506fa80
chore: upgrade graphql-request and restore codegen plugin 6.x
madhurMongia Jul 9, 2026
99b8b35
fix(revamp/1): wire new SVGs at correct display sizes
madhurMongia Jul 9, 2026
386f15f
feat(revamp/1): move navbar chrome into foundation
madhurMongia Jul 9, 2026
a91b14c
feat(revamp/1): wire Figma states, timeline icons and logos
madhurMongia Jul 9, 2026
94f03a6
fix(revamp/1): enlarge header PoH lockup and swap favicon mark
madhurMongia Jul 9, 2026
d8d98fd
chore(revamp/1): drop StatusIcon Figma comment
madhurMongia Jul 9, 2026
ecceb71
chore(revamp/1): remove design-doc comments from foundation PR
madhurMongia Jul 9, 2026
4c26faf
chore: trigger Netlify deploy preview after allowed_branches update
madhurMongia Jul 9, 2026
5d31173
fix(revamp/1): address CodeRabbit review feedback
madhurMongia Jul 9, 2026
b7a0d37
fix(revamp/1): align header, footer and pages on a shared 1400px cont…
madhurMongia Jul 9, 2026
f0cc5bb
revamp(2/7): atoms & molecules per the POH NEW spec
madhurMongia Jul 9, 2026
2f3df40
fix(revamp/2): match monobranch home grid card dimensions
madhurMongia Jul 9, 2026
8b83157
fix(revamp/2): stop ExternalLink default blue hover
madhurMongia Jul 9, 2026
7231cd8
fix(revamp/2): center card status tooltip above info icon
madhurMongia Jul 9, 2026
2853341
fix(revamp/2): use peach/orange for checkboxes instead of browser blue
madhurMongia Jul 9, 2026
13cb0b2
fix(revamp/2): refine status badge sizing and card radius per spec
madhurMongia Jul 9, 2026
1201534
fix(revamp/2): move useIPFS to react-query with jittered retry backoff
madhurMongia Jul 9, 2026
f5d7f1b
fix(revamp/2): make webpack SVGR win over Next asset rule for icons
madhurMongia Jul 10, 2026
ddbfbbe
refactor(revamp/2): streamline component fallbacks and remove unused …
madhurMongia Jul 10, 2026
06fef75
refactor(footer/header): enhance accessibility and improve component …
madhurMongia Jul 13, 2026
04e2127
refactor(Request/Card, StatusBadge): simplify status handling and imp…
madhurMongia Jul 13, 2026
287222b
Merge pull request #436 from Proof-Of-Humanity/revamp/2-atom-molecules
madhurMongia Jul 14, 2026
5a74ec4
Add POH ID badge SVG and implement ActionWalletGate component
madhurMongia Jul 14, 2026
7af1be4
refactor: implement useEnoughFunds and resolveTxState for improved tr…
madhurMongia Jul 15, 2026
29774c0
refactor: enhance user feedback and error handling across components
madhurMongia Jul 15, 2026
4774e76
Merge pull request #441 from Proof-Of-Humanity/revamp/3-profile
madhurMongia Jul 15, 2026
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
10 changes: 5 additions & 5 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ module.exports = {
rules: {
"react/no-unescaped-entities": 0,
"react/display-name": "off",
"react-hooks/exhaustive-deps": "warn",
"no-var": "warn",
"prefer-const": "warn",
eqeqeq: ["warn", "always", { null: "ignore" }],
"object-shorthand": ["warn", "always"],
"react-hooks/exhaustive-deps": "error",
"no-var": "error",
"prefer-const": "error",
eqeqeq: ["error", "always", { null: "ignore" }],
"object-shorthand": ["error", "always"],
"no-restricted-syntax": [
"warn",
{
Expand Down
44 changes: 38 additions & 6 deletions next.config.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
const ipfsGatewayHostname = process.env.REACT_APP_IPFS_GATEWAY;

if (!ipfsGatewayHostname) {
throw new Error(
"Missing required environment variable: REACT_APP_IPFS_GATEWAY",
);
}

/** @type {import('next').NextConfig} */
const nextConfig = {
experimental: {
Expand Down Expand Up @@ -40,11 +48,35 @@ const nextConfig = {
fs: false,
};
}
config.module.rules.push({
test: /\.svg$/i,
issuer: /\.[jt]sx?$/,
use: ["@svgr/webpack"],
});

// Next treats .svg as a static asset by default. Exclude it from that
// pipeline and run SVGR so `import Icon from "*.svg"` yields a component.
// See https://react-svgr.com/docs/next/
const fileLoaderRule = config.module.rules.find(
(rule) => rule.test instanceof RegExp && rule.test.test(".svg"),
);

if (fileLoaderRule) {
config.module.rules.push({
...fileLoaderRule,
test: /\.svg$/i,
resourceQuery: /url/, // *.svg?url
});
config.module.rules.push({
test: /\.svg$/i,
issuer: fileLoaderRule.issuer,
resourceQuery: {
not: [...(fileLoaderRule.resourceQuery?.not || []), /url/],
},
use: ["@svgr/webpack"],
});
fileLoaderRule.exclude = /\.svg$/i;
} else {
config.module.rules.push({
test: /\.svg$/i,
use: ["@svgr/webpack"],
});
}

return config;
},
Expand All @@ -67,7 +99,7 @@ const nextConfig = {
remotePatterns: [
{
protocol: "https",
hostname: process.env.REACT_APP_IPFS_GATEWAY,
hostname: ipfsGatewayHostname,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Search for environment variable examples or usages
rg "REACT_APP_IPFS_GATEWAY" --glob "*.env*" --glob "*.md"

Repository: Proof-Of-Humanity/proof-of-humanity-v2-web

Length of output: 180


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '\n## matches for REACT_APP_IPFS_GATEWAY\n'
rg -n "REACT_APP_IPFS_GATEWAY" . || true

printf '\n## next.config.js context\n'
nl -ba next.config.js | sed -n '85,115p'

printf '\n## remotePatterns usage\n'
rg -n "remotePatterns|ipfsGatewayHostname|new URL\\(" next.config.js . || true

printf '\n## env/docs references around IPFS gateway\n'
rg -n "ipfs gateway|IPFS_GATEWAY|ipfsGateway|gateway" . --glob "*.md" --glob "*.env*" --glob "*.js" --glob "*.ts" --glob "*.tsx" || true

Repository: Proof-Of-Humanity/proof-of-humanity-v2-web

Length of output: 782


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '\n## next.config.js\n'
sed -n '1,130p' next.config.js

printf '\n## src/utils/ipfs.ts\n'
sed -n '1,80p' src/utils/ipfs.ts

printf '\n## CONTRIBUTING.md env example\n'
sed -n '30,45p' CONTRIBUTING.md

Repository: Proof-Of-Humanity/proof-of-humanity-v2-web

Length of output: 5005


Normalize REACT_APP_IPFS_GATEWAY before using it as remotePatterns.hostname

CONTRIBUTING.md documents this env var as a full URL (https://cdn.kleros.link), but next.config.js passes it straight into hostname. Strip the scheme first (or derive the hostname from new URL(...)) so image matching works with the documented format.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@next.config.js` at line 102, Normalize the value used by the
`remotePatterns.hostname` configuration in `next.config.js`: derive a hostname
from the documented full-URL `REACT_APP_IPFS_GATEWAY` value by removing its
scheme before assigning it to `ipfsGatewayHostname`. Preserve support for the
existing configuration flow while ensuring the remote pattern receives only the
host, not `https://` or another protocol.

port: "",
pathname: "/ipfs/**",
},
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
"classnames": "^2.3.2",
"dotenv": "^16.0.3",
"graphql": "^16.4.0",
"graphql-request": "^4.2.0",
"graphql-request": "^7.1.2",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
rg -n "moduleResolution|\"type\"" tsconfig.json package.json
rg -n "graphql-request" -A2 -B2 src/generated/graphql.ts src/config/subgraph.ts

Repository: Proof-Of-Humanity/proof-of-humanity-v2-web

Length of output: 705


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '\n== package.json ==\n'
cat package.json | python3 - <<'PY'
import json,sys
data=json.load(sys.stdin)
print("scripts:")
for k,v in data.get("scripts",{}).items():
    print(f"  {k}: {v}")
print("dependencies:")
for k in ("graphql-request","next","typescript"):
    if k in data.get("dependencies",{}):
        print(f"  {k}: {data['dependencies'][k]}")
    if k in data.get("devDependencies",{}):
        print(f"  {k}: {data['devDependencies'][k]}")
PY

printf '\n== tsconfig.json ==\n'
cat -n tsconfig.json | sed -n '1,120p'

printf '\n== src/config/subgraph.ts ==\n'
cat -n src/config/subgraph.ts | sed -n '1,220p'

printf '\n== src/generated/graphql.ts (top) ==\n'
cat -n src/generated/graphql.ts | sed -n '1,220p'

Repository: Proof-Of-Humanity/proof-of-humanity-v2-web

Length of output: 921


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== package.json =="
python3 - <<'PY'
import json
from pathlib import Path
data = json.loads(Path("package.json").read_text())
print("name:", data.get("name"))
print("type:", data.get("type"))
print("scripts:")
for k, v in data.get("scripts", {}).items():
    print(f"  {k}: {v}")
for section in ("dependencies", "devDependencies"):
    deps = data.get(section, {})
    if "graphql-request" in deps or "typescript" in deps or "next" in deps:
        print(section + ":")
        for k in ("graphql-request", "next", "typescript"):
            if k in deps:
                print(f"  {k}: {deps[k]}")
PY

echo
echo "== tsconfig.json =="
cat -n tsconfig.json | sed -n '1,200p'

echo
echo "== src/config/subgraph.ts =="
cat -n src/config/subgraph.ts | sed -n '1,220p'

echo
echo "== src/generated/graphql.ts (top) =="
cat -n src/generated/graphql.ts | sed -n '1,220p'

echo
echo "== all graphql-request references =="
rg -n "graphql-request|generated/graphql|getSdk" src netlify . -g '!node_modules'

Repository: Proof-Of-Humanity/proof-of-humanity-v2-web

Length of output: 20904


🌐 Web query:

graphql-request v7 package exports ESM-only RequestOptions GraphQLClient TypeScript moduleResolution node bundler node16 nodenext

💡 Result:

Starting with version 7.x, graphql-request is distributed as a pure ESM (ECMAScript Module) package [1][2]. This means it does not support CommonJS (require) imports [1]. Because the package utilizes modern package.exports, TypeScript users must configure their projects to correctly resolve these exports [3][2]. To successfully use graphql-request v7 in a TypeScript project, you must ensure the following configurations are met: 1. Package Configuration: Your project's package.json must include "type": "module" [4][1][2]. 2. TypeScript Configuration: In your tsconfig.json, the moduleResolution option must be set to "node16", "nodenext", or "bundler" [4][1][2][5]. - "node16" or "nodenext" are recommended for Node.js projects, as they align with Node's native ESM resolution algorithm [5][6]. - "bundler" is suitable if you are using a frontend bundler (e.g., Vite, Webpack), as it supports package.exports without strictly requiring file extensions on relative imports [5]. Regarding the types and exports, graphql-request v7 maintains the GraphQLClient class and various request options (such as RequestOptions and RawRequestOptions) [7][8][1]. Because the package is ESM-only, ensure you are using ES module import syntax (e.g., import { GraphQLClient } from 'graphql-request') [9][1]. If you encounter "Cannot find module" errors, it is almost certainly due to an incompatible moduleResolution setting in your tsconfig.json [4][10].

Citations:


graphql-request v7 needs a compatible TypeScript resolver here

src/generated/graphql.ts and src/config/subgraph.ts import GraphQLClient/RequestOptions from graphql-request, but tsconfig.json still uses moduleResolution: "node". v7 is ESM-only, so this can break tsc --noEmit; switch to bundler/node16/nodenext or keep graphql-request on v6.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@package.json` at line 57, Update tsconfig.json’s moduleResolution to an
ESM-compatible resolver such as bundler, node16, or nodenext so the
GraphQLClient and RequestOptions imports in generated/graphql.ts and
config/subgraph.ts resolve with graphql-request v7; alternatively, downgrade
graphql-request to v6 while preserving the existing resolver.

"graphql-tag": "^2.12.6",
"next": "15.5.16",
"pino-pretty": "^11.0.0",
Expand Down
18 changes: 18 additions & 0 deletions public/logo/built-by-kleros.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 23 additions & 0 deletions public/logo/gnosis-app.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading