Skip to content

feat: ens in evidence #2027

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

Merged
merged 2 commits into from
Jun 20, 2025
Merged

feat: ens in evidence #2027

merged 2 commits into from
Jun 20, 2025

Conversation

kemuru
Copy link
Contributor

@kemuru kemuru commented Jun 17, 2025

PR-Codex overview

This PR focuses on refactoring the EvidenceCard component in EvidenceCard.tsx. It simplifies the layout and styling, removes unused imports, and updates the structure for displaying juror information.

Detailed summary

  • Removed unused imports: Identicon and shortenAddress.
  • Added import for JurorTitle.
  • Updated BottomLeftContent to use flex layout with a gap.
  • Removed AccountContainer and replaced it with StyledJurorInternalLink using JurorTitle.
  • Simplified styles for StyledJurorInternalLink.

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

Summary by CodeRabbit

  • Refactor
    • Updated the display of sender information in evidence cards for a more streamlined and consistent look.
    • Improved layout and responsiveness of the sender information section.
  • Style
    • Enhanced visual styling and hover effects for sender identity links in evidence cards.

@kemuru kemuru requested a review from a team as a code owner June 17, 2025 11:26
Copy link

netlify bot commented Jun 17, 2025

Deploy Preview for kleros-v2-testnet-devtools ready!

Name Link
🔨 Latest commit 70b21f9
🔍 Latest deploy log https://app.netlify.com/projects/kleros-v2-testnet-devtools/deploys/68556edcdb04f60008afc9b9
😎 Deploy Preview https://deploy-preview-2027--kleros-v2-testnet-devtools.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link

netlify bot commented Jun 17, 2025

Deploy Preview for kleros-v2-neo ready!

Name Link
🔨 Latest commit 70b21f9
🔍 Latest deploy log https://app.netlify.com/projects/kleros-v2-neo/deploys/68556edb88d19500082f6d2f
😎 Deploy Preview https://deploy-preview-2027--kleros-v2-neo.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link

netlify bot commented Jun 17, 2025

Deploy Preview for kleros-v2-testnet ready!

Name Link
🔨 Latest commit 70b21f9
🔍 Latest deploy log https://app.netlify.com/projects/kleros-v2-testnet/deploys/68556edb208bed00086da11f
😎 Deploy Preview https://deploy-preview-2027--kleros-v2-testnet.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@kemuru kemuru requested a review from alcercu June 17, 2025 11:26
Copy link
Contributor

coderabbitai bot commented Jun 17, 2025

Walkthrough

The EvidenceCard component is updated to replace the identicon and shortened address display with a new styled internal link wrapping the JurorTitle component. Related styled components and unused imports are removed, and layout styling for sender information is revised to use flexbox with responsive adjustments.

Changes

File(s) Change Summary
web/src/components/EvidenceCard.tsx Removed identicon and shortened address; added StyledJurorInternalLink with JurorTitle; updated layout styling; deleted unused imports and styled components.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant EvidenceCard
    participant JurorTitle

    User->>EvidenceCard: Render EvidenceCard
    EvidenceCard->>JurorTitle: Render JurorTitle inside StyledJurorInternalLink
    JurorTitle-->>EvidenceCard: Juror identity displayed
    EvidenceCard-->>User: Show updated sender info layout
Loading

Possibly related PRs

  • feat: public dashboards #1819: Updates EvidenceCard.tsx to use internal dashboard links and modifies hover styles, overlapping with sender address and link rendering changes.

Suggested labels

Type: Feature🗿, Package: Web

Suggested reviewers

  • alcercu

Poem

In the warren of code, a new card is spun,
No more identicons—just links for fun!
Juror titles gleam where addresses once lay,
Flex and style keep clutter at bay.
With a hop and a skip, the sender’s now chic—
This bunny approves of your latest technique! 🐇✨

✨ Finishing Touches
  • 📝 Generate Docstrings

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai or @coderabbitai title anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
web/src/components/EvidenceCard.tsx (1)

23-23: Verify path correctness for JurorTitle import

JurorTitle is now imported through a relatively deep path (pages/Home/TopJurors/JurorCard/JurorTitle).
If a barrel export exists (e.g. pages/Home/TopJurors/index.ts) consider re-exporting JurorTitle there to avoid brittle deep-path imports and to reduce the likelihood of future breakage when directories are reorganised.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0b75799 and 10294ce.

📒 Files selected for processing (1)
  • web/src/components/EvidenceCard.tsx (4 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (15)
  • GitHub Check: Redirect rules - kleros-v2-testnet
  • GitHub Check: Redirect rules - kleros-v2-neo
  • GitHub Check: Redirect rules - kleros-v2-testnet
  • GitHub Check: Redirect rules - kleros-v2-testnet-devtools
  • GitHub Check: Header rules - kleros-v2-testnet
  • GitHub Check: Header rules - kleros-v2-testnet
  • GitHub Check: Header rules - kleros-v2-neo
  • GitHub Check: Header rules - kleros-v2-testnet-devtools
  • GitHub Check: Pages changed - kleros-v2-testnet
  • GitHub Check: Pages changed - kleros-v2-testnet
  • GitHub Check: Pages changed - kleros-v2-neo
  • GitHub Check: Pages changed - kleros-v2-testnet-devtools
  • GitHub Check: SonarCloud
  • GitHub Check: contracts-testing
  • GitHub Check: Analyze (javascript)
🔇 Additional comments (2)
web/src/components/EvidenceCard.tsx (2)

101-104: Portrait → landscape layout switch looks good

Switching BottomLeftContent to a flex layout with gap simplifies spacing and removes the old descendant selector hack – nice cleanup.


238-240: Profile link contains hard-coded “1”

/profile/1/desc/all?address=${sender} hard-codes “1”. If this is intended to be the chain ID or page number, consider deriving it from router params / context so it doesn’t diverge across networks.

-const profileLink = `/profile/1/desc/all?address=${sender}`;
+const profileLink = `/profile/${chainId}/desc/all?address=${sender}`; // obtain chainId from context

Copy link

netlify bot commented Jun 17, 2025

Deploy Preview for kleros-v2-university failed. Why did it fail? →

Name Link
🔨 Latest commit 70b21f9
🔍 Latest deploy log https://app.netlify.com/projects/kleros-v2-university/deploys/68556edbf61b6c00088e1f67

Copy link
Contributor

@alcercu alcercu left a comment

Choose a reason for hiding this comment

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

lgtm

@alcercu alcercu enabled auto-merge June 20, 2025 14:23
Copy link

codeclimate bot commented Jun 20, 2025

Code Climate has analyzed commit 70b21f9 and detected 0 issues on this pull request.

View more on Code Climate.

Copy link

@alcercu alcercu merged commit 2542150 into dev Jun 20, 2025
21 of 26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants