Tell me, is there a plugin to generate a gallery like this:

- with equal height of "lines"
- dynamically determined by the width of the images, which precisely adjusts the width of "lines" for the screen size.
An example of such solutions in the implementation - Yandex-Pictures (
https://yandex.ua/images/search?text=nature&rdrnd=...
Looked for similar settings in the plugin Masonry (
masonry.desandro.com/) and counterparts - have not yet managed to find.
What can be another solution to the question?