Skip to content

fix: Prevent side menu from being clipped in toggle+column layout#2782

Closed
mkcash wants to merge 1 commit into
TypeCellOS:mainfrom
mkcash:fix/toggle-column-side-menu
Closed

fix: Prevent side menu from being clipped in toggle+column layout#2782
mkcash wants to merge 1 commit into
TypeCellOS:mainfrom
mkcash:fix/toggle-column-side-menu

Conversation

@mkcash
Copy link
Copy Markdown

@mkcash mkcash commented May 26, 2026

Fix

Prevents side menu (+ button) from disappearing when hovering left column in toggle blocks.

Problem

Side menu icons were clipped/hidden in multi-column layouts inside toggle blocks. Column wrapper needed overflow:visible.

Fix

Added overflow:visible to column div render.

Fixes #2526

Summary by CodeRabbit

Release Notes

  • Bug Fixes
    • Fixed column overflow handling to properly display content that exceeds column boundaries.

Review Change Stack

@vercel
Copy link
Copy Markdown

vercel Bot commented May 26, 2026

Someone is attempting to deploy a commit to the TypeCell Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 26, 2026

📝 Walkthrough

Walkthrough

The column's rendered DOM element now explicitly sets overflow: "visible" style during rendering. This single-line change addresses button accessibility within multi-column blocks nested in toggle containers by preventing overflow clipping of action buttons.

Changes

Column overflow visibility

Layer / File(s) Summary
Overflow visibility style assignment
packages/xl-multi-column/src/pm-nodes/Column.ts
Column's renderHTML method explicitly sets column.style.overflow = "visible" to ensure action buttons in the left column remain visible and clickable within toggle blocks.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Suggested reviewers

  • nperez0111
  • matthewlipski

Poem

🐰 A column once hid buttons tight,
Overflow clipped them out of sight,
But now with visible we see,
The + icons dance wild and free! ✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive The PR description explains the problem and fix concisely but deviates from the template structure with minimal sections covered compared to the template requirements. Consider using the template structure with sections for Summary, Rationale, Changes, Impact, Testing, and Checklist to provide comprehensive documentation.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately and concisely describes the main fix: preventing the side menu from being clipped in toggle+column layouts.
Linked Issues check ✅ Passed The code change directly addresses issue #2526 by adding overflow:visible to prevent the side menu from being clipped in toggle+column layouts.
Out of Scope Changes check ✅ Passed The single line change (adding overflow:visible to Column.ts) is directly scoped to fixing the reported issue with no extraneous modifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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 and usage tips.

Copy link
Copy Markdown

@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

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@packages/xl-multi-column/src/pm-nodes/Column.ts`:
- Around line 75-77: The loop that applies HTMLAttributes via
column.setAttribute may overwrite the earlier column.style.overflow = "visible"
if HTMLAttributes includes a style key; update the code that iterates
HTMLAttributes (the for loop over Object.entries(HTMLAttributes) which calls
column.setAttribute) to either skip the "style" attribute and instead merge
styles, or apply HTMLAttributes first and then explicitly set
column.style.overflow = "visible" after the loop; ensure you handle merging of
existing style string with the overflow rule so overflow: visible is preserved
(reference symbols: HTMLAttributes, column.setAttribute, column.style.overflow).
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 68500642-e3bf-475c-8fc8-ac5f4903d2ea

📥 Commits

Reviewing files that changed from the base of the PR and between 118d8dc and 032f56d.

📒 Files selected for processing (1)
  • packages/xl-multi-column/src/pm-nodes/Column.ts

Comment on lines +75 to 77
column.style.overflow = "visible";
for (const [attribute, value] of Object.entries(HTMLAttributes)) {
column.setAttribute(attribute, value as any); // TODO as any
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

overflow: visible is currently overwritten by later style attribute assignment.

On Line 75 you set column.style.overflow = "visible", but Line 77 can overwrite it when HTMLAttributes contains style (e.g., flex-grow from width attrs). That makes this fix non-deterministic and can reintroduce the clipping bug.

Suggested fix
   column.className = "bn-block-column";
   column.setAttribute("data-node-type", this.name);
-  column.style.overflow = "visible";
   for (const [attribute, value] of Object.entries(HTMLAttributes)) {
     column.setAttribute(attribute, value as any); // TODO as any
   }
+  column.style.overflow = "visible";
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
column.style.overflow = "visible";
for (const [attribute, value] of Object.entries(HTMLAttributes)) {
column.setAttribute(attribute, value as any); // TODO as any
column.className = "bn-block-column";
column.setAttribute("data-node-type", this.name);
for (const [attribute, value] of Object.entries(HTMLAttributes)) {
column.setAttribute(attribute, value as any); // TODO as any
}
column.style.overflow = "visible";
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/xl-multi-column/src/pm-nodes/Column.ts` around lines 75 - 77, The
loop that applies HTMLAttributes via column.setAttribute may overwrite the
earlier column.style.overflow = "visible" if HTMLAttributes includes a style
key; update the code that iterates HTMLAttributes (the for loop over
Object.entries(HTMLAttributes) which calls column.setAttribute) to either skip
the "style" attribute and instead merge styles, or apply HTMLAttributes first
and then explicitly set column.style.overflow = "visible" after the loop; ensure
you handle merging of existing style string with the overflow rule so overflow:
visible is preserved (reference symbols: HTMLAttributes, column.setAttribute,
column.style.overflow).

@nperez0111 nperez0111 closed this May 26, 2026
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.

Action buttons of left column in toggle block hover

2 participants