Fix diff panel padding and top spacing for virtualized files

- Use horizontal and bottom padding on the diff render surface
- Add top margin to the first diff file for consistent spacing
This commit is contained in:
Julius Marminge committed 2026-03-01 10:30:46 -08:00
1 parent 540e7a3995
commit d3aa5ae0aa
1 file changed
+2 -2
+2 -2
View File
@@ -547,7 +547,7 @@ export default function DiffPanel({ mode = "inline" }: DiffPanelProps) {
</div>
) : renderablePatch.kind === "files" ? (
<Virtualizer
className="diff-render-surface h-full min-h-0 overflow-auto p-2 "
className="diff-render-surface h-full min-h-0 overflow-auto px-2 pb-2"
config={{
overscrollSize: 600,
intersectionObserverMargin: 1200,
@@ -561,7 +561,7 @@ export default function DiffPanel({ mode = "inline" }: DiffPanelProps) {
<div
key={themedFileKey}
data-diff-file-path={filePath}
className="diff-render-file mb-2 rounded-md last:mb-0"
className="diff-render-file mb-2 rounded-md first:mt-2 last:mb-0"
onClickCapture={(event) => {
const nativeEvent = event.nativeEvent as MouseEvent;
const composedPath = nativeEvent.composedPath?.() ?? [];