Skip to content

finding: ThemeSwitcherSchema / ThemePreviewSchema are the same dead component kind #5489 retires — theme-switcher and theme-preview are registered by nothing either #5647

Description

@os-sales

Found while executing #5489 (retire ThemeComponentSchema, type: 'theme'). Filed unassigned, out of that card's scope — the 2026-08-21 maintainer ruling named the themes carrier and its schema, not these two siblings, so widening #5489 to cover them would have been an undeclared scope expansion.

Measurement

The same sweep that proved 'theme' unregistered proves the same for both siblings. Enumerating every registered component key in non-dist package sources:

grep -rhoE "ComponentRegistry\.(register|registerLazy)\(\s*'[a-z0-9-]+'" \
--include='*.ts' --include='*.tsx' packages/*/src | sed -E "s/.*'([a-z0-9-]+)'/\1/" | sort -u
  • theme-switcher → 0 hits · theme-preview → 0 hits
  • positive control on the same pipeline: tooltip → 1 hit (so the command can match)
  • neither appears in PROTOCOL_COMPONENTS / PALETTE_PLACEHOLDER_BLOCKS (packages/components/src/renderers/placeholders.tsx), so not even a placeholder renders them
  • no fixture anywhere declares them: grep -rn '"type": *"theme-switcher"' and the -preview twin → 0, control "type": "form" → 98

So a page declaring either gets the registry's "Unknown component type" panel (OBJUI-001), never a switcher or a preview — the identical declared-but-unenforced shape #5489 measured for 'theme'.

Declaration sites

  • packages/types/src/theme.tsThemeSwitcherSchema, ThemePreviewSchema (TS interfaces)
  • packages/types/src/zod/theme.zod.ts — the two Zod objects, both members of ThemeUnionSchema, plus ThemeSwitcherSchemaType / ThemePreviewSchemaType
  • exported from packages/types/src/index.ts and packages/types/src/zod/index.zod.ts
  • packages/types/src/__tests__/phase2-schemas.test.ts asserts ThemeSwitcherSchema.safeParse succeeds — a test that pins the declaration, not any behaviour

After #5489 lands, ThemeUnionSchema consists of exactly these two unimplemented kinds, so the union itself becomes a candidate for removal if they go.

Not a decision this card can take

Retiring them removes declared types from the published @object-ui/types, and — unlike #5489 — no maintainer ruling covers them. Needs triage: either a ruling extending 2026-08-21's option B to the two siblings, or a decision to implement renderers.

Metadata

Metadata

Assignees

No one assigned

    Labels

    domain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seatfinding

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions