Skip to content

Kit: add a padded option to Group - #220

Open
agorischek wants to merge 1 commit into
mainfrom
agorischek/group-padded
Open

agorischek wants to merge 1 commit into
mainfrom
agorischek/group-padded

Conversation

@agorischek

Copy link
Copy Markdown
Collaborator

Agent assessment

Self-reported assessment, not an independent review.

Assessed revision: 17c567cc0cb3f238f8cd431e2c96f4e6d5412f52

Dimension Assessment Rationale
Change confidence 9/10 ↑ Opt-in prop; default markup unchanged (test asserts both).
↑ Kit tests, lint and tools check --fast pass.
↓ No browser screenshot of a padded group; no built-in uses it yet.

Superego feedback item 20: Group gets a padded prop.

  • padded wraps the body in pk-group-body, inset by --projections-space-3, the header band's own horizontal inset, so prose, chips or a short list line up with the title.
  • The default stays unpadded, so tables keep running edge to edge. Card grids keep their existing inset (same rule).
  • Documented in the components guide and the generated kit reference; a kit test covers both markups and the shared CSS rule.

A padded group insets its body by the header band's own inset, so prose,
chips or a short list line up with the title. The default stays unpadded so
tables keep running edge to edge.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

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

No active review issues are reported for the optional Group body-padding change.

No open issues 🎉

What changed in this PR

Adds opt-in body padding to the renderer kit’s Group component, while preserving the default edge-to-edge layout for tables.

Changes:

  • Adds a padded prop that wraps group content in an inset body.
  • Shares the existing card-grid padding rule with padded group bodies.
  • Documents the option and adds assertions for padded/default markup and CSS spacing.
File Description
packages/​renderers/​kit/​test/​group.test.mjs Tests padded and default markup, plus shared spacing rules.
packages/​renderers/​kit/​styles/​layout.css Applies the existing card-grid inset to padded bodies.
packages/​renderers/​kit/​src/​react/​layout-components.tsx Adds the optional padded prop and conditional body wrapper.
docs/​reference/​renderer-kit.md Updates the generated API reference for padded.
docs/​guides/​renderer-kit-components.md Explains when to use padded groups.

Review effort: Balanced

This branch has not been deployed

No deployments
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