Skip to content

Commit 7f0e33d

Browse files
committed
If sidebar.logo is not specified, keep it as undefined internally.
(cherry picked from commit 526d074)
1 parent fbea21d commit 7f0e33d

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/core/brand/brand.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -344,9 +344,14 @@ export function resolveLogo(
344344
return logo;
345345
};
346346
if (!spec) {
347+
const lightLogo = findLogo("light", order);
348+
const darkLogo = findLogo("dark", order);
349+
if (!lightLogo && !darkLogo) {
350+
return undefined;
351+
}
347352
return {
348-
light: findLogo("light", order) || findLogo("dark", order),
349-
dark: findLogo("dark", order) || findLogo("light", order),
353+
light: lightLogo || darkLogo,
354+
dark: darkLogo || lightLogo,
350355
};
351356
}
352357
if (typeof spec === "string") {

0 commit comments

Comments
 (0)