Skip to content

fix(terminal): prevent long URL clipping and improve layout responsiveness - #8021

Open
MAYANKSHARMA01010 wants to merge 1 commit into
layer5io:masterfrom
MAYANKSHARMA01010:fix/issue-8008-terminal-url-overflow
Open

fix(terminal): prevent long URL clipping and improve layout responsiveness#8021
MAYANKSHARMA01010 wants to merge 1 commit into
layer5io:masterfrom
MAYANKSHARMA01010:fix/issue-8008-terminal-url-overflow

Conversation

@MAYANKSHARMA01010

@MAYANKSHARMA01010 MAYANKSHARMA01010 commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

This PR addresses and fixes #8008 where long URLs (such as https://github.com/meshery/meshery/tree/v0.6.0/install/deployment_yamls/k8s) in the Meshery installation terminal on the Getting Started page were getting cut off horizontally on desktop viewports.

Root Cause

  1. Invalid CSS Property: The <pre> block in Terminal.style.js was using wrap-word: normal; (an invalid CSS property) without overflow-wrap: anywhere;, causing long strings without whitespace to overflow and be clipped by overflow-x: hidden.
  2. Layout & Space Utilization: The previous layout used 18 hardcoded max-width media queries and large fixed margins (margin-left: 150px) that either caused off-screen overflow on certain screens or left an unused void on the right side on wide desktop screens.

Changes Made

  • Safe Word Wrapping: Added overflow-wrap: anywhere; and overflow-wrap: break-word; in Terminal.style.js so continuous strings wrap gracefully on narrow viewports without clipping.
  • Utilize Right-Side Space: In AnimatedStepsList.style.js, added responsive extension using CSS clamp() on viewports $\ge 1200\text{px}$ so the terminal naturally fills the available space on the right, aligning under the top navigation action buttons with safe margin and zero horizontal page scroll.
  • Streamlined Layout: Replaced the 18 hardcoded media query rules with clean flex sizing (flex: 1; min-width: 0; max-width: 100%) and balanced spacing (margin-left: 36px).

Visual Proof

Before After
Before After

Checklist

Summary by CodeRabbit

  • Bug Fixes
    • Improved the responsive layout of animated step lists across desktop and smaller screen sizes.
    • Improved spacing and alignment between step indicators, content, and terminal panels.
    • Fixed terminal text wrapping to prevent content from overflowing its container.
    • Improved horizontal overflow handling in terminal displays.
    • Ensured terminal content uses the available width more consistently.

…eness

Signed-off-by: Mayank Sharma <sharmamayank01010@gmail.com>
@coderabbitai

coderabbitai Bot commented Sep 5, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Team

Run ID: 5943bc84-6187-4a57-9a04-4265da97705a

📥 Commits

Reviewing files that changed from the base of the PR and between 6c975ec and 0331c14.

📒 Files selected for processing (2)
  • src/components/Animated-steps-list/AnimatedStepsList.style.js
  • src/components/Terminal/Terminal.style.js

Included review availability: Your plan provides up to 4 included reviews per hour; 3 remain after this review.


📝 Walkthrough

Walkthrough

The pull request updates the animated steps layout for responsive sizing and spacing. It also moves terminal wrapper styles into the styled component, wraps long text, and constrains code content within the terminal boundary.

Changes

Terminal layout updates

Layer / File(s) Summary
Responsive animated steps layout
src/components/Animated-steps-list/AnimatedStepsList.style.js
The animated steps container uses flexible spacing and width. Breakpoint-specific child widths are replaced with max-width: 100%.
Terminal content containment
src/components/Terminal/Terminal.style.js
Terminal wrapper rules are kept inside the styled component. Long text uses overflow-wrap, and the no-scroll code wrapper gains width, positioning, and overflow constraints.

Estimated code review effort: 2 (Simple) | ~10 minutes

Merge Risk: ⚪ Minimal · up to 0331c

The terminal now wraps long URLs and uses responsive sizing to prevent horizontal clipping. No merge-blocking risk remains.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the two main changes: preventing terminal text clipping and improving responsive layout behavior.
Linked Issues check ✅ Passed The changes address issue [#8008] by enabling long URLs and unbroken text to wrap within the terminal. The responsive sizing changes also support the required terminal layout behavior.
Out of Scope Changes check ✅ Passed The changes remain within the linked issue scope. The formatting and CSS restructuring support the terminal wrapping and responsive layout fixes.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2…
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Warning

Some tools did not complete. Review the errors below.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

src/components/Animated-steps-list/AnimatedStepsList.style.js

Parsing error: The keyword 'import' is reserved

src/components/Terminal/Terminal.style.js

Parsing error: The keyword 'import' is reserved


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

Comment @coderabbitai help to get the list of available commands.

@MAYANKSHARMA01010

MAYANKSHARMA01010 commented Sep 5, 2026

Copy link
Copy Markdown
Contributor Author

@dhruveshmishra Review this

@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

🚀 Preview deployment: https://layer5.io/pr-preview/pr-8021/

@dhruveshmishra dhruveshmishra left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@MAYANKSHARMA01010 The spacing between the sections seems a bit too tight. Could you increase the spacing slightly to make the layout look cleaner and more balanced?

@dhruveshmishra dhruveshmishra left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

‎src/components/Terminal/Terminal.style.js

@MAYANKSHARMA01010 There are quite a few changes in Terminal.style.js that seem to be related only to formatting/spacing and pressing Enter, which aren't necessary for this PR. Could you please keep only the changes required for the issue and revert the unrelated formatting changes? This will keep the PR focused and easier to review.

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.

[UI]: Long URLs overflow the Meshery installation terminal

2 participants