fix: buttons jump around on the mobile menu (#5658)
Update MobileMenu.tsx
This commit is contained in:
parent
b3052f0178
commit
cd61f31116
@ -121,7 +121,6 @@ export const MobileMenu = ({
|
|||||||
const renderAppToolbar = () => {
|
const renderAppToolbar = () => {
|
||||||
// Render eraser conditionally in mobile
|
// Render eraser conditionally in mobile
|
||||||
const showEraser =
|
const showEraser =
|
||||||
!appState.viewModeEnabled &&
|
|
||||||
!appState.editingElement &&
|
!appState.editingElement &&
|
||||||
getSelectedElements(elements, appState).length === 0;
|
getSelectedElements(elements, appState).length === 0;
|
||||||
|
|
||||||
@ -140,9 +139,9 @@ export const MobileMenu = ({
|
|||||||
|
|
||||||
{actionManager.renderAction("undo")}
|
{actionManager.renderAction("undo")}
|
||||||
{actionManager.renderAction("redo")}
|
{actionManager.renderAction("redo")}
|
||||||
{showEraser && actionManager.renderAction("eraser")}
|
{showEraser
|
||||||
|
? actionManager.renderAction("eraser")
|
||||||
{actionManager.renderAction(
|
: actionManager.renderAction(
|
||||||
appState.multiElement ? "finalize" : "duplicateSelection",
|
appState.multiElement ? "finalize" : "duplicateSelection",
|
||||||
)}
|
)}
|
||||||
{actionManager.renderAction("deleteSelectedElements")}
|
{actionManager.renderAction("deleteSelectedElements")}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user