I am encountering a peculiar problem with the height behavior of a collapsible div. The expanded height of the div persists even after it is closed or collapsed. Please see the image below for reference:
https://i.sstatic.net/OetPL.jpg
The JavaScript seems to be adding the height to the list item on click. Here is a snippet of the inspect element:
<ul id="og-grid" class="og-grid">
<li><a target="_blank" href="www.somewebsite.com" data-
largesrc="uploadimage/project/sfs.jpg" data-title="Website Redesign of "
data-type="WebSite" data-description="Website Redesign "><img
src="uploadimage/project/thumb/sfs.jpg" alt="img00"></a></li>
<li style="**transition: height 350ms ease 0s; height: 719px;**"
class="">
<a href="#/" data-largesrc="uploadimage/project/notouch.jpg" data-
title="No Touch" data-type="Mobile Application" data-description="Notouch
is a simple but useful app that helps you to lock the screen temporarily
to prevent unauthorized clicks or to go to other apps from the current
screen. This is especially useful when you give your Phone to kids to view
videos or YouTube. This app will disable the touch facility temporarily.">
<img src="uploadimage/project/thumb/notouch.jpg" alt="img01"></a></li>
<li><a target="_blank" href="www.fhjgh.com" data-
largesrc="uploadimage/project/2capture.jpg" data-title="Test" data-
type="WebSite" data-description="hI there njwehkasd kahffhsaf sdkfhsdf
saklhflkdshf sdhfksdhf kldsh"><img
src="uploadimage/project/thumb/2capture.jpg" alt="img02"></a></li>
<li><a target="_blank" href="http://www.jhghjghjg.in" data-
largesrc="uploadimage/project/green.jpg" data-title="Green Homes" data-
type="WebSite" data-description=", due to better usage of pictures"><img
src="uploadimage/project/thumb/green.jpg" alt="img03"></a></li>
<li><a href="#/" data-largesrc="uploadimage/project/leonardo.jpg" data-
title="Leonardo" data-type="Logo Design" data-description="The Logo design
. We have used the negative space design concept here to make the L hidden
inside a box ( Box represent a furniture)"><img
src="uploadimage/project/thumb/leonardo.jpg" alt="img04"></a></li>
</ul>
Here is the relevant JavaScript code:
...
Any guidance on how to resolve this issue would be greatly appreciated. Is there a CSS or JavaScript solution available?