Skip to content
This repository was archived by the owner on Nov 4, 2026. It is now read-only.

fix(types,layout,app-shell,runner)!: the console renders an app's branding.logo; the top-level logo spelling retires (objectui#10827) - #10849

Merged
objectstack-fleet[bot] merged 1 commit into
mainfrom
claude/issue-10827-render-app-branding-logo
Sep 27, 2026
Merged

objectstack-fleet[bot] merged 1 commit into
mainfrom
claude/issue-10827-render-app-branding-logo

Conversation

@objectstack-fleet

Copy link
Copy Markdown
Contributor

Fixes #10827
Clause-②: no

Related cards, referenced only: objectstack-ai/objectstack#20146 (its ledger row app.branding.logo flips planned to live at a later .objectui-sha pin; that is the PM's step and it is not done here) and objectui#10842 (the other four top-level keys wizardDraftToAppSchema writes).

What this does

The console renders branding.logo. UnifiedSidebar, the sidebar ConsoleLayout mounts, reads the active app's branding.logo and draws it as an image in a header at the top of the sidebar. The alt text is the app's label, computed the same way as the AppSwitcher pill. An app without a logo gets no header, so its sidebar is byte-for-byte today's sidebar. That is the control. The header is drawn in app context only: on Home, the sidebar's activeApp falls back to the FIRST app, whose logo is not the screen's. This is the chrome's only reader of the key.

One spelling. @objectstack/spec declares the app logo only as AppBrandingSchema.logo (a URL). Its AppSchema alias table does not fold a top-level logo. It refuses it: measured, AppSchema.safeParse({ name, label, logo }) answers unrecognized_keys with "Did you mean logo → branding?". objectui's second spelling is retired at once, with no dual-read window:

  • @object-ui/types: AppComponentSchema.logo is now never. The zod mirror refuses a top-level logo by name through aliasKeyRefusal, with the same "Did you mean logo → branding?" lead as the spec. It is a named refusal rather than a deletion because the node is .passthrough(), and a deleted key would be KEPT without any error. wizardDraftToAppSchema no longer copies draft.branding.logo to the top level.
  • @object-ui/layout: AppSchemaRenderer's default sidebar header reads schema.branding?.logo and draws any non-empty value as an image. The old read drew an image only for values starting with http, so the objectstack todo example's site-relative /assets/todo-logo.png would have fallen through to an icon lookup. The tile's icon now comes from schema.icon.
  • @object-ui/runner: LayoutRenderer does the same. It reads branding.logo as the image and takes an icon name from icon. It no longer guesses the kind of value from a / or ..
  • Docs: content/docs/core/app-schema.mdx taught a top-level logo in two examples and its properties table. They now use branding: { logo }, and the table gains icon and branding.logo rows. content/docs/guide/console-architecture.md says where the logo is drawn.

Route change from the dispatch, with the reason (Zone 2, B3 falsified)

The dispatch's B3 suggested adding logo to the AppShellBranding object that ConsoleLayout builds. I measured that route and did not take it. objectui#4818 settled that exact fork. The maintainer ruled option 1 (remove AppShellBranding.logo) and explicitly rejected option 2 ("build a real branding context so sidebar/navbar can read it"). The recorded architecture is "the single real logo path stays the app schema's branding.logo, read directly by the sidebar". That removal shipped in 17.6.0 with the migration note "Delete the key … set it on the app schema's branding.logo instead". Adding the key back would have undone a settled ruling and changed a published interface twice.

The route taken is the other option both the triage and the claim offer: UnifiedSidebar (its header). It is the mounted successor of AppSidebar, the sidebar #4818 named. AppShell.tsx and ConsoleLayout.tsx are not touched. Zone 1's wording "beside the primaryColor that useAppShellBranding already carries" is read as describing where the chrome sits, not as a requirement to route the logo through AppShellBranding. I am naming that reading so the seat can overrule it.

File surface outside the claim: packages/runner/src/LayoutRenderer.tsx. This was forced: with logo?: never, its app.logo.includes(…) is a tsc error. It is the same defect class and the same move as AppSchemaRenderer. No open PR touches it (the file lists of the 14 open PRs were read during this run), and the gate family is the same: type-check plus vitest.

Census: top-level logo writers and readers (the stop gate)

