Skip to content

feat(zoom-controls): default to horizontal orientation - #14

Merged
Andreas-Garcia merged 1 commit into
mainfrom
feature/zoom-controls-horizontal-default
Nov 2, 2026
Merged

Andreas-Garcia merged 1 commit into
mainfrom
feature/zoom-controls-horizontal-default

Conversation

@Andreas-Garcia

Copy link
Copy Markdown
Member

Summary

ZoomControls now defaults to orientation="horizontal". Every consumer already uses the horizontal layout (app-kit-ui, grow's GenealogyChart), so the vertical default only forced them to pass the prop. This is the first step of making the controls single-orientation in genre-tree-view.

Changes

  • ZoomControls.tsx: default orientation is "horizontal"; the prop is kept, so orientation="vertical" still works and explicit "horizontal" callers are unaffected.
  • CHANGELOG.md [Unreleased]: Changed entry. Behavior change for callers relying on the old default, so the release is a minor (0.11.0).

Test plan

  • pnpm build
  • pnpm lint (tsc --noEmit)
  • No automated test: the package has no test runner (pnpm test prints "no tests yet"), so the default is not covered by a test.

🤖 Generated with Claude Code

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings November 2, 2026 13:56
@Andreas-Garcia
Andreas-Garcia merged commit 1726e40 into main Nov 2, 2026
4 checks passed

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The diff is a minimal, self-consistent default change with rendering logic that correctly handles both orientation values and an accurate CHANGELOG entry, leaving no outstanding issues.

No open issues 🎉

What changed in this PR

This PR changes the ZoomControls primitive in @behindthemusictree/ui so that orientation defaults to "horizontal" instead of "vertical". Since every current consumer already passes orientation="horizontal", the old vertical default only forced them to set the prop explicitly. The prop itself is retained, so orientation="vertical" still produces the column layout. This is a small, backward-compatible-at-the-API-level step toward simplifying the controls in genre-tree-view.

Changes:

  • Default orientation for ZoomControls is now "horizontal" (prop kept, so "vertical" still works).
  • Added a ### Changed entry under [Unreleased] in CHANGELOG.md documenting the new default and how to restore the column layout.
File Description
packages/​ui/​src/​ZoomControls.tsx Flips the default value of the orientation prop from "vertical" to "horizontal"; rendering logic already supports both.
CHANGELOG.md Documents the default-orientation behavior change under [Unreleased] > Changed.

Review effort: Balanced

@Andreas-Garcia
Andreas-Garcia deleted the feature/zoom-controls-horizontal-default branch November 2, 2026 17:58
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