Random height for class X in list on pageload

Hi there,

I’m trying to generate a different height for a divider element inside a list using the following script:

<script type="text/javascript">
let divider = document.querySelector('.project_divider')

if (divider) {
	divider.style.setProperty('height', `calc(${Math.floor(Math.random() * 200) + 1}px`)
}

</script>

The trigger works, but it only calculates a height for the first element in the list. How do I get this to calculate a different height for each list element?

Thanks!


Here is my site Read-Only: LINK
(how to share your site Read-Only link)

Would be great if anyone could help me out here!