Skip to content

Comments

devop: to address field#696

Merged
kvhnuke merged 1 commit intodevop/release-v-2-7-0from
feat/add-to-address
May 29, 2025
Merged

devop: to address field#696
kvhnuke merged 1 commit intodevop/release-v-2-7-0from
feat/add-to-address

Conversation

@kvhnuke
Copy link
Contributor

@kvhnuke kvhnuke commented May 21, 2025

Summary by CodeRabbit

  • New Features
    • Added a visual and textual display of the Ethereum transaction recipient address, including its identicon, in the transaction verification interface.
  • Style
    • Improved typography and layout for transaction verification labels and recipient address display for better readability.
  • Enhancements
    • Updated address input fields across Ethereum, Solana, and swap interfaces to fully display short addresses without truncation.

@coderabbitai
Copy link

coderabbitai bot commented May 21, 2025

Walkthrough

A new UI section was added to display the recipient ("To" address) of an Ethereum transaction, including its identicon. A reactive reference for the recipient's identicon is introduced and updated during transaction decoding. The template now shows the recipient's identicon and address alongside existing sender information. CSS styles were added and updated to support the new label and text appearance. Additionally, the package version and dependency version for @enkryptcom/hw-wallets were updated. The address input components for Ethereum, Solana, and swap transactions were modified to show short addresses fully without ellipsis when not focused.

Changes

File(s) Change Summary
packages/extension/src/providers/ethereum/ui/eth-verify-transaction.vue Added display for recipient address and identicon; introduced identiconTo reactive reference; updated template and setup logic; added explicit "From" label and fixed favicon size.
packages/extension/src/providers/common/ui/styles/verify-transaction.less Added .provider-verify-transaction__label CSS class; updated font properties and colors for .provider-verify-transaction__account-info-to selector.
packages/hw-wallets/package.json Bumped package version from 0.0.4 to 0.0.5; changed @ledgerhq/live-common dependency from caret range "^34.20.0" to exact version "34.20.0".
packages/extension/src/providers/ethereum/ui/send-transaction/components/send-address-input.vue Modified visibleAddress computed property to show full address if shorter than 13 characters, removing ellipsis in that case.
packages/extension/src/providers/solana/ui/send-transaction/components/send-address-input.vue Changed address computed property getter to show full address if shorter than 13 characters when not focused, otherwise truncated.
packages/extension/src/ui/action/views/swap/components/send-address-input.vue Updated address computed getter to display full address if shorter than 13 characters regardless of focus, else truncated with ellipsis.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant UI (eth-verify-transaction.vue)
    participant Network

    User->>UI (eth-verify-transaction.vue): Initiates transaction verification
    UI (eth-verify-transaction.vue)->>Network: Decode transaction
    Network-->>UI (eth-verify-transaction.vue): Returns decoded transaction with toAddress
    UI (eth-verify-transaction.vue)->>UI (eth-verify-transaction.vue): Generate identicon for toAddress
    UI (eth-verify-transaction.vue)->>User: Display sender and recipient identicons and addresses
Loading

Suggested reviewers

  • gamalielhere
  • olgakup

Note

⚡️ AI Code Reviews for VS Code, Cursor, Windsurf

CodeRabbit now has a plugin for VS Code, Cursor and Windsurf. This brings AI code reviews directly in the code editor. Each commit is reviewed immediately, finding bugs before the PR is raised. Seamless context handoff to your AI code agent ensures that you can easily incorporate review feedback.
Learn more here.


📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6cab721 and 37ee211.

