Skip to content

Add FormLayout context awareness to Button#698

Open
adamkudrna wants to merge 2 commits intomasterfrom
feature/button-in-form-layout
Open

Add FormLayout context awareness to Button#698
adamkudrna wants to merge 2 commits intomasterfrom
feature/button-in-form-layout

Conversation

@adamkudrna
Copy link
Copy Markdown
Member

@adamkudrna adamkudrna commented Mar 18, 2026

Add FormLayout context awareness to Button:

obrazek

Summary

  • Button now detects FormLayoutContext and applies isRootInFormLayout
    (justify-self: start) to prevent full-width stretching in both vertical
    and horizontal layouts
  • In horizontal FormLayout, isRootLayoutHorizontal places the button in
    the field column (grid-column-start: 2) above the md breakpoint,
    aligning it with adjacent form fields
  • Adds ButtonForFormLayoutTests story component and formLayout visual
    test suite mirroring the pattern from TextField
  • Updates FormLayout README to document Button as a supported component
    and moves the full-form example to a more prominent place near the top

Button now detects FormLayoutContext and applies `isRootInFormLayout`
(justify-self: start) and `isRootLayoutHorizontal` (grid-column-start: 2
above md breakpoint), matching the pattern used by all other form fields.
Also updates FormLayout README to document Button support and adds
Playwright component tests for the new FormLayout integration.
@github-project-automation github-project-automation bot moved this to 💡Ideas in The Board Mar 18, 2026
@adamkudrna adamkudrna moved this from 💡Ideas to 👀 In review in The Board Mar 18, 2026
@adamkudrna
Copy link
Copy Markdown
Member Author

adamkudrna commented Mar 18, 2026

👉 Thorough test coverage of Button behavior in the FormLayout context added in #699.

@adamkudrna adamkudrna requested a review from mbohal March 23, 2026 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: 👀 In review

Development

Successfully merging this pull request may close these issues.

2 participants