-1

Could you please advice whether is it possible to achieve the following behavior with the Vaadin Grid details:

  1. Do not show details row based on grid item content.
  2. Do not collaps previously expanded details on another rows (be able to show details for more than one row).

I am using the latest release version of Vaadin 24.

Thanks in advance, Vadim

  • Please add the code you have tried and how it failed (e.g. errors, stacktraces, logs, ...) so we can improve on it. – cfrick Jul 28 '23 at 19:23

1 Answers1

1

Yes to both.

You can toggle the visibility of the details panel manually with the setDetailsVisible(T item, boolean visible) method, e.g. triggered from a clicklistener on the row, depending on the item on that row.

The 2nd example in this section https://vaadin.com/docs/latest/components/grid#item-details has an example of using that method, and also demonstrates having multiple details open simultaneously.

Rolf
  • 2,178
  • 4
  • 18
  • 29