- Issue created by @duaelfr
- πΊπΈUnited States dalemoore
I disagree with this if I'm understanding what you're saying. It's entirely possible to use a component that renders only with props defined in the SDC and no slots if you're using web components. The rendering logic is instead in the JS/CSS/template of the web component. In this case all of the fields will be in the "disabled" region in Manage Display, and there would be no slot region(s), with the fields being mapped to props in the component only. If this capability is taken away I would need to quit using UI Patterns. I may be misunderstanding what you're saying, though!
- π«π·France duaelfr Montpellier, France
What I'm saying is that Drupal Core currently does not allow that. If all fields are disabled, the entity is not displayed.
@pdureau dug a bit in this issue and figured out everything was happening inside
\Drupal\field_layout\FieldLayoutBuilder::buildView()
and\Drupal\field_layout\FieldLayoutBuilder::getFields()
. - πΊπΈUnited States dalemoore
Okay, I'm using Display Suite rather than Field Layout, and haven't noticed a problem with it rendering slot-less SDCs as layout for my use. Maybe the issue is only there then, or we're using it differently. Just wanted to provide a different use case.
- π«π·France pdureau Paris
Hello Dualefr,
We will see if we can do the change without being too specific to Field Layout.
With UI Patterns, we are not targeting display building tools (Field Layout, Manage Dispaly, Layout Builder, Block Layout, Views...), but Core plugin types: Blocks, Formatters, Layouts...
Of course, we wish to be compatible with all display builders, from Core and Contrib, so we will work on this subject, but I am not sure we will find a suitable fix.
- π«π·France just_like_good_vibes PARIS
It seems, the Field Layout Users should be careful to use only layouts with at least one region, and problem solved ?