Skip to content

Commit

Permalink
Templates: fix deferred rendering for grid layout (#60361)
Browse files Browse the repository at this point in the history
Co-authored-by: oandregal <oandregal@git.wordpress.org>
Co-authored-by: ntsekouras <ntsekouras@git.wordpress.org>
  • Loading branch information
3 people committed Apr 2, 2024
1 parent 0f689f9 commit b68641d
Showing 1 changed file with 4 additions and 1 deletion.
Expand Up @@ -419,7 +419,10 @@ export default function PageTemplatesTemplateParts( { postType } ) {
view={ view }
onChangeView={ onChangeView }
onSelectionChange={ onSelectionChange }
deferredRendering={ ! view.hiddenFields?.includes( 'preview' ) }
deferredRendering={
view.type === LAYOUT_GRID ||
! view.hiddenFields?.includes( 'preview' )
}
/>
</Page>
);
Expand Down

0 comments on commit b68641d

Please sign in to comment.