[PR #389] [MERGED] Fix ScrollBox scissor clipping for nested scrollboxes #504

Closed
opened 2026-03-02 23:46:48 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/anomalyco/opentui/pull/389
Author: @acoliver
Created: 12/5/2025
Status: Merged
Merged: 12/8/2025
Merged by: @kommander

Base: mainHead: feature/clip-fix


📝 Commits (3)

  • c8ebb3c Fix nested scrollbox clipping by intersecting scissor rects
  • bdd2509 Merge branch 'main' into feature/clip-fix
  • c6f85e6 chore: fix prettier formatting

📊 Changes

4 files changed (+219 additions, -2 deletions)

View changed files

📝 packages/core/src/renderables/ScrollBox.ts (+1 -1)
📝 packages/core/src/tests/scrollbox.test.ts (+134 -0)
📝 packages/core/src/zig/buffer.zig (+13 -1)
📝 packages/react/tests/layout.test.tsx (+71 -0)

📄 Description

Fixes #388.

Summary

  • intersect scissor rectangles when nesting ScrollBoxes to prevent children from drawing outside parents
  • remove extra padding on ScrollBox viewport to avoid bleed
  • add core and React regression tests covering nested scrollboxes and stacked tool blocks

Testing

  • bun test packages/core/src/tests/scrollbox.test.ts
  • bun test packages/react/tests/layout.test.tsx

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/anomalyco/opentui/pull/389 **Author:** [@acoliver](https://github.com/acoliver) **Created:** 12/5/2025 **Status:** ✅ Merged **Merged:** 12/8/2025 **Merged by:** [@kommander](https://github.com/kommander) **Base:** `main` ← **Head:** `feature/clip-fix` --- ### 📝 Commits (3) - [`c8ebb3c`](https://github.com/anomalyco/opentui/commit/c8ebb3c226001b2bb548cc306522ea6181fae31b) Fix nested scrollbox clipping by intersecting scissor rects - [`bdd2509`](https://github.com/anomalyco/opentui/commit/bdd25098ecde88ba4319698a9b5625fc91f2d530) Merge branch 'main' into feature/clip-fix - [`c6f85e6`](https://github.com/anomalyco/opentui/commit/c6f85e6db7622f4ec711edffb55dbff603bddb2e) chore: fix prettier formatting ### 📊 Changes **4 files changed** (+219 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `packages/core/src/renderables/ScrollBox.ts` (+1 -1) 📝 `packages/core/src/tests/scrollbox.test.ts` (+134 -0) 📝 `packages/core/src/zig/buffer.zig` (+13 -1) 📝 `packages/react/tests/layout.test.tsx` (+71 -0) </details> ### 📄 Description Fixes #388. ## Summary - intersect scissor rectangles when nesting ScrollBoxes to prevent children from drawing outside parents - remove extra padding on ScrollBox viewport to avoid bleed - add core and React regression tests covering nested scrollboxes and stacked tool blocks ## Testing - bun test packages/core/src/tests/scrollbox.test.ts - bun test packages/react/tests/layout.test.tsx --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-02 23:46:48 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/opentui#504
No description provided.