Read at base 8eaa1a0, over apps/**, examples/**, content/docs/** and packages/**, excluding CHANGELOGs and locale packs.

  • logo: key writes: 23 hits. Top-level logo on an app has 1 production writer, wizardDraftToAppSchema, which this PR removes. The other hits are: the zod mirror's own declaration of the key (now the refusal); 2 doc examples (moved to branding.logo); 2 test fixtures (re-spelled); branding.logo writers, the positive control (AppCreationWizard ×2, BrandingEditor, EditAppPage's draft, app-creation-types ×5); and unrelated keys (organisation logo ×2, header-bar ×3, a record field fixture ×2). The last hit is the CLI's own routed-project app.json vocabulary: a fixture logo: 'Flame', typed by the CLI's local AppConfig, not by AppComponentSchema.
  • ⇒ No writer of a top-level app logo exists outside the wizard. The stop condition does not fire. No writer puts an icon NAME into an AppComponentSchema top-level logo either (B2). The only icon-name logo is in the CLI's separate vocabulary.
  • Readers of a top-level app logo: AppSchemaRenderer and the runner's LayoutRenderer (both moved), plus EditAppPage's pre-fill fallback, which is left alone (see Acceptance notes).
  • Positive control, branding.logo / branding?.logo: 11 hits on an app's branding (the designer's AppCreationWizard ×3 and BrandingEditor ×5, EditAppPage, app.ts and the console README). The same pattern also hits 6 unrelated lines: the operator's branding.logoUrl in runtime-config.ts ×4 and the embeddable form's own branding.logo ×2.
  • objectstack examples/ at origin/main 733822cf, read-only: 0 top-level app logo. branding.logo has one hit, in app-todo's todo.app.ts, inside branding (the control). The app-crm and app-showcase apps declare branding with a colour only.

Verification: all at 6ea8f67

  • Pins, new:
    • ConsoleLayout.appBrandingLogo-10827.test.tsx mounts the real ConsoleLayout, the real AppShell and the real UnifiedSidebar under the real NavigationProvider. It checks four cases. A branded app shows its logo, named by its label. CONTROL: an app without a logo shows no image. An app with only a top-level logo shows nothing. The active app wins over the first app. Separately, Home context draws no logo.
    • AppSchemaRenderer.brandingLogo-10827.test.tsx: relative, absolute and data: URLs are drawn. The CONTROL shows no image and the default icon. The retired key is drawn neither as an image nor as an icon name.
    • LayoutRenderer.brandingLogo-10827.test.tsx (runner): the same three cases, with Box as the control.
    • app-logo-one-spelling-10827.test.ts (types): a named refusal at path logo with code invalid_type, whatever the value. The TypeScript face refuses the key (@ts-expect-error). The wizard output has no logo key and parses green through the refusing mirror. A spec control shows the spec refuses the top-level key and accepts branding.logo.
  • pnpm exec vitest run --maxWorkers=2 packages/types/ packages/layout/ packages/runner/: Test Files 282 passed (282), Tests 5682 passed (5682).
  • pnpm exec vitest run --maxWorkers=2 packages/app-shell/src/layout/ packages/app-shell/src/__tests__/: Test Files 48 passed (48), Tests 626 passed (626).
  • pnpm --workspace-concurrency=2 --filter @object-ui/types --filter @object-ui/layout --filter @object-ui/app-shell --filter @object-ui/runner run type-check: each script echoed (packages/X type-check$ tsc --noEmit && … tsc -p tsconfig.test.json), and each ends Done. The command exited 0. This ran after a turbo build of the dependency closure: Tasks: 28 successful, 28 total. --listFiles confirms that each package's tsconfig.test.json contains its new test.
  • Reverse verification (cross-package type): a temporary runner/src probe wrote { type: 'app', logo: '/x.svg' }. The runner's tsc --noEmit exited 2 with TS2322: Type 'string' is not assignable to type 'undefined', which proves the runner reads the rebuilt dist/app.d.ts. The probe was removed and git status is clean.
  • Ablation of the chrome reader (ablation-replace.mjs, commit first, WRAP mode): activeApp?.branding?.logo was changed to activeApp?.logo, with anchor count 1 → 0 and blob 0ef580a5b1b1 → 0b4febdb08ed. The console pin went 3 failed | 2 passed (5): the branded app, the alias and the active-app cases failed, and the CONTROL and Home cases stayed green, which is the expected direction. The restore was git checkout HEAD -- ABS_PATH: blob == HEAD (0ef580a5b1b1), and git diff HEAD is empty.
  • Docs control: the app-schema.mdx example was put back to the top-level logo through the same tool. pnpm check:doc-snippets then failed with content/docs/core/app-schema.mdx … TS2322 (678 of 678 block(s) judged, 1 failed), and the restore was proven the same way. At HEAD: 678 of 678 block(s) judged, 0 failed.
  • Gates at HEAD, all exit 0:
    • check-changeset-presence (12 source file(s) of 4 released package(s) changed … declares 1 changeset(s)), check-changeset-fixed, check-changeset-no-major, check-changeset-overwrite.
    • check:changeset-claims: 12 pending changesets name files touched here, and each paragraph was read. None is falsified: none speaks of the app logo.
    • check:pending-changeset-literals, check:new-line-citations (0 new citation(s)), check:control-bytes, check:vi-mock-specifiers, check:vi-mock-inherit, check:vi-mock-override-shape, check:test-path-roots.
    • check:doc-types, check:doc-fences, check:doc-example-ids, check:doc-snippets, check:doc-examples, check-doc-expression-carriage, docs:check-links, check:i18n-keys, check:spec-symbols, check:unreferenced-sources.
    • check-governed-queue-guard --test on the 15 paths: NOT GOVERNED.
  • Lint, a declared narrowing:
    • Population: every package's lint is eslint ., and the rule-bearing config objects match **/*.{ts,tsx}.
    • Counted: eslint --format json over the 12 touched .ts/.tsx files gives 12 files, 0 errors and 18 warnings, and 0 of those warnings fall on an added line.
    • Invariance: eslint.config.js sets no parserOptions.project or projectService, so type-aware linting is off, and no custom rule reads the disk. This diff therefore cannot move a verdict on a file it does not touch.
  • NOT MEASURED:
    • The rest of packages/app-shell: the whole-package run passed the 590 s foreground cap and was stopped. The layout directory and the source scans were run. The rest is left to CI.
    • The rendered sidebar in a real browser. The layout is Tailwind utilities only (h-8 w-auto max-w-full object-contain).
    • Whether the wizard's save door (client.meta.saveItem) refuses the other four top-level keys. That is objectui#10842.

Changeset

.changeset/10827-app-branding-logo-one-spelling.md bumps @object-ui/types minor, with the break stated: AppComponentSchema.logo is never and refused by name. @object-ui/layout, @object-ui/app-shell and @object-ui/runner are patch, because no published prop moves. It names the published 17.6.0 changelog sentence that is now false: the one saying the top-level logo is "rendered directly by AppSchemaRenderer's default sidebar header".

