Skip to content

Commit

Permalink
Fix: use viewportWidth in pattern preview data view (#60315)
Browse files Browse the repository at this point in the history
Co-authored-by: fabiankaegy <[email protected]>
Co-authored-by: ntsekouras <[email protected]>
  • Loading branch information
3 people authored Apr 1, 2024
1 parent 7114727 commit fc78ac9
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/edit-site/src/components/page-patterns/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,12 @@ function Preview( { item, categoryId, viewType } ) {
>
{ isEmpty && isTemplatePart && __( 'Empty template part' ) }
{ isEmpty && ! isTemplatePart && __( 'Empty pattern' ) }
{ ! isEmpty && <BlockPreview blocks={ item.blocks } /> }
{ ! isEmpty && (
<BlockPreview
blocks={ item.blocks }
viewportWidth={ item.viewportWidth }
/>
) }
</PreviewWrapper>
</div>
{ ariaDescriptions.map( ( ariaDescription, index ) => (
Expand Down

0 comments on commit fc78ac9

Please sign in to comment.