📒 Files selected for processing (3)
  • packages/extension/src/providers/ethereum/ui/send-transaction/components/send-address-input.vue (1 hunks)
  • packages/extension/src/providers/solana/ui/send-transaction/components/send-address-input.vue (1 hunks)
  • packages/extension/src/ui/action/views/swap/components/send-address-input.vue (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
  • GitHub Check: buildAll
  • GitHub Check: test
  • GitHub Check: test
🔇 Additional comments (3)
packages/extension/src/providers/ethereum/ui/send-transaction/components/send-address-input.vue (1)

74-74: Excellent UX improvement for short address display!

This change enhances user experience by displaying short addresses (< 13 characters) in full instead of unnecessarily truncating them with ellipsis. The logic is sound and maintains backward compatibility while improving readability.

packages/extension/src/ui/action/views/swap/components/send-address-input.vue (1)

83-83: Consistent implementation across components!

This change aligns perfectly with the similar improvement made in the Ethereum send-address-input component, ensuring consistent address display behavior across different transaction types. The logic correctly prioritizes displaying short addresses in full.

packages/extension/src/providers/solana/ui/send-transaction/components/send-address-input.vue (1)

69-75: Great refactoring with consistent UX improvement!

This change accomplishes two improvements:

  1. UX Enhancement: Displays short addresses (< 13 characters) fully, consistent with the other send-address-input components
  2. Code Readability: Refactors from a ternary operator to explicit if-else statements, making the logic flow clearer and easier to understand

The implementation maintains consistency across all three send-address-input components in the application.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 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 anywhere in the PR title to generate the title automatically.

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.

@github-actions
Copy link

github-actions bot commented May 21, 2025

💼 Build Files
chrome: enkrypt-chrome-37ee211f.zip
firefox: enkrypt-firefox-37ee211f.zip

💉 Virus total analysis
chrome: 37ee211f
firefox: 37ee211f

Copy link

@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: 0

🧹 Nitpick comments (2)
packages/extension/src/providers/ethereum/ui/eth-verify-transaction.vue (2)

86-86: Consider formatting the recipient address for better readability

The raw recipient address is displayed without any formatting. For consistency with how the sender address is displayed, consider using the same ellipsis formatting.

-                {{ decodedTx?.toAddress ?? '~' }}
+                {{ $filters.replaceWithEllipsis(decodedTx?.toAddress ?? '~', 6, 4) }}

83-89: Consider adding a label for the recipient address

To improve clarity for users, consider adding a label like "To:" or "Recipient:" before the address, similar to how other information is presented in the UI.

          <div class="provider-verify-transaction__account-info">
+           <h4>Recipient</h4>
            <div>
              <p>
                {{ decodedTx?.toAddress ?? '~' }}
              </p>
            </div>
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 97bd787 and cd4677a.

📒 Files selected for processing (1)
  • packages/extension/src/providers/ethereum/ui/eth-verify-transaction.vue (3 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
  • GitHub Check: buildAll
  • GitHub Check: test
  • GitHub Check: test
🔇 Additional comments (3)
packages/extension/src/providers/ethereum/ui/eth-verify-transaction.vue (3)

80-91: Great addition of recipient address display!

Adding a dedicated UI section for the transaction recipient address improves transparency and user experience when verifying transactions. This helps users confirm they're sending funds to the intended recipient before approving a transaction.


198-198: Good implementation of reactive reference for recipient identicon

The reactive reference for identiconTo is properly initialized with an empty identicon and follows the same pattern as the existing identicon reference.


232-234: Proper implementation of identicon generation for the recipient

The recipient's identicon is correctly generated using the lowercase version of the recipient address, which is a good practice for Ethereum addresses to ensure consistency.

Copy link

@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)
packages/extension/src/providers/common/ui/styles/verify-transaction.less (1)

10-16: Consider more specific BEM naming for the new label.
The generic &__label styling may collide with other labels under this component. If this is only intended for the "To" section, you might scope it more narrowly (e.g., &__to-label under &__account-to) or rename it to avoid unintentional styling of unrelated labels.

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between cd4677a and fe4ed5b.

📒 Files selected for processing (2)
  • packages/extension/src/providers/common/ui/styles/verify-transaction.less (2 hunks)
  • packages/extension/src/providers/ethereum/ui/eth-verify-transaction.vue (5 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • packages/extension/src/providers/ethereum/ui/eth-verify-transaction.vue
⏰ Context from checks skipped due to timeout of 90000ms (3)
  • GitHub Check: buildAll
  • GitHub Check: test
  • GitHub Check: test

@kvhnuke kvhnuke changed the base branch from develop to devop/release-v-2-7-0 May 29, 2025 18:20
@kvhnuke kvhnuke merged commit 5490f2f into devop/release-v-2-7-0 May 29, 2025
5 checks passed
@kvhnuke kvhnuke deleted the feat/add-to-address branch May 29, 2025 18:20
@kvhnuke kvhnuke restored the feat/add-to-address branch May 29, 2025 21:51
This was referenced May 29, 2025
@coderabbitai coderabbitai bot mentioned this pull request Jun 17, 2025
@coderabbitai coderabbitai bot mentioned this pull request Nov 25, 2025
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.

1 participant