Acceptance notes (not filed, per the dispatch's scope rules)

  • EditAppPage's pre-fill still reads appToEdit.branding?.logo || appToEdit.logo. That is a consumer-side fallback onto the retired spelling. Its { ...appToEdit, ...appSchema } merge also passes a stored top-level logo through on save. The claim fences plugin-designer, and this is not needed for compilation (appToEdit is any), so it is left for the card that edits that file next. The favicon twin sits on the adjacent line. Carrier: objectui#10842.
  • favicon has the same two spellings (B5), and they are not changed here. Census at base:
    • Top-level writers: wizardDraftToAppSchema (the only production writer), 2 doc examples, and 1 test fixture.
    • Top-level readers: AppSchemaRenderer (it feeds AppShell's favicon from schema.favicon and never reads branding.favicon) and EditAppPage's fallback.
    • branding.favicon readers: ConsoleLayout into useAppShellBranding (live in the console), the designer's editors, and EditAppPage.
    • The spec refuses a top-level favicon (unrecognized_keys). Carrier: objectui#10842.
  • The CLI's routed-project scaffold reads its own app.json's logo as an icon name, in its generated layout. That vocabulary is separate (a local AppConfig with title / logo / menu), is not validated against AppComponentSchema, and has no in-tree producer beyond its test fixture. It is untouched.
  • UX placement: the logo sits at the top of the sidebar, not in the top bar. The top bar's leftmost tile is the operator's platform logo (getLogoUrl()), which already takes the app's primaryColor through bg-primary.

Generated by Claude Code

… the console; retire the top-level logo spelling

UnifiedSidebar, the console's mounted sidebar, now reads the active app's
branding.logo and shows it as a header image. An app without a logo keeps
today's sidebar. Nothing mounted rendered the key before: its only reader
was the never-mounted AppSidebar.

The logo has one spelling. AppComponentSchema.logo is `never` on the TS
face and refused by name on the zod mirror ("Did you mean logo -> branding?",
the spec's own answer); wizardDraftToAppSchema stops copying the logo to the
top level; AppSchemaRenderer and the runner's LayoutRenderer read
branding.logo as an image URL and take an icon name from `icon`.

Claude-Session: https://claude.ai/code/session_01MCg3z5cGrV51xEddpGcxEY
Co-authored-by: Claude <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

changeset-claim-re-read

⚠️ 12 pending changeset(s) describe a file this change touches

Their bodies publish verbatim into the CHANGELOG at the next release, so this is a request to re-read them against your diff — addressed here because you are the one seat that can answer it without re-deriving anything.

⛔ Nothing here blocks, and nothing here is a verdict on your change. This gate exits 0, is not a required context, and judges name resolution, never meaning: it asked whether a pending body names a file you touched. "Is this sentence still true?" is the one question it will not answer, and the one you are being asked to answer.

.changeset/4895-retire-block-schema-family.md

  • names phase2-schemas.test.ts → packages/types/src/__tests__/phase2-schemas.test.ts — edited by this change

    The zod half is the one that mattered. AnyComponentSchema.safeParse({ type: 'block-library' }) returned success on 17.6.0 for a node no page can render, so an author who copied the documented shape was told green by the shipped validator and then got the registry's OBJUI-001 "Unknown component type" panel. Validated-then-broken is worse than never-validated, because the green light is what the author trusted. All five discriminants — block, block-library, block-editor, block-instance, component — are now refused, pinned in phase2-schemas.test.ts alongside the theme refusals retired the same way.

  • names zod/app.zod.ts → packages/types/src/zod/app.zod.ts — edited by this change

    ⚠️ Not this family, and not touched. The live slotted record-page vocabulary — PageNodeSchema.kind === 'slotted' with slots?: PageSlotMap (packages/types/src/layout.ts), rendered by usePageAssignment / PageBlockCanvas / PageBlockInspector in @object-ui/app-shell — shares the words "block" and "slot" with the retired family and shares no declaration, type or file with it. Neither is the type: 'component' NAVIGATION item kind ({ type: 'component', componentRef }, NavigationItemSchema in zod/app.zod.ts), a different declaration in a different module.

.changeset/6335-starred-apps-nav-exclusion.md

  • names UnifiedSidebar.tsx → packages/app-shell/src/layout/UnifiedSidebar.tsx — edited by this change

    StarredApps now filters items to type !== 'nav' before rendering — the same exclusion already applied to the sidebar Favorites list in UnifiedSidebar.tsx — restoring declared-equals-enforced behaviour and making the missing locale key correct by construction. No locale packs were touched, and the FavoriteItem / RecentItem union types are unchanged.

.changeset/6349-types-internal-name-collisions-batch-2.md

  • names app.ts → packages/types/src/app.ts — edited by this change

    MenuItem — renamed to AppMenuItem in app.ts. app.ts declared a flat, all-optional interface (type?: 'item' | 'group' | 'separator', label, icon, path, href, children, badge, hidden) — the @deprecated legacy navigation item that AppComponentSchema.menu, AppAction.items and menuItemToNavigationItem read. overlay.ts declared a discriminated union, MenuCommandItem | MenuDividerItem, whose command arm requires label and whose both arms tombstone type as type?: never (objectui#6523) — precisely the key app.ts declares as a three-value enum. Re-pointing either at the other would have made an authored type: 'separator' legal on one side and a type error on the other, so the two names had to part. @object-ui/types continues to publish overlay's union as MenuItem and app's interface as AppMenuItem, exactly as before.

.changeset/7113-chart-data-model.md

  • names app.zod.ts → packages/types/src/zod/app.zod.ts — edited by this change

    .extend() with a NEW key still works and preserves the fold and the refinement; .optional(), z.discriminatedUnion, z.toJSONSchema and safeValidateSchema are all unaffected. Nothing in this repository calls the throwing combinators on either const, and the published surface already ships refined mirrors (objectql.zod.ts, complex.zod.ts, form.zod.ts, app.zod.ts), so the class is not new — but it is a real behaviour change on a published export and it belongs in the release note rather than in a reviewer's file.

.changeset/7344-handler-string-any-mirrors.md

.changeset/7719-app-menu-item-shortcut-named-refusal.md

  • names LayoutRenderer.tsx → packages/runner/src/LayoutRenderer.tsx — edited by this change

    ⛔ LayoutRenderer 未恢复任何读点,objectui#6854 的那枚 pin 断言原样保留;本次只修了它与 LayoutRenderer.tsx 里已经过期的散文(两处都在把一个已裁决的问题描述成悬而未决)。 @object-ui/runner 的改动仅为注释,无任何已发布行为变化。

.changeset/7735-zod-mirrors-stop-authoring-defaults.md

  • names app.zod.ts → packages/types/src/zod/app.zod.ts — edited by this change

    What changed. All 41 .default() call sites under packages/types/src/zod/ are removed — layout.zod.ts 22, crud.zod.ts 11, form.zod.ts 5, views.zod.ts 2, app.zod.ts 1. @object-ui/components reconciles the third face objectui#8229 found: flex's registration defaultProps.align seeded 'center', the value its own renderer never applies, so a designer-made node laid out differently from a hand-authored one; it now seeds 'start'.

.changeset/7918-zod-lazy-getter-identity.md

  • names app.zod.ts → packages/types/src/zod/app.zod.ts — edited by this change

    ⚠️ Also settled while locating the ten: AppMenuItemSchema has no declaration of its own — it is the barrel alias of app.zod.ts's MenuItemSchema, while the barrel's own MenuItemSchema is overlay.zod.ts's. Two different schemas, so the list really is ten entries and not nine.

.changeset/8871-page-node-refuses-breadcrumbs.md

  • names page-app-dashboard-spec-parity.test.ts → packages/types/src/__tests__/page-app-dashboard-spec-parity.test.ts — edited by this change

    Scope. One key, by name; the node is not strict. Only 2 of the 23 passthrough- surviving undeclared keys land on a real SDUI page node (actions and this one); the rest belong to different declarations that merely spell type: 'page'. Strictness would also have reddened a living pin — page-app-dashboard-spec-parity.test.ts, "the component envelope still passes unknown renderer props through" — which stays green and is re-asserted from this card's side.

.changeset/9092-inline-locale-declared-face.md

  • names app.ts → packages/types/src/app.ts — edited by this change

    • AppComponentSchema.label (app.ts) - ObjectGridSchema.label and .description (objectql.ts) - PageNodeSchema.aria.ariaLabel (layout.ts)

.changeset/9187-record-highlights-layout-two-values.md

  • names phase2-schemas.test.ts → packages/types/src/__tests__/phase2-schemas.test.ts — edited by this change

    ⚠️ The census behind this narrowing covers this repository only, and it found no in-repo authoring to migrate: every in-tree layout: 'grid' belongs to a different component (detail-view in content/docs/api/schema-reference.md and phase2-schemas.test.ts, ai-recommendations in packages/plugin-ai/README.md), and the one in-repo consumer of this interface that writes a layout (p1-spec-alignment.test.ts) writes 'horizontal'. So no document in this repository stops type-checking. A TypeScript consumer outside this repo that wrote grid is not observable from here and gets a compile error (TS2322) naming the key — which is why the FROM/TO is spelled out above.

.changeset/action-callback-retired-7068.md

  • names phase2-schemas.test.ts → packages/types/src/__tests__/phase2-schemas.test.ts — edited by this change

    What was measured, on this branch's base (900f8d99). ActionCallback ({ type: 'toast' | 'message' | 'redirect' | 'reload' | 'custom' | 'ajax' | 'dialog', message?, url?, api?, method?, dialog?, handler? }) was declared in crud.ts, mirrored in zod/crud.zod.ts, re-exported by both barrels, and carried on the legacy ActionSchema as onSuccess? / onFailure?. Producers: the package's own phase2-schemas.test.ts fixture and three ts fences in content/docs/core/enhanced-actions.mdx — nothing else (git grep -l ActionCallback over packages content skills hit the five packages/types files; positive control SchemaNodeSchema hit 22). Runtime readers: none — ActionRunner imports UIActionSchema, never this interface, and its own ActionDef.onFailure is a different (runner-native) meaning. It was the THIRD meaning of one key: objectui#5934 had already retired the runner's callback meaning of onSuccess and converged it on the spec's block.

Read the paragraph, not the line: both false halves of the objectui#8617 claim sat in one paragraph, and correcting either alone would have left it asserting the same wrong thing.

If a claim did go false, correct the body. That is precedented and prose-only, frontmatter untouched; check-changeset-overwrite.mjs will report the correction as its own case 2 ("correcting a declaration on purpose … legitimate"), which is the intended shape — one gate asks for the read, the other records the write.

Not covered, stated so nobody reads this as more: a born-false claim that spells no line address at all (objectui#9495 coordinated one by ORDINAL — "a grep finds that member first" — and deciding that means reading what the sentence means), a claim spelled as a symbol or a package rather than a backticked file name, and a file named ambiguously.

Compared the checked-out tree with 184cfe109 (merge-base with origin/main): 14 file(s) changed outside .changeset/, read against 1628 pending declaration(s) that publish a body (2217 pending in total). · run

@github-actions

Copy link
Copy Markdown
Contributor

✅ Console Performance Budget

Metric Value Budget
Eager closure (gzip, 329 chunks) 3080.0 KB 3104.5 KB
Main entry chunk (gzip) 148.4 KB 350 KB
Entry file index-Ds7-aWr1.js —
Status PASS —

The eager closure is every chunk the entry reaches through static imports — what the browser fetches and parses before the app renders. The entry chunk on its own is a small fraction of it.


📦 Bundle Size Report

Package Size Gzipped
app-shell (consoleActionDispatch.js) 0.20KB 0.19KB
app-shell (index.js) 16.57KB 6.15KB
app-shell (runtime-config.js) 20.68KB 7.36KB
app-shell (types.js) 0.01KB 0.04KB
app-shell (urlParams.js) 10.06KB 3.86KB
auth (ActiveOrganizationStorage.js) 27.95KB 10.04KB
auth (AuthContext.js) 0.31KB 0.24KB
auth (AuthGuard.js) 2.07KB 1.00KB
auth (AuthProvider.js) 40.17KB 10.58KB
auth (AuthShell.js) 3.49KB 1.40KB
auth (ForgotPasswordForm.js) 12.21KB 3.45KB
auth (LoginForm.js) 18.15KB 5.39KB
auth (PreviewBanner.js) 0.90KB 0.50KB
auth (RegisterForm.js) 6.65KB 2.22KB
auth (SocialSignInButtons.js) 9.61KB 3.89KB
auth (UserMenu.js) 3.39KB 1.21KB
auth (auth-gate-events.js) 1.29KB 0.66KB
auth (authStyles.js) 5.04KB 1.72KB
auth (createAuthClient.js) 40.21KB 10.80KB
auth (createAuthenticatedFetch.js) 8.52KB 3.45KB
auth (index.js) 3.63KB 1.64KB
auth (invitation-status.js) 1.22KB 0.70KB
auth (org-roles.js) 6.66KB 2.78KB
auth (phone-identifier.js) 1.11KB 0.66KB
auth (types.js) 0.59KB 0.35KB
auth (useAuth.js) 5.30KB 1.02KB
auth (useWorkspaceAdminStatus.js) 11.08KB 4.58KB
collaboration (CommentThread.js) 27.13KB 7.95KB
collaboration (LiveCursors.js) 3.17KB 1.27KB
collaboration (PresenceAvatars.js) 6.49KB 2.64KB
collaboration (PresenceProvider.js) 2.79KB 1.13KB
collaboration (index.js) 1.68KB 0.73KB
collaboration (useCollaborationTranslation.js) 6.05KB 2.52KB
collaboration (useCommentSearch.js) 1.98KB 0.88KB
collaboration (useConflictResolution.js) 7.75KB 1.86KB
collaboration (useMentionNotifications.js) 1.81KB 0.68KB
collaboration (usePresence.js) 6.33KB 1.84KB
collaboration (useRealtimeSubscription.js) 7.91KB 2.01KB
components (index.js) 556.80KB 133.32KB
core (index.js) 9.92KB 3.93KB
create-plugin (index.js) 27.94KB 9.51KB
data-objectstack (index.js) 225.01KB 62.50KB
fields (index.js) 261.26KB 66.37KB
i18n (LocalizationContext.js) 1.76KB 0.96KB
i18n (builtinAggregateLabels.js) 0.86KB 0.49KB
i18n (currency.js) 2.59KB 1.22KB
i18n (fallbackInterpolation.js) 6.25KB 2.77KB
i18n (i18n.js) 8.87KB 3.64KB
i18n (index.js) 5.24KB 2.27KB
i18n (pickLocalized.js) 9.86KB 3.95KB
i18n (provider.js) 39.40KB 12.91KB
i18n (translateFn.js) 0.20KB 0.18KB
i18n (useDisplayLocale.js) 3.52KB 1.76KB
i18n (useObjectLabel.js) 34.34KB 9.17KB
i18n (useSafeTranslation.js) 5.60KB 2.33KB
layout (index.js) 39.27KB 11.09KB
mobile (MobileProvider.js) 0.92KB 0.49KB
mobile (ResponsiveContainer.js) 0.94KB 0.38KB
mobile (breakpoints.js) 1.51KB 0.70KB
mobile (createOfflineDataSource.js) 5.61KB 1.75KB
mobile (index.js) 1.99KB 0.87KB
mobile (offlineQueue.js) 3.91KB 1.35KB
mobile (pwa.js) 0.97KB 0.49KB
mobile (serviceWorker.js) 1.48KB 0.62KB
mobile (serviceWorkerSource.js) 3.41KB 1.48KB
mobile (useBreakpoint.js) 1.54KB 0.65KB
mobile (useGesture.js) 6.96KB 1.98KB
mobile (useOfflineSync.js) 1.99KB 0.72KB
mobile (usePullToRefresh.js) 6.62KB 2.45KB
mobile (useResponsive.js) 0.72KB 0.42KB
mobile (useSpecGesture.js) 5.52KB 2.10KB
mobile (useTouchTarget.js) 1.01KB 0.54KB
permissions (MePermissionsProvider.js) 13.52KB 4.88KB
permissions (PermissionContext.js) 0.31KB 0.25KB
permissions (PermissionGuard.js) 0.89KB 0.45KB
permissions (PermissionProvider.js) 6.24KB 2.16KB
permissions (discardProofCache.js) 1.04KB 0.55KB
permissions (evaluator.js) 8.33KB 3.07KB
permissions (index.js) 0.93KB 0.41KB
permissions (store.js) 0.91KB 0.42KB
permissions (useFieldPermissions.js) 1.28KB 0.53KB
permissions (usePermissions.js) 4.83KB 2.27KB
plugin-ai (index.js) 16.01KB 3.93KB
plugin-calendar (index.js) 51.67KB 14.70KB
plugin-charts (index.js) 83.99KB 22.86KB
plugin-chatbot (index.js) 197.67KB 46.90KB
plugin-dashboard (index.js) 135.78KB 36.13KB
plugin-designer (index.js) 216.25KB 44.39KB
plugin-detail (index.js) 233.48KB 61.79KB
plugin-editor (index.js) 2.23KB 1.05KB
plugin-form (index.js) 158.78KB 40.61KB
plugin-gantt (index.js) 169.83KB 41.99KB
plugin-grid (index.js) 218.66KB 59.90KB
plugin-kanban (index.js) 48.43KB 15.11KB
plugin-list (index.js) 114.78KB 28.44KB
plugin-map (index.js) 22.90KB 7.62KB
plugin-markdown (index.js) 13.88KB 4.80KB
plugin-report (index.js) 44.16KB 12.17KB
plugin-timeline (index.js) 30.91KB 9.05KB
plugin-tree (index.js) 11.21KB 3.89KB
plugin-view (index.js) 87.89KB 22.03KB
providers (DataSourceProvider.js) 0.75KB 0.39KB
providers (MetadataProvider.js) 1.37KB 0.59KB
providers (ThemeProvider.js) 1.90KB 0.85KB
providers (UploadProvider.js) 11.81KB 3.58KB
providers (index.js) 0.45KB 0.23KB
providers (types.js) 0.01KB 0.04KB
react-runtime (index.js) 5.62KB 2.34KB
react (LazyPluginLoader.js) 4.47KB 1.63KB
react (SchemaRenderer.js) 119.16KB 39.05KB
react (data-invalidation.js) 5.05KB 2.08KB
react (index.js) 4.03KB 1.86KB
react (schema-input.js) 4.25KB 2.04KB
react (spec-input.js) 0.20KB 0.18KB
sdui-parser (body-dialect.js) 4.78KB 2.09KB
sdui-parser (codegen.js) 7.50KB 3.05KB
sdui-parser (dashboard-widget-options.js) 3.08KB 1.30KB
sdui-parser (index.js) 6.16KB 2.71KB
sdui-parser (input-type.js) 2.84KB 1.40KB
sdui-parser (kanban-quick-add.js) 3.89KB 1.87KB
sdui-parser (parse.js) 25.28KB 7.80KB
sdui-parser (provenance.js) 3.84KB 1.90KB
sdui-parser (types.js) 0.28KB 0.23KB
sdui-parser (validate.js) 18.27KB 6.20KB
types (ai.js) 4.11KB 2.06KB
types (api-types.js) 0.20KB 0.18KB
types (app.js) 2.99KB 1.07KB
types (base.js) 0.20KB 0.18KB
types (blocks.js) 0.20KB 0.18KB
types (complex.js) 2.93KB 1.49KB
types (crud.js) 0.20KB 0.18KB
types (dashboard-filter-alias.js) 6.23KB 2.74KB
types (data-display.js) 3.75KB 1.85KB
types (data-protocol.js) 0.20KB 0.19KB
types (data.js) 0.20KB 0.18KB
types (designer.js) 1.85KB 0.85KB
types (disclosure.js) 0.20KB 0.18KB
types (error-code.js) 1.54KB 0.88KB
types (expression.js) 0.20KB 0.18KB
types (feedback.js) 0.20KB 0.18KB
types (field-types.js) 0.20KB 0.18KB
types (form.js) 0.20KB 0.18KB
types (http-inflight.js) 8.87KB 3.73KB
types (http-retry.js) 4.32KB 2.02KB
types (icon-key-migration.js) 4.26KB 1.63KB
types (index.js) 4.74KB 2.25KB
types (layout.js) 0.20KB 0.18KB
types (managed-by.js) 0.19KB 0.18KB
types (mobile.js) 5.00KB 2.39KB
types (navigation.js) 0.20KB 0.18KB
types (objectql.js) 0.20KB 0.18KB
types (overlay.js) 0.20KB 0.18KB
types (permissions.js) 2.52KB 1.31KB
types (plugin-scope.js) 0.20KB 0.18KB
types (record-components.js) 0.20KB 0.19KB
types (record-semantics.js) 1.28KB 0.67KB
types (registry.js) 0.20KB 0.18KB
types (reports.js) 0.20KB 0.18KB
types (select-option.js) 0.20KB 0.19KB
types (spec-report.js) 5.05KB 1.93KB
types (spec-ui-namespace.js) 0.20KB 0.19KB
types (strict-authoring-face.js) 17.15KB 6.32KB
types (system-fields.js) 3.33KB 1.54KB
types (theme.js) 6.28KB 2.87KB
types (ui-action.js) 8.11KB 3.32KB
types (views.js) 0.20KB 0.18KB
types (widget.js) 0.20KB 0.18KB

Size Limits

  • ✅ Core packages should be < 50KB gzipped
  • ✅ Component packages should be < 100KB gzipped
  • ⚠️ Plugin packages should be < 150KB gzipped

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

Contract review

Served-tier: 93/93 CONTRACT_REVIEW_TIER
Head-sha: 6ea8f67f89f2ace42dc8d7433c54a23cdd0e2fbb

Read: the card thread on objectui#10827 (triage 5858929399, claim 5859129131; the dev report 5859569598 read only for claims to test); objectui#4818 (body and all four comments; the maintainer ruling comment 5339695386 answers 404 on every endpoint this session may use, so its text is taken from the two verbatim relays: the #4818 claim 5349763720 and PR objectui#5366's body); objectui#4830's thread (the ruling's downstream relay); objectstack#20146 (body, triage 5832699195, claim, dev report, review 5859288723); objectui#10842 (body); PR objectui#10617 (body); PR #10849 body, file list (15 files) and the full diff against merge-base 8eaa1a0; head sources of UnifiedSidebar.tsx, ConsoleLayout.tsx, AppShell.tsx, AppSchemaRenderer.tsx, NavigationRenderer.tsx (resolveIcon), runner LayoutRenderer.tsx, types/src/app.ts, types/src/zod/app.zod.ts, tombstone.zod.ts (aliasKeyRefusal), EditAppPage.tsx, useObjectLabel.ts, app-shell/CHANGELOG.md (17.6.0 entry), vitest.config.mts (alias table), the four new pin files and the three edited tests; objectstack packages/spec/src/ui/app.zod.ts (AppSchema alias table, AppBrandingSchema) and shared/strict-object.ts; objectstack examples/**; objectui AGENTS.md §9 (版本号策略, 测试纪律, 怎么跑测试), .changeset/config.json, the changeset 10827-app-branding-logo-one-spelling.md and every pending changeset naming a touched file or logo; the head's check-runs three times; a measured probe of the installed @objectstack/spec 17.4.0; one run of the four pins at the head in a throwaway worktree under the scratch dir (removed afterwards, no force needed).

① Derived judgments

  1. The reader — RIGHT. ConsoleLayout.tsx imports UnifiedSidebar (line 29), mounts it inside the real AppShell (lines 134–136) and sets the navigation context to app on mount (lines 111–115), so UnifiedSidebar is the console's mounted chrome. At head line 213 it reads context === 'app' ? activeApp?.branding?.logo : undefined and, only when that is non-empty, draws a SidebarHeader with an ‹img› whose alt is appLabel({ name, label: resolveKeyedI18nLabel(activeApp.label, t) }); useObjectLabel.appLabel resolves the i18n key and falls back to label ?? name (useObjectLabel.ts:345), so the accessible name is never empty. Absent logo ⇒ no header element at all (the control); Home ⇒ context is not app ⇒ nothing, even though activeApp falls back to the first app there. Census of packages/app-shell/src (non-test): exactly one branding.logo reader, UnifiedSidebar.tsx:213; AppHeader.tsx:439 draws the operator's getLogoUrl(), not the app's. Base UnifiedSidebar had zero ‹img› elements. URL safety: the tree has no img src sanitiser; every other authored-image reader (EmbeddableForm.tsx:531 config.branding.logo, PackageIcon.tsx, AgentPreview.tsx:138, and the designer's own BrandingEditor / AppCreationWizard previews of this same value) passes the raw string, and the tree's scheme sanitisers target href and rich HTML only. An ‹img› src does not execute javascript: and renders a data: image inertly in current browsers, so this reader adds no new exposure class beyond what the designer preview already had; noted in ③.

  2. The route vs the triage wording — RIGHT. Ruling, as relayed verbatim in PR refactor(layout): remove the unread logo key from AppShellBranding #5366's body: 「Maintainer ruling, 2026-08-19, over the 27-card objectui decision-inbox review (comment 5339695386), verbatim: 『全部接受』 — option 1, remove. Option 2 (build a real branding context) was rejected as a permanent provider obligation with zero demand.」 The finding: AppShellBranding.logo 无任何读取方,注释「passed to sidebar/navbar via context」是假的(AppShell 不提供该 context) #4818 claim 5349763720 relays the same and adds 「The single real logo path stays the app schema's branding.logo, read directly by AppSidebar.tsx:194」 and 「⛔ not re-litigable」; PR refactor(layout): remove the unread logo key from AppShellBranding #5366 merged 2026-08-20 and AppShell.tsx at head declares AppShellBranding with primaryColor, accentColor, favicon, title only. The PR does not add logo back (no diff on AppShell.tsx or ConsoleLayout.tsx). The claim's file surface names 「UnifiedSidebar.tsx (its header) and/or AppShell.tsx (useAppShellBranding)」, and both the objectui triage and objectstack#20146's triage (5832699195) name 「UnifiedSidebar's header or AppShell's branding」 as the two options; the ruling forecloses one, the PR takes the other, the mounted successor of the AppSidebar the ruling named. The triage's 「beside the primaryColor that useAppShellBranding already carries」 reads as locating the chrome, not as ordering the carrier; read as the carrier it would contradict a settled ruling, and the ruling wins. No conflict remains that needs the maintainer.

  3. One spelling — RIGHT. Measured against the installed spec (17.4.0): AppSchema.safeParse({ name, label, logo: '/acme.svg' }) answers one unrecognized_keys issue at path [] with 「Unrecognized key(s) on this app: logo. Did you mean logo → branding? …」 (the alias table at app.zod.ts:1387 is logo: 'branding'); branding: { logo } parses. objectui's aliasKeyRefusal('logo', 'branding', 'this app', …) emits 「Unrecognized key(s) on this app: logo. Did you mean logo → branding? …」 — the same lead — as invalid_type at path ['logo'], the structural difference a z.never member has to carry on a .passthrough() mirror (same mechanism as the mirror's existing actions refusal). wizardDraftToAppSchema loses the logo: draft.branding.logo line (app.ts diff) and the types pin asserts hasOwnProperty('logo') === false and a green parse of the wizard output. AppSchemaRenderer.tsx:388–389 reads schema.branding?.logo and resolveIcon(schema.icon) (NavigationRenderer.tsx:234–237: undefined ⇒ FileText); runner LayoutRenderer.tsx:156–157 reads app.branding?.logo and getIcon(app.icon) (line 42: undefined ⇒ null ⇒ Box). Base did read schema.logo as either (resolveIcon(schema.logo) plus startsWith('http') image; runner sniffed / and .). Census at head for an icon name authored in a top-level app logo: none in packages/**, apps/**, examples/**, content/docs/** (TS, JSON, YAML), none in objectstack examples/** (only app-todo's branding.logo, a URL). The single icon-name logo in the tree is the CLI's app-generator.ts:832/898 local AppConfig, a separate vocabulary not typed by AppComponentSchema, untouched. No authored app loses an icon.

  4. Census stop gate — RIGHT, with one flag. Writers of a top-level app logo at base: wizardDraftToAppSchema (removed), two app-schema.mdx examples (moved to branding), the phase2-schemas and page-app-dashboard-spec-parity fixtures (re-spelled), and the mirror's own declaration (now the refusal). Remaining logo: writes at head are all non-app keys (organisation SettingsPage.tsx:101, createAuthClient.ts:823, header-bar, a record-field fixture) or inside branding drafts (AppCreationWizard.tsx:95, EditAppPage.tsx:52). The stop condition does not fire. EditAppPage.tsx:52 still reads appToEdit.branding?.logo || appToEdit.logo as a pre-fill fallback and line 64's { ...appToEdit, ...appSchema } would re-save a stored top-level logo if one existed. That is a reader of the retired spelling, not an originating writer (it can only pass through what the store already holds, and the spec's own door refuses that shape), and it sits in plugin-designer, which the claim fenced; the dev named it in the PR body with carrier objectui#10842, whose body already lists EditAppPage.tsx:68's merged save as unmeasured. Consistent with the card; flagged in ③ as residue with a named carrier.

  5. Scope beyond the claim — RIGHT. packages/runner/src/LayoutRenderer.tsx: with logo?: never, base's app.logo && app.logo.includes('/') is a property access on never, a hard tsc error, so the file is forced; same defect class, same gate family, declared in the PR body, and no file the PR touches changed on main between the merge-base and 184cfe1 (40 files moved on main, overlap with the PR's 15: none). packages/types/src/zod/app.zod.ts: the same type's mirror face; the claim's surface names the type's top-level logo, and retiring the TS face alone would leave the mirror accepting logo: string against the parity test's local list. content/docs/core/app-schema.mdx: two examples typed AppComponentSchema with a top-level logo, which check:doc-snippets compiles, so forced; the table row change follows. content/docs/guide/console-architecture.md: six lines saying where the logo is drawn, Zone 3.

  6. Semver and prose — RIGHT. Changeset: @object-ui/types: minor with the break stated (「breaking for a top-level logo」, migration to branding: { logo } and icon), layout / app-shell / runner: patch; no major; AGENTS.md §9 版本号策略 says objectui's own breaking change is minor with the semantics in the body, which this is. Every sentence of the changeset checked: the 「never mounted, since removed」 reader (PR refactor(app-shell)!: remove the unmounted AppSidebar (objectui#5817) #10617), the alt text (appLabel), the no-header control, the Home behaviour (context === 'app'), 「AppShellBranding is unchanged」 (head AppShell.tsx), the spec's refusal-with-suggestion (measured), base's 「Logo URL or icon name」 doc string (base app.ts:465), the .passthrough() reason (tombstone.zod.ts), the old startsWith('http') read and / . sniff (base diff), and the 17.6.0 CHANGELOG sentence it names as now false (app-shell/CHANGELOG.md:27 「rendered directly by AppSchemaRenderer's default sidebar header」) — all true. PR title fix(types,layout,app-shell,runner)!: follows the repo's own precedent (PR refactor(app-shell)!: remove the unmounted AppSidebar (objectui#5817) #10617 refactor(app-shell)!:) and matches the commit subject. Body: first line Fixes #10827, then Clause-②: no; objectstack#20146 and objectui#10842 appear under 「Related cards, referenced only」 with no closing keyword. Clause-②: no holds: the accept set only shrinks (a formerly accepted key is refused), no export is added. Commit trailers are Claude-Session: and a model-free Co-authored-by.

  7. Pins — RIGHT. Run once at the head under os-verify-lock (slot review-10849, acquired after 0 s, held 14 s): Test Files 4 passed (4), Tests 25 passed (25), 12.17 s, which matches the case count in the sources (console 5, layout 5, runner 3, types 12). No timeout argument, no skip or todo in any of the four files. The console pin imports the real ConsoleLayout, UnifiedSidebar, NavigationProvider and, through ConsoleLayout, the real AppShell; its mocks are providers and siblings only, and it reads images inside [data-sidebar="sidebar"]. Controls: console (no-logo app ⇒ no image; Home ⇒ no image), layout (FileText, no image), runner (Box, no image), types (branding.logo parses; spec refuses top-level and accepts branding.logo). Each file fails on base by construction: base UnifiedSidebar has no ‹img› (branded and active-app cases red); base AppSchemaRenderer never read branding.logo and drew an http alias as an image (three branding cases and the alias case red); base runner read app.logo (branding case and alias case red); base mirror accepted logo: string and the wizard wrote it (refusal cases and the hasOwnProperty case red). The @ts-expect-error leg is exercised by tsc only (vitest strips types); the head's Type Check job is green.

② Semver level

minor for @object-ui/types (a published type key retires: AppComponentSchema.logo becomes never and is refused by name — a breaking narrowing, stated as such in the changeset body); patch declared for @object-ui/layout, @object-ui/app-shell, @object-ui/runner. Under .changeset/config.json's single fixed group the whole group moves minor. Never major, per AGENTS.md §9; check-changeset-no-major and CI's Changeset Bump Policy agree.

③ Boundary flags

  • Ruling provenance: comment 5339695386 is unreachable (404 on objectui and objectstack issue-comment and PR-comment endpoints; the search API is closed to this session). Its text is quoted from two independent verbatim relays (PR refactor(layout): remove the unread logo key from AppShellBranding #5366's body and the finding: AppShellBranding.logo 无任何读取方,注释「passed to sidebar/navbar via context」是假的(AppShell 不提供该 context) #4818 claim) that agree; the finding: app-shell.mdx 的 Features/Styling 散文完全不提 branding 与 rightRail —— 键表已补齐(#4808/PR4829),散文半截待 #4818 裁定 logo 后写 #4830 thread and PR refactor(layout): remove the unread logo key from AppShellBranding #5366's merge corroborate the outcome.
  • Residue, not this PR's defect: EditAppPage.tsx:52 keeps || appToEdit.logo as a pre-fill fallback and line 64's spread would re-save a stored top-level logo; appToEdit is any, so nothing forces it. Carrier objectui#10842 already names the EditAppPage save; the dev noted it there in the PR body but did not comment on [finding] the app creation wizard saves wizardDraftToAppSchema output with top-level type/title/logo/favicon/layout, which objectstack's AppSchema refuses as unrecognized keys #10842.
  • Triage wording: the triage said a top-level logo 「folds into」 branding; measured, the spec refuses it (unrecognized_keys with the suggestion). objectstack#20146's review already corrected the same word. The PR body states the refusal correctly.
  • The ‹img› src is an authored string with no scheme filter, consistent with every other image reader in the tree and with the designer's own preview of the same value; no new exposure class, but it is the first mounted console surface to draw an author-supplied image URL.
  • mergeable_state: behind: main is at 184cfe1, 40 files past the merge-base 8eaa1a0; none overlaps the PR's 15 files. The PR is a draft with one commit.
  • CI on the head, poll 1 at 2026-09-27T20:33:17Z: 42 checks — 28 success, 3 skipped (dependabot, Test (coverage), Test (coverage shard ${{ matrix.shard }}/4)), 11 in progress (Test (shard 1/8) … Test (shard 8/8), Type Check, Lint, Spec Main Shape Gate). Poll 2 at 20:38:10Z: 33 success, 3 skipped, 6 in progress (Test (shard 1/8), (3/8), (4/8), (5/8), Type Check, Spec Main Shape Gate). Poll 3 at 20:40:19Z: 43 checks, 40 success, 3 skipped, 0 in progress, 0 failed — the six above completed success (Type Check 20:38:34Z, shards 3 and 4 20:39:02Z, shard 5 20:39:24Z, shard 1 20:39:50Z, Spec Main Shape Gate 20:39:52Z) and the aggregate Test appeared and completed success at 20:40:01Z. Green checks at poll 3 also include Lint, Build & E2E, Build Docs, Bundle Analysis, Changeset Bump Policy, Changeset Claim Re-read, Changeset Declaration, Changeset Fixed Group Check, Changeset Overwrite Report, Control Byte Scan, Doc Component Type Check, Doc Example Id Check, Doc Fence Language Check, Doc Snippet Type Check, Docs Route Eager Closure Check, Governed Surface Queue Guard, Inert vi.mock Specifier Check, Internal Docs Link Check, Line Citation Gate, Live E2E (informational), Pre-Install Import Graph Check, README Export Check, Shell Escape Residue Scan, Skill Eval Token Check, Skill Example Check, Skill Guide Path Check, Action Ref Convention, Test (dist pins), Test (shard 2/8), (6/8), (7/8), (8/8), label. No annotations to read: no check failed.

Implemented-by: claude/issue-10827-render-app-branding-logo
Reviewed-by: session_01MCg3z5cGrV51xEddpGcxEY

VERDICT: PASS

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[finding] app branding.logo is authored by the designer and documented, but no mounted component renders it since AppSidebar (never mounted) was removed

2 participants