Skip to content

Fix otta-landing deploy failure from client-only brand override primitives - #222

Draft
thinkdj with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-failing-github-actions-job
Draft

Fix otta-landing deploy failure from client-only brand override primitives#222
thinkdj with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-failing-github-actions-job

Conversation

Copilot AI commented Aug 15, 2026

Copy link
Copy Markdown

The Deploy @ottabase/otta-landing Actions job was failing during next build prerendering because shared ui-shadcn primitives invoked the client-only useBrandComponent() hook without being declared as client components. This change restores the intended client/server boundary so prerendered routes do not evaluate those hooks on the server.

  • Client boundary correction

    • Mark override-aware ui-shadcn primitives as explicit client components:
      • button
      • badge
      • card
      • input
    • This keeps useBrandComponent() behind a valid client boundary when these primitives are consumed from Next.js routes.
  • Regression coverage

    • Add a focused test that asserts the affected primitive source files retain the 'use client'; directive.
    • The test is path-local and line-ending tolerant to avoid platform-specific failures.
  • Docs

    • Clarify in @ottabase/ui-shadcn README that primitives using the brand override registry are client components and must cross a normal client boundary when rendered from server routes.
'use client';

import { useBrandComponent } from '@ottabase/ui-shadcn/brand-components';

const Button = React.forwardRef<HTMLButtonElement, ButtonProps>((props, ref) => {
    const Override = useBrandComponent('button');
    // ...
});

Copilot AI changed the title [WIP] Fix failing GitHub Actions job Deploy @ottabase/otta-landing Fix otta-landing deploy failure from client-only brand override primitives Aug 15, 2026
Copilot AI requested a review from thinkdj August 15, 2026 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants