Skip to content

feat(F0Form): add noPadding styling option#4535

Merged
warcos-fact merged 3 commits into
mainfrom
chop/f0form-no-padding
Jun 23, 2026
Merged

feat(F0Form): add noPadding styling option#4535
warcos-fact merged 3 commits into
mainfrom
chop/f0form-no-padding

Conversation

@warcos-fact

@warcos-fact warcos-fact commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Description

Adds a noPadding flag to F0FormStylingConfig that opts out of the default p-4 padding around form content (both the per-section and single-schema layouts), so a form can sit flush inside a host surface (e.g. an AI canvas panel). Defaults to false; existing usage is unaffected.

Extracted from the co-creation patterns PR (#4307).

Stacked on #4533 (chop/ai-processing-overlay); review that first.

Implementation details

  • feat: add noPadding?: boolean to F0FormStylingConfig, honoured in both F0FormPerSection and F0FormSingleSchema content wrappers
  • test: cover the noPadding option and document the styling config

@warcos-fact warcos-fact requested a review from a team as a code owner June 22, 2026 11:37
@github-actions github-actions Bot added feat react Changes affect packages/react labels Jun 22, 2026
@github-actions

github-actions Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

📦 Alpha Package Version Published

Use pnpm i github:factorialco/f0#npm/alpha-pr-4535 to install the package

Use pnpm i github:factorialco/f0#fb0b2cafce1ee111fbb2ea57df8ab4007b4486b8 to install this specific commit

@github-actions

github-actions Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

🔍 Visual review for your branch is published 🔍

Here are the links to:

@github-actions

github-actions Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Coverage Report for packages/react

Status Category Percentage Covered / Total
🔵 Lines 57.3% 17951 / 31328
🔵 Statements 56.49% 18726 / 33144
🔵 Functions 50% 4162 / 8324
🔵 Branches 50.3% 12832 / 25508
File Coverage
File Stmts Branches Functions Lines Uncovered Lines
Changed Files
packages/react/src/patterns/F0Form/F0Form.tsx 82.94% 77.01% 82.6% 83.92% 74-81, 96, 141-144, 157-162, 207-218, 354-366, 613-623, 636, 727, 782, 783, 813, 816-827, 872-878, 903-904, 909-930, 934, 1127
packages/react/src/patterns/F0Form/types.ts 100% 100% 100% 100%
Generated in workflow #15089 for commit d872f96 by the Vitest Coverage Report Action

@warcos-fact warcos-fact force-pushed the chop/f0form-no-padding branch from fe6cdeb to 10758bc Compare June 22, 2026 16:01
@warcos-fact warcos-fact requested a review from a team as a code owner June 22, 2026 16:01
@warcos-fact warcos-fact changed the base branch from chop/ai-chat-welcome-cards to chop/ai-processing-overlay June 22, 2026 16:02

@developerdanx developerdanx left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

💪

Base automatically changed from chop/ai-processing-overlay to main June 23, 2026 13:55
@github-actions

Copy link
Copy Markdown
Contributor

✅ No New Circular Dependencies

No new circular dependencies detected. Current count: 0

@github-actions

github-actions Bot commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

✅ No breaking public API changes

No public exports were removed, renamed, or had existing props/types changed in a breaking way compared to main.

Comparing f0, experimental and ai against main. Adding components, types, or optional props is safe. This check is non-blocking.

warcos-fact and others added 3 commits June 23, 2026 17:09
Opt-out of the default p-4 padding around form content, for embedding a
form flush inside a host surface (e.g. an AI canvas panel).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- test: assert the content wrapper keeps p-4 by default and drops it when
  styling.noPadding is true, for both single-schema and per-section layouts
- docs: add a Styling section to F0Form.mdx documenting showSectionsSidepanel
  and noPadding (nested in F0FormStylingConfig, not surfaced by argTypes)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…ting classes

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@warcos-fact warcos-fact force-pushed the chop/f0form-no-padding branch from 8adc9b0 to d872f96 Compare June 23, 2026 15:10
@warcos-fact warcos-fact merged commit 6bbfb00 into main Jun 23, 2026
24 checks passed
@warcos-fact warcos-fact deleted the chop/f0form-no-padding branch June 23, 2026 15:31
@eliseo-juan eliseo-juan mentioned this pull request Jun 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feat react Changes affect packages/react

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants