As <nuxeo-results-view> was moved to nuxeo/nuxeo-elements, with it came the visible attribute. If this attribute is not set on the element, then it won't be displayed. The reasoning behind this is that the element was made initially to be used in a "selectable view" context (e.g. tabs), in which the element containing it is responsible for triggering its visibility. However, this is a limitation that doesn't make sense when the element is used outside that context (e.g. document picker).
Two possible ways of dealing with this are:
a) Introducing a second element what would either wrap or be wrapped by <nuxeo-results-view>. One element could specify all the behaviour tied to the actual search results, while the other would deal with the visibility behaviour separately. Note: it might make more sense to have a new element wrapped by <nuxeo-results-view>, as this would mean that results view would be able to maintain its API.
b) Allow <nuxeo-results-view> to be able to access its parent and know if it contains a attrForSelected attribute, in which case the element would then control its visibility depending on its own visible attribute. This would allow the results view element to be defined anywhere without having to explicitly set its visibility.
Note: Designer generates configuration with <nuxeo-results-view> (e.g. tabs listings), so we need to handle this carefully in order to avoid breaking customer projects and provide a smooth migration path (e.g. 10.10).
- is caused by
-
ELEMENTS-1311 Move nuxeo-seach-form-layout and nuxeo-seach-results-layout to nuxeo-elements
- Resolved