Description
In PWA Studio we select one of a product's categories to render breadcrumbs on the page.
!product_categories.png|thumbnail!
A product can belong to an enabled category whose parent is disabled.
!disabled_categories.png|thumbnail!
When querying for the product's categories.breadcrumbs data we are seeing the child category return with breadcrumbs data for the disabled category.
!product_query.jpg|thumbnail!
Because we don't know that the category ("id 8" from the screenshot) belongs to a disabled parent category ("id 7"), we use it as the category to render breadcrumbs for the product.
So we make a category query using the enabled child (8) for breadcrumbs data in order to render them:
!breadcrumb_query.png|thumbnail!
What results is our UI rendering links/breadcrumbs for categories which are inaccessible.
Expected Outcome:
I would expect that the GQL api expose that the category is disabled either by not including it in the result or by providing some prop such as disabled
in the query.
You can repro by going https://venia-smoketest-x3mnlqi-c5v7sxvquxwl4.eu-4.magentosite.cloud/layla-tee.html for now.