Skip to content

Commit

Permalink
DataViews: Fix pattens list selection (#63733)
Browse files Browse the repository at this point in the history
Co-authored-by: ntsekouras <ntsekouras@git.wordpress.org>
Co-authored-by: talldan <talldanwp@git.wordpress.org>
  • Loading branch information
3 people authored Jul 19, 2024
1 parent 5d4bf27 commit 6b0b4e4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/edit-site/src/components/page-patterns/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,7 @@ export default function DataviewsPatterns() {
const {
params: { postType, categoryId: categoryIdFromURL },
} = useLocation();
const [ selection, setSelection ] = useState( [] );
const type = postType || PATTERN_TYPES.user;
const categoryId = categoryIdFromURL || PATTERN_DEFAULT_CATEGORY;
const [ view, setView ] = useState( DEFAULT_VIEW );
Expand Down Expand Up @@ -409,6 +410,8 @@ export default function DataviewsPatterns() {
isLoading={ isResolving }
view={ view }
onChangeView={ setView }
selection={ selection }
onChangeSelection={ setSelection }
defaultLayouts={ defaultLayouts }
/>
</Page>
Expand Down

1 comment on commit 6b0b4e4

@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 6b0b4e4.
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/10005052967
📝 Reported issues:

Please sign in to comment.