Skip to content

Commit

Permalink
DataViews: Fix primary field misalignment in grid layout (#66995)
Browse files Browse the repository at this point in the history
Co-authored-by: t-hamano <[email protected]>
Co-authored-by: youknowriad <[email protected]>
  • Loading branch information
3 people authored Nov 15, 2024
1 parent 2e4b8d8 commit 02f67b8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 3 additions & 5 deletions packages/dataviews/src/dataviews-layouts/grid/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,9 @@ function GridItem< Item >( {
justify="space-between"
className="dataviews-view-grid__title-actions"
>
<HStack>
<div { ...clickablePrimaryItemProps }>
{ renderedPrimaryField }
</div>
</HStack>
<div { ...clickablePrimaryItemProps }>
{ renderedPrimaryField }
</div>
<ItemActions item={ item } actions={ actions } isCompact />
</HStack>
{ !! badgeFields?.length && (
Expand Down
2 changes: 2 additions & 0 deletions packages/dataviews/src/dataviews-layouts/grid/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@

.dataviews-view-grid__primary-field {
min-height: $grid-unit-40; // Preserve layout when there is no ellipsis button
display: flex;
align-items: center;

&--clickable {
width: fit-content;
Expand Down

1 comment on commit 02f67b8

@github-actions
Copy link

Choose a reason for hiding this comment

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

Flaky tests detected in 02f67b8.
Some tests passed with failed attempts. The failures may not be related to this commit but are still reported for visibility. See the documentation for more information.

🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/11852650383
📝 Reported issues:

Please sign in to comment.