Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .changeset/appshellbranding-logo-removed.md
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
---
'@object-ui/layout': minor
'@object-ui/app-shell': minor
'@object-ui/console': minor
---

Remove the published optional key `logo` from `AppShellBranding` (`@object-ui/layout`).

The key was declared but never read. `useAppShellBranding` applies only
`primaryColor`, `accentColor`, `favicon` and `title`, and `AppShell` installs no
context provider at all — so its doc comment, "Logo URL — passed to sidebar/navbar
via context", described a mechanism that did not exist. Three call sites were
feeding the key a real value that was silently discarded, and all three are removed
with it: `AppSchemaRenderer`, `ConsoleLayout` and the console's `useBranding` hook.

The real logo entry point is unchanged and is where it always was: the app schema's
own `branding.logo`, read directly by `AppSidebar` in `@object-ui/app-shell`, plus
the app schema's top-level `logo`, rendered directly by `AppSchemaRenderer`'s
default sidebar header. Neither path went through `AppShellBranding`, so nothing
rendering-visible changes.

Migration: a consumer that passes `logo` inside an `AppShellBranding` object literal
now gets a compile error. Delete the key — it never reached a renderer. To show a
logo, set it on the app schema's `branding.logo` instead.
2 changes: 0 additions & 2 deletions apps/console/src/hooks/useBranding.ts
Original file line numberDiff line numberDiff line change
Expand Up@@ -14,7 +14,6 @@ interface AppBranding {
primaryColor?: string;
accentColor?: string;
favicon?: string;
logo?: string;
}

export function useBranding(app: { branding?: AppBranding; label?: string } | undefined) {
Expand All@@ -24,7 +23,6 @@ export function useBranding(app: { branding?: AppBranding; label?: string } | un
primaryColor: app.branding.primaryColor,
accentColor: app.branding.accentColor,
favicon: app.branding.favicon,
logo: app.branding.logo,
}
: undefined,
app?.label ? `${app.label} — ${getProductName()}` : undefined,
Expand Down
1 change: 0 additions & 1 deletion packages/app-shell/src/layout/ConsoleLayout.tsx
Original file line numberDiff line numberDiff line change
Expand Up@@ -171,7 +171,6 @@ export function ConsoleLayout({
primaryColor: activeApp.branding.primaryColor,
accentColor: activeApp.branding.accentColor,
favicon: activeApp.branding.favicon,
logo: activeApp.branding.logo,
title: activeApp.label
? `${resolveKeyedI18nLabel(activeApp.label)} — ${getProductName()}`
: undefined,
Expand Down
1 change: 0 additions & 1 deletion packages/layout/src/AppSchemaRenderer.tsx
Original file line numberDiff line numberDiff line change
Expand Up@@ -579,7 +579,6 @@ export function AppSchemaRenderer({
const branding: AppShellBranding = {
title: schema.title,
favicon: schema.favicon,
logo: schema.logo,
};

// --- Build sidebar element ---
Expand Down
2 changes: 0 additions & 2 deletions packages/layout/src/AppShell.tsx
Original file line numberDiff line numberDiff line change
Expand Up@@ -16,8 +16,6 @@ export interface AppShellBranding {
accentColor?: string;
/** Favicon URL — replaces the <link rel="icon"> href */
favicon?: string;
/** Logo URL — passed to sidebar/navbar via context */
logo?: string;
/** Page title suffix (sets document.title) */
title?: string;
}
Expand Down
Loading