Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

prevent layout shift from new cell buttons (#7276)

Shahmir Varqhabde278b7519e
diff --git a/frontend/src/components/editor/cell/CreateCellButton.tsx b/frontend/src/components/editor/cell/CreateCellButton.tsx
index 093f9cc5d7..8deb2c1e92 100644
--- a/frontend/src/components/editor/cell/CreateCellButton.tsx
+++ b/frontend/src/components/editor/cell/CreateCellButton.tsx
@@ -113,7 +113,7 @@ export const CreateCellButton = ({
<DropdownMenuTrigger asChild={true} onPointerDown={handleButtonClick}>
<Button
className={cn(
- "shoulder-button hover-action border-none shadow-none! bg-transparent! focus-visible:outline-none",
+ "border-none hover-action shadow-none! bg-transparent focus-visible:outline-none",
isAppInteractionDisabled(connectionState) && " inactive-button",
)}
onMouseDown={Events.preventFocus}
diff --git a/frontend/src/components/editor/notebook-cell.tsx b/frontend/src/components/editor/notebook-cell.tsx
index 41cd6b2489..de8cf361a3 100644
--- a/frontend/src/components/editor/notebook-cell.tsx
+++ b/frontend/src/components/editor/notebook-cell.tsx
@@ -839,7 +839,7 @@ const CellLeftSideActions = memo(
className,
)}
>
- <div className="-mt-1">
+ <div className="-mt-1 min-h-7">
<CreateCellButton
tooltipContent={renderShortcut("cell.createAbove")}
connectionState={connection.state}
@@ -849,7 +849,7 @@ const CellLeftSideActions = memo(
</div>
<div className="flex-1 pointer-events-none w-3" />
{/* <div className="flex-1 pointer-events-none bg-border w-px mx-auto hover-action opacity-70" /> */}
- <div className="-mb-2">
+ <div className="-mb-2 min-h-7">
<CreateCellButton
tooltipContent={renderShortcut("cell.createBelow")}
connectionState={connection.state}