Hello,
I am testing out the 'Toolset Blocks' plugin, and have questions regarding the 'View Loop' block.
I have created a simple test view with toolset block view. On the front-end, looking at the devTool (the HTML structure), I see that it has generated a parent container/div for each post item, and the divs has these classnames:
"wp-block-toolset-views-view-template-block wpv-block-loop-item php-to-be-replaced-with-shortcode"
and the data attribute:
data-toolset-views-view-template-block="59ce0d027cb7c1f650e0dca66ce0d7ae"
(screenshot attached- highlighted in yellow)
Is there a way to customize the generated parent container/div?
I would like add a custom class name to the loop div that would have a dynamic post value, such as the post ID. So something like this:
class="wp-block-toolset-views-view-template-block wpv-block-loop-item php-to-be-replaced-with-shortcode loop-item-id-77"
In the example above, the custom classname is 'loop-item-id-77' , 77 is the dynamic value (the post ID).
Also, I have included a screenshot of the list view on how I've created this test view.
Is there a way to add a custom classname with a dynamic post value for each of the parent container inside the loop container?
Thank you!