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

Fix: dev docs layout on medium screen sizes [Fixes #8364] #12460

Merged
merged 3 commits into from
Mar 21, 2024
Merged

Conversation

wackerow
Copy link
Member

@wackerow wackerow commented Mar 14, 2024

Preview link

Related Issue

Summary by CodeRabbit

  • Style
    • Updated the layout and spacing in the navigation components for improved user experience.
    • Adjusted the width of the side navigation panel for better screen space utilization.
    • Modified the width behavior of components for consistency across different screen sizes.

Copy link
Contributor

coderabbitai bot commented Mar 14, 2024

Walkthrough

The updates focus on refining the layout and responsiveness of the documentation navigation components. Adjustments were made to component widths, breakpoints for larger screens, and the overall spacing within the navigation elements. These changes aim to improve the consistency and user experience across different device sizes, particularly addressing layout issues in the documentation sections.

Changes

File Path Change Summary
src/components/DocsNav.tsx Adjusted width, flex properties in CardLink; updated direction, breakpoints, and spacing in DocsNav.
src/components/SideNav.tsx Modified width and minimum width from 298px to 256px.
src/layouts/Docs.tsx Changed maxW to w with value "0" for large breakpoint in Box component.

Assessment against linked issues

Objective Addressed Explanation
Inconsistent padding/margin on docs pages (#8364) The changes address layout and spacing, but it's unclear without visual confirmation if the specific padding/margin inconsistency reported is resolved.

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

netlify bot commented Mar 14, 2024

Deploy Preview for ethereumorg ready!

Name Link
🔨 Latest commit 2393c10
🔍 Latest deploy log https://app.netlify.com/sites/ethereumorg/deploys/65f47c8f160af800081dc75e
😎 Deploy Preview https://deploy-preview-12460--ethereumorg.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 site configuration.

@@ -150,7 +150,7 @@ const Content = (props: ChildOnlyProp) => {
<Box
as={MainArticle}
flex={`1 1 ${mdBreakpoint}`}
maxW={{ base: "full", lg: mdBreakpoint }}
w={{ base: "full", lg: "0" }}
Copy link
Member Author

Choose a reason for hiding this comment

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

@pettinarip Any thoughts on a better way to handle this? Not a fan of using a zero width, but it works exactly as I'd like so figured I'd commit it and see what others thought

Copy link
Member

Choose a reason for hiding this comment

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

As alternatives we could set minW="0" or

Suggested change
w={{ base: "full", lg: "0" }}
overflow="auto"

@wackerow wackerow marked this pull request as ready for review March 20, 2024 04:38
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 UI

Commits Files that changed from the base of the PR and between 90e4310 and 2393c10.
Files selected for processing (3)
  • src/components/DocsNav.tsx (2 hunks)
  • src/components/SideNav.tsx (1 hunks)
  • src/layouts/Docs.tsx (1 hunks)
Additional comments: 3
src/components/SideNav.tsx (1)
  • 159-160: The adjustments to the width and minimum width from 298px to 256px are aligned with the objective to improve the layout for medium screen sizes. Ensure to verify the layout consistency across different screen sizes and components to maintain a uniform user experience.
src/components/DocsNav.tsx (2)
  • 61-62: The adjustments to the width and flex properties in the CardLink component are aimed at improving layout responsiveness. Ensure to verify the impact on other screen sizes to maintain visual consistency across the board.
  • 148-155: The updates to the direction, breakpoints, and spacing in the DocsNav component are likely to enhance the layout's responsiveness and visual consistency. It's important to verify the layout consistency and user experience across different screen sizes to ensure these changes achieve the desired improvements.

@nhsz nhsz merged commit 9b66046 into dev Mar 21, 2024
11 checks passed
@nhsz nhsz deleted the dev-docs-layout branch March 21, 2024 16:06
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.

Inconsistent padding/margin on docs pages
4 participants