-
Notifications
You must be signed in to change notification settings - Fork 47
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(web): Evidence: display submission timestamp #1617
Conversation
✅ Deploy Preview for kleros-v2 ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
|
Name | Link |
---|---|
🔨 Latest commit | 3f2934c |
❌ Deploy Preview for kleros-v2-university failed. Why did it fail? →
|
Important Review skippedAuto reviews are limited to specific labels. Labels to auto review (1)
Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
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 as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
web/src/components/EvidenceCard.tsx
Outdated
@@ -96,6 +97,10 @@ const DesktopText = styled.span` | |||
)} | |||
`; | |||
|
|||
const Timestamp = styled.p` | |||
color: #BECCE5; |
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.
instead of this:
color: #BECCE5;
do this:
color: ${({ theme }) => theme.secondaryText};
this is because we have all the color scheme centralized for both dark mode and light mode, you can check on the styles/themes.ts
folder
web/src/components/EvidenceCard.tsx
Outdated
@@ -137,6 +143,11 @@ const EvidenceCard: React.FC<IEvidenceCard> = ({ evidence, sender, index }) => { | |||
<Identicon size="24" string={sender} /> | |||
<p>{shortenAddress(sender)}</p> | |||
</AccountContainer> | |||
<Timestamp>{new Date(parseInt(timestamp) * 1000).toLocaleDateString('en-US', { |
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.
instead of the above, do this:
<Timestamp>{formatDate(Number(timestamp))}</Timestamp>
its cleaner since we already have this util function at
import { formatDate } from "utils/date";
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.
lgtm, I redeployed the official core devnet subgraphs
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.
lgtm
Code Climate has analyzed commit 3f2934c and detected 1 issue on this pull request. Here's the issue category breakdown:
View more on Code Climate. |
closes #1590
PR-Codex overview
The focus of this PR is to add a
timestamp
field to evidence-related components and update the subgraph version.Detailed summary
timestamp
field to evidence-related components0.5.1