mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-09-18 23:10:16 +02:00
fix: cleanup after rebase
This commit is contained in:
@@ -402,6 +402,7 @@ const bootstrapCanvas = ({
|
||||
theme,
|
||||
isExporting,
|
||||
viewBackgroundColor,
|
||||
exportWithFancyBackground,
|
||||
}: {
|
||||
canvas: HTMLCanvasElement;
|
||||
scale: number;
|
||||
@@ -410,6 +411,7 @@ const bootstrapCanvas = ({
|
||||
theme?: AppState["theme"];
|
||||
isExporting?: StaticCanvasRenderConfig["isExporting"];
|
||||
viewBackgroundColor?: StaticCanvasAppState["viewBackgroundColor"];
|
||||
exportWithFancyBackground?: boolean;
|
||||
}): CanvasRenderingContext2D => {
|
||||
const context = canvas.getContext("2d")!;
|
||||
|
||||
@@ -419,7 +421,6 @@ const bootstrapCanvas = ({
|
||||
if (isExporting && theme === "dark") {
|
||||
context.filter = THEME_FILTER;
|
||||
}
|
||||
|
||||
// Paint background
|
||||
if (typeof viewBackgroundColor === "string") {
|
||||
const hasTransparence =
|
||||
@@ -434,7 +435,7 @@ const bootstrapCanvas = ({
|
||||
context.fillStyle = viewBackgroundColor;
|
||||
context.fillRect(0, 0, normalizedWidth, normalizedHeight);
|
||||
context.restore();
|
||||
} else {
|
||||
} else if (!exportWithFancyBackground) {
|
||||
context.clearRect(0, 0, normalizedWidth, normalizedHeight);
|
||||
}
|
||||
|
||||
@@ -924,6 +925,7 @@ const _renderStaticScene = ({
|
||||
theme: appState.theme,
|
||||
isExporting,
|
||||
viewBackgroundColor: appState.viewBackgroundColor,
|
||||
exportWithFancyBackground: renderConfig.exportWithFancyBackground,
|
||||
});
|
||||
|
||||
// Apply zoom
|
||||
|
Reference in New Issue
Block a user