Skip to content

fix: read more bug fix on safari - #1152

Open
santipalenque wants to merge 1 commit into
masterfrom
fix/safari-read-more-fail
Open

santipalenque wants to merge 1 commit into
masterfrom
fix/safari-read-more-fail

Conversation

@santipalenque

@santipalenque santipalenque commented Nov 12, 2026 •

Copy link
Copy Markdown

https://app.clickup.com/t/9014802374/86bd2dtbx

Summary by CodeRabbit

  • Bug Fixes
    • Improved the layout of clamped text so the “Read more” toggle stays neatly aligned beneath the text when it appears.

@santipalenque

Copy link
Copy Markdown
Author

/deploy-preview

@coderabbitai

coderabbitai Bot commented Nov 12, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The line-clamped layout places the read-more toggle beside the text box in a bottom-aligned flex container. The text box can shrink, and the toggle keeps its size. The toggle still renders only when isClamped is true.

Changes: ExpandText layout

Layer / File(s) Summary
Line-clamped flex layout
src/components/mui/ExpandText/index.jsx
The text box and read-more toggle now use a bottom-aligned flex layout. The text box can shrink, and the toggle does not shrink. The previous floated toggle and ::before spacer are removed.

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

Possibly related PRs

Suggested reviewers: gcutrini, romanetar

Merge Risk: Minimal · up to f61eb

This moves the read-more toggle beside the clamped text to fix its Safari rendering. No concrete merge-blocking risk was found. Confirm the behavior in Safari using the deploy preview.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title "fix: read more bug fix on safari" matches the main change. The PR moves the expand-text "read more" toggle outside the clamped text box so Safari renders the text. The title names the Safar…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title "fix: read more bug fix on safari" matches the main change. The PR moves the expand-text "read more" toggle outside the clamped text box so Safari renders the text. The title names the Safari fix and the read-more control, which are the primary points. It is short and follows a conventional commit prefix. It does not describe the layout mechanism, but that detail is not required.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: 32b64c84-2167-4a5c-8a99-d3a1eb0fcbdf
Commits

Reviewing files that changed from the base of the PR and between 9eb5a45 and f61ebca.

Files selected for processing: 1

  • src/components/mui/ExpandText/index.jsx

Included review availability: This review used your included allowance. 4 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.

@santipalenque santipalenque self-assigned this Nov 12, 2026
@github-actions

Copy link
Copy Markdown

🚀 Deployed on https://pr-1152--show-admin-preview.netlify.app

@smarcet
smarcet requested review from caseylocker, romanetar and smarcet and a balanced review from Copilot November 13, 2026 17:49

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🔵 Needs a closer look

Safari/WebKit validation is still needed for text visibility, toggle alignment, and resize/collapse behavior because the jsdom tests mock geometry and cannot verify the browser-specific layout fix.

No open issues 🎉

What changed in this PR

This PR addresses Safari rendering issues in the shared ExpandText component by moving the “Read more” toggle outside the clamped text.

Changes:

  • Replaces the floated toggle and spacer with a separate, bottom-aligned flex item.
  • Lets the text area shrink while preserving the toggle’s width.
File Description
src/​components/​mui/​ExpandText/​index.jsx Separates the toggle from the clamped text and adjusts flex sizing and alignment.

Review effort: Balanced

@romanetar romanetar left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM

@caseylocker caseylocker left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM

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.

4 participants