@@ -196,6 +196,7 @@ export default function EquationCellEditor(props: EquationEditorProps) {
196196 mor = { props . equation . lhs }
197197 setMor = { setLhs }
198198 isActive = { props . isActive && activeInput ( ) === "lhs" }
199+ side = "lhs"
199200 exitBackward = { ( ) => setActiveInput ( "name" ) }
200201 exitForward = { ( ) => setActiveInput ( "rhs" ) }
201202 exitUp = { ( ) => setActiveInput ( "name" ) }
@@ -216,6 +217,7 @@ export default function EquationCellEditor(props: EquationEditorProps) {
216217 mor = { props . equation . rhs }
217218 setMor = { setRhs }
218219 isActive = { props . isActive && activeInput ( ) === "rhs" }
220+ side = "rhs"
219221 exitBackward = { ( ) => setActiveInput ( "lhs" ) }
220222 exitForward = { props . actions . activateBelow }
221223 exitUp = { ( ) => setActiveInput ( "lhs" ) }
@@ -240,6 +242,10 @@ type PathPickerProps = {
240242 mor : Mor | null ;
241243 setMor : ( mor : Mor | null ) => void ;
242244 isActive : boolean ;
245+ /** Which side of the equation this picker represents. Drives the
246+ per-side alignment of the diagrammatic display (LHS bottom-aligned,
247+ RHS top-aligned) so the two sides hug the centre `=` sign. */
248+ side : "lhs" | "rhs" ;
243249 exitBackward ?: ( ) => void ;
244250 exitForward ?: ( ) => void ;
245251 exitUp ?: ( ) => void ;
@@ -334,7 +340,7 @@ function PathPicker(props: PathPickerProps) {
334340
335341 return (
336342 < div
337- class = { styles . pathPicker }
343+ class = { ` ${ styles . pathPicker } ${ props . side === "lhs" ? styles . lhs : styles . rhs } ` }
338344 onMouseDown = { ( evt ) => {
339345 // Activate the picker when clicking anywhere inside the
340346 // border, but only when not already in editing mode (so
0 commit comments