Skip to content
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

Fe/compress landing images #2300

Merged
merged 2 commits into from
Mar 14, 2024
Merged

Fe/compress landing images #2300

merged 2 commits into from
Mar 14, 2024

Conversation

lawsonkight
Copy link
Collaborator

@lawsonkight lawsonkight commented Mar 14, 2024

Replaces SynapseCircuit diagram with compressed SVG

Replaces outdated Bridge images with semi-interactive React component

Summary by CodeRabbit

  • New Features
    • Introduced a new FauxBridge component for token swapping across different chains with a user-friendly interface.
  • Refactor
    • Updated the landing page's BridgeSection to incorporate the FauxBridge component, enhancing its appearance and functionality.
    • Improved the SecuritySection with better icon import structure and dark mode styling adjustments.

1bf3bf21746f554a68efa254141c2bd9db884d4f: synapse-interface preview link

Copy link
Contributor

coderabbitai bot commented Mar 14, 2024

Walkthrough

The recent updates introduce a new FauxBridge component for token swapping across chains, enhance the UI by integrating this component into the landing page, and refine the dark mode styling across sections. These changes aim to improve user interaction and visual consistency, particularly focusing on the bridge functionality and security section presentation.

Changes

Files Summary
.../icons/LandingIcons/FauxBridge.tsx
.../landing/sections/BridgeSection.tsx
Introduced FauxBridge component for token swapping, replaced old bridge images with FauxBridge, and updated UI styling for dark mode.
.../landing/sections/SecuritySection.tsx Refactored icon imports and adjusted CSS for better dark mode compatibility.

🐰✨

In the land of code, where bridges connect far and wide,

A faux bridge arose, with tokens to glide.

Across chains they leap, in a UI so sleek,

Under the moon's soft glow, the dark mode we seek.

🌉🌙

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?

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>.
    • Generate unit-tests for this file.
    • 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 generate unit tests for this file.
    • @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 generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit tests.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

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)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • The JSON schema for the configuration file is available here.
  • 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/coderabbit-overrides.v2.json

CodeRabbit Discord Community

Join our Discord Community to get help, request features, and share feedback.

Copy link

Deploying sanguine-fe with  Cloudflare Pages  Cloudflare Pages

Latest commit: 97f0d2c
Status: ✅  Deploy successful!
Preview URL: https://45a97b3d.sanguine-fe.pages.dev
Branch Preview URL: https://fe-compress-landing-images.sanguine-fe.pages.dev

View logs

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.

Review Status

Actionable comments generated: 0

Configuration used: .coderabbit.yaml

Commits Files that changed from the base of the PR and between 8fe49ec and 97f0d2c.
Files selected for processing (3)
  • packages/synapse-interface/components/icons/LandingIcons/FauxBridge.tsx (1 hunks)
  • packages/synapse-interface/pages/landing/sections/BridgeSection.tsx (2 hunks)
  • packages/synapse-interface/pages/landing/sections/SecuritySection.tsx (3 hunks)
Additional comments: 14
packages/synapse-interface/pages/landing/sections/SecuritySection.tsx (3)
  • 6-6: The refactoring of icon imports seems to streamline the import statements, making them more organized. This change should make it easier to manage and understand which icons are being used in the SecuritySection.
  • 17-17: The addition of the dark class to the div element is a good practice for supporting dark mode styling. This ensures that the section will adapt its appearance based on the user's preference or system settings, enhancing the user experience.
  • 38-38: The use of the Grid component with responsive column settings (sm: 1, md: 3) and a gap of 8 is a good practice for creating a responsive layout. This ensures that the SupportCard components will be displayed appropriately across different screen sizes.
packages/synapse-interface/pages/landing/sections/BridgeSection.tsx (4)
  • 10-10: The addition of the FauxBridge component import is crucial for integrating the new semi-interactive component into the BridgeSection. This change aligns with the PR's objective to enhance user engagement by replacing static images with a dynamic component.
  • 21-21: Including the dark class in the div element for dark mode support is a positive change. It ensures that the section's appearance adapts to the user's preference or system settings, contributing to a better user experience.
  • 36-36: Replacing the BridgeImage and BridgeImageSmall components with the FauxBridge component is a significant enhancement. This change moves from static images to a semi-interactive component, providing users with a more engaging and informative experience.
  • 28-31: The text formatting changes within the paragraph about the Synapse Bridge improve readability and emphasize key points. Using strong tags for important terms and breaking the text into smaller lines enhances the visual appeal and makes the content easier to digest.
packages/synapse-interface/components/icons/LandingIcons/FauxBridge.tsx (7)
  • 1-5: The commented-out imports (PulseDot and WALLET_ICONS) suggest that there were plans to include these elements in the component but were eventually not used. If these imports are not going to be used in the future, it's a good practice to remove them to keep the code clean and maintainable.
  • 7-20: The styling constants (cardStyle, sectionStyle, buttonStyle, chainSelectStyle, tokenSelectStyle, inputWrapperStyle, inputStyle) are well-organized and contribute to the maintainability of the component. Using descriptive names for these constants makes it easier to understand their purpose and apply consistent styling across the component.
  • 22-49: The structure of the FauxBridge component, with its sections and interactive elements, is well-designed to simulate a bridge interface. The use of the Select component for chain and token selection, along with input fields and the HistoricMax button, provides a semi-interactive experience that aligns with the PR's objective to enhance user engagement.
  • 51-170: The Select component implementation is comprehensive, handling both 'Chain' and 'Token' types with dynamic data. However, the commented-out sections related to header and formatting functions suggest that there was an intention to display additional information that was not fully implemented. If these features are not required, it would be cleaner to remove the commented-out code. Otherwise, consider completing the implementation for a more informative component.
  • 172-186: The SupportedWallets component is currently placeholder content with commented-out sections for wallet icons. If the intention is to support wallet integration in the future, it would be beneficial to implement this feature or provide a TODO comment for future development. Otherwise, consider removing the placeholder and commented-out code to avoid confusion.
  • 188-210: The HistoricMax component provides a link to a specific transaction, which is a nice touch for demonstrating the bridge's capabilities. However, the hardcoded transaction link and values may not be relevant to all users. Consider making this component dynamic, allowing it to display relevant historical transactions based on user selections.
  • 232-270: The BridgeButton component with its hover effect and dynamic width animation adds an interactive element to the component. This is a good practice for enhancing user engagement. However, ensure that the link in the BridgeButton (href="/") is correctly set to the intended destination for initiating bridge transactions or navigating to the bridge page.

Copy link

Deploying sanguine with  Cloudflare Pages  Cloudflare Pages

Latest commit: 97f0d2c
Status: ✅  Deploy successful!
Preview URL: https://a56a165a.sanguine.pages.dev
Branch Preview URL: https://fe-compress-landing-images.sanguine.pages.dev

View logs

@lawsonkight lawsonkight merged commit 50a3634 into master Mar 14, 2024
39 of 41 checks passed
@lawsonkight lawsonkight deleted the fe/compress-landing-images branch March 14, 2024 21:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants