Comments (1)
Hello @studiohic. Thank you for the report.
After looking into this, I can see that this block is not a standard block that has queryable attributes. Its part of the Full-stack editing blocks that are generated dynamically per page.
If you look at the contents of a saved CoreNavigation block you will see that it contains only a reference:
<!-- wp:navigation {"ref":45} /-->
This means that by default it cannot be parsed using the parse_blocks function. It won't do anything.
One could try to fix this by retrieving the navigation model from the ref id (using https://developer.wordpress.org/reference/functions/wp_get_nav_menu_items/) and with adding Query Attributes that extract the menu items from the HTML or return the menu node so that users can query it.
Here is an example of how we do this with the MediaDetails attribute of the Image block
Here is the block code that does this work maybe you can make a sense out of it:
from wp-graphql-content-blocks.
Related Issues (20)
- CorePostTerms doesn't expose any way to ask for the terms HOT 9
- Content Blocks: Add configuration for running tests locally HOT 1
- Reusable block isn't resolved inside columns HOT 3
- CoreImage give wrong caption when lightbox is enable HOT 2
- Feature: Add support for Xpath selectors HOT 1
- Upload Schema Artifact workflow fails to upload schema HOT 1
- CircleCI deploy fails due to restricted context
- Switch to new PHPCSStandards/PHP_CodeSniffer package HOT 1
- Submit plugin to WordPress.org
- Failure running getIntrospectionQuery - GraphiQL IDE Schema not loading HOT 3
- When activation plugin, got Fatal error: Uncaught Error: Class "EnforceSemVer\EnforceSemVer" not found
- Support nested properties inside block.json attributes
- Missing fields in GraphQL query HOT 6
- Add WordPress "nightly" support to testing matrix
- CoreImage / CoreGallery how get MediaItem data?
- Critical error when installing plugin HOT 4
- ApolloError: Internal server error when querying "dropCap" attribute on core/paragraph block HOT 8
- CoreTable column alignment returns null HOT 1
- Interface field argument error in GraphQL IDE after update to WPGraphQL 1.26
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wp-graphql-content-blocks.