Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spread: Add new layout component #1554

Merged
merged 7 commits into from
Aug 9, 2024
Merged

Spread: Add new layout component #1554

merged 7 commits into from
Aug 9, 2024

Conversation

michaeltaranto
Copy link
Contributor

Introduce a new layout component, Spread, used to justify content with both an equally distribute and a specify the minimum amount of space in between each child.

EXAMPLE USAGE:

The Spread component will work horizontally by default:

<Spread space="small" alignY="center">
  <Heading level="4">Heading</Heading>

  <OverflowMenu label="Options">
    <MenuItem>First</MenuItem>
    <MenuItem>Second</MenuItem>
  </OverflowMenu>
</Spread>

But can be switched to vertical via the direction prop:

<Spread space="large" direction="vertical">
  <Stack space="small">
    <Heading level="4">Heading</Heading>
    <Text>Text</Text>
  </Stack>

  <Text size="small" tone="secondary">
    Date
  </Text>
</Spread>

Previews

direction="horizontal"

Horizontal demo

direction="vertical"

Vertical demo

Review notes

Includes updated snippets and examples to use latest spacing and layout guidance, e.g. Job Summary example, and Card snippets.

@michaeltaranto michaeltaranto requested a review from a team as a code owner August 7, 2024 01:43
Copy link

changeset-bot bot commented Aug 7, 2024

🦋 Changeset detected

Latest commit: 2f4effd

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
braid-design-system Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

.changeset/proud-moles-exist.md Outdated Show resolved Hide resolved
.changeset/proud-moles-exist.md Outdated Show resolved Hide resolved
site/src/App/routes/foundations/layout/layout.tsx Outdated Show resolved Hide resolved
@michaeltaranto michaeltaranto merged commit 530251f into master Aug 9, 2024
6 checks passed
@michaeltaranto michaeltaranto deleted the add-spread branch August 9, 2024 00:11
@seek-oss-ci seek-oss-ci mentioned this pull request Aug 9, 2024
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