Skip to content

fix(dashboard): match business context to organization settings - #763

Merged
izadoesdev merged 1 commit into
stagingfrom
codex/business-context-settings-design
Sep 8, 2026
Merged

fix(dashboard): match business context to organization settings#763
izadoesdev merged 1 commit into
stagingfrom
codex/business-context-settings-design

Conversation

@izadoesdev

@izadoesdev izadoesdev commented Sep 8, 2026

Copy link
Copy Markdown
Member

Business Context looked disconnected from Organization Settings: it used a wider unframed layout, an oversized text area, bottom-of-page save controls, and inline source links that were difficult to scan.

Use the same shared cards, column width, spacing, typography, and scrolling layout as General settings. Bound the editor to 12 rows, move Save/Discard to the standard top bar, make mobile labels compact, and display sources as individual rows with page titles and URLs. Loading states use the matching card layout. A synchronous save guard prevents duplicate submissions from the shared desktop/mobile shortcut controls.

Validation: root lint, all 33 type-check tasks, and six authenticated browser regressions including a real keyboard save that submits once. Compared against the actual General settings page, checked light/dark themes and 390px mobile, and preserved the saved local preview brief.

Scope: presentation of the existing business context feature. No API, storage, model, or dependency changes. Based on current staging after #762; no dependency on #751. AI-assisted implementation and visual review.


Summary by cubic

Aligns the business context editor with the Organization Settings design so it uses the same card layout, column width, and top-bar Save/Discard controls as General settings. This is a presentation-only change; no API, storage, model, or dependency behavior changes.

Details

  • Bounds the editor to 12 rows, compacts mobile labels, and shows sources as rows with page titles and URLs.
  • Matches the loading state to the editor's new structure.
  • Adds a synchronous save guard so keyboard and button saves can't submit duplicate requests; the e2e test now saves via keyboard and asserts one request.

Written for commit 8e0e82d. Summary will update on new commits.

Review in cubic

@unkey-deploy

unkey-deploy Bot commented Sep 8, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Unkey Deploy

Name Status Preview Inspect Updated (UTC)
links (preview) Ready Visit Preview Inspect Sep 8, 2026 5:09pm

@vercel

vercel Bot commented Sep 8, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
dashboard Ready Ready Preview Sep 8, 2026 5:10pm UTC
databuddy-status Ready Ready Preview Sep 8, 2026 5:10pm UTC
documentation Ready Ready Preview Sep 8, 2026 5:10pm UTC

@coderabbitai

coderabbitai Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 70bce5d3-f5cd-4928-b70a-7a8e32ede5e2

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@greptile-apps

greptile-apps Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR aligns Business Context with the established Organization Settings presentation and interaction model.

  • Moves Save and Discard controls into the shared top bar and adds a synchronous duplicate-save guard.
  • Uses the standard card-based, max-w-2xl, independently scrolling settings layout.
  • Constrains the brief editor to 12 rows and presents generated sources as individually scannable links.
  • Updates loading UI and authenticated regression coverage for keyboard saving and single submission.

Confidence Score: 5/5

The PR appears safe to merge with no concrete correctness, security, or repository-rule issues identified.

The duplicate keyboard listeners created by shared desktop and mobile top-bar rendering are safely serialized by the synchronous guard, source URLs are validated before rendering, and the revised layout follows the existing General settings structure.

Important Files Changed

Filename Overview
apps/dashboard/app/(main)/organizations/components/business-context-editor.tsx Reworks the editor into shared cards, moves actions to the top bar, formats source links, and safely guards duplicate save submissions.
apps/dashboard/app/(main)/organizations/components/business-context-settings.tsx Adopts the established Organization Settings width, scrolling, and card-shaped loading layout.
apps/dashboard/test/e2e/specs/regressions/business-context.spec.ts Exercises the real keyboard save path and verifies that it produces exactly one request and persists the edited brief.
.agents/skills/databuddy-internal/SKILL.md Documents the established visual and structural conventions for Organization Settings work.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Edit business brief] --> B[Draft becomes dirty]
    B --> C[Top-bar Save and Discard appear]
    C -->|Discard| D[Restore saved brief]
    C -->|Click Save or keyboard shortcut| E{Save already active?}
    E -->|Yes| F[Ignore duplicate submission]
    E -->|No| G[Set synchronous saving guard]
    G --> H[Submit existing save mutation]
    H -->|Success| I[Clear draft and show saved notice]
    H -->|Failure| J[Keep edits and show error]
    I --> K[Release saving guard]
    J --> K
Loading

Reviews (1): Last reviewed commit: "fix(dashboard): match business context t..." | Re-trigger Greptile

@izadoesdev
izadoesdev merged commit 05737fa into staging Sep 8, 2026
16 checks passed
@izadoesdev
izadoesdev deleted the codex/business-context-settings-design branch September 8, 2026 20:39
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.

1 participant