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

Backport: Navigation Post Preloading in Site Editor #4628

Closed

Conversation

getdave
Copy link
Contributor

@getdave getdave commented Jun 16, 2023

Adds a navigation.php file to hold all hooks/utilites relating to Navigation in the Block Editor.

Backports over the preloading hook for Navigation Posts.

Trac ticket: https://core.trac.wordpress.org/ticket/58556


This Pull Request is for code review only. Please keep all other discussion in the Trac ticket. Do not merge this Pull Request. See GitHub Pull Requests for Code Review in the Core Handbook for more details.

Copy link
Contributor

@audrasjb audrasjb left a comment

Choose a reason for hiding this comment

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

I left a small feedback concerning a small docblock issue :)

src/wp-includes/navigation.php Outdated Show resolved Hide resolved
@spacedmonkey
Copy link
Member

@getdave This new file needs to be loaded in wp-settings.php

@getdave
Copy link
Contributor Author

getdave commented Jun 20, 2023

Understood. My first time doing backports. Let me get this sorted.

@spacedmonkey
Copy link
Member

Understood. My first time doing backports. Let me get this sorted.

@getdave See my feedback on trac ticket before continuing.

@getdave
Copy link
Contributor Author

getdave commented Jun 21, 2023

Preload paths for Navigation have now be inlined directly in the Site Editor file as per recommendations.

@getdave getdave requested a review from audrasjb June 23, 2023 08:42
@spacedmonkey spacedmonkey self-requested a review June 23, 2023 08:57
'per_page' => 100,
'order' => 'desc',
'orderby' => 'date',
'_locale' => 'user',
Copy link
Member

Choose a reason for hiding this comment

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

The javascript should be refactored so this rest api call is not made twice.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Agreed. We're tracking it in WordPress/gutenberg#51803

@getdave
Copy link
Contributor Author

getdave commented Jun 26, 2023

Not sure what's going on with the CI tests here.

I believe I now wait for a Core Committer to merge this?

@ramonjd
Copy link
Member

ramonjd commented Jun 27, 2023

I believe I now wait for a Core Committer to merge this?

Yes! If @tellthemachines can't get to it today, hopefully someone will sweep in tonight and commit.

Thanks again!

@tellthemachines
Copy link
Contributor

committed in r56054 / 14a3070.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

5 participants