mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-04-14 16:40:58 -04:00
fix(components/main-menu): not show canvasBackground
This commit is contained in:
parent
9f76f8677b
commit
f3f7d0040c
1 changed files with 6 additions and 1 deletions
|
@ -4,6 +4,7 @@ import {
|
|||
useExcalidrawSetAppState,
|
||||
useExcalidrawActionManager,
|
||||
useExcalidrawElements,
|
||||
useAppProps,
|
||||
} from "../App";
|
||||
import {
|
||||
ExportIcon,
|
||||
|
@ -198,8 +199,12 @@ export const ChangeCanvasBackground = () => {
|
|||
const { t } = useI18n();
|
||||
const appState = useUIAppState();
|
||||
const actionManager = useExcalidrawActionManager();
|
||||
const appProps = useAppProps();
|
||||
|
||||
if (appState.viewModeEnabled) {
|
||||
if (
|
||||
appState.viewModeEnabled ||
|
||||
!appProps.UIOptions.canvasActions.changeViewBackgroundColor
|
||||
) {
|
||||
return null;
|
||||
}
|
||||
return (
|
||||
|
|
Loading…
Add table
Reference in a new issue